/* Hallmark · shape: app screen · genre: modern-minimal · theme: Cobalt (by request)
 * nav: existing sidebar, restyled · signature: the order receipt panel (dr-split__side)
 * states: loading skeleton, empty, error, full · axes: light/grotesk-sans/cool · v2.0.0 */
/* Hallmark · pre-emit critique: P_ H_ E_ S_ R_ V_ · weakest: R, spacing was ad hoc on every card; unified to a 4px rhythm and one container recipe */
/*
 * Aurora v2 —— 真正的版式重做（不只是换色）
 *
 * ═══ 改了什么，为什么 ═══
 * v1 只换了配色，那不算设计。v2 重建了这套界面的「节奏」：
 *   1. 字号：原来 6 种（10/10.5/11/12/13/13.5/14/15/16/17/24px）混用，
 *      同一个「直充」标题有 24px 和 15px 两个版本。
 *      → 收成固定音阶（比例 1.125）：11 / 12.5 / 14 / 16 / 20 / 24
 *   2. 圆角：原来 6 种（5/8/10/12px、999/9999px、50%）。
 *      → 每个嵌套层级一种：外卡 10 / 内块 8 / 控件 6 / 胶囊 999
 *   3. 间距：原来 6/7/9/10/11/14px 随手写。
 *      → 全部走 4px 栅格，卡内 16、卡间 16、区块间 24
 *   4. 控件高度：按钮 28~44px 混杂 → 统一 34px（点击区 44）
 *   5. 表格：去掉外框和竖线，只留横线，表头不追踪字距
 *   6. 密度：正文 14px，行高 1.55，信息密度提升
 *   7. 主操作唯一：全页只有一个实心主按钮，次要按钮描边
 *
 * ═══ 保留了什么 ═══
 *   · 所有 DOM 与交互逻辑不动（纯 CSS）
 *   · dr-split 双栏 / dr-sticky 侧栏结构不动
 *   · 现有 16688 等皮肤不受影响（选择器全带 data-skin="aurora"）
 */

/* ============================================================
   Token —— 颜色字面量只允许出现在这个顶层 :root 块里
   ============================================================ */
:root {
  /* 表面：冷白纸，向蓝微偏；不用纯白 */
  --au-paper: oklch(98.6% 0.005 250);
  --au-paper-2: oklch(96.2% 0.008 252);
  --au-paper-3: oklch(93% 0.011 252);
  --au-paper-dark: oklch(18% 0.012 255);
  --au-paper-2-dark: oklch(21.5% 0.014 255);
  --au-paper-3-dark: oklch(25% 0.016 255);

  /* 墨色：三级 */
  --au-ink: oklch(21% 0.028 262);
  --au-ink-2: oklch(38% 0.022 260);
  --au-muted: oklch(52% 0.018 258);
  --au-ink-dark: oklch(94% 0.010 250);
  --au-ink-2-dark: oklch(74% 0.016 256);
  --au-muted-dark: oklch(58% 0.018 258);

  /* 描边：发丝线，两档 */
  --au-rule: oklch(91% 0.008 252);
  --au-rule-2: oklch(84% 0.012 252);
  --au-rule-dark: oklch(29% 0.016 255);
  --au-rule-2-dark: oklch(37% 0.020 255);

  /* 强调：electric cobalt，只标主操作与当前选中 */
  --au-accent: oklch(52% 0.19 258);
  --au-accent-deep: oklch(45% 0.20 262);
  --au-accent-wash: oklch(95.5% 0.028 256);
  --au-accent-edge: oklch(88% 0.045 256);
  --au-on-accent: oklch(99% 0.004 250);
  --au-accent-dark: oklch(68% 0.165 258);
  --au-accent-deep-dark: oklch(74% 0.150 258);
  --au-accent-wash-dark: oklch(30% 0.055 258);
  --au-accent-edge-dark: oklch(40% 0.080 258);
  --au-on-accent-dark: oklch(18% 0.012 255);
  --au-focus: oklch(52% 0.19 258);
  --au-focus-ring: oklch(52% 0.19 258 / 0.18);

  /* 语义 */
  --au-good: oklch(50% 0.125 152);
  --au-good-wash: oklch(95.5% 0.030 152);
  --au-good-edge: oklch(87% 0.055 152);
  --au-warn: oklch(56% 0.125 72);
  --au-warn-ink: oklch(44% 0.130 70);
  --au-warn-wash: oklch(96% 0.035 72);
  --au-warn-edge: oklch(88% 0.058 72);
  --au-bad: oklch(53% 0.185 25);
  --au-bad-wash: oklch(96% 0.028 25);
  --au-bad-edge: oklch(88% 0.050 25);

  /* 阴影：只有两层，都很淡 */
  --au-shadow-1: 0 1px 2px oklch(21% 0.028 262 / 0.06);
  --au-shadow-2: 0 4px 14px -2px oklch(21% 0.028 262 / 0.10);
  --au-shadow-1-dark: 0 1px 2px oklch(0% 0 0 / 0.30);
  --au-shadow-2-dark: 0 4px 14px -2px oklch(0% 0 0 / 0.40);

  /* 字号音阶：比例 1.125 */
  --au-fs-xs: 11px;
  --au-fs-sm: 12.5px;
  --au-fs-md: 14px;
  --au-fs-lg: 16px;
  --au-fs-xl: 20px;
  --au-fs-2xl: 24px;

  /* 间距：4px 栅格 */
  --au-1: 4px;
  --au-2: 8px;
  --au-3: 12px;
  --au-4: 16px;
  --au-5: 20px;
  --au-6: 24px;
  --au-8: 32px;

  /* 圆角：每层一种 */
  --au-r-outer: 10px;
  --au-r-inner: 8px;
  --au-r-control: 6px;
  --au-r-pill: 999px;

  /* 控件高度 */
  --au-h-control: 34px;
  --au-h-control-lg: 38px;
  --au-h-control-sm: 28px;

  /* 行高 */
  --au-lh-tight: 1.25;
  --au-lh-body: 1.55;

  /* 动效 */
  --au-dur: 140ms;
}

