/*
  Evelyn quiz — styles for everything below the first screen.
  Screen 1 (question 1) is inlined in quiz/index.html for fast first paint,
  using the exact same design tokens as the landing page. This file covers
  every other screen: text areas, single/multi-select, contact form, and
  the offer / thank-you / goodbye screens.
*/

/* ---------- Answer options (single + multi select) ---------- */
.options {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0 0 4px;
}
.option {
  display: flex;
  align-items: center;
  gap: 13px;
  min-height: 56px;
  padding: 8px 16px;
  border-radius: 14px;
  background: var(--bg-surface-alt);
  border: 1px solid rgba(var(--ink-rgb), 0.1);
  font-size: 1.09375rem;
  line-height: 1.4;
  text-align: left;
  cursor: pointer;
  font-family: var(--font-sans);
  color: var(--ink);
}
.option__mark {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  border: 1.5px solid rgba(var(--ink-rgb), 0.28);
}
.option.is-selected {
  padding: 13px 15px;
  background: var(--bg-surface-warm);
  border: 2px solid var(--maroon);
  font-weight: 600;
}
.option.is-selected .option__mark {
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: var(--maroon);
  color: var(--cream);
  font-size: 0.875rem;
  font-weight: 700;
}
.option.is-selected .option__mark::after { content: '\2713'; }
/* While a single-select choice is settling in before auto-advance, fade
   the options that were not picked, same as the design's 250ms hold. */
.options.is-settling .option:not(.is-selected) { opacity: 0.45; }

/* Muted line under a question heading */
.subtext {
  margin: 0 0 12px;
  font-size: 0.96875rem;
  line-height: 1.5;
  color: rgba(var(--ink-rgb), 0.62);
}

/* Full-weight paragraph copy for screens driven by screen.paragraphs —
   currently only Q14. Ink-colored and options-sized so it reads as the
   main content, not a muted hint. Last paragraph (the key point) is
   bolded and gets extra room below to separate the pitch from the
   options — see the isLast check in renderHeading(). */
.question-copy {
  margin: 0 0 14px;
  font-size: 1.09375rem;
  line-height: 1.5;
  color: var(--ink);
}
.question-copy--emphasis {
  margin-bottom: 28px;
  font-weight: 700;
}

/* Bold, slightly darker line under the subtext — spells out that a
   question allows multiple selections. Used on Q3. */
.select-hint {
  margin: 0 0 12px;
  font-size: 0.84375rem;
  font-weight: 700;
  color: rgba(var(--ink-rgb), 0.72);
}

/* ---------- Text answer ---------- */
.text-answer {
  display: block;
  width: 100%;
  min-height: 148px;
  padding: 16px;
  border-radius: 16px;
  background: var(--bg-surface-alt);
  border: 1px solid rgba(var(--ink-rgb), 0.14);
  font-family: var(--font-sans);
  font-size: 1.09375rem;
  line-height: 1.5;
  color: var(--ink);
  resize: none;
}
.text-answer::placeholder { color: rgba(var(--ink-rgb), 0.42); }
.text-answer:focus {
  outline: none;
  background: #FFFCF9;
  border: 2px solid var(--maroon);
  box-shadow: 0 0 0 4px rgba(92, 59, 59, 0.12);
  padding: 15px;
}
.text-answer--short { min-height: 116px; }
.text-answer.has-error {
  background: #FDF6F3;
  border: 2px solid var(--terracotta);
}

/* "Something else" free-text field on a multi-select screen — hidden
   until that option is picked (see otherOption in quiz.js). */
.other-field { display: none; margin: 0 0 16px; }
.other-field.is-visible { display: block; }

/* ---------- Contact form ---------- */
.field { margin: 0 0 16px; }
.field:last-of-type { margin-bottom: 0; }
.field label {
  display: block;
  margin: 0 0 7px;
  font-size: 0.90625rem;
  font-weight: 600;
  color: rgba(var(--ink-rgb), 0.7);
}
.field input {
  display: block;
  width: 100%;
  min-height: 58px;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--bg-surface-alt);
  border: 1px solid rgba(var(--ink-rgb), 0.14);
  font-family: var(--font-sans);
  font-size: 1.09375rem;
  color: var(--ink);
}
.field input::placeholder { color: rgba(var(--ink-rgb), 0.4); }
.field input:focus {
  outline: none;
  border-color: var(--maroon);
}
.field input.has-error {
  background: #FDF6F3;
  border: 2px solid var(--terracotta);
}
.field-error {
  margin: 8px 0 0;
  font-size: 0.90625rem;
  line-height: 1.45;
  font-weight: 600;
  color: #A8402A;
}

/* ---------- Secondary + text-link buttons (shared with static screens) ---------- */
.btn-secondary {
  display: block;
  width: 100%;
  min-height: 56px;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--bg-surface-alt);
  border: 1px solid rgba(var(--ink-rgb), 0.14);
  font-family: var(--font-sans);
  font-size: 1.09375rem;
  font-weight: 600;
  color: var(--maroon);
  text-align: center;
  cursor: pointer;
}
.btn-link {
  display: block;
  margin: 16px auto 0;
  padding: 4px;
  border: none;
  background: none;
  text-align: center;
  font-family: var(--font-sans);
  font-size: 1.03125rem;
  color: var(--maroon);
  text-decoration: underline;
  cursor: pointer;
}

/* ---------- Static / message screens (offer, second chance, thank you, goodbye) ---------- */
.msg-screen h2 { margin: 0 0 16px; }
.msg-screen p {
  margin: 0 0 14px;
  font-size: 1.09375rem;
  line-height: 1.6;
  color: rgba(var(--ink-rgb), 0.85);
}
.msg-screen p:last-of-type { margin-bottom: 26px; }
.msg-screen h3 {
  margin: 0 0 16px;
  font-family: var(--font-serif);
  font-size: 1.4375rem;
  line-height: 1.3;
  font-weight: 600;
}
.msg-highlight {
  margin: 0 0 18px;
  padding: 16px;
  border-radius: 14px;
  background: var(--bg-surface-alt);
  border: 1px solid rgba(var(--ink-rgb), 0.1);
  font-size: 1.125rem;
  line-height: 1.4;
  font-weight: 700;
}
.msg-screen .buttons { display: flex; flex-direction: column; gap: 12px; }
