/* Readprint — base & primitives
   Reset, document defaults, type-helper classes, scroll-reveal utilities, buttons.
   Loaded after tokens.css, before component styles. */

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img, svg { display: block; }
::selection { background: var(--green); color: #fff; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }

/* ── layout vocabulary ──
   The vanilla "primitives": compose any section from .wrap (width) + .stack /
   .row (direction) + a gap-* and align/justify modifier. Spacing comes from the
   --s-* scale in tokens.css — never a bespoke gap. See CLAUDE.md "Layout".
   .block = standard section vertical rhythm. */
.block { padding-block: var(--s-4xl); }
.stack { display: flex; flex-direction: column; gap: var(--gap, var(--s-md)); }
.row   { display: flex; flex-flow: row wrap; align-items: center; gap: var(--gap, var(--s-md)); }
.row.nowrap { flex-wrap: nowrap; }

.gap-xs  { --gap: var(--s-xs); }
.gap-sm  { --gap: var(--s-sm); }
.gap-md  { --gap: var(--s-md); }
.gap-lg  { --gap: var(--s-lg); }
.gap-xl  { --gap: var(--s-xl); }
.gap-2xl { --gap: var(--s-2xl); }
.gap-3xl { --gap: var(--s-3xl); }

.items-start   { align-items: flex-start; }
.items-center  { align-items: center; }
.items-end     { align-items: flex-end; }
.items-stretch { align-items: stretch; }

.justify-center  { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end     { justify-content: flex-end; }

.center-text { text-align: center; }

/* ── type helpers ── */
.h2 {
  font-family: var(--font-head); font-weight: 600;
  font-size: clamp(32px, 5.2vw, 70px); line-height: 1.02; letter-spacing: -.035em;
}
.h3 {
  font-family: var(--font-head); font-weight: 600;
  font-size: clamp(24px, 2.8vw, 40px); line-height: 1.08; letter-spacing: -.02em;
}
.lede {
  font-family: var(--font-body); font-weight: 400;
  font-size: clamp(17px, 1.5vw, 21px); line-height: 1.55; color: var(--ink-2);
}

/* ── scroll reveal (driven by ui/lib/reveal.js) ── */
.reveal { opacity: 0; transform: translateY(34px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-d="1"] { transition-delay: .1s; }
.reveal[data-d="2"] { transition-delay: .2s; }
.reveal[data-d="3"] { transition-delay: .3s; }
.reveal[data-d="4"] { transition-delay: .4s; }

/* ── buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  height: 54px; padding: 0 30px; border-radius: var(--r-pill); border: none;
  font-family: var(--font-body); font-weight: 600; font-size: 16px;
  cursor: pointer; transition: transform .18s var(--ease), background .2s, color .2s, box-shadow .2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-press); }
.btn-sm { height: 42px; padding: 0 20px; font-size: 14.5px; }

/* ── global reduced-motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
  .reveal { opacity: 1 !important; transform: none !important; }
}
