.battle-stage { position:absolute; inset:0; min-width:0; min-height:0; }
.play-screen-caption { display:none; }
.field-play-label, .entry-controls-help { display:none; }
.portrait-entry { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-top:12px; padding:12px 15px; border:1px solid #dce3d5; border-radius:7px; background:#edf1e7; }
.portrait-entry strong { display:block; font-size:12px; }
.portrait-entry small { display:block; margin-top:4px; color:#7c8772; font-size:10px; }
.portrait-entry button { display:flex; align-items:center; gap:7px; flex-shrink:0; padding:10px 13px; border-radius:5px; background:#293b32; color:#eef3e4; font-size:11px; }
.portrait-entry button svg { width:16px; height:16px; }
body.play-screen-open { overflow:hidden; overscroll-behavior:none; }
body.play-screen-open .mobile-nav { display:none; }
.battlefield.play-screen-active {
  position:fixed; inset:0; z-index:100; width:100%; height:100dvh; max-width:none;
  margin:0; padding:8px max(8px, env(safe-area-inset-right)) max(6px, env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left));
  padding-top:max(8px, env(safe-area-inset-top)); border:0; border-radius:0; outline:0;
  aspect-ratio:auto; background:#1c2b25; color:#edf3df; touch-action:none;
  display:grid; grid-template-areas:'toolbar' 'hud' 'battle' 'caption'; grid-template-rows:38px 48px minmax(0,1fr) 24px;
}
.battlefield.play-screen-active .map-top { grid-area:toolbar; position:relative; inset:auto; min-width:0; padding:0 8px; }
.battlefield.play-screen-active .map-name { font-size:11px; letter-spacing:1px; }
.battlefield.play-screen-active .map-name small { font-size:8px; }
.battlefield.play-screen-active .map-tools { gap:7px; }
.battlefield.play-screen-active .map-tool { width:36px; height:36px; border:1px solid #78937955; border-radius:9px; background:#34473a; }
.battlefield.play-screen-active .map-tool svg { width:18px; height:18px; }
.battlefield.play-screen-active .game-hud { grid-area:hud; position:relative; inset:auto; align-items:center; padding:0 10px 7px; }
.battlefield.play-screen-active .game-hud span { font-size:9px; }
.battlefield.play-screen-active .game-hud strong { font-size:14px; }
.battlefield.play-screen-active .game-hud .hud-score strong { font-size:24px; line-height:1; }
.battlefield.play-screen-active .game-hud #hud-health { font-size:13px; letter-spacing:2px; }
.battlefield.play-screen-active .game-hud #hud-base { font-size:9px; }
.battlefield.play-screen-active .battle-stage { grid-area:battle; position:relative; inset:auto; overflow:hidden; border-radius:5px; background:#14251d; box-shadow:0 0 0 1px #7f986f38; }
.battlefield.play-screen-active canvas { position:absolute; left:50%; top:50%; transform:translate(-50%,-50%); max-width:100%; max-height:100%; }
.battlefield.play-screen-active .game-overlay { padding:18px; }
.battlefield.play-screen-active .game-overlay h2 { font-size:27px; }
.battlefield.play-screen-active .game-overlay p { max-width:280px; font-size:11px; }
.battlefield.play-screen-active .game-overlay .primary-button { min-height:44px; margin-top:22px; }
.battlefield.play-screen-active .game-overlay .overlay-secondary { min-height:36px; font-size:11px; }
.battlefield.play-screen-active .play-screen-caption { grid-area:caption; display:flex; justify-content:center; align-items:center; color:#92a18c; font-size:10px; letter-spacing:1px; }
.play-screen-caption .touch-caption { display:none; }
.battlefield.play-screen-active .field-intro h2 { text-align:center; }
.battlefield.play-screen-active:not(.game-active) { grid-template-rows:38px 0 minmax(0,1fr) 24px; }
.battlefield.play-screen-active .field-play { display:flex; align-items:center; justify-content:center; gap:12px; width:auto; min-width:180px; height:54px; padding:0 25px; border-radius:4px; font-size:17px; font-weight:750; }
.battlefield.play-screen-active .field-play-label { display:inline; }
.battlefield.play-screen-active .field-status { margin-top:20px; }
.battlefield.play-screen-active .touch-controls { display:none; }
.battlefield.play-screen-active .touch-controls[hidden] { visibility:hidden; }
.play-screen-open .toast { position:fixed; z-index:150; bottom:max(25px, env(safe-area-inset-bottom)); left:50%; max-width:calc(100vw - 32px); }
@media (pointer:coarse), (max-width:680px), (max-height:500px) {
  .battlefield.play-screen-active { grid-template-areas:'toolbar' 'hud' 'battle' 'controls' 'caption'; grid-template-rows:38px 48px minmax(0,1fr) 146px 22px; }
  .battlefield.play-screen-active:not(.game-active) { grid-template-rows:38px 0 minmax(0,1fr) 146px 22px; }
  .battlefield.play-screen-active:not(.game-active) .entry-controls-help { grid-area:controls; display:flex; align-items:center; justify-content:space-around; gap:20px; color:#bac7ae; font-size:11px; }
  .entry-controls-help>span { display:flex; align-items:center; flex-direction:column; gap:12px; }
  .entry-controls-help i { width:62px; height:62px; border:1px solid #a6b89877; border-radius:50%; background:#c8d5b50d; }
  .entry-controls-help svg { width:26px; height:26px; }
  html[data-skin="phantom"] .entry-controls-help { color:#e5dce8; }
  html[data-skin="phantom"] .entry-controls-help i { background:#2c2533; border-color:#ada2b7; color:#f7f3eb; }
  .battlefield.play-screen-active .touch-controls,
  .battlefield.play-screen-active .touch-controls:not([hidden]) { grid-area:controls; display:flex!important; position:relative; inset:auto; align-items:center; justify-content:space-between; padding:10px 16px 0; pointer-events:none; }
  .battlefield.play-screen-active .touch-controls[hidden] { pointer-events:none; }
  .battlefield.play-screen-active .touch-controls[hidden]>* { pointer-events:none; }
  .battlefield.play-screen-active .joystick { width:110px; height:110px; border-color:#9ebd8170; background:#263b2e; box-shadow:inset 0 0 0 10px #78955b0d,0 4px 15px #101d1855; }
  .battlefield.play-screen-active .joystick-knob { background:#8da27a; border-color:#cfdec08c; width:46px; height:46px; left:calc(50% - 23px); top:calc(50% - 23px); }
  .battlefield.play-screen-active .touch-actions { gap:16px; align-items:center; }
  .battlefield.play-screen-active .touch-fire { width:86px; height:86px; border:2px solid #ed9f697d; background:#c66736; box-shadow:inset 0 0 0 7px #ee9c491c,0 4px 15px #101d1855; }
  .battlefield.play-screen-active .touch-fire svg { width:34px; height:34px; }
  .battlefield.play-screen-active .touch-fire.pressed { background:#ee8b4b; transform:scale(.96); }
  .battlefield.play-screen-active .touch-shield { width:52px; height:52px; margin:0; background:#3d5643; font-size:10px; }
  .play-screen-caption .touch-caption { display:inline; }
  .play-screen-caption .keyboard-caption { display:none; }
}
@media (max-width:370px) {
  .portrait-entry { padding:11px; gap:6px; }
  .portrait-entry small { font-size:9px; }
  .battlefield.play-screen-active { grid-template-rows:36px 44px minmax(0,1fr) 124px 20px; }
  .battlefield.play-screen-active:not(.game-active) { grid-template-rows:36px 0 minmax(0,1fr) 124px 20px; }
  .battlefield.play-screen-active .touch-controls:not([hidden]) { padding:8px 8px 0; }
  .battlefield.play-screen-active .joystick { width:96px; height:96px; }
  .battlefield.play-screen-active .touch-actions { gap:12px; }
  .battlefield.play-screen-active .touch-fire { width:74px; height:74px; }
  .battlefield.play-screen-active .touch-shield { width:48px; height:48px; }
}
@media (orientation:landscape) and (max-height:600px) {
  .battlefield.play-screen-active { grid-template-areas:'toolbar' 'hud' 'battle' 'caption'; grid-template-rows:30px 38px minmax(0,1fr) 18px; padding-top:max(4px, env(safe-area-inset-top)); }
  .battlefield.play-screen-active:not(.game-active) { grid-template-rows:30px 0 minmax(0,1fr) 18px; }
  .battlefield.play-screen-active .entry-controls-help { position:absolute; inset:auto 24px 24px; justify-content:space-between!important; }
  .battlefield.play-screen-active .map-tool { width:30px; height:30px; }
  .battlefield.play-screen-active .map-top { padding:0 8px; }
  .battlefield.play-screen-active .touch-controls,
  .battlefield.play-screen-active .touch-controls:not([hidden]) { position:absolute; inset:auto 24px 24px; padding:0; }
  .battlefield.play-screen-active .game-hud { max-width:500px; width:100%; justify-self:center; }
  .battlefield.play-screen-active .game-hud .hud-score strong { font-size:21px; }
  .battlefield.play-screen-active .joystick { width:96px; height:96px; }
  .battlefield.play-screen-active .touch-fire { width:76px; height:76px; }
}
