/* INTERPOLAR — colors, type, and semantic tokens
   ------------------------------------------------------
   source of truth: source/interpolar-brand-styles.css
   this file is the distilled, machine-portable token layer.
   paper · ink · stone. geist sans · geist mono. nothing else.
   ------------------------------------------------------ */

@import url('https://fonts.googleapis.com/css2?family=Geist+Mono:wght@400;500&display=swap');

/* Geist Sans — self-hosted variable font (brand-supplied).
   wght axis 100–900. optical sizing handled automatically by the renderer
   when `font-optical-sizing: auto` is set on html/body. */
@font-face {
  font-family: 'Geist';
  src: url('fonts/Geist-VariableFont_wght.ttf') format('truetype-variations'),
       url('fonts/Geist-VariableFont_wght.ttf') format('truetype');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  /* -------- color (§03) — three values. nothing else. -------- */
  --paper: #f4f4f4;  /* backgrounds. negative space. document base. */
  --ink:   #0a0a0a;  /* all type. logo. hairlines when structural.  */
  --stone: #6b6b6b;  /* rules. dividers only. never for type.       */

  /* signal accent (§03a) — ice blue. very rarely used. never decorative.
     reserved for: live status, active links in running systems, critical
     telemetry. not for marketing. not for buttons. not for backgrounds.
     budget: one instance per screen. if in doubt, do not use. */
  --ice:   #B8D4E8;

  /* opacity ramps on ink — for hairlines and secondary text */
  --ink-70: rgba(10, 10, 10, 0.70);
  --ink-60: rgba(10, 10, 10, 0.60);
  --ink-40: rgba(10, 10, 10, 0.40);
  --ink-20: rgba(10, 10, 10, 0.18);
  --ink-10: rgba(10, 10, 10, 0.10);

  /* -------- depth (§10) — paired shadow. top-left light source. -------- */
  --elev-raised:    -6px -6px 16px rgba(255,255,255,0.9),  6px  6px 16px rgba(10,10,10,0.07);
  --elev-raised-sm: -3px -3px  8px rgba(255,255,255,0.9),  3px  3px  8px rgba(10,10,10,0.06);
  --elev-inset:     inset -4px -4px 10px rgba(255,255,255,0.9), inset 4px 4px 10px rgba(10,10,10,0.06);
  --elev-pressed:   inset -2px -2px  5px rgba(255,255,255,0.8), inset 2px 2px  5px rgba(10,10,10,0.06);

  /* -------- type families (§02) — two families, no exceptions. -------- */
  --font-sans: 'Geist', 'Geist Sans', 'Helvetica Neue', system-ui, sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, monospace;

  /* -------- type scale, web (§02) — fluid, clamped. -------- */
  --t-display:  clamp(48px, 8vw, 120px);
  --t-h1:       clamp(32px, 5vw, 64px);
  --t-h2:       clamp(24px, 3vw, 40px);
  --t-h3:       18px;
  --t-body:     16px;
  --t-body-sm:  15px;
  --t-caption:  13px;
  --t-mono:     12px;
  --t-mono-sm:  11px;

  /* -------- baseline + spacing — 12pt baseline grid -------- */
  --b:   12px;
  --b2:  24px;
  --b3:  36px;
  --b4:  48px;
  --b6:  72px;
  --b8:  96px;
  --b12: 144px;
  --b16: 192px;

  /* -------- layout (§05) — left aligned, 12 col, 1200 max, 24 gutter -------- */
  --max:    1200px;
  --gutter: 24px;
  --margin: clamp(24px, 5vw, 72px);

  /* -------- motion (§07) — 400ms ease-out, no overshoot -------- */
  --ease: cubic-bezier(0, 0, 0.2, 1);
  --dur:  400ms;

  /* -------- radius — never above 4px on containers, except surfaces -------- */
  /* the anti-pattern rule bans rounded corners above 4px; surfaces in the
     depth system use 20/32/999 deliberately (depth requires softened edges).
     use --r-container for boxes; --r-surface for depth primitives. */
  --r-container: 0px;
  --r-hair:      2px;
  --r-surface:   20px;
  --r-surface-lg:32px;
  --r-pill:      999px;
}

