/* ============================================================
   TalentSaaS Admin Panel — Style v0.7.0
   Refined spacing, professional layout, human-readable design
   ============================================================ */

/* Backward-compatible aliases for enhance.css & legacy pages */
:root {
  --card-bg: var(--bg-card, #ffffff);
  --hover-bg: var(--bg-card-hover, #f8fafc);
  --text-primary: var(--text-primary, #0f172a);
  --text-secondary: var(--text-secondary, #475569);
  --text-muted: var(--text-muted, #94a3b8);
  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --accent-light: #eff6ff;
  --accent-glow: rgba(37, 99, 235, 0.15);
  --success: #10b981;
  --success-bg: #ecfdf5;
  --danger: #ef4444;
  --danger-bg: #fef2f2;
  --warning: #f59e0b;
  --warning-bg: #fffbeb;
  --info: #3b82f6;
  --info-bg: #eff6ff;
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --border-input: #cbd5e1;
  --border-focus: #2563eb;
  --font-mono: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Noto Sans SC', sans-serif;
}

/* ============================================================
   TalentSaaS Admin Panel — Style v0.6.2
   Light theme, clean technology aesthetic
   ============================================================ */

:root {

  /* Background layers */
  --bg-root: #f0f2f5;
  --bg-surface: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f8fafc;
  --bg-input: #f8fafc;
  --bg-input-focus: #ffffff;
  --bg-modal: #ffffff;
  --bg-sidebar: #0f172a;
  --bg-sidebar-hover: #1e293b;
  --bg-sidebar-active: #1e3a5f;
  --bg-tooltip: #1e293b;
  --bg-badge: #f1f5f9;
  --bg-tag: #eff6ff;

  /* Text */
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --text-inverse: #f8fafc;
  --text-sidebar: #cbd5e1;
  --text-sidebar-active: #ffffff;
  --text-accent: #2563eb;

  /* Borders */
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --border-input: #cbd5e1;
  --border-focus: #2563eb;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.06), 0 2px 4px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.08), 0 4px 6px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.1), 0 8px 10px rgba(0, 0, 0, 0.05);
  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.04);

  /* State colors */
  --success: #10b981;
  --success-bg: #ecfdf5;
  --danger: #ef4444;
  --danger-bg: #fef2f2;
  --warning: #f59e0b;
  --warning-bg: #fffbeb;
  --info: #3b82f6;
  --info-bg: #eff6ff;

  /* Sizing */
  --sidebar-w: 232px;
  --header-h: 56px;
  --radius: 8px;
  --radius-sm: 6px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);

  /* Font */
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Noto Sans SC', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
}

/* ============================================================
   Reset & Base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 14px; scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg-root);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-hover); }

/* ============================================================
   Layout
   ============================================================ */
.app-layout {
  display: flex;
  min-height: 100vh;
}

/* ---- Sidebar (v0.8.0 科技风深色渐变) ---- */
.sidebar {
  width: var(--sidebar-w);
  min-width: var(--sidebar-w);
  background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%);
  color: var(--text-sidebar);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  overflow-y: auto;
  overflow-x: hidden;
  border-right: 1px solid rgba(37, 99, 235, 0.15);
  font-family: 'Inter', 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
}

.sidebar::-webkit-scrollbar { width: 4px; }
.sidebar::-webkit-scrollbar-track { background: transparent; }
.sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 4px; }

.sidebar-logo {
  padding: 18px 20px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.sidebar-logo .logo-icon {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; color: #fff; font-weight: 700;
}
.sidebar-logo .logo-text {
  font-size: 1rem; font-weight: 700; color: #fff; letter-spacing: -0.01em;
  white-space: nowrap;
}
.sidebar-logo .logo-ver {
  font-size: 0.65rem; color: var(--text-muted); margin-top: -2px;
}

.sidebar-nav { flex: 1; padding: 10px 0; }
.sidebar-group { padding: 0; margin-bottom: 4px; }
.sidebar-group-title {
  padding: 8px 20px 4px;
  font-size: 0.68rem; font-weight: 600; color: #64748b;
  text-transform: uppercase; letter-spacing: 0.08em;
}
.sidebar-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 20px; margin: 1px 8px;
  border-radius: var(--radius-sm);
  color: var(--text-sidebar);
  font-size: 0.875rem; font-weight: 450;
  cursor: pointer; transition: all var(--transition);
  white-space: nowrap;
  border: 1px solid transparent;
}
.sidebar-item:hover {
  background: var(--bg-sidebar-hover);
  color: var(--text-sidebar-active);
}
.sidebar-item.active {
  background: linear-gradient(135deg, #1e3a5f, #1a56db);
  color: #fff;
  font-weight: 550;
  border-color: rgba(37,99,235,0.4);
}
.sidebar-item .nav-icon { font-size: 1.05rem; line-height: 1; width: 20px; text-align: center; flex-shrink: 0; }

.sidebar-footer {
  padding: 12px 16px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex; align-items: center; gap: 10px;
  cursor: pointer; transition: background var(--transition);
  border-radius: var(--radius-sm); margin: 4px 8px 12px;
}
.sidebar-footer:hover { background: var(--bg-sidebar-hover); }
.sidebar-footer .user-avatar {
  width: 30px; height: 30px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; color: #fff; font-weight: 600; flex-shrink: 0;
}
.sidebar-footer .user-info { flex: 1; min-width: 0; }
.sidebar-footer .user-name { font-size: 0.8rem; color: #e2e8f0; font-weight: 500; }
.sidebar-footer .user-role { font-size: 0.65rem; color: #94a3b8; }

/* ---- Main Content ---- */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-w);
  padding: 0;
  min-height: 100vh;
}

.page-header {
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
  padding: 14px 28px;
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 50;
  gap: 16px;
}
.page-header-left { display: flex; flex-direction: column; gap: 2px; }
.page-header h1 { font-size: 1.2rem; font-weight: 650; color: var(--text-primary); letter-spacing: -0.01em; }
.page-header .breadcrumb { font-size: 0.78rem; color: var(--text-muted); }
.page-header-actions { display: flex; gap: 10px; align-items: center; }

.page-body { padding: 28px 32px 48px; }
.page-body::-webkit-scrollbar { width: 5px; }
.page-body::-webkit-scrollbar-track { background: transparent; }
.page-body::-webkit-scrollbar-thumb { background: var(--border); border-radius: 10px; }

/* ---- Toolbar (二级页面操作栏) ---- */
.toolbar {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 12px;
  margin-bottom: 22px;
  padding: 16px 20px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.toolbar-left { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; flex: 1; min-width: 0; }
.toolbar-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

/* 页面内容区块之间的统一间距 */
.page-body > .card,
.page-body > .card-grid,
.page-body > .stat-grid,
.page-body > .bento-grid,
.page-body > .table-wrap,
.page-body > .section-title,
.page-body > .empty-state { margin-bottom: 24px; }

/* ===== SUb-View Toolbar ===== */
.sub-view-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 0 16px 0;
  flex-wrap: wrap; gap: 10px;
}
.sub-view-toolbar .sub-view-title {
  font-size: 1rem; font-weight: 650; color: var(--text-primary); margin: 0;
}
.sub-view-toolbar .sub-view-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* Page View 切换 – 所有 page-view 默认隐藏，仅 .active 显示 */
.page-view { display: none; padding-bottom: 40px; }
.page-view.active { display: block; }

/* 自动间距：兼容无 .page-body 包裹的页面 */
.page-view > :not(.page-header):not(.page-body):not(.hidden) {
  margin-left: 28px;
  margin-right: 28px;
}
.page-view > .page-header + :not(.page-body):not(.hidden) { padding-top: 24px; }

/* ---- Homepage Layout ---- */
.homepage-header {
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
  padding: 12px 28px;
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 90;
}
.homepage-brand { display: flex; align-items: center; gap: 10px; }
.homepage-brand .brand-icon {
  width: 36px; height: 36px;
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  font-size: 19px; color: #fff; font-weight: 700;
}
.homepage-brand .brand-text { font-size: 1.1rem; font-weight: 700; color: var(--text-primary); }
.homepage-actions { display: flex; gap: 10px; align-items: center; }
.homepage-hero {
  text-align: center; padding: 60px 24px 40px;
  background: linear-gradient(180deg, #eff6ff 0%, #f0f2f5 100%);
}
.homepage-hero h2 { font-size: 2rem; font-weight: 700; color: var(--text-primary); letter-spacing: -0.02em; margin-bottom: 8px; }
.homepage-hero p { font-size: 1rem; color: var(--text-secondary); max-width: 600px; margin: 0 auto 24px; }
.homepage-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  padding: 20px 28px 40px;
  max-width: 1200px; margin: 0 auto;
}
.homepage-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: all var(--transition);
  cursor: pointer;
  display: flex; flex-direction: column; gap: 10px;
}
.homepage-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--accent);
  transform: translateY(-2px);
}
.homepage-card .card-icon {
  width: 44px; height: 44px;
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
}
.homepage-card .card-icon.blue { background: #eff6ff; color: #2563eb; }
.homepage-card .card-icon.green { background: #ecfdf5; color: #10b981; }
.homepage-card .card-icon.purple { background: #f5f3ff; color: #7c3aed; }
.homepage-card .card-icon.orange { background: #fff7ed; color: #f97316; }
.homepage-card .card-icon.teal { background: #f0fdfa; color: #14b8a6; }
.homepage-card h3 { font-size: 1rem; font-weight: 600; color: var(--text-primary); }
.homepage-card p { font-size: 0.83rem; color: var(--text-muted); line-height: 1.5; }

/* ---- Login Modal ---- */
.login-modal-overlay {
  position: fixed; inset: 0; background: rgba(15,23,42,0.5);
  backdrop-filter: blur(4px); z-index: 200;
  display: flex; align-items: center; justify-content: center;
}
.login-modal {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  padding: 36px 32px;
  width: 420px; max-width: 90vw;
  animation: fadeScaleIn 0.25s ease-out;
}
.login-modal h2 { font-size: 1.3rem; font-weight: 700; margin-bottom: 6px; color: var(--text-primary); text-align: center; }
.login-modal .login-subtitle { font-size: 0.85rem; color: var(--text-muted); text-align: center; margin-bottom: 28px; }
.login-modal .form-group { margin-bottom: 16px; }
.login-modal .form-group label { display: block; font-size: 0.82rem; font-weight: 550; color: var(--text-secondary); margin-bottom: 6px; }
.login-modal .form-group input {
  width: 100%; padding: 10px 14px;
  border: 1.5px solid var(--border-input);
  border-radius: var(--radius);
  background: var(--bg-input);
  font-size: 0.95rem; font-family: var(--font);
  color: var(--text-primary);
  transition: all var(--transition);
}
.login-modal .form-group input:focus {
  outline: none; border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--accent-glow);
  background: var(--bg-input-focus);
}
.login-modal .login-btn {
  width: 100%; padding: 11px;
  background: var(--accent); color: #fff; border: none;
  border-radius: var(--radius); font-size: 0.95rem; font-weight: 600;
  cursor: pointer; transition: all var(--transition);
  margin-top: 6px;
}
.login-modal .login-btn:hover { background: var(--accent-hover); }
.login-modal .login-error { color: var(--danger); font-size: 0.82rem; text-align: center; min-height: 20px; margin-top: 8px; }
.login-modal .close-login {
  position: absolute; top: 16px; right: 16px;
  background: none; border: none; font-size: 1.3rem;
  color: var(--text-muted); cursor: pointer;
  padding: 4px; border-radius: 4px; line-height: 1;
}
.login-modal .close-login:hover { color: var(--text-primary); background: var(--bg-badge); }

/* ============================================================
   UI Components
   ============================================================ */

/* Cards */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  box-shadow: var(--shadow-card);
  transition: box-shadow var(--transition);
}
.card:hover { box-shadow: var(--shadow-md); }
.card-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
}
.card-title { font-size: 0.95rem; font-weight: 650; color: var(--text-primary); }
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

/* Stat cards */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 20px; margin-bottom: 28px; }
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow: var(--shadow-card);
  transition: all var(--transition);
}
.stat-card:hover { box-shadow: var(--shadow-md); border-color: var(--accent); }
.stat-card .stat-label { font-size: 0.78rem; color: var(--text-muted); font-weight: 500; }
.stat-card .stat-value { font-size: 1.6rem; font-weight: 700; color: var(--text-primary); margin: 4px 0 2px; letter-spacing: -0.02em; }
.stat-card .stat-change { font-size: 0.72rem; color: var(--text-muted); font-weight: 500; margin-top: 2px; }
.stat-card .stat-desc { font-size: 0.75rem; color: var(--text-muted); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 18px; border-radius: var(--radius);
  font-size: 0.875rem; font-weight: 550; font-family: var(--font);
  border: 1.5px solid transparent; cursor: pointer;
  transition: all var(--transition); white-space: nowrap;
  line-height: 1.4;
}
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-primary { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn-primary:hover:not(:disabled) { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn-secondary { background: var(--bg-surface); color: var(--text-secondary); border-color: var(--border); }
.btn-secondary:hover:not(:disabled) { background: var(--bg-badge); color: var(--text-primary); border-color: var(--border-input); }
.btn-danger { background: var(--danger); color: #fff; border-color: var(--danger); }
.btn-danger:hover:not(:disabled) { background: #dc2626; }
.btn-success { background: var(--success); color: #fff; }
.btn-ghost { background: transparent; color: var(--text-secondary); }
.btn-ghost:hover:not(:disabled) { background: var(--bg-badge); color: var(--text-primary); }
.btn-sm { padding: 5px 12px; font-size: 0.8rem; border-radius: var(--radius-sm); }
.btn-xs { padding: 3px 8px; font-size: 0.72rem; border-radius: var(--radius-sm); }
.btn-full { width: 100%; justify-content: center; padding: 10px; }
.btn-icon { padding: 6px 10px; }

/* Badges */
.badge {
  display: inline-flex; align-items: center;
  padding: 2px 10px; border-radius: 20px;
  font-size: 0.72rem; font-weight: 550;
}
.badge-active { background: var(--success-bg); color: var(--success); }
.badge-inactive { background: var(--bg-badge); color: var(--text-muted); }
.badge-warning { background: var(--warning-bg); color: var(--warning); }
.badge-danger { background: var(--danger-bg); color: var(--danger); }
.badge-info { background: var(--info-bg); color: var(--info); }

/* Tags */
.tag {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 10px; border-radius: var(--radius-sm);
  background: var(--bg-tag); color: var(--text-accent);
  font-size: 0.75rem; font-weight: 500;
  border: 1px solid rgba(37,99,235,0.15);
}

/* Tables */
.table-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--border); }
table {
  width: 100%; border-collapse: collapse;
  font-size: 0.85rem; font-variant-numeric: tabular-nums;
}
thead { background: var(--bg-badge); }
th {
  padding: 10px 14px; text-align: left;
  font-weight: 600; font-size: 0.78rem; color: var(--text-secondary);
  white-space: nowrap; border-bottom: 1px solid var(--border);
}
td { padding: 10px 14px; border-bottom: 1px solid var(--border-light); color: var(--text-primary); }
tr:last-child td { border-bottom: none; }
tr:hover td { background: var(--bg-card-hover); }

/* Forms */
.form-group { margin-bottom: 16px; }
.form-group label {
  display: block; font-size: 0.82rem; font-weight: 550;
  color: var(--text-secondary); margin-bottom: 6px;
}
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%; padding: 9px 13px;
  border: 1.5px solid var(--border-input);
  border-radius: var(--radius);
  background: var(--bg-input);
  font-size: 0.875rem; font-family: var(--font);
  color: var(--text-primary);
  transition: all var(--transition);
  resize: vertical;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none; border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--accent-glow);
  background: var(--bg-input-focus);
}
.form-group input[type="checkbox"] {
  width: auto; accent-color: var(--accent);
}
.form-inline { display: flex; gap: 12px; align-items: flex-end; }
.form-inline .form-group { flex: 1; margin-bottom: 0; }
.form-hint { font-size: 0.75rem; color: var(--text-muted); margin-top: 4px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* Modal */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(15,23,42,0.45);
  backdrop-filter: blur(2px); z-index: 150;
  display: flex; align-items: center; justify-content: center;
}
.modal {
  background: var(--bg-modal);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  width: 560px; max-width: 92vw; max-height: 85vh;
  overflow-y: auto;
  animation: fadeScaleIn 0.2s ease-out;
}
.modal.wide { width: 720px; }
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px 12px;
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; background: var(--bg-modal); z-index: 1;
}
.modal-header h2 { font-size: 1.05rem; font-weight: 650; color: var(--text-primary); }
.modal-close {
  background: none; border: none; font-size: 1.3rem;
  color: var(--text-muted); cursor: pointer;
  padding: 4px 8px; border-radius: var(--radius-sm);
  transition: all var(--transition);
}
.modal-close:hover { color: var(--text-primary); background: var(--bg-badge); }
#modal-body { padding: 28px 30px; line-height: 1.65; }
/* 弹窗内表单字段间距 — !important 覆盖全局 *{margin:0} 重置 */
#modal-body .form-group { margin-bottom: 24px !important; }
#modal-body .form-group:last-of-type { margin-bottom: 4px !important; }
#modal-body .form-group label { display: block; margin-bottom: 8px !important; }

