@layer base {
  @font-face {
    font-family: "Space Grotesk";
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url("/assets/fonts/space-grotesk-latin.woff2") format("woff2");
  }

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

  html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

  body {
    font-family: var(--font-body);
    font-size: var(--step-0);
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    min-height: 100svh;
  }

  h1, h2, h3, h4 {
    font-family: var(--font-display);
    line-height: 1.08;
    font-weight: 600;
    letter-spacing: -.015em;
    text-wrap: balance;
  }
  h1 { font-size: var(--step-5); }
  h2 { font-size: var(--step-3); }
  h3 { font-size: var(--step-1); }

  p { text-wrap: pretty; }
  p, li { max-width: 68ch; }

  a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: .18em; }
  a:hover { text-decoration-thickness: 2px; }

  img, svg, picture { display: block; max-width: 100%; height: auto; }
  ul, ol { list-style: none; padding: 0; }

  :focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
  :target { scroll-margin-top: calc(var(--header-h) + 1rem); }

  ::selection { background: var(--brand-gold); color: var(--brand-gold-ink); }

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