@font-face {
  font-family: "Geist";
  src: url("fonts/geist-latin-wght-normal.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Geist Mono";
  src: url("fonts/geist-mono-latin-wght-normal.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-display: swap;
}

/* Tokens. One accent, sharp corners everywhere. */
:root {
  color-scheme: dark;
  --bg: #0c0d0f;
  --fg: #e8e8e6;
  --muted: #9a9ca1;
  --accent: #e5383b;
  /* Volatility ramp: low -> mid -> high. High is the page accent. */
  --c-low: #52b4c0;
  --c-mid: #d8dbe0;
  --c-high: #ee4a4d;
  --glow: rgba(82, 180, 192, 0.18);
  --vignette: rgba(0, 0, 0, 0.5);
  --grain: 0.08;
  --cta-hover: #d42a2e;
  --on-red: #f4f4f2;
  --gutter: clamp(20px, 6vw, 96px);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html, body {
  height: 100%;
  overflow: hidden;
}

body {
  min-height: 100dvh;
  height: 100dvh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  background:
    radial-gradient(ellipse 55% 60% at 70% 40%, var(--glow), transparent 70%),
    radial-gradient(ellipse 120% 100% at 50% 45%, transparent 55%, var(--vignette)),
    var(--bg);
  color: var(--fg);
  font-family: "Geist", ui-sans-serif, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

#field {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  /* Fade the surface out behind the copy. */
  -webkit-mask-image: linear-gradient(to right, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.5) 30%, #000 55%);
  mask-image: linear-gradient(to right, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.5) 30%, #000 55%);
}
@media (max-width: 767px) {
  #field {
    -webkit-mask-image: linear-gradient(to bottom, #000 40%, rgba(0, 0, 0, 0.4) 72%);
    mask-image: linear-gradient(to bottom, #000 40%, rgba(0, 0, 0, 0.4) 72%);
  }
}

.bar,
.hero { position: relative; padding-inline: var(--gutter); }

.bar {
  height: 72px;
  display: flex;
  align-items: center;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  font-size: 22.5px;
  letter-spacing: -0.02em;
  font-weight: 400;
}
.brand b { font-weight: 600; }
.brand-mark {
  width: 13.5px;
  height: 13.5px;
  background: var(--accent);
}

.hero {
  align-self: end;
  padding-bottom: clamp(32px, 9vh, 112px);
  max-width: calc(36rem + var(--gutter));
}

h1 {
  font-size: clamp(1.75rem, 7.6vw, 4.75rem);
  font-weight: 500;
  line-height: 1.02;
  letter-spacing: -0.04em;
  white-space: nowrap;
}

.cta {
  display: inline-block;
  margin-top: 36px;
  padding: 15px 26px;
  border: 1px solid var(--fg);
  color: var(--fg);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-decoration: none;
  white-space: nowrap;
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  transition: background-color 0.35s var(--ease), border-color 0.35s var(--ease), color 0.35s var(--ease), transform 0.2s var(--ease);
}
.cta:hover { background: var(--cta-hover); border-color: var(--cta-hover); color: var(--on-red); }
.cta:active { transform: scale(0.98); }
.cta:focus-visible,
.brand:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.foot {
  height: 64px;
  color: var(--muted);
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 12px;
  letter-spacing: 0.02em;
}

/* Entrance: text settles after the field begins to form. */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    animation: rise 1.2s var(--ease) both;
    animation-delay: calc(900ms + var(--i) * 140ms);
  }
  @keyframes rise {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: none; }
  }
}

@media (max-width: 767px) {
  .bar { height: 64px; }
  .hero { padding-bottom: 28px; }
  .cta { margin-top: 28px; }
  .foot { height: 56px; }
}

/* Short landscape screens: keep everything inside the viewport. */
@media (max-height: 520px) {
  h1 { font-size: clamp(2rem, 4vw, 3rem); }
  .hero { padding-bottom: 16px; }
  .cta { margin-top: 18px; padding: 12px 22px; }
}

/* Fine grain over everything. Fixed and non-interactive so it never repaints on scroll. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: var(--grain);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
