/* femqq.com/quiz — the questionnaire.
 *
 * Layered on femq-landing.css, which owns the palette tokens, the nav and the
 * footer. Only what the quiz needs is here. The comment above this one said the
 * base was `femq.css` and that the landing sheet was "deliberately not loaded";
 * both stopped being true when the site collapsed to one stylesheet, and
 * femq.css no longer exists.
 *
 * The shape is Noom's: a single column, one question at a time, tap targets big
 * enough for a thumb on a phone held in one hand. The colours are the app's, so a
 * woman who installs after this sees the same product she was just shown.
 */

* { box-sizing: border-box; }

.quiz-page {
  margin: 0;
  background-color: var(--bgDeep);
  color: var(--ink);
  font-family: Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  /* The step machine replaces the whole column, and a shorter screen after a
   * taller one scrolled the page under the user. Reserving the viewport keeps
   * the question in the same place from screen to screen. */
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.wrap {
  width: 100%;
  max-width: 560px;
  margin-inline: auto;
  padding-inline: 20px;
}

@media (min-width: 480px) { .wrap { padding-inline: 24px; } }

/* -------------------------------------------------------------------- chrome */

.site-nav {
  border-bottom: 1px solid var(--border);
  padding: 14px 0;
}

.site-nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--ink);
  text-decoration: none;
  font-family: Fraunces, Georgia, serif;
  font-weight: 600;
  font-size: 1.14rem;
}

.wordmark-mark {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  display: block;
}

/* The promise the funnel is built around, kept in sight rather than in the
 * footer: it is the reason there is no email gate three questions in. */
.nav-note {
  margin: 0;
  font-size: 0.75rem;
  line-height: 1.3;
  color: var(--inkSoft);
  text-align: right;
}

/* One segment per section, sized to how many questions the section holds, so
 * the gaps show how much is left rather than implying a smooth run to the end.
 *
 * Sticky because the nav above it is (femq-landing.css), so anything scrolled to
 * the top of the document passes underneath it. The bar rides on the nav's
 * underside instead of scrolling away, and femq-quiz.js both sets `top` from the
 * nav's measured height and reserves the pair's height on <main>, so a question
 * is never drawn behind them. */
.quiz-bar {
  display: flex;
  gap: 3px;
  height: 4px;
  padding: 0 2px;
  position: sticky;
  top: 0;
  z-index: 99;
  background-color: var(--navBg);
}

.seg {
  flex: 1 1 0;
  background-color: var(--surfaceAlt);
  border-radius: 999px;
  overflow: hidden;
}

.seg-fill {
  display: block;
  height: 100%;
  width: 0;
  background: var(--gradient);
  transition: width 0.3s ease;
}

.quiz { flex: 1 0 auto; padding: 28px 0 56px; }

.quiz-noscript h1 { font-family: Fraunces, Georgia, serif; }
.quiz-noscript a { color: var(--estrogen); }

/* ---------------------------------------------------------------- a question */

.back {
  appearance: none;
  background: none;
  border: 0;
  padding: 6px 0;
  margin-bottom: 10px;
  font: inherit;
  font-size: 0.85rem;
  color: var(--inkSoft);
  cursor: pointer;
}

.back:hover { color: var(--ink); }

.section-label {
  margin: 0 0 10px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--estrogen);
}

.question {
  margin: 0;
  font-family: Fraunces, Georgia, serif;
  font-weight: 600;
  font-size: 1.62rem;
  line-height: 1.22;
  letter-spacing: -0.01em;
  color: var(--ink);
}

@media (min-width: 480px) { .question { font-size: 1.85rem; } }

/* The key phrase inside the question, which is what makes a two-line question
 * scannable in the half second before she decides to read it.
 *
 * Carried by colour and not by weight, which is the opposite of what the markup
 * says, for a typographic reason: Fraunces is loaded at 500 and 600 only, so an
 * honest 700 would be the browser faking one by smearing the 600 — visibly bad
 * on a serif at 1.85rem. The accent token already means "this is the part that
 * matters" everywhere else on the page, and it survives the dark/light
 * inversion because it is the token and not a colour. */
.question b,
.question strong {
  font-weight: inherit;
  color: var(--estrogen);
}

/* In body copy the weight is available, so there it is the weight that does it. */
.because b, .because strong,
.hint b, .hint strong,
.note-body b, .note-body strong {
  font-weight: 600;
  color: var(--ink);
}

/* The justification line. Noom puts one over every question that could read as
 * nosy, and it is the difference between an interrogation and an explanation —
 * so it may not be styled down into a caption nobody reads. */
.because {
  margin: 12px 0 0;
  font-size: 0.92rem;
  line-height: 1.52;
  color: var(--inkSoft);
}

/* Guidance about how to answer, as distinct from `.because` above the question,
 * which justifies being asked at all. Quiet panel, below the button: it is there
 * for the woman who wants it and skippable by the one who does not. */
