/* Reference UI: source mini sprites + native state frame, redrawn gold controls. */
.game-shell .extras{width:24px;gap:2px;padding:0;display:flex;flex-direction:column}
.game-shell .extras button{width:24px;height:24px;min-height:24px;padding:0;display:grid;place-items:center}
.game-shell .extras button .source-mini{background-repeat:no-repeat!important;background-position:left center!important;background-size:300% 100%!important;width:20px!important;height:20px!important;filter:drop-shadow(0 1px 1px #0006)}
.game-shell .extras button .mini-welfare{background-image:url(assets/ui/welfare.png)!important;background-size:200% 100%!important;width:18px!important;height:18px!important}
.game-shell .extras button .mini-ranking{background-image:url(assets/ui/ranking.png)!important}
.game-shell .extras button .mini-world-map{background-image:url(assets/ui/world-map.png)!important}
.game-shell .extras button .mini-hide-players{background-image:url(assets/ui/hide-players.png)!important}
.game-shell .extras button .mini-utility-settings{background-image:url(assets/ui/utility-settings.png)!important}
/* The source frame is 242x75. Keep its geometry, including the lower rank recess. */
.game-shell .player{--hud-scale:1;display:block;width:242px;height:80px;padding:0;border:0;border-radius:0;background:url(assets/ui/entry-hud-Main.png) left top/242px 75px no-repeat;box-shadow:none;transform:scale(var(--hud-scale));transform-origin:top left;filter:drop-shadow(0 2px 1px #0009)}
.game-shell #avatarButton{position:absolute;left:3px;top:4px;width:64px;height:64px;min-height:0;padding:1px;border:1px solid #9b751f;border-radius:50%;background:#1b1711;box-shadow:0 0 0 1px #30230d;overflow:visible}
.game-shell #avatar{width:100%;height:100%;border:0;object-fit:cover;border-radius:50%}
.game-shell .avatar-level{left:39px;right:auto;bottom:-8px;width:30px;height:30px;display:flex;align-items:center;justify-content:center;padding-bottom:2px;border:0;background:url(assets/ui/entry-hud-Level.png) center/100% 100%;font-family:Tahoma,Arial,sans-serif;font-weight:bold;font-size:12px;line-height:1;box-sizing:border-box}
.game-shell .status-info{position:absolute;inset:0;margin:0;display:block;pointer-events:none}
.game-shell .status-info>strong{position:absolute;left:75px;top:5px;width:145px;height:17px;display:flex;align-items:center;justify-content:center;padding:0 3px 2px;box-sizing:border-box;font-size:12px;line-height:1;color:#78ff41;white-space:nowrap;text-align:center}
.game-shell .status-info .bar{position:absolute;display:flex;align-items:center;justify-content:center;margin:0;border:0;border-radius:0;font:11px/1 Tahoma,Arial,sans-serif;padding:0 0 1px;box-sizing:border-box;text-align:center;color:#fff;text-shadow:1px 1px #000,-1px -1px #000;overflow:visible}
.game-shell .status-info .hp{left:78px;top:25px;width:142px;height:10px;background:url(assets/ui/entry-hud-Life_Image.png) left center/100% 7px no-repeat}
.game-shell .status-info .mp{left:75px;top:36px;width:142px;height:10px;background:url(assets/ui/entry-hud-Mana_Image.png) left center/100% 7px no-repeat}
.game-shell .status-info .xp{left:72px;top:46px;width:142px;height:10px;background:none}
.game-shell .status-info .status-rank{position:absolute;left:70px;top:57px;width:141px;height:13px;display:flex;align-items:center;justify-content:center;padding:0 0 2px;font:12px/1 Tahoma,Arial,sans-serif;color:#ead69b;box-sizing:border-box;text-shadow:1px 1px #000;text-align:center}
/* Round control proportions follow the small horse/Auto reference. */
.game-shell .auto-controls{gap:9px}
.game-shell .auto-controls button{position:relative;width:46px;height:46px;min-height:46px;display:grid;place-items:center;padding:4px;border:2px solid #d6b46b!important;background:radial-gradient(circle at 40% 25%,#3a301e,#11120e 65%)!important;box-shadow:0 0 0 1px #30230f,inset 0 0 0 1px #0b0a07,0 2px 3px #0009!important}
.game-shell .auto-controls .game-icon{width:31px;height:31px;filter:drop-shadow(0 1px 1px #000)}
.game-shell .auto-controls button[aria-label="Auto chưa khả dụng"] .game-icon{position:absolute;top:4px;width:25px;height:25px}
.game-shell .auto-controls button .round-caption{display:block;position:absolute;left:0;right:0;bottom:4px;height:12px;font:11px/12px Tahoma,Arial,sans-serif;color:#fff;text-shadow:1px 1px #000;text-align:center}
/* Restore the eight fixed slots and bright captions in the user's exact order. */
.game-shell .toolbar{height:78px;grid-template-columns:repeat(8,minmax(0,1fr));gap:0;padding:5px 4px;background:linear-gradient(#221c10,#0b0b07 80%);border:1px solid #c49a43;border-radius:5px;box-shadow:inset 0 0 0 2px #352710,0 2px 4px #0008}
.game-shell .toolbar button{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:4px;min-width:0;min-height:0;height:100%;padding:1px 3px;border-radius:0;border-right:1px solid #59421c88!important;box-sizing:border-box}
.game-shell .toolbar button:last-child{border-right:0!important}
.game-shell .toolbar button span{display:flex!important;align-items:center;justify-content:center;width:100%;max-width:none;height:17px;min-height:17px;white-space:nowrap;font:12px/1 Tahoma,Arial,sans-serif;color:#f4e8cb;text-align:center;padding-bottom:1px;box-sizing:border-box;text-shadow:0 1px #000}
.game-shell .toolbar b{width:34px!important;height:34px!important;flex:0 0 auto}
.game-shell .toolbar .tool-6,.game-shell .toolbar .tool-7{width:38px!important;height:38px!important;padding:8px;border:1px solid #b78c3d;border-radius:50%;background:radial-gradient(#342714,#10130e 70%)!important;box-shadow:inset 0 0 0 1px #463215}
.game-shell .chat-group{bottom:100px}.game-shell .joystick{bottom:104px}
@media(max-width:600px) and (orientation:portrait){
 .game-shell .player{--hud-scale:.78}
 .game-shell .toolbar{height:76px;padding:4px 1px;width:calc(100% - 10px)}
 .game-shell .toolbar button{gap:3px;padding:1px}
 .game-shell .toolbar button span{height:22px;min-height:22px;font-size:9px;line-height:11px;white-space:normal;padding:0 1px}
 .game-shell .toolbar b{width:29px!important;height:29px!important}
 .game-shell .toolbar .tool-6,.game-shell .toolbar .tool-7{width:34px!important;height:34px!important;padding:7px}
 .game-shell .auto-controls button{width:40px;height:40px;min-height:40px;padding:3px}.game-shell .auto-controls .game-icon{width:27px;height:27px}.game-shell .auto-controls button[aria-label="Auto chưa khả dụng"] .game-icon{top:3px;width:22px;height:22px}.game-shell .auto-controls button .round-caption{bottom:3px;font-size:10px;height:11px;line-height:11px}
 .game-shell .chat-group{bottom:98px}.game-shell .joystick{bottom:104px}
}
@media(max-height:550px) and (orientation:landscape){.game-shell .player{--hud-scale:.82}.game-shell .toolbar{height:70px;padding:3px}.game-shell .toolbar button span{font-size:11px;height:15px;min-height:15px}.game-shell .toolbar b{width:29px!important;height:29px!important}.game-shell .toolbar .tool-6,.game-shell .toolbar .tool-7{width:34px!important;height:34px!important;padding:7px}.game-shell .auto-controls button{width:38px;height:38px;min-height:38px}.game-shell .auto-controls .game-icon{width:25px;height:25px}.game-shell .chat-group{bottom:88px}.game-shell .joystick{bottom:90px}}
/* Preserve the reference joystick; only orient the central taichi vertically. */
.game-shell .joystick{border:2px solid #cead61aa;background:#211c0e70;box-shadow:none}
.game-shell .joystick>span{font-family:Arial,sans-serif;color:#d4aa6590;text-shadow:none;-webkit-text-stroke:0}
.game-shell .joystick i{border:1px solid #cfb36b;background:linear-gradient(#d6b56eaa,#685334aa)}
.game-shell .joystick .taichi-vertical{width:76%;height:76%;filter:none}
.game-shell .joystick .taichi-vertical>circle:first-child{fill:#cfbb85;stroke:none}
.game-shell .joystick .taichi-vertical>path{fill:#847345}
.game-shell .joystick .taichi-vertical>circle:nth-last-child(2){fill:#cfbb85}
.game-shell .joystick .taichi-vertical>circle:last-child{fill:#847345}
/* Every native three-state sprite must show exactly its first frame. */
.game-shell .extras button:nth-child(n) .source-mini{background-size:300% 100%!important}
.game-shell .extras button:nth-child(n) .mini-welfare{background-size:200% 100%!important}
/* Latest reference adjustment: native miniicons +50%, centre skill slots. */
.game-shell .extras{width:36px;gap:3px}
.game-shell .extras button{width:36px;height:36px;min-height:36px}
.game-shell .extras button:nth-child(n) .source-mini{width:30px!important;height:30px!important}
.game-shell .extras button:nth-child(n) .mini-welfare{width:27px!important;height:27px!important}
/* Exact empty medicine-slot appearance from source mobile-hud.css .item-quick. */
.game-shell .quick{display:flex;flex-direction:column;right:0;top:calc(100% + 8px);gap:4px}
.game-shell .quick .empty-slot{position:relative;width:38px;height:38px;min-height:38px;border:1px solid #bdb26a;background:#161d1699;border-radius:3px;padding:2px;overflow:hidden;font-size:10px;color:#ffebaa;text-align:center;box-shadow:none}
.game-shell .quick .empty-slot:hover{border-color:#ffd700;background:#28301c}
.game-shell .quick small{position:absolute;top:1px;left:2px;font:700 9px/1 Tahoma,sans-serif;color:#ffd700;text-shadow:1px 1px #000}
.game-shell .quick .medicine-empty{display:block;max-height:38px;font:9px/1.15 Tahoma,sans-serif;text-align:center;padding-top:6px;color:#666;text-shadow:1px 1px #000}
/* White left lobe, black right lobe, vertical dots; retain translucent gold pad. */
.game-shell .joystick .taichi-vertical>circle:first-child{fill:#1b1a16;stroke:none}
.game-shell .joystick .taichi-vertical>path{fill:#f3ead0}
.game-shell .joystick .taichi-vertical>circle:nth-last-child(2){fill:#1b1a16}
.game-shell .joystick .taichi-vertical>circle:last-child{fill:#f3ead0}
.game-shell .toolbar .tool-6,.game-shell .toolbar .tool-7{width:42px!important;height:42px!important;padding:9px}
/* Channel header, history, input, and four channel tabs follow the annotated layout. */
.game-shell .chat{padding:3px 7px 4px;border-radius:4px}
.game-shell .chat>#chatToggle{display:flex;align-items:center;justify-content:space-between;width:100%;height:28px;min-height:28px;padding:2px 3px;font-size:12px}
.game-shell .chat-content{height:80px;padding:3px;overflow-y:auto;scrollbar-width:thin;line-height:1.5}
.game-shell #chatForm{display:flex;align-items:center;gap:4px;border-top:1px solid #92774488;padding-top:3px;margin:0;height:31px}
.game-shell #chatInput{flex:1;min-width:0;height:25px;min-height:25px;padding:3px 5px;background:#17160f99;border:1px solid #92774466;border-radius:2px;font:12px Tahoma,sans-serif;color:#f5e7bd}
.game-shell #chatForm button{flex:0 0 24px;display:grid;place-items:center;width:24px;height:25px;min-height:25px;padding:2px;border:0;background:none;color:#d9bd77;font:15px/1 Tahoma,sans-serif}
.game-shell #chatFocus svg{width:21px;height:21px}
.game-shell .chat-channels{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:2px;padding-top:3px}
.game-shell .chat-channels button{display:flex;align-items:center;justify-content:center;min-width:0;height:25px;min-height:25px;padding:2px;font:11px/1 Tahoma,sans-serif;white-space:nowrap;border-radius:2px;border:1px solid #78613388;color:#d7c18b;background:#201c1180}
.game-shell .chat-channels button[aria-selected=true]{color:#ffdc7c;border-color:#c8a552;background:#5e431ba8}
.game-shell .chat.collapsed .chat-content,.game-shell .chat.collapsed #chatForm,.game-shell .chat.collapsed .chat-channels{display:none}
.game-shell .chat.collapsed{padding-bottom:3px}
@media(max-width:600px) and (orientation:portrait){.game-shell .player{--hud-scale:.75}.game-shell .toolbar .tool-6,.game-shell .toolbar .tool-7{width:35px!important;height:35px!important;padding:7px}.game-shell .chat-group{width:calc(100% - 124px)}.game-shell .chat-content{height:70px;font-size:10px}.game-shell .chat-channels button{font-size:10px;height:23px;min-height:23px}.game-shell #chatInput{font-size:11px}}
@media(max-height:550px) and (orientation:landscape){.game-shell .quick{right:0;top:calc(100% + 5px)}.game-shell .chat-group{width:280px;bottom:88px}.game-shell .chat-content{height:38px;font-size:9px}.game-shell .chat>#chatToggle{height:22px;min-height:22px;font-size:10px}.game-shell .chat-channels button{height:21px;min-height:21px;font-size:10px}.game-shell #chatForm{height:27px}.game-shell #chatInput,.game-shell #chatForm button{height:22px;min-height:22px}.game-shell .toolbar .tool-6,.game-shell .toolbar .tool-7{width:35px!important;height:35px!important;padding:7px}}
/* Compact source-style chat: history alone collapses; composer remains available. */
.game-shell .chat-group{width:300px}
.game-shell .chat{position:relative;padding:0;border:0;border-radius:0;background:none;box-shadow:none}
.game-shell .chat>#chatToggle{position:absolute;z-index:1;right:0;top:0;width:22px;height:20px;min-height:20px;padding:0;display:grid;place-items:center;border:0;border-radius:0;background:#211b0a77;color:#e1c98b;font:15px/1 Tahoma,Arial,sans-serif}
.game-shell .chat-content{height:64px;padding:6px 22px 5px 8px;background:#1e170e99;border:1px solid #78623b;border-bottom:0;border-radius:2px 2px 0 0;overflow-y:auto;color:#d5d883;font-size:11px;line-height:1.35;box-sizing:border-box}
.game-shell .chat-content p{margin:1px 0;line-height:1.35}
.game-shell #chatForm,.game-shell .chat.collapsed #chatForm{display:flex;align-items:stretch;height:29px;margin:0;padding:0;gap:0;background:#141108ee;border:1px solid #78623b;border-radius:0 0 2px 2px;box-sizing:border-box}
.game-shell #chatInput{flex:1;min-width:0;height:27px;min-height:27px;padding:3px 7px;border:0;border-radius:0;background:#171008;color:#fff4cb;font:11px/21px TGPC,serif;box-sizing:border-box;box-shadow:none}
.game-shell #chatChannel{flex:0 0 70px;min-width:0;width:70px;height:27px;min-height:27px;margin:0;padding:0 2px;border:0;border-left:1px solid #78623b;border-radius:0;background:#2e2410;color:#ffda50;font:11px TGPC,serif;box-sizing:border-box;cursor:pointer;color-scheme:dark}
.game-shell #chatForm button{flex:0 0 40px;width:40px;height:27px;min-height:27px;padding:0 2px;border:0;border-left:1px solid #78623b;border-radius:0;background:linear-gradient(#3f3218,#211b0e);color:#ffe0a0;font:11px/1 Tahoma,Arial,sans-serif;text-shadow:0 1px #000;display:grid;place-items:center}
.game-shell .chat.collapsed{padding:0;padding-top:17px}
.game-shell .chat.collapsed .chat-content{display:none}
.game-shell .chat.collapsed>#chatToggle{height:17px;min-height:17px;top:0}
/* Source-like mission tracker under the character portrait. */
.game-shell .mission-panel{position:absolute;left:max(8px,env(safe-area-inset-left));top:96px;width:210px;color:#dfddbb;font:11px/1.5 TGPC,serif;text-shadow:1px 1px #000;background:#171b103d;border:1px solid #76663855;border-radius:2px}
.game-shell #missionToggle{display:flex;align-items:center;justify-content:space-between;width:100%;min-height:24px;height:24px;padding:2px 7px;border:0;border-radius:0;background:#231d1066;font:12px TGPC,serif;color:#e8cf8c}
.game-shell .mission-body{padding:5px 7px 7px;min-height:58px}
.game-shell .mission-body p{margin:0 0 6px}
.game-shell #missionDetails{min-height:22px;padding:0;border:0;background:none;color:#f4d766;font:10px/1.4 TGPC,serif;text-align:left}
.game-shell .mission-panel.collapsed .mission-body{display:none}
@media(max-width:600px) and (orientation:portrait){.game-shell .chat-group{width:calc(100% - 124px);max-width:300px}.game-shell .chat-content{height:58px;font-size:10px}.game-shell #chatChannel{flex-basis:64px;width:64px;font-size:10px}.game-shell #chatForm button{flex-basis:36px;width:36px;font-size:10px}.game-shell #chatInput{font-size:10px;padding:3px 5px}.game-shell .mission-panel{top:82px;width:174px;font-size:10px}.game-shell #missionToggle{font-size:11px}.game-shell #missionDetails{font-size:9px}}
@media(max-height:550px) and (orientation:landscape){.game-shell .chat-group{width:280px}.game-shell .chat-content{height:44px;font-size:10px}.game-shell .mission-panel{top:82px;width:180px;font-size:10px}.game-shell .mission-body{min-height:48px;padding:3px 6px}.game-shell #missionDetails{font-size:9px}}
.game-shell #chatChannel{flex-basis:82px;width:82px}
@media(max-width:600px) and (orientation:portrait){.game-shell #chatChannel{flex-basis:76px;width:76px}}
.game-shell .chat-group .chat{max-width:none;width:100%}
/* Pack native minimap icons closely, leaving space for future utilities. */
.game-shell .extras{gap:2px}
.game-shell .extras button{height:30px;min-height:30px}
.game-shell .extras button:first-child{height:27px;min-height:27px}
/* Chat shares the mission tracker's muted olive/brown palette. */
.game-shell .mission-panel,.game-shell .chat{--tracker-bg:#171b103d;--tracker-line:#76663855;--tracker-head:#231d1066}
.game-shell .chat-content{background:var(--tracker-bg);border-color:var(--tracker-line);color:#dfddbb}
.game-shell #chatForm,.game-shell .chat.collapsed #chatForm{background:var(--tracker-bg);border-color:var(--tracker-line)}
.game-shell #chatInput{background:transparent;color:#dfddbb}
.game-shell #chatChannel{order:0;flex-basis:65px;width:65px;border-left:0;border-right:1px solid var(--tracker-line);background:var(--tracker-head);color:#f4d766;font:11px Tahoma,Arial,sans-serif;padding:0 2px}
.game-shell #chatInput{order:1}
.game-shell #chatForm button{order:2;background:var(--tracker-head);border-color:var(--tracker-line);color:#f4d766}
.game-shell .chat>#chatToggle{background:var(--tracker-head);color:#e8cf8c}
.game-shell .toolbar b .menu-art{filter:drop-shadow(0 1px 1px #0008)}
.game-shell .auto-controls .reference-round-art{width:34px;height:34px}
.game-shell .auto-controls button[aria-label="Auto chưa khả dụng"] .reference-round-art{top:3px;width:28px;height:28px}
@media(max-width:600px) and (orientation:portrait){.game-shell #chatChannel{flex-basis:61px;width:61px;font-size:10px}.game-shell .auto-controls .reference-round-art{width:29px;height:29px}.game-shell .auto-controls button[aria-label="Auto chưa khả dụng"] .reference-round-art{width:24px;height:24px}}
/* Original-source toolbar, excluding the reference's crossed-out cells. */
.game-shell .source-toolbar{display:block;width:min(760px,calc(100% - 16px));height:62px;padding:3px 8px 8px;bottom:max(6px,env(safe-area-inset-bottom));border:0;border-radius:0;background:linear-gradient(#272616e6,#181a0ee8);box-shadow:0 1px 4px #0008}
.game-shell .source-toolbar:after{content:'';position:absolute;inset:auto 0 0;height:18px;background:url(assets/ui/source-toolbar/toolbar.png) center bottom/100% auto no-repeat;pointer-events:none}
.game-shell .source-toolbar-scroll{display:flex;align-items:center;justify-content:center;gap:3px;overflow-x:auto;overflow-y:hidden;height:100%;scrollbar-width:thin;scrollbar-color:#bba35d #17190e}
.game-shell .source-toolbar .source-tool{flex:0 0 48px;width:48px;height:48px;min-height:48px;margin:0;padding:0;display:grid;place-items:center;border:0!important;box-shadow:none;background:none;border-radius:0}
.game-shell .source-toolbar .source-tool b{display:block;width:44px!important;height:44px!important;background-repeat:no-repeat!important;background-position:left center!important;background-size:300% 100%!important;filter:drop-shadow(0 1px 1px #0009)}
.game-shell .source-toolbar .native-round b{background-size:contain!important;background-position:center!important;width:46px!important;height:46px!important}
.game-shell .source-toolbar .source-tool-shop{flex-basis:56px;width:56px}.game-shell .source-toolbar .source-tool-shop b{width:55px!important;height:52px!important}
.game-shell .source-toolbar .source-tool-world-map b{width:36px!important;height:36px!important}
.game-shell .source-toolbar .source-tool:hover{filter:brightness(1.18)}
@media(max-width:600px) and (orientation:portrait){.game-shell .source-toolbar{height:57px;padding:2px 4px 7px;width:calc(100% - 10px)}.game-shell .source-toolbar-scroll{justify-content:flex-start;gap:1px}.game-shell .source-toolbar .source-tool{flex-basis:43px;width:43px;height:44px;min-height:44px}.game-shell .source-toolbar .source-tool b{width:38px!important;height:40px!important}.game-shell .source-toolbar .native-round b{width:42px!important;height:42px!important}.game-shell .source-toolbar .source-tool-shop{flex-basis:51px}.game-shell .source-toolbar .source-tool-shop b{width:49px!important;height:46px!important}}
@media(max-height:550px) and (orientation:landscape){.game-shell .source-toolbar{height:56px}.game-shell .source-toolbar .source-tool{height:44px;min-height:44px}}
.game-shell .source-toolbar{width:max-content;max-width:calc(100% - 16px);background:linear-gradient(#292e1bde,#151b0fef);border:1px solid #746d38;border-radius:3px;padding-inline:5px}
.game-shell .source-toolbar-scroll{gap:2px}
.game-shell .source-toolbar .source-tool{flex-basis:46px;width:46px}
.game-shell .source-toolbar .native-round b{width:44px!important;height:44px!important;image-rendering:auto}
.game-shell .source-toolbar .source-tool-shop{flex-basis:55px}
@media(max-width:600px) and (orientation:portrait){.game-shell .source-toolbar{width:calc(100% - 10px)}.game-shell .source-toolbar .source-tool{flex-basis:42px;width:42px}.game-shell .source-toolbar .native-round b{width:40px!important;height:40px!important}.game-shell .source-toolbar .source-tool-shop{flex-basis:51px}}
.game-shell .source-toolbar .source-tool b{position:relative;overflow:hidden;flex:none}
.game-shell .source-toolbar .source-tool b img{position:absolute;left:0;top:0;width:300%;height:100%;max-width:none;object-fit:fill}
.game-shell .source-toolbar .native-round b img{width:100%;height:100%;object-fit:contain}
/* Transparent source toolbar, native-like icon proportions, two flanking skill cells. */
.game-shell .source-toolbar{background:none;border:0;box-shadow:none;padding:2px 4px 9px;height:58px;width:max-content;max-width:calc(100% - 12px)}
.game-shell .source-toolbar:after{height:13px;opacity:.95}
.game-shell .source-toolbar-scroll{gap:2px}
.game-shell .source-toolbar .source-tool{flex:0 0 38px;width:38px;height:42px;min-height:42px;padding:0}
.game-shell .source-toolbar .native-round b{width:36px!important;height:36px!important}
.game-shell .source-toolbar .source-tool-shop{flex-basis:46px;width:46px}
.game-shell .source-toolbar .source-tool-shop b{width:45px!important;height:43px!important}
.game-shell .source-toolbar .source-tool-world-map b{width:34px!important;height:34px!important}
.game-shell .source-toolbar .source-skill{display:grid;place-items:center;flex:0 0 42px;width:42px;height:42px;min-height:42px;border:1px solid #a28b4d!important;border-radius:3px;padding:0;background:#151a0d50;box-shadow:inset 0 0 0 1px #342d1855}
.game-shell .source-toolbar .source-skill span{display:grid!important;place-items:center;width:100%;height:100%;min-height:0;padding:0;color:#d9bd74;font:26px/1 Georgia,serif;text-shadow:0 1px #000}
@media(max-width:600px) and (orientation:portrait){.game-shell .source-toolbar{width:calc(100% - 10px);height:55px;padding:1px 3px 8px}.game-shell .source-toolbar .source-tool{flex-basis:35px;width:35px;height:40px;min-height:40px}.game-shell .source-toolbar .native-round b{width:33px!important;height:33px!important}.game-shell .source-toolbar .source-tool-shop{flex-basis:43px;width:43px}.game-shell .source-toolbar .source-tool-shop b{width:42px!important;height:40px!important}.game-shell .source-toolbar .source-skill{flex-basis:38px;width:38px;height:38px;min-height:38px}}
@media(max-height:550px) and (orientation:landscape){.game-shell .source-toolbar{height:55px}}
.game-shell .source-toolbar{display:flex;align-items:center;gap:4px}
.game-shell .source-toolbar-scroll{flex:1;min-width:0;justify-content:flex-start}
.game-shell .source-toolbar .source-skill{position:relative;z-index:1}
/* Compact bottom HUD: 4px above the toolbar, 4px between chat and round controls. */
.game-shell .chat-group{right:max(8px,env(safe-area-inset-right));bottom:66px}
.game-shell .auto-controls{gap:5px;margin-bottom:4px}
.game-shell .joystick{left:max(8px,env(safe-area-inset-left));bottom:66px}
@media(max-width:600px) and (orientation:portrait){.game-shell .chat-group{width:calc(100% - 112px);max-width:300px;bottom:66px}.game-shell .joystick{bottom:66px}.game-shell .auto-controls{gap:5px;margin-bottom:4px}}
@media(max-height:550px) and (orientation:landscape){.game-shell .chat-group,.game-shell .joystick{bottom:66px}}
.game-shell .chat-group{bottom:62px}
.game-shell .joystick{bottom:62px}
.game-shell .chat{margin:0}
.game-shell .chat-content{height:50px;padding:5px 22px 4px 7px}
.game-shell .auto-controls{margin-bottom:4px;gap:5px}
@media(max-width:600px) and (orientation:portrait){.game-shell .chat-group,.game-shell .joystick{bottom:62px}.game-shell .chat-content{height:46px}}
@media(max-height:550px) and (orientation:landscape){.game-shell .chat-group,.game-shell .joystick{bottom:62px}.game-shell .chat-content{height:38px}}
/* Keep joystick 8px beside the chat instead of leaving a wide empty middle. */
.game-shell .joystick{left:auto;right:316px}
@media(max-width:600px) and (orientation:portrait){.game-shell .joystick{left:auto;right:calc(min(300px,100vw - 112px) + 16px)}}
@media(max-height:550px) and (orientation:landscape){.game-shell .joystick{left:auto;right:296px}}
/* Restore the joystick's previous left-hand position. */
.game-shell .joystick{left:max(8px,env(safe-area-inset-left));right:auto}
@media(max-width:600px) and (orientation:portrait){.game-shell .joystick{left:max(8px,env(safe-area-inset-left));right:auto}}
@media(max-height:550px) and (orientation:landscape){.game-shell .joystick{left:max(8px,env(safe-area-inset-left));right:auto}}
/* Align all three round actions to the right edge in both orientations. */
.game-shell .chat-group .auto-controls{justify-content:flex-end;width:100%;margin-left:0;margin-right:0}
@media(orientation:portrait) and (max-width:482px){.game-shell .chat-group,.game-shell .joystick{bottom:calc((100vw - 8px) * 56 / 483 + 6px)}}
/* Leave room above the right-side round actions on short landscape screens. */
@media(max-height:550px) and (orientation:landscape){.game-shell .quick .empty-slot{width:28px;height:28px;min-height:28px}}
/* Portrait-only composition from the marked reference. */
@media(orientation:portrait){
 .game-shell .joystick{width:clamp(116px,30vw,144px);height:clamp(116px,30vw,144px);left:max(16px,env(safe-area-inset-left));right:auto;bottom:86px}
 .game-shell .joystick i{width:42%;height:42%}
 .game-shell .chat-group{width:calc(100% - 176px);max-width:300px;right:max(8px,env(safe-area-inset-right))}
}
@media(orientation:portrait) and (max-width:482px){.game-shell .joystick{bottom:calc((100vw - 8px) * 56 / 483 + 30px)}}
/* Source HUD enlarged to the marked portrait size; mission tracker follows below. */
@media(orientation:portrait){.game-shell .player{--hud-scale:.95}.game-shell .mission-panel{top:94px}.game-shell .chat-group{width:calc(100% - 176px);max-width:300px}}
/* Fit the enlarged HUD beside the source minimap utility column on narrow phones. */
@media(orientation:portrait) and (max-width:420px){.game-shell .player{--hud-scale:.86}}
.game-shell .map-coordinates{height:15px;line-height:15px;text-align:center;color:#f3df9e;font:10px/15px TGPC,serif;text-shadow:1px 1px #000;white-space:nowrap}
