/* PAPAFIT quiz page, builds on papafit-guide.css tokens */
.quiz-hero .hero-copy h1 { max-width: 15ch; }
.quiz-facts { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1.1rem; padding: 0; list-style: none; }
.quiz-facts li { background: white; border: 1px solid var(--guide-line); border-radius: 999px; padding: .3rem .8rem; font-size: .9rem; font-weight: 700; }
.quiz-facts li::before { content: "✓" / ""; color: var(--guide-orange); font-weight: 900; margin-inline-end: .4rem; }
.quiz-start { font-size: 1.08rem; min-height: 54px; padding-inline: 1.6rem; cursor: pointer; }
.quiz-resume { background: none; border: 0; color: var(--guide-accent); text-decoration: underline; text-underline-offset: .2em; cursor: pointer; font: inherit; font-weight: 700; min-height: 44px; }
.quiz-preview { list-style: none; padding: 0; margin: 0; display: grid; gap: .6rem; }
.quiz-preview li { display: flex; gap: .7rem; align-items: center; background: white; border: 1px solid var(--guide-line); border-radius: 16px; padding: .7rem .9rem; font-weight: 700; }
.quiz-preview-box { position: relative; overflow: hidden; background: linear-gradient(160deg, #ffffff 0%, #fff4ea 100%); border: 1px solid #f2d9c4; border-radius: 28px; padding: clamp(1.2rem, 4vw, 2rem); box-shadow: 0 30px 60px -36px rgb(184 70 10 / 38%); }
.quiz-preview-box::before { content: ""; position: absolute; inset-block-start: -90px; inset-inline-end: -90px; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgb(242 106 15 / 16%) 0%, transparent 70%); pointer-events: none; }
.quiz-preview-box h2 { position: relative; color: var(--guide-ink); font-size: clamp(1.25rem, 3vw, 1.55rem); margin-bottom: 1rem; }
.quiz-preview-box h2::after { content: ""; display: block; width: 44px; height: 4px; border-radius: 99px; background: var(--guide-orange); margin-top: .55rem; }
.quiz-preview-box .quiz-preview li { position: relative; background: rgb(255 255 255 / 80%); border-color: #efe3d8; box-shadow: 0 1px 0 rgb(20 20 20 / 3%); }

/* Quiz area */
#quiz-app { padding-block: clamp(1.2rem, 4vw, 3rem) 3rem; scroll-margin-top: 5.5rem; }
#quiz-app :focus { outline: none; }
#quiz-app :focus-visible { outline: 3px solid var(--guide-accent); outline-offset: 3px; }
.quiz-card { max-width: 42rem; margin-inline: auto; background: white; border: 1px solid var(--guide-line); border-radius: 28px; padding: clamp(1.1rem, 4vw, 2.2rem); box-shadow: 0 18px 40px -24px rgb(20 20 20 / 30%); }
.quiz-step { animation: quizIn .28s ease-out; }
@keyframes quizIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.quiz-top { display: flex; justify-content: space-between; align-items: center; min-height: 44px; }
.quiz-back { background: none; border: 0; font: inherit; color: var(--guide-muted); cursor: pointer; min-height: 44px; padding-inline: .2rem; font-weight: 700; }
.quiz-back:hover { color: var(--guide-accent); }
.quiz-count { color: var(--guide-muted); font-size: .9rem; font-weight: 700; }
.quiz-bar { height: 8px; border-radius: 99px; background: var(--guide-tint); overflow: hidden; margin-block: .4rem 1.4rem; }
.quiz-bar span { display: block; height: 100%; background: var(--guide-orange); border-radius: inherit; transition: width .35s ease; }
.quiz-q { font-size: clamp(1.35rem, 3.6vw, 1.9rem); letter-spacing: -.02em; margin: 0; }
.quiz-hint { color: var(--guide-muted); margin-top: .45rem; font-size: .95rem; }
.quiz-opts { list-style: none; padding: 0; margin: 1.2rem 0 0; display: grid; gap: .6rem; }
.quiz-opt { width: 100%; display: flex; align-items: center; gap: .8rem; text-align: start; font: inherit; font-weight: 600; color: var(--guide-ink); background: var(--guide-paper); border: 1.5px solid var(--guide-line); border-radius: 16px; padding: .85rem 1rem; min-height: 56px; cursor: pointer; transition: border-color .15s, background .15s, transform .15s; }
.quiz-opt:hover { border-color: var(--guide-orange); background: #fff; }
.quiz-opt:active { transform: scale(.99); }
.quiz-opt:disabled { cursor: default; }
.quiz-opt.is-on { border-color: var(--guide-orange); background: var(--guide-tint); }
.quiz-mark { flex: 0 0 22px; height: 22px; border-radius: 50%; border: 2px solid #cbbfb4; display: grid; place-items: center; background: white; }
.is-multi .quiz-mark { border-radius: 7px; }
.quiz-opt.is-on .quiz-mark { border-color: var(--guide-orange); background: var(--guide-orange); }
.quiz-opt.is-on .quiz-mark::after { content: "✓" / ""; color: white; font-size: .8rem; font-weight: 900; line-height: 1; }
.quiz-next { margin-top: 1.2rem; width: 100%; cursor: pointer; }
.quiz-next:disabled { opacity: .45; cursor: not-allowed; }
.quiz-name { display: grid; gap: .7rem; margin-top: 1.2rem; }
.quiz-name input { font: inherit; font-size: 1.1rem; padding: .8rem 1rem; min-height: 54px; border: 1.5px solid var(--guide-line); border-radius: 14px; background: var(--guide-paper); }
.quiz-name input:focus-visible { outline: 3px solid var(--guide-orange); outline-offset: 1px; }
.quiz-name .button { cursor: pointer; min-height: 54px; font-size: 1.05rem; }
.quiz-loading { text-align: center; padding-block: 3rem; }
.quiz-loading h2 { font-size: 1.5rem; margin-top: 1rem; }
.quiz-loading p { color: var(--guide-muted); }
.quiz-spinner { display: inline-block; width: 52px; height: 52px; border-radius: 50%; border: 5px solid var(--guide-tint); border-top-color: var(--guide-orange); animation: quizSpin .9s linear infinite; }
@keyframes quizSpin { to { transform: rotate(360deg); } }

/* Results */
.quiz-results { max-width: 52rem; margin-inline: auto; display: grid; gap: clamp(1.4rem, 4vw, 2.4rem); animation: quizIn .4s ease-out; }
.quiz-results h3 { font-size: clamp(1.25rem, 3vw, 1.6rem); }
.result-hero h2 { font-size: clamp(1.9rem, 5vw, 2.9rem); }
.result-hero .intro { max-width: 60ch; }
.result-summary { list-style: none; counter-reset: r; padding: 0; margin: 1.2rem 0 0; display: grid; gap: .55rem; }
.result-summary li { counter-increment: r; display: flex; align-items: center; gap: .75rem; background: white; border: 1px solid var(--guide-line); border-inline-start: 5px solid var(--guide-orange); border-radius: 14px; padding: .7rem 1rem; font-weight: 800; }
.result-summary li::before { content: counter(r); flex: 0 0 30px; height: 30px; border-radius: 50%; background: var(--guide-tint); color: var(--guide-accent); display: grid; place-items: center; font-weight: 900; }
.result-profile, .result-reason, .result-timeline, .result-note, .result-first { background: white; border: 1px solid var(--guide-line); border-radius: 22px; padding: clamp(1rem, 3.5vw, 1.8rem); }
.result-bars { list-style: none; padding: 0; margin: 1rem 0 0; display: grid; gap: .55rem; }
.result-bars li { display: grid; grid-template-columns: 8.5rem minmax(0, 1fr) 4.2rem; align-items: center; gap: .7rem; font-size: .93rem; }
.bar-label { font-weight: 700; }
.bar-track { height: 12px; background: #f1ebe5; border-radius: 99px; overflow: hidden; }
.bar-fill { display: block; height: 100%; border-radius: inherit; transform-origin: right; animation: barGrow .9s ease-out both; }
[dir="rtl"] .bar-fill { transform-origin: right; }
[dir="ltr"] .bar-fill { transform-origin: left; }
@keyframes barGrow { from { transform: scaleX(0); } }
.bar-fill.is-high, .result-level.is-high { background: var(--guide-orange); }
.bar-fill.is-mid, .result-level.is-mid { background: #f6b384; }
.bar-fill.is-low, .result-level.is-low { background: #ddd3ca; }
.bar-val { color: var(--guide-muted); font-size: .85rem; font-weight: 700; }
.result-section-title { margin-bottom: .2rem; }
.result-reason { margin-top: .9rem; }
.result-reason-head { display: flex; align-items: center; gap: .8rem; margin-bottom: .6rem; }
.result-rank { font-size: clamp(2.2rem, 5vw, 3.1rem); font-weight: 900; line-height: 1; color: var(--guide-orange); }
.result-level { display: inline-block; margin-top: .35rem; font-size: .8rem; font-weight: 800; border-radius: 99px; padding: .1rem .6rem; color: var(--guide-ink); }
.result-reason > p { margin-top: .6rem; max-width: 68ch; }
.result-actions { margin-top: 1rem; background: var(--guide-tint); border-radius: 16px; padding: .9rem 1rem; }
.result-actions strong { color: var(--guide-accent); }
.result-actions ul { list-style: none; padding: 0; margin: .5rem 0 0; display: grid; gap: .45rem; }
.result-actions li { position: relative; padding-inline-start: 1.6rem; }
.result-actions li::before { content: "✓" / ""; position: absolute; inset-inline-start: 0; color: var(--guide-accent); font-weight: 900; }
.result-more { margin-top: .8rem; font-weight: 700; }
.result-more a { text-decoration: underline; text-underline-offset: .2em; }
.result-first { display: flex; gap: .9rem; align-items: flex-start; border: 2px solid var(--guide-orange); }
.result-first p { margin-top: .4rem; }
.result-first-step { font-weight: 800; font-size: 1.08rem; background: var(--guide-tint); border-radius: 12px; padding: .7rem .9rem; }
.result-timeline p, .result-note p { margin-top: .5rem; max-width: 68ch; }
.result-cta { display: grid; gap: 1.4rem; align-items: center; }
.result-cta ul { list-style: none; margin-block: .9rem; padding: 0; }
.result-cta ul li { position: relative; padding-inline-start: 1.5rem; margin-block: .25rem; }
.result-cta ul li::before { content: "✓" / ""; color: var(--guide-orange); position: absolute; inset-inline-start: 0; font-weight: 800; }
.result-cta .button { font-size: 1.08rem; min-height: 54px; padding-inline: 1.4rem; }
.result-cta-note { font-size: .88rem; color: var(--guide-muted); margin-top: .6rem !important; }
.result-cta-photo { margin: 0; display: flex; align-items: center; gap: .8rem; background: rgb(255 255 255 / 85%); border: 1px solid #efe3d8; border-radius: 20px; padding: .8rem; }
.result-cta-photo img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.result-cta-photo img { box-shadow: 0 0 0 4px white, 0 0 0 5px #f2d4ba; }
.result-cta-photo figcaption { font-size: .88rem; color: var(--guide-muted); line-height: 1.5; }
.result-cta-photo strong { display: block; color: var(--guide-ink); font-size: 1rem; }
.result-story-list { list-style: none; padding: 0; margin: 1rem 0 .6rem; display: grid; gap: .8rem; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.result-story-list li { background: white; border: 1px solid var(--guide-line); border-radius: 16px; overflow: hidden; }
.result-story-list img { width: 100%; height: auto; aspect-ratio: 1; object-fit: contain; background: #101010; }
.result-story-list p { padding: .6rem .8rem; font-size: .93rem; }
@media (max-width: 560px) { .result-story-list { gap: .45rem; } .result-story-list p { padding: .45rem; font-size: .78rem; line-height: 1.5; } .result-story-list p strong, .result-story-list .story-badge { display: block; width: fit-content; } }
.result-story-list .story-badge { background: var(--guide-tint); color: var(--guide-accent); }
.result-tools-grid { display: grid; gap: .7rem; margin-top: .9rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); }
.result-tool { display: grid; gap: .2rem; text-align: start; font: inherit; background: white; border: 1px solid var(--guide-line); border-radius: 16px; padding: .9rem 1rem; cursor: pointer; color: var(--guide-ink) !important; text-decoration: none; min-height: 64px; }
.result-tool:hover { border-color: var(--guide-orange); background: var(--guide-tint); }
.result-tool strong { font-weight: 800; }
.result-tool span { color: var(--guide-muted); font-size: .9rem; }
.result-disclaimer { color: var(--guide-muted); font-size: .85rem; }

@media (min-width: 760px) {
  .result-cta { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
  .result-cta-photo { flex-direction: column; text-align: center; padding: 1.2rem; }
  .result-cta-photo img { width: 140px; height: 140px; }
}
@media (max-width: 480px) {
  .result-bars li { grid-template-columns: 6.8rem minmax(0, 1fr) 3.6rem; gap: .45rem; font-size: .85rem; }
}
@media (prefers-reduced-motion: reduce) {
  .quiz-step, .quiz-results, .bar-fill { animation: none; }
  .quiz-spinner { animation-duration: 3s; }
}

/* Light premium CTA card (replaces the flat black boxes) */
.pf-cta-card { position: relative; overflow: hidden; background: linear-gradient(155deg, #ffffff 0%, #fff6ee 55%, #ffe9d6 100%); border: 1px solid #f2d4ba; border-radius: 28px; padding: clamp(1.3rem, 4.5vw, 2.6rem); color: var(--guide-ink); box-shadow: 0 34px 70px -40px rgb(184 70 10 / 45%), 0 2px 0 rgb(255 255 255) inset; }
.pf-cta-card::before { content: ""; position: absolute; inset-block-start: -120px; inset-inline-end: -120px; width: 300px; height: 300px; border-radius: 50%; background: radial-gradient(circle, rgb(242 106 15 / 18%) 0%, transparent 68%); pointer-events: none; }
.pf-cta-card > * { position: relative; }
.pf-cta-card h2 { color: var(--guide-ink); font-size: clamp(1.6rem, 4vw, 2.3rem); }
.pf-cta-card p { color: #3f3935; }
.pf-cta-eyebrow { display: inline-block; font-size: .78rem !important; font-weight: 800; letter-spacing: .08em; color: var(--guide-accent) !important; background: rgb(242 106 15 / 12%); border-radius: 99px; padding: .2rem .7rem; margin-bottom: .7rem; }
.pf-cta-card ul li::before { color: var(--guide-accent) !important; }
.pf-cta-card .button { box-shadow: 0 12px 26px -12px rgb(242 106 15 / 75%); }
.pf-cta-card .button:hover { transform: translateY(-1px); }
@media (prefers-reduced-motion: reduce) { .pf-cta-card .button:hover { transform: none; } }
