body { min-height: 100dvh; }
#app { max-width: 560px; margin: 0 auto; padding: 16px 16px 40px; }
section { display: flex; flex-direction: column; gap: 14px; animation: slideIn .3s ease both; }
.center { text-align: center; }
.stack { display: flex; flex-direction: column; gap: 14px; }
label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; color: var(--muted); font-size: 14px; }
.btn.big { padding: 18px; font-size: 20px; border-radius: 14px; width: 100%; }

.top { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-bottom: 4px; border-bottom: 1px solid var(--line); }
.top .brand { font-family: var(--font-display); font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top .me { white-space: nowrap; }
.top .score { background: var(--accent); color: var(--accent-ink); border-radius: 8px; padding: 2px 8px; font-family: var(--font-display); }

.join { text-align: center; padding-top: 6vh; }
.join .logo { font-size: 64px; animation: pulse 2.4s ease infinite; }
.join h1 { font-size: 48px; font-weight: 800; }
.join form { text-align: left; margin-top: 10px; }
.code-in { text-transform: uppercase; letter-spacing: .4em; font-family: var(--font-display); font-weight: 800; font-size: 28px; text-align: center; }
.alert { background: #ff547022; border: 1px solid var(--bad); padding: 12px; border-radius: 12px; }

.hero { text-align: center; padding: 18px 0 6px; }
.hero h1 { font-size: 34px; margin: 4px 0; }
.kicker { text-transform: uppercase; letter-spacing: .2em; font-size: 12px; color: var(--accent); margin: 0; font-weight: 700; }
.players { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.players li { background: var(--panel); padding: 8px 12px; border-radius: 99px; font-weight: 600; }
.players li.ready { background: #3ddc8433; }
.players li.offline { opacity: .45; }
.players li.me { outline: 2px solid var(--accent); }
.leave { align-self: center; margin-top: 18px; }

.qmeta { display: flex; gap: 8px; flex-wrap: wrap; }
.pill { background: var(--panel); border-radius: 99px; padding: 4px 12px; font-size: 14px; font-weight: 600; }
.pill.stars { color: var(--accent); letter-spacing: .1em; }
.qtext { font-size: 26px; line-height: 1.2; }
.qtext.small { font-size: 20px; }
.status { min-height: 1.4em; color: var(--muted); font-weight: 600; }
.timer { display: grid; grid-template-columns: 1fr 48px; gap: 10px; align-items: center; }
.secs { font-family: var(--font-display); font-weight: 800; font-size: 22px; text-align: right; }

.options { display: grid; grid-template-columns: 1fr; gap: 10px; }
.opt {
  display: flex; align-items: center; gap: 12px; text-align: left; border: 0; cursor: pointer;
  background: var(--opt); color: #0f0b1e; font-weight: 700; font-size: 19px; padding: 16px; border-radius: 14px;
  box-shadow: 0 4px 0 #0006; transition: transform .1s ease, opacity .2s ease, outline-color .2s;
  outline: 4px solid transparent; outline-offset: 2px;
}
.opt:active { transform: translateY(3px); box-shadow: 0 1px 0 #0006; }
.opt .letter { background: #fff5; }
.opt.selected { outline-color: #fff; transform: scale(1.02); }
.opt.dim { opacity: .45; }
.intro .options, .intro .textanswer { filter: blur(2px); pointer-events: none; }
.textanswer { display: flex; flex-direction: column; gap: 10px; }
.submitted { color: var(--good); font-weight: 600; min-height: 1.2em; }
.foot { margin-top: 4px; }

.bigstate { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 18px 0; font-weight: 600; }
.spinner { width: 42px; height: 42px; border-radius: 50%; border: 5px solid var(--line); border-top-color: var(--accent); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.correct { display: flex; align-items: center; gap: 10px; padding: 14px; border-radius: 14px; background: var(--opt, var(--good)); color: #0f0b1e; font-weight: 800; font-size: 20px; }
.correct.text { background: var(--good); }
.yours { background: var(--panel); padding: 12px 14px; border-radius: 12px; font-weight: 600; }
section p.muted { margin: 4px 0 -8px; font-size: 13px; text-transform: uppercase; letter-spacing: .08em; }
section p.muted.center { text-transform: none; letter-spacing: 0; font-size: 15px; margin: 0; }
.explain { background: var(--bg-2); border-left: 4px solid var(--accent); padding: 10px 14px; border-radius: 8px; margin: 0; }

.verdict { display: flex; align-items: center; gap: 16px; padding: 18px; border-radius: 18px; font-size: 18px; animation: pop .5s ease both; }
.verdict b { font-family: var(--font-display); font-size: 28px; }
.verdict .icon { font-size: 44px; width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: #0003; font-weight: 800; }
.verdict.good { background: var(--good); color: #032713; }
.verdict.bad { background: var(--bad); color: #2a0009; }
.waitnext { text-align: center; }

.leaderboard h1, .podium-screen h1 { font-size: 34px; }
.podium-screen .podium { margin: 20px 0 6px; font-size: 13px; }
.podium-screen .podium .block { font-size: 28px; }
.podium-screen .p1 .block { height: 150px; } .podium-screen .p2 .block { height: 110px; } .podium-screen .p3 .block { height: 80px; }
.place { font-family: var(--font-display); font-size: 22px; font-weight: 700; }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--panel-2); padding: 12px 18px; border-radius: 12px; box-shadow: 0 10px 30px #0008; z-index: 99; animation: pop .3s ease; max-width: calc(100% - 32px); }