.hint {
  margin: 20px 0 0;
  padding: 13px 15px;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--inkSoft);
  background-color: var(--surface);
  border-radius: 13px;
}

.note-body {
  margin: 14px 0 0;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--inkSoft);
}

.answers { margin-top: 24px; }

/* -------------------------------------------------------------------- cards */

.cards {
  display: grid;
  gap: 10px;
}

.card {
  appearance: none;
  display: grid;
  gap: 3px;
  width: 100%;
  min-height: 60px;
  padding: 15px 17px;
  text-align: left;
  font: inherit;
  color: var(--ink);
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  cursor: pointer;
  transition: border-color 0.14s ease, background-color 0.14s ease;
}

.card:hover { border-color: var(--inkFaint); }

.card:focus-visible {
  outline: 2px solid var(--estrogen);
  outline-offset: 2px;
}

.card.on {
  border-color: var(--estrogen);
  background-color: var(--surfaceAlt);
}

.card-label { font-weight: 600; font-size: 1.02rem; }
.card-blurb { font-size: 0.85rem; line-height: 1.42; color: var(--inkSoft); }

.card-figure {
  font-family: Fraunces, Georgia, serif;
  font-size: 1.02rem;
  color: var(--estrogen);
}

.card-note {
  margin-top: 5px;
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--inkFaint);
}

/* Multi-select needs a visible state that is not just a border, because several
 * cards are on at once and a row of tinted borders reads as one wide box. */
.card.multi { padding-left: 50px; position: relative; }

.tick {
  position: absolute;
  left: 17px;
  top: 17px;
  width: 20px;
  height: 20px;
  border: 1px solid var(--inkFaint);
  border-radius: 6px;
}

.card.multi.on .tick {
  border-color: var(--estrogen);
  background-color: var(--estrogen);
}

.card.multi.on .tick::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 2px;
  width: 6px;
  height: 11px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* -------------------------------------------------------------------- fields */

.units {
  display: inline-flex;
  margin-bottom: 16px;
  padding: 3px;
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
}

.unit {
  appearance: none;
  background: none;
  border: 0;
  padding: 7px 17px;
  font: inherit;
  font-size: 0.85rem;
  color: var(--inkSoft);
  border-radius: 999px;
  cursor: pointer;
}

.unit.on { background-color: var(--surfaceAlt); color: var(--ink); font-weight: 600; }