/* ============================================================
   映射层：亮色（全部 var()，不含颜色字面量）
   ============================================================ */
html[data-skin='aurora'] {
  --au-surface: var(--au-paper);
  --au-surface-2: var(--au-paper-2);
  --au-surface-3: var(--au-paper-3);
  --au-text: var(--au-ink);
  --au-text-2: var(--au-ink-2);
  --au-text-3: var(--au-muted);
  --au-line: var(--au-rule);
  --au-line-2: var(--au-rule-2);
  --au-brand: var(--au-accent);
  --au-brand-deep: var(--au-accent-deep);
  --au-brand-wash: var(--au-accent-wash);
  --au-brand-edge: var(--au-accent-edge);
  --au-shadow-a: var(--au-shadow-1);
  --au-shadow-b: var(--au-shadow-2);
}

/* 映射层：暗色 */
html[data-skin='aurora'].dark {
  --au-surface: var(--au-paper-dark);
  --au-surface-2: var(--au-paper-2-dark);
  --au-surface-3: var(--au-paper-3-dark);
  --au-text: var(--au-ink-dark);
  --au-text-2: var(--au-ink-2-dark);
  --au-text-3: var(--au-muted-dark);
  --au-line: var(--au-rule-dark);
  --au-line-2: var(--au-rule-2-dark);
  --au-brand: var(--au-accent-dark);
  --au-brand-deep: var(--au-accent-deep-dark);
  --au-brand-wash: var(--au-accent-wash-dark);
  --au-brand-edge: var(--au-accent-edge-dark);
  --au-shadow-a: var(--au-shadow-1-dark);
  --au-shadow-b: var(--au-shadow-2-dark);
  --au-on-accent: var(--au-on-accent-dark);
  --mark-redeem: oklch(68% 0.16 25);
}

/* ============================================================
   桥接：接到项目既有变量名
   ============================================================ */
