/* ============================================================
   WIRE & HERALDRY — design tokens.
   A Maryland election-night wire desk: scoreboard numerals, ledger-dense data,
   and the state flag's heraldry (Calvert gold/black, Crossland red/white) as the
   one decorative motif. Party hues are DATA and never double as brand color.
   Switch via <html data-theme="night|broadsheet|civic">.
   ============================================================ */

:root {
  --font-display: "Big Shoulders Display", "Arial Narrow", sans-serif;   /* headlines + big numbers */
  --font-body: "Schibsted Grotesk", "Helvetica Neue", sans-serif;       /* UI + reading */
  --font-mono: "Martian Mono", ui-monospace, monospace;                 /* tabular data, times */
  --font-serif: "Instrument Serif", Georgia, serif;                     /* one italic accent */

  /* heraldry (fixed, decorative only) */
  --flag-gold: #e9a91c;
  --flag-black: #0b0b0a;
  --flag-red: #c8102e;
  --flag-white: #f6f3ea;

  --oth: #8a8678;
  --r-sm: 2px; --r-md: 3px; --r-lg: 4px;
  --maxw: 1280px;
  --ease: cubic-bezier(.2,.8,.2,1);
  --t-fast: .14s; --t-med: .42s;
  --rule: 3px;
  --header-h: 107px;          /* sticky masthead height; sticky sub-bars sit below it */
}

/* ---------- ELECTION NIGHT (default): warm ink, bone, Calvert gold ---------- */
[data-theme="night"] {
  --bg: #0b0c0a;
  --bg-elev: #141613;
  --bg-sunk: #070806;
  --ink: #f3efe4;
  --ink-soft: #b8b2a3;
  --ink-faint: #8a856f;
  --line: #262822;
  --line-strong: #3c3f35;
  --accent: #f2b318;           /* Calvert gold */
  --accent-ink: #0b0c0a;       /* text on accent fills */
  --accent-2: #d9cfb4;
  --gold: #f2b318;
  --dem: #3d8ff5;              /* validated vs #141613: lightness, CVD, contrast */
  --rep: #f04a40;
  --good: #3ccf8e;
  --grain-opacity: .07;
  --shadow: 0 1px 0 rgba(255,255,255,.03), 0 18px 40px -22px rgba(0,0,0,.9);
  --header-bg: rgba(11,12,10,.9);
  color-scheme: dark;
}

/* ---------- PAPER (broadsheet): newsprint, deep ink, burnished gold ---------- */
[data-theme="broadsheet"] {
  --bg: #f3eee2;
  --bg-elev: #fbf7ee;
  --bg-sunk: #e8e1d0;
  --ink: #14130f;
  --ink-soft: #5f584a;
  --ink-faint: #6f6756;
  --line: #d6cdb8;
  --line-strong: #b3a88e;
  --accent: #8a6400;           /* text-safe gold (4.6:1 on paper) */
  --accent-ink: #fbf7ee;
  --accent-2: #3a3428;
  --gold: #c98f0c;
  --dem: #1f5fa6;
  --rep: #b32b22;
  --good: #2f6f4f;
  --grain-opacity: .045;
  --shadow: 0 1px 0 rgba(20,19,15,.04), 0 16px 32px -22px rgba(40,30,10,.35);
  --header-bg: rgba(243,238,226,.92);
  color-scheme: light;
}

/* ---------- CIVIC: maximum contrast, no texture ---------- */
[data-theme="civic"] {
  --bg: #ffffff;
  --bg-elev: #f6f7f9;
  --bg-sunk: #eceef2;
  --ink: #050608;
  --ink-soft: #2f3540;
  --ink-faint: #555c68;
  --line: #c9ced8;
  --line-strong: #8d95a3;
  --accent: #9a5b00;
  --accent-ink: #ffffff;
  --accent-2: #1f2430;
  --gold: #b8860b;
  --dem: #1d4ed8;
  --rep: #b91c1c;
  --good: #15803d;
  --grain-opacity: 0;
  --shadow: 0 1px 0 rgba(0,0,0,.05);
  --header-bg: rgba(255,255,255,.95);
  color-scheme: light;
}
