* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    min-height: 100%;
}

body {
    font-family: Georgia, "Times New Roman", serif;
    color: #17345b;
    background:
        linear-gradient(135deg, #f5f9fc 0%, #ffffff 52%, #edf4f9 100%);
}

.page-shell {
    width: 1180px;
    max-width: calc(100% - 40px);
    margin: 28px auto;
    background: #ffffff;
    border: 1px solid #d8e0e8;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 18px 45px rgba(33, 53, 80, .12);
}

/* HEADER */

.davv-header {
    min-height: 175px;
    display: flex;
    align-items: center;
    padding: 26px 40px;
    color: #ffffff;
    background:
        linear-gradient(105deg, #153556 0%, #1c4f85 55%, #2e68ad 100%);
    border-bottom: 3px solid #e7b63c;
}

.davv-left {
    margin-right: 28px;
}

.davv-left img {
    width: 95px;
    height: 95px;
    object-fit: contain;
    background: #ffffff;
    padding: 5px;
    border-radius: 50%;
}

.davv-center {
    flex: 1;
}

.davv-center h1 {
    margin: 0 0 8px;
    font-size: 34px;
    line-height: 1.15;
    font-weight: 700;
    letter-spacing: .3px;
}

.davv-center p {
    margin: 0 0 4px;
    font-size: 17px;
}

.davv-center h3 {
    margin: 0;
    font-size: 18px;
    font-style: italic;
    font-weight: 600;
}

.header-motto {
    width: 130px;
    padding-left: 26px;
    border-left: 1px solid rgba(255,255,255,.25);
    font-style: italic;
    font-size: 16px;
    line-height: 1.45;
}

.header-motto span {
    display: block;
}

.header-motto::after {
    content: "";
    display: block;
    margin-top: 10px;
    width: 65px;
    height: 4px;
    background: #e6b438;
}

/* ITC STRIP */

.itc-strip {
    padding: 12px 20px;
    text-align: center;
    background: #fffaf0;
    color: #17345b;
    font-size: 17px;
    font-weight: 700;
    border-bottom: 1px solid #e6ded1;
}

/* MAIN */

.portal-content {
    padding: 44px 30px 0;
    background: #fbfdff;
}

/* CARDS */

.portal-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 34px;
    margin: 0 auto 36px;
}

.portal-card {
    min-height: 235px;
    position: relative;
    text-decoration: none;
    border-radius: 14px;
    padding: 28px 28px 26px;
    box-shadow: 0 12px 28px rgba(33, 53, 80, .10);
    transition: transform .18s ease, box-shadow .18s ease;
}

.portal-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 32px rgba(33, 53, 80, .15);
}

