/* DriftHabit — warm lifestyle-magazine theme (light, trustworthy) */
:root {
  --bg: #FAFAF7;
  --surface: #FFFFFF;
  --text: #1A1A1A;
  --muted: #5C5C5C;
  --border: #E5E2DC;
  --accent: #2F6B5A;
  --accent-hover: #255647;
  --highlight: #E8F2EE;
  --danger: #8B3A3A;
  --cream-deep: #F3F0E8;
  --sand: #EDE8DC;
  --chip-money: #2F6B5A;
  --chip-subscriptions: #8A5A2B;
  --chip-focus: #65548F;
  --chip-attention: #7A5B8F;
  --chip-sleep: #465B8D;
  --chip-night: #3F6E82;
  --chip-spending: #A35D4D;
  --chip-freedom: #7C6940;
  --radius: 18px;
  --radius-sm: 12px;
  --radius-xl: 22px;
  --shadow: 0 4px 20px rgba(26, 26, 26, 0.05), 0 1px 3px rgba(26, 26, 26, 0.04);
  --shadow-hover: 0 10px 36px rgba(47, 107, 90, 0.12), 0 2px 8px rgba(26, 26, 26, 0.05);
  --font-display: "Fraunces", "Georgia", "Times New Roman", serif;
  --font-body: "DM Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow-x: hidden;
}

/* Soft paper grain (CSS only) */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.35;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.45'/%3E%3C/svg%3E");
  background-size: 180px 180px;
  mix-blend-mode: multiply;
}

/* Ambient soft blobs */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 55% 40% at 8% 12%, rgba(232, 242, 238, 0.9) 0%, transparent 55%),
    radial-gradient(ellipse 45% 35% at 92% 18%, rgba(237, 232, 220, 0.75) 0%, transparent 50%),
    radial-gradient(ellipse 50% 40% at 70% 88%, rgba(232, 242, 238, 0.55) 0%, transparent 55%),
    radial-gradient(ellipse 40% 30% at 15% 75%, rgba(243, 240, 232, 0.7) 0%, transparent 50%);
}

#app, .site-header, .site-footer, main {
  position: relative;
  z-index: 1;
}

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

.container { width: 100%; max-width: 720px; margin: 0 auto; padding: 0 1.25rem; }
.container-wide { max-width: 980px; margin: 0 auto; padding: 0 1.25rem; }

/* —— Header —— */
.site-header {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0.9rem 0;
  position: sticky; top: 0; z-index: 40;
}
.site-header .inner {
  display: flex; align-items: center; justify-content: space-between;
  max-width: 980px; margin: 0 auto; padding: 0 1.25rem;
}
.logo {
  font-family: var(--font-display);
  font-weight: 700; font-size: 1.45rem; color: var(--text);
  letter-spacing: -0.03em; text-decoration: none;
  font-variation-settings: "SOFT" 50, "WONK" 0.5;
}
.logo span { color: var(--accent); }
.logo:hover { text-decoration: none; }
.nav-links { display: flex; gap: 1.35rem; align-items: center; }
.nav-links a {
  color: var(--muted); font-size: 0.92rem; font-weight: 500;
  text-decoration: none; letter-spacing: 0.01em;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a.nav-cta {
  display: inline-flex; align-items: center; white-space: nowrap;
  background: var(--accent); color: #fff; font-weight: 650;
  padding: 0.42rem 0.95rem; border-radius: 999px; line-height: 1.2;
  box-shadow: 0 3px 10px rgba(47, 107, 90, 0.22);
  transition: background 0.15s, box-shadow 0.15s;
}
.nav-links a.nav-cta:hover {
  background: var(--accent-hover); color: #fff; text-decoration: none;
  box-shadow: 0 5px 14px rgba(47, 107, 90, 0.3);
}
@media (max-width: 480px) {
  .site-header .inner { gap: 0.75rem; }
  .nav-links { gap: 0.9rem; flex-wrap: nowrap; }
  .nav-links a { white-space: nowrap; }
  .nav-links a.nav-cta { padding: 0.38rem 0.8rem; }
}

main { flex: 1; padding: 2rem 0 3.5rem; }

/* —— Hero —— */
.hero {
  text-align: center;
  padding: 2.5rem 1rem 2.6rem;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-radius: 28px;
}
.hero::before {
  content: "";
  position: absolute;
  width: min(560px, 92%);
  height: 250px;
  left: 50%;
  top: 47%;
  transform: translate(-50%, -50%) rotate(-3deg);
  border-radius: 48% 52% 44% 56% / 58% 42% 58% 42%;
  background:
    radial-gradient(circle at 32% 42%, rgba(230, 239, 232, 0.95) 0 24%, transparent 58%),
    radial-gradient(circle at 72% 55%, rgba(241, 232, 215, 0.8) 0 20%, transparent 56%);
  z-index: -1;
  pointer-events: none;
}
.hero-pattern {
  width: min(100%, 330px); height: 150px; margin: 0 auto 0.9rem;
  position: relative;
}
.hero-pattern svg { width: 100%; height: 100%; display: block; }
.hero > *:not(.hero-pattern) { position: relative; z-index: 1; }
.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 6.5vw, 3.15rem);
  font-weight: 650;
  letter-spacing: -0.035em;
  line-height: 1.12;
  margin-bottom: 0.85rem;
  font-variation-settings: "SOFT" 40, "WONK" 0.4;
}
.hero p {
  color: var(--muted);
  font-size: 1.08rem;
  max-width: 30rem;
  margin: 0 auto 1.65rem;
  line-height: 1.55;
}
.hero-cta { margin-top: 0.25rem; }
.hero .eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 0.85rem;
  padding: 0.3rem 0.75rem;
  background: var(--highlight);
  border-radius: 999px;
}
/* —— Homepage lifestyle hero (cream magazine panel) —— */
.homepage-hero {
  background: linear-gradient(180deg, var(--cream-deep) 0%, rgba(250, 250, 247, 0.35) 70%, transparent 100%);
  margin-bottom: 0.35rem;
  padding: 2.1rem 1.1rem 2.35rem;
}
.homepage-hero p { margin-bottom: 0; }


