:root {
    --navy-900: #0b1f3a;
    --navy-800: #0f2547;
    --blue-700: #284F78;
    --blue-600: #315b91;
    --amber-600: #b57503;
    --ink-line: #292d32;
    --card-edge: rgba(32, 36, 42, 0.98);
    --text-body: #526174;
    --text-muted: #64707f;
    --text-on-dark-muted: #bbc8d8;
    --surface: #ffffff;
    --surface-alt: #f4f6f8;
    --white: #ffffff;
    --border: #e3e7ec;
    --shadow-soft: rgba(0, 0, 0, 0.08);

    --fs-h2: clamp(1.5rem, 1.1rem + 1.5vw, 2rem);
    --fs-h2-banner: clamp(1.75rem, 1.3rem + 1.6vw, 2.25rem);
    --fs-body: 1rem;
    --lh-body: 1.8;

    --section-y: clamp(2.8rem, 7vw, 5.625rem);
    --section-x: clamp(1.25rem, 6vw, 5rem);
    --container: 1100px;
    --measure: 50rem;
}

* {
    padding: 0px;
    margin: 0px;
    box-sizing: border-box;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    scrollbar-width: thin;
    scrollbar-color: var(--blue-700) var(--surface-alt);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--surface-alt);
}

::-webkit-scrollbar-thumb {
    background-color: var(--blue-700);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background-color: var(--navy-900);
}

/* Navigation */

.skip-link {
    position: absolute;
    top: -100px;
    left: 1.5rem;
    background-color: var(--navy-900);
    color: var(--white);
    padding: 0.75rem 1.25rem;
    border-radius: 0 0 8px 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    z-index: 999999;
    box-shadow: 0 4px 14px rgba(11, 31, 58, 0.35);
    transition: top 0.2s ease-in-out;
}

.skip-link:focus,
.skip-link:focus-visible {
    top: 0;
    outline: 3px solid var(--blue-600);
    outline-offset: 2px;
}

main:focus {
    outline: none;
}

#nav-placeholder {
    min-height: 164px;
}

.navigation {
    display: flex;
    flex-direction: column;
    justify-content: left;
}

.nav__logo {
    height: 5rem;      
    width: auto;       
    object-fit: contain;
    margin: 0;
    padding: 0;
}

.nav__logo--section{
    padding: 1rem;
    display: flex;
    gap: 1rem;
    justify-content: center;
    align-items: center;
}

.nav__items {
    background-color: #0b1f3a;
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: center; 
    align-items: center;
    gap: clamp(1.5rem, 4vw, 3rem);
}


.nav__item {
    color: white;
    text-decoration: none;
    font-size: clamp(0.95rem, 1.2vw, 1.05rem);
    white-space: nowrap;
    font-weight: 500;
    margin: 0; 
    flex-shrink: 0;
}

.nav__toggle {
    display: none;
}

.nav__dropdown {
    position: relative;
    display: inline-block;
}

.nav__submenu {
    display: none;
}

.nav__submenu-item {
    text-decoration: none;
}

