/* ==========================================================================
   Design tokens
   Colour, type, spacing and motion values shared by every stylesheet.
   Light/dark values are paired with light-dark(); the active scheme is
   chosen by the OS, or forced with <html data-theme="light|dark">.
   ========================================================================== */

:root {
    color-scheme: light dark;

    /* --- Colour: surfaces (concrete & paper) --- */
    --bg:            light-dark(#F3F1EC, #0E1113);
    --surface:       light-dark(#FBFAF7, #15191C);
    --surface-2:     light-dark(#ECE9E2, #1B2024);
    --surface-glass: light-dark(rgb(251 250 247 / .78), rgb(21 25 28 / .72));

    /* --- Colour: text --- */
    --ink:   light-dark(#15191C, #ECE9E3);
    --ink-2: light-dark(#4B5157, #A7ADB2);
    --ink-3: light-dark(#666C71, #868D93);

    /* --- Colour: lines --- */
    --line:        light-dark(#DCD8D0, #262C31);
    --line-strong: light-dark(#C5C0B6, #363D43);

    /* --- Colour: accents (site orange & blueprint blue) --- */
    --accent:      light-dark(#B04A17, #F08A4B);
    --accent-ink:  light-dark(#FFFFFF, #140D08);
    --accent-soft: light-dark(rgb(176 74 23 / .09), rgb(240 138 75 / .12));
    --blue:        light-dark(#2A4A7A, #8DB0E6);
    --blue-soft:   light-dark(rgb(42 74 122 / .07), rgb(141 176 230 / .07));
    --grid-line:   light-dark(rgb(42 74 122 / .075), rgb(141 176 230 / .06));

    /* --- Typography --- */
    --font-sans:  'Instrument Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-mono:  'JetBrains Mono', ui-monospace, 'SFMono-Regular', Consolas, monospace;

    --step--1: clamp(.8125rem, .79rem + .1vw, .875rem);
    --step-0:  clamp(1rem, .97rem + .15vw, 1.0625rem);
    --step-1:  clamp(1.125rem, 1.06rem + .3vw, 1.3125rem);
    --step-2:  clamp(1.375rem, 1.24rem + .6vw, 1.75rem);
    --step-3:  clamp(1.75rem, 1.5rem + 1.2vw, 2.625rem);
    --step-4:  clamp(2.25rem, 1.8rem + 2.2vw, 3.75rem);
    --step-5:  clamp(2.75rem, 1.9rem + 4.2vw, 6rem);

    /* --- Spacing & layout --- */
    --space-xs: .5rem;
    --space-s:  1rem;
    --space-m:  1.5rem;
    --space-l:  clamp(2rem, 1.6rem + 2vw, 3rem);
    --space-xl: clamp(3rem, 2rem + 5vw, 6rem);
    --section:  clamp(5rem, 3.5rem + 7vw, 9.5rem);

    --wrap:   1240px;
    --gutter: clamp(1rem, .5rem + 2.5vw, 2.5rem);
    --header-h: 72px;

    /* --- Shape & depth --- */
    --radius-s: 8px;
    --radius-m: 14px;
    --radius-l: 22px;
    --shadow-s: 0 1px 2px light-dark(rgb(21 25 28 / .06), rgb(0 0 0 / .4));
    --shadow-m: 0 1px 2px light-dark(rgb(21 25 28 / .05), rgb(0 0 0 / .3)),
                0 12px 32px -12px light-dark(rgb(21 25 28 / .14), rgb(0 0 0 / .55));

    /* --- Motion --- */
    --ease-out: cubic-bezier(.22, 1, .36, 1);
    --dur-fast: .18s;
    --dur:      .35s;
    --dur-slow: .8s;
}

:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"]  { color-scheme: dark; }
