/* ============================================================
   BI1XNN Amateur Radio Station — Dark Tech Theme
   Aesthetic: high-end radio rig / mission control console
   Palette: deep navy, brass glow, teal waterfall, signal green
   ============================================================ */

/* ===== CUSTOM PROPERTIES ===== */
:root {
    /* Core surfaces — dark navy palette */
    --bg-base:        #080c13;
    --bg-body:        #0b1019;
    --bg-surface:     #111820;
    --bg-elevated:    #161e2a;
    --bg-input:       #0d1119;
    --bg-hover:       #1a2330;

    /* Sidebar */
    --sb-bg:          #060a10;
    --sb-surface:     #0c111a;
    --sb-text:        #bcc5d0;
    --sb-text-muted:  #5a6575;
    --sb-hover:       rgba(198,145,59,0.06);
    --sb-border:      rgba(255,255,255,0.04);

    /* Accents — calibrated for dark backgrounds */
    --brass:          #d4a24c;
    --brass-bright:   #e8b85c;
    --brass-dark:     #b8892e;
    --brass-dim:      rgba(212,162,76,0.12);
    --brass-glow:     rgba(212,162,76,0.30);
    --teal:           #14b8a6;
    --teal-dark:      #0d9488;
    --teal-dim:       rgba(20,184,166,0.10);
    --teal-glow:      rgba(20,184,166,0.25);
    --signal:         #22c55e;
    --signal-dim:     rgba(34,197,94,0.12);
    --warn:           #ef4444;
    --red:            #ef4444;
    --warn-dim:       rgba(239,68,68,0.10);
    --blue:           #60a5fa;
    --blue-dim:       rgba(96,165,250,0.10);

    /* Text — high contrast on dark */
    --text-heading:   #f0f2f5;
    --text-body:      #d0d5dd;
    --text-muted:     #8896a6;
    --text-link:      #60a5fa;
    --text-link-hover:#93bbfd;

    /* Borders */
    --border:         rgba(255,255,255,0.06);
    --border-light:   rgba(255,255,255,0.10);
    --border-focus:   rgba(212,162,76,0.40);

    /* Glow layers (replaces shadows) */
    --glow-sm:        0 0 8px rgba(0,0,0,0.3);
    --glow-md:        0 0 16px rgba(0,0,0,0.4), 0 0 2px rgba(255,255,255,0.03);
    --glow-lg:        0 0 24px rgba(0,0,0,0.5), 0 0 4px rgba(255,255,255,0.04);
    --glow-brass:     0 0 20px var(--brass-glow), 0 0 2px rgba(212,162,76,0.5);
    --glow-teal:      0 0 16px var(--teal-glow);

    /* Radii */
    --radius-sm:      6px;
    --radius-md:      10px;
    --radius-lg:      14px;
    --radius-xl:      20px;
    --radius-full:    9999px;

    /* Transitions */
    --ease-out:       cubic-bezier(0.4, 0, 0.2, 1);
    --ease-spring:    cubic-bezier(0.34, 1.4, 0.64, 1);
    --ease-smooth:    cubic-bezier(0.65, 0, 0.35, 1);

    /* Layout */
    --hero-py:        80px;
    --sidebar-w:      260px;
    --section-py:     60px;
}

/* ===== RESET & BASE ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--bg-base); }
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans SC', sans-serif;
    line-height: 1.75; color: var(--text-body); background: var(--bg-body);
    -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
    /* Dot-grid pattern (Linear-style) */
    background-image: radial-gradient(circle, rgba(255,255,255,0.025) 1px, transparent 1px);
    background-size: 22px 22px;
    background-attachment: fixed;
}
h1, h2, h3, h4 {
    font-family: 'Space Grotesk', 'Inter', -apple-system, BlinkMacSystemFont, 'Noto Sans SC', sans-serif;
    color: var(--text-heading); letter-spacing: -0.3px;
}
a { color: var(--text-link); text-decoration: none; transition: color 0.2s var(--ease-out); }
a:hover { color: var(--text-link-hover); }
::selection { background: var(--brass-dim); color: var(--brass-bright); }

/* ===== SCROLLBAR (dark) ===== */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: #2a3545; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #3a4858; }

/* ===== KEYFRAMES ===== */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.94); }
    to   { opacity: 1; transform: scale(1); }
}
@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-16px); }
    to   { opacity: 1; transform: translateX(0); }
}
/* S-meter bars */
@keyframes sBar1 { 0%,100% { height: 10px; } 50% { height: 28px; } }
@keyframes sBar2 { 0%,100% { height: 18px; } 50% { height: 38px; } }
@keyframes sBar3 { 0%,100% { height: 26px; } 50% { height: 46px; } }
@keyframes sBar4 { 0%,100% { height: 14px; } 50% { height: 34px; } }
@keyframes sBar5 { 0%,100% { height: 22px; } 50% { height: 42px; } }
@keyframes sBar6 { 0%,100% { height: 8px; } 50% { height: 22px; } }
/* Waterfall */
@keyframes waterfall {
    0%   { background-position: 0 0; }
    100% { background-position: 0 80px; }
}
/* Glow pulse */
@keyframes glowPulse {
    0%,100% { box-shadow: 0 0 0 0 var(--brass-glow); }
    50%     { box-shadow: 0 0 0 10px rgba(212,162,76,0); }
}
/* Breathe for indicators */
@keyframes breathe {
    0%,100% { transform: scale(1); opacity: 1; }
    50%     { transform: scale(1.2); opacity: 0.7; }
}
/* Morse blink */
@keyframes morseBlink {
    0%,100% { opacity: 1; }
    30%,70% { opacity: 0.15; }
}
/* Border sweep */
@keyframes borderSweep {
    0%   { border-color: var(--brass); }
    40%  { border-color: var(--teal); }
    80%  { border-color: var(--brass-bright); }
    100% { border-color: var(--brass); }
}
/* Ripple for buttons */
@keyframes ripple {
    to { transform: scale(4); opacity: 0; }
}
/* Float */
@keyframes float {
    0%,100% { transform: translateY(0); }
    50%     { transform: translateY(-5px); }
}

