/* ==========================================================================
   DESIGN TOKENS — 60 / 30 / 10 colour rule
   --------------------------------------------------------------------------
   Each theme has exactly three colours:
     60%  dominant   → page background and cards
     30%  secondary  → text, nav bar and the inverse blocks (.swap)
     10%  accent     → buttons, highlights, active states, small details

                 60%                  30%                10%
     Light       Pistachio #e3eecf    Ink #1c2430        Raspberry pink #c2185b
     Dark        Black #08090b        Ice white #e8f1f5  Aurora green #3ee6a0

   Every other shade is a blend of the three (color-mix) or one of them
   made transparent. Change a theme by editing its three lines below.
   ========================================================================== */

:root {
  /* Named palette */
  --pistachio: #e3eecf;
  --ink: #1c2430;
  --raspberry: #c2185b;

  --black: #08090b;
  --ice: #e8f1f5;
  --aurora: #3ee6a0;

  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Syne", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;

  --gutter: clamp(16px, 5vw, 64px);
  --max-width: 1200px;
  --radius: 18px;
  --radius-sm: 10px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Theme → 60 / 30 / 10 ---------- */
:root,
:root[data-theme="light"] {
  --t60: var(--pistachio);
  --t30: var(--ink);
  --t10: var(--raspberry);
  --shadow-src: var(--ink);          /* shadows are a darker 30% tone */
}

:root[data-theme="dark"] {
  --t60: var(--black);
  --t30: var(--ice);
  --t10: var(--aurora);
  --shadow-src: var(--aurora);       /* on black, depth comes from an aurora glow */
}

/* The colours in use. Normal areas: 60 is the background, 30 the text. */
:root { --c60: var(--t60); --c30: var(--t30); --c10: var(--t10); }

/* Inverse blocks (nav, marquee, skills band, contact card): 30 becomes the background. */
.swap { --c60: var(--t30); --c30: var(--t60); }

/* ---------- Semantic tokens (declared on :root AND .swap so they recompute inside inverse blocks) ---------- */
:root,
.swap {
  --bg: var(--c60);
  --bg-2: color-mix(in srgb, var(--c60) 92%, var(--c10));
  --surface: color-mix(in srgb, var(--c60) 88%, var(--c30));
  --card-bg: color-mix(in srgb, color-mix(in srgb, var(--c60) 90%, var(--c30)) 75%, transparent);
  --card-solid: color-mix(in srgb, var(--c60) 93%, var(--c30));
  --border: color-mix(in srgb, var(--c30) 14%, transparent);
  --border-strong: color-mix(in srgb, var(--c10) 55%, transparent);

  --text: var(--c30);
  --muted: color-mix(in srgb, var(--c30) 68%, var(--c60));

  --accent: color-mix(in srgb, var(--c10) 88%, var(--c30));   /* accent for text: nudged toward the text colour for contrast */
  --accent2: var(--c10);                                       /* pure accent for fills */
  --accent-deep: color-mix(in srgb, var(--c10) 75%, var(--c30));
  --accent-glow: color-mix(in srgb, var(--c10) 22%, transparent);
  --on-accent: var(--c60);

  --grid-line: color-mix(in srgb, var(--c10) 35%, transparent);
  --shadow-3d: color-mix(in srgb, var(--shadow-src) 26%, transparent);
  --extrude-1: color-mix(in srgb, var(--c10) 45%, var(--c60));
  --extrude-2: color-mix(in srgb, var(--c10) 70%, var(--c60));
  --live: var(--c10);
  --glare: color-mix(in srgb, var(--c10) 16%, transparent);
  --sheen: color-mix(in srgb, var(--c60) 50%, transparent);
}

/* Inverse blocks paint their own background */
.swap { background-color: var(--bg); color: var(--text); }