.field {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.field input {
  width: 100%;
  min-width: 0;
  padding: 13px 16px;
  font-family: Fraunces, Georgia, serif;
  font-size: 1.7rem;
  color: var(--ink);
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.field-split input { width: 50%; }

.field input:focus {
  outline: none;
  border-color: var(--estrogen);
}

/* The spinners are 11px of tap target that changes a weight by one, next to a
 * field she is typing into. */
.field input::-webkit-outer-spin-button,
.field input::-webkit-inner-spin-button { appearance: none; margin: 0; }
.field input { appearance: textfield; -moz-appearance: textfield; }

.suffix { font-size: 0.95rem; color: var(--inkSoft); }

/* ------------------------------------------------------------------ buttons */

.btn {
  display: inline-block;
  padding: 15px 26px;
  font: inherit;
  font-weight: 600;
  font-size: 1rem;
  text-align: center;
  text-decoration: none;
  color: #fff;
  background: var(--gradient);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
}

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

.continue { width: 100%; margin-top: 20px; }

.continue:disabled {
  background: var(--surfaceAlt);
  /* --inkSoft, not --inkFaint: the disabled label is not decoration, it is the
     instruction saying why the button will not move ("Pick at least one").
     WCAG exempts inactive controls, which is how it sat at 3.47:1. */
  color: var(--inkSoft);
  cursor: not-allowed;
}

.link-btn {
  display: block;
  margin: 16px auto 0;
  padding: 8px 0;
  background: none;
  border: 0;
  font: inherit;
  font-size: 0.88rem;
  color: var(--inkSoft);
  text-decoration: underline;
  cursor: pointer;
}

.link-btn:hover { color: var(--ink); }

/* --------------------------------------------------------------- plan reveal */

.plan { padding-bottom: 8px; }

.budget {
  display: grid;
  justify-items: center;
  gap: 2px;
  margin: 24px 0 8px;
  padding: 26px 20px;
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
}

.budget-figure {
  font-family: Fraunces, Georgia, serif;
  font-weight: 600;
  font-size: 3.4rem;
  line-height: 1;
  color: var(--ink);
}

.budget-unit {
  font-size: 0.88rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--inkSoft);
}

/* Rows rather than cards: every line is an account of where the figure above
 * came from, and boxing them would turn an explanation into a feature grid. */
.plan-rows { margin: 20px 0 0; }

.plan-row {
  padding: 15px 0;
  border-top: 1px solid var(--border);
}

.plan-row dt {
  font-size: 0.92rem;
  color: var(--inkSoft);
}

.plan-row dd {
  margin: 3px 0 0;
  font-family: Fraunces, Georgia, serif;
  font-size: 1.14rem;
  color: var(--ink);
}

.plan-note {
  margin: 6px 0 0;
  font-size: 0.8rem;
  line-height: 1.45;
  color: var(--inkFaint);
}

.lead-ring {
  display: flex;
  gap: 14px;
  margin-top: 26px;
  padding: 18px;
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
}

.lead-ring h2 {
  margin: 0;
  font-family: Fraunces, Georgia, serif;
  font-size: 1.1rem;
  color: var(--ink);
}

.lead-ring p {
  margin: 6px 0 0;
  font-size: 0.9rem;
  line-height: 1.52;
  color: var(--inkSoft);
}

.lead-ring strong { color: var(--ink); }

.ring-dot {
  flex: 0 0 auto;
  width: 12px;
  height: 12px;
  margin-top: 6px;
  border-radius: 999px;
  background-color: var(--inkFaint);
}

.lead-ring[data-ring='estrogen'] .ring-dot { background-color: var(--estrogen); }
.lead-ring[data-ring='balance'] .ring-dot { background-color: var(--balance); }
.lead-ring[data-ring='vitality'] .ring-dot { background-color: var(--vitality); }

/* The twelve nutrient targets, three cards. This is the part of the reveal that
 * a calorie calculator cannot show, so it is allowed to be the longest block on
 * the screen — but it comes after the number and after the account of where the
 * number came from, because a woman who scrolled this far has already been
 * answered and is now being told what else she gets. */
.plan-rings { margin-top: 34px; }

.plan-rings h2 {
  margin: 0;
  font-family: Fraunces, Georgia, serif;
  font-size: 1.22rem;
  line-height: 1.25;
  color: var(--ink);
}

.plan-rings-note {
  margin: 8px 0 0;
  font-size: 0.88rem;
  line-height: 1.52;
  color: var(--inkSoft);
}

.ring-card {
  margin-top: 14px;
  padding: 16px 18px;
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
}

/* The lead ring is marked by its own colour on the left edge rather than by a
 * second background: three cards in three tints would read as three states of a
 * control, and only one of these is hers. */
.ring-card.on { border-left-width: 3px; }
.ring-card[data-ring='estrogen'].on { border-left-color: var(--estrogen); }
.ring-card[data-ring='balance'].on { border-left-color: var(--balance); }
.ring-card[data-ring='vitality'].on { border-left-color: var(--vitality); }

.ring-card-head {
  display: flex;
  align-items: baseline;
  gap: 9px;
}

.ring-card-head h3 {
  margin: 0;
  font-family: Fraunces, Georgia, serif;
  font-size: 1.02rem;
  color: var(--ink);
}

.ring-card-head .ring-dot { margin-top: 0; align-self: center; }

.ring-card[data-ring='estrogen'] .ring-dot { background-color: var(--estrogen); }
.ring-card[data-ring='balance'] .ring-dot { background-color: var(--balance); }
.ring-card[data-ring='vitality'] .ring-dot { background-color: var(--vitality); }

.ring-tag {
  margin-left: auto;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--inkFaint);
}

.ring-nutrients {
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

/* Name left, figure right, dotted leader between: a table of contents, which is
 * what this is. A two-column grid would break as soon as a translated nutrient
 * name ran to two lines. */
.ring-nutrients li {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 7px 0;
  font-size: 0.88rem;
  color: var(--inkSoft);
  border-top: 1px solid var(--border);
}

.ring-nutrients li:first-child { border-top: 0; }

.rn-name { flex: 1 1 auto; }

.rn-fig {
  flex: 0 0 auto;
  font-family: Fraunces, Georgia, serif;
  font-size: 0.98rem;
  color: var(--ink);
  white-space: nowrap;
}

/* A figure her life stage moved off the 19-50 baseline. The accent is the
 * marker; the sentence under the cards says which ones and what they were,
 * because a colour on its own is not information. */
.ring-nutrients li.moved .rn-fig { color: var(--estrogen); }

.plan-rings-first,
.plan-rings-stage {
  margin: 14px 0 0;
  font-size: 0.84rem;
  line-height: 1.5;
  color: var(--inkFaint);
}

.plan-rings-first b { color: var(--inkSoft); font-weight: 600; }

.plan-cta { margin-top: 28px; }
.plan-cta .btn { display: block; }
/* Sits against the button, not adrift with the privacy note below it. */
.plan-cta .trial-terms { margin-top: 10px; }

.micro {
  margin: 14px 0 0;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--inkFaint);
  text-align: center;
}

.micro a { color: var(--inkSoft); }

.plan-disclaimer {
  margin: 26px 0 0;
  padding: 14px 16px;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--inkSoft);
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
}

@media (prefers-reduced-motion: reduce) {
  .seg-fill, .card { transition: none; }
}