@media (max-width: 768px) {
    #nav-placeholder {
        min-height: 88px;
    }

    .nav__logo--section {
        position: relative;
        justify-content: center;
        padding: 1rem;
    }

    .nav__logo {
        height: 3.5rem;
    }

    .nav__toggle {
        display: flex;
        flex-direction: column;
        gap: 5px;
        background: none;
        border: 0;
        padding: 0.5rem;
        cursor: pointer;
        position: absolute;
        right: 1rem;
        top: 50%;
        transform: translateY(-50%);
    }

    .nav__toggle span {
        width: 26px;
        height: 3px;
        background: #0b1f3a;
        border-radius: 2px;
        transition: transform 0.25s, opacity 0.25s;
    }

    .nav__toggle.active span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .nav__toggle.active span:nth-child(2) { opacity: 0; }
    .nav__toggle.active span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

    .nav__items {
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 0;
    }

    .nav__items.open {
        display: flex;
    }

    .nav__item {
        display: block;
        padding: 1rem 1.25rem;
        font-size: 1.05rem;
        text-decoration: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav__dropdown.nav__item {
        display: block;
        width: 100%;
        padding: 0;
    }

    .nav__dropdown > .nav__item {
        display: flex;
        align-items: center;
        justify-content: space-between;
        border-bottom: 0;
        cursor: pointer;
    }

    .nav__dropdown.open > .nav__item {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav__dropdown > .nav__item::after {
        content: "";
        display: inline-block;
        width: 8px;
        height: 8px;
        border-right: 2px solid #ffffff;
        border-bottom: 2px solid #ffffff;
        transform: rotate(45deg);
        transition: transform 0.25s ease;
        margin-right: 0.25rem;
    }

    .nav__dropdown.open > .nav__item::after {
        transform: rotate(-135deg);
    }

    .nav__submenu {
        display: none;
        flex-direction: column;
        position: static;
        background-color: #0f2547;
        padding: 0;
        margin: 0;
        border: none;
        border-radius: 0;
        box-shadow: none;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: none;
        min-width: 0;
        width: 100%;
    }

    .nav__dropdown.open .nav__submenu {
        display: flex;
    }

    .nav__submenu-item {
        display: block;
        color: rgba(255, 255, 255, 0.9);
        padding: 0.85rem 1.25rem 0.85rem 2.25rem;
        font-size: 0.98rem;
        text-decoration: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
        transition: background-color 0.18s ease;
    }

    .nav__submenu-item:last-child {
        border-bottom: none;
    }

    .nav__submenu-item:hover,
    .nav__submenu-item:focus-visible {
        background-color: rgba(255, 255, 255, 0.08);
        color: #ffffff;
    }

    .nav__items > a.nav__item.active,
    .nav__dropdown.active > a.nav__item {
        background-color: #1e3f63;
        border-left: 4px solid #ffffff;
        padding-left: calc(1.25rem - 4px);
    }

    .nav__submenu-item.active {
        background-color: #284F78;
        color: #ffffff;
        border-left: 4px solid #ffffff;
        padding-left: calc(2.25rem - 4px);
    }
}

.nav__logo-link {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    transition: transform 0.25s ease;
}

.nav__logo-link:hover {
    transform: scale(1.02);
}

@media (min-width: 769px) {
    .nav__items {
        padding: 0.85rem 2rem;
        gap: clamp(1.5rem, 3.5vw, 3rem);
    }

    .nav__dropdown.nav__item {
        padding: 0;
        background: transparent;
    }

    .nav__items > a.nav__item,
    .nav__dropdown > a.nav__item {
        padding: 0.5rem 1.15rem;
        border-radius: 8px;
        transition: background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
    }

    .nav__items > a.nav__item:hover,
    .nav__items > a.nav__item:focus-visible,
    .nav__dropdown:hover > a.nav__item,
    .nav__dropdown:focus-within > a.nav__item {
        background-color: rgba(255, 255, 255, 0.12);
        color: #ffffff;
    }

    .nav__dropdown.open > a.nav__item {
        background-color: rgba(255, 255, 255, 0.16);
        color: #ffffff;
    }

    .nav__items > a.nav__item.active,
    .nav__dropdown.active > a.nav__item {
        background-color: var(--blue-700);
        color: #ffffff;
        font-weight: 600;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    }

    .nav__dropdown > a.nav__item {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
    }

    .nav__dropdown > a.nav__item::after {
        content: "";
        display: inline-block;
        width: 6px;
        height: 6px;
        border-right: 2px solid currentColor;
        border-bottom: 2px solid currentColor;
        transform: translateY(-1px) rotate(45deg);
        transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    }

    .nav__dropdown:hover > a.nav__item::after,
    .nav__dropdown:focus-within > a.nav__item::after,
    .nav__dropdown.open > a.nav__item::after {
        transform: translateY(2px) rotate(-135deg);
    }

    .nav__submenu {
        display: flex;
        position: absolute;
        top: calc(100% + 8px);
        left: 50%;
        transform: translateX(-50%) translateY(8px);
        background: rgba(11, 31, 58, 0.96);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border: 1px solid rgba(255, 255, 255, 0.14);
        border-radius: 12px;
        min-width: 190px;
        padding: 0.5rem;
        box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
        z-index: 100;
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: opacity 0.22s cubic-bezier(0.16, 1, 0.3, 1), transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.22s;
        flex-direction: column;
        gap: 0.25rem;
    }

    .nav__submenu::before {
        content: "";
        position: absolute;
        top: -12px;
        left: 0;
        right: 0;
        height: 12px;
    }

    .nav__dropdown:hover .nav__submenu,
    .nav__dropdown:focus-within .nav__submenu,
    .nav__dropdown.open .nav__submenu {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateX(-50%) translateY(0);
    }

    .nav__submenu-item {
        color: rgba(255, 255, 255, 0.9);
        padding: 0.65rem 1rem;
        border-radius: 8px;
        font-size: 0.92rem;
        font-weight: 500;
        text-decoration: none;
        display: block;
        white-space: nowrap;
        transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
    }

    .nav__submenu-item:hover,
    .nav__submenu-item:focus-visible {
        background-color: var(--blue-700);
        color: #ffffff;
        transform: translateX(3px);
    }

    .nav__submenu-item.active {
        background-color: var(--blue-700);
        color: #ffffff;
        font-weight: 600;
    }
}

/* Footer */


.footer__section {
    background-color: #0b1f3a;
    color: #64707f;
    padding: clamp(1.5rem, 3vw, 3rem) clamp(0.5rem, 2vw, 1.5rem) 1.5rem;
}

.footer__container {
    max-width: 1200px;
    margin: 0 auto;
}

.footer__info-container {
    display: flex;
    flex-wrap: nowrap; 
    justify-content: space-between;
    gap: clamp(0.5rem, 2vw, 2.5rem); 
    padding-bottom: 2rem;
}

.info__section {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    flex: 1 1 0; 
    min-width: 0; 
}

.info__title {
    color: white;
    font-size: clamp(0.85rem, 1.5vw, 1.1rem); 
    margin: 0 0 0.3rem;
    white-space: nowrap;
}

.info__section p, 
.info__section a {
    color: #64707f;
    font-size: clamp(0.7rem, 1.1vw, 0.9rem);
    text-decoration: none;
    transition: color 0.2s ease;
    word-break: break-word; 
}

.info__section a:hover {
    color: #284F78;
}

.footer__brand {
    flex: 1.2 1 0;
}

.footer__tagline {
    line-height: 1.4;
    margin: 0;
}

.footer__socials {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.85rem;
}

.footer__socials a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.4rem;
    border-radius: 50%;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.footer__socials a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.footer__social-icon {
    width: clamp(1.2rem, 1.8vw, 1.45rem);
    height: clamp(1.2rem, 1.8vw, 1.45rem);
    filter: brightness(0) invert(1);
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

.footer__socials a:hover .footer__social-icon {
    opacity: 1;
}

.footer__divider {
    height: 1px;
    background-color: rgba(255, 255, 255, 0.1);
    margin-bottom: 1.25rem;
}

.footer__copyright {
    text-align: center;
    font-size: clamp(0.7rem, 1vw, 0.8rem);
    margin: 0;
}



[data-scroll] {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    will-change: opacity, transform;
}

[data-scroll].show {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* Staggered Scroll Reveals */
[data-scroll] .stats__grid > .stat,
[data-scroll] .approach__grid > .approach__card,
[data-scroll] .gallery__cards > .gallery__card,
[data-scroll] .gallery__grid > .gallery__image,
[data-scroll] .donor__images > .donor__card,
[data-scroll] .person__section,
[data-scroll] .contact__cards > .contact__card,
[data-scroll] .project-grid > .project-card {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-scroll].show .stats__grid > .stat,
[data-scroll].show .approach__grid > .approach__card,
[data-scroll].show .gallery__cards > .gallery__card,
[data-scroll].show .gallery__grid > .gallery__image,
[data-scroll].show .donor__images > .donor__card,
[data-scroll].show .person__section,
[data-scroll].show .contact__cards > .contact__card,
[data-scroll].show .project-grid > .project-card {
    opacity: 1;
    transform: translateY(0);
}

[data-scroll].show .stats__grid > .stat:nth-child(1),
[data-scroll].show .approach__grid > .approach__card:nth-child(1),
[data-scroll].show .gallery__cards > .gallery__card:nth-child(1),
[data-scroll].show .gallery__grid > .gallery__image:nth-child(1),
[data-scroll].show .donor__images > .donor__card:nth-child(1),
[data-scroll].show .person__section:nth-child(1),
[data-scroll].show .contact__cards > .contact__card:nth-child(1),
[data-scroll].show .project-grid > .project-card:nth-child(1) {
    transition-delay: 0.08s;
}

[data-scroll].show .stats__grid > .stat:nth-child(2),
[data-scroll].show .approach__grid > .approach__card:nth-child(2),
[data-scroll].show .gallery__cards > .gallery__card:nth-child(2),
[data-scroll].show .gallery__grid > .gallery__image:nth-child(2),
[data-scroll].show .donor__images > .donor__card:nth-child(2),
[data-scroll].show .person__section:nth-child(2),
[data-scroll].show .contact__cards > .contact__card:nth-child(2),
[data-scroll].show .project-grid > .project-card:nth-child(2) {
    transition-delay: 0.16s;
}

[data-scroll].show .stats__grid > .stat:nth-child(3),
[data-scroll].show .approach__grid > .approach__card:nth-child(3),
[data-scroll].show .gallery__cards > .gallery__card:nth-child(3),
[data-scroll].show .gallery__grid > .gallery__image:nth-child(3),
[data-scroll].show .donor__images > .donor__card:nth-child(3),
[data-scroll].show .person__section:nth-child(3),
[data-scroll].show .contact__cards > .contact__card:nth-child(3),
[data-scroll].show .project-grid > .project-card:nth-child(3) {
    transition-delay: 0.24s;
}

[data-scroll].show .approach__grid > .approach__card:nth-child(4),
[data-scroll].show .gallery__cards > .gallery__card:nth-child(4),
[data-scroll].show .gallery__grid > .gallery__image:nth-child(4),
[data-scroll].show .donor__images > .donor__card:nth-child(4),
[data-scroll].show .project-grid > .project-card:nth-child(4) {
    transition-delay: 0.32s;
}

[data-scroll].show .approach__grid > .approach__card:nth-child(5),
[data-scroll].show .gallery__cards > .gallery__card:nth-child(5),
[data-scroll].show .gallery__grid > .gallery__image:nth-child(5),
[data-scroll].show .project-grid > .project-card:nth-child(5) {
    transition-delay: 0.40s;
}

[data-scroll].show .gallery__grid > .gallery__image:nth-child(6) { transition-delay: 0.46s; }
[data-scroll].show .gallery__grid > .gallery__image:nth-child(7) { transition-delay: 0.52s; }
[data-scroll].show .gallery__grid > .gallery__image:nth-child(8) { transition-delay: 0.58s; }

/* Card Living Hover Interaction */
.approach__card,
.project-card,
.gallery__card,
.contact__card {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s ease !important;
}

.approach__card:hover,
.project-card:hover,
.project-card:focus-visible,
.gallery__card:hover,
.gallery__card:focus-visible,
.contact__card:hover {
    transform: translateY(-6px) !important;
    border-top-color: var(--blue-700) !important;
    box-shadow: 0 14px 30px rgba(11, 31, 58, 0.12) !important;
}

.approach__card:hover {
    box-shadow: 0px -7px 0px 0px var(--blue-700), 0 14px 30px rgba(11, 31, 58, 0.12) !important;
}

/* Button Interactions & Shimmer */
.feature__cta-button,
.explore__button,
.detail-button,
.notfound__button {
    position: relative;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

.feature__cta-button::after,
.explore__button::after,
.detail-button::after,
.notfound__button::after {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 60%;
    height: 100%;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.22) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: skewX(-20deg);
    transition: left 0.65s ease;
    pointer-events: none;
}

.feature__cta-button:hover::after,
.explore__button:hover::after,
.detail-button:hover::after,
.notfound__button:hover::after {
    left: 150%;
}

.feature__cta-button:hover,
.explore__button:hover,
.detail-button:hover,
.notfound__button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(11, 31, 58, 0.2);
}

.feature__cta-button:active,
.explore__button:active,
.detail-button:active,
.notfound__button:active {
    transform: translateY(0);
}

/* Atmospheric Hero Depth */
.projects-hero,
.section-heading.about__heading-container,
.section-heading.contact__heading-container,
.section-heading.gallery__heading-container,
.detail-hero {
    background: linear-gradient(135deg, #0b1f3a 0%, #16365c 50%, #0b1f3a 100%) !important;
}

/* Page Transition */
@view-transition {
    navigation: auto;
}

body {
    opacity: 0;
    transition: opacity 0.25s ease-out;
}

body.page-loaded {
    opacity: 1;
}

body.page-fading-out {
    opacity: 0;
    transition: opacity 0.2s ease-in;
}

.page-loader {
    position: fixed;
    inset: 0;
    background-color: var(--surface-alt);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s;
    pointer-events: none;
}

.page-loader.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.spinner {
    width: 38px;
    height: 38px;
    border: 3.5px solid rgba(11, 31, 58, 0.12);
    border-top-color: var(--blue-700);
    border-radius: 50%;
    animation: pageSpin 0.75s linear infinite;
}

@keyframes pageSpin {
    to {
        transform: rotate(360deg);
    }
}

@media (prefers-reduced-motion: reduce) {
    body {
        opacity: 1 !important;
        transition: none !important;
    }

    .page-loader {
        display: none !important;
    }

    .back-to-top {
        transition: none !important;
    }

    .skip-link {
        transition: none !important;
    }

    [data-scroll] .stats__grid > .stat,
    [data-scroll] .approach__grid > .approach__card,
    [data-scroll] .gallery__cards > .gallery__card,
    [data-scroll] .gallery__grid > .gallery__image,
    [data-scroll] .donor__images > .donor__card,
    [data-scroll] .person__section,
    [data-scroll] .contact__cards > .contact__card,
    [data-scroll] .project-grid > .project-card {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }

    .feature__cta-button::after,
    .explore__button::after,
    .detail-button::after,
    .notfound__button::after {
        display: none !important;
    }
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: var(--blue-700);
    color: #ffffff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(11, 31, 58, 0.25);
    z-index: 990;
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, background-color 0.2s ease, box-shadow 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

@media (hover: hover) {
    .back-to-top:hover {
        background-color: var(--navy-800);
        transform: translateY(-3px);
        box-shadow: 0 6px 20px rgba(11, 31, 58, 0.35);
    }
}

.back-to-top:focus-visible {
    background-color: var(--navy-800);
    outline: 2px solid var(--white);
    outline-offset: 2px;
}

.back-to-top:active {
    background-color: var(--navy-900);
    transform: translateY(0);
}

@media (max-width: 768px) {
    .back-to-top {
        bottom: 1.25rem;
        right: 1.25rem;
        width: 42px;
        height: 42px;
    }
}

