.chat-intro{padding-block:38px!important}.chat-intro h1{font-size:clamp(2rem,4vw,3.5rem)!important}#chat-workspace{max-width:1240px;margin:0 auto 60px;border:1px solid #dce3dc;border-radius:24px;background:#fff;overflow:hidden;box-shadow:0 16px 50px #183e3110}#chat-profile{margin:0;padding:16px 24px;background:#f2f5ef;font-size:.82rem}.chat-tabs{display:flex;gap:8px;padding:14px 20px;border-bottom:1px solid #e2e7df;overflow-x:auto}.chat-tab{flex:1;white-space:nowrap;border:0;border-radius:12px;padding:14px 18px;background:transparent;color:#52685e;font:inherit;font-weight:700;cursor:pointer}.chat-tab[aria-pressed=true]{background:#173f34;color:#fff}.chat-pane{min-width:0}.chat-pane:not(#chat-pane-conversations){padding:24px}.chat-create-panel{padding:16px 24px;border-bottom:1px solid #e2e7df;background:#fbfcf9}.chat-create-panel summary{cursor:pointer;font-weight:700;color:#214b3e}.chat-create-panel[open] .chat-lobby-grid{margin-top:20px}.chat-conversation-layout{display:grid;grid-template-columns:310px minmax(0,1fr);min-height:600px}.chat-sidebar{background:#fafbf8;border-right:1px solid #e2e7df;padding:20px;min-width:0}.chat-sidebar-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:16px}.chat-sidebar-heading h2{font-size:1.2rem;margin:0}.chat-icon-button{border:1px solid #d7dfd6;border-radius:10px;background:white;width:38px;height:38px;font-size:24px;cursor:pointer}.chat-room-search,.chat-room-filter,#chat-message-search{width:100%;min-width:0;border:1px solid #d9e1d7;border-radius:10px;padding:12px;font:inherit;background:white;color:#24483c}.chat-room-filter{margin:10px 0 18px;font-size:.83rem}#room-list{display:flex;flex-direction:column;gap:7px;padding:0;max-height:600px;overflow-y:auto}.chat-room-item{display:flex;align-items:center;gap:12px;width:100%;padding:13px 10px;border:1px solid transparent;border-radius:13px;text-align:left;background:transparent;color:#23483b;cursor:pointer;font:inherit}.chat-room-item:hover{background:#edf2e9}.chat-room-item.is-selected{background:#e6eee2;border-color:#c3d3bf}.chat-room-item:disabled{opacity:.5;cursor:default}.chat-room-avatar{display:grid;place-items:center;flex:none;width:40px;height:40px;border-radius:13px;background:#dce8d7;font-weight:800}.chat-room-copy{flex:1;min-width:0}.chat-room-copy strong{display:block;overflow-wrap:anywhere;font-size:.92rem;line-height:1.4}.chat-room-copy small{display:block;font-size:.69rem;color:#64776c;margin-top:5px}.chat-unread{background:#205f45;color:white;border-radius:20px;font-size:.7rem;padding:3px 7px}.chat-selection-empty{display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;padding:48px;color:#65766c}.chat-selection-empty h2{color:#23483b;font-size:1.5rem}.chat-empty-symbol{font-size:4rem;color:#a7bd96}.chat-room-empty,.chat-thread-empty{padding:25px 12px;text-align:center;font-size:.88rem;color:#63786a}#chat-room{width:100%;max-width:none;margin:0;padding:20px;border:0;border-radius:0;min-width:0;box-shadow:none}.chat-room-header{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.chat-room-header h2{font-size:1.3rem;flex:1;overflow-wrap:anywhere;margin:0}.chat-room-header #back-lobby{padding:8px 12px;font-size:.8rem}#chat-connection{font-size:.72rem;color:#3e7254}#chat-connection:before{content:'●';margin-right:6px;color:#79a563}.chat-safety{font-size:.82rem;margin:12px 0}.chat-safety summary{cursor:pointer}#chat-message-search{padding:9px 12px;font-size:.82rem}#chat-messages{height:clamp(280px,46vh,540px);margin:14px 0;background:#f5f6f0;padding:18px;border-radius:16px;overscroll-behavior:contain}.chat-date{text-align:center;font-size:.7rem;color:#738171;margin:12px 0 20px}.chat-bubble{box-shadow:0 2px 7px #173e3307;border-radius:16px 16px 16px 4px;max-width:85%;line-height:1.6}.chat-bubble.mine{background:#e1eddc;border-radius:16px 16px 4px 16px}.chat-bubble .small{color:#627564}#chat-send textarea{resize:vertical;min-height:80px;max-height:220px;border-radius:13px;margin:8px 0}.chat-composer-tools{display:flex;align-items:center;gap:12px;flex-wrap:wrap}#chat-character-count{margin-left:auto;font-size:.73rem;color:#748271}#chat-emoji{display:flex;gap:4px}#chat-emoji button{background:#f5f7f0;border:0;border-radius:8px;padding:6px;cursor:pointer}#chat-jump{display:block;margin:-5px auto 12px;padding:8px 18px;font-size:.8rem}.chat-panel-heading h2{font-size:1.5rem}.chat-privacy-settings{padding:22px;border-radius:15px;background:#f5f7f0;margin-top:20px}.chat-privacy-settings label{display:block;margin:14px 0}.chat-pane #chat-social{margin:0;border:0;padding:0}.chat-pane #profile-editor{margin:0}.chat-pane input,.chat-pane select{max-width:100%}.chat-tab:focus-visible,.chat-room-item:focus-visible,.chat-icon-button:focus-visible{outline:3px solid #b79558;outline-offset:2px}@media(max-width:720px){#chat-workspace{border-radius:16px;margin-inline:0}.chat-tabs{gap:2px;padding:9px 6px}.chat-tab{padding:12px 8px;font-size:.78rem}.chat-conversation-layout{display:block;min-height:380px}.chat-sidebar{border:0;padding:16px}.chat-selection-empty{display:none}.has-open-room .chat-sidebar{display:none}#chat-room{padding:12px}.chat-create-panel{padding:14px 16px}.has-open-room .chat-create-panel:not([open]){display:none}#chat-messages{height:45dvh;min-height:240px;padding:12px}.chat-bubble{max-width:93%}.chat-pane:not(#chat-pane-conversations){padding:15px}.chat-room-header h2{font-size:1.1rem}.chat-room-header{gap:8px}.chat-composer-tools{gap:8px}#chat-profile{padding:12px 16px;overflow-wrap:anywhere}}