/* modal-footer / modal-actions: 统一底部按钮栏（footer 是HTML模板预留, actions 是JS动态生成） */
.modal-footer,
.modal-actions {
  padding: 14px 24px 18px;
  border-top: 1px solid var(--border); display: flex; gap: 10px; justify-content: flex-end;
  position: sticky; bottom: 0; background: var(--bg-modal);
}

/* === Detail Display in Modals === */
.modal .dim-group {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
}
.modal .dim-group-header {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 8px; flex-wrap: wrap;
}
.modal .dim-group-header h4 { font-size: 0.9rem; margin: 0; color: var(--text-primary); }
.modal .dim-weight {
  font-size: 0.78rem; color: var(--text-muted);
  background: var(--bg-badge); padding: 2px 8px; border-radius: 10px;
}
.modal .dim-desc {
  font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 8px;
}
.modal .dim-indicators { display: flex; flex-wrap: wrap; gap: 6px; }
.modal .dim-ind-tag {
  display: inline-block; padding: 2px 10px;
  font-size: 0.75rem; color: var(--text-accent);
  background: var(--bg-tag); border-radius: 12px;
}
.modal .criteria-box {
  background: var(--bg-badge);
  padding: 6px 10px; border-radius: var(--radius-sm);
  font-size: 0.8rem; color: var(--text-secondary);
  margin-bottom: 4px; line-height: 1.5;
}
.modal .criteria-label {
  display: inline-block; font-size: 0.72rem; font-weight: 650;
  color: var(--text-secondary); margin-right: 6px;
  min-width: 52px; vertical-align: top;
}
.modal .detail-section { margin-bottom: 20px; }
.modal .detail-field { padding: 6px 0; }
.modal .detail-field label { display: block; font-size: 0.75rem; color: var(--text-muted); font-weight: 500; margin-bottom: 2px; }
.modal .detail-field span { font-size: 0.88rem; color: var(--text-primary); font-weight: 500; }

