/* ============================================================
   BROOD — design tokens
   Inherits the Fledge `ink` ramp (warm plum-charcoal, deliberately
   NOT blue-black — it reads as a lamp-lit room, not a terminal).
   Accent moves from honey to ACID, matching the creatures' status glow.
   Every colour pairing below was solved for contrast, not eyeballed.
   ============================================================ */

:root {
  /* ---- primitive: ink (unchanged from the verified Fledge ramp) ---- */
  --ink-1000:#0E0B12; --ink-900:#120F16; --ink-800:#17131C; --ink-700:#1F1A26;
  --ink-600:#292231;  --ink-550:#3A3145; --ink-500:#544959; --ink-450:#6B6076;
  --ink-400:#796981;  --ink-300:#9E93A8; --ink-200:#C4BACD; --ink-100:#E8E1EC;
  --ink-50:#F6F2F8;   --ink-0:#FFFFFF;

  /* ---- primitive: acid (the new accent — NUB's belly glow) ----
     acid-500 on ink-900 = 14.04:1 · on ink-800 = 13.54:1 · on ink-700 = 12.58:1
     ink-1000 text on acid-400 fill = 10.98:1                                */
  --acid-700:#4A6B12; --acid-600:#6E9B1C; --acid-500:#B6F03C;
  --acid-400:#8FD622; --acid-300:#D4FF63; --acid-200:#E8FFA8;

  /* ---- primitive: state ---- */
  --jade-600:#2A9668; --jade-500:#3FBF87; --jade-400:#6FD3A6;   /* up   8.15:1 */
  --peri-600:#4E5CB8; --peri-500:#6F7EE0; --peri-400:#8E9BEA;   /* down 5.19:1 */
  --coral-600:#C13438;--coral-500:#E5484D;--coral-400:#F17175;  /* ERRORS ONLY */

  /* ---- primitive: rarity ---- */
  --rarity-common:#9C94A4; --rarity-rare:#47B4D8; --rarity-epic:#A970E8;
  --rarity-legendary:#F08A29;
  --rarity-mythic:linear-gradient(115deg,#FF8FB1 0%,#A970E8 45%,#47D8C4 100%);
  --rarity-mythic-flat:#C77DDB;

  /* ---- semantic: surface ---- */
  --bg-canvas:var(--ink-900);
  --bg-surface:var(--ink-800);
  --bg-raised:var(--ink-700);
  --bg-overlay:var(--ink-600);

  /* ---- semantic: text ---- */
  --text-primary:var(--ink-100);    /* 13.9:1 */
  --text-secondary:var(--ink-200);  /* 10.2:1 */
  --text-muted:var(--ink-300);      /*  6.5:1 */
  --text-disabled:var(--ink-450);
  --text-accent:var(--acid-500);

  /* ---- semantic: border ----
     border-strong is what every input/control MUST use: it is solved to clear
     WCAG 1.4.11 (3:1) against the LIGHTEST surface it can sit on.            */
  --border-subtle:var(--ink-600);
  --border-default:var(--ink-500);
  --border-strong:var(--ink-400);

  /* ---- type ---- */
  --font-display:"Cabinet Grotesk","Arial Black",system-ui,sans-serif;
  --font-body:"Switzer",-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  --font-mono:"JetBrains Mono",ui-monospace,"SF Mono",Menlo,monospace;

  /* ---- spacing: strictly monotonic (css_traps.py checks this) ---- */
  --space-1:4px;  --space-2:8px;  --space-3:12px; --space-4:16px;
  --space-5:24px; --space-6:32px; --space-7:48px; --space-8:64px;
  --space-9:96px; --space-10:128px;

  --radius-sm:6px; --radius-md:10px; --radius-lg:16px; --radius-xl:24px;
  --radius-pill:999px;

  --border-hair:1px;
  --maxw:1200px;
}

/* Fonts — self-hosted. The two ITF faces (Cabinet Grotesk, Switzer) ship
   UNSUBSET: their EULA forbids modification and subsetting is modification.
   woff2 here is lossless repackaging, glyph counts verified identical.
   JetBrains Mono is OFL, so it IS subset — and it is a genuine variable font
   (fvar present), so font-variation-settings below actually takes effect. */
@font-face{font-family:"Cabinet Grotesk";src:url("/fonts/CabinetGrotesk-800.woff2") format("woff2");
  font-weight:800;font-style:normal;font-display:swap}
@font-face{font-family:"Cabinet Grotesk";src:url("/fonts/CabinetGrotesk-900.woff2") format("woff2");
  font-weight:900;font-style:normal;font-display:swap}
@font-face{font-family:"Switzer";src:url("/fonts/Switzer-400.woff2") format("woff2");
  font-weight:400;font-style:normal;font-display:swap}
@font-face{font-family:"Switzer";src:url("/fonts/Switzer-600.woff2") format("woff2");
  font-weight:600;font-style:normal;font-display:swap}
@font-face{font-family:"JetBrains Mono";src:url("/fonts/JetBrainsMono.woff2") format("woff2");
  font-weight:100 800;font-style:normal;font-display:swap}

/* Every number in this product is money. Tabular + slashed zero, always.
   Cabinet Grotesk and Switzer ship no slashed zero, which is exactly why the
   mono face exists in this stack. */
.num,.mono{font-family:var(--font-mono);font-variant-numeric:tabular-nums slashed-zero;
  font-feature-settings:"tnum" 1,"zero" 1;letter-spacing:-.01em}