.member-status-group{margin-block:24px}.member-status-group h3{display:flex;align-items:center;gap:8px;font-size:1.15rem}.member-status-group .online-members{max-height:420px}.member-select{display:flex;align-items:center;gap:9px;cursor:pointer;width:100%;margin:0}.member-select input{width:20px;height:20px;accent-color:#205f45;flex:none}.offline-dot{background:#8a918b}.member-presence{font-size:.76rem;border-radius:20px;padding:4px 9px;background:#edf1eb}.member-presence.is-online{background:#e0efdf;color:#245236}.member-presence.is-offline{color:#59635e}.member-selection-tools{display:flex;gap:10px;flex-wrap:wrap;align-items:center;background:#f1f5ec;border:1px solid #d5dfd0;border-radius:12px;padding:16px;margin-block:20px;position:sticky;top:8px;z-index:1}.member-selection-tools p{flex-basis:100%;margin:0}.member-selection-tools .btn{font-size:.86rem}.member-selection-tools button:disabled{opacity:.5;cursor:default}.contact-delivery{border:1px solid #d8e1d4;border-radius:10px;padding:15px;margin-block:12px}.contact-delivery[data-delivery-status=error],.contact-delivery[data-delivery-status=held]{border-color:#bb9b72}.contact-recipients{font-weight:600;overflow-wrap:anywhere}.chat-conversation-dialog{width:min(920px,calc(100vw - 32px));max-width:920px;max-height:92dvh;margin:auto;padding:0;border:1px solid #bdcdb8;border-radius:20px;color:#23483b;background:#fff;box-shadow:0 22px 80px #173e3340;overflow:auto;overscroll-behavior:contain}.chat-conversation-dialog::backdrop,#incoming-request-dialog::backdrop{background:#18382d70}.chat-conversation-dialog #chat-room{padding:20px}.chat-conversation-dialog .chat-room-header{position:sticky;top:0;background:#fff;z-index:2;padding-block:4px 12px}.chat-conversation-dialog #chat-messages{height:34dvh;min-height:180px;max-height:430px}.chat-conversation-dialog #chat-send textarea{min-height:65px;max-height:140px}.chat-conversation-dialog #message-status:empty{display:none}.chat-conversation-dialog #chat-search-help{margin-block:5px}.chat-conversation-dialog .chat-keyboard-hint{margin-block:7px}.chat-conversation-dialog #chat-room>p.small{margin-block:6px}.chat-conversation-dialog .chat-safety{margin-block:8px}#incoming-request-dialog{max-height:88dvh;overflow:auto}#incoming-request-dialog .profile-dialog-head{position:sticky;top:0;background:#fff;z-index:1;padding-block:8px}
@media(max-width:720px){.chat-conversation-dialog{width:calc(100vw - 12px);max-height:96dvh;border-radius:13px}.chat-conversation-dialog #chat-room{padding:12px}.chat-conversation-dialog .chat-room-header h2{font-size:1.1rem}.chat-conversation-dialog #back-lobby{font-size:.73rem}.member-selection-tools{top:0;padding:12px}.chat-conversation-dialog #chat-messages{height:30dvh;min-height:150px}.member-status-group .online-members{max-height:none}}
.contact-message-preview{background:#f1f5ec;border-inline-start:3px solid #8ca77d;padding:14px;border-radius:6px}

.chat-room-actions{display:flex;gap:6px;align-items:center}.chat-preference-button{display:grid;place-items:center;min-width:40px;min-height:40px;padding:6px;border:1px solid #d4dfd0;border-radius:10px;background:#f7f9f4;color:#315441;font:inherit;font-size:1.2rem;cursor:pointer}.chat-preference-button[aria-pressed=true]{background:#e5eedb;border-color:#91aa7e}.chat-preference-button:focus-visible{outline:3px solid #b79558;outline-offset:2px}.chat-room-label,.chat-draft-badge{display:inline-block;font-size:.65rem;padding:2px 6px;border-radius:7px;background:#eef2e9;margin-inline-end:5px;margin-block-start:6px}.chat-draft-badge{background:#fff0ce;color:#735422}.chat-last-activity{display:block;font-size:.65rem;margin-block-start:6px;color:#64776c}.chat-draft-status{font-size:.75rem;color:#617957;margin-block:4px}.chat-draft-status:empty{display:none}.chat-privacy-settings input[type=checkbox]{accent-color:#286a50;min-width:20px;min-height:20px;vertical-align:middle}.chat-room-item:has(.chat-unread) .chat-room-copy strong{font-weight:850}

.voice-panel{margin-block:12px;padding:15px;border:1px solid #b7cfab;border-radius:12px;background:#edf5e6;overflow-wrap:anywhere}.voice-panel strong{display:block}.voice-panel .profile-actions{margin-block-start:10px;display:flex;gap:8px;flex-wrap:wrap}.voice-peer{display:inline-block;margin-inline-end:15px;margin-block-start:5px}.voice-duration{font-variant-numeric:tabular-nums;font-weight:700}.voice-panel[data-voice-phase=incoming]{border-color:#75985c;background:#e2f1d6}.voice-panel .btn{font-size:.82rem;min-height:40px;padding:8px 12px}.voice-help p{line-height:1.6;font-size:.8rem}#voice-call-notice{margin:16px 20px}#voice-remote-audio{display:none}

.chat-translation-settings{border:1px solid #d5dfcc;background:#f7faf3;border-radius:10px;padding:10px 14px;margin:12px 0}.chat-translation-settings summary{cursor:pointer;font-weight:650;font-size:.9rem;min-height:30px}.chat-translation-controls{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:10px 0}.chat-translation-controls label,.chat-source-language{display:grid;gap:4px;font-size:.8rem}.chat-translation-controls select,.chat-source-language select{max-width:100%;width:100%;min-width:0;padding:8px;border:1px solid #b8c5ad;border-radius:6px;background:white;font:inherit}.chat-translation-settings>.btn{margin:4px 6px 4px 0;font-size:.8rem;min-height:40px}.chat-translation-settings p{font-size:.77rem;line-height:1.6}.chat-translated{padding:8px 0}.chat-translated>small{color:#506c37;font-size:.72rem}.chat-translated>p{margin:5px 0}.chat-original{font-size:.82rem;border-top:1px solid #d7dfd1;padding-top:6px}.chat-original summary{cursor:pointer;color:#5d6d57;min-height:28px}.chat-translate-button{border:0;background:transparent;text-decoration:underline;color:#41652d;padding:7px 0;min-height:36px;font-size:.75rem}.chat-source-language{margin-top:8px}.chat-bubble [hidden]{display:none!important}@media(max-width:500px){.chat-translation-controls{grid-template-columns:1fr}.chat-translation-settings>.btn{display:block;width:100%;margin:7px 0}}

.chat-message-actions{display:flex;align-items:center;gap:6px;flex-wrap:wrap;margin-top:7px}.chat-tool-button,.chat-message-actions summary{font:inherit;font-size:.74rem;color:#386043;border:1px solid #d3dece;background:#f9fbf6;border-radius:7px;padding:7px 10px;min-height:36px;cursor:pointer;list-style:none}.chat-message-actions summary::-webkit-details-marker{display:none}.chat-tool-button:focus-visible,.chat-message-actions summary:focus-visible,.chat-reaction-pill:focus-visible{outline:3px solid #b79558;outline-offset:2px}.chat-message-more,.chat-reaction-picker{position:relative}.chat-message-more[open]>div,.chat-reaction-choices{display:flex;gap:5px;flex-wrap:wrap;padding:8px;border:1px solid #c9d8c1;background:#fff;border-radius:9px;margin-top:5px;max-width:100%}.chat-message-more[open]{flex-basis:100%}.chat-message-more[open]>summary{display:inline-block}.chat-reaction-picker[open]{flex-basis:100%}.chat-reaction-choice{font-size:1.1rem;border:1px solid #d2dec9;border-radius:8px;background:#f6f9f1;min-width:42px;min-height:42px;cursor:pointer}.chat-message-reactions{display:flex;gap:5px;flex-wrap:wrap}.chat-message-reactions:empty{display:none}.chat-reaction-pill{border:1px solid #cbdac1;background:#fff;border-radius:18px;padding:5px 10px;color:#385d40;font:inherit;font-size:.8rem;min-height:36px;cursor:pointer}.chat-reaction-pill[aria-pressed=true],.chat-reaction-choice[aria-pressed=true]{background:#d5e9c8;border-color:#769e60}.chat-reply-quote{display:block;width:100%;text-align:start;font:inherit;font-size:.77rem;color:#4b6548;border:0;border-inline-start:3px solid #92ac80;background:#edf3e7;border-radius:5px;padding:9px 12px;margin-block:8px;cursor:pointer;overflow-wrap:anywhere}.chat-reply-quote strong,.chat-reply-quote span{display:block}.chat-reply-quote span{margin-top:3px;white-space:pre-wrap}.chat-reply-quote.is-unavailable{color:#6c7568;cursor:default}.chat-reply-composer{padding:10px 13px;border:1px solid #a9c198;border-inline-start:4px solid #72975d;background:#edf5e6;border-radius:9px;margin-block:12px;font-size:.8rem}.chat-reply-composer p{margin:4px 0 8px;white-space:pre-wrap;overflow-wrap:anywhere}.chat-important-panel{margin-block:12px;border:1px solid #d3ddcb;border-radius:10px;padding:10px 13px;background:#fafbf6}.chat-important-panel>summary{font-weight:650;cursor:pointer;font-size:.86rem;min-height:28px}.chat-important-panel .small{font-size:.76rem}.chat-important-card{padding:12px;border:1px solid #dce5d6;border-radius:8px;background:#fff;margin-block:10px;font-size:.8rem}.chat-important-card>p{white-space:pre-wrap;overflow-wrap:anywhere;margin-block:7px}.chat-pin-badge{display:inline-block;margin-inline-start:10px;font-size:.68rem;color:#536b38}.chat-bubble:focus{outline:2px solid #8aab72;outline-offset:3px}.chat-bubble>p{white-space:pre-wrap;overflow-wrap:anywhere}@media(max-width:500px){.chat-tool-button,.chat-message-actions summary{min-height:40px}.chat-reaction-pill{min-height:40px}.chat-message-actions{gap:5px}.chat-message-more[open]>div{flex-direction:column;align-items:stretch}.chat-important-panel{padding:9px 10px}}

.chat-quoted-full{font-size:.76rem;margin-block:6px;color:#4b6548}.chat-quoted-full summary{cursor:pointer;min-height:32px}.chat-quoted-full p{white-space:pre-wrap;overflow-wrap:anywhere;background:#edf3e7;padding:10px;border-radius:6px}

/* Keep names readable beside voice and preference controls on narrow screens. */
@media(max-width:500px){.chat-conversation-dialog .chat-room-header{display:grid;grid-template-columns:auto minmax(0,1fr);gap:8px}.chat-conversation-dialog #back-lobby{grid-column:1;grid-row:1}.chat-conversation-dialog #chat-room-title{grid-column:2;grid-row:1;min-width:0}.chat-conversation-dialog .chat-room-actions{grid-column:1;grid-row:2}.chat-conversation-dialog #chat-connection{grid-column:2;grid-row:2;justify-self:end;text-align:right;min-width:0}}
