/* ═══════════════════════════════════════════════════════════════
   BLINDSPOT.GG — Design System v2
   ═══════════════════════════════════════════════════════════════ */

:root {
    --bg-base:          #050e08;
    --bg-surface:       #0a1510;
    --bg-elevated:      #0f1c14;
    --bg-overlay:       #152118;

    /* Elevated surface aliases used by panels, chips & inputs */
    --surface-2:        #0f1c14;
    --surface-3:        #152118;

    /* Dark green */
    --primary:          #16A34A;
    --primary-dark:     #15803D;
    --primary-light:    #4ADE80;
    --primary-dim:      rgba(22,163,74,0.10);
    --primary-mid:      rgba(22,163,74,0.20);
    --primary-glow:     rgba(22,163,74,0.28);

    /* Amber gold — SPOT logo + achievements */
    --gold:             #F59E0B;
    --gold-bright:      #FCD34D;
    --gold-dim:         rgba(245,158,11,0.12);
    --gold-mid:         rgba(245,158,11,0.22);

    --text-primary:     #E8F5EC;
    --text-secondary:   rgba(232,245,236,0.55);
    --text-dim:         rgba(232,245,236,0.28);

    --border-subtle:    rgba(22,163,74,0.09);
    --border-mid:       rgba(22,163,74,0.20);
    --border-primary:   rgba(22,163,74,0.45);
    --border-gold:      rgba(245,158,11,0.22);

    --sidebar-w:        244px;
    --sidebar-mini:     64px;
    --topbar-h:         54px;
    --radius-sm:        6px;
    --radius-md:        10px;
    --radius-lg:        16px;
    --shadow-card:      0 4px 40px rgba(0,0,0,0.65);
    --shadow-glow:      0 0 40px rgba(22,163,74,0.22);
    --t:                0.22s ease;
}

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

html, body {
    margin: 0; padding: 0; height: 100%;
    background: var(--bg-base);
    font-family: 'Inter', sans-serif;
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Cinematic depth lighting */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        /* Primary: vivid purple bloom — top-left, like a light source */
        radial-gradient(ellipse 72% 58% at -8% -8%,   rgba(21,128,61,0.38)  0%, rgba(21,128,61,0.12) 45%, transparent 68%),
        /* Secondary: amber ember — bottom-right corner */
        radial-gradient(ellipse 52% 42% at 108% 108%, rgba(245,158,11,0.18)  0%, rgba(245,158,11,0.04) 45%, transparent 65%),
        /* Tertiary: soft violet haze — top-right */
        radial-gradient(ellipse 38% 32% at 96% 4%,    rgba(74,222,128,0.12) 0%, transparent 55%),
        /* Centre pulse: very subtle warmth */
        radial-gradient(ellipse 55% 45% at 52% 50%,   rgba(22,163,74,0.05)  0%, transparent 65%);
    pointer-events: none;
    z-index: 0;
}

/* Mesh grid overlay */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(22,163,74,0.048) 1px, transparent 1px),
        linear-gradient(90deg, rgba(22,163,74,0.048) 1px, transparent 1px);
    background-size: 52px 52px;
    pointer-events: none;
    z-index: 0;
}

/* Scrollbar */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(22,163,74,0.3); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(22,163,74,0.55); }

/* ── Blazor error UI ──────────────────────────────────────────── */
#blazor-error-ui {
    background: rgba(6,8,15,0.96);
    border-top: 1px solid var(--border-mid);
    bottom: 0; left: 0;
    padding: 12px 24px;
    position: fixed;
    width: 100%;
    z-index: 9999;
    color: var(--text-primary);
    display: none;
}
#blazor-error-ui .dismiss { cursor: pointer; color: var(--gold); float: right; }

/* ═══════════════════════════════════════════════════════════════
   SIDEBAR
   ═══════════════════════════════════════════════════════════════ */

/* ── Sidebar shell ─────────────────────────────────────────────── */
.bs-sidebar {
    position: fixed;
    left: 0; top: 0; bottom: 0;
    width: var(--sidebar-w);
    /* Rich dark gradient — deep green-tinted at top */
    background: linear-gradient(180deg,
        rgba(4, 14, 8,  0.97) 0%,
        rgba(3, 10, 6,  0.96) 50%,
        rgba(2,  8, 4,  0.97) 100%);
    backdrop-filter: blur(32px);
    -webkit-backdrop-filter: blur(32px);
    border-right: 1px solid rgba(22,163,74,0.16);
    box-shadow: 4px 0 48px rgba(0,0,0,0.55), inset -1px 0 0 rgba(22,163,74,0.06);
    display: flex;
    flex-direction: column;
    z-index: 200;
    transition: width var(--t);
    overflow: hidden;
}

/* Signature top-edge accent stripe */
.bs-sidebar::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg,
        transparent          0%,
        rgba(22,163,74,0.7) 20%,
        rgba(74,222,128,1)  50%,
        rgba(245,158,11,0.7) 78%,
        transparent          100%);
    z-index: 1;
    pointer-events: none;
}

.bs-sidebar.collapsed { width: var(--sidebar-mini); }

/* ── Logo ──────────────────────────────────────────────────────── */
.bs-sidebar__logo {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 20px 14px 18px;
    border-bottom: 1px solid rgba(22,163,74,0.07);
    min-height: var(--topbar-h);
    flex-shrink: 0;
    overflow: hidden;
    position: relative;
}

