/* ============================================================
   Base — Reset, Typografie-Defaults, A11y-Defaults
   ============================================================ */

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

* { margin: 0; padding: 0; }

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

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: var(--lh-base);
  letter-spacing: var(--tracking-base);
  font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  overflow-x: hidden;
}

img, picture, video, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: var(--lh-tight);
  letter-spacing: var(--tracking-tight);
  color: var(--color-text);
  text-wrap: balance;
}

p { text-wrap: pretty; max-width: 65ch; }

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
  transition: color var(--dur-fast) var(--ease-out-quart);
}

a:hover { color: var(--color-accent); }

a:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

ul, ol { list-style: none; }

table { border-collapse: collapse; width: 100%; }

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

/* Container */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-px);
}

/* Visually hidden but accessible */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* Skip-link */
.skip-link {
  position: absolute;
  top: -100px;
  left: var(--sp-4);
  background: var(--color-text);
  color: var(--color-bg);
  padding: var(--sp-3) var(--sp-4);
  z-index: 100;
  border-radius: var(--radius-md);
}
.skip-link:focus { top: var(--sp-4); }

/* Section heading shared */
.section {
  padding-block: var(--sp-16);
}

.section--alt {
  background: var(--color-bg-alt);
}

.section--dark {
  background: var(--color-bg-dark);
  color: var(--cream-50);
}
.section--dark h1,
.section--dark h2,
.section--dark h3 { color: var(--cream-50); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: var(--fs-meta);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: var(--tracking-caps);
  color: var(--color-eyebrow);
  margin-bottom: var(--sp-3);
}

.section-head {
  max-width: 60ch;
  margin-bottom: var(--sp-8);
}

.section-head h2 {
  font-size: var(--fs-display-lg);
}

.section-lead {
  font-size: var(--fs-body-lg);
  color: var(--color-text);
  margin-top: var(--sp-3);
  max-width: 55ch;
}

/* Reveal animation (scroll-driven) */
.reveal {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity var(--dur-slow) var(--ease-out-quart),
              transform var(--dur-slow) var(--ease-out-quart);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
