/* ============================================================
   De Antillen — Unified Design System
   Dutch Caribbean Military Roleplay · Kingdom of the Netherlands
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

/* ── Reset & Base ─────────────────────────────────────── */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --navy:       #0b1629;
    --navy-mid:   #112240;
    --navy-light: #1c3461;
    --blue:       #1a4f8a;
    --blue-light: #2667c2;
    --orange:     #e05c1a;
    --orange-light: #f07540;
    --gold:       #c9a227;
    --gold-light: #e8bf50;
    --white:      #f4f7fc;
    --text:       #cdd7e8;
    --text-muted: #7e97b8;
    --border:     rgba(255,255,255,0.08);
    --glass:      rgba(255,255,255,0.06);
    --glass-hover:rgba(255,255,255,0.10);
    --shadow:     0 8px 32px rgba(0,0,0,0.45);
    --radius:     14px;
    --radius-sm:  8px;
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', 'Segoe UI', sans-serif;
    background-color: var(--navy);
    background-image:
        radial-gradient(ellipse 80% 60% at 20% -10%, rgba(26,79,138,0.45) 0%, transparent 60%),
        radial-gradient(ellipse 60% 50% at 80% 110%, rgba(201,162,39,0.12) 0%, transparent 55%);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.6;
}

/* ── Scrollbar ─────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--navy); }
::-webkit-scrollbar-thumb { background: var(--blue); border-radius: 3px; }

/* ── Navigation ────────────────────────────────────────── */
nav {
    background: rgba(11,22,41,0.85);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--border);
    padding: 0 2rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 24px rgba(0,0,0,0.4);
}

nav ul {
    list-style: none;
    display: flex;
    gap: 0.25rem;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    height: 62px;
    overflow: visible;
}

nav li {
    position: relative;
    display: flex;
    align-items: center;
}

nav a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    padding: 0.5rem 0.9rem;
    border-radius: var(--radius-sm);
    transition: color 0.2s, background 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    white-space: nowrap;
}

nav a:hover {
    color: var(--gold-light);
    background: rgba(201,162,39,0.1);
}

nav a.active {
    color: var(--gold-light);
    background: rgba(201,162,39,0.15);
    font-weight: 600;
}

/* Dropdown */
.dropdown { position: relative; }
.dropdown-toggle { cursor: pointer; user-select: none; }

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(11,22,41,0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.5rem;
    padding-top: 0.75rem;
    min-width: 240px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.6);
    z-index: 2000;
}

.dropdown.active .dropdown-menu,
.dropdown:hover .dropdown-menu { display: block; }

.dropdown-menu a {
    display: flex;
    padding: 0.65rem 0.9rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    white-space: nowrap;
}

.dropdown-menu a:hover,
.dropdown-menu a.active {
    background: rgba(201,162,39,0.12);
    color: var(--gold-light);
}

/* ── Page Layout ───────────────────────────────────────── */
.main-content {
    padding: 2.5rem 2rem;
}

.container {
    max-width: 1140px;
    margin: 0 auto;
}

/* ── Page Header ───────────────────────────────────────── */
.page-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 3rem 2rem 2.5rem;
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--orange), var(--gold), var(--blue-light));
}

.page-header h1 {
    font-family: 'Cinzel', serif;
    font-size: clamp(1.8rem, 4vw, 3rem);
    font-weight: 700;
    color: var(--white);
    letter-spacing: 0.03em;
    text-shadow: 0 2px 12px rgba(0,0,0,0.4);
    line-height: 1.2;
    margin-bottom: 0.5rem;
}

.page-header .subtitle {
    font-size: 1.05rem;
    color: var(--gold-light);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-weight: 500;
    opacity: 0.85;
}

/* ── Section Card ──────────────────────────────────────── */
.section-card {
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    margin-bottom: 1.75rem;
    transition: border-color 0.2s, background 0.2s;
}

.section-card:hover {
    border-color: rgba(255,255,255,0.14);
    background: var(--glass-hover);
}

