/* ============================================================
   电信老炮工作台 · QUIET LUXURY EDITION
   静奢极简 —— 瓷白 × 浓墨 × 古铜金
   ============================================================ */
:root {
  color-scheme: light;

  /* —— 语义色（沿用旧变量名，JS 内 var() 引用自动生效） —— */
  --coral: #A8894A;                 /* 品牌色 · 古铜金 */
  --coral-dark: #8C7139;            /* 深古铜 · 浅底可读 */
  --coral-ink: #8C7139;             /* 金色正文 */
  --coral-bg: rgba(168,137,74,0.09);
  --coral-border: rgba(168,137,74,0.32);
  --coral-light: rgba(168,137,74,0.05);

  --blue: #6B7F96;                  /* 支柱 · 石板蓝 */
  --blue-dark: #52637A;
  --blue-bg: rgba(107,127,150,0.10);
  --blue-border: rgba(107,127,150,0.30);

  --teal: #7C9082;                  /* 支柱 · 鼠尾草绿 */
  --teal-dark: #5F7265;
  --teal-bg: rgba(124,144,130,0.12);

  --amber: #A87F3D;                 /* 提示 · 深赭金 */
  --amber-bg: rgba(168,127,61,0.10);
  --amber-border: rgba(168,127,61,0.30);

  --red: #A65B53;                   /* 警示 · 砖红 */
  --red-bg: rgba(166,91,83,0.10);

  --purple: #8B7B96;                /* 支柱 · 梅灰紫 */
  --purple-bg: rgba(139,123,150,0.11);

  /* —— 结构色 —— */
  --bg: #F6F4EF;                    /* 温润瓷白 */
  --bg-2: #F1EDE4;                  /* 输入框/嵌块底 */
  --bg-card: #EFEAE0;               /* 卡片内嵌面板 */
  --bg-hover: rgba(168,137,74,0.06);
  --card: #FFFFFF;
  --panel: #FBFAF7;                 /* 弹窗/侧栏 */
  --border: #E4DED2;                /* 发丝线 · 暖灰 */
  --border-light: #EDE8DD;
  --text: #26241F;                  /* 浓墨 */
  --text-1: #26241F;
  --text-2: #6E675C;                /* 暖灰褐 */
  --text-3: #A39B8D;                /* 浅褐 */

  --ink: #1E1C18;                   /* 墨黑（按钮/头像） */
  --paper: #F6F4EF;

  /* —— 字体 —— */
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-display: "Cormorant Garamond", "Noto Serif SC", "Songti SC", serif;
  --font-mono: "Cormorant Garamond", "Noto Serif SC", serif; /* 数字/标签用衬线 */

  --radius: 4px;
  --radius-sm: 3px;
  --shadow: 0 1px 2px rgba(31,28,22,0.05);
  --shadow-lift: 0 14px 34px rgba(31,28,22,0.09);
  --sidebar-w: 232px;
  --mobile-nav-h: 58px;
  --mobile-header-h: 54px;
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html { font-size: 15px; background: var(--bg); }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

::selection { background: rgba(168,137,74,0.25); color: var(--ink); }

/* ============================================================
   侧边栏
   ============================================================ */
.sidebar {
  position: fixed;
  left: 0; top: 0; bottom: 0;
  width: var(--sidebar-w);
  background: var(--panel);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  z-index: 100;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 26px 20px 22px;
  border-bottom: 1px solid var(--border-light);
}

.brand-avatar {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--ink);
  color: #C9A961;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0;
}
.brand-avatar.small { width: 32px; height: 32px; font-size: 15px; }

.brand-name {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 4px;
  color: var(--ink);
}
.brand-sub {
  font-size: 10px;
  letter-spacing: 3px;
  color: var(--text-3);
  margin-top: 2px;
}

