/* ===== 幻想社运营后台 SSR 版样式（对照 React 原版 AdminLayout 设计语言） ===== */
/* 布局：左侧蓝色渐变侧边栏 + 右侧白色内容区（跟原版一致） */
/* 配色：品牌蓝 #1A5FAD + 金色 #F5C518 + 白底内容区 */

/* 字体改用系统栈：Google Fonts 在境内加载缓慢曾导致每次跳转长时间半渲染（闪屏根因），2026-08-27 移除 */

:root {
  /* 品牌色（对照 React 版 index.css :root） */
  --brand-blue: #1A5FAD;
  --brand-blue-light: #4F94DD;
  --brand-blue-dark: #0E3F7C;
  --brand-blue-deep: hsl(212 76% 38%);
  --brand-blue-mid: hsl(212 76% 42%);
  --brand-blue-bright: hsl(212 80% 48%);
  --brand-gold: #F5C518;
  --brand-gold-light: #F8DA70;
  --brand-gold-dark: #D9A409;

  /* 中性色 */
  --bg: hsl(210 40% 98%);
  --card-bg: #ffffff;
  --text-primary: hsl(215 25% 15%);
  --text-secondary: hsl(215 16% 47%);
  --text-muted: hsl(215 16% 65%);
  --border: hsl(212 30% 90%);
  --border-light: hsl(212 30% 95%);

  /* 圆角 */
  --radius: 10px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  /* 阴影 */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04), 0 0 0 1px rgba(0,0,0,0.02);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 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);
  --shadow-brand: 0 4px 14px -2px rgba(26,95,173,0.25);
  --shadow-gold: 0 4px 14px -2px rgba(245,197,24,0.3);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: var(--brand-blue); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--brand-blue-light); }

/* ===== 整体布局（左侧侧边栏 + 右侧内容，跟原版一致） ===== */
.admin-layout {
  display: flex;
  min-height: 100vh;
  background: var(--bg);
}

/* ===== 左侧侧边栏（蓝色渐变，对照原版 aside，缩短四分之一） ===== */
.admin-sidebar {
  width: 192px;
  height: 100vh;
  position: sticky;
  top: 0;
  flex-shrink: 0;
  background: linear-gradient(to bottom, hsl(212 76% 38%), hsl(212 76% 42%), hsl(212 80% 48%));
  color: white;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  z-index: 40;
}

/* 侧边栏装饰（对照原版：金色光晕 + 五线谱） */
.admin-sidebar-decor {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.admin-sidebar-decor .gold-glow {
  position: absolute;
  top: -80px; right: -80px;
  width: 192px; height: 192px;
  border-radius: 50%;
  background: var(--brand-gold);
  opacity: 0.08;
  filter: blur(48px);
}
.admin-sidebar-decor .white-glow {
  position: absolute;
  bottom: 80px; left: -40px;
  width: 128px; height: 128px;
  border-radius: 50%;
  background: white;
  opacity: 0.04;
  filter: blur(32px);
}
.admin-sidebar-decor .staff-lines {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 48px;
  opacity: 0.06;
}

/* Logo 区 */
.sidebar-logo {
  position: relative;
  padding: 20px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.sidebar-logo-link {
  display: flex;
  align-items: center;
  gap: 12px;
}
.sidebar-logo-icon {
  width: 40px; height: 40px;
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(255,255,255,0.2), rgba(255,255,255,0.08));
  border: 1px solid rgba(255,255,255,0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: white;
  font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.sidebar-logo-text {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: white;
}
.sidebar-logo-sub {
  font-size: 9px;
  letter-spacing: 0.3em;
  color: rgba(255,255,255,0.55);
  font-weight: 500;
  margin-top: 2px;
}

/* 导航菜单 */
.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 16px 12px;
  position: relative;
}
.sidebar-nav::-webkit-scrollbar { width: 4px; }
.sidebar-nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 2px; }

.sidebar-nav-section {
  font-size: 10px;
  letter-spacing: 0.15em;
  color: rgba(255,255,255,0.35);
  text-transform: uppercase;
  padding: 12px 12px 6px;
  font-weight: 600;
}

.sidebar-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,0.7);
  transition: all 0.2s;
  position: relative;
  margin-bottom: 2px;
}
.sidebar-nav-item:hover {
  background: rgba(255,255,255,0.08);
  color: white;
}
.sidebar-nav-item.active {
  background: rgba(255,255,255,0.12);
  color: white;
  font-weight: 600;
}
.sidebar-nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 20px;
  border-radius: 0 2px 2px 0;
  background: white;
}
.sidebar-nav-item .icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  opacity: 0.8;
}

/* 可展开父级菜单（对照原版 openMenu） */
.nav-group {
  margin-bottom: 2px;
}
.nav-parent {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}
.nav-arrow {
  font-size: 10px;
  transition: transform 0.2s;
  opacity: 0.6;
}
.nav-group:not(.nav-group-open) .nav-arrow {
  transform: rotate(-90deg);
}
.nav-children {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.2s ease;
  padding-left: 16px;
}
.nav-group-open .nav-children {
  max-height: 200px;
}
.nav-child {
  font-size: 13px;
  padding: 8px 12px;
  color: rgba(255,255,255,0.55);
}
.nav-child:hover {
  color: rgba(255,255,255,0.9);
}
.nav-child.active {
  color: white;
}
.sidebar-nav-item.active .icon {
  color: white;
  opacity: 1;
}

