/* tokens.css — single source of truth for colors, fonts, spacing.
   Dark is the default (:root). Light overrides live in [data-theme="light"].
   Loaded BEFORE base.css. */
:root {
    /* =========================================================================
       SURFACES — existing (§2.1)
       ========================================================================= */
    --bg: #0a0a0a;
    --bg-elevated: #111111;
    --bg-tertiary: #1a1a1a;
    --bg-input: #0d0d0d;

    /* Elevated surface greys (high-frequency in feature CSS — see Task 3) */
    --surface-1: #161616;   /* #161616 x8 */
    --surface-2: #181818;   /* #181818 x11 */
    --surface-3: #1f1f1f;   /* #1f1f1f x9 */
    --surface-4: #2a2a2a;   /* #2a2a2a x35 — most common raised border/card */
    --surface-5: #3a3a3a;   /* #3a3a3a x7 */
    --hairline: #333333;    /* #333 / #333333 borders */
    --text-mute: #6a6a6a;   /* #6a6a6a x11 — dimmer than --text-dim */

    /* =========================================================================
       SURFACES — new near-palette neutrals (§2.2)
       ========================================================================= */
    --bg-void: #050505;              /* deepest black: modal scrims base, intro */
    --surface-0: #141414;            /* just-above-bg (#131313/#141414/#151513 collapsed) */
    --surface-6: #404040;            /* light grey raised (#404040/#444/#2e2e2e/#232323) */
    --scrim: rgba(0, 0, 0, 0.6);     /* modal/overlay backdrop */
    --scrim-deep: rgba(0, 0, 0, 0.85); /* heavy overlay (loaders, intro) */
    --shadow-soft: rgba(0, 0, 0, 0.2);  /* drop shadow light */
    --shadow-mid: rgba(0, 0, 0, 0.3);   /* drop shadow medium */
    --shadow-strong: rgba(0, 0, 0, 0.45); /* drop shadow deep */

    /* =========================================================================
       ACCENT — Antique Amber (§2.4 existing + new)
       ========================================================================= */
    --accent: #FFBF00;
    --accent-rgb: 255, 191, 0;  /* for rgba(var(--accent-rgb), a) */
    --accent-dim: rgba(255, 191, 0, 0.6);
    --accent-glow: rgba(255, 191, 0, 0.15);
    --accent-subtle: rgba(255, 191, 0, 0.08);
    /* Recurring amber alphas that exceed the "3+ occurrences" rule (Task 3 Step 2) */
    --accent-faint: rgba(255, 191, 0, 0.05);   /* covers 0.04 x10 + 0.05 x8 */
    --accent-soft: rgba(255, 191, 0, 0.18);    /* 0.18 x6 */
    --accent-strong: rgba(255, 191, 0, 0.4);   /* covers 0.35 x8 + 0.4 x6 */
    --accent-bright: #ffd54f;                  /* amber hover/highlight (#ffd766/#ffd040 family) */
    --accent-mid: rgba(255, 191, 0, 0.3);      /* mid amber alpha (0.25-0.32) */
    --accent-half: rgba(255, 191, 0, 0.5);     /* half amber (0.45-0.55) */
    --accent-heavy: rgba(255, 191, 0, 0.8);    /* heavy amber (0.65-0.9) */
    --accent-deep: #5a4500;                    /* dark-amber decorative (eyebrow seps, dots) */

    /* =========================================================================
       GOLD — Antique brass chrome (§2.4 new)
       ========================================================================= */
    --gold-antique: #d4a853;                        /* muted brass chrome accent */
    --gold-antique-bright: #e8c068;                 /* brass hover */
    --gold-antique-glow: rgba(212, 168, 83, 0.15);  /* brass glow */
    --gold-antique-soft: rgba(212, 168, 83, 0.08);  /* brass faint tint */
    --gold-line: rgba(212, 168, 83, 0.12);          /* brass hairline */
    --gold-line-bright: rgba(212, 168, 83, 0.25);   /* brass hairline bright */
    --gold-antique-rgb: 212, 168, 83;               /* triplet for rgba() alpha variants */
    --bronze: #dbb778;                              /* warm bronze entity/diff text */
    --bronze-rgb: 219, 183, 120;                   /* triplet for bronze alpha tints */

    /* =========================================================================
       TEXT (§2.3 existing + new)
       ========================================================================= */
    --text: #c4c4c4;
    --text-dim: #8c8c8c;
    --text-bright: #d0ccc2;
    --text-light: #d4d4d4;   /* near-white text on dark cards */
    --text-faint: #6a6a6a;   /* disabled/ghost text — do NOT use for live text */

    /* =========================================================================
       BORDERS / LINES (§2.6 existing + new)
       ========================================================================= */
    --border: rgba(255, 191, 0, 0.2);
    --border-dim: rgba(255, 191, 0, 0.1);
    --border-mid: rgba(255, 191, 0, 0.3);          /* amber border mid (0.25-0.3) */
    --ink-line: rgba(235, 230, 220, 0.08);          /* parchment-ink hairline */
    --ink-line-strong: rgba(235, 230, 220, 0.18);   /* ink hairline stronger */
    --white-line: rgba(255, 255, 255, 0.06);        /* neutral white hairline */
    --white-line-strong: rgba(255, 255, 255, 0.16); /* white hairline stronger */
    --grey-line: rgba(140, 140, 140, 0.3);          /* neutral grey alpha hairline */
    --grey-line-rgb: 140, 140, 140;                /* triplet for grey-line text alpha variants */
    --white-rgb: 255, 255, 255;                     /* for rgba(var(--white-rgb), a) */

    /* =========================================================================
       STATUS (§2.5 existing + new)
       ========================================================================= */
    --error: #ff6b6b;
    --error-rgb: 255, 107, 107;                     /* triplet for error alpha tints */
    --danger-strong: #e74c3c;                       /* solid danger fill/border/button */
    --danger-muted: #c45c4a;                        /* desaturated red chrome (game/SZ/CC) */
    --danger-rgb: 196, 92, 74;                      /* triplet for danger alpha tints */
    --warning: #ffaa00;
    --warn-orange: #ff8c42;                         /* orange warn text/icon/border */
    --warn-orange-rgb: 255, 140, 66;                /* triplet for warn-orange tints */
    --success: #4ade80;                             /* success/active/added text and fill */
    --success-rgb: 74, 222, 128;                    /* triplet for success tints */
    --info: #60a5fa;                                /* informational blue (admin email-status) */
    --info-rgb: 96, 165, 250;                       /* triplet for info tints */

    /* Links (markdown in chat transcript) */
    --link: var(--accent);

    /* =========================================================================
       COMPONENT CANVAS — Game / Session-Zero / Character-Creator (§2.7)
       ========================================================================= */
    --canvas-bg: #0d0d0c;
    --canvas-elevated: #151513;
    --canvas-panel: #121210;
    --canvas-input: #0a0a09;
    --ink: rgba(235, 230, 220, 0.9);
    --ink-secondary: rgba(235, 230, 220, 0.6);
    --ink-hint: rgba(235, 230, 220, 0.35);
    --ink-bright: #ebe6dc;
    --ink-rgb: 235, 230, 220;                       /* for rgba(var(--ink-rgb), a) */
    --copper: #5a9a8a;
    --copper-glow: rgba(90, 154, 138, 0.2);
    --copper-rgb: 90, 154, 138;                     /* for rgba(var(--copper-rgb), a) */

    /* =========================================================================
       COMPONENT — Dice CRT palette (§2.8) — kept as named family, add light in [data-theme]
       ========================================================================= */
    --dice-success: #00ff85;
    --dice-success-dim: rgba(0, 255, 133, 0.1);
    --dice-success-glow: rgba(0, 255, 133, 0.3);
    --dice-success-rgb: 0, 255, 133;               /* for rgba(var(--dice-success-rgb), a) */
    --dice-fail: #ff4444;
    --dice-fail-dim: rgba(255, 68, 68, 0.1);
    --dice-fail-glow: rgba(255, 68, 68, 0.3);
    --dice-fail-rgb: 255, 68, 68;                  /* for rgba(var(--dice-fail-rgb), a) — matches --dice-fail */
    --dice-crit: #ff6b00;
    --dice-crit-glow: rgba(255, 107, 0, 0.4);
    --dice-crit-rgb: 255, 107, 0;                  /* for rgba(var(--dice-crit-rgb), a) */
    --dice-amber-glow: rgba(212, 168, 83, 0.3);
    --dice-amber-dim: rgba(212, 168, 83, 0.12);
    --dice-hairline: rgba(212, 168, 83, 0.07);
    --dice-bg-card: #141414;
    --dice-line: #222222;
    --dice-line-bright: #333333;
    --dice-muted: #555555;
    --dice-dim: #8c8c8c;

    /* =========================================================================
       MISC / ONE-OFF (§2.10)
       ========================================================================= */
    --pure-white: #ffffff;
    --pure-black: #000000;
    --dark-blue-bg: #1a1a2e;                        /* decorative dark-blue card bg */
    /* Hero carousel — a dark media banner in BOTH themes (text must stay legible
       over arbitrary cover images and the no-image fallback). Intentionally NOT
       overridden in [data-theme="light"], so it does not flip to dark-on-dark. */
    --hero-fg: #f4f1e8;
    --hero-fg-dim: #d4d0c4;
    --hero-fallback-bg: #1a1814;
    --hero-scrim-from: rgba(0, 0, 0, 0.82);
    --hero-scrim-to: rgba(0, 0, 0, 0.10);
    --brown-warm: #3a3120;                          /* warm brown decorative near-black */
    --mute-grey: #909090;                           /* misc mid-grey text */

    /* Decorative (dialed down in light mode) */
    --noise-opacity: 0.04;

    /* =========================================================================
       COMPONENT ALIASES — --game-* / --sz-* / --cc-* (§3.12)
       These are `:root`-level aliases so they are NOT shadowed by scoped defs.
       The scoped definition blocks in game.css/session-zero.css/character-creator.css
       have been REMOVED — these are now the only definitions.
       ========================================================================= */
    /* Backgrounds */
    --game-bg: var(--canvas-bg);
    --sz-bg: var(--canvas-bg);
    --cc-bg: var(--canvas-bg);
    --game-bg-elevated: var(--canvas-elevated);
    --sz-bg-elevated: var(--canvas-elevated);
    --cc-bg-elevated: var(--canvas-elevated);
    --game-bg-panel: var(--canvas-panel);
    --sz-bg-panel: var(--canvas-panel);
    --cc-bg-panel: var(--canvas-panel);
    --game-bg-input: var(--canvas-input);
    --sz-bg-input: var(--canvas-input);
    --cc-bg-input: var(--canvas-input);
    /* Text */
    --game-text: var(--ink);
    --sz-text: var(--ink);
    --cc-text: var(--ink);
    --game-text-secondary: var(--ink-secondary);
    --sz-text-secondary: var(--ink-secondary);
    --cc-text-secondary: var(--ink-secondary);
    --game-text-hint: var(--ink-hint);
    --sz-text-hint: var(--ink-hint);
    --cc-text-hint: var(--ink-hint);
    --game-text-bright: var(--ink-bright);
    --sz-text-bright: var(--ink-bright);
    --cc-text-bright: var(--ink-bright);
    /* Dim text variants (legacy aliases used in game.css / character-creator.css) */
    --game-text-dim: var(--ink-secondary);
    --game-dim: var(--ink-hint);
    --cc-text-main: var(--ink);
    --cc-text-dim: var(--ink-secondary);
    /* Gold/amber */
    --game-amber: var(--gold-antique);
    --sz-amber: var(--gold-antique);
    --cc-amber: var(--gold-antique);
    --game-amber-bright: var(--gold-antique-bright);
    --sz-amber-bright: var(--gold-antique-bright);
    --cc-amber-bright: var(--gold-antique-bright);
    --game-amber-glow: var(--gold-antique-glow);
    --sz-amber-glow: var(--gold-antique-glow);
    --cc-amber-glow: var(--gold-antique-glow);
    --game-amber-soft: var(--gold-antique-soft);
    --sz-amber-soft: var(--gold-antique-soft);
    --cc-amber-soft: var(--gold-antique-soft);
    /* Copper */
    --game-copper: var(--copper);
    --sz-copper: var(--copper);
    --cc-copper: var(--copper);
    --game-copper-glow: var(--copper-glow);
    --sz-copper-glow: var(--copper-glow);
    /* Lines and borders */
    --game-line: var(--gold-line);
    --sz-line: var(--gold-line);
    --cc-line: var(--gold-line);
    --game-line-bright: var(--gold-line-bright);
    --sz-line-bright: var(--gold-line-bright);
    --cc-line-bright: var(--gold-line-bright);
    --game-border: var(--ink-line);
    --sz-border: var(--ink-line);
    --cc-border: var(--ink-line);
    /* Status aliases */
    --game-confirmed: var(--copper);
    --sz-confirmed: var(--copper);
    --game-pending: var(--gold-antique);
    --sz-pending: var(--gold-antique);
    --game-error: var(--danger-muted);
    --sz-error: var(--danger-muted);
    --cc-error: var(--danger-muted);
    --game-red: var(--danger-muted);
    /* Green neon */
    --game-green: var(--dice-success);
    --sz-green: var(--dice-success);
    --cc-green: var(--dice-success);
    /* Tool-call line */
    --tool-call-line-color: var(--gold-line);

    /* =========================================================================
       COMPONENT — --model-picker-* (§2.9 / §3.12)
       The .model-picker/.model-picker-modal scoped block in components.css
       has been REMOVED. These replace it.
       NOTE: four values are kept as their OWN literals (not aliased) because the
       catalogue's shared-token targets drifted from the original dark values; the
       modal must render byte-identical in dark mode. Their light values are in
       [data-theme="light"]. The other four are byte-identical to their shared
       tokens and stay as aliases.
       ========================================================================= */
    --model-picker-bg: rgba(0, 0, 0, 0.35);              /* literal: --scrim drifts to 0.6 */
    --model-picker-border: rgba(235, 230, 220, 0.16);    /* literal: --ink-line-strong drifts to 0.18 */
    --model-picker-input-border: rgba(235, 230, 220, 0.22); /* literal: --ink-line-strong drifts to 0.18 */
    --model-picker-text: var(--ink-bright);
    --model-picker-muted: rgba(235, 230, 220, 0.5);      /* literal: --ink-secondary drifts to 0.6 */
    --model-picker-accent: var(--gold-antique);
    --model-picker-option-bg: var(--canvas-bg);
    --model-picker-option-text: var(--ink);

    /* =========================================================================
       BRAND FONTS (fixed, app-wide)
       ========================================================================= */
    --font-ui-brand: 'Courier New', Courier, monospace;
    --font-reading-brand: 'Cormorant Garamond', Georgia, serif;

    /* Selected typography (consumed only inside .typography-scope).
       Defaults ARE the "Scribe" vibe (IBM Plex Mono UI + Cormorant reading), so
       the [data-vibe="scribe"] block below need not restate them. Note --font-ui
       differs from --font-ui-brand: brand chrome stays Courier, Scribe UI is IBM Plex. */
    --font-ui: 'IBM Plex Mono', 'Courier New', monospace;
    --font-reading: var(--font-reading-brand);
    --font-scale: 1;
    --line-height-reading: 1.6;
    --font-size-reading-base: 1.1rem;  /* current .message.game-style.dm size */
    --font-size-ui-base: 0.9rem;       /* player/input message tier (game/sz/cc) */
    --font-size-system-base: 0.8rem;   /* system/meta message tier (sz/cc) */

    /* =========================================================================
       SPACING (moved from base.css :root)
       ========================================================================= */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 15px;
    --spacing-lg: 20px;
    --spacing-xl: 30px;

    /* Mobile-specific spacing (moved from base.css :root) */
    --spacing-mobile-xs: 8px;
    --spacing-mobile-sm: 12px;
    --spacing-mobile-md: 16px;
    --spacing-mobile-lg: 24px;

    /* Touch targets (moved from base.css :root) */
    --touch-target-min: 44px;

    /* Viewport height fix — updated via JavaScript (moved from base.css :root) */
    --vh: 1vh;

    /* Border radius (moved from base.css :root) */
    --radius-sm: 4px;
    --radius-md: 6px;
    --radius-lg: 12px;

    /* Transitions (moved from base.css :root) */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.2s ease;
    --transition-slow: 0.3s ease;

    /* Typography minimum sizes (moved from base.css :root) */
    --font-min-narrative: 1rem;      /* 16px - Cormorant Garamond narrative text */
    --font-min-interface: 0.7rem;    /* 11.2px - IBM Plex Mono interface text */
    --font-min-react-hud: 0.55rem;   /* 8.8px - ReAct HUD phases */

    /* =========================================================================
       NEO-SCRIBE ALIASES (unified from blog.css/legal.css/dashboard.css :root blocks)
       These map the old --neo-* names to the canonical tokens so per-page files
       need no local :root and no values change.
       ========================================================================= */
    --neo-obsidian: var(--bg);
    --neo-obsidian-light: var(--bg-elevated);
    --neo-obsidian-lighter: var(--bg-tertiary);
    --neo-amber: var(--accent);
    --neo-amber-dim: var(--accent-dim);
    --neo-amber-glow: var(--accent-glow);
    --neo-amber-subtle: var(--accent-subtle);
    --neo-amber-bright: var(--accent-bright);    /* was #ffd54f literal — now canonical */
    --neo-text: var(--text);
    --neo-text-dim: var(--text-dim);             /* unified to #8c8c8c — AA fix for blog/legal */
    --neo-text-bright: var(--text-bright);
    --neo-border: var(--border);
    --neo-border-dim: var(--border-dim);
}

