/* One ranking language: four rows, category palette, game-specific records. */
.arcade-summary-screen{--rank-bg:#f0e8fb;--rank-paper:#fbf7ff;--rank-accent:#7548b6;--rank-ink:#4b2b72;--rank-muted:#8866a5;--rank-line:#ddcbef;--rank-soft:#b896e9}
.arcade-summary-screen:has([data-rank-theme=romance]){--rank-bg:#fbe9e6;--rank-paper:#fff8f5;--rank-accent:#b75d70;--rank-ink:#713d4b;--rank-muted:#9c6874;--rank-line:#eac8cb;--rank-soft:#dfa1af}
.arcade-summary-screen:has([data-rank-theme=adult]){--rank-bg:#f8e7ee;--rank-paper:#fff6fa;--rank-accent:#ad527d;--rank-ink:#71364f;--rank-muted:#95637b;--rank-line:#e8c4d4;--rank-soft:#d995b7}
.arcade-summary-screen:has([data-rank-theme=lounge]){--rank-bg:#e2f1e9;--rank-paper:#f6fcf8;--rank-accent:#427f69;--rank-ink:#315d4f;--rank-muted:#628575;--rank-line:#c2dbcd;--rank-soft:#8dbda4}
.arcade-summary-screen:has([data-rank-theme=play]){--rank-bg:#fff0df;--rank-paper:#fff9f0;--rank-accent:#b36b32;--rank-ink:#754a2e;--rank-muted:#977455;--rank-line:#ead0b4;--rank-soft:#e2b17d}
.arcade-summary-screen#arcadeRoot,.arcade-summary-screen#roomArcadePlay,#player.game-surface.game-surface-ranking{background:var(--rank-bg,#f0e8fb);color:var(--rank-ink,#4b2b72);overflow:hidden;overscroll-behavior:none}
#player.game-surface.game-surface-ranking{--rank-bg:#f0e8fb;--rank-ink:#4b2b72;padding:18px 20px;scrollbar-gutter:auto}
#player.game-surface.game-surface-ranking:has([data-rank-theme=romance]){--rank-bg:#fbe9e6;--rank-ink:#713d4b}
#player.game-surface.game-surface-ranking:has([data-rank-theme=adult]){--rank-bg:#f8e7ee;--rank-ink:#71364f}
#player.game-surface.game-surface-ranking #playContent{height:100%;min-height:0;max-width:620px;display:block;padding:0}
#player.game-surface.game-surface-ranking #playContent>.rank-result{height:100%;margin:0;padding:0;background:transparent}
#player.game-surface.game-surface-ranking #playContent>:not(.rank-result){display:none!important}
#player.game-surface.game-surface-ranking>.close{position:absolute;right:14px;top:10px;width:32px;height:32px;font-size:24px;background:none;border:0;color:var(--rank-ink);box-shadow:none}
.arcade-summary-screen#arcadeRoot,.arcade-summary-screen#roomArcadePlay,.rank-result.arcade-summary-screen{box-sizing:border-box;display:flex;flex-direction:column;gap:8px;align-items:stretch;text-align:left}
.arcade-summary-screen .arcade-summary-brand{flex:none;font-size:9px;line-height:16px;height:16px;letter-spacing:1.7px;color:var(--rank-muted);text-align:center;margin:0 auto}
.arcade-summary-screen .arcade-summary-head{display:block;flex:none;text-align:left;border-bottom:1px solid var(--rank-line);padding:0 0 10px;margin:0 auto}
.arcade-summary-screen .arcade-summary-head h1{display:inline;font-size:24px;font-weight:850;color:var(--rank-ink);line-height:1.3;margin:0;letter-spacing:-.04em}
.arcade-summary-screen .arcade-summary-head p{display:inline;margin:0 0 0 10px;font-size:11px;line-height:1.3;color:var(--rank-muted)}
.arcade-summary-screen .arcade-summary-hero{flex:1;min-height:36px;max-height:none;margin:0 auto;gap:16px;display:flex;align-items:center;justify-content:center}
.arcade-summary-screen .arcade-summary-hero svg{width:64px;height:64px;flex:none}
.arcade-summary-screen .arcade-summary-hero>strong{font-size:clamp(22px,5vw,32px);color:var(--rank-accent);min-width:0;max-width:70%;line-height:1.25;overflow-wrap:anywhere}
.arcade-summary-screen .arcade-summary-hero small{font-size:13px;color:var(--rank-muted);line-height:1.3;margin-top:4px}
.arcade-summary-screen .arcade-summary-rows{flex:none;display:grid;gap:7px;margin:0 auto;padding:0;list-style:none;width:100%}
.arcade-summary-screen .arcade-summary-rows>li,.lightning-room-mode .arcade-summary-screen .arcade-summary-rows>li{display:grid;grid-template-columns:25px minmax(0,1fr) minmax(64px,auto);align-items:center;gap:10px;min-height:58px;margin:0;padding:9px 12px;box-sizing:border-box;border:1px solid var(--rank-line);border-radius:16px;background:var(--rank-paper);color:var(--rank-ink);outline:0;box-shadow:none;animation:rank-row-arrive .48s cubic-bezier(.2,.8,.2,1) both;animation-delay:calc(var(--rank-delay,0)*70ms)}
.arcade-summary-screen .arcade-summary-rows>li.winner,.lightning-room-mode .arcade-summary-screen .arcade-summary-rows>li.winner{background:var(--rank-accent);color:var(--rank-paper);border-color:var(--rank-accent)}
.arcade-summary-screen .arcade-summary-rows>li>b,.lightning-room-mode .arcade-summary-screen .arcade-summary-rows>li>b{min-width:0;font-size:21px;line-height:1.2;color:inherit;text-align:center}
.arcade-summary-screen .arcade-summary-rows>li>span,.lightning-room-mode .arcade-summary-screen .arcade-summary-rows>li>span{font-size:14px;line-height:1.25;color:inherit;min-width:0;overflow-wrap:anywhere;text-align:left}
.arcade-summary-screen .arcade-summary-rows small{font-size:10px;line-height:1.25;margin-top:4px;display:block;opacity:.78;color:inherit}
.arcade-summary-screen .arcade-summary-rows>li>strong,.lightning-room-mode .arcade-summary-screen .arcade-summary-rows>li>strong{font-size:20px;line-height:1.2;font-variant-numeric:tabular-nums;text-align:right;color:inherit;overflow-wrap:anywhere;white-space:normal;max-width:155px}
.arcade-summary-screen .arcade-summary-pages{order:4;flex:none;display:flex;justify-content:center;align-items:center;gap:18px;font-size:11px;color:var(--rank-muted);margin:0 auto}
.arcade-summary-screen .arcade-summary-pages button{min-height:32px;padding:4px 12px;border:1px solid var(--rank-line);border-radius:11px;background:var(--rank-paper);color:var(--rank-accent);font-size:11px}
.arcade-summary-screen .rank-outcome{order:5;flex:none;text-align:center;color:var(--rank-ink);font-size:13px;line-height:1.35;margin:0 auto}
.arcade-summary-screen .rank-outcome strong{font-size:14px;line-height:1.35;display:block}
.arcade-summary-screen .rank-outcome p{font-size:10px;line-height:1.4;margin:3px 0 0;color:var(--rank-muted)}
.arcade-summary-screen .arcade-summary-actions{order:6;flex:none;display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:4px auto 0;width:100%}
.arcade-summary-screen .arcade-summary-actions>button,#player.game-surface .rank-result .arcade-summary-actions>button{box-sizing:border-box;min-height:48px;margin:0;padding:9px;border:1px solid var(--rank-line)!important;border-radius:16px;background:var(--rank-paper)!important;color:var(--rank-accent)!important;font-size:14px;font-weight:750;line-height:1.3;box-shadow:none!important;white-space:normal}
.arcade-summary-screen .arcade-summary-actions>button:first-of-type,#player.game-surface .rank-result .arcade-summary-actions>button:first-of-type{background:var(--rank-accent)!important;color:var(--rank-paper)!important;border-color:var(--rank-accent)!important}
.arcade-summary-screen .arcade-summary-actions>p{font-size:11px;color:var(--rank-muted);margin:0;align-self:center}
.arcade-summary-screen .arcade-summary-note{order:7;font-size:10px;color:var(--rank-muted);line-height:1.3;margin:0 auto}
.arcade-summary-screen .arcade-reveal-skip{position:absolute;right:20px;top:42px;min-height:26px!important;width:auto;padding:0 4px;margin:0;font-size:10px;color:var(--rank-muted);border:0;background:var(--rank-bg);text-decoration:underline;z-index:2}
#player.game-surface .rank-result>details.game-rules{position:absolute;top:8px;left:14px;width:auto;margin:0}
#player.game-surface .rank-result>details.game-rules summary{font-size:9px;padding:4px;color:var(--rank-muted)}
.arcade-summary-screen [hidden]{display:none!important}
@media(max-height:700px){.arcade-summary-screen#arcadeRoot,.arcade-summary-screen#roomArcadePlay,#player.game-surface.game-surface-ranking{padding:14px 16px}.arcade-summary-screen#arcadeRoot,.arcade-summary-screen#roomArcadePlay,.rank-result.arcade-summary-screen{gap:6px}.arcade-summary-screen .arcade-summary-head{padding-bottom:7px}.arcade-summary-screen .arcade-summary-head h1{font-size:21px}.arcade-summary-screen .arcade-summary-head p{font-size:10px}.arcade-summary-screen .arcade-summary-hero svg{width:48px;height:48px}.arcade-summary-screen .arcade-summary-hero>strong{font-size:22px}.arcade-summary-screen .arcade-summary-rows>li,.lightning-room-mode .arcade-summary-screen .arcade-summary-rows>li{min-height:51px;padding:7px 10px;gap:8px}.arcade-summary-screen .arcade-summary-rows>li>span{font-size:13px}.arcade-summary-screen .arcade-summary-rows>li>strong{font-size:18px}.arcade-summary-screen .arcade-summary-actions>button,#player.game-surface .rank-result .arcade-summary-actions>button{min-height:44px;font-size:13px}.arcade-summary-screen .rank-outcome strong{font-size:12px}}
@keyframes rank-row-arrive{from{transform:translateY(22px);opacity:0}to{transform:translateY(0);opacity:1}}
@media(prefers-reduced-motion:reduce){.arcade-summary-screen *{animation:none!important;transition:none!important}}
/* Override the live game's backdrop and legacy global header layout. */
#player.unified-player.game-surface.game-surface-ranking[data-game-room]{background:var(--rank-bg,#f0e8fb)!important;color:var(--rank-ink,#4b2b72);overflow:hidden!important}
.arcade-summary-screen>*{width:min(100%,620px);box-sizing:border-box;margin-inline:auto}
#player.game-surface .rank-result .arcade-summary-head{display:block;grid-template-columns:none;min-height:0;text-align:left;padding:0 0 9px;height:auto;align-items:initial;gap:0}
#player.game-surface .rank-result .arcade-summary-head h1{font-size:24px;display:inline;margin:0;line-height:1.3;color:var(--rank-ink)}
#player.game-surface .rank-result .arcade-summary-head p{font-size:11px;display:inline;margin:0 0 0 10px;line-height:1.3;color:var(--rank-muted)}
.arcade-summary-screen .arcade-summary-hero>strong small{display:block!important;font-size:13px!important;line-height:1.3;color:var(--rank-muted);margin:5px 0 0}
#player.unified-player.game-surface.game-surface-ranking>.close{position:absolute;right:10px;top:7px;width:30px;height:30px;padding:0;line-height:1;font-size:23px;border:0;border-radius:50%;background:transparent;box-shadow:none;color:var(--rank-ink)}
@media(max-height:700px){#player.game-surface .rank-result .arcade-summary-head h1{font-size:21px}#player.game-surface .rank-result .arcade-summary-head p{font-size:10px}}