.student-card {
    background: linear-gradient(135deg, #eefafa, #ffffff);
    border: 1px solid #cce6e5;
    color: #006b6d;
}

.faculty-card {
    background: linear-gradient(135deg, #eef4ff, #ffffff);
    border: 1px solid #d5e1f5;
    color: #174f9c;
}

.staff-card {
    background: linear-gradient(135deg, #fff1f4, #ffffff);
    border: 1px solid #efd5da;
    color: #8b2137;
}

.card-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    font-size: 30px;
    background: rgba(255,255,255,.65);
}

.student-card .card-icon {
    background: #d9f2f1;
}

.faculty-card .card-icon {
    background: #dce8fa;
}

.staff-card .card-icon {
    background: #f5dce2;
}

.portal-card h2 {
    margin: 0 0 8px;
    font-size: 30px;
}

.portal-card p {
    margin: 0;
    font-size: 16px;
    line-height: 1.4;
}

.arrow {
    position: absolute;
    right: 26px;
    bottom: 26px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 2px solid currentColor;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* QUICK LINKS */

.quick-links {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    margin-bottom: 26px;
    background: #ffffff;
    border: 1px solid #dce3ea;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 22px rgba(35, 50, 80, .06);
}

.quick-links a {
    min-height: 90px;
    text-decoration: none;
    color: #17345b;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 20px;
    position: relative;
}

.quick-links a:not(:last-child) {
    border-right: 1px solid #dce3ea;
}

.quick-links > a > i:first-child {
    font-size: 24px;
}

.quick-links span {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.quick-links strong {
    font-size: 15px;
}

.quick-links small {
    font-size: 12px;
    color: #617087;
}

.q-arrow {
    margin-left: auto;
    font-size: 13px;
}

/* HERITAGE */

.heritage-zone {
    min-height: 190px;
    position: relative;
    overflow: hidden;
}

.heritage-text {
    position: relative;
    z-index: 2;
    padding-top: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 18px;
    color: #77859a;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 13px;
    letter-spacing: 1px;
}

.heritage-text i {
    width: 1px;
    height: 18px;
    background: #aeb8c6;
}

.campus-art {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 130px;
    background: transparent;
}

/* FOOTER */

.davv-footer {
    min-height: 90px;
    background: #153556;
    color: #ffffff;
    display: grid;
    grid-template-columns: 1.2fr 1.5fr 1fr;
    gap: 20px;
    align-items: center;
    padding: 20px 30px;
    font-size: 12px;
}

.footer-left {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.footer-left i {
    font-size: 18px;
}

.copyright {
    text-align: center;
    line-height: 1.5;
}

.footer-right {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-right div {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* RESPONSIVE */

@media (max-width: 900px) {

    .header-motto {
        display: none;
    }

    .portal-cards {
        gap: 18px;
    }

    .quick-links {
        grid-template-columns: 1fr 1fr;
    }

    .quick-links a:nth-child(2) {
        border-right: none;
    }
}

@media (max-width: 720px) {

    .page-shell {
        margin: 10px auto;
        max-width: calc(100% - 15px);
    }

    .davv-header {
        flex-direction: column;
        text-align: center;
        padding: 24px 18px;
    }

    .davv-left {
        margin: 0 0 15px;
    }

    .davv-center h1 {
        font-size: 23px;
    }

    .davv-center p {
        font-size: 13px;
    }

    .davv-center h3 {
        font-size: 14px;
    }

    .portal-cards {
        grid-template-columns: 1fr;
    }

    .quick-links {
        grid-template-columns: 1fr;
    }

    .quick-links a {
        border-right: none !important;
        border-bottom: 1px solid #dce3ea;
    }

    .davv-footer {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-left,
    .footer-right {
        justify-content: center;
        align-items: center;
    }
}

.dept-icon {
    font-size: 25px;
    line-height: 1;
    display: inline-block;
}


.search-user-icon {
    font-size: 24px;
    line-height: 1;
    display: inline-block;
}

/* =========================================================
   FIVE SERVICE CARD HOME PAGE
   ========================================================= */

.service-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 34px;
    max-width: none;
    margin: 0 auto 48px;
}

.service-grid .portal-card {
    grid-column: span 2;

    min-height: 235px;
    position: relative;

    padding: 28px 30px;

    display: block;

    border-radius: 14px;

    text-decoration: none;

    box-shadow:
        0 12px 28px rgba(33,53,80,.09);

    transition:
        transform .18s ease,
        box-shadow .18s ease;
}

.service-grid .portal-card:hover {
    transform: translateY(-4px);

    box-shadow:
        0 18px 34px rgba(33,53,80,.14);
}

/* Bottom two cards centered */

.service-grid .search-card {
    grid-column: 1 / span 3;
}

.service-grid .forgot-card {
    grid-column: 4 / span 3;
}

/* Card colors */

.dept-card {
    background: linear-gradient(135deg, #eef7ff, #ffffff);
    border: 1px solid #cfe0f5;
    color: #174f9c;
}

.contact-card {
    background: linear-gradient(135deg, #eefbf9, #ffffff);
    border: 1px solid #cceae5;
    color: #00737c;
}

.guest-card {
    background: linear-gradient(135deg, #f3f5ff, #ffffff);
    border: 1px solid #d6def6;
    color: #174f9c;
}

.search-card {
    background: linear-gradient(135deg, #fff9e9, #ffffff);
    border: 1px solid #efdca9;
    color: #9a6b00;
}

.forgot-card {
    background: linear-gradient(135deg, #fff1f4, #ffffff);
    border: 1px solid #efcfd7;
    color: #a51f39;
}

/* Icon circles */

.service-grid .card-icon {
    width: 64px;
    height: 64px;

    margin-bottom: 16px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    font-size: 29px;
}

.dept-card .card-icon {
    background: #dceafa;
}

.contact-card .card-icon {
    background: #d9f3ef;
}

.guest-card .card-icon {
    background: #e2e8fb;
}

.search-card .card-icon {
    background: #fff0c8;
}

.forgot-card .card-icon {
    background: #f8d8df;
}

/* Heading */

.service-grid .portal-card h2 {
    margin: 0 0 8px;

    font-size: 30px;
    line-height: 1.15;

    font-family: Georgia, "Times New Roman", serif;
    font-weight: 700;

    color: currentColor;
}

/* Description */

.service-grid .portal-card p {
    margin: 0;

    font-size: 16px;
    line-height: 1.45;

    color: currentColor;
    opacity: .9;
}

/* Arrow */

.service-grid .arrow {
    position: absolute;

    right: 26px;
    bottom: 26px;

    width: 42px;
    height: 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 2px solid currentColor;
    border-radius: 50%;

    font-size: 15px;
}

/* Icon fallback sizing */

.dept-icon,
.search-user-icon {
    display: inline-block;
    line-height: 1;
    font-size: 30px;
}

/* Hide old quick link layout if any remained */

.quick-links {
    display: none !important;
}

/* Responsive */

@media (max-width: 900px) {

    .service-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .service-grid .portal-card,
    .service-grid .search-card,
    .service-grid .forgot-card {
        grid-column: auto;
    }
}

@media (max-width: 620px) {

    .service-grid {
        grid-template-columns: 1fr;
    }

    .service-grid .portal-card {
        min-height: 185px;
    }

    .service-grid .portal-card h2 {
        font-size: 25px;
    }
}

/* ===== SIX CARD LAYOUT ===== */

.service-grid .search-card,
.service-grid .forgot-card,
.service-grid .support-card {
    grid-column: span 2;
}

.support-card {
    background: linear-gradient(135deg, #eef8f4, #ffffff);
    border: 1px solid #cce4d9;
    color: #176b55;
}

.support-card .card-icon {
    background: #dcefe7;
}

@media (max-width: 900px) {
    .service-grid .search-card,
    .service-grid .forgot-card,
    .service-grid .support-card {
        grid-column: auto;
    }
}

@media (max-width: 620px) {
    .service-grid .search-card,
    .service-grid .forgot-card,
    .service-grid .support-card {
        grid-column: auto;
    }
}
