:root {
  color-scheme: dark;
  --ink: #070d16;
  --ink-soft: #0e1726;
  --paper: #f6f3ee;
  --paper-dim: #a9b4c4;
  --accent: #2f8f66;
  --accent-lift: #7ff0c0;
  --focus: #9ec4ff;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  font-family: Georgia, "Times New Roman", serif;
  background: var(--ink);
  color: var(--paper);
  -webkit-font-smoothing: antialiased;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* --- stage ------------------------------------------------------------- */

.stage {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(2rem, 6vh, 3.5rem);
  min-height: 100vh;
  min-height: 100svh;
  padding: clamp(2rem, 8vw, 5rem) clamp(1.25rem, 6vw, 4rem);
}

/* Slow off-centre light wash: the only large colour in the composition. */
.aurora {
  position: absolute;
  z-index: -2;
  inset: -40% -20%;
  background:
    radial-gradient(38% 42% at 22% 28%, rgba(47, 143, 102, 0.55), transparent 70%),
    radial-gradient(32% 36% at 78% 24%, rgba(127, 240, 192, 0.22), transparent 72%),
    radial-gradient(46% 50% at 62% 88%, rgba(21, 94, 239, 0.28), transparent 74%);
  filter: blur(60px) saturate(115%);
  animation: drift 34s ease-in-out infinite alternate;
}

/* Hairline grid, faded at the edges, to give the wordmark a surface. */
.veil {
  position: absolute;
  z-index: -1;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(246, 243, 238, 0.07) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(246, 243, 238, 0.07) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(72% 64% at 50% 42%, #000 35%, transparent 100%);
  -webkit-mask-image: radial-gradient(72% 64% at 50% 42%, #000 35%, transparent 100%);
}

@keyframes drift {
  from {
    transform: translate3d(-3%, -2%, 0) scale(1);
  }
  to {
    transform: translate3d(4%, 3%, 0) scale(1.12);
  }
}

/* --- masthead ---------------------------------------------------------- */

.masthead {
  width: min(64rem, 100%);
  margin: 0 auto;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 clamp(1rem, 3vh, 1.75rem);
  padding: 0.4rem 0.9rem 0.4rem 0.7rem;
  border: 1px solid rgba(127, 240, 192, 0.45);
  border-radius: 999px;
  background: rgba(7, 13, 22, 0.55);
  color: var(--accent-lift);
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: clamp(0.7rem, 1.6vw, 0.82rem);
  letter-spacing: 0.34em;
  text-transform: uppercase;
}

.pulse {
  width: 0.5rem;
  height: 0.5rem;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--accent-lift);
  box-shadow: 0 0 0 0 rgba(127, 240, 192, 0.7);
  animation: pulse 2.6s ease-out infinite;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(127, 240, 192, 0.7);
  }
  70%,
  100% {
    box-shadow: 0 0 0 0.75rem rgba(127, 240, 192, 0);
  }
}

.wordmark {
  margin: 0;
  font-size: clamp(3rem, 11vw, 8.5rem);
  font-weight: 400;
  line-height: 0.92;
  letter-spacing: -0.035em;
}

/* Flex keeps the nine glyphs on one line and drops the whitespace that
   would otherwise sit between the per-letter boxes. */
.letters {
  display: flex;
  flex-wrap: nowrap;
}

/* Each glyph lifts in on its own beat, then shares one travelling sheen. */
.letter {
  display: inline-block;
  color: var(--paper);
  animation:
    rise 900ms cubic-bezier(0.22, 1, 0.36, 1) backwards,
    sheen 7s linear 1.2s infinite;
  animation-delay: calc(var(--i) * 70ms), calc(1.2s + var(--i) * 70ms);
}

@supports (background-clip: text) or (-webkit-background-clip: text) {
  .letter {
    background-image: linear-gradient(
      102deg,
      var(--paper) 42%,
      var(--accent-lift) 50%,
      var(--paper) 58%
    );
    background-size: 300% 100%;
    background-position: 0 0;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}

.letter-mark {
  font-style: italic;
  letter-spacing: 0.01em;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translate3d(0, 0.34em, 0);
    filter: blur(12px);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
    filter: blur(0);
  }
}

@keyframes sheen {
  0%,
  45% {
    background-position: 0 0;
  }
  85%,
  100% {
    background-position: 100% 0;
  }
}

/* Signature rail: a token crossing the line, echoing the product loop. */
.rail {
  position: relative;
  height: 1px;
  margin: clamp(1.25rem, 4vh, 2rem) 0 clamp(0.9rem, 2vh, 1.25rem);
  background: linear-gradient(
    to right,
    transparent,
    rgba(246, 243, 238, 0.32) 12%,
    rgba(246, 243, 238, 0.32) 88%,
    transparent
  );
}

.rail-token {
  position: absolute;
  top: -3px;
  left: 0;
  width: 7px;
  height: 7px;
  background: var(--accent-lift);
  box-shadow: 0 0 14px rgba(127, 240, 192, 0.85);
  animation: travel 9s cubic-bezier(0.65, 0, 0.35, 1) 1.6s infinite;
}

@keyframes travel {
  0% {
    left: 8%;
    opacity: 0;
  }
  8%,
  72% {
    opacity: 1;
  }
  92%,
  100% {
    left: 90%;
    opacity: 0;
  }
}

.byline {
  margin: 0;
  color: var(--paper-dim);
  font-size: clamp(1rem, 2.4vw, 1.25rem);
  letter-spacing: 0.02em;
}

.signup {
  width: min(64rem, 100%);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.pitch {
  max-width: 38rem;
}

.pitch-lead {
  margin: 0 0 0.55rem;
  color: var(--paper-dim);
  font-size: 0.82rem;
  line-height: 1.45;
}

.pitch-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.pitch-list li {
  margin: 0;
  padding: 0;
  color: var(--paper-dim);
  font-size: 0.82rem;
  line-height: 1.45;
}

/* --- notify form ------------------------------------------------------- */

.notify {
  width: 100%;
}

.notify-label {
  display: block;
  margin-bottom: 0.55rem;
  color: var(--paper-dim);
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.72rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.notify-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  max-width: 38rem;
}

.notify-input,
.notify-cta {
  min-height: 52px;
  min-width: 44px;
  border-radius: 0;
  font-family: inherit;
  font-size: 1.1rem;
}

.notify-input {
  flex: 1 1 18rem;
  padding: 0.75rem 1rem;
  border: 2px solid rgba(246, 243, 238, 0.35);
  background: rgba(14, 23, 38, 0.72);
  color: var(--paper);
}

.notify-input::placeholder {
  color: rgba(169, 180, 196, 0.7);
}

.notify-cta {
  flex: 0 0 auto;
  padding: 0.75rem 1.6rem;
  border: 2px solid var(--accent-lift);
  background: var(--accent);
  color: #f2fffa;
  cursor: pointer;
}

.notify-cta:hover {
  background: var(--accent-lift);
  color: var(--ink);
}

.notify-input:focus-visible,
.notify-cta:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.notify-cta[disabled] {
  cursor: progress;
  opacity: 0.7;
}

.notify-note {
  max-width: 38rem;
  margin: 0.7rem 0 0;
  color: var(--paper-dim);
  font-size: 0.92rem;
  line-height: 1.45;
}

.notify-status {
  min-height: 1.25rem;
  margin: 0.5rem 0 0;
  color: var(--accent-lift);
  font-size: 1rem;
  line-height: 1.5;
}

.notify-status[data-state="error"] {
  color: #ff9d9d;
}

/* --- motion preference ------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  .aurora,
  .pulse,
  .letter {
    animation: none;
  }

  .letter {
    background-position: 0 0;
  }

  .rail-token {
    left: 90%;
    animation: none;
  }
}
