:root {
    --font-heading: 'Caladea', Georgia, serif;
    --font-body: 'Caladea', Georgia, serif;
    --font-mono: 'JetBrains Mono', 'DM Mono', monospace;
    --bg-hud: rgba(10, 15, 26, .94);
    --bg-card: rgba(13, 20, 36, .98);
    --bg-dark: #080b12;
    --border-hud: rgba(59, 130, 246, .3);
    --border-glow: rgba(59, 130, 246, .7);
    --text-main: #e2e8f0;
    --text-muted: #94a3b8;
    --text-heading: #fff;
    --text-tactical: #60a5fa;
    --primary: #3b82f6;
    --primary-glow: rgba(59, 130, 246, .4);
    --secondary: #8b5cf6;
    --accent-green: #10b981;
    --transition-tactical: all .25s cubic-bezier(.16, 1, .3, 1);
}

:root[data-theme="light"] {
    --bg-hud: rgba(255, 255, 255, .96);
    --bg-card: rgba(255, 255, 255, .99);
    --bg-dark: #f1f5f9;
    --border-hud: rgba(2, 132, 199, .3);
    --border-glow: rgba(2, 132, 199, .8);
    --text-main: #1e293b;
    --text-muted: #475569;
    --text-heading: #0f172a;
    --text-tactical: #0284c7;
    --primary: #0284c7;
    --primary-glow: rgba(2, 132, 199, .35);
    --secondary: #9333ea;
    --accent-green: #059669;
}

/* Keep the primary navigation identical to the homepage's CMS-rendered flat menu. */
.site-header .nav-arrow,
.site-header .dropdown-menu {
    display: none !important;
}

/* Nuxt-rendered routes use the same external header as the static pages. */
#__nuxt header:not([data-cybercorp-global-header]) {
    display: none !important;
}

.site-header,
.site-header * {
    box-sizing: border-box;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    color: var(--text-main);
    background: color-mix(in srgb, var(--bg-dark) 82%, transparent);
    border-bottom: 1px solid var(--border-hud);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    font-family: var(--font-body);
}

.site-header .container {
    width: min(100%, 1288px);
    margin: 0 auto;
    padding: 0 24px;
}

.site-header .header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 78px;
    gap: 18px;
}

.site-header .brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 0 0 auto;
    color: var(--text-heading);
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: .02em;
    text-decoration: none;
}

.site-header .brand-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    padding: 6px;
    border: 1px solid var(--border-hud);
    border-radius: 13px;
    background: rgba(59, 130, 246, .1);
    box-shadow: 0 8px 22px rgba(0, 0, 0, .22);
    transition: var(--transition-tactical);
}

.site-header .brand-logo:hover .brand-icon {
    transform: scale(1.05) rotate(3deg);
    border-color: var(--secondary);
}

.site-header .brand-icon img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.site-header .brand-text-block {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.site-header .brand-sub {
    color: var(--text-muted);
    font-family: var(--font-body);
    font-size: .72rem;
    font-weight: 500;
    opacity: .76;
    letter-spacing: .035em;
    letter-spacing: 0;
}

.site-header nav {
    min-width: 0;
}

.site-header .nav-links {
    display: flex;
    align-items: center;
    height: 74px;
    gap: 2px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-header .nav-item {
    position: relative;
    display: flex;
    align-items: center;
    height: 100%;
}

.site-header .nav-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 11px;
    border-radius: 10px;
    color: var(--text-muted);
    font-family: var(--font-heading);
    font-size: .87rem;
    font-weight: 600;
    line-height: 1.3;
    text-decoration: none;
    white-space: nowrap;
    transition: var(--transition-tactical);
}

.site-header .nav-link:hover,
.site-header .nav-item:hover > .nav-link,
.site-header .nav-link.active,
.site-header .nav-link:focus-visible {
    color: var(--text-heading);
    background: rgba(126, 151, 255, .09);
    box-shadow: 0 0 12px rgba(59, 130, 246, .2);
    outline: none;
}

.site-header .nav-arrow {
    font-size: .6rem;
    opacity: .65;
    transition: transform .2s ease;
}

.site-header .nav-item:hover .nav-arrow,
.site-header .nav-item:focus-within .nav-arrow {
    transform: rotate(180deg);
}

.site-header .dropdown-menu {
    position: absolute;
    top: calc(100% - 7px);
    left: 0;
    z-index: 1050;
    min-width: 232px;
    padding: 10px;
    border: 1px solid var(--border-hud);
    border-radius: 14px;
    background: var(--bg-hud);
    box-shadow: 0 18px 44px rgba(0, 0, 0, .32);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
    pointer-events: none;
}

.site-header .nav-item:hover .dropdown-menu,
.site-header .nav-item:focus-within .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.site-header .dropdown-menu::before {
    position: absolute;
    top: -10px;
    right: 0;
    left: 0;
    height: 10px;
    content: '';
}

.site-header .dropdown-header {
    padding: 6px 10px 4px;
    color: var(--text-tactical);
    font-family: var(--font-mono);
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.site-header .dropdown-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 10px;
    border-radius: 8px;
    color: var(--text-muted);
    font-size: .88rem;
    text-decoration: none;
    transition: background .15s ease, color .15s ease;
}

.site-header .dropdown-link:hover,
.site-header .dropdown-link:focus-visible {
    color: var(--text-heading);
    background: rgba(59, 130, 246, .16);
}

.site-header .dropdown-tag {
    padding: 2px 7px;
    border: 1px solid var(--border-hud);
    border-radius: 6px;
    color: var(--text-tactical);
    font-family: var(--font-mono);
    font-size: .68rem;
    white-space: nowrap;
}

.site-header .dropdown-divider {
    height: 1px;
    margin: 6px 0;
    background: var(--border-hud);
}

.site-header .header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 0 0 auto;
}

