/* Landing page styles (layered on top of styles.css tokens) */

html { scroll-behavior: smooth; }

.landing-body { overflow-x: hidden; }
body.no-scroll { overflow: hidden; }

/* ================= STARFIELD ================= */

#starfield { position: fixed; inset: 0; pointer-events: none; z-index: 0; }
#starfield .star {
  position: absolute;
  background: #fff; border-radius: 50%;
  opacity: 0.08;
  animation: twinkle ease-in-out infinite;
}
@keyframes twinkle {
  0%, 100% { opacity: 0.05; }
  50%      { opacity: 0.35; }
}

.site-nav, .landing, .site-footer { position: relative; z-index: 1; }

/* ================= NAV ================= */

.site-nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; gap: 28px;
  padding: 16px 30px;
  background: rgba(14, 14, 17, 0.78);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.site-nav .logo { text-decoration: none; }
.nav-links { display: flex; gap: 24px; margin-left: auto; }
.nav-links a {
  color: var(--muted); text-decoration: none; font-size: 0.9rem; font-weight: 500;
  transition: color 0.15s ease;
}
.nav-links a:hover { color: var(--text); }

.landing { max-width: 1060px; margin: 0 auto; padding: 0 24px 40px; }

/* ================= HERO ================= */

.hero {
  position: relative;
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 52px;
  align-items: center;
  padding: 96px 0 76px;
}

.glow {
  position: absolute; border-radius: 50%;
  filter: blur(130px); pointer-events: none; z-index: -1;
}
.glow-1 { width: 480px; height: 480px; background: rgba(217,119,87,0.07); top: -160px; left: -120px; }
.glow-2 { width: 420px; height: 420px; background: rgba(90,120,160,0.06); bottom: -160px; right: -80px; }

.hero-overline {
  color: var(--accent);
  font-size: 0.76rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.22em;
  margin-bottom: 20px;
}
.hero h1 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(2.5rem, 5.4vw, 3.8rem);
  line-height: 1.08; letter-spacing: -1px; margin-bottom: 22px;
}
.grad { font-style: italic; color: var(--accent); }

.hero-sub { color: var(--muted); font-size: 1.06rem; line-height: 1.7; max-width: 50ch; }
.hero-sub em { color: var(--text); font-style: italic; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-guest-note { color: var(--muted); font-size: 0.86rem; margin-top: 14px; }
.hero-cta .btn { text-decoration: none; text-align: center; border-radius: 999px; }
.hero-cta .btn-big { width: auto; margin-top: 0; padding: 15px 30px; }
.btn-big-secondary { padding: 15px 26px; font-size: 1.02rem; }

.works-with { display: flex; align-items: baseline; gap: 14px; margin-top: 34px; flex-wrap: wrap; }
.works-label {
  color: var(--muted); font-size: 0.7rem;
  text-transform: uppercase; letter-spacing: 0.18em;
}
.works-chips { display: flex; gap: 0; flex-wrap: wrap; }
.works-chips .chip {
  border: none; padding: 0; font-size: 0.9rem; color: var(--muted);
}
.works-chips .chip + .chip::before { content: "·"; margin: 0 10px; opacity: 0.5; }

/* ================= MINI QUIZ (hero demo) ================= */

.hero-demo { perspective: 1000px; }
.mini-quiz {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.5);
  transition: transform 0.15s ease;
  will-change: transform;
}
.mini-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.mini-label {
  color: var(--accent); font-weight: 600; font-size: 0.72rem;
  text-transform: uppercase; letter-spacing: 0.16em;
}
.mini-score { color: var(--muted); font-size: 0.85rem; font-weight: 600; }
.mini-quiz h3 {
  font-family: var(--serif); font-weight: 400;
  font-size: 1.2rem; line-height: 1.4; margin-bottom: 16px; min-height: 3em;
}
.mini-answers { margin-top: 0; gap: 8px; }
.mini-answers .answer-btn { min-height: 52px; padding: 12px 14px; font-size: 0.9rem; }
.mini-feedback { min-height: 2.6em; margin-top: 13px; font-size: 0.88rem; color: var(--muted); line-height: 1.5; }
.mini-feedback .good { color: var(--good); font-weight: 600; }
.mini-feedback .bad { color: var(--bad); font-weight: 600; }

/* ================= SECTIONS ================= */

.section { padding: 72px 0 10px; }
.section h2 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.7rem, 3.4vw, 2.3rem);
  letter-spacing: -0.6px; text-align: center;
}
.section-sub { text-align: center; color: var(--muted); margin: 12px auto 42px; max-width: 58ch; line-height: 1.6; }

.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

.feature-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px;
}
.feature {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px;
  transition: transform 0.18s ease, border-color 0.18s ease, opacity 0.7s ease;
}
.feature:hover { transform: translateY(-4px); border-color: var(--border-strong); }
.feature-num {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  color: var(--accent); font-size: 0.76rem; letter-spacing: 0.12em;
  margin-bottom: 14px;
}
.feature h3 { margin-bottom: 9px; font-size: 1.04rem; font-weight: 600; }
.feature p { color: var(--muted); font-size: 0.92rem; line-height: 1.6; }
.feature code {
  background: rgba(255,255,255,0.08); border-radius: 6px; padding: 1px 6px; font-size: 0.85em;
}

/* steps */
.steps { display: flex; align-items: stretch; gap: 14px; }
.step {
  flex: 1;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px;
}
.step-num {
  font-family: var(--serif); font-style: italic;
  font-size: 2.2rem; line-height: 1; color: var(--accent);
  margin-bottom: 16px;
}
.step h3 { margin-bottom: 9px; font-size: 1.04rem; font-weight: 600; }
.step p { color: var(--muted); font-size: 0.92rem; line-height: 1.6; }
.step-arrow { align-self: center; color: var(--muted); font-size: 1.3rem; opacity: 0.6; }

