:root {
  --paper: oklch(96.7% 0.005 90);
  --ink: oklch(17% 0.012 250);
  --ink-muted: oklch(44% 0.012 250);
  --rule: oklch(17% 0.012 250 / 0.12);
  --accent: oklch(52% 0.23 262);
  --brand: #0066ff;
  --stop: var(--brand);
  --backdrop: oklch(17% 0.012 250 / 0.035);
  --selection: oklch(52% 0.23 262 / 0.18);

  --font-display: "Inter", system-ui, sans-serif;
  --font-body: "Geist", ui-sans-serif, -apple-system, "Segoe UI", sans-serif;

  --gutter: max(1rem, env(safe-area-inset-left), min(5vw, 4rem));
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: oklch(17.5% 0.01 250);
    --ink: oklch(95.5% 0.006 90);
    --ink-muted: oklch(74% 0.01 250);
    --rule: oklch(95.5% 0.006 90 / 0.14);
    --accent: oklch(72% 0.15 258);
    --backdrop: oklch(95.5% 0.006 90 / 0.03);
    --stop: oklch(62% 0.21 260);
    --selection: oklch(72% 0.15 258 / 0.3);
  }
}

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

html,
body {
  overflow-x: clip;
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: var(--selection);
}

p {
  margin: 0;
}

a {
  color: inherit;
}

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

.page {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100dvh;
  max-width: 80rem;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.masthead {
  padding-top: max(clamp(1.5rem, 5vh, 3rem), env(safe-area-inset-top));
}

.wordmark {
  display: block;
  width: auto;
  height: clamp(1.25rem, 1rem + 0.8vw, 1.625rem);
  color: var(--ink);
}

.wordmark-bar {
  fill: var(--brand);
}

.hero {
  align-self: center;
  padding-block: clamp(3.5rem, 12vh, 8rem);
  max-width: 62rem;
}

.kicker {
  color: var(--ink-muted);
  font-size: 0.9375rem;
  font-weight: 500;
}

.headline {
  margin: 1rem 0 0;
  max-width: 11ch;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(3.25rem, 1.4rem + 8.6vw, 8.75rem);
  line-height: 0.92;
  letter-spacing: -0.055em;
  text-wrap: balance;
  overflow-wrap: break-word;
  min-width: 0;
}

.stop {
  color: var(--stop);
}

.lede {
  margin-top: clamp(1.5rem, 3vw, 2.25rem);
  max-width: 34ch;
  color: var(--ink-muted);
  font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.3125rem);
  line-height: 1.5;
  text-wrap: balance;
}

.contact {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.25rem 1rem;
  margin-top: clamp(2.5rem, 6vh, 4rem);
}

.contact-label {
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

.contact-link {
  position: relative;
  display: inline-block;
  padding-block: 0.5rem;
  font-size: clamp(1.25rem, 1.1rem + 0.6vw, 1.625rem);
  font-weight: 500;
  letter-spacing: -0.01em;
  text-decoration: none;
  transition: color 160ms ease;
}

.contact-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.25rem;
  height: 2px;
  background: var(--brand);
  transform-origin: left;
  transition: transform 300ms var(--ease-out);
}

.contact-link:hover {
  color: var(--accent);
}

.contact-link:hover::after {
  transform: scaleX(0.35);
}

.colophon {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem 2rem;
  padding-block: 1.25rem max(1.5rem, env(safe-area-inset-bottom));
  border-top: 1px solid var(--rule);
  color: var(--ink-muted);
  font-size: 0.875rem;
}

.nowrap {
  white-space: nowrap;
}

.backdrop {
  position: fixed;
  z-index: 0;
  right: -18vmin;
  bottom: -14vmin;
  width: 78vmin;
  height: 78vmin;
  fill: var(--backdrop);
  pointer-events: none;
}

@media (max-width: 40rem) {
  .backdrop {
    display: none;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .wordmark,
  .kicker,
  .headline,
  .lede,
  .contact,
  .colophon,
  .backdrop {
    animation: rise 900ms var(--ease-out) both;
  }

  .wordmark { animation-name: fade; animation-duration: 700ms; }
  .kicker { animation-delay: 120ms; --rise: 0.5rem; }
  .headline { animation-delay: 200ms; animation-duration: 1100ms; --rise: 1.5rem; }
  .lede { animation-delay: 420ms; --rise: 0.75rem; }
  .contact { animation-delay: 560ms; --rise: 0.5rem; }
  .colophon { animation-name: fade; animation-delay: 720ms; }
  .backdrop { animation-name: fade; animation-delay: 400ms; animation-duration: 1600ms; }

  .stop {
    display: inline-block;
    animation: land 700ms var(--ease-out) 900ms both;
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(var(--rise, 1rem));
  }
}

@keyframes fade {
  from {
    opacity: 0;
  }
}

@keyframes land {
  from {
    opacity: 0;
    transform: translateY(-0.35em);
  }
}
