/* Firewall Rush */
* { box-sizing: border-box; }

html, body {
    margin: 0;
    height: 100%;
    overflow: hidden;
    overscroll-behavior: none;
    background: #0b0e0c;
    color: #e9f2ec;
    font-family: ui-monospace, 'JetBrains Mono', Consolas, Menlo, monospace;
}

[hidden] { display: none !important; }
#game { position: fixed; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
.screen { display: flex; flex-direction: column; align-items: center; text-align: center; }

#menu { position: fixed; inset: 0; z-index: 3; justify-content: center; gap: 16px; padding: 20px; overflow-y: auto; background: rgba(8, 12, 10, .72); }
#menu h1 { margin: 0; color: #fff; font-size: clamp(36px, 9vw, 92px); font-weight: 900; overflow-wrap: anywhere; text-shadow: 4px 0 0 #ff5c8a, -4px 0 0 #7ae7ff; }
#menu h1 span { color: #39ff88; }
.tag { margin: 0 0 12px; color: #d3e2d8; font-size: clamp(14px, 2vw, 18px); }
.row { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 14px; border: 1px solid #5a6e62; border-radius: 7px; background: #101511; color: #e9f2ec; font: 700 13px ui-monospace, Consolas, monospace; text-decoration: none; cursor: pointer; }
.btn:hover { border-color: #39ff88; color: #39ff88; }
.btn:disabled { opacity: .45; cursor: default; }
.btn.hack { border-color: #39ff88; color: #39ff88; }
.btn.primary { padding: 15px 34px; border: 0; background: #39ff88; color: #06140c; font-size: 20px; }
.btn.primary:hover { background: #7dffaf; color: #06140c; }
.btn.primary.small { padding: 8px 12px; font-size: 13px; }
.site-home { position: fixed; top: calc(12px + env(safe-area-inset-top)); left: 12px; z-index: 4; }

#bar { position: fixed; top: 0; left: 0; right: 0; z-index: 2; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 8px; padding: calc(6px + env(safe-area-inset-top)) 8px 4px; background: rgba(11, 14, 12, .92); }
.bar-right { display: flex; gap: 6px; }
#hud { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 16px; color: #c7d3cb; font-size: 12px; }
#hud b { color: #fff; font-size: 17px; }
@media (max-width: 720px) {
    #hud { order: 3; width: 100%; }
}

#tray { position: fixed; left: 0; right: 0; bottom: 0; z-index: 2; display: flex; flex-wrap: wrap; align-items: stretch; justify-content: center; gap: 6px 10px; padding: 6px 8px calc(6px + env(safe-area-inset-bottom)); background: rgba(11, 14, 12, .92); }
#tower-list { display: flex; flex: 1 1 320px; justify-content: center; gap: 5px; max-width: 640px; }
.tray-side { display: flex; flex: 0 1 auto; gap: 6px; }
.tower-btn { display: flex; flex: 1 1 0; flex-direction: column; align-items: center; justify-content: center; min-width: 0; min-height: 56px; padding: 4px 2px; border: 2px solid #3a4a40; border-radius: 7px; background: #101511; color: #e9f2ec; font: 700 11px ui-monospace, Consolas, monospace; cursor: pointer; }
.tower-btn b { display: block; color: #ffd166; font-size: 13px; }
.tower-btn i { display: block; width: 14px; height: 14px; margin-bottom: 2px; border-radius: 3px; }
.tower-btn.on { border-color: #39ff88; background: #173022; }
.tower-btn.poor { opacity: .5; }

#tower-panel { position: fixed; left: 50%; bottom: 96px; z-index: 3; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; width: min(560px, calc(100% - 16px)); padding: 8px; border: 1px solid #39ff88; border-radius: 8px; background: #101511; transform: translateX(-50%); }
#tp-info { flex: 1 1 170px; color: #c7d3cb; font-size: 12px; }
#tp-info b { display: block; color: #fff; font-size: 14px; }

.modal { position: fixed; inset: 0; z-index: 5; justify-content: center; gap: 14px; padding: 16px; overflow-y: auto; background: rgba(5, 8, 6, .86); }
.modal h2 { margin: 0; color: #39ff88; font-size: clamp(26px, 5vw, 42px); font-weight: 900; }

#panel-body, #patch-list { display: flex; flex-direction: column; gap: 8px; width: min(520px, 100%); text-align: left; }
#panel-body .help { color: #d3e2d8; font-family: Arial, sans-serif; font-size: 15px; line-height: 1.5; }
#panel-body .help b { color: #39ff88; }
#panel-body .note { margin: 4px 0 0; color: #c7d3cb; font-size: 13px; }

.cheat { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 56px; padding: 8px 12px; border: 1px solid #5a6e62; border-radius: 7px; background: #0b0e0c; color: #e9f2ec; font: inherit; text-align: left; cursor: pointer; }
.cheat:hover { border-color: #39ff88; }
.cheat small { display: block; margin-top: 2px; color: #c7d3cb; font-size: 12px; }
.cheat b { font-size: 14px; }
.cheat i { flex: none; font-style: normal; font-weight: 900; font-size: 13px; }
.cheat.on { border-color: #39ff88; background: #39ff88; color: #06140c; }
.cheat.on small { color: #06240f; }

#over-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; width: min(560px, 100%); }
.stat { padding: 10px; border: 1px solid #3a4a40; border-radius: 8px; background: #101511; }
.stat b { display: block; color: #fff; font-size: 21px; }
.stat span { color: #c7d3cb; font-size: 11px; }
.stat.hl b { color: #39ff88; }

.promo { margin: 4px 0 0; color: #d3e2d8; font-size: 14px; }
.promo a { display: inline-block; padding: 8px 4px; color: #39ff88; font-weight: 700; }
