/* ============================================================
   MV FUND — BLOOMBERG TERMINAL THEME (site-wide)
   Loaded last in every page's <head>; overrides each page's
   design tokens. Approved from the dashboard preview 2026-08-27.
   ============================================================ */

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

:root,
html[data-theme="dark"],
html[data-theme="light"] {
    --bg-primary: #000000 !important;
    --bg-secondary: #0a0a0a !important;
    --bg-card: #0d0d0d !important;
    --bg-darker: #060606 !important;       /* weekend cells / sub-headers on 8 pages; was undefined → light-mode #e8e8ea leaked under light text */
    --bg-hover: #1a1a1a !important;
    --bg-input: #101010 !important;
    --border: #2b2b2b !important;
    --border-light: #3a3a3a !important;
    --text-primary: #e8e8e8 !important;
    --text-secondary: #b0b0b0 !important;
    --text-muted: #8a8a8a !important;
    --text-dim: #b0b0b0 !important;
    --gold: #ff8c00 !important;            /* Bloomberg amber */
    --gold-rgb: 255, 140, 0 !important;    /* rgba(var(--gold-rgb), a) follows the session */
    --gold-hover: #ffa733 !important;
    --gold-bg: rgba(255, 140, 0, 0.12) !important;
    --green: #00e653 !important;           /* terminal up-tick */
    --green-dark: #00c247 !important;
    --green-bg: rgba(0, 230, 83, 0.10) !important;
    --red: #ff433d !important;             /* terminal down-tick */
    --red-dark: #e02f29 !important;
    --red-bg: rgba(255, 67, 61, 0.10) !important;
    --yellow: #ffd75e !important;
    --yellow-bg: rgba(255, 215, 94, 0.10) !important;
    --blue: #4aa8ff !important;
    --blue-bg: rgba(74, 168, 255, 0.10) !important;
    --cyan: #00d5ff !important;
    --orange: #ff8c00 !important;
    --orange-bg: rgba(255, 140, 0, 0.10) !important;
    --purple: #c792ea !important;
    --purple-bg: rgba(199, 146, 234, 0.10) !important;
    --rose: #ff6e8a !important;
    --rose-bg: rgba(255, 110, 138, 0.10) !important;
    --emerald: #00e6a8 !important;
    --emerald-bg: rgba(0, 230, 168, 0.10) !important;
    --sky: #38cfff !important;
    --sky-bg: rgba(56, 207, 255, 0.10) !important;
    --meet-blue: #4aa8ff !important;
    --meet-blue-bg: rgba(74, 168, 255, 0.12) !important;
}

/* Terminal typography + flat chrome */
body, body * {
    font-family: 'JetBrains Mono', 'Consolas', monospace !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

/* Icon fonts must keep their own face or glyphs break */
.ti, [class^="ti-"], [class*=" ti-"] {
    font-family: 'tabler-icons' !important;
}

html, body { background: var(--bg-primary) !important; }

/* Panel/section headers → amber terminal bars */
.ic-header, .col-header, .rp-title, .reminders-section-title,
.card-title, .section-title, .panel-title {
    color: var(--gold) !important;
    text-transform: uppercase !important;
    letter-spacing: 0.08em !important;
    font-weight: 600 !important;
    border-bottom: 1px solid var(--gold) !important;
    padding-bottom: 4px !important;
}

/* Buttons: squared, uppercase function-key feel */
button, .s-chip, .mv-confirm-btn {
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
}

::selection { background: var(--gold); color: var(--bg-primary); }
*::-webkit-scrollbar-thumb { background: var(--border-light) !important; }
*::-webkit-scrollbar-track { background: var(--bg-primary) !important; }

/* Shared nav: black bar with amber rule */
nav, .mv-nav, #mv-nav {
    background: var(--bg-primary) !important;
    border-bottom: 2px solid var(--gold) !important;
}

/* ============================================================
   MARKET-SESSION SKINS — attribute stamped by /session-theme.js
   (loaded in <head> just before this file). Approved 2026-09-09.
     rth  → nothing here: the amber tokens above stay byte-identical
     eth  → "Night Ops"  ice blue on blue-black   (Mon–Fri outside 09:30–16:00 ET)
     wkd  → "Steel"      silver on cold graphite  (Fri 17:00 → Sun 18:00 ET)
   Same specificity as the html[data-theme] blocks above; later wins.
   ============================================================ */
html[data-session="eth"] {
    --bg-primary: #03060c !important;
    --bg-secondary: #070b14 !important;
    --bg-card: #0a1020 !important;
    --bg-darker: #050812 !important;
    --bg-hover: #121a2c !important;
    --bg-input: #0a0f1c !important;
    --border: #1e2a40 !important;
    --border-light: #2a3a55 !important;
    --text-primary: #dce6f5 !important;
    --text-secondary: #9fb0c8 !important;
    --text-muted: #6f7f99 !important;
    --text-dim: #9fb0c8 !important;
    --gold: #5cb8ff !important;            /* Night Ops ice blue */
    --gold-rgb: 92, 184, 255 !important;
    --accent-gold: #5cb8ff !important;     /* legacy token on ~28 pages (scrollbar hovers, chips) */
    --gold-hover: #8fd0ff !important;
    --gold-bg: rgba(92, 184, 255, 0.12) !important;
    --orange: #5cb8ff !important;
    --orange-bg: rgba(92, 184, 255, 0.10) !important;
    --blue: #00d5ff !important;            /* info blue moves to cyan so it stays distinct from the accent */
    --blue-bg: rgba(0, 213, 255, 0.10) !important;
    --meet-blue: #00d5ff !important;
    --meet-blue-bg: rgba(0, 213, 255, 0.12) !important;
}

html[data-session="wkd"] {
    --bg-primary: #070809 !important;
    --bg-secondary: #0c0e10 !important;
    --bg-card: #111418 !important;
    --bg-darker: #0a0c0f !important;
    --bg-hover: #1b1f25 !important;
    --bg-input: #0e1114 !important;
    --border: #2a2f37 !important;
    --border-light: #3a414c !important;
    --text-primary: #e2e6ea !important;
    --text-secondary: #a9b1bb !important;
    --text-muted: #737c88 !important;
    --text-dim: #a9b1bb !important;
    --gold: #c9d3dd !important;            /* Steel silver */
    --gold-rgb: 201, 211, 221 !important;
    --accent-gold: #c9d3dd !important;
    --gold-hover: #e3eaf1 !important;
    --gold-bg: rgba(201, 211, 221, 0.12) !important;
    --orange: #c9d3dd !important;
    --orange-bg: rgba(201, 211, 221, 0.10) !important;
}

/* Session badge (injected into nav.js's .nav-right by /session-theme.js) */
.mv-session-badge {
    display: flex; align-items: center; gap: 7px; flex-shrink: 0;
    margin-right: 10px; padding: 3px 9px;
    border: 1px solid var(--gold); color: var(--gold); background: var(--gold-bg);
    font-size: 11px; font-weight: 700; letter-spacing: 0.08em; white-space: nowrap;
    cursor: default; user-select: none;
}
.mv-session-badge i { width: 7px; height: 7px; background: currentColor; display: inline-block; }
.mv-session-badge[data-session="rth"] i { animation: mv-session-blink 1.6s steps(2, start) infinite; }
@keyframes mv-session-blink { to { visibility: hidden; } }
@media (prefers-reduced-motion: reduce) { .mv-session-badge i { animation: none !important; } }