.bs-logo-mark {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: linear-gradient(135deg, #15803D 0%, #16A34A 55%, #A855F7 100%);
    display: flex; align-items: center; justify-content: center;
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.05rem;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
    box-shadow: 0 0 0 1px rgba(74,222,128,0.25), 0 4px 20px rgba(22,163,74,0.60);
    letter-spacing: 0;
}

.bs-logo-text {
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.18rem;
    font-weight: 700;
    letter-spacing: 2.5px;
    white-space: nowrap;
    overflow: hidden;
    line-height: 1;
}

.bs-logo-blind { color: var(--text-primary); }
.bs-logo-spot  { color: var(--gold); }
.bs-logo-gg    { color: rgba(245,158,11,0.38); font-size: 0.86rem; letter-spacing: 1px; }

/* ── Collapse toggle ───────────────────────────────────────────── */
.bs-sidebar__toggle {
    position: absolute;
    right: -13px;
    top: 23px;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #101828;
    border: 1px solid rgba(22,163,74,0.30);
    color: var(--text-secondary);
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    z-index: 210;
    transition: all var(--t);
    box-shadow: 0 2px 10px rgba(0,0,0,0.55);
}
.bs-sidebar__toggle:hover {
    background: rgba(22,163,74,0.22);
    border-color: var(--primary);
    color: var(--primary-light);
    box-shadow: 0 0 14px rgba(22,163,74,0.45);
}

/* ── Nav section label ─────────────────────────────────────────── */
.bs-nav-section {
    padding: 18px 14px 5px;
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 2.5px;
    color: var(--text-dim);
    text-transform: uppercase;
    white-space: nowrap;
    overflow: hidden;
    transition: opacity var(--t);
}
.bs-sidebar.collapsed .bs-nav-section { opacity: 0; }

/* ── Nav items ─────────────────────────────────────────────────── */
.bs-sidebar__nav {
    flex: 1;
    padding: 6px 10px;
    overflow-y: auto;
    overflow-x: hidden;
}
.bs-sidebar__nav::-webkit-scrollbar { display: none; }

.bs-nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 5px 10px 5px 5px;
    border-radius: 11px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.845rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--t);
    position: relative;
    margin-bottom: 3px;
    white-space: nowrap;
    border: 1px solid transparent;
}

.bs-nav-item:hover {
    background: rgba(22,163,74,0.09);
    color: var(--text-primary);
}

.bs-nav-item:hover .bs-nav-icon {
    background: rgba(22,163,74,0.18);
    border-color: rgba(22,163,74,0.34);
    color: var(--primary-light);
}

.bs-nav-item.active {
    background: linear-gradient(135deg, rgba(22,163,74,0.22) 0%, rgba(21,128,61,0.12) 100%);
    color: var(--primary-light);
    border-color: rgba(22,163,74,0.24);
}

/* Left glow bar — visible because overflow is not hidden on the item */
.bs-nav-item.active::after {
    content: '';
    position: absolute;
    left: 0; top: 18%; bottom: 18%;
    width: 2.5px;
    border-radius: 0 2px 2px 0;
    background: linear-gradient(180deg, var(--primary-light) 0%, var(--primary) 100%);
    box-shadow: 0 0 10px rgba(22,163,74,0.75);
}

.bs-nav-item.active .bs-nav-icon {
    background: rgba(22,163,74,0.28);
    border-color: rgba(22,163,74,0.52);
    color: var(--primary-light);
    box-shadow: 0 0 18px rgba(22,163,74,0.32);
}

/* Icon container — the key design element */
.bs-nav-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.07);
    flex-shrink: 0;
    transition: all var(--t);
    color: inherit;
}

.bs-nav-label {
    transition: opacity var(--t), width var(--t);
    font-weight: 500;
    overflow: hidden;
    letter-spacing: 0.15px;
}
.bs-sidebar.collapsed .bs-nav-label { opacity: 0; width: 0; }

/* ── User footer ───────────────────────────────────────────────── */
.bs-sidebar__footer {
    flex-shrink: 0;
    padding: 10px 10px 14px;
    border-top: 1px solid rgba(22,163,74,0.07);
    overflow: hidden;
}

.bs-user-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 8px;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    transition: all var(--t);
    cursor: default;
    overflow: hidden;
}

.bs-user-row:hover {
    background: rgba(22,163,74,0.07);
    border-color: rgba(22,163,74,0.12);
}

.bs-user-avatar {
    width: 34px; height: 34px;
    border-radius: 9px;
    background: linear-gradient(135deg, rgba(22,163,74,0.38) 0%, rgba(21,128,61,0.58) 100%);
    border: 1px solid rgba(22,163,74,0.48);
    display: flex; align-items: center; justify-content: center;
    font-family: 'Rajdhani', sans-serif;
    font-size: 1rem; font-weight: 700;
    color: var(--primary-light);
    flex-shrink: 0;
    box-shadow: 0 0 14px rgba(22,163,74,0.28);
}

.bs-user-info {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    transition: opacity var(--t), width var(--t);
}