.section-card h2 {
    font-family: 'Cinzel', serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gold-light);
    letter-spacing: 0.04em;
    margin-bottom: 1rem;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid rgba(201,162,39,0.2);
}

.section-card p {
    color: var(--text);
    line-height: 1.85;
    font-size: 0.97rem;
    margin-bottom: 0.75rem;
}

.section-card p:last-child { margin-bottom: 0; }

/* ── Highlight Card (Leader/Commander) ─────────────────── */
.highlight-card {
    background: linear-gradient(135deg, rgba(26,79,138,0.25) 0%, rgba(201,162,39,0.08) 100%);
    border: 1px solid rgba(201,162,39,0.25);
    border-radius: var(--radius);
    padding: 2rem;
    margin-bottom: 1.75rem;
    position: relative;
    overflow: hidden;
}

.highlight-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--orange), var(--gold));
}

.highlight-card .card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.highlight-card .card-header h2 {
    font-family: 'Cinzel', serif;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--gold-light);
    letter-spacing: 0.04em;
    margin: 0;
}

/* ── Commander / Profile Card ──────────────────────────── */
.commander-card {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.commander-avatar {
    width: 130px;
    height: 130px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid rgba(201,162,39,0.4);
    box-shadow: 0 4px 20px rgba(0,0,0,0.5), 0 0 0 1px rgba(201,162,39,0.1);
    flex-shrink: 0;
    transition: border-color 0.3s;
}

.commander-avatar:hover { border-color: rgba(201,162,39,0.7); }

.commander-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.commander-info { flex: 1; min-width: 180px; }

.commander-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--gold);
    font-weight: 600;
    margin-bottom: 0.35rem;
    opacity: 0.85;
}

.commander-name {
    font-family: 'Cinzel', serif;
    font-size: 1.7rem;
    font-weight: 700;
    color: var(--white);
    line-height: 1.2;
    margin-bottom: 0.3rem;
    text-decoration: none;
    display: block;
    transition: color 0.2s;
}

.commander-name:hover { color: var(--gold-light); }

.commander-alias {
    font-size: 1rem;
    color: var(--text-muted);
    font-style: italic;
    margin-bottom: 0.5rem;
}

.role-tag {
    display: inline-block;
    padding: 0.3rem 0.85rem;
    background: linear-gradient(135deg, rgba(201,162,39,0.25), rgba(201,162,39,0.1));
    border: 1px solid rgba(201,162,39,0.35);
    color: var(--gold-light);
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.03em;
}

/* ── Members / Moderation Grid ─────────────────────────── */
.members-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
}

.member-card {
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem 1.25rem;
    text-align: center;
    transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}

.member-card:hover {
    transform: translateY(-4px);
    border-color: rgba(201,162,39,0.3);
    box-shadow: 0 12px 32px rgba(0,0,0,0.35);
}

.profile-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.avatar-container {
    width: 110px;
    height: 110px;
    margin: 0 auto 1rem;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid rgba(255,255,255,0.12);
    transition: border-color 0.25s;
}

.profile-link:hover .avatar-container { border-color: rgba(201,162,39,0.5); }

.avatar-container img { width: 100%; height: 100%; object-fit: cover; }

.member-username {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: 0.25rem;
    font-family: 'Cinzel', serif;
}

.member-displayname {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-style: italic;
    margin-bottom: 0.5rem;
}

.member-role {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(201,162,39,0.12);
    border: 1px solid rgba(201,162,39,0.25);
    color: var(--gold-light);
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* ── Role Section Headers (Moderation) ─────────────────── */
.role-section-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.25rem;
    background: var(--glass);
    border: 1px solid var(--border);
    border-left: 3px solid var(--gold);
    border-radius: var(--radius-sm);
    margin: 2rem 0 1rem;
    font-family: 'Cinzel', serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--gold-light);
    letter-spacing: 0.04em;
}