/* 弹窗内评分/摘要卡片 */
.modal .score-badge {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 16px 24px; background: var(--bg-badge);
  border-radius: var(--radius); min-width: 80px;
}
.modal .score-badge .score-num { font-size: 1.6rem; font-weight: 700; color: var(--accent); }
.modal .score-badge .score-label { font-size: 0.72rem; color: var(--text-muted); }
.modal .score-badge .score-sub { font-size: 0.8rem; color: var(--text-secondary); }

/* 弹窗内表格包裹 */
.modal .table-wrap { margin: 0; border-radius: var(--radius-sm); }
.modal .detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* 弹窗内问卷题目卡片 */
.modal .qu-card {
  padding: 14px 16px; margin-bottom: 8px;
  background: var(--bg-surface); border-radius: var(--radius);
  border: 1px solid var(--border);
}
.modal .qu-card:hover { background: var(--bg-badge); }
.modal .qu-card .qu-title { font-weight: 650; font-size: 0.9rem; margin-bottom: 6px; color: var(--text-primary); }
.modal .qu-card .qu-type { font-size: 0.72rem; color: var(--text-muted); background: var(--bg-tag); padding: 1px 8px; border-radius: 10px; margin-left: 8px; }
.modal .qu-card .qu-required { font-size: 0.72rem; color: var(--danger); margin-left: 4px; }
.modal .qu-card .qu-options { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }

/* display-mode form-group (详情查看，非表单输入) */
.form-group.readonly span {
  font-size: 0.88rem; color: var(--text-primary); font-weight: 500; padding-top: 2px;
}

/* Toast */
.toast-container {
  position: fixed; top: 16px; right: 16px; z-index: 300;
  display: flex; flex-direction: column; gap: 8px;
}
.toast {
  padding: 11px 20px; border-radius: var(--radius);
  font-size: 0.85rem; font-weight: 500;
  box-shadow: var(--shadow-lg);
  animation: slideToast 0.3s ease-out;
  min-width: 240px; max-width: 380px;
}
.toast-success { background: var(--success); color: #fff; }
.toast-error { background: var(--danger); color: #fff; }
.toast-info { background: var(--info); color: #fff; }
.toast-warning { background: var(--warning); color: #fff; }

/* Section */
.section-title {
  font-size: 0.95rem; font-weight: 650; color: var(--text-primary);
  margin-bottom: 14px; display: flex; align-items: center; gap: 8px;
}
.section-title::before {
  content: ''; width: 3px; height: 16px;
  background: var(--accent); border-radius: 2px;
}

/* Empty state */
.empty-state { text-align: center; padding: 40px 20px; color: var(--text-muted); }
.empty-state h3 { font-size: 0.95rem; color: var(--text-secondary); margin-bottom: 6px; }
.empty-state p { font-size: 0.85rem; }

/* Code / mono */
code, .mono {
  font-family: var(--font-mono); font-size: 0.82rem;
  background: var(--bg-badge); padding: 2px 6px; border-radius: 4px;
}

/* JSON highlight in config */
.json-config {
  background: #1e293b; color: #e2e8f0;
  padding: 14px 18px; border-radius: var(--radius);
  font-family: var(--font-mono); font-size: 0.8rem;
  white-space: pre-wrap; overflow-x: auto;
  line-height: 1.6;
}

/* Settings panel */
.settings-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.setting-item {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 14px 18px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.setting-item .si-info { flex: 1; min-width: 0; }
.setting-item .si-name { font-weight: 550; font-size: 0.88rem; }
.setting-item .si-status {
  font-size: 0.78rem; display: flex; align-items: center; gap: 5px;
}
.status-dot {
  width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0;
}
.status-dot.ok { background: var(--success); box-shadow: 0 0 6px rgba(16,185,129,0.4); }
.status-dot.error { background: var(--danger); box-shadow: 0 0 6px rgba(239,68,68,0.4); }
.status-dot.warn { background: var(--warning); }

/* Select dropdown */
select {
  padding: 8px 12px; border: 1.5px solid var(--border-input);
  border-radius: var(--radius); background: var(--bg-input);
  font-size: 0.875rem; font-family: var(--font); color: var(--text-primary);
  cursor: pointer; transition: all var(--transition);
}
select:focus { outline: none; border-color: var(--border-focus); }

/* Type badge */
.type-badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: var(--radius-sm);
  font-size: 0.68rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.05em;
}
.type-badge.llm { background: #ede9fe; color: #7c3aed; }
.type-badge.asr { background: #fce7f3; color: #db2777; }
.type-badge.ocr { background: #e0f2fe; color: #0284c7; }

/* Tabs */
.tabs { display: flex; gap: 2px; margin-bottom: 18px; border-bottom: 1px solid var(--border); padding-bottom: 2px; }
.tab-btn {
  padding: 8px 18px; border: none; background: none;
  font-size: 0.85rem; font-weight: 500; color: var(--text-muted);
  cursor: pointer; border-bottom: 2px solid transparent;
  transition: all var(--transition);
}
.tab-btn:hover { color: var(--text-primary); }
.tab-btn.active { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }

/* Binding card */
.binding-row {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border: 1px solid var(--border-light);
  border-radius: var(--radius); margin-bottom: 8px;
  transition: all var(--transition);
}
.binding-row:hover { border-color: var(--border); background: var(--bg-card-hover); }
.binding-row .br-label { flex: 0 0 140px; font-weight: 550; font-size: 0.85rem; color: var(--text-primary); }
.binding-row .br-select { flex: 1; }
.binding-row .br-select select { width: 100%; }

/* Bento Grid (Dashboard) */
.bento-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 24px; }
.bento-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 24px 28px; box-shadow: var(--shadow-card); }

/* Skeleton Loading */
.skeleton { background: var(--border-light); border-radius: var(--radius-sm); position: relative; overflow: hidden; }
.skeleton::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.55), transparent); animation: skeleton-shimmer 1.5s ease-in-out infinite; }
.skeleton-text { height: 14px; margin-bottom: 8px; border-radius: var(--radius-sm); }
.skeleton-text.w-2 { width: 66.6%; }
.skeleton-text.w-3 { width: 100%; }

@keyframes skeleton-shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* Pagination */
.pagination { display: flex; gap: 4px; align-items: center; justify-content: center; padding: 16px 0; }

/* Search bar */
.search-bar { flex: 1; max-width: 360px; }
.search-bar input { width: 100%; padding: 8px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 0.82rem; font-family: var(--font); background: var(--bg-input); color: var(--text-primary); }
.search-bar input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(37,99,235,0.1); }

/* Library category grid */
.library-cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }

/* Extract / Analysis two-column layout */
.extract-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
.extract-layout-3col { grid-template-columns: 1fr 1fr 1.2fr; }
.extract-layout-3col .extract-indicators { display: flex; flex-direction: column; }
.std-ind-category { margin-bottom: 8px; border-bottom: 1px solid var(--border); padding-bottom: 4px; }
.std-ind-category.collapsed .std-ind-cat-body { display: none; }
.std-ind-item:hover { background: var(--bg-surface); border-radius: 4px; }
.pagination button {
  padding: 6px 12px; border: 1px solid var(--border);
  background: var(--bg-surface); color: var(--text-secondary);
  border-radius: var(--radius-sm); cursor: pointer;
  font-size: 0.82rem; transition: all var(--transition);
}
.pagination button:hover:not(:disabled) { background: var(--accent); color: #fff; border-color: var(--accent); }
.pagination button:disabled { opacity: 0.35; cursor: not-allowed; }
.pagination .page-info { font-size: 0.8rem; color: var(--text-muted); padding: 0 8px; }

/* Utility */
.hidden { display: none !important; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-muted { color: var(--text-muted); }
.text-danger { color: var(--danger); }
.text-success { color: var(--success); }
.text-accent { color: var(--accent); }
.flex { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-20 { margin-top: 20px; }
.mb-12 { margin-bottom: 12px; }
.mb-16 { margin-bottom: 16px; }
.w-full { width: 100%; }

/* AI Config type selector */
.type-selector {
  display: flex; gap: 4px; margin-bottom: 12px;
  background: var(--bg-badge); border-radius: var(--radius);
  padding: 3px;
}
.type-selector button {
  flex: 1; padding: 6px 12px; border: none;
  background: transparent; color: var(--text-muted);
  border-radius: var(--radius-sm); cursor: pointer;
  font-size: 0.8rem; font-weight: 550; font-family: var(--font);
  transition: all var(--transition);
}
.type-selector button.active {
  background: var(--bg-surface); color: var(--text-primary);
  box-shadow: var(--shadow-sm);
}

/* Binding view */
.binding-section { margin-top: 24px; }
.binding-group-title {
  font-size: 0.82rem; font-weight: 600; color: var(--text-secondary);
  margin-bottom: 8px; padding-left: 2px;
}

/* Prompt preview */
.prompt-preview {
  background: #1e293b; color: #e2e8f0;
  padding: 14px 18px; border-radius: var(--radius);
  font-size: 0.82rem; white-space: pre-wrap;
  max-height: 200px; overflow-y: auto;
  font-family: var(--font-mono);
  line-height: 1.5;
}

/* Danger zone */
.danger-zone {
  border: 1px solid rgba(239,68,68,0.3);
  border-radius: var(--radius);
  background: var(--danger-bg);
  padding: 16px 20px;
  margin-top: 20px;
}
.danger-zone h4 { color: var(--danger); font-size: 0.88rem; margin-bottom: 8px; }
.danger-zone p { color: var(--text-secondary); font-size: 0.8rem; margin-bottom: 10px; }

/* ============================================================
   Custom Dialog (替代浏览器 alert / confirm / prompt)
   ============================================================ */
.dialog-overlay {
  position: fixed; inset: 0;
  background: rgba(15,23,42,0.5);
  backdrop-filter: blur(3px);
  z-index: 250;
  display: flex; align-items: center; justify-content: center;
}
.dialog {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  width: 420px; max-width: 92vw;
  animation: fadeScaleIn 0.2s ease-out;
}
.dialog-body {
  padding: 28px 30px 20px;
  text-align: center;
}
.dialog-icon {
  font-size: 2.4rem; margin-bottom: 12px; line-height: 1;
}
.dialog-title {
  font-size: 1.05rem; font-weight: 650;
  color: var(--text-primary); margin-bottom: 8px;
}
.dialog-message {
  font-size: 0.88rem; color: var(--text-secondary);
  line-height: 1.6; margin-bottom: 4px;
}
.dialog-input-wrap { margin-top: 16px; }
.dialog-input-wrap input {
  width: 100%; padding: 10px 14px;
  border: 1.5px solid var(--border-input); border-radius: var(--radius);
  background: var(--bg-input); font-size: 0.9rem; font-family: var(--font);
  color: var(--text-primary); outline: none; transition: all var(--transition);
}
.dialog-input-wrap input:focus { border-color: var(--border-focus); box-shadow: 0 0 0 3px var(--accent-glow); }
.dialog-actions {
  display: flex; gap: 10px; justify-content: center;
  padding: 16px 24px 22px;
}

/* ============================================================
   Animations
   ============================================================ */
@keyframes fadeScaleIn {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}
@keyframes slideToast {
  from { opacity: 0; transform: translateX(40px); }
  to { opacity: 1; transform: translateX(0); }
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}
.pulse { animation: pulse 2s ease-in-out infinite; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 900px) {
  :root { --sidebar-w: 60px; }
  .sidebar-logo .logo-text, .sidebar-logo .logo-ver,
  .sidebar-item span:not(.nav-icon), .sidebar-group-title,
  .sidebar-footer .user-info { display: none; }
  .sidebar-item { justify-content: center; padding: 10px; }
  .sidebar-logo { justify-content: center; padding: 14px 8px; }
  .homepage-cards { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
  .form-row { grid-template-columns: 1fr; }
  .bento-grid { grid-template-columns: 1fr; }
  .extract-layout { grid-template-columns: 1fr; }
  .extract-layout-3col { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .page-body { padding: 18px; }
  .card-grid, .stat-grid { grid-template-columns: 1fr; }
  .homepage-cards { grid-template-columns: 1fr; padding: 16px; }
  .homepage-hero h2 { font-size: 1.5rem; }
  .page-header { padding: 12px 16px; }
  .modal { max-width: 98vw; border-radius: var(--radius-lg); }
  .dialog { width: 94vw; }
  .toolbar { padding: 12px 14px; margin-bottom: 16px; }
}

/* ============================================================
   笔试管理增强样式
   ============================================================ */

/* 考试安排 Tab 按钮（笔试/测评管理共用） */
.exam-tab-btn {
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #ffffff;
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
}
.exam-tab-btn:hover {
  background: var(--bg-badge);
  color: var(--text-primary);
  border-color: var(--accent);
}
/* 选中态：蓝色背景白色文字 */
.exam-tab-btn.active {
  background: var(--accent);
  color: #ffffff;
  border-color: var(--accent);
}
.exam-tab-btn.active:hover {
  background: var(--accent);
  color: #ffffff;
}

/* 测评管理 Tab 容器（与笔试管理视觉对齐） */
.assess-tabs {
  display: flex;
  gap: 8px;
  align-items: center;
}
/* 笔试管理 Tab 容器对齐（统一间距） */
#page-exam > div[style*="gap:12px"] {
  gap: 8px !important;
}

/* 阅卷台布局 */
.grading-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 16px;
  align-items: start;
}
.grading-left .card,
.grading-right .card {
  margin: 0;
}
.grading-student-row {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-light);
  cursor: pointer;
  transition: background var(--transition);
}
.grading-student-row:hover {
  background: var(--bg-badge);
}
.grading-student-row.active {
  background: rgba(37, 99, 235, 0.08);
  border-left: 3px solid var(--accent);
  padding-left: 13px;
}

/* 考试进度统计 */
.schedule-progress-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.stat-card-mini {
  background: var(--bg-badge);
  border-radius: var(--radius);
  padding: 16px;
  text-align: center;
}
.stat-card-mini .stat-num {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text-primary);
}
.stat-card-mini .stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* 成绩分析统计卡片 */
.analysis-stats-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}
.analysis-stats-grid .stat-card {
  padding: 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.stat-card-icon {
  font-size: 1.5rem;
  margin-bottom: 4px;
}
.stat-card-value {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
}
.stat-card-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* 成绩分析图表 */
.analysis-charts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.card-header {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}
.card-header h3 {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* 直方图 */
.histogram-chart {
  display: flex;
  align-items: flex-end;
  justify-content: space-around;
  height: 220px;
  padding: 16px 8px 0;
  border-bottom: 2px solid var(--border);
  gap: 8px;
}
.histogram-bar-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  height: 100%;
  justify-content: flex-end;
}
.histogram-bar-count {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 4px;
}
.histogram-bar {
  width: 80%;
  max-width: 60px;
  min-height: 4px;
  border-radius: 4px 4px 0 0;
  transition: height 0.4s ease;
}
.histogram-bar-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 6px;
  text-align: center;
}

