:root{color-scheme:light;--bg: #eef1f5;--sidebar: #f7f8fa;--panel: #ffffff;--chat-bg: #f3f5f8;--line: #dde2e9;--line-soft: #e7ebf0;--line-strong: #cbd3df;--muted: #8b95a5;--text: #1f2937;--text-secondary: #5f6b7a;--text-bright: #111827;--accent: #3b6cf4;--accent-hover: #2f5de0;--accent-soft: #e8efff;--selection: #eef2f8;--selection-border: #d8e0ec;--danger: #dc2626;--danger-soft: #fef2f2;--warning: #d97706;--warning-soft: #fffbeb;--ok: #16a34a;--ok-soft: #ecfdf3;--input-bg: #e9edf2;--search-bg: #e8ecf2;--badge-green: #d1fae5;--badge-green-text: #047857;--topbar-h: 48px;--sidebar-min: 240px;--sidebar-max: 560px;--sidebar-default: 320px;--font: 14px/1.45 "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif}*{box-sizing:border-box}html,body,#root{height:100%;overflow:hidden}body{margin:0;background:var(--bg);color:var(--text);font:var(--font)}button,input,textarea{font:inherit}button{border:none;border-radius:8px;background:transparent;color:var(--text-secondary);cursor:pointer;min-height:28px;padding:4px 10px;white-space:nowrap;transition:background .15s,color .15s}button:hover{background:var(--input-bg);color:var(--text)}button.primary{background:var(--accent);color:#fff}button.primary:hover{background:var(--accent-hover);color:#fff}button.danger{color:var(--danger)}button.icon-btn{display:inline-flex;align-items:center;justify-content:center;min-width:28px;min-height:28px;padding:4px;border-radius:8px;color:var(--muted)}button.icon-btn:hover{background:var(--input-bg);color:var(--text)}button:disabled{cursor:default;opacity:.45}.app{display:grid;grid-template-rows:var(--topbar-h) 1fr;height:100%;overflow:hidden}.topbar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:0 20px;border-bottom:1px solid #d9dfe7;background:var(--panel)}.brand{display:flex;align-items:center;gap:8px;min-width:0}.brand h1{margin:0;font-size:15px;font-weight:600;color:var(--text-bright);letter-spacing:-.01em}.status{overflow:hidden;max-width:50vw;color:var(--muted);font-size:12px;text-align:right;text-overflow:ellipsis;white-space:nowrap}.status.error{color:var(--danger)}.status.ok{color:var(--ok)}.workspace{display:flex;min-height:0;overflow:hidden}.editor-group{display:flex;flex:1;flex-direction:column;min-width:0;min-height:0;overflow:hidden}.editor-tabs-bar{display:flex;flex:0 0 auto;align-items:stretch;gap:0;min-height:35px;overflow-x:auto;overflow-y:hidden;border-bottom:1px solid var(--line);background:#e4e8ee;scrollbar-width:thin}.editor-tab{display:inline-flex;flex:0 0 auto;align-items:center;gap:6px;max-width:200px;min-width:0;padding:0 8px 0 10px;border-right:1px solid var(--line);background:#e1e5eb;color:var(--text-secondary);cursor:pointer;transition:background .12s,color .12s}.editor-tab:hover{background:#d9dfe7;color:var(--text)}.editor-tab.active{background:var(--panel);color:var(--text-bright);box-shadow:inset 0 2px 0 var(--accent)}.editor-tab-icon{flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;color:var(--muted)}.editor-tab.active .editor-tab-icon{color:var(--accent)}.editor-tab-label{flex:1;overflow:hidden;font-size:12px;font-weight:500;text-overflow:ellipsis;white-space:nowrap}.editor-tab-close{flex:0 0 auto;min-width:20px;min-height:20px;padding:0;border-radius:4px;color:var(--muted);font-size:14px;line-height:1}.editor-tab-close:hover{background:#0f172a14;color:var(--text)}.editor-content{display:flex;flex:1;min-width:0;min-height:0;overflow:hidden}.editor-content>.chat-panel,.editor-content>.explorer-panel{flex:1;min-width:0;border-left:0}.sidebar-group{display:flex;flex:0 0 auto;min-height:0;height:100%}.activity-bar{flex:0 0 40px;display:flex;flex-direction:column;align-items:center;gap:4px;padding-top:8px;border-right:1px solid var(--line);background:#e4e8ee}.activity-btn{position:relative;display:inline-flex;align-items:center;justify-content:center;width:32px;min-width:32px;min-height:32px;padding:0;border-radius:8px;color:#6b7280}.activity-btn:hover{color:var(--text)}.activity-btn.active{color:var(--text-bright)}.activity-btn.active:before{content:"";position:absolute;left:-8px;top:6px;bottom:6px;width:2px;border-radius:0 2px 2px 0;background:var(--accent)}.sidebar{display:flex;flex:0 0 auto;flex-direction:column;width:var(--sidebar-default);min-width:var(--sidebar-min);max-width:var(--sidebar-max);min-height:0;height:100%;overflow:hidden;background:var(--sidebar);border-right:1px solid var(--line)}.sidebar-inner{display:grid;grid-template-rows:auto auto auto auto 1fr;min-height:0;height:100%}.sidebar-inner--chats{grid-template-rows:auto auto 1fr}.sidebar-inner--projects{grid-template-rows:auto auto auto auto 1fr}.sidebar-inner--sources{grid-template-rows:auto auto auto auto 1fr auto}.resize-handle{flex:0 0 5px;position:relative;cursor:col-resize;background:transparent;transition:background .15s}.resize-handle:after{content:"";position:absolute;top:0;bottom:0;left:2px;width:1px;background:var(--line)}.resize-handle:hover,.resize-handle.dragging{background:var(--accent-soft)}.resize-handle:hover:after,.resize-handle.dragging:after{background:var(--accent);width:2px;left:1px}.chat-panel{flex:1;min-width:0;min-height:0;display:grid;grid-template-rows:auto 1fr auto;overflow:hidden;background:var(--chat-bg);border-left:0}.sources-panel{display:flex;flex:0 0 auto;flex-direction:column;width:300px;min-width:var(--sidebar-min);max-width:520px;min-height:0;height:100%;overflow:hidden;background:var(--sidebar)}.context-resize-handle{position:relative;flex:0 0 9px;cursor:col-resize;background:#edf0f4;transition:background .15s}.context-resize-handle:before,.context-resize-handle:after{content:"";position:absolute;top:0;bottom:0;width:1px;background:#cfd6e0;transition:background .15s,width .15s}.context-resize-handle:before{left:3px}.context-resize-handle:after{right:3px}.context-resize-handle:hover,.context-resize-handle.dragging{background:var(--accent-soft)}.context-resize-handle:hover:before,.context-resize-handle:hover:after,.context-resize-handle.dragging:before,.context-resize-handle.dragging:after{width:2px;background:var(--accent)}.sources-panel-inner{display:grid;grid-template-rows:auto auto 1fr;min-height:0;height:100%}.sources-header{padding-top:14px}.sources-toolbar{padding-bottom:6px}.sources-scroll{min-height:0;overflow:auto;padding:0 8px 16px}.sources-drop-zone{display:flex;flex-direction:column;gap:3px;margin:0 4px 8px;padding:12px;border:1px dashed var(--line-strong);border-radius:8px;background:#fff;color:var(--text-secondary);transition:border-color .15s,background .15s,color .15s}.sources-drop-zone.active{border-color:var(--accent);background:var(--accent-soft);color:#2f4f9e}.sources-drop-zone.disabled{background:var(--input-bg);color:var(--muted)}.sources-drop-title{overflow:hidden;font-size:12px;font-weight:600;text-overflow:ellipsis;white-space:nowrap}.sources-drop-meta{overflow:hidden;font-size:10px;text-overflow:ellipsis;white-space:nowrap}.source-file-list{display:flex;flex-direction:column;gap:2px}.source-file-item{display:flex;align-items:center;gap:4px;margin:1px 4px;padding:6px 8px;border:1px solid transparent;border-radius:8px;background:transparent}.source-file-item--expanded{border-color:var(--line-soft);background:#f8f9fb;border-bottom-left-radius:0;border-bottom-right-radius:0}.context-source-group{margin-bottom:4px}.context-source-toggle{flex:0 0 16px}.context-source-tree{margin:0 4px 2px;padding:4px 0 6px;border:1px solid var(--line-soft);border-top:0;border-radius:0 0 8px 8px;background:#fff}.context-tree-row{display:flex;align-items:center;gap:4px;min-height:22px;padding:1px 8px 1px 4px}.context-tree-row:hover{background:#f6f7f9}.context-tree-row .tree-label{flex:1;overflow:hidden;color:var(--text);font-size:11px;text-overflow:ellipsis;white-space:nowrap}.context-tree-preview{display:inline-flex;flex:0 0 auto;align-items:center;justify-content:center;width:20px;min-width:20px;min-height:20px;padding:2px;border-radius:5px;color:var(--muted)}.context-tree-preview:hover{background:var(--accent-soft);color:var(--accent)}.context-tree-preview svg{width:14px;height:14px}.context-tree-loading{flex:0 0 auto;color:var(--muted);font-size:10px}.context-tree-empty{padding:4px 8px 4px 28px;color:var(--muted);font-size:10px}.source-file-item:hover{background:#f6f7f9;border-color:var(--line-soft)}.source-file-item-main{display:flex;flex:1;align-items:flex-start;gap:8px;min-width:0}.source-file-item-icon{flex:0 0 16px;display:inline-flex;align-items:center;justify-content:center;margin-top:1px;color:var(--muted)}.source-file-item-body{flex:1;min-width:0}.source-file-item-name{overflow:hidden;color:var(--text);font-size:12px;font-weight:500;text-overflow:ellipsis;white-space:nowrap}.source-file-item-meta{margin-top:2px;color:var(--muted);font-size:10px}.source-file-item-actions{display:flex;flex:0 0 auto;align-items:center;gap:4px}.source-file-item-toggle{flex:0 0 auto;min-height:22px;padding:0 6px;border-radius:6px;color:var(--accent);font-size:10px;font-weight:500;white-space:nowrap}.source-file-item-toggle:hover{background:var(--accent-soft);color:#2f4f9e}.source-file-item-preview{display:inline-flex;flex:0 0 auto;align-items:center;justify-content:center;width:22px;min-width:22px;min-height:22px;padding:3px;border-radius:6px;color:var(--muted)}.source-file-item-preview:hover{background:var(--accent-soft);color:var(--accent)}.source-file-item-preview svg{width:15px;height:15px}.project-sidebar-row[draggable=true]{cursor:grab}.project-sidebar-row[draggable=true]:active{cursor:grabbing}.explorer-row[draggable=true]{cursor:grab}.explorer-row[draggable=true]:active{cursor:grabbing}.search-bar{position:relative;padding:14px 16px 10px}.search-bar input{width:100%;min-height:34px;padding:0 40px 0 38px;border:1px solid transparent;border-radius:999px;background:var(--search-bg);color:var(--text);font-size:12px;transition:border-color .15s,background .15s,box-shadow .15s}.search-bar input::placeholder{color:var(--muted)}.search-bar input:focus{border-color:var(--line-strong);background:#fff;box-shadow:0 1px 3px #0f172a0f;outline:none}.search-icon{position:absolute;top:50%;left:28px;width:16px;height:16px;color:var(--muted);pointer-events:none;transform:translateY(-50%)}.search-clear{position:absolute;top:50%;right:24px;min-height:24px;padding:2px 8px;font-size:11px;transform:translateY(-50%)}.corpus-header{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:2px 16px 8px;color:var(--muted);font-size:10px;font-weight:600;letter-spacing:.08em;text-transform:uppercase}.corpus-legend{color:#b0b8c4;font-size:9px;font-weight:500;letter-spacing:.04em}.toolbar-row{display:flex;align-items:center;justify-content:flex-end;gap:4px;padding:0 12px 8px}.toolbar-text-btn{margin-right:auto;min-height:28px;padding:4px 10px;border:1px solid #d7dce5;border-radius:8px;background:#fff;color:var(--text-secondary);font-size:12px;white-space:nowrap;transition:background .15s,border-color .15s,color .15s}.toolbar-text-btn:hover{border-color:var(--accent);background:var(--accent-soft);color:#2f4f9e}.move-banner{display:none;flex-direction:column;gap:8px;margin:0 12px 10px;padding:10px 12px;border:1px solid #bfd0f5;border-radius:10px;background:var(--accent-soft);color:#2f4f9e;font-size:11px}.move-banner .actions{display:flex;gap:6px}.move-banner.active{display:flex}.tree-wrap{min-height:0;overflow:auto;padding:0 8px 16px}.pending-sources-panel{flex:0 0 auto;margin:0 8px 10px;padding:10px 10px 8px;border:1px solid var(--line-strong);border-radius:10px;background:#fff}.pending-sources-title{margin-bottom:6px;color:var(--text-secondary);font-size:10px;font-weight:600;letter-spacing:.06em;text-transform:uppercase}.pending-sources-list{display:flex;flex-direction:column;gap:4px;margin:0;padding:0;list-style:none}.pending-source-item{display:flex;flex-direction:column;align-items:flex-start;gap:2px;width:100%;padding:8px 9px;border:1px solid var(--line-strong);border-radius:8px;background:#fff;text-align:left;transition:background .15s,border-color .15s}.pending-source-item--credentials{border-color:#f3b4b4;background:var(--danger-soft);color:var(--danger)}.pending-source-item--credentials:hover{border-color:var(--danger);background:#fff5f5}.pending-source-item--nodes{border-color:#fcd34d;background:var(--warning-soft);color:#92400e}.pending-source-item--nodes:hover{border-color:var(--warning);background:#fffbeb}.pending-source-name{overflow:hidden;max-width:100%;font-size:12px;font-weight:600;text-overflow:ellipsis;white-space:nowrap}.pending-source-hint{font-size:10px;line-height:1.35}.pending-source-item--credentials .pending-source-hint{color:#b45353}.pending-source-item--nodes .pending-source-hint{color:#b45309}.pending-source-meta{font-size:10px;opacity:.85}.tree{display:flex;flex-direction:column;gap:2px}.tree-label,.tree-icon,.tree-count,.tree-meta{cursor:pointer}.tree-folder-item{margin:0 4px;padding:6px 8px;border:1px solid transparent;border-radius:10px;-webkit-user-select:none;user-select:none;transition:background .12s,border-color .12s}.tree-folder-item:hover{background:#f6f7f9}.tree-folder-item.selected{background:var(--selection);border-color:var(--selection-border)}.tree-folder-item--sourced{border-color:#bfd0f5;background:linear-gradient(90deg,var(--accent-soft) 0%,#fff 100%);box-shadow:inset 3px 0 0 var(--accent)}.tree-folder-item--sourced:hover{background:linear-gradient(90deg,#dce6ff,#f6f7f9)}.tree-folder-item--sourced.selected{background:linear-gradient(90deg,#dce6ff 0%,var(--selection) 100%);border-color:#93b4f7}.tree-icon--sourced{color:var(--accent)}.tree-label-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tree-source-badge{flex:0 0 auto;padding:1px 6px;border-radius:999px;background:var(--accent-soft);color:#2f4f9e;font-size:9px;font-weight:600;letter-spacing:.04em;text-transform:uppercase;white-space:nowrap}.tree-source-operation{display:inline-flex;flex:0 0 auto;align-items:center;gap:4px;padding:1px 6px;border-radius:999px;background:#dbeafe;color:#1d4ed8;font-size:9px;font-weight:600;letter-spacing:.02em;white-space:nowrap}.tree-source-operation svg{width:10px;height:10px}.tree-folder-item--operating{border-color:#2563eb47;background:linear-gradient(90deg,#eff6ff,#f8fafc)}.tree-folder-item--operating.selected{background:linear-gradient(90deg,#dbeafe 0%,var(--selection) 100%);border-color:#60a5fa}.explorer-row--operating{background:#f8fbff;border-color:#2563eb2e}.explorer-row--operating.selected{background:#eff6ff;border-color:#93c5fd}.tree-source-info{display:flex;flex-direction:column;gap:1px;margin-top:4px;padding-left:36px;cursor:pointer}.tree-source-line{display:flex;align-items:center;gap:6px;min-width:0}.tree-source-type{flex:0 0 auto;color:#2f4f9e;font-size:10px;font-weight:600}.tree-source-name{overflow:hidden;color:var(--text-secondary);font-size:10px;text-overflow:ellipsis;white-space:nowrap}.tree-source-url,.tree-source-desc{overflow:hidden;padding-left:0;color:var(--muted);font-size:10px;text-overflow:ellipsis;white-space:nowrap}.tree-folder-item[draggable=true],.file-card[draggable=true]{cursor:grab}.tree-folder-item[draggable=true]:active,.file-card[draggable=true]:active{cursor:grabbing}.tree-folder-main{display:flex;align-items:center;gap:4px;min-height:20px}.tree-meta{margin-top:2px;padding-left:36px;color:var(--muted);font-size:10px;letter-spacing:.02em}.tree-count{flex:0 0 auto;min-width:20px;padding:0 6px;color:var(--muted);font-size:11px;text-align:right}.tree-toggle{flex:0 0 16px;display:inline-flex;align-items:center;justify-content:center;width:16px;min-height:16px;padding:0;color:#a0a8b4}.tree-toggle.hidden{visibility:hidden}.tree-toggle svg{width:12px;height:12px;transition:transform .12s ease}.tree-toggle.expanded svg{transform:rotate(90deg)}.tree-icon{flex:0 0 16px;display:inline-flex;align-items:center;justify-content:center;width:16px;height:16px;color:#9aa3af}.tree-icon svg{width:15px;height:15px}.tree-icon.status-processing{color:#2563eb}.tree-icon.status-ready{color:#16a34a}.tree-icon.status-error{color:#dc2626}.file-card-name,.explorer-name-text{display:inline-flex;align-items:center;gap:4px;min-width:0}.file-card-name-text,.explorer-name-text>span:first-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.content-status{flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;width:14px;height:14px}.content-status svg{width:12px;height:12px}.content-status.status-processing{color:#2563eb}.content-status.status-ready{color:#16a34a}.content-status.status-error{color:#dc2626}.content-status-spinner{animation:content-status-spin .8s linear infinite}@keyframes content-status-spin{to{transform:rotate(360deg)}}.file-card.status-processing{border-color:#2563eb2e}.file-card.status-error{border-color:#dc262633}.explorer-row.status-processing .explorer-name-main>span:first-child{color:#1d4ed8}.explorer-row.status-error .explorer-name-main>span:first-child{color:#b91c1c}.tree-label{display:flex;align-items:center;gap:6px;overflow:hidden;flex:1;min-width:0;color:var(--text);font-size:12px;font-weight:500}.file-card{margin:1px 4px;padding:5px 8px;border:1px solid transparent;border-radius:8px;background:transparent;cursor:pointer;transition:background .12s,border-color .12s,box-shadow .12s}.file-card:hover{background:#f8f9fb}.file-card.selected{border-color:#c9d8f8;background:#f3f7ff;box-shadow:0 1px 2px #3b6cf414}.file-card-row{display:flex;align-items:flex-start;gap:6px;min-width:0}.file-card-body{flex:1;min-width:0}.file-card-name{display:block;overflow:hidden;color:var(--text);font-size:12px;font-weight:500;text-overflow:ellipsis;white-space:nowrap}.file-card.status-processing .file-card-name-text{color:#1d4ed8}.file-card.status-error .file-card-name-text{color:#b91c1c}.file-card-meta{display:block;margin-top:3px;overflow:hidden;color:var(--muted);font-size:10px;text-overflow:ellipsis;white-space:nowrap}.file-preview-btn{flex:0 0 24px;display:inline-flex;align-items:center;justify-content:center;width:24px;min-width:24px;min-height:24px;margin-top:-2px;padding:0;border-radius:6px;color:var(--muted)}.file-preview-btn svg{width:15px;height:15px}.file-preview-btn:hover{background:var(--accent-soft);color:var(--accent)}.tree-preview-btn{flex:0 0 auto;margin-left:2px}.search-results{padding:0 0 8px;border-top:1px solid var(--line-soft)}.search-results-title{padding:8px 20px 4px;color:var(--muted);font-size:10px;font-weight:600;letter-spacing:.04em;text-transform:uppercase}.search-pagination{display:flex;align-items:center;justify-content:center;gap:8px;padding:8px;color:var(--muted);font-size:11px}.empty-tree{padding:16px 20px;color:var(--muted);font-size:11px}.chat-list-item{margin:1px 4px;padding:7px 10px;border:1px solid transparent;border-radius:8px;cursor:pointer;transition:background .12s,border-color .12s}.chat-list-item:hover{background:#eef1f5}.chat-list-item.selected{background:var(--selection);border-color:var(--selection-border)}.chat-list-item--open:not(.selected){border-color:#dce2ea;background:#f1f3f6}.chat-list-name{overflow:hidden;color:var(--text);font-size:12px;font-weight:500;text-overflow:ellipsis;white-space:nowrap}.chat-list-meta{margin-top:3px;color:var(--muted);font-size:10px}.chat-message-list{display:flex;flex-direction:column;gap:12px}.chat-message{max-width:78%;padding:10px 14px;border-radius:12px;font-size:14px;line-height:1.5;white-space:pre-wrap;word-break:break-word}.chat-message.user{align-self:flex-end;border:1px solid #c9d8f8;background:#f3f7ff;color:var(--text-bright)}.chat-message.assistant{align-self:flex-start;border:1px solid #dce2e9;background:#fff;color:var(--text)}.chat-message.assistant p{margin:0 0 8px}.chat-message.assistant p:last-child{margin-bottom:0}.chat-message.error{border-color:#f0c5c5;background:#fff5f5;color:var(--danger)}.chat-message-pending{color:var(--muted);font-style:italic}.chat-retry-btn{display:block;margin-top:9px;border-color:#e6b7b7;background:#fff;color:var(--danger)}.chat-message-role{margin-bottom:4px;color:var(--muted);font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.04em}.chat-header{display:flex;align-items:center;justify-content:space-between;min-height:48px;padding:0 20px;border-bottom:1px solid var(--line);background:var(--panel);box-shadow:0 1px 2px #0f172a05}.chat-header h2{margin:0;font-size:13px;font-weight:600;color:var(--text-bright);letter-spacing:-.01em}.chat-messages{min-height:0;overflow:auto;padding:24px;display:flex;flex-direction:column}.chat-placeholder{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;min-height:min(100%,320px);padding:24px 0;color:var(--muted);text-align:center}.chat-placeholder-icon{width:52px;height:52px;padding:14px;border-radius:16px;background:var(--input-bg);color:var(--muted)}.chat-placeholder h3{margin:0;color:var(--text-bright);font-size:18px;font-weight:600;letter-spacing:-.02em}.chat-placeholder p{margin:0;max-width:400px;font-size:14px;line-height:1.6;color:var(--text-secondary)}.chat-input-wrap{padding:16px 20px 20px;border-top:1px solid var(--line);background:#f8f9fb}.chat-input-content{display:flex;flex-direction:column;gap:8px}.chat-input-toolbar{display:flex;align-items:center;gap:8px;min-height:30px}.chat-input-row{display:flex;align-items:flex-end;gap:10px}.mention-trigger{flex:0 0 auto;width:30px;min-width:30px;min-height:30px;padding:0;border:1px solid #d6dce5;border-radius:8px;background:#fff;color:var(--text-secondary);font-size:20px;font-weight:400;line-height:1}.mention-trigger:hover{border-color:var(--accent);background:var(--accent-soft);color:var(--accent-hover)}.chat-textarea-wrap{position:relative;flex:1;min-width:0}.chat-input-row textarea{display:block;width:100%;min-height:44px;max-height:140px;padding:10px 14px;border:1px solid var(--line-strong);border-radius:12px;background:#fff;color:var(--text);resize:vertical;transition:border-color .15s,box-shadow .15s}.chat-input-row textarea:focus{border-color:var(--accent);box-shadow:0 0 0 3px #3b6cf41f;outline:none}.chat-input-row textarea:disabled{background:var(--input-bg);opacity:.75;cursor:not-allowed}.chat-input-row .primary{min-height:44px;padding:0 18px;border-radius:12px}.mention-menu{position:absolute;z-index:20;right:0;bottom:calc(100% + 8px);left:0;max-height:270px;overflow:auto;padding:5px;border:1px solid #cfd7e2;border-radius:10px;background:#fff;box-shadow:0 10px 26px #0f172a24}.mention-menu-title{padding:5px 8px 6px;color:var(--muted);font-size:10px;font-weight:600;letter-spacing:.06em;text-transform:uppercase}.mention-menu-item{display:flex;align-items:center;width:100%;min-height:32px;gap:8px;padding:5px 8px;border-radius:7px;text-align:left}.mention-menu-item:hover,.mention-menu-item.selected{background:var(--accent-soft);color:var(--text)}.mention-menu-icon{display:inline-flex;flex:0 0 16px;align-items:center;justify-content:center;color:var(--muted)}.mention-menu-name{display:flex;flex:1;align-items:center;gap:6px;min-width:0;overflow:hidden;color:var(--text);font-size:12px;font-weight:500;text-overflow:ellipsis}.mention-source-badge{flex:0 0 auto;padding:1px 5px;border-radius:4px;background:#e2ebff;color:#3b5fba;font-size:9px;font-weight:600;letter-spacing:.02em;text-transform:uppercase}.mention-menu-type{flex:0 0 auto;color:var(--muted);font-size:10px}.mention-menu-empty{padding:9px 8px;color:var(--muted);font-size:12px}.chat-agent-select{display:flex;align-items:center;gap:6px;min-height:30px;padding:2px 4px 2px 8px;border:1px solid #d6dce5;border-radius:8px;background:#fff;color:var(--text-secondary);font-size:11px}.chat-agent-select:hover{border-color:#bdc7d5}.chat-agent-select-label{color:var(--muted);font-size:10px;font-weight:600;letter-spacing:.03em;text-transform:uppercase}.chat-agent-select select{min-width:150px;min-height:24px;padding:2px 22px 2px 2px;border:0;border-radius:5px;background:transparent;color:var(--text-secondary);font-size:12px;font-weight:500}.chat-agent-select select:focus{outline:none}.chat-agent-select:focus-within{border-color:var(--accent);box-shadow:0 0 0 3px #3b6cf41a}.context-menu{position:fixed;z-index:1000;display:none;min-width:200px;padding:6px;border:1px solid var(--line);border-radius:12px;background:#fff;box-shadow:0 8px 30px #0f172a1f}.context-menu.open{display:block}.context-menu button{display:block;width:100%;min-height:32px;padding:6px 12px;border-radius:8px;color:var(--text);font-size:13px;text-align:left}.context-menu button:hover{background:var(--input-bg);color:var(--text)}.context-menu button.danger{color:var(--danger)}.context-menu button.danger:hover{background:var(--danger-soft);color:var(--danger)}.context-menu hr{margin:4px 6px;border:0;border-top:1px solid var(--line)}.file-preview-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1200;display:flex;align-items:center;justify-content:center;padding:24px;background:#0f172a73}.file-preview-modal{display:grid;grid-template-rows:auto 1fr;width:min(1040px,calc(100vw - 48px));height:min(760px,calc(100vh - 48px));min-width:0;min-height:0;overflow:hidden;border:1px solid var(--line);border-radius:12px;background:#fff;box-shadow:0 18px 60px #0f172a3d}.file-preview-header{display:flex;align-items:center;justify-content:space-between;gap:12px;min-width:0;min-height:68px;padding:10px 16px;border-bottom:1px solid var(--line);background:var(--panel)}.file-preview-title-group{display:flex;align-items:center;gap:10px;min-width:0}.file-preview-file-icon{display:inline-flex;flex:0 0 36px;align-items:center;justify-content:center;width:36px;height:36px;border:1px solid #cfdcf8;border-radius:9px;background:#edf3ff;color:var(--accent)}.file-preview-file-icon svg{width:19px;height:19px}.file-preview-title-block{min-width:0}.file-preview-mode{margin-bottom:1px;color:#61708a;font-size:10px;font-weight:600;letter-spacing:.06em;text-transform:uppercase}.file-preview-title-block h2{overflow:hidden;margin:0;color:var(--text-bright);font-size:14px;font-weight:600;text-overflow:ellipsis;white-space:nowrap}.file-preview-title-block span{display:block;margin-top:2px;overflow:hidden;color:var(--muted);font-size:11px;text-overflow:ellipsis;white-space:nowrap}.file-preview-actions{flex:0 0 auto;display:inline-flex;align-items:center;gap:6px}.file-preview-download{display:inline-flex;align-items:center;min-height:28px;padding:4px 10px;border-radius:8px;color:var(--text-secondary);font-size:13px;text-decoration:none;white-space:nowrap;transition:background .15s,color .15s}.file-preview-download:hover{background:var(--input-bg);color:var(--text)}.file-preview-body{display:flex;align-items:center;justify-content:center;min-width:0;min-height:0;overflow:hidden;padding:12px;background:#eef1f5}.file-preview-frame{width:100%;height:100%;border:0;background:#fff}.file-preview-image{max-width:100%;max-height:100%;object-fit:contain}.file-preview-state{padding:20px;color:var(--muted);font-size:13px;text-align:center}.file-preview-state.error{color:var(--danger)}.file-preview-text{align-self:stretch;width:100%;height:100%;margin:0;padding:22px 26px;overflow:auto;border:1px solid #dfe4eb;border-radius:8px;background:#fff;box-shadow:0 1px 2px #0f172a0a;color:var(--text);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:13px;line-height:1.6;white-space:pre-wrap;word-break:break-word}.file-preview-markdown{align-self:stretch;width:100%;height:100%;padding:22px 30px 30px;overflow:auto;border:1px solid #dfe4eb;border-radius:8px;background:#fff;box-shadow:0 1px 2px #0f172a0a;color:var(--text);font-size:14px;line-height:1.65}.file-preview-markdown>:first-child{margin-top:0}.file-preview-markdown>:last-child{margin-bottom:0}.file-preview-markdown h1,.file-preview-markdown h2,.file-preview-markdown h3,.file-preview-markdown h4{margin:1.2em 0 .55em;color:var(--text-bright);line-height:1.3}.file-preview-markdown h1{font-size:1.6em}.file-preview-markdown h2{font-size:1.35em}.file-preview-markdown h3{font-size:1.15em}.file-preview-markdown p,.file-preview-markdown ul,.file-preview-markdown ol,.file-preview-markdown blockquote,.file-preview-markdown pre{margin:.75em 0}.file-preview-markdown ul,.file-preview-markdown ol{padding-left:1.4em}.file-preview-markdown li+li{margin-top:.25em}.file-preview-markdown blockquote{padding:.2em 0 .2em .9em;border-left:3px solid var(--line-strong);color:var(--text-secondary)}.file-preview-markdown code{padding:.1em .35em;border-radius:4px;background:var(--input-bg);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:.92em}.file-preview-markdown pre{padding:12px 14px;overflow:auto;border:1px solid var(--line);border-radius:8px;background:#f8f9fb}.file-preview-markdown pre code{padding:0;background:transparent;font-size:.9em}.file-preview-markdown a{color:var(--accent);text-decoration:none}.file-preview-markdown a:hover{text-decoration:underline}.file-preview-markdown table{width:100%;margin:.75em 0;border-collapse:collapse;font-size:13px}.file-preview-markdown th,.file-preview-markdown td{padding:8px 10px;border:1px solid var(--line);text-align:left}.file-preview-markdown th{background:#fafbfc;font-weight:600}.file-preview-markdown hr{margin:1.2em 0;border:0;border-top:1px solid var(--line)}.source-modal-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1200;display:flex;align-items:center;justify-content:center;padding:24px;background:#0f172a73}.source-modal{display:grid;grid-template-rows:auto 1fr;width:min(640px,calc(100vw - 48px));max-height:min(760px,calc(100vh - 48px));min-width:0;min-height:0;overflow:hidden;border:1px solid var(--line);border-radius:8px;background:#fff;box-shadow:0 18px 60px #0f172a3d}.source-modal-header{display:flex;align-items:center;justify-content:space-between;gap:12px;min-width:0;min-height:56px;padding:10px 14px 10px 16px;border-bottom:1px solid var(--line);background:var(--panel)}.source-modal-title-block{min-width:0}.source-modal-title-block h2{overflow:hidden;margin:0;color:var(--text-bright);font-size:14px;font-weight:600;text-overflow:ellipsis;white-space:nowrap}.source-modal-title-block span{display:block;margin-top:2px;overflow:hidden;color:var(--muted);font-size:11px;text-overflow:ellipsis;white-space:nowrap}.source-modal-body{min-height:0;overflow:auto;padding:16px}.source-modal-state{padding:20px 0;color:var(--muted);font-size:13px;text-align:center}.source-modal-error{margin-bottom:12px;padding:10px 12px;border-radius:8px;background:var(--danger-soft);color:var(--danger);font-size:13px}.source-form{display:flex;flex-direction:column;gap:12px}.source-form label{display:flex;flex-direction:column;gap:5px}.source-form label span{color:var(--text-secondary);font-size:12px;font-weight:500}.source-form input,.source-form select,.source-form textarea{display:block;width:100%;min-height:38px;padding:9px 12px;border:1px solid #d7dce5;border-radius:10px;background:#f8fafc;color:var(--text);font:inherit;font-size:13px;line-height:1.4;transition:border-color .15s,background .15s,box-shadow .15s}.source-form textarea{min-height:72px;resize:vertical}.source-form input:focus,.source-form select:focus,.source-form textarea:focus{outline:none;border-color:var(--accent);background:#fff;box-shadow:0 0 0 3px #3b82f61f}.source-form input::placeholder,.source-form textarea::placeholder{color:#94a3b8}.source-form input:disabled,.source-form select:disabled,.source-form textarea:disabled{background:var(--input-bg);color:var(--muted)}.source-form-hint{margin:0;color:var(--text-secondary);font-size:12px;line-height:1.5}.source-modal-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:4px}.source-inline-actions{display:flex;justify-content:flex-end}.source-import-actions{gap:8px;flex-wrap:wrap}.source-configure{display:flex;flex-direction:column;gap:16px}.source-setup-warning{padding:12px 14px;border:1px solid #f3b4b4;border-radius:10px;background:var(--danger-soft);color:#991b1b;font-size:12px;line-height:1.5}.source-setup-warning strong{display:block;margin-bottom:2px;color:var(--danger)}.source-setup-warning-count{color:#b45353}.source-import-warning{padding:12px 14px;border:1px solid #fcd34d;border-radius:10px;background:var(--warning-soft);color:#92400e;font-size:12px;line-height:1.5}.source-import-warning strong{display:block;margin-bottom:2px;color:var(--warning)}.source-import-section{border-color:#fde68a;background:linear-gradient(180deg,#fffef8,#fafbfc)}.source-import-note{margin:8px 0 0;color:var(--text-secondary);font-size:11px;line-height:1.45}.source-import-btn:disabled{cursor:not-allowed;opacity:.72}.source-operation-status{display:flex;flex-direction:column;gap:10px;margin:12px 0;padding:12px 14px;border:1px solid var(--line);border-radius:10px;background:#fff}.source-operation-status--active{border-color:#93c5fd;background:#f8fbff}.source-operation-status-header{display:flex;align-items:flex-start;gap:10px}.source-operation-status-header strong{display:block;color:#1d4ed8;font-size:13px}.source-operation-meta{display:block;margin-top:2px;color:var(--text-secondary);font-size:11px}.source-operation-spinner{flex:0 0 auto;width:14px;height:14px;margin-top:2px;border:2px solid rgba(37,99,235,.2);border-top-color:#2563eb;border-radius:50%;animation:content-status-spin .8s linear infinite}.source-operation-progress{display:flex;flex-direction:column;gap:6px}.source-operation-progress-bar{overflow:hidden;height:6px;border-radius:999px;background:#dbeafe}.source-operation-progress-fill{height:100%;border-radius:inherit;background:linear-gradient(90deg,#3b82f6,#2563eb);transition:width .3s ease}.source-operation-progress-text{color:var(--text-secondary);font-size:11px}.source-operation-history{display:grid;gap:8px;margin:0}.source-operation-history>div{display:flex;align-items:baseline;justify-content:space-between;gap:12px}.source-operation-history dt{margin:0;color:var(--text-secondary);font-size:12px;font-weight:500}.source-operation-history dd{margin:0;color:var(--text);font-size:12px;text-align:right}.source-operation-error{padding:10px 12px;border:1px solid #fecaca;border-radius:8px;background:var(--danger-soft);color:#991b1b}.source-operation-error strong{display:block;margin-bottom:4px;font-size:12px}.source-operation-error p{margin:0;font-size:12px;line-height:1.45;white-space:pre-wrap;word-break:break-word}.source-section{padding:0;border:1px solid var(--line);border-radius:12px;background:#fafbfc;overflow:hidden}.source-collapsible.is-open{background:#fafbfc}.source-collapsible.is-highlighted:not(.is-open){border-color:#fca5a5;background:var(--danger-soft);box-shadow:inset 3px 0 0 var(--danger)}.source-collapsible.is-highlighted:not(.is-open) .source-section-toggle{color:#991b1b}.source-collapsible.is-highlighted:not(.is-open) .source-section-toggle:hover{background:#dc26260f}.source-collapsible.is-highlighted:not(.is-open) .source-section-chevron{color:var(--danger)}.source-collapsible.is-highlighted:not(.is-open) .source-section-title{color:var(--danger)}.source-section-toggle{display:flex;align-items:center;gap:8px;width:100%;padding:12px 14px;border:0;background:transparent;color:var(--text-bright);text-align:left;cursor:pointer;transition:background .15s}.source-section-toggle:hover{background:#0f172a08}.source-section-chevron{display:inline-flex;flex:0 0 auto;align-items:center;justify-content:center;width:16px;height:16px;color:var(--muted);transition:transform .15s}.source-section-chevron svg{width:12px;height:12px}.source-section-chevron.expanded{transform:rotate(90deg)}.source-section-title{font-size:11px;font-weight:600;letter-spacing:.08em;text-transform:uppercase}.source-section-content{padding:0 14px 14px}.source-section-content>.source-form,.source-section-content>.source-credentials,.source-section-content>.source-form-hint{margin-top:0}.source-section h3{margin:0 0 12px;color:var(--text-bright);font-size:11px;font-weight:600;letter-spacing:.08em;text-transform:uppercase}.source-credentials{display:flex;flex-direction:column;gap:12px}.source-credential-card{display:flex;flex-direction:column;gap:8px;padding:14px;border:1px solid var(--line);border-radius:12px;background:#fff;box-shadow:0 1px 2px #0f172a0a;transition:border-color .15s,box-shadow .15s,background .15s}.source-credential-card.is-empty{border-color:#fecaca;background:linear-gradient(180deg,snow,#fff);box-shadow:inset 3px 0 0 var(--danger)}.source-credential-card.is-filled:not(.is-empty){border-color:#bbf7d0;background:linear-gradient(180deg,#f8fffb,#fff);box-shadow:inset 3px 0 #22c55e}.source-credential-header{display:flex;align-items:center;justify-content:space-between;gap:10px}.source-credential-name{min-width:0;overflow:hidden;color:var(--text-bright);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:12px;font-weight:600;letter-spacing:.01em;text-overflow:ellipsis;white-space:nowrap}.source-credential-badge{flex:0 0 auto;padding:3px 8px;border-radius:999px;font-size:10px;font-weight:600;letter-spacing:.03em;text-transform:uppercase;white-space:nowrap}.source-credential-badge--error{background:#fee2e2;color:#b91c1c}.source-credential-badge--ok{background:#dcfce7;color:#15803d}.source-credential-desc{margin:0;color:var(--text-secondary);font-size:12px;line-height:1.45}.source-credential-input{display:block;width:100%;min-height:38px;padding:9px 12px;border:1px solid #d7dce5;border-radius:10px;background:#f8fafc;color:var(--text);font:inherit;font-size:13px;line-height:1.4;transition:border-color .15s,background .15s,box-shadow .15s}.source-credential-card.is-empty .source-credential-input{border-color:#fca5a5;background:#fff}.source-credential-card.is-filled:not(.is-empty) .source-credential-input{border-color:#86efac;background:#fff}.source-credential-input::placeholder{color:#94a3b8}.source-credential-input:focus{outline:none;border-color:var(--accent);background:#fff;box-shadow:0 0 0 3px #3b82f61f}.source-credential-card.is-empty .source-credential-input:focus{border-color:var(--danger);box-shadow:0 0 0 3px #dc26261f}.source-credential-input:-webkit-autofill,.source-credential-input:-webkit-autofill:hover,.source-credential-input:-webkit-autofill:focus{-webkit-text-fill-color:var(--text);box-shadow:0 0 0 1000px #fff inset;transition:background-color 9999s ease-out 0s}.archive-preview{align-self:stretch;display:grid;grid-template-rows:auto 1fr;width:100%;min-height:0;padding:14px}.archive-preview-summary{padding:0 0 10px;color:var(--text-secondary);font-size:12px;font-weight:600}.archive-preview-table-wrap{min-height:0;overflow:auto;border:1px solid var(--line);border-radius:8px;background:#fff}.archive-preview-table{width:100%;min-width:620px;border-collapse:collapse;table-layout:fixed;font-size:12px}.archive-preview-table th,.archive-preview-table td{padding:8px 10px;border-bottom:1px solid var(--line-soft);color:var(--text);text-align:left;vertical-align:middle}.archive-preview-table th{position:sticky;top:0;z-index:1;background:#fafbfc;color:var(--muted);font-size:10px;font-weight:600;letter-spacing:.06em;text-transform:uppercase}.archive-preview-table th:nth-child(2),.archive-preview-table td:nth-child(2){width:110px;text-align:right}.archive-preview-table th:nth-child(3),.archive-preview-table td:nth-child(3){width:150px;color:var(--text-secondary)}.archive-preview-table td:first-child span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.archive-preview-table tbody tr:last-child td{border-bottom:0}.topbar-right{display:flex;align-items:center;gap:12px;min-width:0;margin-left:auto}.topbar-user{color:var(--text-secondary);font-size:12px}.topbar-logout{font-size:12px}.explorer-panel{flex:1;min-width:0;min-height:0;display:grid;grid-template-rows:auto 1fr;overflow:hidden;background:var(--chat-bg);border-left:0}.explorer-header{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:48px;padding:0 20px;border-bottom:1px solid var(--line);background:var(--panel)}.explorer-header h2{margin:0;font-size:13px;font-weight:600;color:var(--text-bright)}.explorer-count{color:var(--muted);font-size:12px}.explorer-header-actions{display:flex;align-items:center;gap:10px}.explorer-open-btn{flex:0 0 auto;margin-left:auto}.explorer-body{min-height:0;overflow:auto;padding:16px 20px 24px}.explorer-placeholder{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;min-height:min(100%,320px);color:var(--muted);text-align:center}.explorer-placeholder svg{width:40px;height:40px;padding:10px;border-radius:12px;background:var(--input-bg);color:var(--muted)}.explorer-placeholder h3{margin:0;color:var(--text-bright);font-size:16px}.explorer-placeholder p{margin:0;max-width:360px;font-size:13px;line-height:1.5;color:var(--text-secondary)}.explorer-list{border:1px solid var(--line);border-radius:10px;background:#fff;overflow:hidden}.explorer-list-header,.explorer-row{display:grid;grid-template-columns:1fr 120px 100px;align-items:center;gap:12px;padding:10px 14px}.explorer-list-header{border-bottom:1px solid var(--line-soft);background:#fafbfc;color:var(--muted);font-size:10px;font-weight:600;letter-spacing:.06em;text-transform:uppercase}.explorer-row{border-bottom:1px solid var(--line-soft);cursor:pointer;transition:background .12s}.explorer-row:last-child{border-bottom:0}.explorer-row:hover{background:#f8f9fb}.explorer-row.selected{background:#f3f7ff}.explorer-row--sourced{background:linear-gradient(90deg,var(--accent-soft) 0%,#fff 100%);box-shadow:inset 3px 0 0 var(--accent)}.explorer-row--sourced:hover{background:linear-gradient(90deg,#dce6ff,#f8f9fb)}.explorer-row--sourced.selected{background:linear-gradient(90deg,#dce6ff,#f3f7ff)}.explorer-name{overflow:hidden;display:flex;align-items:center;gap:8px;min-width:0;color:var(--text);font-size:13px;font-weight:500}.explorer-name>span:nth-child(2){overflow:hidden;min-width:0}.explorer-name-text{display:flex;flex-direction:column;gap:2px;min-width:0;flex:1}.explorer-name-main{display:flex;align-items:center;gap:6px;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.explorer-source-meta{overflow:hidden;color:#2f4f9e;font-size:11px;font-weight:400;text-overflow:ellipsis;white-space:nowrap}.explorer-meta,.explorer-size{color:var(--text-secondary);font-size:12px}.explorer-size{text-align:right}.login-page{display:flex;align-items:center;justify-content:center;min-height:100%;padding:24px;background:radial-gradient(circle at top left,rgba(59,108,244,.12),transparent 42%),var(--bg)}.login-card{width:min(400px,100%);padding:32px;border:1px solid var(--line);border-radius:16px;background:#fff;box-shadow:0 12px 40px #0f172a14}.login-brand{margin-bottom:24px;text-align:center}.login-brand h1{margin:0;font-size:28px;font-weight:600;color:var(--text-bright);letter-spacing:-.03em}.login-brand p{margin:6px 0 0;color:var(--muted);font-size:14px}.login-form{display:flex;flex-direction:column;gap:14px}.login-form label{display:flex;flex-direction:column;gap:6px}.login-form label span{color:var(--text-secondary);font-size:12px;font-weight:500}.login-form input{min-height:42px;padding:0 12px;border:1px solid var(--line-strong);border-radius:10px;background:#fff;color:var(--text);transition:border-color .15s,box-shadow .15s}.login-form input:focus{border-color:var(--accent);box-shadow:0 0 0 3px #3b6cf41f;outline:none}.login-error{padding:10px 12px;border-radius:8px;background:var(--danger-soft);color:var(--danger);font-size:13px}.login-submit{min-height:44px;margin-top:4px;border-radius:10px;font-weight:500}body.resizing{cursor:col-resize!important;-webkit-user-select:none;user-select:none}body.resizing *{cursor:col-resize!important}@media(max-width:820px){.workspace{flex-direction:column}.sidebar-group{width:100%!important}.sidebar{width:auto!important;flex:1;max-width:none;min-height:200px;max-height:42vh}.resize-handle,.context-resize-handle{display:none}.explorer-panel{border-left:0;border-top:1px solid var(--line)}.editor-group{min-height:0}.editor-content{flex-direction:column}.editor-content>.sources-panel{width:auto!important;max-width:none;min-height:160px;max-height:32vh;border-top:1px solid var(--line)}.chat-panel{border-left:0;border-top:1px solid var(--line)}.sources-panel{width:auto!important;flex:0 0 auto;max-width:none;min-height:160px;max-height:32vh;border-top:1px solid var(--line)}.status{max-width:100%;text-align:left;white-space:normal}.file-preview-backdrop{padding:10px}.file-preview-modal{width:calc(100vw - 20px);height:calc(100vh - 20px)}.file-preview-header{align-items:flex-start}}.project-modal{width:min(720px,calc(100vw - 48px))}.project-modal-tabs{display:flex;gap:4px;margin-bottom:14px;padding:3px;border-radius:10px;background:#f1f5f9}.project-modal-tabs button{flex:1;min-height:34px;border-radius:8px;color:var(--text-secondary);font-size:12px;font-weight:500}.project-modal-tabs button.active{background:#fff;color:var(--text-bright);box-shadow:0 1px 2px #0f172a14}.project-meta-list{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:0}.project-meta-list div{min-width:0}.project-meta-list dt{margin:0 0 2px;color:var(--muted);font-size:11px}.project-meta-list dd{margin:0;overflow:hidden;color:var(--text);font-size:12px;text-overflow:ellipsis;white-space:nowrap}.project-segmented{display:grid;grid-template-columns:1fr 1fr;gap:4px;padding:3px;border-radius:10px;background:#f1f5f9}.project-segmented button{min-height:34px;border-radius:8px;color:var(--text-secondary);font-size:12px;font-weight:500}.project-segmented button.active{background:#fff;color:var(--text-bright);box-shadow:0 1px 2px #0f172a14}.project-members{display:flex;flex-direction:column;gap:16px}.project-member-form{padding-bottom:14px;border-bottom:1px solid var(--line)}.project-members-empty{padding:16px 0;color:var(--muted);font-size:13px;text-align:center}.project-members-list{display:flex;flex-direction:column;gap:8px;margin:0;padding:0;list-style:none}.project-member-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border:1px solid var(--line);border-radius:10px;background:#fafbfd}.project-member-info{min-width:0}.project-member-name{display:block;overflow:hidden;color:var(--text-bright);font-size:13px;font-weight:500;text-overflow:ellipsis;white-space:nowrap}.project-member-meta{display:block;margin-top:2px;color:var(--muted);font-size:11px}.project-member-actions{display:flex;align-items:center;gap:8px;flex-shrink:0}.project-member-role-input{width:72px;min-height:32px;padding:6px 8px;border:1px solid #d7dce5;border-radius:8px;background:#fff;font:inherit;font-size:12px}.project-member-role-select{min-width:140px;max-width:180px;min-height:32px;padding:6px 8px;border:1px solid #d7dce5;border-radius:8px;background:#fff;font:inherit;font-size:12px}.project-member-subject-meta{display:block;margin-top:1px;color:var(--text-secondary);font-size:11px}.directory-picker{display:flex;flex-direction:column;gap:6px}.directory-picker-label{color:var(--text-secondary);font-size:12px;font-weight:500}.directory-picker-search{display:flex;gap:8px}.directory-picker-search input{flex:1;min-height:36px;padding:8px 10px;border:1px solid #d7dce5;border-radius:8px;background:#f8fafc;font:inherit;font-size:13px}.directory-picker-selected{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:8px 10px;border:1px solid var(--line);border-radius:8px;background:#f8fafc}.directory-picker-selected-main{min-width:0}.directory-picker-selected-name{display:block;overflow:hidden;color:var(--text-bright);font-size:13px;font-weight:500;text-overflow:ellipsis;white-space:nowrap}.directory-picker-selected-meta{display:block;margin-top:2px;overflow:hidden;color:var(--muted);font-size:11px;text-overflow:ellipsis;white-space:nowrap}.directory-picker-empty{color:var(--muted);font-size:12px}.directory-picker-results{display:flex;flex-direction:column;gap:4px;max-height:160px;margin:0;padding:0;overflow:auto;list-style:none}.directory-picker-results button{display:flex;align-items:center;justify-content:space-between;width:100%;min-height:34px;padding:6px 10px;border-radius:8px;color:var(--text);font-size:12px;text-align:left}.directory-picker-results button:hover{background:var(--accent-soft)}.directory-picker-results button span:last-child{color:var(--muted);font-size:11px}.project-list-wrap{min-height:0;padding:0 8px 8px}.project-sidebar-tree{padding:0}.project-sidebar-group{margin-bottom:12px}.project-sidebar-group+.project-sidebar-group{margin-top:0}.project-sidebar-row{margin:0 2px;padding:11px 12px;min-height:42px;border:1px solid #b8c9ee;background:linear-gradient(180deg,#edf2ff,#e2eafc);box-shadow:inset 3px 0 0 var(--accent)}.project-sidebar-row .tree-folder-main{min-height:22px;align-items:center}.project-sidebar-row .tree-label{cursor:pointer}.project-sidebar-row .tree-label-text{font-size:13px;font-weight:600;color:#1e3a6e}.project-sidebar-row .tree-icon{flex:0 0 18px;width:18px;height:18px;color:var(--accent)}.project-sidebar-row .tree-toggle{color:#5b6f9a}.project-sidebar-row:hover{background:linear-gradient(180deg,#e4ecff,#d8e3fc);border-color:#9eb5e8}.project-sidebar-row.selected{background:linear-gradient(180deg,#dce6ff,#cdd9f8);border-color:#7f9de8;box-shadow:inset 3px 0 #2f5de0}.project-sidebar-row--expanded{border-bottom-left-radius:4px;border-bottom-right-radius:4px;margin-bottom:0}.project-sidebar-children{margin:0 2px 4px;padding:6px 0 4px 4px;border:1px solid #d7dce5;border-top:0;border-radius:0 0 10px 10px;background:#fff}.project-sidebar-children .tree-folder-item{margin-left:4px;margin-right:4px}.project-tree-inline-status{margin-left:6px;color:var(--muted);font-size:11px}.project-attach-picker{display:flex;flex-direction:column;min-height:0;max-height:42vh;margin:0 8px 8px;border:1px solid var(--line);border-radius:10px;background:#fafbfd;overflow:hidden}.project-attach-picker-search{flex:0 0 auto;border-bottom:1px solid var(--line)}.project-attach-picker-tree{flex:1;min-height:120px;overflow:auto;padding:0 4px 8px}.project-attach-picker-actions{display:flex;align-items:center;justify-content:space-between;gap:8px;flex:0 0 auto;padding:8px 10px;border-top:1px solid var(--line);background:#fff}.project-attach-picker-count{color:var(--text-secondary);font-size:12px}.attach-node-row .tree-folder-main{gap:4px}.attach-node-check{display:inline-flex;flex:0 0 auto;align-items:center;margin:0;cursor:pointer}.attach-node-check input{width:14px;height:14px;margin:0;cursor:pointer}.attach-node-children-check{display:inline-flex;align-items:center;gap:4px;margin-left:auto;color:var(--text-secondary);font-size:10px;white-space:nowrap;cursor:pointer}.attach-node-children-check input{width:12px;height:12px;margin:0;cursor:pointer}.attach-node-attached{margin-left:auto;color:var(--muted);font-size:10px;white-space:nowrap}.attach-node-row--disabled{opacity:.55}.toolbar-text-btn.active{background:var(--accent-soft);color:var(--text-bright)}.project-add-node-sidebar{margin:0 8px 8px;padding:10px;border:1px solid var(--line);border-radius:10px;background:#fafbfd}.project-list .chat-list-item{display:flex;flex-direction:column;align-items:stretch;width:100%;text-align:left}.project-list .chat-list-meta{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.project-list{margin:0;padding:0;list-style:none}.project-list li+li{margin-top:4px}.error-text{color:var(--danger)}.project-detail{display:flex;flex-direction:column;gap:16px;min-height:0}.project-detail-description{margin:0;color:var(--text-secondary);font-size:13px;line-height:1.5}.project-detail-meta{display:flex;flex-wrap:wrap;gap:16px;margin:0}.project-detail-meta div{min-width:140px}.project-detail-meta dt{margin:0 0 2px;color:var(--muted);font-size:11px}.project-detail-meta dd{margin:0;color:var(--text);font-size:12px}.project-add-node-form{padding:14px;border:1px solid var(--line);border-radius:10px;background:#fafbfd}.project-add-node-form h3{margin:0 0 10px;font-size:13px;font-weight:600}.project-add-node-search{display:flex;gap:8px}.project-add-node-search input{flex:1;min-height:36px;padding:8px 10px;border:1px solid #d7dce5;border-radius:8px;background:#fff;font:inherit;font-size:13px}.project-add-node-results{display:flex;flex-direction:column;gap:4px;max-height:180px;margin:10px 0 0;padding:0;overflow:auto;list-style:none}.project-add-node-results button{display:flex;align-items:center;justify-content:space-between;width:100%;min-height:34px;padding:6px 10px;border-radius:8px;color:var(--text);font-size:12px;text-align:left}.project-add-node-results button:hover{background:var(--accent-soft)}.project-add-node-results button.selected{background:var(--accent-soft);color:var(--text-bright)}.project-add-node-results button span{color:var(--muted);font-size:11px}.project-add-node-checkbox{display:flex;align-items:center;gap:8px;margin-top:10px;color:var(--text-secondary);font-size:12px}.project-add-node-actions{display:flex;justify-content:flex-end;margin-top:10px}.project-tree-panel{min-height:0}.project-tree-title{margin-bottom:8px;color:var(--text-secondary);font-size:12px;font-weight:600;text-transform:uppercase;letter-spacing:.04em}.project-tree{padding:4px 0}.project-tree-item--file{cursor:pointer}.project-node-remove-btn{display:inline-flex;align-items:center;justify-content:center;width:22px;min-width:22px;min-height:22px;margin-left:auto;border-radius:6px;color:var(--muted);font-size:16px;line-height:1}.project-node-remove-btn:hover{background:var(--danger-soft);color:var(--danger)}