/* —— Quiz grid / cards —— */
.quiz-grid { display: grid; grid-template-columns: 1fr; gap: 1.1rem; }
@media (min-width: 600px) { .quiz-grid { grid-template-columns: 1fr 1fr; } }

.quiz-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 1.4rem 1.45rem 1.35rem;
  box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 0.45rem;
  transition: border-color 0.18s, box-shadow 0.18s, transform 0.18s;
  text-decoration: none; color: inherit;
  position: relative;
  overflow: hidden;
}
.quiz-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--chip-color, var(--accent));
  opacity: 0.85;
}
.quiz-card:hover {
  border-color: rgba(47, 107, 90, 0.35);
  box-shadow: var(--shadow-hover);
  text-decoration: none;
  transform: translateY(-2px);
}
.quiz-card.stub { opacity: 0.78; }
.quiz-card.stub:hover {
  border-color: var(--border);
  box-shadow: var(--shadow);
  cursor: default;
  transform: none;
}
.quiz-card .card-top {
  display: flex; align-items: center; gap: 0.65rem; margin-bottom: 0.2rem;
}
.quiz-card .quiz-icon {
  width: 40px; height: 40px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.25rem; line-height: 1;
  background: var(--chip-bg, var(--highlight));
  flex-shrink: 0;
}
.quiz-card .tag {
  font-size: 0.7rem; font-weight: 650; text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--chip-color, var(--accent));
  background: var(--chip-bg, var(--highlight));
  padding: 0.28rem 0.6rem;
  border-radius: 999px;
  display: inline-block;
}
.quiz-card .tag.soon {
  color: var(--muted);
  background: var(--cream-deep);
}
.quiz-card h2 {
  font-family: var(--font-display);
  font-size: 1.22rem;
  font-weight: 650;
  letter-spacing: -0.025em;
  line-height: 1.25;
  margin-top: 0.15rem;
}
.quiz-card p { color: var(--muted); font-size: 0.94rem; flex: 1; line-height: 1.5; }
.quiz-card .meta {
  font-size: 0.82rem; color: var(--muted); margin-top: 0.4rem;
  font-weight: 500;
}
.section-label {
  margin: 2.75rem 0 1rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: -0.02em;
}

