/* Keep the action row and status together so growing labels never cover one another. */
.game-hud-stack{position:fixed;z-index:5;left:20px;top:108px;width:min(520px,calc(100vw - 40px));max-height:min(42vh,370px);display:flex;flex-direction:column;gap:7px;pointer-events:none}
.game-hud-stack>*{position:static;left:auto;top:auto;right:auto;max-width:none;width:100%;pointer-events:auto}
.game-hud-stack .village-hud{display:flex;gap:5px;align-items:stretch;flex-wrap:wrap;background:none}
.game-hud-stack .village-hud button{min-width:0;white-space:normal;line-height:1.2;padding:8px 9px;font-size:11px}
.game-hud-stack .survival-hud{display:flex;gap:7px;align-items:center;padding:8px 10px;line-height:1.3}
.game-hud-stack .survival-hud small{display:none}
.room-chat-dock{position:fixed;z-index:12;left:16px;right:auto;bottom:112px;width:min(350px,calc(100vw - 32px));max-height:min(52vh,420px);display:flex;flex-direction:column;background:#fffdf1;color:#244936;border:1px solid #cadbbd;border-radius:16px;box-shadow:0 14px 48px #142c2580;overflow:hidden}
.room-chat-dock header{display:flex;align-items:center;justify-content:space-between;padding:10px 13px;background:#e4f1d7;font-size:13px}.room-chat-dock header button{background:transparent;color:#244936;font-size:18px}
.room-chat-dock .room-chat-messages{height:min(27vh,230px);min-height:85px;border-radius:0;background:#fffdf1}.room-chat-dock .room-chat-form{margin:0;padding:9px;background:#f2f6e8}
@media(max-width:650px){.game-hud-stack{left:8px;top:calc(101px + env(safe-area-inset-top));width:calc(100vw - 16px);max-height:36vh;gap:5px}.game-hud-stack .village-hud{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px}.game-hud-stack .village-hud button{padding:7px 4px;font-size:10px}.game-hud-stack .survival-hud{display:flex;flex-wrap:wrap;justify-content:center;gap:5px;padding:6px;font-size:10px}.game-hud-stack .survival-hud>*{flex:0 1 auto}.boss-hud{top:auto;bottom:calc(135px + env(safe-area-inset-bottom))}.toast{top:auto;bottom:calc(180px + env(safe-area-inset-bottom));left:50%;max-width:calc(100vw - 24px)}.room-chat-dock{left:auto;right:8px;bottom:calc(78px + env(safe-area-inset-bottom));max-height:47vh}}
@media(max-width:650px) and (max-height:600px){.game-hud-stack{top:calc(55px + env(safe-area-inset-top));max-height:30vh}.game-hud-stack .village-hud button{padding:4px 3px;font-size:9px}.game-hud-stack .survival-hud{padding:4px;font-size:9px}.boss-hud{bottom:65px}.toast{bottom:105px}.room-chat-dock{bottom:60px;max-height:60vh}}

.travel-rescue{position:fixed;z-index:7;left:16px;bottom:calc(190px + env(safe-area-inset-bottom));padding:9px 13px;border-radius:12px;background:#fff2cddd;color:#315257;border:1px solid #eac77c;font-size:12px;font-weight:850;box-shadow:0 5px 17px #16394066;touch-action:manipulation}@media(max-width:650px){.travel-rescue{left:8px;bottom:calc(215px + env(safe-area-inset-bottom));font-size:10px;max-width:150px}}
