﻿/* SIDEBAR HUB CSS */
body {
    display: flex;
    overflow: hidden; /* Prevent body scroll */
}

.sidebar {
    width: 280px;
    background: var(--sidebar-bg);
    border-right: 1px solid var(--border);
    backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
    padding: 2rem 1.5rem;
    z-index: 1000;
    height: 100vh;
    overflow-y: auto;
    flex-shrink: 0;
    transition: background 0.3s ease, border-color 0.3s ease;
}

.brand {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text);
}

.brand-dot {
    width: 10px;
    height: 10px;
    background: var(--orange);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--orange);
}

.nav-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--muted);
    font-weight: 700;
    margin-bottom: 0.75rem;
    margin-top: 1.5rem;
}

.tab-btn {
    background: transparent;
    border: 1px solid transparent;
    color: var(--muted);
    padding: 0.75rem 1rem;
    border-radius: 12px;
    text-align: left;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin-bottom: 0.25rem;
    text-decoration: none;
}

.tab-btn:hover {
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
}

.tab-btn.active {
    background: var(--orange-glow);
    border-color: var(--orange-border);
    color: var(--orange);
}

.main-content {
    flex: 1;
    position: relative;
    height: 100vh;
    overflow-y: auto;
    overflow-x: hidden;
    scroll-behavior: smooth;
    background: transparent;
}

/* Hide all hub panels by default — only .hub-active shows (not .active; scroll-reveal uses .is-visible) */
.main-content > section:not(.hub-active):not(.email-capture-strip),
.main-content > .hero:not(.hub-active) {
    display: none !important;
}

