/* Messages share the vacant skill-upgrade area; there is no extra chat panel. */
.chat-messages{--chat-inset-bottom:6px;position:absolute;left:25px;bottom:calc(25px + var(--chat-inset-bottom));width:280px;height:calc(var(--chat-panel-height,248px) - var(--chat-inset-bottom));padding-left:12px;display:flex;flex-direction:column;overflow-x:hidden;overflow-y:auto;scrollbar-width:thin;scrollbar-color:#61768a55 transparent;scrollbar-gutter:stable;pointer-events:none;z-index:14;font:600 13.5px/1.5 Inter,Arial,sans-serif;color:#f2f7fc;text-shadow:-1px -1px 0 #152231,1px -1px 0 #152231,-1px 1px 0 #152231,1px 1px 0 #152231;user-select:none;overscroll-behavior:contain}
.chat-row{display:grid;grid-template-columns:auto minmax(0,1fr) 22px;align-items:start;gap:5px;padding:3px 1px;min-height:25px;border-radius:3px;flex-shrink:0}
.chat-row:first-child{margin-top:auto}
.chat-name{font-weight:800;color:#74e5f7;max-width:122px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;unicode-bidi:isolate}
.chat-text{min-width:0;overflow-wrap:anywhere;white-space:pre-wrap;unicode-bidi:plaintext}
.chat-name[data-team=red]{color:#ff8193}.chat-name[data-team=blue]{color:#78c7ff}
.chat-row.chat-hover,.chat-row:focus-within{background:#15334855}
.chat-row button,.chat-toolbar button{display:grid;place-items:center;width:22px;height:22px;margin:0;padding:3px;border:1px solid #6e93ac66;border-radius:3px;background:#102538bc;color:#c9e9f4;cursor:pointer;pointer-events:auto}
.chat-mute{position:sticky;top:0;align-self:start;opacity:0;pointer-events:none!important}.chat-row.chat-hover .chat-mute,.chat-row:focus-within .chat-mute{opacity:1;pointer-events:auto!important}
.chat-row button:hover,.chat-toolbar button:hover{background:#234960;color:#fff}.chat-row button:focus-visible,.chat-toolbar button:focus-visible{outline:2px solid #6ce8ff;outline-offset:1px}
.chat-row svg,.chat-toolbar svg{width:15px;height:15px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
/* Clip closed skills before revealing chat; keep their green edge visible. */
.skill-panel.chat-active.collapsed{transition:none}
.chat-composer{position:absolute;left:50%;width:min(420px,calc(var(--view-w)*62));transform:translateX(-50%);pointer-events:auto;z-index:61;font:600 13px Inter,Arial,sans-serif;color:#e2edf6}
.chat-toolbar{display:flex;gap:4px;margin-bottom:5px}.chat-toolbar button{width:26px;height:25px}.chat-toolbar button[aria-pressed=false]{color:#eaa889}
.chat-field{--chat-placeholder-color:#9db2c3;display:flex;align-items:center;gap:8px;background:rgba(7,21,35,.9);border:1px solid #69869b;border-radius:3px;padding:8px 10px;box-shadow:0 2px 6px #0003}
#chatInput{width:100%;min-width:0;padding:0;margin:0;border:0;outline:0;background:transparent;color:inherit;font:600 14px/1.35 Inter,Arial,sans-serif;user-select:text}#chatInput::placeholder{color:var(--chat-placeholder-color);opacity:1}
.chat-counter{flex-shrink:0;color:var(--chat-placeholder-color);font-size:10px}.chat-counter.chat-over-limit{color:#ff8193}
#chatStatus{display:block;min-height:16px;margin:4px 1px 0;color:#cad8e2;font:600 11px/1.4 Inter,Arial,sans-serif;text-shadow:0 1px 2px #000}
.chat-muted-list{position:absolute;left:0;bottom:calc(100% + 6px);width:100%;max-height:190px;overflow:auto;background:#102033f5;border:1px solid #58788f;border-radius:4px;padding:8px;box-shadow:0 4px 16px #0005}
.chat-muted-list>div{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:5px 0}.chat-muted-list button{position:static;margin:0;padding:4px 6px;background:#25455a;border:1px solid #7291a5;border-radius:3px;color:#e2edf6;font:600 11px Inter,Arial,sans-serif;cursor:pointer}
#chatNotice{position:absolute;left:50%;bottom:180px;transform:translateX(-50%);max-width:70%;z-index:62;pointer-events:none;color:#e2edf6;background:#102033e6;border-radius:3px;padding:7px 10px;font:600 12px Inter,Arial,sans-serif}
#chatMessages[hidden],#chatComposer[hidden],#chatMutedList[hidden],#chatNotice[hidden]{display:none!important}
body.hud-large-font .chat-messages{font-size:14px}body.hud-large-font #chatInput{font-size:15px}
body.light-background .chat-messages,body.gray-hud .chat-messages{color:#172d40;text-shadow:0 1px 1px #ffffffe0}
body.light-background .chat-messages .chat-name,body.gray-hud .chat-messages .chat-name{color:#136583}
body.light-background .chat-name[data-team=red],body.gray-hud .chat-name[data-team=red]{color:#a72b43}body.light-background .chat-name[data-team=blue],body.gray-hud .chat-name[data-team=blue]{color:#165eb0}
body.light-background .chat-field,body.gray-hud .chat-field{--chat-placeholder-color:#536d80;background:#edf3f7f2;color:#172d40;border-color:#70889b}
body.light-background #chatStatus,body.gray-hud #chatStatus{color:#172d40;text-shadow:0 1px 1px #fff}
/* A death spectator can read/mute chat, but cannot compose or send messages. */
body:has(#deathScreen:not(.hidden)) #chatComposer{display:none!important}
body:has(#deathScreen:not(.hidden)) .skill-panel{clip-path:inset(0 calc(100% - 5px) 0 0);pointer-events:none;transition:none}
body:has(#deathScreen:not(.hidden)) .chat-messages{z-index:21;color:#f2f7fc;text-shadow:-1px -1px 0 #152231,1px -1px 0 #152231,-1px 1px 0 #152231,1px 1px 0 #152231}
body:has(#deathScreen:not(.hidden)) .chat-messages .chat-name{color:#74e5f7}
body:has(#deathScreen:not(.hidden)) .chat-messages .chat-name[data-team=red]{color:#ff8193}
body:has(#deathScreen:not(.hidden)) .chat-messages .chat-name[data-team=blue]{color:#78c7ff}
/* Retain the scoreboard green on dark views; use deeper green on light ground. */
.chat-messages .chat-name[data-team=infected],body:has(#deathScreen:not(.hidden)) .chat-messages .chat-name[data-team=infected]{color:#799a43}
body.light-background .chat-messages .chat-name[data-team=infected],body.gray-hud .chat-messages .chat-name[data-team=infected]{color:#405d1f}
/* Both bindings share the space formerly occupied by auto fire alone. */
.settings-hotkeys{display:grid;grid-template-columns:minmax(0,1fr);row-gap:22px;margin-top:22px}
.settings-hotkey{min-width:0}
.menu-settings .settings-hotkey>.auto-fire-label{margin-top:0;font-family:Inter,Arial,sans-serif;font-size:calc(var(--menu-label-size) * var(--label-scale,1));font-weight:700;color:var(--menu-label-color);letter-spacing:0;line-height:1.2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.settings-hotkey .auto-fire-hint{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.settings-hotkey .auto-fire-controls{width:132px;max-width:100%}
.settings-hotkey .auto-fire-controls button{flex:1 1 0;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;padding-left:4px;padding-right:4px}
#chatKeyBtn,#autoSpinKeyBtn{min-width:62px;border-color:#66dfff}
#chatKeyBtn[aria-busy=true],#autoSpinKeyBtn[aria-busy=true]{background:#21455b}
/* Keep controls reachable on short windows without changing the normal size. */
/* Keep the previous panel height; additional bindings scroll inside it. */
.menu-settings{max-height:min(593.9375px,calc(var(--view-h)*70));overflow-y:auto;overflow-x:hidden;scrollbar-width:thin}

.admin-observing .minimap-hud{position:absolute!important;right:8px!important;bottom:8px!important;left:auto!important;top:auto!important;width:174px!important;height:198px!important;pointer-events:none;z-index:80}.admin-observing #networkNotice{left:8px;bottom:4px;font-size:9px}#adminRoomChat{position:absolute;left:10px;bottom:22px;width:280px;z-index:90;pointer-events:auto;font:600 13.5px/1.5 Inter,Arial,sans-serif}#adminRoomChatLog.chat-messages{position:relative;left:auto;bottom:auto;width:100%;height:145px;padding-left:9px;border-left:3px solid #63c8ae;pointer-events:auto;user-select:text}#adminRoomChatLog .chat-row{display:flex;flex-wrap:wrap;align-items:baseline;gap:3px;padding:2px 0;min-height:22px}#adminRoomChatLog .chat-name{max-width:112px}#adminRoomChatLog .chat-text{flex:1;min-width:70px}#adminRoomChatLog .watch-chat-id{font:600 9px Inter,Arial;opacity:.8;order:1}#adminRoomChatLog button{order:2;width:auto;height:16px;padding:1px 3px;font:9px Inter,Arial;opacity:0;pointer-events:none}#adminRoomChatLog .chat-row:hover button,#adminRoomChatLog button:focus{opacity:1;pointer-events:auto}#adminRoomChat .chat-field{padding:4px 5px;gap:4px;margin-top:5px}#adminRoomChat input{font:600 12px Inter,Arial;background:transparent;color:inherit;border:0;min-width:0;width:100%;padding:0}#adminRoomChat form button{font:600 10px Inter,Arial;padding:3px;background:#315d7b;color:#fff;border:1px solid #87a9c0;border-radius:3px;cursor:pointer}#adminRoomChat>small{display:block;font-size:10px;color:#61788c}#adminRoomChat>small:empty{display:none}
body .chat-messages .chat-row.chat-admin .chat-name,body .chat-messages .chat-row.chat-admin .chat-text{color:#ffdb63;text-shadow:0 1px 2px #111,0 0 2px #111;font-weight:800}body.light-background .chat-messages .chat-row.chat-admin .chat-name,body.light-background .chat-messages .chat-row.chat-admin .chat-text,body.gray-hud .chat-messages .chat-row.chat-admin .chat-name,body.gray-hud .chat-messages .chat-row.chat-admin .chat-text{color:#765000;text-shadow:0 1px 1px #fff,0 0 2px #fff}
