/* ========== 地下管线缺陷判别平台 - 全局样式 ========== */
:root {
  --primary: #1a5fb4;
  --primary-dark: #0d3d7a;
  --primary-light: #3584e4;
  --accent: #26a269;
  --accent-warn: #e5a50a;
  --accent-danger: #c01c28;
  --bg-page: #f0f1f3;
  --bg-card: #ffffff;
  --text-primary: #1c1c1c;
  --text-secondary: #5e5c64;
  --border: #c0bfc6;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.12);
  --radius: 8px;
  --radius-lg: 12px;
  --header-height: 140px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", sans-serif;
  font-size: 14px;
  color: var(--text-primary);
  background: var(--bg-page);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ========== 顶部导航 ========== */
.site-header {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
  color: #fff;
  padding: 20px 24px 16px;
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
}

.logo {
  margin: 0 0 4px 0;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.tagline {
  margin: 0 0 16px 0;
  font-size: 13px;
  opacity: 0.9;
}

.role-nav {
  display: flex;
  gap: 8px;
}

.role-btn {
  padding: 10px 20px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  transition: background 0.2s, border-color 0.2s;
}

.role-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.6);
}

.role-btn.active {
  background: #fff;
  color: var(--primary);
  border-color: #fff;
}

/* ========== 主内容区 ========== */
.main-content {
  flex: 1;
  max-width: 1400px;
  margin: 0 auto;
  padding: 24px;
  width: 100%;
}

.role-view {
  display: none;
}

.role-view.active {
  display: block;
}

.page-title-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.page-title-bar h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.title-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.new-project-panel .panel-header,
.assign-panel .panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.project-form {
  padding: 20px;
}

.form-actions {
  margin-top: 16px;
}

.upload-area {
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 12px;
  background: #fafafa;
}

.upload-area input[type="file"] {
  display: block;
  width: 100%;
  font-size: 13px;
  margin-bottom: 8px;
}

.upload-hint {
  display: block;
  font-size: 12px;
  color: var(--text-secondary);
}

.discriminator-checkbox-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
}

.discriminator-checkbox-group label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: normal;
  cursor: pointer;
  font-size: 13px;
}

.discriminator-checkbox-group input[type="checkbox"] {
  margin: 0;
}

.assign-panel .assign-hint {
  padding: 12px 20px;
  margin: 0;
  background: #e8f4fc;
  color: var(--primary-dark);
  font-size: 13px;
  border-bottom: 1px solid #eee;
}

.assign-content {
  padding: 16px 20px;
}

.assign-segment-hint {
  margin-top: 12px;
  font-size: 12px;
  color: var(--text-secondary);
}

.assign-panel .header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.assign-project-name {
  font-size: 13px;
  color: var(--primary);
  font-weight: 500;
}

.panel-desc {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: normal;
}

.user-badge {
  padding: 6px 12px;
  background: var(--primary);
  color: #fff;
  border-radius: 20px;
  font-size: 12px;
}

/* ========== 卡片面板 ========== */
.panel {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  margin-bottom: 20px;
  overflow: hidden;
  transition: box-shadow 0.2s;
}

.panel:hover {
  box-shadow: var(--shadow-hover);
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid #eee;
  background: #fafafa;
}

.panel-header h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
}

.search-input {
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  min-width: 180px;
}

.search-input:focus {
  outline: none;
  border-color: var(--primary);
}

.filter-select {
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  background: #fff;
}

/* ========== 按钮 ========== */
.btn {
  padding: 8px 16px;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: background 0.2s, color 0.2s;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-dark);
}

.btn-secondary {
  background: #e0e0e0;
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: #d0d0d0;
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--primary);
}

.btn-outline:hover {
  background: rgba(26, 95, 180, 0.08);
}

.btn-group {
  display: flex;
  gap: 8px;
}

.btn-sm {
  padding: 4px 10px;
  font-size: 12px;
}