.sidebar-nav {
  flex: 1;
  padding: 16px 12px;
  overflow-y: auto;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 3px;
  color: var(--text-2);
  text-decoration: none;
  font-size: 14px;
  letter-spacing: 1px;
  margin-bottom: 2px;
  border-left: 2px solid transparent;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
}
.nav-item:hover { color: var(--ink); background: var(--bg-hover); }
.nav-item.active {
  color: var(--ink);
  font-weight: 500;
  border-left-color: var(--coral);
  background: rgba(168,137,74,0.07);
}
.nav-icon { width: 20px; text-align: center; font-size: 12px; color: var(--text-3); transition: color 0.2s; }
.nav-item.active .nav-icon, .nav-item:hover .nav-icon { color: var(--coral-dark); }

.sidebar-footer {
  padding: 14px 20px 18px;
  border-top: 1px solid var(--border-light);
}
.sidebar-tip {
  font-size: 10px;
  letter-spacing: 2px;
  color: var(--text-3);
  display: flex;
  align-items: center;
  gap: 8px;
}
.sidebar-tip::before {
  content: "";
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--coral);
  flex-shrink: 0;
  animation: sysBreath 3s ease-in-out infinite;
}
@keyframes sysBreath {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

/* ============================================================
   移动端头部
   ============================================================ */
.mobile-header {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--mobile-header-h);
  background: rgba(251,250,247,0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  padding: 0 16px;
  align-items: center;
}
.mobile-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 3px;
  color: var(--ink);
}

/* ============================================================
   主内容区
   ============================================================ */
.main {
  margin-left: var(--sidebar-w);
  padding: 40px 44px 72px;
  min-height: 100vh;
  max-width: 1280px;
}

.page { display: none; animation: fadeIn 0.35s ease; }
.page.active { display: block; }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.page-header { margin-bottom: 30px; }
.page-header.row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}
.page-header h2 {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 600;
  letter-spacing: 5px;
  color: var(--ink);
  margin-bottom: 8px;
  line-height: 1.25;
}
.page-header h2::after {
  content: "";
  display: block;
  width: 44px; height: 2px;
  margin-top: 12px;
  background: var(--coral);
}
.page-desc {
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--text-3);
}

/* ============================================================
   卡片
   ============================================================ */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 18px;
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow);
  transition: box-shadow 0.3s ease, transform 0.3s ease, border-color 0.3s ease;
}
.card:hover {
  box-shadow: var(--shadow-lift);
  transform: translateY(-2px);
  border-color: var(--border-light);
}
.card-header { padding: 20px 24px 0; }
.card-header h3 {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 3px;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 10px;
}
.card-header h3::before {
  content: "";
  width: 3px; height: 15px;
  background: var(--coral);
  flex-shrink: 0;
}
.card-body { padding: 18px 24px 24px; }

/* ============================================================
   按钮
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 22px;
  border-radius: 2px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 2px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.25s ease;
  font-family: inherit;
  white-space: nowrap;
}
.btn-primary {
  background: var(--ink);
  color: #F6F4EF;
}
.btn-primary:hover {
  background: var(--coral-dark);
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(140,113,57,0.22);
}
.btn-outline {
  background: transparent;
  border-color: var(--border);
  color: var(--text-2);
}
.btn-outline:hover {
  border-color: var(--ink);
  color: var(--ink);
}
.btn-sm { padding: 6px 14px; font-size: 12px; letter-spacing: 1px; }
.btn:active { transform: scale(0.97); }

/* ============================================================
   统计卡片
   ============================================================ */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
  margin-bottom: 28px;
}
.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 20px 18px;
  position: relative;
  overflow: hidden;
  transition: box-shadow 0.3s, transform 0.3s;
}
.stat-card::after {
  content: "";
  position: absolute; left: 0; right: 0; top: 0;
  height: 2px;
  background: var(--border-light);
  transition: background 0.3s;
}
.stat-card:hover { box-shadow: var(--shadow-lift); transform: translateY(-2px); }
.stat-card:hover::after { background: var(--coral); }
.stat-label {
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--text-3);
  margin-bottom: 10px;
}
.stat-value {
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 600;
  line-height: 1.1;
  color: var(--ink);
  font-variant-numeric: lining-nums;
}
.stat-extra { font-size: 11px; color: var(--text-3); margin-top: 6px; letter-spacing: 1px; }
.stat-card.accent .stat-value { color: var(--coral-dark); }