.main-content > section.hub-active,
.main-content > .hero.hub-active {
    display: block !important;
    animation: premiumFadeIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Scroll-reveal must never flip a section visible */
.main-content > section.active:not(.hub-active),
.main-content > .hero.active:not(.hub-active) {
    display: none !important;
}

@keyframes premiumFadeIn {
    0% {
        opacity: 0;
        transform: translateY(16px) scale(0.985);
        filter: blur(8px);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* Email capture — always visible below hero */
.email-capture-strip {
    display: block !important;
    opacity: 1 !important;
    padding: 2rem 2rem 2.5rem;
    max-width: 720px;
    margin: 0 auto;
    text-align: center;
}
.email-capture-form {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
    align-items: center;
    margin-top: 1rem;
}
.email-capture-form label {
    width: 100%;
    font-size: 13px;
    font-weight: 700;
    color: var(--text);
    letter-spacing: 0.02em;
}
.email-capture-form input[type="email"] {
    flex: 1;
    min-width: 200px;
    max-width: 320px;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--bg2);
    color: var(--text);
    font-size: 14px;
}
.email-capture-form button {
    padding: 0.85rem 1.5rem;
    border-radius: 12px;
    border: none;
    background: var(--orange);
    color: #000;
    font-weight: 800;
    font-size: 14px;
    cursor: pointer;
}
.email-capture-form button:hover { filter: brightness(1.08); }
.email-capture-hint {
    font-size: 11px;
    color: var(--muted2);
    margin-top: 0.75rem;
}

/* Tier paywall — soft blur overlay */
.tier-gated .tier-gate-target {
    filter: blur(6px);
    pointer-events: none;
    user-select: none;
}
.tier-gate-overlay {
    position: absolute;
    inset: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: rgba(10, 10, 15, 0.55);
    backdrop-filter: blur(2px);
    border-radius: inherit;
}
.tier-gate-card {
    max-width: 400px;
    text-align: center;
    padding: 2rem;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
.tier-gate-card h3 { font-size: 1.25rem; font-weight: 800; margin-bottom: 0.5rem; }
.tier-gate-card p { font-size: 13px; color: var(--muted); line-height: 1.6; margin-bottom: 1.25rem; }
.price-card.tier-locked {
    filter: blur(4px);
    pointer-events: none;
    position: relative;
}
.price-card.tier-locked-wrap { position: relative; }
.price-card-tier-cta {
    position: absolute;
    inset: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(10, 10, 15, 0.5);
    border-radius: inherit;
}

/* Mobile sidebar */
.sidebar-toggle {
    display: none;
    position: fixed;
    top: 1rem;
    left: 1rem;
    z-index: 1101;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--sidebar-bg);
    color: var(--text);
    font-size: 1.25rem;
    cursor: pointer;
    align-items: center;
    justify-content: center;
}
.sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 999;
}
body.sidebar-open .sidebar-backdrop { display: block; }
@media (max-width: 768px) {
    .sidebar-toggle { display: flex; }
    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        transform: translateX(-100%);
        transition: transform 0.25s ease;
        box-shadow: 4px 0 24px rgba(0,0,0,0.3);
    }
    body.sidebar-open .sidebar { transform: translateX(0); }
    .main-content { width: 100%; }
    body { overflow-x: hidden; }
    section table {
        display: block;
        width: 100%;
    }
    .table-scroll-wrap,
    section div[style*="min-width"] {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .email-capture-form { flex-direction: column; }
    .email-capture-form input[type="email"] { max-width: 100%; width: 100%; }
}

/* Hide original top nav, sticky tab bar, dividers */
nav:not(.sidebar) { display: none !important; }
#tab-bar { display: none !important; }
.divider { display: none !important; }
footer { display: none !important; }
/* Hub account / magic-link sign-in */
.hub-auth-panel {
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.hub-signin-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.hub-signin-form input[type="email"] {
    width: 100%;
    box-sizing: border-box;
    padding: 0.55rem 0.75rem;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: rgba(0, 0, 0, 0.25);
    color: var(--text);
    font-size: 12px;
}

.hub-signin-btn {
    width: 100%;
    padding: 0.55rem 0.75rem !important;
    font-size: 11px !important;
    justify-content: center;
}

.hub-auth-hint {
    font-size: 10px;
    color: var(--muted2);
    margin: 0.5rem 0 0;
    line-height: 1.4;
}

.hub-auth-email {
    font-size: 11px;
    color: var(--muted);
    margin: 0 0 0.25rem;
    word-break: break-all;
}

.hub-auth-tier {
    font-size: 11px;
    font-weight: 800;
    color: var(--orange);
    margin: 0 0 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.hub-signout-btn {
    width: 100%;
    text-align: center;
    font-size: 11px !important;
    padding: 0.5rem !important;
}

/* Membership & Pricing Styles */
.upgrade-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.85);
    backdrop-filter: blur(10px);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.upgrade-overlay.active {
    display: flex;
}

.upgrade-content {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 32px;
    padding: 3rem;
    max-width: 600px;
    width: 100%;
    text-align: center;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5);
    position: relative;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.price-card {
    background: var(--bg2);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: all 0.3s ease;
    text-align: left;
}

.price-card:hover {
    border-color: var(--muted);
}

.price-card.featured {
    border: 2px solid var(--orange);
    background: rgba(247, 147, 26, 0.03);
    transform: translateY(-10px);
}

.price-card h3 {
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    color: var(--text);
}

.price-card .amount {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: var(--text);
}

.price-card .amount span {
    font-size: 1rem;
    color: var(--muted);
}

.price-card ul {
    list-style: none;
    padding: 0;
    margin-bottom: 2rem;
    flex-grow: 1;
}

.price-card ul li {
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.85rem;
    color: var(--muted);
}

.price-card ul li::before {
    content: '✓';
    margin-right: 10px;
    color: var(--success);
    font-weight: 800;
}

.price-card .badge {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: var(--orange);
    color: #000;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    text-transform: uppercase;
}

.close-btn {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: transparent;
    border: none;
    color: var(--muted);
    font-size: 1.5rem;
    cursor: pointer;
}

/* VIP Premium Effects */
.vip-card {
    box-shadow: 0 0 40px rgba(255, 215, 0, 0.05);
    overflow: hidden;
    border: 1px solid #ffd700 !important;
}

.vip-card::before {
    content: '';
    position: absolute;
    top: -100%;
    left: -100%;
    width: 300%;
    height: 300%;
    background: linear-gradient(
        45deg,
        transparent,
        rgba(255, 215, 0, 0.08),
        transparent
    );
    transform: rotate(45deg);
    animation: shimmer 8s infinite linear;
    pointer-events: none;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

.vip-features li {
    border-bottom: 1px solid rgba(255, 215, 0, 0.1) !important;
    color: #ffd700 !important;
}

/* ── Interactive Command Deck Styles ── */
#interactive-command-deck {
    perspective: 1000px;
}

#category-grid, #category-details {
    will-change: transform, opacity;
}

.command-cat-card {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                border-color 0.4s ease, 
                box-shadow 0.4s ease, 
                background-color 0.4s ease !important;
    position: relative;
    border-radius: 24px !important;
    border: 1px solid var(--border) !important;
    background: rgba(255, 255, 255, 0.02) !important;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 200px;
}

.command-cat-card:hover {
    transform: translateY(-8px) scale(1.02) !important;
    background: rgba(255, 255, 255, 0.04) !important;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 30px var(--orange-glow) !important;
    border-color: var(--orange-border) !important;
}

.command-cat-card:hover .card-icon {
    transform: scale(1.2) rotate(5deg);
}

.command-cat-card .cat-pill {
    transition: all 0.3s ease;
    align-self: flex-start;
}

.command-cat-card:hover .cat-pill {
    background: var(--orange) !important;
    color: #000 !important;
    transform: translateX(4px);
}

/* Tool Launch Cards */
.tool-launch-card {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                border-color 0.4s ease, 
                box-shadow 0.4s ease, 
                background-color 0.4s ease !important;
    border-radius: 20px !important;
    border: 1px solid var(--border) !important;
    background: rgba(255, 255, 255, 0.015) !important;
    position: relative;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 180px;
    padding: 1.5rem;
}

.tool-launch-card:hover {
    transform: translateY(-5px) scale(1.02) !important;
    background: rgba(255, 255, 255, 0.04) !important;
    border-color: var(--orange-border) !important;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3), 0 0 20px var(--orange-glow) !important;
}

