/* Juara: Quiz Kilat & Wall of Fame — memakai warna tema (--brand, --surface, --line …) dari app.css; layar game memakai latar gelap sendiri. */
.jr-medal{display:inline-grid;place-items:center;flex:none;width:26px;height:26px;border-radius:50%;font-weight:800;font-size:12px;background:var(--surface-2,#eef0f3);color:var(--text,#222)}
.jr-medal.m1{background:linear-gradient(145deg,#f7d774,#c9a227);color:#3b2b00}
.jr-medal.m2{background:linear-gradient(145deg,#e4e8ec,#9aa5b1);color:#222}
.jr-medal.m3{background:linear-gradient(145deg,#e6b48a,#a8653a);color:#fff}
.jr-av{width:34px;height:34px;border-radius:50%;object-fit:cover;flex:none;display:inline-grid;place-items:center;font-size:12px;font-weight:700;background:var(--brand-50,#eef2ff);color:var(--brand,#334)}
.jr-wall{display:flex;flex-direction:column;gap:16px}
.jr-sec{background:var(--surface,#fff);border:1px solid var(--line,#e5e7eb);border-radius:var(--radius,14px);padding:16px 18px}
.jr-sec h3{display:flex;align-items:center;gap:8px;margin:0 0 4px;font-size:17px}
.jr-sub{margin:0 0 12px;color:var(--muted,#6b7280);font-size:13px}
.jr-ang{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:10px}
.jr-ang-card{border:1px solid var(--line,#e5e7eb);border-radius:12px;padding:10px 12px;background:var(--surface-2,#f8fafc)}
.jr-ang-t{display:block;font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted,#6b7280);margin-bottom:6px}
.jr-ang-card ol,.jr-qcard ol,.jr-stars{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px}
.jr-ang-card li,.jr-qcard li,.jr-stars li{display:flex;align-items:center;gap:8px}
.jr-ang-card li>span:not(.jr-medal):not(.jr-av),.jr-qcard li>span:not(.jr-medal):not(.jr-av),.jr-stars li>span:not(.jr-medal):not(.jr-av){flex:1;min-width:0}
.jr-ang-card li.is-first>span:not(.jr-medal){font-weight:800}
.jr-ang-card li.is-first>span:not(.jr-medal)::after{content:" 👑"}
.jr-ang-card li.is-me,.jr-stars li.is-me{outline:2px solid var(--brand,#334);outline-offset:2px;border-radius:8px}
.jr-stars li span strong{display:block;line-height:1.2}
.jr-stars li span small,.jr-qcard li small{color:var(--muted,#6b7280);font-size:12px}
.jr-stars li b,.jr-ang-card li b,.jr-qcard li b{font-variant-numeric:tabular-nums}
.jr-quizzes{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:10px}
.jr-qcard{border:1px solid var(--line,#e5e7eb);border-radius:12px;padding:12px;display:flex;flex-direction:column;gap:6px;border-top:4px solid #3b82f6}
.jr-qcard.lv-medium{border-top-color:#f59e0b}.jr-qcard.lv-high{border-top-color:#ef4444}
.jr-qcard header{display:flex;justify-content:space-between;gap:6px;font-size:12px;color:var(--muted,#6b7280)}
.jr-lv{font-weight:700;color:var(--text,#222)}
.jr-duel{margin:4px 0 0;font-size:13px;font-weight:600}
.jr-live-card{display:flex;align-items:center;gap:12px;padding:14px 16px;border-radius:16px;text-decoration:none;color:#fff;background:linear-gradient(120deg,#7c3aed,#ec4899);box-shadow:0 10px 30px -12px rgba(124,58,237,.7);animation:jr-glow 1.6s ease-in-out infinite}
.jr-live-card span{flex:1}.jr-live-card strong{display:block;font-size:17px}.jr-live-card small{opacity:.9}
.jr-live-card b{background:#fff;color:#7c3aed;border-radius:999px;padding:8px 14px;font-size:13px;white-space:nowrap}
@keyframes jr-glow{50%{box-shadow:0 10px 40px -6px rgba(236,72,153,.9)}}
.jr-me .card-body{display:flex;align-items:center;gap:14px}
.jr-me-n{font-size:40px;font-weight:800;line-height:1;color:var(--brand,#334);min-width:64px;text-align:center}
.jr-me small{display:block}
.jr-how{margin:0;padding-left:18px;display:flex;flex-direction:column;gap:6px;font-size:14px}
.jr-levels{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin:6px 0 12px}
.jr-level{position:relative;display:flex;flex-direction:column;gap:2px;padding:12px;border:2px solid var(--line,#e5e7eb);border-radius:12px;cursor:pointer}
.jr-level input{position:absolute;opacity:0}
.jr-level:has(input:checked){border-color:var(--brand,#334);background:var(--brand-50,#eef2ff)}
.jr-level:has(input:focus-visible){outline:2px solid var(--brand,#334);outline-offset:2px}
.jr-level .jr-sec-n{font-size:30px;font-weight:800;line-height:1}
.jr-level .jr-sec-n small{font-size:12px;font-weight:600;margin-left:3px}
.jr-level>small{color:var(--muted,#6b7280);font-size:12px}
.jr-level.lv-entry .jr-sec-n{color:#2563eb}.jr-level.lv-medium .jr-sec-n{color:#d97706}.jr-level.lv-high .jr-sec-n{color:#dc2626}
.jr-cls-grp{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin:4px 0}
.jr-cls-grp>small{width:100%}
.jr-chip{border:1px solid var(--line,#e5e7eb);border-radius:999px;padding:4px 10px}
.jr-chip.is-off{opacity:.4}
.jr-subs{display:grid;grid-template-columns:repeat(auto-fill,minmax(170px,1fr));gap:4px;margin-top:8px}
.jr-kirim{display:inline-flex;gap:6px;align-items:center}
.jr-web .jr-sec{background:#fff;color:#1f2937}
@media(max-width:700px){.jr-levels{grid-template-columns:1fr}.jr-level{flex-direction:row;align-items:center;gap:10px}.jr-level>small{flex-basis:100%}}

/* Ajakan quiz tiba-tiba (Portal Murid) */
.jr-pop{position:fixed;inset:0;z-index:9999;display:grid;place-items:center;padding:20px;background:rgba(15,10,40,.72);backdrop-filter:blur(4px)}
.jr-pop-in{width:min(420px,100%);border-radius:22px;padding:26px 22px;text-align:center;color:#fff;background:linear-gradient(150deg,#4c1d95,#be185d);box-shadow:0 30px 80px -20px #000;display:flex;flex-direction:column;gap:10px;animation:jr-in .35s ease-out}
.jr-pop-ic{margin:0 auto;width:76px;height:76px;border-radius:50%;display:grid;place-items:center;background:rgba(255,255,255,.15);animation:jr-pulse 1s ease-in-out infinite}
.jr-pop h2{margin:0;font-size:26px}.jr-pop p{margin:0;opacity:.9}
.jr-pop-q{font-size:15px}
.jr-pop .jr-pop-go{background:#fff;color:#6d28d9;font-size:17px;padding:14px;border-radius:14px;justify-content:center}
.jr-pop .jr-pop-x{color:#fff;border-color:rgba(255,255,255,.4)}
@keyframes jr-in{from{transform:scale(.85);opacity:0}}
@keyframes jr-pulse{50%{transform:scale(1.1)}}

/* ------------------------------------------------------------------ Layar game (guru: proyektor, murid: HP) */
.jq{--jq-bg:#160f33;--jq-bg2:#2a1263;--o0:#e11d48;--o1:#2563eb;--o2:#d97706;--o3:#16a34a;--o4:#7c3aed;--o5:#0891b2;color:#fff}
.jq-host{position:fixed;inset:0;display:flex;flex-direction:column;background:radial-gradient(1200px 700px at 20% 0%,var(--jq-bg2),var(--jq-bg));z-index:5;overflow:auto}
.jq.lv-medium{--jq-bg2:#5b2a06}.jq.lv-high{--jq-bg2:#5f0b1d}
.jq-top{display:flex;align-items:center;gap:14px;padding:12px 20px;border-bottom:1px solid rgba(255,255,255,.12);flex-wrap:wrap}
.jq-top a,.jq-top button{color:#fff;background:none;border:1px solid rgba(255,255,255,.25);border-radius:10px;width:38px;height:38px;display:grid;place-items:center;cursor:pointer}
.jq-top .jq-back svg{transform:rotate(180deg)}
.jq-brand{display:inline-flex;align-items:center;gap:6px;font-weight:800;letter-spacing:.04em}
.jq-title{flex:1;font-weight:600;opacity:.9;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.jq-lv{padding:4px 10px;border-radius:999px;background:rgba(255,255,255,.14);font-size:13px;font-weight:700}
.jq-cls{font-size:13px;opacity:.8}
.jq-stage{flex:1;display:grid;place-items:center;padding:24px}
.jq-foot{display:flex;gap:10px;align-items:center;justify-content:flex-end;padding:12px 20px;border-top:1px solid rgba(255,255,255,.12);flex-wrap:wrap}
.jq-foot [data-jq-count]{margin-right:auto;font-weight:600;opacity:.85}
.jq-foot .btn-ghost{color:#fff;background:transparent;border-color:rgba(255,255,255,.35)}
.jq-lobby,.jq-pre,.jq-wait{text-align:center;display:flex;flex-direction:column;align-items:center;gap:12px}
.jq-lobby h2{font-size:clamp(28px,4vw,48px);margin:0}
.jq-lobby p,.jq-wait p{opacity:.85;max-width:560px}
.jq-pulse{width:120px;height:120px;border-radius:50%;display:grid;place-items:center;background:rgba(255,255,255,.1);animation:jr-pulse 1.2s ease-in-out infinite}
.jq-chips{display:flex;flex-wrap:wrap;gap:8px;justify-content:center;max-width:900px}
.jq-chips span{background:rgba(255,255,255,.14);border-radius:999px;padding:6px 12px;font-weight:600;animation:jr-in .3s ease-out}
.jq-chips small{opacity:.7}
.jq-pre p{font-size:22px;margin:0;opacity:.85}
.jq-pre b{font-size:clamp(90px,16vw,200px);line-height:1;font-weight:900}
.jq-q{width:min(1100px,100%);display:flex;flex-direction:column;gap:16px;align-items:stretch}
.jq-meta{display:flex;justify-content:space-between;align-items:center;font-weight:700;opacity:.85}
.jq-text{font-size:clamp(22px,3.2vw,42px);line-height:1.25;text-align:center;margin:0}
.jq-img{max-height:32vh;max-width:100%;object-fit:contain;align-self:center;border-radius:12px;background:#fff}
.jq-timer{position:relative;width:110px;height:110px;align-self:center}
.jq-timer svg{width:100%;height:100%;transform:rotate(-90deg)}
.jq-timer circle{fill:none;stroke:rgba(255,255,255,.15);stroke-width:10}
.jq-timer .jq-ring{stroke:#facc15;stroke-dasharray:339.3;stroke-linecap:round;transition:stroke-dashoffset .1s linear}
.jq-timer .jq-ring.is-low{stroke:#f43f5e}
.jq-timer b{position:absolute;inset:0;display:grid;place-items:center;font-size:44px;font-weight:900}
.jq-opts{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.jq-opt{position:relative;overflow:hidden;display:flex;align-items:center;gap:12px;padding:16px 18px;border-radius:16px;border:0;color:#fff;font:inherit;font-size:clamp(16px,2vw,24px);font-weight:700;text-align:left;background:var(--o0);min-height:76px;box-shadow:0 6px 0 rgba(0,0,0,.25)}
.jq-opt.o1{background:var(--o1)}.jq-opt.o2{background:var(--o2)}.jq-opt.o3{background:var(--o3)}.jq-opt.o4{background:var(--o4)}.jq-opt.o5{background:var(--o5)}
.jq-opt b{display:grid;place-items:center;flex:none;width:40px;height:40px;border-radius:10px;background:rgba(255,255,255,.22);font-size:20px}
.jq-opt span{position:relative;z-index:1}
.jq-opt.is-dim{opacity:.35}
.jq-opt.is-key{outline:4px solid #fff;outline-offset:3px}
.jq-opt.is-key::after{content:"✓";position:absolute;right:16px;font-size:30px}
.jq-opt .jq-bar{position:absolute;left:0;top:0;bottom:0;background:rgba(255,255,255,.18)}
.jq-opt em{margin-left:auto;font-style:normal;font-size:20px;position:relative;z-index:1}
.jq-q.is-reveal{display:grid;grid-template-columns:1.6fr 1fr;gap:18px;align-items:start}
.jq-q.is-reveal .jq-meta,.jq-q.is-reveal .jq-text{grid-column:1/-1}
.jq-side{background:rgba(0,0,0,.25);border-radius:16px;padding:14px}
.jq-side h3,.jq-duel h3,.jq-endm h3{margin:0 0 10px}
.jq-board{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px}
.jq-board li{text-align:left;display:flex;align-items:center;gap:10px;background:rgba(255,255,255,.08);border-radius:12px;padding:8px 12px}
.jq-board li strong{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.jq-board li small{opacity:.7}.jq-board li b{font-size:18px;font-variant-numeric:tabular-nums}
.jq-board li.is-me{outline:2px solid #facc15}
.jq-muted{opacity:.7}
.jq-end{width:min(1000px,100%);display:flex;flex-direction:column;gap:18px;align-items:center;text-align:center}
.jq-end h2{font-size:clamp(30px,4vw,52px);margin:0}
.jq-podium{display:flex;align-items:flex-end;justify-content:center;gap:14px;width:100%}
.jq-pod{display:flex;flex-direction:column;align-items:center;gap:4px;width:min(240px,30%)}
.jq-pod strong{font-size:clamp(16px,2vw,24px)}.jq-pod small{opacity:.75}.jq-pod b{font-size:22px}
.jq-pod .jr-medal{width:46px;height:46px;font-size:20px}
.jq-pod i{display:block;width:100%;border-radius:12px 12px 0 0;background:linear-gradient(#facc15,#ca8a04);height:160px;margin-top:6px}
.jq-pod.p2 i{height:115px;background:linear-gradient(#e5e7eb,#9ca3af)}.jq-pod.p3 i{height:85px;background:linear-gradient(#f0b27a,#a8653a)}
.jq-duel{width:min(560px,100%);background:rgba(0,0,0,.25);border-radius:16px;padding:14px;display:flex;flex-direction:column;gap:8px}
.jq-duel-row{display:flex;align-items:center;gap:10px}.jq-duel-row strong{flex:1;text-align:left}
.jq-duel-row.is-first strong::after{content:" 👑"}
.jq-ok{color:#86efac;font-weight:700}
/* HP murid */
.jq-play{border-radius:20px;overflow:hidden;background:radial-gradient(700px 500px at 20% 0%,var(--jq-bg2),var(--jq-bg));min-height:calc(100svh - 150px);display:flex;flex-direction:column}
.jq-play-head{display:flex;align-items:center;gap:8px;padding:12px 14px;border-bottom:1px solid rgba(255,255,255,.12);flex-wrap:wrap}
.jq-play-head .jq-brand{flex:1;min-width:0;font-size:14px}
.jq-score{font-size:20px;background:rgba(255,255,255,.14);border-radius:999px;padding:4px 12px}
.jq-play-stage{flex:1;display:grid;place-items:center;padding:16px}
.jq-play .jq-q{gap:12px}
.jq-play .jq-text{font-size:clamp(18px,5vw,26px)}
.jq-play .jq-sec{font-size:26px;background:rgba(255,255,255,.14);border-radius:12px;padding:2px 12px}
.jq-tbar{display:block;height:8px;border-radius:999px;background:rgba(255,255,255,.15);overflow:hidden}
.jq-tbar i{display:block;height:100%;background:linear-gradient(90deg,#f43f5e,#facc15);transition:width .1s linear}
.jq-play .jq-opts{grid-template-columns:1fr;gap:10px}
.jq-play .jq-opt{min-height:62px;font-size:18px;cursor:pointer}
.jq-play .jq-opt:active{transform:translateY(3px);box-shadow:0 3px 0 rgba(0,0,0,.25)}
.jq-sent{display:flex;flex-direction:column;gap:12px;text-align:center}
.jq-res{text-align:center;display:flex;flex-direction:column;gap:12px;width:100%}
.jq-res>b{font-size:30px}
.jq-res.is-ok>b{color:#86efac}.jq-res.is-bad>b{color:#fda4af}
.jq-rank{font-weight:700}
.jq-endm{width:100%;display:flex;flex-direction:column;gap:12px;text-align:center}
.jq-endm h2{margin:0;font-size:28px}
.jq-big2{font-size:64px;font-weight:900;margin:0;line-height:1}
@media(max-width:800px){.jq-opts{grid-template-columns:1fr}.jq-q.is-reveal{grid-template-columns:1fr}.jq-title{display:none}}
@media(prefers-reduced-motion:reduce){.jr-live-card,.jr-pop-ic,.jq-pulse,.jr-pop-in,.jq-chips span{animation:none}}

/* ---- Quiz Musik (1.1.0) */
.jr-mode{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:0 0 12px}
.jr-mode-opt{position:relative;display:flex;align-items:center;gap:10px;padding:12px;border:2px solid var(--line,#e5e7eb);border-radius:12px;cursor:pointer}
.jr-mode-opt input{position:absolute;opacity:0}
.jr-mode-opt span{display:flex;flex-direction:column}.jr-mode-opt small{color:var(--muted,#6b7280);font-size:12px}
.jr-mode-opt:has(input:checked){border-color:var(--brand,#334);background:var(--brand-50,#eef2ff)}
.jr-mode-opt:has(input:focus-visible){outline:2px solid var(--brand,#334);outline-offset:2px}
.jr-off td{opacity:.55}
.jr-play.is-on{background:var(--brand,#334);color:#fff}
.jr-edit{display:inline-block}.jr-edit[open]>form{position:absolute;right:16px;z-index:5;width:min(340px,90vw);background:var(--card,#fff);border:1px solid var(--line,#e5e7eb);border-radius:12px;padding:12px;box-shadow:0 12px 30px rgba(0,0,0,.12)}
.jq-top .jq-sound{width:auto;padding:0 12px;gap:6px;display:flex;align-items:center;background:#f59e0b;border-color:#f59e0b;color:#111;font-weight:700}
.jq-sound-hp{margin:10px 14px 0;background:#f59e0b;border-color:#f59e0b;color:#111}
.jq-q.is-music .jq-text{font-size:clamp(20px,2.6vw,34px)}
.jq-eq{display:flex;align-items:flex-end;justify-content:center;gap:6px;height:64px;margin:4px auto}
.jq-eq i{display:block;width:10px;border-radius:5px;background:linear-gradient(#fde68a,#f472b6);animation:jq-eq 1s ease-in-out infinite;height:20%}
.jq-eq i:nth-child(2){animation-delay:-.2s}.jq-eq i:nth-child(3){animation-delay:-.45s}.jq-eq i:nth-child(4){animation-delay:-.7s}.jq-eq i:nth-child(5){animation-delay:-.3s}.jq-eq i:nth-child(6){animation-delay:-.85s}.jq-eq i:nth-child(7){animation-delay:-.55s}
@keyframes jq-eq{0%,100%{height:18%}50%{height:100%}}
@media (prefers-reduced-motion:reduce){.jq-eq i{animation:none;height:60%}}
.jq-hint{text-align:center;margin:0;opacity:.85;font-size:14px}
.jq-info{grid-column:1/-1;text-align:center;margin:6px 0 0;font-size:clamp(14px,1.6vw,18px);opacity:.9}

/* Rating Glicko-2 (1.2.0): kartu murid (orang tua / murid / guru) & tabel guru */
.jr-rt .card-body{display:flex;flex-direction:column;gap:14px}
.jr-rt-hero{display:flex;flex-wrap:wrap;align-items:center;gap:14px 22px;padding:14px 16px;border-radius:14px;background:var(--surface-2,#f6f7f9);border:1px solid var(--line,#e5e7eb)}
.jr-rt-num{display:flex;flex-direction:column;line-height:1}
.jr-rt-num b{font-size:44px;font-weight:800;letter-spacing:-.02em;color:var(--brand,#334)}
.jr-rt-num small{margin-top:4px;color:var(--muted,#6b7280);font-size:12px;text-transform:uppercase;letter-spacing:.08em}
.jr-rt-meta{display:flex;flex-direction:column;gap:6px;min-width:0}
.jr-rt-spark{margin-left:auto;display:flex;flex-direction:column;align-items:flex-end;gap:2px;color:var(--brand,#334)}
.jr-spark{max-width:100%;height:auto}
.jr-lvpill{display:inline-block;padding:2px 10px;border-radius:999px;font-size:12px;font-weight:700;background:var(--brand-50,#eef2ff);color:var(--brand,#334);white-space:nowrap}
.jr-lvpill.lv-pemula{background:#eef1f4;color:#4b5563}
.jr-lvpill.lv-berkembang{background:#e0f2fe;color:#0369a1}
.jr-lvpill.lv-cakap{background:#dcfce7;color:#15803d}
.jr-lvpill.lv-mahir{background:#ede9fe;color:#6d28d9}
.jr-lvpill.lv-unggul{background:#fef3c7;color:#b45309}
.jr-lvpill.lv-juara{background:linear-gradient(135deg,#f7d774,#c9a227);color:#3b2b00}
.jr-dl{font-weight:700;font-size:13px;white-space:nowrap}
.jr-dl.is-up{color:#15803d}.jr-dl.is-down{color:#b91c1c}.jr-dl.is-flat{color:var(--muted,#6b7280)}
.jr-conf{font-size:12px;color:var(--muted,#6b7280)}
.jr-conf.c-rendah{color:#b45309}
.jr-rt-stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(110px,1fr));gap:8px}
.jr-rt-stats>div{border:1px solid var(--line,#e5e7eb);border-radius:12px;padding:10px 12px;display:flex;flex-direction:column;gap:2px}
.jr-rt-stats b{font-size:20px;font-weight:800}.jr-rt-stats b small{font-size:13px;font-weight:600;color:var(--muted,#6b7280)}
.jr-rt-stats>div>small{color:var(--muted,#6b7280);font-size:12px}
.jr-rt-h{margin:4px 0 0;font-size:14px}
.jr-rt-tab td,.jr-rt-tab th{vertical-align:middle}
.jr-rt-tab tr.is-off td{opacity:.65}
.jr-rt-sw{display:flex;flex-wrap:wrap;gap:6px 18px}.jr-rt-sw p{margin:0;display:flex;align-items:center;gap:6px;font-size:13.5px}
.jr-rt-music{margin:0;display:flex;flex-wrap:wrap;align-items:center;gap:6px}
.jr-rt-hist{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}
.jr-rt-hist li{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:8px 0;border-bottom:1px solid var(--line,#e5e7eb)}
.jr-rt-hist li:last-child{border-bottom:0}
.jr-rt-hist li>span{display:flex;flex-direction:column;min-width:0}
.jr-rt-info summary{cursor:pointer;font-weight:600;font-size:13.5px}
.jr-rt-info p{font-size:13px;margin:8px 0 0}
.jr-hard{margin:0;padding-left:18px;display:flex;flex-direction:column;gap:8px}
.jr-hard li span{display:block;font-size:13.5px}
@media (max-width:620px){.jr-rt-num b{font-size:36px}.jr-rt-spark{margin-left:0;align-items:flex-start}}
.jr-rt-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.jr-rt-meta>.jr-lvpill{align-self:flex-start}
