/* Brand tokens: onsen, cerulean. Single source of truth for every project.
   One clear cerulean on bright, faintly warm white does almost everything (like nualt.fr),
   with elegant vermilion accents. Cerulean and vermilion sit opposite on the colour wheel at
   almost the same lightness, so they glow together rather than clash.
   Peach and the rest are an available secondary palette for illustration and data, not page surfaces.
   Copy this file into a project (don't link to ~/.claude) and import it before other styles.
   Light theme is the default; dark follows the OS unless data-theme is set on <html>.
   How things move and answer lives in feel.css (behaviour) and the Motion and Feel tokens below. */

:root {
  /* Primary: one colour, two strengths */
  --primary: #0099DB;        /* cerulean statement: headlines, tile wall, Fuji, the colour band, chart series 1. 3.1:1, large type and shapes only */
  --primary-text: #0075A8;   /* the same hue, deep enough for text: body, labels, links, buttons, rules. 4.9:1 on paper, white on it 5.1:1 */
  --primary-deep: #005F88;   /* hover and pressed states, hair and line work */
  --tint: #D5EEFA;           /* pale cerulean: hills, pale tiles, chart fills (decorative) */
  --water: #8ED2F0;          /* bath water */

  /* Surfaces */
  --paper: #FCFBF9;          /* sunlit wall: bright with the faintest warmth, not pure white */
  --white: #FFFFFF;          /* cards, tiles */
  --mist: #F2F7F9;           /* alternate sections */

  /* Accent: elegant, sparing */
  --vermilion: #FF4A1C;      /* stamp, one highlighted word, a rare tile, the sun, a towel. Shapes and large type only */
  --vermilion-text: #C6330E; /* when vermilion must be small text */

  /* Secondary palette: available for illustration and data, never as page surfaces */
  --peach: #FFB59A;
  --gold: #A06A00;
  --plum: #8E3F86;
  --slate: #4D6466;
  --ink: #0B3436;

  /* Roles */
  --bg: var(--paper);
  --surface: var(--white);
  --surface-alt: var(--mist);
  --text: var(--primary-text);
  --headline: var(--primary);      /* headlines and large type only (3.1:1) */
  --text-muted: #3D6E84;
  --rule: var(--primary-text);
  --rule-soft: color-mix(in srgb, var(--primary-text) 20%, transparent);
  --accent: var(--vermilion);
  --accent-text: var(--vermilion-text);
  --link: var(--primary-text);
  --button-bg: var(--primary-text);
  --button-bg-hover: var(--primary-deep);
  --button-text: var(--white);
  --button-2-bg: transparent;
  --button-2-text: var(--primary-text);
  --focus: var(--vermilion);
  --band: var(--primary);          /* full-width colour section: large white type only */
  --band-text: var(--white);

  /* Data colours, in order. All ≥3:1 on --bg and --surface. */
  --series-1: var(--primary);
  --series-2: var(--vermilion-text);
  --series-3: var(--gold);
  --series-4: var(--plum);
  --series-5: var(--slate);
  --positive: var(--primary-text);
  --negative: var(--vermilion-text);

  /* Type: one family. Weight and size do the work. */
  --font-sans: "Outfit", system-ui, -apple-system, "Segoe UI", "Hiragino Sans", "Noto Sans JP", sans-serif;
  --font-display: var(--font-sans);
  --font-body: var(--font-sans);
  --font-jp: "Hiragino Sans", "Noto Sans JP", var(--font-sans);
  --font-mono: ui-monospace, "SF Mono", Menlo, monospace; /* code only, never UI */

  /* Type scale (1.25, display steps pushed larger for a modern headline) */
  --step--1: 0.85rem;
  --step-0: 1rem;
  --step-1: 1.25rem;
  --step-2: 1.563rem;
  --step-3: 2rem;
  --step-4: clamp(2.2rem, 1.5rem + 3vw, 3.6rem);
  --step-5: clamp(2.8rem, 1.6rem + 5.2vw, 5.6rem);

  /* Space, shape, motion */
  --space-1: 4px;  --space-2: 8px;  --space-3: 12px; --space-4: 16px;
  --space-5: 24px; --space-6: 32px; --space-7: 56px; --space-8: 96px;
  --radius: 0;
  --grout: 2px;
  --line: 1px solid var(--rule);
  --line-dashed: 1px dashed var(--rule);
  --max: 1240px;

  /* Motion: still water. Things answer at once, settle softly, and never ask to be watched.
     Enter with ease-out, leave a little faster than you came, move across the screen with ease-in-out. */
  --ease-out: cubic-bezier(.22, 1, .36, 1);      /* arrivals, reveals, sheets: quick start, long soft landing */
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);   /* something already on screen moving to a new place */
  --ease-spring: cubic-bezier(.34, 1.3, .64, 1); /* a small settle for a press or a tick: overshoot under 5%, never a bounce */
  --ease: var(--ease-out);
  --dur-press: 120ms;   /* the press itself: scale(.97), colour */
  --dur-quick: 180ms;   /* hover, fades of small things, a chevron turning, leaving */
  --dur-base: 280ms;    /* a fold opening, content arriving, a view changing */
  --dur-calm: 420ms;    /* a sheet or panel sliding in */
  --dur-settle: 600ms;  /* a one-time entrance on first load; the longest anything takes */
  --dur: var(--dur-settle);
  --rise: 8px;          /* how far an entrance travels. Small: it hints, it doesn't fly */
  --press-scale: .97;

  /* Feel */
  --tap: 44px;          /* smallest thing a finger has to hit */
  --whisper-for: 2400ms;/* how long a quiet confirmation stays */
  --veil: color-mix(in srgb, var(--ink) 38%, transparent); /* the dim behind a sheet */
  --lift: 0 12px 40px rgba(8, 42, 58, .16);              /* the only shadow: something floating above the page */
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #082A3A;
    --surface: #0C3548;
    --surface-alt: #0A3042;
    --text: #EAF5FB;
    --headline: #5CC6F2;
    --text-muted: #9DC4D6;
    --rule: #5CC6F2;
    --rule-soft: color-mix(in srgb, #5CC6F2 22%, transparent);
    --accent: #FF6B45;
    --accent-text: #FF6B45;
    --link: #5CC6F2;
    --button-bg: #5CC6F2;
    --button-bg-hover: #8AD7F6;
    --button-text: #082A3A;
    --button-2-text: #5CC6F2;
    --band: #5CC6F2;
    --band-text: #082A3A;
    --series-1: #5CC6F2;
    --series-2: #FF6B45;
    --series-3: #F2B84B;
    --series-4: #E59AD8;
    --series-5: #FFB59A;
    --positive: #5CC6F2;
    --negative: #FF6B45;
    --lift: 0 12px 40px rgba(0, 0, 0, .38);
  }
}

:root[data-theme="dark"] {
  --bg: #082A3A;
  --surface: #0C3548;
  --surface-alt: #0A3042;
  --text: #EAF5FB;
  --headline: #5CC6F2;
  --text-muted: #9DC4D6;
  --rule: #5CC6F2;
  --rule-soft: color-mix(in srgb, #5CC6F2 22%, transparent);
  --accent: #FF6B45;
  --accent-text: #FF6B45;
  --link: #5CC6F2;
  --button-bg: #5CC6F2;
  --button-bg-hover: #8AD7F6;
  --button-text: #082A3A;
  --button-2-text: #5CC6F2;
  --band: #5CC6F2;
  --band-text: #082A3A;
  --series-1: #5CC6F2;
  --series-2: #FF6B45;
  --series-3: #F2B84B;
  --series-4: #E59AD8;
  --series-5: #FFB59A;
  --positive: #5CC6F2;
  --negative: #FF6B45;
  --lift: 0 12px 40px rgba(0, 0, 0, .38);
}
