/* ===== 基础重置 ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
*:focus { outline: none; }

:root {
  --primary: #0c6dd3;
  --primary-light: #e3f2fd;
  --primary-dark: #0a4fa3;
  --accent: #00bcd4;
  --accent-light: #e0f7fa;
  --success: #10b981;
  --success-light: #ecfdf5;
  --warning: #f59e0b;
  --warning-light: #fffbeb;
  --danger: #ef4444;
  --danger-light: #fef2f2;
  --info: #3b82f6;
  --info-light: #eff6ff;
  --gray: #64748b;
  --gray-light: #f1f5f9;
  --gray-border: #e2e8f0;
  --text: #1e293b;
  --text-light: #64748b;
  --bg: #f8fafc;
  --white: #ffffff;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,0.05), 0 1px 2px rgba(0,0,0,0.03);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -1px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 30px rgba(0,0,0,0.08), 0 4px 12px rgba(0,0,0,0.05);
  --shadow-xl: 0 20px 50px rgba(0,0,0,0.12);
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: linear-gradient(180deg, #eef3f9 0%, #e4ecf4 40%, #eaf0f7 100%);
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
}

/* ===== 顶部导航 ===== */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  padding: 0 32px;
  background: linear-gradient(135deg, #062a5c 0%, #0c6dd3 100%);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(6, 42, 92, 0.2);
}
.topbar-left { display: flex; align-items: center; gap: 12px; }
.logo-img { width: 34px; height: 34px; object-fit: contain; filter: drop-shadow(0 2px 4px rgba(0, 188, 212, 0.25)); }
.app-title {
  font-size: 19px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 1px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.tabs { display: flex; flex-direction: column; gap: 3px; padding: 0 12px; }
.tab-icon {
  width: 26px;
  height: 26px;
  font-size: 14px;
  text-align: center;
  line-height: 26px;
  flex-shrink: 0;
  background: rgba(12, 109, 211, 0.08);
  border-radius: 7px;
  transition: var(--transition);
}
.tab:hover .tab-icon { background: rgba(12, 109, 211, 0.18); }
.tab.active .tab-icon { background: rgba(255,255,255,0.22); }
.tab {
  padding: 9px 12px;
  border: none;
  background: transparent;
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-radius: 8px;
  transition: var(--transition);
  position: relative;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 0.3px;
}
.tab::before {
  content: "";
  position: absolute;
  left: -12px;
  top: 50%;
  transform: translateY(-50%) scaleY(0);
  width: 3px;
  height: 60%;
  background: var(--accent);
  border-radius: 0 3px 3px 0;
  transition: transform 0.2s ease;
}
.tab.active::before { transform: translateY(-50%) scaleY(1); }
.tab:hover { background: rgba(12, 109, 211, 0.07); color: var(--primary); }
.tab.active {
  background: linear-gradient(135deg, rgba(12, 109, 211, 0.12), rgba(6, 42, 92, 0.08));
  color: var(--primary);
  font-weight: 600;
  box-shadow: inset 0 0 0 1px rgba(12, 109, 211, 0.12);
}
.tab.active:hover { background: linear-gradient(135deg, rgba(12, 109, 211, 0.16), rgba(6, 42, 92, 0.12)); color: var(--primary); }
.tab.active::after { display: none; }

/* ===== 左侧导航栏 ===== */
.sidebar {
  position: fixed;
  top: 64px;
  left: 0;
  width: 216px;
  bottom: 0;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border-right: 1px solid rgba(12, 109, 211, 0.1);
  box-shadow: 2px 0 12px rgba(6, 42, 92, 0.04);
  overflow-y: auto;
  padding: 16px 0;
  z-index: 50;
}
.sidebar .section-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 12px 24px 6px;
}

/* ===== 主内容区 ===== */
.main-content {
  margin-left: 216px;
  padding: 32px 28px 48px;
  min-height: calc(100vh - 64px);
}
.view { display: none; animation: fadeIn 0.3s ease; }
.view.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* 仪表盘科技感网格底纹 */
#view-dashboard {
  position: relative;
}
#view-dashboard::before {
  content: "";
  position: absolute;
  top: -20px; left: -20px; right: -20px; bottom: -20px;
  background-image: 
    linear-gradient(rgba(12, 109, 211, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(12, 109, 211, 0.04) 1px, transparent 1px);
  background-size: 24px 24px;
  pointer-events: none;
  z-index: -1;
  border-radius: 16px;
}
#view-dashboard::after {
  content: "";
  position: absolute;
  top: -60px; right: -60px;
  width: 300px; height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 188, 212, 0.06) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1;
}

/* ===== 统计卡片 ===== */
.stats-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(165px, 1fr));
  gap: 18px;
  margin-bottom: 32px;
}
.stat-card {
  background: linear-gradient(135deg, #ffffff 0%, #f6f9fc 100%);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: 0 4px 20px rgba(12, 109, 211, 0.08), 0 1px 3px rgba(0,0,0,0.04);
  border: 1px solid rgba(12, 109, 211, 0.08);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}
.stat-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  opacity: 1;
}
.stat-card::after {
  content: "";
  position: absolute;
  top: -20px;
  right: -20px;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 188, 212, 0.08) 0%, transparent 70%);
  pointer-events: none;
}
.stat-card:hover { box-shadow: 0 8px 30px rgba(12, 109, 211, 0.15), 0 2px 8px rgba(0,0,0,0.06); transform: translateY(-4px); }
.stat-card-clickable { cursor: pointer; }
.stat-card-clickable:hover { border-color: rgba(12, 109, 211, 0.3); }
.stat-card .stat-icon { font-size: 28px; margin-bottom: 10px; display: block; filter: drop-shadow(0 2px 4px rgba(12, 109, 211, 0.2)); }
.stat-card .stat-value { font-size: 30px; font-weight: 800; line-height: 1.1; }
.stat-card .stat-label { font-size: 13px; color: var(--text-light); margin-top: 6px; font-weight: 500; }

/* ===== 图表区域 ===== */
.dashboard-charts {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 22px;
  margin-bottom: 32px;
}
.chart-card {
  background: linear-gradient(135deg, #ffffff 0%, #f8fbfd 100%);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: 0 4px 20px rgba(12, 109, 211, 0.06), 0 1px 3px rgba(0,0,0,0.04);
  border: 1px solid rgba(12, 109, 211, 0.08);
  position: relative;
  overflow: hidden;
}
.chart-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: linear-gradient(180deg, var(--primary), var(--accent));
  opacity: 0.6;
}
.chart-title { font-size: 16px; font-weight: 700; margin-bottom: 18px; color: var(--text); display: flex; align-items: center; gap: 8px; }
.chart-title::before {
  content: "";
  width: 4px;
  height: 16px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--primary), var(--accent));
}
.chart-card canvas { max-height: 280px; }

/* ===== 最近更新 ===== */
.dashboard-recent {
  background: linear-gradient(135deg, #ffffff 0%, #f8fbfd 100%);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: 0 4px 20px rgba(12, 109, 211, 0.06), 0 1px 3px rgba(0,0,0,0.04);
  border: 1px solid rgba(12, 109, 211, 0.08);
  position: relative;
  overflow: hidden;
}
.dashboard-recent::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: linear-gradient(180deg, var(--accent), var(--primary));
  opacity: 0.6;
}
.section-title { font-size: 16px; font-weight: 700; margin-bottom: 18px; color: var(--text); display: flex; align-items: center; gap: 8px; }
.section-title::before {
  content: "";
  width: 4px;
  height: 16px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--primary), var(--accent));
}
.recent-list { display: flex; flex-direction: column; gap: 10px; }
.recent-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  background: var(--gray-light);
  border-radius: var(--radius-sm);
  transition: var(--transition);
  border: 1px solid transparent;
}
.recent-item:hover { background: var(--primary-light); border-color: var(--primary); transform: translateX(4px); }
.recent-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.recent-info { flex: 1; min-width: 0; }
.recent-name { font-weight: 600; font-size: 13px; }
.recent-task { font-size: 13px; color: var(--text-light); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recent-date { font-size: 12px; color: var(--text-light); flex-shrink: 0; }

/* ===== 工具栏 ===== */
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
  flex-wrap: wrap;
  gap: 14px;
}
.page-title { font-size: 20px; font-weight: 700; color: var(--text); }
.filters { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.filter-select, .filter-date {
  padding: 8px 14px;
  border: 1px solid var(--gray-border);
  border-radius: var(--radius-sm);
  font-size: 13px;
  background: var(--white);
  color: var(--text);
  cursor: pointer;
  transition: var(--transition);
  font-weight: 500;
}
.filter-select:hover, .filter-date:hover { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light); }
.filter-sep { color: var(--text-light); font-size: 13px; }

/* ===== 按钮 ===== */
.btn {
  padding: 9px 20px;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  letter-spacing: 0.3px;
}
.btn-primary { background: var(--primary); color: white; box-shadow: 0 2px 4px rgba(79, 70, 229, 0.25); }
.btn-primary:hover { background: var(--primary-dark); box-shadow: 0 4px 12px rgba(79, 70, 229, 0.35); transform: translateY(-1px); }
.btn-secondary { background: var(--gray-light); color: var(--text); border: 1px solid var(--gray-border); }
.btn-secondary:hover { background: var(--gray-border); }
.btn-danger { background: var(--danger); color: white; box-shadow: 0 2px 4px rgba(239, 68, 68, 0.25); }
.btn-danger:hover { background: #dc2626; box-shadow: 0 4px 12px rgba(239, 68, 68, 0.35); }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.btn-icon {
  padding: 6px 10px;
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 16px;
  border-radius: 6px;
  transition: var(--transition);
}
.btn-icon:hover { background: var(--gray-light); }
.btn-icon.edit:hover { color: var(--primary); }
.btn-icon.delete:hover { color: var(--danger); }

