/* v38: scoped interaction polish. Artwork, rarity frames and the resume scene
   retain their original colors. Arctic base #35BED5; ice highlight #85F9F0. */
:root{
 --arctic-blue:#35bed5;
 --arctic-ice:#85f9f0;
 --arctic-shine:linear-gradient(115deg,#35bed5 0%,#85f9f0 43%,#d8fffc 50%,#60e6e7 60%,#2facc9 100%);
 --arctic-ink:#062b37;
}

/* The selected Magic mode keeps its purple world, with the requested navigation accents. */
body.magic-view .navigation-rail .gameday-button{
 background:var(--arctic-shine)!important;
 border-color:#b9fff4;color:var(--arctic-ink)!important;
 box-shadow:inset 0 1px 0 #efffffad,0 0 20px #59e4ef35;
 text-shadow:none;
}
body.magic-view .navigation-rail .top-nav button,
body.magic-view .navigation-rail .top-nav button.active{
 color:#ffe39b;
 text-shadow:0 1px 1px #3b250b,0 0 15px #f7d27625;
}
body.magic-view .navigation-rail .top-nav button>span{color:#e9c975}
body.magic-view .navigation-rail .top-nav button:hover,
body.magic-view .navigation-rail .top-nav button:focus-visible{color:#fff3c8}

/* Cards and their purchase controls share one exact column track. */
body .magic-pool-grid{align-items:start}
body .magic-pool-grid>.magic-pool-entry{
 min-width:0;width:100%;align-items:stretch;justify-self:stretch;
}
body .magic-pool-grid>.magic-pool-entry>.magic-card{
 width:100%;max-width:none;box-sizing:border-box;margin:0 auto;align-self:stretch;flex:none;
}
body .magic-pool-grid>.magic-pool-entry>.magic-card>.magic-card-face{width:100%;min-width:0}
body .magic-pool-grid>.magic-pool-entry>.btn{width:100%;box-sizing:border-box;margin:0;min-height:46px;font-size:15px}
body .magic-pool-grid .magic-card-header{min-height:88px}
body .magic-pool-grid .magic-card-header strong{font-size:clamp(28px,2.3vw,38px);line-height:1.1}
body .magic-pool-grid .magic-card-art{height:clamp(240px,21vw,340px)}

/* Keep the remove control at the right while centering the label geometrically. */
body .magic-deck-builder .magic-deck-expanded-selection .magic-deck-featured-heading{
 position:relative;display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:8px;
}
body .magic-deck-builder .magic-deck-expanded-selection .magic-deck-featured-heading>small{
 grid-column:2;grid-row:1;text-align:center;justify-self:center;margin:0;font-size:12px;letter-spacing:.1em;
}
body .magic-deck-builder .magic-deck-expanded-selection .magic-deck-featured-remove{grid-column:3;grid-row:1;justify-self:end}
body .magic-deck-builder .magic-deck-slot.is-empty{cursor:pointer}
body .magic-deck-builder .magic-deck-slot.is-empty:hover{border-color:#93e8e4;background:#28434b4d;color:#e4fbff}
body .magic-deck-builder .magic-deck-slot.is-empty strong{font-size:clamp(22px,2vw,30px)}

/* Starting roster choices never share their click area with a purchase or inspect action. */
.roster-starter-card{position:relative;min-width:0;display:flex;flex-direction:column}
.roster-starter-card>.roster-card{width:100%;height:100%;box-sizing:border-box}
.roster-starter-remove{
 position:absolute;z-index:4;top:9px;right:9px;width:30px;height:30px;display:grid;place-items:center;
 padding:0;border:1px solid #8aafc0;border-radius:50%;background:#102331ef;color:#e6faff;
 font:700 22px/1 var(--sans,system-ui);cursor:pointer;opacity:0;transition:opacity .15s,border-color .15s;
}
.roster-starter-card:hover>.roster-starter-remove,
.roster-starter-card:focus-within>.roster-starter-remove{opacity:1}
.roster-starter-remove:hover{background:#244453;border-color:#b6f6ee}
.roster-starter-remove:focus-visible{outline:3px solid #85f9f0;outline-offset:3px;opacity:1}

/* Owned-player selection: large, deliberate targets, with no horizontal scrolling. */
#modal.lineup-picker-dialog{width:min(1320px,calc(100vw - 32px));max-width:calc(100vw - 32px)}
.lineup-picker-dialog .modal-title-row{justify-content:center}
.lineup-picker-dialog .modal-heading-copy{text-align:center}
.lineup-picker-dialog .modal-head h2{font-size:clamp(34px,4vw,54px)}
.lineup-picker-dialog .modal-body{padding:clamp(16px,2.5vw,30px)}
.lineup-picker-grid,.half-bench-grid{
 display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr));gap:18px;align-items:stretch;
}
.lineup-picker-grid[data-count="1"]{max-width:540px;margin:auto}
.lineup-picker-grid[data-count="2"]{max-width:920px;margin:auto}
.lineup-picker-card,.half-bench-card{
 appearance:none;position:relative;display:flex;flex-direction:column;align-items:center;gap:14px;min-width:0;
 padding:24px 20px 18px;border:1px solid #5598a9;border-radius:18px;
 background:radial-gradient(ellipse at top,#2e64733b,transparent 65%),linear-gradient(145deg,#172c3b,#101d2b);
 color:#effaff;text-align:center;font:inherit;cursor:pointer;box-shadow:inset 0 1px #d9ffff0f,0 8px 24px #0002;
 transition:border-color .15s,background-color .15s,box-shadow .15s;
}
.lineup-picker-card:hover,.half-bench-card:hover{
 border-color:#9df8ed;background-color:#254856;box-shadow:inset 0 0 0 1px #85f9f055,0 8px 26px #0004;
}
.lineup-picker-card:focus-visible,.half-bench-card:focus-visible{outline:3px solid #85f9f0;outline-offset:3px}
.lineup-picker-card :is(.profile-photo,.lineup-picker-photo){
 position:relative;display:block;width:clamp(120px,13vw,180px);height:clamp(145px,15vw,205px);max-width:100%;
 margin:0 auto;border-radius:13px;background:#183344;overflow:hidden;border:1px solid #91c9d443;
}
.lineup-picker-card :is(.profile-photo,.lineup-picker-photo) img{width:100%;height:100%;object-fit:cover;object-position:center top}
.lineup-picker-copy{display:grid;gap:7px;width:100%;min-width:0}
.lineup-picker-copy>strong,.half-bench-card>strong{
 display:block;font:800 clamp(26px,2.4vw,34px)/1.12 var(--serif,sans-serif);color:#f1fbff;overflow-wrap:anywhere;
}
.lineup-picker-copy>small,.lineup-picker-copy>span,.half-bench-card>small{font-size:14px;line-height:1.45;color:#b2d4e2}
.lineup-picker-stats{display:flex;flex-wrap:wrap;justify-content:center;gap:10px 18px;font-size:16px;color:#b5eef1;font-variant-numeric:tabular-nums}
.lineup-picker-stats :is(strong,b){font-size:23px;color:#9af1e9}
.lineup-picker-choose,.half-bench-card>span:last-child{
 display:block;align-self:stretch;margin-top:auto;padding:13px 12px;border:1px solid #8debd282;border-radius:9px;
 background:#234b535c;color:#a9fff0;font-size:16px;font-weight:850;line-height:1.4;
}
.lineup-picker-empty{padding:44px 20px;border:1px dashed #547487;border-radius:16px;text-align:center;background:#132432}
.lineup-picker-empty h3{font-size:30px;margin:0 0 10px}.lineup-picker-empty p{font-size:17px;color:#bdd4e0;line-height:1.5}

/* Portraits remain recognizable at normal size and in the compact Magic strip. */
.lineup-portraits{overflow:visible}
.lineup-portraits .lineup-portrait .team-highlight-image{width:clamp(100px,9.2vw,164px)}
.lineup-portraits.is-compact{padding:22px 24px 24px}
.lineup-portraits.is-compact .lineup-portrait-grid{gap:18px}
.lineup-portraits.is-compact .lineup-portrait .team-highlight-image{width:clamp(76px,7.2vw,108px);margin-bottom:12px}
.lineup-portraits.is-compact .lineup-portrait .team-highlight-role{font-size:11px}
.lineup-portraits.is-compact .lineup-portrait strong{font-size:15px}
.lineup-portraits.is-compact .lineup-portrait small{font-size:12px}
.franchise-effect-popover{position:relative;min-width:0}
.franchise-effect-trigger{display:block;list-style:none;cursor:pointer;border-radius:13px;outline-offset:6px}
.franchise-effect-trigger::-webkit-details-marker{display:none}
.franchise-effect-trigger:focus-visible{outline:2px solid #9cf4e6}
.franchise-effect-panel{
 display:none;position:absolute;z-index:60;top:calc(100% + 12px);left:50%;transform:translateX(-50%);
 width:min(340px,calc(100vw - 40px));box-sizing:border-box;padding:19px 20px;border:1px solid #75b7c3;
 border-radius:13px;background:#102431;color:#dbedf3;text-align:left;box-shadow:0 15px 45px #0009;
 font-size:14px;line-height:1.5;
}
.franchise-effect-panel::before{content:"";position:absolute;bottom:100%;left:0;right:0;height:14px}
.franchise-effect-popover:hover>.franchise-effect-panel,
.franchise-effect-popover:focus-within>.franchise-effect-panel,
.franchise-effect-popover[open]>.franchise-effect-panel{display:block}
.lineup-portrait-grid>.lineup-portrait:first-child .franchise-effect-panel{left:0;transform:none}
.lineup-portrait-grid>.lineup-portrait:last-child .franchise-effect-panel{left:auto;right:0;transform:none}
.franchise-effect-panel h3,.franchise-effect-panel h4{font-family:var(--sans,system-ui);font-size:15px;line-height:1.4;color:#ffe39b;margin:0 0 10px}
.franchise-effect-panel section+section{margin-top:15px;padding-top:14px;border-top:1px solid #7fb7c32b}
.franchise-effect-list{margin:0;padding-left:18px;display:grid;gap:8px}
.franchise-effect-panel p{font-size:14px;margin:8px 0;color:#c4dce7}
.franchise-effect-panel strong{font-size:inherit;display:inline;line-height:inherit;color:#b6f5e8}

/* Player inspection uses the existing card art alongside concise structured rules. */
#modal.magic-profile-dialog>.modal-head{position:relative;padding:24px 72px;text-align:center;justify-content:center}
.magic-profile-dialog .modal-heading-copy{width:100%;min-width:0}
.magic-profile-dialog .modal-title-row{justify-content:center;align-items:center}
.magic-profile-dialog .modal-head h2{
 width:100%;margin:0;text-align:center;text-transform:uppercase;letter-spacing:.035em;
 font-size:clamp(36px,4.6vw,68px);line-height:1.05;overflow-wrap:anywhere;
}
.magic-profile-dialog>.modal-head>.close{position:absolute;top:20px;right:20px}
.magic-profile-dialog .magic-profile-layout{
 max-width:1320px;grid-template-columns:minmax(280px,.85fr) minmax(0,1.15fr);gap:clamp(24px,3vw,44px);
}
.magic-profile-dialog .magic-profile-portrait-controls{align-items:center;width:100%}
.magic-profile-dialog .magic-profile-portrait-controls>.magic-card{
 width:100%;max-width:560px;box-sizing:border-box;margin:0 auto;
}
.magic-profile-dialog .magic-profile-portrait-controls>.btn{
 width:100%;max-width:560px;min-height:54px;box-sizing:border-box;margin:0 auto;
 font-size:17px;line-height:1.3;padding:14px 18px;white-space:normal;
}
.magic-profile-dialog .magic-profile-portrait-controls>.magic-starter-select{
 background:var(--arctic-shine)!important;border-color:#b9fff4;color:var(--arctic-ink)!important;
 box-shadow:inset 0 1px #efffffad,0 0 14px #59e4ef24;font-weight:900;
}
.magic-profile-dialog .magic-profile-layout>section{padding:0;min-width:0}
.magic-profile-dialog .magic-profile-abilities{margin:0;gap:18px}
.magic-profile-dialog .magic-profile-abilities .ability-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:0}
.magic-profile-dialog .magic-profile-abilities .ability-summary-chip{
 display:flex;justify-content:center;align-items:center;min-height:66px;box-sizing:border-box;
 padding:14px 10px;font-size:clamp(17px,1.65vw,23px);line-height:1.25;letter-spacing:0;text-align:center;
 border-color:#78d4dc80;border-radius:11px;background:linear-gradient(130deg,#1f4855,#152e3c);color:#baf9fa;
}
.magic-profile-rules{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;align-items:start}
.magic-profile-rules>.magic-attribute:first-child{grid-column:1/-1}
.magic-profile-dialog .magic-profile-rules>.magic-attribute{height:100%;box-sizing:border-box;padding:18px 19px;gap:8px;margin:0}
.magic-profile-dialog .magic-profile-abilities .magic-attribute,
.magic-profile-dialog .magic-profile-abilities .magic-attribute p,
.magic-profile-dialog .magic-profile-abilities .ability-paragraph{font-size:17px;line-height:1.5}
.magic-profile-dialog .magic-profile-abilities .ability-item-heading>b{font-size:20px!important;line-height:1.25}
.magic-profile-dialog .magic-profile-abilities .ability-kind{font-size:11px;margin-bottom:4px}
.magic-profile-dialog .magic-profile-abilities .ability-command-cost{font-size:14px;padding:5px 8px}
.magic-profile-dialog .magic-profile-abilities .ability-fine-print{font-size:14px;line-height:1.5;padding-top:12px;margin-top:12px}
.magic-profile-dialog .magic-profile-layout .magic-profile-lore{font-size:17px!important;line-height:1.5!important;margin:22px 0}
.magic-profile-dialog .magic-profile-layout>section>.btn{min-height:48px;white-space:normal;text-align:center}
.profile-career-scope .profile-filter-display{gap:6px}
.profile-career-scope .profile-filter-value{font-size:17px;color:#e8f8ff;font-weight:800;letter-spacing:0;text-transform:none}
.profile-career-scope .profile-filter-coverage{font-size:14px;font-weight:500;color:#bed5e1;line-height:1.5;letter-spacing:0;text-transform:none}

/* Halftime controls stay together, with evenly sized hit areas. */
body .battle-match-navigation.phase-match-navigation,.phase-summary .battle-match-navigation{
 display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;align-items:stretch;
 width:min(100%,720px);margin:0 0 20px auto;
}
body .battle-match-navigation.phase-match-navigation>.btn,.phase-summary .battle-match-navigation>.btn{
 display:flex;align-items:center;justify-content:center;min-width:0;width:100%;min-height:48px;
 padding:12px 10px;box-sizing:border-box;text-align:center;font-size:15px;line-height:1.25;white-space:normal;
}
.half-substitutions{margin:24px 0;padding:24px;border:1px solid #4d8597;border-radius:17px;background:linear-gradient(120deg,#142e3b,#101f2c)}
.half-substitutions>header{position:static;display:flex;justify-content:space-between;align-items:center;gap:14px;height:auto;min-height:0;padding:0;margin:0 0 12px;background:none;box-shadow:none}
.half-substitutions>header h2{font-size:30px;line-height:1.15;margin:0}
.half-substitution-count{flex:none;border:1px solid #88d7d96b;border-radius:8px;padding:8px 12px;font-size:15px;font-weight:800;color:#a5f4e9;background:#224653}
.half-substitutions>p,.half-bench-context{font-size:16px;line-height:1.55;color:#bdd7e3;margin:0 0 20px}
.half-substitution-starters{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,220px),1fr));gap:12px}
.half-substitution-starter{
 display:grid;grid-template-columns:52px minmax(0,1fr);grid-template-rows:auto auto;gap:5px 12px;align-items:center;
 min-width:0;min-height:88px;padding:14px;border:1px solid #578394;border-radius:11px;background:#183541;
 color:#effaff;text-align:left;font:inherit;cursor:pointer;
}
.half-substitution-starter>.phase-player-avatar{width:52px;height:62px;grid-column:1;grid-row:1/3}
.half-substitution-starter>strong{font-size:17px;line-height:1.3;overflow-wrap:anywhere}
.half-substitution-starter>small{font-size:13px;line-height:1.4;color:#a9d3df}
.half-substitution-starter:hover:not(:disabled){border-color:#9af4e5;background:#244958}
.half-substitution-starter:focus-visible{outline:3px solid #85f9f0;outline-offset:3px}
.half-substitution-starter:disabled{opacity:.55;cursor:default}
.half-bench-card>.phase-player-avatar{width:100px;height:120px;border-radius:12px}

/* Only arena chrome is tinted. Heatseeker, silver signatures, player images,
   the stadium asset/filter, and the purple resume background remain untouched. */
.combat-arena.combat-live{
 --combat-aqua:#85f9f0;
 --combat-control-surface:linear-gradient(125deg,#173e52e8,#10293be8);
 --combat-control-edge:#77d8e080;
}
.combat-arena.combat-live .combat-side-fields .combat-unit-commands>.combat-protect{
 background:var(--arctic-shine)!important;color:var(--arctic-ink)!important;border-color:#b9fff4;
 box-shadow:inset 0 1px 0 #efffffad,0 0 13px #59e4ef22;text-shadow:none;
}
.combat-arena.combat-live .combat-side-fields .combat-unit-commands>.combat-protect strong,
.combat-arena.combat-live .combat-side-fields .combat-unit-commands>.combat-protect small{color:inherit}
.combat-arena.combat-live .combat-side-fields .combat-unit-commands>.combat-move,
.combat-arena.combat-live .combat-sideline-return.btn{
 background:var(--combat-control-surface)!important;border-color:var(--combat-control-edge);color:#baf9f6!important;
 box-shadow:inset 0 1px #b9ffff24;text-shadow:none;
}
.combat-arena.combat-live .combat-side-fields .combat-unit-commands>.combat-move>strong{color:#c8fbff}
.combat-arena.combat-live .combat-drag-handle{
 background:linear-gradient(110deg,#17506a,#133a50);border-color:#80dbe282;color:#befaff;
 box-shadow:inset 0 1px #c4ffff1a;
}
.combat-arena.combat-live :is(.combat-drag-tray,.combat-drag-ghost){background:#102f42f5;border-color:#8ce5ec;color:#d4ffff}
.combat-arena.combat-live .combat-drag-tray>div{border-color:#7bdde6;color:#c3faff}
.combat-arena.combat-live .combat-drop-hover{border-color:#9cfff2!important;box-shadow:inset 0 0 0 2px #79e2ee66,0 0 24px #35bed533}
.combat-arena.combat-live .combat-header-toggle{background:var(--combat-control-surface);border-color:var(--combat-control-edge);color:#c1e9ef}
.combat-arena.combat-live .combat-header-toggle:hover{background:linear-gradient(110deg,#235569,#173748);border-color:#b4f7f2}
.combat-arena.combat-live .combat-header-toggle>small{color:#bad8e5}
.combat-arena.combat-live .combat-header-teams{color:#e9fcff}
.combat-arena.combat-live .combat-header-teams>b{color:#9dcddd}
.combat-arena.combat-live .combat-command-button{
 background:linear-gradient(105deg,#102d40f2 8%,#143749ed 48%,#14374990),var(--command-art,none) 78% 45%/cover;
 border-color:#89d5e08c;box-shadow:inset 0 1px #b9faff2b,0 7px 24px #06132070;color:#e8ffff;
}
.combat-arena.combat-live .combat-command-button small{color:#badce9}
.combat-arena.combat-live .combat-command-button:not(:disabled):hover{border-color:#b9fff4;box-shadow:inset 0 1px #e0ffff55,0 5px 25px #35bed530}
.combat-arena.combat-live .combat-command-button.pressure{border-color:#85f9f0b3;background:linear-gradient(115deg,#1b556b,#183b52)}
.combat-arena .combat-command-deck[data-compact-commands] .combat-basic-commands:has(.pressure){grid-template-columns:repeat(4,minmax(0,1fr))}
.combat-keyword.is-mvp,.combat-keyword.tone-mvp{--keyword-ink:#fff0b1;--keyword-edge:#e5cc7d9c;--keyword-bg:#28494f;box-shadow:inset 0 1px #fff0c52e,0 0 12px #6ad8e316}
:is(.combat-arena,.magic-card,.magic-profile-abilities) .ability-token.is-mvp{color:#ffe39b}

@media(min-width:1600px){
 .lineup-portraits .lineup-portrait .team-highlight-image{width:164px}
 .lineup-portraits.is-compact .lineup-portrait .team-highlight-image{width:108px}
}
@media(max-width:1100px){
 .magic-profile-dialog .magic-profile-layout{grid-template-columns:minmax(260px,.8fr) minmax(0,1.2fr);gap:24px}
 .magic-profile-rules{grid-template-columns:minmax(0,1fr)}
 .magic-profile-dialog .magic-profile-abilities .ability-summary-chip{font-size:17px;padding:12px 7px;min-height:60px}
}
@media(max-width:850px){
 .lineup-portraits .lineup-portrait .team-highlight-image{width:clamp(96px,18vw,140px)}
 .lineup-portraits.is-compact .lineup-portrait-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:24px 16px}
 .lineup-portraits.is-compact .lineup-portrait .team-highlight-image{width:clamp(76px,14vw,102px)}
 .lineup-portrait-grid>.lineup-portrait:nth-child(3n+1) .franchise-effect-panel{left:0;right:auto;transform:none}
 .lineup-portrait-grid>.lineup-portrait:nth-child(3n) .franchise-effect-panel{left:auto;right:0;transform:none}
}
@media(max-width:700px){
 .magic-profile-dialog .magic-profile-layout{grid-template-columns:minmax(0,1fr);max-width:560px;gap:24px}
 #modal.magic-profile-dialog>.modal-head{padding:20px 52px}
 .magic-profile-dialog>.modal-head>.close{top:15px;right:12px}
 .magic-profile-dialog .magic-profile-abilities .ability-summary-chip{font-size:19px;min-height:64px}
 .magic-profile-dialog .magic-profile-rules>.magic-attribute{padding:17px}
 .magic-profile-dialog .modal-body{max-height:calc(100dvh - 130px)}
 body .battle-match-navigation.phase-match-navigation,.phase-summary .battle-match-navigation{gap:7px;width:100%;margin-bottom:16px}
 body .battle-match-navigation.phase-match-navigation>.btn,.phase-summary .battle-match-navigation>.btn{font-size:12px;padding:10px 5px;min-height:48px}
 .half-substitutions{padding:18px}
 .half-substitutions>header{align-items:flex-start;flex-wrap:wrap}
 .half-substitutions>header h2{font-size:27px}
 .half-substitution-starters{grid-template-columns:repeat(2,minmax(0,1fr))}
 .half-substitution-starter{grid-template-columns:42px minmax(0,1fr);padding:10px;gap:5px 9px}
 .half-substitution-starter>.phase-player-avatar{width:42px;height:52px}
 .half-substitution-starter>strong{font-size:15px}
 .half-substitution-starter>small{font-size:12px}
 .combat-arena .combat-command-deck[data-compact-commands] .combat-basic-commands:has(.pressure){grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .combat-arena .combat-command-deck[data-compact-commands] .combat-basic-commands:has(.pressure) .combat-command-button{min-height:62px;padding:10px 8px}
 .combat-arena .combat-command-deck[data-compact-commands] .combat-basic-commands:has(.pressure) .combat-command-button strong{font-size:15px}
 .combat-arena .combat-command-deck[data-compact-commands] .combat-basic-commands:has(.pressure) .combat-command-button small{display:block;font-size:11px}
}
@media(max-width:600px){
 #modal.lineup-picker-dialog{width:calc(100vw - 16px);max-width:calc(100vw - 16px)}
 .lineup-picker-grid,.half-bench-grid{grid-template-columns:minmax(0,1fr);gap:13px}
 .lineup-picker-card{display:grid;grid-template-columns:92px minmax(0,1fr);padding:16px;gap:10px 16px;text-align:left}
 .lineup-picker-card :is(.profile-photo,.lineup-picker-photo){grid-column:1;grid-row:1/4;width:92px;height:122px}
 .lineup-picker-copy{grid-column:2;gap:4px}
 .lineup-picker-copy>strong{font-size:27px}
 .lineup-picker-copy>small,.lineup-picker-copy>span{font-size:13px}
 .lineup-picker-stats{grid-column:2;justify-content:flex-start;gap:6px 12px;font-size:13px}
 .lineup-picker-stats :is(strong,b){font-size:19px}
 .lineup-picker-choose{grid-column:2;font-size:14px;padding:9px;text-align:center}
 .lineup-portraits.is-compact{padding:19px 13px}
 .lineup-portraits.is-compact .lineup-portrait strong{font-size:14px}
 .lineup-portraits.is-compact .lineup-portrait .team-highlight-role{font-size:10px}
 .lineup-portraits.is-compact .lineup-portrait small{font-size:11px}
 .profile-career-scope{grid-template-columns:minmax(0,1fr)}
 .profile-career-scope .profile-filter-value{font-size:16px}
 .profile-career-scope .profile-filter-coverage{font-size:13px}
 body .magic-deck-builder .magic-deck-expanded-selection .magic-deck-featured-heading>small{font-size:10px}
}
@media(max-width:420px){
 .lineup-portraits .lineup-portrait .team-highlight-image{width:88px}
 .lineup-portraits.is-compact .lineup-portrait .team-highlight-image{width:76px}
 .half-substitution-starters{grid-template-columns:minmax(0,1fr)}
 .magic-profile-dialog .magic-profile-abilities .ability-summary-chip{font-size:16px;padding:12px 5px}
 .lineup-picker-card{grid-template-columns:76px minmax(0,1fr);padding:13px;gap:8px 12px}
 .lineup-picker-card :is(.profile-photo,.lineup-picker-photo){width:76px;height:111px}
 .lineup-picker-copy>strong{font-size:24px}
}
@media(hover:none),(pointer:coarse){.roster-starter-remove{width:40px;height:40px;opacity:1}}
@media(prefers-reduced-motion:reduce){.roster-starter-remove,.lineup-picker-card,.half-bench-card{transition:none}}

/* These captions sit inside accessible summary controls instead of figcaptions. */
.lineup-portrait-caption{display:grid;gap:7px;min-width:0}
.lineup-portraits.is-compact .lineup-portrait-caption{gap:4px}
.franchise-effect-panel>.franchise-effect-name{display:block;font:800 21px/1.2 var(--serif,sans-serif);color:#edfcff;margin-bottom:16px}
.franchise-effect-list li{padding:0 0 0 2px}
.franchise-effect-list li>strong{display:block;font-size:13px;color:#b6f5e8;margin-bottom:3px}
.franchise-effect-list li>span{display:block;font-size:14px;line-height:1.5;color:#d0e2ec}
.franchise-effect-list li.is-penalty>strong,.franchise-effect-list li.is-risk>strong{color:#ffc1c9}
.profile-career-scope .profile-filter-value>span:not(.profile-filter-coverage){font:inherit;color:inherit;letter-spacing:0;text-transform:none}
.player-dialog .player-heading-line{display:grid;grid-template-columns:minmax(0,1fr);gap:16px;width:100%;text-align:center}
.player-dialog .player-heading-identity{text-align:center;width:100%}
.player-dialog .player-heading-identity h2{font-size:clamp(34px,4vw,60px);line-height:1.08;text-transform:uppercase;letter-spacing:.025em;text-align:center}
.player-dialog .player-heading-line .profile-major-stats{justify-content:center;justify-self:center;width:100%}
.half-substitution-starter>span:not(.phase-player-avatar){display:grid;grid-column:2;grid-row:1;gap:5px;min-width:0}
.half-substitution-starter>span>strong{font-size:17px;line-height:1.3;overflow-wrap:anywhere}
.half-substitution-starter>span>small{font-size:13px;line-height:1.4;color:#a9d3df}
.half-substitution-starter>b{grid-column:2;grid-row:2;color:#a7f7e9;font-size:13px}
.half-substitution-locked{display:grid;gap:8px;margin:0 0 18px;padding:14px;border:1px solid #80bcb94d;border-radius:10px;background:#224a4a45}
.half-substitution-locked>span{font-size:15px;line-height:1.5;color:#c3dde4}
.half-substitution-locked b{font-size:11px;text-transform:uppercase;letter-spacing:.08em;color:#9dedcd;margin-left:10px}
.combat-cinematic-pressure-note{display:block;margin:12px auto 0;padding:9px 12px;width:fit-content;max-width:100%;box-sizing:border-box;border:1px solid #80dfe270;border-radius:8px;background:#173c4fe8;color:#bdfff6;font-size:14px;line-height:1.5;font-weight:800}
/* Chromium's native closed-details content box must also permit hover/focus previews. */
.franchise-effect-popover:hover::details-content,
.franchise-effect-popover:focus-within::details-content,
.franchise-effect-popover[open]::details-content{content-visibility:visible}
@media(max-width:700px){
 .half-substitution-starter>span>strong{font-size:15px}
 .half-substitution-starter>span>small{font-size:12px}
}
/* Preserve the existing image failure fallback without overlaying loaded portraits. */
.lineup-picker-photo:has(>img:not([hidden]))>.portrait-initials{visibility:hidden}
.lineup-picker-photo>.portrait-initials{position:absolute;inset:0;display:grid;place-items:center;font-size:32px;color:#b8dce5;font-weight:850}
#modal.magic-profile-dialog>.modal-head h2{font-size:clamp(36px,4.6vw,68px);line-height:1.05;margin:0}
#modal.lineup-picker-dialog>.modal-head h2{font-size:clamp(34px,4vw,54px)}
#modal.player-dialog .player-heading-identity h2{font-size:clamp(34px,4vw,60px);line-height:1.08}
body .battle-match-navigation.phase-match-navigation:has(>.btn:nth-child(2):last-child){grid-template-columns:repeat(2,minmax(0,1fr))}
/* Reset legacy generic disclosure styling for the portrait popovers only. */
.lineup-portrait details.franchise-effect-popover{margin:0;padding:0;border:0;border-radius:0;background:none;box-shadow:none;overflow:visible}
.lineup-portrait .franchise-effect-popover>.franchise-effect-trigger{
 display:block;min-height:0;margin:0;padding:0;border:0;background:transparent;color:inherit;
 box-shadow:none;text-transform:none;letter-spacing:normal;font:inherit;text-align:center;
}
.lineup-portrait .franchise-effect-popover>.franchise-effect-trigger:hover{background:transparent}
.lineup-portrait .franchise-effect-popover>.franchise-effect-trigger::before,
.lineup-portrait .franchise-effect-popover>.franchise-effect-trigger::after{content:none;display:none}
