/* Compact conversation rail; native modal drawer and top-layer row menus. */
.rooms-root { --rooms-red:#ef4148; --rooms-ink:#242424; color:var(--rooms-ink); font:14px/1.45 "PingFang SC","Microsoft YaHei",-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
.rooms-root *, .rooms-root *::before, .rooms-root *::after { box-sizing:border-box; }
.rooms-root button, .rooms-root input { font:inherit; }
.rooms-root button { min-height:44px; min-width:44px; border:0; background:transparent; color:var(--rooms-ink); border-radius:9px; padding:8px 12px; cursor:pointer; }
.rooms-root button:focus-visible, .rooms-root input:focus-visible { outline:2px solid #c62d35; outline-offset:2px; }
.rooms-root button:hover { background:#eaeaea; }
.rooms-root [hidden] { display:none!important; }
.rooms-toggle { position:fixed; inset-block-start:calc(6px + env(safe-area-inset-top)); inset-inline-start:8px; z-index:25; width:44px; height:44px; overflow:hidden; font-size:0!important; }
.rooms-toggle::before { content:""; display:block; margin:auto; width:21px; height:18px; border:1.6px solid currentColor; border-radius:4px; background:linear-gradient(to right,transparent 6px,currentColor 6px,currentColor 7.5px,transparent 7.5px); }
body.rooms-rail-open .rooms-toggle { visibility:hidden; }
.rooms-drawer { position:fixed; inset-block:var(--chat-top,0) auto; inset-inline:0 auto; margin:0; width:252px; height:var(--chat-viewport,100dvh); max-height:none; max-width:none; padding:6px 10px max(10px,env(safe-area-inset-bottom)); border:0; border-inline-end:1px solid #ececec; background:#f7f7f7; color:#242424; overflow:hidden; overscroll-behavior:contain; z-index:26; }
.rooms-drawer[open] { display:flex; flex-direction:column; }
.rooms-drawer::backdrop { background:#0005; }
.rooms-heading { display:flex; align-items:center; justify-content:space-between; gap:8px; flex:none; height:44px; }
.rooms-heading strong { font-size:18px; color:#252525; padding-inline-start:10px; }
.rooms-root .rooms-close { width:44px; font-size:0; padding:8px; }
.rooms-close::before { content:""; display:block; width:20px; height:17px; margin:auto; border:1.6px solid currentColor; border-radius:4px; background:linear-gradient(to right,transparent 6px,currentColor 6px,currentColor 7.5px,transparent 7.5px); }
.rooms-drawer h2 { margin:16px 10px 6px; font-size:12px; color:#737373; font-weight:500; order:2; flex:none; }
.rooms-root .rooms-new { width:100%; margin-block:8px 0; text-align:start; background:#ededed; font-weight:500; order:1; flex:none; }
.rooms-new::before { content:"＋"; font-size:20px; margin-inline-end:9px; line-height:1; }
.rooms-archived { display:flex; align-items:center; min-height:44px; gap:8px; margin:2px 8px; font-size:12px; color:#686868; order:5; flex:none; }
.rooms-archived input { width:20px; height:20px; accent-color:#616161; }
.rooms-list { display:flex; flex-direction:column; gap:2px; overflow:auto; overscroll-behavior:contain; min-height:44px; flex:1; order:3; scrollbar-width:thin; }
.rooms-row { display:grid; grid-template-columns:minmax(0,1fr) 44px; align-items:center; min-height:44px; flex:none; border-radius:9px; }
.rooms-row:has([aria-current]), .rooms-row:hover { background:#eaeaea; }
.rooms-root .rooms-room { min-width:0; width:100%; text-align:start; white-space:nowrap; text-overflow:ellipsis; overflow:hidden; }
.rooms-root .rooms-room[aria-current] { background:transparent; color:#242424; font-weight:500; }
.rooms-root .rooms-more { width:44px; height:44px; padding:0; font-size:22px; line-height:1; }
.rooms-row-menu { position:fixed; margin:0; inset:auto; padding:6px; width:208px; max-width:calc(100vw - 24px); max-height:calc(100dvh - 24px); overflow:auto; border:1px solid #dedede; border-radius:12px; color:#242424; background:#fff; box-shadow:0 10px 32px #0002; }
.rooms-row-menu:popover-open { display:grid; }
.rooms-root .rooms-row-action { width:100%; text-align:start; font-size:14px; white-space:normal; }
.rooms-rename-form { position:absolute; inset:110px 10px auto; z-index:1; box-shadow:0 8px 24px #0001; order:2; flex:none; padding:10px; margin-block:8px; border:1px solid #dedede; border-radius:12px; background:#fff; }
.rooms-rename-form label { display:grid; gap:6px; }
.rooms-rename-form input { width:100%; min-height:44px; border:1px solid #ccc; border-radius:8px; padding:8px; margin-bottom:6px; font-size:16px; }
.rooms-rename-form button { margin:2px; background:#f1f1f1; }
.rooms-tasks { order:4; display:grid; gap:2px; max-height:160px; overflow:auto; flex:none; border-top:1px solid #e5e5e5; margin-top:8px; padding-top:8px; }
.rooms-tasks:empty { display:none; }
.rooms-tasks h3 { font-size:12px; font-weight:500; color:#747474; margin:4px 8px; }
.rooms-tasks button { white-space:nowrap; overflow:hidden; text-overflow:ellipsis; text-align:start; }
.rooms-root .rooms-audio { order:6; flex:none; width:100%; font-size:12px; text-align:start; border-top:1px solid #e5e5e5; border-radius:0; }
.rooms-notice { order:7; flex:none; max-height:72px; overflow:auto; font-size:13px; line-height:1.4; color:#a32930; margin:4px 8px; }
.rooms-notice:empty { display:none; }
body.rooms-enabled .rooms-main { box-sizing:border-box; padding-block-start:0; }
body.rooms-rail-open .rooms-main { margin-inline-start:252px; width:calc(100% - 252px); }
.rooms-message { white-space:pre-wrap; overflow-wrap:anywhere; padding:12px 0; margin:8px; background:#fff; color:#242424; }
.rooms-message-user { background:#f3f3f3; margin-inline-start:30px; border-radius:16px; padding:12px; }
@media(max-width:767px) {
 .rooms-drawer { width:min(86vw,300px); padding-block-start:calc(6px + env(safe-area-inset-top)); box-shadow:12px 0 40px #0001; }
 body.rooms-enabled .rooms-main { width:auto; margin-inline-start:0; }
}
@media(prefers-reduced-motion:reduce) { .rooms-root *, .rooms-message { scroll-behavior:auto!important; transition:none!important; animation:none!important; } }

.rooms-mini{position:fixed;inset-inline-start:0;inset-block-start:var(--chat-top,0);height:var(--chat-viewport,100dvh);width:56px;display:flex;flex-direction:column;align-items:center;gap:6px;padding:8px 4px max(12px,env(safe-area-inset-bottom));background:#f8f4f1;border-inline-end:1px solid #eadfd8;z-index:26;box-sizing:border-box}
.rooms-mini-button{width:44px;height:44px;padding:10px!important;display:flex;align-items:center;justify-content:center;flex:none}.rooms-mini-button svg{width:22px;height:22px}.rooms-mini-button img{width:28px;height:28px;object-fit:cover;border-radius:9px}.rooms-mini-profile{margin-block-start:auto}.rooms-mini-profile img{border-radius:50%}.rooms-toggle{display:none!important}
body.rooms-enabled:not(.rooms-rail-open) .page-shell{margin-inline-start:56px!important;width:calc(100% - 56px)!important;max-width:none}
body.rooms-enabled:not(.rooms-menu-open) .topbar .brand{display:none!important}
@media(max-width:767px){.rooms-mini{width:48px;padding-inline:2px}.rooms-mini-button{width:42px;min-width:42px!important}.rooms-mini-button img{width:26px;height:26px}body.rooms-enabled:not(.rooms-rail-open) .page-shell{margin-inline-start:48px!important;width:calc(100% - 48px)!important}.rooms-enabled .topbar{padding-inline-start:8px!important}}
/* Conversation task state; no extra column or shift of the actions menu. */
#taskCountButton { display:none !important; }
.rooms-room[data-task-status="running"]::before,
.rooms-room[data-task-status="unread"]::before,
.conversation-title[data-task-status="running"]::before {
  content:"";display:inline-block;width:7px;height:7px;min-width:7px;
  border-radius:50%;margin-inline-end:7px;vertical-align:middle;
  background:#e34e65;animation:conversation-task-pulse 1.3s ease-in-out infinite;
}
.rooms-room[data-task-status="unread"]::before {background:#29a66b;animation:none;}
@keyframes conversation-task-pulse {0%,100%{opacity:1}50%{opacity:.25}}
@media(prefers-reduced-motion:reduce){.rooms-room[data-task-status]::before,.conversation-title[data-task-status]::before{animation:none;}}