/* ===== SIDEBAR ===== */
.sidebar {
    position: fixed; left: 0; top: 0; bottom: 0;
    width: var(--sidebar-w); background: rgba(6,10,16,0.92);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    color: var(--sb-text); display: flex; flex-direction: column; z-index: 100;
    overflow-y: auto;
    border-right: 1px solid var(--sb-border);
    transition: transform 0.4s var(--ease-smooth);
}
.sidebar-brand {
    padding: 26px 22px 18px; border-bottom: 1px solid var(--sb-border);
    position: relative;
}
.sidebar-brand h2 {
    font-size: 1.1rem; color: #fff; font-weight: 700;
    font-family: 'Space Grotesk', 'Inter', sans-serif; letter-spacing: -0.2px;
}
.sidebar-brand .callsign {
    font-size: 0.82rem; color: var(--brass); margin-top: 4px;
    font-weight: 600; letter-spacing: 0.5px;
    display: flex; align-items: center; gap: 10px;
}
.sidebar-brand .callsign::after {
    content: ''; display: inline-block; width: 28px; height: 2px;
    background: var(--brass); border-radius: 2px;
    animation: morseBlink 1.4s ease-in-out infinite;
}
.sidebar-brand::after {
    content: ''; position: absolute; bottom: 0; left: 22px; right: 22px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212,162,76,0.3), transparent);
}
.lang-top {
    display: inline-block; margin-top: 12px; padding: 5px 14px;
    background: rgba(255,255,255,0.04); color: var(--sb-text-muted) !important;
    border-radius: 5px; font-size: 0.76rem !important; text-align: center;
    border: 1px solid var(--sb-border);
    transition: all 0.25s var(--ease-out) !important;
}
.lang-top:hover {
    background: rgba(255,255,255,0.08) !important; color: #fff !important;
    transform: translateY(-1px); text-decoration: none !important;
}
.sidebar-nav { flex: 1; padding: 10px 0; }
.sidebar-nav a {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 22px; color: var(--sb-text-muted); font-size: 0.9rem;
    transition: all 0.25s var(--ease-out);
    border-left: 3px solid transparent;
    position: relative;
    text-decoration: none;
}
.sidebar-nav a:hover {
    background: var(--sb-hover); color: #e8eef4;
    border-left-color: rgba(212,162,76,0.35);
    padding-left: 26px;
}
.sidebar-nav a.active {
    background: linear-gradient(90deg, rgba(212,162,76,0.10) 0%, rgba(212,162,76,0.02) 50%, transparent 100%);
    color: #fff; border-left-color: var(--brass);
    font-weight: 600;
}
.sidebar-nav a.active::after {
    content: ''; position: absolute; left: -5px; top: 50%; transform: translateY(-50%);
    width: 7px; height: 7px; border-radius: 50%; background: var(--brass);
    box-shadow: 0 0 10px var(--brass-glow);
    animation: breathe 2.4s ease-in-out infinite;
}
.sidebar-nav a .icon {
    width: 22px; text-align: center; font-size: 1rem;
    transition: transform 0.25s var(--ease-spring);
}
.sidebar-nav a:hover .icon { transform: scale(1.18); }
.sidebar-nav a.active .icon { color: var(--brass); }
.sidebar-nav a:nth-child(1) { animation: slideInLeft 0.35s 0.04s var(--ease-out) both; }
.sidebar-nav a:nth-child(2) { animation: slideInLeft 0.35s 0.08s var(--ease-out) both; }
.sidebar-nav a:nth-child(3) { animation: slideInLeft 0.35s 0.12s var(--ease-out) both; }
.sidebar-nav a:nth-child(4) { animation: slideInLeft 0.35s 0.16s var(--ease-out) both; }
.sidebar-nav a:nth-child(5) { animation: slideInLeft 0.35s 0.20s var(--ease-out) both; }
.sidebar-nav a:nth-child(6) { animation: slideInLeft 0.35s 0.24s var(--ease-out) both; }
.sidebar-nav a:nth-child(7) { animation: slideInLeft 0.35s 0.28s var(--ease-out) both; }
.sidebar-nav a:nth-child(8) { animation: slideInLeft 0.35s 0.32s var(--ease-out) both; }

/* ===== HAMBURGER ===== */
.hamburger {
    display: none; position: fixed; top: 14px; left: 14px; z-index: 200;
    background: var(--sb-surface); color: #fff; border: 1px solid var(--sb-border);
    width: 42px; height: 42px; border-radius: 10px; cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.2s var(--ease-spring);
}
.hamburger:hover { transform: scale(1.06); border-color: var(--brass); }
.hamburger:active { transform: scale(0.94); }
.sidebar-overlay {
    display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.6);
    z-index: 99; backdrop-filter: blur(4px);
    animation: fadeIn 0.25s var(--ease-out);
}

/* ===== MAIN CONTENT ===== */
.main-content { margin-left: var(--sidebar-w); min-height: 100vh; }
.main-content > * { animation: fadeInUp 0.45s var(--ease-out) both; }
.main-content > *:nth-child(1) { animation-delay: 0s; }
.main-content > *:nth-child(2) { animation-delay: 0.06s; }
.main-content > *:nth-child(3) { animation-delay: 0.12s; }