/* 单人成绩报告 */
.student-report-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  background: var(--bg-badge);
  border-radius: var(--radius);
  margin-bottom: 16px;
}
.student-report-scores {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}
.score-item {
  padding: 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
}
.score-item-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
}
.score-item-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* 自动组卷配置 */
.autogen-section {
  background: var(--bg-badge);
}

/* 响应式调整 */
@media (max-width: 900px) {
  .grading-layout {
    grid-template-columns: 1fr;
  }
  .analysis-stats-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .schedule-progress-stats {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 640px) {
  .analysis-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ============================================================
   新增: 通知中心 & 人才库 & 数据驾驶舱 样式
   ============================================================ */

/* 通知角标 */
.notif-badge {
  position: absolute;
  top: 4px;
  right: 8px;
  background: #ef4444;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
}

/* 通知列表项 */
.notif-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 8px;
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s;
}
.notif-item:hover {
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.notif-item.unread {
  border-left: 3px solid var(--accent);
  background: var(--accent-light);
}
.notif-icon {
  font-size: 24px;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-surface);
  border-radius: 10px;
}
.notif-body { flex: 1; min-width: 0; }
.notif-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.notif-title {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-primary);
}
.notif-type-tag {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 99px;
  background: var(--bg-badge);
  color: var(--text-muted);
}
.notif-content {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 6px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.notif-meta {
  font-size: 12px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 12px;
}
.notif-link { color: var(--accent); font-size: 12px; text-decoration: none; }
.notif-link:hover { text-decoration: underline; }
.notif-delete {
  flex-shrink: 0;
  opacity: 0;
  transition: opacity 0.2s;
  font-size: 20px;
  padding: 0 8px;
}
.notif-item:hover .notif-delete { opacity: 1; }

/* 通知模板卡片 */
.template-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
}
.template-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}
.template-preview {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-secondary);
  background: var(--bg-surface);
  padding: 12px;
  border-radius: 6px;
}

/* 标签筛选 */
.tags-section .tag {
  display: inline-flex;
  align-items: center;
  font-size: 12px;
  padding: 4px 10px;
  background: var(--bg-badge);
  border: 1px solid var(--border);
  border-radius: 99px;
  color: var(--text-secondary);
}
.tag-clickable { cursor: pointer; transition: all 0.2s; }
.tag-clickable:hover {
  background: var(--accent-light);
  border-color: var(--accent);
  color: var(--accent);
}
.tag-active {
  background: var(--accent-light) !important;
  border-color: var(--accent) !important;
  color: var(--accent) !important;
  font-weight: 500;
}

/* Badge 增强 */
.badge-danger { background: var(--danger-bg); color: var(--danger); }
.badge-warning { background: var(--warning-bg); color: var(--warning); }
.badge-success { background: var(--success-bg); color: var(--success); }
.row-danger { background: rgba(239,68,68,0.04); }

/* 批量操作栏 */
.batch-bar {
  background: var(--accent-light);
  border: 1px solid rgba(37,99,235,0.2);
}

/* 简历详情 */
.detail-section {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}
.detail-section h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.info-item { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.info-item label {
  font-size: 12px;
  color: var(--text-muted);
  min-width: 60px;
}
.info-item span {
  color: var(--text-primary);
  font-weight: 500;
}

/* 表单网格 */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* 搜索结果高亮 */
.resume-name {
  color: var(--accent);
  font-weight: 500;
  text-decoration: none;
}
.resume-name:hover { text-decoration: underline; }

/* 统一 modal-overlay 显示 */
.modal-overlay[style*="display:flex"] {
  display: flex !important;
}

/* 页面头部操作区 */
.page-header-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

/* 响应式调整 */
@media (max-width: 768px) {
  .info-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .notif-item { padding: 12px; }
}

/* ============================================================
   首页导航增强
   ============================================================ */
.homepage-hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 12px;
}
.homepage-hero-actions .btn {
  min-width: 160px;
  font-size: 1rem;
  padding: 12px 28px;
}

/* ============================================================
   用户端门户专属样式
   ============================================================ */

/* 欢迎卡片 */
.user-welcome-card {
  display: flex;
  align-items: center;
  gap: 20px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
.user-welcome-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  font-size: 24px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.user-welcome-info {
  flex: 1;
}
.user-welcome-info h2 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 4px 0;
}
.user-welcome-info p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}
.user-welcome-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

/* 无数据空状态 */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
}
.empty-state h3 {
  font-size: 16px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 8px;
}
.empty-state p {
  font-size: 13px;
}

/* 加载状态 */
.loading-spinner {
  text-align: center;
  padding: 40px;
  color: var(--text-muted);
  font-size: 14px;
}

/* 错误状态 */
.error-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
}
.error-state p {
  margin-bottom: 12px;
  color: var(--danger);
}

/* 详情区域 */
.detail-section {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 12px;
}
.detail-section h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 12px 0;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

/* 信息项 */
.info-label {
  font-size: 12px;
  color: var(--text-muted);
  min-width: 80px;
  display: inline-block;
}
.info-value {
  color: var(--text-primary);
  font-weight: 500;
}

/* 个人信息卡片 */
.profile-card {
  display: flex;
  align-items: center;
  gap: 20px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}
.profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  font-size: 28px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.profile-info-section h2 {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 4px 0;
}
.profile-role {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}

/* 通知列表（用户端） */
.notif-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.notif-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-light);
  background: #fff;
  transition: background 0.15s;
}
.notif-item:last-child { border-bottom: none; }
.notif-item:hover { background: var(--bg); }
.notif-unread { background: #eff6ff; }
.notif-content {
  flex: 1;
  cursor: pointer;
  min-width: 0;
}
.notif-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 6px;
}
.notif-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #2563eb;
  flex-shrink: 0;
}
.notif-body {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.notif-time {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* btn-full（占满整行） */
.btn-full {
  width: calc(100% - 16px);
}

/* ============================================================
   Collapsible Sidebar (v0.7.1)
   ============================================================ */
.sidebar-group-title {
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
  transition: color 0.2s;
}
.sidebar-group-title:hover {
  color: #e2e8f0;
}
.group-arrow {
  font-size: 0.65rem;
  transition: transform 0.2s;
  opacity: 0.6;
}
.sidebar-group.collapsed .group-arrow {
  transform: rotate(-90deg);
}
.sidebar-group.collapsed .sidebar-group-items {
  display: none;
}
.sidebar-group-items {
  transition: max-height 0.3s ease;
}

/* ============================================================
   Public Job Listing (v0.8.0 专业招聘网站风格)
   ============================================================ */
.homepage-jobs-section {
  margin-top: 48px;
  padding: 0 16px 48px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}
.homepage-jobs-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 12px;
}
.homepage-jobs-header h3 {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}
.homepage-jobs-count {
  font-size: 0.82rem;
  color: var(--text-secondary);
  background: #eff6ff;
  padding: 4px 14px;
  border-radius: 20px;
  font-weight: 500;
}

/* 搜索栏 */
.jobs-search-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.jobs-search-bar input[type="text"] {
  flex: 1;
  min-width: 200px;
  padding: 10px 16px;
  border: 1.5px solid var(--border-input);
  border-radius: var(--radius);
  font-size: 0.9rem;
  transition: border-color 0.2s;
}
.jobs-search-bar input[type="text"]:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

/* 岗位卡片网格 */
.jobs-list-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.jobs-loading {
  text-align: center;
  padding: 48px;
  color: var(--text-muted);
  grid-column: 1 / -1;
}

/* 单个岗位卡片 */
.job-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  transition: box-shadow 0.2s, border-color 0.2s, transform 0.15s;
  display: flex;
  flex-direction: column;
  gap: 12px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.job-card:hover {
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
  border-color: var(--accent);
  transform: translateY(-2px);
}
.job-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--accent);
  opacity: 0;
  transition: opacity 0.2s;
}
.job-card:hover::before {
  opacity: 1;
}