.role-section-header.admin { border-left-color: #e05c1a; color: #f07540; }
.role-section-header.moderator { border-left-color: #2667c2; color: #6ba3f5; }
.role-section-header.ingame-mod { border-left-color: #16a34a; color: #4ade80; }

/* ── Mod Cards ─────────────────────────────────────────── */
.mod-card {
    display: block;
    text-decoration: none;
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem 1rem;
    text-align: center;
    color: var(--text);
    transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}

.mod-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 28px rgba(0,0,0,0.35);
}

.mod-card.admin { border-left: 3px solid #e05c1a; }
.mod-card.moderator { border-left: 3px solid #2667c2; }
.mod-card.ingame-mod { border-left: 3px solid #16a34a; }
.mod-card.admin:hover { border-color: #e05c1a; }
.mod-card.moderator:hover { border-color: #2667c2; }
.mod-card.ingame-mod:hover { border-color: #16a34a; }

.mod-avatar {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    margin: 0 auto 0.85rem;
    border: 2px solid rgba(255,255,255,0.12);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    display: block;
    overflow: hidden;
}

.mod-avatar img { width: 100%; height: 100%; object-fit: cover; }

.mod-info { text-align: center; }

.mod-name {
    font-family: 'Cinzel', serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--white);
    text-decoration: none;
    display: block;
    margin-bottom: 0.2rem;
    transition: color 0.2s;
}

.mod-name:hover { color: var(--gold-light); }

.mod-displayname {
    font-size: 0.82rem;
    color: var(--text-muted);
    font-style: italic;
    margin-bottom: 0.3rem;
}

.mod-role-label {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* ── FAQ ───────────────────────────────────────────────── */
.faq-list { margin-top: 0; }

.faq-item {
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.75rem 2rem;
    margin-bottom: 1.25rem;
    transition: border-color 0.2s, background 0.2s;
    cursor: pointer;
}

.faq-item:hover {
    border-color: rgba(201,162,39,0.2);
    background: var(--glass-hover);
}

.faq-question {
    font-family: 'Cinzel', serif;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--gold-light);
    margin-bottom: 0;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    user-select: none;
}

.faq-item.open .faq-question { margin-bottom: 0.85rem; }

.faq-answer {
    font-size: 0.95rem;
    line-height: 1.85;
    color: var(--text);
    display: none;
}

.faq-item.open .faq-answer { display: block; }

.faq-answer a {
    color: #6ba3f5;
    text-decoration: none;
    border-bottom: 1px solid rgba(107,163,245,0.4);
    transition: color 0.2s, border-color 0.2s;
    word-break: break-word;
}

.faq-answer a:hover { color: var(--gold-light); border-bottom-color: var(--gold-light); }

.faq-answer ul { margin: 0.75rem 0 0 1.5rem; }
.faq-answer li { margin-bottom: 0.4rem; }
.faq-answer strong { color: var(--white); font-weight: 600; }

/* ── Stat Cards (Home) ─────────────────────────────────── */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.25rem;
    margin: 1.5rem 0;
}

.stat-card {
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem 1.5rem;
    text-align: center;
    transition: transform 0.25s, border-color 0.25s;
}

.stat-card:hover {
    transform: translateY(-4px);
    border-color: rgba(201,162,39,0.25);
}

.stat-icon { font-size: 2.2rem; margin-bottom: 0.75rem; display: block; }

.stat-value {
    font-family: 'Cinzel', serif;
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--gold-light);
    margin-bottom: 0.3rem;
    min-height: 2.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-label { font-size: 0.88rem; color: var(--text-muted); font-weight: 500; letter-spacing: 0.04em; }

/* ── CTA Buttons ───────────────────────────────────────── */
.cta-buttons {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
    margin-top: 1.5rem;
}

.cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.85rem 2rem;
    font-size: 0.97rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: var(--radius-sm);
    transition: transform 0.2s, box-shadow 0.2s, filter 0.2s;
    letter-spacing: 0.02em;
}

.cta-btn:hover { transform: translateY(-2px); filter: brightness(1.1); }

.cta-btn.roblox {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: #fff;
    box-shadow: 0 4px 16px rgba(231,76,60,0.35);
}
.cta-btn.roblox:hover { box-shadow: 0 6px 24px rgba(231,76,60,0.55); }

.cta-btn.discord {
    background: linear-gradient(135deg, #5865F2, #4752C4);
    color: #fff;
    box-shadow: 0 4px 16px rgba(88,101,242,0.35);
}
.cta-btn.discord:hover { box-shadow: 0 6px 24px rgba(88,101,242,0.55); }

/* ── Discord Link (inline) ─────────────────────────────── */
.discord-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.65rem 1.4rem;
    background: linear-gradient(135deg, #5865F2, #4752C4);
    color: #fff;
    text-decoration: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.93rem;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 4px 14px rgba(88,101,242,0.35);
    white-space: nowrap;
}

.discord-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(88,101,242,0.55);
}

.discord-btn svg { width: 22px; height: 22px; flex-shrink: 0; }

/* ── Docs Link ─────────────────────────────────────────── */
.docs-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.7rem 1.5rem;
    background: linear-gradient(135deg, var(--blue), var(--blue-light));
    color: #fff;
    text-decoration: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.93rem;
    transition: transform 0.2s, box-shadow 0.2s;
    margin-top: 1rem;
    box-shadow: 0 4px 14px rgba(26,79,138,0.35);
}

.docs-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(38,103,194,0.5);
}

/* ── Department Cards ──────────────────────────────────── */
.departments-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1.25rem;
}

.dept-card {
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    text-align: center;
    transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}

.dept-card:hover {
    transform: translateY(-4px);
    border-color: rgba(201,162,39,0.25);
    box-shadow: var(--shadow);
}

.dept-card h3 {
    font-family: 'Cinzel', serif;
    font-size: 1.15rem;
    color: var(--white);
    margin-bottom: 0.75rem;
}

.dept-card p { font-size: 0.93rem; color: var(--text-muted); line-height: 1.7; }

.dept-link {
    display: inline-block;
    margin-top: 1.25rem;
    padding: 0.6rem 1.5rem;
    background: linear-gradient(135deg, rgba(201,162,39,0.2), rgba(201,162,39,0.1));
    border: 1px solid rgba(201,162,39,0.35);
    color: var(--gold-light);
    text-decoration: none;
    border-radius: 20px;
    font-size: 0.88rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    transition: background 0.2s, transform 0.2s;
}

.dept-link:hover {
    background: linear-gradient(135deg, rgba(201,162,39,0.35), rgba(201,162,39,0.18));
    transform: scale(1.04);
}

/* ── Leader Cards (Ministry grid) ──────────────────────── */
.leaders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.25rem;
}

.leader-card {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    transition: transform 0.25s, border-color 0.25s;
}

.leader-card:hover {
    transform: translateY(-3px);
    border-color: rgba(201,162,39,0.25);
}

.leader-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid rgba(201,162,39,0.3);
    flex-shrink: 0;
}