/* ===== 数据表格 ===== */
.table-wrapper {
  background: linear-gradient(135deg, #ffffff 0%, #fafbfd 100%);
  border-radius: var(--radius);
  box-shadow: 0 4px 20px rgba(12, 109, 211, 0.06), 0 1px 3px rgba(0,0,0,0.04);
  border: 1px solid rgba(12, 109, 211, 0.08);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.data-table { min-width: 100%; border-collapse: collapse; }

/* 进度记录表：固定列宽 + 自适应窗口（避免列太多导致横向滚动） */
#recordsTable {
  table-layout: fixed !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  display: table !important;
}
/* 进度记录表专用：包裹层取消滚动条，让表格撑满容器 */
.view-records .table-wrapper {
  overflow-x: visible !important;
  width: 100% !important;
  box-sizing: border-box;
  padding: 0 !important;
}
#recordsTable th, #recordsTable td {
  padding: 12px 8px;
  font-size: 12px;
  word-break: break-word;
  overflow-wrap: anywhere;
  box-sizing: border-box;
}
#recordsTable th.col-wrap, #recordsTable td.col-wrap {
  white-space: normal;
  word-break: break-word;
  line-height: 1.45;
}
#recordsTable th:not(.col-wrap), #recordsTable td:not(.col-wrap) {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.data-table thead { background: linear-gradient(180deg, var(--gray-light), #f8fafc); }
.data-table th {
  padding: 14px 18px;
  text-align: left;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-light);
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 2px solid var(--gray-border);
}
.data-table td {
  padding: 14px 18px;
  font-size: 13px;
  border-top: 1px solid var(--gray-border);
  vertical-align: middle;
}
.data-table tbody tr { transition: var(--transition); }
.data-table tbody tr:nth-child(even) { background: rgba(12, 109, 211, 0.03); }
.data-table tbody tr:hover { background: var(--primary-light); }

/* 任务列表表格：自适应窗口 */
.task-list-table {
  table-layout: fixed;
  width: 100%;
  min-width: 0;
}
.task-list-table th, .task-list-table td {
  padding: 12px 10px;
  box-sizing: border-box;
}
.task-list-table th:not(:first-child):not(:last-child),
.task-list-table td:not(:first-child):not(:last-child) {
  white-space: normal;
  word-break: break-word;
  line-height: 1.45;
}
.task-list-table th:first-child, .task-list-table td:first-child { width: 50px; text-align: center; }
.task-list-table th:nth-child(6), .task-list-table td:nth-child(6) { width: 160px; }
.task-list-table th:last-child, .task-list-table td:last-child { width: 90px; text-align: center; }

/* 操作列固定在右侧 */
.data-table th:last-child,
.data-table td:last-child {
  position: sticky;
  right: 0;
  z-index: 2;
  white-space: nowrap;
  min-width: 52px;
}
.action-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 2px 0;
}
.data-table th:last-child {
  background: linear-gradient(180deg, var(--gray-light), #e8eef6);
  box-shadow: -2px 0 4px rgba(0,0,0,0.06);
}
.data-table td:last-child {
  background: #ffffff;
  box-shadow: -2px 0 4px rgba(0,0,0,0.06);
}
.data-table tbody tr:nth-child(even) td:last-child { background: #f8fafc; }
.data-table tbody tr:hover td:last-child { background: var(--primary-light); }
.member-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
}
.member-dot { width: 8px; height: 8px; border-radius: 50%; }

/* 状态标签 */
.status-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.status-未开始 { background: var(--gray-light); color: var(--gray); }
.status-进行中 { background: var(--info-light); color: var(--info); }
.status-已完成 { background: var(--success-light); color: var(--success); }
.status-阻塞 { background: var(--danger-light); color: var(--danger); }

/* 进度条 */
.progress-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 120px;
}
.progress-track {
  flex: 1;
  height: 6px;
  background: var(--gray-light);
  border-radius: 3px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.3s ease;
}
.progress-text { font-size: 12px; font-weight: 600; min-width: 32px; color: var(--text-light); }

/* ===== 成员卡片 ===== */
.member-grid {
  display: block;
}
.member-grid-inner {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 18px;
}
.member-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-border);
  text-align: center;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}
.member-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(135deg, var(--primary-light), var(--info-light));
  z-index: 0;
}
.member-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-4px); }
.member-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 700;
  color: white;
  margin: 0 auto 14px;
  position: relative;
  z-index: 1;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  border: 3px solid white;
}
.member-name { font-size: 17px; font-weight: 700; position: relative; z-index: 1; }
.member-role { font-size: 13px; color: var(--text-light); margin-top: 3px; position: relative; z-index: 1; }
.member-stats {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--gray-border);
  position: relative;
  z-index: 1;
}
.member-stat { text-align: center; }
.member-stat .num { font-size: 20px; font-weight: 800; }
.member-stat .label { font-size: 11px; color: var(--text-light); }
.member-actions {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  gap: 4px;
  opacity: 0;
  transition: var(--transition);
  z-index: 2;
}
.member-card:hover .member-actions { opacity: 1; }

/* ===== 空状态 ===== */
.empty-state {
  text-align: center;
  padding: 72px 20px;
  color: var(--text-light);
}
.empty-icon { font-size: 56px; display: block; margin-bottom: 16px; opacity: 0.6; }

/* ===== 导出卡片 ===== */
.export-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 22px;
}
.export-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 36px 28px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-border);
  text-align: center;
  transition: var(--transition);
}
.export-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-4px); }
.export-icon { font-size: 44px; display: block; margin-bottom: 14px; }
.export-card h3 { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.export-card p { font-size: 13px; color: var(--text-light); margin-bottom: 18px; line-height: 1.6; }

/* ===== 右侧用户区 ===== */
.topbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ===== 表格任务提示 ===== */
.sheet-tip {
  background: var(--info-light);
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-sm);
  padding: 12px 18px;
  margin-bottom: 22px;
  font-size: 13px;
  color: var(--info);
  display: flex;
  align-items: center;
}
.sheet-upload-area { display: flex; align-items: center; gap: 10px; }

.sheet-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 18px;
}
.sheet-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-border);
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}
.sheet-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--info);
}
.sheet-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-4px); border-color: var(--primary); }
.sheet-card-icon { font-size: 30px; margin-bottom: 12px; }
.sheet-card-name { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.sheet-card-file { font-size: 12px; color: var(--text-light); margin-bottom: 14px; }
.sheet-card-progress {
  display: flex;
  align-items: center;
  gap: 10px;
}
.sheet-card-progress .progress-track { flex: 1; }
.sheet-card-stats {
  display: flex;
  justify-content: space-between;
  margin-top: 12px;
  font-size: 12px;
  color: var(--text-light);
}

/* 表格详情页 */
.sheet-detail-info { flex: 1; text-align: center; }
.sheet-detail-name { font-size: 18px; font-weight: 700; }
.sheet-detail-progress { font-size: 14px; color: var(--text-light); margin-left: 12px; }

.sheet-progress-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  padding: 14px 18px;
  background: var(--white);
  border-radius: var(--radius-sm);
  border: 1px solid var(--gray-border);
  box-shadow: var(--shadow);
}
.sheet-progress-bar .progress-track { flex: 1; height: 8px; }
.sheet-progress-bar .progress-text { font-weight: 700; font-size: 14px; }

/* 表格行样式 */
.sheet-table th:first-child, .sheet-table td:first-child {
  width: 50px;
  text-align: center;
}
.sheet-row-checkbox {
  width: 20px;
  height: 20px;
  cursor: pointer;
  accent-color: var(--success);
}
.sheet-table tr.row-completed { background: var(--success-light); }
.sheet-table tr.row-completed td { color: var(--text-light); }
.sheet-table tr.row-completed .row-text { text-decoration: line-through; }
.sheet-table tbody tr { cursor: context-menu; transition: background 0.1s; }
.sheet-table tbody tr:hover { background: var(--gray-light); }
.row-completed-by {
  font-size: 11px;
  color: var(--success);
  margin-left: 6px;
  font-weight: 600;
  white-space: nowrap;
}
.sheet-table td .cell-content { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.sheet-table th:last-child, .sheet-table td:last-child {
  width: 100px;
  text-align: center;
  white-space: nowrap;
}

/* 来源表格标签 */
.source-badge {
  display: inline-block;
  font-size: 11px;
  color: var(--info);
  background: var(--info-light);
  padding: 2px 8px;
  border-radius: 10px;
  margin-top: 4px;
  font-weight: 500;
}

/* ===== 采购信息标签 ===== */
.info-tag {
  display: inline-block;
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 4px;
  background: var(--gray-light);
  color: var(--gray);
}
.info-tag-amount {
  background: var(--warning-light);
  color: #92400e;
  font-weight: 500;
}

/* ===== 批量创建 ===== */
.batch-count-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  font-size: 11px;
  font-weight: 600;
  background: #fff;
  color: var(--primary);
  border-radius: 9px;
  padding: 0 5px;
  margin-left: 4px;
}
.row-select-checkbox { cursor: pointer; }
.batch-hint {
  background: var(--info-light);
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  font-size: 13px;
  color: var(--info);
}