/* ============================================================
   semantic classes — the base element styles.
   use these when writing markup. ============================ */

html, body {
  margin: 0; padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--t-body);
  font-weight: 400;
  font-optical-sizing: auto;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

/* no italics, ever (§02 forbidden) */
i, em, cite { font-style: normal; }

a { color: inherit; text-decoration: none; }
a:hover { opacity: 0.7; }
a.linked { text-decoration: underline; text-underline-offset: 2px; }

::selection { background: var(--ink); color: var(--paper); }

/* ---- headlines: all caps, tracked, left aligned ---- */
.t-display {
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: var(--t-display);
  line-height: 0.96;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
/* poster / marketing display — lowercase, heavy, tight.
   use for hero-scale editorial moments only. structural titles stay .t-display. */
.t-display-low {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: var(--t-display);
  line-height: 0.98;
  letter-spacing: -0.02em;
  text-transform: lowercase;
}
.t-h1 {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: var(--t-h1);
  line-height: 1.02;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.t-h2 {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: var(--t-h2);
  line-height: 1.08;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.t-h3 {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: var(--t-h3);
  line-height: 1.3;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ---- body + caption: lowercase, natural tracking ---- */
.t-body {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: var(--t-body);
  line-height: 1.6;
  text-transform: lowercase;
}
.t-body-lg {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.5;
  text-transform: lowercase;
}
.t-caption {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: var(--t-caption);
  line-height: 1.5;
  letter-spacing: 0.02em;
  text-transform: lowercase;
}

/* ---- mono: structural labels, trackers, readouts ---- */
.t-mono-label {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: var(--t-mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.t-mono-sm {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: var(--t-mono-sm);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* ---- case + family utility ---- */
.sans      { font-family: var(--font-sans); }
.mono      { font-family: var(--font-mono); }
.caps      { text-transform: uppercase; letter-spacing: 0.04em; }
.caps-wide { text-transform: uppercase; letter-spacing: 0.08em; }
.lower     { text-transform: lowercase; }

/* ---- structural hairlines ---- */
.rule     { height: 1px; background: var(--stone); opacity: 0.4; border: 0; }
.rule-ink { height: 1px; background: var(--ink); border: 0; }

/* ---- layout primitives ---- */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--margin); }
.grid-12 { display: grid; grid-template-columns: repeat(12, 1fr); gap: var(--gutter); }
.left { text-align: left; }

/* ---- depth primitives (§10) ---- */
.surface-raised    { background: var(--paper); border-radius: var(--r-surface);    box-shadow: var(--elev-raised); }
.surface-raised-sm { background: var(--paper); border-radius: 12px;                box-shadow: var(--elev-raised-sm); }
.surface-inset     { background: var(--paper); border-radius: var(--r-surface);    box-shadow: var(--elev-inset); }
.surface-pressed   { background: var(--paper); border-radius: var(--r-pill);       box-shadow: var(--elev-pressed); }

/* ---- reveal on scroll (§07) ---- */
.reveal {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
  will-change: opacity, transform;
}
.reveal.in { opacity: 1; transform: translateY(0); }

/* ---- focus ---- */
:focus-visible { outline: 1px solid var(--ink); outline-offset: 3px; }

/* ---- numbered prefix replaces bullets (§02 forbidden: bullet glyphs) ---- */
.num-list { list-style: none; padding: 0; margin: 0; counter-reset: i; }
.num-list > li {
  counter-increment: i;
  padding: var(--b2) 0;
  border-top: 1px solid var(--ink-10);
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: var(--b2);
}
.num-list > li::before {
  content: counter(i, decimal-leading-zero);
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: var(--t-mono-sm);
  letter-spacing: 0.12em;
  color: var(--stone);
}
