/* ============================================================
   HEADER — Mobile Responsive
   /assets/css/components/header.css
   ============================================================ */

.global-header {
    background: #FFFFFF;
    padding: 12px 0;
    border-bottom: 1px solid rgba(0,51,102,0.06);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0,51,102,0.04);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    width: 100%;
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    flex-shrink: 0;
}

.logo {
    height: 48px;
    width: auto;
}

/* ─── Navigation ─── */
.nav-list {
    display: flex;
    align-items: center;
    gap: 24px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-item a {
    font-size: 14px;
    font-weight: 500;
    color: #415A77;
    text-decoration: none;
    padding: 4px 0;
    border-bottom: 2px solid transparent;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
}

.nav-item a:hover,
.nav-item.active a {
    color: #003366;
    border-bottom-color: #003366;
}

.nav-locator {
    color: #003366 !important;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ─── Mobile Menu Toggle ─── */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    flex-direction: column;
    gap: 5px;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: background 0.2s ease;
}

.menu-toggle:hover {
    background: rgba(0,51,102,0.04);
}

.menu-toggle span {
    display: block;
    width: 28px;
    height: 2.5px;
    background: #003366;
    transition: all 0.3s ease;
    border-radius: 2px;
    transform-origin: center;
}

.menu-toggle span:nth-child(2) {
    width: 20px;
}

/* Hamburger animation when open */
.menu-toggle.open span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
    width: 28px;
}
.menu-toggle.open span:nth-child(2) {
    opacity: 0;
    width: 0;
}
.menu-toggle.open span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 28px;
}

/* ─── Mobile Navigation Overlay ─── */
.nav-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.3);
    z-index: 99;
}

.nav-overlay.active {
    display: block;
}

/* ============================================================
   RESPONSIVE — Tablet & Mobile
   ============================================================ */

/* ─── Tablet (1024px and below) ─── */
@media (max-width: 1024px) {
    .nav-list {
        gap: 16px;
    }
    .nav-item a {
        font-size: 13px;
    }
}

/* ─── Mobile (768px and below) ─── */
@media (max-width: 768px) {
    .header-inner {
        padding: 0 16px;
    }

    .logo {
        height: 38px;
    }

    /* Hide desktop navigation */
    .nav-list {
        display: none;
        flex-direction: column;
        gap: 4px;
        padding: 16px 20px 24px;
        width: 100%;
        background: #FFFFFF;
        position: absolute;
        top: 68px;
        left: 0;
        box-shadow: 0 20px 60px rgba(0,0,0,0.12);
        border-top: 1px solid rgba(0,51,102,0.06);
        max-height: calc(100vh - 68px);
        overflow-y: auto;
    }

    .nav-list.open {
        display: flex;
    }

    .menu-toggle {
        display: flex;
    }

    .nav-item {
        width: 100%;
        border-bottom: 1px solid rgba(0,51,102,0.04);
    }

    .nav-item:last-child {
        border-bottom: none;
    }

    .nav-item a {
        display: block;
        padding: 12px 0;
        font-size: 16px;
        font-weight: 500;
        border-bottom: none;
        color: #003366;
    }

    .nav-item a:hover,
    .nav-item.active a {
        color: #003366;
        border-bottom: none;
        background: rgba(0,51,102,0.04);
        padding-left: 8px;
        border-radius: 4px;
    }

    .nav-locator {
        justify-content: flex-start;
        font-weight: 600;
        color: #003366 !important;
    }

    .nav-locator i {
        font-size: 18px;
    }

    /* Fix for sticky header on mobile */
    .global-header {
        padding: 8px 0;
    }
}

/* ─── Extra Small (480px and below) ─── */
@media (max-width: 480px) {
    .header-inner {
        padding: 0 12px;
    }

    .logo {
        height: 32px;
    }

    .nav-list {
        top: 60px;
        padding: 12px 16px 20px;
        max-height: calc(100vh - 60px);
    }

    .nav-item a {
        font-size: 15px;
        padding: 10px 0;
    }

    .menu-toggle {
        width: 36px;
        height: 36px;
        gap: 4px;
    }

    .menu-toggle span {
        width: 24px;
        height: 2px;
    }

    .menu-toggle span:nth-child(2) {
        width: 16px;
    }

    .menu-toggle.open span:nth-child(1) {
        transform: rotate(45deg) translate(4px, 4px);
        width: 24px;
    }
    .menu-toggle.open span:nth-child(3) {
        transform: rotate(-45deg) translate(4px, -4px);
        width: 24px;
    }
}