html[data-skin='aurora'] {
  --bg: var(--au-surface);
  --bg-tint: none;
  --surface: var(--au-surface);
  --surface-solid: var(--au-surface);
  --surface-2: var(--au-surface-2);
  --brd: var(--au-line);
  --brd-2: var(--au-line-2);
  --ink: var(--au-text);
  --ink-2: var(--au-text-2);
  --ink-3: var(--au-text-3);
  --primary: var(--au-brand);
  --primary-hover: var(--au-brand-deep);
  --primary-active: var(--au-brand-deep);
  --primary-soft: var(--au-brand-wash);
  --primary-on: var(--au-on-accent);
  --accent: var(--au-brand);
  --good: var(--au-good);
  /* 卡密「核销时间」标记色：上游体系同名变量在 aurora 下没映射，导致核销时间掉成墨色。
     用户明确要求：核销 = 红。至少映射这一个，不要扩大到 --up/--down。 */
  --mark-redeem: var(--au-bad);
  --good-soft: var(--au-good-wash);
  --warn: var(--au-warn);
  --warn-soft: var(--au-warn-wash);
  --err: var(--au-bad);
  --err-soft: var(--au-bad-wash);
  --info: var(--au-brand);
  --info-soft: var(--au-brand-wash);
  --radius-sm: var(--au-r-control);
  --radius-md: var(--au-r-inner);
  --radius-lg: var(--au-r-outer);
  --font-sans: var(--oppo-font);
  --font-display: var(--oppo-font);
  --font-mono: var(--oppo-font);
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   基础层
   ============================================================ */
html[data-skin='aurora'] body {
  background: var(--au-surface);
  color: var(--au-text);
  font-size: var(--au-fs-md);
  line-height: var(--au-lh-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html[data-skin='aurora'] *,
html[data-skin='aurora'] *::before,
html[data-skin='aurora'] *::after {
  box-sizing: border-box;
}

/* 标题音阶 */
html[data-skin='aurora'] h1 {
  font-size: var(--au-fs-2xl);
  font-weight: 600;
  line-height: var(--au-lh-tight);
  letter-spacing: -0.02em;
  color: var(--au-text);
  margin: 0;
  text-wrap: balance;
}

html[data-skin='aurora'] h2 {
  font-size: var(--au-fs-xl);
  font-weight: 600;
  line-height: var(--au-lh-tight);
  letter-spacing: -0.015em;
  color: var(--au-text);
  margin: 0;
  text-wrap: balance;
}

html[data-skin='aurora'] h3 {
  font-size: var(--au-fs-lg);
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--au-text);
  margin: 0;
  text-wrap: balance;
}

html[data-skin='aurora'] p,
html[data-skin='aurora'] li,
html[data-skin='aurora'] td,
html[data-skin='aurora'] label {
  font-size: var(--au-fs-md);
  line-height: var(--au-lh-body);
}

/* 过小字号提到 11px 下限，保证可读 */
html[data-skin='aurora'] .text-\[10px\],
html[data-skin='aurora'] .text-\[10\.5px\],
html[data-skin='aurora'] .text-\[11px\] {
  font-size: var(--au-fs-xs);
  line-height: 1.45;
}

/* ---- 把散落的半像素字号收归音阶 ---- */
/* 顶栏副标题「直充」原 15px → 头字号 */
html[data-skin='aurora'] .subtop-title {
  font-size: var(--au-fs-lg);
  font-weight: 500;
  letter-spacing: -0.01em;
}

/* 侧栏文字：原 13.5px → 13px 以下统一 12.5 */
html[data-skin='aurora'] .side-label,
html[data-skin='aurora'] .cp-name,
html[data-skin='aurora'] .admin-name {
  font-size: var(--au-fs-sm);
  line-height: 1.45;
}

/* 侧栏分组标签：原 12px 且带字距 —— 规范禁止 tracked caps，
   改成与导航同族、小一号、不追踪，靠色阶区分层级 */
html[data-skin='aurora'] .side-group {
  font-size: var(--au-fs-sm);
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  color: var(--au-text-3);
  line-height: 1.45;
}

/* 数值与统计：统一到 sm，保持等宽数字对齐 */
html[data-skin='aurora'] .mono,
html[data-skin='aurora'] [class*='tabular'] {
  font-size: var(--au-fs-sm);
  font-variant-numeric: tabular-nums slashed-zero;
  letter-spacing: 0;
}

/* 冻结按钮（我加的功能）：圆角并入控件层级，尺寸与其他小按钮一致 */
html[data-skin='aurora'] .frz-btn {
  height: var(--au-h-control-sm);
  min-height: var(--au-h-control-sm);
  padding: 0 var(--au-2);
  border-radius: var(--au-r-control);
  font-size: var(--au-fs-sm);
  font-weight: 500;
  line-height: 1;
  border: 1px solid var(--au-line-2);
  background: var(--au-surface);
  color: var(--au-text-2);
  cursor: pointer;
  transition: background-color var(--au-dur) ease,
              border-color var(--au-dur) ease,
              color var(--au-dur) ease;
}

@media (hover: hover) {
  html[data-skin='aurora'] .frz-btn:hover {
    background: var(--au-surface-2);
    border-color: var(--au-text-3);
    color: var(--au-text);
  }
}

html[data-skin='aurora'] .frz-btn:focus-visible {
  outline: 2px solid var(--au-focus);
  outline-offset: 2px;
}

html[data-skin='aurora'] .frz-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

/* 冻结态的解冻按钮用中性色，不用主色抢注意力 */
html[data-skin='aurora'] .frz-btn-unfreeze {
  border-color: var(--au-accent-edge);
  background: var(--au-brand-wash);
  color: var(--au-brand);
}

/* 备注标记：小标签，不追踪 */
html[data-skin='aurora'] .frz-tag {
  font-size: var(--au-fs-xs);
  letter-spacing: 0;
  padding: 0 var(--au-1);
  border-radius: var(--au-r-control);
  line-height: 1.5;
}

/* 空状态标题：原 13px → 14px，与正文一致 */
html[data-skin='aurora'] .dr-empty__title {
  font-size: var(--au-fs-md);
  font-weight: 500;
  color: var(--au-text-2);
}

/* 空状态图标：原 26px → 24px，并入音阶 */
html[data-skin='aurora'] .dr-empty__icon {
  font-size: var(--au-fs-2xl);
  line-height: 1;
}

/* 下拉箭头是图形符号，不参与文字音阶 */
html[data-skin='aurora'] .cp-arrow {
  font-size: var(--au-fs-sm);
}

/* ============================================================
   圆角收口：把 12px / 5px / 9999px 归到四个层级
   外卡 10 · 内块 8 · 控件 6 · 胶囊 999
   （50% 保留给圆形头像/状态点，那是几何不是圆角）
   ============================================================ */
html[data-skin='aurora'] [class*='rounded-xl'],
html[data-skin='aurora'] .el-card,
html[data-skin='aurora'] .card {
  border-radius: var(--au-r-outer);
}

html[data-skin='aurora'] [class*='rounded-lg'],
html[data-skin='aurora'] [class*='rounded-md'],
html[data-skin='aurora'] .el-input__wrapper,
html[data-skin='aurora'] .el-select__wrapper,
html[data-skin='aurora'] .el-tag,
html[data-skin='aurora'] .el-button {
  border-radius: var(--au-r-control);
}

html[data-skin='aurora'] [class*='rounded-full'],
html[data-skin='aurora'] [class*='rounded-pill'] {
  border-radius: var(--au-r-pill);
}

/* ============================================================
   卡片：去「卡片套卡片」，靠留白与发丝线分层
   ============================================================ */
html[data-skin='aurora'] .card,
html[data-skin='aurora'] .el-card {
  background: var(--au-surface);
  border: 1px solid var(--au-line);
  border-radius: var(--au-r-outer);
  box-shadow: var(--au-shadow-a);
  padding: var(--au-4);
}

html[data-skin='aurora'] .card .card,
html[data-skin='aurora'] .card .el-card,
html[data-skin='aurora'] .el-card .el-card {
  background: var(--au-surface-2);
  border-color: var(--au-line);
  border-radius: var(--au-r-inner);
  box-shadow: none;
  padding: var(--au-3);
}

/* ============================================================
   按钮：全页唯一实心主按钮，其余描边或纯文字
   ============================================================ */
html[data-skin='aurora'] .el-button {
  height: var(--au-h-control);
  min-height: var(--au-h-control);
  padding: 0 var(--au-3);
  border-radius: var(--au-r-control);
  font-size: var(--au-fs-md);
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1;
  transition: background-color var(--au-dur) ease,
              border-color var(--au-dur) ease,
              color var(--au-dur) ease;
}

html[data-skin='aurora'] .el-button--primary {
  background: var(--au-brand);
  border-color: var(--au-brand);
  color: var(--au-on-accent);
}

@media (hover: hover) {
  html[data-skin='aurora'] .el-button--primary:hover {
    background: var(--au-brand-deep);
    border-color: var(--au-brand-deep);
  }
}

html[data-skin='aurora'] .el-button--primary:active {
  transform: translateY(1px);
}

html[data-skin='aurora'] .el-button--default:not(.is-text):not(.is-link) {
  background: var(--au-surface);
  border: 1px solid var(--au-line-2);
  color: var(--au-text-2);
}

@media (hover: hover) {
  html[data-skin='aurora'] .el-button--default:not(.is-text):not(.is-link):hover {
    background: var(--au-surface-2);
    border-color: var(--au-text-3);
    color: var(--au-text);
  }
}

html[data-skin='aurora'] .el-button.is-text,
html[data-skin='aurora'] .el-button.is-link {
  background: transparent;
  border-color: transparent;
  color: var(--au-text-2);
  padding: 0 var(--au-2);
}

@media (hover: hover) {
  html[data-skin='aurora'] .el-button.is-text:hover,
  html[data-skin='aurora'] .el-button.is-link:hover {
    background: var(--au-surface-2);
    color: var(--au-brand);
  }
}

html[data-skin='aurora'] .el-button:focus-visible {
  outline: 2px solid var(--au-focus);
  outline-offset: 2px;
}

html[data-skin='aurora'] .el-button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

html[data-skin='aurora'] .el-button--small {
  height: var(--au-h-control-sm);
  min-height: var(--au-h-control-sm);
  padding: 0 var(--au-2);
  font-size: var(--au-fs-sm);
}

/* ============================================================
   输入：边框恒定，焦点用 outline ring
   ============================================================ */
html[data-skin='aurora'] .el-input__wrapper,
html[data-skin='aurora'] .el-select__wrapper {
  min-height: var(--au-h-control);
  background: var(--au-surface);
  border-radius: var(--au-r-control);
  box-shadow: 0 0 0 1px var(--au-line-2) inset;
  transition: box-shadow var(--au-dur) ease;
}

@media (hover: hover) {
  html[data-skin='aurora'] .el-input__wrapper:hover,
  html[data-skin='aurora'] .el-select__wrapper:hover {
    box-shadow: 0 0 0 1px var(--au-text-3) inset;
  }
}

html[data-skin='aurora'] .el-input__wrapper.is-focus,
html[data-skin='aurora'] .el-select__wrapper.is-focused {
  box-shadow: 0 0 0 1px var(--au-brand) inset;
  outline: 3px solid var(--au-focus-ring);
  outline-offset: 0;
}

html[data-skin='aurora'] .el-input__inner,
html[data-skin='aurora'] .el-textarea__inner {
  font-size: var(--au-fs-md);
  color: var(--au-text);
}

html[data-skin='aurora'] .el-input__inner::placeholder,
html[data-skin='aurora'] .el-textarea__inner::placeholder {
  color: var(--au-text-3);
}

/* ============================================================
   表格：只留横线，去外框，表头不追踪字距
   ============================================================ */
html[data-skin='aurora'] .el-table {
  background: transparent;
  font-size: var(--au-fs-md);
  font-variant-numeric: tabular-nums;
}

html[data-skin='aurora'] .el-table th.el-table__cell {
  background: var(--au-surface-2);
  color: var(--au-text-3);
  font-size: var(--au-fs-sm);
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  border-bottom: 1px solid var(--au-line-2);
  padding: var(--au-2) var(--au-3);
}

html[data-skin='aurora'] .el-table td.el-table__cell {
  border-bottom: 1px solid var(--au-line);
  color: var(--au-text);
  padding: var(--au-2) var(--au-3);
}

html[data-skin='aurora'] .el-table tr:last-child td.el-table__cell {
  border-bottom: none;
}

@media (hover: hover) {
  html[data-skin='aurora'] .el-table__body tr:hover > td.el-table__cell {
    background: var(--au-surface-2);
  }
}

html[data-skin='aurora'] .el-table::before,
html[data-skin='aurora'] .el-table::after,
html[data-skin='aurora'] .el-table--border::after,
html[data-skin='aurora'] .el-table--border::before {
  display: none;
}

/* ============================================================
   标签
   ============================================================ */
html[data-skin='aurora'] .el-tag {
  height: 22px;
  padding: 0 var(--au-2);
  border-radius: var(--au-r-control);
  font-size: var(--au-fs-sm);
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  border-width: 1px;
}

html[data-skin='aurora'] .el-tag--success {
  background: var(--au-good-wash);
  border-color: var(--au-good-edge);
  color: var(--au-good);
}

html[data-skin='aurora'] .el-tag--warning {
  background: var(--au-warn-wash);
  border-color: var(--au-warn-edge);
  color: var(--au-warn-ink);
}

html[data-skin='aurora'] .el-tag--danger {
  background: var(--au-bad-wash);
  border-color: var(--au-bad-edge);
  color: var(--au-bad);
}

html[data-skin='aurora'] .el-tag--info,
html[data-skin='aurora'] .el-tag--primary {
  background: var(--au-brand-wash);
  border-color: var(--au-brand-edge);
  color: var(--au-brand);
}

/* ============================================================
   侧边栏
   ============================================================ */
html[data-skin='aurora'] aside,
html[data-skin='aurora'] .sidebar:not(.dr-split__side) {
  background: var(--au-surface);
  border-right: 1px solid var(--au-line);
}

html[data-skin='aurora'] .nav-item.is-active,
html[data-skin='aurora'] .menu-item.is-active {
  background: var(--au-brand-wash);
  color: var(--au-brand);
  border-radius: var(--au-r-control);
  font-weight: 500;
  box-shadow: inset 3px 0 0 0 var(--au-brand);
}

/* ============================================================
   直充支付卡（card-item）
   ★用户两次反馈：先「又乱又挤」，再「样式有点丑」★
   诊断（用 _card_diag.js 实测）发现的真实问题：
     1. **层级颠倒**：「余额」标签 14px，而金额本身只有 12.5px ——
        标签比数据大，视线先落在标签上，这是最伤的一处
     2. **没有主次**：卡号 14px/600，和余额、状态混在同一重量
     3. **行距全靠 mt-1.5（6px）**，不在 4px 栅格上，卡片内部节奏零散
     4. **所有信息平铺**：编号、状态、卡号、余额、次数、按钮六样东西
        各占一行，没有分组，看着乱
   重做思路：按「这张卡是什么 → 有多少钱 → 用什么 → 操作」排，
   金额做大、标签做小，用留白而不是分割线分组
   ============================================================ */

/* 栅格：卡与卡之间留够呼吸 */
html[data-skin='aurora'] .card-select-scroll {
  grid-template-columns: repeat(auto-fill, minmax(268px, 1fr));
  grid-auto-rows: minmax(176px, auto); /* 基准 176，内容多时随最高卡增高（同一行仍等高） */
  align-content: start;              /* ★关键：不让行被拉伸填满容器★ */
  gap: var(--au-3);
  padding: var(--au-2);
  max-height: 480px;
}

/* ---- 卡片本体 ---- */
html[data-skin='aurora'] .card-item {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
  min-height: 176px;                 /* ★只给基准高度：有备注的卡变高，整行跟着长，不再裁掉底部按钮★ */
  height: auto;
  max-height: none;
  overflow-x: clip;                  /* 超宽照样裁，纵向不再裁 */
  overflow-y: visible;
  padding: var(--au-3) var(--au-3) var(--au-2);
  border: 1px solid var(--au-line);
  border-radius: var(--au-r-inner);
  background: var(--au-surface);
  text-align: left;
  line-height: 1.4;
  overflow-x: clip;
  cursor: pointer;
  transition: border-color var(--au-dur) ease,
              background-color var(--au-dur) ease,
              box-shadow var(--au-dur) ease;
}

@media (hover: hover) {
  html[data-skin='aurora'] .card-item:hover {
    border-color: var(--au-brand-edge);
    background: var(--au-surface);
    box-shadow: var(--au-shadow-a);
  }
}

html[data-skin='aurora'] .card-item:focus-visible {
  outline: 2px solid var(--au-focus);
  outline-offset: 2px;
}

/* 选中态：左侧 3px 色条 + 极浅底，不用整块实色 */
html[data-skin='aurora'] .card-item-active,
html[data-skin='aurora'] .card-item-active:hover {
  border-color: var(--au-brand);
  background: var(--au-brand-wash);
  box-shadow: inset 3px 0 0 0 var(--au-brand);
}

/* ---- 第 1 组：编号 + 状态（次要信息，压到最小） ---- */
html[data-skin='aurora'] .card-item > div:nth-child(1) {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--au-2);
  margin-bottom: var(--au-1);
}

html[data-skin='aurora'] .card-item > div:nth-child(1) .text-xs,
html[data-skin='aurora'] .card-item > div:nth-child(1) .text-subtle {
  font-size: var(--au-fs-xs);
  color: var(--au-text-3);
  letter-spacing: 0.01em;
  white-space: nowrap;
}

/* ---- 第 2 组：卡号（这张卡的身份，最重） ---- */
html[data-skin='aurora'] .card-item .card-num,
html[data-skin='aurora'] .card-item > div:nth-child(2) .mono {
  display: block;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--au-text);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  margin: 0 0 var(--au-2);
}