/* ===== 批量创建：列映射 ===== */
.batch-mapping-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 10px;
}
@media (max-width: 640px) {
  .batch-mapping-grid { grid-template-columns: 1fr 1fr; }
}
.batch-mapping-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  background: var(--bg);
  border: 1px solid var(--gray-border);
  border-radius: var(--radius-sm);
}
.batch-mapping-icon {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}
.batch-mapping-field {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.batch-mapping-label { font-size: 12px; font-weight: 600; color: var(--text); }
.batch-mapping-select {
  padding: 4px 8px !important;
  font-size: 13px !important;
  height: 32px;
}

/* ===== 批量预览表 ===== */
.batch-preview-wrapper {
  max-height: 360px;
  overflow: auto;
  border: 1px solid var(--gray-border);
  border-radius: var(--radius-sm);
  cursor: grab;
  user-select: none;
}
.batch-preview-wrapper.dragging { cursor: grabbing; }
.batch-preview-table { font-size: 13px; min-width: 100%; }
.batch-preview-table th {
  position: sticky;
  top: 0;
  background: var(--gray-light);
  z-index: 1;
  white-space: nowrap;
  min-width: 80px;
}
.batch-preview-table td { padding: 8px 10px; white-space: nowrap; min-width: 80px; }

/* 高亮映射列 */
.col-mapped { font-weight: 600; }
.col-mapped-task { background: #f5f3ff !important; color: #6d28d9; }
.col-mapped-project { background: var(--info-light) !important; color: #1d4ed8; }
.col-mapped-package { background: var(--warning-light) !important; color: #b45309; }
.col-mapped-amount { background: var(--success-light) !important; color: #047857; }
th.col-mapped-task { background: #ede9fe !important; }
th.col-mapped-project { background: #dbeafe !important; }
th.col-mapped-package { background: var(--warning-light) !important; }
th.col-mapped-amount { background: #d1fae5 !important; }

/* ===== 批量创建：每行映射表格 ===== */
.batch-mapping-table { font-size: 12px; min-width: 100%; }
.batch-mapping-table th {
  position: sticky;
  top: 0;
  background: var(--gray-light);
  z-index: 1;
  white-space: nowrap;
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 600;
}
.batch-mapping-table td { padding: 6px 8px; vertical-align: middle; }
.batch-mapping-table tbody tr:nth-child(even) { background: rgba(12, 109, 211, 0.03); }
.batch-row-select {
  padding: 4px 8px !important;
  font-size: 12px !important;
  height: 30px;
  width: 100%;
  min-width: 120px;
  max-width: 200px;
}

/* ===== 右键菜单 ===== */
.context-menu {
  position: fixed;
  z-index: 9999;
  min-width: 180px;
  background: #fff;
  border: 1px solid var(--gray-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-xl);
  padding: 8px 0;
  animation: ctxFadeIn 0.12s ease;
}
@keyframes ctxFadeIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }
.context-menu-item {
  padding: 10px 18px;
  font-size: 14px;
  color: var(--text);
  cursor: pointer;
  transition: background 0.1s;
  display: flex;
  align-items: center;
  gap: 8px;
}
.context-menu-item:hover { background: var(--primary-light); color: var(--primary); }

/* ===== 制作人标签 & 详情弹窗 ===== */
.maker-tag {
  display: inline-block;
  padding: 3px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  background: var(--primary-light);
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}
.maker-tag:hover { background: var(--primary); color: #fff; }
.creator-popup {
  position: fixed;
  z-index: 10000;
  width: 280px;
  background: #fff;
  border: 1px solid var(--gray-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-xl);
  animation: ctxFadeIn 0.15s ease;
  overflow: hidden;
}
.creator-popup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  font-size: 13px;
  font-weight: 600;
  color: #fff;
}
.creator-popup-close { cursor: pointer; font-size: 18px; line-height: 1; color: rgba(255,255,255,0.7); transition: color 0.15s; }
.creator-popup-close:hover { color: #fff; }
.creator-popup-body { padding: 12px 16px; }
.creator-popup-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--gray-light);
  font-size: 13px;
}
.creator-popup-row:last-child { border-bottom: none; }
.creator-popup-label { color: var(--text-light); flex-shrink: 0; }
.creator-popup-value { color: var(--text); font-weight: 500; text-align: right; max-width: 170px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===== 三段式进度条（表格内） ===== */
.bid-unit-tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.bid-unit-长福影视 { background: #dbeafe; color: #1e40af; }
.bid-unit-南京知光 { background: #fef3c7; color: #92400e; }
.bid-unit-一元科技 { background: #d1fae5; color: #065f46; }
.triple-progress {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 100px;
}
.triple-progress-bar {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.triple-seg-btn {
  position: relative;
  width: 100%;
  height: 16px;
  overflow: hidden;
  border: none;
  cursor: pointer;
  padding: 0 6px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  transition: filter 0.15s;
  border-radius: 3px;
}
.triple-seg-btn:hover { filter: brightness(0.92); }
.triple-seg-btn:active { filter: brightness(0.85); }
.seg-business { background: #93c5fd; }
.seg-quote { background: var(--warning-light); }
.seg-tech { background: #d1fae5; }
.seg-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  transition: width 0.3s ease;
}
.seg-business .seg-fill { background: #2563eb; }
.seg-quote .seg-fill { background: #f59e0b; }
.seg-tech .seg-fill { background: #10b981; }
.seg-text {
  position: relative;
  z-index: 1;
  font-size: 10px;
  font-weight: 700;
  color: #1e293b;
  white-space: nowrap;
}
.triple-progress-text {
  font-size: 13px;
  white-space: nowrap;
  min-width: 36px;
  text-align: right;
  font-weight: 700;
}

/* ===== 三段式进度控件（弹窗内） ===== */
.progress-triple {
  background: var(--gray-light);
  border-radius: var(--radius);
  padding: 16px;
  border: 1px solid var(--gray-border);
}
.progress-triple-item { margin-bottom: 14px; }
.progress-triple-item:last-of-type { margin-bottom: 0; }
.progress-triple-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 13px;
}
.progress-triple-label { font-weight: 600; color: var(--text); }
.progress-triple-weight {
  font-size: 11px;
  color: var(--text-light);
  background: #fff;
  padding: 2px 8px;
  border-radius: 8px;
  border: 1px solid var(--gray-border);
}
.progress-triple-value { margin-left: auto; font-weight: 700; font-size: 14px; }
.progress-triple-item:nth-child(1) .progress-triple-value { color: #2563eb; }
.progress-triple-item:nth-child(2) .progress-triple-value { color: #f59e0b; }
.progress-triple-item:nth-child(3) .progress-triple-value { color: #10b981; }
.progress-triple-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 2px solid var(--gray-border);
  font-size: 14px;
  font-weight: 600;
}
.progress-triple-total-value { font-size: 20px; color: var(--primary); font-weight: 800; }

/* ===== 自动状态显示（弹窗内） ===== */
.auto-status-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: var(--gray-light);
  border-radius: var(--radius-sm);
  border: 1px solid var(--gray-border);
}
.auto-status-wrapper .status-badge { font-size: 14px; padding: 4px 14px; }
.block-toggle {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  color: var(--text-light);
  cursor: pointer;
  user-select: none;
}
.block-toggle input { cursor: pointer; }

/* ===== 弹窗 ===== */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(4px);
  z-index: 200;
  align-items: center;
  justify-content: center;
}
.modal-overlay.active { display: flex; }
.modal {
  background: var(--white);
  border-radius: 16px;
  width: 540px;
  max-width: 90vw;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-xl);
  animation: modalIn 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
.modal-sm { width: 420px; }
@keyframes modalIn { from { transform: scale(0.95) translateY(10px); opacity: 0; } to { transform: scale(1) translateY(0); opacity: 1; } }
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 26px;
  border-bottom: 1px solid var(--gray-border);
  background: linear-gradient(180deg, var(--white), var(--bg));
  border-radius: 16px 16px 0 0;
}
.modal-header h3 { font-size: 17px; font-weight: 700; }
.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--text-light);
  line-height: 1;
  padding: 0;
  transition: var(--transition);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
}
.modal-close:hover { color: var(--text); background: var(--gray-light); }
.modal-body { padding: 26px; }
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 18px 26px;
  border-top: 1px solid var(--gray-border);
  background: var(--bg);
  border-radius: 0 0 16px 16px;
}

/* ===== 表单 ===== */
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text);
}
.required { color: var(--danger); }
.form-input {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--gray-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  transition: var(--transition);
  background: var(--white);
  color: var(--text);
}
.form-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light); }
textarea.form-input { resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-range {
  width: 100%;
  height: 6px;
  -webkit-appearance: none;
  appearance: none;
  background: var(--gray-light);
  border-radius: 3px;
  outline: none;
}
.form-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--primary);
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

/* ===== 颜色选择器 ===== */
.color-picker { display: flex; gap: 8px; flex-wrap: wrap; }
.color-option {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  border: 3px solid transparent;
  transition: var(--transition);
}
.color-option:hover { transform: scale(1.1); }
.color-option.selected { border-color: var(--text); transform: scale(1.1); }

/* ===== 确认弹窗 ===== */
.confirm-icon { font-size: 44px; }

/* ===== Toast ===== */
.toast {
  position: fixed;
  top: 88px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  background: var(--text);
  color: white;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  z-index: 300;
  opacity: 0;
  pointer-events: none;
  transition: var(--transition);
  box-shadow: var(--shadow-lg);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.success { background: var(--success); }
.toast.error { background: var(--danger); }

/* ===== 登录页面 ===== */
.login-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  display: flex;
  z-index: 9999;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}
.login-overlay.hidden { display: none; }

/* 左侧品牌展示区域（占 2/3） */
.login-brand-panel {
  flex: 2;
  position: relative;
  background: linear-gradient(135deg, #062a5c 0%, #0c6dd3 50%, #00a8c6 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.login-brand-panel::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(255,255,255,0.12) 0%, transparent 35%),
    radial-gradient(circle at 80% 70%, rgba(0,188,212,0.25) 0%, transparent 40%),
    radial-gradient(circle at 50% 50%, rgba(255,255,255,0.05) 0%, transparent 60%);
}
.login-brand-shapes {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  pointer-events: none;
}
.login-brand-shape {
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
}
.login-brand-shape.shape-1 { width: 600px; height: 600px; top: -200px; left: -150px; }
.login-brand-shape.shape-2 { width: 400px; height: 400px; bottom: -100px; right: 10%; }
.login-brand-shape.shape-3 { width: 200px; height: 200px; top: 40%; left: 20%; background: rgba(0,188,212,0.12); }
.login-brand-content {
  position: relative;
  z-index: 1;
  text-align: center;
  color: #fff;
  max-width: 720px;
  padding: 40px;
}
.login-brand-logo {
  width: 200px;
  height: 200px;
  object-fit: contain;
  margin-bottom: 24px;
  filter: drop-shadow(0 8px 24px rgba(0,0,0,0.2));
}
.login-brand-title {
  font-size: 44px;
  font-weight: 800;
  letter-spacing: 1px;
  margin-bottom: 12px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.2);
  line-height: 1.2;
  white-space: nowrap;
}
.login-brand-tagline {
  font-size: 18px;
  font-weight: 400;
  opacity: 0.92;
  margin-bottom: 48px;
  letter-spacing: 2px;
}
.login-brand-features {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: flex-start;
  margin: 0 auto;
  max-width: 280px;
}
.login-brand-feature {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 16px;
  font-weight: 500;
  opacity: 0.95;
}
.login-brand-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #00e5ff;
  box-shadow: 0 0 10px rgba(0,229,255,0.6);
}

/* 右侧登录表单区域（占 1/3） */
.login-form-panel {
  flex: 1;
  min-width: 380px;
  max-width: 460px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  box-shadow: -10px 0 40px rgba(0,0,0,0.1);
  position: relative;
  z-index: 2;
}
.login-card {
  width: 100%;
  max-width: 360px;
  text-align: center;
  animation: modalIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.login-logo-img { width: 72px; height: 72px; object-fit: contain; margin-bottom: 18px; }
.login-title { font-size: 26px; font-weight: 800; color: var(--text); margin-bottom: 6px; letter-spacing: 1px; }
.login-subtitle { font-size: 14px; color: var(--text-light); margin-bottom: 36px; font-weight: 500; }
.login-form { text-align: left; }
.login-field { margin-bottom: 22px; }
.login-field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text);
}
.login-input {
  width: 100%;
  padding: 13px 16px;
  border: 1px solid var(--gray-border);
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-family: inherit;
  transition: var(--transition);
  background: var(--white);
  color: var(--text);
}
.login-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light); }
.login-error {
  background: var(--danger-light);
  color: var(--danger);
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  margin-bottom: 16px;
  border: 1px solid #fecaca;
}
.login-btn {
  width: 100%;
  padding: 14px;
  font-size: 16px;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border: none;
  color: white;
  font-weight: 700;
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  box-shadow: 0 4px 14px rgba(12, 109, 211, 0.35);
}
.login-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(12, 109, 211, 0.45); }
.login-hint {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--gray-border);
  font-size: 12px;
  color: var(--text-light);
}

