/* ============================================================
   base.css — reset + tipografía base
   ============================================================ */

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

html {
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
  font-feature-settings: 'kern' 1, 'liga' 1, 'ss01' 1;
}

body, h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd { margin: 0; }
ul[role='list'], ol[role='list'] { list-style: none; padding: 0; margin: 0; }
ul, ol { padding-inline-start: 1.25em; }

a:not([class]) {
  color: currentColor;
  text-decoration-skip-ink: auto;
}

img, picture, svg, video, canvas { max-width: 100%; display: block; height: auto; }
input, button, textarea, select { font: inherit; color: inherit; }

button { background: none; border: 0; cursor: pointer; padding: 0; }

::selection {
  background: var(--primary);
  color: var(--bg);
}

body {
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: var(--lh-body);
  color: var(--ink);
  background: var(--bg);
  font-feature-settings: 'kern' 1, 'liga' 1;
}

/* ---------- Display typography ---------- */

.display, h1.display, .h-display {
  font-family: var(--font-display);
  font-weight: 500;
  font-style: normal;
  letter-spacing: var(--tracking-tight);
  line-height: var(--lh-display);
}

h1, .h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--step-6);
  letter-spacing: var(--tracking-tight);
  line-height: var(--lh-display);
  text-wrap: balance;
}

h2, .h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--step-4);
  letter-spacing: var(--tracking-flat);
  line-height: var(--lh-tight);
  text-wrap: balance;
}

h3, .h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--step-2);
  letter-spacing: var(--tracking-flat);
  line-height: var(--lh-tight);
  text-wrap: balance;
}

h4, .h4 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--step-1);
  line-height: var(--lh-tight);
  letter-spacing: 0;
}

p { text-wrap: pretty; }

/* ---------- Helpers ---------- */

.eyebrow {
  font-family: var(--font-mono);
  text-transform: uppercase;
  font-size: var(--step--2);
  letter-spacing: var(--tracking-loose);
  color: var(--muted);
  font-weight: 500;
}

.meta {
  font-family: var(--font-mono);
  font-size: var(--step--2);
  letter-spacing: var(--tracking-mono);
  color: var(--muted);
  text-transform: uppercase;
}

.tabular { font-variant-numeric: tabular-nums; font-feature-settings: 'tnum' 1; }

.rule {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 0;
}

.rule-strong {
  border: 0;
  border-top: 1px solid var(--rule-strong);
  margin: 0;
}

.lede {
  font-family: var(--font-display);
  font-style: normal;
  font-weight: 400;
  font-size: var(--step-2);
  line-height: 1.35;
  color: var(--ink);
  letter-spacing: var(--tracking-flat);
  text-wrap: pretty;
}

.prose {
  max-width: 62ch;
  font-size: var(--step-1);
  line-height: 1.65;
}
.prose p + p { margin-top: 1.25em; }
.prose strong { font-weight: 600; color: var(--ink); }

.serif { font-family: var(--font-display); }
.mono  { font-family: var(--font-mono); }

.muted { color: var(--muted); }
.ink-soft { color: var(--ink-soft); }

/* focus visible */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

@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;
  }
}
