/*
 * 后台设计变量 + Element Plus 主题覆盖 (docs/新后台样式接入设计方案.md 第二节)
 *
 * 变量值取自设计稿 (Frame22)。新代码一律用变量, 不再硬编码颜色。
 * 必须排在 Element Plus 样式之后加载, 否则覆盖不生效。
 */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/Inter-Regular.otf") format("opentype"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/Inter-Medium.otf") format("opentype"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/Inter-SemiBold.otf") format("opentype"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/Inter-Bold.otf") format("opentype"); }

:root {
  /* 颜色 */
  --c-primary: #3B82F6;
  --c-primary-tint: #EFF6FF;      /* 选中项浅底 */
  --c-primary-soft: #DBEAFE;      /* 胶囊 / 浅色按钮底 */
  --c-success: #16a34a; --c-success-bg: #e8f7ee;
  --c-warning: #d97706; --c-warning-bg: #fdf3e2;
  --c-danger:  #dc2626; --c-danger-bg:  #fdecec;
  --c-info:    #64748b; --c-info-bg:    #eef1f5;
  --c-text: #0F172A;
  --c-text-2: #64748B;
  --c-text-3: #94A3B8;
  --c-text-role: #1D365E;
  --c-bg: #F8FAFC;
  --c-card: #ffffff;
  --c-line: #E5E7EB;

  /* 间距 / 圆角 / 阴影 */
  --sp-1: 4px; --sp-2: 8px; --sp-3: 12px; --sp-4: 16px; --sp-5: 24px;
  --r-1: 8px; --r-2: 10px; --r-3: 16px;
  --shadow-header: 0 2px 12px rgba(15, 23, 42, .08);
  --shadow-card: 0 2px 8px rgba(15, 23, 42, .04);
  --font: 'Inter', system-ui, -apple-system, 'PingFang SC', 'Microsoft YaHei', sans-serif;

  /* 框架尺寸 */
  --header-h: 80px;
  --sidebar-w: 200px;

  /* Element Plus 主色及浅色阶 (与主色混白 30/50/70/80/90%) */
  --el-color-primary: #3B82F6;
  --el-color-primary-light-3: #76A8F9;
  --el-color-primary-light-5: #9DC1FB;
  --el-color-primary-light-7: #C4DAFC;
  --el-color-primary-light-8: #D8E6FD;
  --el-color-primary-light-9: #EBF2FE;
  --el-color-primary-dark-2: #2F68C5;

  --el-border-radius-base: 8px;
  --el-border-radius-small: 6px;
  --el-border-color: #E5E7EB;
  --el-border-color-light: #eef1f5;
  --el-border-color-lighter: #f3f5f8;
  --el-border-color-extra-light: #f8fafc;
  --el-text-color-primary: #0F172A;
  --el-text-color-regular: #475569;
  --el-text-color-secondary: #64748B;
  --el-text-color-placeholder: #94A3B8;
  --el-bg-color-page: #F8FAFC;
  --el-font-family: var(--font);
}

body { font-family: var(--font); color: var(--c-text); -webkit-font-smoothing: antialiased; }

/* ---------- 页面卡片 (47 个页面的外层容器) ---------- */
.page-card { background: var(--c-card); border-radius: var(--r-3); border: 1px solid var(--c-line);
  box-shadow: var(--shadow-card); padding: var(--sp-5); }
.page-card > h3:first-child { font-size: 18px; font-weight: 600; color: var(--c-text); }
.toolbar { margin-bottom: var(--sp-4); display: flex; gap: var(--sp-3); align-items: center; }

/* ---------- 统计卡片 (开票 · 税务统计等 14 个页面) ---------- */
.stat-card { background: var(--c-card); border: 1px solid var(--c-line); border-radius: var(--r-3);
  padding: 18px 20px; box-shadow: var(--shadow-card); }
.stat-label { font-size: 13px; color: var(--c-text-2); margin-bottom: var(--sp-2); }
.stat-value { font-size: 28px; font-weight: 700; color: var(--c-text); line-height: 1.2; }
.stat-unit { font-size: 13px; font-weight: 400; color: var(--c-text-3); margin-left: 4px; }
.stat-sub { font-size: 12px; color: var(--c-text-3); margin-top: 6px; }
