:root {
  --bg: #071228;
  --bg2: #0b1a3a;
  --surface: rgba(255,255,255,0.05);
  --surface-strong: rgba(255,255,255,0.09);
  --border: rgba(255,255,255,0.12);
  --text: #eef1fb;
  --muted: #97a1c2;
  --accent1: #8f7bff;
  --accent2: #4fd6ff;
  --accent3: #ff9d5c;
  --success: #4fe0a0;
  --danger: #ff6b81;
  --radius: 16px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(ellipse 80% 50% at 50% -10%, #1c3a7a 0%, transparent 60%), linear-gradient(180deg, var(--bg2) 0%, var(--bg) 100%);
  color: var(--text);
  font-family: var(--font);
  overflow-x: hidden;
  position: relative;
}

#starfield {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: block;
}

.scanline {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background: repeating-linear-gradient(to bottom, rgba(255,255,255,0.015) 0px, rgba(255,255,255,0.015) 1px, transparent 1px, transparent 3px);
  mix-blend-mode: overlay;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Topbar */
.topbar {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px clamp(20px, 5vw, 64px) 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  font-size: 15px;
}

.icon-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 13px;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, border-color 0.2s;
  backdrop-filter: blur(8px);
}
.icon-btn:hover { background: var(--surface-strong); border-color: rgba(255,255,255,0.25); }
.icon-btn:active { transform: scale(0.96); }

/* Main / Hero */
main { position: relative; z-index: 2; }

.hero {
  max-width: 760px;
  margin: 0 auto;
  padding: clamp(48px, 10vh, 110px) 24px 40px;
  text-align: center;
}

.eyebrow {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--accent2);
  background: rgba(79,214,255,0.1);
  border: 1px solid rgba(79,214,255,0.25);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 24px;
  animation: pulse-glow 3s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(79,214,255,0.3); }
  50% { box-shadow: 0 0 0 6px rgba(79,214,255,0); }
}

h1 {
  font-size: clamp(2.1rem, 5.5vw, 3.4rem);
  line-height: 1.1;
  margin: 0 0 20px;
  letter-spacing: -0.02em;
}

