/* ===== Menu: hero RANKED, 2 PLAYERS + VS CPU (+ ONLINE) side by side, MISSIONS, then info buttons ===== */
.menu-buttons { gap: .85em; }
.menu-buttons .row.hero .btn { font-size: 1.85em; padding: .5em .4em; animation: heroGlow 2.6s ease-in-out infinite; }
@keyframes heroGlow { 50% { filter: brightness(1.1) drop-shadow(0 0 .5em rgba(255, 210, 63, .6)); } }
.menu-buttons .row.modes .btn { font-size: 1.3em; padding: .5em .3em; }
.menu-buttons .row.sub .btn { font-size: .95em; padding: .45em .3em; }
.portrait .menu-buttons { gap: .7em; }
.portrait .menu-buttons .row.hero .btn { font-size: 1.7em; }
.portrait .menu-buttons .row.modes .btn { font-size: 1.15em; }
.portrait .menu-buttons .row.sub .btn { font-size: .8em; }
.short .menu-buttons { gap: .45em; }
.short .menu-buttons .row.hero .btn { font-size: 1.35em; padding: .38em .3em; }
.short .menu-buttons .row.modes .btn { font-size: 1.05em; padding: .38em .3em; }
.short .menu-buttons .row.sub .btn { font-size: .8em; padding: .35em .3em; }
.short .menu-center { gap: 1.6cqmin; }
.menu-buttons .row .btn.yellow { --tc: var(--ink); }