/* 登录页响应式：小屏幕时改为上下布局 */
@media (max-width: 900px) {
  .login-overlay { flex-direction: column; overflow-y: auto; }
  .login-brand-panel { flex: none; min-height: 260px; padding: 40px 24px; }
  .login-brand-logo { width: 120px; height: 120px; margin-bottom: 16px; }
  .login-brand-title { font-size: 30px; white-space: normal; }
  .login-brand-tagline { font-size: 14px; margin-bottom: 24px; }
  .login-brand-features { display: none; }
  .login-form-panel { flex: none; width: 100%; max-width: none; padding: 32px 24px; box-shadow: none; }
}

/* ===== 通知系统 ===== */
.notification-wrapper { position: relative; margin-right: 8px; }
.notification-bell {
  position: relative;
  cursor: pointer;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(255,255,255,0.1);
  transition: var(--transition);
}
.notification-bell:hover { background: rgba(255,255,255,0.2); }
.notification-icon { font-size: 18px; line-height: 1; display: block; }
.notification-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  background: #ef4444;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  box-shadow: 0 2px 6px rgba(239,68,68,0.4);
  animation: badge-pulse 2s ease-in-out infinite;
}
@keyframes badge-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}
.notification-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 360px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.15);
  border: 1px solid var(--gray-border);
  z-index: 2000;
  overflow: hidden;
}
.notification-dropdown-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--gray-border);
  background: linear-gradient(135deg, #f8faff, #f0f4fa);
}
.notification-dropdown-title {
  font-weight: 700;
  font-size: 15px;
  color: var(--text);
}
.notification-read-all {
  font-size: 12px;
  color: var(--primary);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 10px;
  border-radius: 6px;
  transition: var(--transition);
}
.notification-read-all:hover { background: var(--primary-light); }
.notification-list {
  max-height: 380px;
  overflow-y: auto;
}
.notification-list::-webkit-scrollbar { width: 5px; }
.notification-list::-webkit-scrollbar-thumb { background: #ccc; border-radius: 3px; }
.notification-item {
  display: flex;
  gap: 10px;
  padding: 12px 18px;
  border-bottom: 1px solid #f0f0f0;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}
.notification-item:hover { background: #f8faff; }
.notification-item:last-child { border-bottom: none; }
.notification-item.unread { background: #eff6ff; }
.notification-item.unread::before {
  content: '';
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}
.notification-item-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}
.notification-item-icon.claim { background: #dbeafe; }
.notification-item-icon.complete { background: #d1fae5; }
.notification-item-body { flex: 1; min-width: 0; }
.notification-item-title {
  font-weight: 600;
  font-size: 13px;
  color: var(--text);
  margin-bottom: 2px;
}
.notification-item-message {
  font-size: 13px;
  color: var(--text-light);
  line-height: 1.4;
  word-break: break-all;
}
.notification-item-time {
  font-size: 11px;
  color: #9ca3af;
  margin-top: 4px;
}
.notification-empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--text-light);
  font-size: 14px;
}

/* ===== 用户信息徽章 ===== */
.user-menu-wrapper { position: relative; }
.user-info-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 20px;
  font-size: 13px;
  cursor: pointer;
  transition: var(--transition);
  user-select: none;
  color: rgba(255,255,255,0.9);
}
.user-info-badge:hover { background: rgba(255,255,255,0.18); border-color: rgba(255,255,255,0.25); }
.user-avatar-sm { font-size: 16px; }
.user-display-name { font-weight: 600; color: #fff; }
.user-role-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 600;
}
.user-role-badge.admin { background: var(--danger); color: #fff; }
.user-role-badge.member { background: var(--info); color: #fff; }
.user-dropdown-arrow { font-size: 11px; color: rgba(255,255,255,0.6); margin-left: 2px; transition: transform 0.2s; }
.user-info-badge.open .user-dropdown-arrow { transform: rotate(180deg); }

/* ===== 用户下拉菜单 ===== */
.user-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 260px;
  background: #fff;
  border-radius: 14px;
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--gray-border);
  z-index: 1000;
  overflow: hidden;
  animation: dropdownFadeIn 0.18s ease;
}
@keyframes dropdownFadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}
.user-dropdown-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px;
  background: linear-gradient(135deg, var(--primary-light), var(--info-light));
}
.user-dropdown-avatar {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  background: #fff;
  border-radius: 50%;
  box-shadow: var(--shadow);
}
.user-dropdown-info { flex: 1; }
.user-dropdown-name { font-weight: 700; font-size: 15px; color: var(--text); }
.user-dropdown-role { font-size: 12px; color: var(--text-light); margin-top: 2px; }
.user-dropdown-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
}
.user-dropdown-label { font-size: 13px; color: var(--text-light); }
.user-dropdown-value { font-size: 13px; color: var(--text); font-weight: 500; }
.user-dropdown-divider { height: 1px; background: var(--gray-border); margin: 0 18px; }
.user-dropdown-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 12px 18px;
  border: none;
  background: transparent;
  font-size: 14px;
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s;
  font-weight: 500;
}
.user-dropdown-item:hover { background: var(--primary-light); color: var(--primary); }
.user-dropdown-logout { color: var(--danger); }
.user-dropdown-logout:hover { background: var(--danger-light); }

/* ===== 表单错误提示 ===== */
.form-error {
  color: var(--danger);
  font-size: 13px;
  padding: 10px 14px;
  background: var(--danger-light);
  border: 1px solid #fecaca;
  border-radius: var(--radius-sm);
  margin-top: 8px;
}

/* ===== 应用隐藏（未登录时） ===== */
.app-hidden { display: none !important; }

/* ===== 权限控制：非管理员隐藏 ===== */
body.role-member .admin-only { display: none !important; }
/* 财务组用户：财务页管理按钮与管理员的财务页一致（可见） */
body.role-finance .admin-only { display: inline-flex !important; }

/* ===== 中标徽章 ===== */
.won-bid-badge {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  background: var(--accent-light);
  color: #92400e;
  white-space: nowrap;
}

/* ===== 筛选指示器 ===== */
.filter-indicator {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  margin-bottom: 14px;
  background: var(--primary-light);
  border: 1px solid #c7d2fe;
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--primary-dark);
  font-weight: 500;
}

/* ===== 任务列表 ===== */
.task-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
  gap: 18px;
}
.task-card {
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: var(--radius);
  padding: 24px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.task-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--info);
  transition: var(--transition);
}
.task-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}
.task-card.claimed::before { background: var(--success); }
.task-card.claimed { background: #f0fdf4; border-color: #bbf7d0; }
.task-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 14px;
  gap: 12px;
}
.task-card-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.4;
  flex: 1;
}
.task-card-status {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 12px;
  white-space: nowrap;
}
.task-card-status.available {
  background: #dbeafe;
  color: #1e40af;
}
.task-card-status.claimed {
  background: #d1fae5;
  color: #065f46;
}
.task-card-info {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-bottom: 14px;
  font-size: 13px;
  color: var(--text-light);
}
.task-card-info-item {
  display: flex;
  align-items: center;
  gap: 4px;
}
.task-card-info-item strong {
  color: var(--text);
  font-weight: 500;
}
.task-card-desc {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 14px;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.task-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 14px;
  border-top: 1px solid var(--gray-border);
}
.task-card-meta {
  font-size: 12px;
  color: var(--text-light);
}
.task-card-deadline {
  font-size: 12px;
  color: var(--danger);
  font-weight: 500;
}

/* ===== 任务列表表格 ===== */
.task-list-table tbody tr:nth-child(even) { background: rgba(12, 109, 211, 0.03); }
.task-list-table tbody tr:hover {
  background: linear-gradient(90deg, rgba(12,109,211,0.06), rgba(0,188,212,0.06));
}
.task-list-table .btn-sm {
  padding: 4px 16px;
  font-size: 13px;
  border-radius: 6px;
}

/* ===== 响应式 ===== */
@media (max-width: 768px) {
  .topbar { flex-direction: column; height: auto; padding: 12px 16px; gap: 8px; }
  .tabs { width: 100%; overflow-x: auto; }
  .stats-cards { grid-template-columns: repeat(2, 1fr); }
  .dashboard-charts { grid-template-columns: 1fr; }
  .export-cards { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .main-content { padding: 16px; }
  .table-wrapper { overflow-x: auto; }
}

/* ===== 首次登录提醒 ===== */
.first-login-alert {
  background: linear-gradient(135deg, #FEF3C7, #FDE68A);
  border: 1px solid #F59E0B;
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 14px;
  color: #92400E;
  font-weight: 500;
  line-height: 1.5;
}

/* ===== 账号创建成功弹窗 ===== */
.account-created-info {
  text-align: center;
}
.account-created-hint {
  font-size: 14px;
  color: var(--text-light);
  margin-bottom: 16px;
  line-height: 1.5;
}
.account-created-field {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  background: var(--bg-secondary, #f8fafc);
  border-radius: 8px;
  margin-bottom: 8px;
}
.account-created-label {
  font-size: 13px;
  color: var(--text-light);
  min-width: 70px;
  text-align: right;
}
.account-created-value {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  flex: 1;
  text-align: left;
}
.account-created-password {
  font-family: "Courier New", monospace;
  font-size: 18px;
  color: var(--primary);
  letter-spacing: 2px;
}
.account-created-warning {
  margin-top: 16px;
  padding: 10px;
  background: #FEF3C7;
  border-radius: 8px;
  font-size: 13px;
  color: #92400E;
  font-weight: 500;
}

/* ===== 投标报价分析 ===== */
.bid-stats-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.bid-stat-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  text-align: center;
  border-top: 3px solid var(--primary);
}
.bid-stat-card.stat-won { border-top-color: var(--success); }
.bid-stat-card.stat-rate { border-top-color: var(--warning); }
.bid-stat-card.stat-amount { border-top-color: var(--accent); }
.bid-stat-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}
.bid-stat-value.amount { font-size: 22px; }
.bid-stat-label {
  font-size: 13px;
  color: var(--text-light);
  margin-top: 6px;
}
.bid-stat-sub {
  font-size: 12px;
  color: var(--text-light);
  margin-top: 4px;
}
.bid-charts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}

/* 报价录入弹窗 */
.bid-section-title {
  display: flex;
  align-items: center;
  font-size: 15px;
  font-weight: 600;
  color: var(--primary);
  margin: 20px 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--gray-border);
}
.bid-section-title:first-child { margin-top: 0; }