.tool-launch-card:hover .tool-icon {
    transform: scale(1.25) rotate(-5deg);
}

.tool-launch-card .launch-action {
    color: var(--orange);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: all 0.3s ease;
    margin-top: 1rem;
}

.tool-launch-card:hover .launch-action {
    color: var(--text);
    transform: translateX(5px);
}

/* Lock/Access Badges */
.access-badge {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    font-size: 9px;
    font-weight: 800;
    padding: 0.25rem 0.55rem;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid transparent;
}

.access-badge.free {
    background: rgba(34,197,94,0.1) !important;
    color: var(--success) !important;
    border-color: rgba(34,197,94,0.2) !important;
}

.access-badge.pro {
    background: var(--orange-glow) !important;
    color: var(--orange) !important;
    border-color: var(--orange-border) !important;
}

.access-badge.vip {
    background: rgba(168,85,247,0.1) !important;
    color: var(--music) !important;
    border-color: var(--music-border) !important;
}

/* Saylor OS V4 Shared Variables & Classes */
:root {
  --primary-glow: rgba(247, 147, 26, 0.25);
  --primary-dark: var(--orange-dim);
  --primary-muted: var(--orange-glow);
  --primary: var(--orange);
  --radius-sm: var(--r-sm);
  --radius-md: var(--r);
  --radius-lg: 20px;
  --shadow: 0 24px 48px -20px rgba(0, 0, 0, 0.75);
  --shadow-card-hover: 0 28px 56px -22px rgba(0, 0, 0, 0.85);
  --modal-scrim: rgba(9, 9, 15, 0.85);
  --surface-muted: rgba(255, 255, 255, 0.03);
  --border-accent: var(--orange-border);
  --border-bright: var(--border2);
  --text-muted: var(--muted);
}
html[data-theme="light"] {
  --surface-muted: rgba(0, 0, 0, 0.03);
  --modal-scrim: rgba(244, 239, 230, 0.82);
}
html[data-theme="cyberpunk"] {
  --surface-muted: rgba(255, 0, 255, 0.03);
  --modal-scrim: rgba(15, 0, 26, 0.82);
}
html[data-theme="zen"] {
  --surface-muted: rgba(44, 62, 45, 0.03);
  --modal-scrim: rgba(245, 245, 240, 0.82);
}

.subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 3rem;
}

/* Grid Layouts */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 2rem;
}

.col-4 { grid-column: span 4; }
.col-5 { grid-column: span 5; }
.col-6 { grid-column: span 6; }
.col-7 { grid-column: span 7; }
.col-8 { grid-column: span 8; }
.col-12 { grid-column: span 12; }

/* Custom UI Elements */
.stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 500;
    font-family: 'DM Mono', ui-monospace, monospace;
    color: var(--text);
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
}

.stat-trend {
    font-size: 0.85rem;
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    gap: 4px;
}

.trend-up { color: var(--success); }
.trend-down { color: var(--danger); }

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.text-muted {
    color: var(--text-muted);
}

.status-pill {
    display: inline-block;
    border-radius: 999px;
    font-weight: 600;
    letter-spacing: 0.04em;
}

/* Form Error & Toast */
.form-error {
    display: none;
    font-size: 0.8rem;
    color: var(--danger);
    padding: 0.65rem 0.85rem;
    border-radius: var(--radius-md);
    border: 1px solid rgba(244, 63, 94, 0.25);
    background: rgba(244, 63, 94, 0.08);
}

.form-error.is-visible {
    display: block;
}

.toast {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 2000;
    max-width: min(380px, calc(100vw - 2rem));
    padding: 0.85rem 1.1rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: var(--bg2);
    color: var(--text);
    box-shadow: var(--shadow-card-hover);
    font-size: 0.88rem;
    font-weight: 500;
    opacity: 0;
    transform: translateY(12px);
    pointer-events: none;
    transition: opacity 0.35s ease, transform 0.35s ease;
}

.toast.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Supply landscape (who holds BTC) */
.supply-intro {
    max-width: 52rem;
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    line-height: 1.65;
}

.story-banner {
    border-left: 4px solid var(--orange);
    margin-bottom: 2rem !important;
    background: linear-gradient(90deg, rgba(247, 147, 26, 0.07), transparent) !important;
    padding: 1.75rem !important;
    border-radius: var(--radius-md) !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}
html[data-theme="light"] .story-banner {
    background: linear-gradient(90deg, rgba(247, 147, 26, 0.08), rgba(255, 255, 255, 0.4)) !important;
    border-left-color: var(--orange) !important;
    box-shadow: 0 4px 15px rgba(139, 126, 116, 0.05);
}

.supply-pie-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0 1rem;
}

.supply-pie-svg {
    width: min(100%, 320px);
    height: auto;
    filter: drop-shadow(0 12px 28px rgba(0, 0, 0, 0.35));
}

body.lite-mode .supply-pie-svg {
    filter: drop-shadow(0 8px 20px rgba(15, 23, 42, 0.12));
}

.supply-pie-center-title {
    fill: var(--text);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.supply-pie-center-sub {
    fill: var(--text-muted);
    font-size: 9px;
    font-weight: 500;
}

.supply-legend-rows {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.supply-legend-row {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    padding: 0.85rem 0;
    border-bottom: 1px solid var(--border);
}

.supply-legend-row:last-child {
    border-bottom: none;
}

.supply-swatch {
    width: 11px;
    height: 11px;
    border-radius: 3px;
    flex-shrink: 0;
    margin-top: 0.35rem;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.2);
}

body.lite-mode .supply-swatch {
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.5);
}

.supply-legend-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text);
    letter-spacing: -0.01em;
}

.supply-legend-btc-row {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary);
    margin-top: 0.2rem;
    letter-spacing: -0.02em;
}

.supply-legend-btc-row .btc-compact {
    font-weight: 500;
    color: var(--text-muted);
    margin-left: 0.35rem;
    font-size: 0.76rem;
}

.supply-legend-sub {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 0.2rem;
    line-height: 1.45;
}

.corporate-strategy-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.strategy-card {
    padding: 1.25rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.02);
}

.strategy-card.featured {
    border-color: var(--border-accent);
    background: linear-gradient(145deg, rgba(234, 154, 40, 0.1), rgba(255, 255, 255, 0.02));
}