/* 侧边栏底部用户区 */
.sidebar-footer {
  position: relative;
  padding: 16px 20px;
  border-top: 1px solid rgba(255,255,255,0.08);
}
.sidebar-user {
  display: flex;
  align-items: center;
  gap: 10px;
}
.sidebar-user-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 600;
  color: white;
  flex-shrink: 0;
}
.sidebar-user-info {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
}
.sidebar-user-name {
  font-size: 13px;
  font-weight: 600;
  color: white;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar-user-role {
  font-size: 11px;
  color: rgba(255,255,255,0.5);
  display: inline;
  margin-left: 6px;
}
.sidebar-logout {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  padding: 6px 10px;
  border-radius: 6px;
  transition: all 0.2s;
}
.sidebar-logout:hover {
  color: #ef4444;
  background: rgba(239,68,68,0.1);
}

/* ===== 右侧内容区（白底，对照原版 main） ===== */
.admin-main {
  flex: 1;
  min-width: 0;
  padding: 24px 32px;
  max-width: calc(100vw - 192px);
}

/* 页面标题 */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}
.page-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.page-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* ===== 运营页白色卡片包裹（对照原版 rounded-xl bg-white border） ===== */
.ops-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 16px;
}
.ops-header {
  background: linear-gradient(to right, var(--brand-blue-deep), var(--brand-blue-bright));
  padding: 16px 20px;
  position: relative;
  overflow: hidden;
}
.ops-header::before {
  content: '';
  position: absolute;
  right: -20px; top: -20px;
  width: 200px; height: 200px;
  border-radius: 50%;
  background: var(--brand-gold);
  opacity: 0.08;
  filter: blur(40px);
  pointer-events: none;
}
.ops-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}
.ops-tabs {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.ops-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  border-radius: 9999px;
  border: 2px solid rgba(255,255,255,0.3);
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(4px);
  color: white;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s;
}
.ops-tab:hover {
  background: rgba(255,255,255,0.2);
}
.ops-tab.active {
  background: var(--brand-gold);
  color: var(--brand-blue-dark);
  border-color: var(--brand-gold);
  font-weight: 600;
  box-shadow: 0 4px 14px -2px rgba(245,197,24,0.6);
}
.ops-tab-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
.ops-updated {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 9999px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.85);
  font-size: 11px;
}
.ops-updated-icon {
  width: 14px;
  height: 14px;
}
.ops-body {
  padding: 16px 20px;
}
/* 三级标题（运营 pill tab + 月份/导出） */
.ops-sub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  min-width: 0;
  margin-bottom: 16px;
}
.ops-sub-tabs {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  background: hsl(212 30% 95%);
  padding: 4px;
  border-radius: var(--radius);
}
.ops-sub-tab {
  padding: 6px 12px;
  font-size: 12px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.15s;
}
.ops-sub-tab:hover {
  background: rgba(255,255,255,0.5);
}
.ops-sub-tab.active {
  background: var(--brand-blue);
  color: white;
}
.ops-sub-tab-gold.active {
  background: var(--brand-gold);
  color: var(--brand-blue-dark);
}
.ops-sub-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}
.ops-sub-right > form {
  margin: 0;
  line-height: 0;
}
.ops-sync-form {
  display: flex;
  align-items: center;
}
.ops-month-select {
  height: 36px;
  box-sizing: border-box;
  padding: 0 8px;
  font-size: 13px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  cursor: pointer;
}
.ops-export-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 36px;
  box-sizing: border-box;
  padding: 0 12px;
  font-size: 12px;
  border-radius: var(--radius-sm);
  background: linear-gradient(to right, var(--brand-blue-deep), var(--brand-blue-bright));
  color: white;
  text-decoration: none;
  font-weight: 500;
}
.ops-export-icon {
  width: 14px;
  height: 14px;
}
/* KPI 4 卡片 */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}
.kpi-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}
.kpi-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.kpi-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--brand-blue-deep);
  font-variant-numeric: tabular-nums;
}
.kpi-unit {
  font-size: 14px;
  font-weight: 400;
  color: var(--text-muted);
}
.kpi-sub {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}
/* 表格容器 */
.ops-table-wrap {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.ops-section-title {
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border);
}
/* 空状态 */
.ops-empty {
  text-align: center;
  padding: 40px 16px;
  color: var(--text-muted);
  font-size: 14px;
}
.ops-empty-sub {
  font-size: 12px;
  margin-top: 6px;
}
/* 运营宝典卡片 */
.playbook-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.playbook-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  background: white;
}
.playbook-card-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
}
.playbook-card-desc {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.playbook-card-body {
  font-size: 12px;
  color: var(--text-secondary);
}
.playbook-rose .playbook-card-title { color: #e11d48; }
.playbook-blue .playbook-card-title { color: #2563eb; }
.playbook-purple .playbook-card-title { color: #9333ea; }

/* ===== Tab 横幅（蓝色渐变，所有页统一大小/位置） ===== */
.tab-banner {
  background: linear-gradient(to right, var(--brand-blue-deep), var(--brand-blue-mid), var(--brand-blue-bright));
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  position: relative;
  overflow: hidden;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  box-shadow: 0 4px 16px -4px rgba(26,95,173,0.3);
}
/* banner 到顶全宽样式已废弃，所有页统一圆角 */
}
/* 内容区（banner 到顶后，其他内容需要 padding） */
.page-body {
  padding: 0;
}
.tab-banner::before {
  content: '';
  position: absolute;
  right: -20px; top: -20px;
  width: 200px; height: 200px;
  border-radius: 50%;
  background: var(--brand-gold);
  opacity: 0.08;
  filter: blur(40px);
  pointer-events: none;
}
.tab-banner::after {
  content: '';
  position: absolute;
  left: -40px; bottom: -40px;
  width: 120px; height: 120px;
  border-radius: 50%;
  background: white;
  opacity: 0.03;
  filter: blur(24px);
  pointer-events: none;
}

.tab-pills {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}
.tab-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.1);
  border: 2px solid rgba(255,255,255,0.3);
  border-radius: 9999px;
  text-decoration: none;
  transition: all 0.25s ease;
  white-space: nowrap;
  backdrop-filter: blur(4px);
}
.tab-pill:hover {
  background: rgba(255,255,255,0.2);
  color: white;
}
.tab-pill.active {
  background: var(--brand-gold);
  color: var(--brand-blue-dark);
  border-color: var(--brand-gold);
  font-weight: 600;
  box-shadow: 0 4px 14px -2px rgba(245,197,24,0.6);
}
/* SVG 图标（内联矢量，对照原版 lucide-react） */
.tab-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  opacity: 0.8;
}
.tab-icon-sm {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  opacity: 0.7;
}
/* 数据更新时间徽章（banner 右侧，对照原版） */
.tab-updated {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 16px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.85);
  font-size: 11px;
  backdrop-filter: blur(4px);
}
/* 内容区操作栏（月份选择/导出按钮移到这里） */
.content-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.tab-pill.active:hover {
  background: var(--brand-gold-dark);
  color: var(--brand-blue-dark);
}

.tab-banner-right {
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
  z-index: 1;
}
.tab-month-select {
  background: rgba(255,255,255,0.1);
  color: white;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  outline: none;
  cursor: pointer;
  font-family: inherit;
}
.tab-month-select option { color: var(--text-primary); background: white; }
.tab-export-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  border-radius: 8px;
  background: white;
  color: var(--brand-blue-deep);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  border: 1px solid rgba(255,255,255,0.3);
}
.tab-export-btn:hover {
  background: rgba(255,255,255,0.95);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(255,255,255,0.2);
}

/* ===== 卡片（白色 + 圆角 + 阴影，对照原版 Card 组件） ===== */
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s;
}
.card:hover {
  box-shadow: var(--shadow-md);
}
.card-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-light);
}

/* ===== 统计卡片网格 ===== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.stat-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s;
}
.stat-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}
.stat-label {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 6px;
  font-weight: 500;
}
.stat-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--brand-blue);
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
  letter-spacing: -0.02em;
}
.stat-unit {
  font-size: 14px;
  color: var(--text-secondary);
  margin-left: 4px;
  font-weight: 400;
}
.stat-hint {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* ===== 欢迎横幅（蓝色渐变 + 金色数字，对照原版欢迎卡片） ===== */
.welcome-banner {
  background: linear-gradient(135deg, var(--brand-blue-deep), var(--brand-blue-mid));
  border-radius: var(--radius-xl);
  padding: 22px 28px;
  position: relative;
  overflow: hidden;
  margin-bottom: 20px;
  color: white;
  box-shadow: 0 8px 24px -8px rgba(26,95,173,0.35);
}
.welcome-banner::before {
  content: '';
  position: absolute;
  right: -30px; top: -30px;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: var(--brand-gold);
  opacity: 0.1;
  filter: blur(48px);
}
.welcome-banner::after {
  content: '';
  position: absolute;
  left: -40px; bottom: -40px;
  width: 140px; height: 140px;
  border-radius: 50%;
  background: var(--brand-blue-light);
  opacity: 0.08;
  filter: blur(32px);
}
.welcome-content { position: relative; z-index: 1; }
.welcome-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 12px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.15);
  font-size: 11px;
  color: rgba(255,255,255,0.85);
  backdrop-filter: blur(8px);
}
.welcome-badge .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #34d399;
}
.welcome-title {
  font-size: 18px;
  font-weight: 600;
  margin-top: 10px;
}
.welcome-title .gold {
  color: var(--brand-gold);
  font-size: 24px;
  font-weight: 700;
}
.welcome-desc {
  font-size: 13px;
  color: rgba(255,255,255,0.7);
  margin-top: 6px;
}
.welcome-desc .gold { color: var(--brand-gold); font-weight: 600; }

/* ===== 数据表格（对照原版 shadcn Table） ===== */
/* 不拉满整行，按内容宽度收缩（表内4个字就用4个字宽度） */
.data-table {
  width: auto;
  border-collapse: collapse;
  font-size: 13px;
}
.data-table th {
  background: hsl(212 40% 96%);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 12px;
  padding: 10px 14px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
  letter-spacing: 0.01em;
}
.data-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-primary);
  font-size: 13px;
  white-space: nowrap;
}
.data-table tbody tr {
  transition: background 0.15s;
}
.data-table tbody tr:hover {
  background: hsl(212 40% 98%);
}
.data-table .num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 500;
}
.data-table tr:last-child td {
  border-bottom: none;
}

/* ===== 表单 ===== */
.form-group { margin-bottom: 16px; }
.form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 6px;
  color: var(--text-primary);
}
.form-input {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 1px solid #d0d7de;
  border-radius: 10px;
  font-size: 14px;
  background: white;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
  font-family: inherit;
}
.form-input:focus {
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(26,95,173,0.1);
}
.form-error {
  padding: 10px 14px;
  border-radius: var(--radius);
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #dc2626;
  font-size: 13px;
  margin-bottom: 12px;
}
.form-hint { font-size: 11px; color: var(--text-muted); margin-top: 4px; }