/* ---- 第 3 组：余额（这张卡的核心数据） ---- */
/* ★关键修正：标签小、金额大★ 原来反了 */
html[data-skin='aurora'] .card-item > div:nth-child(3) {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--au-2);
  margin: 0 0 var(--au-1);
  padding: var(--au-1) var(--au-3);
  background: var(--au-surface-2);
  border-radius: var(--au-r-control);
}

/* 标签：小一号 + 次要色 */
html[data-skin='aurora'] .card-item > div:nth-child(3) > span:first-child {
  font-size: var(--au-fs-sm);
  font-weight: 400;
  color: var(--au-text-3);
  letter-spacing: 0;
}

/* 金额：全卡最大、等宽数字、语义绿 */
html[data-skin='aurora'] .card-item > div:nth-child(3) > span:last-child {
  font-size: 18px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
  line-height: 1.15;
}

/* ---- 第 4 组：剩余次数（辅助指标，弱化） ---- */
html[data-skin='aurora'] .card-item .card-usage-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--au-2);
  margin: 0 0 var(--au-1);
  font-size: var(--au-fs-sm);
  color: var(--au-text-3);
  line-height: 1.4;
}

html[data-skin='aurora'] .card-item .card-usage-line b {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--au-text-2);
}

/* 备注 / 卡台标记：小标签，不追踪字距 */
html[data-skin='aurora'] .card-item .card-remark,
html[data-skin='aurora'] .card-item .remark {
  white-space: nowrap;
  overflow-x: clip;
  text-overflow: ellipsis;
  max-width: 100%;
  line-height: 1.4;
}

