/* =========================================================================
   Astera — marketing site
   Design language: Celestial Minimalism (dark cosmic canvas, glassmorphism,
   violet / gold / rose accents; Fraunces + Hanken Grotesk + Space Grotesk).
   ========================================================================= */

:root {
  /* palette — aligned to the app's dark "Lavender" theme
     (mobile/lib/theme/colors.dart · gradients.dart) */
  --bg-0: #0b0b1a;   /* AppColors.bg */
  --bg-1: #120a2e;   /* backdropTop */
  --bg-2: #14132b;   /* elevated */
  --panel: rgba(30, 28, 60, 0.48);   /* glass #1E1C3C */
  --panel-2: rgba(30, 28, 60, 0.72);
  --stroke: rgba(155, 123, 255, 0.18);   /* border 0x2E9B7BFF */
  --stroke-2: rgba(155, 123, 255, 0.32); /* fieldBorder 0x4D9B7BFF */

  --primary: #6c5ce7;
  --violet: #9b7bff;
  --violet-2: #b9a3ff;
  --gold: #f5c76b;
  --gold-deep: #e8a94b;
  --rose: #ff6b9d;

  --text: #f4f3ff;       /* AppColors.text */
  --muted: #a7a4c4;      /* AppColors.textDim */
  --muted-2: #7e7aa0;

  --grad-primary: linear-gradient(120deg, #6c5ce7, #9b7bff);   /* AppGradients.primary */
  --grad-aurora: linear-gradient(135deg, #6c5ce7, #ff6b9d);    /* AppGradients.aurora */
  --grad-gold: linear-gradient(135deg, #f5c76b, #e8a94b);      /* AppGradients.gold */

  --radius: 20px;
  --radius-sm: 12px;
  --shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.8);
  --maxw: 1180px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }

/* The `hidden` attribute must win over component display rules
   (.mobile-menu/.wl-success set display, which would otherwise override it). */
[hidden] { display: none !important; }

html { scroll-behavior: smooth; scroll-padding-top: 90px; }
html, body { max-width: 100%; }

body {
  margin: 0;
  background: var(--bg-0);
  color: var(--text);
  font-family: "Hanken Grotesk", system-ui, -apple-system, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

/* subtle vertical gradient over the whole page */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(1200px 760px at 50% -12%, rgba(108, 92, 231, 0.22), transparent 62%),
    linear-gradient(180deg, var(--bg-1), var(--bg-0) 42%, #07071a);
  z-index: -3;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

::selection { background: rgba(155, 123, 255, 0.35); color: #fff; }

/* ------------------------- background FX -------------------------------- */
#starfield {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  opacity: 0.9;
}

.aurora { position: fixed; inset: 0; z-index: -2; overflow: hidden; pointer-events: none; }
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.4;
  animation: drift 22s var(--ease) infinite alternate;
}
.orb-violet { width: 460px; height: 460px; background: #6c5ce7; top: -120px; left: -80px; }
.orb-rose { width: 380px; height: 380px; background: #e0568c; top: 40%; right: -120px; animation-delay: -6s; }
.orb-gold { width: 300px; height: 300px; background: #a9852f; bottom: -120px; left: 30%; animation-delay: -12s; opacity: 0.28; }

@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(40px, -30px, 0) scale(1.15); }
}

/* ------------------------- typography ----------------------------------- */
.display, .h2, h3, h4 { font-family: "Fraunces", Georgia, serif; font-weight: 500; }
.display {
  font-size: clamp(2.7rem, 7vw, 5rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin: 0.2em 0 0.35em;
}
.display em {
  font-style: italic;
  background: var(--grad-aurora);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.h2 { font-size: clamp(1.9rem, 4vw, 3rem); line-height: 1.08; letter-spacing: -0.02em; margin: 0 0 0.4em; }

.kicker, .eyebrow, .cd-unit, .calc-kicker, .calc-kicker, .step-no, .pc-label {
  font-family: "Space Grotesk", monospace;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.74rem;
}
.kicker { color: var(--violet-2); display: inline-block; margin-bottom: 0.8em; }

.lede { font-size: clamp(1.05rem, 2.2vw, 1.28rem); color: var(--muted); max-width: 36ch; }
.lede strong { color: var(--text); font-weight: 600; }
.section-sub { color: var(--muted); font-size: 1.08rem; max-width: 56ch; margin-inline: auto; }

/* ------------------------- buttons -------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 500;
  font-size: 0.98rem;
  padding: 0.85em 1.5em;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.2s var(--ease), box-shadow 0.3s var(--ease), background 0.2s;
  white-space: nowrap;
}
.btn-sm { padding: 0.6em 1.1em; font-size: 0.9rem; }
.btn-lg { padding: 1em 1.9em; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn-primary {
  background: var(--grad-primary);
  color: #fff;   /* onAccent */
  font-weight: 600;
  box-shadow: 0 10px 30px -8px rgba(108, 92, 231, 0.65);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 40px -8px rgba(108, 92, 231, 0.8); }
.btn-ghost {
  background: var(--panel);
  border-color: var(--stroke-2);
  color: var(--text);
  backdrop-filter: blur(10px);
}
.btn-ghost:hover { background: var(--panel-2); transform: translateY(-2px); }
.btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* ------------------------- nav ------------------------------------------ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.9rem clamp(1rem, 4vw, 2.5rem);
  transition: background 0.3s, backdrop-filter 0.3s, border-color 0.3s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(9, 6, 22, 0.72);
  backdrop-filter: blur(16px) saturate(140%);
  border-bottom-color: var(--stroke);
}
.brand { display: inline-flex; align-items: center; gap: 0.6rem; }
.brand-mark { width: 38px; height: 38px; border-radius: 50%; }
.brand-name { font-family: "Fraunces", serif; font-size: 1.4rem; font-weight: 600; letter-spacing: 0.01em; }

.nav-links { display: flex; gap: 1.8rem; }
.nav-links a { color: var(--muted); font-size: 0.98rem; transition: color 0.2s; }
.nav-links a:hover { color: var(--text); }

.nav-actions { display: flex; align-items: center; gap: 0.8rem; }

.nav-toggle { display: none; background: none; border: 0; cursor: pointer; width: 40px; height: 40px; flex-direction: column; justify-content: center; gap: 5px; padding: 0; }
.nav-toggle span { display: block; height: 2px; width: 22px; margin: 0 auto; background: var(--text); border-radius: 2px; transition: transform 0.3s, opacity 0.3s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  position: fixed;
  top: 66px; left: 0; right: 0;
  z-index: 49;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 1rem clamp(1rem, 4vw, 2.5rem) 1.6rem;
  background: rgba(10, 7, 24, 0.96);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--stroke);
  animation: menuIn 0.25s var(--ease);
}
.mobile-menu a { padding: 0.7rem 0.2rem; color: var(--muted); border-bottom: 1px solid rgba(255,255,255,0.05); }
.mobile-menu a.btn { margin-top: 0.6rem; color: #12082e; border: 0; text-align: center; }
@keyframes menuIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

/* ------------------------- layout --------------------------------------- */
.section {
  max-width: var(--maxw);
  margin-inline: auto;
  padding: clamp(4rem, 9vw, 7rem) clamp(1.1rem, 4vw, 2rem);
}
.section-head { text-align: center; margin-bottom: clamp(2.5rem, 5vw, 4rem); }

/* ------------------------- hero ----------------------------------------- */
.hero {
  max-width: var(--maxw);
  margin-inline: auto;
  padding: clamp(7rem, 14vw, 10rem) clamp(1.1rem, 4vw, 2rem) clamp(2rem, 5vw, 3rem);
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 2rem;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  color: var(--gold);
  background: rgba(245, 199, 107, 0.1);
  border: 1px solid rgba(245, 199, 107, 0.25);
  padding: 0.4em 0.9em;
  border-radius: 999px;
}
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 10px var(--gold); animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.3; } }

.hero-cta { display: flex; gap: 0.8rem; flex-wrap: wrap; margin: 2rem 0 1rem; }

.waitlist-inline { margin: 2rem 0 1.4rem; max-width: 460px; }
.inline-fields { display: flex; gap: 0.6rem; }
.inline-fields input {
  flex: 1;
  min-width: 0;
  padding: 0.95em 1.1em;
  border-radius: 999px;
  border: 1px solid var(--stroke-2);
  background: var(--panel);
  color: var(--text);
  font-size: 1rem;
  font-family: inherit;
}
.inline-fields input:focus { outline: none; border-color: var(--violet); box-shadow: 0 0 0 4px rgba(155,123,255,0.18); }
.inline-hint { font-size: 0.85rem; color: var(--muted-2); margin: 0 0.2rem 1.7rem; }

.social-proof { display: flex; align-items: center; gap: 0.9rem; }
.social-proof p { margin: 0; color: var(--muted); font-size: 0.95rem; }
.social-proof strong { color: var(--text); }
.avatars { display: flex; }
.avatars span {
  width: 32px; height: 32px; border-radius: 50%;
  border: 2px solid var(--bg-1);
  margin-left: -10px;
  background: var(--grad-primary);
  display: grid;
  place-items: center;
  font-family: "Space Grotesk", sans-serif;
  font-size: 0.62rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
  letter-spacing: 0.02em;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.avatars span:nth-child(2) { background: var(--grad-gold); }
.avatars span:nth-child(3) { background: linear-gradient(120deg,#ff6b9d,#ff9d7a); }
.avatars span:nth-child(4) { background: linear-gradient(120deg,#7b8cff,#9b7bff); }
.avatars span:first-child { margin-left: 0; }

/* hero visual — orbit stage */
.hero-visual { display: flex; justify-content: center; }
.orbit-stage { position: relative; width: min(440px, 94%); aspect-ratio: 1; display: grid; place-items: center; }
/* The animated sacred-geometry mandala (ported from the app) sits behind the
   logo, which becomes its glowing core. */
.mandala { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; }

.phone {
  position: relative;
  width: 58%;
  aspect-ratio: 1;
  border-radius: 32px;
  display: grid;
  place-items: center;
  z-index: 2;
}
.phone-glow { position: absolute; inset: -10%; border-radius: 50%; background: radial-gradient(circle, rgba(155,123,255,0.55), transparent 65%); filter: blur(20px); }
.phone-logo { width: 78%; border-radius: 50%; position: relative; box-shadow: 0 20px 60px -12px rgba(0,0,0,0.7); animation: bob 6s ease-in-out infinite; }
@keyframes bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }

.phone-card {
  position: absolute;
  bottom: -6%;
  right: -12%;
  background: rgba(16, 11, 38, 0.82);
  backdrop-filter: blur(14px);
  border: 1px solid var(--stroke-2);
  border-radius: 16px;
  padding: 0.85rem 1.05rem;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow);
  z-index: 3;
  white-space: nowrap; /* stay a compact badge; never wrap into a tall box */
  animation: bob 6s ease-in-out infinite 0.6s;
}
.pc-label { color: var(--muted); }
.pc-score { font-family: "Fraunces", serif; font-size: 2.1rem; line-height: 1; background: var(--grad-gold); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pc-score span { font-size: 1rem; }
.pc-sub { font-size: 0.8rem; color: var(--muted); }

.floaty { position: absolute; color: var(--gold); filter: drop-shadow(0 0 8px rgba(245,199,107,0.8)); animation: twinkle 3s ease-in-out infinite; }
.star-a { top: 8%; right: 14%; font-size: 1.4rem; }
.star-b { bottom: 18%; left: 8%; font-size: 1rem; color: var(--violet-2); animation-delay: -1s; }
.star-c { top: 34%; left: 0; font-size: 0.8rem; animation-delay: -2s; }
@keyframes twinkle { 0%,100% { opacity: 0.4; transform: scale(0.9); } 50% { opacity: 1; transform: scale(1.2); } }

/* ------------------------- countdown ------------------------------------ */
.countdown {
  max-width: 720px;
  margin: 1rem auto 0;
  text-align: center;
  padding: 2rem clamp(1.1rem, 4vw, 2rem);
}
.count-label { color: var(--muted); font-family: "Space Grotesk", sans-serif; letter-spacing: 0.05em; margin-bottom: 1.2rem; }
.count-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: clamp(0.6rem, 3vw, 1.6rem); }
.count-grid > div {
  background: var(--panel);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-sm);
  padding: 1rem clamp(0.7rem, 3vw, 1.4rem);
  min-width: 72px;
  backdrop-filter: blur(8px);
}
.cd-num { display: block; font-family: "Fraunces", serif; font-size: clamp(1.8rem, 6vw, 2.8rem); line-height: 1; }
.cd-unit { color: var(--muted-2); }

/* ------------------------- steps ---------------------------------------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
.step {
  background: var(--panel);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 1.6rem 1.4rem;
  position: relative;
  overflow: hidden;
  transition: transform 0.3s var(--ease), border-color 0.3s;
}
.step:hover { transform: translateY(-6px); border-color: var(--stroke-2); }
.step-no { color: var(--violet); font-size: 0.9rem; }
.step h3 { font-size: 1.2rem; margin: 0.8rem 0 0.5rem; }
.step p { color: var(--muted); font-size: 0.96rem; margin: 0; }

/* ------------------------- features ------------------------------------- */
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; }
.feature {
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem;
  transition: transform 0.3s var(--ease), border-color 0.3s, box-shadow 0.3s;
}
.feature:hover { transform: translateY(-6px); border-color: var(--stroke-2); box-shadow: var(--shadow); }
.f-icon {
  width: 48px; height: 48px;
  display: grid; place-items: center;
  border-radius: 14px;
  font-size: 1.4rem;
  background: rgba(155,123,255,0.14);
  border: 1px solid var(--stroke-2);
  color: var(--violet-2);
  margin-bottom: 1rem;
}
.feature h3 { font-size: 1.25rem; margin: 0 0 0.5rem; }
.feature p { color: var(--muted); margin: 0; font-size: 0.98rem; }

/* ------------------------- cosmos / calculator -------------------------- */
.cosmos-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.tick-list { list-style: none; padding: 0; margin: 1.5rem 0 0; display: grid; gap: 0.7rem; }
.tick-list li { position: relative; padding-left: 1.9rem; color: var(--muted); }
.tick-list li::before { content: "✦"; position: absolute; left: 0; color: var(--gold); }

.calc {
  background: linear-gradient(180deg, rgba(155,123,255,0.1), var(--panel));
  border: 1px solid var(--stroke-2);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 3vw, 2.2rem);
  box-shadow: var(--shadow);
}
.calc-kicker { color: var(--gold); }
.calc-head p { color: var(--muted); margin: 0.5rem 0 1.4rem; }
.calc-signs { display: flex; align-items: flex-end; gap: 1rem; justify-content: center; }
.calc-signs label { display: flex; flex-direction: column; gap: 0.4rem; flex: 1; font-size: 0.85rem; color: var(--muted); }
.calc-heart { color: var(--rose); font-size: 1.5rem; padding-bottom: 0.4rem; }
.calc select, .field select, .field input {
  width: 100%;
  padding: 0.8em 1em;
  border-radius: var(--radius-sm);
  border: 1px solid var(--stroke-2);
  background: rgba(10, 7, 24, 0.6);
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
}
.calc select:focus, .field select:focus, .field input:focus { outline: none; border-color: var(--violet); box-shadow: 0 0 0 4px rgba(155,123,255,0.16); }
option { background: #14102b; color: var(--text); }

.calc-result { text-align: center; margin-top: 1.6rem; }
.calc-meter { height: 8px; border-radius: 999px; background: rgba(255,255,255,0.08); overflow: hidden; }
.calc-fill { height: 100%; width: 0; border-radius: 999px; background: var(--grad-aurora); transition: width 0.9s var(--ease); }
.calc-score { font-family: "Fraunces", serif; font-size: 3rem; line-height: 1; margin: 0.8rem 0 0.2rem; background: var(--grad-gold); -webkit-background-clip: text; background-clip: text; color: transparent; }
.calc-score small { font-size: 1.2rem; }
.calc-line { color: var(--muted); min-height: 1.5em; margin: 0.3rem 0 0.9rem; }
.calc-foot { font-size: 0.82rem; color: var(--muted-2); text-align: center; margin: 1.2rem 0 0; }

/* ------------------------- waitlist ------------------------------------- */
.waitlist-section { scroll-margin-top: 80px; }
.waitlist-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.4rem;
  background: linear-gradient(135deg, rgba(108,92,231,0.18), rgba(255,107,157,0.10));
  border: 1px solid var(--stroke-2);
  border-radius: 28px;
  padding: clamp(2.2rem, 5vw, 3.6rem);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.waitlist-card::before {
  content: ""; position: absolute; top: -40%; left: 50%; transform: translateX(-50%);
  width: 520px; height: 520px; border-radius: 50%;
  background: radial-gradient(circle, rgba(245,199,107,0.16), transparent 70%);
  pointer-events: none;
}
.waitlist-card > * { position: relative; }
.waitlist-card .section-sub { margin-top: 0.2rem; }
.wl-logo { width: 60px; height: 60px; border-radius: 50%; margin-bottom: 0.8rem; }
.perk-list { list-style: none; padding: 0; margin: 1.6rem 0 1.8rem; display: flex; flex-wrap: wrap; gap: 0.6rem 1.4rem; justify-content: center; }
.perk-list li { color: var(--text); font-size: 0.98rem; }

/* ------------------------- waitlist modal ------------------------------- */
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 1rem; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(5, 3, 13, 0.72); backdrop-filter: blur(6px); animation: fade 0.25s var(--ease); }
.modal-dialog {
  position: relative;
  width: min(480px, 100%);
  max-height: 92vh;
  overflow-y: auto;
  background: linear-gradient(180deg, #171033, #100b26);
  border: 1px solid var(--stroke-2);
  border-radius: 24px;
  box-shadow: var(--shadow);
  animation: modalIn 0.32s var(--ease);
}
.modal-body { padding: clamp(1.6rem, 4vw, 2.4rem); text-align: center; }
.modal-logo { width: 54px; height: 54px; border-radius: 50%; margin: 0 auto 0.9rem; }
.modal-title { font-family: "Fraunces", serif; font-weight: 500; font-size: clamp(1.7rem, 4vw, 2.2rem); margin: 0.2rem 0 0; }
.modal-sub { color: var(--muted); margin: 0.5rem 0 1.6rem; font-size: 0.98rem; }
.modal-close {
  position: absolute; top: 0.7rem; right: 0.9rem; z-index: 2;
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--panel); border: 1px solid var(--stroke);
  color: var(--muted); font-size: 1.5rem; line-height: 1; cursor: pointer;
  transition: color 0.2s, background 0.2s;
}
.modal-close:hover { color: var(--text); background: var(--panel-2); }
.modal .wl-form { text-align: left; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes modalIn { from { opacity: 0; transform: translateY(24px) scale(0.98); } to { opacity: 1; transform: none; } }
body.modal-open { overflow: hidden; }

.wl-form { display: grid; gap: 1rem; }
.field { display: grid; gap: 0.4rem; }
.field label { font-size: 0.85rem; color: var(--muted); font-family: "Space Grotesk", sans-serif; }
.field .opt { color: var(--muted-2); text-transform: none; letter-spacing: 0; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.wl-consent { font-size: 0.8rem; color: var(--muted-2); margin: 0.2rem 0 0; }
.wl-consent a { color: var(--violet-2); text-decoration: underline; }
.form-msg { margin: 0; font-size: 0.9rem; min-height: 1.2em; }
.form-msg.error { color: var(--rose); }
.form-msg.success { color: #7ce0a8; }

.wl-success { text-align: center; display: grid; place-items: center; gap: 0.6rem; padding: 1rem 0; }
.success-badge {
  width: 64px; height: 64px; border-radius: 50%;
  display: grid; place-items: center; font-size: 1.8rem;
  background: var(--grad-gold); color: #2a1d00;   /* goldInk */
  box-shadow: 0 0 40px rgba(245,199,107,0.5);
  animation: pop 0.5s var(--ease);
}
@keyframes pop { from { transform: scale(0); } to { transform: scale(1); } }
.wl-success h3 { font-size: 1.6rem; margin: 0.4rem 0 0; }
.success-pos { font-family: "Space Grotesk", sans-serif; color: var(--gold); font-size: 1.05rem; margin: 0; }
.wl-success p { color: var(--muted); margin: 0.2rem 0; max-width: 34ch; }
.share-row { display: flex; gap: 0.6rem; flex-wrap: wrap; justify-content: center; margin-top: 0.6rem; }
.follow-row { display: flex; gap: 0.9rem; align-items: center; flex-wrap: wrap; justify-content: center; margin-top: 0.8rem; font-size: 0.9rem; color: var(--muted); }
.follow-row .soc { color: var(--violet-2); text-decoration: underline; }

/* ------------------------- faq ------------------------------------------ */
.faq-list { max-width: 780px; margin-inline: auto; display: grid; gap: 0.8rem; }
.faq-list details {
  background: var(--panel);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-sm);
  padding: 0.4rem 1.3rem;
  transition: border-color 0.3s;
}
.faq-list details[open] { border-color: var(--stroke-2); background: var(--panel-2); }
.faq-list summary {
  cursor: pointer;
  list-style: none;
  padding: 1rem 0;
  font-family: "Fraunces", serif;
  font-size: 1.15rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; color: var(--violet-2); font-size: 1.5rem; transition: transform 0.3s; }
.faq-list details[open] summary::after { transform: rotate(45deg); }
.faq-list p { color: var(--muted); margin: 0 0 1rem; }

/* ------------------------- footer --------------------------------------- */
.footer {
  border-top: 1px solid var(--stroke);
  background: linear-gradient(180deg, transparent, rgba(155,123,255,0.05));
  margin-top: 3rem;
}
.footer-top {
  max-width: var(--maxw);
  margin-inline: auto;
  padding: clamp(2.5rem, 5vw, 4rem) clamp(1.1rem, 4vw, 2rem) 2rem;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 2rem;
}
.footer-tag { color: var(--muted); max-width: 40ch; margin: 1rem 0 1.4rem; }
.footer-social { display: flex; gap: 0.7rem; }
.soc-icon {
  width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--panel); border: 1px solid var(--stroke-2);
  color: var(--muted); transition: color 0.2s, transform 0.2s, background 0.2s;
}
.soc-icon:hover { color: var(--text); background: var(--panel-2); transform: translateY(-3px); }
.footer-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.footer-cols h4 { font-family: "Space Grotesk", sans-serif; text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.76rem; color: var(--muted-2); margin: 0 0 1rem; }
.footer-cols a { display: block; color: var(--muted); padding: 0.35rem 0; transition: color 0.2s; }
.footer-cols a:hover { color: var(--text); }
.footer-bottom {
  max-width: var(--maxw);
  margin-inline: auto;
  padding: 1.4rem clamp(1.1rem, 4vw, 2rem);
  border-top: 1px solid var(--stroke);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  color: var(--muted-2);
  font-size: 0.85rem;
}
.footer-bottom p { margin: 0; }

/* ------------------------- legal pages ---------------------------------- */
.legal { max-width: 780px; margin: 0 auto; padding: 8rem clamp(1.1rem, 4vw, 2rem) 4rem; }
.legal h1 { font-family: "Fraunces", serif; font-weight: 500; font-size: clamp(2rem, 5vw, 3rem); margin: 0 0 0.3em; }
.legal .updated { color: var(--muted-2); font-family: "Space Grotesk", sans-serif; margin-bottom: 2.5rem; }
.legal h2 { font-family: "Fraunces", serif; font-weight: 500; font-size: 1.4rem; margin: 2.2rem 0 0.6rem; }
.legal p, .legal li { color: var(--muted); }
.legal a { color: var(--violet-2); text-decoration: underline; }
.legal .back { display: inline-flex; align-items: center; gap: 0.4em; color: var(--violet-2); margin-bottom: 2rem; font-family: "Space Grotesk", sans-serif; }

/* ------------------------- reveal animation ----------------------------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ------------------------- responsive ----------------------------------- */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; text-align: center; padding-top: 6rem; gap: 1rem; }
  .hero-copy { display: flex; flex-direction: column; align-items: center; }
  .lede { max-width: 46ch; }
  .hero-cta { justify-content: center; }
  .waitlist-inline { margin-inline: auto; }
  .social-proof { justify-content: center; }
  /* content + CTA come first; the graphic follows so the waitlist button stays
     above the fold on phones and tablets */
  .hero-visual { order: 2; margin-top: 1.5rem; }
  .orbit-stage { width: min(300px, 74%); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .cosmos-wrap { grid-template-columns: 1fr; }
  .waitlist-card { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
  .nav .btn-primary { display: none; }

  /* Drop the cosmic-match card completely below the logo (centered) so it never
     covers the mark. white-space:nowrap keeps it full width despite the small
     parent; bob is disabled so the centering transform isn't overridden. */
  .orbit-stage { width: min(300px, 78%); }
  .phone { width: 56%; }
  .phone-card {
    animation: none;
    top: calc(100% + 8px);
    bottom: auto;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    text-align: center;
    padding: 0.7rem 1.1rem;
  }
  .pc-score { font-size: 1.7rem; }
}

/* Guard against grid/flex "blowout": children may not force tracks wider than
   the viewport (a common source of mobile horizontal overflow). */
.hero > *, .cosmos-wrap > *, .waitlist-card > *, .steps > *, .features-grid > *,
.footer-top > *, .inline-fields > * { min-width: 0; }

@media (max-width: 540px) {
  body { font-size: 16px; }
  .steps, .features-grid { grid-template-columns: 1fr; }
  .inline-fields { flex-direction: column; }
  .inline-fields .btn { width: 100%; }
  .field-row { grid-template-columns: 1fr; }
  .count-grid > div { min-width: 62px; padding: 0.8rem 0.6rem; }
  .footer-bottom { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}
