/* ============================================================
   Kheiri Lab — Base element styles & primitives
   ------------------------------------------------------------
   A light reset plus default element styling derived from tokens.
   Also defines a few brand primitives (.eyebrow, .lab-mark) used
   across cards and the UI kit.
   ============================================================ */

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--body-font);
  font-size: var(--text-base);
  line-height: var(--body-leading);
  color: var(--text-body);
  background: var(--surface-page);
  font-weight: var(--fw-regular);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--heading-font);
  color: var(--text-strong);
  font-weight: var(--fw-medium);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-snug);
  margin: 0 0 0.5em;
  text-wrap: balance;
}

h1 { font-size: var(--text-3xl); line-height: var(--leading-tight); letter-spacing: var(--tracking-tight); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }

p { margin: 0 0 1em; text-wrap: pretty; }

a {
  color: var(--accent);
  text-decoration-color: color-mix(in oklch, var(--accent) 35%, transparent);
  text-underline-offset: 0.16em;
  transition: color var(--dur-fast) var(--ease-out);
}
a:hover { color: var(--accent-hover); }

strong { font-weight: var(--fw-semibold); color: var(--text-strong); }

::selection { background: var(--accent-tint-2); color: var(--ink-900); }

:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

hr {
  border: none;
  border-top: var(--border-width) solid var(--border-hair);
  margin: var(--space-6) 0;
}

/* ---- Brand primitives ---- */

/* Mono eyebrow / kicker label */
.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--eyebrow-size);
  font-weight: var(--fw-medium);
  letter-spacing: var(--eyebrow-tracking);
  text-transform: uppercase;
  color: var(--accent);
}
.eyebrow--muted { color: var(--text-muted); }
.eyebrow--teal  { color: var(--secondary); }

/* A thin index numeral, e.g. "01 / TME" */
.index-num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}

/* Reading measure */
.measure { max-width: var(--container-text); }