/* ===== 按钮（对照原版 shadcn Button） ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  font-family: inherit;
  white-space: nowrap;
}
.btn-primary {
  background: var(--brand-blue);
  color: white;
  border-color: var(--brand-blue);
}
.btn-primary:hover {
  background: var(--brand-blue-light);
  border-color: var(--brand-blue-light);
  box-shadow: var(--shadow-brand);
}
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-secondary {
  background: white;
  color: var(--text-primary);
  border-color: var(--border);
}
.btn-secondary:hover {
  background: var(--bg);
  border-color: var(--text-muted);
}
.btn-danger {
  background: #ef4444;
  color: white;
  border-color: #ef4444;
}
.btn-danger:hover { background: #dc2626; border-color: #dc2626; }
.btn-gold {
  background: white;
  color: var(--brand-blue-deep);
  border-color: white;
}
.btn-gold:hover {
  background: rgba(255,255,255,0.95);
  box-shadow: 0 2px 8px rgba(255,255,255,0.2);
}
.btn-lg { height: 44px; font-size: 15px; width: 100%; padding: 0 24px; }
.btn-sm { padding: 5px 12px; font-size: 12px; border-radius: var(--radius-sm); }

/* ===== 徽章/状态标签 ===== */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.4;
}
.badge-success { background: #d1fae5; color: #059669; }
.badge-warn { background: #fef2f2; color: #dc2626; }
.badge-warning { background: #fef3c7; color: #b45309; }
.badge-info { background: #dbeafe; color: #0284c7; }
.badge-muted { background: #f1f5f9; color: #64748b; }

/* ===== 空状态 ===== */
.empty-state {
  text-align: center;
  padding: 48px 16px;
  color: var(--text-muted);
  font-size: 14px;
}
.empty-icon {
  width: 24px;
  height: 24px;
  margin: 0 auto 8px;
  color: var(--brand-blue);
  opacity: 0.4;
}
.empty-sub {
  font-size: 12px;
  margin-top: 6px;
  color: var(--text-muted);
}
.empty-state-icon { font-size: 36px; margin-bottom: 10px; opacity: 0.4; }
.empty-state-hint { font-size: 12px; margin-top: 6px; color: var(--text-muted); }

/* ===== 登录页 ===== */
.login-page { min-height: 100vh; display: flex; position: relative; overflow: hidden; }
.login-brand {
  display: none;
  width: 55%; position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--brand-blue-deep), var(--brand-blue-mid), var(--brand-blue-bright));
}
@media (min-width: 1024px) { .login-brand { display: flex; } }
.login-brand-content {
  position: relative; z-index: 10;
  display: flex; flex-direction: column; justify-content: center;
  align-items: flex-end; text-align: right; /* 2026-09-01 用户要求靠右居中 */
  padding: 48px 64px; color: white; width: 100%;
}
.login-brand-content > div:first-child {
  margin-bottom: 28px;
}
.login-brand-content .login-brand-badge { width: fit-content; }
.login-brand-title { font-size: 44px; font-weight: 700; line-height: 1.15; letter-spacing: -0.02em; }
.login-brand-title .gold { color: var(--brand-gold); }
.login-brand-sub { font-size: 16px; color: rgba(255,255,255,0.85); line-height: 1.6; margin-top: 20px; }
.login-brand-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px; border-radius: 16px;
  background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.2);
  font-size: 13px; width: fit-content;
  backdrop-filter: blur(8px);
}
.login-brand-footer { font-size: 13px; color: rgba(255,255,255,0.5); }
.login-form-side { flex: 1; display: flex; align-items: center; justify-content: center; padding: 24px; position: relative; background: var(--bg); }
.login-form-card { width: 100%; max-width: 380px; position: relative; z-index: 10; }

/* ===== 模态弹窗 ===== */
.modal-overlay {
  display: none;
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,0.4);
  z-index: 200;
  align-items: center; justify-content: center;
  backdrop-filter: blur(4px);
}
.modal-overlay.show { display: flex; }
.modal-card {
  background: white;
  border-radius: var(--radius-xl);
  padding: 24px;
  width: 420px;
  max-width: 90%;
  box-shadow: var(--shadow-lg);
}

/* ===== 移动端适配 ===== */
@media (max-width: 1024px) {
  .admin-sidebar { position: fixed; transform: translateX(-100%); transition: transform 0.3s; }
  .admin-sidebar.open { transform: translateX(0); }
  .admin-main { max-width: 100vw; padding: 16px; }
}
@media (max-width: 768px) {
  .data-table { font-size: 12px; display: block; overflow-x: auto; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .tab-banner { padding: 10px 12px; }
}

/* ===== 总览：本月总流水大卡片 ===== */
.overview-revenue-card {
  background: linear-gradient(to right, var(--brand-blue), hsl(212 80% 50%));
  border-radius: var(--radius);
  padding: 20px;
  position: relative;
  overflow: hidden;
  margin-bottom: 16px;
  color: white;
}
.overview-revenue-glow {
  position: absolute;
  right: 0; top: 0;
  width: 192px; height: 192px;
  border-radius: 50%;
  background: var(--brand-gold);
  opacity: 0.15;
  filter: blur(48px);
  pointer-events: none;
}
.overview-revenue-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.2);
  font-size: 11px;
  margin-bottom: 8px;
  position: relative;
}
.overview-revenue-value {
  font-size: 32px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  position: relative;
}
.overview-revenue-unit {
  font-size: 16px;
  font-weight: 400;
  opacity: 0.8;
}

/* ===== 4运营×2列矩阵表 ===== */
.matrix-wrap {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}
.matrix-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.matrix-title-badge {
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: rgba(26,95,173,0.1);
  color: var(--brand-blue);
  font-size: 12px;
  font-weight: 600;
}
.matrix-title-text {
  font-size: 14px;
  color: var(--text-secondary);
}
.matrix-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.matrix-header-row1 th {
  padding: 8px 4px;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  border-bottom: 1px solid var(--border);
  border-left: 1px solid var(--border-light);
}
.matrix-header-row1 th:first-child { border-left: none; }
.matrix-op-name { color: var(--text-primary); }
.matrix-header-row2 th {
  padding: 6px 4px;
  text-align: center;
  font-size: 10px;
  font-weight: 400;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  background: hsl(212 30% 97%);
  border-left: 1px solid var(--border-light);
}
.matrix-header-row2 th:first-child { border-left: none; }
.matrix-row { border-bottom: 1px solid var(--border-light); }
.matrix-row-label {
  padding: 10px 16px 10px 0;
  font-weight: 500;
  font-size: 13px;
  color: var(--text-primary);
}
.matrix-cell {
  padding: 10px 4px;
  text-align: center;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--text-secondary);
  border-left: 1px solid var(--border-light);
}
.matrix-cell-bonus { color: var(--text-muted); }
.matrix-cell-bonus.has-bonus { color: var(--brand-gold-dark); font-weight: 600; }
.matrix-cell-dash { color: var(--text-muted); }
.matrix-row-summary { border-bottom: 1px solid var(--border); }
.matrix-row-gold { background: rgba(245,197,24,0.05); }
.matrix-row-amber { background: rgba(251,191,36,0.06); }
.matrix-row-total { background: rgba(26,95,173,0.04); border-bottom: none; }
.matrix-label-gold { color: var(--brand-gold-dark); font-weight: 600; }
.matrix-label-amber { color: var(--text-primary); font-weight: 600; }
.matrix-label-total { color: var(--brand-blue); font-weight: 700; }