/* 项目类型多选标签 */
.bid-type-checkboxes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.bid-type-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  border: 1px solid var(--gray-border);
  border-radius: 20px;
  font-size: 13px;
  cursor: pointer;
  transition: var(--transition);
  user-select: none;
  background: var(--white);
}
.bid-type-tag:hover { border-color: var(--primary); background: var(--primary-light); }
.bid-type-tag input { width: auto; margin: 0; cursor: pointer; }
.bid-type-tag:has(input:checked) {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

/* 竞争对手列表 */
.bid-competitor-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.bid-competitor-empty {
  text-align: center;
  padding: 20px;
  color: var(--text-light);
  font-size: 13px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  border: 1px dashed var(--gray-border);
}
.bid-competitor-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  border: 1px solid var(--gray-border);
}
.bid-competitor-row .bid-comp-name {
  flex: 2;
}
.bid-competitor-row .bid-comp-price {
  flex: 1;
}
.bid-competitor-row .bid-comp-won {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  white-space: nowrap;
}
.bid-competitor-row .btn-icon {
  flex-shrink: 0;
}
.bid-comp-remove {
  background: none;
  border: none;
  color: var(--danger);
  cursor: pointer;
  font-size: 18px;
  padding: 4px 8px;
  border-radius: 6px;
  transition: var(--transition);
}
.bid-comp-remove:hover { background: var(--danger-light); }

/* Excel导入 */
.bid-excel-mapping {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.bid-excel-mapping-row {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 12px;
  align-items: center;
  padding: 8px 12px;
  background: var(--bg);
  border-radius: var(--radius-sm);
}
.bid-excel-mapping-row label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}

/* 图片识别 */
.bid-image-preview-wrapper {
  text-align: center;
  border: 2px dashed var(--gray-border);
  border-radius: var(--radius);
  padding: 12px;
  background: var(--bg);
}
.bid-image-preview {
  max-width: 100%;
  max-height: 300px;
  border-radius: var(--radius-sm);
}
.bid-ocr-progress-bar {
  width: 100%;
  height: 8px;
  background: var(--gray-light);
  border-radius: 4px;
  overflow: hidden;
}
.bid-ocr-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transition: width 0.3s ease;
}

/* 报价分析表格 */
#bidsTable .bid-won-yes { color: var(--success); font-weight: 600; }
#bidsTable .bid-won-no { color: var(--text-light); }
#bidsTable .bid-type-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  background: var(--primary-light);
  color: var(--primary-dark);
  margin: 1px 2px;
}

/* zebra striping for bids table */
#bidsTable tbody tr:nth-child(even) { background: var(--bg); }

/* ===== 投标报价策略 ===== */
#view-bidprice { max-width: 1200px; }

.bp-header {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-bottom: 12px;
}
.bp-title-input {
  flex: 1; font-size: 16px; font-weight: 600; border: 1px solid var(--border);
  border-radius: 6px; padding: 8px 12px; background: #fff; color: var(--text);
}
.bp-project-select {
  cursor: pointer; appearance: auto;
  background-image: none;
}
.bp-project-select option:first-child { color: var(--text-light); }
.bp-input-md[readonly] { background: var(--bg); color: var(--text-light); cursor: not-allowed; }
.bp-header-btns { display: flex; gap: 8px; }

