:root {
  --plum-950: #12040f;
  --plum-900: #1c0820;
  --plum-800: #2a0f30;
  --plum-700: #3a1442;
  --plum-600: #4f1d58;
  --rose: #e8768f;
  --rose-deep: #c94568;
  --rose-soft: #f6b3c3;
  --gold: #e6b85c;
  --gold-soft: #f5dca0;
  --ink: #fbeef2;
  --muted: #c7a9b8;
  --line: rgba(246, 179, 195, 0.16);
  --truth: #8f7cf0;
  --dare: #e8768f;
  --wild: #e6b85c;
  --radius: 22px;
  --tap: 56px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background:
    radial-gradient(120% 70% at 50% -10%, #5a1f55 0%, transparent 60%),
    radial-gradient(90% 60% at 100% 110%, #4a1230 0%, transparent 60%),
    var(--plum-900);
  background-attachment: fixed;
  color: var(--ink);
  font: 17px/1.45 ui-rounded, "SF Pro Rounded", "Nunito", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior: none;
  user-select: none;
  -webkit-user-select: none;
}
input, textarea, select { user-select: text; -webkit-user-select: text; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: 0.88rem; }
.tiny { font-size: 0.78rem; margin: 0; }
.center { text-align: center; }
code { background: rgba(255,255,255,0.08); padding: 1px 5px; border-radius: 6px; font-size: 0.9em; }

#app { height: 100%; position: relative; overflow: hidden; }

/* ---------- screens ---------- */
.screen {
  position: absolute; inset: 0;
  display: none; flex-direction: column;
  padding: calc(16px + var(--safe-top)) 20px calc(16px + var(--safe-bottom));
  max-width: 560px; margin: 0 auto;
}
.screen.active { display: flex; animation: fadeIn .35s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.scroll { overflow-y: auto; flex: 1; padding-bottom: 12px; -webkit-overflow-scrolling: touch; }
.center-stack {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 14px; text-align: center;
}
.stack { display: flex; flex-direction: column; gap: 20px; }
.stack-sm { display: flex; flex-direction: column; gap: 10px; }
.row { display: flex; align-items: center; }
.gap { gap: 10px; }
.grow { flex: 1; min-width: 0; }
.narrow { width: 92px; }

.brand {
  font-family: "Georgia", "Times New Roman", serif;
  font-style: italic; font-weight: 600;
  font-size: 2.6rem; margin: 0; letter-spacing: 0.5px;
  background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lead { margin: 0 0 6px; color: var(--rose-soft); max-width: 22em; }
.logo-flame { width: 76px; height: 108px; filter: drop-shadow(0 6px 22px rgba(232,118,143,.45)); animation: flicker 3.2s ease-in-out infinite; }
.logo-flame.small { width: 44px; height: 62px; }
@keyframes flicker { 0%,100% { transform: scale(1) rotate(0); } 40% { transform: scale(1.04, .97) rotate(-1.5deg); } 70% { transform: scale(.98, 1.03) rotate(1deg); } }

.panel {
  background: linear-gradient(180deg, rgba(79,29,88,.55), rgba(42,15,48,.55));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  text-align: left;
  width: 100%;
}
.panel p { margin: 0 0 6px; }
.panel p:last-child { margin-bottom: 0; }

/* ---------- buttons ---------- */
.btn {
  min-height: var(--tap);
  border: 0; border-radius: 999px;
  padding: 12px 24px;
  font-weight: 700; font-size: 1.05rem; letter-spacing: .2px;
  transition: transform .12s ease, filter .2s ease, background .2s ease;
  width: 100%;
}
.btn:active { transform: scale(.97); }
.btn-lg { min-height: 62px; font-size: 1.15rem; }
.btn-primary {
  background: linear-gradient(135deg, var(--rose) 0%, var(--rose-deep) 100%);
  color: #fff;
  box-shadow: 0 10px 28px -10px rgba(232,118,143,.8), inset 0 1px 0 rgba(255,255,255,.25);
}
.btn-secondary { background: rgba(230,184,92,.14); color: var(--gold-soft); border: 1px solid rgba(230,184,92,.4); }
.btn-ghost { background: transparent; color: var(--muted); min-height: 48px; }
.btn-danger { background: rgba(201,69,104,.15); color: #ff9db3; border: 1px solid rgba(201,69,104,.5); }
.icon-btn {
  width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid var(--line); background: rgba(255,255,255,.04);
  display: grid; place-items: center; color: var(--ink); flex: none;
}
.icon-btn svg { width: 22px; height: 22px; }
.link-btn { background: none; border: 0; color: var(--muted); text-decoration: underline; padding: 8px; min-height: 40px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

/* ---------- PIN ---------- */
.pin-dots { display: flex; gap: 18px; margin: 6px 0 10px; }
.pin-dots i { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--rose-soft); transition: background .15s, transform .15s; }
.pin-dots i.on { background: var(--rose); border-color: var(--rose); transform: scale(1.1); }
.pin-dots.shake { animation: shake .4s; }
@keyframes shake { 20%,60% { transform: translateX(-10px); } 40%,80% { transform: translateX(10px); } }
.pinpad { display: grid; grid-template-columns: repeat(3, 76px); gap: 14px; }
.pinpad button {
  width: 76px; height: 76px; border-radius: 50%;
  border: 1px solid var(--line); background: rgba(255,255,255,.05);
  font-size: 1.7rem; font-weight: 500;
  transition: background .15s, transform .1s;
}
.pinpad button:active { background: rgba(232,118,143,.35); transform: scale(.94); }
.pinpad button.blank { visibility: hidden; }
.pinpad button.del { font-size: 1.1rem; color: var(--muted); border-color: transparent; background: none; }

/* ---------- setup ---------- */
.setup-head { display: flex; align-items: center; gap: 10px; justify-content: center; margin: 8px 0 20px; }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
legend { font-weight: 700; color: var(--gold-soft); margin-bottom: 10px; font-size: .95rem; text-transform: uppercase; letter-spacing: 1.5px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span { font-size: .85rem; color: var(--muted); }
.field input, .field select, .field textarea {
  min-height: var(--tap);
  background: rgba(18,4,15,.55); border: 1px solid var(--line); border-radius: 16px;
  padding: 12px 16px; font-size: 1.05rem; width: 100%;
  transition: border-color .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 90px; line-height: 1.4; }
.field select { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 32px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--rose); box-shadow: 0 0 0 3px rgba(232,118,143,.25); }
.heat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.heat-opt input { position: absolute; opacity: 0; pointer-events: none; }
.heat-opt span {
  display: flex; flex-direction: column; gap: 2px;
  min-height: 82px; padding: 14px; border-radius: 18px;
  border: 1px solid var(--line); background: rgba(255,255,255,.03);
  transition: all .2s ease; cursor: pointer;
}
.heat-opt b { font-size: 1.05rem; }
.heat-opt small { color: var(--muted); font-size: .8rem; line-height: 1.25; }
.heat-opt input:checked + span {
  border-color: var(--rose); background: linear-gradient(160deg, rgba(232,118,143,.28), rgba(79,29,88,.4));
  box-shadow: 0 8px 24px -12px rgba(232,118,143,.9);
}
.heat-opt input:focus-visible + span { outline: 3px solid var(--gold); outline-offset: 2px; }

.toggle { display: flex; align-items: center; gap: 14px; min-height: var(--tap); cursor: pointer; }
.toggle input { position: absolute; opacity: 0; }
.toggle-ui { width: 52px; height: 30px; border-radius: 999px; background: rgba(255,255,255,.12); position: relative; flex: none; transition: background .2s; }
.toggle-ui::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; transition: transform .2s; }
.toggle input:checked + .toggle-ui { background: var(--rose); }
.toggle input:checked + .toggle-ui::after { transform: translateX(22px); }
.toggle input:disabled ~ * { opacity: .5; }
.toggle input:focus-visible + .toggle-ui { outline: 3px solid var(--gold); outline-offset: 2px; }

/* ---------- game ---------- */
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.heat-pill {
  min-height: 44px; padding: 8px 18px; border-radius: 999px;
  border: 1px solid rgba(230,184,92,.4); background: rgba(230,184,92,.1); color: var(--gold-soft);
  font-weight: 700; font-size: .9rem; letter-spacing: .3px;
}
.heat-pill .flames { margin-left: 6px; display: inline-flex; gap: 1px; vertical-align: -3px; }
.heat-pill .flames svg { width: 12px; height: 17px; }
.round { width: 48px; text-align: right; color: var(--muted); font-size: .85rem; }

.turn { text-align: center; margin: 14px 0 6px; min-height: 64px; }
.turn .who {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: Georgia, serif; font-style: italic; font-size: 1.7rem; color: var(--ink);
}
.turn .avatar {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  font: 700 1.1rem/1 system-ui, sans-serif; font-style: normal; color: #fff;
  background: linear-gradient(135deg, var(--rose), var(--plum-600));
  box-shadow: 0 0 0 3px rgba(232,118,143,.25);
}
.turn .avatar.p2 { background: linear-gradient(135deg, var(--gold), var(--rose-deep)); box-shadow: 0 0 0 3px rgba(230,184,92,.25); }
.turn .sub { display: block; font-size: .85rem; color: var(--muted); margin-top: 2px; }
.turn.swap .who { animation: popIn .45s cubic-bezier(.2,1.4,.4,1); }
@keyframes popIn { from { transform: scale(.7); opacity: 0; } to { transform: none; opacity: 1; } }

.card-zone { flex: 1; display: flex; align-items: center; justify-content: center; perspective: 1400px; min-height: 0; padding: 8px 0; }
.card {
  width: min(100%, 360px); aspect-ratio: 5 / 7; max-height: 100%;
  position: relative;
}
.card-inner {
  position: absolute; inset: 0;
  transform-style: preserve-3d;
  transition: transform .7s cubic-bezier(.3,1.25,.5,1);
}
.card.flipped .card-inner { transform: rotateY(180deg); }
.card.deal .card-inner { animation: deal .45s ease; }
@keyframes deal { from { transform: translateY(-30px) scale(.92) rotate(-3deg); opacity: .4; } to { transform: none; opacity: 1; } }
.card-back, .card-face {
  position: absolute; inset: 0; border-radius: 28px;
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  overflow: hidden;
  box-shadow: 0 30px 60px -25px rgba(0,0,0,.8), 0 0 0 1px rgba(230,184,92,.35) inset;
}
.card-back {
  background: radial-gradient(circle at 50% 40%, var(--plum-600), var(--plum-800) 70%);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
}
.card-back::before {
  content: ""; position: absolute; inset: 12px; border-radius: 20px;
  border: 1.5px solid rgba(230,184,92,.5);
}
.card-back-pattern {
  position: absolute; inset: 0; opacity: .14;
  background-image:
    radial-gradient(circle at 25% 25%, var(--gold) 1.5px, transparent 2px),
    radial-gradient(circle at 75% 75%, var(--rose) 1.5px, transparent 2px);
  background-size: 28px 28px;
}
.card-back .logo-flame { width: 84px; height: 120px; }
.card-back-label { font-family: Georgia, serif; font-style: italic; font-size: 1.6rem; color: var(--gold-soft); position: relative; }

.card-face {
  transform: rotateY(180deg);
  background: linear-gradient(165deg, #3f1747 0%, #24092a 100%);
  display: flex; flex-direction: column; padding: 22px 22px 18px;
  --accent: var(--rose);
}
.card-face::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 6px; background: var(--accent);
}
.card-face::after {
  content: ""; position: absolute; width: 260px; height: 260px; right: -90px; bottom: -110px; border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--accent) 30%, transparent), transparent 70%);
  pointer-events: none;
}
.card-face.truth { --accent: var(--truth); }
.card-face.dare { --accent: var(--dare); }
.card-face.wild { --accent: var(--wild); }
.card-head { display: flex; align-items: center; gap: 8px; }
.card-type {
  font-weight: 800; text-transform: uppercase; letter-spacing: 2.5px; font-size: .95rem; color: var(--accent);
}
.card-level { font-size: .78rem; color: var(--muted); border: 1px solid var(--line); padding: 3px 10px; border-radius: 999px; }
.fav-btn {
  margin-left: auto; width: 52px; height: 52px; border-radius: 50%;
  border: 0; background: rgba(255,255,255,.06); display: grid; place-items: center;
  position: relative; z-index: 1;
}
.fav-btn svg { width: 26px; height: 26px; fill: none; stroke: var(--rose-soft); stroke-width: 1.8; transition: fill .2s, transform .2s; }
.fav-btn[aria-pressed="true"] svg { fill: var(--rose); stroke: var(--rose); animation: beat .45s ease; }
@keyframes beat { 30% { transform: scale(1.35); } 60% { transform: scale(.9); } }
.card-text {
  flex: 1; display: flex; align-items: center;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.3rem, 5.6vw, 1.65rem); line-height: 1.35; margin: 10px 0;
  overflow-y: auto; user-select: text; -webkit-user-select: text;
  position: relative; z-index: 1;
}
.card-text .name { color: var(--gold-soft); font-style: italic; }
.card-custom { position: absolute; bottom: 14px; left: 22px; font-size: .72rem; color: var(--muted); letter-spacing: 1px; text-transform: uppercase; }

