/* Reset, typography, focus, buttons-agnostic utilities. */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; background: var(--bg); color: var(--ink);
  font: var(--text-md)/1.5 var(--font); -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { margin: 0; line-height: 1.2; font-weight: 800; letter-spacing: -0.01em; }
p { margin: 0; }
a { color: var(--ac); }
img { display: block; max-width: 100%; height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: 0.55; }

/* Focus: solid accent ring (3:1 non-text contrast); --line-focus is the softer glow on inputs. */
:focus-visible { outline: 2px solid var(--ac); outline-offset: 2px; }

code {
  padding: 2px 7px; border-radius: 5px; background: var(--chip); color: var(--ink);
  font: 500 var(--text-xs) var(--mono);
}

.icon {
  display: inline-block; width: 17px; height: 17px; flex-shrink: 0; vertical-align: middle;
  fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}

.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--mut); }
.lede { color: var(--mut); margin: var(--space-2) 0 var(--space-6); }
.cluster { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); }
.stack { display: grid; gap: var(--space-3); }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: var(--space-2); top: -4rem; z-index: 300;
  padding: var(--space-2) var(--space-4); background: var(--surface); color: var(--ac);
  border-radius: var(--radius-sm); box-shadow: var(--shadow-md); font-weight: 700;
}
.skip-link:focus { top: var(--space-2); }

@media (max-width: 48rem) {
  input, select, textarea { font-size: 16px; }
}

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