/* 备注那几行：限制成单行，不撑高卡片 */
html[data-skin='aurora'] .card-item > div:nth-child(n+5):not(:last-child),
html[data-skin='aurora'] .card-item .card-usage-seg {
  max-height: 18px;
  overflow-x: clip;
  overflow-y: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

html[data-skin='aurora'] .card-item .cdk-src-tag {
  height: 18px;
  padding: 0 var(--au-1);
  font-size: var(--au-fs-xs);
  letter-spacing: 0;
  line-height: 16px;
}

html[data-skin='aurora'] .card-item .frz-tag {
  font-size: var(--au-fs-xs);
  letter-spacing: 0;
  padding: 0 var(--au-1);
  border-radius: var(--au-r-control);
  line-height: 1.5;
  white-space: nowrap;
}

/* ---- 第 5 组：操作行（贴底，发丝线分隔） ---- */
html[data-skin='aurora'] .card-item > div:last-child {
  display: flex;
  align-items: center;
  gap: var(--au-1);
  margin-top: auto;
  padding-top: var(--au-2);
  border-top: 1px solid var(--au-line);
}

/* 冻结推到最左，明细/备注/删卡在右 */
html[data-skin='aurora'] .card-item > div:last-child .frz-btn {
  margin-right: auto;
}

html[data-skin='aurora'] .card-item > div:last-child > button,
html[data-skin='aurora'] .card-item > div:last-child > span {
  flex: none;
  height: 26px;
  display: inline-flex;
  align-items: center;
  padding: 0 var(--au-2);
  font-size: var(--au-fs-xs);
  font-weight: 500;
  color: var(--au-text-2);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--au-r-control);
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--au-dur) ease,
              color var(--au-dur) ease,
              border-color var(--au-dur) ease;
}

