/* Live rooms: host board (/live/) and student phone view (/join/). */
.lv-conn { margin-left: auto; color: #ffd25e; font-weight: 700; }
.lv-error { color: #ffb0a6 !important; font-weight: 700; }
.lv-lobby { display: grid; grid-template-columns: 1fr auto; gap: 26px; align-items: center; }
.lv-lobby-main { text-align: center; }
.lv-step { font: 700 1.5rem var(--font-display); color: rgba(244,241,232,.9); margin: 4px 0; }
.lv-step b { color: #ffd25e; }
.lv-code { font: 700 clamp(4rem, 11vw, 7.5rem)/1 var(--font-display); letter-spacing: .06em; color: #fff; background: rgba(0,0,0,.25); border: 3px dashed rgba(244,241,232,.35); border-radius: 18px; padding: 10px 26px; display: inline-block; margin: 8px 0 18px; }
.lv-time { display: inline-flex; gap: 8px; align-items: center; color: rgba(244,241,232,.8); font-weight: 600; margin-top: 4px; }
.lv-qr { background: #fff; border-radius: 14px; padding: 10px 10px 6px; text-align: center; color: var(--ink); font-weight: 700; width: 220px; }
.lv-qr svg { width: 100%; height: auto; display: block; }
.lv-sub { color: #ffd25e; font: 700 1.5rem var(--font-hand); margin: 18px 0 8px; text-align: center; }
.lv-players { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.tool-panel .lv-player { background: rgba(255,255,255,.12); border: 0; border-radius: 999px; padding: 6px 14px; font: 700 1.05rem var(--font-display); animation: pop .3s ease; }
.tool-panel .lv-player:hover { background: rgba(255,107,90,.4); text-decoration: line-through; }
.lv-player.is-off { opacity: .45; }
.lv-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; background: rgba(0,0,0,.2); border-radius: 10px; padding: 8px 14px; margin-bottom: 10px; color: rgba(244,241,232,.85); }
.lv-head b { color: #fff; }
.lv-code-sm { font-family: var(--font-display); font-size: 1.3rem; letter-spacing: .05em; color: #ffd25e !important; }
.lv-count { font: 700 1.2rem var(--font-display); }
.lv-answered { font: 700 1.2rem var(--font-display); color: rgba(244,241,232,.85); }
.lv-answered b { color: #ffd25e; font-size: 1.6rem; }
.qs-answers .qs-ans { position: relative; display: flex; align-items: center; gap: 14px; padding: 18px; border-radius: 12px; color: #fff; font: 700 clamp(1.05rem, 2.2vw, 1.6rem) var(--font-display); box-shadow: inset 0 -6px 0 rgba(0,0,0,.2); min-height: 80px; }
div.qs-ans.ans-0 { background: #e2453c; } div.qs-ans.ans-1 { background: #2f6fd1; } div.qs-ans.ans-2 { background: #d89a00; } div.qs-ans.ans-3 { background: #3c8f37; }
.lv-dist { margin-left: auto; min-width: 2.4em; text-align: right; font-size: 1.6rem; }
.lv-dist::before { content: ''; position: absolute; left: 0; bottom: 0; height: 6px; width: var(--w); background: rgba(255,255,255,.75); border-radius: 0 6px 6px 0; }
.lv-board { list-style: none; padding: 0; margin: 0 auto; max-width: 560px; }
.lv-board li { display: flex; align-items: center; gap: 12px; background: rgba(0,0,0,.22); border-radius: 10px; padding: 8px 14px; margin: 6px 0; font: 700 1.15rem var(--font-display); color: #fff; animation: pop .3s ease both; }
.lv-board li:nth-child(2) { animation-delay: .05s; } .lv-board li:nth-child(3) { animation-delay: .1s; } .lv-board li:nth-child(4) { animation-delay: .15s; } .lv-board li:nth-child(5) { animation-delay: .2s; }
.lv-rank { width: 30px; height: 30px; border-radius: 50%; background: #ffd25e; color: #3b2a00; display: grid; place-items: center; font-size: .95rem; flex: none; }
.lv-board[start] li .lv-rank { display: none; }
.lv-name { flex: 1; }
.lv-gain { color: #7dd87a; font-size: .95rem; }
.lv-podium { display: grid; grid-template-columns: repeat(3, 1fr); align-items: end; gap: 12px; max-width: 620px; margin: 10px auto 18px; }
.lv-podium > div { display: flex; flex-direction: column; align-items: center; gap: 2px; color: #fff; font-family: var(--font-display); animation: pop .5s ease both; }
.lv-podium b { font-size: 1.3rem; word-break: break-word; text-align: center; }
.lv-podium span:not(.lv-medal) { color: #ffd25e; font-weight: 700; }
.lv-medal { font-size: 3rem; }
.lv-podium i { display: block; width: 100%; border-radius: 10px 10px 0 0; background: rgba(255,255,255,.16); margin-top: 6px; }
.lv-step-1 i { height: 150px; background: rgba(255,210,94,.45) !important; } .lv-step-2 i { height: 105px; } .lv-step-3 i { height: 75px; }
.lv-step-1 { animation-delay: .6s !important; } .lv-step-2 { animation-delay: .3s !important; }
.lv-bars { max-width: 820px; margin: 0 auto; display: grid; gap: 10px; }
.lv-bar { display: grid; grid-template-columns: minmax(120px, 30%) 1fr 3em; align-items: center; gap: 12px; color: #fff; font: 700 1.2rem var(--font-display); }
.lv-bar-track { height: 38px; background: rgba(0,0,0,.25); border-radius: 10px; overflow: hidden; }
.lv-bar-track i { display: block; height: 100%; border-radius: 10px; transition: width .6s ease; }
.lv-bar.ans-0 i { background: #e2453c; } .lv-bar.ans-1 i { background: #2f6fd1; } .lv-bar.ans-2 i { background: #d89a00; } .lv-bar.ans-3 i { background: #3c8f37; }
.lv-bar b { text-align: right; font-size: 1.5rem; }
.lv-cloud { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 18px; max-width: 900px; margin: 0 auto; min-height: 180px; font-family: var(--font-display); font-weight: 700; }
.lv-cloud span { animation: pop .4s ease; line-height: 1.1; }
.lv-cloud sup { font-size: .45em; opacity: .7; margin-left: 2px; }
.lv-cloud .c0 { color: #ffd25e; } .lv-cloud .c1 { color: #7dd87a; } .lv-cloud .c2 { color: #5aa2ff; } .lv-cloud .c3 { color: #ff8f80; } .lv-cloud .c4 { color: #c4a3ff; } .lv-cloud .c5 { color: #fff; }
#lv-pollform:empty { display: none; }
.lv-pollform { max-width: 640px; margin: 16px auto 0; background: rgba(0,0,0,.22); border: 2px dashed var(--s-line); border-radius: 12px; padding: 14px 16px; display: grid; gap: 10px; }
.lv-pollform label { display: grid; gap: 6px; color: rgba(244,241,232,.85); font-weight: 700; }
.lv-pollform input, .lv-pollform textarea { width: 100%; }
@media (max-width: 760px) { .lv-lobby { grid-template-columns: 1fr; } .lv-qr { margin: 0 auto; width: 180px; } .lv-bar { grid-template-columns: 1fr 3em; } .lv-bar-label { grid-column: 1 / -1; } }

/* ---------- student phone view ---------- */
.page-join { background: var(--board); }
.page-join .site-footer { display: none; }
.jn-wrap { min-height: calc(100vh - 80px); display: grid; place-items: start center; padding: 18px 14px 40px; background: var(--chalk-texture), radial-gradient(ellipse at 30% 10%, #3b5e48, transparent 60%), var(--board); }
.jn-card { width: min(520px, 100%); color: var(--chalk); }
.jn-form { display: grid; gap: 14px; text-align: center; background: rgba(0,0,0,.18); border: 3px dashed rgba(244,241,232,.25); border-radius: 18px; padding: 26px 20px; margin-top: 6vh; }
.jn-form h1 { color: #fff; margin: 0; font-size: 2rem; }
.jn-form p { margin: 0; color: rgba(244,241,232,.8); }
.jn-form input, .jn-text input { width: 100%; font: 700 1.5rem var(--font-display); text-align: center; padding: 14px; border-radius: 12px; border: 3px solid rgba(244,241,232,.35); background: var(--paper); color: var(--ink); }
#jn-code { letter-spacing: .25em; font-size: 2rem; }
.jn-small { font-size: .85rem; }
.jn-error { color: #ffb0a6 !important; font-weight: 800; }
.jn-top { display: flex; justify-content: space-between; align-items: center; background: rgba(0,0,0,.25); border-radius: 12px; padding: 10px 14px; font: 700 1.1rem var(--font-display); }
.jn-top b { color: #ffd25e; }
.jn-conn { text-align: center; color: #ffd25e; font-weight: 700; padding: 6px; }
.jn-center { text-align: center; padding: 8vh 10px 20px; }
.jn-center h2 { color: #fff; font-size: 2rem; margin: 10px 0 6px; }
.jn-center p { color: rgba(244,241,232,.85); font-size: 1.1rem; margin: 6px 0; }
.jn-big { font-size: 5rem; line-height: 1; animation: pop .35s ease; }
.jn-result.is-right h2 { color: #7dd87a; } .jn-result.is-wrong h2 { color: #ffb0a6; }
.jn-rank { font: 700 1.4rem var(--font-hand); }
.jn-q { color: #fff; font: 700 1.35rem/1.3 var(--font-display); text-align: center; margin: 18px 4px; }
.jn-answers { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.jn-answers.n2 { grid-template-columns: 1fr; }
.jn-ans { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 120px; padding: 12px; border: 0; border-radius: 16px; color: #fff; font: 700 1.1rem/1.2 var(--font-display); box-shadow: inset 0 -7px 0 rgba(0,0,0,.2); cursor: pointer; }
.jn-ans span { font-size: 2.2rem; }
.jn-ans:active { transform: scale(.96); }
.jn-ans.ans-0 { background: #e2453c; } .jn-ans.ans-1 { background: #2f6fd1; } .jn-ans.ans-2 { background: #d89a00; } .jn-ans.ans-3 { background: #3c8f37; }
.jn-text { display: grid; gap: 12px; }
.jn-wait { text-align: center; padding: 14vh 0; color: var(--chalk); }
.jn-spin { width: 44px; height: 44px; border-radius: 50%; border: 5px solid rgba(255,255,255,.2); border-top-color: #ffd25e; margin: 0 auto; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pop { from { transform: scale(.85); opacity: 0; } }
.page-join .main-nav, .page-join .header-actions, .page-join .skip { display: none; }
.page-join .site-header { position: static; }
