/* Reset, typography and small layout utilities. Components live in components.css. */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scroll-padding-top: calc(var(--topbar-h) + 16px);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body.is-scroll-locked {
  overflow: hidden;
  padding-right: var(--scrollbar-gap, 0px);
}

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--ink);
  letter-spacing: var(--track-display);
  line-height: var(--lh-tight);
  text-wrap: balance;
}
h1 { font-size: var(--fs-2xl); }
h2 { font-size: var(--fs-xl); }
h3 { font-size: var(--fs-lg); letter-spacing: var(--track-tight); line-height: var(--lh-snug); }
h4 { font-size: var(--fs-md); letter-spacing: var(--track-tight); line-height: var(--lh-snug); font-weight: 600; }
p { text-wrap: pretty; }

a { color: var(--purple); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--purple-hover); }
strong, b { font-weight: 600; }
small { font-size: var(--fs-sm); }

img, svg, video { display: block; max-width: 100%; }
svg.icon { flex: none; }
img { height: auto; }

button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
button:disabled { cursor: not-allowed; }
[hidden] { display: none !important; }

code, kbd, samp { font-family: ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace; font-size: .9em; }
hr { border: 0; border-top: 1px solid var(--line); margin: var(--s-6) 0; }

::selection { background: var(--purple-soft); color: var(--purple-dark); }

:focus-visible { outline: var(--focus); outline-offset: 2px; }
:focus:not(:focus-visible) { outline: none; }
[tabindex="-1"]:focus { outline: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------------------------------------------------------------- type helpers */
.display { font-family: var(--font-display); font-weight: 500; letter-spacing: var(--track-display); line-height: var(--lh-tight); }
.display-xl { font-size: clamp(38px, 6vw, var(--fs-5xl)); }
.display-lg { font-size: clamp(30px, 4.6vw, var(--fs-4xl)); }
.display-md { font-size: clamp(26px, 3.6vw, var(--fs-3xl)); }
.eyebrow {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--purple);
}
.lead { font-size: var(--fs-md); color: var(--ink-2); line-height: 1.5; }
.muted { color: var(--ink-2); }
.subtle { color: var(--ink-muted); }
.small { font-size: var(--fs-sm); }
.tiny { font-size: var(--fs-xs); }
.strong { font-weight: 600; }
.num { font-variant-numeric: tabular-nums; }
.nowrap { white-space: nowrap; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.center { text-align: center; }

/* ---------------------------------------------------------------- layout helpers */
.stack { display: flex; flex-direction: column; gap: var(--gap, var(--s-4)); }
.row { display: flex; align-items: center; gap: var(--gap, var(--s-3)); min-width: 0; }
.row-top { align-items: flex-start; }
.wrap { flex-wrap: wrap; }
.spread { justify-content: space-between; }
.grow { flex: 1 1 auto; min-width: 0; }
.push { margin-left: auto; }
.gap-1 { --gap: var(--s-1); }
.gap-2 { --gap: var(--s-2); }
.gap-3 { --gap: var(--s-3); }
.gap-4 { --gap: var(--s-4); }
.gap-6 { --gap: var(--s-6); }
.gap-8 { --gap: var(--s-8); }
.grid { display: grid; gap: var(--gap, var(--s-4)); }
.grid-2 { display: grid; gap: var(--gap, var(--s-4)); grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.grid-3 { display: grid; gap: var(--gap, var(--s-4)); grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }
.grid-4 { display: grid; gap: var(--gap, var(--s-4)); grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); }
.divider { height: 1px; background: var(--line); border: 0; margin: var(--s-4) 0; }

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

@media (max-width: 719px) { .hide-mobile { display: none !important; } }
@media (min-width: 720px) { .hide-desktop { display: none !important; } }
