:root {
  --beige:      #F0EAD6;
  --tan:        #D2B48C;
  --tan-dk:     #b8956a;
  --rose:       #BC4749;
  --rose-dk:    #9b3a3c;
  --rose-lt:    #f5e0e0;
  --teal:       #70A3A7;
  --teal-dk:    #4e7d80;
  --teal-lt:    #e0edef;
  --charcoal:   #403B33;
  --charcoal-lt:#5a5449;
  --white:      #ffffff;
}

/* HEADER */

/* FOOTER */

/* HERO */
.quiz-hero { position: relative; overflow: hidden; background: linear-gradient(-45deg,var(--beige) 0%,#e8d5c0 20%,#f0c8c8 40%,#c8dfe0 60%,#d4c5b0 80%,var(--beige) 100%); background-size: 400% 400%; animation: gradwave 18s ease-in-out infinite; padding: 64px 28px 56px; text-align: center; }
@keyframes gradwave { 0%{background-position:0% 50%}50%{background-position:100% 50%}100%{background-position:0% 50%} }
.fbg { position: absolute; font-size: var(--size,2rem); opacity: .13; user-select: none; pointer-events: none; animation: floatemoji var(--dur,7s) var(--delay,0s) ease-in-out infinite alternate; }
@keyframes floatemoji { from{transform:translateY(0) rotate(0deg)} to{transform:translateY(var(--ty,-18px)) rotate(var(--rot,10deg))} }
.hero-eyebrow { font-size: .8rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--rose); margin-bottom: 14px; display: flex; align-items: center; justify-content: center; gap: 10px; }
.hero-eyebrow::before,.hero-eyebrow::after { content:''; flex: 0 0 32px; height: 1.5px; background: var(--rose); opacity: .5; }
.hero-title { font-family: 'Fredoka', cursive; font-size: clamp(2.2rem,7vw,4.4rem); font-weight: 700; line-height: 1.1; color: var(--charcoal); margin-bottom: 14px; }
.hero-title .accent  { color: var(--rose); }
.hero-title .accent2 { color: var(--teal-dk); }
.hero-sub { font-size: clamp(.95rem,2vw,1.1rem); color: var(--charcoal-lt); font-weight: 500; line-height: 1.65; max-width: 520px; margin: 0 auto; }

/* SECTION TAG */

/* LAYOUT */
main { flex: 1; }
.page-wrap { max-width: 760px; margin: 0 auto; padding: 48px 20px 80px; }

/* FORM */
.field-label { display: block; font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--charcoal-lt); margin-bottom: 6px; }
.field-label.green { color: var(--teal-dk); }
.field-label.red   { color: var(--rose); }
.field-label.blue  { color: #6b4fa0; }
.form-input { width: 100%; background: var(--beige); border: 1.5px solid rgba(64,59,51,.15); border-radius: 10px; padding: 11px 14px; color: var(--charcoal); font-size: 14px; font-family: 'Inter', sans-serif; transition: border-color .15s, box-shadow .15s; }
.form-input:focus { outline: none; border-color: var(--teal-dk); box-shadow: 0 0 0 3px rgba(78,125,128,.12); }
.form-textarea { width: 100%; background: var(--beige); border: 1.5px solid rgba(64,59,51,.15); border-radius: 10px; padding: 11px 14px; color: var(--charcoal); font-size: 13px; font-family: 'Inter', sans-serif; resize: vertical; transition: border-color .15s; }
.form-textarea:focus { outline: none; border-color: var(--teal-dk); box-shadow: 0 0 0 3px rgba(78,125,128,.12); }
.ans-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.ans-field { background: var(--beige); border-radius: 10px; padding: 10px 14px; border: 1.5px solid rgba(64,59,51,.12); }
.ans-field.correct { background: var(--teal-lt); border-color: var(--teal-dk); }
.ans-field.wrong   { background: var(--rose-lt); border-color: #e0a0a0; }
.ans-field input   { width: 100%; background: transparent; border: none; color: var(--charcoal); font-size: 14px; font-family: 'Inter', sans-serif; }
.ans-field input:focus { outline: none; }
.ans-field input::placeholder { color: var(--charcoal-lt); opacity: .6; }

/* Q CARDS (setup) */
.q-card { background: white; border-radius: 16px; box-shadow: 0 4px 20px rgba(64,59,51,.07); padding: 24px 22px; margin-bottom: 16px; border: 1.5px solid rgba(64,59,51,.06); transition: box-shadow .2s; }
.q-card:hover { box-shadow: 0 8px 32px rgba(64,59,51,.12); }
.q-num { background: var(--rose); color: white; border-radius: 50%; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px; flex-shrink: 0; box-shadow: 0 2px 0 var(--rose-dk); }
.prize-chip { background: var(--teal-lt); color: var(--teal-dk); font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--teal-dk); }

/* BUTTONS */
.btn-primary:disabled { background: #ccc; box-shadow: 0 4px 0 #aaa; cursor: not-allowed; transform: none; }
.btn-teal { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--teal-dk); color: white; font-weight: 700; border-radius: 14px; padding: 13px 28px; font-size: .95rem; font-family: 'Fredoka', cursive; border: none; cursor: pointer; box-shadow: 0 4px 0 #3a6063; transition: transform .15s, box-shadow .15s; }
.btn-teal:hover { transform: translateY(-2px); box-shadow: 0 6px 0 #3a6063; }
.btn-block { display: block; width: 100%; text-align: center; }

/* ERROR */
.error-box { background: var(--rose-lt); border: 1.5px solid var(--rose); border-radius: 10px; padding: 12px 16px; color: var(--rose-dk); font-size: 14px; font-weight: 600; margin-bottom: 16px; }

/* GAME CHROME */
.game-topbar { background: var(--charcoal); padding: 12px 24px; display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.topbar-name  { color: rgba(240,234,214,.7); font-size: 13px; font-weight: 600; }
.topbar-q     { background: rgba(255,255,255,.1); color: var(--beige); font-size: 13px; font-weight: 700; padding: 3px 12px; border-radius: 999px; }
.topbar-prize { background: var(--rose); color: white; font-size: 13px; font-weight: 800; padding: 4px 14px; border-radius: 999px; font-family: 'Fredoka', cursive; box-shadow: 0 2px 0 var(--rose-dk); margin-left: auto; }
.topbar-streak { background: #F5A623; color: var(--charcoal); font-size: 13px; font-weight: 800; padding: 4px 14px; border-radius: 999px; font-family: 'Fredoka', cursive; box-shadow: 0 2px 0 #c9820f; }
.progress-outer { height: 5px; background: rgba(64,59,51,.12); }
.progress-inner { height: 100%; background: linear-gradient(90deg, var(--rose), var(--teal-dk)); transition: width .5s ease; }

/* QUESTION */
.q-display { background: white; border-radius: 18px; box-shadow: 0 6px 28px rgba(64,59,51,.1); padding: 32px 28px; text-align: center; margin-bottom: 22px; border-top: 5px solid var(--rose); }
.q-display-text { font-family: 'Fredoka', cursive; font-size: clamp(18px,3.5vw,24px); line-height: 1.5; color: var(--charcoal); font-weight: 600; }

/* OPTIONS */
.opt-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 20px; }
.opt-btn { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 18px; border-radius: 14px; border: 2px solid rgba(64,59,51,.14); cursor: pointer; font-size: clamp(13px,2vw,15px); font-family: 'Inter', sans-serif; font-weight: 600; background: white; color: var(--charcoal); text-align: left; box-shadow: 0 2px 8px rgba(64,59,51,.06); transition: all .2s; }
.opt-btn:hover:not(:disabled) { border-color: var(--teal-dk); background: var(--teal-lt); transform: translateY(-2px); box-shadow: 0 6px 18px rgba(64,59,51,.12); }
.opt-btn:disabled { cursor: default; }
.opt-btn.selected { border-color: var(--rose); background: var(--rose-lt); box-shadow: 0 4px 16px rgba(188,71,73,.18); }
.opt-btn.correct  { border-color: var(--teal-dk); background: var(--teal-lt); }
.opt-btn.wrong    { border-color: var(--rose); background: var(--rose-lt); }
.opt-btn.faded    { opacity: .3; }
.opt-letter { background: var(--charcoal); color: white; border-radius: 50%; min-width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; flex-shrink: 0; transition: background .2s; }
.opt-btn.selected .opt-letter { background: var(--rose); }
.opt-btn.correct  .opt-letter { background: var(--teal-dk); }
.opt-btn.wrong    .opt-letter { background: var(--rose-dk); }

/* REVEAL */
.reveal-panel { border-radius: 14px; padding: 20px 22px; margin-bottom: 16px; }
.reveal-panel.ok  { background: var(--teal-lt); border: 2px solid var(--teal-dk); }
.reveal-panel.bad { background: var(--rose-lt); border: 2px solid var(--rose); }
.reveal-title { font-family: 'Fredoka', cursive; font-size: 20px; margin-bottom: 8px; }
.reveal-panel.ok  .reveal-title { color: var(--teal-dk); }
.reveal-panel.bad .reveal-title { color: var(--rose-dk); }
.fact-box { background: white; border-radius: 10px; padding: 12px 16px; margin-top: 10px; border-left: 4px solid #6b4fa0; }
.fact-label { font-size: .68rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: #6b4fa0; margin-bottom: 4px; }

/* NAME SCREEN */
.name-screen { padding: 64px 24px; display: flex; align-items: center; justify-content: center; }
.name-box { background: white; border-radius: 24px; box-shadow: 0 8px 40px rgba(64,59,51,.12); padding: 40px 36px; max-width: 440px; width: 100%; text-align: center; border-top: 6px solid var(--rose); }
.name-input { width: 100%; background: var(--beige); border: 2px solid rgba(64,59,51,.15); border-radius: 12px; padding: 14px 18px; color: var(--charcoal); font-size: 18px; font-family: 'Fredoka', cursive; text-align: center; transition: border-color .15s, box-shadow .15s; }
.name-input:focus { outline: none; border-color: var(--rose); box-shadow: 0 0 0 3px rgba(188,71,73,.12); }

/* RESULTS */
.results-hero { background: var(--charcoal); padding: 48px 24px; text-align: center; }
.results-hero h1 { font-family: 'Fredoka', cursive; font-size: clamp(22px,5vw,38px); color: var(--beige); margin: 12px 0 6px; }
.results-hero p { color: rgba(240,234,214,.65); font-size: 14px; }
.summary-bar { display: inline-flex; gap: 0; background: rgba(255,255,255,.07); border: 1px solid rgba(240,234,214,.15); border-radius: 16px; overflow: hidden; flex-wrap: wrap; margin-top: 20px; }
.summary-stat { padding: 18px 28px; text-align: center; border-right: 1px solid rgba(240,234,214,.1); }
.summary-stat:last-child { border-right: none; }
.summary-num { font-family: 'Fredoka', cursive; font-size: 30px; color: var(--beige); line-height: 1; }
.summary-lbl { font-size: 11px; font-weight: 600; color: rgba(240,234,214,.5); text-transform: uppercase; letter-spacing: .08em; margin-top: 3px; }

.result-row { background: white; border-radius: 14px; padding: 18px 20px; margin-bottom: 12px; box-shadow: 0 2px 12px rgba(64,59,51,.06); border-left: 5px solid; }
.result-row.ok  { border-left-color: var(--teal-dk); }
.result-row.bad { border-left-color: var(--rose); }
.result-num { flex-shrink: 0; width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 800; color: white; }
.result-row.ok  .result-num { background: var(--teal-dk); }
.result-row.bad .result-num { background: var(--rose); }

/* SHARE */
.share-panel { background: white; border-radius: 16px; box-shadow: 0 4px 20px rgba(64,59,51,.08); padding: 24px 22px; margin-bottom: 24px; border-top: 4px solid var(--teal-dk); }
.share-textarea { width: 100%; background: var(--beige); border: 1.5px solid rgba(64,59,51,.15); border-radius: 10px; padding: 12px 14px; color: var(--charcoal); font-size: 13px; font-family: 'Inter', sans-serif; resize: none; }
.share-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.btn-share { display: inline-flex; align-items: center; justify-content: center; gap: 6px; flex: 1; min-width: 120px; padding: 10px 14px; border-radius: 10px; font-size: 13px; font-weight: 700; font-family: 'Inter', sans-serif; cursor: pointer; border: 2px solid; transition: all .15s; }
.btn-share.copy  { background: var(--charcoal); color: white; border-color: var(--charcoal); }
.btn-share.copy:hover { background: #2a2620; }
.btn-share.tweet { background: white; color: #000; border-color: #000; }
.btn-share.tweet:hover { background: #000; color: white; }
.btn-share.email { background: white; color: var(--rose-dk); border-color: var(--rose); }
.btn-share.email:hover { background: var(--rose-lt); }
.copy-confirm { font-size: 13px; font-weight: 600; color: var(--teal-dk); margin-top: 8px; display: none; }

.live-prize { display: inline-block; background: var(--rose); color: white; font-family: 'Fredoka', cursive; font-size: 14px; font-weight: 600; padding: 5px 18px; border-radius: 999px; box-shadow: 0 2px 0 var(--rose-dk); }
.hint-line { text-align: center; color: var(--charcoal-lt); font-size: 14px; font-style: italic; padding: 8px 0; }

@media(max-width:600px) {
  .ans-grid, .opt-grid { grid-template-columns: 1fr; }
  .name-box { padding: 28px 20px; }
  .summary-stat { padding: 14px 18px; }
  .share-actions { flex-direction: column; }
  .page-wrap { padding: 32px 16px 60px; }
}

@media print {
  .site-header, .site-footer, #actionsBar, .share-panel { display: none !important; }
  body { font-family: 'Inter', sans-serif; background: var(--beige); color: var(--charcoal); min-height: 100vh; display: flex; flex-direction: column; overflow-x: hidden; }
  .results-hero { background: white !important; border-bottom: 2px solid var(--charcoal); }
  .results-hero h1 { color: var(--charcoal) !important; }
  .results-hero p { color: var(--charcoal-lt) !important; }
  .summary-num { color: var(--charcoal) !important; }
  .summary-lbl { color: var(--charcoal-lt) !important; }
  .summary-bar { border: 1px solid #ccc !important; background: white !important; }
  .summary-stat { border-right-color: #ccc !important; }
  .result-row { box-shadow: none !important; page-break-inside: avoid; border: 1.5px solid #ccc; border-left: 5px solid; }
  .fact-box { border: 1px solid #ccc !important; }
}
.skip-link{position:absolute;left:-9999px;top:auto;width:1px;height:1px;overflow:hidden}.skip-link:focus{left:50%;transform:translateX(-50%);top:8px;width:auto;height:auto;padding:10px 20px;background:#BC4749;color:white;font-weight:700;font-size:.9rem;border-radius:8px;z-index:9999;text-decoration:none;white-space:nowrap}
/* mobile-nav cascade fix */
.reveal{opacity:1!important;transform:none!important}