/* Lane B page pieces the kit does not carry (quiz list, editor, runtime). Tokens only. */
.qz-a { color: inherit; text-decoration: none; min-width: 0; display: block; }
.qz-a:hover strong { text-decoration: underline; }
.qz-a:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; border-radius: 6px; }
.qz-ways { grid-template-columns: 1fr; }
.qz-ways form { display: grid; }
.qz-ways .way { width: 100%; }
.qz-tools { flex-wrap: wrap; }
.qz-start { justify-self: start; }
.qz-n { width: 22px; flex: none; }
.qz-thumb { max-width: min(240px, 100%); max-height: 140px; border-radius: 8px; object-fit: contain; background: var(--surface-2); }
.qz-flash { animation: qz-flash 1.4s ease-out 1; }
@keyframes qz-flash { from { background: var(--pc); } to { background: transparent; } }
.qz-dragging { opacity: .6; background: var(--surface-2); }
.qz-L { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--ink-2); font-weight: 700; font-size: 13px; flex: none; }
.dx-opt-row .ibtn.on { background: var(--ok-c); color: var(--ok); }
.qz-sug { position: relative; }
.qz-sugpop { position: absolute; left: 0; right: 0; top: 100%; z-index: 90; margin-top: 4px; max-height: 260px; overflow: auto; }
.qz-chrow { gap: 8px; }
.qz-chrow .drag { display: inline-grid; place-items: center; width: 20px; align-self: stretch; flex: none; touch-action: none; }
.qz-chrow .drag svg.lucide { width: 16px; height: 16px; }
.qz-chno { width: 56px; text-align: center; flex: none; }
.qz-chn { width: 44px; text-align: right; flex: none; }
.qz-drop { display: grid; justify-items: center; gap: 8px; padding: 32px 16px; border-style: dashed; background: var(--surface-2); cursor: pointer; text-align: center; }
.qz-drop:focus-within { outline: 2px solid var(--primary); outline-offset: 2px; }
.qz-drop .scene { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); color: var(--ink-2); }
.qz-bkrows { display: grid; gap: 12px; }
.qz-bkrow { padding: 12px; display: grid; gap: 10px; }
.qz-warn { color: var(--warn); }
.qz-aim { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--quiz-c); color: var(--on-quiz-c); flex: none; }
.qz-aif { display: grid; gap: 10px; justify-content: stretch; }
.qz-aicards { display: grid; gap: 10px; }
.qz-aicard { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; }
.qz-aicard .qt { flex: 1; min-width: 0; display: grid; gap: 6px; }
.qz-aicard.added { opacity: .7; }
.qz-aierr { background: var(--danger-c); color: var(--danger); }
.composer .fsel-w { flex: none; }
.qz-aif form.composer { display: flex; width: 100%; }
.qz-aif .composer textarea { min-width: 0; }
.qz-pvmeta .card-b { display: grid; gap: 12px; padding-top: 16px; }
.qz-pvt { font-size: 20px; line-height: 28px; font-weight: 600; }
.qz-by { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: 13px; margin: 0; }
.qz-pvplay .card-b { display: grid; gap: 12px; padding-top: 16px; }
.qz-pvq { font-size: 18px; line-height: 27px; overflow-wrap: anywhere; }
.qz-pvopts { display: grid; gap: 10px; }
.qz-pvopts .bigopt { cursor: default; }
.bigopt.qz-right { box-shadow: 0 0 0 3px var(--ok); }
.bigopt.qz-dim { opacity: .45; }
.bigopt .qz-tick { margin-left: auto; flex: none; }
.qz-between { justify-content: space-between; }
.qz-ink { color: var(--ink); }
.qz-pvrow { width: 100%; text-align: left; border: 0; background: none; font: inherit; }
.qz-pvrow[aria-current="true"] { background: var(--surface-2); }
.qz-rowacts { flex-wrap: nowrap; justify-content: flex-end; }
/* History: the game code sits under its quiz and the live chip under its time, so the table fits its card. */
.qz-hcode { display: block; font-size: 12px; color: var(--ink-3); margin-top: 2px; }
.qz-won { display: flex; align-items: center; gap: 4px; margin-top: 2px; font-size: 12px; color: var(--ink-2); min-width: 0; }
.qz-won > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
table.tb td.qz-when { white-space: normal; min-width: 120px; }
table.tb td.qz-when > span:first-child { display: block; white-space: nowrap; }
table.tb td.qz-when .chip { margin-top: 4px; }
.qz-bq details > summary { list-style: none; }
.qz-bq details > summary::-webkit-details-marker { display: none; }
.qz-bq details[open] .f-chev { transform: rotate(180deg); }
.qz-qn { width: 36px; flex: none; }
.qz-votes { display: grid; gap: 8px; padding: 4px 16px 14px 60px; }
.qz-vote { display: grid; grid-template-columns: minmax(0, 1fr) minmax(60px, 160px) 32px; gap: 10px; align-items: center; font-size: 14px; }
.qz-vote.ok .qz-vl { color: var(--ok); font-weight: 600; }
.qz-vl { min-width: 0; overflow-wrap: anywhere; }
.qz-fast { font-size: 13px; margin: 0; }
.qz-bars { display: grid; gap: 8px; padding-top: 12px; }
.qz-barrow { display: grid; grid-template-columns: 56px minmax(0, 1fr) 72px; gap: 10px; align-items: center; font-size: 13px; }
.qz-barrow .num:last-child { text-align: right; }
.qz-bin { font-size: 12px; }
@media (max-width: 599px) { .qz-votes { padding-left: 16px; } .qz-vote { grid-template-columns: minmax(0, 1fr) 72px 28px; } }
/* runtime */
.qp-tight { padding: 8px; }
.qp-center { text-align: center; justify-content: center; }
.qp-fill { min-height: calc(100dvh - 140px); align-content: center; display: grid; gap: 16px; }
.qp-join { display: grid; gap: 16px; align-content: center; min-height: calc(100dvh - 120px); }
.qp-codein { position: relative; cursor: text; }
.qp-codein input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; border: 0; font-size: 16px; color: transparent; background: transparent; caret-color: transparent; }
.qp-codein:focus-within span.f { border-color: var(--primary); box-shadow: inset 0 0 0 1px var(--primary); }
.qp-codein span[hidden] { display: none; }
@media (max-width: 380px) { .qp-codein span { width: 42px; height: 54px; } }
.qp-ok { background: var(--ok-c); color: var(--ok); }
.qp-q { font-size: 19px; line-height: 28px; overflow-wrap: anywhere; }
.qp-img { max-width: 100%; max-height: 240px; border-radius: 12px; object-fit: contain; background: var(--surface-2); justify-self: center; }
.qp-opts { display: grid; gap: 10px; }
.qp-opts .bigopt { cursor: pointer; }
.qp-opts .bigopt:disabled { cursor: default; }
.bigopt.qp-picked { box-shadow: 0 0 0 4px var(--ink-2); }
.bigopt.qp-dim { opacity: .35; }
.bigopt.qp-wrong { box-shadow: 0 0 0 3px var(--danger); }
.qp-line { text-align: center; font-weight: 700; font-size: 18px; min-height: 24px; margin: 0; }
.qp-view { display: grid; gap: 16px; position: relative; }
.qp-view[hidden] { display: none; }
.qp-paused { position: absolute; inset: -8px; background: color-mix(in srgb, var(--bg) 88%, transparent); display: grid; place-items: center; border-radius: 16px; z-index: 3; }
.qp-paused[hidden] { display: none; }
.timebar i.qp-low { background: var(--danger); }
.qp-res { border-radius: 24px; padding: 32px 16px; background: var(--surface-2); }
.qp-res .scene { background: var(--surface-3); color: var(--ink-2); }
.qp-res.ok { background: var(--ok-c); }
.qp-res.ok .scene { background: var(--ok); color: var(--on-primary); }
.qp-res.ok p { color: var(--ok); }
.qp-res.bad { background: var(--danger-c); }
.qp-res.bad .scene { background: var(--danger); color: var(--on-primary); }
.qp-res.bad p { color: var(--danger); }
.qp-answer { margin: 0; }
.qp-rk { width: 24px; flex: none; }
.qp-me { background: var(--pc); }
.qp-out { opacity: .55; }
.qs-progress { height: 6px; }
.qs-out { display: grid; justify-items: center; gap: 4px; text-align: center; margin: 0; }
.qs-ok { color: var(--ok); font-size: 22px; }
.qs-bad { color: var(--danger); font-size: 22px; }
.qs-kpis { grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); }
.qs-ic { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--ink-3); flex: none; }
.qs-ic.ok { background: var(--ok-c); color: var(--ok); }
.qs-ic.bad { background: var(--danger-c); color: var(--danger); }
.qs-rev { display: grid; gap: 6px; padding: 4px 16px 14px 56px; }
.qs-ch { display: flex; gap: 8px; align-items: center; font-size: 14px; color: var(--ink-2); }
.qs-ch.ok { color: var(--ok); font-weight: 600; }
.qs-ch.bad { color: var(--danger); }
@media (max-width: 599px) { .qs-rev { padding-left: 16px; } }
.qs-wrap { padding: 16px 0 32px; width: min(1100px, 100% - 32px); margin-inline: auto; display: grid; gap: 20px; }
.qs-side { display: grid; gap: 20px; align-content: start; }
.qs-share { display: grid; gap: 10px; justify-items: start; padding-top: 12px; }
.qs-code { font-size: 40px; }
.qs-share .qr { width: 140px; }
.ln-grid { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.ln-b { display: flex; align-items: center; gap: 8px; padding-top: 12px; }
.ln-h2 { margin-top: 8px; }
.ln-pg { margin-top: 12px; }
.ln-h2 h2 { font-size: 20px; line-height: 28px; font-weight: 500; }
.qs-page { min-height: 100%; display: grid; grid-template-rows: auto 1fr; }
/* Self paced question: one column on portrait phones; wide screens put the question left and the choices right */
.qs-page .qs-l, .qs-page .qs-r { display: contents; }
.qs-page .qp-img { display: block; max-height: 35dvh; cursor: zoom-in; background: var(--fig); }
@media (min-width: 700px), (orientation: landscape) {
  .qs-page { height: 100%; grid-template-rows: auto minmax(0, 1fr); }
  .qs-page > .phone-col { width: 100%; max-width: 1600px; min-height: 0; padding: 12px clamp(12px, 3vw, 48px); grid-template-columns: minmax(0, 1.25fr) minmax(280px, 1fr); grid-template-rows: auto minmax(0, 1fr); column-gap: clamp(16px, 2.5vw, 40px); row-gap: 12px; }
  .qs-page .qs-progress { grid-column: 1 / -1; }
  .qs-page .qs-l, .qs-page .qs-r { display: flex; flex-direction: column; gap: 12px; min-height: 0; }
  .qs-page .qs-l { overflow-y: auto; }
  .qs-page .qp-q { font-size: clamp(20px, 1.2vw + 12px, 32px); line-height: 1.4; flex: none; }
  .qs-page .qp-img { flex: 1 1 0; min-height: 140px; width: 100%; height: auto; max-height: none; object-fit: contain; border-radius: 16px; }
  .qs-page .qs-r .qp-opts { align-content: start; }
  .qs-page .qs-r .bigopt { min-height: clamp(48px, 10dvh, 96px); }
}
@media (orientation: landscape) and (max-height: 520px) {
  .qs-page > .phone-col { padding-block: 8px; row-gap: 8px; }
  .qs-page .qs-r { gap: 8px; }
  .qs-page .qs-r .qp-opts { gap: 8px; }
  .qs-page .qs-r .bigopt { font-size: 16px; padding-block: 6px; }
  .qs-page .qp-img { min-height: 96px; }
}
/* The title link covers the row (one 72 px target); the row's own presses sit above it. */
.clist .li[data-qz-row] { position: relative; }
.clist .li[data-qz-row] .qz-a::after { content: ''; position: absolute; inset: 0; }
/* Positioned presses after the link paint above its overlay; no z-index, so an open menu stays above later rows. */
.clist .li[data-qz-row] > .btn, .clist .li[data-qz-row] > .fsel-w { position: relative; }
/* Editor: the bank's structure panel beside the question list. */
.qz-main { display: grid; gap: 12px; min-width: 0; align-content: start; }
.qz-count { padding-block: 10px; }
.qz-count + #qz-qlist { border-top: 1px solid var(--line); }
#qz-qwrap[data-filtered] .qz-n { width: auto; min-width: 22px; }
/* Bonus and multipliers: tier rows (Top N x M, N in a row x M) */
.qz-tiers { list-style: none; margin: 0 0 8px; padding: 0; display: grid; gap: 6px; }
.qz-tier { display: flex; align-items: center; gap: 8px; min-width: 0; flex-wrap: wrap; }
.qz-tier .in { width: 76px; height: 44px; flex: none; }
.qz-tier-l { color: var(--ink-2); font-size: 14px; white-space: nowrap; }
.qz-tier-l:empty { display: none; }
.qz-tier-none { font-size: 13px; }
/* Questions to play: the chapter picker rows */
.qz-drtree { display: grid; gap: 4px; margin-top: 8px; }
.qz-drtree[hidden] { display: none; }
.qz-drow { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 2px 8px 2px calc(8px + var(--lv, 0) * 20px); border: 1px solid var(--line); border-radius: 12px; background: var(--surface); min-width: 0; }
.qz-drow .box { flex: none; }
.qz-dn { flex: 1; min-width: 0; display: grid; }
.qz-dn .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.qz-dn small { color: var(--ink-3); font-size: 12px; }
.qz-dc { flex: none; }
.qz-dc[hidden] { display: none; }
.qz-dc .numrow { gap: 8px; }
.qz-dc .numrow .tl { font-size: 13px; color: var(--ink-2); }
@media (max-width: 480px) { .qz-drow { flex-wrap: wrap; } .qz-dc { flex-basis: 100%; padding-left: 32px; } }
.qz-drway { flex-wrap: wrap; }
.qz-pk { display: grid; gap: 8px; margin-top: 8px; min-width: 0; }
.qz-pk[hidden] { display: none; }
.qz-pkh { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.qz-pko { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; }
.qz-pkr { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 4px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); min-width: 0; }
.qz-pkr .qz-pkg { cursor: grab; touch-action: none; color: var(--ink-3); }
.qz-pkno { flex: none; min-width: 32px; color: var(--primary); }
.qz-pkr .nm, .qz-pkq .nm, .qz-pkgh .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qz-pks { display: flex; align-items: center; gap: 8px; position: relative; }
.qz-pks > svg, .qz-pks > i { position: absolute; left: 12px; width: 16px; height: 16px; color: var(--ink-3); pointer-events: none; }
.qz-pks .in { padding-left: 36px; width: 100%; }
.qz-pkl { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px; max-height: 360px; overflow-y: auto; overflow-x: hidden; border: 1px solid var(--line); border-radius: 12px; padding: 4px; }
.qz-pkgr[hidden], .qz-pkq[hidden] { display: none; }
.qz-pkgh, .qz-pkq { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 8px 0 calc(8px + var(--lv, 0) * 16px); min-width: 0; }
.qz-pkgh { font-weight: 600; }
.qz-pkgh small { flex: none; color: var(--ink-3); font-size: 12px; font-weight: 400; }
.qz-pkq { padding-left: calc(24px + var(--lv, 0) * 16px); }
.qz-pk .box.mixed::before { content: ""; width: 10px; height: 2px; border-radius: 1px; background: var(--on-primary); }
.qz-drper { margin-top: 4px; }
.qz-drper [data-qz-drperl] { display: grid; gap: 4px; }
.qz-dr > summary .f-t { flex: none; }
.qz-dr > summary .f-s { flex: 1 1 0; text-align: end; contain: inline-size; }