.leader-avatar img { width: 100%; height: 100%; object-fit: cover; }

.leader-info { flex: 1; min-width: 0; }

.leader-role-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--gold);
    font-weight: 600;
    margin-bottom: 0.2rem;
}

.leader-name {
    font-family: 'Cinzel', serif;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--white);
    text-decoration: none;
    display: block;
    transition: color 0.2s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.leader-name:hover { color: var(--gold-light); }

.leader-alias {
    font-size: 0.83rem;
    color: var(--text-muted);
    font-style: italic;
}

/* ── Background Slideshow (WIP, Branch pages) ──────────── */
.background-image {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
    z-index: 0;
}

.background-image.active { opacity: 1; }

.background-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 1;
    transition: background 1.5s ease;
    opacity: 0.72;
}

/* For pages with background slideshow, content must be above overlay */
/* nav keeps its own position:sticky + z-index:1000 — only main-content needs raising */
body.has-slideshow .main-content { position: relative; z-index: 2; }
body.has-slideshow .wip-wrapper { position: relative; z-index: 2; }

/* ── WIP Page specific ─────────────────────────────────── */
.wip-wrapper {
    display: flex;
    flex: 1;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 62px);
    padding: 2rem;
}

.wip-card {
    text-align: center;
    padding: 3rem 2.5rem;
    max-width: 520px;
    width: 100%;
    background: rgba(11,22,41,0.8);
    border: 1px solid var(--border);
    border-radius: 20px;
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    box-shadow: 0 12px 48px rgba(0,0,0,0.5);
    position: relative;
    overflow: hidden;
}

