/* 文档管理页面样式 */ /* 覆盖 body 的 overflow 设置 */ body { overflow: auto; } /* 左侧迷你导航 */ .sidebar-mini { width: 200px; background: #e8f0fe; display: flex; flex-direction: column; border-right: 1px solid #dadce0; } .sidebar-mini-header { padding: 20px 16px; border-bottom: 1px solid #dadce0; } .sidebar-mini-header h2 { font-size: 18px; font-weight: 500; color: #202124; } .sidebar-mini-nav { padding: 16px 8px; display: flex; flex-direction: column; gap: 4px; } .nav-link { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 12px; color: #202124; text-decoration: none; transition: background 0.2s ease; } .nav-link:hover { background: #f1f3f4; } .nav-link.active { background: #d2e3fc; } .nav-link svg { width: 20px; height: 20px; flex-shrink: 0; } .nav-link span { font-size: 14px; font-weight: 400; } /* 主内容区 */ .main-content { flex: 1; display: flex; flex-direction: column; overflow: auto; padding: 24px; background: #f8f9fa; } /* 页面头部 */ .page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; } .page-header h1 { font-size: 24px; font-weight: 500; color: #202124; } .header-actions { display: flex; gap: 12px; } /* 按钮样式 */ .btn-primary, .btn-secondary, .btn-danger { display: flex; align-items: center; gap: 8px; padding: 10px 20px; border: none; border-radius: 8px; font-size: 14px; font-weight: 500; cursor: pointer; transition: all 0.2s ease; } .btn-primary { background: #1a73e8; color: #ffffff; } .btn-primary:hover { background: #1557b0; box-shadow: 0 1px 3px rgba(0,0,0,0.2); } .btn-secondary { background: #ffffff; color: #202124; border: 1px solid #dadce0; } .btn-secondary:hover { background: #f1f3f4; } .btn-danger { background: #ea4335; color: #ffffff; } .btn-danger:hover { background: #d33426; } .btn-primary svg, .btn-secondary svg { width: 16px; height: 16px; } .btn-primary:disabled, .btn-secondary:disabled, .btn-danger:disabled { opacity: 0.5; cursor: not-allowed; } /* 状态统计卡片 */ .stats-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 24px; } .stat-card { background: #ffffff; border: 1px solid #dadce0; border-radius: 12px; padding: 20px; cursor: pointer; transition: all 0.2s ease; display: flex; align-items: center; gap: 16px; } .stat-card:hover { border-color: #1a73e8; box-shadow: 0 2px 8px rgba(0,0,0,0.1); transform: translateY(-2px); } .stat-icon { width: 48px; height: 48px; border-radius: 12px; display: flex; align-items: center; justify-content: center; } .stat-icon svg { width: 24px; height: 24px; } .stat-icon.pending { background: #f1f3f4; color: #757575; } .stat-icon.processing { background: #e8f0fe; color: #1a73e8; } .stat-icon.indexed { background: #e6f4ea; color: #34a853; } .stat-icon.failed { background: #fce8e6; color: #ea4335; } .stat-info { display: flex; flex-direction: column; } .stat-label { font-size: 13px; color: #5f6368; margin-bottom: 4px; } .stat-value { font-size: 28px; font-weight: 500; color: #202124; } /* 工具栏 */ .toolbar { margin-bottom: 16px; } .filters { display: flex; gap: 12px; } .filter-select, .filter-input { padding: 10px 16px; border: 1px solid #dadce0; border-radius: 8px; font-size: 14px; background: #ffffff; color: #202124; outline: none; transition: border-color 0.2s ease; } .filter-select:focus, .filter-input:focus { border-color: #1a73e8; } .filter-select { min-width: 150px; } .filter-input { flex: 1; max-width: 300px; } /* 文档表格 */ .documents-table-container { flex: 1; background: #ffffff; border-radius: 12px; border: 1px solid #dadce0; overflow-y: auto; display: flex; flex-direction: column; } .documents-table { width: 100%; border-collapse: collapse; } .documents-table thead { background: #f8f9fa; border-bottom: 1px solid #dadce0; } .documents-table th { padding: 16px; text-align: left; font-size: 13px; font-weight: 500; color: #5f6368; white-space: nowrap; } .documents-table td { padding: 16px; font-size: 14px; color: #202124; border-bottom: 1px solid #f1f3f4; } .documents-table tbody tr:hover { background: #f8f9fa; } .documents-table tbody tr:last-child td { border-bottom: none; } /* 状态徽章 */ .status-badge { display: inline-flex; align-items: center; padding: 4px 12px; border-radius: 12px; font-size: 12px; font-weight: 500; color: #ffffff; } .status-badge.pending { background: #757575; } .status-badge.processing { background: #1a73e8; } .status-badge.indexed { background: #34a853; } .status-badge.failed { background: #ea4335; } /* 操作按钮 */ .action-buttons { display: flex; gap: 8px; } .btn-view, .btn-delete { padding: 6px 12px; border: none; border-radius: 6px; font-size: 13px; cursor: pointer; transition: all 0.2s ease; } .btn-view { background: #e8f0fe; color: #1a73e8; } .btn-view:hover { background: #d2e3fc; } .btn-delete { background: #fce8e6; color: #ea4335; } .btn-delete:hover { background: #f6c1bc; } /* 空状态 */ .empty-state { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 80px 20px; color: #5f6368; } .empty-state svg { width: 64px; height: 64px; margin-bottom: 16px; opacity: 0.3; } .empty-state p { font-size: 16px; margin-bottom: 20px; } /* 详情面板 */ .detail-panel { position: fixed; top: 0; right: -450px; width: 450px; height: 100vh; background: #ffffff; border-left: 1px solid #dadce0; box-shadow: -2px 0 16px rgba(0,0,0,0.1); transition: right 0.3s ease; overflow-y: auto; z-index: 1000; } .detail-panel.open { right: 0; } .panel-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid #dadce0; background: #ffffff; position: sticky; top: 0; z-index: 10; } .panel-header h2 { font-size: 18px; font-weight: 500; color: #202124; } .btn-close { width: 32px; height: 32px; border: none; background: none; border-radius: 50%; font-size: 24px; color: #5f6368; cursor: pointer; transition: background 0.2s ease; display: flex; align-items: center; justify-content: center; line-height: 1; } .btn-close:hover { background: #f1f3f4; } .panel-content { padding: 24px; } .detail-section { margin-bottom: 32px; } .detail-section:last-child { margin-bottom: 0; } .detail-section h3 { font-size: 16px; font-weight: 500; color: #202124; margin-bottom: 16px; } .detail-item { display: flex; padding: 12px 0; border-bottom: 1px solid #f1f3f4; } .detail-item:last-child { border-bottom: none; } .detail-item label { flex: 0 0 120px; font-size: 13px; color: #5f6368; } .detail-item span { flex: 1; font-size: 14px; color: #202124; word-break: break-word; } .detail-item.error span { color: #ea4335; } .loading-state { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 60px 20px; color: #5f6368; } .spinner { width: 32px; height: 32px; border: 3px solid #f1f3f4; border-top-color: #1a73e8; border-radius: 50%; animation: spin 0.8s linear infinite; margin-bottom: 16px; } @keyframes spin { to { transform: rotate(360deg); } } /* 对话框 */ .modal { display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0; z-index: 2000; align-items: center; justify-content: center; } .modal.show { display: flex; } .modal-backdrop { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0, 0, 0, 0.5); } .modal-content { position: relative; background: #ffffff; border-radius: 12px; width: 90%; max-width: 600px; max-height: 90vh; overflow-y: auto; box-shadow: 0 8px 32px rgba(0,0,0,0.2); } .modal-small { max-width: 480px; } .modal-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid #dadce0; } .modal-header h2 { font-size: 18px; font-weight: 500; color: #202124; } .modal-body { padding: 24px; } .modal-actions { display: flex; justify-content: flex-end; gap: 12px; padding: 16px 24px; border-top: 1px solid #dadce0; } /* 表单 */ .form-group { margin-bottom: 20px; } .form-group:last-child { margin-bottom: 0; } .form-group label { display: block; font-size: 14px; font-weight: 500; color: #202124; margin-bottom: 8px; } .required { color: #ea4335; } .form-input, .form-select, .file-input { width: 100%; padding: 10px 12px; border: 1px solid #dadce0; border-radius: 8px; font-size: 14px; color: #202124; outline: none; transition: border-color 0.2s ease; } .form-input:focus, .form-select:focus, .file-input:focus { border-color: #1a73e8; } .form-hint { display: block; margin-top: 6px; font-size: 12px; color: #5f6368; } .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; } .warning-message { display: flex; align-items: flex-start; gap: 8px; padding: 12px; background: #fef7e0; border: 1px solid #f9ab00; border-radius: 8px; color: #b06000; font-size: 13px; margin-top: 16px; } .warning-message svg { width: 18px; height: 18px; flex-shrink: 0; } /* 加载状态 */ .btn-loading { display: flex; align-items: center; gap: 8px; } .spinner-small { width: 14px; height: 14px; border: 2px solid rgba(255,255,255,0.3); border-top-color: #ffffff; border-radius: 50%; animation: spin 0.6s linear infinite; } /* 通知 */ .notification-container { position: fixed; top: 20px; right: 20px; z-index: 3000; display: flex; flex-direction: column; gap: 12px; max-width: 400px; } .notification { display: flex; align-items: center; gap: 12px; padding: 16px; border-radius: 8px; box-shadow: 0 4px 16px rgba(0,0,0,0.15); animation: slideIn 0.3s ease; color: #ffffff; font-size: 14px; } @keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } } .notification.success { background: #34a853; } .notification.error { background: #ea4335; } .notification svg { width: 20px; height: 20px; flex-shrink: 0; } /* 响应式 */ @media (max-width: 1200px) { .stats-cards { grid-template-columns: repeat(2, 1fr); } } @media (max-width: 768px) { .sidebar-mini { width: 60px; } .sidebar-mini-header h2, .nav-link span { display: none; } .stats-cards { grid-template-columns: 1fr; } .detail-panel { width: 100%; right: -100%; } .modal-content { width: 95%; } }