/* 卡片头部：标题 + 状态 */
.job-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}
.job-card-title {
  font-size: 1.05rem;
  font-weight: 650;
  color: var(--text-primary);
  letter-spacing: -0.01em;
  margin: 0;
  line-height: 1.35;
}
.job-card-left {
  flex: 1;
  min-width: 0;
}
.job-card-right {
  flex-shrink: 0;
}

/* 岗位元信息标签 */
.job-card-meta {
  display: flex;
  gap: 8px 16px;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: var(--text-secondary);
}
.job-card-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.job-card-meta .meta-label {
  color: var(--text-muted);
}

/* 薪资高亮 */
.job-card-salary {
  color: #ea580c;
  font-weight: 600;
  font-size: 0.92rem;
}

/* 卡片底部：发布时间 + 投递人数 */
.job-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 10px;
  border-top: 1px solid var(--border-light);
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* 状态标签 */
.job-tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.72rem;
  font-weight: 600;
  white-space: nowrap;
}
.job-tag-active { background: #dcfce7; color: #15803d; }
.job-tag-closed { background: #f1f5f9; color: #64748b; }
.job-tag-draft { background: #fef3c7; color: #92400e; }

.jobs-empty {
  text-align: center;
  padding: 56px 24px;
  color: var(--text-muted);
  grid-column: 1 / -1;
}
.jobs-empty h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
  color: var(--text-secondary);
}

/* 岗位详情弹窗内容 */
.job-detail-modal-body {
  padding: 0;
}
.job-detail-section {
  margin-bottom: 24px;
}
.job-detail-section h4 {
  font-size: 0.95rem;
  font-weight: 650;
  color: var(--text-primary);
  margin-bottom: 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-light);
}
.job-detail-section .job-detail-text {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.7;
  white-space: pre-wrap;
}
.job-detail-meta {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
  padding: 16px;
  background: #f8fafc;
  border-radius: var(--radius);
}
.job-detail-meta .meta-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.job-detail-meta .meta-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 500;
}
.job-detail-meta .meta-value {
  font-size: 0.88rem;
  color: var(--text-primary);
  font-weight: 550;
}

/* 分页 */
.jobs-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 24px;
  flex-wrap: wrap;
}
.jobs-pagination button {
  min-width: 36px;
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.15s;
}
.jobs-pagination button:hover:not(:disabled) {
  border-color: var(--accent);
  color: var(--accent);
}
.jobs-pagination button.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.jobs-pagination button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ============================================================
   Exam Taking Page (v0.7.1)
   ============================================================ */
.exam-taking-layout {
  display: flex;
  gap: 20px;
}
.exam-questions-area {
  flex: 1;
  min-width: 0;
}
.exam-progress-panel {
  width: 240px;
  flex-shrink: 0;
  position: sticky;
  top: 20px;
}
.exam-question-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}
.exam-question-number {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 8px;
}
.exam-question-text {
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 16px;
  color: var(--text-primary);
}
.exam-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.exam-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.exam-option:hover { background: var(--bg); }
.exam-option.selected { background: #eff6ff; border-color: var(--primary); }
.exam-option input { margin: 0; }
.exam-option-label {
  font-weight: 600;
  min-width: 24px;
  color: var(--text-muted);
}
.answer-card-num {
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s;
}
.answer-card-num:hover { border-color: var(--primary); }
.answer-card-num.answered { background: var(--primary); color: #fff; border-color: var(--primary); }
.answer-card-num.current { border-color: var(--primary); border-width: 2px; }

/* ============================================================
   System Admin Tabs + New Features (v0.7.1)
   ============================================================ */
.sys-info-block {
  margin-bottom: 16px;
}
.sys-info-block h4 {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-light);
}
.sys-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 16px;
}
.sys-info-item {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 0.85rem;
  border-bottom: 1px solid var(--border-light);
}
.sys-info-item .key { color: var(--text-muted); }
.sys-info-item .value { font-weight: 500; color: var(--text-primary); }
.log-file-item {
  padding: 8px 16px;
  cursor: pointer;
  border-bottom: 1px solid var(--border-light);
  font-size: 0.82rem;
  transition: background 0.15s;
}
.log-file-item:hover { background: var(--bg); }
.log-file-item.active { background: #eff6ff; border-left: 3px solid var(--primary); }
.log-file-item .lf-name { font-weight: 500; }
.log-file-item .lf-meta { font-size: 0.72rem; color: var(--text-muted); margin-top: 2px; }

/* ============================================================
   Modal Close Button Fix (v0.7.1)
   ============================================================ */
.login-modal .modal-close-btn {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-muted);
  line-height: 1;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: background 0.15s, color 0.15s;
}
.login-modal .modal-close-btn:hover {
  background: var(--bg);
  color: var(--text-primary);
}

/* Toast positioning fix */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast {
  background: #1e293b;
  color: #fff;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 0.88rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  animation: slideIn 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 380px;
}
.toast.success { border-left: 4px solid #22c55e; }
.toast.error { border-left: 4px solid #ef4444; }
@keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }

/* ============================================================
   Tech-Style Enhancements (v0.8.0 科技风升级)
   ============================================================ */
:root {
  --sidebar-bg: #0f172a;
  --sidebar-hover: #1e293b;
  --sidebar-active: #1e3a5f;
  --primary-glow: rgba(37, 99, 235, 0.12);
  --sidebar-indicator: #2563eb;
  --sidebar-divider: rgba(255, 255, 255, 0.06);
}

/* 侧边栏渐变深色背景 */
.sidebar {
  background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%);
  font-family: 'Inter', 'Noto Sans SC', -apple-system, sans-serif;
}

/* Logo 区域 */
.sidebar-logo {
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--sidebar-divider);
}
.sidebar-logo .logo-icon {
  background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
  box-shadow: 0 0 12px rgba(37, 99, 235, 0.3);
}
.sidebar-logo .logo-ver {
  color: #64748b;
}

/* 侧边栏导航容器 */
.sidebar-nav {
  padding: 8px 0 16px;
}

/* 顶部分隔细线 */
.sidebar-nav::before {
  content: '';
  display: block;
  height: 1px;
  background: var(--sidebar-divider);
  margin: 0 16px 8px;
}

/* 分组容器 */
.sidebar-group {
  margin-bottom: 2px;
}
.sidebar-group + .sidebar-group::before {
  content: '';
  display: block;
  height: 1px;
  background: var(--sidebar-divider);
  margin: 4px 16px;
}

/* 分组标题 - 可点击，带 chevron 旋转 */
.sidebar-group-title {
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 20px 6px;
  font-size: 0.66rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(148, 163, 184, 0.65);
  user-select: none;
  transition: color 0.2s ease;
}
.sidebar-group-title:hover {
  color: #cbd5e1;
}

/* chevron 箭头旋转动画 */
.sidebar-group-title .group-arrow {
  font-size: 0.6rem;
  opacity: 0.5;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-block;
}
.sidebar-group.collapsed .group-arrow {
  transform: rotate(-90deg);
}
.sidebar-group.collapsed .sidebar-group-items {
  display: none;
}
.sidebar-group-items {
  transition: max-height 0.3s ease;
  overflow: hidden;
}

/* 菜单项 - 科技风 */
.sidebar-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 20px 9px 28px;
  margin: 1px 0;
  font-size: 0.86rem;
  font-weight: 450;
  color: rgba(226, 232, 240, 0.78);
  cursor: pointer;
  border-radius: 0;
  border-left: 3px solid transparent;
  transition: all 0.15s ease;
  white-space: nowrap;
  position: relative;
}
.sidebar-item:hover {
  background: var(--sidebar-hover);
  color: #ffffff;
  border-left-color: var(--sidebar-indicator);
}
.sidebar-item.active {
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.18) 0%, rgba(37, 99, 235, 0.02) 70%);
  color: #ffffff;
  border-left-color: var(--sidebar-indicator);
  font-weight: 550;
}
.sidebar-item .nav-icon {
  font-size: 1rem;
  line-height: 1;
  width: 20px;
  text-align: center;
  flex-shrink: 0;
  opacity: 0.85;
}
.sidebar-item.active .nav-icon {
  opacity: 1;
}

/* SVG 图标样式 */
.sidebar-item .nav-icon svg,
.sidebar-item svg.nav-icon {
  width: 16px;
  height: 16px;
  display: inline-block;
  vertical-align: middle;
}

/* 底部用户区 */
.sidebar-footer {
  border-top: 1px solid var(--sidebar-divider);
}

