/* ============================================================
   Ascendant Memory Trainer — shared styles
   Design system mirrors the iOS app (indigo/purple, soft cards).
   ============================================================ */

:root {
  --indigo: #6C63FF;
  --indigo-strong: #5B5BD6;
  --indigo-deep: #4F46E5;
  --indigo-ink: #1E1B4B;
  --grad-purple: linear-gradient(120deg, #8B7CF6 0%, #6C63FF 60%, #7C3AED 100%);
  --grad-logo: linear-gradient(135deg, #7C5CFF 0%, #B14FD8 60%, #E96BB0 100%);

  --ink: #15192C;
  --slate: #4A5568;
  --muted: #7A8499;
  --line: #E7E9F2;

  --bg: #F4F5FA;
  --bg-soft: #FAFBFE;
  --card: #FFFFFF;

  --shadow-sm: 0 2px 8px rgba(30, 27, 75, 0.05);
  --shadow-md: 0 10px 30px rgba(30, 27, 75, 0.08);
  --shadow-lg: 0 24px 60px rgba(30, 27, 75, 0.16);

  --radius: 22px;
  --radius-sm: 14px;
  --maxw: 1080px;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "SF Pro Display",
    Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

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

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

a { color: var(--indigo-deep); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(244, 245, 250, 0.82);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav .wrap {
  display: flex; align-items: center; justify-content: space-between;
  height: 68px;
}
.brand { display: flex; align-items: center; gap: 12px; font-weight: 800; }
.brand:hover { text-decoration: none; }
.logo {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--grad-logo);
  display: grid; place-items: center;
  box-shadow: 0 6px 16px rgba(124, 92, 255, 0.35);
  flex: none;
}
.logo svg { width: 20px; height: 20px; }
.brand .name {
  font-size: 1.05rem; letter-spacing: 0.16em; color: var(--indigo-strong);
}
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a { color: var(--slate); font-weight: 600; font-size: 0.95rem; }
.nav-links a:hover { color: var(--indigo-deep); text-decoration: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--indigo); color: #fff; font-weight: 700;
  padding: 14px 26px; border-radius: 14px; font-size: 1rem;
  box-shadow: 0 12px 26px rgba(108, 99, 255, 0.32);
  transition: transform .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-2px); text-decoration: none; box-shadow: 0 16px 32px rgba(108, 99, 255, 0.4); }
.btn.ghost {
  background: #fff; color: var(--indigo-deep);
  box-shadow: var(--shadow-sm); border: 1px solid var(--line);
}

/* ---------- Hero ---------- */
.hero { padding: 72px 0 40px; }
.hero .wrap { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 48px; align-items: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 700; font-size: 0.8rem; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--indigo-deep);
  background: #ECEAFF; padding: 7px 14px; border-radius: 999px; margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.6rem); line-height: 1.05;
  letter-spacing: -0.02em; font-weight: 800;
}
.hero h1 .grad {
  background: var(--grad-purple); -webkit-background-clip: text;
  background-clip: text; -webkit-text-fill-color: transparent;
}
.hero p.lead { font-size: 1.18rem; color: var(--slate); margin: 22px 0 30px; max-width: 30em; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-note { margin-top: 18px; font-size: 0.9rem; color: var(--muted); }

/* ---------- Phone mockup ---------- */
.phones { position: relative; display: flex; justify-content: center; }
.phone {
  width: 280px; background: #fff; border-radius: 42px;
  border: 10px solid #11131f; box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.phone.tilt-back {
  position: absolute; transform: scale(.84) translate(-78px, 26px) rotate(-7deg);
  filter: saturate(.96); opacity: .96; z-index: 1;
}
.phone.front { position: relative; z-index: 2; transform: rotate(2deg); }

.scr { padding: 18px 18px 22px; min-height: 540px; background: var(--bg); display: flex; flex-direction: column; }
.scr .notch { width: 92px; height: 22px; background: #11131f; border-radius: 0 0 14px 14px; margin: -18px auto 14px; }
.scr-top { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--ink); font-size: 1.02rem; margin-bottom: 8px; }
.scr-top .back { color: var(--ink); font-weight: 800; }
.scr-progress { height: 4px; background: var(--line); border-radius: 4px; overflow: hidden; margin-bottom: 26px; }
.scr-progress i { display: block; width: 22%; height: 100%; background: var(--indigo); }

.scr .label { text-align: center; color: var(--slate); font-weight: 700; font-size: 1rem; margin-bottom: 8px; }
.scr .big-number { text-align: center; color: var(--indigo); font-size: 3.4rem; font-weight: 800; letter-spacing: 0.04em; margin: auto 0; }
.scr .big-letters { text-align: center; color: var(--indigo); font-size: 2.6rem; font-weight: 800; letter-spacing: 0.18em; margin: auto 0; }
.scr .big-words { text-align: center; color: var(--ink); font-size: 1.7rem; font-weight: 800; margin: auto 0; }
.scr-foot { display: flex; justify-content: space-between; color: var(--slate); font-size: 0.82rem; font-weight: 600; margin-top: auto; padding-top: 18px; }
.dots { display: flex; gap: 8px; margin-top: 12px; }
.dots span { width: 9px; height: 9px; border-radius: 50%; background: var(--line); }
.dots span.on { background: var(--indigo); }

/* home screen bits */
.streak-card { background: var(--grad-purple); border-radius: 18px; padding: 18px; display: flex; align-items: center; gap: 14px; color: #fff; margin-bottom: 16px; }
.streak-icon { width: 46px; height: 46px; border-radius: 12px; background: rgba(255,255,255,.85); display: grid; place-items: center; font-size: 1.5rem; }
.streak-card .s-label { font-size: .82rem; opacity: .92; }
.streak-card .s-num { font-size: 1.7rem; font-weight: 800; line-height: 1; }
.phase-card { background: #fff; border-radius: 18px; padding: 18px; box-shadow: var(--shadow-sm); margin-bottom: 16px; }
.phase-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.phase-badge { width: 40px; height: 40px; border-radius: 11px; background: #ECEAFF; display: grid; place-items: center; font-size: 1.2rem; }
.phase-card .p-title { font-weight: 800; font-size: 1.02rem; }
.phase-card .p-sub { color: var(--muted); font-size: .82rem; }
.prow { display: flex; justify-content: space-between; font-weight: 700; }
.prow .pv { color: var(--indigo-deep); }
.scr-btn { background: var(--indigo); color: #fff; text-align: center; font-weight: 800; padding: 14px; border-radius: 14px; box-shadow: 0 10px 22px rgba(108,99,255,.3); }

/* ---------- Section ---------- */
section.block { padding: 64px 0; }
.section-head { text-align: center; max-width: 40em; margin: 0 auto 48px; }
.section-head .eyebrow { margin-bottom: 16px; }
.section-head h2 { font-size: clamp(1.8rem, 3.5vw, 2.5rem); letter-spacing: -0.02em; font-weight: 800; }
.section-head p { color: var(--slate); font-size: 1.1rem; margin-top: 14px; }

/* ---------- Features ---------- */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.feature {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow-sm); transition: transform .18s ease, box-shadow .18s ease;
}
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.f-icon {
  width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center;
  background: #ECEAFF; color: var(--indigo-deep); margin-bottom: 18px;
}
.f-icon svg { width: 26px; height: 26px; }
.feature h3 { font-size: 1.15rem; font-weight: 800; margin-bottom: 8px; }
.feature p { color: var(--slate); font-size: 0.98rem; }

/* ---------- How it works (phases) ---------- */
.how { background: var(--bg-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.step { text-align: center; padding: 8px; }
.step .num {
  width: 44px; height: 44px; border-radius: 50%; margin: 0 auto 16px;
  display: grid; place-items: center; font-weight: 800; color: #fff;
  background: var(--grad-purple); box-shadow: 0 10px 20px rgba(108,99,255,.28);
}
.step h4 { font-weight: 800; margin-bottom: 6px; }
.step p { color: var(--slate); font-size: .95rem; }

/* ---------- CTA band ---------- */
.cta-band { padding: 70px 0; }
.cta-inner {
  background: var(--grad-purple); border-radius: 30px; padding: 56px 40px; text-align: center;
  color: #fff; box-shadow: var(--shadow-lg);
}
.cta-inner h2 { font-size: clamp(1.8rem, 3.5vw, 2.4rem); font-weight: 800; letter-spacing: -0.01em; }
.cta-inner p { opacity: .95; font-size: 1.12rem; margin: 14px auto 28px; max-width: 32em; }
.cta-inner .btn { background: #fff; color: var(--indigo-deep); }
.cta-inner .btn:hover { box-shadow: 0 16px 32px rgba(0,0,0,.18); }

/* ---------- Footer ---------- */
footer.site {
  background: var(--indigo-ink); color: #C8C9E4; padding: 48px 0 36px; margin-top: 8px;
}
footer.site .wrap { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
footer.site .brand .name { color: #fff; }
footer.site a { color: #C8C9E4; font-weight: 600; }
footer.site a:hover { color: #fff; }
.foot-links { display: flex; gap: 26px; align-items: center; }
.foot-copy { width: 100%; border-top: 1px solid rgba(255,255,255,.12); margin-top: 28px; padding-top: 22px; font-size: .85rem; color: #9698c4; }

/* ---------- Legal / privacy page ---------- */
.legal { max-width: 760px; margin: 0 auto; padding: 56px 24px 72px; }
.legal h1 { font-size: 2.4rem; font-weight: 800; letter-spacing: -0.02em; }
.legal .updated { color: var(--muted); margin: 8px 0 36px; font-size: .95rem; }
.legal h2 { font-size: 1.35rem; font-weight: 800; margin: 38px 0 12px; }
.legal p { color: var(--slate); margin-bottom: 14px; }
.legal ul { color: var(--slate); margin: 0 0 16px 22px; }
.legal li { margin-bottom: 8px; }
.legal .card-note {
  background: var(--bg-soft); border: 1px solid var(--line); border-left: 4px solid var(--indigo);
  border-radius: 12px; padding: 18px 20px; margin: 24px 0; color: var(--slate);
}
.back-home { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; margin-bottom: 8px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 36px; text-align: center; }
  .hero-cta { justify-content: center; }
  .eyebrow { margin-left: auto; margin-right: auto; }
  .phones { margin-top: 8px; }
  .features { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr 1fr; gap: 28px; }
}
@media (max-width: 620px) {
  .nav-links { gap: 16px; }
  .nav-links a.hide-sm { display: none; }
  .phone.tilt-back { display: none; }
  .phone.front { transform: none; }
  .steps { grid-template-columns: 1fr; }
  footer.site .wrap { flex-direction: column; align-items: flex-start; }
}
