/* The courtyard page's tokens: every colour, font, size and shape its stylesheet uses, each named for its role. */
:root {
  /* Page backdrop: the gradient behind the sections below the hero */
  --backdrop-top: #2a3160;
  --backdrop-bottom: #1c2346;

  /* Text */
  --text: #e7ebfb;
  --text-body: #cfd5ee;
  --text-lead: #c3cbe6;
  --text-hero: #eef0ff;
  --text-bright: #fff;
  --text-parchment: #e9e2c8;
  --text-muted: #b4bbd8;
  --text-soft: #c4ccdf;
  --title-shadow: #0a1030;
  --accent-shadow: #4a3708;
  --shadow-ink: #060a1a;

  /* Brand and accent */
  --brand: #3a6bff;
  --brand-deep: #274bbf;
  --brand-light: #7fb0ff;
  --brand-bright: #7f95ff;
  --accent: #f0c65a;

  /* Page chrome */
  --header-bg: #090a16;
  --section-shade: #0a0e22;

  /* Dialogue window */
  --window-fill-top: #16295f;
  --window-fill-bottom: #0c1740;
  --window-edge: #dfe7ff;
  --window-frame: #244fc4;
  --window-outline: #0a1330;

  /* Stat bars and status */
  --stat-health: #57d977;
  --stat-health-light: #6bf58a;
  --stat-skill: #e5484d;
  --stat-skill-light: #ff6a6a;
  --status-live: #57d977;

  /* Scene: sky, sun and clouds */
  --scene-sky-high: #3f86d6;
  --scene-sky-mid: #6fb0e6;
  --scene-sky-low: #a9d8f2;
  --scene-sky-horizon: #d8eef8;
  --scene-sun-core: #fff7d6;
  --scene-sun-mid: #ffe06a;
  --scene-sun-edge: #ffcf3a;
  --scene-sun-ring: #ffec96;
  --scene-sun-glow: #ffe06e;
  --scene-cloud: #fdfeff;
  --scene-cloud-shade: #eef4fb;
  --scene-cloud-underside: #b4cde6;
  --scene-dragon-shadow: #141e3c;
  --scene-scrim: #14224a;

  /* Scene: land and water */
  --scene-hill-left: #6cae52;
  --scene-hill-right: #7cbc60;
  --scene-hill-centre: #5c9a45;
  --scene-grass: #4f9d3f;
  --scene-grass-shade: #397a2c;
  --scene-lawn-light: #5cae48;
  --scene-lawn-edge: #6cbf54;
  --scene-haze: #2a3160;
  --scene-water: #2f7fd8;
  --scene-water-light: #56a0e8;
  --scene-water-deep: #1f5fae;

  /* Scene: castle */
  --castle-stone: #6f7488;
  --castle-stone-shade: #4b4f63;
  --castle-stone-light: #9096ab;
  --castle-stone-deep: #34374a;
  --castle-window-top: #0f111a;
  --castle-window-bottom: #191d2c;
  --castle-window-frame: #5a5f72;
  --castle-drape: #8a2f2f;
  --castle-drape-fold: #6f2323;
  --castle-mullion: #2b2f3d;
  --castle-gate-top: #191c2e;
  --castle-gate-bottom: #0c0e18;
  --castle-portcullis: #787e96;

  /* Scene: drawbridge and torches */
  --bridge-plank: #7a5230;
  --bridge-plank-gap: #6b4626;
  --bridge-beam-dark: #5f3d20;
  --bridge-beam-light: #8a5c34;
  --bridge-outline: #4a3018;
  --bridge-chain: #d9d2b8;
  --torch-pole-top: #6b4a2a;
  --torch-pole-bottom: #3a2716;
  --torch-flame-core: #fff2b0;
  --torch-flame-mid: #ffb43c;
  --torch-flame-edge: #ff6a1e;
  --torch-glow: #ff9628;

  /* Boss card stage */
  --stage-sky-top: #101a3e;
  --stage-sky-mid: #17224e;
  --stage-sky-bottom: #223066;
  --stage-floor-top: #2b2447;
  --stage-floor-bottom: #1c1836;

  /* Type: the fonts, and the one scale every font size comes from */
  --font-display: 'Pixel Game', 'Courier New', monospace;
  --font-ui: 'Game Paused', 'Pixel Game', monospace;
  --font-body: 'Source Sans Pro', 'Segoe UI', system-ui, sans-serif;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-md: 1rem;
  --font-size-lg: 1.0625rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.4375rem;
  --font-size-tagline: clamp(0.75rem, 2.4vw, 1.0625rem);
  --font-size-heading: clamp(1.625rem, 5vw, 2.875rem);
  --font-size-display: clamp(2.5rem, 8.4vw, 5.75rem);

  /* Layout */
  --width-page: 1140px;
  --width-prose: 70ch;
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 5rem;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;

  /* Shadows and focus */
  --glow-brand:
    0 0 6px color-mix(in srgb, var(--brand) 80%, transparent),
    0 0 18px color-mix(in srgb, var(--brand) 50%, transparent);
  --glow-accent:
    0 0 6px color-mix(in srgb, var(--accent) 85%, transparent),
    0 0 16px color-mix(in srgb, var(--accent) 45%, transparent);
  --focus-ring: var(--text-bright);
  --focus-ring-edge: var(--window-outline);
}