.bp-history-list {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 8px;
  margin-bottom: 12px; overflow: hidden;
}
.bp-history-item {
  display: flex; align-items: center; justify-content: space-between; padding: 10px 16px;
  border-bottom: 1px solid var(--border); cursor: pointer; transition: background .15s;
}
.bp-history-item:hover { background: var(--primary-light); }
.bp-history-item:last-child { border-bottom: none; }
.bp-history-item-info { display: flex; align-items: center; gap: 12px; }
.bp-history-item-name { font-weight: 600; color: var(--text); }
.bp-history-item-meta { font-size: 12px; color: var(--text-light); }
.bp-history-item-del { color: #dc2626; font-size: 12px; }

.bp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.bp-section {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 8px; padding: 16px;
}
.bp-section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.bp-section-title { font-size: 15px; font-weight: 700; color: var(--text); margin: 0 0 12px; }
.bp-section-tag {
  display: inline-block; font-size: 11px; font-weight: 500; color: var(--primary-dark);
  background: var(--primary-light); padding: 2px 8px; border-radius: 10px; margin-left: 6px;
}

.bp-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.bp-field { display: flex; flex-direction: column; gap: 4px; }
.bp-field label { font-size: 13px; font-weight: 500; color: var(--text); }
.bp-input-sm {
  width: 100%; padding: 6px 10px; border: 1px solid var(--border); border-radius: 6px;
  font-size: 14px; background: #fff; color: var(--text);
}
.bp-input-md {
  width: 100%; padding: 8px 12px; border: 1px solid var(--border); border-radius: 6px;
  font-size: 15px; font-weight: 600; background: #fff; color: var(--text);
}
.bp-field-hint { font-size: 11px; color: var(--text-light); }

.bp-formula-details { margin-top: 12px; }
.bp-formula-details summary { cursor: pointer; font-size: 13px; color: var(--primary); font-weight: 500; }
.bp-formula-text { margin-top: 8px; padding: 12px; background: var(--bg); border-radius: 6px; font-size: 12px; line-height: 1.8; color: var(--text); }
.bp-formula-text p { margin: 0; }

/* 报价清单表 */
.bp-quote-table input {
  width: 100%; padding: 4px 6px; border: 1px solid #e5e7eb; border-radius: 4px;
  font-size: 13px; background: #fff; color: var(--text);
}
.bp-quote-table .bp-item-no { text-align: center; }
.bp-quote-table .bp-suggested { background: #fef9c3; font-weight: 600; }
.bp-quote-table tfoot td { padding: 8px 10px; background: var(--bg); }

/* 竞争对手输入 */
.bp-subsection { margin-bottom: 16px; }
.bp-subsection-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.bp-subsection-title { font-size: 14px; font-weight: 600; color: var(--text); }
.bp-subsection-hint { font-size: 12px; color: var(--text-light); margin: 0 0 10px; }

.bp-comp-row {
  display: flex; align-items: center; gap: 8px; margin-bottom: 8px;
}
.bp-comp-row input { padding: 6px 10px; border: 1px solid var(--border); border-radius: 6px; font-size: 13px; }
.bp-comp-name { width: 180px; }
.bp-comp-price { width: 140px; text-align: right; font-weight: 500; }
.bp-comp-del { color: #dc2626; cursor: pointer; font-size: 13px; width: 28px; text-align: center; }

.bp-calc-btn { margin: 0; }
.bp-calc-btns { display: flex; flex-direction: column; gap: 10px; margin: 12px 0; }
.bp-confirm-btn {
  display: block; width: 100%; margin-top: 16px; padding: 12px;
  font-size: 16px; font-weight: 700; border: none; border-radius: 8px;
  background: linear-gradient(135deg, #059669, #10b981); color: #fff;
  cursor: pointer; transition: all 0.2s;
}
.bp-confirm-btn:hover { background: linear-gradient(135deg, #047857, #059669); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(16,185,129,0.3); }

/* AI 分析按钮 */
.bp-ai-btn {
  background: linear-gradient(135deg, #6d28d9, #4f46e5); color: #fff;
  border: none; padding: 8px 20px; border-radius: 6px; font-size: 14px;
  font-weight: 600; cursor: pointer; transition: all 0.2s; white-space: nowrap;
}
.bp-ai-btn:hover { background: linear-gradient(135deg, #5b21b6, #4338ca); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(99,102,241,0.3); }
.bp-ai-btn:disabled { opacity: 0.6; cursor: wait; }

/* AI 分析结果 */
.bp-ai-card {
  background: linear-gradient(135deg, #faf5ff, #eef2ff); border: 1px solid #c4b5fd;
  border-radius: 10px; padding: 18px; margin-top: 4px;
}
.bp-ai-card-header {
  display: flex; align-items: center; gap: 8px; margin-bottom: 12px;
  padding-bottom: 10px; border-bottom: 1px solid #ddd6fe;
}
.bp-ai-card-header-icon { font-size: 20px; }
.bp-ai-card-header-title { font-size: 15px; font-weight: 700; color: #5b21b6; }
.bp-ai-card-header-badge { font-size: 11px; color: #7c3aed; background: #ede9fe; padding: 2px 8px; border-radius: 10px; margin-left: auto; }
.bp-ai-content {
  font-size: 13px; line-height: 1.8; color: var(--text); white-space: pre-wrap;
}
.bp-ai-content h1, .bp-ai-content h2, .bp-ai-content h3, .bp-ai-content h4 {
  font-weight: 700; color: #4c1d95; margin: 12px 0 6px;
}
.bp-ai-content strong { color: #5b21b6; }
.bp-ai-loading {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  padding: 40px; color: #7c3aed; font-size: 14px;
}
.bp-ai-loading .bp-ai-spinner {
  width: 20px; height: 20px; border: 3px solid #ddd6fe; border-top-color: #7c3aed;
  border-radius: 50%; animation: bp-ai-spin 0.8s linear infinite;
}
@keyframes bp-ai-spin { to { transform: rotate(360deg); } }
.bp-ai-error {
  background: #fef2f2; border: 1px solid #fca5a5; border-radius: 8px;
  padding: 14px; color: #991b1b; font-size: 13px;
}

/* 结果卡片 */
.bp-result-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; margin-bottom: 16px; }
.bp-result-card {
  background: linear-gradient(135deg, #eff6ff, #dbeafe); border: 1px solid #93c5fd;
  border-radius: 8px; padding: 14px; text-align: center;
}
.bp-result-card.best { background: linear-gradient(135deg, #dcfce7, #bbf7d0); border-color: #4ade80; }
.bp-result-card-label { font-size: 12px; color: var(--text-light); margin-bottom: 4px; }
.bp-result-card-value { font-size: 20px; font-weight: 700; color: #1e40af; }
.bp-result-card.best .bp-result-card-value { color: #15803d; }
.bp-result-card-sub { font-size: 11px; color: var(--text-light); margin-top: 2px; }

/* 图表 */
.bp-chart-box { background: var(--card-bg); border: 1px solid var(--border); border-radius: 8px; padding: 16px; margin-bottom: 16px; }
.bp-chart-title { font-size: 14px; font-weight: 600; color: var(--text); margin: 0 0 10px; }
.bp-chart-box canvas { max-height: 320px; }

/* 详细计算过程 */
.bp-detail-table { background: var(--card-bg); border: 1px solid var(--border); border-radius: 8px; padding: 14px; margin-bottom: 16px; }
.bp-detail-title { font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.bp-detail-row { display: flex; justify-content: space-between; padding: 4px 0; font-size: 13px; border-bottom: 1px dashed var(--border); }
.bp-detail-row:last-child { border-bottom: none; }
.bp-detail-label { color: var(--text-light); }
.bp-detail-value { font-weight: 600; color: var(--text); }

/* 二次报价 */
.bp-second-round {
  border-top: 2px dashed var(--border); padding-top: 16px; margin-top: 8px;
}
.bp-second-options { margin: 8px 0; }
.bp-check-label { font-size: 13px; color: var(--text); display: flex; align-items: center; gap: 6px; cursor: pointer; }
.bp-check-label input { width: auto; }

/* 进度记录表内联报价输入 */
.bid-inline-input {
  width: 100px; padding: 4px 6px; border: 1px solid var(--border);
  border-radius: 4px; font-size: 12px; text-align: right;
  background: #fff; color: var(--text);
}
.bid-inline-input:focus { border-color: var(--primary); outline: none; box-shadow: 0 0 0 2px rgba(59,130,246,0.15); }
.bid-inline-input.filled { background: #f0fdf4; border-color: #86efac; font-weight: 600; color: #15803d; }
.bid-empty { color: var(--text-light); font-size: 12px; }

/* 二次报价跳转按钮 */
.bid-link-btn {
  background: none; border: 1px dashed var(--primary); color: var(--primary);
  padding: 3px 10px; border-radius: 4px; font-size: 12px; cursor: pointer;
  transition: all 0.15s;
}
.bid-link-btn:hover { background: var(--primary); color: #fff; }
.bid-link-btn.filled { border-style: solid; background: #eff6ff; color: #1d4ed8; font-weight: 600; }
.bid-link-btn.filled:hover { background: #1d4ed8; color: #fff; }

/* 各家报价输入 */
.bp-bidder-prices {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 8px; margin-bottom: 4px;
}
.bp-bidder-input-row {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 10px; border: 1px solid var(--border); border-radius: 6px;
  background: var(--bg);
}
.bp-bidder-input-row label {
  font-size: 13px; font-weight: 600; color: var(--text);
  white-space: nowrap; min-width: 42px;
}
.bp-bidder-input-row input {
  flex: 1; min-width: 0; padding: 4px 6px; border: 1px solid var(--border);
  border-radius: 4px; font-size: 13px; text-align: right; background: #fff;
}
.bp-bidder-input-row input:focus { border-color: var(--primary); outline: none; }
.bp-bidder-input-row span { font-size: 12px; color: var(--text-light); white-space: nowrap; }

/* ===== 登录组别选择 ===== */
.login-group-tabs {
  display: flex; gap: 0; margin-bottom: 20px; border-radius: 8px; overflow: hidden;
  border: 1px solid var(--border);
}
.login-group-tab {
  flex: 1; padding: 10px 0; border: none; background: #f3f4f6; color: var(--text-light);
  font-size: 14px; font-weight: 500; cursor: pointer; transition: all 0.2s;
}
.login-group-tab:hover { background: #e5e7eb; }
.login-group-tab.active {
  background: var(--primary); color: #fff;
}

/* ===== 财务模块 ===== */
.finance-cards {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px; margin-bottom: 30px;
}
.finance-card {
  background: #fff; border-radius: 12px; padding: 30px 24px; text-align: center;
  border: 1px solid var(--border); transition: box-shadow 0.2s, transform 0.2s;
}
.finance-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.08); transform: translateY(-2px); }
.finance-card-icon { font-size: 48px; margin-bottom: 12px; }
.finance-card h3 { font-size: 18px; margin: 0 0 8px; color: var(--text); }
.finance-card p { font-size: 13px; color: var(--text-light); margin: 0 0 16px; }
.finance-btn { width: 100%; }
.finance-btn:disabled { opacity: 0.5; cursor: not-allowed; }

.finance-dashboard {
  background: #fff; border-radius: 12px; padding: 24px; border: 1px solid var(--border);
}
.finance-stat-row {
  display: flex; gap: 30px; flex-wrap: wrap;
}
.finance-stat-item {
  display: flex; flex-direction: column; gap: 6px;
}
.finance-stat-label { font-size: 13px; color: var(--text-light); }
.finance-stat-value { font-size: 28px; font-weight: 700; color: var(--primary); }

/* ===== 标书制作 ===== */
.bid-doc-container { max-width: 900px; margin: 0 auto; }
.bid-doc-upload-area { background: #fff; border-radius: 12px; padding: 24px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); margin-bottom: 20px; }
.bid-doc-upload-group { margin-bottom: 24px; }
.bid-doc-label { display: block; font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.bid-doc-label .required { color: #ef4444; }
.bid-doc-dropzone { border: 2px dashed #d1d5db; border-radius: 10px; padding: 32px 20px; text-align: center; cursor: pointer; transition: all 0.2s; background: #f9fafb; }
.bid-doc-dropzone:hover { border-color: var(--primary); background: #eff6ff; }
.bid-doc-dropzone.dragover { border-color: var(--primary); background: #dbeafe; }
.bid-doc-dropzone-icon { font-size: 36px; display: block; margin-bottom: 8px; }
.bid-doc-dropzone-text { font-size: 14px; color: var(--text); margin: 0 0 4px; }
.bid-doc-dropzone-hint { font-size: 12px; color: var(--text-light); margin: 0; }
.bid-doc-file-info { margin-top: 8px; padding: 8px 12px; background: #f0f9ff; border-radius: 6px; font-size: 13px; color: var(--text); display: flex; align-items: center; gap: 8px; }
.bid-doc-file-info::before { content: "✅"; }
.bid-doc-file-list { margin-top: 8px; }
.bid-doc-file-item { padding: 6px 12px; background: #f0f9ff; border-radius: 6px; font-size: 13px; color: var(--text); margin-bottom: 4px; display: flex; align-items: center; justify-content: space-between; }
.bid-doc-file-item-remove { color: #ef4444; cursor: pointer; font-size: 16px; }
.bid-doc-generate-btn { width: 100%; padding: 14px; font-size: 16px; font-weight: 600; border-radius: 10px; }
.bid-doc-generate-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.bid-doc-instructions { width: 100%; min-height: 120px; padding: 12px 16px; border: 1.5px solid #d1d5db; border-radius: 10px; font-size: 14px; line-height: 1.6; resize: vertical; font-family: inherit; transition: border-color 0.2s; box-sizing: border-box; }
.bid-doc-instructions:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(12,109,211,0.1); }
.bid-doc-instructions::placeholder { color: #9ca3af; font-size: 13px; }
.bid-doc-btn-spinner { display: inline-block; width: 16px; height: 16px; border: 2px solid rgba(255,255,255,0.3); border-top-color: #fff; border-radius: 50%; animation: spin 0.8s linear infinite; margin-left: 8px; vertical-align: middle; }
@keyframes spin { to { transform: rotate(360deg); } }
.bid-doc-result { background: #fff; border-radius: 12px; padding: 24px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.bid-doc-result-header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.bid-doc-result-title { font-size: 18px; font-weight: 700; color: var(--text); margin: 0; flex: 1; }
.bid-doc-copy-btn, .bid-doc-download-btn { padding: 6px 16px; font-size: 13px; border-radius: 6px; }
.bid-doc-content { font-size: 14px; line-height: 1.8; color: var(--text); max-height: 600px; overflow-y: auto; padding: 16px; background: #f9fafb; border-radius: 8px; }
.bid-doc-content h1 { font-size: 20px; font-weight: 700; margin: 20px 0 12px; color: var(--text); }
.bid-doc-content h2 { font-size: 18px; font-weight: 700; margin: 18px 0 10px; color: var(--primary); border-bottom: 2px solid #e5e7eb; padding-bottom: 6px; }
.bid-doc-content h3 { font-size: 16px; font-weight: 600; margin: 14px 0 8px; color: var(--text); }
.bid-doc-content p { margin: 8px 0; }
.bid-doc-content ul, .bid-doc-content ol { margin: 8px 0; padding-left: 24px; }
.bid-doc-content li { margin: 4px 0; }
.bid-doc-content strong { font-weight: 600; color: var(--text); }
.bid-doc-content table { width: 100%; border-collapse: collapse; margin: 12px 0; }
.bid-doc-content th, .bid-doc-content td { border: 1px solid #e5e7eb; padding: 8px 12px; font-size: 13px; }
.bid-doc-content th { background: #f3f4f6; font-weight: 600; }
.bid-doc-error { background: #fef2f2; border: 1px solid #fecaca; color: #dc2626; padding: 12px 16px; border-radius: 8px; font-size: 14px; margin-top: 16px; }

/* ===== 一次报价 ===== */
.fq-container { max-width: 1000px; margin: 0 auto; }
.fq-step { background: #fff; border-radius: 12px; padding: 24px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); margin-bottom: 20px; }
.fq-step-title { font-size: 16px; font-weight: 700; color: var(--text); margin-bottom: 16px; display: flex; align-items: center; gap: 10px; }
.fq-step-num { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; background: var(--primary); color: #fff; font-size: 14px; font-weight: 700; }
.fq-step-desc { font-size: 13px; color: var(--gray); margin-bottom: 16px; line-height: 1.6; }
.fq-upload-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.fq-upload-group { margin-bottom: 0; }
.fq-label { display: block; font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.fq-label .required { color: #ef4444; }
.fq-dropzone { border: 2px dashed #d1d5db; border-radius: 10px; padding: 24px; text-align: center; cursor: pointer; transition: all 0.2s; background: #fafbfc; }
.fq-dropzone:hover { border-color: var(--primary); background: var(--primary-light); }
.fq-dropzone.dragover { border-color: var(--primary); background: var(--primary-light); }
.fq-dropzone-inner { pointer-events: none; }
.fq-dropzone-icon { font-size: 32px; display: block; margin-bottom: 8px; }
.fq-dropzone-text { font-size: 14px; color: var(--text); font-weight: 500; }
.fq-dropzone-hint { font-size: 12px; color: var(--gray); margin-top: 4px; }
.fq-file-info { margin-top: 8px; padding: 10px 14px; background: var(--success-light); border: 1px solid #d1fae5; border-radius: 8px; font-size: 13px; color: #065f46; display: flex; align-items: center; justify-content: space-between; }
.fq-file-info-remove { cursor: pointer; color: var(--danger); font-size: 18px; font-weight: bold; }
.fq-criteria-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.fq-field { display: flex; flex-direction: column; }
.fq-field label { font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 6px; }
.fq-field input { padding: 8px 12px; border: 1px solid #d1d5db; border-radius: 6px; font-size: 14px; }
.fq-field input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(12,109,211,0.1); }
.fq-input { width: 100%; }
.fq-input-sm { width: 120px; }
.fq-field-hint { font-size: 12px; color: var(--gray); margin-top: 4px; }
.fq-formula-details { margin-top: 16px; background: #f9fafb; border-radius: 8px; padding: 12px; }
.fq-formula-details summary { cursor: pointer; font-size: 13px; font-weight: 600; color: var(--primary); }
.fq-formula-text { margin-top: 12px; font-size: 13px; color: var(--text); line-height: 1.8; }
.fq-formula-text p { margin: 2px 0; }
.fq-generate-btn { width: 100%; padding: 14px; font-size: 16px; font-weight: 600; border-radius: 10px; border: none; background: var(--primary); color: #fff; cursor: pointer; transition: all 0.2s; }
.fq-generate-btn:hover:not(:disabled) { background: var(--primary-dark); }
.fq-generate-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.fq-btn-spinner { display: inline-block; width: 16px; height: 16px; border: 2px solid rgba(255,255,255,0.3); border-top-color: #fff; border-radius: 50%; animation: spin 0.8s linear infinite; margin-left: 8px; }
@keyframes spin { to { transform: rotate(360deg); } }
.fq-ai-result { background: #fff; border-radius: 12px; padding: 24px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); margin-bottom: 20px; border-left: 4px solid var(--accent); }
.fq-ai-result-title { font-size: 16px; font-weight: 700; color: var(--text); margin-bottom: 12px; }
.fq-ai-content { font-size: 14px; line-height: 1.8; color: var(--text); max-height: 400px; overflow-y: auto; padding: 16px; background: #f9fafb; border-radius: 8px; white-space: pre-wrap; }
.fq-ai-content h2 { font-size: 16px; font-weight: 700; margin: 12px 0 8px; color: var(--primary); }
.fq-ai-content h3 { font-size: 14px; font-weight: 600; margin: 10px 0 6px; color: var(--text); }
.fq-ai-content p { margin: 6px 0; }
.fq-result { background: #fff; border-radius: 12px; padding: 24px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.fq-result-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.fq-result-title { font-size: 16px; font-weight: 700; color: var(--text); }
.fq-result-btns { display: flex; gap: 8px; }
.fq-summary-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 16px; }
.fq-summary-card { background: #f9fafb; border-radius: 8px; padding: 14px; text-align: center; }
.fq-summary-card-label { font-size: 12px; color: var(--gray); margin-bottom: 4px; }
.fq-summary-card-value { font-size: 18px; font-weight: 700; color: var(--primary); }
.fq-quote-table input { width: 100%; padding: 4px 8px; border: 1px solid #e5e7eb; border-radius: 4px; font-size: 13px; }
.fq-quote-table input:focus { border-color: var(--primary); }
.fq-error { background: #fef2f2; border: 1px solid #fecaca; color: #dc2626; padding: 12px 16px; border-radius: 8px; font-size: 14px; margin-top: 16px; }
@media (max-width: 768px) {
  .fq-upload-grid { grid-template-columns: 1fr; }
  .fq-criteria-grid { grid-template-columns: 1fr; }
  .fq-summary-cards { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================ */
/* ===== 业务统计模块样式 ===== */
/* ============================================ */

.biz-filter-bar, .business-filter-bar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.filter-input { padding: 6px 12px; border: 1px solid #e0e0e0; border-radius: 8px; font-size: 14px; min-width: 180px; background: #fff; }

/* 统计卡片 */
.biz-stats-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 20px; }
.biz-stat-card { background: #fff; border-radius: 12px; padding: 20px; display: flex; align-items: center; gap: 16px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); transition: transform 0.2s; }
.biz-stat-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.biz-stat-card-clickable { cursor: pointer; border: 1px solid transparent; }
.biz-stat-card-clickable:hover { border-color: #0c6dd3; background: #f0f7ff; }
.biz-stat-card-clickable .biz-stat-label::after { content: " (点击查看)"; font-size: 11px; color: #0c6dd3; font-weight: 500; }
.biz-stat-icon { font-size: 32px; width: 56px; height: 56px; display: flex; align-items: center; justify-content: center; border-radius: 12px; background: #f0f7ff; }
.biz-stat-info { display: flex; flex-direction: column; }
.biz-stat-value { font-size: 24px; font-weight: 700; color: #1f2937; }
.biz-stat-label { font-size: 13px; color: #6b7280; margin-top: 2px; }

/* 图表区域 */
.biz-charts { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; margin-bottom: 20px; }
.biz-charts .chart-card { min-height: 280px; }

/* 来源徽章 */
.biz-source-badge { display: inline-block; padding: 2px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; }

/* 来源选择Tab */
.biz-source-tabs { display: flex; gap: 8px; }
.biz-source-tab { flex: 1; padding: 12px 16px; border: 2px solid #e5e7eb; border-radius: 10px; background: #fff; cursor: pointer; font-size: 14px; font-weight: 500; color: #6b7280; transition: all 0.2s; text-align: center; }
.biz-source-tab:hover { border-color: #c0d4ea; }
.biz-source-tab.active { border-color: #0c6dd3; background: #f0f7ff; color: #0c6dd3; }
.biz-source-panel { padding: 16px 0; }

/* 中标信息卡片 */
.biz-wonbid-info-card { background: #f0f7ff; border-radius: 10px; padding: 16px; border: 1px solid #d0e0f0; }
.biz-wonbid-info-row { display: flex; gap: 8px; padding: 4px 0; font-size: 14px; }
.biz-wonbid-info-row span { color: #6b7280; min-width: 80px; }

/* 合同上传区域 */
.contract-upload-box { border: 2px dashed #cbd5e1; border-radius: 12px; padding: 32px 20px; text-align: center; cursor: pointer; transition: all 0.2s; background: #f9fafb; }
.contract-upload-box:hover { border-color: #0c6dd3; background: #f0f7ff; }
.contract-upload-box.drag-over { border-color: #0c6dd3; background: #e0f0ff; }
.contract-upload-icon { font-size: 40px; display: block; margin-bottom: 8px; }
.contract-upload-box p { margin: 4px 0; font-weight: 600; color: #374151; }
.contract-upload-box small { color: #9ca3af; font-size: 12px; }

/* 合同解析结果 */
.contract-parsed-card { background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 10px; padding: 16px; margin-top: 12px; }
.contract-parsed-header { font-weight: 700; color: #15803d; margin-bottom: 12px; font-size: 14px; }
.contract-parsed-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.contract-parsed-item { display: flex; flex-direction: column; gap: 2px; padding: 6px 10px; background: #fff; border-radius: 6px; }
.contract-parsed-item.full { grid-column: 1 / -1; }
.contract-parsed-item label { font-size: 11px; color: #6b7280; font-weight: 500; }
.contract-parsed-item span { font-size: 14px; color: #1f2937; }

/* 通用表单区域 */
.biz-form-section { border-top: 1px solid #e5e7eb; padding-top: 16px; margin-top: 8px; }

/* 加载动画 */
.spinner { display: inline-block; width: 28px; height: 28px; border: 3px solid #e5e7eb; border-top-color: #0c6dd3; border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 768px) {
  .biz-stats-cards { grid-template-columns: repeat(2, 1fr); }
  .biz-charts { grid-template-columns: 1fr; }
  .biz-source-tabs { flex-direction: column; }
  .biz-type-tabs { flex-direction: column; }
  .contract-parsed-grid { grid-template-columns: 1fr; }
  .price-table-table-wrap { overflow-x: auto; }
}

/* ============================================ */
/* ===== 框架业务 - 业务类型选择 + 单价表样式 ===== */
/* ============================================ */

/* 业务类型选择 Tab */
.biz-type-tabs { display: flex; gap: 8px; margin-bottom: 4px; }
.biz-type-tab { flex: 1; padding: 14px 16px; border: 2px solid #e5e7eb; border-radius: 10px; background: #fff; cursor: pointer; font-size: 15px; font-weight: 600; color: #6b7280; transition: all 0.2s; text-align: center; }
.biz-type-tab:hover { border-color: #c4b5fd; background: #faf5ff; }
.biz-type-tab.active { border-color: #7c3aed; background: #f5f3ff; color: #7c3aed; }

/* 框架业务区域 */
.biz-framework-section { margin-top: 8px; }
.biz-section-divider { height: 1px; background: linear-gradient(90deg, transparent, #d1d5db, transparent); margin: 12px 0; }
.biz-section-title { font-size: 15px; font-weight: 700; color: #7c3aed; margin: 0 0 12px; }

/* 单价表上传区 */
.price-table-upload-box { border: 2px dashed #a78bfa; border-radius: 12px; padding: 32px 20px; text-align: center; cursor: pointer; transition: all 0.2s; background: #faf5ff; }
.price-table-upload-box:hover { border-color: #7c3aed; background: #f3e8ff; }
.price-table-upload-box.drag-over { border-color: #7c3aed; background: #e9d5ff; }
.price-table-upload-icon { font-size: 36px; display: block; margin-bottom: 8px; }
.price-table-upload-box p { margin: 4px 0; font-weight: 600; color: #374151; }
.price-table-upload-box small { color: #9ca3af; font-size: 12px; }

/* ============ 财务管理 ============ */
.finance-sub-tabs { display: flex; gap: 8px; margin-bottom: 20px; border-bottom: 2px solid #e5e7eb; }
.finance-sub-tab { padding: 10px 20px; border: none; background: none; font-size: 15px; font-weight: 600; color: #6b7280; cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -2px; transition: all 0.2s; }
.finance-sub-tab:hover { color: #0c6dd3; }
.finance-sub-tab.active { color: #0c6dd3; border-bottom-color: #0c6dd3; }
.finance-sub-content { display: none; }
.finance-sub-content.active { display: block; }
.finance-stat-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.finance-stat-item { background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 16px 20px; text-align: center; }
.finance-stat-label { display: block; font-size: 13px; color: #6b7280; margin-bottom: 6px; }
.finance-stat-value { display: block; font-size: 22px; font-weight: 700; color: #1f2937; }
.finance-total-bar { background: linear-gradient(135deg, #f0fdf4, #dcfce7); border: 1px solid #bbf7d0; border-radius: 10px; padding: 16px 24px; display: flex; align-items: center; justify-content: flex-end; gap: 8px; margin-bottom: 16px; }

/* 工资条-按天折算标签 */
.salary-note {
  display: inline-block;
  margin-left: 4px;
  padding: 1px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 600;
  background: #fef3c7;
  color: #d97706;
  cursor: help;
  vertical-align: middle;
  white-space: nowrap;
}
.finance-comm-card { background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 16px; }
.finance-comm-card .comm-card-name { font-size: 16px; font-weight: 700; color: #1f2937; margin-bottom: 8px; }
.finance-comm-card .comm-card-total { font-size: 24px; font-weight: 700; color: #16a34a; }
.finance-comm-card .comm-card-sub { font-size: 13px; color: #6b7280; margin-top: 4px; }
.att-status-normal { color: #16a34a; }
.att-status-late, .att-status-early_leave { color: #f59e0b; }
.att-status-leave, .att-status-sick_leave { color: #2563eb; }
.att-status-business_trip { color: #7c3aed; }
.att-status-absent { color: #dc2626; }
.att-status-comp_leave { color: #0891b2; }

/* 工资提成页面样式 */
#salaryTable td { vertical-align: middle; }
#salaryDetailTable td { vertical-align: middle; }
#salaryDetailSection { background: #f9fafb; border-radius: 12px; padding: 20px; }
#salaryDetailSection h3 { color: #374151; }

/* 自定义弹窗 */
#customAlertOverlay .modal-body { padding: 20px; }
#customAlertOverlay .data-table { font-size: 13px; }

/* 文件删除按钮（合同+单价表通用） */
.biz-file-delete-btn {
  position: absolute; top: 8px; right: 8px;
  width: 26px; height: 26px; border-radius: 50%;
  border: none; background: #fee2e2; color: #dc2626;
  font-size: 14px; font-weight: 700; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.15s; z-index: 2;
}
.biz-file-delete-btn:hover { background: #dc2626; color: #fff; transform: scale(1.1); }
.contract-upload-box, .price-table-upload-box { position: relative; }

/* 单价表解析结果 */
.price-table-parsed-card { border: 1px solid #ddd6fe; border-radius: 10px; overflow: hidden; margin-top: 12px; }
.price-table-parsed-header { background: #f5f3ff; padding: 10px 16px; font-weight: 600; color: #6d28d9; font-size: 14px; border-bottom: 1px solid #e9d5ff; }
.price-table-sheet-name { padding: 8px 16px; font-weight: 600; color: #5b21b6; font-size: 13px; background: #faf5ff; border-bottom: 1px solid #f3e8ff; }
.price-table-table-wrap { overflow-x: auto; max-height: 400px; overflow-y: auto; }
.price-table-preview { width: 100%; border-collapse: collapse; font-size: 12px; }
.price-table-preview th { background: #7c3aed; color: #fff; padding: 6px 10px; text-align: left; position: sticky; top: 0; z-index: 1; white-space: nowrap; }
.price-table-preview td { padding: 5px 10px; border-bottom: 1px solid #f3f4f6; white-space: nowrap; }
.price-table-preview tbody tr:hover { background: #faf5ff; }
.price-table-preview tbody tr:nth-child(even) { background: #fcfcfd; }

/* 业务类型徽章 */
.biz-type-badge { display: inline-block; padding: 1px 8px; border-radius: 4px; font-size: 11px; font-weight: 500; }

/* ===== 新增：操作日志徽章 ===== */
.log-module-badge {
  display: inline-block; padding: 2px 8px; border-radius: 6px;
  background: #eff6ff; color: #1d4ed8; font-size: 12px; font-weight: 500;
}
.log-action-badge {
  display: inline-block; padding: 2px 8px; border-radius: 6px;
  background: #f1f5f9; color: #475569; font-size: 12px; font-weight: 500;
}
.log-action-badge.action-新增 { background: #ecfdf5; color: #047857; }
.log-action-badge.action-修改 { background: #eff6ff; color: #1d4ed8; }
.log-action-badge.action-删除 { background: #fef2f2; color: #b91c1c; }
.log-action-badge.action-登录 { background: #f5f3ff; color: #6d28d9; }
.log-action-badge.action-标记完成 { background: #ecfdf5; color: #047857; }
.log-action-badge.action-中标标记 { background: #fffbeb; color: #b45309; }
.log-action-badge.action-批量生成 { background: #ecfeff; color: #0e7490; }
.table-pager { display: flex; align-items: center; justify-content: center; }

/* ===== 新增：仪表盘图表布局 ===== */
.dashboard-charts {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 22px;
  margin-bottom: 32px;
}
.chart-card { min-height: 260px; }
.chart-card-wide { grid-column: 1 / -1; }

/* ===== 新增：移动端汉堡菜单 ===== */
.menu-toggle {
  display: none;
  background: rgba(255,255,255,0.12);
  border: none;
  color: #fff;
  font-size: 20px;
  width: 38px; height: 38px;
  border-radius: 10px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  flex-shrink: 0;
}
.menu-toggle:hover { background: rgba(255,255,255,0.22); }
.sidebar-overlay {
  position: fixed;
  inset: 0;
  top: 64px;
  background: rgba(15, 23, 42, 0.45);
  z-index: 60;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.sidebar-overlay.show { display: block !important; opacity: 1; }

/* ===== 移动端适配 ===== */
@media (max-width: 900px) {
  .menu-toggle { display: flex; }
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 4px 0 24px rgba(6, 42, 92, 0.12);
  }
  .sidebar.open { transform: translateX(0); }
  .main-content { margin-left: 0; padding: 20px 14px; }
  .topbar { padding: 0 14px; }
  .app-title { font-size: 16px; letter-spacing: 0.5px; }
  .logo-img { width: 30px; height: 30px; }
  .dashboard-charts { grid-template-columns: 1fr; }
  .stats-cards { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .stat-card { padding: 14px 10px; }
  .stat-value { font-size: 20px; }
  .toolbar { flex-wrap: wrap; gap: 8px; }
  .filters { flex-wrap: wrap; }
  .filter-select, .filter-date { max-width: 140px; }
  .notification-dropdown {
    width: min(360px, calc(100vw - 24px));
    right: -8px;
  }
  .table-wrapper { -webkit-overflow-scrolling: touch; }
  .finance-sub-tabs { overflow-x: auto; -webkit-overflow-scrolling: touch; white-space: nowrap; }
  .finance-sub-tabs .finance-sub-tab { display: inline-block; white-space: nowrap; }
  .data-table { min-width: 700px; }
  /* 打卡卡片移动端 */
  #dashAttendanceCard { flex-direction: column; align-items: flex-start !important; padding: 14px 16px !important; }
  #dashAttendanceCard > div:last-child { width: 100%; justify-content: space-between; }
  .modal-content { width: 92%; max-height: 86vh; }
  .recent-item { flex-wrap: wrap; gap: 6px; }
  .recent-date { margin-left: auto; }
  .export-cards { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .topbar-right { gap: 4px; }
  .user-display-name, .user-role-badge, .user-dropdown-arrow { display: none; }
  .user-info-badge { padding: 6px 8px; }
  .stats-cards { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .stat-card { padding: 12px 8px; }
  .stat-icon { font-size: 20px; }
  .stat-value { font-size: 18px; }
  .dashboard-charts { gap: 12px; }
  .filters .filter-select, .filters .filter-date { max-width: 120px; }
  .btn { padding: 7px 12px; font-size: 13px; }
}

/* ===== 项目看板 ===== */
.kanban-board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  min-height: 400px;
}
.kanban-column {
  background: #f1f5f9;
  border-radius: 12px;
  padding: 10px;
  min-height: 300px;
  display: flex;
  flex-direction: column;
}
.kanban-column-header {
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  padding: 9px 14px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.kanban-count {
  background: rgba(255,255,255,0.25);
  border-radius: 10px;
  padding: 1px 9px;
  font-size: 12px;
  font-weight: 700;
}
.kanban-list { flex: 1; display: flex; flex-direction: column; gap: 8px; overflow-y: auto; max-height: 70vh; }
.kanban-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px 14px;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.kanban-card:hover { border-color: var(--primary); box-shadow: 0 4px 14px rgba(12,109,211,0.12); transform: translateY(-2px); }
.kanban-card-title { font-size: 13.5px; font-weight: 600; color: #1e293b; margin-bottom: 6px; line-height: 1.4; }
.kanban-card-meta { font-size: 12px; color: #64748b; margin-top: 3px; }
.kanban-card-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.kanban-card-date { font-size: 11px; color: #94a3b8; }
.kanban-empty { text-align: center; color: #94a3b8; font-size: 12px; padding: 24px 0; }
@media (max-width: 900px) {
  .kanban-board { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .kanban-board { grid-template-columns: 1fr; }
}

/* ===== 档期排期冲突 ===== */
.schedule-conflict-box {
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 10px;
  padding: 10px 16px;
  font-size: 12.5px;
  color: #b91c1c;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.conflict-item { line-height: 1.5; }

/* ===== 项目档案 ===== */
.archive-folders { display: flex; flex-direction: column; gap: 14px; }
.archive-folder {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.archive-folder-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-bottom: 1px solid #e2e8f0;
}
.archive-file-count {
  font-size: 12px;
  color: #64748b;
  background: #e2e8f0;
  border-radius: 10px;
  padding: 2px 10px;
  margin-right: 6px;
}
.archive-folder-files { padding: 10px 18px; display: flex; flex-direction: column; }
.archive-file-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 6px;
  border-bottom: 1px dashed #f1f5f9;
}
.archive-file-item:last-child { border-bottom: none; }
.archive-file-icon { font-size: 16px; }
.archive-folder-empty {
  padding: 14px 18px;
  font-size: 12.5px;
  color: #94a3b8;
  text-align: center;
}

/* ===== 投标文件（00_中标信息） ===== */
.bid-style-choice {
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 12px;
}
.bid-slot {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 10px;
}
.bid-slot-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.bid-slot-files { display: flex; flex-direction: column; }
.bid-slot .archive-file-item {
  background: #fff;
  border-radius: 8px;
  border: 1px solid #f1f5f9;
  padding: 8px 10px;
  margin-bottom: 6px;
}

/* ===== 项目立项信息卡 ===== */
.project-lixiang-card { margin-bottom: 16px; border-color: #c7d2fe; }
.team-select { width: 100%; border: 1px solid #e2e8f0; border-radius: 8px; padding: 6px; }
.team-select option { padding: 3px 6px; }
@media (max-width: 768px) {
  .project-lixiang-card [style*="grid-template-columns:1fr 1fr"],
  .project-lixiang-card [style*="grid-template-columns:repeat(3,1fr)"] { grid-template-columns: 1fr !important; }
}

/* ===== 项目任务区块 ===== */
.project-tasks-section { margin-bottom: 16px; border-color: #bbf7d0; }
.project-task-item { transition: var(--transition); }
.project-task-item:hover { border-color: #86efac !important; box-shadow: 0 2px 8px rgba(16,185,129,0.08); }

/* ===== 底部备案信息条（ICP 合规） ===== */
.site-footer {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 5px 12px;
  font-size: 12px;
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.92);
  border-top: 1px solid #e2e8f0;
  backdrop-filter: blur(4px);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
}
.site-footer a {
  color: #94a3b8;
  text-decoration: none;
  transition: color 0.2s;
}
.site-footer a:hover { color: #6366f1; }