.grad-text {
  background: linear-gradient(90deg, var(--accent1), var(--accent2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lead {
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.15rem);
  line-height: 1.6;
  max-width: 560px;
  margin: 0 auto 40px;
}

/* Countdown */
.countdown {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.cd-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px 18px;
  min-width: 76px;
  backdrop-filter: blur(10px);
}

.cd-num {
  display: block;
  font-size: clamp(1.4rem, 3.5vw, 2rem);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(180deg, #fff, var(--accent2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.cd-label {
  display: block;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.08em;
  margin-top: 2px;
  text-transform: uppercase;
}

/* Newsletter form */
.newsletter {
  display: flex;
  gap: 10px;
  max-width: 480px;
  margin: 0 auto;
  flex-wrap: wrap;
  justify-content: center;
}

.field {
  position: relative;
  flex: 1 1 260px;
  display: flex;
  align-items: center;
}

.field-icon {
  position: absolute;
  left: 16px;
  color: var(--muted);
  pointer-events: none;
}

.field input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 12px;
  padding: 14px 16px 14px 44px;
  font-size: 15px;
  font-family: inherit;
  transition: border-color 0.2s, background 0.2s;
}

.field input::placeholder { color: var(--muted); }

.field input:focus {
  outline: none;
  border-color: var(--accent2);
  background: rgba(79,214,255,0.06);
}

.field input.invalid {
  border-color: var(--danger);
  animation: shake 0.35s;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

#submitBtn {
  position: relative;
  border: none;
  border-radius: 12px;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  color: #05070f;
  background: linear-gradient(90deg, var(--accent2), var(--accent1));
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.2s, opacity 0.2s;
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 190px;
}

#submitBtn:hover { box-shadow: 0 8px 24px rgba(79,214,255,0.25); transform: translateY(-1px); }
#submitBtn:active { transform: translateY(0); }
#submitBtn:disabled { opacity: 0.75; cursor: default; transform: none; }

.btn-spinner {
  display: none;
  animation: spin 0.8s linear infinite;
}

#submitBtn.loading .btn-label { display: none; }
#submitBtn.loading .btn-spinner { display: block; }

@keyframes spin { to { transform: rotate(360deg); } }

.form-msg {
  min-height: 22px;
  margin: 14px 0 0;
  font-size: 14px;
  font-weight: 600;
  transition: opacity 0.2s;
}
.form-msg.success { color: var(--success); }
.form-msg.error { color: var(--danger); }

/* Social proof */
.social-proof {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
  color: var(--muted);
  font-size: 14px;
}

.avatars { display: flex; }
.avatars span {
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 2px solid var(--bg);
  margin-left: -8px;
  background: linear-gradient(135deg, var(--accent1), var(--accent2));
}
.avatars span:first-child { margin-left: 0; }
.avatars span:nth-child(2) { background: linear-gradient(135deg, var(--accent3), var(--accent1)); }
.avatars span:nth-child(3) { background: linear-gradient(135deg, var(--accent2), var(--success)); }
.avatars span:nth-child(4) { background: linear-gradient(135deg, var(--success), var(--accent3)); }

.social-proof strong { color: var(--text); }

/* Milestones / Timeline */
.milestones {
  max-width: 720px;
  margin: 40px auto 0;
  padding: 40px 24px;
}

.milestones h2 {
  text-align: center;
  font-size: 1.6rem;
  margin-bottom: 32px;
}

.timeline {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 21px;
  top: 12px;
  bottom: 12px;
  width: 2px;
  background: linear-gradient(180deg, var(--accent2), transparent);
  opacity: 0.35;
}

.milestone {
  position: relative;
  display: flex;
  gap: 18px;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  cursor: pointer;
  font-family: inherit;
  color: inherit;
  transition: background 0.2s, border-color 0.2s;
}

.milestone:hover { background: var(--surface-strong); }

.m-dot {
  flex-shrink: 0;
  width: 14px; height: 14px;
  border-radius: 50%;
  margin-top: 5px;
  background: rgba(255,255,255,0.2);
  border: 2px solid rgba(255,255,255,0.3);
  z-index: 1;
}
.m-dot.done { background: var(--success); border-color: var(--success); }
.m-dot.active {
  background: var(--accent2);
  border-color: var(--accent2);
  box-shadow: 0 0 0 4px rgba(79,214,255,0.2);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 4px rgba(79,214,255,0.2); }
  50% { box-shadow: 0 0 0 8px rgba(79,214,255,0.05); }
}

.m-body { flex: 1; min-width: 0; }

.m-head {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.m-tag {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.m-head h3 {
  margin: 2px 0 0;
  font-size: 1.02rem;
  flex: 1;
}

.chev {
  color: var(--muted);
  transition: transform 0.25s;
  flex-shrink: 0;
}

.milestone[data-expanded="true"] .chev { transform: rotate(180deg); }

.m-detail {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
  margin: 0;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.3s ease, margin 0.3s ease;
}

.milestone[data-expanded="true"] .m-detail {
  max-height: 120px;
  opacity: 1;
  margin-top: 10px;
}

/* Features */
.features {
  max-width: 1000px;
  margin: 20px auto 60px;
  padding: 20px 24px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 22px;
  transition: transform 0.2s, border-color 0.2s, background 0.2s;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255,255,255,0.25);
  background: var(--surface-strong);
}

.feature-icon {
  width: 46px; height: 46px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(143,123,255,0.2), rgba(79,214,255,0.2));
  color: var(--accent2);
  margin-bottom: 14px;
}

.feature-card h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.feature-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

/* reveal on scroll */
.feature-card, .milestone {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease, background 0.2s, border-color 0.2s;
}
.feature-card.in-view, .milestone.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* Footer */
footer {
  position: relative;
  z-index: 2;
  border-top: 1px solid var(--border);
  padding: 28px 24px 40px;
}

.footer-inner {
  max-width: 1000px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.foot-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
}

.foot-social {
  display: flex;
  gap: 10px;
}

.foot-social a {
  color: var(--muted);
  display: flex;
  padding: 8px;
  border-radius: 8px;
  transition: color 0.2s, background 0.2s;
}
.foot-social a:hover { color: var(--text); background: var(--surface); }

.foot-legal {
  width: 100%;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
  opacity: 0.7;
  margin: 8px 0 0;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #12162a;
  border: 1px solid var(--border);
  color: var(--text);
  padding: 12px 20px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 12px 32px rgba(0,0,0,0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 8px;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@media (max-width: 480px) {
  .newsletter { flex-direction: column; }
  #submitBtn { width: 100%; }
  .cd-box { min-width: 64px; padding: 10px 12px; }
}
