/* ──────────────────────────────────────────────────────────────
   全局基础
   ────────────────────────────────────────────────────────────── */
* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', Arial, sans-serif;
  background: linear-gradient(160deg, #dde9ff 0%, #f5f8ff 40%, #eaf1ff 100%);
  min-height: 100vh;
  color: #1a1f36;
  -webkit-font-smoothing: antialiased;
}

#app { min-height: 100vh; }

/* ──────────────────────────────────────────────────────────────
   启动加载占位 (Vue 加载完毕前展示)
   ────────────────────────────────────────────────────────────── */
#boot-loader {
  position: fixed; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  background: linear-gradient(160deg, #dde9ff 0%, #f5f8ff 40%, #eaf1ff 100%);
  z-index: 9999;
  transition: opacity .3s;
}
.boot-spinner {
  width: 40px; height: 40px;
  border: 3px solid #c5d8fc;
  border-top-color: #1a6fe8;
  border-radius: 50%;
  animation: boot-spin .8s linear infinite;
}
.boot-text {
  margin-top: 16px;
  color: #1a6fe8;
  font-size: 14px;
  font-weight: 500;
}
@keyframes boot-spin { to { transform: rotate(360deg); } }
.boot-fade-out { opacity: 0; pointer-events: none; }

/* ──────────────────────────────────────────────────────────────
   通用工具类
   ────────────────────────────────────────────────────────────── */