.bs-user-name {
    font-size: 0.775rem;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bs-user-role {
    font-size: 0.65rem;
    color: var(--primary-light);
    font-weight: 600;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    opacity: 0.8;
}

.bs-sidebar.collapsed .bs-user-info { opacity: 0; width: 0; }

.bs-logout-btn {
    flex-shrink: 0;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-dim);
    display: flex; align-items: center; justify-content: center;
    padding: 5px;
    border-radius: 7px;
    transition: all var(--t);
}
.bs-logout-btn:hover { color: #F87171; background: rgba(248,113,113,0.12); }
.bs-sidebar.collapsed .bs-logout-btn { display: none; }

/* ═══════════════════════════════════════════════════════════════
   TOPBAR + MAIN LAYOUT
   ═══════════════════════════════════════════════════════════════ */

.bs-layout {
    margin-left: var(--sidebar-w);
    transition: margin-left var(--t);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

.bs-layout.sidebar-collapsed { margin-left: var(--sidebar-mini); }

.bs-topbar {
    position: sticky; top: 0; z-index: 100;
    height: var(--topbar-h);
    background: rgba(5,8,16,0.78);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(22,163,74,0.09);
    display: flex; align-items: center;
    padding: 0 28px;
    gap: 14px;
}

.bs-toggle-btn {
    background: none; border: none;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    padding: 7px;
    border-radius: var(--radius-sm);
    transition: all var(--t);
}
.bs-toggle-btn:hover { background: var(--primary-dim); color: var(--primary-light); }

.bs-content {
    flex: 1;
    padding: 36px 32px 64px;
    width: 100%;
}

/* ═══════════════════════════════════════════════════════════════
   MudBlazor overrides (purple-first)
   ═══════════════════════════════════════════════════════════════ */

.mud-table-root { background: transparent !important; }
.mud-table-container { background: transparent !important; }
.mud-table-body .mud-table-row:hover { background: var(--primary-dim) !important; }
.mud-table-body .mud-table-row { border-bottom: 1px solid rgba(22,163,74,0.06) !important; }
.mud-table-head .mud-table-cell { border-bottom: 1px solid var(--border-subtle) !important; }
.mud-input-outlined .mud-input-outlined-border { border-color: var(--border-mid) !important; }
.mud-input-outlined:hover .mud-input-outlined-border { border-color: rgba(22,163,74,0.42) !important; }
.mud-chip { font-family: 'Inter', sans-serif !important; font-weight: 500 !important; }
.mud-dialog { background: rgba(11,17,32,0.98) !important; border: 1px solid var(--border-mid) !important; border-radius: var(--radius-lg) !important; backdrop-filter: blur(20px) !important; }
.mud-dialog-title { border-bottom: 1px solid var(--border-subtle) !important; }
.mud-dialog-actions { border-top: 1px solid var(--border-subtle) !important; }
.mud-snackbar { border-radius: var(--radius-md) !important; }
.mud-button-root.mud-button-filled-primary { box-shadow: 0 2px 16px rgba(22,163,74,0.38) !important; }

/* ═══════════════════════════════════════════════════════════════
   PAGE HEADERS
   ═══════════════════════════════════════════════════════════════ */

.page-header { margin-bottom: 28px; }

.page-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.75rem; font-weight: 700; letter-spacing: 1px;
    color: var(--text-primary);
    margin: 0 0 4px; line-height: 1.2;
}

.page-subtitle {
    font-size: 0.82rem; color: var(--text-secondary); margin: 0;
}

/* ═══════════════════════════════════════════════════════════════
   DASHBOARD HERO
   ═══════════════════════════════════════════════════════════════ */

.dash-hero {
    background: linear-gradient(135deg, rgba(20,12,45,0.9) 0%, var(--bg-surface) 100%);
    border: 1px solid rgba(22,163,74,0.18);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    margin-bottom: 28px;
    position: relative;
    overflow: hidden;
}

.dash-hero::before {
    content: '';
    position: absolute;
    top: -60px; right: -60px;
    width: 220px; height: 220px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(22,163,74,0.18) 0%, rgba(22,163,74,0.05) 50%, transparent 70%);
    pointer-events: none;
}

.dash-hero::after {
    content: '';
    position: absolute;
    bottom: -20px; left: 30%;
    width: 160px; height: 80px;
    background: radial-gradient(ellipse, rgba(245,158,11,0.07) 0%, transparent 70%);
    pointer-events: none;
}

.dash-hero-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.9rem; font-weight: 700; letter-spacing: 1px;
    margin: 0 0 4px;
}

.dash-hero-sub { color: var(--text-secondary); font-size: 0.875rem; margin: 0; }

/* ═══════════════════════════════════════════════════════════════
   STAT CARDS
   ═══════════════════════════════════════════════════════════════ */

.stat-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 22px;
    transition: border-color var(--t), transform var(--t), box-shadow var(--t);
    position: relative; overflow: hidden; cursor: default;
}

.stat-card::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, var(--primary), transparent);
    opacity: 0; transition: opacity var(--t);
}

.stat-card:hover { border-color: rgba(22,163,74,0.35); transform: translateY(-3px); box-shadow: var(--shadow-glow); }
.stat-card:hover::before { opacity: 1; }

.stat-label {
    font-size: 0.68rem; font-weight: 700; letter-spacing: 2px;
    text-transform: uppercase; color: var(--text-dim); margin-bottom: 10px;
}

.stat-number {
    font-family: 'Rajdhani', sans-serif;
    font-size: 2.8rem; font-weight: 700; line-height: 1;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--primary-light) 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
    margin-bottom: 4px;
}

.stat-desc { font-size: 0.78rem; color: var(--text-secondary); }

.stat-icon-wrap {
    width: 44px; height: 44px; border-radius: var(--radius-md);
    background: var(--primary-dim); border: 1px solid var(--border-subtle);
    display: flex; align-items: center; justify-content: center;
    color: var(--primary);
}

.stat-icon-gold { background: var(--gold-dim); color: var(--gold); border-color: var(--border-gold); }

/* ═══════════════════════════════════════════════════════════════
   PANELS
   ═══════════════════════════════════════════════════════════════ */

.bs-panel {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.bs-panel-header {
    padding: 14px 20px;
    border-bottom: 1px solid var(--border-subtle);
    display: flex; align-items: center; justify-content: space-between;
}

.bs-panel-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.82rem; font-weight: 700; letter-spacing: 1.5px;
    color: var(--text-secondary); text-transform: uppercase;
}