.chip-money { --chip-color: var(--chip-money); --chip-bg: #E5F2EC; }
.chip-subscriptions { --chip-color: var(--chip-subscriptions); --chip-bg: #FFF0D8; }
.chip-focus { --chip-color: var(--chip-focus); --chip-bg: #EEE9F7; }
.chip-attention { --chip-color: var(--chip-attention); --chip-bg: #F3EAF7; }
.chip-sleep { --chip-color: var(--chip-sleep); --chip-bg: #E9EEF9; }
.chip-night { --chip-color: var(--chip-night); --chip-bg: #E7F2F5; }
.chip-spending { --chip-color: var(--chip-spending); --chip-bg: #F8E8E2; }
.chip-freedom { --chip-color: var(--chip-freedom); --chip-bg: #F3EEDF; }

/* —— Buttons —— */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem;
  font-family: var(--font-body); font-size: 1.05rem; font-weight: 650;
  padding: 0.95rem 1.55rem; border-radius: 999px; border: none; cursor: pointer;
  text-decoration: none; transition: background 0.15s, transform 0.1s, box-shadow 0.15s;
  min-height: 54px;
}
.btn:active { transform: scale(0.98); }
.btn-primary {
  background: var(--accent); color: #fff;
  box-shadow: 0 4px 14px rgba(47, 107, 90, 0.28);
}
.btn-primary:hover {
  background: var(--accent-hover); text-decoration: none; color: #fff;
  box-shadow: 0 6px 18px rgba(47, 107, 90, 0.35);
}
.btn-secondary { background: var(--highlight); color: var(--accent); }
.btn-secondary:hover { background: #d9ebe4; text-decoration: none; }
.btn-ghost {
  background: transparent; color: var(--muted);
  border: 1px solid var(--border);
}
.btn-ghost:hover { border-color: var(--muted); text-decoration: none; color: var(--text); }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; box-shadow: none; }

/* —— Quiz shell —— */
.quiz-shell { max-width: 560px; margin: 0 auto; }

.progress-wrap { margin-bottom: 1.6rem; }
.progress-label {
  display: flex; justify-content: space-between; font-size: 0.82rem;
  color: var(--muted); margin-bottom: 0.5rem; font-weight: 550;
}
.progress-bar {
  height: 12px;
  background: var(--sand);
  border-radius: 999px;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(26, 26, 26, 0.06);
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent) 0%, #3d8a72 100%);
  border-radius: 999px;
  transition: width 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 0 8px rgba(47, 107, 90, 0.25);
}

.question-card, .start-card, .teaser-card, .result-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 1.65rem 1.5rem;
  box-shadow: var(--shadow);
}
.question-card h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 650;
  letter-spacing: -0.025em;
  margin-bottom: 1.15rem;
  line-height: 1.3;
}
.start-card .tag-pill {
  display: inline-block;
  font-size: 0.7rem; font-weight: 650; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--accent);
  background: var(--highlight);
  padding: 0.3rem 0.7rem; border-radius: 999px; margin-bottom: 0.75rem;
}
.start-card h1 {
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 4.5vw, 2rem);
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin-bottom: 0.85rem;
}
.start-card p { color: var(--muted); margin-bottom: 1.35rem; font-size: 1.02rem; }

/* —— Answers —— */
.answers { display: flex; flex-direction: column; gap: 0.7rem; }
.answer-btn {
  text-align: left;
  background: var(--bg);
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.05rem 1.15rem;
  font-family: var(--font-body);
  font-size: 1.02rem;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, color 0.15s, box-shadow 0.15s;
  line-height: 1.4;
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  position: relative;
}
.answer-btn .answer-check {
  width: 22px; height: 22px; border-radius: 50%;
  border: 2px solid var(--border);
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; font-weight: 700; color: transparent;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
@media (hover: hover) {
  .answer-btn:hover {
    border-color: var(--accent);
    background: var(--highlight);
  }
}
.answer-btn.selected {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(47, 107, 90, 0.25);
}
.answer-btn.selected .answer-check {
  background: #fff;
  border-color: #fff;
  color: var(--accent);
}
.quiz-nav { display: flex; gap: 0.75rem; margin-top: 1.35rem; }

/* —— Computing —— */
.computing {
  text-align: center; padding: 3.5rem 1rem; color: var(--muted);
}
.computing .spinner {
  width: 40px; height: 40px;
  border: 3px solid var(--sand);
  border-top-color: var(--accent);
  border-radius: 50%;
  margin: 0 auto 1.1rem;
  animation: spin 0.75s linear infinite;
}
.computing p {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--text);
  font-weight: 550;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* —— Teaser —— */
.teaser-card .type-label {
  font-size: 0.72rem; font-weight: 650; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--accent); margin-bottom: 0.5rem;
}
.teaser-card .type-chip {
  display: inline-flex; align-items: center; gap: 0.4rem;
  font-size: 0.72rem; font-weight: 650; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--chip-color, var(--accent));
  background: var(--chip-bg, var(--highlight));
  padding: 0.3rem 0.7rem; border-radius: 999px; margin-bottom: 0.75rem;
}
.teaser-card h2 {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 5vw, 2.4rem);
  font-weight: 650;
  margin-bottom: 0.75rem;
  letter-spacing: -0.035em;
  line-height: 1.15;
}
.teaser-card .blurb {
  color: var(--muted); margin-bottom: 1.35rem; font-size: 1.05rem; line-height: 1.55;
}
.locked-sections {
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1.15rem;
  margin-bottom: 1.35rem;
  background: linear-gradient(180deg, var(--cream-deep) 0%, var(--bg) 100%);
}
.locked-sections li {
  list-style: none; padding: 0.45rem 0; color: var(--muted); font-size: 0.95rem;
  filter: blur(3.5px); user-select: none;
}
.locked-sections .lock-note {
  filter: none; font-size: 0.85rem; font-weight: 650;
  color: var(--accent); margin-top: 0.55rem;
}

