/* Denkmal TD2 — combat toolbar alignment, scoped to mouse/keyboard screens.
   Android touch retains HUD 2.0, joystick and contextual build controls. */
@media (hover:hover) and (pointer:fine) and (min-width:701px) {
  #arsenal:not(.hidden) {
    position:fixed !important;
    left:auto !important;
    right:max(14px,env(safe-area-inset-right,0px)) !important;
    bottom:calc(82px + env(safe-area-inset-bottom,0px)) !important;
    transform:none !important;
    box-sizing:border-box;
    width:max-content !important;
    max-width:calc(100vw - 28px) !important;
    display:flex;
    align-items:stretch;
    justify-content:flex-end;
    flex-wrap:nowrap;
    gap:6px;
    overflow-x:auto;
    overflow-y:hidden;
    padding:3px !important;
    scrollbar-width:thin;
    z-index:9;
  }
  #arsenal button {
    flex:0 0 auto !important;
    min-width:clamp(80px,6.2vw,106px) !important;
    min-height:48px !important;
    padding:7px 9px !important;
    box-sizing:border-box;
    white-space:nowrap;
  }
  #arsenal button span {font-size:12px}
  #arsenal button b {font-size:13px;margin-top:3px}
  #controls {
    position:fixed !important;
    left:auto !important;
    right:max(14px,env(safe-area-inset-right,0px)) !important;
    bottom:calc(14px + env(safe-area-inset-bottom,0px)) !important;
    transform:none !important;
    width:max-content !important;
    max-width:calc(100vw - 28px) !important;
    box-sizing:border-box;
    display:flex;
    flex-direction:row;
    justify-content:flex-end;
    align-items:center;
    flex-wrap:wrap;
    gap:6px;
    z-index:9;
  }
  #controls .move-hint {display:none}
  #controls .action-btn:not(.hidden) {
    box-sizing:border-box;
    min-width:0;
    min-height:44px;
    padding:7px 9px;
    gap:5px;
    white-space:nowrap;
  }
  #controls .action-btn span {font-size:11px;letter-spacing:0}
  #controls .action-btn kbd {font-size:10px;padding:5px 6px;min-width:0}
}
@media (hover:hover) and (pointer:fine) and (min-width:701px) and (max-width:980px) {
  #arsenal:not(.hidden) {
    bottom:calc(126px + env(safe-area-inset-bottom,0px)) !important;
  }
  #arsenal button {
    min-width:78px !important;
    padding:5px 6px !important;
  }
  #controls {max-width:min(500px,calc(100vw - 28px)) !important}
}
/* Narrow mouse-browser simulations: two toolbar rows stay separate. */
@media (hover:hover) and (pointer:fine) and (max-width:700px) {
  #arsenal:not(.hidden) {
    position:fixed !important;
    left:12px !important;
    right:12px !important;
    bottom:calc(183px + env(safe-area-inset-bottom,0px)) !important;
    transform:none !important;
    box-sizing:border-box;
    width:calc(100vw - 24px) !important;
    max-width:calc(100vw - 24px) !important;
    display:flex;
    flex-wrap:nowrap;
    gap:4px;
    overflow-x:auto;
    padding:2px !important;
  }
  #arsenal button {
    min-width:72px !important;
    min-height:48px !important;
    flex:1 0 72px !important;
    padding:5px 3px !important;
  }
  #arsenal button span{font-size:10px}
  #controls {
    position:fixed !important;
    left:auto !important;
    right:12px !important;
    bottom:calc(12px + env(safe-area-inset-bottom,0px)) !important;
    transform:none !important;
    box-sizing:border-box;
    width:min(250px,calc(100vw - 24px)) !important;
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:6px;
  }
  #controls .action-btn:not(.hidden){min-width:0;min-height:44px;padding:5px}
  #controls .move-hint{display:none}
}
/* All variants: a retired tower is never a clickable shop item. */
#arsenal button[data-tower="boomerang"] {display:none !important}