.bs-empty { padding: 56px 24px; text-align: center; color: var(--text-dim); }
.bs-empty-icon { font-size: 2.5rem; opacity: 0.25; margin-bottom: 10px; }

/* ═══════════════════════════════════════════════════════════════
   TEAM CARDS
   ═══════════════════════════════════════════════════════════════ */

.team-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 18px 20px;
    transition: border-color var(--t), transform var(--t), box-shadow var(--t);
    cursor: default; position: relative; overflow: hidden;
}
.team-card:hover { border-color: var(--border-primary); transform: translateY(-2px); box-shadow: 0 8px 32px rgba(0,0,0,0.35); }

.team-avatar {
    width: 48px; height: 48px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, rgba(22,163,74,0.18), rgba(21,128,61,0.3));
    border: 1px solid rgba(22,163,74,0.3);
    display: flex; align-items: center; justify-content: center;
    font-family: 'Rajdhani', sans-serif; font-size: 1rem; font-weight: 700;
    color: var(--primary-light); letter-spacing: 1px; flex-shrink: 0;
}

.team-name { font-size: 0.95rem; font-weight: 600; color: var(--text-primary); margin: 0 0 2px; }
.team-meta { font-size: 0.78rem; color: var(--text-secondary); margin: 0; }

.team-tag-chip {
    display: inline-flex; align-items: center;
    padding: 1px 8px; border-radius: 4px;
    font-size: 0.68rem; font-weight: 700; letter-spacing: 1px;
    background: var(--gold-dim); color: var(--gold);
    border: 1px solid var(--border-gold);
    font-family: 'Rajdhani', sans-serif; text-transform: uppercase;
}

/* ═══════════════════════════════════════════════════════════════
   PLAYER CARDS
   ═══════════════════════════════════════════════════════════════ */

.player-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    transition: border-color var(--t), transform var(--t);
    display: flex; align-items: center; gap: 12px; cursor: default;
}
.player-card:hover { border-color: rgba(22,163,74,0.22); transform: translateX(3px); }

.player-role-badge {
    width: 38px; height: 38px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.72rem; font-weight: 700; flex-shrink: 0; letter-spacing: 0.5px;
}