/* =============================================================================
   LIGHT THEME — [data-theme="light"]
   Overrides every token defined with a literal value in :root that should
   change in light mode. Aliases (var(--x)) auto-follow their canonical token
   and do NOT need to be listed here again.
   §5b overrides applied: --text-mute=#6b6657, --ink-hint=rgba(42,39,34,0.6)
   ============================================================================= */
[data-theme="light"] {
    /* =========================================================================
       SURFACES (§2.1 + §2.2)
       ========================================================================= */
    --bg: #f1ede3;
    --bg-elevated: #f9f6ed;
    --bg-tertiary: #ece8df;
    --bg-input: #fbf8f1;
    --surface-1: #f9f6ee;
    --surface-2: #f5f1e7;
    --surface-3: #f0ede5;
    --surface-4: #e6e2d8;
    --surface-5: #d8d3c6;
    --hairline: #cfc9ba;
    --bg-void: #ece8df;
    --surface-0: #f3efe5;
    --surface-6: #cdc7b8;
    --scrim: rgba(40, 36, 28, 0.45);
    --scrim-deep: rgba(40, 36, 28, 0.72);
    --shadow-soft: rgba(60, 54, 40, 0.10);
    --shadow-mid: rgba(60, 54, 40, 0.16);
    --shadow-strong: rgba(60, 54, 40, 0.24);

    /* =========================================================================
       TEXT (§2.3)
       ========================================================================= */
    --text: #2a2722;
    --text-dim: #5f5a4f;
    --text-bright: #15130f;
    --text-mute: #6b6657;     /* §5b override: 5.0:1, safe on tertiary surfaces */
    --text-light: #2a2722;    /* maps to body text in light */
    --text-faint: #8a8475;    /* disabled/ghost only — 3.3:1, AA-exempt for disabled */

    /* =========================================================================
       ACCENT / AMBER (§2.4)
       ========================================================================= */
    --accent: #7a5c00;
    --accent-rgb: 122, 92, 0;
    --accent-dim: rgba(122, 92, 0, 0.7);
    --accent-glow: rgba(122, 92, 0, 0.10);
    --accent-subtle: rgba(122, 92, 0, 0.06);
    --accent-faint: rgba(122, 92, 0, 0.05);
    --accent-soft: rgba(122, 92, 0, 0.16);
    --accent-strong: rgba(122, 92, 0, 0.30);
    --accent-bright: #6f5400;                  /* light: hover/highlight darkens (AA 5.8:1 on canvas) */
    --accent-mid: rgba(122, 92, 0, 0.26);
    --accent-half: rgba(122, 92, 0, 0.5);
    --accent-heavy: rgba(122, 92, 0, 0.8);
    --accent-deep: #c9b88a;

    /* =========================================================================
       GOLD — Antique brass (§2.4)
       ========================================================================= */
    --gold-antique: #74591a;                        /* light: AA 5.4:1 on canvas for entity-link text */
    --gold-antique-bright: #5f4a16;                 /* light: hover darkens (AA 6.9:1), inverted from dark mode */
    --gold-antique-glow: rgba(116, 89, 26, 0.12);
    --gold-antique-soft: rgba(116, 89, 26, 0.07);
    --gold-line: rgba(116, 89, 26, 0.16);
    --gold-line-bright: rgba(116, 89, 26, 0.30);
    --gold-antique-rgb: 116, 89, 26;
    --bronze: #8a5a28;
    --bronze-rgb: 138, 90, 40;                     /* triplet for bronze alpha tints */

    /* =========================================================================
       STATUS (§2.5)
       ========================================================================= */
    --error: #c0392b;
    --error-rgb: 192, 57, 43;
    --danger-strong: #c0392b;
    --danger-muted: #a8412f;
    --danger-rgb: 168, 65, 47;
    --warning: #8a5e00;
    --warn-orange: #9a5a00;
    --warn-orange-rgb: 154, 90, 0;
    --success: #1e7a3c;
    --success-rgb: 30, 122, 60;
    --info: #2563c4;
    --info-rgb: 37, 99, 196;

    /* =========================================================================
       BORDERS / LINES (§2.6)
       ========================================================================= */
    --border: rgba(122, 92, 0, 0.28);
    --border-dim: rgba(122, 92, 0, 0.14);
    --border-mid: rgba(122, 92, 0, 0.34);
    --ink-line: rgba(60, 54, 40, 0.12);
    --ink-line-strong: rgba(60, 54, 40, 0.22);
    --white-line: rgba(0, 0, 0, 0.06);
    --white-line-strong: rgba(0, 0, 0, 0.12);
    --grey-line: rgba(80, 76, 66, 0.3);
    --grey-line-rgb: 80, 76, 66;                   /* triplet for grey-line text alpha variants */
    --white-rgb: 0, 0, 0;

    /* =========================================================================
       COMPONENT CANVAS (§2.7)
       ========================================================================= */
    --canvas-bg: #efebe1;
    --canvas-elevated: #f9f6ed;
    --canvas-panel: #ece8dd;
    --canvas-input: #fbf8f1;
    --ink: rgba(42, 39, 34, 0.92);
    --ink-secondary: rgba(42, 39, 34, 0.7);
    --ink-hint: rgba(42, 39, 34, 0.6);     /* §5b override: alpha 0.6 not 0.55 */
    --ink-bright: #15130f;
    --ink-rgb: 60, 54, 40;
    --copper: #2f7565;
    --copper-glow: rgba(47, 117, 101, 0.16);
    --copper-rgb: 47, 117, 101;

    /* =========================================================================
       DICE CRT PALETTE — light values (§2.8)
       Neon values are darkened for AA readability on light surfaces.
       ========================================================================= */
    --dice-success: #07703c;
    --dice-success-dim: rgba(7, 112, 60, 0.12);
    --dice-success-glow: rgba(7, 112, 60, 0.22);
    --dice-success-rgb: 7, 112, 60;
    --dice-fail: #c0392b;
    --dice-fail-dim: rgba(192, 57, 43, 0.12);
    --dice-fail-glow: rgba(192, 57, 43, 0.22);
    --dice-fail-rgb: 192, 57, 43;
    --dice-crit: #a84a00;
    --dice-crit-glow: rgba(168, 74, 0, 0.3);
    --dice-crit-rgb: 168, 74, 0;
    --dice-amber-glow: rgba(116, 89, 26, 0.26);
    --dice-amber-dim: rgba(116, 89, 26, 0.16);
    --dice-hairline: rgba(116, 89, 26, 0.10);
    --dice-bg-card: #f7f5ef;
    --dice-line: #d8d3c6;
    --dice-line-bright: #cfc9ba;
    --dice-muted: #8a8475;
    --dice-dim: #5f5a4f;

    /* =========================================================================
       MISC / ONE-OFF (§2.10)
       ========================================================================= */
    --pure-white: #15130f;     /* white-on-white vanishes in light — map to ink */
    --pure-black: #15130f;
    --dark-blue-bg: #e4e6f0;
    --brown-warm: #e8e2d4;
    --mute-grey: #6b6658;
    --noise-opacity: 0.015;    /* dialed down for light parchment */

    /* =========================================================================
       MODEL-PICKER — light values for the four non-aliased literals (§2.9)
       The other four model-picker vars are aliases and auto-follow.
       ========================================================================= */
    --model-picker-bg: rgba(40, 36, 28, 0.30);
    --model-picker-border: rgba(60, 54, 40, 0.16);
    --model-picker-input-border: rgba(60, 54, 40, 0.22);
    --model-picker-muted: rgba(42, 39, 34, 0.66);
}

