/* ============================================================
 * style.css - 种草项目后台管理系统 · 响应式样式
 * 适配手机、平板、电脑工作台
 * ============================================================ */

/* ---- CSS 变量 ---- */
:root {
  --primary: #4f46e5;
  --primary-light: #eef2ff;
  --primary-dark: #4338ca;
  --success: #10b981;
  --success-light: #ecfdf5;
  --warning: #f59e0b;
  --warning-light: #fffbeb;
  --danger: #ef4444;
  --danger-light: #fef2f2;
  --info: #3b82f6;
  --info-light: #eff6ff;
  --purple: #8b5cf6;
  --purple-light: #f5f3ff;

  --bg: #f1f5f9;
  --bg-card: #ffffff;
  --bg-hover: #f8fafc;
  --text: #1e293b;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --border: #e2e8f0;
  --border-light: #f1f5f9;

  --sidebar-w: 220px;
  --sidebar-w-collapsed: 64px;
  --header-h: 56px;
  --radius: 8px;
  --radius-sm: 6px;
  --radius-lg: 12px;
  --shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.08), 0 2px 4px -2px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.04);
  --transition: all 0.2s ease;
}

/* ---- Reset ---- */
* { margin: 0; padding: 0; box-sizing: border-box; }
[v-cloak] { display: none !important; }
html, body { height: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--primary); text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 14px; }

/* ---- 滚动条 ---- */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
::-webkit-scrollbar-track { background: transparent; }

/* ---- 布局 ---- */
.app-layout { display: flex; min-height: 100vh; }

/* ---- 侧边栏 ---- */
.sidebar {
  width: var(--sidebar-w);
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  transition: var(--transition);
}
.sidebar-logo {
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 18px;
  border-bottom: 1px solid var(--border);
  font-weight: 700;
  font-size: 15px;
  color: var(--primary);
  white-space: nowrap;
  overflow: hidden;
}
.sidebar-logo .logo-icon {
  width: 32px; height: 32px;
  background: linear-gradient(135deg, var(--primary), var(--purple));
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 16px; flex-shrink: 0;
}
.sidebar-nav { flex: 1; padding: 12px 10px; overflow-y: auto; }
.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 2px;
  white-space: nowrap;
  font-size: 14px;
}
.nav-item:hover { background: var(--bg-hover); color: var(--text); }
.nav-item.active { background: var(--primary-light); color: var(--primary); font-weight: 600; }
.nav-icon { width: 20px; text-align: center; flex-shrink: 0; font-size: 16px; }
.sidebar-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: var(--text-light);
  white-space: nowrap;
  overflow: hidden;
}

/* ---- 主内容区 ---- */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-w);
  display: flex;
  flex-direction: column;
  min-width: 0;
  transition: var(--transition);
}

/* ---- 顶栏 ---- */
.topbar {
  height: var(--header-h);
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  position: sticky;
  top: 0;
  z-index: 50;
}
.topbar-left { display: flex; align-items: center; gap: 12px; }
.topbar-title { font-size: 16px; font-weight: 600; }
.topbar-right { display: flex; align-items: center; gap: 10px; }
.user-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: var(--primary-light);
  border-radius: 16px;
  font-size: 13px;
}
.hamburger {
  display: none;
  width: 36px; height: 36px;
  border-radius: var(--radius-sm);
  align-items: center; justify-content: center;
  font-size: 20px;
  color: var(--text);
}
.hamburger:hover { background: var(--bg-hover); }

/* ---- 内容容器 ---- */
.page-content { padding: 20px; flex: 1; }

/* ---- 指标卡片 ---- */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.metric-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
  transition: var(--transition);
}
.metric-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.metric-card .mc-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 6px;
  display: flex; align-items: center; gap: 6px;
}
.metric-card .mc-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}
.metric-card .mc-sub {
  font-size: 11px;
  color: var(--text-light);
  margin-top: 4px;
}
.metric-card .mc-icon {
  width: 32px; height: 32px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  float: right;
}
.mc-icon.bg-primary { background: var(--primary-light); color: var(--primary); }
.mc-icon.bg-success { background: var(--success-light); color: var(--success); }
.mc-icon.bg-warning { background: var(--warning-light); color: var(--warning); }
.mc-icon.bg-info { background: var(--info-light); color: var(--info); }
.mc-icon.bg-purple { background: var(--purple-light); color: var(--purple); }
.mc-icon.bg-danger { background: var(--danger-light); color: var(--danger); }