/* Card hover lift effect */
.card {
  transition: box-shadow 0.2s, transform 0.15s;
}
.card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}

/* Enhanced stat cards */
.stat-card {
  transition: box-shadow 0.2s, transform 0.15s;
}
.stat-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
  transform: translateY(-1px);
}

/* ============================================================
   Competency Library Grid (v0.7.1)
   ============================================================ */
.library-cats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}
.lib-cat-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  cursor: pointer;
  transition: box-shadow 0.2s, border-color 0.2s;
}
.lib-cat-card:hover {
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  border-color: var(--primary);
}
.lib-cat-card .cat-name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}
.lib-cat-card .cat-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.lib-cat-card .cat-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

/* ============================================================
   AI Extract Workflow Layout (v0.7.1)
   ============================================================ */
.extract-indicator-selector {
  margin-top: 4px;
}
.extract-selected-count {
  font-size: 0.82rem;
  color: var(--primary);
  font-weight: 500;
  background: #eff6ff;
  padding: 4px 12px;
  border-radius: 12px;
}
.extract-indicator-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-bottom: 1px solid var(--border-light);
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.15s;
}
.extract-indicator-item:hover { background: var(--bg); }
.extract-indicator-item.selected { background: #eff6ff; }
.extract-indicator-item input { margin: 0; width: auto; }
.extract-indicator-item .ind-name { font-weight: 500; flex: 1; }
.extract-indicator-item .ind-dim { font-size: 0.78rem; color: var(--text-muted); padding: 1px 8px; background: var(--bg); border-radius: 10px; }

/* ============================================================
   Competency Library v0.8.0 — Refactored Layout
   ============================================================ */
.lib-page-container { display: flex; flex-direction: column; height: 100%; gap: 16px; }
.lib-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius); padding: 14px 20px;
}
.lib-toolbar-left { display: flex; align-items: center; gap: 12px; flex: 1; }
.lib-toolbar-right { display: flex; align-items: center; gap: 12px; }
.lib-search-wrap { position: relative; flex: 1; max-width: 420px; }
.lib-search-wrap .lib-search-icon {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  color: var(--text-muted); font-size: 0.9rem; pointer-events: none;
}
.lib-search-input {
  width: 100%; padding: 9px 12px 9px 36px; border: 1px solid var(--border);
  border-radius: var(--radius); font-size: 0.875rem; transition: border-color 0.2s;
}
.lib-search-input:focus { border-color: var(--primary); outline: none; box-shadow: 0 0 0 3px rgba(37,99,235,0.1); }

.lib-body { display: grid; grid-template-columns: 240px 1fr; gap: 16px; flex: 1; min-height: 0; }
.lib-sidebar {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 12px; overflow-y: auto; max-height: calc(100vh - 240px);
}
.lib-main { display: flex; flex-direction: column; gap: 12px; min-height: 0; }
.lib-breadcrumb {
  font-size: 0.82rem; color: var(--text-muted); padding: 0 4px;
}
.lib-grid-container { flex: 1; overflow-y: auto; padding-right: 4px; }
.library-indicators-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}
.lib-pagination-wrap {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 0; border-top: 1px solid var(--border-light);
}