/* ============================================================
   仪表盘布局
   ============================================================ */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-bottom: 18px;
}

.quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* ============================================================
   周计划 / 待办
   ============================================================ */
.plan-day {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-light);
  font-size: 13px;
}
.plan-day:last-child { border-bottom: none; }
.plan-day .day-name {
  width: 46px;
  font-weight: 500;
  color: var(--text-2);
  flex-shrink: 0;
  letter-spacing: 1px;
}
.plan-tag {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 2px;
  font-weight: 500;
  letter-spacing: 1px;
}
.plan-tag.video { background: var(--coral-bg); color: var(--coral-dark); }
.plan-tag.image { background: var(--blue-bg); color: var(--blue-dark); }
.plan-tag.rest { background: var(--bg-2); color: var(--text-3); }

.todo-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-light);
  font-size: 13px;
}
.todo-item:last-child { border-bottom: none; }
.todo-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  margin-top: 8px;
  flex-shrink: 0;
}
.todo-dot.high { background: var(--red); }
.todo-dot.mid { background: var(--amber); }
.todo-dot.low { background: var(--teal); }
.todo-text { flex: 1; }
.todo-meta { font-size: 11px; color: var(--text-3); }

.empty-state {
  text-align: center;
  padding: 36px 16px;
  color: var(--text-3);
  font-size: 13px;
  letter-spacing: 1px;
}

/* ============================================================
   筛选栏
   ============================================================ */
.filter-bar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.filter-chip {
  padding: 7px 18px;
  border-radius: 2px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 1px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-2);
  cursor: pointer;
  transition: all 0.2s;
}
.filter-chip:hover { border-color: var(--text-3); color: var(--ink); }
.filter-chip.active {
  background: var(--ink);
  border-color: var(--ink);
  color: #F6F4EF;
}
.filter-chip .count {
  display: inline-block;
  margin-left: 5px;
  font-size: 11px;
  opacity: 0.6;
}

/* ============================================================
   选题列表
   ============================================================ */
.topic-item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 12px;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: var(--shadow);
}
.topic-item:hover {
  border-color: var(--coral-border);
  box-shadow: var(--shadow-lift);
  transform: translateY(-2px);
}
.topic-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.topic-title {
  font-size: 15px;
  font-weight: 600;
  flex: 1;
  line-height: 1.55;
  color: var(--ink);
}
.topic-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  flex-shrink: 0;
}
.badge {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 2px;
  font-weight: 500;
  letter-spacing: 1px;
  white-space: nowrap;
}
.badge.pillar-1 { background: var(--blue-bg); color: var(--blue-dark); }
.badge.pillar-2 { background: var(--teal-bg); color: var(--teal-dark); }
.badge.pillar-3 { background: var(--coral-bg); color: var(--coral-dark); }
.badge.pillar-4 { background: var(--purple-bg); color: var(--purple); }
.badge.pillar-5 { background: var(--amber-bg); color: var(--amber); }
.badge.format-video { background: var(--coral-bg); color: var(--coral-dark); }
.badge.format-image { background: var(--blue-bg); color: var(--blue-dark); }
.badge.priority-高 { background: var(--red-bg); color: var(--red); }
.badge.priority-中 { background: var(--amber-bg); color: var(--amber); }
.badge.priority-低 { background: var(--bg-2); color: var(--text-3); }

