* { margin: 0; padding: 0; box-sizing: border-box; } :root { --primary-color: #1a1a1a; --secondary-color: #2d2d2d; --accent-color: #0066ff; --accent-hover: #0052cc; --bg-primary: #ffffff; --bg-secondary: #f8f9fa; --bg-tertiary: #f1f3f5; --text-primary: #1a1a1a; --text-secondary: #6c757d; --text-muted: #adb5bd; --border-color: #e9ecef; --success-color: #28a745; --warning-color: #ffc107; --error-color: #dc3545; --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05); --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1); --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15); } body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif; background: var(--bg-secondary); margin: 0; padding: 0; color: var(--text-primary); line-height: 1.6; height: 100vh; overflow: hidden; } .container { max-width: 100%; margin: 0; background: var(--bg-primary); height: 100vh; display: flex; flex-direction: column; box-shadow: var(--shadow-lg); overflow: hidden; } .main-layout { display: flex; flex: 1; overflow: hidden; min-height: 0; } /* 主侧边栏样式 - 紧凑宽度,参考常见后台 200~220px */ .main-sidebar { width: 208px; background: linear-gradient(180deg, #fafbfc 0%, #f5f7fa 100%); color: var(--text-primary); display: flex; flex-direction: column; flex-shrink: 0; border-right: 1px solid var(--border-color); box-shadow: 2px 0 8px rgba(0, 0, 0, 0.04); position: relative; transition: width 0.2s ease; } .main-sidebar.collapsed { width: 64px; } .sidebar-collapse-btn { position: absolute; top: 16px; right: 8px; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; cursor: pointer; border-radius: 6px; background: var(--bg-primary); border: 1px solid var(--border-color); color: var(--text-secondary); transition: all 0.2s ease; z-index: 10; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08); } .sidebar-collapse-btn:hover { background: var(--bg-tertiary); color: var(--text-primary); border-color: var(--accent-color); } .main-sidebar.collapsed .sidebar-collapse-btn { right: 16px; transform: rotate(180deg); } .sidebar-collapse-btn svg { width: 16px; height: 16px; stroke: currentColor; transition: transform 0.2s ease; } .main-sidebar-header { padding: 14px 16px; border-bottom: 1px solid var(--border-color); flex-shrink: 0; background: var(--bg-primary); } .main-sidebar-header .logo { display: flex; align-items: center; gap: 12px; color: var(--text-primary); } .main-sidebar-header .logo span { font-size: 1.25rem; font-weight: 600; letter-spacing: -0.3px; color: var(--text-primary); } .main-sidebar-nav { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 16px 0; background: transparent; padding-top: 56px; } /* 侧边栏滚动条样式 */ .main-sidebar-nav::-webkit-scrollbar { width: 6px; } .main-sidebar-nav::-webkit-scrollbar-track { background: transparent; } .main-sidebar-nav::-webkit-scrollbar-thumb { background: rgba(0, 0, 0, 0.2); border-radius: 3px; } .main-sidebar-nav::-webkit-scrollbar-thumb:hover { background: rgba(0, 0, 0, 0.3); } .nav-item { margin-bottom: 0; } .nav-item-content { display: flex; align-items: center; gap: 10px; padding: 10px 16px; cursor: pointer; transition: all 0.2s ease; color: var(--text-primary); position: relative; font-size: 0.9375rem; border-left: 3px solid transparent; justify-content: flex-start; } .main-sidebar.collapsed .nav-item-content { padding: 12px 12px 12px 9px; justify-content: center; position: relative; gap: 0; } .main-sidebar.collapsed .nav-item-content:hover::after { content: attr(data-title); position: absolute; left: 100%; top: 50%; transform: translateY(-50%); margin-left: 12px; padding: 6px 12px; background: rgba(0, 0, 0, 0.85); color: white; border-radius: 4px; font-size: 0.8125rem; white-space: nowrap; z-index: 1000; pointer-events: none; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15); } .main-sidebar.collapsed .nav-item-content:hover::before { content: ''; position: absolute; left: 100%; top: 50%; transform: translateY(-50%); margin-left: 6px; border: 6px solid transparent; border-right-color: rgba(0, 0, 0, 0.85); z-index: 1001; pointer-events: none; } .nav-item-content:hover { background: rgba(0, 102, 255, 0.06); color: var(--text-primary); } .nav-item.active > .nav-item-content { background: linear-gradient(90deg, rgba(0, 102, 255, 0.12) 0%, rgba(0, 102, 255, 0.06) 100%); color: var(--accent-color); border-left-color: var(--accent-color); font-weight: 500; } .nav-item.active > .nav-item-content svg { stroke: var(--accent-color); } .nav-item-content svg { flex-shrink: 0; stroke: currentColor; width: 18px; height: 18px; } .nav-item-content span { flex: 1; font-size: 0.9375rem; font-weight: 400; white-space: nowrap; opacity: 1; transition: opacity 0.2s ease; } .main-sidebar.collapsed .nav-item-content span { display: none; } .nav-item-has-submenu .nav-item-content { justify-content: space-between; } .main-sidebar.collapsed .nav-item-has-submenu .nav-item-content { justify-content: center; } .main-sidebar.collapsed .submenu-arrow { display: none; } .submenu-arrow { transition: transform 0.2s ease; flex-shrink: 0; width: 14px; height: 14px; stroke: var(--text-secondary); } .nav-item.expanded .submenu-arrow { transform: rotate(90deg); } .nav-item.expanded > .nav-item-content { color: var(--text-primary); font-weight: 500; } .nav-submenu { max-height: 0; overflow: hidden; transition: max-height 0.3s ease; background: rgba(255, 255, 255, 0.5); } .nav-item.expanded .nav-submenu { max-height: 300px; } .nav-submenu-item { padding: 10px 20px 10px 56px; cursor: pointer; transition: all 0.2s ease; color: var(--text-secondary); font-size: 0.875rem; position: relative; border-left: 3px solid transparent; } .main-sidebar.collapsed .nav-submenu { display: none; } .main-sidebar.collapsed .nav-item.expanded .nav-submenu { display: none; } /* 子菜单弹出框样式 */ .submenu-popup { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); padding: 4px 0; min-width: 160px; margin-left: 8px; animation: popupFadeIn 0.2s ease; } @keyframes popupFadeIn { from { opacity: 0; transform: translateX(-8px); } to { opacity: 1; transform: translateX(0); } } .submenu-popup-item { padding: 10px 16px; cursor: pointer; transition: all 0.2s ease; color: var(--text-primary); font-size: 0.875rem; white-space: nowrap; } .submenu-popup-item:hover { background: rgba(0, 102, 255, 0.08); color: var(--accent-color); } .submenu-popup-item:active { background: rgba(0, 102, 255, 0.12); } .submenu-popup-item.active { background: rgba(0, 102, 255, 0.1); color: var(--accent-color); font-weight: 500; } .nav-submenu-item:hover { background: rgba(0, 102, 255, 0.06); color: var(--text-primary); } .nav-submenu-item.active { background: linear-gradient(90deg, rgba(0, 102, 255, 0.12) 0%, rgba(0, 102, 255, 0.06) 100%); color: var(--accent-color); border-left-color: var(--accent-color); font-weight: 500; } /* 内容区域 */ .content-area { flex: 1; display: flex; flex-direction: column; overflow: hidden; min-width: 0; background: #f5f7fa; } /* 对话页面不需要page-header */ #page-chat .page-header { display: none; } #page-chat .page-content { padding: 0; overflow: hidden; } .page { display: none; flex: 1; flex-direction: column; overflow: hidden; min-height: 0; } .page.active { display: flex; } .page-header { padding: 12px 20px; background: linear-gradient(135deg, #ffffff 0%, #fafbfc 100%); border-bottom: 1px solid var(--border-color); display: flex; justify-content: space-between; align-items: center; flex-shrink: 0; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04); } .page-header h2 { margin: 0; font-size: 1.25rem; font-weight: 600; color: var(--text-primary); } .page-header-actions { display: flex; gap: 8px; align-items: center; } .page-content { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 16px 20px; min-height: 0; } /* 任务管理页面内容区域底部圆角 */ #page-tasks .page-content { /* 确保底部左右角都是圆角 */ border-bottom-left-radius: 8px; border-bottom-right-radius: 8px; overflow: hidden; } /* 对话页面布局 */ .chat-page-layout { display: flex; flex: 1; overflow: hidden; min-height: 0; width: 100%; height: 100%; position: relative; } .conversation-sidebar { width: 280px; background: linear-gradient(180deg, #ffffff 0%, #fafbfc 100%); border-right: 1px solid var(--border-color); display: flex; flex-direction: column; flex-shrink: 0; height: 100%; overflow: hidden; } header { background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%); color: var(--text-primary); padding: 10px 24px; border-bottom: 1px solid var(--border-color); flex-shrink: 0; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06); } .header-content { display: flex; justify-content: space-between; align-items: center; } .logo { display: flex; align-items: center; gap: 12px; } .logo svg { color: var(--accent-color); } .logo h1 { font-size: 1.5rem; font-weight: 600; letter-spacing: -0.5px; } .header-logo-link { cursor: pointer; transition: opacity 0.2s ease; } .header-logo-link:hover { opacity: 0.85; } .version-badge { display: inline-block; margin-left: 6px; font-size: 0.6875rem; font-weight: 400; color: var(--text-muted); letter-spacing: 0.02em; vertical-align: 0.35em; user-select: none; } .header-right { display: flex; align-items: center; gap: 16px; } .header-subtitle { font-size: 0.875rem; color: var(--text-secondary); margin: 0; font-weight: 400; } .header-actions { display: flex; align-items: center; gap: 12px; } .header-actions button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 6px 12px; border-radius: 6px; border: 1px solid var(--border-color); background: var(--bg-primary); color: var(--text-primary); cursor: pointer; font-size: 0.8125rem; font-weight: 500; transition: all 0.2s ease; } .header-actions button svg { stroke: currentColor; } .header-actions button:hover { background: var(--bg-tertiary); border-color: var(--accent-color); color: var(--accent-color); transform: translateY(-1px); } .openapi-doc-btn { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 6px; border: 1px solid var(--border-color); background: var(--bg-primary); color: var(--text-primary); cursor: pointer; font-size: 0.8125rem; font-weight: 400; transition: all 0.2s ease; } .openapi-doc-btn:hover { background: var(--bg-tertiary); border-color: var(--accent-color); color: var(--accent-color); transform: translateY(-1px); } .monitor-btn { color: var(--accent-color); border-color: var(--border-color); background: var(--bg-primary); } .monitor-btn:hover { background: rgba(0, 102, 255, 0.08); border-color: var(--accent-color); color: var(--accent-color); } .attack-chain-btn { color: var(--text-secondary); border: none; background: transparent; padding: 6px 10px; font-size: 0.8125rem; font-weight: 400; box-shadow: none; display: inline-flex; align-items: center; gap: 6px; border-radius: 6px; transition: all 0.2s ease; } .attack-chain-btn svg { flex-shrink: 0; opacity: 0.7; } .conversation-header .attack-chain-btn { background: transparent; border: none; backdrop-filter: none; color: var(--text-secondary); } .conversation-header .attack-chain-btn:hover { background: rgba(0, 102, 255, 0.06); color: var(--accent-color); transform: none; border: none; } .conversation-header .attack-chain-btn:hover svg { opacity: 1; } .conversation-header .attack-chain-btn:disabled { opacity: 0.4; cursor: not-allowed; background: transparent; color: var(--text-muted); } /* 用户菜单样式 */ .user-menu-container { position: relative; } .user-avatar-btn { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--border-color); background: var(--bg-primary); color: var(--text-secondary); cursor: pointer; transition: all 0.2s ease; padding: 0; } .user-avatar-btn:hover { background: var(--bg-tertiary); border-color: var(--accent-color); color: var(--accent-color); } .user-avatar-btn svg { stroke: currentColor; } .user-menu-dropdown { position: absolute; top: calc(100% + 8px); right: 0; min-width: 160px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); z-index: 1000; overflow: hidden; } .user-menu-item { display: flex; align-items: center; gap: 8px; padding: 12px 16px; cursor: pointer; color: var(--text-primary); font-size: 0.875rem; transition: all 0.2s ease; border: none; background: none; width: 100%; text-align: left; } .user-menu-item:hover { background: var(--bg-tertiary); color: var(--accent-color); } .user-menu-item svg { stroke: currentColor; flex-shrink: 0; } .attack-chain-btn:not(:disabled):hover { background: var(--bg-tertiary); border: none; color: var(--accent-color); transform: none; } .attack-chain-btn:disabled { opacity: 0.4; cursor: not-allowed; border: none; background: transparent; color: var(--text-muted); } .settings-btn { padding: 8px; min-width: 44px; } /* 设置页面样式 */ .settings-actions { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--border-color); display: flex; justify-content: flex-end; gap: 12px; } /* 旧侧边栏样式(保留用于对话页面内的历史对话侧边栏) */ .sidebar { width: 280px; background: var(--bg-secondary); border-right: 1px solid var(--border-color); display: flex; flex-direction: column; flex-shrink: 0; height: 100%; overflow: hidden; } .sidebar-header { padding: 16px; border-bottom: 1px solid var(--border-color); flex-shrink: 0; } .new-chat-btn { width: 100%; padding: 10px 16px; background: var(--accent-color); color: white; border: none; border-radius: 8px; font-size: 0.9375rem; font-weight: 500; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; justify-content: center; gap: 8px; } .new-chat-btn:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: var(--shadow-sm); } .new-chat-btn span { font-size: 1.2em; line-height: 1; } .sidebar-content { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 16px; min-height: 0; } .sidebar-title { font-size: 0.8125rem; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 12px; padding: 0 8px; } .conversation-search-box { position: relative; margin-bottom: 12px; } .conversation-search-box input { width: 100%; padding: 8px 32px 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; background: var(--bg-primary); color: var(--text-primary); transition: all 0.2s ease; } .conversation-search-box input:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1); } .conversation-search-box input::placeholder { color: var(--text-muted); } .conversation-search-clear { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; padding: 0; border: none; background: transparent; cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--text-muted); transition: color 0.2s ease; border-radius: 4px; } .conversation-search-clear:hover { color: var(--text-primary); background: var(--bg-tertiary); } .conversation-search-clear svg { width: 14px; height: 14px; } .conversations-list { display: flex; flex-direction: column; gap: 4px; } .conversation-group { display: flex; flex-direction: column; gap: 4px; margin-bottom: 14px; } .conversation-group:last-child { margin-bottom: 0; } .conversation-group-title { font-size: 0.75rem; color: var(--text-muted); font-weight: 600; letter-spacing: 0.5px; padding: 8px 8px 0; } .conversation-item { padding: 12px; border-radius: 8px; cursor: pointer; transition: all 0.2s; border: 1px solid transparent; display: flex; align-items: center; justify-content: space-between; gap: 8px; position: relative; user-select: none; -webkit-user-select: none; } .conversation-item:hover { background: var(--bg-tertiary); } .conversation-item:hover .conversation-delete-btn { opacity: 1; } .conversation-item.active { background: var(--bg-primary); border-color: var(--accent-color); } .conversation-content { flex: 1; min-width: 0; overflow: hidden; } .conversation-title { font-size: 0.875rem; font-weight: 500; color: var(--text-primary); margin-bottom: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .conversation-time { font-size: 0.75rem; color: var(--text-muted); } .conversation-group-tag { display: inline-flex; align-items: center; gap: 4px; margin-top: 4px; padding: 2px 6px; background: rgba(0, 102, 255, 0.08); border: 1px solid rgba(0, 102, 255, 0.2); border-radius: 4px; font-size: 0.7rem; color: var(--accent-color); line-height: 1.2; } .group-tag-icon { font-size: 0.75rem; line-height: 1; } .group-tag-name { font-weight: 500; } .conversation-delete-btn { width: 28px; height: 28px; border: none; background: transparent; color: var(--text-muted); cursor: pointer; border-radius: 6px; display: flex; align-items: center; justify-content: center; padding: 0; opacity: 0; transition: all 0.2s ease; flex-shrink: 0; position: relative; } .conversation-delete-btn svg { width: 14px; height: 14px; transition: all 0.2s ease; } .conversation-delete-btn:hover { background: rgba(220, 53, 69, 0.1); color: var(--error-color); opacity: 1; } .conversation-delete-btn:hover svg { transform: scale(1.1); } .conversation-delete-btn:active { background: rgba(220, 53, 69, 0.2); transform: scale(0.95); } .conversation-item.active .conversation-delete-btn { opacity: 0.6; } .conversation-item.active:hover .conversation-delete-btn { opacity: 1; } /* 对话界面样式 */ .chat-container { display: flex; flex-direction: column; flex: 1; min-width: 0; background: #f5f7fa; overflow: hidden; height: 100%; } /* 会话顶部栏样式 */ .conversation-header { background: transparent; padding: 8px 24px; flex-shrink: 0; border-bottom: none; } .conversation-header-content { display: flex; align-items: center; justify-content: flex-start; gap: 8px; } .chat-messages { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 24px; background: #f5f7fa; display: flex; flex-direction: column; min-height: 0; } .message { margin-bottom: 24px; display: flex; align-items: flex-start; gap: 12px; animation: fadeIn 0.3s ease-in; width: 100%; } @keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } } .message.user { flex-direction: row-reverse; justify-content: flex-end; } .message.system { justify-content: center; margin-bottom: 16px; } .message-avatar { width: 32px; height: 32px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 600; flex-shrink: 0; } .message.user .message-avatar { background: var(--accent-color); color: white; } .message.assistant .message-avatar { background: var(--bg-tertiary); color: var(--text-secondary); border: 1px solid var(--border-color); } .message.system .message-avatar { display: none; } .message-content { flex: 0 1 auto; max-width: 70%; min-width: 120px; display: flex; flex-direction: column; overflow-x: visible; overflow-y: visible; width: 100%; } .message.user .message-content { align-items: flex-end; margin-left: auto; } .message.assistant .message-content { align-items: flex-start; margin-right: auto; min-width: 0; } .message.system .message-content { max-width: 75%; align-items: stretch; margin: 0; } .message-bubble { padding: 12px 16px; border-radius: 8px; word-wrap: break-word; word-break: break-word; line-height: 1.6; box-shadow: var(--shadow-sm); overflow-x: auto; overflow-y: visible; max-width: 100%; -webkit-overflow-scrolling: touch; position: relative; } /* Markdown 样式 */ .message-bubble p { margin: 0.5em 0; } .message-bubble p:first-child { margin-top: 0; } .message-bubble p:last-child { margin-bottom: 0; } .message-bubble strong, .message-bubble b { font-weight: 600; color: inherit; } .message-bubble em, .message-bubble i { font-style: italic; } .message-bubble code { background: rgba(0, 0, 0, 0.05); padding: 2px 6px; border-radius: 3px; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; font-size: 0.9em; } .message.user .message-bubble code { background: rgba(255, 255, 255, 0.2); } .message-bubble pre { background: rgba(0, 0, 0, 0.05); padding: 12px; border-radius: 6px; overflow-x: auto; margin: 0.5em 0; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; font-size: 0.875em; line-height: 1.5; } .message.user .message-bubble pre { background: rgba(255, 255, 255, 0.15); } .message-bubble pre code { background: none; padding: 0; } .message-bubble ul, .message-bubble ol { margin: 0.5em 0; padding-left: 1.5em; } .message-bubble li { margin: 0.25em 0; } .message-bubble blockquote { border-left: 3px solid var(--border-color); padding-left: 1em; margin: 0.5em 0; color: var(--text-secondary); } .message-bubble h1, .message-bubble h2, .message-bubble h3, .message-bubble h4, .message-bubble h5, .message-bubble h6 { margin: 0.8em 0 0.4em 0; font-weight: 600; line-height: 1.3; } .message-bubble h1:first-child, .message-bubble h2:first-child, .message-bubble h3:first-child, .message-bubble h4:first-child, .message-bubble h5:first-child, .message-bubble h6:first-child { margin-top: 0; } .message-bubble h1 { font-size: 1.5em; } .message-bubble h2 { font-size: 1.3em; } .message-bubble h3 { font-size: 1.1em; } .message-bubble hr { border: none; border-top: 1px solid var(--border-color); margin: 1em 0; } .message-bubble a { color: var(--accent-color); text-decoration: none; } .message-bubble a:hover { text-decoration: underline; } .message.user .message-bubble a { color: rgba(255, 255, 255, 0.9); text-decoration: underline; } /* Markdown 表格样式 */ /* 表格包装容器,为每个表格提供独立的横向滚动 */ .message-bubble .table-wrapper { width: 100%; overflow-x: auto; overflow-y: visible; margin: 1em 0; -webkit-overflow-scrolling: touch; /* 自定义滚动条样式 */ scrollbar-width: thin; scrollbar-color: rgba(0, 0, 0, 0.2) transparent; } .message-bubble .table-wrapper::-webkit-scrollbar { height: 8px; } .message-bubble .table-wrapper::-webkit-scrollbar-track { background: transparent; border-radius: 4px; } .message-bubble .table-wrapper::-webkit-scrollbar-thumb { background: rgba(0, 0, 0, 0.2); border-radius: 4px; } .message-bubble .table-wrapper::-webkit-scrollbar-thumb:hover { background: rgba(0, 0, 0, 0.3); } /* 表格本身,允许根据内容自动扩展宽度 */ .message-bubble table { width: auto; min-width: 100%; border-collapse: collapse; margin: 0; font-size: 0.9em; display: table; table-layout: auto; } /* 确保表格能够超出容器宽度 */ .message-bubble table * { box-sizing: border-box; } /* 确保表格内容不会被压缩 */ .message-bubble table colgroup, .message-bubble table col { width: auto; } .message-bubble table thead { background: var(--bg-secondary); } .message-bubble table th { padding: 10px 12px; text-align: left; font-weight: 600; color: var(--text-primary); border-bottom: 2px solid var(--border-color); white-space: nowrap; min-width: fit-content; } .message-bubble table td { padding: 10px 12px; border-bottom: 1px solid var(--border-color); color: var(--text-primary); width: auto; min-width: 120px; max-width: none; vertical-align: top; /* 允许文字换行,避免重叠和溢出 */ white-space: normal; word-wrap: break-word; word-break: break-word; overflow-wrap: break-word; hyphens: auto; line-height: 1.5; } .message-bubble table tbody tr:hover { background: var(--bg-secondary); } .message-bubble table tbody tr:last-child td { border-bottom: none; } /* 消息气泡相对定位,用于放置复制按钮 */ .message-bubble { position: relative; } /* 消息复制按钮 - 位于消息气泡右下角 */ .message-copy-btn { position: absolute; bottom: 12px; right: 12px; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 14px; background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(8px); border: 1px solid rgba(0, 0, 0, 0.08); border-radius: 20px; color: #666; font-size: 0.8125rem; cursor: pointer; transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04); z-index: 10; opacity: 0; transform: translateY(4px); font-weight: 500; } .message-bubble:hover .message-copy-btn { opacity: 1; transform: translateY(0); } .message-copy-btn:hover { background: rgba(255, 255, 255, 1); border-color: rgba(0, 102, 255, 0.2); color: #0066ff; box-shadow: 0 4px 12px rgba(0, 102, 255, 0.15), 0 2px 4px rgba(0, 0, 0, 0.08); transform: translateY(-1px); } .message-copy-btn:active { transform: translateY(0) scale(0.98); box-shadow: 0 2px 6px rgba(0, 102, 255, 0.12), 0 1px 2px rgba(0, 0, 0, 0.06); } .message-copy-btn svg { width: 16px; height: 16px; flex-shrink: 0; transition: transform 0.2s ease; } .message-copy-btn:hover svg { transform: scale(1.1); } .message-copy-btn span { font-weight: 500; letter-spacing: 0.01em; } /* 用户消息中的表格样式 */ .message.user .message-bubble .table-wrapper { scrollbar-color: rgba(255, 255, 255, 0.3) transparent; } .message.user .message-bubble .table-wrapper::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.3); } .message.user .message-bubble .table-wrapper::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.4); } .message.user .message-bubble table { color: rgba(255, 255, 255, 0.95); } .message.user .message-bubble table thead { background: rgba(255, 255, 255, 0.15); } .message.user .message-bubble table th { color: rgba(255, 255, 255, 0.95); border-bottom-color: rgba(255, 255, 255, 0.3); } .message.user .message-bubble table td { color: rgba(255, 255, 255, 0.9); border-bottom-color: rgba(255, 255, 255, 0.2); } .message.user .message-bubble table tbody tr:hover { background: rgba(255, 255, 255, 0.1); } .message.user .message-bubble { background: var(--accent-color); color: white; border-bottom-right-radius: 8px; border-top-right-radius: 2px; } .message.assistant .message-bubble { background: var(--bg-primary); color: var(--text-primary); border: 1px solid var(--border-color); border-bottom-left-radius: 8px; border-top-left-radius: 2px; } .message.assistant .message-bubble pre { margin: 0; white-space: pre-wrap; word-wrap: break-word; font-family: inherit; } .message.system .message-bubble { background: var(--bg-tertiary); color: var(--text-secondary); border: 1px solid var(--border-color); text-align: left; font-size: 0.875rem; padding: 10px 16px; width: 100%; } .message-time { font-size: 0.6875rem; color: var(--text-muted); margin-top: 4px; padding: 0 2px; font-weight: 400; } /* MCP调用区域 */ .mcp-call-section { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border-color); width: 100%; } .mcp-call-label { font-size: 0.75rem; color: var(--text-secondary); margin-bottom: 8px; display: flex; align-items: center; gap: 6px; font-weight: 500; } .mcp-call-label::before { content: ''; width: 4px; height: 4px; background: var(--accent-color); border-radius: 50%; display: inline-block; flex-shrink: 0; } .mcp-call-buttons { display: flex; flex-wrap: wrap; gap: 6px; } .process-detail-btn { background: rgba(156, 39, 176, 0.1) !important; border-color: rgba(156, 39, 176, 0.3) !important; color: #9c27b0 !important; display: inline-flex; align-items: center; gap: 6px; } .process-detail-btn:hover { background: rgba(156, 39, 176, 0.2) !important; border-color: #9c27b0 !important; color: #7b1fa2 !important; } .process-detail-btn span { display: inline-flex; align-items: center; gap: 4px; } .process-details-container { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border-color); width: 100%; } .process-details-content { width: 100%; } .process-details-content .progress-timeline { max-height: 0; overflow: hidden; transition: max-height 0.3s ease; opacity: 0; } .process-details-content .progress-timeline.expanded { max-height: 2000px; overflow-y: auto; opacity: 1; margin-top: 12px; } .chat-input-container { display: flex; flex-direction: row; gap: 8px; align-items: flex-end; padding: 12px 16px; background: var(--bg-primary); border-top: 1px solid rgba(0, 0, 0, 0.06); flex-shrink: 0; width: 100%; box-sizing: border-box; } .chat-input-container > .chat-input-with-files { flex: 1; display: flex; flex-direction: column; min-width: 0; gap: 6px; } .chat-input-container > .chat-input-field { flex: 1; display: flex; min-width: 0; } .chat-file-list { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; min-height: 0; } .chat-file-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; background: rgba(0, 102, 255, 0.08); border: 1px solid rgba(0, 102, 255, 0.2); border-radius: 8px; font-size: 12px; color: var(--text-primary); max-width: 200px; } .chat-file-chip-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .chat-file-chip-remove { flex-shrink: 0; width: 18px; height: 18px; padding: 0; border: none; background: rgba(0, 0, 0, 0.08); border-radius: 50%; cursor: pointer; color: var(--text-muted); display: flex; align-items: center; justify-content: center; transition: background 0.2s, color 0.2s; } .chat-file-chip-remove:hover { background: rgba(0, 0, 0, 0.12); color: var(--text-primary); } .chat-file-input-hidden { position: absolute; width: 0; height: 0; opacity: 0; overflow: hidden; pointer-events: none; } .chat-upload-btn { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; padding: 0; border: 1px solid rgba(0, 0, 0, 0.1); border-radius: 12px; background: #ffffff; color: var(--text-muted); cursor: pointer; transition: border-color 0.2s, color 0.2s, background 0.2s; flex-shrink: 0; } .chat-upload-btn:hover { border-color: var(--accent-color); color: var(--accent-color); background: rgba(0, 102, 255, 0.04); } .chat-input-container.drag-over { background: rgba(0, 102, 255, 0.06); border-radius: 12px; outline: 2px dashed rgba(0, 102, 255, 0.35); outline-offset: -2px; } .chat-input-field { flex: 1; position: relative; display: flex; } .chat-input-field textarea { width: 100%; } .chat-input-container textarea { flex: 1; min-width: 0; padding: 10px 14px; border: 1px solid rgba(0, 0, 0, 0.1); border-radius: 12px; font-size: 0.9375rem; outline: none; transition: all 0.2s; background: #ffffff; color: var(--text-primary); resize: none; height: 40px; min-height: 40px; max-height: 120px; font-family: inherit; line-height: 1.4; overflow-y: auto; box-sizing: border-box; vertical-align: middle; /* 隐藏滚动条但保留滚动功能 */ scrollbar-width: thin; /* Firefox */ scrollbar-color: transparent transparent; /* Firefox - 隐藏滚动条 */ } /* WebKit 浏览器(Chrome, Safari, Edge)的滚动条样式 - 隐藏但保留功能 */ .chat-input-container textarea::-webkit-scrollbar { width: 4px; /* 最窄的滚动条 */ } .chat-input-container textarea::-webkit-scrollbar-track { background: transparent; /* 隐藏轨道 */ } .chat-input-container textarea::-webkit-scrollbar-thumb { background: transparent; /* 默认隐藏滑块 */ border-radius: 2px; } /* 鼠标悬停时显示滚动条 */ .chat-input-container textarea:hover::-webkit-scrollbar-thumb { background: var(--text-muted); /* 悬停时显示 */ } .chat-input-container textarea:focus::-webkit-scrollbar-thumb { background: var(--text-muted); /* 聚焦时显示 */ } .chat-input-container textarea:focus { border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.08); background: #ffffff; } .chat-input-container textarea::placeholder { color: var(--text-muted); } .chat-input-container .send-btn { display: flex; align-items: center; justify-content: center; gap: 6px; padding: 10px 20px; height: 40px; background: linear-gradient(135deg, var(--accent-color) 0%, #0052cc 100%); color: white; border: none; border-radius: 12px; cursor: pointer; font-size: 0.9375rem; font-weight: 600; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); white-space: nowrap; flex-shrink: 0; box-sizing: border-box; position: relative; overflow: hidden; box-shadow: 0 2px 8px rgba(0, 102, 255, 0.2), 0 1px 3px rgba(0, 0, 0, 0.1); } /* 按钮光效动画 */ .chat-input-container .send-btn::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent); transition: left 0.5s; } .chat-input-container .send-btn:hover::before { left: 100%; } .chat-input-container .send-btn:hover { background: linear-gradient(135deg, #0052cc 0%, var(--accent-color) 100%); transform: translateY(-2px) scale(1.02); box-shadow: 0 4px 12px rgba(0, 102, 255, 0.35), 0 2px 6px rgba(0, 0, 0, 0.15); } .chat-input-container .send-btn:active { transform: translateY(0) scale(0.98); box-shadow: 0 2px 6px rgba(0, 102, 255, 0.25), 0 1px 3px rgba(0, 0, 0, 0.1); transition: all 0.1s; } .chat-input-container .send-btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; } .chat-input-container .send-btn svg { flex-shrink: 0; transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1); } .chat-input-container .send-btn:hover svg { transform: translateX(2px); } .chat-input-container .send-btn:active svg { transform: translateX(4px); } .chat-input-container .send-btn span { position: relative; z-index: 1; } .mention-suggestions { position: absolute; bottom: calc(100% + 8px); left: 0; right: 0; background: #ffffff; border: 1px solid rgba(15, 23, 42, 0.08); border-radius: 16px; box-shadow: 0 20px 45px rgba(15, 23, 42, 0.18); padding: 0; overflow: hidden; display: none; z-index: 15; backdrop-filter: blur(6px); animation: mentionFadeIn 0.15s ease-out; box-sizing: border-box; } .mention-suggestions-list { max-height: 320px; overflow-y: auto; padding: 12px; box-sizing: border-box; } @keyframes mentionFadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } } .mention-item { display: flex; flex-direction: column; gap: 6px; padding: 12px 18px; width: 100%; border: 1px solid rgba(15, 23, 42, 0.05); background: #f7f8fa !important; cursor: pointer; text-align: left; font-size: 0.875rem; color: rgba(15, 23, 42, 0.9) !important; transition: background 0.18s ease, border-left-color 0.18s ease, color 0.15s ease, transform 0.18s ease; border-left: 3px solid transparent; outline: none; border-radius: 12px; margin: 0 0 8px 0; box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08); -webkit-appearance: none; appearance: none; } .mention-item:focus, .mention-item:focus-visible { outline: none; box-shadow: none; } .mention-item:hover { background: #ffffff !important; border-left-color: rgba(0, 0, 0, 0.18); transform: translateY(-1px); box-shadow: 0 6px 18px rgba(15, 23, 42, 0.12); } .mention-item.active, .mention-item:focus, .mention-item:focus-visible { background: linear-gradient(105deg, rgba(0, 102, 255, 0.08), rgba(0, 102, 255, 0.02)) !important; border-left-color: rgba(0, 102, 255, 0.6); transform: translateY(-2px); box-shadow: 0 10px 26px rgba(0, 102, 255, 0.22); color: rgba(15, 23, 42, 0.95); } .mention-item.active .mention-item-name, .mention-item.active .mention-item-desc, .mention-item.active .mention-item-meta, .mention-item.active .mention-status { color: rgba(15, 23, 42, 0.95); } .mention-item.active .mention-status { background: rgba(0, 102, 255, 0.12); color: #0052cc; } .mention-item.disabled { opacity: 0.65; box-shadow: none; } .mention-item-name { font-weight: 600; display: flex; align-items: center; gap: 8px; color: rgba(15, 23, 42, 0.95); } .mention-item-icon { font-size: 1rem; } .mention-item-text { flex: 1; } .mention-item-desc { font-size: 0.78rem; color: var(--text-muted); line-height: 1.4; word-break: break-word; } .mention-item-meta { display: flex; flex-wrap: wrap; gap: 8px; font-size: 0.75rem; } .mention-status { padding: 2px 8px; border-radius: 999px; font-weight: 600; } .mention-status.enabled { background: rgba(46, 204, 113, 0.18); color: #1e8a4d; } .mention-status.disabled { background: rgba(231, 76, 60, 0.18); color: #b23d2f; } .mention-origin { color: var(--text-secondary); } .mention-item-badge { font-size: 0.68rem; padding: 2px 8px; border-radius: 999px; background: rgba(0, 0, 0, 0.06); color: var(--text-primary); font-weight: 600; } .mention-item-badge.internal { background: rgba(108, 117, 125, 0.18); color: rgba(33, 37, 41, 0.9); } .mention-empty { padding: 10px 18px; font-size: 0.78rem; color: var(--text-muted); } /* MCP调用详情按钮 */ .mcp-detail-btn { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; background: var(--bg-primary); color: var(--accent-color); border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.8125rem; font-weight: 500; cursor: pointer; transition: all 0.2s; } .mcp-detail-btn:hover { background: var(--accent-color); color: white; border-color: var(--accent-color); transform: translateY(-1px); box-shadow: var(--shadow-sm); } .mcp-detail-btn:active { transform: translateY(0); } /* 登录遮罩 */ .login-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.5); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); display: none; align-items: center; justify-content: center; z-index: 1200; padding: 24px; animation: loginOverlayIn 0.3s ease-out; } @keyframes loginOverlayIn { from { opacity: 0; } to { opacity: 1; } } @keyframes loginCardIn { from { opacity: 0; transform: scale(0.96) translateY(-12px); } to { opacity: 1; transform: scale(1) translateY(0); } } .login-card { width: 100%; max-width: 400px; background: var(--bg-primary); border-radius: 16px; padding: 0; box-shadow: 0 24px 48px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.04); border: 1px solid var(--border-color); display: flex; flex-direction: column; gap: 0; overflow: hidden; animation: loginCardIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); } .login-brand { padding: 32px 28px 24px; text-align: center; background: linear-gradient(180deg, rgba(0, 102, 255, 0.06) 0%, transparent 100%); border-bottom: 1px solid var(--border-color); } .login-brand h2 { margin: 0; font-size: 1.375rem; font-weight: 600; color: var(--text-primary); letter-spacing: -0.02em; } .login-subtitle { margin: 8px 0 0 0; font-size: 0.875rem; color: var(--text-secondary); } .login-form { display: flex; flex-direction: column; gap: 16px; padding: 24px 28px 28px; } .login-form .form-group { margin-bottom: 0; } .login-form .form-group label { display: block; margin-bottom: 8px; font-size: 0.8125rem; font-weight: 500; color: var(--text-secondary); } .login-form input[type="password"] { width: 100%; padding: 12px 14px; font-size: 0.9375rem; border: 1px solid var(--border-color); border-radius: 10px; background: var(--bg-primary); color: var(--text-primary); transition: border-color 0.2s, box-shadow 0.2s; } .login-form input[type="password"]::placeholder { color: var(--text-muted); } .login-form input[type="password"]:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.15); } .login-error { color: var(--error-color); background: rgba(220, 53, 69, 0.08); border: 1px solid rgba(220, 53, 69, 0.3); border-radius: 8px; padding: 10px 12px; font-size: 0.8125rem; } .login-card .login-submit { width: 100%; justify-content: center; display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; font-size: 0.9375rem; font-weight: 600; border-radius: 10px; background: linear-gradient(135deg, var(--accent-color) 0%, #0047ab 100%) !important; border: none !important; color: #fff !important; box-shadow: 0 4px 14px rgba(0, 102, 255, 0.4); transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s; } .login-card .login-submit:hover { box-shadow: 0 6px 20px rgba(0, 102, 255, 0.45); transform: translateY(-1px); background: linear-gradient(135deg, var(--accent-hover) 0%, #003d8a 100%) !important; } .login-card .login-submit:active { transform: translateY(0); box-shadow: 0 2px 10px rgba(0, 102, 255, 0.35); } .login-submit-arrow { transition: transform 0.2s ease; } .login-card .login-submit:hover .login-submit-arrow { transform: translateX(3px); } /* 模态框样式 */ .modal { display: none; position: fixed; z-index: 1000; left: 0; top: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.6); backdrop-filter: blur(4px); overflow: auto; animation: fadeIn 0.2s ease-in; } .modal-content { background-color: var(--bg-primary); margin: 5% auto; padding: 0; border-radius: 12px; width: 90%; max-width: 900px; max-height: 85vh; display: flex; flex-direction: column; box-shadow: var(--shadow-lg); border: 1px solid var(--border-color); animation: slideDown 0.3s ease-out; overflow: hidden; } @keyframes slideDown { from { opacity: 0; transform: translateY(-20px); } to { opacity: 1; transform: translateY(0); } } .modal-header { display: flex; justify-content: space-between; align-items: center; padding: 24px 28px; border-bottom: 1px solid var(--border-color); background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%); border-top-left-radius: 16px; border-top-right-radius: 16px; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04); } .modal-header h2 { margin: 0; font-size: 1.5rem; font-weight: 600; color: var(--text-primary); background: linear-gradient(135deg, var(--accent-color) 0%, #0052cc 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; /* 允许标题在 flex 中收缩/换行,避免把右侧按钮挤压变形 */ flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; } .modal-close { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; border-radius: 10px; cursor: pointer; color: var(--text-secondary); font-size: 1.5rem; line-height: 1; transition: all 0.25s ease; border: 2px solid transparent; background: transparent; font-weight: 300; } .modal-close:hover { background: linear-gradient(135deg, rgba(220, 53, 69, 0.1) 0%, rgba(220, 53, 69, 0.05) 100%); color: #dc3545; border-color: rgba(220, 53, 69, 0.2); transform: scale(1.1); } .modal-body { padding: 24px; overflow-y: auto; flex: 1; } .detail-section { margin-bottom: 20px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 14px; padding: 20px; box-shadow: var(--shadow-sm); } .detail-section:last-child { margin-bottom: 0; } .detail-section-overview { background: linear-gradient(135deg, rgba(0, 102, 255, 0.07), rgba(0, 102, 255, 0.02)); border-color: rgba(0, 102, 255, 0.2); } .detail-section-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; } .detail-section h3 { margin: 0; color: var(--text-primary); font-size: 1rem; font-weight: 600; letter-spacing: 0.5px; } .detail-info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; } .detail-info-grid .detail-item { background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 12px; padding: 12px 14px; box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.02); } .detail-item { display: flex; flex-direction: column; gap: 6px; margin: 0; } .detail-item strong { color: var(--text-secondary); font-weight: 600; font-size: 0.75rem; letter-spacing: 0.5px; text-transform: uppercase; } .detail-item span { color: var(--text-primary); font-size: 0.95rem; font-weight: 600; word-break: break-word; } .mono-text { font-family: 'SF Mono', 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', monospace; font-size: 0.85rem; color: var(--text-secondary); } .status-chip { display: inline-flex; align-items: center; justify-content: center; padding: 4px 12px; border-radius: 999px; font-size: 0.8125rem; font-weight: 600; background: var(--bg-tertiary); color: var(--text-secondary); border: 1px solid transparent; text-transform: none; } .status-chip.status-running { background: rgba(0, 102, 255, 0.12); color: var(--accent-color); border-color: rgba(0, 102, 255, 0.3); } .status-chip.status-completed { background: rgba(40, 167, 69, 0.12); color: var(--success-color); border-color: rgba(40, 167, 69, 0.3); } .status-chip.status-failed { background: rgba(220, 53, 69, 0.12); color: var(--error-color); border-color: rgba(220, 53, 69, 0.3); } .status-chip.status-pending, .status-chip.status-unknown { background: rgba(255, 193, 7, 0.12); color: #b8860b; border-color: rgba(255, 193, 7, 0.3); } .detail-code-card { background: var(--bg-secondary); border: 1px dashed rgba(0, 0, 0, 0.06); border-radius: 12px; padding: 12px; } .detail-code-card .code-block { margin: 0; max-height: 360px; } .detail-error-wrapper { border-color: rgba(220, 53, 69, 0.4); background: rgba(220, 53, 69, 0.05); } .detail-success-wrapper { border-color: rgba(40, 167, 69, 0.4); background: rgba(40, 167, 69, 0.03); } .code-block { background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 8px; padding: 16px; font-family: 'SF Mono', 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', monospace; font-size: 0.8125rem; line-height: 1.6; overflow-x: auto; white-space: pre-wrap; word-wrap: break-word; max-height: 400px; overflow-y: auto; color: var(--text-primary); } .code-block.error { background: #fff5f5; border-color: var(--error-color); color: var(--error-color); } .code-block.success { background: rgba(40, 167, 69, 0.05); border-color: var(--success-color); } .btn-ghost { padding: 6px 14px; border-radius: 999px; background: transparent; border: 1px solid transparent; color: var(--accent-color); font-size: 0.8125rem; font-weight: 500; cursor: pointer; transition: all 0.2s ease; } .btn-ghost:hover { background: rgba(0, 102, 255, 0.08); border-color: rgba(0, 102, 255, 0.2); color: var(--accent-hover); } /* 滚动条样式 */ ::-webkit-scrollbar { width: 8px; height: 8px; } ::-webkit-scrollbar-track { background: var(--bg-secondary); border-radius: 4px; } ::-webkit-scrollbar-thumb { background: var(--text-muted); border-radius: 4px; } ::-webkit-scrollbar-thumb:hover { background: var(--text-secondary); } /* 响应式设计 */ @media (max-width: 768px) { body { height: 100vh; overflow: hidden; } .container { border-radius: 0; height: 100vh; overflow: hidden; } header { padding: 10px 20px; flex-shrink: 0; } .logo h1 { font-size: 1.25rem; } .header-subtitle { display: none; } .main-layout { overflow: hidden; min-height: 0; } /* 主侧边栏在移动设备上可以折叠或调整 */ .main-sidebar { width: 200px; } .main-sidebar.collapsed { width: 64px; } .sidebar-collapse-btn { width: 28px; height: 28px; } .main-sidebar-header .logo span { font-size: 1rem; } .nav-item-content { padding: 10px 12px; font-size: 0.875rem; } .nav-item-content span { font-size: 0.875rem; } .conversation-sidebar, .sidebar { width: 240px; height: 100%; overflow: hidden; } .sidebar-content { min-height: 0; } .chat-container { height: 100%; overflow: hidden; } .chat-messages { padding: 16px; min-height: 0; } .message-content { max-width: 85%; } .chat-input-container { padding: 16px; flex-shrink: 0; } .page-header { padding: 16px; flex-wrap: wrap; } .page-header h2 { font-size: 1.25rem; } .page-content { padding: 16px; } .modal-content { width: 95%; margin: 10% auto; } } /* 进度展示样式 */ .progress-container { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; padding: 16px; max-width: 100%; } .progress-container.completed { background: var(--bg-secondary); border-color: var(--border-color); opacity: 0.95; } .progress-details { margin-top: 8px; margin-bottom: 24px; } .progress-timeline-empty { padding: 12px; text-align: center; color: var(--text-muted); font-size: 0.875rem; } .progress-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; padding-bottom: 12px; border-bottom: 1px solid var(--border-color); } .progress-actions { display: flex; align-items: center; gap: 8px; } .progress-title { font-weight: 600; color: var(--text-primary); font-size: 0.9375rem; } .progress-stop { padding: 4px 12px; background: rgba(220, 53, 69, 0.1); border: 1px solid rgba(220, 53, 69, 0.4); border-radius: 4px; font-size: 0.8125rem; color: var(--error-color); cursor: pointer; transition: all 0.2s; } .progress-stop:hover { background: rgba(220, 53, 69, 0.15); border-color: var(--error-color); } .progress-stop:disabled { opacity: 0.6; cursor: not-allowed; } .progress-toggle { padding: 4px 12px; background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 4px; font-size: 0.8125rem; color: var(--text-secondary); cursor: pointer; transition: all 0.2s; } .progress-toggle:hover { background: var(--bg-secondary); color: var(--text-primary); } .progress-timeline { max-height: 0; overflow: hidden; transition: max-height 0.3s ease; } .progress-timeline.expanded { max-height: 2000px; overflow-y: auto; } .timeline-item { padding: 12px; margin-bottom: 8px; border-left: 3px solid var(--border-color); padding-left: 16px; background: var(--bg-secondary); border-radius: 4px; transition: all 0.2s; } .timeline-item:hover { background: var(--bg-tertiary); } .timeline-item-iteration { border-left-color: var(--accent-color); background: rgba(0, 102, 255, 0.05); } .timeline-item-thinking { border-left-color: #9c27b0; background: rgba(156, 39, 176, 0.05); } .timeline-item-tool_call { border-left-color: #ff9800; background: rgba(255, 152, 0, 0.05); } .timeline-item-tool_result { border-left-color: var(--success-color); background: rgba(40, 167, 69, 0.05); } .timeline-item-tool_result.error { border-left-color: var(--error-color); background: rgba(220, 53, 69, 0.05); } .timeline-item-error { border-left-color: var(--error-color); background: rgba(220, 53, 69, 0.1); } .timeline-item-cancelled { border-left-color: #ff7043; background: rgba(255, 112, 67, 0.12); } .timeline-item-header { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; } .timeline-item-time { font-size: 0.75rem; color: var(--text-muted); font-family: monospace; min-width: 70px; } .timeline-item-title { font-weight: 500; color: var(--text-primary); font-size: 0.875rem; flex: 1; } .timeline-item-content { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border-color); font-size: 0.875rem; color: var(--text-secondary); line-height: 1.6; } .tool-details { display: flex; flex-direction: column; gap: 12px; } .tool-arg-section { display: flex; flex-direction: column; gap: 8px; } .tool-arg-section strong { color: var(--text-primary); font-size: 0.8125rem; } .tool-args { background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 4px; padding: 12px; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; font-size: 0.8125rem; line-height: 1.5; overflow-x: auto; margin: 0; color: var(--text-primary); } .tool-result-section { display: flex; flex-direction: column; gap: 8px; } .tool-result-section strong { color: var(--text-primary); font-size: 0.8125rem; } .tool-result { background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 4px; padding: 12px; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; font-size: 0.8125rem; line-height: 1.5; overflow-x: auto; max-height: 400px; overflow-y: auto; margin: 0; white-space: pre-wrap; word-wrap: break-word; color: var(--text-primary); } .tool-result-section.error .tool-result { background: rgba(220, 53, 69, 0.1); border-color: var(--error-color); color: var(--error-color); } .tool-result-section.success .tool-result { background: rgba(40, 167, 69, 0.1); border-color: var(--success-color); } .tool-execution-id { margin-top: 8px; font-size: 0.75rem; color: var(--text-muted); } .tool-execution-id code { background: var(--bg-tertiary); padding: 2px 6px; border-radius: 3px; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; color: var(--text-secondary); } /* 工具调用状态徽章 */ .tool-status-badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 12px; font-size: 0.75rem; font-weight: 600; margin-left: 8px; white-space: nowrap; vertical-align: middle; } .tool-status-badge.tool-status-running { background: rgba(0, 102, 255, 0.12); color: var(--accent-color); border: 1px solid rgba(0, 102, 255, 0.3); } .tool-status-badge.tool-status-running::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--accent-color); display: inline-block; animation: tool-running-pulse 1.5s infinite; } @keyframes tool-running-pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(0.8); } } .tool-status-badge.tool-status-completed { background: rgba(40, 167, 69, 0.12); color: var(--success-color); border: 1px solid rgba(40, 167, 69, 0.3); } .tool-status-badge.tool-status-failed { background: rgba(220, 53, 69, 0.12); color: var(--error-color); border: 1px solid rgba(220, 53, 69, 0.3); } /* 工具调用项状态样式 */ .timeline-item-tool_call.tool-call-running { border-left-color: var(--accent-color); background: rgba(0, 102, 255, 0.08); } .timeline-item-tool_call.tool-call-completed { border-left-color: var(--success-color); background: rgba(40, 167, 69, 0.08); } .timeline-item-tool_call.tool-call-failed { border-left-color: var(--error-color); background: rgba(220, 53, 69, 0.08); } /* 活跃任务栏 */ .active-tasks-bar { display: none; align-items: center; gap: 12px; padding: 10px 16px; margin: 12px 0; background: var(--bg-primary); border: 1px solid rgba(0, 102, 255, 0.15); border-radius: 10px; box-shadow: var(--shadow-sm); color: var(--text-primary); flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden; } .active-task-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--bg-primary); border: 1px solid rgba(0, 102, 255, 0.2); border-radius: 8px; padding: 8px 12px; flex-shrink: 0; min-width: 280px; box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.03); } .active-task-info { display: flex; align-items: center; gap: 6px; min-width: 0; flex-wrap: wrap; } .active-task-status { background: rgba(0, 102, 255, 0.12); color: var(--accent-color); padding: 2px 8px; border-radius: 999px; font-size: 0.75rem; font-weight: 600; flex-shrink: 0; } .active-task-message { font-size: 0.85rem; color: var(--text-primary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 320px; } .active-task-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; } .active-task-time { font-size: 0.75rem; color: var(--text-muted); } .active-task-cancel { padding: 6px 12px; background: rgba(220, 53, 69, 0.1); border: 1px solid rgba(220, 53, 69, 0.4); border-radius: 6px; color: var(--error-color); font-size: 0.8125rem; cursor: pointer; transition: all 0.2s; } .active-task-cancel:hover { background: rgba(220, 53, 69, 0.2); border-color: var(--error-color); } .active-task-cancel:disabled { opacity: 0.6; cursor: not-allowed; } .active-task-error { font-size: 0.875rem; color: var(--error-color); } /* 设置模态框样式 */ .settings-modal-content { max-width: 800px; max-height: 90vh; display: flex; flex-direction: column; } .settings-body { overflow-y: auto; flex: 1; padding: 24px; } /* 设置页面布局 */ .settings-layout { display: flex; flex: 1; overflow: hidden; background: var(--bg-primary); } /* 设置侧边栏 */ .settings-sidebar { width: 200px; background: var(--bg-primary); border-right: 1px solid var(--border-color); flex-shrink: 0; padding: 0; } .settings-nav { display: flex; flex-direction: column; gap: 0; padding: 0; } .settings-nav-item { padding: 14px 20px; cursor: pointer; color: var(--text-primary); font-size: 0.9375rem; transition: all 0.2s ease; background: transparent; border-left: 3px solid transparent; position: relative; } .settings-nav-item:hover { background: var(--bg-secondary); } .settings-nav-item.active { background: rgba(0, 102, 255, 0.08); color: var(--accent-color); font-weight: 500; border-left-color: var(--accent-color); } /* 设置内容区域 */ .settings-content { flex: 1; overflow-y: auto; padding: 24px 32px; background: var(--bg-primary); } .settings-section-content { display: none; } .settings-section-content.active { display: block; } .settings-section-header { margin-bottom: 32px; } .settings-section-header h3 { font-size: 1.5rem; font-weight: 600; color: var(--text-primary); margin: 0; } .settings-subsection { margin-bottom: 24px; padding: 0; } .settings-subsection h4 { font-size: 1rem; font-weight: 600; color: var(--text-primary); margin-bottom: 16px; } .settings-subsection-header { margin-top: 24px; margin-bottom: 16px; padding-top: 16px; border-top: 1px solid var(--border-color); } .settings-subsection-header h5 { font-size: 0.9375rem; font-weight: 600; color: var(--text-primary); margin-bottom: 12px; } .form-hint { display: block; font-size: 0.8125rem; color: var(--text-secondary); margin-top: 4px; line-height: 1.4; } .settings-description { font-size: 0.875rem; color: var(--text-secondary); margin-bottom: 24px; line-height: 1.6; } /* 系统设置 - 终端 */ .terminal-wrapper { border: 1px solid var(--border-color); border-radius: 6px; overflow: hidden; background: #0d1117; } .terminal-tabs { display: flex; align-items: center; flex-wrap: wrap; gap: 0; padding: 6px 10px 0; background: #161b22; border-bottom: 1px solid var(--border-color); min-height: 36px; } .terminal-tab { display: flex; align-items: center; gap: 6px; padding: 5px 8px 5px 12px; font-size: 0.8125rem; color: #8b949e; background: transparent; border: none; border-radius: 4px 4px 0 0; cursor: pointer; margin-right: 2px; } .terminal-tab-label { cursor: pointer; } .terminal-tab-close { padding: 0; width: 18px; height: 18px; font-size: 1.1rem; line-height: 1; color: #8b949e; background: transparent; border: none; border-radius: 4px; cursor: pointer; display: flex; align-items: center; justify-content: center; } .terminal-tab-close:hover { color: #ff7b72; background: rgba(255, 123, 114, 0.15); } .terminal-tab:hover { color: #e6edf3; background: rgba(255, 255, 255, 0.06); } .terminal-tab.active { color: #e6edf3; background: #0d1117; font-weight: 500; } .terminal-tab-new { margin-left: 4px; width: 28px; height: 28px; font-size: 1.125rem; line-height: 1; color: #8b949e; background: transparent; border: 1px solid transparent; border-radius: 6px; cursor: pointer; display: flex; align-items: center; justify-content: center; } .terminal-tab-new:hover { color: #58a6ff; background: rgba(88, 166, 255, 0.1); border-color: rgba(88, 166, 255, 0.3); } .terminal-toolbar { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; background: #161b22; border-bottom: 1px solid var(--border-color); } .terminal-toolbar-title { font-size: 0.8125rem; font-weight: 600; color: #8b949e; letter-spacing: 0.02em; } .terminal-btn { padding: 6px 12px; font-size: 0.8125rem; color: var(--text-secondary); background: transparent; border: 1px solid var(--border-color); border-radius: 6px; cursor: pointer; transition: color 0.15s, background 0.15s, border-color 0.15s; } .terminal-btn:hover { color: var(--text-primary); background: rgba(255, 255, 255, 0.06); border-color: #8b949e; } .terminal-panes { position: relative; min-height: 400px; } .terminal-pane { display: none; min-height: 400px; } .terminal-pane.active { display: block; } .terminal-container { min-height: 400px; padding: 8px; box-sizing: border-box; } .terminal-container .xterm { padding: 0; } .terminal-container .xterm-viewport { border-radius: 0; } .terminal-error { color: #ff7b72; padding: 16px; font-size: 0.875rem; } .settings-section { margin-bottom: 32px; } .settings-section:last-child { margin-bottom: 0; } .settings-section h3 { font-size: 1.125rem; font-weight: 600; color: var(--text-primary); margin-bottom: 16px; padding-bottom: 8px; border-bottom: 2px solid var(--border-color); } .settings-form { display: flex; flex-direction: column; gap: 16px; } .form-group { display: flex; flex-direction: column; gap: 6px; } .form-group label { font-size: 0.875rem; font-weight: 500; color: var(--text-primary); } .form-group input, .form-group select { padding: 10px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.9375rem; background: var(--bg-primary); color: var(--text-primary); transition: border-color 0.2s; font-family: inherit; width: 100%; box-sizing: border-box; } .form-group select { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 9L1 4h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; } .form-group input:focus, .form-group select:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1); } .form-group input:hover, .form-group select:hover { border-color: var(--accent-color); } .form-group input.error, .form-group select.error { border-color: var(--error-color); box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1); } .form-group input.error:focus, .form-group select.error:focus { border-color: var(--error-color); box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.2); } /* 现代化复选框样式 */ .checkbox-label { display: flex !important; align-items: center; gap: 12px; margin: 0; justify-content: flex-start; width: 100%; cursor: pointer; user-select: none; padding: 8px 0; transition: all 0.2s ease; } .checkbox-label:hover { opacity: 0.9; } .modern-checkbox { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; } .checkbox-custom { position: relative; width: 44px; height: 24px; background: var(--bg-tertiary); border: 2px solid var(--border-color); border-radius: 12px; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); flex-shrink: 0; box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1); } .checkbox-custom::before { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; background: white; border-radius: 50%; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); } .modern-checkbox:checked + .checkbox-custom { background: var(--accent-color); border-color: var(--accent-color); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.15), inset 0 2px 4px rgba(0, 0, 0, 0.1); } .modern-checkbox:checked + .checkbox-custom::before { transform: translateX(20px); box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25); } .modern-checkbox:focus + .checkbox-custom { outline: none; box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.2), inset 0 2px 4px rgba(0, 0, 0, 0.1); } .modern-checkbox:checked:focus + .checkbox-custom { box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.25), inset 0 2px 4px rgba(0, 0, 0, 0.1); } .checkbox-text { font-size: 0.9375rem; font-weight: 500; color: var(--text-primary); line-height: 1.5; transition: color 0.2s ease; } .checkbox-label:hover .checkbox-text { color: var(--accent-color); } .modern-checkbox:disabled + .checkbox-custom { opacity: 0.5; cursor: not-allowed; background: var(--bg-tertiary); } .modern-checkbox:disabled + .checkbox-custom + .checkbox-text { opacity: 0.5; cursor: not-allowed; } .form-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 4px; } .password-hint { font-size: 0.8125rem; color: var(--text-muted); margin-top: 8px; } .tools-controls { display: flex; flex-direction: column; gap: 12px; } .tools-actions { display: flex; gap: 8px; align-items: center; flex-wrap: nowrap; width: 100%; overflow: visible; } .tools-actions button { padding: 8px 16px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); color: var(--text-primary); font-size: 0.875rem; cursor: pointer; transition: all 0.2s; flex-shrink: 0; white-space: nowrap; } .tools-actions button:hover { background: var(--bg-tertiary); border-color: var(--accent-color); } .tools-actions input { flex: 1; padding: 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; background: var(--bg-primary); color: var(--text-primary); } .search-box { display: flex; gap: 4px; flex: 1; min-width: 150px; align-items: center; } .page-size-selector { display: flex; align-items: center; gap: 4px; flex-shrink: 0; white-space: nowrap; margin-right: 8px; } .page-size-selector label { font-size: 0.8125rem; color: var(--text-secondary); white-space: nowrap; margin-right: 4px; } .page-size-selector select { padding: 6px 10px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); color: var(--text-primary); font-size: 0.8125rem; cursor: pointer; transition: all 0.2s; min-width: 70px; height: 32px; } .page-size-selector select:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .page-size-selector select:hover { border-color: var(--accent-color); } .search-box input { flex: 1; padding: 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; background: var(--bg-primary); color: var(--text-primary); } .search-box input:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .btn-search { padding: 6px 12px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); color: var(--text-primary); font-size: 0.875rem; cursor: pointer; transition: all 0.2s; min-width: 40px; height: 32px; display: flex; align-items: center; justify-content: center; box-sizing: border-box; } .btn-search:hover { background: var(--accent-color); border-color: var(--accent-color); color: white; transform: translateY(-1px); box-shadow: var(--shadow-sm); } .tools-list { max-height: 400px; overflow-y: auto; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); padding: 8px; } .tool-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 6px; transition: background 0.2s; cursor: pointer; } .tool-item:hover { background: var(--bg-tertiary); } .tool-item input[type="checkbox"] { width: 18px; height: 18px; cursor: pointer; accent-color: var(--accent-color); } .tool-item-info { flex: 1; min-width: 0; } .tool-item-name { font-weight: 500; color: var(--text-primary); font-size: 0.9375rem; margin-bottom: 4px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; } .external-tool-badge { display: inline-flex; align-items: center; padding: 2px 8px; background: rgba(255, 152, 0, 0.12); border: 1px solid rgba(255, 152, 0, 0.3); border-radius: 12px; font-size: 0.75rem; font-weight: 600; color: #ff9800; white-space: nowrap; } .tool-item-desc { font-size: 0.8125rem; color: var(--text-secondary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .tool-item.hidden { display: none; } .tools-list-items { max-height: 400px; overflow-y: auto; } .tools-pagination, .monitor-pagination, .pagination { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-top: 1px solid var(--border-color); margin-top: 8px; background: var(--bg-primary); gap: 16px; flex-wrap: wrap; } .pagination-container { margin-top: 0; } /* 漏洞管理页面的分页栏间距优化 */ #vulnerability-pagination.pagination-fixed { margin-top: 12px; } /* Skills管理页面分页优化 */ .page-content-with-pagination { display: flex; flex-direction: column; height: 100%; position: relative; overflow: hidden; } .skills-list-with-pagination { flex: 1; overflow-y: auto; overflow-x: hidden; min-height: 0; /* 为分页组件预留空间,确保视觉连接自然 */ padding-bottom: 0; } .pagination-fixed { background: var(--bg-primary); margin-top: 0; padding: 0; /* 确保分页组件宽度与内容区域一致,不包括滚动条 */ width: 100%; box-sizing: border-box; /* 确保分页组件不延伸到滚动条区域 */ overflow: hidden; /* 当列表有滚动条时,分页组件应该与内容区域对齐 */ position: relative; /* 添加四个角的圆角,与上方卡片保持一致 */ border-radius: 8px; /* 确保底部左右角都是圆角 */ border-bottom-left-radius: 8px; border-bottom-right-radius: 8px; /* 添加边框和阴影,使圆角更明显 */ border: 1px solid var(--border-color); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05); } .pagination-fixed .pagination { margin-top: 0; border-top: 1px solid var(--border-color); padding: 10px 16px; background: var(--bg-primary); justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; /* 确保分页内容与列表内容对齐 */ width: 100%; box-sizing: border-box; /* 柔和的顶部边框,与列表自然分离 */ border-top-color: rgba(233, 236, 239, 0.6); /* 添加四个角的圆角,与上方卡片保持一致 */ border-radius: 8px; /* 确保底部左右角都是圆角 */ border-bottom-left-radius: 8px; border-bottom-right-radius: 8px; /* 移除顶部边框,因为外层容器已有边框 */ border-top: none; } /* 左侧:信息显示和每页数量选择器 - 更自然的设计 */ .pagination-fixed .pagination-info { font-size: 0.8125rem; color: var(--text-secondary); display: flex; align-items: center; gap: 12px; flex-wrap: wrap; /* 去掉背景色和边框,更自然 */ padding: 0; background: transparent; border-radius: 0; } .pagination-fixed .pagination-info span { color: var(--text-primary); white-space: nowrap; font-weight: 400; } .pagination-fixed .pagination-info .pagination-page-size { display: flex; align-items: center; gap: 6px; font-size: 0.8125rem; color: var(--text-secondary); font-weight: 400; } .pagination-fixed .pagination-info .pagination-page-size select { padding: 4px 24px 4px 8px; border-radius: 6px; border: 1px solid var(--border-color); background: var(--bg-primary); color: var(--text-primary); font-size: 0.8125rem; cursor: pointer; transition: all 0.2s ease; width: auto; min-width: 60px; max-width: 80px; font-weight: 500; /* 更柔和的边框 */ border-color: rgba(233, 236, 239, 0.8); /* 确保四个角都是圆角 */ border-radius: 8px !important; /* 确保下拉框不被拉伸 */ flex-shrink: 0; box-sizing: border-box; /* 确保下拉箭头正确显示 */ appearance: none; -webkit-appearance: none; -moz-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 9L1 4h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 8px center; background-size: 12px; } .pagination-fixed .pagination-info .pagination-page-size select:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1); background: var(--bg-primary); } .pagination-fixed .pagination-info .pagination-page-size select:hover { border-color: var(--accent-color); background: var(--bg-secondary); } /* 右侧:分页按钮组 - 更统一的设计 */ .pagination-fixed .pagination-controls { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; } .pagination-fixed .pagination-controls .btn-secondary { padding: 5px 12px; font-size: 0.8125rem; min-width: auto; transition: all 0.2s ease; font-weight: 500; border-radius: 6px; /* 更柔和的边框 */ border-color: rgba(233, 236, 239, 0.8); /* 确保四个角都是圆角 */ border-radius: 8px !important; } .pagination-fixed .pagination-controls .btn-secondary:hover:not(:disabled) { background: var(--bg-tertiary); border-color: var(--accent-color); color: var(--accent-color); transform: translateY(-1px); box-shadow: 0 2px 4px rgba(0, 102, 255, 0.1); } .pagination-fixed .pagination-controls .btn-secondary:active:not(:disabled) { transform: translateY(0); box-shadow: 0 1px 2px rgba(0, 102, 255, 0.08); } .pagination-fixed .pagination-controls .btn-secondary:disabled { opacity: 0.4; cursor: not-allowed; background: var(--bg-secondary); border-color: var(--border-color); color: var(--text-muted); } .pagination-fixed .pagination-page { font-size: 0.8125rem; color: var(--text-secondary); padding: 5px 10px; white-space: nowrap; font-weight: 400; /* 添加圆角设计,四个角都是圆的 */ border-radius: 8px !important; background: var(--bg-secondary) !important; border: 1px solid var(--border-color) !important; display: inline-flex !important; align-items: center; justify-content: center; } /* 响应式优化 */ @media (max-width: 768px) { .pagination-fixed .pagination { flex-direction: column; gap: 16px; align-items: stretch; padding: 16px; } .pagination-fixed .pagination-info { width: 100%; justify-content: center; gap: 16px; } .pagination-fixed .pagination-controls { width: 100%; justify-content: center; flex-wrap: wrap; gap: 6px; } .pagination-fixed .pagination-controls .btn-secondary { flex: 1; min-width: 60px; max-width: 120px; } } .pagination-info { font-size: 0.875rem; color: var(--text-secondary); display: flex; align-items: center; gap: 16px; } .pagination-controls { display: flex; align-items: center; gap: 8px; } .pagination-controls button { padding: 6px 12px; font-size: 0.875rem; min-width: auto; } .pagination-controls button:disabled, .pagination-btn.disabled { opacity: 0.5; cursor: not-allowed; } .pagination-page-size { display: flex; align-items: center; gap: 6px; font-size: 0.875rem; color: var(--text-secondary); } .pagination-page-size select { padding: 4px 8px; border-radius: 6px; border: 1px solid var(--border-color); background: var(--bg-secondary); color: var(--text-primary); font-size: 0.875rem; cursor: pointer; transition: all 0.2s; min-width: 60px; } .pagination-page-size select:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .pagination-page-size select:hover { border-color: var(--accent-color); } .pagination-btn { padding: 6px 12px; font-size: 0.875rem; min-width: 36px; height: 32px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); color: var(--text-primary); cursor: pointer; transition: all 0.2s; display: inline-flex; align-items: center; justify-content: center; } .pagination-btn:hover:not(.disabled):not(.active) { background: var(--bg-tertiary); border-color: var(--accent-color); } .pagination-btn.active { background: var(--accent-color); color: white; border-color: var(--accent-color); font-weight: 500; } .pagination-btn.disabled { opacity: 0.5; cursor: not-allowed; } .pagination-ellipsis { padding: 0 8px; color: var(--text-secondary); font-size: 0.875rem; } .pagination-page { font-size: 0.875rem; color: var(--text-secondary); padding: 0 8px; } .pagination-page-size { display: flex; align-items: center; gap: 6px; flex-shrink: 0; } .pagination-page-size label { font-size: 0.875rem; color: var(--text-secondary); white-space: nowrap; } .pagination-page-size select { padding: 6px 10px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); color: var(--text-primary); font-size: 0.875rem; cursor: pointer; transition: all 0.2s; min-width: 70px; } .pagination-page-size select:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .pagination-page-size select:hover { border-color: var(--accent-color); } .modal-footer { display: flex; justify-content: flex-end; gap: 12px; padding: 16px 24px; border-top: 1px solid var(--border-color); flex-shrink: 0; border-bottom-left-radius: 12px; border-bottom-right-radius: 12px; } .btn-primary { padding: 7px 16px; background: var(--accent-color); color: white; border: none; border-radius: 6px; font-size: 0.875rem; font-weight: 500; cursor: pointer; transition: all 0.2s; } .btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: var(--shadow-sm); } .btn-secondary { padding: 7px 16px; background: var(--bg-secondary); color: var(--text-primary); border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; font-weight: 500; cursor: pointer; transition: all 0.2s; } .btn-secondary:hover { background: var(--bg-tertiary); border-color: var(--accent-color); } /* 通用按钮加载态(用于耗时请求:AI 解析等) */ .btn-loading { opacity: 0.9; cursor: progress; display: inline-flex; align-items: center; justify-content: center; gap: 6px; } .btn-loading::before { content: ''; width: 12px; height: 12px; border: 2px solid rgba(0, 0, 0, 0.18); border-top-color: currentColor; border-radius: 50%; display: inline-block; animation: btnSpin 0.8s linear infinite; } @keyframes btnSpin { to { transform: rotate(360deg); } } .fofa-nl-status { margin-top: 6px; font-size: 0.8125rem; } .btn-danger { padding: 10px 20px; background: rgba(220, 53, 69, 0.08); color: var(--error-color, #dc3545); border: 1px solid rgba(220, 53, 69, 0.3); border-radius: 6px; font-size: 0.9375rem; font-weight: 500; cursor: pointer; transition: all 0.2s; } .btn-danger:hover { background: rgba(220, 53, 69, 0.15); border-color: var(--error-color, #dc3545); color: #c82333; } .monitor-modal-content { max-width: 1080px; width: 95%; max-height: 92vh; display: flex; flex-direction: column; overflow: hidden; } .monitor-modal-body { padding: 24px; background: var(--bg-secondary); border-radius: 0 0 16px 16px; overflow-y: auto; } .monitor-sections { display: grid; gap: 24px; width: 100%; box-sizing: border-box; min-width: 0; } .monitor-section { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 14px; padding: 20px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 16px; min-width: 0; overflow: hidden; box-sizing: border-box; } .monitor-section .section-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; flex-wrap: wrap; } .monitor-section .section-header h3 { margin: 0; font-size: 1.1rem; color: var(--text-primary); flex-shrink: 0; min-width: 0; } .monitor-section .section-actions { display: flex; align-items: center; gap: 12px; font-size: 0.875rem; color: var(--text-secondary); flex-wrap: wrap; min-width: 0; flex-shrink: 1; } .monitor-section .section-actions select { margin-left: 6px; padding: 6px 10px; border-radius: 999px; border: 1px solid var(--border-color); background: var(--bg-secondary); color: var(--text-primary); font-size: 0.875rem; cursor: pointer; transition: all 0.2s; min-width: 140px; max-width: 200px; } .monitor-section .section-actions select:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .monitor-section .section-actions select:hover { border-color: var(--accent-color); } .monitor-section .section-actions input[type="text"] { margin-left: 6px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--border-color); background: var(--bg-secondary); color: var(--text-primary); font-size: 0.875rem; transition: all 0.2s; min-width: 180px; max-width: 250px; } .monitor-section .section-actions input[type="text"]:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .monitor-section .section-actions input[type="text"]:hover { border-color: var(--accent-color); } .monitor-section .section-actions input[type="text"]::placeholder { color: var(--text-muted); } .monitor-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; width: 100%; box-sizing: border-box; } .monitor-stat-card { background: var(--bg-secondary); border: 1px solid rgba(0, 102, 255, 0.12); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 6px; box-shadow: var(--shadow-xs); min-width: 0; overflow: hidden; box-sizing: border-box; } .monitor-stat-card h4 { margin: 0; font-size: 0.95rem; color: var(--text-secondary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; word-break: break-word; max-width: 100%; } .monitor-stat-value { font-size: 1.8rem; font-weight: 600; color: var(--text-primary); word-break: break-word; overflow-wrap: break-word; } .monitor-stat-meta { font-size: 0.8rem; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; word-break: break-word; max-width: 100%; } .monitor-table-container { border: 1px solid var(--border-color); border-radius: 12px; overflow: hidden; width: 100%; box-sizing: border-box; overflow-x: auto; } .monitor-table { width: 100%; border-collapse: collapse; font-size: 0.875rem; table-layout: auto; min-width: 100%; } .monitor-table th, .monitor-table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--border-color); vertical-align: middle; word-break: break-word; overflow-wrap: break-word; } .monitor-table th { white-space: nowrap; } .monitor-table td { white-space: nowrap; } .monitor-table td:nth-child(2) { max-width: 250px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .monitor-table thead { background: var(--bg-secondary); color: var(--text-secondary); font-weight: 600; } .monitor-table tbody tr:hover { background: rgba(0, 102, 255, 0.08); } .monitor-status-chip { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 4px 10px; font-size: 0.75rem; font-weight: 600; } .monitor-status-chip.completed { background: rgba(40, 167, 69, 0.12); color: var(--success-color); } .monitor-status-chip.running { background: rgba(0, 102, 255, 0.12); color: var(--accent-color); } .monitor-status-chip.failed { background: rgba(220, 53, 69, 0.12); color: var(--error-color); } .monitor-execution-actions { display: flex; align-items: center; gap: 8px; } .monitor-execution-actions button { padding: 6px 12px; font-size: 0.75rem; } .monitor-execution-actions .btn-delete { color: var(--error-color, #dc3545); } .monitor-execution-actions .btn-delete:hover { background: rgba(220, 53, 69, 0.1); border-color: rgba(220, 53, 69, 0.4); color: #c82333; } .monitor-batch-actions { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 12px; margin-bottom: 16px; gap: 16px; } .monitor-batch-actions .batch-actions-info { display: flex; align-items: center; color: var(--text-secondary); font-size: 0.875rem; font-weight: 500; } .monitor-batch-actions .batch-actions-buttons { display: flex; align-items: center; gap: 8px; } .monitor-batch-actions .batch-actions-buttons button { padding: 6px 12px; font-size: 0.75rem; } .monitor-execution-checkbox { cursor: pointer; width: 18px; height: 18px; accent-color: var(--accent-color); margin: 0; vertical-align: middle; display: inline-block; } /* 确保复选框单元格垂直居中 */ .monitor-table td:first-child, .monitor-table th:first-child { text-align: center; vertical-align: middle; } /* 统一表头复选框大小 */ #monitor-select-all { width: 18px; height: 18px; cursor: pointer; accent-color: var(--accent-color); margin: 0; vertical-align: middle; display: inline-block; } /* 移除第一列的特殊样式,让表格更灵活 */ .monitor-vuln-container { display: grid; gap: 16px; } .monitor-vuln-summary { display: flex; gap: 12px; flex-wrap: wrap; } .vuln-counter { padding: 10px 16px; border-radius: 12px; background: var(--bg-secondary); border: 1px solid rgba(0, 102, 255, 0.12); min-width: 140px; display: flex; flex-direction: column; gap: 4px; } .vuln-counter strong { font-size: 1.4rem; color: var(--text-primary); } .vuln-counter span { font-size: 0.8rem; color: var(--text-muted); } .vuln-list { border: 1px solid var(--border-color); border-radius: 12px; overflow: hidden; } .vuln-item { padding: 14px 16px; border-bottom: 1px solid var(--border-color); display: flex; flex-direction: column; gap: 6px; } .vuln-item:last-child { border-bottom: none; } .vuln-title { font-weight: 600; color: var(--text-primary); } .vuln-severity { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; font-size: 0.75rem; font-weight: 600; color: var(--text-primary); } .vuln-severity.critical { background: rgba(108, 0, 150, 0.15); color: #bf00ff; } .vuln-severity.high { background: rgba(220, 53, 69, 0.12); color: var(--error-color); } .vuln-severity.medium { background: rgba(255, 193, 7, 0.15); color: #b8860b; } .vuln-severity.low { background: rgba(40, 167, 69, 0.12); color: var(--success-color); } .monitor-empty { text-align: center; padding: 32px 16px; color: var(--text-muted); font-size: 0.9rem; } .monitor-error { text-align: center; padding: 24px 16px; color: var(--error-color); font-size: 0.9rem; background: rgba(220, 53, 69, 0.08); border-radius: 12px; } /* 外部MCP配置样式 */ .external-mcp-controls { display: flex; flex-direction: column; gap: 16px; } .external-mcp-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; } .external-mcp-stats { display: flex; align-items: center; gap: 20px; margin-left: auto; padding: 10px 20px; background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%); border: 1px solid var(--border-color); border-radius: 10px; font-size: 0.875rem; color: var(--text-secondary); box-shadow: var(--shadow-sm); } .external-mcp-stats span { display: inline-flex; align-items: center; gap: 8px; padding: 4px 0; white-space: nowrap; } .external-mcp-stats span strong { color: var(--text-primary); font-weight: 600; margin-left: 4px; } .external-mcp-stats span:not(:last-child)::after { content: ''; } .tools-stats { display: flex; align-items: center; gap: 12px; margin-left: auto; padding: 6px 12px; background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%); border: 1px solid var(--border-color); border-radius: 10px; font-size: 0.75rem; color: var(--text-secondary); box-shadow: var(--shadow-sm); flex-wrap: nowrap; flex-shrink: 1; white-space: nowrap; min-width: 0; } .tools-stats span { display: inline-flex; align-items: center; gap: 6px; padding: 2px 0; white-space: nowrap; flex-shrink: 0; } .tools-stats span strong { color: var(--text-primary); font-weight: 600; margin-left: 4px; } .tools-stats span:not(:last-child)::after { content: ''; width: 1px; height: 16px; background: var(--border-color); margin-left: 8px; display: inline-block; } .external-mcp-list { display: flex; flex-direction: column; gap: 12px; } .external-mcp-items { display: flex; flex-direction: column; gap: 12px; } .external-mcp-item { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; padding: 20px; box-shadow: var(--shadow-sm); transition: all 0.2s ease; display: flex; flex-direction: column; gap: 16px; } .external-mcp-item:hover { box-shadow: var(--shadow-md); border-color: var(--accent-color); transform: translateY(-2px); } .external-mcp-item-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; } .external-mcp-item-info { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; } .external-mcp-item-info h4 { margin: 0; font-size: 1.125rem; font-weight: 600; color: var(--text-primary); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; } .tool-count-badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; background: rgba(0, 102, 255, 0.1); border: 1px solid rgba(0, 102, 255, 0.3); border-radius: 12px; font-size: 0.75rem; font-weight: 600; color: var(--accent-color); margin-left: 8px; white-space: nowrap; } .external-mcp-status { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; font-size: 0.8125rem; font-weight: 600; white-space: nowrap; } .external-mcp-status.status-connected { background: rgba(40, 167, 69, 0.12); color: var(--success-color); border: 1px solid rgba(40, 167, 69, 0.3); } .external-mcp-status.status-connected::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--success-color); display: inline-block; animation: pulse 2s infinite; } @keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } } .external-mcp-status.status-disconnected { background: rgba(108, 117, 125, 0.12); color: var(--text-secondary); border: 1px solid rgba(108, 117, 125, 0.3); } .external-mcp-status.status-connecting { background: rgba(0, 123, 255, 0.12); color: var(--accent-color); border: 1px solid rgba(0, 123, 255, 0.3); } .external-mcp-status.status-connecting::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--accent-color); display: inline-block; animation: pulse 1.5s infinite; } .external-mcp-status.status-disabled { background: rgba(255, 193, 7, 0.12); color: #b8860b; border: 1px solid rgba(255, 193, 7, 0.3); } .external-mcp-status.status-error { background: rgba(220, 53, 69, 0.12); color: var(--error-color); border: 1px solid rgba(220, 53, 69, 0.3); } .external-mcp-status.status-error::before { content: '❌'; display: inline-block; margin-right: 4px; } .external-mcp-item-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; } .btn-small { padding: 6px 14px; font-size: 0.8125rem; border-radius: 6px; border: 1px solid var(--border-color); background: var(--bg-secondary); color: var(--text-primary); cursor: pointer; transition: all 0.2s ease; font-weight: 500; white-space: nowrap; } .btn-small:hover { background: var(--bg-tertiary); border-color: var(--accent-color); color: var(--accent-color); transform: translateY(-1px); box-shadow: var(--shadow-sm); } .btn-small.btn-danger { background: rgba(220, 53, 69, 0.08); border-color: rgba(220, 53, 69, 0.3); color: var(--error-color); } .btn-small.btn-danger:hover { background: rgba(220, 53, 69, 0.15); border-color: var(--error-color); color: #c82333; } .external-mcp-item-details { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; padding-top: 16px; border-top: 1px solid var(--border-color); } .external-mcp-item-details > div { display: flex; flex-direction: column; gap: 6px; padding: 12px; background: var(--bg-secondary); border-radius: 8px; border: 1px solid var(--border-color); transition: all 0.2s ease; } .external-mcp-item-details > div:hover { background: var(--bg-tertiary); border-color: var(--accent-color); transform: translateY(-1px); box-shadow: var(--shadow-sm); } .external-mcp-item-details strong { font-size: 0.75rem; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 2px; } .external-mcp-item-details span { font-size: 0.875rem; color: var(--text-primary); word-break: break-word; line-height: 1.5; } .external-mcp-list .empty { text-align: center; padding: 48px 24px; color: var(--text-muted); font-size: 0.9375rem; background: var(--bg-secondary); border: 2px dashed var(--border-color); border-radius: 12px; } .external-mcp-list .error { text-align: center; padding: 24px; color: var(--error-color); background: rgba(220, 53, 69, 0.08); border: 1px solid rgba(220, 53, 69, 0.3); border-radius: 12px; font-size: 0.875rem; } .error-message { display: block; padding: 8px 12px; background: rgba(220, 53, 69, 0.1); border: 1px solid rgba(220, 53, 69, 0.3); border-radius: 6px; color: var(--error-color); font-size: 0.875rem; line-height: 1.5; } .form-group textarea { padding: 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.9375rem; background: var(--bg-primary); color: var(--text-primary); transition: border-color 0.2s; width: 100%; font-family: inherit; resize: vertical; min-height: 200px; } .form-group textarea:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1); } .form-group textarea.error { border-color: var(--error-color); box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1); } /* 响应式优化 */ @media (max-width: 768px) { .tools-actions { gap: 6px; } .tools-actions button { padding: 6px 12px; font-size: 0.8125rem; } .search-box { min-width: 100px; } .search-box input { font-size: 0.8125rem; padding: 6px 10px; } .btn-search { padding: 6px 12px; min-width: 36px; } .page-size-selector { font-size: 0.75rem; } .page-size-selector select { padding: 4px 8px; font-size: 0.75rem; min-width: 50px; } .tools-stats { padding: 4px 8px; font-size: 0.7rem; gap: 8px; } .tools-stats span { gap: 4px; } .external-mcp-actions { flex-direction: column; align-items: stretch; } .external-mcp-stats { margin-left: 0; width: 100%; justify-content: space-around; } .external-mcp-item-header { flex-direction: column; align-items: flex-start; } .external-mcp-item-actions { width: 100%; justify-content: flex-end; } .external-mcp-item-details { grid-template-columns: 1fr; } } /* ==================== 攻击链可视化样式 ==================== */ .attack-chain-modal-content { max-width: 95vw; width: 95vw; height: 90vh; max-height: 90vh; display: flex; flex-direction: column; border-radius: 20px; overflow: hidden; box-shadow: 0 24px 80px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(0, 0, 0, 0.05); background: #ffffff; } .attack-chain-body { display: flex; flex-direction: column; flex: 1; overflow: hidden; padding: 0; background: linear-gradient(135deg, #fafbfc 0%, #f5f7fa 100%); } .attack-chain-main-layout { display: flex; flex: 1; overflow: hidden; min-height: 0; gap: 0; } .attack-chain-visualization-area { flex: 1; display: flex; flex-direction: column; overflow: hidden; min-width: 0; min-height: 0; } .attack-chain-sidebar { width: 280px; flex-shrink: 0; background: linear-gradient(135deg, #ffffff 0%, #fafbfc 100%); border-left: 1px solid rgba(0, 0, 0, 0.06); display: flex; flex-direction: column; overflow: hidden; } .attack-chain-sidebar-content { flex: 1; overflow-y: auto; overflow-x: hidden; display: flex; flex-direction: column; will-change: scroll-position; -webkit-overflow-scrolling: touch; } .attack-chain-toolbar { padding: 12px 16px; border-bottom: 1px solid rgba(0, 0, 0, 0.06); background: linear-gradient(135deg, #ffffff 0%, #fafbfc 100%); display: flex; align-items: center; gap: 16px; flex-shrink: 0; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02); } .attack-chain-info { font-size: 0.8125rem; color: var(--text-primary); font-weight: 600; padding: 6px 12px; background: linear-gradient(135deg, rgba(0, 102, 255, 0.1) 0%, rgba(0, 102, 255, 0.06) 100%); border: 1px solid rgba(0, 102, 255, 0.2); border-radius: 6px; box-shadow: 0 1px 3px rgba(0, 102, 255, 0.08); display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; flex-shrink: 0; } .attack-chain-info::before { content: '📊'; font-size: 0.8125rem; } .attack-chain-legend { display: flex; flex-direction: column; gap: 20px; padding: 16px; background: transparent; flex-shrink: 0; } .legend-item { display: flex; align-items: center; gap: 10px; font-size: 0.8125rem; font-weight: 500; color: var(--text-primary); padding: 4px 0; transition: all 0.2s ease; } .legend-item:hover { transform: translateX(2px); } .legend-color { width: 20px; height: 20px; border-radius: 6px; border: 1.5px solid rgba(255, 255, 255, 0.9); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12), inset 0 1px 2px rgba(255, 255, 255, 0.3); transition: all 0.2s ease; flex-shrink: 0; } .legend-item:hover .legend-color { transform: scale(1.15); box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2), inset 0 1px 2px rgba(255, 255, 255, 0.3); } .legend-section { display: flex; flex-direction: column; gap: 8px; width: 100%; } .legend-title { font-size: 0.75rem; font-weight: 700; color: var(--text-primary); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 6px; padding-bottom: 6px; border-bottom: 1px solid rgba(0, 0, 0, 0.08); } .legend-line { display: inline-block; width: 32px; height: 0; margin-right: 0; vertical-align: middle; border-radius: 2px; flex-shrink: 0; transition: all 0.2s ease; } .legend-item:hover .legend-line { transform: scaleX(1.2); } .attack-chain-container { flex: 1; min-height: 0; background: #ffffff; border: none; position: relative; overflow: hidden; margin: 12px; border-radius: 12px; box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.06); } .attack-chain-container::before { content: ''; position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: radial-gradient(circle at 20% 30%, rgba(0, 102, 255, 0.02) 0%, transparent 50%), radial-gradient(circle at 80% 70%, rgba(0, 102, 255, 0.02) 0%, transparent 50%); pointer-events: none; z-index: 0; border-radius: 12px; } /* 攻击链筛选器样式 */ .attack-chain-filters { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; flex: 1; min-width: 0; } .attack-chain-filters input[type="text"] { padding: 6px 12px; border: 1.5px solid rgba(0, 0, 0, 0.1); border-radius: 6px; font-size: 0.8125rem; min-width: 180px; flex: 1; max-width: 300px; background: #ffffff; color: var(--text-primary); transition: all 0.25s ease; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04); } .attack-chain-filters input[type="text"]:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 4px rgba(0, 102, 255, 0.12), 0 2px 6px rgba(0, 102, 255, 0.1); transform: translateY(-1px); } .attack-chain-filters input[type="text"]:hover { border-color: rgba(0, 102, 255, 0.3); } .attack-chain-filters input[type="text"]::placeholder { color: var(--text-muted); } .attack-chain-filters select { padding: 6px 12px; padding-right: 32px; border: 1.5px solid rgba(0, 0, 0, 0.1); border-radius: 6px; font-size: 0.8125rem; background: #ffffff; color: var(--text-primary); cursor: pointer; transition: all 0.25s ease; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04); appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 10px center; font-weight: 500; min-width: 120px; } .attack-chain-filters select:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 4px rgba(0, 102, 255, 0.12), 0 2px 6px rgba(0, 102, 255, 0.1); transform: translateY(-1px); } .attack-chain-filters select:hover { border-color: rgba(0, 102, 255, 0.3); box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08); } .attack-chain-filters button.btn-secondary { padding: 6px 14px; font-size: 0.8125rem; font-weight: 600; border: 1.5px solid rgba(0, 0, 0, 0.1); border-radius: 6px; background: #ffffff; color: var(--text-primary); cursor: pointer; transition: all 0.25s ease; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04); white-space: nowrap; } .attack-chain-filters button.btn-secondary:hover { background: linear-gradient(135deg, rgba(0, 102, 255, 0.08) 0%, rgba(0, 102, 255, 0.04) 100%); border-color: var(--accent-color); color: var(--accent-color); transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0, 102, 255, 0.15); } .attack-chain-action-btn { padding: 10px 18px !important; font-size: 0.875rem !important; font-weight: 600 !important; border-radius: 10px !important; transition: all 0.25s ease !important; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08) !important; } .attack-chain-action-btn:hover { transform: translateY(-2px) !important; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12) !important; } .modal-header { padding: 16px 20px !important; border-bottom: 1px solid rgba(0, 0, 0, 0.06) !important; background: linear-gradient(135deg, #ffffff 0%, #fafbfc 100%) !important; flex-shrink: 0; } .modal-header h2 { font-size: 1.25rem !important; font-weight: 700 !important; letter-spacing: -0.3px !important; background: linear-gradient(135deg, #1a1a1a 0%, #4a4a4a 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; } .attack-chain-details { display: flex !important; flex-direction: column; gap: 12px; margin-top: 8px; padding-top: 20px; border-top: 1px solid rgba(0, 0, 0, 0.08); transition: opacity 0.2s ease; overflow: hidden; will-change: opacity; } .attack-chain-details[style*="display: none"] { display: none !important; } @keyframes slideDown { from { opacity: 0; max-height: 0; padding-top: 0; margin-top: 0; } to { opacity: 1; max-height: 1500px; padding-top: 20px; margin-top: 8px; } } .attack-chain-details-title { display: flex !important; justify-content: space-between; align-items: center; margin-bottom: 0 !important; padding-bottom: 8px !important; border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important; } .attack-chain-details-title span { flex: 1; } .attack-chain-details-close { width: 24px; height: 24px; display: flex; align-items: center; justify-content: center; border-radius: 4px; cursor: pointer; color: var(--text-secondary); border: 1px solid transparent; background: transparent; transition: all 0.2s ease; padding: 0; flex-shrink: 0; opacity: 0.6; } .attack-chain-details-close:hover { background: rgba(0, 0, 0, 0.06); color: var(--text-primary); opacity: 1; } .attack-chain-details-content { display: flex; flex-direction: column; gap: 12px; max-height: 600px; overflow-y: auto; overflow-x: hidden; padding-right: 4px; will-change: scroll-position; -webkit-overflow-scrolling: touch; } .attack-chain-details-content::-webkit-scrollbar { width: 6px; } .attack-chain-details-content::-webkit-scrollbar-track { background: rgba(0, 0, 0, 0.02); border-radius: 3px; } .attack-chain-details-content::-webkit-scrollbar-thumb { background: rgba(0, 0, 0, 0.15); border-radius: 3px; } .attack-chain-details-content::-webkit-scrollbar-thumb:hover { background: rgba(0, 0, 0, 0.25); } .node-detail-item { margin-bottom: 0; font-size: 0.8125rem; line-height: 1.6; padding: 10px 12px; background: rgba(0, 0, 0, 0.02); border-radius: 6px; border: 1px solid rgba(0, 0, 0, 0.05); transition: all 0.2s ease; } .node-detail-item:hover { background: rgba(0, 0, 0, 0.04); border-color: rgba(0, 102, 255, 0.2); } .node-detail-item strong { display: block; margin-bottom: 6px; color: var(--text-primary); font-weight: 600; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-secondary); } .node-detail-item code { background: rgba(0, 0, 0, 0.06); padding: 3px 8px; border-radius: 4px; font-size: 0.8125rem; word-break: break-all; display: inline-block; max-width: 100%; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; color: var(--text-primary); } .node-detail-item pre { background: rgba(0, 0, 0, 0.06); padding: 10px; border-radius: 6px; font-size: 0.75rem; overflow-x: auto; margin: 8px 0 0 0; line-height: 1.5; max-width: 100%; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; border: 1px solid rgba(0, 0, 0, 0.08); } .node-detail-item ul { margin: 8px 0 0 0; padding-left: 20px; } .node-detail-item li { margin-bottom: 6px; line-height: 1.5; } .node-detail-item li:last-child { margin-bottom: 0; } .node-detail-item div[style*="background"] { margin-top: 8px; padding: 10px 12px !important; border-radius: 6px; line-height: 1.6; border: 1px solid rgba(0, 0, 0, 0.08); } .node-detail-item ul { margin: 8px 0; padding-left: 20px; } .node-detail-item li { margin-bottom: 4px; } .node-detail-item strong { color: var(--text-primary); margin-right: 8px; } .node-detail-item code { background: var(--bg-tertiary); padding: 2px 6px; border-radius: 3px; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; font-size: 0.8125rem; } .metadata-pre { background: var(--bg-tertiary); padding: 8px; border-radius: 4px; font-size: 0.8125rem; overflow-x: auto; margin-top: 4px; } .modal-header-actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; } .attack-chain-action-btn { padding: 8px 16px !important; font-size: 0.8125rem !important; font-weight: 600 !important; border-radius: 8px !important; transition: all 0.25s ease !important; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08) !important; border: 2px solid transparent !important; display: inline-flex !important; align-items: center !important; gap: 6px !important; } .attack-chain-action-btn:hover { transform: translateY(-2px) !important; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12) !important; } .attack-chain-action-btn.btn-primary { background: linear-gradient(135deg, #0066ff 0%, #0052cc 100%) !important; color: white !important; border-color: #0066ff !important; } .attack-chain-action-btn.btn-primary:hover { background: linear-gradient(135deg, #0052cc 0%, #0040a3 100%) !important; box-shadow: 0 6px 20px rgba(0, 102, 255, 0.3) !important; } .attack-chain-action-btn.btn-secondary { background: linear-gradient(135deg, #ffffff 0%, #fafbfc 100%) !important; color: var(--text-primary) !important; border-color: rgba(0, 0, 0, 0.1) !important; } .attack-chain-action-btn.btn-secondary:hover { background: linear-gradient(135deg, #f8f9fa 0%, #f1f3f5 100%) !important; border-color: var(--accent-color) !important; color: var(--accent-color) !important; } .attack-chain-action-btn.btn-primary:hover { background: linear-gradient(135deg, #0052cc 0%, #0040a3 100%); border-color: #0052cc; } .loading-spinner { display: flex; align-items: center; justify-content: center; height: 100%; color: var(--text-secondary); font-size: 1rem; } .empty-message { display: flex; align-items: center; justify-content: center; height: 100%; color: var(--text-secondary); font-size: 1rem; } .error-message { display: flex; align-items: center; justify-content: center; height: 100%; color: var(--error-color); font-size: 1rem; padding: 20px; } /* ==================== 知识管理样式 ==================== */ .knowledge-controls { display: flex; flex-direction: column; gap: 16px; margin-bottom: 24px; } .knowledge-stats-bar { display: flex; gap: 24px; padding: 16px 20px; background: linear-gradient(135deg, rgba(0, 102, 255, 0.05) 0%, rgba(0, 102, 255, 0.02) 100%); border: 1px solid rgba(0, 102, 255, 0.15); border-radius: 12px; box-shadow: var(--shadow-sm); } .knowledge-stat-item { display: flex; flex-direction: column; gap: 4px; } .knowledge-stat-label { font-size: 0.8125rem; color: var(--text-secondary); font-weight: 500; } .knowledge-stat-value { font-size: 1.5rem; font-weight: 600; color: var(--accent-color); } /* 索引进度显示 */ .knowledge-index-progress { padding: 16px 20px; background: linear-gradient(135deg, rgba(255, 193, 7, 0.1) 0%, rgba(255, 193, 7, 0.05) 100%); border: 1px solid rgba(255, 193, 7, 0.3); border-radius: 12px; box-shadow: var(--shadow-sm); } .knowledge-index-progress-complete { padding: 16px 20px; background: linear-gradient(135deg, rgba(40, 167, 69, 0.1) 0%, rgba(40, 167, 69, 0.05) 100%); border: 1px solid rgba(40, 167, 69, 0.3); border-radius: 12px; box-shadow: var(--shadow-sm); display: flex; align-items: center; gap: 12px; } .knowledge-index-progress .progress-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; } .knowledge-index-progress .progress-icon { font-size: 1.25rem; flex-shrink: 0; } .knowledge-index-progress .progress-text { font-size: 0.9375rem; font-weight: 500; color: var(--text-primary); flex: 1; } .knowledge-index-progress-complete .progress-icon { font-size: 1.25rem; } .knowledge-index-progress-complete .progress-text { font-size: 0.9375rem; font-weight: 500; color: var(--text-primary); } .progress-bar-container { width: 100%; height: 8px; background: rgba(0, 0, 0, 0.1); border-radius: 4px; overflow: hidden; margin-bottom: 8px; } .progress-bar { height: 100%; background: linear-gradient(90deg, #ffc107 0%, #ff9800 100%); border-radius: 4px; transition: width 0.3s ease; animation: progress-pulse 2s ease-in-out infinite; } @keyframes progress-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.8; } } .progress-hint { font-size: 0.8125rem; color: var(--text-secondary); margin-top: 4px; } .knowledge-filters { display: flex; gap: 16px; align-items: flex-end; flex-wrap: wrap; } .knowledge-filters label { display: flex; flex-direction: column; gap: 6px; font-size: 0.875rem; font-weight: 500; color: var(--text-primary); } .knowledge-filters select { padding: 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); color: var(--text-primary); font-size: 0.875rem; cursor: pointer; transition: all 0.2s; min-width: 160px; } .knowledge-filters select:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } /* 自定义下拉组件样式 */ .custom-select-wrapper { position: relative; min-width: 160px; } .custom-select { position: relative; } .custom-select-trigger { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); color: var(--text-primary); font-size: 0.875rem; cursor: pointer; transition: all 0.2s; min-width: 160px; } .custom-select-trigger:hover { border-color: var(--accent-color); } .custom-select-trigger svg { transition: transform 0.2s; flex-shrink: 0; margin-left: 8px; } .custom-select.open .custom-select-trigger { border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .custom-select.open .custom-select-trigger svg { transform: rotate(180deg); } .custom-select-dropdown { position: absolute; top: calc(100% + 4px); left: 0; right: 0; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 6px; box-shadow: var(--shadow-lg); z-index: 1000; max-height: 300px; overflow-y: auto; overflow-x: hidden; display: none; } .custom-select.open .custom-select-dropdown { display: block; } .custom-select-option { padding: 10px 12px; font-size: 0.875rem; color: var(--text-primary); cursor: pointer; transition: background-color 0.15s; border-bottom: 1px solid var(--border-color); } .custom-select-option:last-child { border-bottom: none; } .custom-select-option:hover { background: var(--bg-secondary); } .custom-select-option.selected { background: var(--accent-color); color: white; } .custom-select-option.selected:hover { background: var(--accent-hover); } /* 自定义下拉组件滚动条样式 */ .custom-select-dropdown::-webkit-scrollbar { width: 6px; } .custom-select-dropdown::-webkit-scrollbar-track { background: transparent; } .custom-select-dropdown::-webkit-scrollbar-thumb { background: rgba(0, 0, 0, 0.2); border-radius: 3px; } .custom-select-dropdown::-webkit-scrollbar-thumb:hover { background: rgba(0, 0, 0, 0.3); } .knowledge-items-list { min-height: 200px; } .knowledge-categories-container { display: flex; flex-direction: column; gap: 32px; } .knowledge-category-section { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 16px; padding: 24px; box-shadow: var(--shadow-sm); transition: all 0.2s ease; } .knowledge-category-section:hover { box-shadow: var(--shadow-md); border-color: rgba(0, 102, 255, 0.2); } .knowledge-category-header { margin-bottom: 20px; padding-bottom: 16px; border-bottom: 2px solid var(--border-color); } .knowledge-category-info { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; } .knowledge-category-title { margin: 0; font-size: 1.25rem; font-weight: 600; color: var(--text-primary); display: flex; align-items: center; gap: 8px; } .knowledge-category-title::before { content: '📁'; font-size: 1.1rem; } .knowledge-category-count { padding: 4px 12px; background: rgba(0, 102, 255, 0.1); border: 1px solid rgba(0, 102, 255, 0.2); border-radius: 12px; font-size: 0.8125rem; font-weight: 600; color: var(--accent-color); } .knowledge-items-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; } .knowledge-item-card { background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 12px; padding: 16px; transition: all 0.2s ease; display: flex; flex-direction: column; gap: 12px; cursor: pointer; position: relative; overflow: hidden; } .knowledge-item-card::before { content: ''; position: absolute; top: 0; left: 0; width: 4px; height: 100%; background: var(--accent-color); opacity: 0; transition: opacity 0.2s ease; } .knowledge-item-card:hover { background: var(--bg-primary); border-color: var(--accent-color); box-shadow: var(--shadow-md); transform: translateY(-2px); } .knowledge-item-card:hover::before { opacity: 1; } .knowledge-item-card-header { display: flex; flex-direction: column; gap: 8px; } .knowledge-item-card-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; } .knowledge-item-card-title { margin: 0; font-size: 1rem; font-weight: 600; color: var(--text-primary); flex: 1; line-height: 1.4; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; } .knowledge-item-card-actions { display: flex; gap: 4px; flex-shrink: 0; opacity: 0; transition: opacity 0.2s ease; } .knowledge-item-card:hover .knowledge-item-card-actions { opacity: 1; } .knowledge-item-action-btn { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); color: var(--text-secondary); cursor: pointer; transition: all 0.2s ease; padding: 0; } .knowledge-item-action-btn:hover { background: var(--bg-tertiary); border-color: var(--accent-color); color: var(--accent-color); transform: scale(1.05); } .knowledge-item-delete-btn:hover { background: rgba(220, 53, 69, 0.1); border-color: var(--error-color); color: var(--error-color); } .knowledge-item-action-btn svg { width: 16px; height: 16px; stroke: currentColor; } .knowledge-item-path { font-size: 0.75rem; color: var(--text-muted); display: flex; align-items: center; gap: 4px; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .knowledge-item-card-content { flex: 1; min-height: 60px; } .knowledge-item-preview { margin: 0; font-size: 0.875rem; color: var(--text-secondary); line-height: 1.6; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; } .knowledge-item-card-footer { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding-top: 12px; border-top: 1px solid var(--border-color); flex-wrap: wrap; } .knowledge-item-meta { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; } .knowledge-item-time { font-size: 0.75rem; color: var(--text-muted); white-space: nowrap; } .knowledge-item-badge-new { padding: 2px 6px; background: rgba(40, 167, 69, 0.15); border: 1px solid rgba(40, 167, 69, 0.3); border-radius: 4px; font-size: 0.6875rem; font-weight: 600; color: var(--success-color); white-space: nowrap; } .knowledge-item-updated { font-size: 0.75rem; color: var(--text-muted); white-space: nowrap; } .empty-state { text-align: center; padding: 48px 24px; color: var(--text-muted); font-size: 0.9375rem; background: var(--bg-secondary); border: 2px dashed var(--border-color); border-radius: 12px; } /* ==================== 检索历史样式 ==================== */ .retrieval-logs-controls { display: flex; flex-direction: column; gap: 16px; margin-bottom: 24px; } .retrieval-stats-bar { display: flex; gap: 24px; padding: 16px 20px; background: linear-gradient(135deg, rgba(0, 102, 255, 0.05) 0%, rgba(0, 102, 255, 0.02) 100%); border: 1px solid rgba(0, 102, 255, 0.15); border-radius: 12px; box-shadow: var(--shadow-sm); flex-wrap: wrap; } .retrieval-stat-item { display: flex; flex-direction: column; gap: 4px; } .retrieval-stat-label { font-size: 0.8125rem; color: var(--text-secondary); font-weight: 500; } .retrieval-stat-value { font-size: 1.5rem; font-weight: 600; color: var(--accent-color); } .retrieval-stat-value.text-success { color: var(--success-color); } .retrieval-logs-filters { display: flex; gap: 16px; align-items: flex-end; flex-wrap: wrap; padding: 16px; background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 12px; } .retrieval-logs-filters label { display: flex; flex-direction: column; gap: 6px; font-size: 0.875rem; font-weight: 500; color: var(--text-primary); flex: 1; min-width: 200px; } .retrieval-logs-filters input { padding: 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); color: var(--text-primary); font-size: 0.875rem; transition: all 0.2s; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; } .retrieval-logs-filters input:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .retrieval-logs-list { display: flex; flex-direction: column; gap: 16px; } .retrieval-log-card { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; padding: 20px; transition: all 0.2s ease; box-shadow: var(--shadow-sm); position: relative; overflow: hidden; } .retrieval-log-card::before { content: ''; position: absolute; top: 0; left: 0; width: 4px; height: 100%; background: var(--border-color); transition: all 0.2s ease; } .retrieval-log-card.has-results::before { background: var(--success-color); } .retrieval-log-card.no-results::before { background: var(--warning-color); } .retrieval-log-card:hover { box-shadow: var(--shadow-md); border-color: var(--accent-color); transform: translateY(-2px); } .retrieval-log-card-header { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 16px; } .retrieval-log-icon { font-size: 1.5rem; flex-shrink: 0; width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; background: var(--bg-secondary); border-radius: 8px; border: 1px solid var(--border-color); } .retrieval-log-main-info { flex: 1; min-width: 0; } .retrieval-log-query { font-size: 1rem; font-weight: 600; color: var(--text-primary); margin-bottom: 8px; line-height: 1.5; word-break: break-word; } .retrieval-log-meta { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; } .retrieval-log-time { font-size: 0.8125rem; color: var(--text-secondary); display: flex; align-items: center; gap: 4px; } .retrieval-log-risk-type { font-size: 0.8125rem; padding: 4px 10px; background: rgba(0, 102, 255, 0.1); border: 1px solid rgba(0, 102, 255, 0.2); border-radius: 12px; color: var(--accent-color); font-weight: 500; } .retrieval-log-result-badge { flex-shrink: 0; padding: 6px 14px; border-radius: 20px; font-size: 0.875rem; font-weight: 600; white-space: nowrap; } .retrieval-log-result-badge.success { background: rgba(40, 167, 69, 0.15); border: 1px solid rgba(40, 167, 69, 0.3); color: var(--success-color); } .retrieval-log-result-badge.empty { background: rgba(255, 193, 7, 0.15); border: 1px solid rgba(255, 193, 7, 0.3); color: #b8860b; } .retrieval-log-card-body { padding-top: 16px; border-top: 1px solid var(--border-color); } .retrieval-log-details-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 12px; margin-bottom: 12px; } .retrieval-log-detail-item { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px; background: var(--bg-secondary); border-radius: 8px; border: 1px solid var(--border-color); } .detail-label { font-size: 0.75rem; color: var(--text-secondary); font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; } .detail-value { font-size: 0.875rem; color: var(--text-primary); font-weight: 500; word-break: break-all; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; } .detail-value.text-success { color: var(--success-color); } .detail-value.text-muted { color: var(--text-muted); } .retrieval-log-items-preview { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border-color); } .retrieval-log-items-label { font-size: 0.8125rem; color: var(--text-secondary); font-weight: 500; margin-bottom: 8px; } .retrieval-log-items-list { display: flex; flex-wrap: wrap; gap: 8px; } .retrieval-log-item-tag { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; background: rgba(0, 102, 255, 0.1); border: 1px solid rgba(0, 102, 255, 0.2); border-radius: 8px; font-size: 0.8125rem; font-weight: 600; color: var(--accent-color); } .retrieval-log-item-tag.more { background: var(--bg-tertiary); border-color: var(--border-color); color: var(--text-secondary); } /* 响应式设计 */ @media (max-width: 768px) { .knowledge-items-grid { grid-template-columns: 1fr; } .knowledge-stats-bar { flex-direction: column; gap: 12px; } .knowledge-stat-item { flex-direction: row; justify-content: space-between; align-items: center; } .knowledge-filters { flex-direction: column; align-items: stretch; } .knowledge-filters select { min-width: 100%; } .retrieval-stats-bar { flex-direction: column; gap: 12px; } .retrieval-stat-item { flex-direction: row; justify-content: space-between; align-items: center; } .retrieval-logs-filters { flex-direction: column; align-items: stretch; } .retrieval-logs-filters label { min-width: 100%; } .retrieval-log-details-grid { grid-template-columns: 1fr; } .retrieval-log-card-header { flex-wrap: wrap; } .retrieval-log-result-badge { width: 100%; text-align: center; } } /* 旋转动画 */ @keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } } /* 对话分组和最近对话样式 */ .conversation-groups-section, .recent-conversations-section { margin-bottom: 24px; } .conversation-groups-section:last-child, .recent-conversations-section:last-child { margin-bottom: 0; } .section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; padding: 0 8px; } .section-title { font-size: 0.8125rem; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.5px; } .add-group-btn, .batch-manage-btn { width: 24px; height: 24px; padding: 0; border: none; background: transparent; color: var(--text-muted); cursor: pointer; border-radius: 4px; display: flex; align-items: center; justify-content: center; transition: all 0.2s ease; } .add-group-btn:hover, .batch-manage-btn:hover { background: var(--bg-tertiary); color: var(--accent-color); } .add-group-btn svg, .batch-manage-btn svg { width: 16px; height: 16px; } .conversation-groups-list { display: flex; flex-direction: column; gap: 4px; } .group-item { padding: 10px 12px; border-radius: 8px; cursor: pointer; transition: all 0.2s; border: 1px solid transparent; display: flex; align-items: center; justify-content: space-between; gap: 8px; position: relative; } .group-item:hover { background: var(--bg-tertiary); } .group-item.active { background: rgba(0, 102, 255, 0.08); border-color: var(--accent-color); } .group-item-content { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; } .group-item-icon { font-size: 1rem; flex-shrink: 0; } .group-item-name { font-size: 0.875rem; font-weight: 500; color: var(--text-primary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; display: flex; align-items: center; gap: 4px; } .group-item-pinned { font-size: 0.75rem; flex-shrink: 0; opacity: 0.7; } .group-item-menu { width: 24px; height: 24px; padding: 0; border: none; background: transparent; color: var(--text-muted); cursor: pointer; border-radius: 4px; display: flex; align-items: center; justify-content: center; opacity: 0; transition: all 0.2s ease; flex-shrink: 0; } .group-item:hover .group-item-menu { opacity: 1; } .group-item-menu:hover { background: var(--bg-tertiary); color: var(--text-primary); } .conversation-item { position: relative; } .conversation-item-pinned { display: inline-flex; align-items: center; margin-left: 4px; color: var(--accent-color); } .conversation-item-menu { width: 28px; height: 28px; padding: 0; border: none; background: transparent; color: var(--text-secondary); cursor: pointer; border-radius: 6px; display: flex; align-items: center; justify-content: center; opacity: 0.6; transition: all 0.2s ease; flex-shrink: 0; font-size: 18px; font-weight: 600; line-height: 1; } .conversation-item:hover .conversation-item-menu, .group-conversation-item:hover .conversation-item-menu { opacity: 1; } .conversation-item-menu:hover { background: var(--bg-tertiary); color: var(--text-primary); opacity: 1; } /* 分组详情页面 */ .group-detail-page { display: flex; flex-direction: column; flex: 1; min-width: 0; background: var(--bg-primary); overflow: hidden; height: 100%; } .group-detail-header { padding: 16px 24px; border-bottom: 1px solid var(--border-color); display: flex; align-items: center; gap: 16px; flex-shrink: 0; } .back-btn { width: 32px; height: 32px; padding: 0; border: none; background: transparent; color: var(--text-secondary); cursor: pointer; border-radius: 6px; display: flex; align-items: center; justify-content: center; transition: all 0.2s ease; } .back-btn:hover { background: var(--bg-tertiary); color: var(--accent-color); } .group-detail-title { font-size: 1.5rem; font-weight: 600; color: var(--text-primary); margin: 0; flex: 1; } .group-detail-actions { display: flex; align-items: center; gap: 8px; } .group-action-btn { display: flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid var(--border-color); background: var(--bg-primary); color: var(--text-primary); border-radius: 6px; font-size: 0.875rem; cursor: pointer; transition: all 0.2s ease; } .group-action-btn:hover { background: var(--bg-tertiary); border-color: var(--accent-color); color: var(--accent-color); } .group-action-btn.delete-btn { color: var(--error-color); } .group-action-btn.delete-btn:hover { background: rgba(220, 53, 69, 0.1); border-color: var(--error-color); } .group-search-container { padding: 12px 24px; border-bottom: 1px solid var(--border-color); background: var(--bg-primary); flex-shrink: 0; } .group-search-input-wrapper { position: relative; display: flex; align-items: center; } .group-search-input { width: 100%; padding: 8px 36px 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; color: var(--text-primary); background: var(--bg-secondary); transition: all 0.2s ease; } .group-search-input:focus { outline: none; border-color: var(--accent-color); background: var(--bg-primary); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1); } .group-search-input::placeholder { color: var(--text-muted); } .group-search-clear-btn { position: absolute; right: 8px; width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; border: none; background: transparent; color: var(--text-muted); cursor: pointer; border-radius: 4px; transition: all 0.2s ease; padding: 0; } .group-search-clear-btn:hover { background: var(--bg-tertiary); color: var(--text-primary); } .group-detail-content { flex: 1; overflow-y: auto; padding: 24px; background: #f5f7fa; } .group-conversations-list { display: flex; flex-direction: column; gap: 8px; max-width: 100%; } .group-conversation-item { padding: 12px 16px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; cursor: pointer; transition: all 0.2s ease; position: relative; display: flex; align-items: flex-start; gap: 12px; } .group-conversation-item:hover { background: var(--bg-tertiary); border-color: var(--accent-color); } .group-conversation-item.active { background: rgba(0, 102, 255, 0.08); border-color: var(--accent-color); } .group-conversation-item:hover .conversation-item-menu { opacity: 1; } .group-conversation-content-wrapper { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; } .group-conversation-item .conversation-item-menu { position: absolute; top: 8px; right: 8px; opacity: 0.6; flex-shrink: 0; } .group-conversation-title { font-size: 0.9375rem; font-weight: 500; color: var(--text-primary); line-height: 1.4; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 1; line-clamp: 1; -webkit-box-orient: vertical; } .group-conversation-time { font-size: 0.75rem; color: var(--text-muted); line-height: 1.4; } .group-conversation-content { margin-top: 4px; padding: 8px 12px; background: var(--bg-secondary); border-radius: 6px; font-size: 0.8125rem; color: var(--text-secondary); line-height: 1.5; max-height: 60px; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; word-break: break-word; } /* 批量管理模态框 */ .batch-manage-modal-content { max-width: 800px; width: 90vw; display: flex; flex-direction: column; max-height: 85vh; } .batch-manage-header-actions { display: flex; align-items: center; gap: 12px; } .batch-search-box { position: relative; display: flex; align-items: center; } .batch-search-box input { padding: 8px 32px 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; background: var(--bg-primary); color: var(--text-primary); width: 200px; } .batch-search-box svg { position: absolute; right: 8px; width: 16px; height: 16px; color: var(--text-muted); pointer-events: none; } .batch-manage-body { flex: 1; min-height: 0; overflow-y: auto; padding: 0; display: flex; flex-direction: column; } .batch-conversations-table { display: flex; flex-direction: column; } .batch-table-header { display: grid; grid-template-columns: 40px 1fr 180px 80px; gap: 16px; padding: 12px 16px; background: var(--bg-secondary); border-bottom: 1px solid var(--border-color); font-size: 0.8125rem; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.5px; } .batch-conversations-list { display: flex; flex-direction: column; } .batch-conversation-row { display: grid; grid-template-columns: 40px 1fr 180px 80px; gap: 16px; padding: 12px 16px; border-bottom: 1px solid var(--border-color); align-items: center; transition: background 0.2s ease; } .batch-conversation-row:hover { background: var(--bg-tertiary); } .batch-table-col-checkbox { display: flex; align-items: center; justify-content: center; } .batch-table-col-name { font-size: 0.875rem; color: var(--text-primary); overflow: hidden; text-overflow: clip; white-space: nowrap; word-break: keep-all; /* 完全依赖JavaScript截断,禁用CSS的ellipsis以避免在UTF-8多字节字符中间截断 */ } .batch-table-col-time { font-size: 0.875rem; color: var(--text-muted); } .batch-table-col-action { display: flex; align-items: center; justify-content: center; } .batch-delete-btn { width: 28px; height: 28px; padding: 0; border: none; background: transparent; color: var(--text-muted); cursor: pointer; border-radius: 4px; display: flex; align-items: center; justify-content: center; transition: all 0.2s ease; } .batch-delete-btn:hover { background: rgba(220, 53, 69, 0.1); color: var(--error-color); } .batch-manage-footer { display: flex; align-items: center; justify-content: space-between; padding: 16px 24px; border-top: 1px solid var(--border-color); flex-shrink: 0; } .select-all-checkbox { display: flex; align-items: center; gap: 8px; cursor: pointer; font-size: 0.875rem; color: var(--text-primary); } .batch-footer-actions { display: flex; gap: 12px; } /* 创建分组模态框 */ .create-group-modal-content { max-width: 640px; width: 60vw; margin: 8% auto; } .create-group-modal-content .modal-header { padding: 12px 20px; border-bottom: 1px solid #f0f0f0; background: #ffffff; } .create-group-modal-content .modal-header h2 { font-size: 1rem; font-weight: 600; color: #1a1a1a; background: none; -webkit-background-clip: unset; -webkit-text-fill-color: #1a1a1a; background-clip: unset; margin: 0; } .create-group-modal-content .modal-close { width: 28px; height: 28px; font-size: 1.1rem; color: #666; } .create-group-modal-content .modal-close:hover { background: #f5f5f5; color: #333; border-color: transparent; transform: scale(1); } .create-group-modal-content .modal-footer { padding: 10px 20px; border-top: 1px solid #f0f0f0; background: #fafafa; } .create-group-body { padding: 16px 20px; } .create-group-description { font-size: 0.8125rem; color: #666; line-height: 1.3; margin-bottom: 12px; margin-top: 0; padding: 0; } .create-group-input-wrapper { position: relative; display: flex; align-items: center; margin-bottom: 0; width: 100%; } .group-icon-input { position: absolute; left: 8px; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; display: flex; align-items: center; justify-content: center; background: #f5f5f5; border: 1px solid #e0e0e0; border-radius: 6px; font-size: 1rem; cursor: pointer; z-index: 2; box-shadow: none; line-height: 1; transition: all 0.2s ease; } .group-icon-input:hover { background: #e8e8e8; border-color: #d0d0d0; transform: translateY(-50%) scale(1.05); } .group-icon-input:active { transform: translateY(-50%) scale(0.98); background: #ddd; } /* 图标选择器面板 */ .group-icon-picker { position: absolute; top: calc(100% + 8px); left: 0; width: 280px; background: #ffffff; border: 1px solid #e0e0e0; border-radius: 12px; box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15); z-index: 100; overflow: hidden; } .icon-picker-header { padding: 10px 14px; font-size: 0.8125rem; font-weight: 600; color: #666; background: #fafafa; border-bottom: 1px solid #f0f0f0; display: flex; align-items: center; justify-content: space-between; gap: 10px; } .icon-picker-header > span { flex-shrink: 0; } .icon-picker-custom { display: flex; align-items: center; gap: 6px; } .custom-icon-input { width: 60px; padding: 4px 8px; border: 1px solid #e0e0e0; border-radius: 6px; font-size: 0.875rem; text-align: center; background: #ffffff; transition: all 0.2s ease; } .custom-icon-input:focus { outline: none; border-color: #667eea; box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1); } .custom-icon-input::placeholder { color: #bbb; font-size: 0.75rem; } .custom-icon-btn { padding: 4px 10px; font-size: 0.75rem; font-weight: 500; color: #fff; background: #667eea; border: none; border-radius: 6px; cursor: pointer; transition: all 0.2s ease; white-space: nowrap; } .custom-icon-btn:hover { background: #5a6fd6; } .custom-icon-btn:active { transform: scale(0.96); } .icon-picker-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; padding: 12px; max-height: 180px; overflow-y: auto; } .icon-option { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; font-size: 1.25rem; cursor: pointer; border-radius: 8px; transition: all 0.15s ease; user-select: none; } .icon-option:hover { background: #f0f0f0; transform: scale(1.15); } .icon-option:active { transform: scale(1); background: #e0e0e0; } #create-group-name-input { width: 100%; padding: 8px 12px 8px 40px; border: 1.5px solid #e0e0e0; border-radius: 8px; font-size: 0.875rem; background: #fafafa; color: var(--text-primary); transition: all 0.3s ease; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03); height: 36px; box-sizing: border-box; line-height: 1.2; } #create-group-name-input:hover { border-color: #b0b0b0; background: #ffffff; } #create-group-name-input:focus { outline: none; border-color: #667eea; background: #ffffff; box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1), 0 2px 8px rgba(0, 0, 0, 0.08); } #create-group-name-input::placeholder { color: #999; } .create-group-suggestions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; } .suggestion-tag { display: inline-flex; align-items: center; padding: 5px 12px; background: #f5f5f5; border: 1px solid #e0e0e0; border-radius: 14px; font-size: 0.8125rem; color: #666; cursor: pointer; transition: all 0.2s ease; user-select: none; height: 26px; box-sizing: border-box; } .suggestion-tag:hover { background: #e8e8e8; border-color: #d0d0d0; color: #333; transform: translateY(-1px); } .suggestion-tag:active { transform: translateY(0); background: #ddd; } /* 上下文菜单 */ .context-menu { position: fixed; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); z-index: 10000; min-width: 180px; padding: 4px; } .context-menu-item { display: flex; align-items: center; gap: 8px; padding: 10px 12px; cursor: pointer; color: var(--text-primary); font-size: 0.875rem; border-radius: 6px; transition: all 0.2s ease; position: relative; } .context-menu-item:hover { background: var(--bg-tertiary); color: var(--accent-color); } .context-menu-item svg { width: 16px; height: 16px; flex-shrink: 0; } .context-menu-item-has-submenu { justify-content: space-between; } .context-menu-item-has-submenu .submenu-arrow { width: 12px; height: 12px; margin-left: auto; } .context-menu-item-danger { color: var(--error-color); } .context-menu-item-danger:hover { background: rgba(220, 53, 69, 0.1); color: var(--error-color); } .context-menu-divider { height: 1px; background: var(--border-color); margin: 4px 0; } .context-submenu { position: absolute; left: 100%; top: 0; margin-left: 4px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); min-width: 160px; max-width: 240px; max-height: 400px; overflow-y: auto; padding: 4px; z-index: 10001; } .context-submenu[style*="right: 100%"] { left: auto; right: 100%; margin-left: 0; margin-right: 4px; } .context-submenu-item { display: flex; align-items: center; gap: 8px; padding: 10px 12px; cursor: pointer; color: var(--text-primary); font-size: 0.875rem; border-radius: 6px; transition: all 0.2s ease; white-space: nowrap; } .context-submenu-item svg { width: 16px; height: 16px; flex-shrink: 0; } .context-submenu-item:hover { background: var(--bg-tertiary); color: var(--accent-color); } .context-submenu-item.add-group-item { color: var(--accent-color); font-weight: 500; } .context-submenu-item.add-group-item:hover { background: rgba(0, 102, 255, 0.1); } /* 任务管理页面样式 */ .tasks-stats-bar { display: flex; gap: 24px; padding: 16px 20px; background: linear-gradient(135deg, rgba(0, 102, 255, 0.05) 0%, rgba(0, 102, 255, 0.02) 100%); border: 1px solid rgba(0, 102, 255, 0.15); border-radius: 12px; box-shadow: var(--shadow-sm); margin-bottom: 24px; flex-wrap: wrap; } .tasks-controls { margin-bottom: 24px; } .tasks-filters { display: flex; gap: 16px; align-items: flex-end; flex-wrap: wrap; padding: 16px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; margin-bottom: 16px; } .tasks-filters label { display: flex; flex-direction: column; gap: 6px; font-size: 0.875rem; color: var(--text-secondary); font-weight: 500; } .tasks-filters select { padding: 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; background: var(--bg-primary); color: var(--text-primary); min-width: 150px; cursor: pointer; transition: all 0.2s; } .tasks-filters select:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .tasks-filters select:hover { border-color: var(--accent-color); } .tasks-filters input[type="text"] { padding: 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; background: var(--bg-primary); color: var(--text-primary); width: 100%; transition: all 0.2s; } .tasks-filters input[type="text"]:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .tasks-filters input[type="text"]:hover { border-color: var(--accent-color); } .tasks-batch-actions { display: flex; align-items: center; gap: 12px; padding: 12px 16px; background: rgba(0, 102, 255, 0.05); border: 1px solid rgba(0, 102, 255, 0.2); border-radius: 8px; margin-top: 12px; } .tasks-batch-actions span { font-size: 0.875rem; color: var(--text-primary); font-weight: 500; } .auto-refresh-toggle { display: flex; align-items: center; gap: 8px; font-size: 0.875rem; color: var(--text-primary); cursor: pointer; user-select: none; } .auto-refresh-toggle input[type="checkbox"] { width: 18px; height: 18px; cursor: pointer; accent-color: var(--accent-color); } .page-header-actions { display: flex; align-items: center; gap: 12px; } .show-history-toggle { display: flex; align-items: center; gap: 8px; font-size: 0.875rem; color: var(--text-primary); cursor: pointer; user-select: none; margin-left: auto; } .show-history-toggle input[type="checkbox"] { width: 18px; height: 18px; cursor: pointer; accent-color: var(--accent-color); } .tasks-history-section { margin-top: 32px; padding-top: 24px; border-top: 2px solid var(--border-color); } .tasks-history-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--border-color); } .tasks-history-title { font-size: 0.9375rem; font-weight: 600; color: var(--text-secondary); } .task-item-history { opacity: 0.85; } .task-item-history:hover { opacity: 1; } .task-history-badge { font-size: 0.875rem; margin-left: 4px; opacity: 0.7; } .task-stat-item { display: flex; flex-direction: column; gap: 4px; } .task-stat-label { font-size: 0.8125rem; color: var(--text-secondary); font-weight: 500; } .task-stat-value { font-size: 1.5rem; font-weight: 600; color: var(--accent-color); } .tasks-list { display: flex; flex-direction: column; gap: 16px; } .tasks-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 60px 20px; text-align: center; color: var(--text-secondary); } .tasks-empty p { font-size: 1rem; margin-bottom: 16px; } .task-item { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; padding: 20px; box-shadow: var(--shadow-sm); transition: all 0.2s ease; } .task-item:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); } .task-header { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; } .task-info { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 200px; } .task-checkbox { display: flex; align-items: center; cursor: pointer; } .task-checkbox input[type="checkbox"] { width: 18px; height: 18px; cursor: pointer; accent-color: var(--accent-color); } .task-checkbox-placeholder { width: 18px; height: 18px; } .task-status { display: inline-flex; align-items: center; padding: 4px 12px; border-radius: 12px; font-size: 0.8125rem; font-weight: 500; white-space: nowrap; } .task-status-running { background: rgba(0, 123, 255, 0.1); color: var(--accent-color); border: 1px solid rgba(0, 123, 255, 0.3); } .task-status-cancelling { background: rgba(255, 193, 7, 0.1); color: #b8860b; border: 1px solid rgba(255, 193, 7, 0.3); } .task-status-completed { background: rgba(40, 167, 69, 0.1); color: var(--success-color); border: 1px solid rgba(40, 167, 69, 0.3); } .task-status-failed, .task-status-timeout { background: rgba(220, 53, 69, 0.1); color: var(--error-color); border: 1px solid rgba(220, 53, 69, 0.3); } .task-status-cancelled { background: rgba(108, 117, 125, 0.1); color: var(--text-secondary); border: 1px solid rgba(108, 117, 125, 0.3); } .task-status-unknown { background: var(--bg-secondary); color: var(--text-secondary); border: 1px solid var(--border-color); } .task-message { font-size: 0.9375rem; color: var(--text-primary); font-weight: 500; word-break: break-word; } .task-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; } .task-time { font-size: 0.8125rem; color: var(--text-secondary); white-space: nowrap; } .task-duration { font-size: 0.8125rem; color: var(--accent-color); font-weight: 500; white-space: nowrap; padding: 4px 8px; background: rgba(0, 102, 255, 0.1); border-radius: 4px; } .task-details { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border-color); display: flex; align-items: center; gap: 8px; font-size: 0.8125rem; } .task-id-label { color: var(--text-secondary); font-weight: 500; } .task-id-value { color: var(--text-primary); font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; background: var(--bg-secondary); padding: 2px 8px; border-radius: 4px; word-break: break-all; cursor: pointer; transition: all 0.2s; } .task-id-value:hover { background: var(--bg-tertiary); color: var(--accent-color); } @media (max-width: 768px) { .tasks-stats-bar { flex-direction: column; gap: 12px; } .task-stat-item { flex-direction: row; justify-content: space-between; align-items: center; } .tasks-filters { flex-direction: column; align-items: stretch; } .tasks-filters select { min-width: 100%; } .tasks-batch-actions { flex-direction: column; align-items: stretch; } .page-header-actions { flex-direction: column; align-items: stretch; } .task-header { flex-direction: column; align-items: flex-start; } .task-actions { width: 100%; justify-content: flex-end; flex-wrap: wrap; } .task-duration { font-size: 0.75rem; padding: 2px 6px; } } /* 批量任务相关样式 */ .batch-queues-section { margin-top: 0; padding-top: 0; /* 确保底部左右角都是圆角 */ border-bottom-left-radius: 8px; border-bottom-right-radius: 8px; overflow: hidden; } .batch-queues-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; padding-bottom: 12px; } .batch-queues-header h3 { margin: 0; font-size: 1.125rem; font-weight: 600; color: var(--text-primary); } .batch-queues-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 16px; } .batch-queue-item { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; padding: 20px; box-shadow: var(--shadow-sm); transition: all 0.2s ease; cursor: pointer; } .batch-queue-item:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); border-color: var(--accent-color); } .batch-queue-header { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 12px; flex-wrap: wrap; } .batch-queue-info { display: flex; align-items: center; gap: 12px; flex: 1; flex-wrap: wrap; } .batch-queue-status { display: inline-flex; align-items: center; padding: 4px 12px; border-radius: 12px; font-size: 0.8125rem; font-weight: 500; white-space: nowrap; } .batch-queue-status-pending { background: rgba(108, 117, 125, 0.1); color: var(--text-secondary); border: 1px solid rgba(108, 117, 125, 0.3); } .batch-queue-status-running { background: rgba(0, 123, 255, 0.1); color: var(--accent-color); border: 1px solid rgba(0, 123, 255, 0.3); } .batch-queue-status-completed { background: rgba(40, 167, 69, 0.1); color: var(--success-color); border: 1px solid rgba(40, 167, 69, 0.3); } .batch-queue-status-cancelled { background: rgba(108, 117, 125, 0.1); color: var(--text-secondary); border: 1px solid rgba(108, 117, 125, 0.3); } .batch-queue-id { font-size: 0.8125rem; color: var(--text-secondary); font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; } .batch-queue-time { font-size: 0.8125rem; color: var(--text-secondary); } .batch-queue-progress { display: flex; align-items: center; gap: 12px; min-width: 200px; } .batch-queue-progress-bar { flex: 1; height: 8px; background: var(--bg-secondary); border-radius: 4px; overflow: hidden; } .batch-queue-progress-fill { height: 100%; background: linear-gradient(90deg, var(--accent-color) 0%, var(--accent-hover) 100%); transition: width 0.3s ease; } .batch-queue-progress-text { font-size: 0.8125rem; color: var(--text-secondary); white-space: nowrap; min-width: 60px; text-align: right; } .batch-queue-stats { display: flex; gap: 16px; flex-wrap: wrap; font-size: 0.8125rem; color: var(--text-secondary); } .batch-queue-stats span { white-space: nowrap; } .batch-queue-detail-info { margin-bottom: 24px; padding: 20px; background: var(--bg-secondary); border-radius: 12px; border: 1px solid var(--border-color); display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; } .batch-queue-detail-info .detail-item { display: flex; flex-direction: column; gap: 6px; padding: 12px; background: var(--bg-primary); border-radius: 8px; border: 1px solid var(--border-color); transition: all 0.2s ease; } .batch-queue-detail-info .detail-item:hover { border-color: var(--accent-color); box-shadow: 0 2px 8px rgba(0, 102, 255, 0.08); } .batch-queue-detail-info .detail-label { font-size: 0.75rem; color: var(--text-secondary); font-weight: 500; letter-spacing: 0.3px; text-transform: uppercase; } .batch-queue-detail-info .detail-value { font-size: 0.9375rem; color: var(--text-primary); font-weight: 500; word-break: break-word; } .batch-queue-detail-info .detail-value code { font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; font-size: 0.875rem; background: var(--bg-secondary); padding: 2px 6px; border-radius: 4px; color: var(--accent-color); } /* 批量队列详情弹窗:标题很长时避免挤压右侧按钮 */ #batch-queue-detail-modal .modal-header { align-items: flex-start; gap: 12px; } #batch-queue-detail-modal .modal-header > div { flex-shrink: 0; } #batch-queue-detail-modal .modal-header-actions { flex-direction: row; width: auto; flex-wrap: wrap; justify-content: flex-end; } #batch-queue-detail-modal .modal-header-actions button { white-space: nowrap; } .batch-queue-tasks-list { max-height: 500px; overflow-y: auto; } .batch-queue-tasks-list h4 { margin: 0 0 16px 0; font-size: 1rem; font-weight: 600; color: var(--text-primary); } .batch-task-item { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; padding: 16px; margin-bottom: 12px; transition: all 0.2s ease; } .batch-task-item:hover { box-shadow: var(--shadow-sm); } .batch-task-item-active { border-color: var(--accent-color); background: rgba(0, 102, 255, 0.02); } .batch-task-header { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; flex-wrap: wrap; } .batch-task-header .btn-small { margin-left: 0; flex-shrink: 0; } .batch-task-header .batch-task-edit-btn { /* 仅把“编辑”(首个操作按钮)推到最右,避免多个按钮都 margin-left:auto 导致挤压/错位 */ margin-left: auto; } .batch-task-header .batch-task-delete-btn { margin-left: 8px; } .batch-task-index { font-weight: 600; color: var(--text-secondary); min-width: 30px; } .batch-task-status { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: 8px; font-size: 0.75rem; font-weight: 500; white-space: nowrap; } .batch-task-status-pending { background: rgba(108, 117, 125, 0.1); color: var(--text-secondary); } .batch-task-status-running { background: rgba(0, 123, 255, 0.1); color: var(--accent-color); } .batch-task-status-completed { background: rgba(40, 167, 69, 0.1); color: var(--success-color); } .batch-task-status-failed { background: rgba(220, 53, 69, 0.1); color: var(--error-color); } .batch-task-status-cancelled { background: rgba(108, 117, 125, 0.1); color: var(--text-secondary); } .batch-task-message { flex: 1; font-size: 0.875rem; color: var(--text-primary); word-break: break-word; } .batch-task-time { font-size: 0.75rem; color: var(--text-secondary); margin-top: 4px; } .batch-task-error { font-size: 0.8125rem; color: var(--error-color); margin-top: 8px; padding: 8px; background: rgba(220, 53, 69, 0.05); border-radius: 4px; border-left: 3px solid var(--error-color); } .batch-task-result { font-size: 0.8125rem; color: var(--text-primary); margin-top: 8px; padding: 8px; background: var(--bg-secondary); border-radius: 4px; max-height: 150px; overflow-y: auto; word-break: break-word; } .batch-import-stats { display: none; padding: 8px 12px; background: rgba(0, 102, 255, 0.05); border: 1px solid rgba(0, 102, 255, 0.2); border-radius: 6px; font-size: 0.875rem; color: var(--accent-color); } .batch-import-stat { font-weight: 500; } @media (max-width: 768px) { .batch-queue-header { flex-direction: column; align-items: flex-start; } .batch-queue-progress { width: 100%; } .batch-queue-stats { flex-direction: column; gap: 8px; } .batch-task-header { flex-direction: column; align-items: flex-start; } } /* 漏洞管理页面样式 */ .vulnerability-dashboard { margin-bottom: 24px; } .dashboard-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; margin-bottom: 24px; } .stat-card { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; padding: 16px; text-align: center; box-shadow: var(--shadow-sm); transition: all 0.2s ease; } .stat-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); } .stat-card.stat-critical { border-left: 4px solid #dc3545; } .stat-card.stat-high { border-left: 4px solid #fd7e14; } .stat-card.stat-medium { border-left: 4px solid #ffc107; } .stat-card.stat-low { border-left: 4px solid #20c997; } .stat-card.stat-info { border-left: 4px solid #6c757d; } .stat-label { font-size: 0.875rem; color: var(--text-secondary); margin-bottom: 8px; } .stat-value { font-size: 2rem; font-weight: 700; color: var(--text-primary); } /* 仪表盘页面样式(最佳实践布局 + 视觉增强) */ .dashboard-page { height: 100%; display: flex; flex-direction: column; overflow: auto; background: linear-gradient(180deg, #eef2f7 0%, #f1f5f9 50%, #e2e8f0 100%); position: relative; } .dashboard-page::before { content: ''; position: absolute; inset: 0; background-image: radial-gradient(circle at 1px 1px, rgba(0,0,0,0.03) 1px, transparent 0); background-size: 24px 24px; pointer-events: none; } .dashboard-page .page-header { flex-shrink: 0; padding: 12px 24px; border-bottom: 1px solid rgba(0,0,0,0.06); background: rgba(255,255,255,0.95); backdrop-filter: blur(10px); box-shadow: 0 1px 0 rgba(255,255,255,0.8) inset; } .dashboard-page .page-header h2 { font-size: 1.25rem; font-weight: 700; letter-spacing: -0.02em; margin: 0; } .dashboard-content { flex: 1; padding: 24px; overflow: auto; width: 100%; box-sizing: border-box; } /* 第一行:核心 KPI(视觉层次 + 色块强调) */ .dashboard-kpi-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 24px; } @media (max-width: 900px) { .dashboard-kpi-row { grid-template-columns: repeat(2, 1fr); } } @media (max-width: 480px) { .dashboard-kpi-row { grid-template-columns: 1fr; } } .dashboard-kpi-card { background: #fff; border-radius: 14px; padding: 22px; cursor: pointer; transition: transform 0.2s ease, box-shadow 0.25s ease; border: 1px solid rgba(0,0,0,0.06); box-shadow: 0 2px 8px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04); position: relative; } .dashboard-kpi-card:nth-child(1) { background: linear-gradient(145deg, #fff 0%, #f0f9ff 100%); } .dashboard-kpi-card:nth-child(2) { background: linear-gradient(145deg, #fff 0%, #fef2f2 100%); } .dashboard-kpi-card:nth-child(3) { background: linear-gradient(145deg, #fff 0%, #f0fdf4 100%); } .dashboard-kpi-card:nth-child(4) { background: linear-gradient(145deg, #fff 0%, #f0fdfa 100%); } .dashboard-kpi-card:hover { transform: translateY(-3px); box-shadow: 0 12px 24px rgba(0,0,0,0.08), 0 4px 12px rgba(0,102,255,0.08); border-color: rgba(0, 102, 255, 0.2); } .dashboard-kpi-value { font-size: 1.875rem; font-weight: 800; color: var(--text-primary); line-height: 1.2; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; } .dashboard-kpi-card:focus-visible { outline: 2px solid rgba(0, 102, 255, 0.5); outline-offset: 2px; } .dashboard-kpi-label { font-size: 0.8125rem; color: var(--text-secondary); margin-top: 8px; font-weight: 500; } /* 两列主内容网格 */ .dashboard-grid { display: grid; grid-template-columns: 1fr 380px; gap: 24px; align-items: start; } @media (max-width: 1100px) { .dashboard-grid { grid-template-columns: 1fr; } } .dashboard-main { display: flex; flex-direction: column; gap: 24px; } .dashboard-side { display: flex; flex-direction: column; gap: 24px; } .dashboard-grid .dashboard-section { margin-bottom: 0; background: rgba(255, 255, 255, 0.95); border-radius: 14px; padding: 22px; box-shadow: 0 2px 12px rgba(0,0,0,0.06), 0 1px 4px rgba(0,0,0,0.04); border: 1px solid rgba(0,0,0,0.05); transition: box-shadow 0.25s ease; position: relative; } .dashboard-grid .dashboard-section:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.07), 0 2px 8px rgba(0,0,0,0.04); } .dashboard-section-title { display: block; font-size: 0.9375rem; font-weight: 700; color: var(--text-primary); margin: 0 0 16px 0; padding-bottom: 10px; border-bottom: 2px solid #f1f5f9; letter-spacing: -0.01em; } .dashboard-overview-list { display: flex; flex-direction: column; gap: 12px; } .dashboard-overview-item { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; background: linear-gradient(135deg, #fafbfc 0%, #f8fafc 100%); border-radius: 10px; border: 1px solid rgba(0,0,0,0.05); cursor: pointer; transition: border-color 0.2s, background 0.2s, transform 0.2s; } .dashboard-overview-item:hover { border-color: rgba(0, 102, 255, 0.25); background: linear-gradient(135deg, rgba(0,102,255,0.04) 0%, rgba(0,102,255,0.06) 100%); transform: translateX(4px); } .dashboard-overview-item:focus-visible { outline: 2px solid rgba(0, 102, 255, 0.5); outline-offset: 2px; } .dashboard-overview-icon { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 8px; background: rgba(0, 102, 255, 0.08); color: #0369a1; flex-shrink: 0; } .dashboard-overview-item > div { min-width: 0; } .dashboard-overview-label { display: block; font-size: 0.8rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 4px; } .dashboard-overview-value { font-size: 0.9rem; color: var(--text-primary); } /* 运行概览优化样式 */ .dashboard-overview-content { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; } .dashboard-overview-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 2px; } .dashboard-overview-total { font-size: 0.75rem; font-weight: 600; color: var(--text-secondary); background: rgba(0, 102, 255, 0.08); padding: 2px 8px; border-radius: 12px; } .dashboard-overview-success-rate { font-size: 0.75rem; font-weight: 600; color: #10b981; background: rgba(16, 185, 129, 0.1); padding: 2px 8px; border-radius: 12px; } .dashboard-overview-status { font-size: 0.75rem; font-weight: 600; color: var(--text-secondary); background: rgba(0, 0, 0, 0.05); padding: 2px 8px; border-radius: 12px; } .dashboard-overview-stats { display: flex; gap: 16px; flex-wrap: wrap; } .dashboard-overview-stat { display: flex; align-items: center; gap: 6px; font-size: 0.8125rem; } .dashboard-overview-stat-badge { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite; } .dashboard-overview-stat-badge.badge-pending { background: #f59e0b; box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.7); } .dashboard-overview-stat-badge.badge-running { background: #3b82f6; box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7); animation: pulse-running 1.5s cubic-bezier(0.4, 0, 0.6, 1) infinite; } .dashboard-overview-stat-badge.badge-done { background: #10b981; } @keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } } @keyframes pulse-running { 0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7); } 50% { opacity: 0.8; box-shadow: 0 0 0 4px rgba(59, 130, 246, 0); } } .dashboard-overview-stat-value { font-weight: 700; font-size: 0.9375rem; color: var(--text-primary); font-variant-numeric: tabular-nums; } .dashboard-overview-stat-label { color: var(--text-secondary); font-size: 0.8125rem; } .dashboard-overview-progress { margin-top: 4px; } .dashboard-overview-progress-bar { height: 6px; background: #f1f5f9; border-radius: 3px; overflow: hidden; display: flex; position: relative; } .dashboard-overview-progress-segment { height: 100%; transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1); position: relative; } .dashboard-overview-progress-pending { background: linear-gradient(90deg, #fbbf24, #f59e0b); } .dashboard-overview-progress-running { background: linear-gradient(90deg, #60a5fa, #3b82f6); animation: shimmer 2s infinite; } .dashboard-overview-progress-done { background: linear-gradient(90deg, #34d399, #10b981); } @keyframes shimmer { 0% { opacity: 1; } 50% { opacity: 0.8; } 100% { opacity: 1; } } .dashboard-overview-value-group { display: flex; align-items: baseline; gap: 4px; flex-wrap: wrap; } .dashboard-overview-value-large { font-size: 1.25rem; font-weight: 800; color: var(--text-primary); font-variant-numeric: tabular-nums; letter-spacing: -0.02em; line-height: 1.2; } .dashboard-overview-value-normal { font-size: 0.9375rem; font-weight: 600; color: var(--text-primary); font-variant-numeric: tabular-nums; } .dashboard-overview-value-unit { font-size: 0.8125rem; color: var(--text-secondary); font-weight: 500; } .dashboard-overview-value-separator { color: var(--text-secondary); opacity: 0.4; margin: 0 2px; } /* 不同模块的图标颜色 */ .dashboard-overview-icon-batch { background: rgba(245, 158, 11, 0.1); color: #d97706; } .dashboard-overview-icon-tools { background: rgba(59, 130, 246, 0.1); color: #2563eb; } .dashboard-overview-icon-knowledge { background: rgba(139, 92, 246, 0.1); color: #7c3aed; } .dashboard-overview-icon-skills { background: rgba(236, 72, 153, 0.1); color: #db2777; } /* 悬停效果增强 */ .dashboard-overview-item:hover .dashboard-overview-icon { transform: scale(1.1); transition: transform 0.2s ease; } .dashboard-overview-item:hover .dashboard-overview-value-large { color: #0066ff; transition: color 0.2s ease; } .dashboard-overview-item-batch:hover { border-color: rgba(245, 158, 11, 0.3); background: linear-gradient(135deg, rgba(245,158,11,0.06) 0%, rgba(245,158,11,0.08) 100%); } .dashboard-overview-item-tools:hover { border-color: rgba(59, 130, 246, 0.3); background: linear-gradient(135deg, rgba(59,130,246,0.06) 0%, rgba(59,130,246,0.08) 100%); } .dashboard-overview-item-knowledge:hover { border-color: rgba(139, 92, 246, 0.3); background: linear-gradient(135deg, rgba(139,92,246,0.06) 0%, rgba(139,92,246,0.08) 100%); } .dashboard-overview-item-skills:hover { border-color: rgba(236, 72, 153, 0.3); background: linear-gradient(135deg, rgba(236,72,153,0.06) 0%, rgba(236,72,153,0.08) 100%); } /* 响应式优化 */ @media (max-width: 768px) { .dashboard-overview-stats { gap: 12px; } .dashboard-overview-value-group { flex-direction: column; align-items: flex-start; gap: 2px; } .dashboard-overview-value-separator { display: none; } } .dashboard-chart-wrap { display: flex; flex-direction: column; gap: 20px; } .dashboard-stacked-bar { display: flex; width: 100%; height: 28px; border-radius: 14px; overflow: hidden; background: #f1f5f9; } .dashboard-bar-seg { height: 100%; min-width: 2px; transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1); opacity: 0.92; border-right: 1px solid rgba(241, 245, 249, 0.9); box-sizing: border-box; } .dashboard-bar-seg:first-child { border-radius: 14px 0 0 14px; } .dashboard-bar-seg:last-child { border-right: none; border-radius: 0 14px 14px 0; } /* 严重→信息:柔和连续色阶,红→橙→黄→绿→蓝,无灰沉感 */ .dashboard-bar-seg.seg-critical { background: linear-gradient(90deg, #f87171, #fca5a5); } .dashboard-bar-seg.seg-high { background: linear-gradient(90deg, #fb923c, #fdba74); } .dashboard-bar-seg.seg-medium { background: linear-gradient(90deg, #facc15, #fde047); } .dashboard-bar-seg.seg-low { background: linear-gradient(90deg, #34d399, #6ee7b7); } .dashboard-bar-seg.seg-info { background: linear-gradient(90deg, #60a5fa, #93c5fd); } .dashboard-legend { display: flex; flex-wrap: wrap; gap: 16px 32px; align-items: center; } .dashboard-legend-item { display: inline-flex; align-items: center; gap: 8px; font-size: 0.875rem; padding: 6px 12px; background: #f8fafc; border-radius: 20px; transition: background 0.2s; } .dashboard-legend-item:hover { background: #f1f5f9; } .dashboard-legend-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; box-shadow: 0 0 0 2px rgba(255,255,255,0.8); } /* 与条形图同色系,图例与条形视觉一致 */ .dashboard-legend-dot.critical { background: #f87171; } .dashboard-legend-dot.high { background: #fb923c; } .dashboard-legend-dot.medium { background: #facc15; } .dashboard-legend-dot.low { background: #34d399; } .dashboard-legend-dot.info { background: #60a5fa; } .dashboard-legend-label { color: var(--text-secondary); } .dashboard-legend-value { font-weight: 700; color: var(--text-primary); min-width: 1.5em; } .dashboard-quick-links { display: grid; grid-template-columns: 1fr; gap: 10px; } /* 主内容区:快捷入口横向排列,按钮保持自然宽度不拉伸 */ .dashboard-quick-links-row { display: flex; flex-wrap: wrap; gap: 12px; } .dashboard-quick-inline .dashboard-quick-link { flex: 0 0 auto; width: auto; min-width: unset; padding: 8px 14px; } /* 主内容区快捷入口:去掉图标外层的“涂层”,降低按钮高度 */ .dashboard-quick-inline .dashboard-quick-icon { width: auto; height: auto; min-width: unset; padding: 0; border-radius: 0; background: transparent; box-shadow: none; } .dashboard-quick-inline .dashboard-quick-link:hover .dashboard-quick-icon { background: transparent; box-shadow: none; } @media (max-width: 1000px) { .dashboard-quick-links:not(.dashboard-quick-links-row) { grid-template-columns: repeat(2, 1fr); } } @media (max-width: 480px) { .dashboard-quick-links:not(.dashboard-quick-links-row) { grid-template-columns: 1fr; } } .dashboard-quick-link { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: linear-gradient(135deg, #fafbfc 0%, #f8fafc 100%); border: 1px solid rgba(0,0,0,0.06); border-radius: 10px; color: var(--text-primary); font-size: 0.875rem; font-weight: 500; text-decoration: none; cursor: pointer; transition: all 0.25s ease; } .dashboard-quick-link:hover { border-color: rgba(0, 102, 255, 0.3); background: linear-gradient(135deg, rgba(0,102,255,0.06) 0%, rgba(0,102,255,0.04) 100%); color: var(--text-primary); transform: translateX(4px); box-shadow: 0 2px 8px rgba(0,102,255,0.08); } .dashboard-quick-link:focus-visible { outline: 2px solid rgba(0, 102, 255, 0.5); outline-offset: 2px; } .dashboard-quick-icon { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 10px; background: #fff; color: var(--text-secondary); box-shadow: 0 1px 3px rgba(0,0,0,0.06); transition: color 0.2s, background 0.2s, box-shadow 0.2s; } .dashboard-quick-link:hover .dashboard-quick-icon { color: #0369a1; background: rgba(3, 105, 161, 0.1); box-shadow: 0 2px 8px rgba(3, 105, 161, 0.15); } /* 工具执行次数(仅柱状图) */ .dashboard-section-tools .dashboard-section-title { margin-bottom: 12px; } .dashboard-tools-chart-wrap { display: flex; flex-direction: column; min-width: 0; flex: 1; } .dashboard-tools-chart-placeholder { display: flex; align-items: center; justify-content: center; min-height: 120px; flex: 1; font-size: 0.8125rem; color: var(--text-muted); background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%); border-radius: 10px; border: 1px dashed #cbd5e1; } .dashboard-tools-bar-chart { display: flex; flex-direction: column; gap: 10px; } .dashboard-tools-bar-item { display: grid; grid-template-columns: 82px 1fr 36px; gap: 12px; align-items: center; font-size: 0.8125rem; } .dashboard-tools-bar-label { color: var(--text-secondary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .dashboard-tools-bar-track { height: 18px; background: #f1f5f9; border-radius: 9px; overflow: hidden; } .dashboard-tools-bar-fill { height: 100%; border-radius: 9px; min-width: 6px; transform-origin: left; animation: dashboard-bar-fill-in 0.8s cubic-bezier(0.25, 0.1, 0.25, 1) forwards; opacity: 0.92; } @keyframes dashboard-bar-fill-in { from { transform: scaleX(0); } to { transform: scaleX(1); } } .dashboard-tools-bar-value { font-weight: 600; color: var(--text-secondary); font-size: 0.8125rem; text-align: right; font-variant-numeric: tabular-nums; } .dashboard-tools-bar-tooltip { display: none; position: fixed; left: 0; top: 0; z-index: 10000; max-width: 320px; padding: 6px 10px; font-size: 0.8125rem; line-height: 1.4; color: #fff; background: rgba(15, 23, 42, 0.95); border-radius: 6px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2); pointer-events: none; word-break: break-all; } .dashboard-cta-block { position: relative; margin-top: 24px; padding: 24px 28px; background: linear-gradient(90deg, rgba(14, 165, 233, 0.12) 0%, rgba(14, 165, 233, 0.04) 22%, transparent 38%), linear-gradient(135deg, rgba(255,255,255,0.98) 0%, rgba(241,245,249,0.95) 50%, rgba(226,232,240,0.4) 100%); border: 1px solid rgba(2, 132, 199, 0.12); border-radius: 16px; display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; box-shadow: 0 4px 20px rgba(0,0,0,0.06), 0 1px 4px rgba(0,0,0,0.04), inset 0 1px 0 rgba(255,255,255,0.8); overflow: hidden; } .dashboard-cta-content { display: flex; align-items: center; gap: 16px; flex: 1; min-width: 0; } .dashboard-cta-icon { flex-shrink: 0; width: 48px; height: 48px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, rgba(14, 165, 233, 0.15) 0%, rgba(2, 132, 199, 0.1) 100%); color: #0284c7; border-radius: 12px; } .dashboard-cta-copy { min-width: 0; } .dashboard-cta-text { font-size: 1.125rem; font-weight: 700; color: var(--text-primary); margin: 0 0 4px 0; letter-spacing: -0.02em; line-height: 1.3; } .dashboard-cta-sub { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; line-height: 1.4; max-width: 420px; } .dashboard-cta-btn { flex-shrink: 0; display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px 12px 22px; background: linear-gradient(135deg, #0369a1 0%, #0284c7 48%, #0ea5e9 100%); border: none; border-radius: 12px; color: #fff; font-size: 0.9375rem; font-weight: 600; cursor: pointer; transition: transform 0.2s ease, box-shadow 0.25s ease, filter 0.2s; box-shadow: 0 4px 14px rgba(2, 132, 199, 0.35); } .dashboard-cta-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(2, 132, 199, 0.45); filter: brightness(1.06); } .dashboard-cta-btn-arrow { display: inline-flex; opacity: 0.9; transition: transform 0.2s ease; } .dashboard-cta-btn:hover .dashboard-cta-btn-arrow { transform: translateX(2px); } .dashboard-cta-btn:focus-visible { outline: 2px solid rgba(255, 255, 255, 0.8); outline-offset: 2px; } /* 尊重用户“减少动效”偏好(无障碍最佳实践) */ @media (prefers-reduced-motion: reduce) { .dashboard-kpi-card, .dashboard-overview-item, .dashboard-quick-link, .dashboard-cta-btn { transition: none; } .dashboard-kpi-card:hover, .dashboard-overview-item:hover { transform: none; } .dashboard-quick-link:hover { transform: none; } .dashboard-cta-btn:hover { transform: none; } .dashboard-cta-btn:hover .dashboard-cta-btn-arrow { transform: none; } .dashboard-cta-btn-arrow { transition: none; } .dashboard-tools-bar-fill { animation: none; } .dashboard-bar-seg { transition: none; } } .vulnerability-controls { margin-bottom: 24px; } .vulnerability-filters { display: flex; gap: 16px; flex-wrap: wrap; align-items: flex-end; } .vulnerability-filters label { display: flex; flex-direction: column; gap: 4px; font-size: 0.875rem; color: var(--text-secondary); } .vulnerability-filters input, .vulnerability-filters select { padding: 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; min-width: 150px; } .vulnerabilities-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 0; } .vulnerability-card { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; padding: 20px; box-shadow: var(--shadow-sm); transition: all 0.2s ease; } .vulnerability-card:hover { box-shadow: var(--shadow-md); } .vulnerability-card.severity-critical { border-left: 4px solid #dc3545; } .vulnerability-card.severity-high { border-left: 4px solid #fd7e14; } .vulnerability-card.severity-medium { border-left: 4px solid #ffc107; } .vulnerability-card.severity-low { border-left: 4px solid #20c997; } .vulnerability-card.severity-info { border-left: 4px solid #6c757d; } .vulnerability-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 0; padding: 4px 0; transition: background-color 0.2s ease; } .vulnerability-header:hover { background-color: var(--bg-secondary); border-radius: 4px; } .vulnerability-title-section { flex: 1; } .vulnerability-title { font-size: 1.125rem; font-weight: 600; color: var(--text-primary); margin-bottom: 8px; flex: 1; } .vulnerability-expand-icon { color: var(--text-secondary); transition: transform 0.2s ease, color 0.2s ease; } .vulnerability-header:hover .vulnerability-expand-icon { color: var(--accent-color); } .vulnerability-meta { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; } .severity-badge { display: inline-block; padding: 4px 12px; border-radius: 12px; font-size: 0.75rem; font-weight: 600; text-transform: uppercase; } .severity-badge.severity-critical { background: rgba(220, 53, 69, 0.1); color: #dc3545; } .severity-badge.severity-high { background: rgba(253, 126, 20, 0.1); color: #fd7e14; } .severity-badge.severity-medium { background: rgba(255, 193, 7, 0.1); color: #ffc107; } .severity-badge.severity-low { background: rgba(32, 201, 151, 0.1); color: #20c997; } .severity-badge.severity-info { background: rgba(108, 117, 125, 0.1); color: #6c757d; } .status-badge { display: inline-block; padding: 4px 12px; border-radius: 12px; font-size: 0.75rem; font-weight: 500; background: var(--bg-tertiary); color: var(--text-secondary); } .status-badge.status-open { background: rgba(0, 102, 255, 0.1); color: #0066ff; } .status-badge.status-confirmed { background: rgba(40, 167, 69, 0.1); color: #28a745; } .status-badge.status-fixed { background: rgba(108, 117, 125, 0.1); color: #6c757d; } .status-badge.status-false_positive { background: rgba(220, 53, 69, 0.1); color: #dc3545; } .vulnerability-date { font-size: 0.75rem; color: var(--text-muted); } .vulnerability-actions { display: flex; gap: 8px; } .vulnerability-content { margin-top: 16px; padding-left: 24px; animation: slideDown 0.2s ease; } @keyframes slideDown { from { opacity: 0; max-height: 0; } to { opacity: 1; max-height: 5000px; } } .vulnerability-description { margin-bottom: 16px; color: var(--text-primary); line-height: 1.6; } .vulnerability-details { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; margin-bottom: 16px; padding: 12px; background: var(--bg-secondary); border-radius: 6px; } .detail-item { font-size: 0.875rem; } .detail-item strong { color: var(--text-secondary); margin-right: 4px; } .detail-item code { background: var(--bg-tertiary); padding: 2px 6px; border-radius: 4px; font-size: 0.8rem; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; } .vulnerability-proof, .vulnerability-impact, .vulnerability-recommendation { margin-top: 12px; padding: 12px; background: var(--bg-secondary); border-radius: 6px; font-size: 0.875rem; line-height: 1.6; } .vulnerability-proof pre { margin-top: 8px; padding: 12px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 4px; overflow-x: auto; font-size: 0.8rem; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; white-space: pre-wrap; word-wrap: break-word; } .vulnerability-proof strong, .vulnerability-impact strong, .vulnerability-recommendation strong { color: var(--text-primary); display: block; margin-bottom: 8px; } .empty-state { text-align: center; padding: 48px; color: var(--text-secondary); font-size: 1rem; } /* ==================== 攻击链可视化响应式样式 ==================== */ @media (max-width: 1200px) { .attack-chain-modal-content { width: 98vw; height: 92vh; max-height: 92vh; } .attack-chain-sidebar { width: 240px; } .attack-chain-toolbar { padding: 10px 12px; gap: 12px; } .attack-chain-filters { gap: 6px; } .attack-chain-filters input[type="text"] { min-width: 150px; max-width: 250px; } .attack-chain-container { margin: 10px; } } @media (max-width: 768px) { .attack-chain-modal-content { width: 100vw; height: 100vh; max-height: 100vh; border-radius: 0; } .attack-chain-main-layout { flex-direction: column; } .attack-chain-sidebar { width: 100%; max-height: 200px; border-left: none; border-top: 1px solid rgba(0, 0, 0, 0.06); order: 2; } .attack-chain-visualization-area { order: 1; } .attack-chain-toolbar { flex-direction: column; align-items: stretch; gap: 10px; padding: 10px 12px; } .attack-chain-info { text-align: center; width: 100%; } .attack-chain-filters { flex-direction: column; width: 100%; } .attack-chain-filters input[type="text"], .attack-chain-filters select, .attack-chain-filters button { width: 100%; min-width: auto; max-width: none; } .attack-chain-legend { flex-direction: row; gap: 16px; padding: 12px; overflow-x: auto; } .legend-section { min-width: 160px; flex-shrink: 0; } .attack-chain-details { min-width: 200px; flex-shrink: 0; } .attack-chain-details-content { max-height: 400px; } .attack-chain-container { margin: 8px; border-radius: 10px; } .attack-chain-details { margin: 0 8px 8px 8px; border-radius: 10px; padding: 12px 16px; } .modal-header { padding: 12px 16px !important; } .modal-header h2 { font-size: 1.125rem !important; } .modal-header-actions { flex-direction: column; width: 100%; gap: 6px; } /* 批量队列详情弹窗:即使在窄屏也保持按钮不“变形” */ #batch-queue-detail-modal .modal-header-actions { flex-direction: row; width: auto; gap: 8px; } .attack-chain-action-btn { width: 100%; justify-content: center; padding: 7px 14px !important; font-size: 0.8125rem !important; } } /* 角色选择器样式 */ .role-selector-btn { display: flex; align-items: center; gap: 6px; padding: 10px 12px; height: 40px; background: #ffffff; border: 1px solid rgba(0, 0, 0, 0.1); border-radius: 12px; color: var(--text-primary); cursor: pointer; transition: all 0.2s; flex-shrink: 0; font-size: 0.9375rem; font-weight: 500; white-space: nowrap; box-sizing: border-box; } .role-selector-btn:hover { background: #f8f9fa; border-color: rgba(0, 102, 255, 0.3); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.08); } .role-selector-btn:active { transform: scale(0.98); background: #f0f2f5; } .role-selector-btn.active { background: #f0f2f5; border-color: rgba(0, 102, 255, 0.4); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.12); } .role-selector-btn.active .role-selector-arrow { transform: rotate(180deg); color: rgba(0, 102, 255, 0.8); } .role-selector-icon { font-size: 1rem; line-height: 1; flex-shrink: 0; display: flex; align-items: center; justify-content: center; } .role-selector-text { font-size: 0.875rem; font-weight: 500; color: var(--text-primary); flex-shrink: 0; } .role-selector-arrow { width: 10px; height: 10px; color: rgba(0, 0, 0, 0.4); flex-shrink: 0; transition: transform 0.2s, color 0.2s; } .role-selector-btn:hover .role-selector-arrow { color: rgba(0, 102, 255, 0.6); } /* 角色选择器包装器 */ .role-selector-wrapper { position: relative; flex-shrink: 0; } /* 主内容区域角色选择面板样式(下拉菜单形式) */ .role-selection-panel { position: absolute; bottom: calc(100% + 8px); left: 0; width: 340px; max-width: calc(100vw - 32px); max-height: 60vh; background: #ffffff; border: 1px solid rgba(0, 0, 0, 0.08); border-radius: 16px; padding: 12px; box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12), 0 4px 16px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(0, 0, 0, 0.04); z-index: 1000; overflow: hidden; display: flex; flex-direction: column; animation: slideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1); backdrop-filter: blur(20px); } @keyframes slideUp { from { opacity: 0; transform: translateY(8px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } } .role-selection-panel-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; padding: 10px 4px 12px 4px; border-bottom: 1px solid rgba(0, 0, 0, 0.06); position: sticky; top: 0; background: #ffffff; z-index: 10; } .role-selection-panel-title { font-size: 0.9375rem; font-weight: 600; color: #1a1a1a; margin: 0; letter-spacing: -0.01em; } .role-selection-panel-close { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border: none; background: transparent; border-radius: 8px; cursor: pointer; color: #666666; transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1); padding: 0; } .role-selection-panel-close:hover { background: rgba(0, 0, 0, 0.06); color: #1a1a1a; transform: rotate(90deg); } .role-selection-panel-close:active { transform: rotate(90deg) scale(0.95); } .role-selection-list-main { display: flex; flex-direction: column; gap: 6px; /* 限制显示8个角色:每个角色约70px高度 + gap,8个角色约580px */ max-height: 580px; overflow-y: auto; padding-right: 6px; flex: 1; } .role-selection-list-main::-webkit-scrollbar { width: 8px; } .role-selection-list-main::-webkit-scrollbar-track { background: transparent; } .role-selection-list-main::-webkit-scrollbar-thumb { background: rgba(0, 0, 0, 0.16); border-radius: 4px; border: 2px solid transparent; background-clip: padding-box; } .role-selection-list-main::-webkit-scrollbar-thumb:hover { background: rgba(0, 0, 0, 0.24); background-clip: padding-box; } .role-selection-item-main { display: flex; flex-direction: row; align-items: flex-start; gap: 12px; padding: 12px; border: 1.5px solid rgba(0, 0, 0, 0.06); border-radius: 12px; background: #ffffff; cursor: pointer; transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1); position: relative; } .role-selection-item-main:hover { background: linear-gradient(135deg, rgba(138, 43, 226, 0.04) 0%, rgba(138, 43, 226, 0.02) 100%); border-color: rgba(138, 43, 226, 0.2); box-shadow: 0 2px 8px rgba(138, 43, 226, 0.08); transform: translateY(-1px); } .role-selection-item-main.selected { background: linear-gradient(135deg, rgba(138, 43, 226, 0.12) 0%, rgba(138, 43, 226, 0.06) 100%); border-color: rgba(138, 43, 226, 0.4); box-shadow: 0 4px 12px rgba(138, 43, 226, 0.15), 0 0 0 1px rgba(138, 43, 226, 0.1); } .role-selection-item-main:active { transform: translateY(0) scale(0.98); } .role-selection-item-icon-main { font-size: 1.25rem; flex-shrink: 0; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, rgba(0, 0, 0, 0.04) 0%, rgba(0, 0, 0, 0.02) 100%); border-radius: 10px; transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1); border: 1px solid rgba(0, 0, 0, 0.04); } .role-selection-item-main:hover .role-selection-item-icon-main { background: linear-gradient(135deg, rgba(138, 43, 226, 0.1) 0%, rgba(138, 43, 226, 0.05) 100%); border-color: rgba(138, 43, 226, 0.15); transform: scale(1.05); } .role-selection-item-main.selected .role-selection-item-icon-main { background: linear-gradient(135deg, rgba(138, 43, 226, 0.2) 0%, rgba(138, 43, 226, 0.12) 100%); border-color: rgba(138, 43, 226, 0.3); box-shadow: 0 2px 6px rgba(138, 43, 226, 0.2); } .role-selection-item-content-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; padding-top: 2px; } .role-selection-item-name-main { font-weight: 500; color: #1a1a1a; font-size: 0.875rem; line-height: 1.4; margin: 0; transition: color 0.2s cubic-bezier(0.16, 1, 0.3, 1); letter-spacing: -0.01em; } .role-selection-item-main.selected .role-selection-item-name-main { color: #6a1bb2; font-weight: 600; } .role-selection-item-description-main { font-size: 0.75rem; color: #666666; line-height: 1.4; margin: 0; display: -webkit-box; -webkit-line-clamp: 1; line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis; transition: color 0.2s; } .role-selection-item-main.selected .role-selection-item-description-main { color: #8a5ab8; } .role-selection-checkmark-main { position: absolute; top: 10px; right: 10px; width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #8a2be2 0%, #6a1bb2 100%); color: white; border-radius: 50%; font-size: 0.6875rem; font-weight: 700; flex-shrink: 0; box-shadow: 0 2px 8px rgba(138, 43, 226, 0.4); animation: checkmarkPop 0.3s cubic-bezier(0.16, 1, 0.3, 1); } @keyframes checkmarkPop { 0% { transform: scale(0); opacity: 0; } 50% { transform: scale(1.1); } 100% { transform: scale(1); opacity: 1; } } @keyframes highlight-flash { 0%, 100% { background-color: transparent; } 50% { background-color: rgba(138, 43, 226, 0.1); } } .role-select-item { display: flex; align-items: flex-start; gap: 14px; padding: 16px 18px; border: 2px solid var(--border-color); border-radius: 12px; background: var(--bg-primary); cursor: pointer; transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1); position: relative; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05); } .role-select-item::before { content: ''; position: absolute; top: 0; left: 0; right: 0; bottom: 0; border-radius: 12px; background: linear-gradient(135deg, rgba(138, 43, 226, 0.03) 0%, rgba(138, 43, 226, 0.01) 100%); opacity: 0; transition: opacity 0.25s; } .role-select-item:hover { background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%); border-color: rgba(138, 43, 226, 0.3); box-shadow: 0 4px 12px rgba(138, 43, 226, 0.1), 0 2px 4px rgba(0, 0, 0, 0.08); transform: translateY(-2px); } .role-select-item:hover::before { opacity: 1; } .role-select-item.selected { background: linear-gradient(135deg, rgba(138, 43, 226, 0.1) 0%, rgba(138, 43, 226, 0.05) 100%); border-color: #8a2be2; box-shadow: 0 4px 16px rgba(138, 43, 226, 0.2), 0 2px 8px rgba(138, 43, 226, 0.15); transform: translateY(-2px); } .role-select-item.selected::before { opacity: 1; background: linear-gradient(135deg, rgba(138, 43, 226, 0.08) 0%, rgba(138, 43, 226, 0.03) 100%); } .role-select-item.selected::after { content: '✓'; position: absolute; top: 12px; right: 14px; width: 24px; height: 24px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #8a2be2 0%, #6a1bb2 100%); color: white; border-radius: 50%; font-size: 0.75rem; font-weight: 700; box-shadow: 0 2px 6px rgba(138, 43, 226, 0.4); } .role-select-item-icon { font-size: 1.5rem; flex-shrink: 0; width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%); border-radius: 10px; transition: all 0.25s; border: 1px solid rgba(0, 0, 0, 0.05); } .role-select-item.selected .role-select-item-icon { background: linear-gradient(135deg, rgba(138, 43, 226, 0.15) 0%, rgba(138, 43, 226, 0.08) 100%); border-color: rgba(138, 43, 226, 0.2); transform: scale(1.05); } .role-select-item-content { flex: 1; display: flex; flex-direction: column; gap: 6px; min-width: 0; } .role-select-item-name { font-weight: 600; color: var(--text-primary); font-size: 1rem; line-height: 1.4; margin: 0; transition: color 0.2s; } .role-select-item.selected .role-select-item-name { color: #8a2be2; } .role-select-item-description { font-size: 0.8125rem; color: var(--text-secondary); line-height: 1.5; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis; } /* 角色管理页面样式 */ .roles-controls { margin-bottom: 24px; } .roles-stats-bar { display: flex; gap: 16px; padding: 16px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; } .role-stat-item { display: flex; flex-direction: column; gap: 4px; } .role-stat-label { font-size: 0.8125rem; color: var(--text-secondary); } .role-stat-value { font-size: 1.25rem; font-weight: 600; color: var(--text-primary); } .roles-list { display: flex; flex-direction: column; gap: 12px; } /* 角色搜索框样式 */ .roles-search-box { position: relative; margin-bottom: 20px; } .roles-search-box input { width: 100%; padding: 10px 40px 10px 16px; border: 1px solid var(--border-color); border-radius: 8px; background: var(--bg-primary); color: var(--text-primary); font-size: 0.9375rem; transition: all 0.2s; } .roles-search-box input:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1); } .roles-search-clear { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--text-secondary); padding: 4px; display: flex; align-items: center; justify-content: center; transition: color 0.2s; } .roles-search-clear:hover { color: var(--text-primary); } /* 角色卡片网格布局 */ .roles-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; padding: 0; } /* 角色卡片样式 */ .role-card { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; padding: 20px; display: flex; flex-direction: column; gap: 12px; transition: all 0.2s; cursor: default; } .role-card:hover { box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); border-color: var(--accent-color); transform: translateY(-2px); } .role-card-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; } .role-card-title { font-size: 1.125rem; font-weight: 600; color: var(--text-primary); margin: 0; flex: 1; line-height: 1.4; display: flex; align-items: center; gap: 8px; } .role-card-icon { font-size: 1.25rem; line-height: 1; flex-shrink: 0; } .role-card-badge { padding: 4px 10px; border-radius: 12px; font-size: 0.75rem; font-weight: 600; white-space: nowrap; flex-shrink: 0; } .role-card-badge.enabled { background: rgba(40, 167, 69, 0.12); color: var(--success-color); } .role-card-badge.disabled { background: rgba(220, 53, 69, 0.12); color: var(--error-color); } .role-card-description { font-size: 0.875rem; color: var(--text-secondary); line-height: 1.5; flex: 1; min-height: 40px; } .role-card-tools { display: flex; gap: 8px; font-size: 0.8125rem; color: var(--text-secondary); padding-top: 8px; border-top: 1px solid var(--border-color); } .role-card-tools-label { font-weight: 500; white-space: nowrap; } .role-card-tools-value { color: var(--text-primary); flex: 1; word-break: break-word; } .role-card-actions { display: flex; gap: 8px; margin-top: 4px; } .btn-small { padding: 6px 12px; font-size: 0.8125rem; } .role-item { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; padding: 16px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; transition: all 0.2s; } .role-item:hover { box-shadow: var(--shadow-sm); border-color: var(--accent-color); } .role-item-content { flex: 1; display: flex; flex-direction: column; gap: 8px; } .role-item-header { display: flex; align-items: center; gap: 12px; } .role-item-name { font-size: 1rem; font-weight: 600; color: var(--text-primary); } .role-item-badge { padding: 4px 10px; border-radius: 12px; font-size: 0.75rem; font-weight: 600; } .role-item-badge.enabled { background: rgba(40, 167, 69, 0.12); color: var(--success-color); } .role-item-badge.disabled { background: rgba(220, 53, 69, 0.12); color: var(--error-color); } .role-item-description { font-size: 0.875rem; color: var(--text-secondary); line-height: 1.5; } .role-item-details { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; } .role-item-detail { display: flex; gap: 8px; font-size: 0.8125rem; } .role-item-detail-label { color: var(--text-secondary); font-weight: 500; min-width: 80px; } .role-item-detail-value { color: var(--text-primary); flex: 1; word-break: break-word; } .role-item-actions { display: flex; gap: 8px; flex-shrink: 0; } .empty-state { padding: 48px 24px; text-align: center; color: var(--text-secondary); font-size: 0.9375rem; } /* 角色MCP选择列表样式 */ .role-mcps-list { margin-top: 8px; border: 1px solid var(--border-color); border-radius: 8px; background: var(--bg-primary); min-height: 120px; max-height: 300px; overflow-y: auto; padding: 12px; } .role-mcps-checkbox-list { display: flex; flex-direction: column; gap: 8px; } .role-mcp-checkbox-item { display: flex; align-items: center; padding: 10px 12px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); cursor: pointer; transition: all 0.2s ease; user-select: none; } .role-mcp-checkbox-item:hover { background: var(--bg-secondary); border-color: var(--accent-color); box-shadow: 0 2px 4px rgba(0, 102, 255, 0.1); } .role-mcp-checkbox-item input[type="checkbox"] { width: 18px; height: 18px; margin-right: 12px; cursor: pointer; accent-color: var(--accent-color); } .role-mcp-checkbox-item:has(input[type="checkbox"]:checked) { background: rgba(0, 102, 255, 0.08); border-color: var(--accent-color); } .role-mcp-checkbox-content { flex: 1; display: flex; flex-direction: column; gap: 4px; } .role-mcp-name { display: flex; align-items: center; gap: 8px; font-weight: 500; color: var(--text-primary); font-size: 0.9375rem; } .role-mcp-status { padding: 2px 8px; border-radius: 10px; font-size: 0.75rem; font-weight: 500; } .role-mcp-status.status-connected { background: rgba(40, 167, 69, 0.12); color: var(--success-color); } .role-mcp-status.status-disconnected { background: rgba(108, 117, 125, 0.12); color: var(--text-secondary); } .role-mcp-status.status-connecting { background: rgba(255, 193, 7, 0.12); color: var(--warning-color); } .role-mcp-status.status-error { background: rgba(220, 53, 69, 0.12); color: var(--error-color); } .role-mcp-status.status-disabled { background: rgba(108, 117, 125, 0.12); color: var(--text-muted); } .role-mcp-tool-count { padding: 2px 6px; background: rgba(0, 102, 255, 0.1); color: var(--accent-color); border-radius: 8px; font-size: 0.75rem; font-weight: 500; } .mcp-loading, .mcp-empty, .mcp-error { padding: 24px; text-align: center; color: var(--text-secondary); font-size: 0.875rem; } .mcp-error { color: var(--error-color); } /* 角色工具选择列表样式 */ .role-tools-controls { margin-bottom: 12px; } .role-tools-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; } .role-tools-search-box { position: relative; flex: 1; min-width: 200px; max-width: 400px; } .role-tools-search-box input { width: 100%; padding: 8px 32px 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; background: var(--bg-primary); color: var(--text-primary); transition: all 0.2s; } .role-tools-search-box input:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1); } .role-tools-search-clear { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; padding: 0; border: none; background: transparent; color: var(--text-muted); cursor: pointer; border-radius: 4px; display: flex; align-items: center; justify-content: center; transition: all 0.2s; } .role-tools-search-clear:hover { background: var(--bg-tertiary); color: var(--text-primary); } .role-tools-stats { display: flex; gap: 16px; padding: 8px 12px; background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.8125rem; color: var(--text-secondary); } .role-tools-stats span { white-space: nowrap; } .role-tools-stats strong { color: var(--text-primary); font-weight: 600; } .role-tools-list { margin-top: 8px; border: 1px solid var(--border-color); border-radius: 8px; background: var(--bg-primary); min-height: 200px; max-height: 400px; overflow-y: auto; padding: 12px; } .role-tools-list-items { display: flex; flex-direction: column; gap: 8px; } .role-tool-item { display: flex; align-items: flex-start; gap: 12px; padding: 10px 12px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); transition: all 0.2s ease; } .role-tool-item:hover { background: var(--bg-secondary); border-color: var(--accent-color); box-shadow: 0 2px 4px rgba(0, 102, 255, 0.1); } .role-tool-item input[type="checkbox"] { width: 18px; height: 18px; margin-top: 2px; cursor: pointer; accent-color: var(--accent-color); flex-shrink: 0; } .role-tool-item-info { flex: 1; display: flex; flex-direction: column; gap: 4px; min-width: 0; } .role-tool-item-name { display: flex; align-items: center; gap: 8px; font-weight: 500; color: var(--text-primary); font-size: 0.9375rem; } .role-tool-item-desc { font-size: 0.8125rem; color: var(--text-secondary); line-height: 1.5; } .external-tool-badge { padding: 2px 6px; background: rgba(0, 102, 255, 0.1); color: var(--accent-color); border-radius: 8px; font-size: 0.75rem; font-weight: 500; white-space: nowrap; } .role-tools-pagination { display: flex; justify-content: space-between; align-items: center; padding: 12px; border-top: 1px solid var(--border-color); background: var(--bg-secondary); flex-wrap: wrap; gap: 12px; } .role-tools-pagination .pagination-info { font-size: 0.8125rem; color: var(--text-secondary); } .role-tools-pagination .pagination-controls { display: flex; gap: 8px; align-items: center; } .role-tools-pagination .pagination-page { font-size: 0.8125rem; color: var(--text-secondary); padding: 0 8px; } .tools-loading, .tools-empty, .tools-error { padding: 24px; text-align: center; color: var(--text-secondary); font-size: 0.875rem; } .tools-error { color: var(--error-color); } /* 默认角色提示信息样式 */ .role-tools-default-hint { margin-top: 8px; padding: 16px; border: 1px solid var(--border-color); border-radius: 8px; background: var(--bg-secondary); } .role-tools-default-info { display: flex; align-items: flex-start; gap: 12px; } .role-tools-default-icon { font-size: 1.25rem; flex-shrink: 0; margin-top: 2px; } .role-tools-default-content { flex: 1; display: flex; flex-direction: column; gap: 4px; } .role-tools-default-title { font-weight: 600; color: var(--text-primary); font-size: 0.9375rem; } .role-tools-default-desc { color: var(--text-secondary); font-size: 0.875rem; line-height: 1.5; } /* 角色选择面板响应式样式 */ @media (max-width: 768px) { .role-selection-panel { width: calc(100vw - 16px); max-width: calc(100vw - 16px); left: -8px; padding: 10px; border-radius: 14px; max-height: 60vh; } .role-selection-panel-header { margin-bottom: 10px; padding: 8px 4px 10px 4px; } .role-selection-panel-title { font-size: 0.875rem; } .role-selection-list-main { /* 在移动设备上限制显示8个角色,每个约60px,总计约480px */ max-height: 480px; gap: 5px; } .role-selection-item-main { padding: 10px; gap: 10px; } .role-selection-item-icon-main { width: 32px; height: 32px; font-size: 1.125rem; } .role-selection-item-name-main { font-size: 0.8125rem; } .role-selection-item-description-main { font-size: 0.71875rem; } } @media (max-width: 480px) { .role-selection-panel { width: calc(100vw - 8px); max-width: calc(100vw - 8px); left: -4px; padding: 8px; border-radius: 12px; max-height: 50vh; } .role-selection-list-main { /* 在小屏幕上限制显示8个角色,每个约55px,总计约450px */ max-height: 450px; gap: 5px; } .role-selection-item-main { padding: 10px; gap: 10px; border-radius: 10px; } .role-selection-item-icon-main { width: 30px; height: 30px; font-size: 1.0625rem; } .role-selection-checkmark-main { width: 18px; height: 18px; font-size: 0.625rem; top: 8px; right: 8px; } } /* Skills选择相关样式 */ .role-skills-controls { margin-bottom: 12px; } .role-skills-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; } .role-skills-search-box { position: relative; flex: 1; min-width: 200px; max-width: 400px; } .role-skills-search-box input { width: 100%; padding: 8px 32px 8px 12px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; background: var(--bg-primary); color: var(--text-primary); transition: all 0.2s; } .role-skills-search-box input:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1); } .role-skills-search-clear { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--text-secondary); padding: 4px; display: flex; align-items: center; justify-content: center; transition: color 0.2s; } .role-skills-search-clear:hover { color: var(--text-primary); } .role-skills-stats { font-size: 0.8125rem; color: var(--text-secondary); margin-top: 8px; } .role-skills-list { max-height: 300px; overflow-y: auto; border: 1px solid var(--border-color); border-radius: 6px; padding: 8px; background: var(--bg-primary); } .role-skill-item { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-primary); transition: all 0.2s ease; margin-bottom: 6px; } .role-skill-item:last-child { margin-bottom: 0; } .role-skill-item:hover { background: var(--bg-secondary); border-color: var(--accent-color); box-shadow: 0 2px 4px rgba(0, 102, 255, 0.1); } .role-skill-item .checkbox-text { font-size: 0.9375rem; color: var(--text-primary); font-weight: 500; } .skills-loading, .skills-empty, .skills-error { padding: 20px; text-align: center; color: var(--text-secondary); font-size: 0.875rem; } .skills-error { color: var(--error-color); } /* Skills管理页面样式 */ .skills-controls { margin-bottom: 8px; } .skills-stats-bar { display: flex; gap: 12px; padding: 10px 12px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 6px; margin-bottom: 10px; } .skill-stat-item { display: flex; flex-direction: column; gap: 4px; } .skill-stat-label { font-size: 0.75rem; color: var(--text-secondary); } .skill-stat-value { font-size: 1.125rem; font-weight: 600; color: var(--text-primary); } .skills-filters { display: flex; gap: 8px; align-items: center; } .skills-filters input { flex: 1; padding: 6px 10px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 0.875rem; box-sizing: border-box; height: 32px; line-height: 1.4; } .skills-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 16px; } /* 技能搜索框样式 */ .skills-search-box { position: relative; margin-bottom: 12px; } .skills-search-box input { width: 100%; padding: 8px 40px 8px 16px; border: 1px solid var(--border-color); border-radius: 8px; background: var(--bg-primary); color: var(--text-primary); font-size: 0.9375rem; transition: all 0.2s; } .skills-search-box input:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1); } .skills-search-clear { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--text-secondary); padding: 4px; display: flex; align-items: center; justify-content: center; transition: color 0.2s; } .skills-search-clear:hover { color: var(--text-primary); } /* 技能列表布局 */ .skills-grid { display: flex; flex-direction: column; gap: 12px; padding: 0; /* 确保列表可以滚动,不会把分页栏推出视口 */ flex: 1; overflow-y: auto; overflow-x: hidden; min-height: 0; } /* 技能列表项样式 */ .skill-card { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; padding: 16px; display: flex; flex-direction: row; align-items: center; gap: 16px; transition: all 0.2s; cursor: default; box-sizing: border-box; width: 100%; } .skill-card:hover { box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); border-color: var(--accent-color); transform: translateY(-2px); } .skill-card-header { display: flex; flex-direction: column; flex: 1; gap: 8px; min-width: 0; } .skill-card-title { font-size: 1.125rem; font-weight: 600; color: var(--text-primary); margin: 0; line-height: 1.4; word-break: break-word; overflow-wrap: break-word; } .skill-card-description { font-size: 0.875rem; color: var(--text-secondary); line-height: 1.6; word-break: break-word; overflow-wrap: break-word; margin: 0; } .skill-card-actions { display: flex; gap: 8px; flex-shrink: 0; } /* 技能列表响应式布局优化 */ @media (max-width: 768px) { .skill-card { padding: 14px; gap: 12px; flex-direction: column; align-items: flex-start; } .skill-card-header { width: 100%; } .skill-card-actions { width: 100%; justify-content: flex-start; } } .skill-item { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 6px; padding: 10px 12px; transition: all 0.2s; } .skill-item:hover { border-color: var(--accent-color); box-shadow: 0 2px 8px rgba(0, 102, 255, 0.1); } .skill-item-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 6px; } .skill-item-info { flex: 1; } .skill-item-name { font-size: 1rem; font-weight: 600; color: var(--text-primary); margin: 0 0 4px 0; line-height: 1.3; } .skill-item-desc { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; line-height: 1.4; } .skill-item-actions { display: flex; gap: 6px; } .btn-icon { background: none; border: 1px solid var(--border-color); border-radius: 4px; padding: 4px; cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); transition: all 0.2s; } .btn-icon:hover { background: var(--bg-secondary); border-color: var(--accent-color); color: var(--accent-color); } .btn-icon.btn-danger:hover { background: rgba(220, 53, 69, 0.1); border-color: #dc3545; color: #dc3545; } .skill-item-meta { display: flex; gap: 12px; flex-wrap: wrap; font-size: 0.75rem; color: var(--text-secondary); line-height: 1.4; } .skill-meta-item { display: flex; align-items: center; } /* Skills监控页面样式 */ .skills-monitor-controls { margin-bottom: 24px; } .skills-monitor-list { display: flex; flex-direction: column; gap: 12px; } .skill-monitor-item { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 8px; padding: 16px; transition: all 0.2s; } .skill-monitor-item:hover { border-color: var(--accent-color); box-shadow: 0 2px 8px rgba(0, 102, 255, 0.1); } .skill-monitor-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 12px; } .skill-monitor-info { flex: 1; } .skill-monitor-name { font-size: 1.125rem; font-weight: 600; color: var(--text-primary); margin: 0 0 8px 0; } .skill-monitor-desc { font-size: 0.875rem; color: var(--text-secondary); margin: 0; } .skill-monitor-status { display: flex; align-items: center; } .status-badge { padding: 4px 12px; border-radius: 12px; font-size: 0.75rem; font-weight: 500; } .status-success { background: rgba(40, 167, 69, 0.1); color: #28a745; border: 1px solid rgba(40, 167, 69, 0.3); } .skill-monitor-meta { display: flex; gap: 16px; flex-wrap: wrap; font-size: 0.8125rem; color: var(--text-secondary); } /* ==================== 信息收集(FOFA)页面 ==================== */ .info-collect-panel { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; padding: 16px; margin-bottom: 16px; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04); } /* 表单整体增加纵向留白,避免“挤在一起” */ .info-collect-form { display: flex; flex-direction: column; gap: 14px; } /* 将每个表单块做成轻量卡片分组(只作用于 info-collect 顶层 form-group) */ .info-collect-form > .form-group, .info-collect-form > .info-collect-form-row { padding: 14px 14px; border: 1px solid rgba(0, 0, 0, 0.06); border-radius: 12px; background: linear-gradient(135deg, #ffffff 0%, #fafbfc 100%); } /* 覆盖全局 .form-group textarea(min-height:200px) 的默认大留白 */ .form-group textarea.info-collect-query-input { min-height: 36px; max-height: 96px; overflow: hidden; /* 配合 JS 自动增高 */ resize: none; padding: 10px 12px; } .info-collect-nl-row { display: flex; align-items: flex-start; gap: 10px; } .info-collect-nl-row .info-collect-query-input { flex: 1 1 auto; min-width: 0; /* 允许在 flex 中收缩,避免撑破布局 */ } .info-collect-nl-row button { flex: 0 0 auto; white-space: nowrap; } @media (max-width: 980px) { .info-collect-form-row { grid-template-columns: 1fr; } .info-collect-nl-row { flex-direction: column; align-items: stretch; } .info-collect-col-actions { width: 140px; } } .info-collect-form-row { display: grid; grid-template-columns: repeat(3, minmax(180px, 1fr)); gap: 14px; align-items: end; } .info-collect-form-row .form-group { min-width: 0; } .info-collect-results { background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; overflow: hidden; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04); } .info-collect-results-header { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--border-color); gap: 12px; } .info-collect-results-header-left { display: flex; flex-direction: column; gap: 2px; min-width: 240px; } .info-collect-results-toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; } .info-collect-selected { font-size: 0.8125rem; color: var(--text-secondary); padding: 4px 10px; border: 1px solid var(--border-color); border-radius: 999px; background: var(--bg-secondary); margin-right: 4px; } .info-collect-results-title { font-weight: 600; color: var(--text-primary); } .info-collect-results-meta { font-size: 0.8125rem; color: var(--text-secondary); } .info-collect-results-table-wrap { overflow: auto; max-height: 60vh; position: relative; } .info-collect-table { width: 100%; border-collapse: collapse; font-size: 0.875rem; table-layout: fixed; } .info-collect-table th, .info-collect-table td { padding: 9px 12px; border-bottom: 1px solid var(--border-color); vertical-align: top; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .info-collect-table th + th, .info-collect-table td + td { border-left: 1px solid rgba(0, 0, 0, 0.04); } .info-collect-table thead th { position: sticky; top: 0; background: var(--bg-secondary); color: var(--text-secondary); font-weight: 600; z-index: 1; } .info-collect-table tbody tr:nth-child(even) td { background: rgba(0, 0, 0, 0.012); } .info-collect-table tbody tr:hover td { background: rgba(0, 102, 255, 0.04); } .info-collect-table .muted { color: var(--text-secondary); } /* 操作列:放到最右侧并固定,避免横向滚动找不到 */ .info-collect-col-actions { width: 150px; text-align: left; } .info-collect-table thead th.info-collect-col-actions, .info-collect-table tbody td.info-collect-col-actions { position: sticky; right: 0; z-index: 2; background: var(--bg-primary); border-left: 1px solid var(--border-color); } .info-collect-table thead th.info-collect-col-actions { background: var(--bg-secondary); z-index: 3; text-align: center; /* 表头“操作”居中 */ } .info-collect-actions { display: flex; gap: 8px; justify-content: flex-start; /* 按钮向左 */ } .info-collect-actions .btn-icon { padding: 6px; border-radius: 8px; } .info-collect-presets { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; } .info-collect-query-input { min-height: 40px; max-height: 110px; line-height: 1.45; overflow: hidden; /* 配合 JS 自动增高 */ resize: none; } .preset-chip { border: 1px solid var(--border-color); background: var(--bg-secondary); color: var(--text-secondary); padding: 7px 12px; border-radius: 999px; cursor: pointer; font-size: 0.8125rem; line-height: 1; transition: all 0.15s ease; } .preset-chip:hover { border-color: var(--accent-color); color: var(--accent-color); background: rgba(0, 102, 255, 0.06); } .info-collect-link { color: var(--accent-color); text-decoration: none; border-bottom: 1px dashed rgba(0, 102, 255, 0.35); } .info-collect-link:hover { border-bottom-color: rgba(0, 102, 255, 0.75); } /* 勾选列(左侧固定) */ .info-collect-col-select { width: 44px; text-align: center; } .info-collect-table thead th.info-collect-col-select, .info-collect-table tbody td.info-collect-col-select { position: sticky; left: 0; z-index: 2; background: var(--bg-primary); border-right: 1px solid var(--border-color); } .info-collect-table thead th.info-collect-col-select { background: var(--bg-secondary); z-index: 4; } /* 单元格点击展开提示(非强制) */ .info-collect-cell { cursor: pointer; } .info-collect-cell-text { display: inline-block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; vertical-align: top; } /* 字段显示/隐藏面板 */ .info-collect-columns-panel { position: sticky; top: 0; z-index: 6; background: var(--bg-primary); border-bottom: 1px solid var(--border-color); padding: 12px 16px; } .info-collect-columns-panel-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; } .info-collect-columns-title { font-weight: 600; color: var(--text-primary); } .info-collect-columns-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; } .info-collect-columns-list { display: grid; grid-template-columns: repeat(4, minmax(140px, 1fr)); gap: 8px; } .info-collect-col-item { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--border-color); border-radius: 10px; background: var(--bg-secondary); cursor: pointer; user-select: none; color: var(--text-secondary); font-size: 0.875rem; overflow: hidden; } .info-collect-col-item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } /* 单元格详情弹窗 */ .info-collect-cell-modal { position: fixed; inset: 0; background: rgba(0,0,0,0.45); display: flex; align-items: center; justify-content: center; z-index: 10000; padding: 24px; } .info-collect-cell-modal-content { width: min(920px, 100%); max-height: 86vh; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,0.20); display: flex; flex-direction: column; overflow: hidden; } .info-collect-cell-modal-header { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid var(--border-color); } .info-collect-cell-modal-title { font-weight: 600; color: var(--text-primary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding-right: 12px; } .info-collect-cell-modal-body { padding: 12px 14px; overflow: auto; } .info-collect-cell-modal-pre { margin: 0; white-space: pre-wrap; word-break: break-word; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; font-size: 0.875rem; line-height: 1.55; color: var(--text-primary); } .info-collect-cell-modal-footer { padding: 12px 14px; border-top: 1px solid var(--border-color); display: flex; justify-content: flex-end; gap: 8px; } @media (max-width: 980px) { .info-collect-columns-list { grid-template-columns: repeat(2, minmax(140px, 1fr)); } }