/* ========== 全局样式：深蓝侧边栏 + 白内容区，专业后台风 ========== */
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body, #app { height: 100%; }
body {
  font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  background: #f0f2f5;
  color: #303133;
}

/* ---------- 登录页 ---------- */
.login-wrap {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0f2a4a 0%, #163d66 55%, #1c4f85 100%);
}
.login-card {
  width: 400px;
  background: #fff;
  border-radius: 10px;
  padding: 40px 36px 32px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, .28);
}
.login-card h1 { font-size: 22px; text-align: center; color: #163d66; margin-bottom: 6px; }
.login-card .sub { text-align: center; color: #909399; font-size: 13px; margin-bottom: 28px; }
.login-tip {
  margin-top: 14px;
  font-size: 12px;
  color: #e6a23c;
  background: #fdf6ec;
  border: 1px solid #faecd8;
  border-radius: 4px;
  padding: 8px 10px;
  line-height: 1.6;
}
/* 后端连通性提示条（登录页顶部） */
.backend-alert {
  margin-bottom: 16px;
  font-size: 12px;
  line-height: 1.6;
  color: #c0392b;
  background: #fdecea;
  border: 1px solid #f5c6c2;
  border-radius: 4px;
  padding: 8px 10px;
}
.backend-checking {
  margin-bottom: 16px;
  font-size: 12px;
  color: #909399;
  text-align: center;
}
/* 登录页底部独立入口（商家入驻 / 进度查询） */
.login-links {
  margin-top: 14px;
  display: flex;
  justify-content: center;
  gap: 18px;
}
.login-link {
  font-size: 13px;
  color: #163d66;
  text-decoration: none;
  cursor: pointer;
}
.login-link:hover { color: #2b6cb0; text-decoration: underline; }

/* ---------- 主布局 ---------- */
.layout { display: flex; height: 100%; }

/* 深蓝侧边栏 */
.sider {
  width: 220px;
  flex-shrink: 0;
  background: #0f2a4a;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.sider .logo {
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 1px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.sider .logo small { font-size: 11px; color: #8fb3d9; margin-left: 6px; font-weight: 400; }
.sider .menu { flex: 1; padding: 10px 0; }
/* 菜单分组标题 */
.sider .menu-group {
  padding: 14px 20px 6px;
  font-size: 12px;
  color: #5c7a99;
  letter-spacing: 1px;
}
.sider .menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 46px;
  padding: 0 20px;
  color: #b8c7d9;
  font-size: 14px;
  cursor: pointer;
  transition: all .15s;
  border-left: 3px solid transparent;
}
.sider .menu-item:hover { color: #fff; background: rgba(255, 255, 255, .06); }
.sider .menu-item.active {
  color: #fff;
  background: #1c4f85;
  border-left-color: #409eff;
}
.sider .menu-item .ico { width: 18px; text-align: center; }

/* 右侧主区 */
.main { flex: 1; display: flex; flex-direction: column; min-width: 0; }

/* 顶部栏：面包屑 + 管理员信息 */
.topbar {
  height: 60px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  box-shadow: 0 1px 4px rgba(0, 21, 41, .08);
  z-index: 2;
}
.topbar .admin-box { display: flex; align-items: center; gap: 14px; color: #606266; font-size: 14px; }
.topbar .admin-box .logout { cursor: pointer; color: #409eff; }
.topbar .admin-box .logout:hover { text-decoration: underline; }

/* 内容区 */
.content { flex: 1; overflow: auto; padding: 20px 24px; }

/* ---------- 通用页面元素 ---------- */
.page-card {
  background: #fff;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 1px 4px rgba(0, 21, 41, .06);
}
.page-card + .page-card { margin-top: 16px; }
.filter-bar { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; align-items: center; }
.pager { display: flex; justify-content: flex-end; margin-top: 16px; }
.table-img { width: 56px; height: 56px; object-fit: cover; border-radius: 4px; cursor: pointer; border: 1px solid #ebeef5; }

/* 看板统计卡片 */
.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; margin-bottom: 16px; }
.stat-card {
  background: #fff;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 1px 4px rgba(0, 21, 41, .06);
  border-top: 3px solid #409eff;
}
.stat-card.c-green { border-top-color: #67c23a; }
.stat-card.c-orange { border-top-color: #e6a23c; }
.stat-card.c-red { border-top-color: #f56c6c; }
.stat-card.c-purple { border-top-color: #8e6cc8; }
.stat-card .label { font-size: 13px; color: #909399; }
.stat-card .value { font-size: 28px; font-weight: 600; color: #303133; margin-top: 8px; }

/* 图表容器 */
.chart-box { width: 100%; height: 340px; }
.chart-half { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* 海报预览 */
.poster-wrap { display: flex; gap: 24px; flex-wrap: wrap; align-items: flex-start; }
.poster-canvas-box { border: 1px dashed #dcdfe6; border-radius: 8px; padding: 12px; background: #fafafa; }

/* ============ V4 搜索分析 / 分享与佣金 ============ */
.stat-row { margin-bottom: 4px; }
.stat-card {
  background: #fff;
  border-radius: 8px;
  padding: 14px 12px;
  border-top: 3px solid #FF6A00;
  box-shadow: 0 2px 10px rgba(0,0,0,.04);
  margin-bottom: 12px;
  min-height: 84px;
}
.stat-card .stat-num {
  font-size: 24px;
  font-weight: 700;
  color: #303133;
  line-height: 1.2;
  word-break: break-all;
}
.stat-card .stat-num.warn { color: #F5271F; }
.stat-card .stat-num.ok { color: #07A35A; }
.stat-card .stat-label {
  font-size: 12px;
  color: #909399;
  margin-top: 6px;
}
.stat-card .stat-sub {
  font-size: 11px;
  color: #FF6A00;
  margin-top: 2px;
}

.panel {
  background: #fff;
  border-radius: 8px;
  padding: 14px;
  box-shadow: 0 2px 10px rgba(0,0,0,.04);
  margin-bottom: 12px;
}
.panel-title {
  font-size: 14px;
  font-weight: 600;
  color: #303133;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.panel-tip {
  font-size: 11px;
  font-weight: 400;
  color: #A8A8A8;
}
.panel-empty {
  padding: 28px 0;
  text-align: center;
  font-size: 12px;
  color: #B8B8B8;
}
.filter-bar .hint {
  font-size: 12px;
  color: #A8A8A8;
  margin-left: 8px;
}

/* ============ V6 积分核销 / 维权签约 ============ */
.stat-box { background: #fff; border-radius: 8px; padding: 20px; text-align: center; border-top: 3px solid #FF6A00; }
.stat-box .sv { font-size: 26px; font-weight: 600; color: #303133; }
.stat-box .sl { font-size: 13px; color: #909399; margin-top: 6px; }
.form-tip { font-size: 12px; color: #909399; line-height: 1.6; margin-top: 4px; }
/* 异常门店整行高亮（风控预警） */
.el-table .risk-row { background: #fef0f0 !important; }
.el-table .risk-row:hover > td { background: #fde2e2 !important; }