.site-header .admin-launch-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 38px;
    padding: 0 12px;
    border: 1px solid var(--border-hud);
    border-radius: 12px;
    background: rgba(255, 255, 255, .035);
    color: var(--text-main);
    font-family: var(--font-heading);
    font-size: .84rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: var(--transition-tactical);
}

.site-header .admin-launch-btn:hover,
.site-header .admin-launch-btn:focus-visible {
    border-color: var(--border-glow);
    background: var(--primary-glow);
    color: var(--text-heading);
    outline: none;
}

.site-header .hud-toggle-btn,
.site-header .burger-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 38px;
    padding: 8px 14px;
    border: 1px solid var(--border-hud);
    border-radius: 9px;
    background: rgba(255, 255, 255, .04);
    color: var(--text-main);
    font-family: var(--font-heading);
    font-size: .8rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-tactical);
}

.site-header .hud-toggle-btn:hover,
.site-header .burger-btn:hover {
    border-color: var(--border-glow);
    background: rgba(59, 130, 246, .12);
    color: var(--text-heading);
}

.site-header .sound-active {
    border-color: var(--accent-green);
    color: var(--accent-green);
    background: rgba(16, 185, 129, .1);
}

.site-header .hud-toggle-btn#soundToggleBtn {
    display: none !important;
}

.site-header .audio-bars-mini {
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 12px;
}

.site-header .ab-bar {
    width: 2px;
    border-radius: 1px;
    background: currentColor;
    animation: cc-audio-bounce .8s infinite ease-in-out;
}

.site-header .ab-bar:nth-child(1) { height: 40%; animation-delay: .1s; }
.site-header .ab-bar:nth-child(2) { height: 90%; animation-delay: .25s; }
.site-header .ab-bar:nth-child(3) { height: 60%; animation-delay: .15s; }

@keyframes cc-audio-bounce {
    0%, 100% { transform: scaleY(.4); }
    50% { transform: scaleY(1); }
}

.site-header .btn-discord-hud {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 17px;
    border: 0;
    border-radius: 999px;
    background: #5865f2;
    box-shadow: 0 8px 25px rgba(90, 114, 230, .22);
    color: #fff;
    font-family: var(--font-heading);
    font-size: .85rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: var(--transition-tactical);
}

.site-header .btn-discord-hud:hover,
.site-header .btn-discord-hud:focus-visible {
    background: #4752c4;
    color: #fff;
    transform: translateY(-1px);
}

.site-header .burger-btn {
    display: none;
    border-radius: 12px;
    font-family: Arial, sans-serif;
    font-size: 1.15rem;
}

.site-header .mobile-drawer {
    display: none;
    flex-direction: column;
    gap: 8px;
    padding: 18px 24px;
    border-top: 1px solid var(--border-hud);
    background: var(--bg-hud);
    box-shadow: 0 18px 30px rgba(0, 0, 0, .18);
}

.site-header .mobile-drawer.open {
    display: flex;
}

.site-header .mobile-drawer .nav-link {
    width: 100%;
    padding: 10px 12px;
}

@media (max-width: 1160px) {
    .site-header nav { display: none !important; }
    .site-header .burger-btn { display: inline-flex !important; }
    .site-header .mobile-drawer.open { display: flex !important; }
    .site-header .header-content { height: 72px; }
}

@media (max-width: 600px) {
    .site-header .container { padding: 0 20px; }
    .site-header .header-content { height: 68px; gap: 8px; }
    .site-header .brand-logo { gap: 9px; font-size: 1rem; }
    .site-header .brand-icon { width: 36px; height: 36px; }
    .site-header .brand-sub { font-size: .62rem; }
    .site-header #themeToggle { min-width: 38px; padding: 6px; }
    .site-header .btn-discord-hud { display: none !important; }
    .site-header .header-actions { gap: 6px; }
    .site-header .mobile-drawer { padding-right: 20px; padding-left: 20px; }
}
