/* Quiz Platform — Nandgram Dham. Follows the /songs/ token palette. */

/* Across the whole quiz section (every page carries body.qz-body), the
   site's normal header pins itself to the top of the viewport on scroll
   (see style.css — #desktop-nav-wrapper is always fixed on desktop, and
   #mobile-fixed-header-wrapper gets .is-fixed added by script.js on
   mobile scroll). That's useful site-wide navigation elsewhere, but here
   it just eats screen space and competes with quiz content for attention,
   so let it scroll away with the page like normal content instead. */
body.qz-body #desktop-nav-wrapper,
body.qz-body #mobile-fixed-header-wrapper.is-fixed {
  position: relative !important;
  top: auto !important;
}
body.qz-body #header-placeholder {
  display: none !important;
}

:root {
  --qz-dark: #0F4D4A;
  --qz-dark-soft: #1f5053;
  --qz-cream: #FEFAEC;
  --qz-cream-2: #FAEAB1;
  --qz-bg: #FAF8F0;
  --qz-ink: #1a1a1a;
  --qz-muted: #6b6255;
  --qz-line: #e6ddc8;
  --qz-accent: #8c7247;
  --qz-radius: 14px;
  --qz-shadow: 0 1px 2px rgba(15, 77, 74, .05), 0 8px 24px rgba(15, 77, 74, .06);
  --qz-correct: #1f8a4c;
  --qz-incorrect: #c23a3a;
  --qz-timeout: #b8860b;

  /* Category accents — book stays the core teal/gold brand; festival and
     personality get their own accent so a shelf reads at a glance even out
     of context (e.g. a festival card reshared on its own). */
  --qz-gold: #C99A2E;
  --qz-gold-soft: #F8E18F;
  --qz-rose: #7A2E3A;
  --qz-rose-soft: #F3E1E4;
  --qz-shadow-lg: 0 2px 6px rgba(15, 77, 74, .08), 0 20px 44px rgba(15, 77, 74, .14);
}

.qz-body { background: linear-gradient(180deg, var(--qz-cream) 0%, var(--qz-bg) 380px); color: var(--qz-ink); }
.qz-page { font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif; padding-bottom: 5rem; }
.qz-shell { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 1.15rem; }
.qz-shell-narrow { max-width: 760px; }