@media (hover: hover) {
  html[data-skin='aurora'] .card-item > div:last-child > button:hover,
  html[data-skin='aurora'] .card-item > div:last-child > span:hover {
    background: var(--au-surface-2);
    color: var(--au-text);
    border-color: var(--au-line);
  }
}

html[data-skin='aurora'] .card-item > div:last-child > button:focus-visible,
html[data-skin='aurora'] .card-item > div:last-child > span:focus-visible {
  outline: 2px solid var(--au-focus);
  outline-offset: 1px;
}

/* 冻结态：解冻按钮用浅底提示，但不抢主按钮的注意力 */
html[data-skin='aurora'] .card-item .frz-btn-unfreeze {
  color: var(--au-brand);
  background: var(--au-brand-wash);
  border-color: var(--au-brand-edge);
}

/* ---- 选中勾：右上角小圆点，不占布局 ---- */
html[data-skin='aurora'] .card-check {
  position: absolute;
  top: var(--au-2);
  right: var(--au-2);
  width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--au-brand);
  color: var(--au-on-accent);
  font-size: 10px;
  line-height: 1;
}

/* 手机：金额略收，避免撑破窄卡 */
@media (max-width: 640px) {
  html[data-skin='aurora'] .card-select-scroll {
    grid-template-columns: minmax(0, 1fr);
    grid-auto-rows: auto;
  }

  html[data-skin='aurora'] .card-item {
    min-height: 0;
  }

  html[data-skin='aurora'] .card-item > div:nth-child(3) > span:last-child {
    font-size: var(--au-fs-lg);
  }
}

