@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('fonts/inter-roman.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url('fonts/inter-italic.woff2') format('woff2');
}

:root {
  --navy: #070F1E;
  --text: #EEF2F8;
  --text-soft: #8FA0B8;
  --line: rgba(255, 255, 255, 0.12);
  --accent: #3C6DFF;
  --accent-light: #9DBEFF;
  --ok: #4ADE80;
  --err: #FF8B7A;
}

* { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  background: var(--navy);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

/* ---------- Background layers ---------- */
#bg-canvas { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; }

.scrim {
  position: fixed; inset: 0; z-index: 1;
  pointer-events: none;
  background:
    /* accent glow behind the headline */
    radial-gradient(42% 40% at 50% 42%, rgba(60, 109, 255, 0.20) 0%, rgba(60, 109, 255, 0) 70%),
    /* legibility veil, strongest where the text sits */
    radial-gradient(46% 34% at 50% 42%, rgba(7, 15, 30, 0.62) 0%, rgba(7, 15, 30, 0.22) 64%, rgba(7, 15, 30, 0) 100%),
    /* vignette */
    linear-gradient(to bottom, rgba(7,15,30,0.78) 0%, rgba(7,15,30,0) 32%, rgba(7,15,30,0) 68%, rgba(7,15,30,0.88) 100%);
}

/* ---------- Layout ---------- */
.page {
  position: relative;
  z-index: 2;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  max-width: 1100px;
  margin: 0 auto;
  padding: 26px 28px;
}

.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 { display: flex; justify-content: center; padding: 6px 0 0; }
.wordmark {
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.22em;
  color: #fff;
}
.wordmark span { opacity: 0.45; font-weight: 400; }

.stage {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 0;
}

/* ---------- Type ---------- */
h1 {
  margin: 0 0 22px;
  font-size: clamp(38px, 7vw, 82px);
  line-height: 1.02;
  font-weight: 700;
  letter-spacing: -0.035em;
  color: #fff;
  text-wrap: balance;
}
h1 em {
  font-style: italic;
  font-weight: 600;
  background: linear-gradient(100deg, var(--accent-light) 0%, #D8E5FF 55%, var(--accent-light) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.sub {
  margin: 0 0 42px;
  font-size: clamp(16px, 1.7vw, 19px);
  color: var(--text-soft);
  max-width: 44ch;
}

/* ---------- Capture ---------- */
.capture { width: 100%; max-width: 530px; }

.field {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 7px 7px 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  border-radius: 999px;
  backdrop-filter: blur(10px);
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}
.field:focus-within {
  border-color: rgba(60, 109, 255, 0.75);
  background: rgba(255, 255, 255, 0.07);
  box-shadow: 0 0 0 4px rgba(60, 109, 255, 0.14);
}
.field.is-invalid { border-color: var(--err); }

.field input {
  flex: 1;
  min-width: 0;
  padding: 12px 14px;
  font: inherit;
  font-size: 15px;
  color: #fff;
  background: transparent;
  border: 0;
  outline: none;
}
.field input::placeholder { color: rgba(255, 255, 255, 0.34); }

.field button {
  flex-shrink: 0;
  padding: 13px 26px;
  font: inherit;
  font-size: 14.5px;
  font-weight: 600;
  color: #fff;
  background: var(--accent);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.2s ease, transform 0.2s cubic-bezier(.2,.8,.3,1);
}
.field button:hover:not(:disabled) { background: #2E59E8; transform: translateY(-1px); }
.field button:disabled { opacity: 0.5; cursor: default; }

.capture-msg {
  min-height: 22px;
  margin: 14px 0 0;
  font-size: 13.5px;
  color: var(--text-soft);
}
.capture-msg.is-ok { color: var(--ok); }
.capture-msg.is-err { color: var(--err); }

.tagline {
  margin: 30px 0 0;
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.38);
}

/* ---------- Bottom ---------- */
.bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.34);
}
.bottom a { color: var(--text-soft); text-decoration: none; }
.bottom a:hover { color: #fff; }

/* ---------- Responsive ---------- */
@media (max-width: 560px) {
  .field { flex-direction: column; gap: 8px; padding: 8px; border-radius: 22px; }
  .field input { width: 100%; text-align: center; }
  .field button { width: 100%; }
  .bottom { justify-content: center; }
}

/* The background keeps drifting under reduced motion (slowed in script.js);
   only the UI transitions are dropped here. */
@media (prefers-reduced-motion: reduce) {
  .field, .field button { transition: none; }
}
