/* Same ordered stylesheets as ui-demo.html, not an approximation of its skin. */
@import url('../ui-demo/shared.css');
@import url('../ui-demo/lobby.css');
@import url('../ui-demo/shop.css');
@import url('../ui-demo/match.css');
@import url('../ui-demo/motion.css');
@import url('../ui-demo/theme.css');
@import url('../ui-demo/match-clean.css');
@import url('../ui-demo/serve-reference.css');
@import url('../ui-demo/reference-system.css');
@import url('../ui-demo/polish.css');
@import url('../ui-demo/locker.css');
@import url('../ui-demo/visual-pass.css');
@import url('../ui-demo/community-layout.css');
@import url('./mod-menu.css');
@import url('./global-chat.css');

/* Controller nodes stay mounted for existing account/settings/network handlers,
   but are not a second UI. Only production-specific additions are styled here. */
body.live-ui #main-menu,body.live-ui #ability-menu,body.live-ui #menu-toggle{display:none!important}
.live-shell{position:fixed;inset:0;z-index:30;isolation:isolate}
.live-shell[hidden],.live-match[hidden]{display:none!important}
.live-shell.has-celebration{--celebration-height:36px}
.live-shell.has-celebration>.demo-shell{margin-top:var(--celebration-height);height:calc(100dvh - var(--celebration-height))}
.legend-celebration{position:absolute;inset:0 0 auto;z-index:3;min-height:36px;height:36px;padding:5px 12px;display:flex;align-items:center;justify-content:center;gap:9px;box-sizing:border-box;background:linear-gradient(110deg,#594025,#8b682d 50%,#594025);border-top:1px solid #d8b869;border-bottom:2px solid #a88b4d;box-shadow:0 2px 9px #0005;color:#fff0ca;font:900 12px/1.25 var(--sport-type);text-align:center;text-shadow:0 1px 2px #251b12;letter-spacing:.25px}
.legend-celebration[hidden]{display:none!important}.legend-celebration-icon{display:grid;place-items:center;color:#f3d67e;flex:none}.legend-celebration strong{font:inherit}
@media(max-width:570px){.live-shell.has-celebration{--celebration-height:44px}.legend-celebration{height:44px;font-size:10px;padding:5px 9px;letter-spacing:0}}
.live-shell .demo-wordmark{border:0;background:none;padding:0;box-shadow:none}
.live-shell .demo-shell{z-index:1}
.live-shell #demo-world,.live-shell .world-wash{position:absolute}
.live-shell .demo-header,.live-shell .demo-dock{position:relative}
.live-shell nav{background:none;border:0;border-radius:0;padding:0;box-shadow:none}
.live-shell .shop-tabs{margin:0}
.live-shell .demo-dock nav{inset:auto;position:relative}
.live-shell nav button{width:auto;height:auto;overflow:visible}
.live-shell .demo-dock nav button{min-height:70px}
.live-shell .demo-dock nav button:before{content:none}
.live-shell .demo-dock nav button>span{position:static}
.live-shell .live-map-button{cursor:pointer}
.live-shell .lobby-rank-title>div{min-width:0}
.live-shell .lobby-rank-title strong{min-width:0}
.live-shell .lobby-rank[data-placing=true] .lobby-rank-title strong{font-size:clamp(17px,1.5vw,25px);white-space:normal}
.live-shell .lobby-rank-title strong span{font-size:12px}
.live-shell .lobby-rank-title small{white-space:normal}
.live-shell .lobby-poll-options .live-poll-option{position:relative;overflow:hidden;display:flex;align-items:center;justify-content:space-between;gap:6px;text-align:left}
.live-shell .live-poll-option>span{position:relative;z-index:1;font-size:inherit;font-weight:900;color:inherit}
.live-shell .live-poll-option>small{position:relative;z-index:1;font-size:9px;flex:none}
.live-shell .live-poll-option>i{position:absolute;left:0;top:0;bottom:0;width:var(--vote-percent,0%);background:#94b77d18;pointer-events:none}
.live-shell .live-poll-option[aria-pressed=true]{border-color:#8caa6e;background:#34472e}
.live-resume{width:100%;margin-top:5px;font-size:11px;min-height:28px}
#live-dialog-host .dialog-scrim{z-index:70}
#live-dialog-host .dialog-close{padding:0}
.demo-toast{z-index:110}
.live-update-ready{position:fixed;z-index:115;top:66px;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:12px;padding:8px 12px;max-width:90vw;border:1px solid #ad9358;border-radius:5px;background:#192b38;color:#efe5cb;box-shadow:0 3px 12px #0005;font:700 12px var(--sport-type)}
.live-update-ready button{padding:6px 10px;border:1px solid #bda568;border-radius:4px;background:#765c31;color:#fff;font:inherit}.live-update-ready button:disabled{opacity:.65;cursor:default}
.is-match .live-update-ready,.dialog-open .live-update-ready{display:none}
/* Existing live-only dialogs retain all capabilities and share the theme. */
.live-ui .friends-overlay,.live-ui .settings-overlay,.live-ui .feedback-overlay,.live-ui .identity-overlay,.live-ui .leaderboard-overlay,.live-ui .ranked-boost-modal,.live-ui .format-picker{z-index:80}
.live-ui .friends-shell,.live-ui .settings-shell,.live-ui .leaderboard-card,.live-ui .identity-card,.live-ui .ranked-boost-card{background:linear-gradient(140deg,#25313bef,#172029f5);border:2px solid #667680;border-radius:6px;color:#f5f6f8;box-shadow:0 8px 25px #0007}
.live-ui .friends-shell>header,.live-ui .settings-head,.live-ui .leaderboard-card>header{background:linear-gradient(115deg,#70542e,#a08043);border-bottom:1px solid #baa46b}
.live-ui .settings-head{position:static;inset:auto;width:auto;height:auto}
.live-ui .friends-shell button,.live-ui .settings-shell button,.live-ui .leaderboard-card button,.live-ui .identity-card button{border-radius:5px;text-shadow:var(--vl-outline);font-family:var(--sport-type);box-shadow:inset 0 1px #ffffff25,0 2px #10161d}
.live-ui .live-save-slot{margin:20px 0}.live-ui .live-save-slot details{padding:14px;border:1px solid #607382;border-radius:5px;background:#192731;color:#fff}.live-ui .live-save-slot input{display:block;max-width:100%;padding:9px;margin:8px 0;color:#fff;background:#17232f;border:1px solid #81919e}.live-ui .live-map-slot select{font:inherit;color:#fff;background:#192731;border:1px solid #81919e;padding:12px;width:100%}
/* The exact demo HUD classes read the actual match. No demo controls/fixtures. */
.live-match{position:fixed;inset:0;z-index:7;pointer-events:none;width:100%;height:100%;margin:0}
.live-match button{pointer-events:auto}
.is-lobby .live-match,.is-shop .live-match{display:none!important}
.live-match .match-ability.long-name .match-ability-art,.live-match .match-ability.long-name .match-ability-art img{height:40px}
.live-match .match-ability.long-name .match-ability-copy b{font-size:8px;max-height:18px;overflow:hidden}
.live-match .match-ability.long-name .match-ability-copy small{margin:2px 0}
.live-ui [aria-label="Game paused"]{z-index:85}
.live-ui .broadcast-score,.live-ui #rally-clock,.live-ui #match-point,.live-ui #serve-panel,.live-ui .lower-hud,.live-ui .ability-slots,.live-ui .style-hud,.live-ui .serve-techniques,.live-ui .wallet-chip,.live-ui #play,.live-ui .live-viewers,.live-ui>nav,.live-ui>.brand{display:none!important}
.live-ui #tilt-panel{bottom:150px;z-index:6}
body.in-menu #tilt-panel{display:none}
.live-ui .live-match .match-menu{z-index:2}
.live-ui .live-match .match-ability-art>span:first-child{display:block;width:100%;height:100%}
.live-ui .match-special-heading strong{font:inherit}
.live-ui .match-brand>[hidden]{display:none}
.live-ui .match-stats-overlay,.live-ui #match-over,.live-ui .pause-menu{z-index:85}
.live-ui #match-over .result{background:linear-gradient(#263541,#17232e);border:2px solid #78868d;color:#fff;box-shadow:0 10px 30px #0007}
.live-ui #match-over #winner{font-family:var(--sport-type);text-shadow:var(--vl-outline)}
@media(max-width:540px){.live-shell .demo-dock nav button{min-height:58px}.live-shell .demo-feedback{display:block;font-size:9px;padding:5px}.live-shell .lobby-rank-title strong{font-size:20px}.live-shell .lobby-rank-title strong span{font-size:9px}.live-shell .live-map-button{display:none}}

.live-shell .demo-shell{margin-left:0;width:100%;transition:margin-left .36s cubic-bezier(.2,.8,.2,1),width .36s cubic-bezier(.2,.8,.2,1)}
.chat-open .live-shell .demo-shell{margin-left:300px;width:calc(100% - 300px)}
.global-chat{position:fixed;z-index:55;left:0;top:0;bottom:0;width:300px;display:flex;flex-direction:column;gap:8px;padding:16px 12px 14px;box-sizing:border-box;background:linear-gradient(160deg,#263a48f7,#111f2dfc);border-right:2px solid #73919f;box-shadow:8px 0 24px #0005;color:#eef3f6;transform:translateX(-105%);visibility:hidden;transition:transform .36s cubic-bezier(.2,.8,.2,1),visibility .36s;font:700 12px var(--sport-type)}
.chat-open .global-chat{transform:translateX(0);visibility:visible}
.global-chat header{display:flex;align-items:center;gap:9px;padding:9px 2px 13px;border-bottom:1px solid #688494}.global-chat header>div{flex:1}.global-chat header strong{display:block;font-size:17px;letter-spacing:.5px}.global-chat header small{display:block;margin-top:4px;color:#a6c0cc;font-size:10px}.global-chat button{cursor:pointer;color:#e6eff4;background:#304857;border:1px solid #829aa7;border-radius:4px;padding:6px 10px;font:700 11px var(--sport-type)}.global-chat button:hover{background:#436173}.global-chat button:disabled{opacity:.5;cursor:wait}.global-chat header button{font-size:23px;background:none;border:0;padding:0 5px}
.chat-guidelines{color:#a9becb;font-size:10px;line-height:1.4;margin:0}.chat-messages{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:0 4px 5px 0;scrollbar-color:#698696 #182632}.chat-message{border-bottom:1px solid #48617160;padding:13px 8px;overflow-wrap:anywhere}.chat-message>strong{color:#d3bd8b;font-size:12px}.chat-message>time{float:right;font-size:9px;color:#94aabd;line-height:16px}.chat-message>p{margin:6px 0 0;font-size:12px;line-height:1.55;font-weight:500;white-space:pre-wrap}.chat-message.is-you{border-left:2px solid #91b87d;background:#81af7420}.chat-message>button{font-size:9px;margin-top:5px;padding:2px 5px;background:none;color:#d2b3a1;border-color:#6e6c6a}.chat-empty{color:#a7bdc9;line-height:1.6;text-align:center;margin:35px 14px}.chat-compose label{display:block;font-size:9px;color:#c6d4df;letter-spacing:1px;margin-bottom:6px}.chat-compose textarea{width:100%;box-sizing:border-box;resize:none;padding:10px;color:#f6fafc;background:#0c1925;border:1px solid #718b9d;border-radius:5px;font:500 12px/1.5 var(--sport-type)}.chat-compose>div{display:flex;justify-content:space-between;align-items:center;margin-top:7px}.chat-count{font-size:9px;color:#a3bac7}.chat-status{margin:0;color:#c6d5dc;font-size:10px;line-height:1.45;min-height:28px}.chat-latest{align-self:center}.global-chat [hidden]{display:none!important}.setting-account-card{padding:18px;background:#152431;border:1px solid #657b8d;border-radius:6px}.setting-account-card>small{font-size:10px;color:#abbfcd}.setting-account-card>h4{font-size:27px;margin:10px 0}.setting-account-card>p{font-size:12px;line-height:1.5}.settings-tabs{flex-wrap:wrap}
@media(max-width:1100px) and (min-width:701px){.chat-open .lobby-view{grid-template-columns:minmax(180px,1fr) minmax(210px,1fr);gap:12px}.chat-open .lobby-right-rail{grid-column:2}.chat-open .lobby-left-bottom{grid-column:1}.chat-open .lobby-center-caption{display:none}.chat-open .lobby-rank-title strong{font-size:23px}.chat-open .demo-dock nav button{min-width:48px;padding:5px}.chat-open .demo-dock nav button span{font-size:10px}.chat-open .demo-dock nav button .nav-art{width:26px;height:26px}}
@media(max-width:700px){.chat-open .live-shell .demo-shell{margin-left:0;width:100%}.global-chat{width:min(320px,88vw)}}
@media(prefers-reduced-motion:reduce){.global-chat,.live-shell .demo-shell{transition:none}}
.reduced-motion .global-chat,.reduced-motion .live-shell .demo-shell{transition:none}

/* A clear, dismissible arcade card; keep the actual lobby sharp at its sides. */
.live-ui .identity-overlay{backdrop-filter:none;background:transparent;padding:16px;}
.live-ui .identity-card{position:relative;width:min(92vw,460px);box-sizing:border-box;padding:25px 24px 22px;border:2px solid #af9259;border-top:7px solid #b69751;border-radius:6px;background:linear-gradient(145deg,#293743fa,#162330fc);box-shadow:0 12px 32px #0007,inset 0 1px #ffffff22;font-family:var(--sport-type);animation:identity-arrive .25s cubic-bezier(.2,.8,.2,1) both}
.live-ui .identity-card>small{color:#e1c68d;font-size:10px;letter-spacing:1.5px}.live-ui .identity-card>h2{font:900 clamp(23px,3vw,30px)/1.12 var(--sport-type);margin:12px 30px 13px 0;text-shadow:var(--vl-outline);letter-spacing:-.5px}.live-ui .identity-card>p{color:#c1cfd9;font:500 12px/1.6 var(--sport-type)}.live-ui .identity-card label{font-size:12px;gap:8px;margin:18px 0 10px}.live-ui .identity-card input{font:700 16px var(--sport-type);padding:12px;border:1px solid #829aaa;border-radius:4px;background:#101d29}.live-ui .identity-card>div:last-child{gap:10px;margin-top:17px}.live-ui .identity-card button{cursor:pointer;padding:10px 12px;font-size:11px}.live-ui .identity-card #username-save{background:linear-gradient(#4c713a,#304b28);border:1px solid #a4c28a;color:#fff}.live-ui .identity-card .identity-close{position:absolute;right:12px;top:12px;display:grid;place-items:center;width:31px;height:31px;padding:0;font:500 25px/1 var(--sport-type);color:#fff;background:linear-gradient(#a04447,#773036);border:1px solid #e1a39d;box-shadow:inset 0 1px #fff3,0 2px #27171c}.live-ui .identity-card .identity-close:hover{filter:brightness(1.2)}
@keyframes identity-arrive{from{opacity:0;transform:translateY(8px) scale(.98)}to{opacity:1;transform:none}}
@media(prefers-reduced-motion:reduce){.live-ui .identity-card{animation:none}}
.reduced-motion .identity-card{animation:none}