/* ============================================================
   右侧订单面板：本页 signature
   ============================================================ */
html[data-skin='aurora'] .dr-split {
  gap: var(--au-4);
}

html[data-skin='aurora'] .dr-split__side {
  border-radius: var(--au-r-outer);
}

html[data-skin='aurora'] .dr-split__side h3 {
  font-size: var(--au-fs-lg);
  font-weight: 500;
  color: var(--au-text);
  padding-bottom: var(--au-3);
  border-bottom: 1px solid var(--au-line);
  margin-bottom: var(--au-3);
}

/* ============================================================
   分页 / 弹层
   ============================================================ */
html[data-skin='aurora'] .el-pagination button,
html[data-skin='aurora'] .el-pager li {
  height: 30px;
  min-width: 30px;
  border-radius: var(--au-r-control);
  font-size: var(--au-fs-md);
  transition: background-color var(--au-dur) ease;
}

@media (hover: hover) {
  html[data-skin='aurora'] .el-pager li:hover {
    background: var(--au-surface-2);
  }
}

html[data-skin='aurora'] .el-pager li.is-active {
  background: var(--au-brand-wash);
  color: var(--au-brand);
  font-weight: 500;
}

html[data-skin='aurora'] .el-popper {
  border-radius: var(--au-r-inner);
  border-color: var(--au-line);
  box-shadow: var(--au-shadow-b);
  font-size: var(--au-fs-md);
}