/* ---- 通用面板 ---- */
.panel {
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
  margin-bottom: 20px;
  overflow: hidden;
}
.panel-header {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
.panel-title { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.panel-body { padding: 18px; }

/* ---- 筛选栏 ---- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-light);
}
.filter-bar .search-box {
  flex: 1;
  min-width: 180px;
  position: relative;
}
.filter-bar .search-box input {
  width: 100%;
  padding: 8px 12px 8px 34px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  transition: var(--transition);
}
.filter-bar .search-box input:focus {
  outline: none;
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(79,70,229,0.1);
}
.filter-bar .search-box .search-icon {
  position: absolute;
  left: 10px; top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  font-size: 14px;
}
.filter-select {
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}
.filter-select:focus { outline: none; border-color: var(--primary); }

/* ---- 表格 ---- */
.table-wrap { overflow-x: auto; }
table.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
table.data-table th {
  text-align: left;
  padding: 10px 14px;
  background: var(--bg);
  color: var(--text-muted);
  font-weight: 600;
  white-space: nowrap;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
}
table.data-table th.sortable { cursor: pointer; user-select: none; }
table.data-table th.sortable:hover { color: var(--primary); }
table.data-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-light);
  white-space: nowrap;
}
table.data-table tbody tr:hover { background: var(--bg-hover); }
table.data-table tbody tr:last-child td { border-bottom: none; }
.td-num { text-align: right; font-variant-numeric: tabular-nums; }
.td-link { color: var(--primary); cursor: pointer; }
.td-link:hover { text-decoration: underline; }