/* —— Paywall gate —— */
.gate-overlay {
  position: fixed; inset: 0;
  background: rgba(26, 26, 26, 0.42);
  display: flex; align-items: flex-end; justify-content: center;
  z-index: 100; padding: 1rem;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
@media (min-width: 600px) { .gate-overlay { align-items: center; } }
.gate-modal {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: 1.85rem 1.55rem;
  max-width: 440px; width: 100%;
  box-shadow: 0 20px 56px rgba(0,0,0,0.2);
  max-height: 90dvh; overflow-y: auto;
  border: 1px solid var(--border);
}
.gate-modal h2 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 650;
  letter-spacing: -0.025em;
  margin-bottom: 0.85rem;
  line-height: 1.28;
}
.gate-modal h2 em {
  font-style: italic;
  color: var(--accent);
  font-weight: 650;
}
.price-line {
  text-align: center; margin: 1.1rem 0; padding: 1.1rem;
  background: var(--highlight);
  border-radius: var(--radius-sm);
  font-size: 1.02rem; font-weight: 600;
}
.price-line .amt {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 650;
  letter-spacing: -0.02em;
  display: block;
  margin-bottom: 0.2rem;
}
.gate-features { list-style: none; margin: 0 0 1.35rem; font-size: 0.98rem; }
.gate-features li {
  padding: 0.4rem 0 0.4rem 1.55rem;
  position: relative;
}
.gate-features li::before {
  content: "✓";
  position: absolute; left: 0;
  color: var(--accent); font-weight: 700;
}
.cta-sub {
  font-size: 0.8rem; color: var(--muted);
  text-align: center; margin-top: 0.8rem; line-height: 1.45;
}
.disclaimer {
  font-size: 0.8rem; color: var(--muted);
  margin-top: 1rem; text-align: center; line-height: 1.45;
}
.gate-legal {
  font-size: 0.72rem; margin-top: 0.85rem; opacity: 0.9;
}

/* —— Full result —— */
.result-type-label {
  font-size: 0.72rem; font-weight: 650; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--accent); margin-bottom: 0.5rem;
}
.result-card .type-chip {
  display: inline-flex; align-items: center; gap: 0.4rem;
  font-size: 0.72rem; font-weight: 650; text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--chip-color, var(--accent));
  background: var(--chip-bg, var(--highlight));
  padding: 0.32rem 0.75rem; border-radius: 999px; margin-bottom: 0.85rem;
}
.result-card h1 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 5vw, 2.35rem);
  font-weight: 650;
  letter-spacing: -0.035em;
  margin-bottom: 1.15rem;
  line-height: 1.15;
}
.result-card .profile p {
  margin-bottom: 0.9rem;
  color: var(--text);
  font-size: 1.02rem;
  line-height: 1.6;
}
.plan-section {
  margin-top: 1.65rem;
  padding-top: 1.4rem;
  border-top: 1px solid var(--border);
}
.plan-section h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 650;
  margin-bottom: 0.9rem;
  letter-spacing: -0.02em;
}
.plan-section ul {
  list-style: none;
  display: flex; flex-direction: column; gap: 0.7rem;
}
.plan-section li {
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 1rem 1.1rem 1rem 1.15rem;
  font-size: 0.96rem;
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  line-height: 1.5;
}
.plan-section li strong {
  display: block;
  color: var(--accent);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.3rem;
  font-weight: 700;
}

/* —— Pricing —— */
.pricing-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2.15rem 1.6rem;
  text-align: center;
  box-shadow: var(--shadow);
  max-width: 420px; margin: 0 auto;
}
.pricing-box h1 {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 650;
  margin-bottom: 0.5rem;
  letter-spacing: -0.03em;
}
.pricing-box .amount {
  font-family: var(--font-display);
  font-size: 2.75rem;
  font-weight: 650;
  margin: 1.1rem 0 0.25rem;
  letter-spacing: -0.03em;
}
.pricing-box .amount small {
  font-size: 1rem; font-weight: 500; color: var(--muted);
  font-family: var(--font-body);
}

/* —— Legal —— */
.legal { max-width: 640px; margin: 0 auto; }
.legal h1 {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 650;
  margin-bottom: 1rem;
  letter-spacing: -0.03em;
}
.legal h2 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  margin: 1.6rem 0 0.55rem;
}
.legal p, .legal li { color: var(--muted); margin-bottom: 0.75rem; }
.legal ul { padding-left: 1.25rem; margin-bottom: 1rem; }

