/* IM Fell English (Igino Marini, from the Fell types of the 1670s; SIL Open Font License, wwwroot/fonts/im-fell/OFL.txt), the
   display face for headings: the nautical touches of 2026-11-24. Latin letters only; anything else falls back to --serif. */
@font-face { font-family: "IM Fell English"; font-style: normal; font-weight: 400; font-display: swap; src: url("/fonts/im-fell/im-fell-english.woff2") format("woff2"); }
@font-face { font-family: "IM Fell English"; font-style: italic; font-weight: 400; font-display: swap; src: url("/fonts/im-fell/im-fell-english-italic.woff2") format("woff2"); }

/* ==========================================================
   JOURNA :: DESIGN TOKENS
   The colours are the owner's (prompts 01, 24-29). Day is parchment; night is not "dark mode" but Night Horizon (prompt 24),
   following the device's own setting.
   ========================================================== */

:root {
  color-scheme: light;

  /* Roles (prompt 01) */
  --adventurer: #1E4E79;
  --adventurer-2: #4F86C6;
  --adventurer-3: #8CB3D9;
  --navigator: #B8860B;
  --navigator-ink: #85620A;
  --navigator-2: #D4A017;
  --navigator-3: #E6C55A;
  --pilot: #2F6B3C;
  --pilot-2: #4E9F5A;
  --pilot-3: #8CCB91;
  --legacy: #6A4E3B;
  --legacy-2: #8A6A52;
  --legacy-3: #B09174;

  /* The page */
  --page: #F8F3EB;
  --surface: #FCF8F1;
  --surface-2: #F3EADB;
  --ink: #2E2A25;
  --ink-soft: #5E554B;
  --ink-faint: #8A8073;
  --line: #E2D6C1;
  --line-strong: #D9C6A6;
  --focus: #D5AA52;
  --shadow: 0 8px 20px rgba(22, 59, 89, 0.08);

  /* Horizon (prompt 26) */
  --horizon-sky-deep: #163B59;
  --horizon-sky-mid: #3E6B89;
  --horizon-sky-light: #7698A9;
  --horizon-mist: #AEBFC7;
  --horizon-light-soft: #D9C6A6;
  --horizon-light-warm: #F4E5C5;
  --horizon-gradient-dawn: linear-gradient(180deg, #163B59 0%, #3E6B89 30%, #7698A9 55%, #D9C6A6 80%, #F4E5C5 100%);
  --horizon-line: #B6A48A;
  --horizon-line-active: #D5AA52;
  --horizon-line-glow: #E1C47B;

  --horizon-thread-beyond-stroke: #C7D1D9;
  --horizon-thread-beyond-fill: #D8DFE3;
  --horizon-thread-beyond-glow: #E4E9EC;
  --horizon-thread-beyond-text: #667785;
  --horizon-thread-emerging-stroke: #6E94A8;
  --horizon-thread-emerging-fill: #8BAAB8;
  --horizon-thread-emerging-glow: #AEBFC7;
  --horizon-thread-emerging-text: #355167;
  --horizon-thread-calling-stroke: #D5AA52;
  --horizon-thread-calling-fill: #E1C47B;
  --horizon-thread-calling-glow: #F0D99C;
  --horizon-thread-calling-text: #7D6024;
  --horizon-thread-approaching-stroke: #D98C52;
  --horizon-thread-approaching-fill: #E4A36A;
  --horizon-thread-approaching-glow: #F0BD87;
  --horizon-thread-approaching-text: #784219;
  --horizon-thread-transition-core: #D5AA52;
  --horizon-thread-transition-wave: #EAC98E;
  --horizon-thread-transition-glow: #F3D8A3;

  --horizon-card-bg: #F8F3EB;
  --horizon-card-surface: #FCF8F1;
  --horizon-card-border: #D9C6A6;
  --horizon-card-focus-bg: #FFF3D6;
  --horizon-card-focus-border: #E1C47B;
  --horizon-card-focus-glow: #F5DEAB;
  --horizon-card-shadow: 0 8px 20px rgba(22, 59, 89, 0.08);
  --horizon-card-shadow-focus: 0 12px 32px rgba(213, 170, 82, 0.18);

  --reflection-bg: #FDF8EF;
  --reflection-border: #D8BE93;
  --reflection-text: #6A4E3B;
  --reflection-accent: #B8860B;

  --distance-far-opacity: 0.40;
  --distance-mid-opacity: 0.70;
  --distance-near-opacity: 1.00;
  --distance-far-blur: 6px;
  --distance-mid-blur: 2px;
  --distance-near-blur: 0px;

  --horizon-night-sky: #081824;
  --horizon-night-ocean: #102D42;
  --horizon-night-mist: #184760;
  --horizon-night-light-near: #E1CB95;
  --horizon-night-light-far: #C7B27A;
  --horizon-night-light-beacon: #F2D883;
  --horizon-gradient-night: linear-gradient(180deg, #081824 0%, #102D42 50%, #184760 100%);

  --horizon-possibility: #6E94A8;
  --horizon-curiosity: #8BAAB8;
  --horizon-calling: #D5AA52;
  --horizon-approaching: #D98C52;
  --horizon-unknown: #C7D1D9;
  --horizon-beacon-light: #F2D883;
  --horizon-sunrise-glow: radial-gradient(circle, rgba(240, 217, 156, 0.50) 0%, rgba(240, 217, 156, 0.15) 45%, transparent 75%);
  --horizon-atmosphere: linear-gradient(180deg, transparent 0%, rgba(174, 191, 199, .15) 65%, rgba(217, 198, 166, .20) 100%);

  /* Temperature (prompt 27): emotional distance from action, never priority */
  --temperature-cold: #6E94A8;
  --temperature-cool: #8BAAB8;
  --temperature-warm: #D5AA52;
  --temperature-warmer: #E1C47B;
  --temperature-hot: #D98C52;
  --temperature-hotter: #E4A36A;
  --temperature-white-hot: #F3D8A3;

  --temp-cold-primary: #6E94A8;
  --temp-cold-glow: rgba(110, 148, 168, .15);
  --temp-cold-shadow: 0 0 6px rgba(110, 148, 168, .15);
  --temp-cool-primary: #8BAAB8;
  --temp-cool-glow: rgba(139, 170, 184, .22);
  --temp-cool-shadow: 0 0 12px rgba(139, 170, 184, .18);
  --temp-warm-primary: #D5AA52;
  --temp-warm-glow: rgba(213, 170, 82, .25);
  --temp-warm-shadow: 0 0 18px rgba(213, 170, 82, .20);
  --temp-hot-primary: #D98C52;
  --temp-hot-glow: rgba(217, 140, 82, .35);
  --temp-hot-shadow: 0 0 24px rgba(217, 140, 82, .28);
  --temp-whitehot-primary: #F3D8A3;
  --temp-whitehot-glow: rgba(243, 216, 163, .50);
  --temp-whitehot-shadow: 0 0 36px rgba(243, 216, 163, .42);

  --badge-cold-bg: rgba(110, 148, 168, 0.12);
  --badge-cold-text: #355167;
  --badge-warm-bg: rgba(213, 170, 82, 0.14);
  --badge-warm-text: #7D6024;
  --badge-hot-bg: rgba(217, 140, 82, 0.14);
  --badge-hot-text: #784219;

  --heat-beyond-shadow: 0 0 4px rgba(199, 209, 217, .20);
  --heat-emerging-shadow: 0 0 10px rgba(110, 148, 168, .25);
  --heat-calling-shadow: 0 0 18px rgba(213, 170, 82, .30);
  --heat-approaching-shadow: 0 0 24px rgba(217, 140, 82, .35);
  --heat-activated-shadow: 0 0 32px rgba(243, 216, 163, .45);

  /* Thread states (prompt 29) */
  --state-seed-opacity: .55;
  --state-emerging-bg: rgba(110, 148, 168, .05);
  --state-emerging-opacity: .75;
  --state-calling-bg: rgba(213, 170, 82, .06);
  --state-pulled-bg: rgba(217, 140, 82, .08);
  --state-active-bg: rgba(47, 107, 60, .06);
  --state-intertwined-bg: rgba(106, 78, 59, .08);
  --state-legacy-bg: rgba(106, 78, 59, .12);
  --state-legacy-opacity: .95;
  --state-dormant-bg: rgba(174, 191, 199, .04);
  --state-dormant-opacity: .55;
  --state-rediscovered-bg: rgba(213, 170, 82, .12);

  /* Type and space */
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: "IM Fell English", var(--serif);
  /* Nautical touches: the rope of the dividers and the faint lines of a chart, the same by day and by night. */
  --rope: #B09174;
  --chart-line: rgba(140, 116, 88, .09);
  --radius: 24px;
  --radius-sm: 14px;
  --gutter: 16px;
  --bar-h: 64px;
}

/* Night watch (prompt 25): every surface, line and text pairs with a night value. */
@media (prefers-color-scheme: dark) {
  :root {
    --chart-line: rgba(176, 145, 116, .08);
    color-scheme: dark;
    --page: #0B1C2A;
    --surface: #102D42;
    --surface-2: #143650;
    --ink: #EDE6D6;
    --ink-soft: #C9C0AE;
    --ink-faint: #9C9483;
    --line: #23455E;
    --line-strong: #3A5A70;
    --shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
    --adventurer: #8CB3D9;
    --adventurer-2: #6E9FD2;
    --navigator-ink: #E6C55A;
    --pilot: #8CCB91;
    --legacy: #C9AA8C;
    --horizon-card-bg: #102D42;
    --horizon-card-surface: #12324A;
    --horizon-card-border: #2C5068;
    --horizon-card-focus-bg: #1A3D57;
    --reflection-bg: #16374F;
    --reflection-border: #6E5A3A;
    --reflection-text: #E8D6B8;
    --horizon-thread-beyond-text: #AFC0CC;
    --horizon-thread-emerging-text: #B7D0DD;
    --horizon-thread-calling-text: #F0D99C;
    --horizon-thread-approaching-text: #F0BD87;
    --badge-cold-text: #B7D0DD;
    --badge-warm-text: #F0D99C;
    --badge-hot-text: #F0BD87;
  }
}