.topic-notes {
  font-size: 12px;
  color: var(--text-2);
  margin-bottom: 12px;
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.topic-pipeline {
  display: flex;
  gap: 5px;
  align-items: center;
}
.pipe-step {
  flex: 1;
  height: 3px;
  border-radius: 2px;
  background: var(--border-light);
  position: relative;
}
.pipe-step.done { background: var(--coral); }
.pipe-step.current { background: var(--ink); }
.pipe-labels {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  letter-spacing: 1px;
  color: var(--text-3);
  margin-top: 6px;
}
.pipe-labels .current { color: var(--ink); font-weight: 600; }
.pipe-labels .done { color: var(--coral-dark); }

.topic-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.topic-actions .btn { padding: 5px 12px; font-size: 11px; letter-spacing: 1px; }

/* ============================================================
   日历
   ============================================================ */
.calendar-nav { display: flex; gap: 8px; }

.calendar-week {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 10px;
}
.cal-day {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  min-height: 148px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow);
  transition: box-shadow 0.25s, border-color 0.25s;
}
.cal-day:hover { box-shadow: var(--shadow-lift); }
.cal-day.today {
  border-color: var(--coral);
  box-shadow: 0 0 0 1px var(--coral), var(--shadow);
}
.cal-day-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-light);
}
.cal-day-name {
  font-size: 12px;
  letter-spacing: 2px;
  font-weight: 600;
  color: var(--text-2);
}
.cal-day-num {
  font-family: var(--font-display);
  font-size: 14px;
  color: var(--text-3);
}
.cal-day.today .cal-day-num { color: var(--coral-dark); font-weight: 700; }
.cal-day.today .cal-day-name { color: var(--coral-dark); }
.cal-slot {
  font-size: 11px;
  padding: 7px 10px;
  border-radius: 2px;
  margin-bottom: 5px;
  line-height: 1.45;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  transition: transform 0.15s;
}
.cal-slot:hover { transform: translateX(2px); }
.cal-slot.video { background: var(--coral-bg); color: var(--coral-dark); border-left: 3px solid var(--coral); }
.cal-slot.image { background: var(--blue-bg); color: var(--blue-dark); border-left: 3px solid var(--blue); }
.cal-slot.done { opacity: 0.5; text-decoration: line-through; }
.cal-add {
  margin-top: auto;
  text-align: center;
  font-size: 16px;
  color: var(--text-3);
  padding: 4px;
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.2s;
}
.cal-add:hover { background: var(--bg-2); color: var(--coral-dark); }

/* 日历拖拽状态 */
.cal-day.drag-over {
  background: var(--coral-light);
  border-color: var(--coral);
  box-shadow: 0 0 0 2px rgba(168,137,74,0.2);
}
.drag-chip {
  padding: 5px 12px;
  border-radius: 2px;
  font-size: 11px;
  font-weight: 500;
  cursor: grab;
  white-space: nowrap;
  user-select: none;
  flex-shrink: 0;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.drag-chip:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(31,28,22,0.12);
}
.drag-chip.dragging {
  opacity: 0.4 !important;
  transform: scale(0.95);
}
.drag-source-bar {
  transition: background 0.2s ease;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.cal-slot[draggable="true"] { cursor: grab; }
.cal-slot[draggable="true"]:active { cursor: grabbing; }

/* ============================================================
   创作工具 Tabs
   ============================================================ */
.creator-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.tab-btn {
  padding: 9px 22px;
  border-radius: 2px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 2px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-2);
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
}
.tab-btn:hover { border-color: var(--text-3); color: var(--ink); }
.tab-btn.active {
  background: var(--ink);
  border-color: var(--ink);
  color: #F6F4EF;
}
.tab-content { display: none; }
.tab-content.active { display: block; animation: fadeIn 0.3s ease; }

.formula-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
  margin-bottom: 14px;
  box-shadow: var(--shadow);
  transition: box-shadow 0.25s, transform 0.25s, border-color 0.25s;
}
.formula-card:hover { box-shadow: var(--shadow-lift); transform: translateY(-2px); border-color: var(--coral-border); }
.formula-name {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--ink);
  margin-bottom: 10px;
}
.formula-tpl {
  font-size: 13px;
  background: var(--bg-2);
  border-left: 3px solid var(--coral);
  padding: 12px 16px;
  border-radius: 2px;
  margin-bottom: 10px;
  font-weight: 500;
  color: var(--text);
}
.formula-example { font-size: 12px; color: var(--text-2); }
.formula-example strong { color: var(--coral-dark); }
.formula-copy { margin-top: 10px; }