/* ================= POWERED-BY MARQUEE ================= */

.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  padding: 8px 0;
}
.marquee-track {
  display: flex; gap: 12px; width: max-content;
  animation: marquee-scroll 34s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee-scroll { to { transform: translateX(-50%); } }
.m-chip {
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  padding: 11px 22px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.85rem; color: var(--muted);
  white-space: nowrap;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.m-chip:hover { color: var(--text); border-color: var(--accent); }

/* ================= PLANS ================= */

.plan-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px;
  align-items: stretch;
}
.plan {
  position: relative;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 30px 26px;
  display: flex; flex-direction: column;
  transition: transform 0.18s ease, border-color 0.18s ease, opacity 0.7s ease;
}
.plan:hover { transform: translateY(-4px); border-color: var(--border-strong); }
.plan-featured { border-color: rgba(217,119,87,0.5); background: linear-gradient(170deg, #1b1a20, var(--card)); }
.plan-flag {
  position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--accent); color: var(--accent-ink);
  border-radius: 999px; padding: 4px 14px;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  white-space: nowrap;
}
.plan h3 { font-size: 1rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.1em; }
.plan-price { font-family: var(--serif); font-size: 2.4rem; margin: 10px 0 18px; }
.plan-price span { font-size: 1rem; color: var(--muted); font-family: inherit; }
.plan ul { list-style: none; display: grid; gap: 10px; margin-bottom: 26px; }
.plan li { color: var(--muted); font-size: 0.92rem; padding-left: 22px; position: relative; line-height: 1.45; }
.plan li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); }
.plan .plan-btn { margin-top: auto; border-radius: 999px; width: 100%; }
.plan.active { border-color: var(--accent); }
.plan.active .plan-btn { pointer-events: none; opacity: 0.75; }
.plan-note { text-align: center; color: var(--good); font-size: 0.9rem; margin-top: 20px; min-height: 1.4em; }

/* ================= CTA BAND ================= */

.cta-band {
  margin: 90px 0 30px; text-align: center;
  background: linear-gradient(160deg, var(--card), var(--bg-2));
  border: 1px solid var(--border-strong);
  border-radius: 22px; padding: 60px 30px;
}
.cta-band h2 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.6rem, 3vw, 2.1rem); letter-spacing: -0.5px;
}
.cta-band p { color: var(--muted); margin: 12px 0 26px; }
.cta-btn {
  width: auto; display: inline-block; text-decoration: none; margin-top: 0;
  border-radius: 999px; padding: 15px 34px;
}

/* ================= FOOTER ================= */

.site-footer {
  display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap;
  max-width: 1060px; margin: 0 auto; padding: 28px 24px 44px;
  color: var(--muted); font-size: 0.86rem;
  border-top: 1px solid var(--border);
}
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); }

/* app page home link */
.home-link { color: var(--muted); text-decoration: none; font-size: 0.9rem; font-weight: 500; }
.home-link:hover { color: var(--text); }

/* ================= TRENDING SHOWCASE ================= */

.trending-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px;
}
.trend-card {
  display: flex; flex-direction: column;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px;
  text-decoration: none; color: var(--text);
  transition: transform 0.18s ease, border-color 0.18s ease;
}
.trend-card:hover { transform: translateY(-4px); border-color: rgba(217,119,87,0.5); }
.trend-card-top {
  display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 12px;
}
.trend-card .trend-rank {
  font-family: var(--serif); font-style: italic;
  color: var(--accent); font-size: 1.3rem;
}
.trend-stats { color: var(--muted); font-size: 0.8rem; }
.trend-card h3 {
  font-family: var(--serif); font-weight: 400;
  font-size: 1.15rem; line-height: 1.35; margin-bottom: 8px;
}
.trend-card p { color: var(--muted); font-size: 0.88rem; margin-bottom: 16px; }
.trend-cta { margin-top: auto; color: var(--accent); font-weight: 600; font-size: 0.92rem; }
.trend-empty { text-align: center; grid-column: 1 / -1; }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; padding-top: 52px; gap: 36px; }
  .steps { flex-direction: column; }
  .step-arrow { transform: rotate(90deg); align-self: center; }
  .nav-links { display: none; }
}

/* ---------------- access-code vault ---------------- */
.vault {
  max-width: 520px; margin: 36px auto 0; padding: 26px 28px;
  background: var(--card); border: 1px solid var(--border); border-radius: 16px;
  text-align: center;
}
.vault h3 { font-family: var(--serif); font-weight: 400; font-size: 1.3rem; margin-bottom: 6px; }
.vault-sub { color: var(--muted); font-size: 0.9rem; margin-bottom: 16px; }
.vault-form { display: flex; gap: 10px; }
.vault-form input {
  flex: 1; padding: 11px 14px; border-radius: 10px;
  background: var(--bg-2, #111014); border: 1px solid var(--border);
  color: var(--text); font-size: 0.92rem; letter-spacing: 0.06em;
}
.vault-form input:focus { outline: none; border-color: var(--accent); }
.vault-msg { min-height: 1.3em; margin-top: 12px; font-size: 0.88rem; }
.vault-msg.good { color: var(--good); }
.vault-msg.bad { color: var(--bad); }
.vault-step.hidden { display: none; }
@media (max-width: 520px) { .vault-form { flex-direction: column; } }
