/* ── Header ── */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 48px;
    background: #ffffff;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.08);
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Logo image sizing */
.site-logo {
    display: block;
    width: auto;
    height: auto;
}

.site-logo--header {
    max-height: 48px;
}

/* Nav */
nav {
    display: flex;
    align-items: center;
    gap: 6px;
}

nav a {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #000000;
    text-decoration: none;
    font-size: 14.5px;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: 8px;
    transition: background 0.2s ease;
    white-space: nowrap;
}

nav a:hover {
    background: #DFEDFF;
}

nav a.active {
    background: #DFEDFF;
}

nav a .arrow {
    font-size: 10px;
    opacity: 0.6;
}

/* ── Nav Dropdown ── */
.nav-dropdown {
    position: relative;
    display: flex;
    align-items: center;
}

.nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    min-width: 230px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 16px 48px rgba(7, 41, 85, 0.18);
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    z-index: 200;
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-dropdown-menu a {
    display: block;
    padding: 10px 14px;
    border-radius: 8px;
    color: #0A1F3D;
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    transition: background 0.15s ease, color 0.15s ease;
}

.nav-dropdown-menu a:hover,
.nav-dropdown-menu a.active {
    background: #DFEDFF;
    color: #1C7BF6;
}

/* ── Hamburger Button ── */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 36px;
    height: 36px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 4px;
    flex-shrink: 0;
    margin-left: auto;
}

.hamburger span {
    display: block !important;
    width: 22px;
    height: 2.5px;
    background: #000000;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Mobile Menu ── */
.mobile-menu {
    display: none;
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    width: 100%;
    background: #ffffff;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    z-index: 99;
    flex-direction: column;
    padding: 8px 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
    transform: translateY(-8px);
}

.mobile-menu.open {
    opacity: 1;
    pointer-events: all;
    transform: translateY(0);
}

.mobile-menu a {
    display: block;
    padding: 12px 24px;
    color: #000000;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    transition: background 0.2s ease;
}

.mobile-menu a:last-child { border-bottom: none; }
.mobile-menu a:hover { background: #DFEDFF; }

.mobile-menu a.active { background: #DFEDFF; }

/* ── Mobile submenu (accordion) ── */
.mobile-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 12px 24px;
    background: none;
    border: none;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    color: #000000;
    font-size: 14px;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    text-align: left;
}

.mobile-menu-toggle .arrow {
    font-size: 10px;
    opacity: 0.5;
    transition: transform 0.2s ease;
}

.mobile-menu-toggle.open .arrow {
    transform: rotate(180deg);
}

.mobile-submenu {
    display: flex;
    flex-direction: column;
    max-height: 0;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.02);
    transition: max-height 0.3s ease;
}

.mobile-submenu.open {
    max-height: 420px;
}

.mobile-submenu a {
    padding: 10px 24px 10px 40px;
    font-size: 13px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.mobile-submenu a:last-child { border-bottom: none; }

.mobile-submenu a.active {
    color: #1C7BF6;
    background: #DFEDFF;
}

/* ── Mobile breakpoint ── */
@media (max-width: 768px) {
    header {
        padding: 8px 24px;
    }

    header nav {
        display: none !important;
        visibility: hidden !important;
    }

    .site-logo--header {
        max-height: 42px;
        width: auto;
    }

    .hamburger {
        display: flex !important;
        visibility: visible !important;
    }

    .mobile-menu {
        display: flex;
        top: 58px;
        z-index: 9999 !important;
    }
}
