/* MultiTool base · reset, fonts, type roles, layout primitives, background */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: var(--t-15);
  line-height: 1.5;
  font-variation-settings: "wdth" var(--wdth-ui);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  position: relative;
  min-height: 100vh;
  transition: background-color var(--d-3) var(--e-out), color var(--d-3) var(--e-out);
}
/* Aurora + grid: a faint field behind the glass. Fixed, non-interactive, cheap (no blur filter, just gradients). */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60vw 60vw at 8% 0%, oklch(0.78 0.15 157 / calc(0.26 * var(--aurora-a))), transparent 62%),
    radial-gradient(50vw 50vw at 96% 12%, oklch(0.80 0.16 82 / calc(0.22 * var(--aurora-a))), transparent 62%),
    radial-gradient(55vw 55vw at 80% 100%, oklch(0.60 0.22 297 / calc(0.20 * var(--aurora-a))), transparent 62%),
    radial-gradient(45vw 45vw at 10% 90%, oklch(0.66 0.15 235 / calc(0.18 * var(--aurora-a))), transparent 62%);
}
body::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: linear-gradient(180deg, #000 0%, #000 60%, transparent 100%);
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 60%, transparent 100%);
}
[hidden] { display: none !important; }   /* the attribute must win over component display rules (menus, segmented controls, panels) */
img, svg, canvas, video { display: block; max-width: 100%; }
/* sprite icons: <svg><use href="#i-name"/></svg> → outline icons in currentColor */
svg:has(> use) { fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; flex: none; }
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; }
a { color: var(--accent-text); text-decoration-color: color-mix(in oklch, var(--accent-text) 40%, transparent); text-underline-offset: 0.15em; transition: color var(--d-2) var(--e-out), text-decoration-color var(--d-2) var(--e-out); }
a:hover { color: var(--ink); text-decoration-color: var(--g-500); }
:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--r-xs); }
::selection { background: var(--g-300); color: var(--g-950); }
hr { border: 0; border-top: 1px solid var(--line); margin: 0; }
code, kbd, pre, .mono, [data-mono] {
  font-family: var(--font-mono);
  font-variation-settings: "wdth" var(--wdth-mono);
  font-variant-numeric: tabular-nums;
  font-size: 0.875em;
}
small { font-size: var(--t-13); }
strong, b { font-weight: 700; }

/* ── Type roles ───────────────────────────────────────────────── */
.t-display {
  font-family: var(--font-display);
  font-size: var(--t-display);
  font-weight: 900;
  line-height: 0.92;
  letter-spacing: -0.03em;
  font-variation-settings: "wdth" var(--wdth-display);
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
.t-headline {
  font-family: var(--font-display);
  font-size: var(--t-headline);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.02em;
  font-variation-settings: "wdth" 108;
  margin: 0;
  text-wrap: balance;
}
.t-h2 { font-size: var(--t-32); font-weight: 800; line-height: 1.08; letter-spacing: -0.02em; font-variation-settings: "wdth" 106; margin: 0; text-wrap: balance; }
.t-h3 { font-size: var(--t-22); font-weight: 700; line-height: 1.18; letter-spacing: -0.015em; margin: 0; }
.t-title { font-size: var(--t-18); font-weight: 700; line-height: 1.25; letter-spacing: -0.01em; margin: 0; }
.t-lead  { font-size: var(--t-lead); line-height: 1.45; color: var(--ink-2); margin: 0; max-width: 62ch; text-wrap: pretty; }
.t-body  { font-size: var(--t-15); line-height: 1.5; margin: 0; max-width: 68ch; }
.t-small { font-size: var(--t-13); line-height: 1.45; color: var(--ink-2); }
.t-label { font-size: var(--t-13); font-weight: 600; line-height: 1.2; letter-spacing: 0.01em; color: var(--ink-2); }
.t-micro { font-size: var(--t-12); font-weight: 600; line-height: 1.2; letter-spacing: 0.02em; color: var(--ink-3); }
.t-data  { font-family: var(--font-mono); font-variation-settings: "wdth" var(--wdth-mono); font-variant-numeric: tabular-nums; font-size: var(--t-13); font-weight: 500; line-height: 1.4; }
.t-data-lg { font-family: var(--font-mono); font-variation-settings: "wdth" 100; font-variant-numeric: tabular-nums; font-size: var(--t-26); font-weight: 600; line-height: 1.1; letter-spacing: -0.02em; }
.t-num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; font-variation-settings: "wdth" 95; }
.muted { color: var(--ink-3); }
.ink-2 { color: var(--ink-2); }

/* Wordmark: Archivo wdth breathes 112 → 125 on hover. Width axis is the only thing that animates in type. */
.wordmark {
  font-family: var(--font-display);
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 1;
  color: var(--ink);
  text-transform: uppercase;
  font-variation-settings: "wdth" 112;
  transition: font-variation-settings var(--d-4) var(--e-out-x);
  display: inline-block;
  text-decoration: none;
}
.wordmark:hover { font-variation-settings: "wdth" 125; color: var(--ink); }
.wordmark em { font-style: normal; color: var(--ink); }
.wordmark b { font-weight: inherit; }
.wordmark b:nth-of-type(1) { color: var(--g-500); }
.wordmark b:nth-of-type(2) { color: var(--water); }
.wordmark b:nth-of-type(3) { color: var(--stocks); }
.wordmark b:nth-of-type(4) { color: var(--burn); }
.wordmark b:nth-of-type(5) { color: var(--holders); }

/* ── Layout primitives ────────────────────────────────────────── */
.container { width: min(100% - 2 * var(--gutter), var(--container)); margin-inline: auto; }
.container--narrow { width: min(100% - 2 * var(--gutter), var(--container-narrow)); margin-inline: auto; }
.grid { display: grid; gap: var(--s-5); grid-template-columns: repeat(12, minmax(0, 1fr)); }
.stack > * + * { margin-top: var(--s-4); }
.stack-sm > * + * { margin-top: var(--s-2); }
.stack-lg > * + * { margin-top: var(--s-6); }
.row { display: flex; gap: var(--s-3); align-items: center; flex-wrap: wrap; }
.row--between { justify-content: space-between; }
.row--end { justify-content: flex-end; }
.nowrap { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ── Reduced motion: keep feedback, freeze ambience ───────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