.script-block {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
  margin-bottom: 14px;
  box-shadow: var(--shadow);
}
.script-block h4 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 2px;
  margin-bottom: 6px;
  color: var(--ink);
}
.script-time {
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--coral-dark);
  font-weight: 600;
  margin-bottom: 10px;
}
.script-block p {
  font-size: 13px;
  color: var(--text-2);
  line-height: 1.8;
}
.script-tips {
  margin-top: 10px;
  font-size: 12px;
  color: var(--amber);
  background: var(--amber-bg);
  border-left: 3px solid var(--amber);
  padding: 10px 14px;
  border-radius: 2px;
}

.cover-guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}
.cover-demo {
  aspect-ratio: 3/4;
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 16px;
  border: 1px solid var(--border);
  transition: transform 0.25s, box-shadow 0.25s;
}
.cover-demo:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.cover-demo .cd-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.35;
  margin-bottom: 8px;
  letter-spacing: 1px;
}
.cover-demo .cd-sub { font-size: 10px; font-weight: 500; letter-spacing: 2px; }
.cover-demo .cd-label {
  font-size: 10px;
  letter-spacing: 2px;
  color: var(--text-3);
  margin-top: auto;
  padding-top: 14px;
}
.cover-demo.s1 {
  background: var(--ink);
  color: #F6F4EF;
  border-color: var(--ink);
}
.cover-demo.s1 .cd-sub { color: #C9A961; }
.cover-demo.s1 .cd-label { color: rgba(246,244,239,0.45); }
.cover-demo.s2 { background: var(--coral-bg); color: var(--coral-dark); border-color: var(--coral-border); }
.cover-demo.s3 { background: var(--blue-bg); color: var(--blue-dark); border-color: var(--blue-border); }

.kw-group { margin-bottom: 18px; }
.kw-group-title {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 2px;
  margin-bottom: 10px;
  color: var(--ink);
}
.kw-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.kw-tag {
  font-size: 12px;
  padding: 5px 14px;
  border-radius: 2px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  letter-spacing: 1px;
}
.kw-tag:hover { transform: translateY(-1px); }
.kw-tag.k1 { background: var(--coral-bg); color: var(--coral-dark); }
.kw-tag.k2 { background: var(--blue-bg); color: var(--blue-dark); }
.kw-tag.k3 { background: var(--teal-bg); color: var(--teal-dark); }
.kw-tag.k4 { background: var(--amber-bg); color: var(--amber); }

/* ============================================================
   消息列表
   ============================================================ */
.news-item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 12px;
  box-shadow: var(--shadow);
  transition: box-shadow 0.25s, transform 0.25s;
}
.news-item:hover { box-shadow: var(--shadow-lift); transform: translateY(-2px); }
.news-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.news-title { font-size: 14px; font-weight: 600; flex: 1; color: var(--ink); }
.news-cat {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 2px;
  font-weight: 500;
  letter-spacing: 1px;
  flex-shrink: 0;
}
.news-cat.运营商政策 { background: var(--blue-bg); color: var(--blue-dark); }
.news-cat.行业监管 { background: var(--red-bg); color: var(--red); }
.news-cat.竞品动态 { background: var(--purple-bg); color: var(--purple); }
.news-cat.江西本地 { background: var(--teal-bg); color: var(--teal-dark); }
.news-detail {
  font-size: 12px;
  color: var(--text-2);
  margin-bottom: 10px;
  line-height: 1.7;
}
.news-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--text-3);
}
.news-actions { display: flex; gap: 8px; }

/* ============================================================
   粉丝互动
   ============================================================ */
