/* Graphite workbench: one stage, five target shortcuts, two collections. */
:root:not([data-theme=light]){--bg:#0c0d10;--surface:#15181d;--well:#20252c;--card:#14181e;--hover:#2d3440;--border:#3b4350;--image-floor:#232a34;--text:#ffffff;--muted:#bdc5d2;--subtle:#929eaf;--accent:#f5f7ff;--accent-fill:#f5f7ff;--accent-ink:#0c0d10;--accent-soft:#2b3039;--accent-border:#a5aab4;--secondary:#a5aab4;--green:#26e680;--red:#ff4557;--success-bg:#103123;--success-border:#217d50;--error-bg:#35141b;--error-border:#953848;--zone-control:#9fa6b2;--zone-control-hover:#d5dae3;--zone-grip-top:#ffffff;--zone-grip-mid:#e1e4eb;--zone-grip-bottom:#9fa7b4;--zone-grip-ink:#5c6573;--zone-grip-shine:#ffffff}
:root[data-theme=light]{--zone-control:#6e7888;--zone-control-hover:#394457;--zone-grip-top:#626d7d;--zone-grip-mid:#485365;--zone-grip-bottom:#283343;--zone-grip-ink:#111926;--zone-grip-shine:#929dad}
.topbar .language-switch,.topbar .theme-toggle,.topbar .balance-chip,.topbar .deposit-button,.topbar .profile-button{height:36px;min-height:36px}
.topbar .language-switch,.topbar .theme-toggle,.topbar .balance-chip,.topbar .deposit-button{border-radius:10px}
.topbar .profile-button{width:36px;min-width:36px}
#upgradeView .game-settings{gap:6px}
#upgradeView .game-settings .setting-button,#upgradeView .volume-popover summary{height:30px;min-height:30px;border-radius:8px;display:flex;align-items:center;justify-content:center}
#upgradeView .game-settings .setting-button[data-action=help],#upgradeView .volume-popover summary{width:30px;padding:0}
#upgradeView>.presets-bar:not(.has-presets){height:0;min-height:0;overflow:visible;padding:0;border:0}
#upgradeView>.presets-bar:not(.has-presets) #newPreset{position:absolute;right:0;top:0;width:30px;height:30px;min-height:30px;padding:0;font-size:0;background:var(--well);border:1px solid var(--border);border-radius:8px}
#upgradeView>.presets-bar:not(.has-presets) #newPreset svg{width:14px;height:14px}
#upgradeView>.page-heading{padding-right:36px}
#upgradeView{position:relative}
#arena .panel-eyebrow{padding:0;align-items:center}
#arena .panel-link,#arena .multiplier-badge{display:inline-flex;align-items:center;justify-content:center;width:60px;height:24px;padding:0;border-radius:7px;font-size:9px;line-height:1}
#arena .roll-side{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));width:156px;height:28px;padding:3px;gap:3px;margin:0 auto 8px;background:var(--surface);border:1px solid var(--border);border-radius:9px}
#arena .roll-side button{width:100%;height:20px;min-height:0;padding:0;display:flex;align-items:center;justify-content:center;border-radius:5px;font-size:9px;line-height:1;white-space:nowrap}
#arena .roll-side button.active{background:var(--hover);color:var(--text)}
#arena .upgrade-button{display:grid;grid-template-columns:20px minmax(0,1fr) 20px;gap:8px;width:100%;max-width:none;height:46px;padding:0 16px;border-radius:11px}
#arena .upgrade-button>span{margin:0;display:flex;align-items:center;justify-content:center;min-width:0}
#arena .upgrade-button.is-busy>span:only-child{grid-column:1/-1}
#arena .round-status{height:14px;min-height:14px;line-height:14px;margin:7px 0 0;font-size:9px}
#arena #dialSubtext{display:none}
#arena .dial-track{stroke-width:17}
#arena .dial-gradient-arc path{fill:none;stroke-width:17;stroke-linecap:butt;filter:none}
#arena .dial-bezel{stroke:var(--border);stroke-width:1;opacity:.7}
#arena .dial-inner{stroke:var(--border);opacity:.6}
#arena .dial-svg{filter:drop-shadow(0 8px 22px #0003)}
#arena .dial-pointer .pointer-shadow{fill:var(--bg);stroke:none;filter:none}
#arena .dial-pointer .pointer-needle{filter:none}
#arena .selection-caption{display:none}
#arena .selection-caption.has-message{display:block;font-size:9px;color:var(--muted)}
#arena .balance-entry,#arena .amount-field{width:100%}
#arena .amount-field{max-width:none}
#arena .target-tuning{min-width:0}
#arena .target-shortcuts{width:100%;height:42px;display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px}
#arena .target-shortcuts button{width:100%;height:100%;min-height:0;padding:0;display:flex;align-items:center;justify-content:center;border:1px solid var(--border);border-radius:9px;background:var(--surface);color:var(--muted);font-size:12px;font-weight:600;font-variant-numeric:tabular-nums;white-space:nowrap;transition:background .18s,border-color .18s,color .18s,transform .18s}
#arena .target-shortcuts button:hover{background:var(--hover);color:var(--text)}
#arena .target-shortcuts button[data-chance]{border-color:color-mix(in srgb,var(--preset-color) 35%,var(--border))}
#arena .target-shortcuts button.active{background:var(--accent-soft);border-color:var(--accent-border);color:var(--text)}
#arena .target-shortcuts button[data-chance].active{border-color:var(--preset-color);color:var(--preset-color)}
#arena .arena-controls{min-width:0;width:100%}
#arena .stake-breakdown{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));width:100%;max-width:560px;margin:0 auto;gap:0;justify-content:center}
#arena .stake-breakdown>div{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:0 10px;gap:2px;min-width:0;line-height:12px}
#arena .stake-breakdown>div+div{border-left:1px solid var(--border)}
#arena .stake-breakdown span{font-size:9px;white-space:nowrap}
#arena .stake-breakdown b{font-size:12px;line-height:17px;white-space:nowrap}
#arena .stake-breakdown .stake-total{padding-left:10px}
#arena .stake-breakdown .stake-total b{font-size:15px}
#upgradeView .picker-panel{border-radius:14px}
#upgradeView .filter-toggle,#upgradeView .search-field,#upgradeView .inventory-tools select,#catalogSort{border-radius:9px}
#upgradeView #clearSelection,#upgradeView #selectAll{border:1px solid var(--border);background:var(--well);border-radius:8px}
#upgradeView .picker-note{display:none}
#upgradeView .target-picker>.picker-bottom{display:none}
#upgradeView .inventory-picker>.picker-bottom{justify-content:flex-end;min-height:24px;height:24px;padding-block:4px;border:0;background:none}
#upgradeView .filter-chips:empty{display:none}
#upgradeView .inventory-shop{display:inline-flex;align-items:center;justify-content:center;gap:6px;flex-shrink:0;width:98px;min-width:98px;height:30px;min-height:30px;padding:0 8px;background:var(--well);border:1px solid var(--border);border-radius:8px;color:var(--text);font-size:10px;white-space:nowrap}
#upgradeView .inventory-shop svg{width:14px;height:14px;flex-shrink:0}
#upgradeView .inventory-shop:hover{background:var(--hover);border-color:var(--accent-border)}
#upgradeView .inventory-picker .section-title h2{flex:0 1 auto;margin-right:0}
#upgradeView .inventory-picker #selectAll{margin-left:auto}
#upgradeView #inventoryGrid:has(>.inventory-empty){height:100%;min-height:0;grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr)}
#upgradeView #inventoryScroll:has(.inventory-empty){container-name:empty-inventory;container-type:size}
#upgradeView #inventoryGrid>.inventory-empty{position:relative;grid-column:1/-1;min-height:0;height:100%;overflow:hidden;border-radius:10px;display:grid;place-items:center}
#upgradeView .empty-preview-grid{position:absolute;inset:0;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;filter:blur(4px);opacity:.28;pointer-events:none}
#upgradeView .empty-preview-grid{grid-template-rows:repeat(3,minmax(0,1fr))}
#upgradeView .empty-preview-grid>div{display:grid;place-items:center;min-height:0;overflow:hidden;background:radial-gradient(ellipse,color-mix(in srgb,var(--rarity) 30%,transparent),transparent 80%),var(--card);border:1px solid color-mix(in srgb,var(--rarity) 45%,var(--border));border-radius:8px}
#upgradeView .empty-preview-grid img{width:80%;height:100%;max-height:110px;min-height:0;object-fit:contain}
#upgradeView .inventory-empty-card{z-index:1;display:flex;flex-direction:column;align-items:center;gap:16px;padding:24px;background:var(--surface);border:1px solid var(--border);border-radius:12px;box-shadow:0 10px 35px #0005;font-size:13px}
#upgradeView .inventory-empty-card .inventory-shop{height:38px;background:var(--accent-fill);border-color:var(--accent-border);color:var(--accent-ink)}
@media(min-width:751px) and (min-height:620px){
 body[data-view=upgrade] main{padding-top:12px;padding-bottom:12px}
 #upgradeView{--wheel-size:clamp(212px,calc(50dvh - 110px),340px);grid-template-rows:30px calc(var(--wheel-size) + 104px) auto minmax(0,1fr);gap:10px}
 #upgradeView>.page-heading{height:30px;min-height:30px;margin:0;align-items:center}
 #upgradeView>.page-heading h1{font-size:24px}
 #arena{grid-template-columns:minmax(0,1fr) var(--wheel-size) minmax(0,1fr);grid-template-rows:minmax(0,1fr);gap:0 26px;max-width:none;align-items:start}
 #arena .stake-panel,#arena .target-panel{position:relative;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:26px minmax(0,1fr) 74px;gap:10px;height:100%;min-height:0;align-self:start}
 #arena .panel-eyebrow{grid-row:1;height:26px;margin:0}
 #arena .item-display{grid-row:2;width:100%;height:100%;min-height:0;max-height:none;border-radius:14px;padding:10px 14px 14px}
 #arena .empty-selection{height:100%;min-height:0}
 #arena .item-art{height:clamp(90px,calc(25dvh - 65px),170px);margin:0}
 #arena .item-art img{height:clamp(100px,calc(26dvh - 65px),185px);width:310px}
 #arena .item-finish{font-size:clamp(18px,1.7vw,24px);line-height:1.2}
 #arena .item-tail{height:19px;margin-top:7px}
 #arena .selected-tray{position:absolute;left:8px;right:8px;bottom:92px;margin:0;max-height:34px;z-index:2}
 #arena .selected-tray button{width:34px;height:30px}
 #arena .selection-caption.has-message{position:absolute;top:1px;right:68px;line-height:24px;margin:0;font-size:8px}
 #arena .balance-controls,#arena .target-tuning{grid-row:3;height:74px;margin:0;padding:10px;border:1px solid var(--border);border-radius:12px;background:var(--surface);min-width:0}
 #arena .balance-controls{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:12px 25px 10px;gap:3px}
 #arena .balance-controls label{display:block;font-size:9px;line-height:12px;margin:0}
 #arena .balance-entry,#arena .amount-field{height:25px}
 #arena .amount-field{border:0;background:transparent;padding:0;gap:6px}
 #arena .amount-field input{font-size:15px;line-height:25px}
 #arena .balance-slider{display:flex;height:10px;margin:0;gap:12px;align-items:center}
 #arena .balance-slider input{height:10px;flex:1;min-width:0}
 #arena .balance-slider>span{display:block;flex-shrink:0;max-width:42%;font-size:8px;white-space:nowrap}
 #arena .target-tuning{display:flex;align-items:center;padding:0;background:none;border:0}
 #arena .target-shortcuts{height:46px}
 #arena .chance-panel{height:100%;margin:0;padding:0;align-self:start;display:flex;flex-direction:column;align-items:center;justify-content:flex-start}
 #arena .dial{width:var(--wheel-size);height:var(--wheel-size);max-width:none;max-height:none;flex-shrink:0}
 #arena .dial-copy strong{font-size:clamp(43px,6.3dvh,60px)}
 #arena .dial-copy>span{font-size:12px}
 #arena .chance-actions{width:90%;margin-top:8px;flex-shrink:0}
 #arena .arena-controls{padding:0;margin:0;align-self:end}
 #upgradeView>.presets-bar{grid-row:3;margin:0;gap:8px}
 #upgradeView>.presets-bar:not(.has-presets){margin-block:-5px}
 #upgradeView>.presets-bar.has-presets{height:28px;min-height:28px}
 #upgradeView .preset-save{height:28px;min-height:28px;border-radius:8px}
 #upgradeView>.picker-layout{grid-row:4;gap:12px}
 #upgradeView .picker-panel{padding:10px 12px 0}
 #upgradeView .section-title{height:30px;min-height:30px;margin:0 0 8px;gap:6px}
 #upgradeView .section-title h2{font-size:14px;white-space:nowrap}
 #upgradeView #selectAll{height:28px;min-height:28px;width:82px;padding:0 5px;font-size:8px}
 #upgradeView #clearSelection{height:28px;width:28px;flex-shrink:0}
 #upgradeView .inventory-tools,#upgradeView .catalog-tools{height:32px;min-height:32px;margin:0 0 8px;gap:6px}
 #upgradeView .search-field,#upgradeView .filter-toggle,#upgradeView .inventory-tools select,#catalogSort{height:32px;min-height:32px}
 #upgradeView .inventory-tools select,#catalogSort{width:82px;min-width:82px;font-size:9px}
 #upgradeView .filter-chips{position:static;height:24px;min-height:24px;max-height:24px;margin:0 0 6px;flex-wrap:nowrap;overflow:auto}
 #upgradeView .skin-card{min-height:122px}
 #upgradeView .inventory-empty{min-height:165px}
}
@media(min-width:751px) and (max-width:1099px) and (min-height:620px){
 #upgradeView{--wheel-size:clamp(212px,calc(50dvh - 110px),300px)}
 #arena{gap:0 18px}
 #arena .target-shortcuts{gap:4px}
 #arena .target-shortcuts button{font-size:11px}
 #upgradeView .inventory-shop{width:72px;min-width:72px;font-size:9px;gap:4px}
 #upgradeView .section-title h2{font-size:12px}
 #upgradeView #selectAll{width:66px;font-size:7px}
}
@media(min-width:751px) and (min-height:620px) and (max-height:680px){
 #arena .item-art{height:64px}#arena .item-art img{height:82px}
 #arena .item-finish{font-size:17px}#arena .item-value b{font-size:14px}
 #arena .dial-copy>span{font-size:10px}
 #arena .upgrade-button{height:40px}
}
@media(min-width:751px) and (min-height:620px) and (max-height:780px){
 #upgradeView{grid-template-rows:30px calc(var(--wheel-size) + 92px) auto minmax(0,1fr);gap:8px}
 #arena .chance-actions{margin-top:6px}
 #arena .roll-side{height:24px;padding:2px;margin-bottom:6px}
 #arena .roll-side button{height:18px;font-size:8px}
 #arena .upgrade-button{height:38px}
 #arena .round-status{height:12px;min-height:12px;line-height:12px;margin-top:4px;font-size:8px}
 #upgradeView .picker-panel{padding-top:8px}
 #upgradeView .section-title{height:26px;min-height:26px;margin-bottom:4px}
 #upgradeView .inventory-shop{height:26px;min-height:26px}
 #upgradeView .inventory-tools,#upgradeView .catalog-tools{height:28px;min-height:28px;margin-bottom:4px}
 #upgradeView .search-field,#upgradeView .filter-toggle,#upgradeView .inventory-tools select,#catalogSort{height:28px;min-height:28px}
 #upgradeView .inventory-picker>.picker-bottom{display:none}
}
@media(min-width:751px) and (min-height:620px) and (max-height:680px){
 #upgradeView .skin-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
 #upgradeView .skin-card{display:grid;grid-template-columns:38px minmax(0,1fr);grid-template-rows:11px 13px 15px;gap:0 5px;min-height:55px;padding:7px 6px}
 #upgradeView .skin-card .wear{display:none}
 #upgradeView .skin-card:before{left:6px;top:5px;width:3px;height:3px}
 #upgradeView .skin-card img{grid-column:1;grid-row:1/4;width:38px;height:39px;margin:0}
 #upgradeView .card-weapon,#upgradeView .card-finish,#upgradeView .card-price{grid-column:2;margin:0;white-space:nowrap}
 #upgradeView .card-weapon{grid-row:1;font-size:7px}
 #upgradeView .card-finish{grid-row:2;font-size:8px}
 #upgradeView .card-price{grid-row:3;font-size:9px;padding-right:0;gap:2px}
 #upgradeView .card-price small{font-size:6px}
 #upgradeView .card-check{width:11px;height:11px;bottom:4px;right:3px;font-size:7px}
}
@media(max-width:750px){
 .topbar .language-switch,.topbar .theme-toggle,.topbar .balance-chip,.topbar .deposit-button,.topbar .profile-button{height:32px;min-height:32px}
 .topbar .theme-toggle,.topbar .profile-button,.topbar .deposit-button{width:32px;min-width:32px}
 #upgradeView>.page-heading{padding-right:30px}
 #upgradeView .game-settings{gap:3px}
 #upgradeView .game-settings .setting-button{height:26px;min-height:26px;padding-inline:6px}
 #upgradeView .game-settings .setting-button[data-action=help],#upgradeView .volume-popover summary{width:26px;height:26px;min-height:26px}
 #upgradeView>.presets-bar:not(.has-presets) #newPreset{height:26px;min-height:26px;width:26px}
 #arena .target-shortcuts{height:34px;gap:3px}
 #arena .target-shortcuts button{font-size:9px;border-radius:7px}
 #arena .panel-link,#arena .multiplier-badge{height:20px;width:48px;font-size:8px}
 #arena .upgrade-button{height:38px;grid-template-columns:14px minmax(0,1fr) 14px;padding-inline:10px;font-size:12px}
 #arena .roll-side{width:132px;height:26px;padding:2px;gap:2px;margin-bottom:7px;border-radius:8px}
 #arena .roll-side button{height:20px;font-size:8px}
 #arena .round-status{font-size:7px;margin-top:6px;height:12px;min-height:12px;line-height:12px}
 #arena .stake-breakdown>div{padding-inline:4px}
 #arena .stake-breakdown span{font-size:7px}
 #arena .stake-breakdown b{font-size:10px}
 #arena .stake-breakdown .stake-total{padding-left:4px}
 #arena .stake-breakdown .stake-total b{font-size:11px}
 #upgradeView .section-title{gap:5px}
 #upgradeView .section-title h2{font-size:12px;white-space:nowrap}
 #upgradeView .inventory-shop{width:72px;min-width:72px;height:26px;min-height:26px;font-size:9px;gap:4px}
 #upgradeView #clearSelection{width:24px;height:24px;flex-shrink:0}
 #upgradeView #selectAll{height:24px;min-height:24px;font-size:7px;padding-inline:4px}
 #upgradeView .inventory-empty{min-height:120px}
 #upgradeView .inventory-empty-card{padding:15px;font-size:11px;gap:12px}
}
@media(max-width:750px) and (min-height:700px){
 #upgradeView{grid-template-rows:30px auto auto 30px minmax(0,1fr);gap:6px}
 #upgradeView>.presets-bar{grid-row:3}
 #upgradeView>.presets-bar:not(.has-presets){margin-block:-3px}
 #arena{grid-row:2;padding:0;gap:6px 10px}
 #arena .stake-panel,#arena .target-panel{min-width:0}
 #arena .balance-controls,#arena .target-tuning{height:40px;margin-top:6px;padding:5px;background:var(--surface);border:1px solid var(--border);border-radius:10px;display:flex;align-items:center}
 #arena .balance-entry,#arena .amount-field{height:28px}
 #arena .target-tuning{border:0;padding:0;background:none}
 #arena .chance-panel{grid-template-columns:clamp(142px,23dvh,188px) minmax(0,1fr);padding:4px 12px;gap:16px}
 #arena .dial{width:clamp(142px,23dvh,188px);height:clamp(142px,23dvh,188px)}
 #arena .dial-copy strong{font-size:36px}
 #arena .dial-copy>span{font-size:8px}
 #arena .chance-actions{margin:0;min-width:0}
 #arena .arena-controls{margin:0;padding:0;min-height:34px}
 #upgradeView .picker-tabs{grid-row:4}
 #upgradeView>.picker-layout{grid-row:5}
 #upgradeView .picker-panel{padding-top:8px}
}
@media(max-width:750px) and (min-height:700px) and (max-height:780px){
 #arena .chance-panel{grid-template-columns:148px minmax(0,1fr);padding:0 8px;gap:12px}
 #arena .dial{width:148px;height:148px}
 #arena .dial-copy strong{font-size:34px}
 #arena .item-display{height:80px;min-height:80px}
 #arena .item-art{height:28px}#arena .item-art img{height:39px}
 #arena .item-finish{font-size:12px}
}

/* Account links live in a light-dismiss profile popover. */
.topbar .header-preferences{margin-left:auto}
.profile-button[aria-expanded=true]{border-color:var(--accent-border);background:var(--hover)}
.profile-menu{position:fixed;inset:64px 24px auto auto;margin:0;width:226px;padding:7px;border:1px solid var(--border);border-radius:13px;background:var(--surface);color:var(--text);box-shadow:0 14px 45px #0006;overflow:hidden}
.profile-menu:popover-open{display:flex;flex-direction:column;animation:profile-menu-enter .16s ease-out}
.profile-menu::backdrop{background:transparent}
.profile-menu button{display:flex;align-items:center;gap:10px;width:100%;height:40px;min-height:40px;padding:0 12px;border:0;border-radius:8px;background:transparent;color:var(--muted);text-align:left;font-size:12px;white-space:nowrap;transition:color .15s,background .15s}
.profile-menu button:hover,.profile-menu button:focus-visible,.profile-menu button.active{color:var(--text);background:var(--well)}
.profile-menu button>span[data-icon]{width:17px;height:17px;flex-shrink:0;display:grid;place-items:center}
.profile-menu button svg{width:17px;height:17px}
.profile-menu .count-badge{margin-left:auto;font-size:9px;min-width:20px;text-align:center}
.profile-menu-divider{height:1px;background:var(--border);margin:5px 8px}
@keyframes profile-menu-enter{from{opacity:0;transform:translateY(-5px)}to{opacity:1;transform:translateY(0)}}
@media(max-width:750px){.profile-menu{inset:62px 12px auto auto;width:220px}}
@media(prefers-reduced-motion:reduce){.profile-menu:popover-open{animation:none}}

/* Inline SVG flags stay crisp and render consistently on Windows. */
.language-control{display:flex;align-items:center;flex-shrink:0}
.topbar .language-menu-button{display:flex;align-items:center;justify-content:center;gap:7px;width:56px;height:36px;min-height:36px;padding:0 8px;border:1px solid var(--border);border-radius:10px;background:var(--surface);color:var(--muted)}
.language-flag{display:block;width:24px;height:16px;flex-shrink:0;border-radius:3px;overflow:hidden;box-shadow:0 0 0 1px #ffffff12}
.language-flag svg{display:block;width:100%;height:100%}
.language-menu-button>span[data-icon]{display:grid;place-items:center;width:10px;height:10px;flex-shrink:0;transition:transform .16s}
.language-menu-button>span[data-icon] svg{width:10px;height:10px}
.language-menu-button[aria-expanded=true]{background:var(--well);border-color:var(--accent-border)}
.language-menu-button[aria-expanded=true]>span[data-icon]{transform:rotate(180deg)}
.language-menu{position:fixed;inset:auto;margin:0;width:184px;padding:6px;border:1px solid var(--border);border-radius:12px;background:var(--surface);color:var(--text);box-shadow:0 14px 45px #0006;overflow:hidden}
.language-menu:popover-open{display:flex;flex-direction:column;gap:3px;animation:profile-menu-enter .16s ease-out}
.language-menu::backdrop{background:transparent}
.language-menu button{display:flex;align-items:center;gap:10px;width:100%;height:40px;min-height:40px;padding:0 10px;border:0;border-radius:8px;background:transparent;color:var(--muted);font-size:12px;white-space:nowrap;text-align:left;transition:background .15s,color .15s}
.language-menu button:hover,.language-menu button:focus-visible,.language-menu button[aria-pressed=true]{background:var(--well);color:var(--text)}
.language-check{margin-left:auto;font-size:12px;opacity:0;color:var(--accent)}
.language-menu button[aria-pressed=true] .language-check{opacity:1}
@media(max-width:750px){.topbar .language-menu-button{width:50px;height:32px;min-height:32px;gap:6px;padding:0 6px}}
@media(prefers-reduced-motion:reduce){.language-menu:popover-open{animation:none}}

/* A separate circular slider moves the winning field, not the result pointer. */
#arena .dial{position:relative;overflow:visible}
#arena .zone-selector{position:absolute;inset:0;z-index:3;pointer-events:none;outline:none;touch-action:none;cursor:grab}
#arena .zone-selector-svg{display:block;width:100%;height:100%;overflow:visible;pointer-events:none;touch-action:none}
#arena .zone-selector-track{fill:none;stroke:var(--border);stroke-width:2;opacity:1}
#arena .zone-preview{fill:none;stroke:var(--zone-control);stroke-width:2.5;stroke-linecap:butt;opacity:.9}
#arena .zone-hit{fill:none;stroke:transparent;stroke-width:24;pointer-events:stroke;touch-action:none}
#arena .zone-handle{pointer-events:all;touch-action:none}
#arena .zone-handle .zone-grip-face{fill:url(#zoneGripFace);stroke:var(--bg);stroke-width:1.5;filter:drop-shadow(0 1px 2px #0008);transition:filter .15s}
#arena .zone-handle path{fill:none;stroke-width:1;stroke-linecap:round;pointer-events:none}
#arena .zone-grip-grooves{stroke:var(--zone-grip-ink)}
#arena .zone-grip-shine{stroke:var(--zone-grip-shine);opacity:.6}
#arena .zone-selector:focus-visible .zone-selector-track,#arena .zone-selector:hover .zone-selector-track{stroke:color-mix(in srgb,var(--zone-control) 55%,var(--border))}
#arena .zone-selector:focus-visible .zone-grip-face{stroke:var(--text);stroke-width:1.5}
#arena .zone-selector:hover .zone-grip-face{filter:drop-shadow(0 1px 3px #0009) brightness(1.1)}
#arena .zone-selector.is-dragging .zone-grip-face{stroke:var(--zone-control-hover);stroke-width:1.5}
#arena .zone-selector.is-dragging{cursor:grabbing}
#arena .zone-selector[aria-disabled=true]{cursor:default;opacity:.5}
#arena .zone-selector[aria-disabled=true] .zone-hit,#arena .zone-selector[aria-disabled=true] .zone-handle{pointer-events:none}
#arena .zone-hint{height:28px;line-height:28px;margin:0 0 8px;display:flex;align-items:center;justify-content:center;gap:5px;font-size:10px;font-weight:600;color:var(--muted)}
#arena .zone-hint svg{width:13px;height:13px;fill:none;stroke:var(--zone-control);stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}
@media(min-width:751px) and (min-height:620px) and (max-height:780px){#arena .zone-hint{height:24px;line-height:24px;margin-bottom:6px;font-size:8px}}
@media(max-width:750px){#arena .zone-hint{height:26px;line-height:26px;margin-bottom:7px;font-size:8px}}
@media(max-width:750px) and (min-height:700px){
 #upgradeView>.presets-bar.has-presets{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-rows:32px;height:32px;min-height:32px;margin:0;gap:6px}
 #upgradeView>.presets-bar.has-presets .preset-list{grid-column:1;grid-row:1;min-width:0;padding:0;gap:6px}
 #upgradeView>.presets-bar.has-presets .preset-save{grid-column:2;grid-row:1;height:28px;min-height:28px;align-self:center}
 #upgradeView>.presets-bar.has-presets .preset-apply{height:28px;min-height:28px;padding:4px 8px}
 #upgradeView>.presets-bar.has-presets .preset-edit{height:28px;min-height:28px}
}
:root:not([data-theme=light]) .skin-card{border-color:color-mix(in srgb,var(--rarity,#707b89) 62%,var(--border));background:radial-gradient(ellipse at 50% 40%,color-mix(in srgb,var(--rarity,#707b89) 22%,transparent),transparent 82%),var(--card)}
:root:not([data-theme=light]) .skin-card.selected{border-color:var(--zone-control);background:var(--accent-soft)}
:root:not([data-theme=light]) #arena .item-display{background:var(--surface)}
:root:not([data-theme=light]) #arena .dial-inner{fill:var(--bg);opacity:1}
:root:not([data-theme=light]) .deposit-button,:root:not([data-theme=light]) .primary-button,:root:not([data-theme=light]) #arena .upgrade-button:not(:disabled):not(.is-busy){background:var(--accent-fill);border:1px solid #ffffff;box-shadow:none;color:var(--accent-ink)}
@container empty-inventory (max-height:140px){
 #upgradeView .inventory-empty-card{flex-direction:row;gap:12px;padding:10px;font-size:11px;max-width:calc(100% - 12px)}
 #upgradeView .inventory-empty-card .inventory-shop{height:30px;min-height:30px}
}
@media(max-width:750px){
 #arena .empty-selection{height:100%;min-height:0;gap:6px}
 #arena .empty-selection svg{width:20px;height:20px;margin:0}
 #arena .empty-selection p{font-size:9px;line-height:13px}
}