.strategy-tier-title {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: baseline;
    margin-bottom: 0.85rem;
}

.strategy-btc {
    font-size: 1.65rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    color: var(--primary);
}

.strategy-role {
    font-size: 0.68rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.strategy-metric-row {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.5rem 0;
    border-top: 1px solid var(--border);
    font-size: 0.78rem;
}

/* Modals */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    align-items: center;
    justify-content: center;
    background: var(--modal-scrim);
    backdrop-filter: blur(14px);
    z-index: 1000;
    padding: 1rem;
}

.modal-panel {
    width: 400px;
    max-width: 100%;
    border-top: 4px solid var(--primary);
}

.modal-overlay.is-open {
    display: flex;
}

body.modal-open {
    overflow: hidden !important;
}

.philosophy-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.quote-card blockquote {
    font-style: italic;
    font-size: 1.1rem;
    line-height: 1.8;
    margin: 0;
}

.quote-card cite {
    display: block;
    margin-top: 2rem;
    font-size: 0.75rem;
    font-weight: 600;
    font-style: normal;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.field-input,
.field-select {
    width: 100%;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 0.75rem;
    border-radius: var(--radius-md);
    font-size: 1rem;
}

.field-input:focus-visible,
.field-select:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Slider Custom Inputs */
input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    background: var(--border2);
    height: 6px;
    border-radius: 3px;
    outline: none;
}
input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    box-shadow: 0 0 10px var(--primary-glow);
    transition: transform 0.1s;
}
input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

/* Traffic Command dashboard */
#traffic-command .section-sub,
#traffic-command .traffic-meta,
#traffic-command p {
    color: var(--text);
    opacity: 0.92;
}

#traffic-command #traffic-range {
    color: var(--text);
    background: var(--bg3);
    border: 1px solid var(--border);
}

.traffic-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.25rem;
}

.traffic-stat.glass-card {
    overflow: visible !important;
    min-height: 108px;
    padding: 1.5rem 1.25rem 1.35rem !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-align: center;
}

.traffic-stat.glass-card > * {
    position: relative;
    z-index: 1;
}

.traffic-stat-val {
    font-size: 2.5rem;
    font-weight: 900;
    line-height: 1.15;
    color: var(--orange);
    margin: 0;
    padding: 0;
}

.traffic-stat-label {
    font-size: 12px;
    font-weight: 700;
    color: var(--text);
    text-transform: uppercase;
    margin: 0;
    letter-spacing: 0.6px;
    line-height: 1.4;
    max-width: 140px;
}

html[data-theme="light"] #traffic-command .traffic-stat-label,
html[data-theme="light"] #traffic-command .traffic-label,
html[data-theme="light"] #traffic-command .traffic-meta,
html[data-theme="light"] #traffic-command h4 {
    color: #2c261f;
}

html[data-theme="light"] #traffic-command .traffic-stat-val {
    color: #c2410c;
}

html[data-theme="light"] #traffic-command .traffic-bar-track {
    background: rgba(0, 0, 0, 0.08);
}

#traffic-command .glass-card h4 {
    color: var(--text);
    font-weight: 800;
}

.traffic-bars {
    display: flex;
    flex-direction: column;
    gap: 1.15rem;
}

.traffic-row-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.4rem;
}

.traffic-label {
    font-size: 14px;
    font-weight: 800;
    color: var(--text);
    text-transform: capitalize;
}

.traffic-meta {
    font-size: 12px;
    font-weight: 600;
    color: var(--muted);
}

.traffic-bar-track {
    height: 10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.traffic-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--orange), #fbbf24);
    border-radius: 8px;
    transition: width 0.4s ease;
}

.traffic-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.traffic-pill {
    font-size: 13px;
    font-weight: 600;
    padding: 0.45rem 0.85rem;
    border-radius: 999px;
    background: rgba(14, 165, 233, 0.15);
    border: 1px solid rgba(14, 165, 233, 0.35);
    color: var(--text);
}

.traffic-pill strong {
    color: #0ea5e9;
    margin-left: 4px;
}