.fans-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.faq-item {
  padding: 14px 0;
  border-bottom: 1px solid var(--border-light);
}
.faq-item:last-child { border-bottom: none; }
.faq-q {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--ink);
}
.faq-a {
  font-size: 12px;
  color: var(--text-2);
  line-height: 1.7;
}
.faq-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--text-3);
}

/* ============================================================
   数据分析
   ============================================================ */
.analytics-table-wrap { overflow-x: auto; }
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 640px;
}
.data-table th {
  text-align: left;
  padding: 12px 14px;
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--text-3);
  font-weight: 500;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.data-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--border-light);
  white-space: nowrap;
  color: var(--text-2);
  font-variant-numeric: lining-nums;
}
.data-table tbody tr { transition: background 0.15s; }
.data-table tbody tr:hover { background: var(--bg-hover); }
.data-table td:first-child {
  font-weight: 500;
  white-space: normal;
  min-width: 180px;
  color: var(--ink);
}
.rate-good { color: var(--teal-dark); font-weight: 600; }
.rate-mid { color: var(--amber); font-weight: 600; }
.rate-bad { color: var(--text-3); }

/* ============================================================
   AI助手
   ============================================================ */
.ai-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.ai-result {
  margin-top: 18px;
  display: none;
}
.ai-result.show { display: block; }
.ai-result-item {
  background: var(--bg-2);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 8px;
  font-size: 13px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  transition: border-color 0.2s;
}
.ai-result-item:hover { border-color: var(--coral-border); }
.ai-result-item .formula-tag {
  font-size: 10px;
  letter-spacing: 1px;
  color: var(--text-3);
  flex-shrink: 0;
  margin-top: 3px;
}
.ai-script-section { margin-bottom: 14px; }
.ai-script-section h5 {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--coral-dark);
  margin-bottom: 6px;
}
.ai-script-section p {
  font-size: 12px;
  color: var(--text-2);
  line-height: 1.8;
}

/* ============================================================
   表单
   ============================================================ */
.form-group { margin-bottom: 16px; }
.form-group label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 1px;
  color: var(--text-2);
  margin-bottom: 7px;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 2px;
  font-size: 13px;
  font-family: inherit;
  color: var(--text);
  background: #FFFFFF;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text-3); }
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--coral);
  box-shadow: 0 0 0 3px rgba(168,137,74,0.12);
}
.form-group textarea { resize: vertical; }
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.form-row.four { grid-template-columns: repeat(4, 1fr); }

/* ============================================================
   弹窗
   ============================================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(30,28,24,0.45);
  backdrop-filter: blur(3px);
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay.show { display: flex; }
.modal {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 100%;
  max-width: 540px;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalIn 0.28s ease;
  box-shadow: 0 32px 80px rgba(30,28,24,0.28);
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(0.97) translateY(12px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 22px 24px 0;
}
.modal-header h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 3px;
  color: var(--ink);
}
.modal-close {
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: transparent;
  font-size: 16px;
  cursor: pointer;
  color: var(--text-2);
  transition: all 0.2s;
}
.modal-close:hover { border-color: var(--ink); color: var(--ink); }
.modal-body { padding: 18px 24px; }
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 0 24px 22px;
}

/* ============================================================
   Toast
   ============================================================ */
.toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--ink);
  color: #F6F4EF;
  padding: 12px 28px;
  border-radius: 2px;
  font-size: 13px;
  letter-spacing: 2px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s;
  z-index: 300;
  box-shadow: 0 16px 40px rgba(30,28,24,0.3);
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ============================================================
   移动端底部导航
   ============================================================ */
.mobile-nav {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: var(--mobile-nav-h);
  background: rgba(251,250,247,0.96);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--border);
  z-index: 100;
  padding: 0 4px;
}
.mobile-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  text-decoration: none;
  color: var(--text-3);
  font-size: 16px;
  transition: color 0.2s;
}
.mobile-nav-item small { font-size: 10px; letter-spacing: 1px; }
.mobile-nav-item.active { color: var(--coral-dark); }

