@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,wght@0,400;0,600;1,500&family=Work+Sans:wght@400;500;600;700&display=swap');

:root {
  --charcoal: #1B171C;
  --plum: #241F26;
  --plum-light: #2C2530;
  --pink: #E85DAD;
  --blush: #E4ABA5;
  --violet: #6E54D7;
  --cream: #F0E4D2;
  --taupe: #8C7F76;
  --line: rgba(240, 228, 210, 0.12);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--charcoal);
  color: var(--cream);
  font-family: 'Work Sans', sans-serif;
  -webkit-font-smoothing: antialiased;
}

body { line-height: 1.55; }

h1, h2, h3 {
  font-family: 'Work Sans', sans-serif;
  font-weight: 600;
  margin: 0 0 0.5em;
  line-height: 1.15;
}

.accent {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 500;
  color: var(--blush);
}

p { color: var(--cream); opacity: 0.92; max-width: 62ch; }

a { color: var(--pink); }

.wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line);
}

.logo {
  font-family: 'Fraunces', serif;
  font-size: 1.15rem;
  color: var(--cream);
  text-decoration: none;
}
.logo span { color: var(--taupe); font-size: 0.85rem; margin-left: 6px; }

.btn {
  display: inline-block;
  font-family: 'Work Sans', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 13px 26px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--pink); color: var(--charcoal); }
.btn-primary:hover { opacity: 0.9; }
.btn-ghost { background: transparent; color: var(--cream); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--blush); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-block { display: block; width: 100%; }

.hero {
  padding: 90px 0 60px;
}
.eyebrow {
  color: var(--taupe);
  font-size: 0.85rem;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: '';
  width: 22px;
  height: 1px;
  background: var(--taupe);
  display: inline-block;
}
.hero h1 {
  font-size: clamp(2.1rem, 5vw, 2.9rem);
  max-width: 14ch;
}
.hero p.lede {
  font-size: 1.1rem;
  max-width: 48ch;
}
.hero-actions { margin-top: 28px; display: flex; gap: 14px; flex-wrap: wrap; }

.section { padding: 56px 0; border-top: 1px solid var(--line); }

.card {
  background: var(--plum);
  border-radius: 16px;
  padding: 28px;
  border: 1px solid var(--line);
}

.step { display: none; }
.step.active { display: block; }

.progress-track {
  height: 3px;
  background: var(--line);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 32px;
}
.progress-fill {
  height: 100%;
  background: var(--pink);
  transition: width 0.3s ease;
}

.step-count {
  color: var(--taupe);
  font-size: 0.85rem;
  margin-bottom: 8px;
}

.options { display: flex; flex-direction: column; gap: 10px; margin: 20px 0 32px; }
.option {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--plum-light);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 15px 18px;
  cursor: pointer;
  transition: border-color 0.15s ease;
}
.option:hover { border-color: var(--taupe); }
.option.selected { border-color: var(--pink); background: rgba(232, 93, 173, 0.08); }
.option input { accent-color: var(--pink); width: 18px; height: 18px; flex-shrink: 0; }
.option label { cursor: pointer; flex: 1; }

.step-nav { display: flex; justify-content: space-between; gap: 12px; }

.email-field {
  width: 100%;
  padding: 15px 18px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--plum-light);
  color: var(--cream);
  font-size: 1rem;
  font-family: 'Work Sans', sans-serif;
  margin: 16px 0 8px;
}
.email-field::placeholder { color: var(--taupe); }
.field-error { color: var(--pink); font-size: 0.85rem; min-height: 1.2em; }

/* Report / scores */
.scores-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin: 28px 0 40px;
}
.score-card {
  background: var(--plum);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px;
}
.score-label { font-size: 0.85rem; color: var(--taupe); margin-bottom: 6px; }
.score-value { font-family: 'Fraunces', serif; font-size: 1.9rem; color: var(--cream); }
.score-status { font-size: 0.8rem; color: var(--blush); margin-top: 4px; }
.score-bar-track { height: 5px; background: var(--line); border-radius: 999px; margin-top: 10px; overflow: hidden; }
.score-bar-fill { height: 100%; background: var(--pink); }

.rec-card {
  border-left: 3px solid var(--violet);
  padding: 18px 0 18px 20px;
  margin-bottom: 6px;
}
.rec-card h3 { font-size: 1.05rem; margin-bottom: 6px; }
.rec-category { font-size: 0.78rem; color: var(--taupe); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 4px; }

.upgrade-card {
  background: linear-gradient(135deg, var(--plum), var(--plum-light));
  border: 1px solid var(--pink);
  border-radius: 18px;
  padding: 32px;
  margin: 40px 0;
  text-align: center;
}
.upgrade-price { font-family: 'Fraunces', serif; font-size: 2.4rem; color: var(--pink); margin: 6px 0 18px; }

.doctor-note {
  background: var(--plum-light);
  border-radius: 12px;
  padding: 18px 20px;
  margin-top: 32px;
  font-size: 0.9rem;
}
.doctor-note ul { margin: 10px 0 0; padding-left: 20px; }

.meal-list { list-style: none; padding: 0; margin: 12px 0 0; }
.meal-list li {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.meal-list li:last-child { border-bottom: none; }

.tracker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
  gap: 8px;
  margin-top: 16px;
}
.tracker-day {
  background: var(--plum-light);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 6px;
  text-align: center;
  font-size: 0.78rem;
}
.tracker-day .day-num { color: var(--pink); font-weight: 600; display: block; margin-bottom: 4px; }

footer {
  padding: 40px 0 60px;
  color: var(--taupe);
  font-size: 0.85rem;
  border-top: 1px solid var(--line);
}

.loading, .error-state { text-align: center; padding: 60px 0; color: var(--taupe); }
.error-state { color: var(--blush); }

@media (max-width: 600px) {
  .scores-grid { grid-template-columns: 1fr 1fr; }
  .hero { padding: 60px 0 40px; }
}
