/* ---- Self-hosted faces ----------------------------------------------------
 * Served from this origin instead of Google Fonts: no third-party request on
 * page load, nothing for the privacy notice to disclose, and no dependency on
 * a host the page cannot control. Latin subset only; the site is in English.
 * Space Grotesk — SIL Open Font License 1.1 (Florian Karsten & contributors)
 * IBM Plex Sans / Mono — SIL Open Font License 1.1 (IBM Corp.)
 * Files in assets/fonts/, licence texts in assets/fonts/LICENSE.txt
 * -------------------------------------------------------------------------- */
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../assets/fonts/space-grotesk-latin-600-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../assets/fonts/space-grotesk-latin-700-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../assets/fonts/ibm-plex-sans-latin-400-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../assets/fonts/ibm-plex-sans-latin-500-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../assets/fonts/ibm-plex-sans-latin-600-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../assets/fonts/ibm-plex-mono-latin-400-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../assets/fonts/ibm-plex-mono-latin-500-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../assets/fonts/ibm-plex-mono-latin-600-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}


/* Hallmark · macrostructure: Terminal Dashboard (custom) · genre: modern-minimal
 * theme: custom — "quant signal terminal" · vibe: systematic, engineered, gold-signal, restrained
 * paper oklch(15.5% 0.004 80) — near-neutral graphite (chroma held under 0.006, warmed not cooled,
 * deliberately not the blue-black "AI fintech dark mode" default), single unified ground (differs
 * from source's alternating dark/light "Ledger" cover-and-page structure)
 * accent oklch(72% 0.16 55) — signal amber/copper, warm hue, high-chroma "electric" vs source's muted
 * antique gold (kept in the warm family deliberately: the product trades XAU — this is the one place
 * a literal color-to-content tie is honest, not decorative)
 * display: Space Grotesk (grotesk-sans) · body: IBM Plex Sans · data/mono: IBM Plex Mono
 * — differs from source's Archivo Expanded (condensed display) + Source Serif 4 (serif body) on
 * display-style axis; differs on paper-band axis (mixed → uniform dark). Redesign preserves all
 * copy facts, figures, disclosures, screenshots and analytics hooks from the source implementation;
 * only the visual/interaction layer changes.
 * pre-emit critique: P4 H4 E4 S4 R4 V4
 */

:root {
  color-scheme: dark;

  /* ---- Color: ground — true neutral graphite, deliberately NOT blue-black.
     A tinted navy dark-mode is the single most recognisable "AI fintech mockup"
     cliché; this stays within 0.006 chroma of neutral gray, warmed a hair
     toward the accent rather than cooled toward blue. ---- */
  --color-ground: oklch(18% 0.004 80);
  --color-ground-raised: oklch(23% 0.006 80);
  --color-ground-sunken: oklch(15% 0.004 80);
  --color-ground-veil: var(--color-ground);
  --color-border: oklch(39% 0.006 80);
  --color-border-soft: oklch(32% 0.006 80);

  /* ---- Color: text ---- */
  --color-text: oklch(95% 0.003 80);
  --color-text-dim: oklch(79% 0.006 80);
  --color-text-faint: oklch(71% 0.007 80);

  /* ---- Color: shadow (neutral, used sparingly for real depth, never a tint) ---- */
  --shadow-sm: oklch(0% 0 0 / 0.4);
  --shadow-md: oklch(0% 0 0 / 0.45);
  --shadow-lg: oklch(0% 0 0 / 0.5);

  /* ---- Color: the one accent — signal amber, the commodity actually traded ---- */
  --color-signal: oklch(72% 0.16 55);
  --color-signal-strong: oklch(78% 0.17 58);
  --color-signal-deep: oklch(58% 0.15 50);
  --color-signal-wash: oklch(72% 0.16 55 / 0.12);
  --color-signal-wash-strong: oklch(72% 0.16 55 / 0.22);

  /* ---- Color: semantic (trade data only, never decorative) ---- */
  --color-long: oklch(74% 0.15 152);
  --color-short: oklch(68% 0.18 27);

  /* ---- Color: focus ---- */
  --color-focus: var(--color-signal-strong);

  /* ---- Type roles ---- */
  --font-display: 'Space Grotesk', 'Arial Narrow', sans-serif;
  --font-body: 'IBM Plex Sans', -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', monospace;

  /* ---- Type scale (fluid) — headline bracketed by copy length ---- */
  --text-display: clamp(2.5rem, 1.9rem + 2.6vw, 4.5rem);
  --text-display-s: clamp(2.25rem,1.6rem + 2.2vw,3.75rem);
  --text-h2: clamp(1.75rem,1.4rem + 1.2vw,2.5rem);
  --text-h3: clamp(1.2rem, 1.1rem + 0.4vw, 1.4rem);
  --text-body-lg: clamp(1.0625rem, 1rem + 0.3vw, 1.25rem);
  --text-body: 1rem;
  --text-meta: .875rem;
  --text-stat: clamp(2rem, 1.6rem + 1.8vw, 3.25rem);
  --leading-display: 1.05;
  --leading-body: 1.6;

  /* ---- Spacing (4pt base) ---- */
  --space-1: 0.25rem; --space-2: 0.5rem; --space-3: 0.75rem; --space-4: 1rem;
  --space-5: 1.25rem; --space-6: 1.5rem; --space-8: 2rem; --space-10: 2.5rem;
  --space-12: 3rem; --space-16: 4rem; --space-20: 5rem; --space-24: 6rem;
  --section-pad-y: clamp(3rem,4.5vw,5rem);

  /* ---- Shape: sharp by default — a terminal is ruled, not carded ---- */
  --radius-sm: 2px;
  --radius-md: 2px;
  --radius-lg: 0px;
  --line-width: 1px;

  /* ---- Motion ---- */
  --ease-out: cubic-bezier(0.2, 0, 0, 1);
  --ease-in: cubic-bezier(0.4, 0, 1, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --dur-fast: 130ms;
  --dur-standard: 220ms;
  --dur-reveal: 640ms;

  /* ---- Reviewed refinements: contrast, reading measure, layout ----
     Raised from the original values so every text role clears WCAG AA
     on the graphite ground. Verified in-browser, not estimated. */
  --space-reading: 44rem;
  --header-height: 4.25rem;
  --dialog-overlay: oklch(8% 0.004 80 / .92);
  --hero-heading: clamp(2.35rem,2rem + 2.2vw,4rem);
  --guide-rail-width: 12rem;
}

@media (prefers-reduced-motion: reduce) {
  :root { --dur-fast: 0ms; --dur-standard: 0ms; --dur-reveal: 1ms; }
}