/* ========== 判别员：当前任务池表格（置顶） ========== */
.task-pool-table-panel {
  margin-bottom: 20px;
}

.task-pool-table-panel .table-wrap {
  max-height: 220px;
  overflow-y: auto;
}

/* ========== 判别员：视频区当前项目 ========== */
.video-current-project-header {
  flex-wrap: wrap;
  gap: 8px;
}

.video-header-right {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.current-project-label {
  font-size: 12px;
  color: var(--text-secondary);
}

.current-project-name {
  font-weight: 600;
  color: var(--primary);
  margin-right: 8px;
}

/* ========== 判别员：项目树 ========== */
.project-tree-panel {
  max-height: calc(100vh - 200px);
  display: flex;
  flex-direction: column;
}

.project-tree-wrap {
  padding: 8px 12px;
  overflow-y: auto;
  flex: 1;
}

.project-tree-node {
  margin: 0;
  padding: 0;
  list-style: none;
}

.project-tree-item {
  margin: 0;
  padding: 4px 0;
}

.project-tree-item .tree-node-label {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 13px;
  user-select: none;
}

.project-tree-item .tree-node-label:hover {
  background: #f0f0f0;
}

.project-tree-item .tree-node-label.expanded {
  background: #e8f0fe;
}

.tree-expand-icon {
  width: 18px;
  text-align: center;
  font-size: 12px;
  color: var(--text-secondary);
  transition: transform 0.2s;
}

.tree-expand-icon.expanded {
  transform: rotate(90deg);
}

.tree-expand-icon.no-children {
  visibility: hidden;
}

.tree-children {
  margin-left: 20px;
  border-left: 1px solid #eee;
  padding-left: 8px;
}

.tree-node-name {
  flex: 1;
}

/* ========== 判别员布局 ========== */
.discriminator-layout {
  display: grid;
  grid-template-columns: 280px 1fr 260px;
  gap: 20px;
  align-items: start;
}

@media (max-width: 1200px) {
  .discriminator-layout {
    grid-template-columns: 1fr;
  }
}

.discriminator-left-column {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
}

.center-area {
  min-width: 0;
}

/* ========== 消息列表（项目列表下方） ========== */
.message-list-panel {
  display: flex;
  flex-direction: column;
  max-height: 280px;
}

.message-list-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.message-list-header h3 {
  margin: 0;
}

.message-unread-badge {
  display: inline-block;
  min-width: 20px;
  height: 20px;
  line-height: 20px;
  padding: 0 6px;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  background: #c01c28;
  border-radius: 10px;
  text-align: center;
}

.message-unread-badge:empty,
.message-unread-badge[data-count="0"] {
  display: none;
}

.message-list {
  list-style: none;
  margin: 0;
  padding: 8px;
  overflow-y: auto;
  flex: 1;
}

.message-list li {
  padding: 10px;
  margin-bottom: 6px;
  border-radius: var(--radius);
  font-size: 13px;
  cursor: pointer;
  border-left: 3px solid transparent;
  background: #f8f9fa;
  transition: background 0.2s;
}

.message-list li:hover {
  background: #eee;
}

.message-list li.message-item.unread {
  background: #fff;
  border-left-color: var(--primary);
  font-weight: 500;
}

.message-list li.message-item.read {
  color: var(--text-secondary);
}

.message-item-time {
  font-size: 11px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.task-panel,
.history-panel {
  max-height:  calc(100vh - 220px);
  display: flex;
  flex-direction: column;
}

.task-list,
.history-list {
  list-style: none;
  margin: 0;
  padding: 12px;
  overflow-y: auto;
  flex: 1;
}

.task-list li,
.history-list li {
  padding: 12px;
  border-radius: var(--radius);
  margin-bottom: 8px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.2s, border-color 0.2s;
}

.task-list li:hover,
.history-list li:hover {
  background: #f5f5f5;
}

.task-list li.active,
.history-list li.active {
  background: rgba(26, 95, 180, 0.08);
  border-color: var(--primary);
}

.task-item-title {
  font-weight: 600;
  margin-bottom: 4px;
}

.task-item-meta {
  font-size: 12px;
  color: var(--text-secondary);
}

.task-item-status {
  display: inline-block;
  margin-top: 6px;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
}

.status-pending { background: #fff3e0; color: #e65100; }
.status-in_progress { background: #e3f2fd; color: var(--primary); }
.status-draft { background: #f5f5f5; color: #616161; }
.status-submitted { background: #e8f5e9; color: var(--accent); }

/* ========== 视频区 ========== */
.video-panel .panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.video-info {
  font-size: 12px;
  color: var(--text-secondary);
}

.video-container {
  position: relative;
  padding: 16px;
  background: #1a1a1a;
}

.video-container video {
  width: 100%;
  max-height: 360px;
  display: block;
}

.video-container.small video {
  max-height: 220px;
}

.video-placeholder-note {
  margin-top: 8px;
  font-size: 12px;
  color: #888;
  text-align: center;
}

.video-controls-extra {
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border-top: 1px solid #eee;
}

.segment-indicator {
  font-size: 13px;
  color: var(--text-secondary);
}

.video-shortcuts {
  padding: 10px 16px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  border-top: 1px solid #eee;
  background: #f8f9fa;
}

.video-shortcuts .shortcuts-label {
  font-size: 12px;
  color: var(--text-secondary);
  margin-right: 4px;
}

.btn-shortcut {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  font-size: 12px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}

.btn-shortcut:hover {
  background: #e8f0fe;
  border-color: var(--primary);
}

.btn-shortcut .shortcut-icon {
  font-size: 14px;
}

.btn-shortcut kbd {
  display: inline-block;
  padding: 1px 5px;
  font-size: 11px;
  font-family: inherit;
  background: #e0e0e0;
  border-radius: 4px;
  color: var(--text-secondary);
}

/* ========== 缺陷记录列表 ========== */
.defect-panel .panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.defect-panel-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.defect-count {
  font-size: 12px;
  color: var(--text-secondary);
}

.defect-empty-hint {
  padding: 20px;
  margin: 0;
  font-size: 13px;
  color: var(--text-secondary);
  text-align: center;
  border-bottom: 1px solid #eee;
}

.defect-panel .defect-empty-hint:not(.hidden) + .defect-records-list:not(:empty) {
  margin-top: 0;
}

.defect-records-list {
  list-style: none;
  margin: 0;
  padding: 12px;
  max-height: 400px;
  overflow-y: auto;
}

.defect-records-list:empty {
  display: none;
}

.defect-empty-hint.hidden {
  display: none !important;
}

.defect-record-item {
  display: flex;
  gap: 12px;
  padding: 12px;
  margin-bottom: 8px;
  background: #f8f9fa;
  border-radius: var(--radius);
  border: 1px solid #eee;
}

.defect-record-item:last-child {
  margin-bottom: 0;
}

.defect-record-thumb {
  flex-shrink: 0;
  width: 100px;
  height: 64px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid var(--border);
}

.defect-record-body {
  flex: 1;
  min-width: 0;
}

.defect-record-meta {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.defect-record-type {
  font-weight: 600;
  color: var(--text-primary);
  margin-right: 8px;
}

.defect-record-remark {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* ========== 弹窗 ========== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal-overlay[aria-hidden="false"] {
  display: flex;
}

.modal {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  max-width: 640px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #eee;
  background: #fafafa;
}

.modal-header h3 {
  margin: 0;
  font-size: 16px;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  line-height: 1;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 0 4px;
}

.modal-close:hover {
  color: var(--text-primary);
}

.modal-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 20px;
  border-top: 1px solid #eee;
}

.defect-entry-image-section {
  margin-bottom: 16px;
}

.defect-entry-image-hint {
  font-size: 12px;
  color: var(--text-secondary);
  margin: 0 0 8px 0;
}

.defect-entry-canvas-wrap {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: #1a1a1a;
  display: inline-block;
  max-width: 100%;
}

.defect-entry-canvas-wrap canvas {
  display: block;
  cursor: crosshair;
  max-width: 100%;
  height: auto;
}

.defect-entry-canvas-actions {
  margin-top: 8px;
}

.defect-entry-form .form-row {
  margin-bottom: 12px;
}

.defect-entry-form .form-row:last-of-type {
  margin-bottom: 0;
}

/* ========== 表单通用 ========== */
.defect-form,
.defect-entry-form {
  padding: 0;
}

.defect-entry-form .form-row label,
.form-row label {
  display: block;
  margin-bottom: 6px;
  font-weight: 500;
  color: var(--text-primary);
}

.form-row {
  margin-bottom: 16px;
}

.form-row label {
  display: block;
  margin-bottom: 6px;
  font-weight: 500;
  color: var(--text-primary);
}

.form-row input,
.form-row select,
.form-row textarea {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  font-family: inherit;
}

.form-row textarea {
  resize: vertical;
  min-height: 60px;
}

/* ========== 分页 ========== */
.pagination {
  padding: 12px 16px;
  border-top: 1px solid #eee;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pagination button {
  padding: 6px 12px;
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 4px;
  cursor: pointer;
  font-size: 13px;
}

.pagination button:hover:not(:disabled) {
  background: #f0f0f0;
  border-color: var(--primary);
}

.pagination button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.pagination .page-info {
  font-size: 12px;
  color: var(--text-secondary);
}

.btn-merge-report {
  background: #2e7d32;
  color: #fff;
  border: none;
}

.btn-merge-report:hover {
  background: #1b5e20;
  color: #fff;
}

.data-table .th-checkbox,
.data-table .td-checkbox {
  width: 40px;
  text-align: center;
  vertical-align: middle;
}

.data-table .th-checkbox input,
.data-table .td-checkbox input {
  margin: 0;
  cursor: pointer;
}

/* ========== 审核员 Tab ========== */
.reviewer-tabs {
  margin-top: 0;
}

.reviewer-tab-head {
  display: flex;
  gap: 4px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.reviewer-tab-btn {
  padding: 10px 20px;
  border: none;
  background: none;
  font-size: 14px;
  color: var(--text-secondary);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.2s, border-color 0.2s;
}

.reviewer-tab-btn:hover {
  color: var(--text-primary);
}

.reviewer-tab-btn.active {
  color: var(--primary);
  font-weight: 600;
  border-bottom-color: var(--primary);
}

.reviewer-tab-pane {
  display: none;
}

.reviewer-tab-pane.active {
  display: block;
}

/* ========== 我管理的项目：左右布局 ========== */
.managed-project-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 20px;
  align-items: start;
}

@media (max-width: 900px) {
  .managed-project-layout {
    grid-template-columns: 1fr;
  }
}

.managed-tree-panel {
  max-height: calc(100vh - 240px);
  display: flex;
  flex-direction: column;
}

.managed-tree-panel .project-tree-wrap {
  flex: 1;
  overflow-y: auto;
}

.managed-detail-panel .panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.managed-selected-name {
  font-size: 13px;
  color: var(--primary);
  font-weight: 500;
}

.managed-empty-hint {
  padding: 24px;
  margin: 0;
  text-align: center;
  color: var(--text-secondary);
  font-size: 13px;
}

.managed-detail-panel .table-wrap:not(:has(tbody tr)) + .managed-empty-hint,
.managed-detail-panel .managed-empty-hint:first-of-type {
  display: block;
}

.managed-empty-hint.hidden {
  display: none !important;
}

/* 当前进度：进度条 */
.progress-cell {
  min-width: 140px;
}

.progress-bar-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.progress-bar-track {
  flex: 1;
  height: 8px;
  background: #e0e0e0;
  border-radius: 4px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 4px;
  transition: width 0.2s;
}

.progress-bar-fill.risk-delay {
  background: var(--accent-danger);
}

.progress-bar-fill.risk-ahead {
  background: var(--accent);
}

.progress-bar-text {
  font-size: 12px;
  color: var(--text-secondary);
  white-space: nowrap;
}

/* 风险预测标签 */
.risk-tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 12px;
}

.risk-delay {
  background: #ffebee;
  color: #c62828;
}

.risk-normal {
  background: #e8f5e9;
  color: #2e7d32;
}

.risk-ahead {
  background: #e3f2fd;
  color: #1565c0;
}

/* 操作按钮组 */
.segment-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.segment-actions .btn-sm {
  padding: 4px 8px;
  font-size: 11px;
}

/* ========== 审核员布局 ========== */
.reviewer-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 20px;
}

.reviewer-layout .full-width {
  grid-column: 1 / -1;
}

.reviewer-layout .panel:not(.full-width) {
  grid-row: span 2;
}

.table-wrap {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.data-table th,
.data-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid #eee;
}

.data-table th {
  background: #fafafa;
  font-weight: 600;
  color: var(--text-primary);
}

.data-table tbody tr:hover {
  background: #f9f9f9;
}

.data-table tbody tr.active {
  background: rgba(26, 95, 180, 0.08);
}

.report-status-list {
  list-style: none;
  margin: 0;
  padding: 12px 16px;
}

.report-status-list li {
  padding: 10px 0;
  border-bottom: 1px solid #eee;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.report-status-list li:last-child {
  border-bottom: none;
}

.report-status-list .status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.report-status-list .status-dot.pending {
  background: var(--accent-warn);
}

.report-status-list .status-dot.done {
  background: var(--accent);
}

.hint {
  padding: 8px 16px;
  font-size: 12px;
  color: var(--text-secondary);
  margin: 0;
}

/* ========== 图表 ========== */
.chart-panel .panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.charts-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  padding: 20px;
}

.chart-box {
  position: relative;
  height: 260px;
  padding: 10px;
}

.chart-box.large {
  height: 320px;
}

.chart-label {
  text-align: center;
  font-size: 12px;
  color: var(--text-secondary);
  margin: 8px 0 0 0;
}

/* ========== 领导驾驶舱 ========== */
.dashboard-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}

@media (max-width: 900px) {
  .dashboard-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

.stat-card {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: #fff;
  padding: 24px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.stat-card:nth-child(2) {
  background: linear-gradient(135deg, #0d7a4a 0%, var(--accent) 100%);
}

.stat-card:nth-child(3) {
  background: linear-gradient(135deg, #a53a00 0%, #e5a50a 100%);
}

.stat-card:nth-child(4) {
  background: linear-gradient(135deg, #5e35b1 0%, #7e57c2 100%);
}

.stat-value {
  display: block;
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 13px;
  opacity: 0.9;
}

.leader-layout {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 20px;
}

.leader-layout .full-width {
  grid-column: 1 / -1;
}

.leader-efficiency-row {
  grid-column: 1 / -1;
  display: flex;
  gap: 20px;
  align-items: stretch;
}

.leader-efficiency-table-panel {
  flex: 1;
  min-width: 0;
}

.leader-discriminator-status-panel {
  flex: 0 0 280px;
}

.leader-discriminator-status-panel .chart-box {
  height: 220px;
}

.value-section {
  margin-top: 32px;
  padding: 24px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.value-section h3 {
  margin: 0 0 16px 0;
  font-size: 16px;
  color: var(--text-primary);
}

.value-list {
  margin: 0;
  padding-left: 20px;
  color: var(--text-secondary);
  line-height: 1.8;
}

.value-list li {
  margin-bottom: 8px;
}

/* ========== 页脚 ========== */
.site-footer {
  padding: 16px 24px;
  text-align: center;
  font-size: 12px;
  color: var(--text-secondary);
  background: #e8e8e8;
  margin-top: auto;
}
