body.referenceHUD #globalChat{width:min(calc(300px * var(--global-chat-scale,1)),calc(100vw - 20px))!important}body.referenceHUD #chatPanel{height:min(calc(225px * var(--global-chat-scale,1)),calc(100dvh - 84px))!important;padding:7px!important;gap:6px}
#chatPanel>.chatHead>strong{font-size:13px!important}#chatPanel .chatHead button{width:25px!important;height:25px!important;min-height:25px!important;padding:2px!important}#chatPanel #chatMessages{padding:6px!important}#chatPanel #chatMessages .chatMessage{gap:6px;margin-bottom:8px!important}#chatPanel .globalMessageAvatar{width:24px!important;height:24px!important}#chatPanel .chatPlayerName{font-size:11px!important;min-height:15px!important}#chatPanel .globalMessageTime{font-size:8px!important}.chatMessageStack{min-width:0;flex:1;display:flex;flex-direction:column;align-items:flex-start;gap:5px}.chatMessageBubble{max-width:100%!important;padding:5px 7px!important;font-size:11px!important;line-height:1.4!important;border-radius:8px!important;white-space:pre-wrap}.chatMessageBubble[hidden]{display:none!important}#chatPanel .chatScreenshot{display:block;max-width:160px!important;max-height:105px!important;width:auto;height:auto;border:0!important;border-radius:4px!important;background:transparent!important;padding:0!important;margin:0!important}#chatPanel .chatMessageLine .messageOptionsTrigger{width:23px!important;min-width:23px!important;height:23px!important;min-height:23px!important}#chatPanel #chatForm>button,#chatPanel #chatInput{height:29px!important;min-height:29px!important;font-size:11px!important}#chatPanel #chatForm>button{width:29px}#chatForm{gap:5px!important}#chatPin::before,#chatSend::before{width:19px!important;height:19px!important}
/* Message headers and media remain outside text bubbles. */
#friendsPanel .friendMessage{display:grid!important;grid-template-columns:24px minmax(0,1fr) 23px!important;grid-template-rows:auto auto auto auto!important;gap:4px 6px!important;align-items:start!important;max-width:92%!important;width:fit-content!important;min-width:100px!important;background:transparent!important;border:0!important;border-radius:0!important;padding:0!important;margin-block:0 10px!important}
#friendsPanel .friendMessage.ownMessage{background:transparent!important;margin-left:auto!important}#friendsPanel .friendMessage .messageAvatar{grid-column:1;grid-row:1/4;width:24px!important;height:24px!important;margin:0!important}#friendsPanel .friendMessage .messageSender{grid-column:2/4;grid-row:1;justify-content:flex-start!important;min-height:17px!important;height:auto!important;padding:0!important;font-size:11px!important;line-height:1.3!important;background:none!important;border:0!important;text-align:left!important}
#friendsPanel .friendMessage .messageBody{grid-column:2;grid-row:2;display:block;justify-self:start;width:fit-content;max-width:100%;min-width:0;background:#1d719a!important;border:1px solid #559dbd;border-radius:8px;padding:6px 8px!important;font-size:12px!important;line-height:1.45!important;white-space:pre-wrap;overflow-wrap:anywhere}#friendsPanel .friendMessage .messageBody[hidden]{display:none!important}#friendsPanel .friendMessage.ownMessage .messageBody{background:#258ab3!important}#friendsPanel .friendMessage .messageActions{grid-column:3;grid-row:2;margin:0!important;align-self:start}#friendsPanel .friendMessage .messageTime{grid-column:2/4;grid-row:4;font-size:8px!important;line-height:1.2;text-align:right!important;margin:0!important}#friendsPanel .friendMessage .friendScreenshot{grid-column:2;grid-row:3;max-width:180px!important;max-height:125px!important;width:auto;height:auto;margin:0!important;padding:0!important;border:0!important;border-radius:4px!important;background:transparent!important}#friendsPanel .friendMessage .voicePlayer{grid-column:2;grid-row:3;min-width:170px;max-width:100%}#friendsPanel .deletedMessage .messageBody{background:none!important;border:0!important;padding:0!important;opacity:.65}
/**** Center glyphs using flex geometry, not font baselines or legacy icon margins. ****/
body.referenceHUD :is(.messageOptionsTrigger,.roomInfoOpen,#friendSearch>button[type=submit],#accountDialog .accountFieldEdit){display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:0!important;padding:0!important;line-height:1!important;text-indent:0!important;vertical-align:middle}
.messageOptionsTrigger .previewIcon{display:none!important}.messageOptionsTrigger::after,.roomInfoOpen::after{content:'•••';font:700 12px/1 sans-serif;letter-spacing:1px;display:block;transform:none}.messageOptionsTrigger,.roomInfoOpen{font-size:0!important}.roomInfoOpen{width:30px!important;height:30px!important;min-height:30px!important}.messageOptionsTrigger{width:23px!important;height:23px!important;min-height:23px!important}#friendSearch>button[type=submit]{align-self:center;margin:0!important}#friendSearch>button[type=submit]::after{margin:0!important;width:21px!important;height:21px!important;flex:none}
body.referenceHUD #accountDialog .accountEditableField>.accountFieldEdit{bottom:3px!important;right:4px!important;width:28px!important;height:28px!important;min-height:28px!important;border:0!important;box-sizing:border-box}#accountDialog .accountFieldEdit .previewIcon{width:20px!important;height:20px!important;margin:0!important;object-fit:contain}#accountDialog .accountJoinedCard{margin-right:8px!important;margin-top:9px!important;padding:7px!important;align-self:flex-start!important}.accountSubmenu #accountUsernameTools{padding:0;border:0}.accountSubmenu #accountUsernameTools>summary{display:none}.accountSubmenu #accountUsernameTools[hidden]{display:none!important}
body.referenceHUD #mapDialog{inset:50% auto auto 50%!important;transform:translate(-50%,-50%)!important;margin:0!important;height:min(590px,calc(100dvh - 50px))!important}#mapDialog .mapLayout>aside{display:flex!important;flex-direction:column!important;min-height:0!important;height:100%!important}#mapDialog #catalog{flex:1 1 0!important;min-height:90px!important;max-height:none!important;height:auto!important;overflow-y:auto!important}#mapDialog .mapLayout{min-height:0!important;height:calc(100% - 60px)!important}#mapDialog .gameSelectTrigger{display:flex!important;align-items:center!important;justify-content:center!important;text-align:center!important;gap:6px!important;min-width:0}#mapDialog .gameSelectTrigger>span{flex:1;min-width:0;text-align:center!important;padding:0!important}#mapDialog .gameSelectTrigger::after{flex:none;position:static!important;margin:0!important}#mapDialog #atlasCanvas{background:#020713!important}#mapDialog .atlasCaption{max-width:35%}#mapDialog #atlasToolbar{max-width:65%}
body.referenceHUD #pilotStatus{display:flex!important;align-items:center!important;justify-content:center!important;text-align:center!important;padding:0 8px!important;line-height:1!important;box-sizing:border-box}
body.referenceHUD #walkTouch{position:static!important;inset:auto!important;width:0!important;height:0!important}body.referenceHUD #walkTouch #walkRun{position:fixed!important;left:calc(22px + var(--stick-size,118px) + 14px)!important;bottom:max(55px,env(safe-area-inset-bottom))!important;width:48px!important;height:48px!important}body.referenceHUD #walkTouch #walkJump{position:fixed!important;left:auto!important;right:max(24px,env(safe-area-inset-right))!important;bottom:max(28px,env(safe-area-inset-bottom))!important;width:var(--jump-size,100px)!important;height:var(--jump-size,100px)!important}
#helpDialog{width:min(640px,calc(100vw - 28px));max-height:calc(100dvh - 28px);overflow:auto;background:#104d70;border:2px solid #9bdbed;border-radius:13px;padding:16px}.helpGuide{display:grid;gap:13px}.helpGuide section{padding-bottom:12px;border-bottom:1px solid #b9eaff44}.helpGuide h3{margin:3px 0 7px;font-size:17px}.helpGuide p,.helpGuide li,.helpGuide dd{font-size:13px;line-height:1.55;color:#d0eaf7}.helpGuide li{margin-bottom:6px}.helpGuide ol{padding-left:20px}.helpGuide dt{font-size:12px;font-weight:600}
@media(max-height:480px){body.referenceHUD #mapDialog{width:min(660px,calc(100vw - 120px))!important;height:calc(100dvh - 40px)!important;max-height:calc(100dvh - 40px)!important}body.referenceHUD #mapDialog .mapSelectedText h2{font-size:16px!important}body.referenceHUD #mapDialog #selection{max-height:105px!important;padding:7px!important}#mapDialog .mapLayout>aside{width:170px!important}#mapDialog .mapLayout{grid-template-columns:170px minmax(0,1fr)!important}#mapDialog #catalog button{min-height:43px!important}#mapDialog .dialogHead{height:36px!important;min-height:36px!important;margin-bottom:8px!important}#mapDialog .mapLayout{height:calc(100% - 44px)!important}}
.messageOptionsTrigger::after,.roomInfoOpen::after{content:''!important;width:19px;height:19px;background:url('./icons/ui/more-centered.svg') center/contain no-repeat;flex:none;letter-spacing:0!important}
#mapDialog .gameSelectTrigger{position:relative!important;padding-inline:22px!important}#mapDialog .gameSelectTrigger::after{content:''!important;position:absolute!important;right:9px!important;top:50%!important;transform:translateY(-25%)!important;border:4px solid transparent;border-top-color:#b6e9ff;width:0!important;height:0!important;margin:0!important}
@media(max-height:480px){#mapDialog #tabs{display:none!important}#mapDialog #search{height:30px!important;margin-bottom:6px!important}#mapDialog #systemFilter+.gameSelectTrigger{height:30px!important;min-height:30px!important;margin-bottom:6px!important}#mapDialog #catalogFilters{margin-bottom:6px!important}}