/* ===== Ranked hub ===== */
.rk { font-size: clamp(12px, 2.5cqmin, 26px); }
.portrait .rk { font-size: clamp(11px, min(3.6cqw, 2.05cqh), 24px); }
#scr-ranked.active { display: flex; flex-direction: column; align-items: center; gap: 1.2cqmin; padding-top: 2cqmin; }
.rk-back { position: absolute; top: 2.5cqmin; left: 2.5cqmin; z-index: 5; font-size: clamp(14px, 2.6cqmin, 26px); }
.rk-title { flex: none; font-size: 2.7em; line-height: 1; margin-top: .1em; }
.rk-body { flex: 1 1 0; min-height: 0; width: 100%; max-width: 1100px; padding: 0 3cqmin 2cqmin; display: grid; gap: 2cqmin; align-items: center; }
.landscape .rk-body { grid-template-columns: minmax(0, .85fr) minmax(0, 1.2fr); }
.portrait .rk-body { grid-template-rows: auto minmax(0, 1fr); align-items: start; }
.rk-badge-col { display: flex; flex-direction: column; align-items: center; gap: .4em; min-width: 0; }
.rk-badge-wrap { width: min(100%, 26cqh, 78cqw); aspect-ratio: 1; animation: badgeFloat 3s ease-in-out infinite; }
.landscape .rk-badge-wrap { width: min(100%, 42cqh); }
.portrait .rk-badge-wrap { width: min(100%, 24cqh, 56cqw); }
.rk-badge-wrap .tier-badge { width: 100% !important; height: 100% !important; filter: drop-shadow(0 .4em .5em rgba(0, 0, 0, .45)); }
@keyframes badgeFloat { 50% { transform: translateY(-.35em) rotate(1.5deg); } }
.rk-id { text-align: center; max-width: 100%; }
.rk-tier { font-size: 1.7em; line-height: 1.1; color: var(--tc, var(--yellow)); -webkit-text-stroke: .07em var(--ink); paint-order: stroke fill; text-shadow: 0 .08em 0 var(--ink); padding: 0 .1em .08em; }
.rk-mmr { display: flex; align-items: baseline; justify-content: center; gap: .35em; }
.rk-mmr b { font-size: 2.7em; line-height: 1; color: #fff; text-shadow: 0 .06em 0 var(--ink); }
.rk-mmr span { color: var(--text-dim); font-weight: 800; letter-spacing: .08em; }
.rk-info { display: flex; flex-direction: column; gap: .7em; min-width: 0; }
.rk-card { background: var(--panel-2); border: .15em solid var(--ink); border-radius: 1em; padding: .5em .8em; box-shadow: 0 .2em 0 var(--ink); min-width: 0; }
.rk-progress { display: flex; flex-direction: column; gap: .25em; }
.rk-bar { height: 1.15em; background: #0c0618; border: .15em solid var(--ink); border-radius: 1em; overflow: hidden; }
.rk-bar i { display: block; height: 100%; width: 0; border-radius: 1em; transition: width .9s var(--ease-out);
    background: repeating-linear-gradient(-45deg, var(--tc, var(--yellow)) 0 .7em, color-mix(in srgb, var(--tc, var(--yellow)) 78%, #000) .7em 1.4em); background-size: 200% 100%; animation: stripes 1.2s linear infinite; }
.rk-bar-l { display: flex; justify-content: space-between; color: var(--text-dim); font-size: .8em; gap: 1em; }
.rk-tonext { text-align: center; font-weight: 800; font-size: .92em; }
.rk-opp { display: flex; flex-direction: column; gap: .3em; }
.rk-opp-h { font-size: .75em; letter-spacing: .12em; color: var(--text-dim); font-weight: 800; }
.rk-opp-row { display: flex; align-items: center; gap: .8em; min-width: 0; }
.rk-opp-av { flex: none; width: 3.6em; height: 3.6em; } .rk-opp-av canvas { width: 100% !important; height: 100% !important; }
.rk-stack { display: flex; flex-direction: column; min-width: 0; flex: 1; gap: .1em; }
.rk-opp-name { font-size: 1.3em; color: #fff; text-shadow: 0 .06em 0 var(--ink); }
.rk-opp-meta { font-weight: 800; color: var(--yellow); font-size: .95em; }
.rk-opp-style { font-size: .85em; color: var(--text-dim); } .rk-opp-style { text-shadow: 0 0 0 var(--bc); }
.rk-two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: .7em; }
.rk-record { display: flex; justify-content: space-around; text-align: center; align-items: center; gap: .4em; }
.rk-record > div { display: flex; flex-direction: column; min-width: 0; }
.rk-record b { font-size: 1.7em; line-height: 1.05; } .rk-record small { color: var(--text-dim); font-size: .75em; }
.rk b.w, .rk .rk-chip.w b { color: var(--green); } .rk b.l, .rk .rk-chip.l b { color: #ff7d7d; }
.rk-seasoncard { display: flex; align-items: center; gap: .6em; }
.rk-seasoncard > .ico { width: 2em; height: 2em; flex: none; display: inline-flex; } .rk-seasoncard > .ico svg { width: 100%; height: 100%; }
.rk-season { font-weight: 800; font-size: .92em; }
.rk-reward { display: flex; align-items: center; gap: .35em; font-size: .78em; color: var(--text-dim); min-width: 0; flex-wrap: wrap; }
.rk-reward .new { color: var(--green); font-weight: 800; }
.paint-dot { flex: none; width: 1.1em; height: 1.1em; border-radius: 50%; border: .12em solid var(--ink); box-shadow: inset 0 .15em 0 rgba(255, 255, 255, .45); }
.paint-dot.own { width: .95em; height: .95em; }
.rk-last { display: flex; gap: .4em; justify-content: center; min-height: 2em; align-items: center; }
.rk-chip { display: flex; align-items: baseline; gap: .3em; padding: .15em .55em; border-radius: 1em; background: rgba(12, 6, 26, .65); border: .12em solid var(--ink); font-weight: 800; font-size: .9em; }
.rk-chip b { font-family: var(--font-display); } .rk-chip span { color: var(--text-dim); font-size: .9em; }
.rk-chip.latest { border-color: var(--yellow); animation: popIn .5s var(--ease-spring) both; }
.rk-empty { color: var(--text-dim); font-size: .9em; }
.rk-actions { display: flex; gap: .8em; margin-top: .2em; } .rk-actions .btn { min-width: 0; }
.rk-actions .btn.big { flex: 1.7; font-size: 1.5em; } .rk-actions .btn.purple { flex: 1; font-size: 1.05em; }
.portrait .rk-actions { flex-direction: column; } .portrait .rk-actions .btn.big { font-size: 1.4em; }
/* portrait: badge left of the id block would not fit 360px; stack but keep it compact */
.portrait .rk-badge-col { flex-direction: row; justify-content: center; gap: 1em; }
.portrait .rk-id { text-align: left; flex: 1; min-width: 0; } .portrait .rk-mmr { justify-content: flex-start; }
.portrait .rk-mmr b { font-size: 2.3em; } .portrait .rk-tier { font-size: 1.35em; }
.portrait .rk-badge-wrap { flex: none; width: min(40cqw, 22cqh); }
.portrait .rk-info { gap: .5em; } .portrait .rk-two { grid-template-columns: 1fr; }
.portrait .rk-record b { font-size: 1.3em; }
.short .rk-title { font-size: 1.9em; } .short .rk-card { padding: .35em .7em; } .short .rk-info { gap: .45em; }
.short .rk-tier { font-size: 1.3em; } .short .rk-mmr b { font-size: 2em; } .short .rk-opp-av { width: 2.8em; height: 2.8em; }
.short .rk-record b { font-size: 1.3em; } .short .rk-last { min-height: 1.5em; }
.short .rk-actions .btn.big { font-size: 1.2em; } .short .rk-actions .btn.purple { font-size: .9em; }

/* ===== Ranked panel on the match result ===== */
.rkr { position: relative; display: flex; align-items: center; gap: .8em; background: rgba(12, 6, 26, .6); border: .15em solid var(--ink); border-radius: 1em; padding: .5em .8em; overflow: hidden; }
.rkr-badge { flex: none; width: 7em; height: 7em; } .rkr-badge .tier-badge { width: 100% !important; height: 100% !important; }
.rkr-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .15em; }
.rkr-h { font-size: .75em; letter-spacing: .12em; color: var(--text-dim); font-weight: 800; }
.rkr-mmr { display: flex; align-items: baseline; gap: .35em; } .rkr-mmr b { font-size: 2.3em; line-height: 1; color: #fff; text-shadow: 0 .06em 0 var(--ink); } .rkr-mmr small { color: var(--text-dim); font-weight: 800; }
.rkr-delta { font-size: 1.5em; opacity: 0; transform: scale(.4); transition: opacity .3s, transform .5s var(--ease-spring); }
.rkr-delta.show { opacity: 1; transform: none; } .rkr-delta.up { color: var(--green); } .rkr-delta.down { color: #ff7d7d; }
.rkr-tier { font-size: 1.15em; color: var(--yellow); }
.rkr-bar { height: .9em; background: #0c0618; border: .13em solid var(--ink); border-radius: 1em; overflow: hidden; margin: .2em 0; }
.rkr-bar i { display: block; height: 100%; width: 0; border-radius: 1em; transition: width 1s var(--ease-out); background: linear-gradient(180deg, #fff3a8, var(--yellow) 40%, var(--yellow-d)); }
.rkr-opp { display: flex; align-items: center; gap: .4em; color: var(--text-dim); font-size: .85em; } .rkr-opp canvas { width: 1.6em !important; height: 1.6em !important; flex: none; }
.rkr-banner { position: absolute; left: 0; right: 0; top: 50%; text-align: center; font-size: 1.7em; padding: .15em .3em; transform: translateY(-50%) scale(0) rotate(-6deg); opacity: 0; pointer-events: none;
    -webkit-text-stroke: .08em var(--ink); paint-order: stroke fill; text-shadow: 0 .08em 0 var(--ink); background: linear-gradient(90deg, transparent, rgba(12, 6, 26, .88) 12%, rgba(12, 6, 26, .88) 88%, transparent); }
.rkr-banner.promoted { color: var(--yellow); } .rkr-banner.demoted { color: #ff7d7d; }
.rkr-banner.show { animation: rkrBanner 2.6s var(--ease-spring) forwards; }
@keyframes rkrBanner { 0% { transform: translateY(-50%) scale(0) rotate(-8deg); opacity: 0; } 14% { transform: translateY(-50%) scale(1.1) rotate(-3deg); opacity: 1; } 24% { transform: translateY(-50%) scale(1) rotate(-3deg); } 80% { opacity: 1; } 100% { transform: translateY(-50%) scale(1) rotate(-3deg); opacity: 0; } }
.rkr.flash::after { content: ''; position: absolute; inset: 0; background: #fff; animation: rkrFlash .6s ease-out forwards; pointer-events: none; }
@keyframes rkrFlash { from { opacity: .85; } to { opacity: 0; } }
.rkr.promoted .rkr-badge { animation: popIn .6s var(--ease-spring); } .rkr.demoted { animation: shake .5s; }
#scr-result.is-ranked .mr-ledger { padding: .3em .5em; } #scr-result.is-ranked .mr-ledger-h { display: none; }
.short #scr-result.is-ranked .mr-stats { display: none; }
.short .rkr-badge { width: 5em; height: 5em; } .short .rkr-mmr b { font-size: 1.8em; } .short .rkr-opp { display: none; }
.portrait .rkr-badge { width: 5.5em; height: 5.5em; }

/* ===== Leaderboard modal ===== */
.lb-modal { width: min(94%, 38em); }
.lb-me { display: flex; align-items: center; gap: .8em; background: rgba(12, 6, 26, .5); border: .12em solid var(--ink); border-radius: 1em; padding: .4em .8em; }
.lb-me-badge { flex: none; width: 4.6em !important; height: 4.6em !important; }
.lb-me-main { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.lb-me-h { font-size: .75em; letter-spacing: .1em; color: var(--text-dim); font-weight: 800; text-transform: uppercase; }
.lb-me-t { font-size: 1.3em; color: var(--yellow); } .lb-me-s { font-size: .85em; color: var(--text); }
.lb-body { display: flex; flex-direction: column; gap: .4em; min-height: 5em; max-height: 46cqh; overflow: hidden; }
.lb-list { display: flex; flex-direction: column; gap: .25em; overflow-y: auto; min-height: 0; flex: 0 1 auto; scrollbar-width: thin; touch-action: pan-y; }
.lb-row { flex: none; }
.lb-row { display: flex; align-items: center; gap: .6em; padding: .2em .6em; background: rgba(12, 6, 26, .45); border-radius: .7em; border: .1em solid rgba(255, 255, 255, .06); }
.lb-row.you { border-color: var(--yellow); background: rgba(255, 210, 63, .14); }
.lb-row.top1 .lb-rank { color: #FFD23F; } .lb-row.top2 .lb-rank { color: #C9D4E6; } .lb-row.top3 .lb-rank { color: #E0904F; }
.lb-rank { width: 2.8em; flex: none; color: var(--text-dim); font-size: .95em; }
.lb-tier { flex: none; width: 2em; height: 2em; }
.lb-name { flex: 1; min-width: 0; font-weight: 800; }
.lb-score { flex: none; color: #fff; }
.lb-sep { text-align: center; color: var(--text-dim); line-height: .6; }
.lb-note { text-align: center; color: var(--text-dim); padding: .8em .4em; text-wrap: balance; line-height: 1.3; }
.lb-loading { display: flex; align-items: center; justify-content: center; gap: .7em; padding: 1.2em; color: var(--text-dim); }
.lb-loading i { width: 1.4em; height: 1.4em; border-radius: 50%; border: .2em solid var(--yellow); border-right-color: transparent; animation: spin .8s linear infinite; }
.short .lb-me-badge { width: 3.4em !important; height: 3.4em !important; } .short .lb-body { max-height: 38cqh; }
.portrait #scr-result.is-ranked .mr-ledger { font-size: 1.25em; }

/* scrollable modal bodies must accept touch panning (the page itself is touch-action: none) */
.modal-body { touch-action: pan-y; }
.short .set-body > .set-hint { display: none; }

/* ranked match result: stats + roast + MMR panel + rewards + buttons must all fit; drop the least useful blocks on low stages */
@container stage (max-height: 860px) { .landscape #scr-result.is-ranked .mr-stats { display: none; } }
@container stage (max-height: 640px) { .landscape #scr-result.is-ranked .mr-roast { display: none; } .landscape #scr-result.is-ranked .mr-title { font-size: 2.4em; } }
.short #scr-result.is-ranked .mr-roast { display: none; }

/* season champion crown icon (ui/crownIcon.js; nameplates + leaderboard) */
.crown-ico { display: inline-block; flex: none; width: 1.3em; height: .92em; line-height: 0; filter: drop-shadow(0 .06em 0 #140c22); }
.crown-ico svg { width: 100%; height: 100%; display: block; }
.crown-ico.none { visibility: hidden; }

/* ===== Leaderboard 2.0: podium + season switcher (ui/leaderboard.js) ===== */
[hidden] { display: none !important; }
.lb2-modal { width: min(96%, 36em); height: min(96%, 62em); gap: .55em; padding: 1em 1.1em 1.1em; }
.lb2-modal.lb2-plain { height: auto; width: min(94%, 34em); }
.lb2-head { display: flex; flex-direction: column; align-items: center; gap: .35em; flex: none; }
.lb2-head h2 { font-size: 1.5em; line-height: 1; }
.lb2-switch { display: flex; align-items: center; gap: .6em; width: 100%; justify-content: center; }
.lb2-arrow { flex: none; width: 2.6em; height: 2.6em; min-width: 44px; min-height: 44px; padding: 0; font-size: .8em; display: grid; place-items: center; }
.lb2-arrow svg { width: 1.2em; height: 1.2em; }
.lb2-arrow.dis { opacity: .35; pointer-events: none; filter: grayscale(.6); }
.lb2-sinfo { display: flex; flex-direction: column; align-items: center; gap: .15em; min-width: 11em; }
.lb2-stitle { font-size: 1.35em; line-height: 1.05; color: var(--yellow); text-shadow: 0 .09em 0 var(--ink); letter-spacing: .02em; }
.lb2-ssub { display: flex; align-items: center; gap: .5em; font-size: .8em; color: var(--text-dim); font-weight: 700; min-height: 1.6em; }
.lb2-chip { font-size: .85em; font-weight: 900; letter-spacing: .08em; padding: .15em .65em; border-radius: 2em; border: .12em solid var(--ink); color: var(--ink); text-transform: uppercase; white-space: nowrap; }
.lb2-chip.cur { background: linear-gradient(var(--green), #3fbf63); box-shadow: 0 .1em 0 var(--ink); }
.lb2-chip.fin { background: linear-gradient(#ffe27a, var(--yellow-d)); box-shadow: 0 .1em 0 var(--ink); }
.lb2-dots { display: flex; gap: .35em; margin-top: .1em; }
.lb2-dot { all: unset; box-sizing: border-box; cursor: pointer; min-width: 1.8em; height: 1.5em; padding: 0 .4em; text-align: center; font: 800 .7em/1.4em var(--font-ui); border-radius: 2em; background: rgba(12, 6, 26, .6); color: var(--text-dim); border: .12em solid rgba(255, 255, 255, .12); }
.lb2-dot.on { background: var(--yellow); color: var(--ink); border-color: var(--ink); }
.lb2-dot:focus-visible { outline: .15em solid #fff; }

.lb2-main { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: .5em; }
.lb2-left { flex: none; display: flex; flex-direction: column; gap: .5em; min-height: 0; }
.lb2-listwrap { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: .3em; }
.lb2-me { display: flex; align-items: center; gap: .6em; background: rgba(12, 6, 26, .5); border: .12em solid var(--ink); border-radius: 1em; padding: .25em .7em .25em .5em; flex: none; }
.lb2-me-badge { flex: none; width: 3.4em !important; height: 3.4em !important; filter: drop-shadow(0 .2em .2em rgba(0, 0, 0, .4)); }
.lb2-me-main { min-width: 0; flex: 1; display: flex; flex-direction: column; line-height: 1.15; }
.lb2-me-h { font-size: .65em; letter-spacing: .1em; color: var(--text-dim); font-weight: 800; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb2-me-t { font-size: 1.1em; color: var(--yellow); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb2-me-s { font-size: .78em; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb2-me-rank { flex: none; font-size: 1.4em; color: #fff; text-shadow: 0 .08em 0 var(--ink); background: var(--purple-d); border: .09em solid var(--ink); border-radius: .5em; padding: .05em .45em; }

/* podium */
.lb2-podium { flex: none; position: relative; min-height: 0; }
.lb2-podrow { flex: none; position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: .35em; padding: .2em .1em 0; isolation: isolate; border-bottom: .22em solid var(--ink); }
.lb2-shine { position: absolute; left: 50%; top: 18%; width: 17em; height: 17em; margin: -8.5em 0 0 -8.5em; z-index: -1; pointer-events: none; border-radius: 50%;
    background: repeating-conic-gradient(from 0deg, rgba(255, 226, 122, .2) 0 9deg, transparent 9deg 24deg);
    -webkit-mask: radial-gradient(circle, #000 18%, transparent 68%); mask: radial-gradient(circle, #000 18%, transparent 68%); animation: lb2spin 22s linear infinite; }
.lb2-podrow.past .lb2-shine { opacity: .55; }
@keyframes lb2spin { to { transform: rotate(360deg); } }
.lb2-pod { position: relative; display: flex; flex-direction: column; align-items: center; min-width: 0; --g: #C9D4E6; --gd: #6b7894; }
.lb2-pod.c1 { --g: #FFD23F; --gd: #c4880b; } .lb2-pod.c3 { --g: #E0904F; --gd: #8a4c1c; }
.lb2-crown { width: 3em; height: 2.45em; margin-bottom: -.75em; position: relative; z-index: 2; filter: drop-shadow(0 .12em 0 rgba(0, 0, 0, .35)); transform-origin: 50% 100%; }
.lb2-crown svg { width: 100%; height: 100%; display: block; overflow: visible; }
.lb2-pod.p1 .lb2-crown { width: 4em; height: 3.26em; margin-bottom: -.9em; }
.lb2-avwrap { position: relative; z-index: 1; }
.lb2-av { width: 4.2em; height: 4.2em; border-radius: 50%; border: .2em solid var(--ink); display: grid; place-items: center; overflow: hidden;
    background: radial-gradient(circle at 50% 35%, color-mix(in srgb, var(--g) 70%, #fff) 0, var(--g) 38%, var(--gd) 100%);
    box-shadow: 0 .18em 0 var(--ink), 0 0 1.1em color-mix(in srgb, var(--g) 55%, transparent), inset 0 -.25em .4em rgba(0, 0, 0, .25); }
.lb2-pod.p1 .lb2-av { width: 5.4em; height: 5.4em; }
.lb2-av.ghost { background: rgba(12, 6, 26, .55); box-shadow: none; border-style: dashed; border-color: rgba(255, 255, 255, .25); color: var(--text-dim); }
.lb2-bot { width: 150%; height: 150%; max-width: none; object-fit: contain; flex: none; transform: translate(-4%, -13%); opacity: 0; transition: opacity .2s; filter: drop-shadow(0 .1em 0 rgba(0, 0, 0, .3)); }
.lb2-bot.ready { opacity: 1; }
.lb2-youtag { position: absolute; left: 50%; bottom: -.5em; transform: translateX(-50%); font-size: .7em; padding: .05em .6em; border-radius: 2em; background: var(--yellow); color: var(--ink); border: .12em solid var(--ink); }
.lb2-pname { width: 100%; text-align: center; font-weight: 800; font-size: .82em; margin-top: .55em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 .15em; text-shadow: 0 .08em 0 var(--ink); }
.lb2-pod.p1 .lb2-pname { font-size: .95em; color: #fff3b0; }
.lb2-pscore { display: flex; align-items: center; justify-content: center; gap: .25em; font-size: .85em; color: #fff; margin: .1em 0 .3em; }
.lb2-pscore .lb-tier { width: 1.5em; height: 1.5em; }
.lb2-block { position: relative; width: 100%; display: grid; place-items: start center; padding-top: .2em; border: .2em solid var(--ink); border-bottom: 0; border-radius: .7em .7em 0 0;
    background: linear-gradient(180deg, color-mix(in srgb, var(--g) 80%, #fff) 0, var(--g) 30%, var(--gd) 100%); box-shadow: inset 0 .2em 0 rgba(255, 255, 255, .45), inset 0 -.4em .5em rgba(0, 0, 0, .18); height: 2.6em; }
.lb2-pod.p1 .lb2-block { height: 5em; } .lb2-pod.p2 .lb2-block { height: 3.6em; } .lb2-pod.p3 .lb2-block { height: 2.6em; }
.lb2-block b { font-size: 1.9em; line-height: 1; color: #fff; -webkit-text-stroke: .08em var(--ink); paint-order: stroke fill; text-shadow: 0 .08em 0 var(--ink); }
.lb2-pod.p1 .lb2-block b { font-size: 2.6em; }
.lb2-block i { position: absolute; right: .35em; top: .2em; font-style: normal; font-weight: 900; font-size: .9em; color: var(--ink); }
.lb2-pod.empty { opacity: .55; }
.lb2-pod.you .lb2-av { border-color: #fff; box-shadow: 0 .18em 0 var(--ink), 0 0 0 .18em var(--yellow), 0 0 1.2em var(--yellow); }
.lb2-pod.skeleton .lb2-pname { height: .9em; width: 70%; border-radius: 1em; margin-top: .6em; }
.lb2-pod.skeleton .lb2-block { background: rgba(255, 255, 255, .08); box-shadow: none; }
.lb2-pod.skeleton .lb2-pname, .lb2-row.sk .lb2-rank, .lb2-row.sk .lb2-name { background: rgba(255, 255, 255, .09); animation: lb2pulse 1.1s ease-in-out infinite alternate; }
.lb2-row.sk { height: 2.2em; } .lb2-row.sk .lb2-rank { height: 1em; width: 2.2em; border-radius: 1em; } .lb2-row.sk .lb2-name { height: 1em; border-radius: 1em; }
@keyframes lb2pulse { to { opacity: .45; } }

/* entrance: seats rise 3rd, 2nd, 1st (<= .8 s), avatars drop in, crowns pop */
.lb2-podrow.enter .lb2-block { animation: lb2rise .42s var(--ease-out) both; transform-origin: 50% 100%; }
.lb2-podrow.enter .lb2-pod.p3 .lb2-block { animation-delay: 0s; } .lb2-podrow.enter .lb2-pod.p2 .lb2-block { animation-delay: .08s; } .lb2-podrow.enter .lb2-pod.p1 .lb2-block { animation-delay: .16s; }
.lb2-podrow.enter .lb2-avwrap, .lb2-podrow.enter .lb2-pname, .lb2-podrow.enter .lb2-pscore { animation: lb2drop .4s var(--ease-spring) both; animation-delay: calc(.2s + (4 - var(--seat)) * .05s); }
.lb2-podrow.enter .lb2-pod.p1 .lb2-avwrap, .lb2-podrow.enter .lb2-pod.p1 .lb2-pname, .lb2-podrow.enter .lb2-pod.p1 .lb2-pscore { animation-delay: .3s; }
.lb2-podrow.enter .lb2-crown { animation: lb2crown .4s var(--ease-spring) both; animation-delay: .4s; }
.lb2-podrow.enter .lb2-pod.p1 .lb2-crown { animation: lb2crown .4s var(--ease-spring) both, lb2bob 2.4s ease-in-out .9s infinite; animation-delay: .4s, .9s; }
@keyframes lb2rise { from { transform: scaleY(0); } to { transform: none; } }
@keyframes lb2drop { from { opacity: 0; transform: translateY(-.9em) scale(.85); } to { opacity: 1; transform: none; } }
@keyframes lb2crown { from { opacity: 0; transform: translateY(-.8em) rotate(-18deg) scale(.4); } to { opacity: 1; transform: none; } }
@keyframes lb2bob { 50% { transform: translateY(-.15em) rotate(2deg); } }
.lb2-conf { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 3; }
.lb2-conf i { position: absolute; top: 12%; height: .5em; border-radius: .1em; opacity: 0; animation: lb2conf 1.6s ease-out forwards; animation-delay: var(--dl); }
@keyframes lb2conf { 0% { opacity: 1; transform: translate(0, 0) rotate(0); } 100% { opacity: 0; transform: translate(var(--dx), 11em) rotate(var(--dr)); } }

/* list */
.lb2-list { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; gap: .25em; overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; touch-action: pan-y; padding: .1em .3em .1em 0; scrollbar-width: thin; outline: none; }
.lb2-list:focus-visible { box-shadow: 0 0 0 .15em rgba(255, 255, 255, .5); border-radius: .5em; }
.lb2-list::-webkit-scrollbar { width: .55em; } .lb2-list::-webkit-scrollbar-track { background: rgba(12, 6, 26, .55); border-radius: 1em; }
.lb2-list::-webkit-scrollbar-thumb { background: linear-gradient(90deg, var(--purple), var(--purple-d)); border: .1em solid var(--ink); border-radius: 1em; }
.lb2-row { flex: none; display: flex; align-items: center; gap: .55em; padding: .22em .7em .22em .55em; background: rgba(12, 6, 26, .45); border-radius: .7em; border: .1em solid rgba(255, 255, 255, .06); }
.lb2-row:nth-child(even) { background: rgba(12, 6, 26, .3); }
.lb2-row.you { border-color: var(--yellow); background: linear-gradient(90deg, rgba(255, 210, 63, .26), rgba(255, 210, 63, .1)); box-shadow: 0 0 .8em rgba(255, 210, 63, .25); }
.lb2-rank { width: 2.9em; flex: none; color: var(--text-dim); font-size: .9em; white-space: nowrap; }
.lb2-row.you .lb2-rank { color: var(--yellow); }
.lb2-row .lb-tier { width: 1.8em; height: 1.8em; }
.lb2-name { flex: 1; min-width: 0; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb2-score { flex: none; color: #fff; font-size: .95em; }
.lb2-pin { flex: none; border-top: .12em dashed rgba(255, 255, 255, .25); padding-top: .3em; }
.lb2-pin .lb2-row { box-shadow: 0 0 .8em rgba(255, 210, 63, .3), 0 .15em 0 var(--ink); }
.lb2-note { text-align: center; color: var(--text-dim); padding: 1em .5em; text-wrap: balance; line-height: 1.3; }
.lb2-note.small { padding: .6em; font-size: .85em; }
.lb2-plain .lb2-listwrap { flex: none; align-items: stretch; }

/* landscape: podium left, list right */
.landscape .lb2-modal:not(.lb2-plain) { width: min(96%, 70em); height: min(96%, 38em); }
.landscape .lb2-main { flex-direction: row; gap: .9em; }
.landscape .lb2-left { flex: 1 1 0; min-width: 0; justify-content: flex-start; gap: .5em; }
.landscape .lb2-listwrap { flex: 1 1 0; min-width: 0; }
.landscape .lb2-head { flex-direction: row; justify-content: space-between; align-items: center; padding-right: 2em; gap: 1em; }
.landscape .lb2-head h2 { text-align: left; flex: none; }
.landscape .lb2-switch { width: auto; }
.landscape .lb2-podium { font-size: 1.5em; flex: 1 1 auto; display: flex; flex-direction: column; justify-content: flex-end; }
.short.landscape .lb2-podium { font-size: 1.2em; }
.short .lb2-modal { padding: .7em .9em .8em; gap: .35em; }
.short .lb2-head h2 { font-size: 1.25em; } .short .lb2-stitle { font-size: 1.15em; }
.short .lb2-me-badge { width: 2.8em !important; height: 2.8em !important; }
.short .lb2-av { width: 3.4em; height: 3.4em; } .short .lb2-pod.p1 .lb2-av { width: 4.4em; height: 4.4em; }
.short .lb2-crown { width: 2.4em; height: 1.96em; margin-bottom: -.6em; } .short .lb2-pod.p1 .lb2-crown { width: 3.1em; height: 2.53em; }
.short .lb2-pod.p1 .lb2-block { height: 3.8em; } .short .lb2-pod.p2 .lb2-block { height: 2.7em; } .short .lb2-pod.p3 .lb2-block { height: 2em; }
.short .lb2-row { padding-top: .12em; padding-bottom: .12em; }
@media (max-width: 380px) and (orientation: portrait) { .lb2-av { width: 3.7em; height: 3.7em; } .lb2-pod.p1 .lb2-av { width: 4.8em; height: 4.8em; } }
@media (prefers-reduced-motion: reduce) {
    .lb2-shine, .lb2-crown, .lb2-podrow.enter *, .lb2-conf i, .lb2-row.sk .lb2-rank, .lb2-row.sk .lb2-name { animation: none !important; }
    .lb2-conf { display: none; }
}

/* ===== Ranks overview (ladder modal) ===== */
.rk-ranks { margin-top: .45em; font-size: .85em; padding: .3em .8em; gap: .4em; }
.rk-ranks .ico { width: 1.2em; height: 1.2em; display: inline-flex; } .rk-ranks .ico svg { width: 100%; height: 100%; }
.portrait .rk-ranks { margin-top: .3em; }
.rl-modal { width: min(94%, 34em); max-height: 94%; font-size: clamp(12px, 2.3cqmin, 22px); }
.portrait .rl-modal { font-size: clamp(12px, min(3.5cqw, 2cqh), 22px); }
.landscape .rl-modal { width: min(94%, 60em); }
.rl-body { position: relative; display: flex; flex-direction: column; gap: .8em; padding-right: .3em; scroll-behavior: auto; outline: none; }
.rl-champ { display: flex; flex-direction: column; align-items: center; gap: .35em; padding: .6em .8em; border: .15em solid var(--ink); border-radius: 1em;
    background: radial-gradient(120% 140% at 50% 0%, rgba(255, 210, 63, .22), rgba(12, 6, 26, .55) 70%); box-shadow: 0 .2em 0 var(--ink); }
.rl-champ-h { font-family: var(--font-display); font-size: 1.1em; letter-spacing: .1em; color: var(--yellow); text-shadow: 0 .08em 0 var(--ink); max-width: 100%; }
.rl-crowns { display: flex; justify-content: center; align-items: flex-end; gap: 1.2em; }
.rl-crown { display: flex; flex-direction: column; align-items: center; gap: .1em; }
.rl-crown-ico { display: block; width: 3.4em; filter: drop-shadow(0 .15em 0 var(--ink)); } .rl-crown-ico svg { display: block; width: 100%; height: auto; }
.rl-crown.p1 .rl-crown-ico { width: 4.6em; } .rl-crown.p2 .rl-crown-ico { width: 3.8em; }
.rl-crown b { font-size: .95em; color: #fff; text-shadow: 0 .06em 0 var(--ink); }
.rl-champ-t { text-align: center; font-size: .85em; color: var(--text-dim); font-weight: 700; line-height: 1.25; }
.rl-list { display: flex; flex-direction: column; gap: .55em; }
.landscape .rl-list { display: block; columns: 2; column-gap: .7em; }
.landscape .rl-row { break-inside: avoid; margin-bottom: .55em; }
.rl-row { position: relative; display: flex; align-items: center; gap: .8em; padding: .55em .8em; border: .15em solid var(--ink); border-radius: 1em; box-shadow: 0 .2em 0 var(--ink);
    background: linear-gradient(100deg, color-mix(in srgb, var(--tc) 24%, #1d0f33), rgba(12, 6, 26, .6) 65%); }
.rl-row.locked { filter: saturate(.35) brightness(.72); }
.rl-row.locked .rl-bw { opacity: .7; }
.rl-row.me { border-color: var(--tc); box-shadow: 0 .2em 0 var(--ink), 0 0 0 .14em var(--ink), 0 0 1.1em color-mix(in srgb, var(--tc) 70%, transparent); animation: rlGlow 2.4s ease-in-out infinite; }
@keyframes rlGlow { 50% { box-shadow: 0 .2em 0 var(--ink), 0 0 0 .14em var(--ink), 0 0 1.8em var(--tc); } }
.rl-bw { flex: none; width: 4.6em; height: 4.6em; } .rl-bw canvas { width: 100% !important; height: 100% !important; filter: drop-shadow(0 .2em .25em rgba(0, 0, 0, .5)); }
.rl-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .2em; }
.rl-name { font-size: 1.35em; line-height: 1.1; color: var(--tc); -webkit-text-stroke: .07em var(--ink); paint-order: stroke fill; text-shadow: 0 .08em 0 var(--ink); padding-bottom: .06em; }
.rl-range { font-size: .85em; font-weight: 800; color: var(--text-dim); }
.rl-divs { display: flex; gap: .35em; }
.rl-div { flex: 1; display: flex; align-items: baseline; justify-content: center; gap: .3em; padding: .08em .3em; border-radius: .6em; border: .12em solid var(--ink); background: rgba(12, 6, 26, .65); color: var(--text-dim); min-width: 0; }
.rl-div b { font-size: .9em; } .rl-div span { font-size: .7em; font-weight: 800; }
.rl-div.on { color: #fff; background: color-mix(in srgb, var(--tc) 45%, #0c0618); }
.rl-div.cur { color: var(--ink); background: var(--tc); box-shadow: 0 0 .6em var(--tc); }
.rl-reward { display: flex; align-items: center; gap: .4em; font-size: .78em; font-weight: 800; color: var(--text-dim); min-width: 0; }
.rl-reward.none { opacity: .6; }
.rl-you { display: flex; align-items: center; gap: .6em; margin-top: .15em; min-width: 0; }
.rl-tag { flex: none; padding: .05em .55em .1em; border-radius: 1em; background: var(--yellow); color: var(--ink); border: .12em solid var(--ink); font-size: .9em; letter-spacing: .06em; box-shadow: 0 .1em 0 var(--ink); }
.rl-prog { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .1em; }
.rl-bar { height: .7em; background: #0c0618; border: .12em solid var(--ink); border-radius: 1em; overflow: hidden; }
.rl-bar i { display: block; height: 100%; border-radius: 1em; background: var(--tc); }
.rl-tonext, .rl-yoummr { font-size: .78em; font-weight: 800; color: #fff; }
.short .rl-modal { padding: .6em .9em .7em; gap: .4em; }
.short .rl-bw { width: 3.6em; height: 3.6em; } .short .rl-crown-ico { width: 2.6em; } .short .rl-crown.p1 .rl-crown-ico { width: 3.4em; } .short .rl-crown.p2 .rl-crown-ico { width: 2.9em; }
@media (prefers-reduced-motion: reduce) { .rl-row.me { animation: none; } }
.rl-modal h2 { line-height: 1.15; padding-bottom: .15em; } .short .rl-modal { gap: .6em; }
