:root { --safe-right:env(safe-area-inset-right,0px);--safe-left:env(safe-area-inset-left,0px);--safe-top:env(safe-area-inset-top,0px);--safe-bottom:env(safe-area-inset-bottom,0px); }
.mobile-panel,.mobile-layout,.mobile-notice {position:fixed;z-index:100;box-sizing:border-box;color:#fff;font:16px/1.5 system-ui;pointer-events:auto;}
.mobile-panel {inset:max(10px,var(--safe-top)) max(16px,var(--safe-right)) max(10px,var(--safe-bottom)) max(16px,var(--safe-left));background:#171629f5;border:2px solid #ff951d;border-radius:20px;display:flex;flex-direction:column;max-width:850px;margin:auto;}
.mobile-panel header {display:flex;align-items:center;justify-content:space-between;padding:8px 20px;}.mobile-panel h2{margin:0;font-size:22px;}
.mobile-panel-body {overflow:auto;touch-action:pan-y;padding:8px 20px;display:grid;grid-template-columns:1fr 1fr;gap:14px;}
.mobile-panel label {display:flex;flex-direction:column;gap:6px;}.mobile-panel p{grid-column:1/-1;margin:5px 0 12px;}
.mobile-panel button,.mobile-panel select,.mobile-notice button,.mobile-layout button,.mobile-settings-launch {min-height:44px;border:1px solid #6e678a;border-radius:12px;color:white;background:#33304d;padding:8px 16px;font:600 16px system-ui;touch-action:manipulation;}
.mobile-panel input{min-height:32px;accent-color:#ff951d;width:100%;touch-action:pan-x;}
.mobile-settings-launch {position:fixed;z-index:45;right:max(12px,var(--safe-right));bottom:max(12px,var(--safe-bottom));background:#211c38e8;}
.mobile-settings-launch[hidden]{display:none;}.mobile-layout{inset:0;background:#171629dd;touch-action:none;}
.mobile-layout-tools{display:flex;justify-content:center;align-items:center;gap:24px;padding:8px;}
.mobile-layout-button{position:absolute;border-radius:50%!important;padding:0!important;background:#ff951d88!important;}
.mobile-notice{left:10%;right:10%;top:15%;background:#26213bf5;border:2px solid #ff951d;border-radius:16px;padding:18px;display:flex;align-items:center;gap:12px;flex-wrap:wrap;}
.mobile-room-fields{display:flex;gap:8px;position:relative;z-index:5;}.mobile-room-fields input{min-width:0;width:50%;box-sizing:border-box;min-height:44px;font:16px system-ui;background:#211c38;color:#fff;border:1px solid #999;border-radius:8px;padding:8px;user-select:text;touch-action:manipulation;}
.mobile-game .iw-touch.is-live .iw-touch__btn{opacity:var(--touch-opacity,.65);backdrop-filter:none;font-size:12px;box-sizing:border-box;}
.mobile-game .iw-touch__btn.is-down{opacity:1!important;}
.mobile-game .iw-ui input{font-size:16px!important;user-select:text;-webkit-user-select:text;}
.mobile-game .iw-screen{padding-left:var(--safe-left);padding-right:var(--safe-right);}
.mobile-game .iw-ui button{min-height:40px;min-width:40px;}
.mobile-game .iw-settings__panel{overflow:auto;touch-action:pan-y;max-height:75dvh;}
.mobile-game .iw-hub__steps{display:none;}
.mobile-game .iw-code{display:none;}
.mobile-game .iw-hub__body{top:20%;bottom:8%;overflow-y:auto;touch-action:pan-y;}
.mobile-game .iw-hubcard{flex-shrink:0;}
.mobile-game .iw-hubcard__sub{font-size:12px;}
.mobile-game .iw-setup__body,.mobile-game .iw-loadout__body,.mobile-game .iw-locker__body{bottom:50px;overflow-y:auto;overflow-x:hidden;touch-action:pan-y;padding:8px;}
.mobile-game .iw-setup__maps{grid-auto-columns:120px;overflow-x:auto;touch-action:pan-x;padding:8px;}
.mobile-game .iw-main__menu{top:23%;bottom:48px;transform:none;overflow-y:auto;touch-action:pan-y;padding:6px;min-width:220px;}
.mobile-game .iw-main__menu button{flex-shrink:0;min-height:44px;}
.mobile-game .iw-main__desc{display:none;}
@media(orientation:portrait){.mobile-panel-body{grid-template-columns:1fr;}.mobile-game .iw-screen{overflow-y:auto;touch-action:pan-y;}.mobile-game .iw-hub__body{width:90%;}.mobile-game .iw-hub__me{display:none;}}