/* ============================================================
   运营助理
   ============================================================ */
.nav-item.premium {
  background: var(--coral-bg);
  font-weight: 600;
  margin-top: 10px;
  border: 1px solid var(--coral-border);
  border-left: 2px solid transparent;
  color: var(--coral-dark);
}
.nav-item.premium:hover {
  background: rgba(168,137,74,0.14);
  border-color: var(--coral);
  color: var(--coral-dark);
}
.nav-item.premium .nav-icon { color: var(--coral-dark); }
.nav-item.premium.active {
  border-left-color: var(--coral);
  color: var(--coral-dark);
}
.mobile-nav-item.premium { color: var(--coral-dark); }

.assistant-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

/* 诊断报告卡片 */
.assistant-report { }
.report-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 16px;
  animation: fadeIn 0.35s ease;
  box-shadow: var(--shadow);
}
.report-card .report-icon {
  font-size: 24px;
  margin-bottom: 10px;
}
.report-card .report-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 3px;
  color: var(--ink);
  margin-bottom: 14px;
}
.report-card .report-body {
  font-size: 13px;
  color: var(--text-2);
  line-height: 1.9;
}
.report-card .report-body ul {
  list-style: none;
  padding: 0;
  margin: 10px 0;
}
.report-card .report-body li {
  padding: 6px 0;
  padding-left: 20px;
  position: relative;
}
.report-card .report-body li::before {
  content: "—";
  position: absolute;
  left: 0;
  color: var(--coral);
  font-size: 11px;
}
.report-card.good { border-left: 3px solid var(--teal); }
.report-card.warn { border-left: 3px solid var(--amber); }
.report-card.bad { border-left: 3px solid var(--red); }
.report-card.info { border-left: 3px solid var(--blue); }

.report-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 12px;
  margin: 16px 0;
}
.report-stat {
  background: var(--bg-2);
  border-radius: var(--radius-sm);
  padding: 16px 12px;
  text-align: center;
}
.report-stat .rs-value {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 600;
  color: var(--ink);
  font-variant-numeric: lining-nums;
}
.report-stat .rs-label {
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--text-3);
  margin-top: 4px;
}
.report-stat.rs-good .rs-value { color: var(--teal-dark); }
.report-stat.rs-warn .rs-value { color: var(--amber); }
.report-stat.rs-bad .rs-value { color: var(--red); }

.report-pillar-bar {
  display: flex;
  height: 30px;
  border-radius: 2px;
  overflow: hidden;
  margin: 12px 0;
}
.report-pillar-bar .bar-seg {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 600;
  color: #fff;
  min-width: 0;
  overflow: hidden;
  letter-spacing: 1px;
}
.bar-seg.s1 { background: var(--blue); }
.bar-seg.s2 { background: var(--teal); }
.bar-seg.s3 { background: var(--coral); }
.bar-seg.s4 { background: var(--purple); }
.bar-seg.s5 { background: var(--amber); }
.report-pillar-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--text-2);
  margin-top: 8px;
}
.report-pillar-legend .dot {
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 1px;
  margin-right: 5px;
}

/* 聊天界面 */
.assistant-chat-log {
  min-height: 200px;
  max-height: 420px;
  overflow-y: auto;
  padding: 6px 0;
  margin-bottom: 14px;
}
.chat-bubble {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  align-items: flex-start;
}
.chat-bubble.user { flex-direction: row-reverse; }
.chat-avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}
.chat-bubble.bot .chat-avatar {
  background: var(--ink);
  color: #C9A961;
}
.chat-bubble.user .chat-avatar {
  background: var(--coral-bg);
  color: var(--coral-dark);
  border: 1px solid var(--coral-border);
}
.chat-content { max-width: 80%; }
.chat-text {
  font-size: 13px;
  line-height: 1.8;
  color: var(--text);
  padding: 12px 16px;
  border-radius: 3px;
}
.chat-bubble.bot .chat-text {
  background: var(--bg-2);
  border: 1px solid var(--border-light);
  border-top-left-radius: 0;
}
.chat-bubble.user .chat-text {
  background: var(--coral-bg);
  border: 1px solid var(--coral-border);
  color: var(--coral-dark);
  border-top-right-radius: 0;
}
.chat-text strong { color: var(--coral-dark); }
.chat-text em { color: var(--text-3); font-style: normal; }
.chat-text ul { padding-left: 16px; margin: 6px 0; }
.chat-text li { margin: 4px 0; }