/* ===== HERO ===== */
.hero {
    position: relative; overflow: hidden;
    background: linear-gradient(170deg, #060a14 0%, #0c1524 40%, #0a1a22 100%);
    color: #fff; text-align: center;
    padding: var(--hero-py) 32px;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
/* Fallback radial glow via pseudo-element (works without HTML changes) */
.hero::before {
    content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 600px; height: 500px;
    background: radial-gradient(ellipse, rgba(212,162,76,0.06) 0%, rgba(20,184,166,0.03) 30%, transparent 65%);
    border-radius: 50%; z-index: 0; pointer-events: none;
}
.hero-bg { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
/* Radial glow */
.hero-glow {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 600px; height: 500px;
    background: radial-gradient(ellipse, rgba(212,162,76,0.07) 0%, rgba(20,184,166,0.03) 30%, transparent 65%);
    border-radius: 50%;
}
/* Waterfall */
.hero-waterfall {
    position: absolute; inset: 0; opacity: 0.06;
    background: repeating-linear-gradient(
        0deg, transparent, transparent 2px,
        rgba(20,184,166,0.7) 2px, rgba(20,184,166,0.7) 3px,
        transparent 3px, transparent 6px,
        rgba(212,162,76,0.5) 6px, rgba(212,162,76,0.5) 7px,
        transparent 7px, transparent 10px
    );
    animation: waterfall 12s linear infinite;
}
/* Hex grid */
.hero-grid {
    position: absolute; inset: 0; opacity: 0.025;
    background-image:
        linear-gradient(rgba(255,255,255,0.4) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.4) 1px, transparent 1px);
    background-size: 50px 50px;
}
.hero-content { position: relative; z-index: 1; }
.hero-owner {
    display: inline-block; font-size: 0.85rem; font-weight: 600;
    color: var(--brass); letter-spacing: 0.6px;
    padding: 6px 16px; background: rgba(8,12,19,0.7);
    border-radius: var(--radius-full);
    border: 1px solid rgba(212,162,76,0.25);
    backdrop-filter: blur(6px); margin-bottom: 20px;
    animation: fadeIn 0.5s 0.15s var(--ease-out) both;
}
.hero h1 {
    font-size: 3.2rem; margin-bottom: 16px; font-weight: 800;
    font-family: 'Space Grotesk', 'Inter', sans-serif; color: #fff;
    letter-spacing: -0.8px;
    text-shadow: 0 0 60px rgba(212,162,76,0.18);
    animation: fadeInUp 0.55s var(--ease-out) both;
}
.hero p {
    font-size: 1.15rem; opacity: 0.78; max-width: 680px; margin: 0 auto;
    line-height: 1.8; animation: fadeInUp 0.55s 0.08s var(--ease-out) both;
}

/* S-meter bars */
.signal-meter {
    position: relative; z-index: 1;
    display: flex; align-items: flex-end; justify-content: center;
    gap: 4px; margin-top: 32px; height: 48px;
    animation: fadeInUp 0.55s 0.2s var(--ease-out) both;
}
.s-bar {
    width: 9px; border-radius: 2px 2px 0 0;
    transition: all 0.3s var(--ease-out);
}
.s-bar:nth-child(1) { background: var(--teal); height: 14px; animation: sBar1 2s ease-in-out infinite; }
.s-bar:nth-child(2) { background: var(--teal); height: 22px; animation: sBar2 1.7s ease-in-out infinite 0.1s; }
.s-bar:nth-child(3) { background: var(--teal); height: 30px; animation: sBar3 1.5s ease-in-out infinite 0.2s; }
.s-bar:nth-child(4) { background: #c9a44a; height: 18px; animation: sBar4 1.8s ease-in-out infinite 0.15s; }
.s-bar:nth-child(5) { background: #c9a44a; height: 26px; animation: sBar5 1.6s ease-in-out infinite 0.25s; }
.s-bar:nth-child(6) { background: var(--brass); height: 10px; animation: sBar6 2.1s ease-in-out infinite 0.05s; }
.s-bar:nth-child(7) { background: var(--brass); height: 20px; animation: sBar3 1.55s ease-in-out infinite 0.3s; }
.s-bar:nth-child(8) { background: var(--brass-dark); height: 6px; animation: sBar1 2.3s ease-in-out infinite 0.1s; }

/* Hero gallery */
.hero-gallery {
    position: relative; z-index: 1; display: flex; gap: 18px;
    justify-content: center; margin-top: 36px; flex-wrap: wrap;
}
.hero-gallery img {
    width: 280px; height: 180px; object-fit: cover;
    border-radius: var(--radius-md);
    border: 2px solid rgba(255,255,255,0.06);
    transition: all 0.5s var(--ease-spring);
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
    animation: fadeInUp 0.55s var(--ease-out) both;
}
.hero-gallery img:nth-child(1) { animation-delay: 0.12s; }
.hero-gallery img:nth-child(2) { animation-delay: 0.20s; }
.hero-gallery img:nth-child(3) { animation-delay: 0.28s; }
.hero-gallery img:hover {
    transform: translateY(-10px) scale(1.05);
    box-shadow: 0 16px 48px rgba(0,0,0,0.6), 0 0 20px rgba(212,162,76,0.1);
    border-color: rgba(212,162,76,0.4);
}
.photo-credit { font-size: 0.7rem; opacity: 0.35; margin-top: 14px; position: relative; z-index: 1; }

/* ===== SECTIONS ===== */
.section { padding: var(--section-py) 40px; max-width: 1140px; }
.section h2 {
    font-size: 1.55rem; margin-bottom: 28px; color: var(--text-heading);
    display: flex; align-items: center; gap: 12px; font-weight: 700;
    letter-spacing: -0.4px;
}
.section h2::after {
    content: ''; flex: 1; height: 1px;
    background: linear-gradient(90deg, var(--border) 0%, transparent 100%);
}
.section > p { color: var(--text-muted); margin-bottom: 16px; max-width: 720px; }

/* ===== INFO CARDS ===== */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px; margin-top: 20px;
}
.info-card {
    background: var(--bg-surface); padding: 30px 26px;
    border-radius: var(--radius-lg); border: 1px solid var(--border);
    box-shadow: var(--glow-sm);
    transition: all 0.35s var(--ease-smooth);
    position: relative; overflow: hidden;
}
.info-card::before {
    content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
    background: linear-gradient(180deg, var(--brass) 0%, var(--teal) 100%);
    transform: scaleY(0); transform-origin: top;
    transition: transform 0.5s var(--ease-smooth); border-radius: 0 3px 3px 0;
}
.info-card:hover {
    transform: translateY(-4px); background: var(--bg-elevated);
    border-color: var(--border-light);
    box-shadow: var(--glow-lg), 0 0 16px rgba(212,162,76,0.06);
}
.info-card:hover::before { transform: scaleY(1); }
.info-card h3 { font-size: 1.05rem; margin-bottom: 8px; font-weight: 700; }
.info-card p { font-size: 0.92rem; color: var(--text-muted); line-height: 1.7; }

/* ===== POST CARDS ===== */
.post-card {
    background: var(--bg-surface); padding: 26px 30px;
    border-radius: var(--radius-md); border: 1px solid var(--border);
    box-shadow: var(--glow-sm); margin-bottom: 14px;
    transition: all 0.35s var(--ease-smooth);
    position: relative; overflow: hidden;
}
.post-card::before {
    content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
    background: linear-gradient(180deg, var(--brass) 0%, var(--brass-dark) 100%);
    border-radius: 0 3px 3px 0;
    transform: scaleY(0); transform-origin: top;
    transition: transform 0.4s var(--ease-smooth);
}
.post-card:hover {
    transform: translateY(-3px); background: var(--bg-elevated);
    border-color: var(--border-light);
    box-shadow: var(--glow-lg), 0 0 12px rgba(212,162,76,0.05);
}
.post-card:hover::before { transform: scaleY(1); }
.post-card h3 { margin-bottom: 6px; font-size: 1.08rem; }
.post-card h3 a { color: var(--text-heading); transition: color 0.2s; }
.post-card h3 a:hover { color: var(--brass); text-decoration: none; }
.post-card .meta {
    font-size: 0.8rem; color: var(--text-muted); margin-bottom: 8px;
    display: flex; align-items: center; gap: 8px;
}
.post-card p { color: var(--text-muted); font-size: 0.93rem; }

/* ===== FORMS & INPUTS ===== */
.form-group { margin-bottom: 18px; }
.form-group label {
    display: block; margin-bottom: 6px; font-weight: 600;
    font-size: 0.84rem; color: var(--text-body);
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    letter-spacing: 0.1px;
}
.form-group label .req { color: var(--brass); }
.form-group input, .form-group textarea, .form-group select {
    width: 100%; padding: 11px 15px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm); font-size: 0.93rem; font-family: inherit;
    transition: all 0.3s var(--ease-out);
    background: var(--bg-input); color: var(--text-body);
}
.form-group input:hover, .form-group textarea:hover {
    border-color: var(--border-light); background: var(--bg-surface);
}
.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
    outline: none; border-color: var(--brass);
    background: var(--bg-surface);
    box-shadow: 0 0 0 3px var(--brass-dim), 0 0 12px rgba(212,162,76,0.08);
}
.form-group textarea { resize: vertical; min-height: 100px; }
.form-group select {
    appearance: none; -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%238896a6' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 14px center;
    padding-right: 36px; cursor: pointer;
}
.form-group select option { background: var(--bg-surface); color: var(--text-body); }
.form-group input:disabled, .form-group textarea:disabled {
    opacity: 0.45; background: var(--bg-base); border-style: dashed; cursor: not-allowed;
}
.form-group:has(.req) input:focus,
.form-group:has(.req) textarea:focus {
    border-color: var(--brass-bright);
    box-shadow: 0 0 0 3px var(--brass-dim), 0 0 16px rgba(212,162,76,0.10);
}

/* ===== QSL FORM ===== */
.qsl-form {
    background: var(--bg-surface); padding: 36px;
    border-radius: var(--radius-lg); max-width: 720px;
    border: 1px solid var(--border); box-shadow: var(--glow-md);
    animation: scaleIn 0.35s var(--ease-out);
}
.qsl-form .form-row {
    display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px;
}
.qsl-form .form-row.full { grid-template-columns: 1fr; }

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 11px 24px; border: none; border-radius: var(--radius-sm); cursor: pointer;
    font-size: 0.93rem; font-weight: 600; font-family: inherit;
    transition: all 0.3s var(--ease-smooth);
    position: relative; overflow: hidden;
    outline: none; letter-spacing: 0.1px; line-height: 1.4;
    text-decoration: none;
}
.btn:active { transform: scale(0.95); }
.btn-primary {
    background: linear-gradient(135deg, var(--brass-bright) 0%, var(--brass) 40%, var(--brass-dark) 100%);
    color: #0a0e14; box-shadow: 0 0 12px var(--brass-dim);
}
.btn-primary:hover {
    background: linear-gradient(135deg, #eec560 0%, var(--brass-bright) 40%, var(--brass) 100%);
    box-shadow: var(--glow-brass); transform: translateY(-2px);
    color: #0a0e14; text-decoration: none;
}
.btn-primary:active { box-shadow: 0 0 4px var(--brass-dim); }
.btn-danger {
    background: linear-gradient(135deg, #f87171 0%, var(--warn) 100%);
    color: #fff; box-shadow: 0 0 12px var(--warn-dim);
}
.btn-danger:hover {
    box-shadow: 0 0 24px rgba(239,68,68,0.35); transform: translateY(-2px);
}
.btn-secondary {
    background: var(--bg-elevated); color: var(--text-body);
    border: 1px solid var(--border); box-shadow: var(--glow-sm);
}
.btn-secondary:hover {
    background: var(--bg-hover); transform: translateY(-2px);
    border-color: var(--border-light);
    box-shadow: var(--glow-md); color: var(--text-heading);
    text-decoration: none;
}
.btn-sm { padding: 6px 14px; font-size: 0.81rem; border-radius: 5px; }
.btn::after {
    content: ''; position: absolute; border-radius: 50%;
    background: rgba(255,255,255,0.2); width: 120px; height: 120px;
    margin-top: -60px; margin-left: -60px;
    top: 50%; left: 50%; opacity: 0; transform: scale(0); pointer-events: none;
}
.btn:active::after { animation: ripple 0.6s var(--ease-out); }
.btn-secondary::after { background: rgba(255,255,255,0.05); }

/* ===== ALERTS ===== */
.alert {
    padding: 14px 18px; border-radius: var(--radius-sm); margin-bottom: 18px;
    font-size: 0.91rem; font-weight: 500;
    animation: scaleIn 0.25s var(--ease-out);
    border-left: 3px solid transparent; line-height: 1.6;
}
.alert-success {
    background: rgba(34,197,94,0.08); color: #4ade80;
    border-color: var(--signal);
}
.alert-error {
    background: rgba(239,68,68,0.08); color: #f87171;
    border-color: var(--warn);
}
.alert-info {
    background: rgba(20,184,166,0.08); color: #2dd4bf;
    border-color: var(--teal);
}

/* ===== EMPTY STATE ===== */
.empty-state {
    text-align: center; padding: 72px 20px; color: var(--text-muted);
    animation: fadeIn 0.45s var(--ease-out);
}
.empty-state h2 { font-size: 1.15rem; margin-bottom: 8px; color: var(--text-muted); }
.empty-state h2::after { display: none; }

/* ===== SINGLE POST ===== */
article.single {
    background: var(--bg-surface); padding: 40px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border); box-shadow: var(--glow-md);
    animation: fadeInUp 0.4s var(--ease-out); max-width: 800px;
}
article.single h1 {
    font-size: 2.2rem; margin-bottom: 12px; line-height: 1.25; font-weight: 800;
    letter-spacing: -0.6px;
}
article.single .meta {
    color: var(--text-muted); font-size: 0.9rem; margin-bottom: 34px;
    display: flex; align-items: center; gap: 10px;
    padding-bottom: 20px; border-bottom: 1px solid var(--border);
}
article.single .body { font-size: 1.12rem; line-height: 2.1; color: var(--text-body); }
article.single .body p { margin-bottom: 1.3em; }
article.single .body p:last-child { margin-bottom: 0; }
.back-link { margin-bottom: 18px; font-size: 0.88rem; }
.back-link a {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 8px 16px; background: var(--bg-surface);
    border: 1px solid var(--border); border-radius: var(--radius-full);
    font-weight: 500; box-shadow: var(--glow-sm);
    transition: all 0.25s var(--ease-out);
}
.back-link a:hover {
    gap: 10px; box-shadow: var(--glow-md); border-color: var(--border-light);
    text-decoration: none;
}

/* ===== FOOTER ===== */
.site-footer {
    border-top: 1px solid;
    border-image: linear-gradient(90deg, var(--brass), var(--teal), transparent) 1;
    background: var(--bg-surface); margin-top: 16px;
}
.footer-inner {
    max-width: 1100px; margin: 0 auto;
    display: grid; grid-template-columns: 1fr auto 1fr;
    align-items: center; padding: 26px 36px; gap: 24px;
    font-size: 0.84rem; color: var(--text-muted);
}
.footer-col:nth-child(1) { text-align: left; }
.footer-col:nth-child(2) { display: flex; gap: 22px; }
.footer-col:nth-child(2) a {
    color: var(--text-muted); transition: all 0.2s;
    white-space: nowrap; font-weight: 500;
}
.footer-col:nth-child(2) a:hover { color: var(--brass); text-decoration: none; }
.footer-col:nth-child(3) { text-align: right; font-weight: 600; color: var(--text-body); }
.footer-callsign .morse-dots {
    display: inline-block; margin-left: 8px; color: var(--brass);
    font-size: 0.76rem; letter-spacing: 2px; opacity: 0.7;
    animation: morseBlink 2s ease-in-out infinite;
}

/* ===== FAB ADMIN BUTTON ===== */
.manage-link {
    position: fixed; bottom: 26px; right: 26px; z-index: 50;
}
.manage-link a {
    display: flex; align-items: center; gap: 8px;
    padding: 13px 22px; background: var(--bg-elevated);
    color: var(--sb-text-muted); border-radius: var(--radius-full);
    font-size: 0.84rem; font-weight: 600;
    border: 1px solid var(--border);
    box-shadow: var(--glow-lg);
    transition: all 0.35s var(--ease-spring);
    animation: glowPulse 3s infinite;
    text-decoration: none;
}
.manage-link a:hover {
    color: var(--brass); transform: translateY(-4px);
    border-color: var(--brass);
    box-shadow: var(--glow-brass), var(--glow-lg);
    text-decoration: none;
}

/* ===== ADMIN PANEL ===== */
.admin-header {
    background: var(--bg-base); color: #fff;
    padding: 14px 26px; display: flex; justify-content: space-between;
    align-items: center; border-bottom: 1px solid var(--sb-border);
    position: sticky; top: 0; z-index: 50;
}
.admin-header strong {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 0.95rem; letter-spacing: -0.2px;
}
.admin-header nav { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.admin-header a {
    color: var(--text-muted); font-size: 0.84rem;
    padding: 6px 14px; border-radius: var(--radius-full);
    transition: all 0.2s var(--ease-out); font-weight: 500;
    text-decoration: none;
}
.admin-header a:hover { color: #fff; background: rgba(255,255,255,0.05); text-decoration: none; }
.admin-wrap {
    max-width: 1100px; margin: 0 auto; padding: 30px 26px;
    animation: fadeInUp 0.4s var(--ease-out);
}
.admin-wrap h2 { margin-bottom: 20px; font-weight: 700; font-size: 1.35rem; }

/* Admin stat cards */
.admin-stats {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 14px; margin-bottom: 26px;
}
.admin-stat-card {
    background: var(--bg-surface); padding: 18px 22px;
    border-radius: var(--radius-md); border: 1px solid var(--border);
    box-shadow: var(--glow-sm);
    transition: all 0.3s var(--ease-out);
    text-decoration: none; color: inherit; display: block;
}
.admin-stat-card:hover {
    transform: translateY(-3px); border-color: var(--brass);
    box-shadow: var(--glow-md), 0 0 12px rgba(212,162,76,0.05);
    text-decoration: none; color: inherit;
}
.admin-stat-card .stat-num {
    font-size: 1.9rem; font-weight: 800; color: var(--brass);
    font-family: 'Space Grotesk', 'Inter', sans-serif; line-height: 1.2;
}
.admin-stat-card .stat-label { font-size: 0.8rem; color: var(--text-muted); margin-top: 4px; font-weight: 500; }

/* ===== TABLES ===== */
.table-wrap {
    background: var(--bg-surface); border-radius: var(--radius-lg); overflow: hidden;
    border: 1px solid var(--border); box-shadow: var(--glow-md);
    animation: fadeInUp 0.4s var(--ease-out);
}
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th, .admin-table td { padding: 13px 18px; text-align: left; }
.admin-table th {
    background: var(--bg-elevated); font-weight: 700; font-size: 0.76rem;
    text-transform: uppercase; color: var(--text-muted); letter-spacing: 0.6px;
    border-bottom: 2px solid var(--border);
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    position: sticky; top: 0; z-index: 1;
}
.admin-table td {
    border-top: 1px solid rgba(255,255,255,0.03);
    font-size: 0.9rem; color: var(--text-body);
    transition: background 0.15s;
}
.admin-table tbody tr:nth-child(even) td { background: rgba(255,255,255,0.012); }
.admin-table tbody tr:hover td {
    background: rgba(212,162,76,0.04);
    box-shadow: inset 3px 0 0 var(--brass);
}
.admin-table tbody tr.row-confirmed td { background: rgba(34,197,94,0.04); }
.admin-table tbody tr.row-confirmed:hover td { background: rgba(34,197,94,0.08); }
.actions-bar {
    display: flex; gap: 10px; align-items: center; margin-bottom: 22px;
    flex-wrap: wrap;
}

/* Status badges */
.status-badge {
    display: inline-block; padding: 3px 12px; border-radius: var(--radius-full);
    font-size: 0.72rem; font-weight: 700; letter-spacing: 0.3px;
    text-transform: uppercase;
}
.status-published { background: rgba(34,197,94,0.15); color: #4ade80; }
.status-draft { background: rgba(212,162,76,0.15); color: var(--brass-bright); }
.status-badge-reject { background: rgba(239,68,68,0.15); color: #f87171; }

/* ===== AUTH BOXES ===== */
.login-box {
    max-width: 420px; margin: 80px auto; background: var(--bg-surface);
    padding: 44px; border-radius: var(--radius-lg);
    border: 1px solid var(--border); border-top: 3px solid var(--brass);
    box-shadow: var(--glow-lg), 0 0 40px rgba(212,162,76,0.04);
    animation: scaleIn 0.35s var(--ease-out);
}
.login-box h1 { margin-bottom: 8px; font-size: 1.5rem; font-weight: 700; text-align: center; }

.auth-box {
    max-width: 500px; margin: 0 auto; background: var(--bg-surface);
    padding: 36px; border-radius: var(--radius-lg);
    border: 1px solid var(--border); box-shadow: var(--glow-md);
    animation: scaleIn 0.35s var(--ease-out);
}
.auth-box .form-group { margin-bottom: 20px; }
.auth-box .form-group label {
    display: block; margin-bottom: 6px; font-weight: 600;
    font-size: 0.86rem; color: var(--text-body);
    font-family: 'Space Grotesk', 'Inter', sans-serif;
}
.auth-box .form-group input {
    width: 100%; padding: 11px 15px;
    border: 1px solid var(--border); border-radius: var(--radius-sm);
    font-size: 0.93rem; font-family: inherit;
    transition: all 0.3s var(--ease-out);
    background: var(--bg-input); color: var(--text-body);
}
.auth-box .form-group input:focus {
    outline: none; border-color: var(--teal);
    box-shadow: 0 0 0 3px var(--teal-dim), 0 0 12px rgba(20,184,166,0.08);
}
.auth-box .form-group input:disabled {
    opacity: 0.45; background: var(--bg-base); border-style: dashed;
}
.auth-footer-link { text-align: center; margin-top: 24px; color: var(--text-muted); font-size: 0.91rem; }
.auth-footer-link a { font-weight: 600; }
.auth-submit-full { width: 100%; padding: 13px !important; font-size: 0.98rem !important; }
.resend-wrap { margin-top: 16px; font-size: 0.84rem; color: var(--text-muted); display: flex; align-items: center; gap: 8px; }

/* ===== COMMUNITY ===== */
.community-layout {
    display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start;
}
.community-form-wrap {
    background: var(--bg-surface); padding: 30px;
    border-radius: var(--radius-lg); border: 1px solid var(--border);
    box-shadow: var(--glow-md); animation: scaleIn 0.35s var(--ease-out);
}
.community-form-wrap h3, .community-messages h3 {
    font-size: 1.1rem; margin-bottom: 18px; font-weight: 700;
}
.community-form .form-row {
    display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px;
}
.community-form .form-group { margin-bottom: 14px; }
.community-form .form-group label {
    display: block; margin-bottom: 5px; font-weight: 600;
    font-size: 0.83rem; color: var(--text-body);
    font-family: 'Space Grotesk', 'Inter', sans-serif;
}
.community-form .form-group input, .community-form .form-group textarea {
    width: 100%; padding: 10px 14px;
    border: 1px solid var(--border); border-radius: var(--radius-sm);
    font-size: 0.91rem; font-family: inherit;
    transition: all 0.3s var(--ease-out);
    background: var(--bg-input); color: var(--text-body);
}
.community-form .form-group input:focus, .community-form .form-group textarea:focus {
    outline: none; border-color: var(--teal);
    box-shadow: 0 0 0 3px var(--teal-dim);
}
.community-form .form-group textarea { resize: vertical; min-height: 100px; }
.community-messages { animation: fadeInUp 0.4s var(--ease-out); }
.community-msg {
    background: var(--bg-surface); padding: 18px 22px;
    border-radius: var(--radius-md); border: 1px solid var(--border);
    margin-bottom: 12px; border-left: 3px solid transparent;
    box-shadow: var(--glow-sm);
    transition: all 0.3s var(--ease-smooth);
    animation: fadeInUp 0.3s var(--ease-out) both;
}
.community-msg:nth-child(1) { animation-delay: 0s; }
.community-msg:nth-child(2) { animation-delay: 0.05s; }
.community-msg:nth-child(3) { animation-delay: 0.10s; }
.community-msg:nth-child(4) { animation-delay: 0.15s; }
.community-msg:nth-child(5) { animation-delay: 0.20s; }
.community-msg:nth-child(6) { animation-delay: 0.25s; }
.community-msg:nth-child(7) { animation-delay: 0.30s; }
.community-msg:nth-child(8) { animation-delay: 0.35s; }
.community-msg:hover {
    background: var(--bg-elevated); border-color: var(--border-light);
    box-shadow: var(--glow-md);
}
.community-msg-verified-msg { border-left-color: var(--teal); }
.community-msg-owner-msg { border-left-color: var(--brass); }
.community-msg-header {
    display: flex; align-items: center; gap: 10px; margin-bottom: 10px;
    flex-wrap: wrap;
}
.community-msg-avatar {
    width: 30px; height: 30px; border-radius: 50%;
    background: linear-gradient(135deg, var(--brass), var(--brass-dark));
    color: #fff; display: inline-flex; align-items: center;
    justify-content: center; font-weight: 700; font-size: 0.78rem;
    flex-shrink: 0; font-family: 'Space Grotesk', 'Inter', sans-serif;
}
.community-msg-header strong { color: var(--text-heading); font-size: 0.93rem; }
.community-msg-callsign {
    background: var(--brass-dim); color: var(--brass-bright);
    padding: 2px 10px; border-radius: var(--radius-full);
    font-size: 0.76rem; font-weight: 600; letter-spacing: 0.3px;
}
.community-msg-time { color: var(--text-muted); font-size: 0.76rem; margin-left: auto; }
.community-msg p { color: var(--text-body); font-size: 0.93rem; line-height: 1.7; white-space: pre-line; }
.community-msg-user { color: var(--signal); font-size: 0.78rem; }
.community-msg-owner { color: var(--brass); font-size: 0.83rem; animation: float 3s ease-in-out infinite; }
.community-msg-verified { color: var(--signal); font-size: 0.83rem; }
.guest-limit-note {
    background: rgba(20,184,166,0.06); border-left: 3px solid var(--teal);
    padding: 10px 14px; margin-bottom: 16px;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    font-size: 0.86rem; color: var(--text-muted);
}
.community-login-prompt { color: var(--text-muted); margin-bottom: 20px; font-size: 0.91rem; }
.community-autofill-note { font-size: 0.82rem; color: var(--text-muted); margin-bottom: 16px; }

/* ===== CODE INPUT ===== */
.code-input {
    font-size: 1.5rem !important; letter-spacing: 10px !important;
    text-align: center !important; font-weight: 700 !important;
    font-family: 'Space Grotesk', 'Inter', monospace !important;
}

/* ===== TABS ===== */
.log-tabs, .profile-tabs {
    display: flex; gap: 6px; margin-bottom: 26px; flex-wrap: wrap;
}
.log-tab, .profile-tab, .exam-tab {
    padding: 9px 20px; border-radius: var(--radius-full);
    border: 1px solid var(--border); background: var(--bg-surface);
    cursor: pointer; font-size: 0.87rem; font-weight: 600;
    transition: all 0.25s var(--ease-smooth);
    color: var(--text-muted); font-family: inherit;
    text-decoration: none; box-shadow: var(--glow-sm);
}
.log-tab:hover, .profile-tab:hover, .exam-tab:hover {
    border-color: var(--border-light); color: var(--text-body);
    text-decoration: none; transform: translateY(-1px);
    box-shadow: var(--glow-md);
}
.log-tab.active, .profile-tab.active, .exam-tab.active {
    border-color: var(--brass);
    background: linear-gradient(135deg, var(--brass-dim), rgba(212,162,76,0.04));
    color: var(--brass-bright);
    box-shadow: 0 0 8px var(--brass-dim);
}
.profile-tab.danger-tab { color: var(--warn); }
.profile-tab.danger-tab:hover { border-color: var(--warn); background: var(--warn-dim); }
.profile-tab.danger-tab.active { border-color: var(--warn); background: var(--warn-dim); color: var(--warn); }
.log-tab-export { margin-left: auto; }
.profile-content { animation: fadeInUp 0.35s var(--ease-out); }
.profile-verified { color: var(--signal); font-size: 0.8rem; }
.profile-danger-box { border-color: rgba(239,68,68,0.3) !important; border-width: 2px !important; }
.profile-danger-heading { color: var(--warn); margin-bottom: 16px; }
.profile-danger-text { color: var(--text-muted); margin-bottom: 20px; }

/* ===== EXAM ===== */
.exam-tabs { display: flex; gap: 8px; margin-bottom: 26px; }
.start-screen { text-align: center; padding: 60px 20px; animation: fadeInUp 0.4s var(--ease-out); }
.start-screen .btn { font-size: 1.1rem; padding: 14px 40px; }
.question-card {
    background: var(--bg-surface); border-radius: var(--radius-lg); padding: 34px;
    border: 1px solid var(--border); box-shadow: var(--glow-md);
    animation: fadeInUp 0.3s var(--ease-out); max-width: 800px;
}
.question-num { color: var(--text-muted); font-size: 0.83rem; margin-bottom: 8px; font-weight: 600; }
.question-text {
    font-size: 1.18rem; font-weight: 600; margin-bottom: 26px;
    color: var(--text-heading); line-height: 1.6;
}
.option-btn {
    display: block; width: 100%; text-align: left; padding: 14px 18px;
    margin-bottom: 10px; border: 1px solid var(--border);
    border-radius: var(--radius-sm); background: var(--bg-surface);
    cursor: pointer; font-size: 0.95rem; font-family: inherit;
    transition: all 0.25s var(--ease-smooth); color: var(--text-body);
    box-shadow: var(--glow-sm);
}
.option-btn:hover:not(.disabled) {
    border-color: var(--teal); background: rgba(20,184,166,0.06);
    transform: translateX(6px);
    box-shadow: var(--glow-teal);
}
.option-btn:active:not(.disabled) { transform: scale(0.98); }
.option-btn.correct {
    border-color: var(--signal); background: rgba(34,197,94,0.08);
    color: #4ade80;
    box-shadow: 0 0 8px rgba(34,197,94,0.15);
}
.option-btn.wrong {
    border-color: var(--warn); background: rgba(239,68,68,0.08);
    color: #f87171;
    box-shadow: 0 0 8px rgba(239,68,68,0.12);
}
.option-btn.disabled { pointer-events: none; }
.feedback-box {
    margin-top: 16px; padding: 14px 18px; border-radius: var(--radius-sm);
    font-size: 0.9rem; animation: fadeInUp 0.25s var(--ease-out); line-height: 1.6;
}
.feedback-box.correct { background: rgba(34,197,94,0.06); color: #4ade80; border: 1px solid rgba(34,197,94,0.2); }
.feedback-box.wrong { background: rgba(239,68,68,0.06); color: #f87171; border: 1px solid rgba(239,68,68,0.2); }
.next-btn { margin-top: 20px; display: none; }
.next-btn.show { display: inline-flex; }
.progress-bar-wrap {
    background: var(--bg-elevated); border-radius: var(--radius-full);
    height: 8px; margin-bottom: 22px; overflow: hidden;
}
.progress-bar-fill {
    height: 100%; border-radius: var(--radius-full);
    background: linear-gradient(90deg, var(--brass) 0%, var(--teal) 100%);
    transition: width 0.5s var(--ease-smooth);
    box-shadow: 0 0 16px rgba(212,162,76,0.3);
}
.score-display {
    display: flex; gap: 20px; align-items: center; margin-bottom: 20px;
    font-weight: 600; color: var(--text-muted); font-size: 0.9rem;
}
.results-screen { text-align: center; padding: 44px; animation: scaleIn 0.45s var(--ease-smooth); }
.results-screen .big-score {
    font-size: 4.5rem; font-weight: 800;
    background: linear-gradient(135deg, var(--brass-bright) 0%, var(--teal) 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
}
.exam-score-denom { font-size: 1.5rem; color: var(--text-muted); }
.results-screen .detail { color: var(--text-muted); font-size: 1.1rem; margin: 10px 0 26px; }
.exam-select-text { color: var(--text-muted); font-size: 1.05rem; margin-bottom: 26px; }
.exam-resources { display: flex; gap: 16px; margin-bottom: 30px; }
.resource-card {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px;
    padding: 22px 16px; background: var(--bg-surface); border: 1px solid var(--border);
    border-radius: var(--radius-md); text-align: center;
    transition: all 0.3s var(--ease-smooth);
    text-decoration: none; color: inherit;
    box-shadow: var(--glow-sm);
}
.resource-card:hover {
    border-color: var(--brass); box-shadow: var(--glow-md), 0 0 12px rgba(212,162,76,0.05);
    transform: translateY(-3px); text-decoration: none;
}
.resource-flag { font-size: 1.8rem; margin-bottom: 4px; }
.resource-label { font-weight: 700; font-size: 0.95rem; }
.resource-desc { font-size: 0.8rem; color: var(--text-muted); }

/* ===== NOTIFICATIONS ===== */
.notif-list { display: flex; flex-direction: column; gap: 10px; }
.notif-item {
    display: flex; justify-content: space-between; align-items: flex-start;
    gap: 14px; background: var(--bg-surface); border: 1px solid var(--border);
    border-radius: var(--radius-md); padding: 16px 20px;
    transition: all 0.25s var(--ease-out);
    box-shadow: var(--glow-sm);
}
.notif-item:hover { background: var(--bg-elevated); border-color: var(--border-light); }
.notif-unread {
    border-left: 3px solid var(--teal);
    background: rgba(20,184,166,0.03);
    box-shadow: 0 0 12px rgba(20,184,166,0.04);
}
.notif-content { flex: 1; }
.notif-content p { margin: 4px 0; color: var(--text-body); line-height: 1.5; }
.notif-time { font-size: 0.76rem; color: var(--text-muted); }
.notif-actions { display: flex; gap: 8px; align-items: center; white-space: nowrap; }
.notif-badge {
    display: inline-block; background: var(--warn); color: #fff;
    font-size: 0.66rem; font-weight: 700; min-width: 19px; height: 19px;
    line-height: 19px; text-align: center; border-radius: 10px;
    padding: 0 6px; vertical-align: middle; margin-left: 2px;
    animation: breathe 2.5s ease-in-out infinite;
}

/* ===== SEARCH ===== */
.search-hero-form {
    position: relative; z-index: 1;
    display: flex; gap: 10px; max-width: 600px; margin: 26px auto 0;
    animation: fadeInUp 0.55s 0.18s var(--ease-out) both;
}
.search-hero-input {
    flex: 1; padding: 14px 20px;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-full);
    background: rgba(255,255,255,0.04); color: #fff;
    font-size: 0.98rem; font-family: inherit;
    backdrop-filter: blur(6px);
    transition: all 0.35s var(--ease-smooth);
}
.search-hero-input::placeholder { color: rgba(255,255,255,0.3); }
.search-hero-input:focus {
    outline: none; border-color: var(--brass);
    background: rgba(255,255,255,0.08);
    box-shadow: 0 0 0 3px rgba(212,162,76,0.12), 0 0 20px rgba(212,162,76,0.08);
}
.search-hero-btn {
    padding: 14px 30px; border-radius: var(--radius-full) !important;
    font-size: 0.98rem !important; white-space: nowrap;
}
.hero-search { padding: 40px 32px; }
.hero-search .search-hero-form { margin-top: 16px; }

.search-summary { color: var(--text-muted); font-size: 0.93rem; margin-bottom: 30px; }
.search-section { margin-bottom: 36px; }
.search-section-title {
    font-size: 1.1rem; font-weight: 700; color: var(--text-heading);
    margin-bottom: 14px; padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    display: flex; align-items: center; gap: 8px;
}
.search-grid { display: flex; flex-direction: column; gap: 10px; }
.search-result-card {
    display: flex; align-items: flex-start; gap: 16px;
    background: var(--bg-surface); padding: 16px 20px;
    border-radius: var(--radius-md); border: 1px solid var(--border);
    transition: all 0.3s var(--ease-smooth);
    text-decoration: none; color: inherit;
    box-shadow: var(--glow-sm); border-left: 3px solid transparent;
}
.search-result-card:hover {
    transform: translateY(-2px); border-color: var(--brass);
    border-left-color: var(--brass);
    box-shadow: var(--glow-md), 0 0 8px rgba(212,162,76,0.05);
    text-decoration: none; color: inherit;
}
.search-result-avatar {
    width: 46px; height: 46px; border-radius: 50%;
    background: linear-gradient(135deg, var(--brass), var(--brass-dark));
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 1.1rem; flex-shrink: 0;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
}
.search-result-body { flex: 1; min-width: 0; }
.search-result-title {
    font-weight: 700; color: var(--text-heading); font-size: 0.98rem;
    display: flex; align-items: center; gap: 8px;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
}
.search-result-sub { font-size: 0.82rem; color: var(--text-muted); margin-top: 2px; }
.search-result-excerpt {
    font-size: 0.86rem; color: var(--text-muted); margin-top: 4px;
    line-height: 1.5; overflow: hidden; text-overflow: ellipsis;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.search-result-callsign {
    display: inline-block; background: var(--brass-dim); color: var(--brass-bright);
    padding: 2px 10px; border-radius: var(--radius-full);
    font-size: 0.74rem; font-weight: 600;
}

/* ===== PUBLIC PROFILE ===== */
.profile-public { max-width: 800px; margin: 0 auto; animation: fadeInUp 0.4s var(--ease-out); }
.profile-public-card {
    display: flex; align-items: center; gap: 26px;
    background: var(--bg-surface); padding: 32px; border-radius: var(--radius-lg);
    border: 1px solid var(--border); box-shadow: var(--glow-md);
    margin-bottom: 22px;
}
.profile-public-avatar {
    width: 76px; height: 76px; border-radius: 50%;
    background: linear-gradient(135deg, var(--brass), var(--brass-dark));
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 1.8rem; flex-shrink: 0;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    box-shadow: 0 0 0 3px var(--brass-dim), 0 0 24px var(--brass-glow);
}
.profile-public-info h2 { font-size: 1.4rem; margin-bottom: 4px; font-weight: 700; }
.profile-public-callsign {
    display: inline-block; font-size: 1rem; font-weight: 600; color: var(--brass);
    margin-bottom: 4px;
}
.profile-public-owner { color: var(--brass); font-weight: 600; font-size: 0.88rem; }
.profile-public-verified { color: var(--signal); font-weight: 600; font-size: 0.88rem; }
.profile-public-joined { color: var(--text-muted); font-size: 0.83rem; margin-top: 4px; }
.profile-public-bio {
    background: var(--bg-surface); padding: 28px 32px;
    border-radius: var(--radius-lg); border: 1px solid var(--border);
    box-shadow: var(--glow-md); margin-bottom: 22px;
}
.profile-public-bio h3 { font-size: 1.05rem; margin-bottom: 10px; font-weight: 700; }
.profile-public-bio p { color: var(--text-body); line-height: 1.8; white-space: pre-line; font-size: 0.95rem; }
.profile-public-logs { margin-bottom: 22px; }
.profile-public-logs h3 { font-size: 1.05rem; margin-bottom: 14px; font-weight: 700; }
.text-muted { color: var(--text-muted); }
.text-muted a { color: var(--text-link); font-weight: 600; }

/* ===== STATUS BANNER ===== */
.status-banner {
    background: var(--bg-surface); border: 1px solid var(--border);
    border-radius: var(--radius-md); padding: 14px 22px; margin-bottom: 22px;
    box-shadow: var(--glow-sm);
}
.status-banner-row {
    display: flex; justify-content: space-between; align-items: center;
    flex-wrap: wrap; gap: 10px; font-size: 0.9rem; color: var(--text-body);
}
.status-verified { border-left: 3px solid var(--signal); background: rgba(34,197,94,0.03); }
.status-rejected { border-left: 3px solid var(--warn); background: rgba(239,68,68,0.03); }

/* ===== STATION LOG ===== */
.log-search-row {
    display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
    padding: 14px 18px; background: var(--bg-surface);
    border-radius: var(--radius-md); border: 1px solid var(--border);
    box-shadow: var(--glow-sm);
}
.log-search-row input, .log-search-row select {
    padding: 9px 14px; border: 1px solid var(--border);
    border-radius: var(--radius-sm); font-family: 'Inter', sans-serif;
    font-size: 0.87rem; transition: all 0.25s var(--ease-out);
    background: var(--bg-input); color: var(--text-body);
}
.log-search-row input:focus, .log-search-row select:focus {
    outline: none; border-color: var(--teal);
    box-shadow: 0 0 0 3px var(--teal-dim);
}
.log-search-input { flex: 1; min-width: 150px; }
.log-form-wrap {
    background: var(--bg-surface); border: 1px solid var(--border);
    border-radius: var(--radius-md); padding: 22px;
    margin-bottom: 22px; box-shadow: var(--glow-sm);
}
.log-form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 14px;
}
.log-notes-cell { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===== EXPORT ===== */
.export-formats { display: grid; gap: 16px; }
.export-card {
    background: var(--bg-surface); border: 1px solid var(--border);
    border-radius: var(--radius-md); padding: 22px;
    box-shadow: var(--glow-sm); transition: all 0.3s var(--ease-out);
}
.export-card:hover { border-color: var(--border-light); box-shadow: var(--glow-md); }
.export-card h4 { font-family: 'Space Grotesk', sans-serif; margin: 0 0 6px 0; font-size: 1rem; }
.export-card p { color: var(--text-muted); font-size: 0.86rem; margin-bottom: 14px; }

/* ===== SCROLL REVEAL (Intersection Observer) ===== */
.reveal { opacity: 0; transform: translateY(28px); transition: all 0.7s var(--ease-smooth); }
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ===== GHOST BUTTON VARIANT ===== */
.btn-ghost {
    background: transparent; color: var(--text-muted);
    border: 1px solid transparent;
    box-shadow: none;
}
.btn-ghost:hover {
    background: rgba(255,255,255,0.03); color: var(--text-body);
    border-color: var(--border); box-shadow: none;
    transform: translateY(-1px);
}

/* ===== TOAST NOTIFICATIONS ===== */
.toast-container {
    position: fixed; top: 20px; right: 20px; z-index: 999;
    display: flex; flex-direction: column; gap: 10px;
    pointer-events: none;
}
.toast {
    pointer-events: auto;
    padding: 14px 20px; border-radius: var(--radius-md);
    font-size: 0.9rem; font-weight: 500; line-height: 1.5;
    box-shadow: var(--glow-lg);
    animation: toastIn 0.4s var(--ease-spring);
    max-width: 400px; cursor: pointer;
    display: flex; align-items: flex-start; gap: 10px;
}
.toast.toast-out { animation: toastOut 0.3s var(--ease-out) forwards; }
.toast-success {
    background: #0d2b1a; color: #4ade80;
    border: 1px solid rgba(34,197,94,0.25);
}
.toast-error {
    background: #2b0d0d; color: #f87171;
    border: 1px solid rgba(239,68,68,0.25);
}
.toast-close {
    margin-left: auto; background: none; border: none;
    color: inherit; opacity: 0.5; cursor: pointer; font-size: 1.1rem;
    line-height: 1; padding: 0;
}
.toast-close:hover { opacity: 1; }
@keyframes toastIn {
    from { opacity: 0; transform: translateX(40px) scale(0.95); }
    to   { opacity: 1; transform: translateX(0) scale(1); }
}
@keyframes toastOut {
    from { opacity: 1; transform: translateX(0) scale(1); }
    to   { opacity: 0; transform: translateX(40px) scale(0.95); }
}

/* ===== SEARCH KEYBOARD HINT ===== */
.kbd-hint {
    display: inline-flex; align-items: center; gap: 2px;
    padding: 2px 7px; background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.10);
    border-radius: 4px; font-size: 0.7rem; font-weight: 600;
    color: rgba(255,255,255,0.3); letter-spacing: 0.5px;
    font-family: 'Inter', -apple-system, sans-serif;
    vertical-align: middle;
}

/* ===== UTILITY CLASSES ===== */
.glass {
    background: rgba(20,27,38,0.8);
    backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255,255,255,0.06);
}
.gradient-text {
    background: linear-gradient(135deg, var(--brass-bright) 0%, var(--teal) 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
}
.stagger-list > * { animation: fadeInUp 0.35s var(--ease-out) both; }
.stagger-list > *:nth-child(1) { animation-delay: 0s; }
.stagger-list > *:nth-child(2) { animation-delay: 0.05s; }
.stagger-list > *:nth-child(3) { animation-delay: 0.10s; }
.stagger-list > *:nth-child(4) { animation-delay: 0.15s; }
.stagger-list > *:nth-child(5) { animation-delay: 0.20s; }

/* ===== ACCESSIBILITY ===== */
:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; border-radius: 2px; }
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html { scroll-behavior: auto; }
}

/* ===== PRINT ===== */
@media print {
    .sidebar, .hamburger, .sidebar-overlay, .manage-link,
    .admin-header, .site-footer, .hero { display: none !important; }
    .main-content { margin-left: 0 !important; }
    body { background: #fff; color: #000; }
    article.single { border: none; box-shadow: none; padding: 0; }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .community-layout { grid-template-columns: 1fr; }
    .community-form .form-row { grid-template-columns: 1fr; }
    .admin-stats { grid-template-columns: repeat(2, 1fr); }
    .hero h1 { font-size: 1.9rem; }
    .hero { --hero-py: 52px; }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.4s var(--ease-smooth);
    }
    .sidebar.open { transform: translateX(0); }
    .sidebar-overlay.show { display: block; backdrop-filter: blur(4px); }
    .hamburger { display: flex; align-items: center; justify-content: center; }
    .main-content { margin-left: 0; }
    .hero { padding: 40px 18px 32px; --hero-py: 40px; }
    .hero h1 { font-size: 1.4rem; }
    .hero p { font-size: 0.91rem; }
    .hero-gallery { gap: 10px; }
    .hero-gallery img { width: 100%; height: auto; max-width: 320px; }
    .section { padding: 26px 16px; }
    .qsl-form { padding: 22px 16px; }
    .qsl-form .form-row { grid-template-columns: 1fr; }
    article.single { padding: 22px; }
    .info-grid { grid-template-columns: 1fr; }
    .manage-link { bottom: 16px; right: 16px; }
    .manage-link a { padding: 11px 16px; font-size: 0.78rem; }
    .admin-wrap { padding: 18px 12px; }
    .admin-table th, .admin-table td { padding: 10px 12px; font-size: 0.8rem; }
    .auth-box { padding: 22px 16px; }
    .profile-tabs { flex-direction: column; }
    .profile-tab { text-align: center; }
    .exam-resources { flex-direction: column; }
    .log-form-grid { grid-template-columns: 1fr 1fr; }
    .log-search-row { flex-direction: column; align-items: stretch; }
    .signal-meter { gap: 3px; height: 36px; }
    .s-bar { width: 6px; }
    .search-hero-form { flex-direction: column; }
    .search-hero-btn { width: 100%; }
    .profile-public-card { flex-direction: column; text-align: center; padding: 22px; }
    .search-result-card { padding: 14px; }
    .notif-item { flex-direction: column; }
    .notif-actions { width: 100%; justify-content: flex-end; }
    .admin-header { flex-direction: column; gap: 8px; text-align: center; }
    .admin-header nav { justify-content: center; }
    .community-msg-header { flex-direction: column; align-items: flex-start; gap: 6px; }
    .community-msg-time { margin-left: 0; }
    .admin-stats { grid-template-columns: 1fr; }
    .footer-inner {
        grid-template-columns: 1fr; text-align: center; gap: 12px;
        padding: 22px 16px;
    }
    .footer-col:nth-child(1),
    .footer-col:nth-child(3) { text-align: center; }
    .footer-col:nth-child(2) { justify-content: center; }
}

@media (max-width: 400px) {
    .hero h1 { font-size: 1.2rem; }
    .hero-owner { font-size: 0.76rem; padding: 4px 12px; }
    .log-form-grid { grid-template-columns: 1fr; }
    article.single { padding: 16px; }
    .section h2 { font-size: 1.15rem; }
}
