/* ============================================
   Main stylesheet — landing page
   ============================================ */

/* Reset & base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --color-bg: #0d0d0f;
  --color-surface: #141418;
  --color-surface-2: #1c1c22;
  --color-border: rgba(255,255,255,0.08);
  --color-text: #f0f0f3;
  --color-text-muted: #8c8c99;
  --color-text-faint: #4d4d5a;
  --color-accent: #7c6ef5;
  --color-accent-2: #5e51d4;
  --color-accent-light: rgba(124, 110, 245, 0.12);
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --shadow-glow: 0 0 60px rgba(124,110,245,0.15);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ---- Utility ---- */
.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

/* ---- Nav ---- */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(13,13,15,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}
.nav__inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.nav__logo {
  font-size: 1.125rem; font-weight: 700; letter-spacing: -0.02em;
  color: var(--color-text); text-decoration: none;
}
.nav__logo span { color: var(--color-accent); }
.btn-nav {
  padding: 8px 18px; border-radius: var(--radius-sm);
  background: var(--color-accent); color: #fff; font-size: 0.875rem; font-weight: 600;
  text-decoration: none; border: none; cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}
.btn-nav:hover { background: var(--color-accent-2); transform: translateY(-1px); }

/* ---- Hero ---- */
.hero {
  padding: 96px 0 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(124,110,245,0.18) 0%, transparent 70%);
  pointer-events: none;
}
.hero__badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--color-accent-light); border: 1px solid rgba(124,110,245,0.3);
  border-radius: 100px; padding: 5px 14px;
  font-size: 0.8125rem; font-weight: 500; color: #a99ef7;
  margin-bottom: 24px;
}
.hero__badge-dot {
  width: 6px; height: 6px; border-radius: 50%; background: #7c6ef5;
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
.hero__headline {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800; letter-spacing: -0.04em; line-height: 1.1;
  color: var(--color-text); max-width: 760px; margin: 0 auto 20px;
}
.hero__headline em { font-style: normal; color: var(--color-accent); }
.hero__subhead {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--color-text-muted); max-width: 520px; margin: 0 auto 40px;
  line-height: 1.65;
}

/* ---- Waitlist form ---- */
.waitlist-form {
  display: flex; gap: 10px; max-width: 480px; margin: 0 auto;
  flex-wrap: wrap; justify-content: center;
}
.waitlist-form__input {
  flex: 1 1 260px; padding: 14px 18px;
  background: var(--color-surface-2); border: 1px solid var(--color-border);
  border-radius: var(--radius-sm); color: var(--color-text); font-size: 1rem;
  outline: none; transition: border-color 0.2s;
}
.waitlist-form__input::placeholder { color: var(--color-text-faint); }
.waitlist-form__input:focus { border-color: var(--color-accent); }
.waitlist-form__btn {
  padding: 14px 24px; border-radius: var(--radius-sm);
  background: var(--color-accent); color: #fff; font-size: 1rem; font-weight: 600;
  border: none; cursor: pointer; white-space: nowrap;
  transition: background 0.2s, transform 0.1s;
}
.waitlist-form__btn:hover:not(:disabled) { background: var(--color-accent-2); transform: translateY(-1px); }
.waitlist-form__btn:disabled { opacity: 0.6; cursor: not-allowed; }
.waitlist-form__status {
  width: 100%; font-size: 0.875rem; min-height: 20px; text-align: center;
}
.waitlist-form__status--error { color: #f87171; }
.waitlist-form__status--loading { color: var(--color-text-muted); }
.waitlist-success {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 20px; text-align: center;
}
.waitlist-success__icon {
  width: 48px; height: 48px; border-radius: 50%;
  background: rgba(52,211,153,0.15); display: flex; align-items: center; justify-content: center;
  font-size: 1.25rem;
}
.waitlist-success__text { font-size: 1.125rem; font-weight: 600; color: #34d399; }
.waitlist-success__sub { font-size: 0.875rem; color: var(--color-text-muted); }

/* ---- Referral share block (shown after signup) ---- */
.referral-share {
  width: 100%; max-width: 420px; margin-top: 12px;
  background: rgba(124,110,245,0.08); border: 1px solid rgba(124,110,245,0.25);
  border-radius: var(--radius-sm); overflow: hidden;
}
.referral-share__url {
  padding: 10px 14px; font-size: 0.8125rem; font-family: 'SF Mono','Fira Code',monospace;
  color: var(--color-text); word-break: break-all; border-bottom: 1px solid rgba(124,110,245,0.15);
  user-select: all;
}
.referral-share__actions {
  display: flex; align-items: center; gap: 0;
}
.referral-share__copy {
  flex: 1; padding: 9px 14px; font-size: 0.8125rem; font-weight: 600;
  background: transparent; border: none; border-right: 1px solid rgba(124,110,245,0.15);
  color: var(--color-accent); cursor: pointer; text-align: center;
  transition: background 0.15s;
}
.referral-share__copy:hover { background: rgba(124,110,245,0.12); }
.referral-share__twitter {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 16px; font-size: 0.8125rem; font-weight: 600;
  background: transparent; color: var(--color-accent); text-decoration: none;
  transition: background 0.15s; white-space: nowrap;
}
.referral-share__twitter:hover { background: rgba(124,110,245,0.12); }

.hero__secondary {
  display: block; margin-top: 16px;
  font-size: 0.875rem; color: var(--color-text-muted); text-decoration: none;
}
.hero__secondary:hover { color: var(--color-text); }
.hero__social-proof {
  margin-top: 32px; font-size: 0.8125rem; color: var(--color-text-faint);
}

/* ---- Features grid ---- */
.features { padding: 96px 0; }
.section-label {
  font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--color-accent); margin-bottom: 12px;
}
.section-headline {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700; letter-spacing: -0.03em; margin-bottom: 16px; color: var(--color-text);
}
.section-sub { color: var(--color-text-muted); font-size: 1.0625rem; max-width: 480px; }
.features__grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 56px;
}
.feature-card {
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-md); padding: 28px;
  transition: border-color 0.2s, transform 0.2s;
}
.feature-card:hover { border-color: rgba(124,110,245,0.35); transform: translateY(-2px); }
.feature-card__icon {
  width: 40px; height: 40px; border-radius: var(--radius-sm);
  background: var(--color-accent-light); display: flex; align-items: center; justify-content: center;
  font-size: 1.125rem; margin-bottom: 16px;
}
.feature-card__title { font-size: 1rem; font-weight: 600; margin-bottom: 8px; }
.feature-card__desc { font-size: 0.875rem; color: var(--color-text-muted); line-height: 1.6; }

