.ant-game .screen-tools{display:flex;justify-content:flex-end;padding:8px 10px;gap:8px}
.ant-game .screen-button,.ant-game #compactActions button{min-height:44px;padding:7px 12px;border:1px solid #638c78;border-radius:4px;background:#fbfffd;color:#253331;cursor:pointer;font:inherit;font-size:13px;font-weight:700}
.ant-game .compact-bar{display:none}
.ant-game .map-nest-actions{position:absolute;left:8px;top:50%;transform:translateY(-50%);z-index:26;display:flex;flex-direction:column;gap:6px;align-items:flex-start}
.ant-game .map-nest-actions[hidden]{display:none}
.ant-game .map-action-row{position:relative}
.ant-game .map-nest-actions button{width:96px;min-height:44px;padding:6px;border:1px solid #638c78;border-radius:4px;background:#fbfffddd;color:#253331;font:inherit;font-size:13px;font-weight:700;cursor:pointer}
.ant-game .map-nest-actions button[aria-disabled="true"]{background:#e0e4ddd9;color:#737b72;border-color:#99a397}
.ant-game .map-nest-actions button[aria-pressed="true"]{background:#923924e8;color:#fff;border-color:#742d1d}
.ant-game #mapActionNotice{position:absolute;left:calc(100% + 7px);top:50%;transform:translateY(-50%);width:max-content;max-width:min(210px,calc(100vw - 140px));padding:5px 8px;border-radius:4px;background:#26352bef;color:#fff;font-size:13px;line-height:1.4;pointer-events:none}
.ant-game.has-map-actions .sortie-buttons,.ant-game.has-map-actions #launchWinged{display:none}
.ant-game.has-map-actions .local-stage:has(.map-nest-actions:not([hidden])) .local-exit.west{top:calc(50% + 76px)}
.ant-game.is-expanded{position:fixed;inset:0;z-index:10000;width:100%;height:100dvh;margin:0;border:0;border-radius:0;overflow:auto;overscroll-behavior:contain;padding:env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left)}
.ant-game.is-expanded .screen-tools{position:sticky;top:0;z-index:20;background:#f3f9f5}
.ant-game .game-panel{width:min(640px,calc(100% - 24px));max-height:calc(100dvh - 20px);padding:0;border:1px solid #638c78;border-radius:6px;background:#fbfffd;color:#253331;overflow:auto;overscroll-behavior:contain}
.ant-game .game-panel::backdrop{background:#17271db3}
.ant-game .game-panel-header{position:sticky;top:0;z-index:3;display:flex;align-items:center;justify-content:space-between;padding:6px 12px;background:#f3f9f5;border-bottom:1px solid #dce9e4}
.ant-game .game-panel-header h2{font-size:18px;margin:0}
.ant-game #gamePanelBody{padding:10px}
.ant-game.is-compact{--map-ratio:1.333333;--hud-width:min(calc(100% - env(safe-area-inset-left) - env(safe-area-inset-right)),calc(var(--game-map-height) * var(--map-ratio)));display:grid;grid-template-rows:minmax(0,1fr);overflow:hidden}
.ant-game.is-compact:has(#localWorkspace:not([hidden])){--map-ratio:1.305555}
.ant-game.is-compact .screen-tools{position:absolute;top:calc(env(safe-area-inset-top) + 8px);left:50%;transform:translateX(-50%);width:var(--hud-width);padding:0 8px;align-items:center;background:none;pointer-events:none}
.ant-game.is-compact .screen-tools>*{pointer-events:auto}
.ant-game.is-compact .territory-app{grid-row:1;padding:0;margin:0;min-height:0;width:100%}
.ant-game.is-compact .territory-app>.page-head,.ant-game.is-compact .territory-app>footer,.ant-game.is-compact .territory-app>#factionPanel,.ant-game.is-compact .play-workspace>#nestCommands,.ant-game.is-compact #overviewWorkspace>.detail-panel{display:none}
.ant-game.is-compact .play-workspace,.ant-game.is-compact .map-column,.ant-game.is-compact .workspace,.ant-game.is-compact .map-panel,.ant-game.is-compact .local-workspace,.ant-game.is-compact .local-stage-wrap{height:100%;min-height:0;margin:0;padding:0;border:0;box-shadow:none}
.ant-game.is-compact .play-workspace,.ant-game.is-compact .workspace{display:block}
.ant-game.is-compact .map-column{position:relative;top:0}
.ant-game.is-compact .map-panel,.ant-game.is-compact .local-stage-wrap{display:flex;align-items:center;justify-content:center;background:#9caa70}
.ant-game.is-compact .map-toolbar,.ant-game.is-compact .map-foot,.ant-game.is-compact .column-labels,.ant-game.is-compact .row-labels,.ant-game.is-compact .local-toolbar,.ant-game.is-compact .local-life-status,.ant-game.is-compact .local-footer{display:none}
.ant-game.is-compact .map-frame{display:block;padding:0;max-width:none;width:min(100%,calc(var(--game-map-height) * 1.333333));margin:0}
.ant-game.is-compact .local-stage{width:min(100%,calc(var(--game-map-height) * 1.305555));min-width:0;margin:0}
.ant-game.is-compact .local-map-return{position:absolute;top:8px;left:8px;z-index:25;box-shadow:none}
.ant-game.is-compact .compact-bar{position:absolute;bottom:calc(env(safe-area-inset-bottom) + 4px);left:50%;transform:translateX(-50%);width:calc(var(--hud-width) - 8px);z-index:20;display:flex;align-items:flex-end;justify-content:space-between;gap:6px;padding:0;background:none;border:0;min-width:0;pointer-events:none}
.ant-game.is-compact .local-exit.south{bottom:8px}
.ant-game.is-compact:has(#localWorkspace:not([hidden])) #compactSummary{max-width:calc(50% - 40px)}
.ant-game #compactSummary{font-size:11px;line-height:1.35;min-width:0;padding:1px 3px;margin:0;border-radius:2px;color:#253331;background:#f3f9f580}
.ant-game #compactActions{display:flex;align-items:flex-end;gap:6px;flex-shrink:0;pointer-events:auto}
.ant-game #compactSpeed{min-height:44px;margin:0;padding:6px 8px;border:1px solid #638c78;border-radius:4px;background:#fbfffd;color:#253331;font:inherit;font-size:13px;cursor:pointer}
.ant-game.is-compact .founding-notice,.ant-game.is-compact .match-finished{position:absolute;left:8px;top:52px;max-width:min(440px,70%);z-index:12;font-size:12px}
.ant-game.is-compact #foundingNotice{top:110px}
.ant-game.is-compact .game-panel .command-inputs{grid-template-columns:1fr 1fr}
.ant-game.is-compact .game-panel .winged-command{grid-column:1/-1}
@media(max-width:640px){.ant-game #compactSummary{font-size:11px}.ant-game #compactActions{gap:3px}.ant-game #compactActions button{padding:6px 8px}}