/* 分类树节点 */
.lib-tree-section-title {
  font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.5px;
  color: var(--text-muted); padding: 8px 10px 4px; font-weight: 600;
}
.lib-tree-node {
  display: flex; align-items: center; gap: 8px; padding: 8px 10px;
  border-radius: 6px; cursor: pointer; font-size: 0.875rem; color: var(--text-secondary);
  transition: background 0.15s, color 0.15s; margin-bottom: 2px;
}
.lib-tree-node:hover { background: var(--bg); color: var(--text-primary); }
.lib-tree-node.active { background: #eff6ff; color: var(--primary); font-weight: 500; }
.lib-tree-node.active .lib-tree-count { background: var(--primary); color: #fff; }
.lib-tree-icon { font-size: 0.95rem; flex-shrink: 0; }
.lib-tree-label { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lib-tree-count {
  font-size: 0.72rem; padding: 1px 7px; border-radius: 10px;
  background: var(--bg); color: var(--text-muted); flex-shrink: 0;
}

/* 指标卡片 */
.lib-indicator-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px; display: flex; flex-direction: column; gap: 10px;
  transition: box-shadow 0.2s, border-color 0.2s, transform 0.15s;
}
.lib-indicator-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.08); border-color: var(--primary); transform: translateY(-2px); }
.lib-card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.lib-card-name {
  font-size: 1rem; font-weight: 600; color: var(--text-primary);
  margin: 0; flex: 1; line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.lib-card-actions { display: flex; gap: 4px; flex-shrink: 0; }
.lib-card-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.lib-tag {
  font-size: 0.72rem; padding: 2px 8px; border-radius: 10px; font-weight: 500;
}
.lib-tag.dim-professional { background: #dbeafe; color: #1e40af; }
.lib-tag.dim-quality { background: #dcfce7; color: #166534; }
.lib-tag.dim-other { background: #f3f4f6; color: #374151; }
.lib-tag.lib-tag-category { background: #fef3c7; color: #92400e; }
.lib-card-desc {
  font-size: 0.82rem; color: var(--text-muted); margin: 0; line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.lib-card-weight { display: flex; align-items: center; gap: 8px; }
.lib-weight-label { font-size: 0.75rem; color: var(--text-muted); width: 30px; }
.lib-weight-bar {
  flex: 1; height: 6px; background: var(--bg); border-radius: 3px; overflow: hidden;
}
.lib-weight-fill {
  height: 100%; background: linear-gradient(90deg, var(--primary), #3b82f6);
  border-radius: 3px; transition: width 0.3s;
}
.lib-weight-value { font-size: 0.82rem; font-weight: 600; color: var(--primary); width: 24px; text-align: right; }
.lib-card-anchors { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.lib-card-anchors-label { font-size: 0.72rem; color: var(--text-muted); margin-right: 4px; }
.lib-anchor-tag {
  font-size: 0.7rem; padding: 2px 6px; background: #f3f4f6; color: var(--text-secondary);
  border-radius: 4px; max-width: 120px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.lib-anchor-more { font-size: 0.7rem; color: var(--text-muted); }

/* 指标表单 */
.lib-form { display: flex; flex-direction: column; gap: 12px; }
.lib-anchor-row { display: flex; gap: 6px; align-items: center; margin-bottom: 6px; }
.lib-anchor-input { flex: 1; }

/* ============================================================
   AI Extract v0.8.0 — 3-Step Workflow
   ============================================================ */
.extract-page-container { display: flex; flex-direction: column; gap: 20px; }
.extract-stepper {
  display: flex; align-items: center; justify-content: center; gap: 0;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px 32px;
}
.extract-step {
  display: flex; align-items: center; gap: 10px; cursor: pointer;
  transition: color 0.2s; position: relative;
}
.extract-step-circle {
  width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center;
  justify-content: center; font-weight: 600; font-size: 0.95rem;
  border: 2px solid var(--border); color: var(--text-muted); background: #fff;
  transition: all 0.3s; flex-shrink: 0;
}
.extract-step-label { font-size: 0.9rem; color: var(--text-muted); font-weight: 500; }
.extract-step.active .extract-step-circle {
  background: var(--primary); border-color: var(--primary); color: #fff;
}
.extract-step.active .extract-step-label { color: var(--primary); font-weight: 600; }
.extract-step.completed .extract-step-circle {
  background: #dcfce7; border-color: #16a34a; color: #16a34a;
}
.extract-step.completed .extract-step-label { color: #16a34a; }
.extract-step-line {
  width: 60px; height: 2px; background: var(--border); margin: 0 12px;
  transition: background 0.3s;
}
.extract-step-line.completed { background: #16a34a; }

.extract-step-content {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 24px;
}
.extract-step-content.hidden { display: none; }
.extract-textarea-wrap { position: relative; }
.extract-jd-textarea {
  width: 100%; min-height: 240px; padding: 14px; font-size: 0.875rem;
  border: 1px solid var(--border); border-radius: var(--radius); resize: vertical;
  font-family: inherit; line-height: 1.6;
}
.extract-jd-textarea:focus { border-color: var(--primary); outline: none; box-shadow: 0 0 0 3px rgba(37,99,235,0.1); }
.extract-file-upload {
  border: 2px dashed var(--border); border-radius: var(--radius); padding: 24px;
  text-align: center; cursor: pointer; transition: border-color 0.2s, background 0.2s;
  margin-top: 12px;
}
.extract-file-upload:hover { border-color: var(--primary); background: #f8fafc; }
.extract-file-upload.has-file { border-color: #16a34a; background: #f0fdf4; }

.extract-selector-body { display: grid; grid-template-columns: 220px 1fr; gap: 16px; min-height: 320px; }
.extract-selector-tree {
  border: 1px solid var(--border); border-radius: var(--radius); padding: 10px; overflow-y: auto; max-height: 400px;
}
.extract-selector-list { max-height: 400px; overflow-y: auto; border: 1px solid var(--border); border-radius: var(--radius); }
.extract-selector-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  border-bottom: 1px solid var(--border-light); cursor: pointer; transition: background 0.15s;
}
.extract-selector-item:hover { background: var(--bg); }
.extract-selector-item.selected { background: #eff6ff; }
.extract-selector-item input[type="checkbox"] { width: 16px; height: 16px; cursor: pointer; }
.extract-selector-item-info { flex: 1; }
.extract-selector-item-name { font-size: 0.875rem; font-weight: 500; color: var(--text-primary); }
.extract-selector-item-meta { font-size: 0.75rem; color: var(--text-muted); margin-top: 2px; }

.extract-result-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px; margin-bottom: 12px; transition: border-color 0.2s;
}
.extract-result-card.adopted { border-color: #16a34a; background: #f0fdf4; }
.extract-result-card.rejected { border-color: var(--border); opacity: 0.55; }
.extract-result-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; margin-bottom: 8px; }
.extract-result-card-name { font-size: 1rem; font-weight: 600; color: var(--text-primary); margin: 0; }
.extract-result-card-tags { display: flex; gap: 6px; margin: 6px 0; }
.extract-result-card-desc { font-size: 0.82rem; color: var(--text-muted); line-height: 1.5; margin: 6px 0; }
.extract-result-card-actions { display: flex; gap: 8px; margin-top: 10px; }

/* ============================================================
   Exam Taking v0.8.0 — 作答界面
   ============================================================ */
.exam-take-container { display: grid; grid-template-columns: 240px 1fr; gap: 16px; min-height: 600px; }
.exam-take-header {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px 24px; display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
}
.exam-take-title { font-size: 1.1rem; font-weight: 600; color: var(--text-primary); margin: 0; }
.exam-take-timer {
  font-size: 1.2rem; font-weight: 700; padding: 6px 16px; border-radius: 8px;
  background: #fef3c7; color: #92400e; font-variant-numeric: tabular-nums;
}
.exam-take-timer.warning { background: #fee2e2; color: #dc2626; animation: pulse 1.5s infinite; }
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.7} }

.exam-answer-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px; overflow-y: auto; max-height: calc(100vh - 280px);
}
.exam-answer-card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(44px, 1fr)); gap: 8px; }
.exam-answer-card-item {
  width: 40px; height: 40px; border-radius: 6px; border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center; font-size: 0.85rem;
  font-weight: 500; cursor: pointer; transition: all 0.15s; background: #fff;
}
.exam-answer-card-item:hover { border-color: var(--primary); }
.exam-answer-card-item.answered { background: #dcfce7; border-color: #16a34a; color: #16a34a; }
.exam-answer-card-item.current { background: var(--primary); border-color: var(--primary); color: #fff; }
.exam-answer-card-item.marked { background: #fef3c7; border-color: #d97706; color: #d97706; }
.exam-answer-card-legend { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border-light); font-size: 0.75rem; color: var(--text-muted); }
.exam-answer-card-legend-item { display: flex; align-items: center; gap: 4px; }
.exam-answer-card-legend-dot { width: 12px; height: 12px; border-radius: 3px; border: 1px solid var(--border); }

.exam-question-panel {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 24px; display: flex; flex-direction: column; gap: 16px;
}
.exam-question-meta { display: flex; align-items: center; gap: 8px; font-size: 0.82rem; color: var(--text-muted); }
.exam-question-type-badge {
  padding: 2px 10px; border-radius: 10px; font-size: 0.72rem; font-weight: 500;
  background: #eff6ff; color: var(--primary);
}
.exam-question-score { font-weight: 500; color: var(--text-secondary); }
.exam-question-stem { font-size: 1rem; line-height: 1.7; color: var(--text-primary); white-space: pre-wrap; }
.exam-question-options { display: flex; flex-direction: column; gap: 10px; }
.exam-option-item {
  display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px;
  border: 1px solid var(--border); border-radius: 8px; cursor: pointer; transition: all 0.15s;
}
.exam-option-item:hover { border-color: var(--primary); background: #f8fafc; }
.exam-option-item.selected { border-color: var(--primary); background: #eff6ff; }
.exam-option-letter {
  width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center; font-size: 0.82rem; font-weight: 600;
  flex-shrink: 0; transition: all 0.15s;
}
.exam-option-item.selected .exam-option-letter { background: var(--primary); border-color: var(--primary); color: #fff; }
.exam-option-text { flex: 1; font-size: 0.9rem; line-height: 1.5; padding-top: 3px; }
.exam-question-nav { display: flex; justify-content: space-between; align-items: center; padding-top: 16px; border-top: 1px solid var(--border-light); }

.exam-result-summary {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 32px; text-align: center; margin-bottom: 16px;
}
.exam-result-score { font-size: 3rem; font-weight: 700; color: var(--primary); margin: 8px 0; }
.exam-result-grade { font-size: 1.2rem; font-weight: 600; padding: 4px 16px; border-radius: 16px; display: inline-block; }

/* 阅卷台 */
.grading-console { display: grid; grid-template-columns: 320px 1fr; gap: 16px; }
.grading-candidate-list {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  max-height: calc(100vh - 220px); overflow-y: auto;
}
.grading-candidate-item {
  padding: 12px 16px; border-bottom: 1px solid var(--border-light); cursor: pointer;
  transition: background 0.15s;
}
.grading-candidate-item:hover { background: var(--bg); }
.grading-candidate-item.active { background: #eff6ff; border-left: 3px solid var(--primary); }
.grading-candidate-name { font-size: 0.9rem; font-weight: 500; color: var(--text-primary); }
.grading-candidate-meta { font-size: 0.75rem; color: var(--text-muted); margin-top: 4px; display: flex; gap: 8px; }
.grading-detail-panel { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; }
.grading-question-item { border: 1px solid var(--border); border-radius: 8px; padding: 16px; margin-bottom: 12px; }
.grading-question-item.auto { background: #f0fdf4; border-color: #bbf7d0; }
.grading-question-item.manual { background: #fffbeb; border-color: #fde68a; }

/* ============================================================
   System Admin v0.8.0 — 5-Tab 完善
   ============================================================ */
.sys-tab-content { padding: 20px 0; }
.sys-health-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.sys-health-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; display: flex; flex-direction: column; gap: 8px;
}
.sys-health-card-label { font-size: 0.8rem; color: var(--text-muted); font-weight: 500; }
.sys-health-card-value { font-size: 1.6rem; font-weight: 700; color: var(--text-primary); }
.sys-health-card-status { display: inline-flex; align-items: center; gap: 6px; font-size: 0.78rem; }
.sys-health-dot { width: 8px; height: 8px; border-radius: 50%; }
.sys-health-dot.healthy { background: #16a34a; }
.sys-health-dot.warning { background: #d97706; }
.sys-health-dot.error { background: #dc2626; }

.sys-server-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.sys-server-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px;
}
.sys-server-card-title { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.sys-server-row { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px solid var(--border-light); font-size: 0.85rem; }
.sys-server-row:last-child { border-bottom: none; }
.sys-server-row-label { color: var(--text-muted); }
.sys-server-row-value { color: var(--text-primary); font-weight: 500; }
.sys-server-progress { height: 6px; background: var(--bg); border-radius: 3px; overflow: hidden; margin-top: 4px; }
.sys-server-progress-fill { height: 100%; border-radius: 3px; transition: width 0.3s; }

.sys-log-viewer {
  background: #1e293b; color: #e2e8f0; border-radius: 8px; padding: 16px;
  font-family: 'SFMono-Regular', Consolas, monospace; font-size: 0.8rem; line-height: 1.6;
  max-height: 500px; overflow-y: auto; white-space: pre-wrap; word-break: break-all;
}
.sys-log-file-item {
  display: flex; align-items: center; justify-content: space-between; padding: 10px 14px;
  border-bottom: 1px solid var(--border-light); cursor: pointer; transition: background 0.15s;
}
.sys-log-file-item:hover { background: var(--bg); }
.sys-log-file-item.active { background: #eff6ff; }