/* —— Footer —— */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.6rem 0;
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(8px);
}
.site-footer .inner {
  max-width: 980px; margin: 0 auto; padding: 0 1.25rem;
  display: flex; flex-wrap: wrap; gap: 0.75rem 1.5rem;
  justify-content: space-between; align-items: center;
  font-size: 0.85rem; color: var(--muted);
}
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--accent); }
.footer-links { display: flex; gap: 1rem; flex-wrap: wrap; }

.hidden { display: none !important; }
.locked-notice { text-align: center; padding: 3rem 1rem; }
.locked-notice h1 {
  font-family: var(--font-display);
  font-weight: 650;
  margin-bottom: 0.75rem;
  letter-spacing: -0.03em;
}
.locked-notice p { color: var(--muted); margin-bottom: 1.5rem; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.answer-btn:focus-visible { outline-offset: 0; }
.btn:focus-visible { outline-offset: 3px; }


/* —— Livelier magazine motion (trust-safe, not neon) —— */
@keyframes drift-fade-up {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes drift-soft-pulse {
  0%, 100% { opacity: 0.85; transform: translate(-50%, -50%) rotate(-3deg) scale(1); }
  50% { opacity: 1; transform: translate(-50%, -50%) rotate(-2deg) scale(1.03); }
}
@keyframes drift-shimmer {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}
@keyframes drift-pop {
  0% { opacity: 0; transform: scale(0.92); }
  60% { opacity: 1; transform: scale(1.02); }
  100% { opacity: 1; transform: scale(1); }
}
@keyframes drift-plan-in {
  from { opacity: 0; transform: translateX(-6px); }
  to { opacity: 1; transform: translateX(0); }
}
@keyframes drift-sparkle {
  0% { opacity: 0; transform: translateY(8px) scale(0.6); }
  30% { opacity: 0.9; }
  100% { opacity: 0; transform: translateY(-48px) scale(1); }
}

.hero { animation: drift-fade-up 0.7s cubic-bezier(0.22, 1, 0.36, 1) both; }
.hero::before { animation: drift-soft-pulse 8s ease-in-out infinite; }
.hero .eyebrow { animation: drift-fade-up 0.55s 0.05s both; }
.hero h1 { animation: drift-fade-up 0.65s 0.1s both; }
.hero p { animation: drift-fade-up 0.65s 0.18s both; }
.hero-cta { animation: drift-fade-up 0.65s 0.26s both; }

.quiz-grid .quiz-card {
  animation: drift-fade-up 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.quiz-grid .quiz-card:nth-child(1) { animation-delay: 0.04s; }
.quiz-grid .quiz-card:nth-child(2) { animation-delay: 0.08s; }
.quiz-grid .quiz-card:nth-child(3) { animation-delay: 0.12s; }
.quiz-grid .quiz-card:nth-child(4) { animation-delay: 0.16s; }
.quiz-grid .quiz-card:nth-child(5) { animation-delay: 0.2s; }
.quiz-grid .quiz-card:nth-child(6) { animation-delay: 0.24s; }
.quiz-grid .quiz-card:nth-child(7) { animation-delay: 0.28s; }
.quiz-grid .quiz-card:nth-child(8) { animation-delay: 0.32s; }

.quiz-card .quiz-icon {
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}
.quiz-card:hover .quiz-icon { transform: scale(1.08) rotate(-4deg); }

.progress-fill {
  background: linear-gradient(
    90deg,
    var(--accent) 0%,
    #3d8a72 45%,
    #5aa88a 55%,
    #3d8a72 65%,
    var(--accent) 100%
  );
  background-size: 200% 100%;
  animation: drift-shimmer 2.8s linear infinite;
}

.question-card, .start-card, .teaser-card {
  animation: drift-fade-up 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.answer-btn { transition: border-color 0.15s, background 0.15s, color 0.15s, box-shadow 0.15s, transform 0.12s; }
.answer-btn:active { transform: scale(0.985); }
.answer-btn.selected { animation: drift-pop 0.28s ease-out; }

/* Richer result cards */
.result-card {
  position: relative;
  overflow: hidden;
  animation: drift-pop 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
  border-top: 3px solid var(--chip-color, var(--accent));
}
.result-card::after {
  content: "";
  position: absolute;
  top: -40%;
  right: -20%;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--chip-bg, var(--highlight)) 0%, transparent 70%);
  opacity: 0.7;
  pointer-events: none;
  z-index: 0;
}
.result-card > * { position: relative; z-index: 1; }
.result-card .result-banner {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.85rem;
  flex-wrap: wrap;
}
.result-card .result-unlocked {
  font-size: 0.7rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  background: var(--highlight);
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
}
.result-card .teaser-echo {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.55;
  margin: -0.35rem 0 1.15rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.plan-section li {
  animation: drift-plan-in 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.plan-section li:nth-child(1) { animation-delay: 0.05s; }
.plan-section li:nth-child(2) { animation-delay: 0.12s; }
.plan-section li:nth-child(3) { animation-delay: 0.19s; }
.plan-section li:nth-child(4) { animation-delay: 0.26s; }

/* Soft petal celebration (no confetti/scam energy) */
.celebrate-burst {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 200;
  overflow: hidden;
}
.celebrate-burst .petal {
  position: absolute;
  bottom: 18%;
  left: var(--x, 50%);
  width: var(--s, 10px);
  height: var(--s, 10px);
  border-radius: 50% 50% 45% 55%;
  background: var(--c, var(--accent));
  opacity: 0;
  animation: drift-sparkle var(--d, 1.2s) ease-out forwards;
  animation-delay: var(--delay, 0s);
}

@media (prefers-reduced-motion: reduce) {
  .progress-fill, .quiz-card, .btn, .answer-btn { transition: none; }
  .computing .spinner { animation: none; border-top-color: var(--accent); }
  .hero, .hero::before, .hero .eyebrow, .hero h1, .hero p, .hero-cta,
  .quiz-grid .quiz-card, .question-card, .start-card, .teaser-card,
  .result-card, .plan-section li, .answer-btn.selected, .progress-fill,
  .celebrate-burst .petal {
    animation: none !important;
  }
  .quiz-card:hover .quiz-icon { transform: none; }
}

/* --- Pro lock + account (v3) --- */
.quiz-card.locked {
  position: relative;
  opacity: 0.92;
  cursor: pointer;
}
.quiz-card.locked::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, transparent 40%, rgba(250,250,247,0.55));
  pointer-events: none;
}
.quiz-card .lock-badge,
.quiz-card .free-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.quiz-card .lock-badge { font-size: 1.1rem; }
.quiz-card .free-badge {
  background: var(--highlight, #E8F2EE);
  color: var(--accent, #2F6B5A);
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
}
.quiz-card .tag.locked-tag {
  background: #F0EBE3;
  color: #5C5C5C;
}
.section-label {
  font-family: Fraunces, Georgia, serif;
  font-size: 1.35rem;
  margin: 2.25rem 0 0.75rem;
  color: var(--text, #1A1A1A);
}
.section-sub {
  color: var(--muted, #5C5C5C);
  margin: -0.25rem 0 1rem;
  font-size: 0.95rem;
}
.hard-gate .blurb { font-size: 1.05rem; }
.gate-lead {
  color: var(--muted, #5C5C5C);
  margin: 0 0 1rem;
  line-height: 1.5;
}
.trial-callout {
  background: var(--highlight, #E8F2EE);
  color: var(--text, #1A1A1A);
  padding: 0.85rem 1rem;
  border-radius: 12px;
  margin: 0 0 1.25rem;
  font-size: 0.98rem;
}
.lock-hero {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}
.account-box, .pricing-box {
  max-width: 440px;
  margin: 2.5rem auto;
  background: #fff;
  border: 1px solid var(--border, #E5E2DC);
  border-radius: 20px;
  padding: 2rem 1.5rem;
  text-align: center;
}
.account-box h1, .pricing-box h1 {
  font-family: Fraunces, Georgia, serif;
  margin-bottom: 0.5rem;
}
.account-email {
  font-weight: 600;
  font-size: 1.05rem;
  margin: 1rem 0 0.35rem;
}
.account-status {
  color: var(--muted, #5C5C5C);
  margin-bottom: 1rem;
}
.account-status.pro { color: var(--accent, #2F6B5A); font-weight: 600; }
.account-status.trial { color: var(--accent, #2F6B5A); }
.account-actions { display: flex; flex-direction: column; gap: 0.65rem; margin: 1rem 0; }
.login-form { text-align: left; margin: 1rem 0; }
.login-form label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}
.login-form input {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--border, #E5E2DC);
  border-radius: 12px;
  font: inherit;
  margin-bottom: 0.85rem;
  background: #fff;
}
.login-msg {
  margin-top: 0.75rem;
  padding: 0.75rem 1rem;
  background: var(--highlight, #E8F2EE);
  border-radius: 12px;
  font-size: 0.95rem;
  text-align: left;
}
.login-msg.hidden { display: none; }
.form-error {
  color: #8B3A3A;
  background: #F8EDEA;
  padding: 0.65rem 0.85rem;
  border-radius: 10px;
  margin-bottom: 0.75rem;
  font-size: 0.92rem;
}
.account-divider {
  border: none;
  border-top: 1px solid var(--border, #E5E2DC);
  margin: 1.5rem 0;
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 0.65rem; }
.muted { color: var(--muted, #5C5C5C); font-size: 0.92rem; }


/* --- Flagship Money IQ --- */
:root { --chip-moneyiq: #2F6B5A; }
.chip-moneyiq { --chip-color: #1F5A4A; --chip-bg: #E2F0EA; }

.flagship-link {
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.flagship-link:hover {
  color: inherit;
  transform: translateY(-2px);
  box-shadow: 0 22px 44px rgba(26, 26, 26, 0.1);
}
.flagship-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.flagship-featured {
  display: grid;
  grid-template-columns: 1.35fr 0.9fr;
  gap: 1.75rem;
  align-items: stretch;
  margin: 1.75rem 0 0.5rem;
  padding: 1.75rem 1.6rem;
  background: linear-gradient(145deg, #FFFFFF 0%, #E8F2EE 55%, #F7F3EA 100%);
  border: 1px solid var(--border, #E5E2DC);
  border-radius: 24px;
  box-shadow: 0 18px 40px rgba(26, 26, 26, 0.06);
  position: relative;
  overflow: hidden;
}
.flagship-featured::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 5px;
  background: var(--chip-color, var(--accent));
}
.flagship-copy { position: relative; z-index: 1; }
.flagship-copy h1,
.flagship-copy h2 {
  font-family: Fraunces, Georgia, serif;
  font-size: clamp(1.65rem, 3vw, 2.15rem);
  line-height: 1.15;
  margin: 0.35rem 0 0.65rem;
  letter-spacing: -0.025em;
}
.flagship-copy > p { color: var(--muted); margin: 0 0 0.75rem; line-height: 1.55; max-width: 36rem; }
.flagship-meta {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--chip-color, var(--accent)) !important;
  margin-bottom: 1rem !important;
}
.flagship-note {
  margin: 0.85rem 0 0 !important;
  font-size: 0.82rem !important;
  color: var(--muted) !important;
}
.flagship-visual { display: flex; align-items: center; justify-content: center; }
.flagship-score-card {
  width: 100%;
  max-width: 260px;
  background: #FFFDF8;
  border: 1px solid rgba(47, 107, 90, 0.22);
  border-radius: 20px;
  padding: 1.35rem 1.2rem 1.2rem;
  text-align: center;
  box-shadow: 0 10px 28px rgba(47, 107, 90, 0.08);
}
.flagship-score-label {
  font-family: Fraunces, Georgia, serif;
  font-size: 1.05rem;
  margin-bottom: 0.85rem;
}
.flagship-score-rings {
  display: flex;
  justify-content: center;
  gap: 0.45rem;
  margin-bottom: 0.85rem;
}
.flagship-score-rings span {
  width: 42px; height: 42px;
  border-radius: 50%;
  border: 3px solid #2F6B5A;
  opacity: 0.35;
  display: inline-block;
}
.flagship-score-rings span:nth-child(2) { opacity: 0.65; transform: scale(1.05); }
.flagship-score-rings span:nth-child(3) { opacity: 1; background: #E8F2EE; }
.flagship-score-hint {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.4;
}

.section-break {
  font-family: Fraunces, Georgia, serif;
  font-size: 1.05rem;
  color: var(--accent);
  margin: 0 0 0.75rem;
  padding: 0.55rem 0.85rem;
  background: var(--highlight);
  border-radius: 12px;
  border: 1px solid rgba(47, 107, 90, 0.12);
}
.section-chip {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--highlight);
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  margin-bottom: 0.75rem;
}
.section-chip.subtle { opacity: 0.75; background: transparent; border: 1px solid var(--border); }

.start-flagship .tag-pill { background: var(--highlight); color: var(--accent); }
.start-tease {
  color: var(--accent);
  font-weight: 600;
  margin: -0.25rem 0 1rem;
}
.start-disclaimer { margin-top: 1rem; font-size: 0.8rem; }

.score-pill {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.55rem;
  margin: 0.75rem 0 0.5rem;
  padding: 0.85rem 1rem;
  background: var(--highlight);
  border-radius: 14px;
  border: 1px solid rgba(47, 107, 90, 0.15);
}
.score-pill .score-num {
  font-family: Fraunces, Georgia, serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}
.score-pill .score-of { color: var(--muted); font-weight: 600; }
.score-pill .score-caption {
  width: 100%;
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 600;
}

@media (max-width: 820px) {
  .flagship-featured { grid-template-columns: 1fr; padding: 1.35rem 1.15rem; }
  .flagship-visual { order: -1; }
  .flagship-score-card { max-width: none; }
}

/* —— Boot loading —— */
.boot-loading {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  color: var(--muted);
  padding: 3rem 1rem;
}
.boot-loading .spinner {
  width: 36px;
  height: 36px;
  border: 3px solid var(--sand);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
}
.boot-loading p {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--text);
  font-weight: 550;
}

/* —— Account empty states —— */
.account-empty {
  margin-top: 1.5rem;
  padding: 1.25rem 1.15rem;
  background: var(--highlight);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: left;
}
.account-empty.signed-out {
  background: transparent;
  border: none;
  padding: 0;
  margin: 0 0 1rem;
}
.account-empty h2 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 650;
  margin-bottom: 0.35rem;
  color: var(--text);
}
.account-empty p {
  color: var(--muted);
  margin-bottom: 0.9rem;
  font-size: 0.95rem;
}
.account-empty .btn {
  margin-right: 0.5rem;
  margin-bottom: 0.4rem;
}
.account-empty.signed-out p { margin-bottom: 0; }

/* —— 404 —— */
.not-found .eyebrow {
  color: var(--accent);
  font-weight: 650;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.75rem;
  margin-bottom: 0.5rem;
}


/* —— Pro drip calendar + week check-ins + shifted —— */
.release-calendar {
  margin-top: 2.5rem;
  padding-top: 0.5rem;
}
.coming-grid .quiz-card {
  cursor: default;
  position: relative;
}
.coming-badge {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--highlight);
  border: 1px solid rgba(47, 107, 90, 0.22);
  border-radius: 999px;
  padding: 0.28rem 0.55rem;
}
.pro-drip-foot {
  margin-top: 1rem;
  font-size: 0.9rem;
}
.plan-checkin-lead {
  color: var(--muted);
  font-size: 0.9rem;
  margin: -0.35rem 0 0.9rem;
}
.plan-weeks {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.plan-week-text {
  line-height: 1.5;
}
.week-checkin {
  margin-top: 0.75rem;
  padding-top: 0.65rem;
  border-top: 1px dashed var(--border);
}
.checkin-label {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.4rem;
}
.checkin-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.checkin-btn {
  appearance: none;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.checkin-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.checkin-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.plan-week.has-done {
  border-left-color: #2F6B5A;
  background: #f3faf7;
}
.plan-week.has-partial {
  border-left-color: #C68B55;
  background: #fffaf3;
}
.plan-week.has-skip {
  border-left-color: #9a9a9a;
  background: #f7f7f5;
  opacity: 0.92;
}
.shift-banner {
  margin: 0.85rem 0 1rem;
  padding: 0.9rem 1rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--highlight);
  text-align: left;
}
.shift-banner.changed {
  background: #fff8ef;
  border-color: rgba(198, 139, 85, 0.45);
}
.shift-banner.same {
  background: var(--highlight);
}
.shift-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.25rem;
}
.shift-banner p {
  margin: 0;
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.45;
}
.gate-features em {
  font-style: italic;
  font-weight: 600;
}

/* Phone quiz fit — keep choices on screen with the question */
.start-card .quiz-about {
  color: var(--text);
  margin-bottom: 0.75rem;
}
.question-card h2,
.answer-btn,
.quiz-card h2,
.quiz-card p,
.start-card h1,
.start-card p {
  overflow-wrap: break-word;
}
.answer-btn { max-width: 100%; }
.drip-card { cursor: pointer; }
@media (max-width: 480px) {
  body.in-quiz .site-header { padding: 0.4rem 0; }
  body.in-quiz .logo { font-size: 1.15rem; }
  body.in-quiz .nav-links { gap: 0.85rem; }
  body.in-quiz .nav-links a { font-size: 0.84rem; }
  body.in-quiz .nav-links a.nav-cta { padding: 0.3rem 0.7rem; }
  body.in-question .site-footer { display: none; }
  body.in-question main { padding: 0.55rem 0 0.85rem; }
  body.in-question .container { padding-left: 0.85rem; padding-right: 0.85rem; }
  body.in-question .progress-wrap { margin-bottom: 0.5rem; }
  body.in-question .section-break {
    margin-bottom: 0.4rem;
    padding: 0.32rem 0.65rem;
    font-size: 0.92rem;
  }
  body.in-question .section-break + .question-card .section-chip { display: none; }
  body.in-question .question-card {
    padding: 0.85rem 0.8rem 0.7rem;
  }
  body.in-question .question-card h2 {
    font-size: 1.05rem;
    line-height: 1.25;
    margin-bottom: 0.55rem;
  }
  body.in-question .answers { gap: 0.4rem; }
  body.in-question .answer-btn {
    min-height: 44px;
    padding: 0.58rem 0.7rem;
    font-size: 0.94rem;
    line-height: 1.3;
  }
  body.in-question .quiz-nav { margin-top: 0.55rem; }
  .homepage-hero { padding: 1.35rem 0.85rem 1.4rem; }
  .homepage-hero h1 { font-size: 1.85rem; }
}