/* =============================================================================
   VIBE FONT PAIRINGS — swap --font-ui / --font-reading per selected vibe.
   Consumed only inside .typography-scope (applied by Task 11).
   Default (scribe) is already set in :root above; not redefined here.
   ============================================================================= */
[data-vibe="terminal"]   { --font-reading: 'IBM Plex Mono', monospace; --font-ui: 'IBM Plex Mono', monospace; }
[data-vibe="manuscript"] { --font-reading: 'Lora', Georgia, serif; --font-ui: 'IBM Plex Mono', monospace; }
[data-vibe="plain"]      { --font-reading: 'Atkinson Hyperlegible', sans-serif; --font-ui: 'Atkinson Hyperlegible', sans-serif; }

/* =============================================================================
   BACK-COMPAT ALIASES — so existing var(--*-color) usages keep resolving while
   files are migrated incrementally. Remove in the final guardrail task once
   no file references the old names.
   ============================================================================= */
:root {
    --bg-color: var(--bg);
    --bg-secondary: var(--bg-elevated);
    --accent-color: var(--accent);
    --text-color: var(--text);
    --border-color: var(--border);
    --error-color: var(--error);
    --warning-color: var(--warning);
    --success-color: var(--success);
    --text-main: var(--text);
    --bg-primary: var(--bg);
    --input-bg: var(--bg-input);
}