.txt-center { text-align: center; }
.txt-muted  { color: #6b7280; }
.txt-blue   { color: #1a6fe8; }
.txt-mono   { font-family: 'Courier New', Consolas, Menlo, monospace; }
.gap-12     { gap: 12px; }
.mt-12      { margin-top: 12px; }
.mt-16      { margin-top: 16px; }
.mt-24      { margin-top: 24px; }
.mb-12      { margin-bottom: 12px; }
.mb-16      { margin-bottom: 16px; }
.mb-24      { margin-bottom: 24px; }
.w-full     { width: 100%; }

/* ──────────────────────────────────────────────────────────────
   前台 Hero
   ────────────────────────────────────────────────────────────── */
.hero {
  text-align: center;
  padding: 48px 20px 32px;
}
.hero h1 {
  font-size: 36px;
  font-weight: 700;
  color: #1a6fe8;
  letter-spacing: -.5px;
  margin: 0 0 12px;
}
.hero p {
  color: #6b7280;
  margin: 0 0 24px;
  font-size: 16px;
}
.hero-badges {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,.85);
  border: 1px solid #c5d8fc;
  border-radius: 20px;
  padding: 6px 14px;
  font-size: 12px;
  color: #374151;
  font-weight: 500;
}
@media (max-width: 600px) {
  .hero { padding: 32px 16px 24px; }
  .hero h1 { font-size: 26px; }
}

/* ──────────────────────────────────────────────────────────────
   前台 卡片
   ────────────────────────────────────────────────────────────── */
.page-wrap {
  max-width: 880px;
  margin: 0 auto 48px;
  padding: 0 16px;
}
.main-card {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 4px 24px rgba(26,111,232,.10);
  border: 1px solid #e0e7f5;
  overflow: hidden;
}

/* Header (前台顶部导航) */
.top-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  height: 60px;
  background: rgba(255,255,255,.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #e0e7f5;
  position: sticky; top: 0; z-index: 100;
}
.top-logo {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 18px; color: #1a6fe8;
}
@media (max-width: 600px) {
  .top-header { padding: 0 16px; }
}

/* 步骤指示 */
.steps-bar {
  display: flex;
  justify-content: center;
  padding: 28px 24px 20px;
  border-bottom: 1px solid #f0f4fd;
}
.step-circle {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: #e5e7eb;
  color: #9ca3af;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 14px;
  transition: all .3s;
  border: 2px solid #e5e7eb;
}
.step-circle.active {
  background: #1a6fe8; color: #fff; border-color: #1a6fe8;
  box-shadow: 0 0 0 5px rgba(26,111,232,.15);
}
.step-circle.done { background: #1a6fe8; color: #fff; border-color: #1a6fe8; }
.step-connector {
  flex: 1; height: 2px; background: #e0e7f5;
  margin-top: 17px; transition: background .3s;
  min-width: 20px; max-width: 80px;
}
.step-connector.done { background: #1a6fe8; }
.step-label {
  font-size: 11px;
  color: #9ca3af;
  font-weight: 500;
  margin-top: 6px;
  text-align: center;
  white-space: nowrap;
}
.step-label.active { color: #1a6fe8; font-weight: 600; }

/* 信息盒 */
.info-box {
  background: #f8faff;
  border: 1px solid #c5d8fc;
  border-radius: 10px;
  padding: 16px 20px;
}
.info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: 14px;
  border-bottom: 1px dashed #dde8f8;
}
.info-row:last-child { border-bottom: none; }
.info-label { color: #6b7280; }
.info-val   { font-weight: 600; color: #1a1f36; }
.info-val.blue { color: #1a6fe8; }

/* 结果图标 */
.result-icon {
  width: 72px; height: 72px;
  margin: 0 auto 16px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 36px;
}
.result-icon.ok   { background: #d1fae5; color: #10b981; }
.result-icon.fail { background: #fee2e2; color: #ef4444; }

/* ──────────────────────────────────────────────────────────────
   后台布局
   ────────────────────────────────────────────────────────────── */
.admin-layout {
  display: flex;
  min-height: 100vh;
  background: #f5f7fb;
}
.admin-sidebar {
  width: 230px;
  background: #1e293b;
  color: #e2e8f0;
  display: flex; flex-direction: column;
  flex-shrink: 0;
}
.admin-sidebar-header {
  padding: 24px 22px;
  font-size: 17px; font-weight: 700;
  color: #fff;
  border-bottom: 1px solid #334155;
  display: flex; align-items: center; gap: 8px;
}
.admin-nav { padding: 14px 0; flex: 1; }
.admin-nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 22px;
  color: #cbd5e1;
  text-decoration: none;
  font-size: 14px;
  cursor: pointer;
  border-left: 3px solid transparent;
  transition: all .15s;
}
.admin-nav-item:hover { background: #283548; color: #fff; }
.admin-nav-item.active {
  background: #283548;
  color: #fff;
  border-left-color: #3b82f6;
  font-weight: 600;
}
.admin-sidebar-footer {
  padding: 14px 22px;
  border-top: 1px solid #334155;
  font-size: 12px;
  color: #94a3b8;
}
.admin-main {
  flex: 1;
  padding: 28px 32px;
  overflow: auto;
}
.admin-page-title {
  font-size: 22px;
  font-weight: 700;
  color: #1a1f36;
  margin: 0 0 4px;
}
.admin-page-sub {
  color: #6b7280;
  font-size: 13px;
  margin-bottom: 20px;
}
@media (max-width: 768px) {
  .admin-layout { flex-direction: column; }
  .admin-sidebar { width: 100%; }
  .admin-main { padding: 16px; }
}

/* ──────────────────────────────────────────────────────────────
   登录页
   ────────────────────────────────────────────────────────────── */
.login-bg {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.login-card {
  width: 100%;
  max-width: 380px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 8px 32px rgba(26,111,232,.15);
  padding: 36px 32px;
}
.login-title {
  font-size: 22px;
  font-weight: 700;
  text-align: center;
  color: #1a6fe8;
  margin: 0 0 4px;
}
.login-sub {
  text-align: center;
  color: #6b7280;
  font-size: 13px;
  margin: 0 0 24px;
}

/* ──────────────────────────────────────────────────────────────
   统计卡 (Dashboard)
   ────────────────────────────────────────────────────────────── */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.stat-card {
  background: #fff;
  border: 1px solid #e0e7f5;
  border-radius: 12px;
  padding: 18px 20px;
}
.stat-card .stat-label {
  font-size: 12px;
  color: #6b7280;
  margin-bottom: 6px;
  font-weight: 500;
}
.stat-card .stat-value {
  font-size: 28px;
  font-weight: 700;
  color: #1a1f36;
  line-height: 1.2;
}
.stat-card.blue   .stat-value { color: #1a6fe8; }
.stat-card.green  .stat-value { color: #10b981; }
.stat-card.orange .stat-value { color: #f59e0b; }
.stat-card.red    .stat-value { color: #ef4444; }

/* ──────────────────────────────────────────────────────────────
   表格 (data-table 风格)
   ────────────────────────────────────────────────────────────── */
.code-block {
  background: #1e293b;
  color: #7dd3fc;
  border-radius: 8px;
  padding: 12px 14px;
  font-family: 'Courier New', monospace;
  font-size: 12px;
  line-height: 1.6;
  word-break: break-all;
  overflow-x: auto;
  max-height: 300px;
  overflow-y: auto;
}

/* Token 复制按钮 */
.copy-btn-row {
  display: flex; gap: 8px; margin-top: 10px;
  flex-wrap: wrap;
}

/* CDK 生成结果列表 */
.cdk-list {
  background: #f8faff;
  border: 1px solid #e0e7f5;
  border-radius: 8px;
  padding: 12px;
  max-height: 280px;
  overflow-y: auto;
  font-family: 'Courier New', monospace;
  font-size: 13px;
  line-height: 1.8;
}

/* v1.6.5 前台专业化优化 */
:root {
  --front-primary: #1769e0;
  --front-primary-dark: #0f4fb6;
  --front-success: #0f9f6e;
  --front-warning: #b7791f;
  --front-danger: #dc2626;
  --front-text: #172033;
  --front-muted: #69748a;
  --front-line: #dce7f8;
  --front-soft: #f5f8ff;
}

html, body {
  background:
    radial-gradient(circle at 18% 12%, rgba(76, 139, 245, .16) 0, transparent 24%),
    radial-gradient(circle at 84% 6%, rgba(20, 184, 166, .12) 0, transparent 26%),
    linear-gradient(160deg, #f7fbff 0%, #edf4ff 44%, #f8fbff 100%);
  color: var(--front-text);
}

.customer-shell { min-height: 100vh; }

.top-header {
  height: 64px;
  padding: 0 34px;
  background: rgba(255,255,255,.78);
  border-bottom: 1px solid rgba(220,231,248,.9);
  box-shadow: 0 10px 30px rgba(31, 87, 164, .06);
}

.top-logo { color: var(--front-text); gap: 12px; }

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  background: linear-gradient(135deg, var(--front-primary), #18b6a7);
  box-shadow: 0 8px 18px rgba(23,105,224,.22);
}

.top-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(15,159,110,.09);
  color: #087857;
  border: 1px solid rgba(15,159,110,.18);
  font-size: 13px;
  font-weight: 600;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 99px;
  background: #10b981;
  box-shadow: 0 0 0 4px rgba(16,185,129,.12);
}

.hero {
  max-width: 960px;
  margin: 0 auto;
  padding: 54px 20px 30px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  padding: 7px 13px;
  border-radius: 999px;
  background: rgba(255,255,255,.72);
  border: 1px solid rgba(197,216,252,.9);
  color: var(--front-primary);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 14px;
}

.hero h1 {
  color: var(--front-text);
  font-size: 42px;
  line-height: 1.15;
  letter-spacing: -1px;
  margin-bottom: 14px;
}

.hero p {
  max-width: 640px;
  margin: 0 auto 24px;
  color: var(--front-muted);
  line-height: 1.8;
}

.hero-badge {
  border-color: rgba(197,216,252,.95);
  background: rgba(255,255,255,.75);
  box-shadow: 0 8px 18px rgba(31, 87, 164, .05);
}

.page-wrap { max-width: 920px; }

.main-card {
  border-radius: 22px;
  border: 1px solid rgba(220,231,248,.95);
  box-shadow: 0 18px 48px rgba(31, 87, 164, .12);
}

.front-tabs {
  padding: 0 16px;
  background: rgba(248,251,255,.96);
  border-bottom: 1px solid var(--front-line);
}

.front-panel { background: #fff; }

.form-section {
  padding: 28px 38px 36px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 20px;
}

.section-head h3 {
  margin: 0 0 7px;
  font-size: 20px;
  color: var(--front-text);
}

.section-head p {
  margin: 0;
  color: var(--front-muted);
  font-size: 13px;
  line-height: 1.7;
}

.section-pill {
  flex-shrink: 0;
  padding: 6px 10px;
  border-radius: 999px;
  background: #eef5ff;
  color: var(--front-primary);
  font-size: 12px;
  font-weight: 700;
  border: 1px solid #d8e8ff;
}

.trust-note,
.warning-note,
.after-submit-tip {
  border-radius: 12px;
  padding: 11px 14px;
  font-size: 13px;
  line-height: 1.65;
  margin: 0 0 16px;
}

.trust-note {
  background: #f7fbff;
  border: 1px solid #dce9fb;
  color: #52627a;
}

.warning-note {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #8a5a12;
}

.after-submit-tip {
  max-width: 440px;
  margin: 0 auto 18px;
  background: #f7fbff;
  border: 1px solid #dce9fb;
  color: #52627a;
}

.clean-alert { margin-bottom: 16px; }

.button-row,
.result-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}

.grow-btn { flex: 1; }
.success-btn { background: var(--front-success) !important; border-color: var(--front-success) !important; }
.success-text { color: var(--front-success); }
.warning-text { color: var(--front-warning); }

.steps-bar {
  padding: 28px 28px 22px;
  background: linear-gradient(180deg, #fbfdff, #f7faff);
}

.steps-inner {
  display: flex;
  align-items: flex-start;
  width: 100%;
  max-width: 560px;
}

.step-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
}

.step-circle {
  width: 38px;
  height: 38px;
  background: #eef2f8;
  border-color: #e5ecf7;
}

.step-circle.active,
.step-circle.done {
  background: var(--front-primary);
  border-color: var(--front-primary);
}

.step-connector {
  margin-top: 18px;
  background: #e3ebf7;
}

.step-connector.done { background: var(--front-primary); }

.info-box {
  border-radius: 14px;
  background: #f8fbff;
  border-color: #dce8fb;
}

.info-val { text-align: right; max-width: 62%; word-break: break-all; }
.small-val { font-size: 12px; }

.result-section {
  padding: 38px 38px 40px;
  text-align: center;
}

.result-section h3 {
  margin: 0 0 8px;
  font-size: 22px;
  color: var(--front-text);
}

.result-section p {
  color: var(--front-muted);
  font-size: 14px;
  margin: 0 0 20px;
}

.result-box {
  text-align: left;
  max-width: 440px;
  margin: 0 auto 18px;
}

.query-progress { margin-top: 20px; }

.progress-head {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 7px;
  color: var(--front-muted);
}

.progress-head strong { color: var(--front-primary); }
.input-count { color: var(--front-muted); font-weight: 400; font-size: 12px; margin-left: 4px; }

.query-summary-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.mini-stat {
  padding: 13px 14px;
  border: 1px solid #e3ebf8;
  border-radius: 14px;
  background: #fbfdff;
}

.mini-stat span {
  display: block;
  font-size: 12px;
  color: var(--front-muted);
  margin-bottom: 4px;
}

.mini-stat strong {
  font-size: 22px;
  color: var(--front-text);
}

.mini-stat.success strong { color: var(--front-success); }
.mini-stat.warning strong { color: #d97706; }
.mini-stat.info strong { color: var(--front-primary); }
.mini-stat.danger strong { color: var(--front-danger); }

.table-wrap {
  margin-top: 16px;
  overflow-x: auto;
  border: 1px solid #e3ebf8;
  border-radius: 14px;
}

.front-table th {
  background: #f7faff;
  color: #52627a;
  font-weight: 700;
}

.code-cell { font-size: 12px; min-width: 180px; }
.muted-cell { color: var(--front-muted); font-size: 12px; }
.site-footer {
  display: flex;
  gap: 8px;
  justify-content: center;
  align-items: center;
  padding: 24px 16px;
  color: #8a97aa;
  font-size: 12px;
}

.footer-dot { color: #c1cad8; }

@media (max-width: 700px) {
  .top-header { padding: 0 16px; height: 58px; }
  .top-logo { font-size: 16px; }
  .brand-mark { width: 30px; height: 30px; border-radius: 10px; }
  .top-status { font-size: 12px; padding: 6px 10px; }
  .hero { padding: 34px 16px 22px; }
  .hero h1 { font-size: 28px; letter-spacing: -.4px; }
  .hero p { font-size: 14px; }
  .page-wrap { padding: 0 12px; margin-bottom: 28px; }
  .main-card { border-radius: 18px; }
  .form-section, .result-section { padding: 22px 18px 28px; }
  .section-head { flex-direction: column; gap: 10px; }
  .steps-bar { padding: 22px 14px 18px; }
  .step-circle { width: 32px; height: 32px; font-size: 12px; }
  .step-connector { min-width: 12px; margin-top: 15px; }
  .step-label { font-size: 10px; }
  .button-row, .result-actions { flex-direction: column; align-items: stretch; }
  .grow-btn { width: 100%; }
  .info-row { align-items: flex-start; gap: 12px; }
  .info-val { max-width: 58%; }
  .query-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .query-summary-grid .mini-stat:first-child { grid-column: span 2; }
  .site-footer { flex-wrap: wrap; }
}

/* 账单查询工具 v1.6.8 自有风格 */
.bill-page {
  padding: 30px 34px 38px;
  background:
    radial-gradient(circle at 0% 0%, rgba(79,145,255,.10), transparent 28%),
    radial-gradient(circle at 100% 10%, rgba(20,184,166,.09), transparent 30%),
    linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.bill-start-panel,
.bill-result-panel {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.bill-hero-card,
.bill-input-panel,
.bill-profile-card,
.bill-ledger-card,
.bill-empty {
  border: 1px solid rgba(210, 224, 245, .95);
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 16px 38px rgba(31, 87, 164, .075);
}

.bill-hero-card {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  padding: 24px;
  border-radius: 24px;
}

.bill-hero-card::after {
  content: '';
  position: absolute;
  right: -80px;
  top: -90px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  border: 34px solid rgba(26, 111, 232, .06);
  pointer-events: none;
}

.bill-hero-mark {
  width: 132px;
  height: 132px;
  border-radius: 34px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 20px;
  color: #fff;
  background:
    linear-gradient(135deg, #1a6fe8 0%, #16a394 72%, #10b981 100%);
  box-shadow: 0 18px 34px rgba(26, 111, 232, .20);
}

.bill-hero-mark span {
  font-size: 14px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
  opacity: .86;
}

.bill-hero-mark b {
  display: block;
  margin-top: 8px;
  font-size: 28px;
  line-height: 1.05;
}

.bill-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 11px;
  border-radius: 999px;
  background: #eef6ff;
  color: var(--front-primary);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .04em;
}

.bill-hero-copy h3,
.bill-result-hero h3,
.bill-profile-title h3,
.bill-ledger-head h3 {
  margin: 10px 0 8px;
  color: var(--front-text);
  font-weight: 900;
  letter-spacing: -.3px;
}

.bill-hero-copy h3,
.bill-result-hero h3 { font-size: 26px; line-height: 1.24; }
.bill-profile-title h3,
.bill-ledger-head h3 { font-size: 20px; }

.bill-hero-copy p,
.bill-result-hero p,
.bill-ledger-head p {
  margin: 0;
  color: var(--front-muted);
  font-size: 14px;
  line-height: 1.75;
}

.bill-pill-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.bill-pill-line span {
  padding: 7px 11px;
  border-radius: 999px;
  color: #41516a;
  background: #fff;
  border: 1px solid #dfeafa;
  font-size: 12px;
  font-weight: 800;
}

.bill-guide-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.bill-guide-strip div {
  position: relative;
  overflow: hidden;
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, .88);
  border: 1px solid #e4edf8;
  box-shadow: 0 10px 24px rgba(31, 87, 164, .045);
}

.bill-guide-strip b {
  display: inline-flex;
  margin-bottom: 9px;
  color: #9ba8bb;
  font-size: 13px;
  font-weight: 900;
}

.bill-guide-strip strong {
  display: block;
  color: var(--front-text);
  font-size: 15px;
  font-weight: 900;
  margin-bottom: 5px;
}

.bill-guide-strip span {
  display: block;
  color: var(--front-muted);
  font-size: 12px;
}

.bill-input-panel {
  padding: 24px;
  border-radius: 24px;
}

.bill-input-head { margin-bottom: 14px; }
.inline-code {
  color: var(--front-primary);
  font-weight: 800;
  background: #f2f7ff;
  padding: 2px 6px;
  border-radius: 7px;
}

.bill-safe-note {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin: 0 0 16px;
  padding: 14px 16px;
  border-radius: 16px;
  background: linear-gradient(135deg, #f2fbf8, #f7fbff);
  border: 1px solid #cfe9df;
  color: #3d5f5b;
  line-height: 1.65;
  font-size: 13px;
}

.bill-safe-note strong {
  flex: 0 0 auto;
  color: #0f766e;
  font-weight: 900;
}

.bill-token-area textarea {
  font-family: Consolas, Monaco, 'Courier New', monospace;
  font-size: 13px;
  line-height: 1.6;
  border-radius: 16px !important;
}

.bill-actions { margin-top: 4px; }

.bill-result-panel { animation: resultIn .24s ease-out; }

.bill-result-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 24px;
  border-radius: 24px;
  border: 1px solid rgba(180, 212, 246, .95);
  background:
    linear-gradient(135deg, rgba(238, 248, 255, .98), rgba(240, 253, 250, .92));
  box-shadow: 0 16px 38px rgba(31, 87, 164, .075);
}

.bill-result-hero h3 {
  word-break: break-word;
  margin-bottom: 4px;
}

.bill-result-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.bill-status-badge {
  display: inline-flex;
  align-items: center;
  padding: 9px 14px;
  border-radius: 999px;
  background: #0f9f6e;
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(15, 159, 110, .20);
}

.bill-dashboard-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.bill-dash-card {
  min-height: 128px;
  padding: 19px;
  border-radius: 22px;
  border: 1px solid #e3edf8;
  background: rgba(255,255,255,.94);
  box-shadow: 0 12px 28px rgba(31, 87, 164, .055);
}

.bill-dash-card.main {
  background: linear-gradient(135deg, #fff, #eef8ff);
  border-color: #cfe4fb;
}

.bill-dash-card span {
  display: block;
  margin-bottom: 10px;
  color: #667085;
  font-size: 13px;
  font-weight: 900;
}

.bill-dash-card strong {
  display: block;
  color: var(--front-text);
  font-size: 20px;
  line-height: 1.28;
  word-break: break-word;
}

.bill-dash-card em {
  display: block;
  margin-top: 8px;
  color: #667085;
  font-style: normal;
  font-size: 13px;
  line-height: 1.5;
}

.bill-profile-card,
.bill-ledger-card {
  padding: 22px;
  border-radius: 24px;
}

.bill-profile-title,
.bill-ledger-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 16px;
}

.bill-profile-title h3,
.bill-ledger-head h3 { margin: 0 0 4px; }
.bill-profile-title span,
.bill-ledger-head span {
  display: inline-flex;
  align-items: center;
  padding: 7px 10px;
  border-radius: 999px;
  background: #f2f7ff;
  color: #52627a;
  font-size: 12px;
  font-weight: 900;
}

.bill-profile-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.bill-profile-list div {
  padding: 14px;
  border-radius: 16px;
  background: #f8fbff;
  border: 1px solid #edf2fa;
}

.bill-profile-list span {
  display: block;
  color: #667085;
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 7px;
}

.bill-profile-list strong {
  display: block;
  color: var(--front-text);
  font-size: 14px;
  word-break: break-word;
}

.bill-ledger-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.bill-ledger-item {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 14px;
  align-items: stretch;
}

.bill-ledger-date {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  color: #52627a;
  background: #f2f7ff;
  border: 1px solid #dfeafa;
  font-size: 13px;
  font-weight: 900;
}

.bill-ledger-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 140px 92px;
  gap: 12px;
  align-items: center;
  padding: 15px 16px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid #e5ecf6;
  box-shadow: 0 8px 18px rgba(31, 87, 164, .045);
}

.bill-ledger-main strong {
  display: block;
  color: var(--front-text);
  font-size: 14px;
  line-height: 1.45;
  margin-bottom: 5px;
}

.bill-ledger-main span {
  color: #667085;
  font-size: 12px;
  font-weight: 700;
}

.bill-ledger-side b {
  display: block;
  color: var(--front-text);
  font-size: 15px;
  margin-bottom: 5px;
}

.bill-ledger-side em {
  display: inline-flex;
  padding: 4px 9px;
  border-radius: 999px;
  background: #e9fbef;
  border: 1px solid #bfe8cb;
  color: #0b8a42;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.bill-open-btn {
  border: 0;
  border-radius: 999px;
  padding: 8px 10px;
  color: #fff;
  background: linear-gradient(135deg, var(--front-primary), #12a891);
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(26, 111, 232, .16);
}

.bill-open-btn:hover { filter: brightness(.98); transform: translateY(-1px); }
.bill-no-link {
  color: #98a2b3;
  font-size: 13px;
  text-align: center;
}

.bill-empty {
  padding: 20px;
  color: #667085;
  text-align: center;
  border-radius: 20px;
}

@media (max-width: 980px) {
  .bill-dashboard-grid,
  .bill-profile-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bill-ledger-body { grid-template-columns: minmax(0, 1fr) 130px; }
  .bill-open-btn,
  .bill-no-link { grid-column: 1 / -1; justify-self: start; }
}

@media (max-width: 760px) {
  .bill-page { padding: 20px 14px 26px; }
  .bill-hero-card { grid-template-columns: 1fr; padding: 20px; }
  .bill-hero-mark { width: 100%; height: auto; min-height: 86px; border-radius: 22px; }
  .bill-hero-copy h3,
  .bill-result-hero h3 { font-size: 22px; }
  .bill-guide-strip { grid-template-columns: 1fr; }
  .bill-input-panel,
  .bill-profile-card,
  .bill-ledger-card { padding: 18px; border-radius: 20px; }
  .bill-safe-note { flex-direction: column; gap: 4px; }
  .bill-result-hero,
  .bill-profile-title,
  .bill-ledger-head { flex-direction: column; align-items: stretch; }
  .bill-result-actions { justify-content: flex-start; }
  .bill-dashboard-grid,
  .bill-profile-list { grid-template-columns: 1fr; }
  .bill-dash-card { min-height: auto; }
  .bill-ledger-item { grid-template-columns: 1fr; gap: 8px; }
  .bill-ledger-date { justify-content: flex-start; padding: 10px 12px; }
  .bill-ledger-body { grid-template-columns: 1fr; }
  .bill-open-btn,
  .bill-no-link { justify-self: stretch; text-align: center; }
}

/* v1.7.1 手机端查询按钮修复：防止 Naive UI 大按钮在窄屏下被压成细条 */
.front-panel .button-row {
  width: 100%;
}

.front-panel .button-row .n-button,
.front-panel .result-actions .n-button,
.front-panel .bill-actions .n-button,
.front-panel .bill-result-actions .n-button {
  min-height: 44px !important;
  height: 44px !important;
  border-radius: 13px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  line-height: 1.2 !important;
  box-sizing: border-box !important;
}

.front-panel .button-row .n-button.n-button--large-type,
.front-panel .result-actions .n-button.n-button--large-type,
.front-panel .bill-actions .n-button.n-button--large-type,
.front-panel .bill-result-actions .n-button.n-button--large-type {
  --n-height: 44px !important;
  --n-padding: 0 18px !important;
  min-height: 44px !important;
  height: 44px !important;
}

.front-panel .button-row .n-button .n-button__content,
.front-panel .result-actions .n-button .n-button__content,
.front-panel .bill-actions .n-button .n-button__content,
.front-panel .bill-result-actions .n-button .n-button__content {
  width: 100% !important;
  min-height: 42px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
}

@media (max-width: 700px) {
  .front-panel .button-row,
  .front-panel .result-actions,
  .front-panel .bill-actions,
  .front-panel .bill-result-actions {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    align-items: stretch !important;
    width: 100% !important;
  }

  .front-panel .button-row .n-button,
  .front-panel .result-actions .n-button,
  .front-panel .bill-actions .n-button,
  .front-panel .bill-result-actions .n-button {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 46px !important;
    height: 46px !important;
    font-size: 15px !important;
  }

  .front-panel .button-row .n-button.n-button--large-type,
  .front-panel .result-actions .n-button.n-button--large-type,
  .front-panel .bill-actions .n-button.n-button--large-type,
  .front-panel .bill-result-actions .n-button.n-button--large-type {
    --n-height: 46px !important;
    height: 46px !important;
  }

  .query-section .button-row {
    margin-top: 4px;
  }

  .bill-input-panel .button-row {
    margin-top: 12px;
  }

  .bill-result-actions {
    justify-items: stretch !important;
  }

  .bill-status-badge {
    justify-content: center;
    width: 100%;
    box-sizing: border-box;
  }
}


/* v1.7.3 手机端进度查询按钮专项修复 */
.query-section .button-row {
  width: 100%;
}

.query-section .button-row .query-submit-btn,
.query-section .button-row .n-button.query-submit-btn {
  --n-height: 46px !important;
  width: 100% !important;
  min-width: 0 !important;
  min-height: 46px !important;
  height: 46px !important;
  line-height: 46px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  border-radius: 13px !important;
  box-sizing: border-box !important;
  overflow: visible !important;
}

.query-section .button-row .query-submit-btn .n-button__content {
  min-height: 44px !important;
  height: 44px !important;
  line-height: 1.2 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  white-space: nowrap !important;
}

@media (max-width: 700px) {
  .query-section .button-row {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    align-items: stretch !important;
  }

  .query-section .button-row .n-button,
  .query-section .button-row .query-submit-btn,
  .query-section .button-row .n-button.query-submit-btn {
    --n-height: 46px !important;
    width: 100% !important;
    min-height: 46px !important;
    height: 46px !important;
    flex: none !important;
    transform: none !important;
  }

  .query-section .button-row .n-button .n-button__content {
    min-height: 44px !important;
    height: 44px !important;
    padding: 0 14px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
  }
}

/* v1.6.9 前台短标签、流程条居中、接单状态 */
.top-status.open {
  background: rgba(15,159,110,.09);
  color: #087857;
  border-color: rgba(15,159,110,.18);
}
.top-status.open .status-dot {
  background: #10b981;
  box-shadow: 0 0 0 4px rgba(16,185,129,.12);
}
.top-status.rest {
  background: rgba(245,158,11,.10);
  color: #9a5a00;
  border-color: rgba(245,158,11,.24);
}
.top-status.rest .status-dot {
  background: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245,158,11,.14);
}
.steps-bar {
  justify-content: center;
}
.steps-inner {
  width: min(100%, 540px);
  margin: 0 auto;
  justify-content: center;
}
.step-item {
  width: 76px;
}
.step-connector {
  flex: 0 1 54px;
  width: 54px;
  max-width: 54px;
  min-width: 36px;
}
.settings-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.35fr);
  gap: 18px;
}
.setting-preview {
  margin-top: 8px;
  padding: 18px;
  border-radius: 14px;
  background: #f8fbff;
  border: 1px solid #dce8fb;
}
.settings-actions {
  margin-top: 18px;
  display: flex;
  justify-content: flex-end;
}
@media (max-width: 700px) {
  .steps-inner { width: 100%; }
  .step-item { width: 58px; }
  .step-connector {
    flex-basis: 18px;
    width: 18px;
    min-width: 10px;
    max-width: 22px;
  }
  .settings-grid { grid-template-columns: 1fr; }
  .settings-actions { justify-content: stretch; }
  .settings-actions .n-button { width: 100%; }
}

/* v1.6.9f PC 端步骤条与结果按钮居中修复 */
.front-panel .steps-bar {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

.front-panel .steps-inner {
  display: grid !important;
  grid-template-columns: 86px 72px 86px 72px 86px 72px 86px !important;
  align-items: start !important;
  justify-content: center !important;
  width: max-content !important;
  max-width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

.front-panel .step-item {
  width: 86px !important;
  min-width: 86px !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
}

.front-panel .step-connector {
  width: 72px !important;
  min-width: 72px !important;
  max-width: 72px !important;
  flex: none !important;
  justify-self: center !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.result-section .result-actions {
  justify-content: center !important;
  width: 100% !important;
  margin-top: 12px !important;
}

@media (min-width: 701px) {
  .result-section .result-actions .n-button {
    min-width: 128px !important;
  }
}

@media (max-width: 700px) {
  .front-panel .steps-inner {
    grid-template-columns: 58px minmax(12px, 18px) 58px minmax(12px, 18px) 58px minmax(12px, 18px) 58px !important;
    width: 100% !important;
  }

  .front-panel .step-item {
    width: 58px !important;
    min-width: 58px !important;
  }

  .front-panel .step-connector {
    width: 18px !important;
    min-width: 12px !important;
    max-width: 18px !important;
  }
}

/* v1.6.9g PC 端流程条与结果按钮强制居中修复 */
.front-panel > .steps-bar {
  display: grid !important;
  place-items: center !important;
  width: 100% !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  box-sizing: border-box !important;
}

.front-panel > .steps-bar > .steps-inner {
  display: flex !important;
  align-items: flex-start !important;
  justify-content: center !important;
  width: fit-content !important;
  max-width: calc(100% - 32px) !important;
  margin: 0 auto !important;
  transform: none !important;
}

.front-panel > .steps-bar > .steps-inner .step-item {
  flex: 0 0 92px !important;
  width: 92px !important;
  min-width: 92px !important;
  max-width: 92px !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: flex-start !important;
  text-align: center !important;
}

.front-panel > .steps-bar > .steps-inner .step-connector {
  flex: 0 0 74px !important;
  width: 74px !important;
  min-width: 74px !important;
  max-width: 74px !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  margin-top: 17px !important;
}

.front-panel .result-section {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  text-align: center !important;
}

.front-panel .result-section .result-actions {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 12px !important;
  width: 100% !important;
  margin: 16px auto 0 !important;
  text-align: center !important;
}

.front-panel .result-section .result-actions .n-button {
  flex: 0 0 auto !important;
}

@media (max-width: 700px) {
  .front-panel > .steps-bar {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  .front-panel > .steps-bar > .steps-inner {
    width: 100% !important;
    max-width: 100% !important;
  }

  .front-panel > .steps-bar > .steps-inner .step-item {
    flex: 1 1 0 !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
  }

  .front-panel > .steps-bar > .steps-inner .step-connector {
    flex: 0 0 14px !important;
    width: 14px !important;
    min-width: 10px !important;
    max-width: 16px !important;
  }

  .front-panel .result-section .result-actions {
    flex-direction: column !important;
    align-items: stretch !important;
  }
}

/* ChatGPT Cookie 扩展字段 */
.cookie-extra-box {
  border: 1px solid #bfdbfe;
  background: linear-gradient(180deg, #eff6ff 0%, #ffffff 100%);
  border-radius: 16px;
  padding: 14px;
  margin: 12px 0 14px;
}
.cookie-extra-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 10px;
}
.cookie-extra-head strong {
  color: #1e3a8a;
  font-size: 14px;
}
.cookie-extra-head p {
  margin: 4px 0 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.6;
}
.cookie-guide-steps {
  display: grid;
  gap: 10px;
  color: #374151;
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 14px;
}
.cookie-guide-img {
  display: block;
  width: 100%;
  max-height: 420px;
  object-fit: contain;
  border-radius: 14px;
  border: 1px solid #e5e7eb;
  background: #0f172a;
}
@media (max-width: 640px) {
  .cookie-extra-head {
    display: block;
  }
  .cookie-extra-head .n-button {
    margin-top: 10px;
  }
}


/* v1.6.6 后台移动端适配优化：侧栏压缩 + 表格横向滚动 */
.admin-table-scroll {
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  border-radius: 10px;
}

.admin-table-scroll table {
  min-width: 860px;
}

.admin-table-scroll::-webkit-scrollbar {
  height: 8px;
}

.admin-table-scroll::-webkit-scrollbar-track {
  background: #eef2f7;
  border-radius: 999px;
}

.admin-table-scroll::-webkit-scrollbar-thumb {
  background: #c7d2e4;
  border-radius: 999px;
}

.admin-table-scroll::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

.admin-scroll-hint {
  display: none;
  margin: 0 0 8px;
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
}

.admin-filter-card .n-card__content {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.admin-filter-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: flex-end;
}

@media (max-width: 768px) {
  html, body {
    overflow-x: hidden;
  }

  .admin-layout {
    display: block;
    min-height: 100vh;
  }

  .admin-sidebar {
    position: sticky;
    top: 0;
    z-index: 80;
    width: 100%;
    display: block;
    box-shadow: 0 8px 24px rgba(15, 23, 42, .12);
  }

  .admin-sidebar-header {
    padding: 14px 16px 10px;
    font-size: 16px;
    border-bottom: 0;
  }

  .admin-nav {
    display: flex;
    gap: 8px;
    padding: 0 12px 12px;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
    scrollbar-width: thin;
  }

  .admin-nav-item {
    flex: 0 0 auto;
    border-left: 0;
    border-radius: 12px;
    padding: 9px 12px;
    background: rgba(255,255,255,.05);
    font-size: 13px;
  }

  .admin-nav-item.active {
    border-left: 0;
    background: #334155;
  }

  .admin-sidebar-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 14px 12px;
  }

  .admin-sidebar-footer > div {
    margin-bottom: 0 !important;
    min-width: 0;
  }

  .admin-sidebar-footer .n-button {
    width: auto !important;
    min-width: 86px;
    flex-shrink: 0;
  }

  .admin-main {
    width: 100%;
    min-width: 0;
    padding: 18px 12px 28px;
    overflow: visible;
  }

  .admin-page-title {
    font-size: 20px;
  }

  .admin-page-sub {
    margin-bottom: 14px;
  }

  .admin-filter-row {
    min-width: 620px;
  }

  .admin-scroll-hint {
    display: block;
  }

  .admin-table-scroll {
    margin: 0 -2px;
    padding-bottom: 4px;
  }

  .admin-table-scroll table {
    min-width: 920px;
  }

  .n-modal .info-row {
    align-items: flex-start;
    gap: 10px;
  }

  .n-modal .info-val {
    text-align: right;
    word-break: break-all;
  }
}

@media (max-width: 480px) {
  .admin-sidebar-header {
    padding-left: 14px;
    padding-right: 14px;
  }

  .admin-main {
    padding-left: 10px;
    padding-right: 10px;
  }

  .admin-filter-row {
    min-width: 560px;
  }

  .admin-table-scroll table {
    min-width: 900px;
  }
}

/* ──────────────────────────────────────────────────────────────
   后台左侧栏抽屉版修复 20260513
   ────────────────────────────────────────────────────────────── */
.admin-layout {
  display: flex;
  min-height: 100vh;
  background: #f5f7fb;
}

.admin-sidebar {
  width: 230px;
  background: #1e293b;
  color: #e2e8f0;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  transition: width .18s ease, transform .22s ease;
}

.admin-sidebar-header {
  height: 72px;
  padding: 0 16px 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  border-bottom: 1px solid #334155;
}

.admin-brand,
.admin-user-line {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.admin-brand-text,
.admin-user-name,
.admin-nav-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-sidebar-toggle,
.admin-menu-btn {
  border: 0;
  cursor: pointer;
  flex-shrink: 0;
}

.admin-sidebar-toggle {
  width: 30px;
  height: 30px;
  border-radius: 10px;
  background: rgba(255,255,255,.08);
  color: #e5e7eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  line-height: 1;
}

.admin-sidebar-toggle:hover {
  background: rgba(255,255,255,.14);
  color: #fff;
}

.mobile-toggle { display: none; }

.admin-nav {
  padding: 14px 0;
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
}

.admin-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 22px;
  color: #cbd5e1;
  text-decoration: none;
  font-size: 14px;
  cursor: pointer;
  border-left: 3px solid transparent;
  transition: background .15s, color .15s;
}

.admin-nav-item:hover {
  background: #283548;
  color: #fff;
}

.admin-nav-item.active {
  background: #283548;
  color: #fff;
  border-left-color: #3b82f6;
  font-weight: 600;
}

.admin-nav-icon {
  width: 20px;
  text-align: center;
  flex-shrink: 0;
}

.admin-sidebar-footer {
  padding: 14px 22px;
  border-top: 1px solid #334155;
  font-size: 12px;
  color: #94a3b8;
}

.admin-sidebar-footer .n-button {
  margin-top: 10px;
}

.admin-main {
  flex: 1;
  min-width: 0;
  padding: 28px 32px;
  overflow: auto;
}

.admin-mobile-topbar,
.admin-sidebar-mask {
  display: none;
}

.sidebar-collapsed .admin-sidebar {
  width: 76px;
}

.sidebar-collapsed .admin-sidebar-header {
  padding-left: 14px;
  padding-right: 14px;
  justify-content: center;
}

.sidebar-collapsed .admin-brand-text,
.sidebar-collapsed .admin-nav-label,
.sidebar-collapsed .admin-user-name,
.sidebar-collapsed .admin-sidebar-footer .n-button {
  display: none !important;
}

.sidebar-collapsed .admin-brand {
  justify-content: center;
}

.sidebar-collapsed .admin-sidebar-toggle {
  position: absolute;
  left: 60px;
  top: 21px;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: #334155;
  box-shadow: 0 6px 16px rgba(15,23,42,.22);
}

.sidebar-collapsed .admin-nav-item {
  justify-content: center;
  padding-left: 0;
  padding-right: 0;
}

.sidebar-collapsed .admin-sidebar-footer {
  padding-left: 0;
  padding-right: 0;
}

.sidebar-collapsed .admin-user-line {
  justify-content: center;
}

@media (max-width: 768px) {
  html, body {
    overflow-x: hidden;
  }

  .admin-layout,
  .admin-layout.sidebar-collapsed {
    display: block;
    min-height: 100vh;
    padding-top: 56px;
  }

  .admin-mobile-topbar {
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    z-index: 95;
    height: 56px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 14px;
    background: rgba(245,247,251,.94);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid #e5e7eb;
  }

  .admin-menu-btn {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: #1e293b;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    box-shadow: 0 8px 20px rgba(15,23,42,.18);
  }

  .admin-menu-btn span {
    width: 17px;
    height: 2px;
    border-radius: 999px;
    background: #fff;
  }

  .admin-mobile-title {
    font-size: 17px;
    font-weight: 700;
    color: #111827;
  }

  .admin-sidebar,
  .sidebar-collapsed .admin-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    z-index: 110;
    width: 246px;
    max-width: 82vw;
    display: flex;
    transform: translateX(-104%);
    box-shadow: 14px 0 34px rgba(15, 23, 42, .26);
  }

  .sidebar-open .admin-sidebar {
    transform: translateX(0);
  }

  .admin-sidebar-mask {
    position: fixed;
    inset: 0;
    z-index: 105;
    display: block;
    background: rgba(15,23,42,.38);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
  }

  .sidebar-open .admin-sidebar-mask {
    opacity: 1;
    pointer-events: auto;
  }

  .admin-sidebar-header,
  .sidebar-collapsed .admin-sidebar-header {
    height: 68px;
    padding: 0 14px 0 18px;
    justify-content: space-between;
    border-bottom: 1px solid #334155;
  }

  .admin-brand-text,
  .admin-nav-label,
  .admin-user-name,
  .admin-sidebar-footer .n-button {
    display: inline-flex !important;
  }

  .desktop-toggle { display: none; }
  .mobile-toggle { display: inline; font-size: 22px; }

  .sidebar-collapsed .admin-sidebar-toggle,
  .admin-sidebar-toggle {
    position: static;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    box-shadow: none;
  }

  .admin-nav,
  .sidebar-collapsed .admin-nav {
    display: block;
    padding: 12px 0;
    overflow-y: auto;
    overflow-x: hidden;
    white-space: normal;
  }

  .admin-nav-item,
  .sidebar-collapsed .admin-nav-item {
    justify-content: flex-start;
    border-left: 3px solid transparent;
    border-radius: 0;
    padding: 12px 22px;
    background: transparent;
    font-size: 14px;
  }

  .admin-nav-item.active,
  .sidebar-collapsed .admin-nav-item.active {
    border-left-color: #3b82f6;
    background: #283548;
  }

  .admin-sidebar-footer,
  .sidebar-collapsed .admin-sidebar-footer {
    display: block;
    padding: 14px 18px;
  }

  .admin-sidebar-footer .n-button {
    width: 100% !important;
    min-width: 0;
  }

  .admin-main {
    width: 100%;
    min-width: 0;
    padding: 16px 10px 28px;
    overflow: visible;
  }

  .admin-page-title {
    font-size: 20px;
  }

  .admin-page-sub {
    margin-bottom: 14px;
  }

  .admin-filter-card .n-card__content {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .admin-filter-row {
    min-width: 620px;
  }

  .admin-scroll-hint {
    display: block;
  }

  .admin-table-scroll {
    margin: 0 -2px;
    padding-bottom: 4px;
  }

  .admin-table-scroll table {
    min-width: 920px;
  }

  .n-modal .info-row {
    align-items: flex-start;
    gap: 10px;
  }

  .n-modal .info-val {
    text-align: right;
    word-break: break-all;
  }
}

@media (max-width: 480px) {
  .admin-main {
    padding-left: 8px;
    padding-right: 8px;
  }

  .admin-filter-row {
    min-width: 560px;
  }

  .admin-table-scroll table {
    min-width: 900px;
  }
}
/* ══════════════════════════════════════════════════════════════
 *  v2 进度查询页样式 (已修复级联覆盖 bug)
 *  覆盖: 三段卡片布局 / 可点击 mini-stat / 移动端卡片视图
 *  ══════════════════════════════════════════════════════════════ */

/* ① 页面整体:三个卡之间留间距 */
.query-page-v2 .form-section + .form-section {
  margin-top: 14px;
  border-top: 1px solid var(--front-line);
}

/* ② 输入区:标签行 + 快捷键提示 */
.input-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 12px;
}
.input-dup {
  color: #d97706;
  font-size: 12px;
  font-weight: 400;
  margin-left: 6px;
}
.hint-line {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--front-muted);
  margin: -4px 0 14px;
}
.hint-line .hint-key {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 6px;
  background: #eef2f8;
  border: 1px solid #e0e6f0;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11px;
  color: #52627a;
}


/* ③ 进度卡:完成横幅 */
.query-done-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 12px;
  background: #effaf3;
  border: 1px solid #c8ecd6;
  color: #1b7a4c;
  font-size: 13px;
  margin-bottom: 14px;
}
.query-done-banner .done-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--front-success);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}
.query-done-banner strong { color: #0c5a36; }
.query-done-banner .banner-spacer { flex: 1; }
.query-done-banner .filter-hint a {
  color: var(--front-primary);
  cursor: pointer;
  margin-left: 4px;
}


/* ④ mini-stat 可点击/激活态 — 在原有基础上扩展 */
.mini-stat {
  appearance: none;
  border: 1px solid #e3ebf8;
  background: #fbfdff;
  text-align: left;
  cursor: pointer;
  transition: transform .12s ease, box-shadow .15s ease, border-color .15s ease;
  font: inherit;
}
.mini-stat:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 10px rgba(80, 110, 160, .08);
  border-color: #c9d8ef;
}
.mini-stat.active {
  border-color: var(--front-primary);
  background: #f1f6ff;
  box-shadow: 0 0 0 2px rgba(50, 110, 220, .12);
}
.mini-stat.success.active  { border-color: var(--front-success); background: #f0faf4; box-shadow: 0 0 0 2px rgba(15,159,110,.14); }
.mini-stat.warning.active  { border-color: #d97706;             background: #fff8ec; box-shadow: 0 0 0 2px rgba(217,119,6,.14); }
.mini-stat.danger.active   { border-color: var(--front-danger); background: #fdf2f3; box-shadow: 0 0 0 2px rgba(214,76,76,.14); }


/* ⑤ 结果卡工具条 */
.result-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.result-toolbar h4 {
  margin: 0;
  font-size: 15px;
  color: var(--front-text);
  font-weight: 700;
}
.result-toolbar h4 .muted {
  color: var(--front-muted);
  font-weight: 400;
  font-size: 13px;
}
.result-toolbar-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}


/* ⑥ 表格行染色 + 行操作 */
.front-table tr.row-fail td      { background: rgba(214, 76, 76, .03); }
.front-table .code-cell {
  cursor: pointer;
  transition: color .12s;
}
.front-table .code-cell:hover { color: var(--front-primary); }
.front-table .empty-cell {
  text-align: center;
  color: var(--front-muted);
  padding: 24px 0;
}

/* ⑥-2 失败原因 — 红色 + 感叹号图标 + 多行换行 */
.fail-reason {
  display: inline-flex;
  align-items: flex-start;
  gap: 6px;
  color: #c0392b;
  font-weight: 500;
  line-height: 1.5;
  word-break: break-word;
  cursor: help;          /* 悬停时鼠标变 ?,提示用户有 title */
}
.fail-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--front-danger);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  margin-top: 2px;
}
/* 移动端卡片版本的失败原因 */
.rc-progress.rc-fail {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  color: #c0392b;
  font-weight: 500;
}
.rc-progress.rc-fail .fail-icon { margin-top: 3px; }


/* ⑦ 移动端卡片视图 — 注意:这里不设 display,留给 ⑧ 的工具类控制 */
.result-card-list {
  flex-direction: column;
  gap: 10px;
}
.result-card-item {
  border: 1px solid #e3ebf8;
  border-radius: 12px;
  padding: 12px 14px;
  background: #fff;
}
.result-card-item.row-fail     { border-color: #f3cccc; background: #fdf7f7; }
.result-card-item.row-pending  { border-color: #f4dba6; background: #fffaf0; }
.result-card-item.row-ok       { border-color: #c8ecd6; background: #f6fdf9; }

.rc-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.rc-idx {
  font-size: 12px;
  color: var(--front-muted);
  font-weight: 600;
}
.rc-spacer { flex: 1; }
.rc-cdk {
  font-size: 12px;
  word-break: break-all;
  color: #2a3650;
  padding: 6px 0;
  cursor: pointer;
}
.rc-progress {
  font-size: 13px;
  line-height: 1.5;
  color: #3a4661;
  margin-bottom: 6px;
}
.rc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  font-size: 12px;
  color: var(--front-muted);
}


/* ⑧ 响应式切换 — 工具类放在所有具体规则之后,确保级联优先级 */
.desktop-only { display: block; }
.mobile-only  { display: none; }

@media (max-width: 700px) {
  .desktop-only { display: none; }
  .mobile-only  { display: block; }
  /* 双类选择器(0,2,0)优先级高于单类(0,1,0),恢复 flex 容器布局 */
  .result-card-list.mobile-only { display: flex; }

  .result-toolbar { flex-direction: column; align-items: stretch; }
  .result-toolbar-actions { justify-content: stretch; }
  .result-toolbar-actions .n-button { flex: 1; }

  .query-done-banner { flex-wrap: wrap; font-size: 12px; }
  .query-done-banner .filter-hint { width: 100%; padding-top: 4px; }

  .input-label-row { flex-wrap: wrap; }
}
