/* ==========================================================================
   Base: reset, typography, layout primitives
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { overflow-x: clip; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--nav-h) + 1rem); }
body {
  background: var(--gg-color-bg);
  color: var(--gg-color-text);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, picture, svg, video, iframe { display: block; max-width: 100%; }
img { height: auto; }
input, button, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
a { color: inherit; text-decoration: none; }
ul[role="list"], ol[role="list"] { list-style: none; padding: 0; }
p, li { text-wrap: pretty; }
h1, h2, h3, h4 { text-wrap: balance; font-weight: 900; }

::selection { background: var(--gg-color-accent); color: var(--gg-color-accent-contrast); }
:focus-visible { outline: 3px solid var(--gg-color-accent); outline-offset: 3px; border-radius: 2px; }
html { scrollbar-color: var(--gg-color-line) var(--gg-color-bg); }

/* ---- type ---- */
.display, h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 900;
  text-transform: uppercase;
  line-height: var(--lh-display);
  letter-spacing: 0;
}
.h2 { font-size: var(--fs-h2); }
.h2--home { font-size: var(--fs-h2-home); }
.h3 { font-size: var(--fs-h3); line-height: 0.92; }
.label {
  font-family: var(--font-body);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--gg-color-text-muted);
}
.label--accent { color: var(--gg-color-accent); }
.lead { font-size: var(--fs-lead); line-height: 1.6; }
.muted { color: var(--gg-color-text-muted); }
.measure { max-width: 34rem; }
.tabular { font-variant-numeric: tabular-nums; }

/* ---- layout ---- */
.wrap { width: 100%; max-width: calc(var(--content-max) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section-y); }
.section--surface { background: var(--gg-color-surface); }
.section--flush-top { padding-top: 0; }
.section--rule { border-top: 1px solid var(--gg-color-line); }
.stack > * + * { margin-top: var(--stack, var(--space-5)); }
.section-head {
  display: grid; gap: var(--space-5); align-items: end;
  margin-bottom: clamp(2rem, 1rem + 3vw, 4rem);
}
@media (min-width: 900px) {
  .section-head { grid-template-columns: 1fr minmax(18rem, 26rem); gap: var(--space-9); }
}

.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-4); top: -4rem; z-index: 100;
  background: var(--gg-color-accent); color: var(--gg-color-accent-contrast);
  padding: var(--space-3) var(--space-5); font-weight: 600;
}
.skip-link:focus { top: var(--space-4); }