.timer { display: flex; flex-direction: column; align-items: center; gap: 2px; position: relative; z-index: 1; }
.timer-ring { position: relative; width: 112px; height: 112px; border: 0; background: none; padding: 0; border-radius: 50%; }
.timer-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.timer-ring circle { fill: none; stroke-width: 7; }
.timer-ring .track { stroke: rgba(255,255,255,.1); }
.timer-ring .bar { stroke: var(--accent, var(--rose)); stroke-linecap: round; stroke-dasharray: 276.46; stroke-dashoffset: 0; transition: stroke-dashoffset .25s linear; }
.timer-num { position: absolute; inset: 0; display: grid; place-items: center; font-size: 1.9rem; font-weight: 700; font-variant-numeric: tabular-nums; padding-bottom: 14px; }
.timer-hint { position: absolute; left: 0; right: 0; bottom: 26px; font-size: .66rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1.5px; }
.timer.done .timer-num { color: var(--gold); animation: beat .6s ease 2; }

.controls { padding-top: 8px; }
.choice-label { text-align: center; color: var(--muted); margin: 0 0 10px; font-size: .95rem; min-height: 1.4em; }
.choice-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.btn-type { min-height: 68px; border-radius: 20px; padding: 10px 6px; font-size: 1.1rem; color: #fff; }
.btn-type.truth { background: linear-gradient(160deg, #a090ff, #5b44c4); box-shadow: 0 10px 24px -12px #8f7cf0; }
.btn-type.dare { background: linear-gradient(160deg, #ff8fa8, var(--rose-deep)); box-shadow: 0 10px 24px -12px var(--rose); }
.btn-type.wild { background: linear-gradient(160deg, #f5d08a, #b9832b); color: #2a0f30; box-shadow: 0 10px 24px -12px var(--gold); }
.btn-type:disabled { opacity: .3; filter: grayscale(.6); }
.act { display: grid; grid-template-columns: 1fr 1.6fr; gap: 12px; }
.act .btn { min-height: 64px; }

/* ---------- sheet ---------- */
.sheet { position: fixed; inset: 0; z-index: 20; background: rgba(10,2,8,.6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); opacity: 0; pointer-events: none; transition: opacity .25s; }
.sheet.open { opacity: 1; pointer-events: auto; }
.sheet-panel {
  position: absolute; left: 0; right: 0; bottom: 0; max-width: 560px; margin: 0 auto;
  max-height: 92%; display: flex; flex-direction: column;
  background: linear-gradient(180deg, var(--plum-700), var(--plum-900));
  border-radius: 28px 28px 0 0; border: 1px solid var(--line); border-bottom: 0;
  padding: 10px 18px calc(18px + var(--safe-bottom));
  transform: translateY(100%); transition: transform .35s cubic-bezier(.2,.9,.3,1);
}
.sheet.open .sheet-panel { transform: none; }
.sheet-head { display: flex; align-items: center; gap: 10px; padding: 6px 0 12px; }
.sheet-head h2 { flex: 1; margin: 0; font-size: 1.25rem; font-family: Georgia, serif; font-style: italic; color: var(--gold-soft); }
.sheet-head .icon-btn:first-child.hidden + h2 { padding-left: 4px; }
.sheet-body { overflow-y: auto; display: flex; flex-direction: column; gap: 14px; padding-bottom: 6px; }
.menu-item {
  display: flex; align-items: center; gap: 14px; text-align: left;
  min-height: 64px; padding: 10px 16px; border-radius: 18px;
  border: 1px solid var(--line); background: rgba(255,255,255,.04);
  font-weight: 600;
}
.menu-item:active { background: rgba(232,118,143,.18); }
.menu-item span:nth-child(2) { flex: 1; }
.menu-item small { color: var(--muted); font-weight: 400; }
.mi-icon { width: 24px; height: 24px; display: grid; place-items: center; color: var(--gold); font-size: 1.3rem; flex: none; }
.mi-icon.heart { fill: var(--rose); }
.mi-icon.plus { font-size: 1.6rem; font-weight: 300; }

.card-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.card-list li {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 12px 12px 12px 16px; border-radius: 16px;
  background: rgba(255,255,255,.04); border: 1px solid var(--line);
  border-left: 4px solid var(--rose);
}
.card-list li.truth { border-left-color: var(--truth); }
.card-list li.wild { border-left-color: var(--wild); }
.card-list .li-text { flex: 1; font-size: .95rem; }
.card-list .li-meta { display: block; font-size: .72rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 3px; }
.card-list .li-del { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255,255,255,.06); color: var(--muted); }
.card-list .empty { border: 1px dashed var(--line); border-left: 1px dashed var(--line); justify-content: center; color: var(--muted); font-size: .9rem; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; top: calc(76px + var(--safe-top)); z-index: 40;
  transform: translate(-50%, -20px); opacity: 0; pointer-events: none;
  background: var(--plum-950); border: 1px solid var(--line); color: var(--ink);
  padding: 12px 20px; border-radius: 999px; font-size: .92rem; transition: all .3s ease;
  max-width: calc(100% - 40px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* privacy blur when backgrounded */
body.veiled #app { filter: blur(18px); }

@media (max-height: 680px) {
  .turn { margin: 6px 0 2px; min-height: 52px; }
  .turn .who { font-size: 1.4rem; }
  .btn-type { min-height: 58px; }
  .act .btn { min-height: 56px; }
  .timer-ring { width: 92px; height: 92px; }
  .pinpad { grid-template-columns: repeat(3, 68px); gap: 10px; }
  .pinpad button { width: 68px; height: 68px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ---------- challenges ---------- */
.flexcol { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.screen-title { flex: 1; margin: 0; text-align: center; font-family: Georgia, serif; font-style: italic; font-size: 1.2rem; color: var(--gold-soft); }
.topbar-spacer { width: 48px; flex: none; }
#screen-create .topbar { margin-bottom: 14px; }
.small-brand { font-size: 2rem; }
.invite {
  margin: 0; padding: 8px 16px; border-radius: 999px;
  background: rgba(230,184,92,.14); border: 1px solid rgba(230,184,92,.4); color: var(--gold-soft); font-weight: 700;
}
.menu-item.highlight { border-color: rgba(230,184,92,.45); background: linear-gradient(135deg, rgba(232,118,143,.22), rgba(230,184,92,.12)); }

.kind-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.kind-tile {
  display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left;
  min-height: 170px; padding: 18px 16px; border-radius: 22px;
  border: 1px solid var(--line); color: var(--ink);
  transition: transform .12s ease;
}
.kind-tile:active { transform: scale(.97); }
.kind-tile.dare { background: linear-gradient(160deg, rgba(232,118,143,.35), rgba(79,29,88,.5)); }
.kind-tile.quiz { background: linear-gradient(160deg, rgba(143,124,240,.35), rgba(79,29,88,.5)); }
.kind-tile b { font-size: 1.2rem; }
.kind-tile small { color: var(--muted); font-size: .85rem; line-height: 1.3; }
.kind-emoji { font-size: 1.8rem; }

.tabs { display: flex; gap: 6px; padding-bottom: 10px; overflow-x: auto; flex: none; }
.tab {
  flex: 1; min-height: 44px; padding: 8px 12px; border-radius: 999px;
  border: 1px solid var(--line); background: rgba(255,255,255,.04); color: var(--muted); font-weight: 700; font-size: .9rem;
}
.tab.active { background: var(--rose); border-color: var(--rose); color: #fff; }

.pick-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pick-list .empty { padding: 18px; text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: 16px; }
.pick {
  width: 100%; display: flex; gap: 12px; align-items: flex-start; text-align: left;
  padding: 14px; border-radius: 16px; border: 1px solid var(--line); background: rgba(255,255,255,.04);
  font-size: .95rem; transition: background .15s, border-color .15s;
}
.pick.on { border-color: var(--rose); background: rgba(232,118,143,.16); }
.pick-check { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--muted); flex: none; margin-top: 1px; display: grid; place-items: center; }
.pick.on .pick-check { background: var(--rose); border-color: var(--rose); }
.pick.on .pick-check::after { content: "✓"; color: #fff; font-size: .8rem; font-weight: 800; }
.pick-text .name, .li-text .name { color: var(--gold-soft); }
.pick-text .li-meta { display: block; font-size: .72rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 3px; }
.cr-foot { flex: none; padding-top: 10px; display: flex; flex-direction: column; gap: 6px; border-top: 1px solid var(--line); }
.cr-foot .row { justify-content: space-between; }
.cr-count { font-weight: 800; color: var(--gold-soft); min-width: 52px; }
.btn:disabled { opacity: .45; filter: grayscale(.4); }

.quiz-build { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 12px; counter-reset: q; }
.quiz-build li { counter-increment: q; }
.qb-q { margin: 0; font-family: Georgia, serif; font-size: 1.1rem; }
.qb-q::before { content: counter(q) ". "; color: var(--rose); font-weight: 700; }
.opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.opt {
  min-height: 64px; padding: 10px 12px; border-radius: 16px;
  border: 1px solid var(--line); background: rgba(255,255,255,.05);
  font-weight: 600; font-size: .98rem; line-height: 1.25;
  transition: background .2s, border-color .2s, transform .1s;
}
.opt:active { transform: scale(.97); }
.opts.compact .opt { min-height: 52px; font-size: .9rem; font-weight: 500; }
.opt.picked { background: var(--rose); border-color: var(--rose); color: #fff; font-weight: 700; }
.opt.right { background: linear-gradient(135deg, var(--gold), #c9953a); border-color: var(--gold); color: #2a0f30; font-weight: 800; }
.opt.wrong { background: rgba(201,69,104,.25); border-color: var(--rose-deep); text-decoration: line-through; }
.opt:disabled:not(.right):not(.wrong) { opacity: .5; }

.link-box {
  width: 100%; min-height: 48px; padding: 10px 14px; border-radius: 14px;
  background: rgba(18,4,15,.6); border: 1px solid var(--line); color: var(--muted);
  font: .82rem ui-monospace, monospace; text-overflow: ellipsis;
}
.note {
  margin: 0; padding: 14px 18px; border-left: 3px solid var(--gold); border-radius: 4px 16px 16px 4px;
  background: rgba(230,184,92,.08); font-family: Georgia, serif; font-style: italic; font-size: 1.1rem; color: var(--gold-soft);
  max-width: 100%; overflow-wrap: anywhere;
}

.progress { display: flex; justify-content: center; gap: 8px; padding: 10px 0 4px; flex: none; }
.progress i { width: 34px; height: 6px; border-radius: 3px; background: rgba(255,255,255,.12); transition: background .3s; }
.progress i.now { background: var(--rose-soft); }
.progress i.win { background: var(--gold); }
.progress i.miss { background: var(--rose-deep); opacity: .6; }
.ch-step { margin: 4px 0 0; font-size: .9rem; }
.seal-hint { position: relative; font-size: .78rem; color: var(--muted); text-transform: uppercase; letter-spacing: 2px; }
#ch-card { cursor: pointer; }

.quiz-card {
  margin: 18px 0; padding: 26px 22px; border-radius: 26px;
  background: linear-gradient(165deg, #3f1747 0%, #24092a 100%);
  box-shadow: 0 30px 60px -25px rgba(0,0,0,.8), 0 0 0 1px rgba(230,184,92,.35) inset;
  animation: fadeIn .35s ease;
}
.quiz-says { margin: 0 0 10px; color: var(--truth); font-weight: 800; text-transform: uppercase; letter-spacing: 1.5px; font-size: .8rem; }
.quiz-q { margin: 0; font-family: Georgia, serif; font-size: clamp(1.4rem, 6vw, 1.75rem); line-height: 1.3; overflow-wrap: anywhere; }
.quiz-feedback { text-align: center; min-height: 1.5em; margin: 14px 0 0; font-weight: 700; color: var(--gold-soft); }

.result { gap: 12px; padding: 10px 0 20px; }
.score-ring { position: relative; width: 150px; height: 150px; }
.score-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.score-ring circle { fill: none; stroke-width: 7; }
.score-ring .track { stroke: rgba(255,255,255,.1); }
.score-ring .bar { stroke: var(--gold); stroke-linecap: round; stroke-dasharray: 276.46; stroke-dashoffset: 276.46; transition: stroke-dashoffset 1.2s cubic-bezier(.3,1,.4,1); }
.score-num { position: absolute; inset: 0; display: grid; place-items: center; font-size: 2.3rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.recap { width: 100%; text-align: left; }
.recap summary { cursor: pointer; color: var(--muted); padding: 10px 4px; min-height: 44px; }
.recap .card-list li b { color: var(--gold-soft); }