/* ---- 徽章 ---- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-stage-未开始 { background: #f1f5f9; color: #64748b; }
.badge-stage-测试期 { background: #dbeafe; color: #2563eb; }
.badge-stage-种草期 { background: #dbeafe; color: #2563eb; }
.badge-stage-爆发期 { background: #fef3c7; color: #d97706; }
.badge-stage-长尾期 { background: #ede9fe; color: #7c3aed; }
.badge-stage-已完成 { background: #d1fae5; color: #059669; }
.badge-platform-抖音 { background: #fce7f3; color: #db2777; }
.badge-platform-小红书 { background: #fee2e2; color: #dc2626; }
.badge-platform-B站 { background: #dbeafe; color: #2563eb; }
.badge-platform-快手 { background: #fef3c7; color: #d97706; }
.badge-platform-微博 { background: #fee2e2; color: #dc2626; }
.badge-status-待合作 { background: #f1f5f9; color: #64748b; }
.badge-status-已合作 { background: #dbeafe; color: #2563eb; }
.badge-status-已发布 { background: #fef3c7; color: #d97706; }
.badge-status-已回收 { background: #d1fae5; color: #059669; }

/* ---- 按钮 ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  transition: var(--transition);
  white-space: nowrap;
  border: 1px solid transparent;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-outline { background: #fff; color: var(--text); border-color: var(--border); }
.btn-outline:hover { background: var(--bg-hover); border-color: var(--text-light); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #dc2626; }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-icon {
  width: 30px; height: 30px;
  padding: 0;
  justify-content: center;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
}
.btn-icon:hover { background: var(--bg-hover); color: var(--text); }
.btn-icon.text-danger:hover { color: #fff; background: var(--danger); }
.btn-icon.text-danger { color: var(--danger); font-size: 16px; }

/* ---- 进度条 ---- */
.progress-bar {
  width: 80px;
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
}
.progress-bar .fill { height: 100%; border-radius: 3px; transition: width 0.3s; }
.progress-bar .fill.stage-测试期 { background: #94a3b8; }
.progress-bar .fill.stage-种草期 { background: #3b82f6; }
.progress-bar .fill.stage-爆发期 { background: #f59e0b; }
.progress-bar .fill.stage-长尾期 { background: #8b5cf6; }
.progress-bar .fill.stage-已完成 { background: #10b981; }

/* ---- 图表容器 ---- */
.chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}
.chart-container { width: 100%; height: 300px; }
.chart-container-lg { width: 100%; height: 360px; }
.chart-container-sm { width: 100%; height: 240px; }

/* ---- 模态框 ---- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 200;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 40px 16px;
  overflow-y: auto;
}
.modal {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 640px;
  margin-bottom: 40px;
}
.modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-title { font-size: 16px; font-weight: 600; }
.modal-body { padding: 20px; max-height: 60vh; overflow-y: auto; }
.modal-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* ---- Toast ---- */
.toast-container {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  pointer-events: none;
}
.toast {
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  animation: toastIn 0.3s ease, toastOut 0.3s ease 1.7s forwards;
  pointer-events: auto;
  white-space: nowrap;
}
.toast-success { background: #10b981; }
.toast-error { background: #ef4444; }
.toast-info { background: #3b82f6; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes toastOut { from { opacity: 1; } to { opacity: 0; transform: translateY(-12px); } }
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group.full { grid-column: 1 / -1; }
.form-label { font-size: 13px; font-weight: 500; color: var(--text); }
.form-label .req { color: var(--danger); }
.form-input, .form-select, .form-textarea {
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--text);
  transition: var(--transition);
  width: 100%;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(79,70,229,0.1);
}
.form-textarea { resize: vertical; min-height: 70px; }
.form-hint { font-size: 12px; color: var(--text-light); }

/* ---- 分页 ---- */
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  border-top: 1px solid var(--border-light);
  flex-wrap: wrap;
  gap: 10px;
}
.pagination-info { font-size: 13px; color: var(--text-muted); }
.pagination-controls { display: flex; gap: 4px; }
.page-btn {
  min-width: 32px; height: 32px;
  padding: 0 8px;
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px;
  color: var(--text-muted);
  transition: var(--transition);
}
.page-btn:hover { background: var(--bg-hover); color: var(--text); }
.page-btn.active { background: var(--primary); color: #fff; }
.page-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* ---- 看板卡片 ---- */
.kanban-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}
.kanban-col {
  background: var(--bg);
  border-radius: var(--radius);
  padding: 10px;
  min-height: 100px;
}
.kanban-col-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  padding: 4px 6px;
}
.kanban-col-title { font-size: 13px; font-weight: 600; }
.kanban-col-count {
  background: #fff;
  border-radius: 10px;
  padding: 1px 8px;
  font-size: 12px;
  color: var(--text-muted);
}
.kanban-card {
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-bottom: 8px;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: var(--transition);
  border-left: 3px solid transparent;
}
.kanban-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.kanban-card.stage-测试期 { border-left-color: #94a3b8; }
.kanban-card.stage-种草期 { border-left-color: #3b82f6; }
.kanban-card.stage-爆发期 { border-left-color: #f59e0b; }
.kanban-card.stage-长尾期 { border-left-color: #8b5cf6; }
.kanban-card.stage-已完成 { border-left-color: #10b981; }
.kanban-card .kc-name { font-size: 13px; font-weight: 600; margin-bottom: 4px; }
.kanban-card .kc-meta { font-size: 11px; color: var(--text-muted); display: flex; flex-wrap: wrap; gap: 8px; }
.kanban-card .kc-manager { font-size: 11px; color: var(--text-light); margin-top: 4px; }

/* ---- 空状态 ---- */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-light);
}
.empty-state .es-icon { font-size: 40px; margin-bottom: 10px; }

/* ---- 标签页 ---- */
.tabs {
  display: flex;
  gap: 4px;
  border-bottom: 2px solid var(--border);
  margin-bottom: 16px;
}
.tab {
  padding: 8px 16px;
  font-size: 14px;
  color: var(--text-muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: var(--transition);
  white-space: nowrap;
}
.tab:hover { color: var(--text); }
.tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }

/* ---- 信息行 ---- */
.info-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-light);
}
.info-row:last-child { border-bottom: none; }
.info-label { color: var(--text-muted); }
.info-value { font-weight: 500; }

/* ---- 遮罩（移动端侧边栏） ---- */
.overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.3);
  z-index: 99;
}

/* ---- 登录页面 ---- */
.login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: linear-gradient(135deg, #eef2ff 0%, #f5f3ff 50%, #ecfdf5 100%);
  padding: 20px;
}
.login-card {
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 40px;
  width: 100%;
  max-width: 400px;
  text-align: center;
}
.login-logo {
  font-size: 48px;
  margin-bottom: 12px;
}
.login-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}
.login-sub {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 24px;
}
.login-error {
  background: var(--danger-light);
  color: var(--danger);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  margin-bottom: 12px;
  text-align: left;
}
.login-hint {
  font-size: 12px;
  color: var(--text-light);
  margin-top: 14px;
}
.login-page .form-group {
  margin-bottom: 14px;
  text-align: left;
}

/* ---- 统计行 ---- */
.stats-inline {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  padding: 10px 18px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  margin-bottom: 14px;
}
.stats-inline .si-item { font-size: 13px; }
.stats-inline .si-label { color: var(--text-muted); }
.stats-inline .si-value { font-weight: 600; color: var(--text); margin-left: 4px; }

/* ============================================================
 * 响应式 · 平板
 * ============================================================ */
@media (max-width: 1024px) {
  .kanban-grid { grid-template-columns: repeat(3, 1fr); }
  .chart-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
}

/* ============================================================
 * 新组件样式 · 趋势/进度/协同
 * ============================================================ */

/* 页面 Hero */
.page-hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 14px;
}
.hero-title { font-size: 22px; font-weight: 700; color: var(--text); }
.hero-sub { font-size: 13px; color: var(--text-muted); margin-top: 4px; }

/* 在线协作者 */
.online-team {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-card);
  padding: 6px 12px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
}
.ot-label { font-size: 12px; color: var(--text-muted); }
.ot-avatars { display: flex; }
.ot-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  margin-left: -8px;
  border: 2px solid var(--bg-card);
  position: relative;
  cursor: pointer;
  transition: var(--transition);
}
.ot-avatar:first-child { margin-left: 0; }
.ot-avatar:hover { transform: translateY(-2px); z-index: 2; }
.ot-avatar .ot-dot {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 8px;
  height: 8px;
  background: var(--success);
  border: 1.5px solid var(--bg-card);
  border-radius: 50%;
}

