/* Scoped presentation overrides; geometry and team/health semantics stay in mode CSS. */
.table-themed{--table-panel:#202c27;--table-text:#f2e5c5;--table-border:#a79970;--table-accent:#dfbd72;--table-overlay:#10221f8c;color:var(--table-text)}
.game-page.table-themed,.game-page.table-scene,.theme-preview{background:linear-gradient(var(--table-overlay,#10221f88),var(--table-overlay,#10221f88)),var(--table-background,url('https://bj-cdn.geemii.com/backgrounds/standard/cloud-pass-v1.png')) center/cover,var(--table-panel,#202c27)!important}
.formation-battle.table-scene:before,.formation-battle.table-themed:before{background-image:var(--table-background,url('https://bj-cdn.geemii.com/backgrounds/standard/cloud-pass-v1.png'));filter:none}
.formation-battle.table-themed:after{background:var(--table-overlay)}
.table-themed :is(.battle-log,.formation-console,.formation-drawer,.formation-chat,.formation-sidebar,.theme-sample-panel){background:var(--table-panel)!important;color:var(--table-text)!important;border-color:var(--table-border)!important}
.table-themed .player-area{background:transparent!important;color:var(--table-text)!important}
.table-themed :is(.seat,.self-general,.formation-unit,.theme-sample-seats>span){border-color:var(--table-border)!important}
.table-themed :is(.seat.active,.formation-unit.acting,.formation-unit.target-chosen){outline-color:var(--table-accent);border-color:var(--table-accent)!important}
.table-themed{--action-background:var(--table-panel);--action-color:var(--table-text);--action-border:var(--table-accent)}
.table-themed .theme-sample-panel button{border-color:var(--table-accent);background:var(--table-panel);color:var(--table-text)}
.table-custom-back :is(.deck-card-back,.hand-card-back,.draw-card-back,.discard-card.card-back,.formation-central-discard.card-back){background:var(--table-card-back) center/cover!important}
.table-custom-back .card-back-seal{visibility:hidden}
.theme-editor{margin-top:20px;padding-top:16px;border-top:1px solid #a7997055;min-width:0}
.theme-editor fieldset{min-width:0}.theme-editor input[type=color]{width:100%;min-width:60px;height:40px;padding:3px}
.theme-validation{color:#dba682;min-height:1.5em}
.theme-previews{display:flex;align-items:flex-start;gap:16px;flex-wrap:wrap;margin-top:16px}
.theme-preview{box-sizing:border-box;flex:1 1 280px;min-width:0;padding:14px;border:1px solid var(--table-border);border-radius:12px;overflow:hidden;color:var(--table-text)}
.theme-preview[data-theme-preview=formation]{flex:0 1 230px;max-width:100%}
.theme-sample-seats{display:flex;justify-content:space-around;gap:8px;margin:12px 0}
.theme-sample-seats>span{padding:14px 6px;background:var(--table-panel);border:1px solid var(--table-border);border-radius:6px;font-size:12px}
.theme-sample-center{display:flex;align-items:center;justify-content:center;gap:12px;min-height:68px}
.theme-preview[data-theme-preview=formation] .theme-sample-center{min-height:120px}
.theme-sample-panel{display:flex;gap:8px;align-items:center;justify-content:space-between;padding:10px;border:1px solid var(--table-border);border-radius:8px;font-size:12px}
.theme-preview .deck-card-back{display:inline-flex;align-items:center;justify-content:center;width:35px;height:48px;background:#253e32;border:1px solid var(--table-border);border-radius:4px}
.table-effect-back :is(.draw-card-back,.discard-card.card-back,.formation-central-discard.card-back){background:var(--table-effect-card-back) center/cover!important}
.table-effect-back :is(.draw-card-back,.discard-card.card-back,.formation-central-discard.card-back) .card-back-seal{visibility:hidden}
.theme-editor>section,.theme-media-grid{margin-block:24px;padding-top:16px;border-top:1px solid #a7997033}
.theme-media-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px}
.theme-media-slot img{display:block;object-fit:contain;margin:12px 0}.theme-cardBack{width:100px;height:150px}.theme-healthIcon{width:48px;height:60px}
.theme-preview-health{display:inline-flex;align-items:center;gap:4px}.theme-preview-health img{width:16px;height:20px;object-fit:contain}
.preset-advanced{margin-top:16px}.preset-advanced>summary{cursor:pointer;padding:12px 0}.preset-advanced[open]>summary{margin-bottom:12px}
.content-tabs{display:grid;grid-template-columns:repeat(auto-fit,minmax(0,1fr))}
@media(max-width:480px){.theme-media-grid{grid-template-columns:1fr}.content-tabs button{padding-inline:4px;min-width:0;font-size:13px}}