/* 主播投诉行（红色） */
.matrix-row-rose { background: rgba(244,63,94,0.05); }
.matrix-label-rose { color: #e11d48; font-weight: 600; }
.matrix-cell-complaint {
  padding: 10px 4px;
  text-align: center;
  font-size: 11px;
  color: #e11d48;
  border-left: 1px solid var(--border-light);
  word-break: break-all;
}
.matrix-cell-complaint-num {
  padding: 10px 4px;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: #e11d48;
  font-variant-numeric: tabular-nums;
}

/* 总合计行（浅绿底+深绿字，2026-08-29 用户要求） */
.matrix-row-grand {
  background: #dcfce7;
  border-bottom: none;
}
.matrix-label-grand {
  color: #15803d;
  font-weight: 700;
  font-size: 14px;
}
.matrix-cell-grand {
  text-align: center;
  padding: 12px 4px;
  font-size: 16px;
  font-weight: 700;
  color: #15803d;
  font-variant-numeric: tabular-nums;
}

/* ===== 单运营页：总奖金结算卡 ===== */
.op-settle-card {
  background: linear-gradient(to right, rgba(26,95,173,0.05), rgba(245,197,24,0.05));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 16px;
}
.op-settle-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.op-settle-row {
  display: flex;
  align-items: baseline;
  gap: 16px;
  flex-wrap: wrap;
}
.op-settle-total {
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.op-settle-amount {
  font-size: 24px;
  font-weight: 700;
  color: var(--brand-blue);
  font-variant-numeric: tabular-nums;
}
.op-settle-unit {
  font-size: 12px;
  color: var(--text-muted);
}
.op-settle-detail {
  font-size: 14px;
  color: var(--text-secondary);
}
.op-settle-warn {
  color: #e11d48;
  margin-left: 4px;
}
.op-settle-complaint {
  font-size: 12px;
  color: #e11d48;
  margin-top: 6px;
  width: 100%;
}

/* ===== 单运营页：4 KPI 卡片 ===== */
.op-kpi-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1.8fr;
  gap: 10px;
  margin-bottom: 16px;
}
.op-kpi-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 8px;
  min-width: 0;
  overflow: visible;
}
/* 标题行：左 title+current 一组，右 badge（对齐原版 OpCard） */
.op-kpi-card {
  position: relative;
}
.op-kpi-top {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
  min-height: 24px;
  flex-wrap: wrap;
  padding-right: 80px;
}
.op-kpi-title {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(26,95,173,0.10);
  color: var(--brand-blue);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
}
.op-kpi-current {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.op-kpi-target {
  font-size: 11px;
  font-weight: 400;
  color: var(--text-muted);
}
.op-kpi-rule-row {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 8px;
  min-height: 30px;
  line-height: 1.4;
  flex-wrap: wrap;
  padding-right: 80px;
}
.op-kpi-badge {
  position: absolute;
  top: 12px;
  right: 6px;
  min-width: 67px;
  height: 38px;
  padding: 0 10px;
  border-radius: 8px;
  background: rgba(245,197,24,0.18);
  color: var(--brand-gold-dark);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  text-align: center;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(245,197,24,0.25);
}
.op-kpi-rule-label {
  font-size: 10px;
  font-weight: 500;
  color: var(--brand-blue);
  white-space: nowrap;
  opacity: 0.8;
}
.op-kpi-rule-text {
  font-size: 10px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ===== 提成独立区块 ===== */
.commission-block {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}
.commission-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.commission-badge {
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: rgba(245,197,24,0.15);
  color: var(--brand-gold-dark);
  font-size: 12px;
  font-weight: 600;
}
.commission-rule {
  font-size: 12px;
  color: var(--text-muted);
}
.commission-old {
  color: #2563eb;
  font-weight: 500;
}
.commission-new {
  color: #059669;
  font-weight: 500;
}
.commission-warn {
  color: #e11d48;
  margin-left: 8px;
}
.commission-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.commission-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}
.commission-card-old {
  background: rgba(37,99,235,0.04);
}
.commission-card-new {
  background: rgba(5,150,105,0.04);
}
.commission-card-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.commission-card-value {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
}
.commission-card-value-line {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
}
.commission-warn-inline {
  font-size: 11px;
  font-weight: 600;
  color: #dc2626;
  white-space: nowrap;
}
.commission-card-rev-inline {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
  margin-left: 6px;
}

/* ===== 上传数据页 ===== */
.upload-section {
  margin-bottom: 8px;
}
.upload-section-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.upload-section-desc {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
  line-height: 1.5;
}
.upload-stats {
  display: flex;
  gap: 24px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.upload-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.upload-stat-label {
  font-size: 11px;
  color: var(--text-muted);
}
.upload-stat-value {
  font-size: 18px;
  font-weight: 600;
  color: var(--brand-blue);
  font-variant-numeric: tabular-nums;
}
.upload-form {
  display: flex;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}
.upload-mode, .upload-date, .upload-file {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.upload-mode-label {
  font-size: 11px;
  color: var(--text-muted);
}
.upload-select {
  height: 36px;
  width: 120px;
  padding: 0 8px;
  font-size: 13px;
}
.upload-date-input {
  height: 36px;
  width: 160px;
  padding: 0 8px;
  font-size: 13px;
}
.upload-calib-input {
  height: 36px;
  width: 120px;
  padding: 0 8px;
  font-size: 13px;
}
.upload-file-input {
  height: 36px;
  font-size: 13px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0 8px;
  background: white;
}

/* ===== 上传数据页（白色卡片 + 蓝色徽章标题，对照原版 ExcelUploadCard） ===== */
.upload-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}
.upload-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px 8px;
}
.upload-card-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: rgba(26,95,173,0.1);
  color: var(--brand-blue);
  font-size: 12px;
  font-weight: 600;
}
.upload-card-count {
  font-size: 11px;
  color: var(--text-muted);
}
.upload-card-body {
  padding: 8px 20px 20px;
}
.upload-sub-section {
  padding: 8px 0;
}
.upload-sub-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.upload-desc {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
  line-height: 1.5;
}
.upload-headers {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.upload-header-label {
  font-size: 11px;
  color: var(--text-muted);
}
.upload-header-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  background: hsl(212 30% 95%);
  border: 1px solid var(--border-light);
  font-size: 11px;
  color: var(--text-primary);
}
.upload-stats-row {
  display: flex;
  gap: 24px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.upload-divider {
  border-top: 1px solid var(--border);
  margin: 12px 0;
}

/* 上传表单行（所有字段同一行 flex items-end） */
.upload-form-row {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}
.upload-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.upload-field-label {
  font-size: 11px;
  color: var(--text-muted);
}
.upload-field-label.invisible {
  visibility: hidden;
}
.upload-input-sm {
  height: 36px;
  width: 120px;
  padding: 0 8px;
  font-size: 13px;
}
.upload-input-md {
  height: 36px;
  width: 160px;
  padding: 0 8px;
  font-size: 13px;
}
.upload-file-input {
  height: 36px;
  font-size: 13px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0 8px;
  background: white;
  max-width: 240px;
}
.upload-btn {
  height: 36px;
  padding: 0 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: white;
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.upload-btn:hover {
  background: hsl(212 30% 95%);
}

/* 列表只显示5行，其余下滑可见；宽度贴内容，不拉满；表格水平可滚 */
.table-scroll-5 {
  max-height: 200px;
  overflow-y: auto;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  width: fit-content;
  max-width: 100%;
}
.table-scroll-5 table {
  margin: 0;
  width: max-content;
  min-width: 100%;
}
.table-scroll-5 thead {
  position: sticky;
  top: 0;
  z-index: 1;
  background: hsl(212 30% 97%);
}

/* 隐藏原生 file input，用 label 按钮替代（对照原版 hidden + label） */
.upload-file-hidden {
  display: none;
}
.upload-file-label {
  display: inline-flex;
  cursor: pointer;
}
.upload-btn-text {
  pointer-events: none;
}

/* ===== 单运营 KPI 卡片内排行榜 ===== */
.op-ranking {
  margin-top: 8px;
  border-top: 1px solid var(--border-light);
  padding-top: 6px;
}
.op-ranking-header {
  display: grid;
  grid-template-columns: 24px 1fr 90px 90px;
  gap: 6px;
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
  padding: 4px 0;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
  min-height: 24px;
  align-items: center;
}
.op-ranking-header > span {
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.op-ranking-header > span:nth-child(2) { text-align: left; }
.op-ranking-list {
  max-height: 260px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}
.op-ranking-list .op-ranking-header {
  position: sticky;
  top: 0;
  z-index: 2;
  background: white;
}
.op-ranking-row {
  display: grid;
  grid-template-columns: 24px 1fr 90px 90px;
  gap: 6px;
  align-items: center;
  padding: 4px 0;
  font-size: 11px;
  border-bottom: 1px solid var(--border-light);
  min-height: 24px;
  white-space: nowrap;
}
.op-rank-status.is-ok {
  color: #059669;
}
.op-rank-status.is-fail {
  color: #dc2626;
}
.op-ranking-row:last-child { border-bottom: none; }
.op-rank-medal {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  color: white;
  flex-shrink: 0;
  margin: 0 auto;
  min-width: 0;
}
.medal-1 { background: linear-gradient(to bottom right, #fbbf24, #d97706); }
.medal-2 { background: linear-gradient(to bottom right, #cbd5e1, #64748b); }
.medal-3 { background: linear-gradient(to bottom right, #fb923c, #ea580c); }
.medal-n { background: hsl(212 30% 95%); color: var(--text-muted); }
.op-rank-name {
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-left: 2px;
}
.op-rank-val1, .op-rank-val2, .op-rank-status {
  color: var(--text-secondary);
  font-variant-numeric: tabular-nums;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 400;
  line-height: 1;
  min-width: 0;
}
.op-rank-status { color: #059669; font-weight: 700; }
.op-rank-status.is-fail { color: #dc2626; font-weight: 700; }
.op-rank-status:empty { display: none; }
.op-rank-col-rank, .op-rank-col-val1, .op-rank-col-val2, .op-rank-col-status {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
}
.op-rank-col-name {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-left: 2px;
  min-width: 0;
}

/* 每张表自己的列数（总流水3列，达标时长/优质主播4列，新主播5列） */
.op-ranking-3 .op-ranking-header,
.op-ranking-3 .op-ranking-row {
  grid-template-columns: 24px 1fr 90px;
}
.op-ranking-3 .op-rank-col-val2,
.op-ranking-3 .op-rank-col-status { display: none; }

.op-ranking-4 .op-ranking-header,
.op-ranking-4 .op-ranking-row {
  grid-template-columns: 24px 1fr 90px 90px;
}
.op-ranking-4 .op-rank-col-val2 { display: none; }

.op-ranking-5 .op-ranking-header,
.op-ranking-5 .op-ranking-row {
  grid-template-columns: 24px 1fr 90px 70px 90px;
}
.op-ranking-6 .op-ranking-header,
.op-ranking-6 .op-ranking-row {
  grid-template-columns: 18px 1.2fr 1fr 1fr 1fr 1fr;
}
.op-ranking-6 .op-rank-col-val2,
.op-ranking-6 .op-rank-val2 {
  display: flex;
  align-items: center;
  justify-content: center;
}
.op-rank-col-date,
.op-rank-date {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  color: var(--text-secondary);
  font-variant-numeric: tabular-nums;
  font-size: 11px;
}

/* ===== B站日期查看器 ===== */
.bili-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: rgba(26,95,173,0.05);
  border: 1px solid rgba(26,95,173,0.15);
  margin-bottom: 12px;
}
.bili-section-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--brand-blue);
}
.bili-section-hint {
  font-size: 10px;
  color: var(--text-muted);
}
.bili-date-viewer {
  margin-top: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.bili-date-viewer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: hsl(212 30% 97%);
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.bili-date-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-right: 6px;
}
.bili-date-input {
  height: 32px;
  width: 160px;
  padding: 0 8px;
  font-size: 13px;
}
.bili-date-info {
  font-size: 12px;
  color: var(--text-muted);
}

/* ===== 重要提醒页 ===== */
.reminder-section {
  margin-bottom: 24px;
}
.reminder-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.reminder-section-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}
.reminder-section-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
}
.reminder-section-icon {
  width: 14px;
  height: 14px;
}
.reminder-badge-gold {
  background: rgba(245,197,24,0.15);
  color: var(--brand-gold-dark);
}
.reminder-badge-amber {
  background: rgba(251,191,36,0.15);
  color: #b45309;
}
.reminder-badge-blue {
  background: rgba(26,95,173,0.1);
  color: var(--brand-blue);
}
.reminder-badge-green {
  background: rgba(5,150,105,0.1);
  color: #059669;
}
.reminder-section-summary {
  font-size: 12px;
  color: var(--text-muted);
}
.reminder-section-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.reminder-btn-ghost {
  height: 24px;
  padding: 0 8px;
  font-size: 12px;
  color: var(--text-muted);
  text-decoration: none;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.reminder-btn-ghost:hover {
  color: var(--brand-blue);
}
.reminder-btn-blue {
  height: 24px;
  padding: 0 10px;
  font-size: 12px;
  color: white;
  text-decoration: none;
  border-radius: var(--radius-sm);
  background: linear-gradient(to right, var(--brand-blue-deep), var(--brand-blue-bright));
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.reminder-btn-blue:hover {
  opacity: 0.95;
}

/* 日历网格 */
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.calendar-col {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.calendar-col-header {
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  background: hsl(212 30% 97%);
  border-bottom: 1px solid var(--border);
}
.calendar-list {
  max-height: 224px;
  overflow-y: auto;
  padding: 4px;
}
.calendar-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  font-size: 12px;
  color: var(--text-primary);
  border-radius: var(--radius-sm);
}
.calendar-item:hover {
  background: hsl(212 30% 95%);
}
.calendar-item-date {
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
  width: 60px;
}
.calendar-item-type {
  padding: 1px 6px;
  border-radius: var(--radius-sm);
  font-size: 10px;
  font-weight: 500;
  flex-shrink: 0;
}
.cal-type-生日 { background: #fef3c7; color: #b45309; }
.cal-type-周年 { background: #e0f2fe; color: #0369a1; }
.cal-type-节日 { background: #ede9fe; color: #6d28d9; }
.cal-type-敏感日期 { background: #ffe4e6; color: #be123c; }
.cal-type-其他 { background: #d1fae5; color: #047857; }
.cal-type-敏感 { background: #ffe4e6; color: #be123c; }
.cal-type-生日badge { background: #fef3c7; color: #b45309; }
.cal-type-周年badge { background: #e0f2fe; color: #0369a1; }
.cal-type-节日badge { background: #ede9fe; color: #6d28d9; }
.cal-type-其他badge { background: #d1fae5; color: #047857; }
.calendar-item-content {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.calendar-item-op {
  font-size: 10px;
  color: var(--brand-blue);
  flex-shrink: 0;
}
.calendar-empty {
  padding: 24px 12px;
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
}

/* 异常规则卡 */
.anomaly-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.anomaly-rule-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.anomaly-rule-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 16px;
  background: hsl(212 30% 97%);
  border-bottom: 1px solid var(--border);
}
.anomaly-rule-info {
  display: flex;
  align-items: center;
  gap: 8px;
}
.anomaly-rule-title {
  font-size: 14px;
  font-weight: 500;
}
.anomaly-rule-desc {
  font-size: 11px;
  color: var(--text-muted);
}

/* 空状态 */
.reminder-empty {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  font-size: 14px;
  color: var(--text-muted);
  background: white;
}

/* ===== 优质新主播 4 个子区域 ===== */
.quality-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.quality-sub-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: white;
  padding: 16px;
}
.quality-sub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}
.quality-sub-left {
  display: flex;
  align-items: center;
  gap: 8px;
}
.quality-sub-right {
  display: flex;
  align-items: center;
  gap: 8px;
}
.quality-sub-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
}
.quality-badge-blue { background: rgba(26,95,173,0.1); color: var(--brand-blue); }
.quality-badge-green { background: #d1fae5; color: #059669; }
.quality-badge-amber { background: #fef3c7; color: #b45309; }
.quality-badge-violet { background: #ede9fe; color: #7c3aed; }
.quality-sub-count {
  font-size: 11px;
  color: var(--text-muted);
}
.quality-task-month {
  font-size: 11px;
  color: var(--text-muted);
}
.quality-task-hint {
  font-size: 10px;
  color: var(--text-muted);
  margin-bottom: 10px;
  line-height: 1.5;
}
.quality-intro-text {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.7;
}
.quality-empty {
  padding: 24px;
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
}

/* ===== 运营宝典卡片（对照原版 PlaybookCard） ===== */
.playbook-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: white;
  overflow: hidden;
  transition: box-shadow 0.3s;
}
.playbook-card:hover {
  box-shadow: 0 8px 24px -6px rgba(26,95,173,0.15);
}
.playbook-card-bar {
  height: 6px;
}
.playbook-bar-rose { background: linear-gradient(to right, #f43f5e, #fb923c); }
.playbook-bar-blue { background: linear-gradient(to right, #3b82f6, #06b6d4); }
.playbook-bar-purple { background: linear-gradient(to right, #a855f7, #ec4899); }
.playbook-card-body-wrap {
  padding: 20px;
}
.playbook-card-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}
.playbook-card-icon svg {
  width: 20px;
  height: 20px;
}
.playbook-icon-rose { background: linear-gradient(to bottom right, #f43f5e, #fb923c); }
.playbook-icon-blue { background: linear-gradient(to bottom right, #3b82f6, #06b6d4); }
.playbook-icon-purple { background: linear-gradient(to bottom right, #a855f7, #ec4899); }
.playbook-card-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text-primary);
}
.playbook-card-desc {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.playbook-detail-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 12px;
  font-size: 12px;
  color: var(--brand-blue);
  text-decoration: none;
  font-weight: 500;
}
.playbook-detail-btn:hover {
  text-decoration: underline;
}

/* ===== 优质新主播交互元素 ===== */
.quality-sub-hint {
  font-size: 10px;
  color: var(--text-muted);
}
.quality-intro-textarea {
  width: 100%;
  font-size: 11px;
  color: var(--text-primary, #1f2937);
  line-height: 1.6;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px;
  resize: vertical;
  font-family: inherit;
}
.quality-intro-textarea:focus {
  outline: none;
  border-color: rgba(26,95,173,0.5);
}
.quality-progress-select {
  height: 28px;
  font-size: 11px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  cursor: pointer;
}
.quality-note-input {
  width: 100%;
  height: 28px;
  font-size: 11px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0 6px;
}
.quality-note-input:focus {
  outline: none;
  border-color: rgba(26,95,173,0.5);
}
.quality-task-month-select {
  height: 28px;
  font-size: 11px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  padding: 0 6px;
}
.quality-restore-btn {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(26,95,173,0.4);
  color: var(--brand-blue);
  font-size: 10px;
  background: white;
  cursor: pointer;
  transition: background 0.2s;
}
.quality-restore-btn:hover {
  background: rgba(26,95,173,0.1);
}

/* ===== 重要提醒：进度彩色 chip（优质新主播） ===== */
.progress-chip {
  display: inline-block;
  max-width: 100%;
  border-radius: var(--radius-sm);
  font-size: 10px;
  font-weight: 500;
  padding: 2px 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* 进度下拉触发器（带彩色背景的 select 外观） */
.quality-progress-select {
  height: 28px;
  font-size: 11px;
  font-weight: 500;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  padding: 0 4px;
  text-align: center;
  max-width: 100%;
}
.quality-progress-select:focus {
  outline: 1px solid rgba(26,95,173,0.3);
}

/* ===== 异常主播：启用开关 + 删除按钮 + 命中表格 ===== */
.anomaly-rule-toggle {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  border: 1px solid var(--border);
  background: white;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  padding: 0;
  font-size: 11px;
  line-height: 1;
  color: white;
}
.anomaly-rule-toggle.on {
  background: var(--brand-blue);
  border-color: var(--brand-blue);
}
.anomaly-rule-delete {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  padding: 2px;
  flex-shrink: 0;
}
.anomaly-rule-delete:hover {
  color: #f43f5e;
}
.anomaly-hit-zero {
  color: #f43f5e;
  font-weight: 500;
}
.anomaly-hit-lastlive {
  color: var(--text-muted);
}

/* ===== 日历 hover 删除按钮 ===== */
.calendar-item {
  position: relative;
}
.calendar-item-del {
  opacity: 0;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 12px;
  line-height: 1;
  padding: 0 2px;
  flex-shrink: 0;
  transition: opacity 0.15s, color 0.15s;
}
.calendar-item:hover .calendar-item-del {
  opacity: 1;
}
.calendar-item-del:hover {
  color: #f43f5e;
}
.calendar-item-meta {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}
.calendar-col-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.calendar-col-title {
  color: var(--brand-blue);
}
.calendar-col-count {
  font-size: 10px;
  color: var(--text-muted);
  background: var(--border-light);
  padding: 1px 6px;
  border-radius: 999px;
}
.calendar-item-line {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  flex: 1;
  overflow: hidden;
}
.calendar-item-field {
  color: var(--text-primary, #1f2937);
  flex-shrink: 0;
}
.calendar-item-content {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.anomaly-rule-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.anomaly-rule-nohit {
  padding: 12px 16px;
  font-size: 12px;
  color: var(--text-muted);
}
.reminder-table-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: white;
  overflow: hidden;
}
.quality-fixed {
  table-layout: fixed;
}
.quality-fixed th,
.quality-fixed td {
  text-align: center;
}

/* ===== 主播积分页（对照原版 PointsPage） ===== */
.points-banner {
  background: linear-gradient(to right, hsl(212 76% 36%), hsl(212 80% 48%));
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 16px;
}
.points-banner-tabs {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.points-pill {
  display: inline-flex;
  align-items: center;
  padding: 8px 20px;
  border-radius: 9999px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s;
  border: 2px solid rgba(255,255,255,0.3);
  background: rgba(255,255,255,0.1);
  color: white;
}
.points-pill:hover { background: rgba(255,255,255,0.2); }
.points-pill.active {
  background: var(--brand-gold);
  color: var(--brand-blue-dark);
  border-color: var(--brand-gold);
  box-shadow: 0 4px 14px -2px rgba(245,197,24,0.6);
}
.points-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
}
.points-card-body { padding: 20px; }
.points-query-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.points-badge-blue {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: rgba(26,95,173,0.1);
  color: var(--brand-blue);
  font-size: 12px;
  font-weight: 600;
}
.points-type-toggle {
  display: flex;
  gap: 2px;
  background: hsl(212 30% 95%);
  border-radius: var(--radius-sm);
  padding: 2px;
}
.points-type-btn {
  padding: 6px 12px;
  font-size: 12px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: var(--text-muted);
  font-weight: 500;
}
.points-type-btn.active {
  background: var(--brand-blue);
  color: white;
}
.points-query-form {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.points-mode-select { height: 36px; width: 130px; font-size: 13px; }
.points-search-input { height: 36px; width: 260px; font-size: 13px; }
.points-query-btn {
  height: 36px;
  padding: 0 16px;
  font-size: 13px;
  border-radius: var(--radius-sm);
  background: linear-gradient(to right, hsl(212 76% 36%), hsl(212 80% 50%));
  color: white;
  border: none;
  cursor: pointer;
}
.points-query-btn:hover { opacity: 0.95; }
.points-not-found { margin-top: 8px; font-size: 12px; color: #e11d48; }
.points-result-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.points-result-sub { font-size: 12px; color: var(--text-muted); }
.points-balance-label { font-size: 11px; color: var(--text-muted); margin-left: auto; }
.points-export-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  font-size: 12px;
  border-radius: var(--radius-sm);
  background: linear-gradient(to right, hsl(212 76% 36%), hsl(212 80% 50%));
  color: white;
  text-decoration: none;
  font-weight: 500;
}
.points-export-btn:hover { opacity: 0.95; }

/* ===== 上传数据页补充（同步按钮 + 统计卡 + 组别） ===== */
.sync-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 36px;
  box-sizing: border-box;
  padding: 0 16px;
  font-size: 12px;
  border-radius: var(--radius-sm);
  background: linear-gradient(to right, hsl(212 76% 36%), hsl(212 80% 50%));
  color: white;
  border: none;
  cursor: pointer;
  font-weight: 500;
}
.sync-btn:hover { opacity: 0.95; }
.sync-btn:disabled { cursor: wait; opacity: 0.78; }
.sync-spinner {
  display: none;
  width: 13px;
  height: 13px;
  box-sizing: border-box;
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-top-color: white;
  border-radius: 50%;
}
.sync-btn.is-syncing .sync-spinner {
  display: inline-block;
  animation: sync-button-spin 0.7s linear infinite;
}
@keyframes sync-button-spin { to { transform: rotate(360deg); } }
.sync-time {
  display: inline-flex;
  align-items: center;
  height: 36px;
  font-size: 11px;
  color: var(--text-muted);
}
/* 校准目标 pill 按钮（运营数据/主播积分） */
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 12px;
  border-radius: 9999px;
  border: 1px solid var(--border);
  background: white;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}
/* 2026-08-27 勾选目标=胶囊开关：原生框隐藏，SVG 圆圈勾随状态显色 */
.calib-target-pill input[type="checkbox"] {
  display: none;
}
.calib-target-pill .pill-ck {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  opacity: 0.55;
  transition: opacity 0.15s;
}
.calib-target-pill.active .pill-ck {
  opacity: 1;
}
.calib-target-pill.active {
  background: var(--brand-blue);
  color: white;
  border-color: var(--brand-blue);
  box-shadow: 0 2px 8px -2px rgba(26,95,173,0.5);
}
.calib-target-pill:hover:not(.active) {
  background: hsl(212 30% 95%);
}
.group-stats-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.group-stat-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 20px;
  min-width: 100px;
}
.group-stat-label {
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.group-stat-value {
  font-size: 22px;
  font-weight: 700;
  color: var(--brand-blue);
  font-variant-numeric: tabular-nums;
}
.group-select {
  height: 28px;
  font-size: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  cursor: pointer;
}

/* ===== B站日期紧凑弹出日历（点上传日期字段弹出，尺寸紧凑，已上传绿色）===== */
.date-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  font-size: 13px;
  color: var(--text-primary);
  cursor: pointer;
  font-family: inherit;
  min-width: 150px;
}
.date-trigger:hover {
  border-color: rgba(26,95,173,0.5);
}
.date-trigger-text {
  font-variant-numeric: tabular-nums;
}
.date-trigger-caret {
  color: var(--text-muted);
  font-size: 10px;
}
/* 弹出层：绝对定位，紧凑（约 264px 宽） */
.cal-popover {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  z-index: 50;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 8px 24px -8px rgba(26,95,173,0.25);
  padding: 10px;
  width: 264px;
}
.cal-pop-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.cal-pop-nav {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: white;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  line-height: 1;
}
.cal-pop-nav:hover {
  background: hsl(212 30% 95%);
  color: var(--brand-blue);
}
.cal-pop-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}
.cal-pop-week {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  margin-bottom: 2px;
  font-size: 10px;
  color: var(--text-muted);
}
.cal-pop-week span {
  text-align: center;
  padding: 2px 0;
}
.cal-pop-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}
.cal-pop-cell {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  height: 26px;
}
.cal-pop-cell.empty {
  background: transparent;
}
.cal-pop-cell.empty-date {
  background: hsl(212 30% 95%);
  color: var(--text-muted);
}
.cal-pop-cell.future {
  background: white;
  color: var(--border-light);
}
.cal-pop-cell.uploaded {
  background: #d1fae5;
  color: #059669;
  font-weight: 600;
  border: 1px solid #6ee7b7;
}
.cal-pop-cell.uploaded:hover {
  background: #a7f3d0;
}
.cal-pop-cell.selected {
  box-shadow: 0 0 0 2px var(--brand-blue);
  z-index: 1;
}
.cal-pop-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  text-decoration: none;
  color: inherit;
}
.autodetect-input::-webkit-calendar-picker-indicator {
  opacity: 0.4;
  cursor: pointer;
}

/* ===== 总览 top25 排行榜 ===== */
.rank-section {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-top: 16px;
}
.rank-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.rank-title-badge {
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: rgba(26,95,173,0.1);
  color: var(--brand-blue);
  font-size: 12px;
  font-weight: 600;
}
.rank-title-text {
  font-size: 14px;
  color: var(--text-secondary);
}
.rank-list {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  max-height: 380px;
  overflow-y: auto;
}
.rank-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-bottom: 1px solid var(--border-light);
  font-size: 13px;
}
.rank-row:last-child { border-bottom: none; }
.rank-row:hover { background: hsl(212 30% 98%); }
.rank-no { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: center; }
.rank-medal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  color: white;
  flex-shrink: 0;
}
.rank-medal-1 { background: linear-gradient(to bottom right, #fbbf24, #d97706); }
.rank-medal-2 { background: linear-gradient(to bottom right, #cbd5e1, #64748b); }
.rank-medal-3 { background: linear-gradient(to bottom right, #fb923c, #ea580c); }
.rank-medal-n { background: hsl(212 30% 95%); color: var(--text-muted); }
.rank-group { flex: 1; min-width: 0; display: flex; justify-content: center; }
.group-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  font-size: 10px;
  font-weight: 600;
}
.group-S { background: #ffe4e6; color: #be123c; }
.group-A { background: #dbeafe; color: #1d4ed8; }
.group-B1 { background: #d1fae5; color: #047857; }
.group-B2 { background: #fef3c7; color: #b45309; }
.group-R1 { background: #ede9fe; color: #6d28d9; }
.group-R2 { background: #cffafe; color: #0e7490; }
.group-C { background: #f1f5f9; color: #475569; }
.rank-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-primary); font-weight: 400; }
.rank-revenue { flex: 1; min-width: 0; text-align: center; font-variant-numeric: tabular-nums; color: var(--text-secondary); }
.rank-op { flex: 1; min-width: 0; text-align: center; }
.op-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  background: rgba(26,95,173,0.08);
  color: var(--brand-blue);
  font-size: 10px;
  font-weight: 500;
}

/* ===== 自招自带视图 ===== */
.self-recruit-rule {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}
.self-rule-block { margin-bottom: 16px; }
.self-rule-block:last-child { margin-bottom: 0; }
.self-rule-title { font-size: 14px; font-weight: 600; color: var(--brand-blue); margin-bottom: 6px; }
.self-rule-sub { font-size: 13px; font-weight: 600; color: var(--text-primary); margin-bottom: 4px; }
.self-rule-item { font-size: 13px; color: var(--text-muted); padding-left: 8px; line-height: 1.7; }
.self-hl { color: var(--brand-blue); font-weight: 500; }
.self-hl-gold { color: var(--brand-gold-dark); font-weight: 600; }

.self-recruit-list {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.self-list-title { font-size: 14px; font-weight: 500; margin-bottom: 12px; }
.self-list-table { border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.self-list-head {
  display: grid;
  grid-template-columns: 1fr 4fr 2fr 2fr 2fr 1fr;
  gap: 8px;
  padding: 8px 16px;
  background: hsl(212 30% 96%);
  border-bottom: 1px solid var(--border);
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
}
.self-list-head .col-rank, .self-list-head .col-pay { text-align: left; }
.self-list-head .col-num { text-align: right; }
.self-list-head .col-status { text-align: center; }
.self-list-body { max-height: 600px; overflow-y: auto; }
.self-list-row {
  display: grid;
  grid-template-columns: 1fr 4fr 2fr 2fr 2fr 1fr;
  gap: 8px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-light);
  font-size: 13px;
  align-items: center;
}
.self-list-row:last-child { border-bottom: none; }
.self-list-row .col-num { text-align: right; }
.self-list-row .col-status { text-align: center; }

/* ===== 新主播提成明细 ===== */
.commission-detail-title {
  font-size: 12px;
  color: var(--text-muted);
  margin: 16px 0 8px;
}
.commission-detail-count { color: var(--brand-blue); font-weight: 500; }
.commission-detail-table { border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.cd-head {
  display: grid;
  grid-template-columns: 1fr 3fr 2fr 2fr 2fr;
  gap: 8px;
  padding: 8px 16px;
  background: hsl(212 30% 96%);
  border-bottom: 1px solid var(--border);
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
}
.cd-head span { text-align: center; }
.cd-body { max-height: 200px; overflow-y: auto; }
.cd-row {
  display: grid;
  grid-template-columns: 1fr 3fr 2fr 2fr 2fr;
  gap: 8px;
  padding: 8px 16px;
  border-bottom: 1px solid var(--border-light);
  font-size: 13px;
  align-items: center;
}
.commission-detail-table.cd-grid-4 .cd-head,
.commission-detail-table.cd-grid-4 .cd-row {
  grid-template-columns: 1fr 3fr 2fr 2fr 2fr;
}
.cd-row:last-child { border-bottom: none; }
.cd-row span { text-align: center; }
.cd-name { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cd-commission { color: #059669; font-weight: 600; font-variant-numeric: tabular-nums; }
.cd-revenue { font-variant-numeric: tabular-nums; }
.cd-cycle { font-size: 12px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.cd-empty { text-align: center; padding: 24px; font-size: 12px; color: var(--text-muted); }

/* ===== 主播进度看板 ===== */
.progress-board-wrap { margin-top: 20px; display: flex; flex-direction: column; gap: 16px; }
.progress-board {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.pb-header {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.pb-title { font-size: 14px; font-weight: 600; }
.pb-subtitle { font-size: 12px; color: var(--text-muted); }
.pb-target { margin-left: auto; font-size: 12px; color: var(--text-muted); }
.pb-group-label { font-size: 12px; font-weight: 500; color: var(--text-muted); margin: 10px 0 6px; }
.pb-row { display: flex; align-items: center; gap: 12px; padding: 4px 0; }
.pb-name { width: 120px; font-size: 12px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex-shrink: 0; }
.pb-track { flex: 1; height: 20px; background: hsl(212 30% 94%); border-radius: 9999px; overflow: hidden; }
.pb-fill { height: 100%; border-radius: 9999px; transition: all 0.3s; }
.pb-blue { background: #60a5fa; }
.pb-teal { background: #2dd4bf; }
.pb-amber { background: #fbbf24; }
.pb-coral { background: #fb7185; }
.pb-value { width: 100px; text-align: right; font-size: 12px; font-variant-numeric: tabular-nums; flex-shrink: 0; }
.pb-val-num { font-weight: 500; }
.pb-val-target { color: var(--text-muted); }
.pb-status { width: 80px; text-align: right; font-size: 12px; font-weight: 500; flex-shrink: 0; }
.pb-t-blue { color: #2563eb; }
.pb-t-teal { color: #0d9488; }
.pb-t-amber { color: #d97706; }
.pb-t-coral { color: #e11d48; }

/* ========== 通用弹窗组件（舰礼风格：原生 HTML+CSS+JS） ========== */
.app-modal {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.app-modal[hidden] { display: none; }
.app-modal-backdrop {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 23, 42, 0.45);
}
.app-modal-dialog {
  position: relative;
  background: white;
  border-radius: 12px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.25);
  max-width: 90vw;
  max-height: 90vh;
  width: 560px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
/* 宽版弹窗（账号管理权限树等需要宽松排版的场景，AppModal.open 第三参 {wide:true}） */
.app-modal-dialog-wide { width: 1560px; max-width: 95vw; }
.app-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border-light);
  background: linear-gradient(to right, #1A5FAD, #2563eb);
  color: white;
}
.app-modal-title {
  font-size: 15px;
  font-weight: 600;
}
.app-modal-close {
  background: none;
  border: none;
  color: white;
  font-size: 22px;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
  opacity: 0.85;
}
.app-modal-close:hover { opacity: 1; }
.app-modal-body {
  padding: 20px;
  overflow-y: auto;
  max-height: calc(90vh - 50px);
}
.app-modal-error {
  display: none;
  padding: 10px 14px;
  margin-bottom: 12px;
  border-radius: 6px;
  background: #fee2e2;
  color: #dc2626;
  font-size: 13px;
}
.app-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-light);
}
.app-modal-btn {
  padding: 8px 20px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  border: none;
}
.app-modal-btn-primary {
  background: #1A5FAD;
  color: white;
}
.app-modal-btn-primary:hover { background: #2563eb; }
.app-modal-btn-ghost {
  background: white;
  color: var(--text-secondary);
  border: 1px solid var(--border);
}
.points-add-btn {
  padding: 6px 14px;
  border-radius: 6px;
  border: none;
  background: linear-gradient(to right, hsl(212 76% 36%), hsl(212 80% 50%));
  color: white;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  margin-left: 8px;
}
.points-add-btn:hover { opacity: 0.92; }
.points-del-btn {
  background: none;
  border: none;
  color: #dc2626;
  cursor: pointer;
  font-size: 12px;
  padding: 2px 6px;
}
.points-del-btn:hover { text-decoration: underline; }
.points-edit-btn {
  background: none;
  border: none;
  color: #1d4ed8;
  cursor: pointer;
  font-size: 12px;
  padding: 2px 6px;
}
.points-edit-btn:hover { text-decoration: underline; }

/* ===== 主播积分：余额徽章 / toast / 经费拖动排序（对齐原版 20260826） ===== */
.points-balance-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 6px;
  background: #fffbeb;
  border: 1px solid rgba(180, 83, 9, 0.25);
}
.points-toast {
  display: none;
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  padding: 8px 16px;
  border-radius: 8px;
  background: #059669;
  color: #fff;
  font-size: 13px;
  box-shadow: 0 4px 14px rgba(5, 150, 105, 0.35);
  pointer-events: none;
}
.fund-grip {
  color: rgba(100, 116, 139, 0.45);
  cursor: grab;
  font-size: 13px;
  margin-right: 4px;
  user-select: none;
}
tr[data-fund-id] { cursor: grab; }
tr[data-fund-id]:active { cursor: grabbing; }
tr.fund-dragging { opacity: 0.45; }
tr.fund-drag-over td { background: #eff6ff !important; }

/* ===== 变动情况 tab：常驻录入表单（对齐原版 ChangeTab） ===== */
.pts-form-label {
  width: 112px;
  text-align: right;
  font-size: 12px;
  color: var(--text-muted);
  flex-shrink: 0;
  white-space: nowrap;
}
.pts-toggle {
  flex: 1;
  height: 36px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.15s ease;
}
.pts-toggle.off { background: #fff; color: var(--text-muted); }
.pts-toggle.tg-blue:hover:not(.on-blue) { border-color: #93c5fd; color: #2563eb; }
.pts-toggle.tg-amber:hover:not(.on-amber) { border-color: #fbbf24; color: #d97706; }
.pts-toggle.tg-red:hover:not(.on-red) { border-color: #fb7185; color: #e11d48; }
.pts-toggle.tg-green:hover:not(.on-green) { border-color: #6ee7b7; color: #059669; }
.pts-toggle.on-blue { background: #2563eb; color: #fff; border-color: #2563eb; box-shadow: 0 1px 2px rgba(15, 23, 42, 0.1); }
.pts-toggle.on-amber { background: #f59e0b; color: #fff; border-color: #f59e0b; box-shadow: 0 1px 2px rgba(15, 23, 42, 0.1); }
.pts-toggle.on-red { background: #f43f5e; color: #fff; border-color: #f43f5e; box-shadow: 0 1px 2px rgba(15, 23, 42, 0.1); }
.pts-toggle.on-green { background: #10b981; color: #fff; border-color: #10b981; box-shadow: 0 1px 2px rgba(15, 23, 42, 0.1); }
/* 记录列表操作列 ✕ 按钮（对齐原版 X icon，hover 红） */
.points-del-x {
  border: none;
  background: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 13px;
  padding: 4px 8px;
  transition: color 0.15s ease;
  line-height: 1;
}
.points-del-x:hover { color: #dc2626; }

/* datalist 原生下拉箭头隐藏（2026-08-27 用户要求） */
.points-search-input::-webkit-calendar-picker-indicator,
.autodetect-input::-webkit-calendar-picker-indicator { display: none !important; }

/* 创作经费操作项图标按钮（2026-08-27 用户指定：图标替代文字；↑↓按钮替代拖拽） */
.fund-ico-btn {
  background: none;
  border: none;
  padding: 2px 3px;
  cursor: pointer;
  vertical-align: middle;
  color: #555;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
}
.fund-ico-btn:hover { background: #eef1f5; }
.fund-ico-btn svg { width: 15px; height: 15px; }


/* 2026-08-27 定稿：表格 100% 铺满（表头灰条通到右缘），数据列靠左紧凑排，
   行尾隐形补位列吃掉剩余宽度 → 内容不占满、不折叠 */
.table-fill { width: 100%; }
.table-fill table { width: 100%; }
/* 补位列=表中唯一不定宽列，自动吃掉剩余宽度；其余列必须显式定宽 */
.tbl-filler { border-top: none !important; border-left: none !important; border-right: none !important; background: transparent !important; }
tr:hover .tbl-filler { background: transparent !important; }

/* 成才卡「无法完成」：深灰色（2026-08-28） */
.op-rank-status.is-giveup { color: #6b7280; }
