:root{font-family:Inter,Pretendard,"Noto Sans KR",system-ui,sans-serif;color:#253149;background:#f2f5f9;font-synthesis:none}*{box-sizing:border-box}body{margin:0}button,input,textarea{font:inherit}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.5}.app-shell{display:grid;grid-template-columns:292px minmax(0,1fr) 0;height:100dvh;min-height:520px;overflow:hidden}.app-shell.detail-open{grid-template-columns:292px minmax(0,1fr) 288px}.sidebar{display:flex;flex-direction:column;min-height:0;background:#111b2d;color:#eaf0fa;padding:26px 15px 16px}.brand{display:flex;align-items:center;gap:11px;padding:0 12px 30px}.brand-mark{display:grid;place-items:center;width:37px;height:37px;border-radius:12px;background:#17b99a;color:#fff;font-size:25px}.brand strong,.profile strong{display:block;font-size:15px}.brand small,.profile small{display:block;margin-top:3px;color:#8da0bb;font-size:11px}.sidebar-actions{display:flex;gap:8px;margin:0 5px 19px}.primary-button,.secondary-button,.icon-button{border:0;border-radius:10px;transition:background .15s,transform .15s}.primary-button{background:#17b99a;color:#fff;font-weight:700;padding:11px 15px}.primary-button:hover,.send-button:hover{background:#0da88b}.sidebar-actions .primary-button{flex:1;text-align:left}.icon-button{display:grid;place-items:center;width:40px;height:40px;background:#25324a;color:#eaf0fa;font-size:22px}.icon-button:hover{background:#344762}.icon-button.light{background:transparent;color:#66758c}.icon-button.light:hover{background:#eef2f7}.search-wrap{display:flex;align-items:center;gap:9px;background:#202d43;color:#9cafc8;border-radius:9px;padding:0 12px;margin:0 5px 21px;height:39px}.search-wrap span{font-size:24px;line-height:0}.search-wrap input{width:100%;background:transparent;border:0;outline:0;color:#fff;font-size:13px}.search-wrap input::placeholder{color:#899ab3}.sidebar nav{overflow:auto;flex:1}.section-label{padding:0 11px 9px;text-transform:uppercase;color:#8193ac;font-size:11px;font-weight:800;letter-spacing:.08em}.direct-label{margin-top:24px}.room-list{display:grid;gap:3px}.room-item{display:flex;align-items:center;width:100%;gap:10px;border:0;background:transparent;color:#e8eef9;border-radius:9px;padding:10px 11px;text-align:left}.room-item:hover{background:#202d43}.room-item.active{background:#263b54}.room-icon,.avatar{display:grid;place-items:center;flex:none;width:38px;height:38px;border-radius:12px;background:#344861;color:#c9f7ea;font-size:17px;font-weight:700}.avatar{border-radius:50%;font-size:12px;background:#6577a4;color:#fff}.avatar.me{background:#19b99b}.room-icon.direct{border-radius:50%;background:#44617a}.room-text{min-width:0;flex:1}.room-text strong,.room-text small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.room-text strong{font-size:13px;font-weight:650}.room-text small{font-size:11px;color:#9bacc2;margin-top:4px}.room-count{font-size:10px;color:#d3e0ef}.profile{display:flex;align-items:center;gap:10px;border-top:1px solid #29374d;padding:17px 11px 0;margin-top:12px}.profile-dot{width:8px;height:8px;background:#27cca7;border-radius:50%;margin-left:auto}.conversation{display:flex;flex-direction:column;min-width:0;min-height:0;background:#f8fafc}.conversation-header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:18px 28px;min-height:79px;border-bottom:1px solid #e3e9f0;background:#fff}.room-identity{display:flex;align-items:center;gap:12px;min-width:0}.room-identity h1{font-size:17px;margin:0;font-weight:750;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.room-identity p{font-size:12px;color:#8a97aa;margin:4px 0 0}.header-actions{display:flex;align-items:center;gap:7px}.secondary-button{background:#eef4f6;color:#178b79;padding:10px 13px;font-size:12px;font-weight:700}.secondary-button:hover{background:#dfeeea}.message-list{flex:1;overflow:auto;padding:26px max(28px,calc((100% - 860px)/2));display:flex;flex-direction:column;gap:19px}.date-divider{align-self:center;padding:6px 12px;border-radius:20px;background:#eaf0f6;color:#8b99a9;font-size:11px;font-weight:650;margin:2px 0 7px}.message{display:flex;gap:9px;max-width:80%;align-self:flex-start}.message.mine{align-self:flex-end;flex-direction:row-reverse}.message .avatar{width:32px;height:32px;font-size:11px}.message-main{min-width:0}.message-meta{display:flex;align-items:center;gap:7px;margin:0 0 5px;font-size:11px;color:#8a97a9}.message.mine .message-meta{justify-content:flex-end}.message-meta strong{color:#526078;font-size:11px}.bubble{background:#fff;border:1px solid #e7ecf2;border-radius:4px 14px 14px 14px;padding:11px 14px;box-shadow:0 2px 8px rgba(33,53,84,.03);font-size:13px;line-height:1.6;white-space:pre-wrap;overflow-wrap:anywhere}.mine .bubble{background:#dff8f0;border-color:#c9f0e3;border-radius:14px 4px 14px 14px}.message.whisper .bubble{background:#f0eafd;border-color:#e2d7fa}.message.whisper.mine .bubble{background:#e9defd}.whisper-label{font-size:10px;font-weight:750;color:#8459bd;margin-bottom:5px}.file-chip{display:flex;align-items:center;gap:9px;background:rgba(255,255,255,.65);border:1px solid #dde6ec;border-radius:9px;padding:9px 10px;margin-top:8px;color:#344255;text-decoration:none;font-size:12px;max-width:280px}.file-chip span{font-size:18px}.file-chip strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:650}.empty-state{margin:auto;text-align:center;color:#8a98a9;max-width:310px}.empty-state .empty-icon{display:grid;place-items:center;margin:auto auto 18px;width:70px;height:70px;border-radius:24px;background:#e5f8f2;color:#0da98b;font-size:32px}.empty-state h2{font-size:17px;color:#344255;margin:0 0 7px}.empty-state p{font-size:13px;line-height:1.6;margin:0}.composer-area{padding:14px max(28px,calc((100% - 860px)/2)) 17px;background:#fff;border-top:1px solid #e8edf3}.composer{display:flex;align-items:flex-end;gap:9px;background:#f5f7fa;border:1px solid #e1e7ee;border-radius:13px;padding:7px 8px}.composer:focus-within{border-color:#94dccc}.attach-button{display:grid;place-items:center;width:34px;height:34px;border-radius:8px;color:#8293a9;font-size:24px;cursor:pointer}.attach-button:hover{background:#e7edf3}.composer textarea{flex:1;min-width:0;max-height:130px;resize:none;border:0;outline:0;background:transparent;color:#253149;padding:8px 0;font-size:13px;line-height:1.45}.composer textarea::placeholder{color:#a4afbd}.whisper-button{border:0;border-radius:8px;background:transparent;color:#9a6dc8;padding:8px 10px;font-size:11px;font-weight:700;margin-bottom:1px}.whisper-button:hover,.whisper-button.active{background:#eadcfb}.whisper-button[hidden]{display:none}.send-button{display:grid;place-items:center;border:0;border-radius:9px;width:35px;height:35px;background:#17b99a;color:#fff;font-size:16px}.composer-hint{text-align:right;margin:6px 4px 0;color:#a2adba;font-size:10px}.attachment-preview{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:9px}.attachment-preview[hidden]{display:none}.pending-file{border:1px solid #dce6eb;background:#f3f8f8;border-radius:7px;padding:6px 9px;color:#48636a;font-size:11px}.pending-file button{border:0;background:none;margin-left:6px;color:#8a9ba4;font-size:14px}.detail-panel{overflow:auto;background:#fff;border-left:1px solid #e3e9f0;min-width:0}.detail-head{display:flex;justify-content:space-between;align-items:center;padding:20px 19px;border-bottom:1px solid #e9edf2;font-size:14px}.detail-head .icon-button{width:26px;height:26px}.detail-section{padding:21px 20px;border-bottom:1px solid #edf1f5}.detail-section h3{margin:0 0 14px;font-size:11px;color:#9aa7b5;text-transform:uppercase;letter-spacing:.07em}.member-row{display:flex;align-items:center;gap:9px;margin:12px 0;font-size:12px}.member-row .avatar{width:31px;height:31px}.member-row em{margin-left:auto;font-style:normal;color:#9aa6b6;font-size:10px}.detail-summary{text-align:center;padding:27px 16px 10px}.detail-summary .room-icon{margin:auto;width:54px;height:54px;font-size:23px}.detail-summary h2{font-size:15px;margin:12px 0 3px}.detail-summary p{font-size:12px;color:#94a2b1;margin:0}.detail-section .secondary-button{width:100%}dialog{border:0;border-radius:16px;width:min(420px,calc(100vw - 30px));padding:0;box-shadow:0 22px 70px rgba(20,35,62,.25)}dialog::backdrop{background:rgba(13,24,42,.48)}dialog form{padding:21px}.dialog-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:16px}.dialog-head h2{margin:0;font-size:18px}.dialog-head .icon-button{width:30px;height:30px}.dialog-field{display:grid;gap:7px;margin:13px 0;font-size:12px;font-weight:700;color:#55657a}.dialog-field input,.dialog-field select{width:100%;border:1px solid #dce4ec;border-radius:9px;padding:10px 11px;outline:0;color:#28374c;background:#fff;font-size:13px}.dialog-field input:focus,.dialog-field select:focus{border-color:#22baa0}.dialog-note{font-size:12px;color:#8190a2;line-height:1.6}.dialog-error{min-height:16px;font-size:12px;color:#c64545;margin:6px 0}.dialog-actions{display:flex;justify-content:flex-end;gap:8px}.toast{position:fixed;left:50%;bottom:24px;transform:translate(-50%,20px);background:#1e3246;color:#fff;border-radius:9px;padding:10px 14px;box-shadow:0 8px 28px #1c2d4355;font-size:12px;opacity:0;pointer-events:none;transition:all .2s}.toast.show{opacity:1;transform:translate(-50%,0)}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@media(max-width:950px){.app-shell.detail-open{grid-template-columns:260px minmax(0,1fr)}.detail-panel{position:fixed;right:0;top:0;bottom:0;width:280px;z-index:3;box-shadow:-10px 0 30px #1c2d4322}.app-shell{grid-template-columns:260px minmax(0,1fr)}}@media(max-width:650px){.app-shell,.app-shell.detail-open{grid-template-columns:76px minmax(0,1fr)}.sidebar{padding:22px 10px}.brand{padding:0 8px 26px}.brand-mark{flex:none}.brand div,.sidebar-actions .primary-button,.search-wrap,.section-label,.room-text,.room-count,.profile div,.profile-dot{display:none}.sidebar-actions{justify-content:center;margin:0 0 24px}.sidebar-actions .icon-button{width:42px;height:42px}.room-item{justify-content:center;padding:8px}.profile{justify-content:center;padding:15px 0 0}.conversation-header{padding:14px}.conversation-header .secondary-button{font-size:0;padding:9px}.conversation-header .secondary-button::after{content:"＋";font-size:18px}.message-list{padding:20px 14px}.message{max-width:94%}.composer-area{padding:10px 12px}.composer-hint{display:none}.detail-panel{width:min(280px,calc(100vw - 76px))}}
:not(.detail-open) > .detail-panel{display:none}
.member-row .secondary-button{width:auto;margin-left:auto;padding:6px 8px;font-size:10px;white-space:nowrap}
.leave-button{width:100%;border:1px solid #e6b8b8;border-radius:10px;background:#fff4f4;color:#b13d3d;padding:10px 12px;font-size:12px;font-weight:700}.leave-button:hover{background:#ffe9e9}
.sidebar-actions .direct-create-button{font-size:12px;font-weight:800}.invitation-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:9px}.invitation-heading h3{margin:0}.invitation-status{max-width:100px;border:1px solid #dce4ec;border-radius:8px;background:#fff;color:#33465e;padding:6px;font-size:11px}.invitation-history-item{display:flex;align-items:center;gap:8px;padding:9px 0;border-top:1px solid #edf1f5}.invitation-history-info{display:grid;gap:3px;min-width:0;flex:1}.invitation-history-info strong{font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.invitation-history-info small{font-size:10px;color:#8190a2}.invitation-status-label{font-size:11px;font-weight:700;color:#5d6c80}.invitation-history-item .secondary-button{padding:6px 8px;font-size:10px}
.invitation-results[aria-busy="true"]{opacity:.65}.invitation-results[aria-busy="true"]::before{content:"초대 내역을 불러오는 중…";display:block;padding:7px 0;color:#8190a2;font-size:11px}
.admin-button{margin:0 5px 14px;padding:9px 12px;text-align:left;border:1px solid #365066;border-radius:9px;background:#1a2b40;color:#bfd9df;font-size:12px;font-weight:700}.admin-button:hover{background:#263e56}.admin-button[hidden]{display:none}.dialog-field input[readonly]{background:#f4f7f9;color:#526378}.dialog-link{border:0;background:none;color:#168b78;padding:4px 0;font-size:12px;font-weight:700}.dialog-link:hover{text-decoration:underline}
.invitation-card{display:grid;gap:7px;padding:13px 0;border-bottom:1px solid #e7edf3}.invitation-card strong{font-size:14px}.invitation-card small{color:#728095;font-size:12px}.invitation-actions{display:flex;gap:8px;margin-top:5px}.invitation-actions button{padding:7px 12px;font-size:12px}#received-count{float:right;color:#40d3b5}@media(max-width:650px){#received-invitations{font-size:0;text-align:center;padding:9px 0}#received-invitations::before{content:"✉";font-size:19px}#received-count{float:none;font-size:11px;margin-left:4px}}
@media(max-width:650px){.admin-button{font-size:0;width:42px;height:42px;padding:0;margin:0 auto 14px;text-align:center}.admin-button::after{content:"＋";font-size:21px}}
.detail-section .invitation-history-item .secondary-button{width:auto;flex:0 0 auto;white-space:nowrap}

.image-attachment{display:flex;flex-direction:column;align-items:center;gap:8px;width:min(240px,100%);margin-top:8px;padding:8px;border:1px solid #dce5ea;border-radius:12px;background:#f5f8fa;color:#526378;overflow:hidden;text-align:left}.image-attachment:hover{border-color:#17b99a;background:#edf7f4}.image-attachment img{display:block;width:100%;height:160px;object-fit:contain;border-radius:7px;background:#e9eef2}.image-attachment img[hidden],.image-attachment-status[hidden]{display:none}.image-attachment-status{display:grid;place-items:center;min-height:160px;padding:12px;font-size:12px;text-align:center}.image-attachment-name{width:100%;font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.image-preview{width:min(960px,94vw);max-width:94vw;max-height:92dvh;padding:16px;border:0;border-radius:16px;background:#111b2d;color:#fff;box-shadow:0 20px 80px #0005}.image-preview::backdrop{background:#07101cbd}.image-preview-head{display:flex;align-items:center;gap:14px;margin-bottom:14px}.image-preview-head strong{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:14px}.image-preview-download{flex:none;color:#8ee4d1;font-size:13px;text-decoration:none}.image-preview-close{flex:none;width:36px;height:36px;border:0;border-radius:8px;background:#ffffff16;color:#fff;font-size:26px}.image-preview-close:hover{background:#ffffff30}.image-preview-full{display:block;width:100%;max-height:calc(92dvh - 90px);object-fit:contain;border-radius:8px}@media(max-width:700px){.image-preview{padding:12px}.image-attachment{width:200px}.image-attachment img{height:140px}.image-attachment-status{min-height:140px}}

/* Image albums sit outside text bubbles; each tile opens the original image. */
.message.has-images{width: min(420px,80%)}
.message.has-images .message-main{flex:1;min-width:0}
.image-gallery{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;width:100%;overflow:hidden;border-radius:14px;margin-top:7px}
.image-gallery[data-count="1"]{display:block;max-width:280px}
.mine .image-gallery[data-count="1"]{margin-left:auto}
.image-gallery .image-attachment{position:relative;display:block;width:100%;aspect-ratio:1;margin:0;padding:0;border:0;border-radius:0;background:#e7edf2;overflow:hidden}
.image-gallery .image-attachment:hover{background:#e7edf2}
.image-gallery .image-attachment:focus-visible{outline:3px solid #17b99a;outline-offset:-3px;z-index:1}
.image-gallery .image-attachment img{width:100%;height:100%;object-fit:cover;border-radius:0;transition:transform .18s ease}
.image-gallery .image-attachment:hover img{transform:scale(1.035)}
.image-gallery .image-attachment-status{position:absolute;inset:0;min-height:0;padding:12px}
.image-gallery .image-attachment-name{position:absolute;bottom:0;left:0;padding:18px 9px 8px;color:#fff;background:linear-gradient(transparent,#0009);opacity:0;transition:opacity .18s ease;pointer-events:none}
.image-gallery .image-attachment:hover .image-attachment-name,.image-gallery .image-attachment:focus-visible .image-attachment-name{opacity:1}
.image-gallery[data-count="1"] .image-attachment{aspect-ratio:4/3;border-radius:14px}
.image-gallery[data-count="1"] .image-attachment img{object-fit:contain}
.image-gallery[data-count="3"] .image-attachment:first-child,.image-gallery[data-count="5"] .image-attachment:first-child{grid-column:1/-1;aspect-ratio:16/9}
.message.has-images>.message-main>.whisper-label{margin:2px 0 5px}
.message.has-images.mine>.message-main>.whisper-label{text-align:right}
@media(max-width:700px){.message.has-images{width:min(360px,94%)}.image-gallery{gap:4px}.image-gallery[data-count="1"]{max-width:240px}}
@media(prefers-reduced-motion:reduce){.image-gallery .image-attachment img,.image-gallery .image-attachment-name{transition:none}}

.image-upload-options{display:flex;align-items:center;gap:16px;margin:4px 0 10px;color:#718097;font-size:11px}.image-upload-options[hidden]{display:none}.image-upload-options label{display:flex;align-items:center;gap:5px;white-space:nowrap;color:#526078;font-weight:650}.image-upload-options input{accent-color:#17b99a}.image-upload-options span{line-height:1.5}


.image-preview-nav{display:flex;align-items:center;justify-content:center;gap:24px;margin-top:12px}.image-preview-nav button,.image-preview-retry{border:0;border-radius:8px;background:#ffffff16;color:#fff;cursor:pointer}.image-preview-nav button{width:44px;height:44px;font-size:30px}.image-preview-nav button:hover:not(:disabled),.image-preview-retry:hover{background:#ffffff30}.image-preview-nav button:disabled{opacity:.25;cursor:default}.image-preview-nav span{min-width:52px;text-align:center;font-size:14px;font-variant-numeric:tabular-nums}.image-preview-status{min-height:180px;display:grid;place-items:center;color:#c9d4df;font-size:14px}.image-preview-retry{display:block;padding:12px 20px;margin:0 auto}.image-preview-full{max-height:calc(92dvh - 150px)}.image-preview [hidden]{display:none}

/* Document attachments are independent cards, outside the text bubble. */
.message.has-documents{width:min(420px,80%)}
.message.has-documents .message-main{flex:1;min-width:0}
.document-attachments{display:grid;gap:7px;margin-top:7px;width:min(320px,100%)}
.mine .document-attachments{margin-left:auto}
.document-attachment{display:flex;align-items:center;gap:12px;width:100%;min-width:0;padding:14px;border:1px solid #dde6ec;border-radius:12px;background:#fff;color:#344255;text-align:left;box-shadow:0 2px 5px #25314905}
.document-attachment:hover{border-color:#80cbbb;background:#f8fcfb}
.document-attachment:focus-visible{outline:3px solid #17b99a;outline-offset:2px}
.document-icon{position:relative;display:grid;place-items:center;flex:none;width:40px;height:48px;padding-top:8px;border-radius:5px;background:#edf1f6;color:#61738b;font-size:10px;font-weight:800;letter-spacing:.02em;overflow:hidden}
.document-icon::after{content:"";position:absolute;right:0;top:0;width:0;height:0;border-left:11px solid #0002;border-top:11px solid #fff}
.document-icon-pdf{background:#ffeded;color:#c64242}.document-icon-word{background:#eaf1ff;color:#3569b6}.document-icon-sheet{background:#e6f5eb;color:#288453}.document-icon-slides{background:#fff0e5;color:#bf6c2a}.document-icon-archive{background:#f2eafb;color:#8955b5}
.document-info{display:grid;gap:5px;flex:1;min-width:0}.document-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:13px;font-weight:650}.document-kind{font-size:11px;color:#8a97a7;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.document-download{flex:none;font-size:23px;color:#8a97a7}
.message.has-documents>.message-main>.whisper-label{margin:2px 0 5px}.message.has-documents.mine>.message-main>.whisper-label{text-align:right}
@media(max-width:700px){.message.has-documents{width:min(360px,94%)}.document-attachment{padding:11px;gap:9px}}

.document-preview{width:min(1000px,94vw);max-width:94vw;height:90dvh;max-height:90dvh;padding:0;background:#f5f7fa;color:#253149}
.document-preview[open]{display:flex;flex-direction:column}.document-preview::backdrop{background:#07101cbd}
.document-preview-head{display:flex;align-items:center;gap:16px;padding:14px 18px;background:#fff;border-bottom:1px solid #e1e7ee;flex:none}
.document-preview-head strong{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:14px}
.document-preview-download{flex:none;color:#16846e;font-size:13px;text-decoration:none}.document-preview-close{width:40px;height:40px;border:0;border-radius:8px;background:#eef2f6;color:#526378;font-size:26px}
.document-preview-content{flex:1;min-height:0;overflow:auto;padding:16px;display:flex;flex-direction:column;gap:12px}
.document-preview-note{margin:0;color:#718197;font-size:12px;line-height:1.6;flex:none}.document-preview-pdf{border:0;width:100%;flex:1;min-height:300px;background:#fff}
.document-preview-text{margin:0;padding:20px;background:#fff;border-radius:8px;white-space:pre-wrap;overflow-wrap:anywhere;font:14px/1.8 inherit}
.document-preview-sheets{align-self:flex-start;max-width:100%;padding:8px;border:1px solid #dce4ec;border-radius:7px;background:#fff}
.document-preview-table{overflow:auto;background:#fff;flex:1;min-height:100px}.document-preview-table table{border-collapse:collapse;font-size:12px}.document-preview-table td{border:1px solid #dce4ec;padding:7px 10px;min-width:80px;max-width:360px;white-space:pre-wrap;overflow-wrap:anywhere}
.document-preview-table tr:nth-child(even){background:#f6f9fc}
@media(max-width:700px){.document-preview-head{padding:10px;gap:10px}.document-preview-content{padding:10px}.document-preview-text{padding:12px}}

.upload-policy-hint{margin:7px 4px 0;font-size:11px;color:#7b899a;line-height:1.5}.upload-policy-types{display:flex;flex-wrap:wrap;gap:12px;border:1px solid #dce4ec;border-radius:9px;padding:12px;margin:4px 0 16px}.upload-policy-types legend{padding:0 5px;font-size:12px;font-weight:700;color:#55657a}.upload-policy-types label{display:flex;gap:5px;align-items:center;font-size:13px}.upload-policy-types input{accent-color:#17b99a}

/* Link cards keep their metadata outside the message bubble. */
.message-url{color:inherit;text-decoration:underline;text-underline-offset:3px;overflow-wrap:anywhere}
.link-preview{display:flex;flex-direction:column;width:320px;max-width:100%;margin-top:8px;border:1px solid #dce4ec;border-radius:12px;overflow:hidden;background:#fff;color:#27384d;text-decoration:none;text-align:left;box-shadow:0 2px 5px #24364b08}
.link-preview:hover{border-color:#17a68e}.link-preview:focus-visible{outline:3px solid #17a68e;outline-offset:3px}
.link-preview-copy{display:flex;flex-direction:column;gap:7px;padding:13px 15px;min-width:0}
.link-preview-site{font-size:11px;color:#66778b;overflow-wrap:anywhere}
.link-preview strong{font-size:14px;line-height:1.5;overflow-wrap:anywhere;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.link-preview-description{font-size:12px;line-height:1.6;color:#637388;overflow-wrap:anywhere;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.link-preview-image{display:block;width:100%;height:168px;object-fit:cover;background:#edf2f6}.link-preview.loading strong{font-size:12px;font-weight:400;color:#8391a2}
@media(max-width:650px){.link-preview{width:260px}.link-preview-image{height:140px}}

.outgoing-message .message-meta{opacity:.75}.outgoing-message .bubble{opacity:.8;white-space:pre-wrap;overflow-wrap:anywhere}
.outgoing-progress{width:310px;max-width:100%;padding:13px 15px;margin-top:8px;border:1px solid #cde5dc;border-radius:12px;background:#f4faf7;color:#267767;font-size:12px}
.outgoing-file{display:grid;gap:5px;padding:8px 0;border-bottom:1px solid #deebe5}.outgoing-file:first-child{padding-top:0}.outgoing-file-name{font-weight:600;overflow-wrap:anywhere}.outgoing-file-state{font-size:11px;color:#60786f}
.outgoing-status{margin:10px 0 4px;line-height:1.6;overflow-wrap:anywhere}.outgoing-progress[data-phase="error"]{border-color:#edc9c2;background:#fff6f3;color:#a84235}
.outgoing-actions{display:flex;gap:12px;align-items:center;margin-top:12px}.outgoing-dismiss{border:0;background:none;color:#7d7774;font-size:12px;text-decoration:underline;cursor:pointer}.outgoing-actions button:disabled{opacity:.5;cursor:not-allowed}
.outgoing-progress progress{display:block;width:100%;height:6px;margin-top:3px;border:0;border-radius:4px;overflow:hidden;accent-color:#17b99a}.outgoing-progress progress[hidden]{display:none}.outgoing-progress progress::-webkit-progress-bar{background:#d5e9e2}.outgoing-progress progress::-webkit-progress-value{background:#17b99a}.outgoing-progress progress::-moz-progress-bar{background:#17b99a}
@media(max-width:650px){.outgoing-progress{width:250px}}

.link-confirm-host{display:block;color:#253149;font-size:15px;overflow-wrap:anywhere;unicode-bidi:isolate}.link-confirm-address{max-height:180px;overflow:auto;overflow-wrap:anywhere;white-space:pre-wrap;background:#f3f6fa;border:1px solid #e1e7ee;border-radius:9px;padding:12px;font-size:12px;line-height:1.6;color:#526078;unicode-bidi:isolate}

.message-text-clamped{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:8;overflow:hidden;white-space:pre-wrap;overflow-wrap:anywhere}
.message-text-more{display:block;border:0;border-top:1px solid #d6e2e8;background:transparent;color:#177b69;font-size:12px;font-weight:700;padding:8px 0 0;margin-top:8px;cursor:pointer}
.message-text-more[hidden]{display:none}
.message-full-preview{width:min(680px,calc(100vw - 30px));max-height:85dvh;padding:22px;box-sizing:border-box}
.message-full-preview[open]{display:flex;flex-direction:column;gap:12px}
.message-full-head,.message-full-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-shrink:0}
.message-full-head h2{font-size:18px;margin:0}
.message-full-label{font-size:12px;color:#8190a2;margin:0}
.message-full-content{overflow:auto;min-height:0;white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.7;font-size:14px;padding:4px 2px;color:#253149}
.message-full-footer{border-top:1px solid #e3e9f0;padding-top:12px}
.message-full-footer span{font-size:12px;color:#527367}

.history-status{align-self:center;flex-shrink:0;color:#8b99a9;font-size:12px;line-height:1.5;text-align:center;padding:4px 8px;min-height:18px}

.voice-composer{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-bottom:8px;font-size:12px;color:#66758c}
.voice-composer button,.audio-attachment button{border:1px solid #dce6eb;border-radius:8px;background:#f3f8f8;color:#177b69;padding:7px 10px;font-size:12px}
.voice-composer [hidden],.audio-attachment [hidden]{display:none}.voice-composer audio{width:min(100%,300px);height:36px}
.voice-composer span{overflow-wrap:anywhere;max-width:100%}.audio-attachment{display:grid;gap:8px;padding:10px;border:1px solid #dce6eb;border-radius:12px;background:#fff;font-size:12px;max-width:100%;overflow-wrap:anywhere}
.audio-attachment audio{width:260px;max-width:100%;height:40px}
.voice-button-hint{display:inline-flex}
.room-id-label{display:grid;gap:7px;margin-bottom:10px;font-size:12px;color:#65758a}
.room-id-value{width:100%;box-sizing:border-box;border:1px solid #dce4ec;border-radius:7px;padding:8px;font:inherit;color:#28374c;background:#f6f8fa}
.voice-button-hint button:disabled{pointer-events:none}

.notes-panel[hidden]{display:none}
.app-shell.notes-open{grid-template-columns:260px minmax(300px,1fr) minmax(320px,420px)}
.notes-panel{min-width:0;border-left:1px solid #e3e9f0;background:#fff;display:flex;flex-direction:column;gap:12px;padding:18px;overflow:auto}
.notes-head,.notes-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.notes-head{justify-content:space-between}
.notes-description,.notes-status{font-size:12px;line-height:1.6;color:#65758a;margin:0}.notes-status{min-height:20px}
.notes-list{display:flex;flex-direction:column;max-height:200px;overflow:auto;gap:4px;flex-shrink:0}
.notes-item{border:0;background:#f6f8fa;padding:10px;text-align:left;border-radius:6px;overflow-wrap:anywhere;color:#35465a}
.notes-item[aria-pressed="true"]{background:#e3f5ef;color:#12755f}
.notes-editor{display:flex;flex-direction:column;gap:12px;min-height:320px;flex:1}.notes-editor[hidden]{display:none}
.notes-editor label{display:flex;flex-direction:column;gap:6px;font-size:12px;color:#526176}
.notes-editor label:nth-child(2){flex:1}.notes-editor input,.notes-editor textarea{border:1px solid #dbe3eb;border-radius:8px;padding:10px;font:inherit;color:#24364a;width:100%;box-sizing:border-box}
.notes-editor textarea{flex:1;min-height:220px;resize:vertical;line-height:1.7}
.notes-panel button:disabled{opacity:.55;cursor:default}
@media(max-width:1100px){.app-shell.notes-open{grid-template-columns:260px minmax(0,1fr)}.notes-panel{position:fixed;right:0;top:0;bottom:0;width:min(420px,calc(100vw - 76px));z-index:4;box-sizing:border-box;box-shadow:-10px 0 30px #1c2d4322}}
@media(max-width:650px){.app-shell.notes-open{grid-template-columns:76px minmax(0,1fr)}.conversation-header #room-notes{font-size:12px}.conversation-header #room-notes::after{content:none}}

.agent-chat{display:flex;flex-direction:column;flex:1;min-height:0;min-width:0}
.agent-chat[hidden],.message-list[hidden],.composer-area[hidden]{display:none}
.agent-help{font-size:12px;line-height:1.6;color:#65758a;margin:12px 24px}
.agent-history{flex:1;min-height:0;overflow:auto;display:block}
.agent-run{margin:0 0 24px;display:grid;gap:16px}
.agent-question,.agent-answer{padding:14px 18px;border-radius:14px;max-width:92%;overflow-wrap:anywhere}
.agent-question{justify-self:end;background:#def5ed}.agent-answer{justify-self:start;background:#fff;border:1px solid #e2e8f0}
.agent-run strong{font-size:12px;color:#527565}.agent-run p{white-space:pre-wrap;line-height:1.7;font-size:14px;margin:8px 0 0}
.agent-status{font-size:12px;color:#9c4a36;margin:0 24px;min-height:18px;white-space:pre-wrap}
.agent-composer{padding:12px 24px 18px;background:white;border-top:1px solid #e3e9f0}
.agent-composer textarea{width:100%;resize:vertical;min-height:64px;max-height:180px;border:1px solid #dbe3eb;border-radius:10px;padding:12px;font:inherit}
.agent-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:8px;flex-wrap:wrap}.agent-actions [hidden]{display:none}
.agent-history-end{text-align:center;color:#8995a5;font-size:11px;margin:0 0 18px}
@media(max-width:650px){.agent-composer{padding:10px}.agent-help{margin:10px}.sidebar-actions .primary-button{display:block;flex:none;font-size:0;width:24px;padding:5px}.sidebar-actions .primary-button:after{content:'＋';font-size:18px}}
