/* Game-only layout. The lab retains its shared stylesheet. */
.game-shell{--bg:#111c28;--panel:#202e3d;--ink:#eef3f7;--muted:#a9bac9;--line:#354657;--accent:#267d69;background:#111c28;color:var(--ink);min-height:100vh}.game-shell [hidden]{display:none!important}.game-shell .topbar{height:58px;padding:0 24px;background:#101c29}.game-shell .match-alert{margin-left:auto}.game-shell nav{margin:0;padding:0 24px;border-radius:0;background:#192a3a;gap:3px}.game-shell nav button{border-radius:0;padding:12px 20px}.game-shell nav button[aria-current=true]{background:#345467;color:#fff}.game-shell #subnavigation{background:#26394b}.game-shell #logout{margin-left:auto}.game-shell main{max-width:none;padding:12px 24px}.game-shell .card{background:#202e3d;border-color:#37495b;padding:16px}.game-shell input,.game-shell select{background:#142433;border-color:#42596c;color:#fff}.game-shell label{min-width:0}.game-shell h2,.game-shell h3{margin:0 0 10px}.game-shell #service-notice:empty{display:none}.game-shell #service-notice{color:#ffe2a1}.sr-only{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.locker-grid{display:grid;grid-template-columns:2fr 1fr;gap:16px;height:100%}.locker-room,.club-overview,.reserve-area,#player-detail{background:#172736;border:1px solid #3b5162;border-radius:5px;padding:18px;min-width:0}.locker-room{background:repeating-linear-gradient(90deg,#263746 0,#263746 79px,#53616b 80px);display:flex;flex-direction:column}.lockers{display:flex;align-items:center;justify-content:space-around;flex:1;gap:8px}.lockers i{width:17%;height:45%;background:#46776a;border:6px solid #192a35;display:grid;place-items:center;font-size:2em;font-style:normal}.squad-board{display:grid;grid-template-columns:2fr 1fr;gap:14px;min-height:0}.lineup-group{display:grid;grid-template-columns:1.3fr 1fr;gap:14px;min-height:0}.starting-area{display:flex;flex-direction:column;min-height:0;background:#173e32}.formation-heading{padding:8px}.formation-field{position:relative;display:flex;flex-direction:column-reverse;justify-content:space-around;flex:1;min-height:450px;padding:10px;background:repeating-linear-gradient(0deg,#256547 0,#256547 60px,#2a6c4b 60px,#2a6c4b 120px)}.formation-field:before{content:'';position:absolute;inset:12px;border:1px solid #c5e6cf80;pointer-events:none}.formation-row{display:flex;justify-content:space-evenly;gap:4px;z-index:1}
.tactics-bench{display:flex;flex-direction:column;min-height:0}.game-shell #squad-save{display:grid;gap:8px}.tactics-inputs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}.tactics-bench h3{margin:12px 0 8px}.player-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}.reserve-area{display:flex;flex-direction:column;min-height:0}.reserve-grid{overflow:auto;align-content:start}.empty-state{grid-column:1/-1;padding:24px;text-align:center;color:#a9bac9}.panel-title,.filters{display:flex;justify-content:space-between;gap:12px}.filters{justify-content:flex-start;margin-bottom:12px}.player-browser{display:grid;grid-template-columns:2fr 1fr;gap:12px;min-height:0}.table-scroll{overflow:auto;min-width:0}.game-shell table{width:100%;border-collapse:collapse}.game-shell th,.game-shell td{padding:8px;white-space:nowrap}.game-shell th{background:#26394b}.schedule-layout{display:grid;grid-template-columns:220px minmax(0,1fr);gap:14px;min-height:0;margin-top:12px}.schedule-main{min-width:0;display:flex;flex-direction:column}.game-shell #schedule-teams{display:flex;flex-direction:column;gap:3px;overflow:auto}.game-shell #schedule-days{display:flex;gap:4px;flex-wrap:wrap;margin-bottom:8px}.match-layout{display:grid;grid-template-columns:minmax(0,2fr) minmax(260px,1fr);gap:12px;min-height:0}.match-field{display:flex;flex-direction:column;min-height:0}.game-shell .arena{display:flex;flex-direction:column;min-height:0;padding:10px}.pitch-wrap{position:relative;min-height:0;flex:1;display:flex}.game-shell #pitch{width:100%;height:100%;min-height:250px}.match-waiting{position:absolute;inset:0;display:grid;place-content:center;text-align:center;pointer-events:none;background:#10261a99}.match-waiting h2{font-size:18px}.game-shell #events{overflow:auto;max-height:100px}.match-roster{overflow:auto;background:#172736;padding:12px}.match-roster h3{margin:6px 0}.match-tabs{display:flex;gap:4px}.match-tabs button{flex:1}.match-roster fieldset{border:0;padding:8px 0;display:flex;gap:6px;flex-wrap:wrap}.match-roster label{flex:1}.game-shell #account-settings-panel details{margin-top:16px}.game-shell #recovery-code{overflow-wrap:anywhere}
@media(min-width:1024px){body.game-shell{height:100dvh;min-height:0;display:grid;place-items:center;overflow:hidden;background:#080f17}.game-frame{width:min(100vw,calc(100dvh * 16 / 9));height:min(100dvh,calc(100vw * 9 / 16));container-type:size;display:flex;flex-direction:column;background:#111c28;overflow:hidden}.shell-top{flex:none}.game-shell .topbar{height:5cqh;padding:0 1.5cqw}.game-shell nav{padding:0 1.5cqw}.game-shell nav button{min-height:0;height:4cqh;padding:.5cqh 1.4cqw;font-size:1.4cqh}.game-shell #subnavigation button{height:3.5cqh}.game-shell main,.game-shell .workspace,.game-shell .content-area{display:flex;flex:1;min-height:0;flex-direction:column}.game-shell main{width:100%;padding:1cqh 1.5cqw}.game-shell .content-area>section:not([hidden]){flex:1;min-height:0;overflow:auto}.game-shell .card{padding:1.2cqh 1cqw}.game-shell button,.game-shell input,.game-shell select{font-size:1.3cqh;min-height:3cqh;padding:.4cqh .5cqw}.game-shell h3{font-size:1.5cqh}.game-shell #squad-panel:not([hidden]),.game-shell #players-panel:not([hidden]),.game-shell #match-panel:not([hidden]),.game-shell #schedule-panel:not([hidden]){display:flex;flex-direction:column;overflow:hidden}.squad-board,.match-layout,.player-browser,.schedule-layout{flex:1}.formation-field{min-height:0}.formation-row{flex:1;min-height:0;align-items:center}.game-shell #squad-save{gap:.4cqh}.tactics-bench h3{margin:.8cqh 0}.reserve-grid,.table-scroll{flex:1;min-height:0}.game-shell #pitch{min-height:0}.game-shell .arena{flex:1}.match-roster{font-size:1.2cqh}.match-roster h3{font-size:1.3cqh;margin:.4cqh 0}.game-shell #events{max-height:9cqh}.game-shell #schedule-teams button{min-height:0;padding:.5cqh}.game-shell th,.game-shell td{padding:.7cqh .5cqw;font-size:1.3cqh}}
@media(max-width:1023px){.game-shell main{padding:12px}.game-shell .topbar{padding:0 12px}.game-shell nav{padding:0 4px;flex-wrap:wrap}.game-shell nav button{padding:10px 8px;font-size:12px}.locker-grid,.squad-board,.lineup-group,.player-browser,.match-layout,.schedule-layout{grid-template-columns:1fr}.locker-room{min-height:260px}.formation-field{min-height:450px}.formation-row{flex-wrap:nowrap;gap:4px;padding:8px 0}.reserve-area{min-height:160px}.schedule-layout{gap:10px}.game-shell #schedule-teams{flex-direction:row;flex-wrap:wrap}.game-shell #schedule-teams button{flex:1 1 28%}.game-shell #pitch{min-height:210px}.game-shell table{width:max-content;min-width:100%}.filters{flex-wrap:wrap}}
/* Override shared shell defaults and keep table controls legible. */
.game-shell .workspace{display:block;align-items:stretch}.game-shell .card{margin-bottom:0}.game-shell #squad-save{margin-bottom:0}.game-shell #pitch{max-height:none}.game-shell .secondary{background:#334859;border-color:#587184;color:#fff}.game-shell button[aria-pressed=true],.game-shell [data-match-tab][aria-selected=true]{background:#267d69;color:#fff;box-shadow:inset 0 -3px #a5edc8}.game-shell #schedule-teams .own-team{border:1px solid #9dd8bb}.game-shell tr.own-team td{background:#285245;color:#fff;font-weight:700}.game-shell .table-scroll thead th{position:sticky;top:0;z-index:1}.game-shell .player-browser{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr) auto}.game-shell #player-detail{padding:8px;max-height:25cqh}.game-shell #player-detail:empty{display:none}
@media(min-width:1024px){.game-shell .workspace{display:flex;align-items:stretch}.game-shell .content-area{width:100%}}
@media(max-width:1023px){.game-shell #player-detail{max-height:none}}
/* Shared labels flex horizontally in forms; standalone selectors stay compact. */
.game-shell #schedule-panel > label,.game-shell #standings-panel > label,.game-shell #scorers-panel > label{flex:none;align-self:flex-start;width:min(100%,260px)}


/* A one-time club choice precedes the locker summary. */
.game-shell #locker-panel:not([hidden]){display:flex;flex-direction:column;gap:12px}.game-shell .locker-grid{flex:1;min-height:0}.game-shell #team-selection{flex:none}

/* Compact lineup cards: identity and condition only; abilities live in the dialog. */
.game-shell .player-card{--card-accent:#b9d5df;position:relative;display:flex;flex-direction:column;align-items:stretch;flex:0 1 94px;width:94px;height:122px;min-width:0;min-height:0;padding:0;gap:0;border:1px solid #a7bac9;border-radius:3px;background:#142433;color:#fff;overflow:hidden;font-size:12px;line-height:1.15;font-weight:400;text-align:center;cursor:grab;touch-action:none;user-select:none}
.game-shell .player-card[data-role=GK]{--card-accent:#f0ca75}.game-shell .player-card[data-role=DF]{--card-accent:#99c6f0}.game-shell .player-card[data-role=MF]{--card-accent:#9bd5b7}.game-shell .player-card[data-role=FW]{--card-accent:#efada2}
.card-player-hero{position:relative;flex:1;min-height:0;background:linear-gradient(135deg,#38556b,#213849)}
.card-portrait{display:block;width:100%;height:100%;fill:#acbdc8}
.card-role{position:absolute;left:0;top:0;padding:2px 5px;background:var(--card-accent);color:#10202c;font-weight:800}

.game-shell .player-card .card-player-name{display:block;flex:none;padding:3px 2px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:1em;line-height:1.2;background:#101d29}
.card-status{display:flex;align-items:center;gap:4px;padding:0 4px 2px;font-size:.8em;background:#101d29}
.card-fitness{flex:1;display:block;width:100%;min-width:0;height:5px;border:0;background:#364651}
.card-fitness::-webkit-meter-bar{background:#364651;border:0;border-radius:0}.card-fitness::-webkit-meter-optimum-value{background:#6ed3a0}.card-fitness::-moz-meter-bar{background:#6ed3a0}

.game-shell .player-card:hover{border-color:#fff}.game-shell .player-card:focus-visible{outline:3px solid #ffe59e;outline-offset:2px}
.player-grid{align-content:start;justify-items:center}.game-shell #bench{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;flex:0 0 auto}
.formation-field{padding:12px 8px;background:radial-gradient(ellipse at center,transparent 19%,#c5e6cf60 19.2%,transparent 19.6%),linear-gradient(transparent 49.8%,#c5e6cf60 50%,transparent 50.2%),repeating-linear-gradient(0deg,#245d43 0,#245d43 12.5%,#29674a 12.5%,#29674a 25%)}
.game-shell .formation-heading{display:flex;justify-content:space-between}.game-shell #squad-dirty{font-size:11px;color:#b7c9d6}
.game-shell .player-card.drag-source{opacity:.45}.game-shell .player-card.drop-target{outline:3px solid #ffe59e;outline-offset:2px}
.game-shell .drag-ghost{position:fixed;z-index:100;pointer-events:none;opacity:.9;cursor:grabbing;box-shadow:0 8px 24px #0008}
@media(min-width:1024px){
 .squad-board{grid-template-columns:minmax(0,2.6fr) minmax(0,1fr);gap:1cqw}.game-shell .lineup-group{grid-template-columns:minmax(0,3fr) minmax(0,1fr);gap:.8cqw}
 .game-shell .player-card{flex-basis:clamp(64px,5.4cqw,124px);width:clamp(64px,5.4cqw,124px);height:clamp(76px,12.4cqh,160px);font-size:clamp(10px,1.15cqh,15px)}
 .game-shell #bench{gap:.65cqh .4cqw;grid-template-rows:none}.game-shell .reserve-area{padding:1cqh .8cqw}.reserve-grid{gap:1cqh .6cqw}
 .game-shell .tactics-bench h3{font-size:clamp(11px,1.5cqh,18px)}
}
@media(max-width:1023px){
 .game-shell .formation-row .player-card{flex:0 1 94px;width:94px;height:112px;font-size:11px}
 .formation-field{min-height:540px}.game-shell #bench{grid-template-columns:repeat(3,minmax(0,1fr))}.game-shell .tactics-bench{padding:10px 0}
 .game-shell .reserve-area{padding:12px}.game-shell .reserve-grid{max-height:440px;gap:10px}.game-shell .tactics-inputs input{width:100%}
}
/* Enlarged player view: portrait left, switchable detail right, league records below. */
.game-shell #player-card-dialog{width:min(740px,90vw);max-height:90dvh;padding:0;border:1px solid #748c9e;border-radius:6px;background:#1b2b3a;color:#eef3f7;overflow:auto;box-shadow:0 20px 80px #0009;font-size:14px}
#player-card-dialog::backdrop{background:#030a13b8}.player-dialog-top{display:flex;align-items:center;justify-content:space-between;padding:10px 16px;background:#263d50;border-bottom:1px solid #506778}
.game-shell #player-card-dialog button{font-size:14px;min-height:36px;padding:6px 14px}
.player-dialog-body{display:grid;grid-template-columns:210px minmax(0,1fr);gap:20px;padding:20px}
.expanded-identity{border:1px solid #738b9d;background:#13212e;position:relative}.expanded-identity>span{position:absolute;top:0;left:0;background:#c8dae5;color:#13212e;font-size:20px;font-weight:bold;padding:5px 10px}
#expanded-portrait{height:185px;background:linear-gradient(135deg,#39586d,#203445)}.game-shell #expanded-name{font-size:20px;text-align:center;overflow-wrap:anywhere;margin:10px 6px}
#expanded-fitness{display:grid;gap:7px;padding:0 12px 14px;font-size:12px}.card-detail-tabs{display:flex;gap:4px;margin-bottom:14px}.card-detail-tabs button{flex:1}
#expanded-abilities{display:grid;gap:15px}.expanded-ability{display:grid;grid-template-columns:58px minmax(0,1fr) 28px;gap:10px;align-items:center}.expanded-ability b{text-align:right;font-variant-numeric:tabular-nums}.expanded-ability meter{width:100%;height:10px}
.expanded-ability meter::-webkit-meter-bar{background:#344d5e;border:0}.expanded-ability meter::-webkit-meter-optimum-value{background:#83b9da}
#expanded-profile{display:grid;grid-template-columns:70px minmax(0,1fr);gap:13px 10px;margin:0}#expanded-profile dt{color:#b6cad8}#expanded-profile dd{margin:0;overflow-wrap:anywhere}
.expanded-history{padding:14px 20px 20px;border-top:1px solid #40596b}.game-shell .expanded-history h3{font-size:13px;font-weight:400;color:#bccdd9;margin:0 0 12px}
#expanded-records{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));margin:0;background:#13212e;border:1px solid #40596b}#expanded-records>div{text-align:center;padding:12px 4px}#expanded-records dt{font-size:12px;color:#bccdd9}#expanded-records dd{font-size:20px;font-weight:700;margin:8px 0 0}
@media(max-width:600px){.game-shell #player-card-dialog{width:calc(100vw - 24px)}.player-dialog-body{grid-template-columns:1fr;padding:14px;gap:16px}.expanded-identity{width:160px;justify-self:center}#expanded-portrait{height:128px}.game-shell #expanded-name{font-size:18px}.expanded-history{padding:14px}#expanded-records{grid-template-columns:repeat(3,minmax(0,1fr))}.player-dialog-top{position:sticky;top:0;z-index:1}}

.game-shell .card-detail-tabs button[aria-pressed=false]{background:#31495b;border-color:#526c80;color:#d8e4ed}
.squad-board,.lineup-group,.starting-area,.tactics-bench{min-width:0}
@media(max-width:1023px){.squad-board,.lineup-group{grid-template-columns:minmax(0,1fr)}.game-shell #squad-panel{padding:8px}}

/* Account controls stay together at the end of the main navigation. */
.game-shell .account-menu{display:flex;align-items:center;gap:3px;margin-left:auto}.game-shell .account-menu #logout{margin-left:0}
/* One table language for players, fixtures, standings, rosters and records. */
.game-shell table{font-size:12px;line-height:1.45;color:#eef3f7;background:#172736}
.game-shell th,.game-shell td{padding:8px;border-bottom:1px solid #354b5e;vertical-align:middle;font-variant-numeric:tabular-nums}
.game-shell th{background:#26394b;color:#b9cbd8;font-weight:600}.game-shell tbody tr:nth-child(even){background:#1c2e3e}
.game-shell table .table-select{display:block;width:100%;min-height:0;padding:0;margin:0;border:0;border-radius:0;background:transparent;color:inherit;font:inherit;text-align:left;line-height:inherit;box-shadow:none}
.game-shell table .table-select[aria-pressed=true]{background:transparent;color:inherit;box-shadow:none}
.game-shell tbody tr.selected-row td,.game-shell tbody tr.own-team td{background:#285245;color:#fff;font-weight:400}
.game-shell tbody tr:has(.table-select):hover td{background:#304b5c}
@media(min-width:1024px){.game-shell th,.game-shell td{font-size:1.3cqh;padding:.7cqh .5cqw}}
@media(max-width:600px){.game-shell .account-menu{flex-basis:100%;justify-content:flex-end;border-top:1px solid #354657}}

/* Notifications overlay the viewport; they never consume game-frame space. */
.game-shell #service-notification{position:fixed;z-index:120;right:max(18px,env(safe-area-inset-right));bottom:max(18px,env(safe-area-inset-bottom));display:flex;align-items:flex-start;gap:12px;width:min(420px,calc(100vw - 32px));max-height:40dvh;padding:14px 12px 14px 16px;border:1px solid #68829a;border-left:4px solid #82d5ab;border-radius:6px;background:#203446;color:#eef3f7;box-shadow:0 8px 30px #0008}
.game-shell #service-notification[data-kind=error]{border-left-color:#ffad8e}
.game-shell #service-notice{flex:1;min-width:0;max-height:calc(40dvh - 30px);overflow:auto;margin:0;padding:0;color:#eef3f7;font-size:14px;line-height:1.5;overflow-wrap:anywhere}
.game-shell #dismiss-notice{flex:none;display:grid;place-items:center;min-width:36px;min-height:36px;margin:-6px -4px -6px 0;padding:0;border:0;background:transparent;color:#fff;font-size:24px;line-height:1}
@media(max-width:600px){.game-shell #service-notification{right:12px;bottom:max(12px,env(safe-area-inset-bottom));width:calc(100vw - 24px)}}

/* Live league scores stay inside the pitch and never intercept play controls. */
.game-shell .league-match-notice:not([hidden]){position:absolute;z-index:3;top:10px;left:10px;max-width:min(340px,calc(100% - 20px));padding:8px 11px;border-left:3px solid #d8e9a6;border-radius:3px;background:#10261eea;color:#fff;box-shadow:0 3px 12px #0006;white-space:pre-line;overflow-wrap:anywhere;font-size:14px;line-height:1.4;pointer-events:none}
@media(min-width:1024px){.game-shell .league-match-notice:not([hidden]){font-size:clamp(11px,1.3cqh,16px);top:1cqh;left:.7cqw}}
@media(max-width:600px){.game-shell .league-match-notice:not([hidden]){max-width:min(260px,calc(100% - 16px));top:8px;left:8px;font-size:12px;padding:6px 8px}}

/* Formal league standings: rank bands are current positions, not settled outcomes. */
.game-shell .standings-heading{flex:none;margin:10px 0 6px;color:#b9cbd8;font-size:14px}
.game-shell #league-entry-status{flex:none;margin:8px 0 0;color:#ffdf9b}
.game-shell .waiting-clubs{flex:none;margin-top:10px;border:1px solid #42596c;border-radius:4px;background:#172736}
.game-shell .waiting-clubs summary{padding:10px 12px;cursor:pointer;color:#dce9f2}
.game-shell .waiting-clubs ul{max-height:180px;overflow:auto;margin:0;padding:0 12px 10px 30px;color:#b9cbd8}
.game-shell .waiting-clubs li{padding:3px 0;overflow-wrap:anywhere}
@media(min-width:1024px){.game-shell #standings-panel:not([hidden]),.game-shell #scorers-panel:not([hidden]){display:flex;flex-direction:column;overflow:hidden}.game-shell .standings-heading{margin:.8cqh 0 .5cqh;font-size:1.3cqh}.game-shell .waiting-clubs{margin-top:.8cqh}.game-shell .waiting-clubs summary{padding:.7cqh .6cqw;font-size:1.3cqh}.game-shell .waiting-clubs ul{max-height:16cqh}}
@media(max-width:600px){
 .game-shell #standings{overflow:visible}
 .game-shell #standings table,.game-shell #standings tbody{display:block;width:100%;min-width:0}
 .game-shell #standings thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
 .game-shell #standings tr{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));margin-bottom:8px;border:1px solid #354b5e}
 .game-shell #standings td{min-width:0;white-space:normal;overflow-wrap:anywhere;padding:7px 9px;border:0}
 .game-shell #standings td:nth-child(2){grid-column:span 2;text-align:right;color:#b9dcd1}
 .game-shell #standings td:nth-child(3){grid-column:1/-1;font-size:15px;font-weight:600;border-bottom:1px solid #354b5e}
 .game-shell #standings td:nth-child(n+4)::before{content:attr(data-label) ' ';color:#a9bac9;font-size:12px}
 .game-shell #standings td.empty-state{grid-column:1/-1}
}

/* Shared compact information tables and controls. */
.game-shell .topbar{position:relative}.game-shell .match-alert{position:absolute;left:50%;transform:translateX(-50%);margin:0;max-width:55%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.game-shell #players-panel .filters{justify-content:flex-end;align-items:end;gap:8px}.game-shell #players-panel .filters label{display:flex;flex-direction:column;gap:3px;font-size:12px;color:#b9cbd8}.game-shell #players-panel .filters input{width:180px}.game-shell #players-panel .filters select{width:90px}
.game-shell .table-scroll table{table-layout:auto}.game-shell .table-scroll th,.game-shell .table-scroll td{text-align:left}.game-shell .table-scroll [data-numeric=true]{text-align:right}.game-shell #owned-players td[data-label=선수],.game-shell #player-records td[data-label=선수],.game-shell .table-scroll td[data-label=클럽]{min-width:110px}
.game-shell .table-scroll th,.game-shell .table-scroll td{padding:6px 9px}
/* The footer is inside the desktop frame; on mobile it stays above the safe area. */
.game-shell .game-frame{position:relative}.game-shell .social-bar{position:relative;flex:none;z-index:20;min-width:0;background:#152534;border-top:1px solid #3b5162}
.game-shell #social-toggle{display:flex;align-items:center;gap:10px;width:min(420px,100%);min-height:34px;padding:6px 14px;border:0;border-radius:0;background:transparent;color:#edf5f7;text-align:left}
.game-shell #social-toggle strong{flex:none}.game-shell #social-preview{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#b9cbd8;font-weight:400}
.game-shell .social-panel{position:absolute;left:0;bottom:100%;display:flex;flex-direction:column;width:min(380px,calc(100vw - 16px));height:min(510px,65dvh);max-height:calc(100dvh - 80px);background:#1d3040;border:1px solid #587184;box-shadow:0 -5px 20px #0007}
.game-shell .social-header{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:9px 12px;border-bottom:1px solid #42596c}
.game-shell .social-header button{padding:5px 8px;min-height:30px}.game-shell .social-tabs{display:flex;gap:0;border-bottom:1px solid #42596c}.game-shell .social-tabs button{flex:1;border:0;border-radius:0;background:transparent}.game-shell .social-tabs [aria-selected=true]{background:#345467;box-shadow:inset 0 -3px #a5edc8}
.game-shell .social-content{display:flex;flex:1;min-height:0;flex-direction:column;padding:8px}.game-shell .social-messages{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain}.game-shell .social-message{padding:7px 8px;margin-bottom:6px;background:#172736;border-radius:3px}.game-shell .social-message.own-message{background:#28483f}.game-shell .social-message-heading{display:flex;justify-content:space-between;gap:8px;font-size:12px;color:#b9cbd8}.game-shell .social-message p{margin:4px 0 0;white-space:pre-wrap;overflow-wrap:anywhere;font-size:14px;line-height:1.4}
.game-shell #social-older{flex:none;align-self:center;margin-bottom:6px}.game-shell #social-form{display:flex;align-items:stretch;gap:6px;flex:none;margin:8px 0 0}.game-shell #social-input{flex:1;min-width:0;resize:none;max-height:100px;padding:8px;background:#142433;border:1px solid #42596c;color:#fff;font:inherit}.game-shell #social-send{flex:none}.game-shell #social-presence-count{margin:2px 0 8px;color:#b9cbd8}.game-shell #social-users{flex:1;min-height:0;overflow:auto;margin:0;padding-left:22px}.game-shell #social-users li{padding:4px 0;overflow-wrap:anywhere}.game-shell #social-status{flex:none;margin:0;padding:0 8px;color:#ffdf9b;font-size:12px}.game-shell #social-status:not(:empty){padding:4px 8px 8px}
@media(min-width:1024px){.game-shell #players-panel .filters input{width:12cqw}.game-shell #players-panel .filters select{width:6cqw}.game-shell .social-bar{min-height:3.2cqh}.game-shell #social-toggle{min-height:3.2cqh;padding:.4cqh .8cqw;font-size:1.3cqh}.game-shell .social-panel{width:min(29cqw,420px);height:min(53cqh,520px);font-size:1.3cqh}}
@media(max-width:1023px){.game-shell main{padding-bottom:calc(60px + env(safe-area-inset-bottom))}.game-shell .social-bar{position:fixed;left:0;right:0;bottom:0;padding-bottom:env(safe-area-inset-bottom)}.game-shell .social-panel{left:8px;bottom:100%;height:min(480px,60dvh)}.game-shell #players-panel .filters{justify-content:flex-start}.game-shell #players-panel .filters input{width:min(100%,200px)}}
@media(max-width:600px){.game-shell .table-scroll th,.game-shell .table-scroll td{padding:7px 8px}.game-shell #standings td:nth-child(3){text-align:left}.game-shell .match-alert{max-width:48%;font-size:12px}.game-shell .topbar{padding-right:8px}}

/* Compact formation rows; the original card details and drag targets are unchanged. */
.game-shell .squad-summary{flex:none;margin:0;padding:4px 8px;color:#c1d7ca;background:#173e32;font-size:12px;line-height:1.35}
.game-shell .formation-row{width:100%;max-width:610px;align-self:center;justify-content:center;gap:8px}
@media(min-width:1024px){.game-shell .squad-board{grid-template-columns:minmax(0,3fr) minmax(0,1fr);gap:.5cqw}.game-shell .lineup-group{grid-template-columns:minmax(0,3fr) minmax(0,1.1fr);gap:.5cqw}.game-shell .formation-row{max-width:38cqw;gap:.45cqw}.game-shell .squad-summary{padding:.3cqh .5cqw;font-size:1.15cqh}.game-shell .reserve-area{padding:.5cqh .4cqw}.game-shell .reserve-grid,.game-shell #bench{gap:.35cqh .3cqw}.game-shell .tactics-bench h3{margin:.45cqh 0}.game-shell #squad-save{gap:.25cqh}}
@media(max-width:1023px){.game-shell .formation-row{gap:4px}.game-shell .squad-summary{font-size:12px}.game-shell .tactics-bench{padding:6px 0}.game-shell .reserve-area{padding:8px}}
@media(min-width:601px){
 .game-shell table.game-list{width:auto;min-width:0;max-width:100%;table-layout:auto}
 .game-shell .game-list :is(td,th){font-size:clamp(12px,1.4cqh,16px)}
 .game-shell .game-list :is(td,th)[data-numeric=true]{width:auto;min-width:3ch;text-align:right;white-space:nowrap;padding-inline:.6em}
 .game-shell .game-list td[data-label]{overflow-wrap:anywhere}
 .game-shell .game-list td:is([data-label=클럽],[data-label=선수],[data-label=상대클럽]){max-width:20em}

}
/* Record groups keep coverage visible and avoid squeezing long tables on phones. */
.game-shell .records-scope{flex:none;margin:0 0 10px;color:#b9cbd8;font-size:13px}.game-shell .record-tabs{display:flex;gap:4px;flex:none;margin-bottom:8px}.game-shell .record-tabs button{padding:6px 12px}
@media(min-width:1024px){.game-shell #team-records-panel:not([hidden]),.game-shell #player-records-panel:not([hidden]){display:flex;flex-direction:column;overflow:hidden}.game-shell .records-scope{font-size:1.3cqh}}
@media(max-width:600px){
 .game-shell .record-list{overflow:visible}
 .game-shell .record-list :is(table,tbody){display:block;width:100%;min-width:0}
 .game-shell .record-list thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
 .game-shell .record-list tr{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));margin-bottom:8px;border:1px solid #354b5e}
 .game-shell .record-list td[data-label]{width:auto;min-width:0;white-space:normal;overflow-wrap:anywhere;text-align:left}
 .game-shell .record-list td[data-label]::before{content:attr(data-label) ' ';color:#a9bac9;font-size:12px}
 .game-shell .record-list td:is([data-label=클럽],[data-label=선수],[data-label=상대클럽]){grid-column:1/-1;font-weight:600;border-bottom:1px solid #354b5e}
 .game-shell .record-list td:is([data-label=클럽],[data-label=선수],[data-label=상대클럽])::before{content:none}
 .game-shell .record-list td.empty-state{grid-column:1/-1}
}
@media(min-width:1024px){
 .game-shell .squad-board{grid-template-columns:minmax(0,1fr) minmax(0,20cqw)}
 .game-shell .lineup-group{grid-template-columns:minmax(0,1fr) minmax(0,14cqw)}
 .game-shell #bench{grid-template-columns:repeat(2,clamp(64px,5.4cqw,124px));justify-content:start}
 .game-shell .reserve-grid{grid-template-columns:repeat(3,clamp(64px,5.4cqw,124px));justify-content:start}
}
.game-shell .social-history-controls{display:flex;flex:none;justify-content:center;gap:6px}.game-shell .social-history-controls:has(button:not([hidden])){margin-bottom:6px}.game-shell #social-older{margin:0}
/* Keep the pitch, tactics and reserve columns close to 52/16/32 on desktop. */
@media(min-width:1024px){
 .game-shell .squad-board{grid-template-columns:minmax(0,68fr) minmax(0,32fr)}
 .game-shell .lineup-group{grid-template-columns:minmax(0,52fr) minmax(0,16fr)}
}
/* Keep all seven substitutes visible in the smallest desktop frame. */
@media(min-width:1024px) and (max-width:1279px){
 .game-shell #bench .player-card{height:64px;font-size:10px}
 .game-shell .tactics-bench label,.game-shell .tactics-bench input,.game-shell .tactics-bench select,.game-shell .tactics-bench button,.game-shell .tactics-bench h3,.game-shell #squad-dirty,.game-shell .squad-summary{font-size:10px}
 .game-shell #squad-panel .card-status{font-size:10px}
}

/* The pitch and both card trays share one reading width. */
.game-shell .formation-field {
  background-color: #235840;
  background-image: radial-gradient(circle at center, transparent 12%, #cbefd34d 12.2%, transparent 12.6%),
    linear-gradient(transparent 49.8%, #cbefd34d 50%, transparent 50.2%),
    repeating-linear-gradient(0deg, transparent 0 12.5%, #8bbe7810 12.5% 25%);
}
.game-shell .formation-field::after {
  content: ''; position: absolute; inset: 12px 26%; pointer-events: none;
  --pitch-line: linear-gradient(#cfebcf66,#cfebcf66);
  background: var(--pitch-line) 0 11% / 100% 1px,
    var(--pitch-line) 0 89% / 100% 1px,
    var(--pitch-line) left top / 1px 11%, var(--pitch-line) right top / 1px 11%,
    var(--pitch-line) left bottom / 1px 11%, var(--pitch-line) right bottom / 1px 11%;
  background-repeat:no-repeat;
}
.game-shell .card-player-hero {background:linear-gradient(155deg,#314657,#192b39)}
.game-shell .player-card .card-portrait {width:75%;margin:auto;fill:#8195a4}
.game-shell .player-card {border-color:#687f8c;box-shadow:0 2px 4px #06121942}
.game-shell .player-card .card-player-name {padding:3px 2px;font-weight:730}
.game-shell .formation-heading {font-weight:700;background:#1a4135}
.game-shell .formation-heading span {font-variant-numeric:tabular-nums}
@media(min-width:1024px){
  .game-shell .squad-board {width: min(100%,84cqw);margin-inline:auto;grid-template-columns:minmax(0,1fr) minmax(0,26cqw);gap:.65cqw}
  .game-shell .lineup-group {grid-template-columns:minmax(0,1fr) minmax(0,13.2cqw);gap:.65cqw}
  .game-shell .formation-row {gap:clamp(6px,1.15cqw,23px)}
  .game-shell #bench,.game-shell .reserve-grid {grid-template-columns:repeat(2,minmax(0,1fr));justify-items:stretch;align-content:start}
  .game-shell .reserve-grid {grid-template-columns:repeat(4,minmax(0,1fr))}
  .game-shell :is(#bench,#reserves) .player-card {width:100%}
}

/* Keep related totals on one line in stacked phone records. */
@media(max-width:600px){
 .game-shell :is(#team-records,#standings) tr:has(td[data-label=승]){
  grid-template-columns:repeat(3,minmax(0,4.8em));justify-content:start;
 }
 .game-shell :is(#team-records,#standings) td[data-label=경기]{grid-column:1/-1}
 .game-shell #standings td[data-label=경기],.game-shell #standings td:nth-child(n+4){text-align:left}
}
.game-shell #fixture-result-dialog{background:#1b2b3a;color:var(--ink);width:min(35rem,94vw);max-height:88dvh;padding:0;border:1px solid #526b7c;border-radius:6px}
#fixture-result-dialog::backdrop{background:#030a13b8}
#fixture-result-dialog :is(h2,form){margin:0}
#fixture-result-dialog p,#fixture-result-dialog .table-scroll{margin:12px;color:inherit}

.game-shell #league-scorers td[data-label=클럽]{grid-column:auto;font-weight:inherit}
@media(max-width:600px){.game-shell #league-scorers td[data-label=클럽]::before{content:attr(data-label) " "}}

@media(max-width:600px){
 .game-shell :is(#locker-record,#schedule,#player-detail,#starter-list,#match-bench,#fixture-result-stats) table.game-list{width:auto;min-width:0}
}

/* League workspaces use one row rhythm and keep related numbers together. */
.game-shell .game-list {font-variant-numeric:tabular-nums}
.game-shell .form-marks {display:inline-flex;align-items:center;gap:.3em}
.game-shell .form-marks span {display:grid;place-items:center;width:1.65em;height:1.65em;font-size:.82em;border-radius:3px;color:#e5eaf1;background:#354658}
.game-shell .form-marks [data-result=승] {background:#215649;color:#c5f6df}
.game-shell .form-marks [data-result=패] {background:#533944;color:#ffced2}
.game-shell .record-tabs button:not([aria-pressed=true]),.game-shell #schedule-days button:not([aria-pressed=true]),.game-shell #schedule-teams button:not([aria-pressed=true]) {background:#213446;color:#cad5df;border-color:#394e60;box-shadow:none}
.game-shell #schedule-teams button {text-align:left}
.game-shell .venue-bar {display:flex;gap:3px}
.game-shell .venue-bar.has-values::before,.game-shell .venue-bar.has-values::after {content:'';flex:1;height:.52em;border-radius:2px;background-color:#324555;background-repeat:no-repeat}
.game-shell .venue-bar.has-values::before {background-image:linear-gradient(#70cdb0,#70cdb0);background-size:var(--home-size) 100%;background-position:right}
.game-shell .venue-bar.has-values::after {background-image:linear-gradient(#869ccf,#869ccf);background-size:var(--away-size) 100%}
.game-shell #team-records [data-label=홈] {color:#a8eacf}
.game-shell #team-records [data-label=원정] {color:#c4d3f9}
.game-shell :is(#standings,#league-scorers) td:is([data-label=승점],[data-label=득점]):last-of-type,
.game-shell #league-scorers td[data-label=득점],.game-shell #standings td[data-label=승점],.game-shell #team-records td[data-label=시즌] {color:#c6f5da;font-weight:700}
@media(min-width:601px){
 .game-shell .table-scroll table.game-list {width:100%;max-width:100%;min-width:0}
 .game-shell :is(#standings,#league-scorers,#team-records,#owned-players,#player-records,#schedule) .game-list :is(th,td) {
  height:clamp(36px,4.9cqh,54px);padding-block:.32em;padding-inline:clamp(6px,1cqw,19px);font-size:clamp(13px,1.63cqh,18px)
 }
 .game-shell :is(#standings,#league-scorers,#team-records,#owned-players,#player-records,#schedule) th {box-shadow:inset 0 -2px #506777;white-space:nowrap}
 .game-shell #standings table {table-layout:fixed}
 .game-shell #standings :is(th,td):is([data-label=순위],[data-label=경기],[data-label=승],[data-label=무],[data-label=패],[data-label=득점],[data-label=실점],[data-label=득실],[data-label=승점]) {width:clamp(30px,2.8cqw,53px);min-width:0;padding-inline:3px;text-align:center}
 .game-shell #standings [data-label=승점] {background-color:#28433f}
 .game-shell #standings :is(th,td)[data-label=승점] {width:4.8%}
 .game-shell #standings td[data-label=클럽],.game-shell #league-scorers td[data-label=선수],.game-shell #team-records td:first-child {font-weight:650}
 .game-shell #standings :is(th,td)[data-label="최근 5경기"] {width:15%;text-align:center}
 .game-shell #standings tbody tr.own-team td:first-child {box-shadow:inset 3px 0 #97e8bb}
 .game-shell #team-records :is(th,td){height:clamp(37px,6.05cqh,65px)}
 .game-shell #team-records :is(th,td)[data-label="홈 · 원정 비교"]{width:32%;text-align:center}
 .game-shell #team-records :is(th,td)[data-label=원정]{text-align:left;width:13%}
 .game-shell #team-records :is(th,td)[data-label=홈]{width:13%}
 .game-shell #team-records :is(th,td)[data-label=시즌]{width:14%;text-align:center;background-color:#213b3b}
 .game-shell #team-records :is(th,td):first-child{padding-inline-start:1.4em}
 .game-shell #league-scorers :is(th,td)[data-numeric=true],.game-shell #player-records :is(th,td)[data-numeric=true],.game-shell #owned-players :is(th,td)[data-numeric=true]{text-align:center}
 .game-shell :is(#schedule-panel,#scorers-panel,#standings-panel)>label{display:flex;align-items:center;gap:.8em;margin-bottom:.7em;color:#bfceda}
 .game-shell :is(#league-select,#scorers-league,#standings-league){width:auto;max-width:100%}
 .game-shell #schedule-teams button{padding:.65em 1em}
}
@media(max-width:600px){
 .game-shell #team-records table.game-list{display:table;width:100%;table-layout:fixed}
 .game-shell #team-records thead{display:table-header-group;position:static;clip-path:none}
 .game-shell #team-records tbody{display:table-row-group}
 .game-shell #team-records tr{display:table-row;border:0}
 .game-shell #team-records :is(th,td){padding:10px 3px;text-align:right;font-size:13px;white-space:normal}
 .game-shell #team-records :is(th,td):first-child{width:34%;text-align:left;padding-left:7px}
 .game-shell #team-records :is(th,td):nth-child(5){display:none}
 .game-shell #team-records td[data-label]::before{content:none}
 .game-shell #standings tr:has(td[data-label=승]){grid-template-columns:repeat(3,minmax(0,1fr))}
 .game-shell #standings td[data-label="최근 5경기"]{grid-column:1/-1}
 .game-shell #standings td[data-label="최근 5경기"]::before{margin-right:.6em}
}
@media(min-width:601px){
 .game-shell #standings :is(th,td)[data-label=구역] {width:18%;padding-left:1.4em}
 .game-shell #standings td[data-label=득실]{border-right:1px solid #394e60}
 .game-shell #team-records .game-list :is(th,td){height:clamp(37px,5.7cqh,62px)}
}
@media(max-width:600px){
 .game-shell #standings tr:has(td[data-label=승]){
  grid-template-columns:repeat(6,minmax(0,1fr));align-items:center;gap:0;
  padding:6px 7px;margin-bottom:5px
 }
 .game-shell #standings tr td[data-label]{grid-column:auto;padding:3px 1px;min-width:0;text-align:left;font-size:13px;font-weight:400;border:0}
 .game-shell #standings tr td[data-label]::before{content:attr(data-label) ' ';font-size:11px;color:#b1c2cf}
 .game-shell #standings tr td[data-label=순위]::before,.game-shell #standings tr td[data-label=클럽]::before,.game-shell #standings tr td[data-label=구역]::before {content:none}
 .game-shell #standings tr td[data-label=클럽]{grid-column:span 3;font-weight:700;font-size:15px}
 .game-shell #standings tr td[data-label=승점]{grid-column:span 2;text-align:right;font-weight:700}
 .game-shell #standings tr td[data-label=구역]{grid-column:span 2;color:#bed1db;font-size:11px}
 .game-shell #standings tr td[data-label="최근 5경기"]{grid-column:span 3;text-align:right}
 .game-shell #standings tr td[data-label="최근 5경기"]::before{content:none}
 .game-shell :is(#owned-players,#schedule,#player-detail) table.game-list{width:100%;min-width:0}
 .game-shell :is(#owned-players,#schedule,#player-records,#league-scorers,#player-detail) tr {gap:0;padding:5px 7px;margin-bottom:5px}
 .game-shell :is(#owned-players,#schedule,#player-records,#league-scorers,#player-detail) tr td[data-label]{padding:4px 2px;min-width:0;border:0}
 .game-shell #owned-players td[data-label=선수],.game-shell #league-scorers td[data-label=선수],.game-shell #schedule td[data-label=상대클럽]{grid-row:1;grid-column:1/-1}
 .game-shell #league-scorers tr{grid-template-columns:2.4em minmax(0,1fr) auto auto}
 .game-shell #league-scorers tr td[data-label=순위]{grid-row:1;grid-column:1}
 .game-shell #league-scorers tr td[data-label=선수]{grid-column:2;grid-row:1}
 .game-shell #league-scorers tr td[data-label=득점]{grid-column:3/5;grid-row:1;text-align:right}
 .game-shell #league-scorers tr td[data-label=클럽]{grid-row:2;grid-column:1/3}
 .game-shell #league-scorers tr td[data-label=출전],.game-shell #league-scorers tr td[data-label=슈팅]{padding-left:8px}
 .game-shell #league-scorers tr td:is([data-label=순위],[data-label=클럽])::before{content:none}
 .game-shell #schedule tr {grid-template-columns:1fr 1.5fr 1fr}
 .game-shell #schedule tr td[data-label=경기결과]{grid-row:1;grid-column:3;text-align:right}
 .game-shell #schedule tr td[data-label=상대클럽]{grid-column:1/3}
 .game-shell #schedule tr td[data-label=경기결과]::before{content:none}
}
.game-shell .schedule-team-picker{display:none}
@media(min-width:601px){
 .game-shell #team-records table{table-layout:fixed}
 .game-shell #team-records :is(th,td):first-child{width:20%}
 .game-shell #team-records .game-list :is(th,td):is([data-label=시즌],[data-label=홈],[data-label=원정]){width:clamp(74px,6cqw,112px);padding-inline:.35em;text-align:center}
 .game-shell #team-records :is(th,td)[data-label="홈 · 원정 비교"]{width:auto;padding-inline:3%}
 .game-shell #standings :is(th,td)[data-label="다음 상대"]{width:16%;white-space:normal}
}
@media(min-width:601px) and (max-width:1023px){
 .game-shell #standings .game-list :is(td,th){font-size:12px;white-space:normal;min-width:0;padding-inline:2px}
 .game-shell #standings .form-marks{gap:1px;flex-wrap:wrap}
 .game-shell #standings :is(th,td)[data-label=승점]{width:34px}
}
@media(min-width:1024px){
 .game-shell nav button,.game-shell .record-tabs button,.game-shell .records-scope{font-size:clamp(13px,1.4cqh,16px)}
}
@media(max-width:600px){
 .game-shell #schedule-teams{display:none}
 .game-shell .schedule-team-picker,.game-shell #schedule-panel>label,.game-shell #scorers-panel>label,.game-shell #standings-panel>label{display:flex;align-items:center;gap:8px;margin:0 0 6px}
 .game-shell .schedule-team-picker select,.game-shell :is(#league-select,#scorers-league,#standings-league){width:auto;flex:1;min-width:0}
 .game-shell #schedule-days{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:3px}
 .game-shell #schedule-days button{padding:7px 0}
 .game-shell #standings tr td[data-label="다음 상대"]{grid-column:1/-1;color:#c4d0dd}
}
@media(min-width:601px){
 .game-shell #league-scorers table{table-layout:fixed}
 .game-shell #league-scorers :is(td,th)[data-label=순위]{width:7%}
 .game-shell #league-scorers :is(td,th):is([data-label=득점],[data-label=출전],[data-label=슈팅]){width:clamp(38px,4cqw,72px)}
 .game-shell #league-scorers :is(td,th):is([data-label="경기당 득점"],[data-label="득점 전환율"]){width:14%}
}
@media(max-width:600px){
 .game-shell #league-scorers tr td[data-label="경기당 득점"]{grid-column:1/3}
 .game-shell #league-scorers tr td[data-label="득점 전환율"]{grid-column:3/5;text-align:right}
}
.game-shell .match-roster :is(#starter-list,#match-bench) table.game-list {width:100%;min-width:0;table-layout:fixed}
.game-shell .match-roster :is(td,th):first-child {width:20%}
.game-shell .match-roster :is(td,th):last-child {width:23%;text-align:right}
.game-shell .match-tabs button[aria-selected=false]{background:#26394b;color:#c7d4de;border-color:#405569}
@media(min-width:1024px){
 .game-shell .match-roster .game-list :is(th,td){height:2.58cqh;padding:.18cqh .55cqw;font-size:clamp(12px,1.4cqh,16px);line-height:1.2}
 .game-shell #schedule-teams button,.game-shell #schedule-days button{font-size:clamp(12px,1.4cqh,16px)}
}
@media(max-width:600px){
 .game-shell #schedule-panel :is(#league-select,#schedule-team-picker){max-width:none}
}
.game-shell .team-record-toolbar{display:flex;justify-content:space-between;gap:8px;flex-wrap:wrap}
.game-shell .team-record-toolbar .record-tabs:last-child{margin-left:auto}
@media(max-width:600px){.game-shell #team-records :is(th,td){font-size:13px;overflow-wrap:anywhere}}
/* Recent team results: a shared scale keeps the paired bars comparable. */
.game-shell #team-form-chart{flex:none;color:#eaf3f4;min-width:0}
.game-shell .team-form-heading{display:flex;align-items:baseline;gap:12px;flex-wrap:wrap;line-height:1.25}
.game-shell .team-form-heading strong{font-size:15px;color:#fff}
.game-shell .team-form-heading span,.game-shell .team-form-legend{font-size:12px;color:#c1d2dd}
.game-shell .team-form-legend{margin-top:2px}
.game-shell .team-form-key{display:inline-block;width:8px;height:8px;border-radius:2px;margin:0 4px 0 8px}.game-shell .team-form-key:first-child{margin-left:0}
.game-shell .team-form-games{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:5px;list-style:none;margin:5px 0 0;padding:0}
.game-shell .team-form-game{display:grid;grid-template-columns:auto auto;justify-content:center;align-items:center;column-gap:5px;min-width:0;text-align:center;font-size:12px;line-height:1.2}
.game-shell .team-form-bars{grid-column:1/-1;height:45px;display:flex;align-items:flex-end;justify-content:center;gap:3px;border-bottom:1px solid #78909b}
.game-shell .team-form-bar{width:clamp(8px,1.4vw,17px);display:block;border-radius:2px 2px 0 0}
.game-shell .team-form-for{background:#73e1bb}.game-shell .team-form-against{background:#f5bf6e}
.game-shell .team-form-score{font-size:13px;font-variant-numeric:tabular-nums;color:#fff;white-space:nowrap}
.game-shell .team-form-result{font-weight:800;color:#b4c6d4}.game-shell .team-form-result[data-result=승]{color:#83e8c1}.game-shell .team-form-result[data-result=패]{color:#ffd18c}
.game-shell .team-form-opponent{grid-column:1/-1;display:block;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#d9e6ea}
.game-shell .team-form-empty{margin:8px 0;color:#c1d2dd;font-size:13px}
@media(max-width:600px){.game-shell .team-form-game{font-size:11px}.game-shell .team-form-heading span,.game-shell .team-form-legend{font-size:12px}.game-shell .team-form-bars{height:38px}}

/* Season overview and benchmark rows share the records board's edges and type scale. */
.game-shell .record-overview{display:grid;grid-template-columns:minmax(260px,.8fr) minmax(0,1.65fr);flex:none;border:1px solid #40586a;background:#172b39;margin-bottom:10px}
.game-shell .record-overview>section{min-width:0;padding:clamp(13px,1.55cqh,20px) clamp(15px,1.4cqw,28px)}
.game-shell #season-profile{background:linear-gradient(110deg,#183e43,#19323c);border-right:1px solid #40586a;display:flex;flex-direction:column;justify-content:center}
.game-shell .season-heading,.game-shell .team-form-heading{display:flex;align-items:center;justify-content:space-between;gap:9px}
.game-shell .season-heading h2,.game-shell .team-form-heading strong{font-size:clamp(15px,1.8cqh,20px);color:#f2f8fa;font-weight:700;line-height:1.2;margin:0}
.game-shell #season-played,.game-shell .team-form-heading span{font-size:clamp(12px,1.35cqh,15px);color:#c4d6df}
.game-shell #season-standing{display:flex;align-items:baseline;gap:4px;margin:8px 0 12px;color:#ecfffb;font-variant-numeric:tabular-nums}
.game-shell #season-standing strong{font-size:clamp(35px,4.6cqh,54px);line-height:1;letter-spacing:-.055em}
.game-shell #season-standing>span{font-weight:650}.game-shell #season-standing small{margin-left:3px;color:#b6ccd3}
.game-shell #season-standing .season-points{margin-left:auto;color:#acedd6;font-size:clamp(14px,1.65cqh,18px)}
.game-shell #season-distribution{display:flex;gap:2px;height:9px;overflow:hidden;border-radius:3px}
.game-shell #season-distribution:empty{display:none}
.game-shell #season-outcomes{display:flex;gap:clamp(12px,1.5cqw,28px);margin-top:8px;font-size:14px;color:#d3e3e7}
.game-shell #season-outcomes span{display:flex;align-items:baseline;gap:2px}
.game-shell #season-outcomes b{color:white;font-size:clamp(15px,1.85cqh,21px)}
.game-shell #season-outcomes span::before{content:'';width:8px;height:8px;align-self:center;background:var(--result-color);margin-right:4px}
.game-shell #season-profile .won{--result-color:#71d9b4}.game-shell #season-profile .drawn{--result-color:#a2b3c4}.game-shell #season-profile .lost{--result-color:#e9ae72}
.game-shell #season-distribution span{background:var(--result-color)}
.game-shell .team-form-legend{margin-top:5px}
.game-shell .team-form-games{gap:0;margin-top:6px}
.game-shell .team-form-game{justify-content:stretch;grid-template-columns:1fr 1fr;padding:0 8px;row-gap:3px;border-left:1px solid #314857}
.game-shell .team-form-game:first-child{border-left:0}
.game-shell .team-form-bars{height:clamp(32px,4.4cqh,54px);gap:4px;border-bottom:1px solid #49616e;background:linear-gradient(0deg,transparent 48%,#29404e 49%,#29404e 51%,transparent 52%)}
.game-shell .team-form-bar{width:clamp(10px,1.35cqw,25px)}
.game-shell .team-form-score{justify-self:end;font-size:clamp(13px,1.65cqh,18px)}
.game-shell .team-form-result{justify-self:start;align-self:center;padding:1px 4px;border-radius:3px;background:#314451}
.game-shell .team-form-opponent{font-size:clamp(12px,1.4cqh,15px)}
.game-shell .comparison-caption{display:flex;align-items:center;gap:14px;justify-content:space-between;margin:1px 0 6px;flex:none}
.game-shell .comparison-caption .records-scope{margin:0;font-size:12px;color:#b5c7d3}
.game-shell #comparison-key{display:flex;gap:14px;font-size:13px;color:#d7e5eb;white-space:nowrap}
.game-shell #comparison-key[hidden]{display:none}
.game-shell #comparison-key span{display:inline-flex;align-items:center;gap:6px}
.game-shell #comparison-key span::before{content:'';display:block;width:18px;height:6px;border-radius:1px;background:#72dcbb}
.game-shell #comparison-key span:nth-child(2)::before{width:3px;height:12px;background:#ffcd83}
.game-shell .comparison-metric{display:grid;grid-template-columns:clamp(88px,8cqw,150px) minmax(0,1fr);align-items:center;gap:15px}
.game-shell .metric-plot{display:block;position:relative;height:10px;background:#32495a;border-radius:2px;min-width:0}
.game-shell .metric-plot.signed{background:linear-gradient(to right,#32495a 49.8%,#c1d2de 50%,#32495a 50.2%)}
.game-shell .metric-plot::before,.game-shell .metric-plot::after{content:'';position:absolute}
.game-shell .metric-plot::before{inset-block:0;left:var(--start);width:var(--length);background:#70d5b6;border-radius:2px}
.game-shell .metric-plot::after{top:-3px;bottom:-3px;left:clamp(0px,var(--mean),calc(100% - 2px));width:3px;background:#ffd08b;box-shadow:0 0 0 1px #28363f}
.game-shell .metric-change{font-variant-numeric:tabular-nums}
.game-shell .metric-change[data-tone=positive]{color:#99f0cb}
.game-shell .metric-change[data-tone=negative]{color:#ffbba0}
.game-shell #team-records[data-mode=league] .game-list :is(th,td){text-align:right;font-variant-numeric:tabular-nums}
.game-shell #team-records[data-mode=league] .game-list :is(th,td):first-child{width:61%;text-align:left}
.game-shell #team-records[data-mode=league] .game-list td[data-label="내 팀"]{font-weight:700;color:#d7fff0}
.game-shell #team-records[data-mode=league] .game-list :is(th,td):last-child{padding-right:clamp(8px,2.2cqw,42px)}
@media(max-width:700px){
 .game-shell .record-overview{grid-template-columns:1fr}
 .game-shell .record-overview>section{padding:12px}
 .game-shell #season-profile{border-right:0;border-bottom:1px solid #40586a}
 .game-shell #season-standing{margin:5px 0 9px}
 .game-shell #season-outcomes{margin-top:5px}
 .game-shell .team-form-game{padding:0 3px;column-gap:2px}
 .game-shell .team-form-legend{margin-top:4px}
 .game-shell .team-form-bars{height:36px}
 .game-shell .team-form-score{font-size:13px}
 .game-shell .team-form-opponent{font-size:12px}
 .game-shell .comparison-caption{flex-wrap:wrap;gap:3px 12px}
 .game-shell #team-records[data-mode=league] .game-list :is(th,td):first-child{width:38%}
 .game-shell .comparison-metric{display:flex;flex-direction:column;align-items:stretch;gap:5px;padding-right:5px}
 .game-shell .metric-plot{height:5px}
 .game-shell .metric-plot::after{top:-2px;bottom:-2px;width:2px}
}
/* Recent-form graph controls and compact mobile names. */
.game-shell .team-form-controls{display:flex;gap:4px;margin-left:auto}
.game-shell .team-form-controls button{min-height:0;padding:3px 9px;font-size:12px;line-height:1.2}
.game-shell .team-form-controls button:not([aria-pressed=true]){background:#283d4e;color:#d9e6ea;border-color:#557080;box-shadow:none}
.game-shell .team-form-shot-value{grid-column:1/-1;grid-row:1;font-size:11px;color:#d9e6ea;font-variant-numeric:tabular-nums}
.game-shell .team-form-name-short{display:none}
.game-shell .team-form-game.latest .team-form-opponent{color:#a6eed4;font-weight:650}
@media(max-width:1023px){.game-shell .team-form-name-full{display:none}.game-shell .team-form-name-short{display:inline}.game-shell .team-form-opponent{white-space:normal;overflow-wrap:anywhere;line-height:1.15}}
.game-shell #team-reading:not([hidden]){display:flex;align-items:baseline;gap:12px;flex-wrap:wrap;padding:9px 13px;margin:0 0 7px;border-inline-start:3px solid #73ccaf;background:#1b343f;color:#e0efef;font-size:clamp(13px,1.5cqh,16px)}
.game-shell #team-reading>strong{color:#a0e4cd;font-size:.94em}
.game-shell #team-reading-text{display:flex;flex-wrap:wrap;align-items:baseline;gap:3px 18px}
@media(max-width:700px){
 .game-shell .team-record-toolbar{gap:6px;align-items:start}
 .game-shell .team-record-toolbar .record-tabs{gap:2px}
 .game-shell .team-record-toolbar .record-tabs button{padding:7px 5px;font-size:13px}
 .game-shell #team-reading:not([hidden]){align-items:flex-start;gap:4px 10px;padding:7px 9px}
 .game-shell #team-reading-text{gap:3px 12px}
}
.game-shell .team-form-shot-value{color:#dae9ed;font-size:clamp(12px,1.3cqh,15px)}
@media(min-width:701px){.game-shell #team-records[data-mode=league] .game-list :is(th,td):first-child{width:auto}.game-shell #team-records[data-mode=league] .game-list :is(th,td):not(:first-child){width:clamp(98px,8.7cqw,168px)}}
@media(max-width:700px){.game-shell .team-form-controls button{min-height:28px}}
.game-shell .player-card .card-portrait.card-photo,.game-shell #expanded-portrait .card-photo{width:100%;height:100%;object-fit:contain;object-position:center bottom}
.game-shell #discord-entry{max-width:420px;margin-bottom:16px}
.game-shell .discord-action{display:inline-flex;justify-content:center;align-items:center;min-height:42px;padding:8px 22px;background:#4752c4;border:1px solid #8290fa;border-radius:5px;color:white;font-weight:650;text-decoration:none}
.game-shell .discord-action:hover,.game-shell .discord-action:focus-visible{background:#3944ab}
.game-shell #discord-settings{margin-bottom:14px}
.game-shell #discord-settings h3{margin:0 0 8px}
.game-shell #discord-entry p,.game-shell #discord-settings p{font-size:14px;color:#c1d3df;margin:7px 0 0}
.game-shell #discord-status{margin-inline-end:6px}
/* Locker overview and club messages. */
.locker-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.32fr) minmax(0,2fr);gap:16px;min-height:0;height:100%}.locker-summary-column{display:flex;flex-direction:column;gap:14px;min-width:0}.locker-box{min-width:0;background:#1c2b39;border:1px solid #304454;border-radius:8px;padding:18px}.locker-summary h1{font-size:25px;margin:0 0 4px}.locker-league{color:#68d4a0;font-weight:700;margin-bottom:12px}.locker-summary-row,.locker-rank-row{display:flex;justify-content:space-between;align-items:center;gap:8px;border-top:1px solid #344453;padding:9px 0}.locker-summary-row>span,.locker-next h2,.locker-rank h2,.inbox-header h2{color:#a9bac9}.locker-summary-row #locker-fans{background:none;border:0;color:inherit;padding:0;text-align:right}.locker-summary-row #locker-record table{width:auto}.locker-summary-row #locker-record th{display:none}.locker-summary-row #locker-record td{padding:0 2px;border:0}.locker-summary-row #content-balance{color:#ffd36a;font-weight:700}.locker-result{display:inline-block;border-radius:3px;padding:2px 5px;margin-left:3px;color:#102932;font-weight:700}.result-W{background:#62cc93}.result-D{background:#adbac7}.result-L{background:#e9787e}.locker-next #locker-next-match{background:#253d50;border-radius:6px;padding:12px}.locker-next #locker-next-match span,.locker-next #locker-next-match strong{display:block}.locker-next-time{font-size:12px;color:#b4c6d4}.locker-actions{display:flex;gap:6px;margin-top:10px}.locker-rank-row.own{color:#6dd4a3;font-weight:700}.inbox-list-panel,.inbox-detail{display:flex;flex-direction:column;min-height:0}.inbox-header{display:flex;align-items:center;gap:8px}.inbox-header h2{margin:0;flex:1}.inbox-header #inbox-unread{color:#a9bac9}.inbox-filters{display:flex;flex-wrap:wrap;gap:5px;margin:10px 0}.inbox-filters button{background:#2a3d4d;color:#c9d7df;border-radius:20px}.inbox-filters button[aria-pressed=true]{background:#267d69;color:white}.inbox-list{overflow-y:auto;min-height:0;flex:1}.inbox-item{display:flex;align-items:center;width:100%;gap:9px;text-align:left;background:transparent;border:0;border-bottom:1px solid #344453;border-radius:4px;color:#dce5eb;padding:10px 5px}.inbox-item[aria-pressed=true]{background:#294154}.inbox-dot{flex:0 0 7px;width:7px;height:7px;border-radius:50%;background:transparent}.inbox-item.unread .inbox-dot{background:#68d4a0}.inbox-avatar{display:grid;place-items:center;flex:0 0 38px;width:38px;height:38px;border-radius:50%;background:#68cba0;color:#142c33;font-weight:800}.inbox-item-copy{display:flex;flex-direction:column;min-width:0}.inbox-item-copy strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.inbox-meta{font-size:11px;color:#a9bac9}.inbox-detail{overflow:auto}.inbox-detail-header{display:flex;align-items:center;gap:12px;border-bottom:1px solid #354657;padding-bottom:14px;color:#bdccd5}.inbox-detail h2{font-size:22px;margin:18px 0}.inbox-body{white-space:pre-wrap;color:#dce5eb}.inbox-facts{display:grid;grid-template-columns:1fr 1fr;gap:10px;background:#253d50;padding:14px;border-radius:6px}.inbox-facts dd{margin:0;text-align:right}.inbox-retention{font-size:12px}.locker-badge{display:inline-block;border-radius:100%;background:#df6079;padding:0 5px;color:#fff;font-size:11px}.inbox-empty{color:#a9bac9}.inbox-detail #inbox-back{display:none}
@media(min-width:1024px){.game-shell #locker-panel:not([hidden]){display:flex;flex-direction:column;overflow:hidden}.locker-layout{flex:1}.locker-box{padding:1.3cqh .9cqw}.locker-summary-column{gap:1cqh}.locker-summary h1{font-size:2.2cqh}.locker-summary-row,.locker-rank-row{padding:.55cqh 0}.inbox-filters{margin:.7cqh 0}.inbox-item{padding:.65cqh .3cqw}.inbox-avatar{width:3.5cqh;height:3.5cqh;flex-basis:3.5cqh}.inbox-detail h2{font-size:2cqh}}
@media(max-width:1023px){.locker-layout{display:flex;flex-direction:column;height:auto}.inbox-list{overflow:visible}.inbox-detail{display:none}.inbox-reading .locker-summary-column,.inbox-reading .inbox-list-panel{display:none}.inbox-reading .inbox-detail{display:block;min-height:70vh}.inbox-detail #inbox-back{display:block;background:transparent;color:#68d4a0;border:0;padding:0 0 15px}.inbox-filters{flex-wrap:wrap}.locker-summary-row #locker-record{overflow:visible}}

#squad-panel #squad-summary,#squad-panel #squad-save {
 background:#192b39;border:1px solid #43596a;padding:8px 10px;
}
#squad-panel #squad-summary {border-bottom:0;border-radius:6px 6px 0 0}
#squad-panel #squad-summary h3 {margin:0 0 4px;font-size:13px;color:#bed1db}
#squad-summary dl {display:flex;gap:12px;margin:0}
#squad-summary dl div {display:flex;align-items:baseline;gap:6px}
#squad-summary dt {color:#bed1db;font-size:12px}
#squad-summary dd {margin:0;color:#99e2bd;font-weight:700;font-variant-numeric:tabular-nums}
#squad-panel #squad-save {border-radius:0 0 6px 6px}
#player-card-dialog .expanded-data {min-width:0}
#player-card-dialog #expanded-abilities {gap:0}
#player-card-dialog .expanded-ability {padding:8px;border-bottom:1px solid #354b5c}
#player-card-dialog .primary-ability {background:#23473e;color:#cdf0d9;font-weight:700}
#player-card-dialog .primary-ability meter::-webkit-meter-optimum-value {background:#8cd7ac}
@media(max-width:600px){
 #player-card-dialog .expanded-identity {width:100%;display:grid;grid-template-columns:84px minmax(0,1fr);align-items:center}
 #player-card-dialog #expanded-portrait {height:100px;grid-row:1/3}
 #player-card-dialog #expanded-name {text-align:left;margin:10px 12px 0}
 #player-card-dialog #expanded-fitness {padding:4px 12px 12px}
 #player-card-dialog .expanded-identity>span {font-size:13px;padding:3px 5px}
 #player-card-dialog .player-dialog-body {gap:12px}
 #player-card-dialog .card-detail-tabs {margin-bottom:6px}
}
#content-card-detail .content-card-actions {flex:1;min-width:0;padding:10px;background:#192b39;border:1px solid #43596a;border-radius:6px}
#content-card-detail .content-card-actions :is(h2,p,dl,dd) {margin:0}
#content-card-detail .content-card-actions h2 {font-size:20px;line-height:1.2}
#content-card-detail .detail-position,#content-card-detail .detail-growth dt {color:#b8cbd9;font-size:13px}
#content-card-detail .detail-growth {display:grid;grid-template-columns:repeat(3,1fr);gap:6px;border-block:1px solid #415362;padding:8px 0}
#content-card-detail .detail-growth dd {font-size:18px;font-weight:700}
#content-card-detail .detail-xp {display:grid;gap:4px;font-size:13px}
#content-card-detail .detail-xp :is(progress,meter) {width:100%;height:8px;accent-color:#87c8af}
@media(max-width:560px){
 #content-card-detail .content-card-actions {flex:none;box-sizing:border-box;max-width:none}
}
#players-panel #player-detail {padding:14px;background:#192b39;border:1px solid #43596a;border-radius:6px;align-self:start}
#players-panel #player-detail :is(h3,h4,p,dl,dd) {margin:0}
#players-panel #player-detail p {color:#b8cbd9;margin:4px 0 12px}
#players-panel #player-detail label {display:grid;gap:4px}
#players-panel #player-detail meter {width:100%}
#players-panel #player-detail h4 {margin:16px 0 6px}
#players-panel #player-detail dl {display:grid;grid-template-columns:repeat(auto-fit,minmax(58px,1fr));gap:5px}
#players-panel #player-detail dl div {padding:6px;background:#243a4a}
#players-panel #player-detail dt {font-size:12px;color:#bfd0dc}
#players-panel #player-detail dd {font-size:18px;font-weight:bold}
#content-card-detail .detail-actions-group {display:grid;gap:6px;padding-top:8px;border-top:1px solid #415362}
#content-card-detail .detail-actions-group h3 {font-size:14px;margin:0}
#content-card-detail .detail-actions-group p {color:#c4d2dd;font-size:13px}
#content-card-detail .detail-actions-group progress {width:100%;height:7px;accent-color:#8dc3dd}
#content-card-detail .detail-actions-group button {min-height:36px}
#content-card-detail .detail-actions-group button:last-child:not(:first-of-type) {background:#453140;color:#ffced2;border-color:#80555f}
@media(min-width:1024px){
 #squad-panel .lineup-group {grid-template-columns:minmax(0,1fr) minmax(0,17cqw)}
 #squad-panel #bench {flex:1 1 auto;min-height:0;grid-template-columns:repeat(3,minmax(0,1fr));align-content:start}
 #squad-panel :is(#formation,#bench) .content-card-name {bottom:8px;height:auto;align-content:center;line-height:1.1;font-size:clamp(10px,10cqh,13px)}
}

/* The one-off placement action stays inside the lineup pitch. */
.game-shell #formation{position:relative}
.game-shell #lineup-arrange{position:absolute;z-index:2;inset-block-start:8px;inset-inline-end:8px;min-height:36px;padding:.4em .7em}
.game-shell #fixture-lineup{margin-block:4px;font-size:.85em;color:var(--muted)}
.game-shell #fixture-lineup summary{cursor:pointer;color:var(--ink)}
.game-shell #fixture-lineup p{margin:.35em 0}
.game-shell #rotation-warning{color:#ffe2a1}
.game-shell .fixture-lineup-actions{display:flex;flex-wrap:wrap;gap:4px}
@media(max-width:1023px){.game-shell #formation{padding-block-start:50px}}

/* Compact, sample-labelled comparisons above the full records tables. */
.game-shell .record-insight{display:flex;flex-wrap:wrap;align-items:baseline;gap:6px 16px;padding:9px 12px;margin:0 0 8px;border-left:3px solid #70cda5;background:#203b42;color:#e3f4ee;font-size:13px;line-height:1.35}
.game-shell .record-insight strong{color:#a8e9ca}.game-shell .record-insight small{color:#bdcfc9;font-size:11px}
@media(max-width:700px){.game-shell .record-insight{display:grid;gap:4px;padding:9px 10px}}

/* Shared game shell palette and number alignment from the club design guide. */
body.game-shell {
 --bg:#16202b;--panel:#1f2a36;--ink:#e6e9ee;--muted:#9aa4b1;--line:#2a3846;--accent:#1f8f6a;
 --menu-selected:#24384a;--chrome:#111a24;--section-gap:8px;
 font-variant-numeric:tabular-nums;
}
.game-shell .game-frame {background:var(--bg);color:var(--ink)}
.game-shell .shell-top .topbar {background:var(--chrome)}
.game-shell .shell-top :is(#navigation,#subnavigation) button[aria-current=true] {background:var(--menu-selected);color:var(--ink);box-shadow:inset 0 -3px #5fc489}
.game-shell .content-area>section.card {background-color:var(--panel);border-color:var(--line)}