/* 指标趋势列表 */
.trend-list {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.trend-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  gap: 4px;
}
.trend-period { color: var(--text-muted); flex-shrink: 0; width: 28px; }
.trend-num { font-weight: 600; color: var(--text); flex: 1; text-align: right; }
.trend-pct {
  font-weight: 600;
  font-size: 11px;
  flex-shrink: 0;
  min-width: 50px;
  text-align: right;
}
.trend-pct.up { color: var(--success); }
.trend-pct.down { color: var(--danger); }

/* 进度列表 */
.progress-list { margin-bottom: 14px; }
.progress-list:last-child { margin-bottom: 0; }
.progress-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 5px;
}
.progress-label { display: flex; align-items: center; gap: 6px; }
.progress-pct { font-weight: 600; font-size: 12px; color: var(--text-muted); }
.progress-pct.achieved { color: var(--success); }
.progress-bar-lg {
  width: 100%;
  height: 8px;
  background: var(--border);
  border-radius: 4px;
  overflow: hidden;
}
.progress-bar-lg .fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.4s ease;
}

/* 看板卡片 */
.kc-progress { display: flex; align-items: center; gap: 6px; margin-top: 6px; }
.kc-progress .progress-bar { flex: 1; }
.kc-pct { font-size: 11px; font-weight: 600; color: var(--text-muted); white-space: nowrap; }
.kc-pct.achieved { color: var(--success); }
.kc-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 6px;
}
.kc-author { font-size: 14px; display: inline-flex; align-items: center; }
.kc-comments {
  font-size: 11px;
  color: var(--info);
  background: var(--info-light);
  padding: 1px 5px;
  border-radius: 8px;
}

/* 更新人头像 */
.upd-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  background: var(--bg);
  border-radius: 50%;
  font-size: 13px;
  cursor: help;
}

/* 备注列表 */
.comment-list { display: flex; flex-direction: column; gap: 12px; }
.comment-item { display: flex; gap: 10px; }
.ci-avatar {
  width: 32px;
  height: 32px;
  background: var(--bg);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}
.ci-body { flex: 1; }
.ci-meta { font-size: 12px; margin-bottom: 3px; }
.ci-name { font-weight: 600; color: var(--text); }
.ci-time { color: var(--text-light); margin-left: 8px; }
.ci-text {
  font-size: 13px;
  color: var(--text);
  background: var(--bg);
  padding: 6px 10px;
  border-radius: 6px;
}

/* 历史列表 */
.history-list { display: flex; flex-direction: column; gap: 6px; }
.history-item { display: flex; align-items: center; gap: 8px; font-size: 12px; padding: 4px 0; }
.hi-dot {
  width: 6px;
  height: 6px;
  background: var(--primary);
  border-radius: 50%;
  flex-shrink: 0;
}
.hi-user { font-weight: 600; color: var(--text); }
.hi-action { color: var(--text-muted); }
.hi-time { color: var(--text-light); margin-left: auto; }

/* ============================================================
 * 响应式 · 手机
 * ============================================================ */
@media (max-width: 768px) {
  :root { --sidebar-w: 240px; }

  .sidebar {
    transform: translateX(-100%);
    box-shadow: var(--shadow-lg);
  }
  .sidebar.open { transform: translateX(0); }
  .overlay.show { display: block; }

  .main-content { margin-left: 0; }
  .hamburger { display: flex; }
  .topbar { padding: 0 12px; }
  .topbar-title { font-size: 14px; }

  .page-content { padding: 12px; }

  .metrics-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  .metric-card { padding: 12px; }
  .metric-card .mc-value { font-size: 18px; }
  .metric-card .mc-icon { width: 28px; height: 28px; font-size: 14px; }

  .kanban-grid { grid-template-columns: 1fr; }

  .panel-header { padding: 12px 14px; }
  .panel-body { padding: 12px 14px; }

  .filter-bar { padding: 10px 12px; gap: 8px; }
  .filter-bar .search-box { min-width: 100%; }

  table.data-table th, table.data-table td { padding: 8px 10px; font-size: 12px; }

  .modal { max-width: 100%; }
  .modal-body { max-height: 50vh; }

  .form-grid { grid-template-columns: 1fr; }

  .pagination { padding: 10px 12px; }

  .stats-inline { gap: 12px; }
}