.assistant-input-row {
  display: flex;
  gap: 10px;
}
.assistant-input {
  flex: 1;
  padding: 11px 16px;
  border: 1px solid var(--border);
  border-radius: 2px;
  font-size: 13px;
  font-family: inherit;
  background: #FFFFFF;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.assistant-input::placeholder { color: var(--text-3); }
.assistant-input:focus {
  border-color: var(--coral);
  box-shadow: 0 0 0 3px rgba(168,137,74,0.12);
}

/* ============================================================
   今日选题推荐
   ============================================================ */
.recommend-card {
  margin-bottom: 18px;
  border-top: 2px solid var(--coral);
}
.rec-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
.rec-item {
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  background: var(--bg-2);
  border: 1px solid var(--border-light);
  position: relative;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.rec-item:hover {
  border-color: var(--coral-border);
  box-shadow: var(--shadow-lift);
  transform: translateY(-2px);
}
.rec-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 8px;
  line-height: 1.5;
}
.rec-meta {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-bottom: 8px;
}
.rec-pillar {
  font-size: 10px;
  letter-spacing: 1px;
  padding: 2px 8px;
  border-radius: 2px;
  background: var(--blue-bg);
  color: var(--blue-dark);
  font-weight: 500;
}
.rec-format {
  font-size: 10px;
  letter-spacing: 1px;
  padding: 2px 8px;
  border-radius: 2px;
}
.rec-format.video { background: var(--coral-bg); color: var(--coral-dark); }
.rec-format.image { background: var(--teal-bg); color: var(--teal-dark); }
.rec-reason {
  font-size: 11px;
  color: var(--text-3);
  margin-bottom: 10px;
  line-height: 1.6;
}
.rec-add-btn {
  font-size: 11px;
  padding: 4px 12px;
}

/* ============================================================
   滚动条
   ============================================================ */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-3); }

/* ============================================================
   响应式
   ============================================================ */
@media (max-width: 900px) {
  .dashboard-grid,
  .fans-grid,
  .ai-grid { grid-template-columns: 1fr; }
  .calendar-week { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 5px; }
  .cal-day { min-height: 104px; padding: 7px; }
  .assistant-actions { flex-direction: column; }
  .assistant-actions .btn { width: 100%; text-align: center; justify-content: center; }
  .assistant-chat-log { max-height: 320px; }
  .main { padding: 32px 28px 60px; }
}

@media (max-width: 768px) {
  .sidebar { display: none; }
  .mobile-header { display: flex; }
  .mobile-nav { display: flex; }
  .main {
    margin-left: 0;
    padding: calc(var(--mobile-header-h) + 18px) 16px calc(var(--mobile-nav-h) + 26px);
  }
  .page-header h2 { font-size: 24px; letter-spacing: 3px; }
  .form-row.four { grid-template-columns: repeat(2, 1fr); }
  .calendar-week { display: flex; flex-direction: column; gap: 8px; }
  .cal-day { min-height: auto; }
  .cal-slot { display: inline-block; margin-right: 4px; }
  .toast { bottom: calc(var(--mobile-nav-h) + 16px); }
  .topic-top { flex-direction: column; gap: 8px; }
  .topic-badges { flex-shrink: 1; }
  .charts-grid { grid-template-columns: 1fr !important; }
  .drag-source-bar { flex-wrap: nowrap; overflow-x: auto; }
  .rec-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   动效偏好
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
