/* ==========================================================================
   MajDev design tokens
   Single source of truth for colour, type, radius, spacing and motion.
   Rules for using them live in brand/BRAND.md.

   Default palette: Slate & Lavender (evolved from the original site).
   Alternates are opt-in: <html data-palette="gold|mint|paper">.
   Light/dark mode: <html data-theme="light"> uses Paper & Indigo; no attribute (or "dark") is Slate & Lavender.
   See "Switching palettes" in brand/BRAND.md.
   ========================================================================== */

:root {
  /* ---- Colour: Slate & Lavender (default) ---- */
  --bg:          #12181d;  /* page background */
  --bg2:         #151c22;  /* full-width strips (industries bar) */
  --surface:     #1b242b;  /* cards, panels, floating badges */
  --surface2:    #232e37;  /* raised surface inside a surface */
  --sunken:      #0e1317;  /* image wells behind screenshots */
  --line:        #2e3a44;  /* default 1px borders and dividers */
  --line2:       #3a4752;  /* stronger borders: ghost buttons, chips, inputs */
  --text:        #eef1f4;  /* headings, primary text */
  --text2:       #d6dce2;  /* nav links, chip labels */
  --soft:        #b4bec8;  /* lead paragraphs, body copy on dark */
  --muted:       #a3afba;  /* captions, meta, stat labels */
  --accent:      #a4abdb;  /* the one brand colour */
  --accent-hi:   #c3c8ee;  /* accent hover */
  --accent-text: #a4abdb;  /* accent used as text (eyebrows) */
  --on-accent:   #12181d;  /* text on an accent fill */
  --link:        #c3c8ee;
  --ok-fg:       #b9e6c9;  /* "Available for projects" badge */
  --ok-bg:       #16241c;
  --ok-line:     #2f4a3b;
  --ok-dot:      #5fd38d;
  --logo-bg:     transparent;
  --tile-bg:     #4d5b65;  /* skill/tool tiles: mid-slate, as on the original site */
  --tile-text:   #ffffff;  /* label and monogram on a tile */
  --tile-hi:     #c3c8ee;  /* "Used in N projects" on a tile (stays light in every theme) */
  --nav-bg:      rgba(18, 24, 29, 0.88);
  --err:         #f2a7a7;  /* form error text and borders */

  /* ---- Type ---- */
  --font-display: 'Space Grotesk', system-ui, sans-serif;
  --font-body:    Inter, system-ui, sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, monospace;

  --fs-hero:   clamp(42px, 6vw, 64px);  /* line-height 1.05, tracking -1.5px */
  --fs-h2:     clamp(34px, 4vw, 44px);  /* line-height 1.1,  tracking -0.8px */
  --fs-h3:     24px;
  --fs-stat:   32px;
  --fs-lead:   19px;
  --fs-body:   16px;                    /* line-height 1.6 */
  --fs-small:  14px;
  --fs-eyebrow: 13px;
  --fs-micro:  11px;                    /* mono labels inside badges */

  --lh-tight: 1.05;
  --lh-head:  1.1;
  --lh-body:  1.6;

  /* ---- Shape ---- */
  --radius-sm:    10px;   /* small buttons, image tops */
  --radius-md:    12px;   /* buttons, inputs, banners */
  --radius-lg:    20px;   /* cards, case-study panel */
  --radius-xl:    28px;   /* portrait */
  --radius-pill:  999px;  /* chips, status badge */
  --border:       1px solid var(--line);
  --border-strong: 1px solid var(--line2);

  /* ---- Space & layout ---- */
  --container:   1200px;
  --gutter:      24px;
  --section-y:   112px;   /* 64px under 760px */
  --gap-xs: 8px;
  --gap-sm: 12px;
  --gap-md: 16px;
  --gap-lg: 24px;
  --gap-xl: 32px;
  --gap-2xl: 56px;

  /* ---- Motion ---- */
  --ease:      cubic-bezier(.2, .7, .2, 1);
  --dur-fast:  .15s;
  --dur:       .2s;
  --lift:      -4px;      /* card hover */
}

@media (max-width: 760px) {
  :root { --section-y: 64px; }
}

@media (prefers-reduced-motion: reduce) {
  :root { --dur-fast: 0s; --dur: 0s; --lift: 0px; }
}

/* ---- Alternate palettes (only the colour layer changes) ---- */

[data-palette="gold"] {           /* Graphite & Gold */
  --bg: #121212; --bg2: #171717; --surface: #1d1d1d; --surface2: #262626; --sunken: #0c0c0c;
  --line: #303030; --line2: #3f3f3f; --text: #f3f1ec; --text2: #dcd8cf; --soft: #bdb8ad; --muted: #a8a397;
  --accent: #e2b454; --accent-hi: #f0cd80; --accent-text: #e2b454; --on-accent: #1a1405; --link: #f0cd80;
  --ok-fg: #b9e6c9; --ok-bg: #15211a; --ok-line: #2f4a3b; --ok-dot: #5fd38d;
  --logo-bg: transparent; --tile-bg: #3b3934; --tile-text: #ffffff; --tile-hi: #f0cd80; --nav-bg: rgba(18, 18, 18, 0.88);
}

[data-palette="mint"] {           /* Deep Sea & Mint */
  --bg: #0d1717; --bg2: #101d1d; --surface: #152524; --surface2: #1c2f2e; --sunken: #091111;
  --line: #243a38; --line2: #304a47; --text: #ecf4f2; --text2: #d0e0dd; --soft: #a9c1bd; --muted: #95afab;
  --accent: #5fd0b8; --accent-hi: #8fe3d1; --accent-text: #5fd0b8; --on-accent: #062019; --link: #8fe3d1;
  --ok-fg: #c6ecb6; --ok-bg: #17261a; --ok-line: #35502f; --ok-dot: #8bd16a;
  --logo-bg: transparent; --tile-bg: #2e4846; --tile-text: #ffffff; --tile-hi: #8fe3d1; --nav-bg: rgba(13, 23, 23, 0.88);
}

[data-palette="paper"],
[data-theme="light"] {             /* Paper & Indigo (light) — also the site's light mode */
  --bg: #f7f7f4; --bg2: #efefea; --surface: #ffffff; --surface2: #f1f2f6; --sunken: #e7e9ee;
  --line: #dfe1e6; --line2: #c6cad3; --text: #1a1f27; --text2: #2c333d; --soft: #4a5360; --muted: #5b6470;
  --accent: #4b52b0; --accent-hi: #383e93; --accent-text: #454ca8; --on-accent: #ffffff; --link: #3f46a3;
  --ok-fg: #1d6b3d; --ok-bg: #e5f4ea; --ok-line: #b9dfc6; --ok-dot: #2a9d5c;
  --logo-bg: #1b252c; --tile-bg: #4d5b65; --tile-text: #ffffff; --tile-hi: #c3c8ee; --nav-bg: rgba(247, 247, 244, 0.9);
  --err: #b42318;
}