/* 移动端调整新组件 */
@media (max-width: 768px) {
  .page-hero { flex-direction: column; align-items: flex-start; }
  .hero-title { font-size: 18px; }
  .online-team { width: 100%; flex-wrap: wrap; }
  .trend-list { font-size: 10px; }
  .trend-pct { min-width: 40px; font-size: 10px; }
  .mc-value { font-size: 18px; }
}

@media (max-width: 480px) {
  .metrics-grid { grid-template-columns: 1fr 1fr; }
  .topbar-title { display: none; }
}

/* ---- 动画 ---- */
.fade-enter-active, .fade-leave-active { transition: opacity 0.2s; }
.fade-enter-from, .fade-leave-to { opacity: 0; }

.modal-enter-active { animation: modalIn 0.25s ease; }
@keyframes modalIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---- 内联编辑 ---- */
.inline-input, .inline-select {
  width: 100%;
  min-width: 60px;
  padding: 2px 6px;
  border: 2px solid var(--primary);
  border-radius: 4px;
  font-size: inherit;
  font-family: inherit;
  background: #fff;
  outline: none;
  box-sizing: border-box;
}
.inline-input:focus, .inline-select:focus { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(79,70,229,0.15); }
td.editable { cursor: pointer; }

/* 推广任务完成情况对比 */
.comparison-table { font-size: 12px; }
.comparison-table th { white-space: nowrap; padding: 8px 6px; font-size: 11px; }
.comparison-table td { padding: 8px 6px; vertical-align: middle; }
.comparison-cell { min-width: 70px; }
.comp-values {
  display: flex;
  align-items: baseline;
  gap: 2px;
  justify-content: flex-end;
  margin-bottom: 3px;
}
.comp-actual { font-weight: 600; font-size: 13px; white-space: nowrap; }
.comp-kpi { font-size: 10px; color: var(--text-muted); white-space: nowrap; }
.comp-bar-sm {
  width: 100%;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 2px;
}
.comp-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 0.3s ease;
}
.progress-bar-sm {
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
  min-width: 40px;
}
.progress-bar-sm .fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.4s ease;
}

/* 文字颜色工具类 */
.text-success { color: var(--success) !important; }
.text-warning { color: var(--warning) !important; }
.text-danger { color: var(--danger) !important; }
.text-muted { color: var(--text-muted) !important; }
.bg-success { background: var(--success) !important; }
.bg-warning { background: var(--warning) !important; }
.bg-danger { background: var(--danger) !important; }
td.editable:hover { background: var(--primary-light); border-radius: 4px; }

