:root {
  --sky: #e9efeb;
  --sky-low: #d6e1d9;
  --ink: #101916;
  --muted: #52635a;
  --dawn: #f2a47d;
  --error: #b23a22;
  --line: rgba(16, 25, 22, 0.18);
  --display: "Newsreader", "Iowan Old Style", Georgia, serif;
  --body: "Manrope", "Helvetica Neue", sans-serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--sky);
}

body {
  margin: 0;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  color: var(--ink);
  font-family: var(--body);
  background:
    radial-gradient(70% 50% at 72% 62%, rgba(242, 164, 125, 0.22), transparent 72%),
    linear-gradient(180deg, var(--sky) 0%, var(--sky) 56%, var(--sky-low) 100%);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  opacity: 0.035;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");
}

.ambient {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(50% 38% at 18% 8%, rgba(255, 255, 255, 0.5), transparent 70%),
    radial-gradient(42% 32% at 82% 54%, rgba(242, 164, 125, 0.16), transparent 70%);
}

.shell {
  position: relative;
  z-index: 1;
  width: min(100% - 64px, 1240px);
  margin-inline: auto;
}

.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;
}

/* Top bar */

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 26px;
}

.wordmark,
.text-link {
  color: var(--ink);
  text-decoration: none;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.top-right {
  display: flex;
  align-items: center;
  gap: 24px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.text-link {
  border-bottom: 1px solid transparent;
  transition: border-color 160ms ease, color 160ms ease;
}

.text-link:hover {
  border-color: currentColor;
}

/* Hero */

.stage {
  flex: 1;
  display: flex;
  align-items: flex-end;
  padding-top: clamp(32px, 8vh, 96px);
  padding-bottom: clamp(28px, 5vh, 56px);
}

.hero {
  width: 100%;
}

.eyebrow {
  margin: 0 0 clamp(28px, 4.5vh, 48px);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

h1 {
  margin: 0 0 clamp(12px, 2vh, 24px) -0.055em;
  font-family: var(--display);
  font-size: clamp(6rem, 19vw, 17rem);
  font-weight: 300;
  font-variation-settings: "opsz" 72;
  line-height: 0.74;
  letter-spacing: -0.055em;
  white-space: nowrap;
}

.horizon {
  position: relative;
  height: 22px;
  margin-bottom: clamp(22px, 4vh, 40px);
}

.horizon::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(
    90deg,
    var(--ink) 0%,
    var(--ink) 7%,
    var(--line) 42%,
    var(--line) 100%
  );
}

.horizon-glow {
  position: absolute;
  top: -1px;
  left: 0;
  width: min(34%, 420px);
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--dawn) 35%, transparent);
  filter: blur(1.5px);
  box-shadow: 0 0 34px 7px rgba(242, 164, 125, 0.3);
  transform-origin: left center;
}

.clock {
  position: absolute;
  right: 0;
  top: 8px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.thanks-title {
  font-size: clamp(4rem, 12vw, 11rem);
}

.hero-foot {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(320px, 0.88fr);
  gap: clamp(32px, 7vw, 96px);
  align-items: start;
}

.lede {
  max-width: 43ch;
  margin: 0;
  font-size: clamp(1rem, 1.35vw, 1.18rem);
  line-height: 1.55;
  letter-spacing: -0.01em;
  text-wrap: pretty;
}

.signup {
  width: 100%;
  max-width: 430px;
  justify-self: end;
}

.signup-label {
  margin: 0 0 10px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

#waitlist-form {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 7px;
}

#email {
  min-width: 0;
  flex: 1;
  border: 0;
  background: transparent;
  padding: 8px 0;
  color: var(--ink);
  font-family: var(--body);
  font-size: 15px;
  letter-spacing: -0.01em;
  outline: none;
}

#email::placeholder {
  color: var(--muted);
  opacity: 0.75;
}

#waitlist-form:focus-within {
  border-color: var(--error);
}

button {
  flex: none;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: var(--ink);
  color: var(--sky);
  padding: 11px 14px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

button:hover {
  border-color: var(--error);
  background: var(--error);
}

button:disabled {
  cursor: wait;
  opacity: 0.55;
}

.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-note,
.form-status {
  margin: 9px 0 0;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.03em;
  line-height: 1.5;
}

.form-note {
  color: var(--muted);
}

.form-status {
  min-height: 14px;
  color: var(--ink);
}

.form-status.is-error {
  color: var(--error);
}

/* Footer */

.footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  border-top: 1px solid var(--line);
  padding-block: 18px 26px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.footer .text-link {
  color: var(--ink);
}

/* Focus */

:focus-visible {
  outline: 2px solid var(--error);
  outline-offset: 4px;
}

/* Entrance */

@media (prefers-reduced-motion: no-preference) {
  .eyebrow,
  h1,
  .horizon,
  .hero-foot {
    animation: rise 900ms cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  h1 {
    animation-delay: 70ms;
  }

  .horizon {
    animation-delay: 150ms;
  }

  .hero-foot {
    animation-delay: 230ms;
  }

  .horizon-glow {
    animation: sweep 1300ms cubic-bezier(0.22, 1, 0.36, 1) 260ms both;
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes sweep {
  from {
    opacity: 0;
    transform: translateX(-18%) scaleX(0.3);
  }
  to {
    opacity: 1;
    transform: translateX(250%) scaleX(1);
  }
}

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

@media (max-width: 760px) {
  .shell {
    width: calc(100% - 40px);
  }

  .top {
    padding-block: 20px;
  }

  .top-right {
    gap: 16px;
  }

  .stage {
    padding-top: 32px;
    padding-bottom: 26px;
  }

  h1 {
    font-size: clamp(5rem, 22vw, 8.5rem);
  }

  .hero-foot {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .signup {
    justify-self: start;
    max-width: none;
  }

  .footer {
    flex-wrap: wrap;
    gap: 8px 18px;
  }
}

@media (max-height: 720px) and (min-width: 761px) {
  .stage {
    padding-top: 24px;
    padding-bottom: 22px;
  }

  h1 {
    font-size: clamp(5rem, 14vw, 12rem);
  }

  .eyebrow {
    margin-bottom: 14px;
  }

  .horizon {
    margin-bottom: 20px;
  }
}