.wip-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--orange), var(--gold), var(--blue-light));
}

.wip-icon {
    font-size: 4rem;
    margin-bottom: 1.25rem;
    animation: wipPulse 2.5s ease-in-out infinite;
    display: block;
}

@keyframes wipPulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.08); opacity: 0.8; }
}

.wip-card h1 {
    font-family: 'Cinzel', serif;
    font-size: 2rem;
    color: var(--white);
    margin-bottom: 0.75rem;
    letter-spacing: 0.04em;
}

.wip-card p {
    font-size: 1rem;
    color: var(--text);
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.wip-status {
    padding: 0.75rem 1.25rem;
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.wip-status strong { color: var(--gold-light); }

.progress-track {
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.08);
    border-radius: 2px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    width: 40%;
    background: linear-gradient(90deg, var(--orange), var(--gold));
    border-radius: 2px;
    animation: progressSweep 2s ease-in-out infinite;
}

@keyframes progressSweep {
    0% { transform: translateX(-100%); }
    50% { transform: translateX(200%); }
    100% { transform: translateX(-100%); }
}

/* ── Spinner ───────────────────────────────────────────── */
.spinner {
    border: 3px solid rgba(255,255,255,0.1);
    border-top-color: var(--gold-light);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    display: inline-block;
}

.spinner.sm { width: 20px; height: 20px; border-width: 2px; }
.spinner.md { width: 36px; height: 36px; }
.spinner.lg { width: 52px; height: 52px; border-width: 4px; }

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

.loading-block {
    text-align: center;
    padding: 3rem 2rem;
    color: var(--text-muted);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    font-size: 0.95rem;
}

/* ── Error Block ───────────────────────────────────────── */
.error-block {
    background: rgba(220,38,38,0.1);
    border: 1px solid rgba(220,38,38,0.3);
    border-radius: var(--radius);
    padding: 1.25rem;
    color: #fca5a5;
    text-align: center;
    font-size: 0.93rem;
}

/* ── Pulse Animation ───────────────────────────────────── */
.pulse {
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

/* ── Mobile ────────────────────────────────────────────── */
@media (max-width: 768px) {
    nav {
        padding: 0 1rem;
    }

    nav ul {
        height: auto;
        padding: 0.5rem 0;
        gap: 0.1rem;
    }

    nav a { font-size: 0.85rem; padding: 0.45rem 0.65rem; }

    .main-content { padding: 1.5rem 1rem; }

    .page-header { padding: 2rem 1.25rem 1.75rem; }

    .members-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; }

    .commander-card { flex-direction: column; text-align: center; }
    .commander-info { min-width: auto; }

    .cta-buttons { flex-direction: column; gap: 0.75rem; }
    .cta-btn { width: 100%; justify-content: center; }

    .departments-grid { grid-template-columns: 1fr; }

    .leaders-grid { grid-template-columns: 1fr; }

    .highlight-card .card-header { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 480px) {
    nav ul { justify-content: flex-start; overflow-x: auto; flex-wrap: nowrap; padding: 0.5rem 0; }
    .members-grid { grid-template-columns: 1fr 1fr; }
}