/* ---- 批量选择复选框列 ---- */
.td-check { width: 38px; min-width: 38px; text-align: center; padding-left: 8px !important; padding-right: 8px !important; }
.td-check input[type=checkbox] { width: 16px; height: 16px; cursor: pointer; accent-color: var(--primary); vertical-align: middle; }
.badge-product { background:#eef2ff; color:#4338ca; border:1px solid #c7d2fe; border-radius:6px; padding:1px 7px; font-size:11px; line-height:1.7; white-space:nowrap; }

/* ---- 操作日志视图 ---- */
.logs-wrap { padding: 18px 22px; }
.logs-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; justify-content: space-between; margin-bottom: 14px; }
.logs-tip { font-size: 13px; color: var(--text-muted); }
.logs-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; color: var(--text-muted); }
.logs-filters .input-sm { padding: 5px 8px; border: 1px solid var(--border); border-radius: 7px; font-size: 13px; background: #fff; color: var(--text); }
.logs-table-card { background: #fff; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; box-shadow: 0 1px 3px rgba(15,23,42,.04); }
.logs-table-card .table { margin: 0; }
.logs-table-card .table thead th { background: var(--bg-hover); font-size: 12px; color: var(--text-muted); font-weight: 600; white-space: nowrap; }
.logs-table-card .table td { vertical-align: middle; }
.empty-cell { text-align: center; color: var(--text-muted); padding: 36px 0 !important; }
.mem-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: middle; }
.log-action { display: inline-block; padding: 2px 9px; border-radius: 999px; background: var(--primary-light); color: var(--primary-dark); font-size: 12px; font-weight: 600; white-space: nowrap; }
.logs-count { margin-top: 10px; font-size: 12px; color: var(--text-muted); text-align: right; }

/* ---- 视频成长数据 ---- */
.growth-box { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--border); }
.growth-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.growth-title { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.growth-switch { display: inline-flex; background: var(--bg-hover); border-radius: 8px; padding: 2px; }
.gtab { border: none; background: transparent; padding: 5px 14px; font-size: 12px; border-radius: 6px; cursor: pointer; color: var(--text-muted); font-weight: 500; }
.gtab.active { background: #fff; color: var(--primary); font-weight: 600; box-shadow: 0 1px 3px rgba(15,23,42,.08); }
.growth-sum { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; margin-bottom: 14px; }
.gsum-item { background: var(--bg-hover); border: 1px solid var(--border-light); border-radius: 9px; padding: 8px 10px; display: flex; flex-direction: column; gap: 2px; }
.gsum-label { font-size: 11px; color: var(--text-muted); }
.gsum-val { font-size: 16px; font-weight: 700; line-height: 1.2; }
.gsum-diff { font-size: 11px; color: var(--text-muted); font-weight: 600; }
.gsum-diff.up { color: #dc2626; }
.gsum-diff.down { color: #059669; }
.growth-metrics { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.gchip { border: 1px solid var(--border); background: #fff; color: var(--text-muted); border-radius: 999px; padding: 3px 12px; font-size: 12px; cursor: pointer; transition: all .15s; }
.gchip:hover { color: var(--text); border-color: var(--primary); }
.gchip.active { color: #fff; font-weight: 600; }
.growth-table-wrap { max-height: 260px; overflow: auto; border: 1px solid var(--border-light); border-radius: 9px; }
.growth-table { margin: 0; font-size: 12px; }
.growth-table thead th { position: sticky; top: 0; background: var(--bg-hover); z-index: 1; font-size: 11px; white-space: nowrap; }
.growth-table td { padding: 7px 10px; }
.gsrc { display: inline-block; padding: 1px 8px; border-radius: 999px; background: var(--primary-light); color: var(--primary-dark); font-size: 11px; font-weight: 600; }
.grev { display: inline-block; margin-left: 4px; padding: 1px 6px; border-radius: 999px; background: #fef3c7; color: #b45309; font-size: 10px; font-weight: 700; cursor: help; }
.growth-tip { margin-top: 10px; font-size: 11px; color: var(--text-muted); }
.growth-empty { padding: 26px 0; text-align: center; color: var(--text-muted); font-size: 13px; }

/* ===== 单条视频成长趋势弹窗 / 列表留档角标 ===== */
.btn-growth { position: relative; }
.btn-growth .gdot {
  position: absolute; top: -3px; right: -5px; min-width: 15px; height: 15px; padding: 0 3px;
  border-radius: 999px; background: var(--primary); color: #fff;
  font-size: 9px; font-weight: 700; line-height: 15px; text-align: center;
  box-shadow: 0 0 0 1.5px #fff;
}
.gsolo-head { padding-bottom: 12px; border-bottom: 1px solid var(--border); }
.gsolo-title { font-size: 15px; font-weight: 700; color: var(--text); line-height: 1.45; word-break: break-all; }
.gsolo-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px;
  margin-top: 8px; font-size: 12px; color: var(--text-muted);
}
.gsolo-link { color: var(--primary); text-decoration: none; font-weight: 600; }
.gsolo-link:hover { text-decoration: underline; }
.growth-table tr.grow-rev td { background: #fffbeb; color: var(--text-muted); font-size: 11px; }
.growth-table tr.grow-rev td:first-child { padding-left: 18px; color: #b45309; }

/* ===== 团队/达人/产品/个人 看板 ===== */
.progress-bar { display:inline-block; width:90px; height:8px; border-radius:999px; background:var(--border); overflow:hidden; vertical-align:middle; margin-right:6px; }
.progress-bar span { display:block; height:100%; border-radius:999px; background:linear-gradient(90deg,#4f46e5,#10b981); }
.prog-txt { font-size:11px; color:var(--text-muted); }

/* ===== 种草计划日历（对齐进度日历 UI） ===== */
.cal-card { padding: 14px 16px 18px; }
.cal-toolbar { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:10px; margin-bottom:12px; }
.cal-nav { display:flex; align-items:center; gap:10px; }
.cal-title { font-weight:600; font-size:15px; min-width:110px; text-align:center; }
.cal-legend { display:flex; flex-wrap:wrap; gap:12px; }
.cal-legend .lg { display:inline-flex; align-items:center; gap:5px; font-size:12px; color:var(--text-muted); }
.cal-legend .lg i { width:10px; height:10px; border-radius:3px; display:inline-block; }
.cal-grid { display:grid; grid-template-columns: repeat(7, 1fr); gap:6px; }
.cal-dow { text-align:center; font-size:12px; font-weight:600; padding:6px 0; background:#E990AC; color:#fff; border-radius:6px; }
.cal-day { min-height:96px; border:1px solid var(--border); border-radius:8px; padding:6px; background:#F6F6F6; display:flex; flex-direction:column; gap:4px; }
.cal-day.out { background:#fbfbfc; opacity:.6; }
.cal-day.today { border-color:var(--accent); box-shadow:0 0 0 2px rgba(79,70,229,.15); }
.cal-date { font-size:12px; font-weight:600; color:var(--text-muted); }
.cal-day.today .cal-date { color:var(--accent); }
.cal-items { display:flex; flex-direction:column; gap:3px; }
.cal-chip { display:flex; align-items:center; gap:5px; width:100%; text-align:left; border:none; border-left:3px solid #ccc; background:#fff; border-radius:5px; padding:3px 6px; font-size:11px; cursor:pointer; box-shadow:0 1px 2px rgba(0,0,0,.04); overflow:hidden; }
.cal-chip:hover { background:#eef2ff; }
.cc-dot { width:7px; height:7px; border-radius:50%; flex:0 0 auto; }
.cc-txt { white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cal-more { font-size:11px; color:var(--text-muted); text-align:center; }

/* 设计清单里程碑进度条 */
.plan-list thead th { background:#FF8C7A; color:#fff; }
.ms-bar { display:inline-flex; gap:2px; vertical-align:middle; }
.ms-seg { width:8px; height:10px; border-radius:2px; background:var(--border); }
.ms-seg.on { background:var(--accent); }
.ms-txt { font-size:11px; color:var(--text-muted); margin-left:6px; }
.stage-tag { display:inline-block; padding:2px 8px; border-radius:999px; font-size:11px; font-weight:600; }
.status-tag { display:inline-block; padding:2px 10px; border-radius:999px; font-size:11px; font-weight:600; }
.status-tag.done { background:#dcfce7; color:#15803d; }
.status-tag.doing { background:#fef9c3; color:#a16207; }

/* ===== 复盘 ===== */
.growth-sub { font-size:12px; color:var(--text-muted); }
.review-kpis { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; margin-bottom:14px; }
.rkpi { background:#f8fafc; border:1px solid var(--border); border-radius:10px; padding:10px 12px; text-align:center; }
.rkpi-label { display:block; font-size:12px; color:var(--text-muted); }
.rkpi-val { display:block; font-size:20px; font-weight:700; color:var(--accent); margin:2px 0; }
.rkpi-unit { display:block; font-size:11px; color:var(--text-muted); }
.review-form { display:grid; grid-template-columns:1fr 1fr; gap:12px; }

/* ===== 看板互通导航 ===== */
.clickable-row { cursor: pointer; transition: background 0.15s; }
.clickable-row:hover { background: #eff6ff; }
.clickable-row td:first-child { color: var(--accent); font-weight: 600; }
.clickable-row:hover td:first-child { text-decoration: underline; }

/* ===== 排名/评分 ===== */
.rank-cell { width: 32px; text-align: center; font-weight: 700; color: var(--text-muted); }
.score-cell { width: 52px; text-align: center; font-weight: 700; color: var(--accent); }
.num-cell { font-variant-numeric: tabular-nums; text-align: right; }
.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
.sortable:hover { color: var(--accent); }

/* ===== 看板时间切换 ===== */
.period-toggle { display: flex; align-items: center; gap: 6px; }
.period-toggle select { margin-left: 4px; }

/* ===== 单视频看板卡片 ===== */
.vid-card { background:#fff; border:1px solid var(--border); border-radius:12px; margin-bottom:10px; overflow:hidden; transition:box-shadow .15s; }
.vid-card:hover { box-shadow:0 2px 12px rgba(0,0,0,.06); }
.vc-header { display:flex; align-items:center; justify-content:space-between; padding:12px 16px; cursor:pointer; background:#fafbfc; border-bottom:1px solid var(--border); gap:12px; }
.vc-header:hover { background:#f0f4ff; }
.vc-hleft { display:flex; align-items:center; gap:8px; min-width:0; flex:1; }
.vc-expand { font-size:10px; color:var(--text-muted); width:16px; flex-shrink:0; }
.vc-title { font-weight:600; font-size:14px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.vc-stage-tag { font-size:11px; color:#fff; padding:1px 8px; border-radius:10px; white-space:nowrap; flex-shrink:0; }
.vc-hright { display:flex; gap:12px; flex-shrink:0; }
.vc-meta { font-size:12px; color:var(--text-muted); white-space:nowrap; }

.vc-body-top { padding:12px 16px 8px; }
.vc-metrics { display:flex; gap:12px; flex-wrap:wrap; margin-bottom:10px; }
.vcm-item { display:flex; flex-direction:column; align-items:center; background:#f8fafc; border-radius:8px; padding:6px 12px; min-width:64px; }
.vcm-label { font-size:11px; color:var(--text-muted); }
.vcm-val { font-size:15px; font-weight:700; color:#1e293b; }
.vcm-val.hm { color:var(--accent); }

.vc-costs { display:flex; align-items:center; gap:6px; font-size:12px; margin-bottom:8px; flex-wrap:wrap; }
.vc-cost-label { color:var(--text-muted); }
.vc-cost-item { color:#475569; }
.vc-cost-sep { color:#cbd5e1; }
.vc-cost-total { color:#1e293b; font-weight:600; }
.vc-cost-total b { color:var(--accent); }

.vc-roi-bar { display:flex; gap:16px; font-size:12px; flex-wrap:wrap; align-items:center; }
.vc-roi-bar span { color:#64748b; }
.vc-roi-bar b { color:#1e293b; }
.vc-growth-indicator { margin-left:auto; }
.c-green { color:#16a34a !important; }
.c-amber { color:#d97706 !important; }
.c-red { color:#dc2626 !important; }
.c-gray { color:#94a3b8 !important; }

.vc-body-expand { padding:0 16px 14px; border-top:1px dashed var(--border); }
.vc-section { margin-top:12px; }
.vc-sec-title { font-size:13px; font-weight:600; margin-bottom:8px; color:#334155; }
.vc-review-grid { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.vc-review-item { display:flex; flex-direction:column; gap:3px; }
.vc-review-item.full { grid-column:1/-1; }
.vcr-label { font-size:11px; color:var(--text-muted); }
.vcr-val { font-size:13px; font-weight:600; color:#1e293b; }
.vcr-val.爆款 { color:#16a34a; }
.vcr-val.达标 { color:#2563eb; }
.vcr-val.普通 { color:#64748b; }
.vcr-val.翻车 { color:#dc2626; }
.vcr-text { font-size:12px; color:#475569; line-height:1.5; }
.vc-actions { display:flex; gap:8px; margin-top:12px; }
.review-form .form-group-full { grid-column:1 / -1; }

/* ===== 种草节奏时间轴 ===== */
.tl-wrap { overflow-x:auto; font-size:12px; }
.tl-header, .tl-footer { border-bottom:1px dashed var(--border); }
.tl-footer { border-bottom:none; border-top:1px dashed var(--border); }
.tl-name-col { width:130px; flex-shrink:0; padding:3px 6px 3px 0; display:flex; align-items:center; gap:4px; font-size:11px; }
.tl-bar-col { flex:1; min-width:500px; position:relative; }
.tl-months-bar { display:flex; height:22px; align-items:center; }
.tl-month-cell { text-align:center; font-size:10px; color:var(--text-muted); border-left:1px solid var(--border); padding:2px 0; overflow:hidden; text-overflow:ellipsis; }
.tl-body { position:relative; }
.tl-row { display:flex; align-items:center; margin:2px 0; position:relative; }
.tl-lvl { font-size:9px; color:#fff; padding:0 4px; border-radius:3px; font-weight:700; flex-shrink:0; min-width:18px; text-align:center; }
.tl-prod-name { white-space:nowrap; overflow:hidden; text-overflow:ellipsis; font-size:11px; }
.tl-track { position:relative; height:26px; background:#f8fafc; border-radius:3px; width:100%; }
.tl-bar { position:absolute; top:4px; height:18px; border-radius:4px; min-width:4px; display:flex; align-items:center; color:#fff; font-size:9px; cursor:default; transition:filter .15s; }
.tl-bar:hover { filter:brightness(0.85); z-index:2; }
.tl-start, .tl-fin { font-size:8px; margin:0 1px; opacity:0.8; flex-shrink:0; }
.tl-bar-label { padding:0 3px; white-space:nowrap; overflow:hidden; }
.tl-bar-end { margin-left:auto; padding:0 3px; white-space:nowrap; }
.tl-legend { display:flex; gap:12px; flex-wrap:wrap; }
.tl-lg { font-size:11px; display:flex; align-items:center; gap:4px; }
.tl-lg i { width:12px; height:12px; border-radius:2px; display:inline-block; }