/* ---- How it works ---- */
.how-it-works { padding: 96px 0; background: var(--color-surface); }
.how-it-works__steps {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; margin-top: 56px;
  position: relative;
}
.how-it-works__steps::before {
  content: '';
  position: absolute; top: 24px; left: calc(16.67% + 12px); right: calc(16.67% + 12px);
  height: 1px; background: linear-gradient(to right, var(--color-accent), rgba(124,110,245,0.2));
}
.step { text-align: center; }
.step__num {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--color-accent); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; font-weight: 700; margin: 0 auto 20px;
  position: relative; z-index: 1;
}
.step__title { font-size: 1.0625rem; font-weight: 600; margin-bottom: 8px; }
.step__desc { font-size: 0.875rem; color: var(--color-text-muted); line-height: 1.6; }

/* ---- Social proof ---- */
.social-proof { padding: 72px 0; border-top: 1px solid var(--color-border); border-bottom: 1px solid var(--color-border); }
.social-proof__heading { text-align: center; margin-bottom: 40px; }
.logo-strip {
  display: flex; align-items: center; justify-content: center;
  gap: 48px; flex-wrap: wrap;
}
.logo-placeholder {
  height: 28px; background: var(--color-surface-2); border-radius: var(--radius-sm);
  opacity: 0.5;
}

/* ---- Final CTA ---- */
.cta-band {
  padding: 96px 0; text-align: center;
  background: radial-gradient(ellipse 80% 60% at 50% 100%, rgba(124,110,245,0.14) 0%, transparent 70%);
}

/* ---- Footer ---- */
.footer {
  padding: 32px 0; border-top: 1px solid var(--color-border);
}
.footer__inner {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  flex-wrap: wrap;
}
.footer__copy { font-size: 0.8125rem; color: var(--color-text-faint); }
.footer__contact { font-size: 0.8125rem; color: var(--color-text-muted); text-decoration: none; }
.footer__contact:hover { color: var(--color-text); }

/* ---- Responsive ---- */
@media (max-width: 768px) {
  .features__grid { grid-template-columns: 1fr; }
  .how-it-works__steps { grid-template-columns: 1fr; }
  .how-it-works__steps::before { display: none; }
  .nav__logo { font-size: 1rem; }
  .hero { padding: 64px 0 56px; }
  .features, .how-it-works, .cta-band { padding: 64px 0; }
}
@media (max-width: 480px) {
  .waitlist-form { flex-direction: column; }
  .waitlist-form__input, .waitlist-form__btn { width: 100%; }
}