/* ---------- authbar ---------- */
.qz-authbar { background: #fff; border-bottom: 1px solid var(--qz-line); }
.qz-authbar-inner { display: flex; align-items: center; justify-content: space-between; padding: .7rem 1.15rem; flex-wrap: wrap; gap: .6rem; }
.qz-authbar-brand { display: inline-flex; align-items: center; gap: .5rem; font-weight: 800; color: var(--qz-dark); text-decoration: none; font-size: .95rem; }
.qz-authbar-nav { display: flex; align-items: center; gap: 1.1rem; font-size: .85rem; }
.qz-authbar-nav a { color: var(--qz-muted); text-decoration: none; display: inline-flex; align-items: center; gap: .35rem; }
.qz-authbar-nav a:hover { color: var(--qz-dark); }
.qz-authbar-cta { background: var(--qz-dark); color: #fff !important; padding: .4rem .9rem; border-radius: 999px; font-weight: 600; }
.qz-authbar-cta:hover { background: var(--qz-dark-soft); }

/* On narrow screens there are too many nav items (lang toggle + Books +
   Festivals + Personalities + Leaderboard + account/login) to ever fit on
   one line without wrapping into a jumbled mess. Drop the wrap, drop the
   brand's text label (icon still links home), and let the nav itself
   scroll horizontally as one tidy strip instead. */
@media (max-width: 640px) {
  .qz-authbar-inner { flex-wrap: nowrap; padding: .6rem .9rem; gap: .6rem; }
  .qz-authbar-brand { flex-shrink: 0; font-size: 1.1rem; }
  .qz-authbar-brand-text { display: none; }
  .qz-authbar-nav {
    flex-wrap: nowrap; overflow-x: auto; gap: .95rem; padding-bottom: .15rem;
    scrollbar-width: none; -ms-overflow-style: none;
  }
  .qz-authbar-nav::-webkit-scrollbar { display: none; }
  .qz-authbar-nav a, .qz-authbar-cta, .qz-lang-toggle { flex-shrink: 0; white-space: nowrap; }
}

/* Language toggle — switches quiz CONTENT (questions/options/explanations/
   titles) only; site chrome stays English by design. */
.qz-lang-toggle { display: inline-flex; border: 1px solid var(--qz-line); border-radius: 999px; overflow: hidden; }
.qz-lang-toggle a { padding: .3rem .7rem !important; font-size: .78rem; font-weight: 700; color: var(--qz-muted) !important; text-decoration: none; }
.qz-lang-toggle a.qz-lang-active { background: var(--qz-dark); color: #fff !important; }

/* ---------- crumbs ---------- */
.qz-crumbs { padding: 1.15rem 0 .5rem; font-size: .8125rem; color: var(--qz-muted); display: flex; gap: .55rem; flex-wrap: wrap; }
.qz-crumbs a { color: var(--qz-muted); text-decoration: none; }
.qz-crumbs a:hover { color: var(--qz-dark); text-decoration: underline; }
.qz-crumbs span:last-child { color: var(--qz-dark); font-weight: 600; }

/* ---------- hero ---------- */
.qz-eyebrow { display: inline-flex; align-items: center; gap: .5rem; font-size: .75rem; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--qz-accent); }
.qz-eyebrow > span { width: 26px; height: 1px; background: var(--qz-accent); display: inline-block; }
.qz-eyebrow.qz-eyebrow-gold { color: var(--qz-gold); }
.qz-eyebrow.qz-eyebrow-gold > span { background: var(--qz-gold); }
.qz-eyebrow.qz-eyebrow-rose { color: var(--qz-rose); }
.qz-eyebrow.qz-eyebrow-rose > span { background: var(--qz-rose); }

.qz-hero { position: relative; padding: 2.75rem 0 1.75rem; text-align: center; overflow: hidden; }
.qz-hero::before {
  content: ""; position: absolute; inset: -20% -10% auto -10%; height: 340px; z-index: -1;
  background:
    radial-gradient(closest-side, rgba(201, 154, 46, .16), transparent 70%) 18% 15% / 40% 90% no-repeat,
    radial-gradient(closest-side, rgba(15, 77, 74, .14), transparent 70%) 82% 10% / 44% 100% no-repeat;
}
.qz-hero h1 { font-size: clamp(1.95rem, 5.4vw, 3.15rem); line-height: 1.1; margin: .8rem 0 .6rem; font-weight: 800; color: var(--qz-dark); letter-spacing: -.02em; }
.qz-hero-sub { max-width: 42rem; margin: 0 auto; color: var(--qz-muted); font-size: clamp(.95rem, 2.4vw, 1.075rem); line-height: 1.65; }
.qz-hero-links { display: flex; flex-wrap: wrap; gap: .6rem; justify-content: center; margin-top: 1.4rem; }

.qz-stats-strip { display: flex; flex-wrap: wrap; justify-content: center; gap: 2.4rem; margin: 1.9rem 0 .5rem; padding-top: 1.5rem; border-top: 1px solid var(--qz-line); }
.qz-stat { text-align: center; }
.qz-stat strong { display: block; font-size: 1.5rem; font-weight: 800; color: var(--qz-dark); line-height: 1.2; }
.qz-stat span { font-size: .76rem; color: var(--qz-muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 600; }

/* ---------- buttons ---------- */
.qz-btn { display: inline-flex; align-items: center; gap: .5rem; padding: .7rem 1.3rem; border-radius: 999px; font-weight: 600; font-size: .9rem; text-decoration: none; border: none; cursor: pointer; transition: transform .15s, box-shadow .15s, opacity .15s; }
.qz-btn-primary { background: var(--qz-dark); color: #fff; box-shadow: var(--qz-shadow); }
.qz-btn-primary:hover { background: var(--qz-dark-soft); transform: translateY(-1px); }
.qz-btn-primary:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.qz-btn-ghost { background: #fff; color: var(--qz-dark); border: 1px solid var(--qz-line); }
.qz-btn-ghost:hover { border-color: var(--qz-dark); }
.qz-btn-text { background: transparent; color: var(--qz-muted); padding: .7rem .4rem; }
.qz-btn-text:hover { color: var(--qz-dark); }
.qz-btn-block { width: 100%; justify-content: center; }
.qz-btn-large { padding: .9rem 1.8rem; font-size: 1rem; }
.qz-btn-sm { padding: .4rem .9rem; font-size: .8rem; }

/* ---------- section headers (homepage shelves) ---------- */
.qz-section { padding: 1.6rem 0; }
.qz-section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.2rem; }
.qz-section-head h2 { font-size: clamp(1.35rem, 3vw, 1.75rem); font-weight: 800; color: var(--qz-dark); margin: .5rem 0 .3rem; letter-spacing: -.01em; }
.qz-section-head p { color: var(--qz-muted); font-size: .92rem; max-width: 40rem; margin: 0; line-height: 1.55; }
.qz-section-link { flex-shrink: 0; font-size: .85rem; font-weight: 700; color: var(--qz-dark); text-decoration: none; white-space: nowrap; padding-bottom: .3rem; }
.qz-section-link:hover { text-decoration: underline; }

/* ---------- cards / grid (quiz listing) ---------- */
.qz-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1.3rem; padding: .3rem 0 1rem; }
.qz-card { display: block; background: #fff; border: 1px solid var(--qz-line); border-radius: var(--qz-radius); overflow: hidden; text-decoration: none; color: inherit; box-shadow: var(--qz-shadow); transition: transform .2s ease, box-shadow .2s ease; border-top: 3px solid var(--qz-dark); }
.qz-card:hover { transform: translateY(-4px); box-shadow: var(--qz-shadow-lg); }
.qz-card--festival { border-top-color: var(--qz-gold); }
.qz-card--personality { border-top-color: var(--qz-rose); }

.qz-card-cover { aspect-ratio: 3 / 4; background: linear-gradient(135deg, var(--qz-cream-2), var(--qz-cream)) center/cover; position: relative; overflow: hidden; }
.qz-card-cover-img { position: absolute; inset: 0; background-size: cover; background-position: center; transition: transform .35s ease; }
.qz-card:hover .qz-card-cover-img { transform: scale(1.05); }
.qz-card-scrim { position: absolute; inset: 0; background: linear-gradient(to top, rgba(15,42,40,.9) 0%, rgba(15,42,40,.35) 42%, transparent 62%); }
.qz-card-tag-float { position: absolute; left: .7rem; bottom: .65rem; right: .7rem; display: flex; align-items: center; gap: .35rem; font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: #fff; }
.qz-card-tag-float i { font-size: .65rem; opacity: .85; }

.qz-card-body { padding: 1rem 1.15rem 1.25rem; }
.qz-card-tag { display: inline-block; font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--qz-accent); margin-bottom: .4rem; }
.qz-card-body h3 { font-size: 1.1rem; font-weight: 700; color: var(--qz-dark); margin: 0 0 .4rem; line-height: 1.3; }
.qz-card-body p { font-size: .85rem; color: var(--qz-muted); line-height: 1.5; margin: 0 0 .6rem; }
.qz-card-meta { display: flex; gap: 1rem; font-size: .78rem; color: var(--qz-muted); }
.qz-card-meta i { margin-right: .3rem; }

.qz-badge { position: absolute; top: .6rem; right: .6rem; font-size: .68rem; font-weight: 700; padding: .35rem .65rem; border-radius: 999px; backdrop-filter: blur(6px); }
.qz-badge-done { background: rgba(255,255,255,.92); color: var(--qz-dark); box-shadow: 0 2px 8px rgba(0,0,0,.18); }
.qz-badge-done i { color: var(--qz-gold); }
.qz-badge-practice { background: var(--qz-cream-2); color: var(--qz-accent); display: inline-flex; align-items: center; gap: .4rem; padding: .35rem .8rem; border-radius: 999px; font-size: .78rem; font-weight: 700; margin-bottom: .8rem; }
.qz-empty { text-align: center; color: var(--qz-muted); padding: 2.5rem 0; }

/* ---------- carousels (Swiper — bundle already loaded site-wide) ---------- */
.qz-carousel { position: relative; padding: 0 .1rem; }
.qz-swiper { overflow: hidden; padding-bottom: .4rem; }
.qz-swiper .swiper-wrapper { align-items: stretch; }
.qz-swiper .swiper-slide { width: clamp(220px, 68vw, 300px); height: auto; }
.qz-swiper .swiper-slide .qz-card { height: 100%; }
.qz-swiper-nav { display: inline-flex; align-items: center; justify-content: center; width: 2.3rem; height: 2.3rem; border-radius: 50%; background: #fff; border: 1px solid var(--qz-line); color: var(--qz-dark); box-shadow: var(--qz-shadow); cursor: pointer; transition: background .15s, color .15s; }
.qz-swiper-nav:hover { background: var(--qz-dark); color: #fff; }
.qz-swiper-nav.swiper-button-disabled { opacity: .35; cursor: default; pointer-events: none; }
.qz-swiper-nav.swiper-button-disabled:hover { background: #fff; color: var(--qz-dark); }
.qz-carousel-arrows { display: flex; gap: .5rem; }
@media (max-width: 640px) { .qz-carousel-arrows { display: none; } }

/* ---------- coming soon placeholder ---------- */
.qz-coming-soon { display: flex; align-items: center; gap: 1.1rem; background: linear-gradient(120deg, var(--qz-rose-soft), #fff 70%); border: 1px dashed var(--qz-rose); border-radius: var(--qz-radius); padding: 1.5rem 1.7rem; }
.qz-coming-soon i { font-size: 1.6rem; color: var(--qz-rose); flex-shrink: 0; }
.qz-coming-soon h3 { margin: 0 0 .25rem; font-size: 1.05rem; font-weight: 700; color: var(--qz-dark); }
.qz-coming-soon p { margin: 0; font-size: .88rem; color: var(--qz-muted); line-height: 1.5; }

/* ---------- book browse page ---------- */
.qz-book-chip { display: inline-flex; align-items: center; gap: .4rem; padding: .45rem 1rem; border-radius: 999px; font-size: .82rem; font-weight: 600; text-decoration: none; color: var(--qz-dark); border: 1px solid var(--qz-line); background: #fff; transition: background .15s, color .15s, border-color .15s; }
.qz-book-chip:hover, .qz-book-chip.active { background: var(--qz-dark); color: #fff; border-color: var(--qz-dark); }
.qz-book-chip span { opacity: .7; font-weight: 700; }
.qz-chapter-anchor { scroll-margin-top: 5.5rem; }
.qz-chapter-heading { font-size: 1.05rem; font-weight: 700; color: var(--qz-dark); margin: 2rem 0 1rem; padding-top: .2rem; border-top: 1px solid var(--qz-line); }
.qz-chapter-heading:first-of-type { border-top: none; margin-top: .5rem; }

/* ---------- book index cards (books.php) ---------- */
.qz-book-card { display: block; background: #fff; border: 1px solid var(--qz-line); border-radius: var(--qz-radius); overflow: hidden; text-decoration: none; color: inherit; box-shadow: var(--qz-shadow); transition: transform .2s ease, box-shadow .2s ease; }
.qz-book-card:hover { transform: translateY(-4px); box-shadow: var(--qz-shadow-lg); }
.qz-book-mosaic { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 2px; aspect-ratio: 16 / 9; background: var(--qz-line); }
.qz-book-mosaic div { background-size: cover; background-position: center; background-color: var(--qz-cream-2); }
.qz-book-card-body { padding: 1.2rem 1.3rem 1.4rem; }
.qz-book-card-body h3 { font-size: 1.25rem; font-weight: 800; color: var(--qz-dark); margin: 0 0 .45rem; }
.qz-book-card-body p { font-size: .88rem; color: var(--qz-muted); line-height: 1.55; margin: 0 0 .7rem; }

/* ---------- auth pages ---------- */
.qz-auth-page { padding-top: 1.5rem; }
.qz-auth-card { background: #fff; border: 1px solid var(--qz-line); border-radius: var(--qz-radius); box-shadow: var(--qz-shadow); padding: 2rem; margin: 1.5rem 0 3rem; }
.qz-auth-card-center { text-align: center; }
.qz-auth-card h1 { font-size: 1.6rem; font-weight: 800; color: var(--qz-dark); margin: .5rem 0 .4rem; }
.qz-auth-sub { color: var(--qz-muted); font-size: .92rem; margin-bottom: 1.3rem; }
.qz-auth-switch { text-align: center; margin-top: 1.2rem; font-size: .9rem; color: var(--qz-muted); }
.qz-auth-switch a, .qz-auth-links a { color: var(--qz-dark); font-weight: 600; text-decoration: none; }
.qz-auth-links { text-align: right; margin: -.4rem 0 .8rem; font-size: .85rem; }
.qz-verify-icon { width: 64px; height: 64px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.6rem; margin: 0 auto 1rem; }
.qz-verify-icon-ok { background: #e5f5ea; color: var(--qz-correct); }
.qz-verify-icon-warn { background: #fbeaea; color: var(--qz-incorrect); }

.qz-form { display: flex; flex-direction: column; gap: 1.1rem; }
.qz-field { display: flex; flex-direction: column; gap: .4rem; font-size: .85rem; font-weight: 600; color: var(--qz-ink); }
.qz-field em { color: var(--qz-incorrect); font-style: normal; }
.qz-field em.qz-optional { color: var(--qz-muted); font-weight: 400; }
.qz-field input { border: 1px solid var(--qz-line); border-radius: 10px; padding: .7rem .9rem; font-size: .95rem; font-weight: 400; font-family: inherit; }
.qz-field input:focus { outline: none; border-color: var(--qz-dark); box-shadow: 0 0 0 3px rgba(15,77,74,.1); }
.qz-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.qz-field-error { color: var(--qz-incorrect); font-weight: 400; }
/* display:none is the one hiding technique every browser and password
   manager reliably treats as "do not autofill, do not include in tabbing" —
   off-screen positioning (left:-9999px) is NOT, and Chrome's password
   manager has been observed filling such fields anyway, silently tripping
   the bot check for real users. Only used on signup/forgot-password now;
   the login form dropped its honeypot entirely (see quiz/login.php). */
.qz-honeypot { display: none !important; }
.qz-alert { border-radius: 10px; padding: .8rem 1rem; margin-bottom: 1rem; font-size: .88rem; }
.qz-alert p { margin: 0; }
.qz-alert-error { background: #fbeaea; color: var(--qz-incorrect); }
.qz-alert-success { background: #e5f5ea; color: var(--qz-correct); }

/* ---------- mobile OTP widget ---------- */
.qz-otp-phone-row { display: flex; align-items: stretch; border: 1px solid var(--qz-line); border-radius: 10px; overflow: hidden; }
.qz-otp-prefix { display: flex; align-items: center; padding: 0 .8rem; background: var(--qz-bg); color: var(--qz-muted); font-weight: 600; font-size: .95rem; }
.qz-otp-phone-row input { border: none !important; border-radius: 0 !important; flex: 1; }
.qz-otp-phone-row:focus-within { outline: none; box-shadow: 0 0 0 3px rgba(15,77,74,.1); border-color: var(--qz-dark); }
.qz-otp-input { text-align: center; font-size: 1.4rem; font-weight: 700; letter-spacing: .5em; padding-left: 1.1em !important; }
.qz-otp-sent-to { font-size: .88rem; color: var(--qz-muted); margin: 0 0 1rem; }
.qz-otp-resend { font-size: .85rem; color: var(--qz-muted); text-align: center; margin: .9rem 0 0; }
.qz-otp-resend-btn { color: var(--qz-dark); font-weight: 600; }
.qz-otp-resend-btn:disabled { color: var(--qz-muted); cursor: default; }
.qz-auth-divider { display: flex; align-items: center; gap: .8rem; margin: 1.3rem 0; color: var(--qz-muted); font-size: .82rem; text-transform: uppercase; letter-spacing: .05em; }
.qz-auth-divider::before, .qz-auth-divider::after { content: ""; flex: 1; height: 1px; background: var(--qz-line); }
.qz-google-widget { width: 100%; }
.qz-google-btn-container { display: flex; justify-content: center; width: 100%; }
.qz-auth-toggle { width: 100%; }
@media (max-width: 520px) { .qz-field-row { grid-template-columns: 1fr; } }

/* ---------- quiz detail ---------- */
.qz-detail-card { background: #fff; border: 1px solid var(--qz-line); border-radius: var(--qz-radius); box-shadow: var(--qz-shadow); padding: 2rem; margin-bottom: 3rem; }
.qz-detail-card h1 { font-size: 1.9rem; font-weight: 800; color: var(--qz-dark); margin: .4rem 0 .8rem; }
.qz-detail-desc { color: var(--qz-muted); line-height: 1.65; margin-bottom: 1.2rem; }
.qz-detail-facts { list-style: none; padding: 0; margin: 0 0 1.4rem; display: flex; flex-direction: column; gap: .55rem; font-size: .9rem; color: var(--qz-ink); }
.qz-detail-facts i { width: 1.2rem; color: var(--qz-accent); margin-right: .4rem; }
.qz-refs { background: var(--qz-bg); border: 1px solid var(--qz-line); border-radius: 12px; padding: 1.1rem 1.3rem; margin-bottom: 1.5rem; }
.qz-refs h2 { font-size: 1rem; font-weight: 700; color: var(--qz-dark); margin: 0 0 .6rem; }
.qz-refs ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: .5rem; }
.qz-refs a { color: var(--qz-dark); text-decoration: none; font-weight: 600; font-size: .9rem; }
.qz-refs a:hover { text-decoration: underline; }
.qz-faq { margin-bottom: 1.5rem; }
.qz-faq h2 { font-size: 1rem; font-weight: 700; color: var(--qz-dark); margin: 0 0 .6rem; }
.qz-faq-item { border: 1px solid var(--qz-line); border-radius: 10px; padding: .7rem .9rem; margin-bottom: .5rem; }
.qz-faq-item summary { cursor: pointer; font-weight: 600; font-size: .9rem; color: var(--qz-ink); }
.qz-faq-item p { color: var(--qz-muted); font-size: .88rem; line-height: 1.55; margin: .55rem 0 0; }
.qz-detail-actions { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; }
.qz-notice { color: var(--qz-muted); font-size: .9rem; }
.qz-notice a { color: var(--qz-dark); font-weight: 600; }
.qz-notice-done { display: flex; flex-direction: column; gap: .6rem; }

/* ---------- take-quiz screen ---------- */
.qz-practice-banner { background: var(--qz-cream-2); color: var(--qz-accent); font-weight: 700; font-size: .85rem; text-align: center; padding: .6rem; border-radius: 10px; margin: 1.3rem 0; }
.qz-loading { text-align: center; padding: 4rem 0; color: var(--qz-muted); font-size: 1rem; }
.qz-take-head { padding: 1.5rem 0 .8rem; }
.qz-progress { height: 6px; background: var(--qz-line); border-radius: 999px; overflow: hidden; margin-bottom: .7rem; }
.qz-progress-bar { height: 100%; background: var(--qz-dark); transition: width .4s ease; }
.qz-take-meta { display: flex; justify-content: space-between; font-size: .85rem; color: var(--qz-muted); font-weight: 600; }
.qz-timer { display: inline-flex; align-items: center; gap: .35rem; color: var(--qz-dark); }
.qz-timer.qz-timer-low { color: var(--qz-incorrect); }

.qz-question-card { background: #fff; border: 1px solid var(--qz-line); border-radius: var(--qz-radius); box-shadow: var(--qz-shadow); padding: 1.8rem; margin-bottom: 3rem; }
.qz-question-type { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--qz-accent); }
.qz-question-text { font-size: 1.3rem; font-weight: 700; color: var(--qz-ink); margin: .5rem 0 1.2rem; line-height: 1.4; }
.qz-question-image { max-width: 100%; border-radius: 10px; margin-bottom: 1.2rem; display: block; }

.qz-options { display: flex; flex-direction: column; gap: .7rem; }
.qz-option { display: flex; align-items: center; gap: .7rem; border: 1.5px solid var(--qz-line); border-radius: 10px; padding: .8rem 1rem; cursor: pointer; transition: border-color .15s, background .15s; font-size: .95rem; }
.qz-option:hover { border-color: var(--qz-dark); }
.qz-option input { width: 18px; height: 18px; accent-color: var(--qz-dark); flex-shrink: 0; }
.qz-option-correct { border-color: var(--qz-correct); background: #eef8f0; }
.qz-option-incorrect { border-color: var(--qz-incorrect); background: #fbeaea; }
.qz-fillblank-input { border: 1.5px solid var(--qz-line); border-radius: 10px; padding: .8rem 1rem; font-size: .95rem; font-family: inherit; }
.qz-fillblank-input:focus { outline: none; border-color: var(--qz-dark); }

.qz-feedback { margin-top: 1.3rem; padding-top: 1.1rem; border-top: 1px solid var(--qz-line); }
.qz-feedback-verdict { font-weight: 800; font-size: 1.05rem; display: flex; align-items: center; gap: .6rem; }
.qz-feedback-correct { color: var(--qz-correct); }
.qz-feedback-incorrect { color: var(--qz-incorrect); }
.qz-feedback-timeout { color: var(--qz-timeout); }
.qz-feedback-points { font-size: .85rem; font-weight: 700; background: var(--qz-bg); padding: .2rem .6rem; border-radius: 999px; color: var(--qz-ink); }
.qz-feedback-explain { color: var(--qz-muted); font-size: .9rem; line-height: 1.55; margin-top: .5rem; }

/* ---------- result ---------- */
.qz-result-card { background: #fff; border: 1px solid var(--qz-line); border-radius: var(--qz-radius); box-shadow: var(--qz-shadow); padding: 2rem; margin: 1.5rem 0 2rem; text-align: center; }
.qz-result-card h1 { font-size: 1.6rem; font-weight: 800; color: var(--qz-dark); margin: .5rem 0 1.3rem; }
.qz-result-score { display: flex; align-items: center; justify-content: center; gap: 2rem; flex-wrap: wrap; }
.qz-score-ring { width: 120px; height: 120px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: conic-gradient(var(--qz-dark) calc(var(--pct) * 1%), var(--qz-line) 0); position: relative; }
.qz-score-ring::before { content: ""; position: absolute; inset: 8px; background: #fff; border-radius: 50%; }
.qz-score-ring span { position: relative; font-size: 1.4rem; font-weight: 800; color: var(--qz-dark); }
.qz-score-ring small { font-size: .85rem; font-weight: 600; color: var(--qz-muted); }
.qz-result-stats { display: flex; gap: 1.5rem; }
.qz-result-stats div { display: flex; flex-direction: column; }
.qz-result-stats strong { font-size: 1.2rem; color: var(--qz-dark); }
.qz-result-stats span { font-size: .75rem; color: var(--qz-muted); text-transform: uppercase; letter-spacing: .05em; }
.qz-result-actions { display: flex; gap: .7rem; flex-wrap: wrap; justify-content: center; margin-top: 1.6rem; }

.qz-review-title { font-size: 1.2rem; font-weight: 700; color: var(--qz-dark); margin: 1rem 0; }
.qz-review-list { display: flex; flex-direction: column; gap: .8rem; margin-bottom: 3rem; }
.qz-review-item { background: #fff; border: 1px solid var(--qz-line); border-left-width: 4px; border-radius: 12px; padding: 1rem 1.2rem; }
.qz-review-correct { border-left-color: var(--qz-correct); }
.qz-review-incorrect { border-left-color: var(--qz-incorrect); }
.qz-review-timeout { border-left-color: var(--qz-timeout); }
.qz-review-head { display: flex; align-items: flex-start; gap: .7rem; }
.qz-review-num { background: var(--qz-bg); color: var(--qz-dark); font-weight: 700; font-size: .8rem; width: 1.6rem; height: 1.6rem; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.qz-review-head p { flex: 1; font-weight: 600; margin: 0; }
.qz-review-pts { font-size: .78rem; font-weight: 700; color: var(--qz-muted); white-space: nowrap; }
.qz-review-note { font-size: .85rem; color: var(--qz-muted); margin: .5rem 0 0 2.3rem; }
.qz-review-explain { font-size: .85rem; color: var(--qz-accent); margin: .35rem 0 0 2.3rem; line-height: 1.5; }

/* ---------- leaderboard ---------- */
.qz-lb-title { font-size: 1.6rem; font-weight: 800; color: var(--qz-dark); margin: 1rem 0 1.2rem; display: flex; align-items: center; gap: .6rem; }
.qz-lb-tabs { display: flex; gap: .5rem; margin-bottom: 1.2rem; }
.qz-lb-tabs a { padding: .5rem 1.1rem; border-radius: 999px; font-size: .85rem; font-weight: 600; text-decoration: none; color: var(--qz-muted); border: 1px solid var(--qz-line); }
.qz-lb-tabs a.active { background: var(--qz-dark); color: #fff; border-color: var(--qz-dark); }
.qz-lb-table-wrap { background: #fff; border: 1px solid var(--qz-line); border-radius: var(--qz-radius); box-shadow: var(--qz-shadow); overflow: hidden; margin-bottom: 2rem; overflow-x: auto; }
.qz-lb-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.qz-lb-table th { text-align: left; padding: .8rem 1.1rem; background: var(--qz-bg); color: var(--qz-muted); font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; }
.qz-lb-table td { padding: .75rem 1.1rem; border-top: 1px solid var(--qz-line); }
.qz-lb-top td:first-child { font-weight: 800; color: var(--qz-accent); }

@media (max-width: 640px) {
  .qz-auth-card, .qz-detail-card, .qz-question-card, .qz-result-card { padding: 1.4rem; }
  .qz-result-score { flex-direction: column; }
}