.role-top     { background: rgba(248,113,113,0.14); color: #F87171; border: 1px solid rgba(248,113,113,0.3); }
.role-jungle  { background: rgba(52,211,153,0.14);  color: #34D399; border: 1px solid rgba(52,211,153,0.3); }
.role-mid     { background: rgba(22,163,74,0.16);  color: var(--primary-light); border: 1px solid var(--border-mid); }
.role-bottom  { background: rgba(251,191,36,0.14);  color: #FBBF24; border: 1px solid rgba(251,191,36,0.3); }
.role-support { background: rgba(244,114,182,0.14); color: #F472B6; border: 1px solid rgba(244,114,182,0.3); }
.role-default { background: var(--bg-elevated); color: var(--text-secondary); border: 1px solid var(--border-subtle); }

.player-name { font-size: 0.9rem; font-weight: 600; color: var(--text-primary); margin: 0 0 2px; }
.player-team { font-size: 0.75rem; color: var(--text-secondary); margin: 0; }

/* ═══════════════════════════════════════════════════════════════
   SCRIM ROWS
   ═══════════════════════════════════════════════════════════════ */

.scrim-row-item { transition: background var(--t); }
.scrim-row-item:hover { background: rgba(22,163,74,0.05); }
.scrim-row-item:last-child { border-bottom: none !important; }

.patch-badge {
    display: inline-flex; align-items: center;
    padding: 2px 9px; border-radius: 4px;
    font-size: 0.7rem; font-weight: 600; letter-spacing: 0.5px;
    background: var(--primary-dim); color: var(--primary-light);
    border: 1px solid var(--border-mid);
    font-family: 'Inter', monospace;
}

.game-count-badge {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 2px 9px; border-radius: 4px;
    font-size: 0.75rem; font-weight: 600;
    background: var(--bg-elevated); color: var(--text-secondary);
    border: 1px solid var(--border-subtle);
}

/* ═══════════════════════════════════════════════════════════════
   AUTH PAGES
   ═══════════════════════════════════════════════════════════════ */

.auth-root {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 460px;
    background: var(--bg-base);
}

@media (max-width: 880px) {
    .auth-root { grid-template-columns: 1fr; }
    .auth-brand { display: none; }
}

.auth-brand {
    position: relative;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    overflow: hidden; padding: 48px;
    background:
        radial-gradient(ellipse 80% 60% at 15% 25%, rgba(21,128,61,0.28) 0%, rgba(21,128,61,0.08) 45%, transparent 65%),
        radial-gradient(ellipse 55% 35% at 85% 80%, rgba(245,158,11,0.12) 0%, transparent 55%),
        var(--bg-base);
}

.auth-brand-grid {
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(22,163,74,0.055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(22,163,74,0.055) 1px, transparent 1px);
    background-size: 48px 48px;
}

.auth-brand-content { position: relative; z-index: 1; text-align: center; }

.auth-brand-logo {
    font-family: 'Rajdhani', sans-serif;
    font-size: 3.2rem; font-weight: 700; letter-spacing: 4px;
    margin-bottom: 14px; line-height: 1;
}

.auth-brand-tagline { font-size: 0.95rem; color: var(--text-secondary); max-width: 300px; line-height: 1.65; }

.auth-brand-features { margin-top: 44px; display: flex; flex-direction: column; gap: 14px; text-align: left; }

.auth-feature { display: flex; align-items: center; gap: 12px; color: var(--text-secondary); font-size: 0.875rem; }

.auth-feature-dot {
    width: 5px; height: 5px; border-radius: 50%;
    background: var(--primary); flex-shrink: 0;
    box-shadow: 0 0 8px var(--primary);
}

.auth-feature-dot.gold { background: var(--gold); box-shadow: 0 0 8px rgba(245,158,11,0.55); }

.auth-form-panel {
    background: rgba(4, 12, 7, 0.97);
    border-left: 1px solid var(--border-subtle);
    display: flex; align-items: center; justify-content: center;
    padding: 40px 48px;
    backdrop-filter: blur(12px);
}

.auth-form-inner { width: 100%; max-width: 360px; }

.auth-form-logo {
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.6rem; font-weight: 700; letter-spacing: 3px; margin-bottom: 8px;
}

.auth-form-title { font-size: 1.45rem; font-weight: 600; color: var(--text-primary); margin: 0 0 5px; }
.auth-form-sub { font-size: 0.85rem; color: var(--text-secondary); margin: 0 0 28px; }

hr.auth-divider { border: none; border-top: 1px solid var(--border-subtle); margin: 22px 0; }

/* ═══════════════════════════════════════════════════════════════
   SKELETON
   ═══════════════════════════════════════════════════════════════ */

@keyframes shimmer {
    0%   { background-position: -200% 0; }
    100% { background-position:  200% 0; }
}

.skeleton {
    background: linear-gradient(90deg,
        var(--bg-elevated) 25%, rgba(22,163,74,0.06) 50%, var(--bg-elevated) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.6s infinite;
    border-radius: var(--radius-sm);
}

/* ═══════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════ */

.btn-primary {
    font-family: 'Rajdhani', sans-serif !important;
    font-weight: 700 !important; font-size: 0.875rem !important;
    letter-spacing: 1px !important; border-radius: var(--radius-sm) !important;
}

.btn-ghost {
    background: transparent !important;
    border: 1px solid var(--border-mid) !important;
    color: var(--text-secondary) !important;
    font-family: 'Rajdhani', sans-serif !important;
    font-weight: 600 !important; letter-spacing: 0.5px !important;
    border-radius: var(--radius-sm) !important;
}
.btn-ghost:hover { border-color: var(--border-primary) !important; color: var(--primary-light) !important; }

/* ═══════════════════════════════════════════════════════════════
   LIGHT MODE  (applied when <html class="light">)
   ═══════════════════════════════════════════════════════════════ */

html.light {
    --bg-base:          #F0F7F3;
    --bg-surface:       #FFFFFF;
    --bg-elevated:      #F4FBF7;
    --bg-overlay:       #EAF4EE;

    --primary:          #16A34A;
    --primary-dark:     #15803D;
    --primary-light:    #15803D;   /* darker so it reads on white */
    --primary-dim:      rgba(22,163,74,0.08);
    --primary-mid:      rgba(22,163,74,0.16);
    --primary-glow:     rgba(22,163,74,0.18);

    --gold:             #D97706;
    --gold-bright:      #B45309;
    --gold-dim:         rgba(217,119,6,0.10);
    --gold-mid:         rgba(217,119,6,0.18);

    --text-primary:     #0F1F15;
    --text-secondary:   rgba(15,31,21,0.58);
    --text-dim:         rgba(15,31,21,0.36);

    --border-subtle:    rgba(22,163,74,0.10);
    --border-mid:       rgba(22,163,74,0.22);
    --border-primary:   rgba(22,163,74,0.48);
    --border-gold:      rgba(217,119,6,0.22);

    --shadow-card:      0 2px 20px rgba(0,0,0,0.07);
    --shadow-glow:      0 0 28px rgba(22,163,74,0.14);
}

/* Base */
html.light body { background: var(--bg-base); color: var(--text-primary); }

html.light body::before {
    background:
        radial-gradient(ellipse 72% 58% at -8% -8%,   rgba(22,163,74,0.12) 0%, transparent 65%),
        radial-gradient(ellipse 52% 42% at 108% 108%, rgba(245,158,11,0.08) 0%, transparent 55%),
        radial-gradient(ellipse 38% 32% at 96% 4%,    rgba(74,222,128,0.08) 0%, transparent 55%);
}

html.light body::after {
    background-image:
        linear-gradient(rgba(22,163,74,0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(22,163,74,0.06) 1px, transparent 1px);
}

html.light ::-webkit-scrollbar-thumb { background: rgba(22,163,74,0.25); }
html.light ::-webkit-scrollbar-thumb:hover { background: rgba(22,163,74,0.45); }

/* Sidebar */
html.light .bs-sidebar {
    background: linear-gradient(180deg, #FFFFFF 0%, #F6FBF8 100%);
    border-right-color: rgba(22,163,74,0.14);
    box-shadow: 4px 0 32px rgba(0,0,0,0.06), inset -1px 0 0 rgba(22,163,74,0.05);
}

html.light .bs-sidebar__logo { border-bottom-color: rgba(22,163,74,0.08); }

html.light .bs-logo-mark {
    box-shadow: 0 0 0 1px rgba(74,222,128,0.30), 0 4px 16px rgba(22,163,74,0.28);
}

html.light .bs-nav-section { color: rgba(15,31,21,0.35); }

html.light .bs-nav-item { color: rgba(15,31,21,0.58); }

html.light .bs-nav-item:hover { background: rgba(22,163,74,0.07); color: var(--text-primary); }

html.light .bs-nav-item:hover .bs-nav-icon {
    background: rgba(22,163,74,0.12);
    border-color: rgba(22,163,74,0.26);
    color: #15803D;
}

html.light .bs-nav-item.active {
    background: linear-gradient(135deg, rgba(22,163,74,0.13) 0%, rgba(21,128,61,0.07) 100%);
    color: #15803D;
    border-color: rgba(22,163,74,0.20);
}

html.light .bs-nav-item.active .bs-nav-icon {
    background: rgba(22,163,74,0.18);
    border-color: rgba(22,163,74,0.38);
    color: #15803D;
    box-shadow: 0 0 12px rgba(22,163,74,0.18);
}

html.light .bs-nav-icon {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.06);
    color: rgba(15,31,21,0.50);
}

html.light .bs-sidebar__toggle {
    background: #FFFFFF;
    border-color: rgba(22,163,74,0.24);
    color: rgba(15,31,21,0.50);
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
}

html.light .bs-sidebar__toggle:hover {
    background: rgba(22,163,74,0.10);
    border-color: #16A34A;
    color: #15803D;
    box-shadow: 0 0 10px rgba(22,163,74,0.22);
}

html.light .bs-sidebar__footer { border-top-color: rgba(22,163,74,0.08); }

html.light .bs-user-row:hover { background: rgba(22,163,74,0.06); border-color: rgba(22,163,74,0.12); }

html.light .bs-user-avatar {
    background: linear-gradient(135deg, rgba(22,163,74,0.22) 0%, rgba(21,128,61,0.38) 100%);
    border-color: rgba(22,163,74,0.35);
    color: #15803D;
    box-shadow: 0 0 10px rgba(22,163,74,0.14);
}

html.light .bs-user-name { color: #0F1F15; }
html.light .bs-user-role { color: #16A34A; }
html.light .bs-logout-btn:hover { background: rgba(220,38,38,0.08); }

/* Topbar */
html.light .bs-topbar {
    background: rgba(240,247,243,0.88);
    border-bottom-color: rgba(22,163,74,0.10);
}

/* Cards */
html.light .stat-card, html.light .team-card, html.light .player-card {
    background: #FFFFFF;
    border-color: rgba(22,163,74,0.10);
}

html.light .stat-card:hover { border-color: rgba(22,163,74,0.30); box-shadow: var(--shadow-glow); }
html.light .team-card:hover { border-color: rgba(22,163,74,0.28); box-shadow: 0 6px 24px rgba(0,0,0,0.06); }
html.light .player-card:hover { border-color: rgba(22,163,74,0.24); }

html.light .stat-label { color: rgba(15,31,21,0.42); }
html.light .stat-desc  { color: rgba(15,31,21,0.58); }

html.light .dash-hero {
    background: linear-gradient(135deg, rgba(22,163,74,0.06) 0%, #FFFFFF 70%);
    border-color: rgba(22,163,74,0.15);
}

/* Panels */
html.light .bs-panel { background: #FFFFFF; border-color: rgba(22,163,74,0.10); }
html.light .bs-panel-header { border-bottom-color: rgba(22,163,74,0.08); }

/* Auth */
html.light .auth-form-panel { background: rgba(255,255,255,0.97); border-left-color: rgba(22,163,74,0.10); }

/* Skeleton */
html.light .skeleton {
    background: linear-gradient(90deg, #F4FBF7 25%, rgba(22,163,74,0.06) 50%, #F4FBF7 75%);
    background-size: 200% 100%;
    animation: shimmer 1.6s infinite;
}

/* MudBlazor light overrides */
html.light .mud-dialog { background: #FFFFFF !important; }
html.light .mud-table-body .mud-table-row:hover { background: rgba(22,163,74,0.05) !important; }
html.light .mud-table-body .mud-table-row { border-bottom: 1px solid rgba(22,163,74,0.06) !important; }
html.light .mud-input-outlined .mud-input-outlined-border { border-color: rgba(22,163,74,0.22) !important; }
html.light .mud-button-root.mud-button-filled-primary { box-shadow: 0 2px 12px rgba(22,163,74,0.25) !important; }

/* Theme toggle button */
.bs-theme-toggle {
    display: flex; align-items: center; justify-content: center;
    width: 34px; height: 34px; border-radius: 8px;
    background: rgba(22,163,74,0.07); border: 1px solid rgba(22,163,74,0.16);
    color: var(--text-secondary); cursor: pointer; transition: all var(--t);
    flex-shrink: 0;
}
.bs-theme-toggle:hover { background: rgba(22,163,74,0.14); border-color: var(--primary); color: var(--primary-light); }
html.light .bs-theme-toggle { background: rgba(22,163,74,0.08); border-color: rgba(22,163,74,0.20); color: #15803D; }
html.light .bs-theme-toggle:hover { background: rgba(22,163,74,0.15); }

/* ═══════════════════════════════════════════════════════════════
   COACHING NOTES — Notion-style table + editor
   ═══════════════════════════════════════════════════════════════ */

/* ── Table ─────────────────────────────────────────────────────── */
.note-grid {
    display: grid;
    grid-template-columns: minmax(200px, 1.5fr) 130px 130px 84px 120px 110px 130px 56px;
    gap: 14px;
    align-items: center;
    padding: 11px 20px;
    min-width: 1000px;
}
.note-grid-head {
    border-bottom: 1px solid var(--border-gold);
    position: sticky; top: 0;
}
.note-row {
    border-bottom: 1px solid var(--border-subtle);
    cursor: pointer;
    transition: background var(--t);
}
.note-row:hover { background: rgba(245,158,11,0.04); }

.note-col-label {
    font-size: 0.62rem; letter-spacing: 1.5px; text-transform: uppercase;
    color: var(--gold); font-weight: 700;
}
.note-col-sort { cursor: pointer; user-select: none; }
.note-col-sort:hover { color: var(--gold-bright); }

.note-title-cell {
    font-weight: 600; font-size: 0.9rem; color: var(--text-primary);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.note-sub-cell { font-size: 0.72rem; color: var(--text-dim); margin-top: 2px; }
.note-text-cell {
    font-size: 0.82rem; color: var(--text-secondary);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.note-chip {
    display: inline-block; padding: 2px 9px; border-radius: 6px;
    font-size: 0.72rem; font-weight: 600; white-space: nowrap;
}

.note-goal-bar {
    flex: 1; height: 6px; min-width: 40px;
    background: var(--surface-3); border-radius: 3px; overflow: hidden;
}
.note-goal-fill {
    height: 100%; background: linear-gradient(90deg, rgba(245,158,11,0.7), var(--gold));
    border-radius: 3px; transition: width var(--t);
}

/* ── Editor ────────────────────────────────────────────────────── */
.note-editor { padding: 4px 2px; }

.note-editor-title {
    width: 100%; border: none; background: transparent;
    font-family: 'Rajdhani', sans-serif; font-size: 1.7rem; font-weight: 700;
    color: var(--text-primary); padding: 4px 0 10px; outline: none;
}
.note-editor-title::placeholder { color: var(--text-dim); }

.note-props {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 8px 18px; padding: 6px 0 14px;
    border-bottom: 1px solid var(--border-subtle); margin-bottom: 14px;
}
.note-prop { display: flex; align-items: center; gap: 8px; min-height: 30px; }
.note-prop label {
    display: flex; align-items: center; gap: 5px;
    font-size: 0.72rem; color: var(--text-secondary);
    width: 96px; flex-shrink: 0;
}
.note-prop-ic { font-size: 0.85rem !important; color: var(--text-dim); }
.note-prop-input {
    flex: 1; min-width: 0;
    background: var(--surface-2); border: 1px solid var(--border-subtle);
    border-radius: 6px; padding: 5px 9px;
    color: var(--text-primary); font-size: 0.82rem; font-family: 'Inter', sans-serif;
    outline: none; transition: border-color var(--t);
}
.note-prop-input:focus { border-color: var(--border-gold); }
.note-prop-input::placeholder { color: var(--text-dim); }
select.note-prop-input { cursor: pointer; }

.note-section-label {
    font-size: 0.78rem; font-weight: 700; color: var(--text-secondary);
    text-transform: uppercase; letter-spacing: 0.5px; margin: 14px 0 8px;
}

/* Goals checklist */
.note-goals { display: flex; flex-direction: column; gap: 4px; }
.note-goal-row { display: flex; align-items: center; gap: 9px; }
.note-goal-row input[type=checkbox] {
    width: 16px; height: 16px; accent-color: var(--gold); cursor: pointer; flex-shrink: 0;
}
.note-goal-text {
    flex: 1; background: transparent; border: none; border-bottom: 1px solid transparent;
    color: var(--text-primary); font-size: 0.86rem; padding: 4px 2px; outline: none;
    font-family: 'Inter', sans-serif;
}
.note-goal-text:focus { border-bottom-color: var(--border-gold); }
.note-goal-text.done { text-decoration: line-through; color: var(--text-dim); }
.note-add-goal {
    align-self: flex-start; margin-top: 4px;
    background: transparent; border: none; color: var(--text-dim);
    font-size: 0.8rem; cursor: pointer; padding: 4px 2px; font-family: 'Inter', sans-serif;
    transition: color var(--t);
}
.note-add-goal:hover { color: var(--gold); }

/* Body editor */
.note-mode-toggle { display: inline-flex; background: var(--surface-2); border-radius: 7px; padding: 2px; }
.note-mode-toggle button {
    border: none; background: transparent; color: var(--text-dim);
    font-size: 0.74rem; font-weight: 600; padding: 4px 12px; border-radius: 5px;
    cursor: pointer; font-family: 'Inter', sans-serif; transition: all var(--t);
}
.note-mode-toggle button.active { background: var(--gold); color: #000; }

.note-toolbar { display: flex; gap: 4px; margin-bottom: 8px; flex-wrap: wrap; }
.note-toolbar button {
    min-width: 30px; height: 30px; padding: 0 8px;
    background: var(--surface-2); border: 1px solid var(--border-subtle);
    border-radius: 6px; color: var(--text-secondary);
    font-size: 0.82rem; cursor: pointer; transition: all var(--t);
}
.note-toolbar button:hover { border-color: var(--border-gold); color: var(--gold); }

.note-md-editor {
    width: 100%; min-height: 220px; resize: vertical;
    background: var(--surface-2); border: 1px solid var(--border-subtle);
    border-radius: 8px; padding: 12px 14px;
    color: var(--text-primary); font-size: 0.88rem; line-height: 1.6;
    font-family: 'Inter', sans-serif; outline: none;
}
.note-md-editor:focus { border-color: var(--border-gold); }
.note-md-editor::placeholder { color: var(--text-dim); }

.note-md-preview {
    min-height: 220px; padding: 4px 2px; font-size: 0.9rem; line-height: 1.65;
    color: var(--text-primary);
}
.note-md-preview h1 { font-size: 1.4rem; font-weight: 700; margin: 14px 0 8px; font-family: 'Rajdhani', sans-serif; }
.note-md-preview h2 { font-size: 1.15rem; font-weight: 700; margin: 12px 0 6px; font-family: 'Rajdhani', sans-serif; }
.note-md-preview h3 { font-size: 1rem; font-weight: 700; margin: 10px 0 6px; }
.note-md-preview p { margin: 6px 0; }
.note-md-preview ul, .note-md-preview ol { margin: 6px 0; padding-left: 22px; }
.note-md-preview li { margin: 3px 0; }
.note-md-preview a { color: var(--gold); }
.note-md-preview code {
    background: var(--surface-3); padding: 1px 5px; border-radius: 4px;
    font-size: 0.85em; font-family: 'Consolas', monospace;
}
.note-md-preview blockquote {
    border-left: 3px solid var(--border-gold); margin: 8px 0; padding: 2px 0 2px 14px;
    color: var(--text-secondary);
}
.note-md-preview input[type=checkbox] { accent-color: var(--gold); margin-right: 6px; }
.note-md-preview table { border-collapse: collapse; margin: 8px 0; }
.note-md-preview th, .note-md-preview td {
    border: 1px solid var(--border-subtle); padding: 5px 10px; font-size: 0.85rem;
}

/* Note image attachments */
.note-goal-block { display: flex; flex-direction: column; gap: 4px; }
.note-attach-btn, .note-toolbar-file {
    display: inline-flex; align-items: center; justify-content: center;
    cursor: pointer; color: var(--text-dim); flex-shrink: 0;
    transition: color var(--t);
}
.note-attach-btn { width: 28px; height: 28px; border-radius: 6px; }
.note-attach-btn:hover, .note-toolbar-file:hover { color: var(--gold); }
.note-toolbar-file {
    min-width: 30px; height: 30px; padding: 0 8px;
    background: var(--surface-2); border: 1px solid var(--border-subtle); border-radius: 6px;
}
.note-toolbar-file:hover { border-color: var(--border-gold); }

.note-goal-thumb { position: relative; display: inline-block; margin: 2px 0 6px 27px; }
.note-goal-thumb img {
    max-width: 220px; max-height: 130px; border-radius: 8px;
    border: 1px solid var(--border-subtle); display: block;
}
.note-thumb-remove {
    position: absolute; top: -7px; right: -7px;
    width: 22px; height: 22px; border-radius: 50%;
    background: #1a1a1a; border: 1px solid var(--border-mid); color: #e74c3c;
    display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.note-thumb-remove:hover { background: #2a1010; }

.note-md-preview img { max-width: 100%; border-radius: 8px; margin: 8px 0; border: 1px solid var(--border-subtle); }

/* Team initials fallback badge (dashboard results & VODs) */
.bs-team-initials {
    display: inline-flex; align-items: center; justify-content: center;
    flex-shrink: 0; border-radius: 5px;
    background: linear-gradient(135deg, rgba(245,158,11,0.16), rgba(217,119,6,0.26));
    border: 1px solid var(--border-gold); color: var(--gold);
    font-family: 'Rajdhani', sans-serif; font-weight: 700;
    font-size: 0.58rem; letter-spacing: 0.5px; line-height: 1;
}

/* ── Notes: type tabs ─────────────────────────────────────────── */
.note-type-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.note-type-tab {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 6px 13px; border-radius: 8px; cursor: pointer;
    background: var(--surface-2); border: 1px solid var(--border);
    color: var(--text-secondary); font-size: 0.8rem; font-weight: 600;
    transition: border-color var(--t), color var(--t);
}
.note-type-tab:hover { border-color: var(--border-gold); color: var(--text-primary); }
.note-type-tab.active { border-color: var(--gold); color: var(--gold); background: rgba(245,158,11,0.08); }
.note-type-dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.note-type-count {
    font-size: 0.68rem; font-weight: 700; color: var(--text-dim);
    background: var(--surface-3); border-radius: 8px; padding: 1px 7px;
}
.note-type-tab.active .note-type-count { color: var(--gold); }

/* ── Notes: open action items panel ───────────────────────────── */
.note-actions-panel { padding-bottom: 4px; }
.note-actions-head {
    display: flex; align-items: center; gap: 8px; cursor: pointer;
    padding: 12px 16px; font-size: 0.85rem; font-weight: 700;
    letter-spacing: 0.4px; user-select: none;
}
.note-action-row {
    display: flex; align-items: center; gap: 10px;
    padding: 6px 16px 6px 18px; border-top: 1px solid var(--border);
}
.note-action-row:hover { background: rgba(245,158,11,0.04); }
.note-action-row input[type=checkbox] {
    width: 15px; height: 15px; accent-color: var(--gold); cursor: pointer; flex-shrink: 0;
}
.note-action-text {
    font-size: 0.83rem; color: var(--text-primary); cursor: pointer;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.note-action-src {
    font-size: 0.72rem; color: var(--text-dim); cursor: pointer;
    margin-left: auto; flex-shrink: 0; white-space: nowrap;
}

/* ── Notes: row snippet + templates ───────────────────────────── */
.note-snippet {
    font-size: 0.74rem; color: var(--text-dim); margin-top: 3px;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 520px;
}
.note-template-row {
    display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 12px;
}
.note-template-label {
    font-size: 0.7rem; letter-spacing: 1.2px; text-transform: uppercase;
    color: var(--text-dim); margin-right: 4px;
}
.note-template-chip {
    padding: 4px 11px; border-radius: 14px; cursor: pointer;
    background: var(--surface-2); border: 1px solid var(--border);
    color: var(--text-secondary); font-size: 0.75rem; font-weight: 600;
    transition: border-color var(--t), color var(--t);
}
.note-template-chip:hover { border-color: var(--gold); color: var(--gold); }

/* ── Auth splash: shown while the stored token is being validated ── */
.bs-auth-splash {
    position: fixed; inset: 0; z-index: 9999;
    background: var(--bg-base);
    display: flex; align-items: center; justify-content: center;
}
.bs-auth-splash-pulse { animation: bs-splash-pulse 1.1s ease-in-out infinite; }
@keyframes bs-splash-pulse {
    0%, 100% { opacity: 0.45; transform: scale(0.96); }
    50%      { opacity: 1;    transform: scale(1.04); }
}