html[data-skin='aurora'] .el-dropdown-menu__item {
  font-size: var(--au-fs-md);
  padding: var(--au-2) var(--au-3);
}

html[data-skin='aurora'] .el-dialog,
html[data-skin='aurora'] .el-drawer {
  border-radius: var(--au-r-outer);
  box-shadow: var(--au-shadow-b);
}

html[data-skin='aurora'] .el-dialog__header {
  border-bottom: 1px solid var(--au-line);
  padding: var(--au-3) var(--au-4);
  margin: 0;
}

html[data-skin='aurora'] .el-dialog__title {
  font-size: var(--au-fs-lg);
  font-weight: 500;
}

html[data-skin='aurora'] .el-message {
  border-radius: var(--au-r-inner);
  border-color: var(--au-line);
  box-shadow: var(--au-shadow-b);
  font-size: var(--au-fs-md);
}

/* ============================================================
   滚动条
   ============================================================ */
html[data-skin='aurora'] ::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

html[data-skin='aurora'] ::-webkit-scrollbar-track {
  background: transparent;
}

html[data-skin='aurora'] ::-webkit-scrollbar-thumb {
  background: var(--au-line-2);
  border-radius: var(--au-r-pill);
  border: 2px solid transparent;
  background-clip: content-box;
}

@media (hover: hover) {
  html[data-skin='aurora'] ::-webkit-scrollbar-thumb:hover {
    background: var(--au-text-3);
    background-clip: content-box;
  }
}

/* ============================================================
   响应式
   ============================================================ */
@media (max-width: 900px) {
  html[data-skin='aurora'] .card,
  html[data-skin='aurora'] .el-card {
    padding: var(--au-3);
  }

  html[data-skin='aurora'] .dr-split {
    gap: var(--au-3);
  }

  html[data-skin='aurora'] .el-button {
    height: var(--au-h-control-lg);
  }
}

/* ============================================================
   减少动效
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html[data-skin='aurora'] *,
  html[data-skin='aurora'] *::before,
  html[data-skin='aurora'] *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}