/* 数据大屏（总后台）· 只在这一个页面生效，类名统一 as- 前缀 */
.as-root {
  --bg: #060a14;
  --panel: rgba(15, 25, 46, .78);
  --panel-2: rgba(10, 17, 33, .9);
  --line: rgba(110, 160, 240, .16);
  --ink: #e9effc;
  --dim: #7d8cb0;
  --main: #ff7a1a;
  --main2: #ffb066;
  --cyan: #22d3ee;
  --green: #34d399;
  --purple: #a78bfa;
  --red: #fb7185;
  --gold: #fbbf24;

  position: fixed; inset: 0; z-index: 2000;
  background:
    radial-gradient(1200px 620px at 18% -8%, rgba(255, 122, 26, .13), transparent 62%),
    radial-gradient(1000px 560px at 86% 4%, rgba(34, 211, 238, .10), transparent 60%),
    var(--bg);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, 'Microsoft YaHei', 'PingFang SC', sans-serif;
}
.as-root::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(110, 160, 240, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(110, 160, 240, .045) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at 50% 40%, #000 30%, transparent 78%);
  -webkit-mask-image: radial-gradient(circle at 50% 40%, #000 30%, transparent 78%);
}

.as-stage {
  width: 1920px; height: 1080px; flex: none;
  transform-origin: center center;
  position: relative;
  display: flex; flex-direction: column;
  padding: 18px 24px 16px;
}
.as-loading { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-size: 16px; color: var(--dim); letter-spacing: 2px; }

/* ========== 顶部 ========== */
.as-hd { height: 74px; flex: none; display: flex; align-items: center; gap: 20px; position: relative; }
.as-hd::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(110, 160, 240, .42) 22%, rgba(255, 122, 26, .5) 50%, rgba(110, 160, 240, .42) 78%, transparent);
}
.as-brand { display: flex; align-items: center; gap: 14px; flex: none; }
.as-logo {
  width: 40px; height: 40px; border-radius: 10px; flex: none;
  background: linear-gradient(135deg, #ff8a2b, #e85d04);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 700; color: #fff;
  box-shadow: 0 0 24px rgba(255, 122, 26, .5);
}
.as-h1 { font-size: 25px; font-weight: 700; letter-spacing: 3px; margin: 0;
  background: linear-gradient(180deg, #fff, #b9c9e8);
  -webkit-background-clip: text; background-clip: text; color: transparent; }
.as-sub { font-size: 11px; color: var(--dim); letter-spacing: 3px; margin-top: 3px; }

.as-clock { flex: 1; text-align: center; }
.as-clock b { font-size: 30px; font-weight: 600; letter-spacing: 2px; font-variant-numeric: tabular-nums;
  color: #fff; text-shadow: 0 0 22px rgba(120, 180, 255, .4); }
.as-clock span { display: block; font-size: 12px; color: var(--dim); letter-spacing: 3px; margin-top: 2px; }

.as-tools { display: flex; align-items: center; gap: 8px; flex: none; }
.as-chip {
  height: 32px; padding: 0 12px; border-radius: 8px; font-size: 12px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
  background: rgba(255, 255, 255, .05); border: 1px solid var(--line); color: #c3cfe6;
  transition: all .16s;
}
.as-chip:hover { background: rgba(255, 255, 255, .1); color: #fff; border-color: rgba(255, 122, 26, .5); }
.as-chip.on { background: rgba(255, 122, 26, .16); border-color: rgba(255, 122, 26, .55); color: var(--main2); }
.as-chip.demo-on { background: rgba(251, 191, 36, .09); border-color: rgba(251, 191, 36, .3); color: #e0c081; }
.as-chip.demo-on:hover { background: rgba(251, 191, 36, .17); border-color: rgba(251, 191, 36, .55); color: #fbe0a8; }
.as-chip .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); }
.as-live { font-size: 12px; color: var(--dim); letter-spacing: 1px; margin-right: 4px; }
.as-live i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--green);
  margin-right: 6px; box-shadow: 0 0 10px var(--green); animation: asPulse 1.6s infinite; }
@keyframes asPulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.75); } }

/* ========== KPI ========== */
.as-kpis { height: 152px; flex: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; padding: 16px 0; }
.as-kpi {
  position: relative; border-radius: 12px; padding: 20px 22px;
  background: linear-gradient(160deg, rgba(24, 38, 66, .9), rgba(11, 19, 36, .82));
  border: 1px solid var(--line); overflow: hidden;
  display: flex; flex-direction: column; justify-content: center;
}
.as-kpi::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: linear-gradient(180deg, var(--c, var(--main)), transparent);
}
.as-kpi::after {
  content: ''; position: absolute; right: -30px; top: -30px; width: 110px; height: 110px; border-radius: 50%;
  background: radial-gradient(circle, var(--c, var(--main)), transparent 68%); opacity: .14;
}
.as-kpi-l { font-size: 13px; color: var(--dim); letter-spacing: 1px; margin-bottom: 8px; }
.as-kpi-v { display: flex; align-items: baseline; gap: 6px; }
.as-kpi-v b { font-size: 46px; font-weight: 700; line-height: 1; letter-spacing: -1px;
  font-variant-numeric: tabular-nums; color: #fff; }
.as-kpi-v i { font-size: 14px; font-style: normal; color: var(--dim); }
.as-kpi-s { margin-top: 10px; font-size: 12px; color: var(--dim); display: flex; gap: 10px; flex-wrap: wrap; }
.as-kpi-s em { font-style: normal; color: var(--c, var(--main2)); }

/* ========== 主体三列 ========== */
.as-body { flex: 1; display: grid; grid-template-columns: 420px 1fr 420px; gap: 16px; min-height: 0; }
.as-col { display: flex; flex-direction: column; gap: 16px; min-height: 0; }

.as-panel {
  position: relative; border-radius: 12px; min-height: 0;
  background: var(--panel); border: 1px solid var(--line);
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .04);
  animation: asIn .5s ease both;
}
@keyframes asIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.as-panel:nth-child(2) { animation-delay: .08s; }
.as-pt {
  flex: none; height: 44px; padding: 0 16px; display: flex; align-items: center; gap: 9px;
  font-size: 15px; font-weight: 600; letter-spacing: 1px; color: #dfe8fa;
  background: linear-gradient(180deg, rgba(45, 68, 112, .34), transparent);
  border-bottom: 1px solid rgba(110, 160, 240, .1);
}
.as-pt::before { content: ''; width: 3px; height: 15px; border-radius: 2px; background: var(--main); box-shadow: 0 0 10px var(--main); }
.as-pt small { margin-left: auto; font-size: 11px; font-weight: 400; color: var(--dim); letter-spacing: 0; }
.as-pb { flex: 1; min-height: 0; padding: 12px 16px 14px; position: relative; }

.as-chart { width: 100%; height: 100%; }

/* 空状态 */
.as-empty { position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 8px; color: #64738f; font-size: 13px;
  text-shadow: 0 2px 14px rgba(4, 8, 16, .95), 0 0 26px rgba(4, 8, 16, .9); }
.as-empty b { font-size: 15px; color: #94a4c2; font-weight: 500; }

/* 排行 */
.as-rank { height: 100%; display: flex; flex-direction: column; justify-content: flex-start; gap: 15px; padding-top: 4px; }
.as-rk { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.as-rk-no {
  width: 22px; height: 22px; flex: none; border-radius: 6px; font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .07); color: #9aa8c4;
}
.as-rk-no.n1 { background: linear-gradient(135deg, #ffb020, #f97316); color: #2a1703; }
.as-rk-no.n2 { background: linear-gradient(135deg, #cbd5e1, #94a3b8); color: #1c2537; }
.as-rk-no.n3 { background: linear-gradient(135deg, #d08b5b, #a16207); color: #26160a; }
.as-rk-nm { width: 128px; min-width: 0; flex: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #cdd8ee; }
.as-rk-tag { font-style: normal; font-size: 11px; color: #93a6c6; margin-left: 5px;
  padding-left: 6px; border-left: 1px solid rgba(140, 165, 205, .45); }
.as-rk-bar { flex: 1; height: 8px; border-radius: 6px; background: rgba(255, 255, 255, .06); overflow: hidden; }
.as-rk-bar i { display: block; height: 100%; border-radius: 6px;
  background: linear-gradient(90deg, #ff8a35, #ffb877);
  box-shadow: 0 0 12px rgba(255, 122, 26, .5); transition: width .9s cubic-bezier(.2, .8, .2, 1); }
.as-rk-v { width: 56px; flex: none; text-align: right; font-variant-numeric: tabular-nums; color: #fff; font-weight: 600; }
.as-rk-v span { font-size: 11px; color: var(--dim); font-weight: 400; margin-left: 2px; }

/* 实时流 */
.as-feed { height: 100%; display: flex; flex-direction: column; gap: 6px; overflow: hidden; }
.as-fi {
  display: flex; align-items: center; gap: 10px; padding: 6px 10px; border-radius: 8px;
  background: rgba(255, 255, 255, .035); border: 1px solid rgba(110, 160, 240, .09);
  animation: asRow .45s ease both;
  flex: 1 1 0; min-height: 0; overflow: hidden;
}
@keyframes asRow { from { opacity: 0; transform: translateX(-8px); } to { opacity: 1; transform: none; } }
.as-fi-dot { width: 7px; height: 7px; border-radius: 50%; flex: none; box-shadow: 0 0 8px currentColor; }
.as-fi-m { flex: 1; min-width: 0; }
.as-fi-t1 { font-size: 13px; color: #e2eafb; display: flex; gap: 8px; align-items: center; }
.as-fi-t1 b { font-weight: 600; }
.as-fi-t1 em { font-style: normal; font-size: 11px; color: var(--dim);
  border: 1px solid rgba(110, 160, 240, .22); border-radius: 4px; padding: 0 5px; }
.as-fi-t2 { font-size: 11px; color: #6b7a99; margin-top: 2px; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; }
.as-fi-time { font-size: 11px; color: #5f6e8d; flex: none; font-variant-numeric: tabular-nums; }
.as-fi-deal { color: var(--green); font-size: 11px; flex: none; }

/* 健康 */
.as-health { height: 100%; display: flex; flex-direction: column; gap: 10px; }
.as-rings { display: flex; justify-content: space-around; }
.as-ring { width: 104px; text-align: center; }
.as-ring svg { display: block; margin: 0 auto; }
.as-ring-t { margin-top: 6px; font-size: 12px; color: var(--dim); }
.as-ring-v { font-size: 13px; color: #dfe8fa; margin-top: 1px; font-variant-numeric: tabular-nums; }
.as-hrow { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--dim); }
.as-hrow b { margin-left: auto; color: #cdd8ee; font-weight: 500; font-variant-numeric: tabular-nums; }

/* 到期预警 */
.as-warn { height: 100%; display: flex; flex-direction: column; gap: 8px; overflow: hidden; justify-content: space-between; }
.as-wi { display: flex; align-items: center; gap: 9px; font-size: 13px; padding: 7px 10px;
  border-radius: 8px; background: rgba(251, 191, 36, .05); border: 1px solid rgba(251, 191, 36, .14); }
.as-wi.urgent { background: rgba(251, 113, 133, .07); border-color: rgba(251, 113, 133, .22); }
.as-wi-nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #dbe5f8; }
.as-wi-d { font-size: 12px; color: var(--gold); font-variant-numeric: tabular-nums; }
.as-wi.urgent .as-wi-d { color: var(--red); }

/* 底部状态条 */
.as-ft {
  height: 46px; flex: none; margin-top: 14px; border-radius: 10px;
  background: linear-gradient(90deg, rgba(20, 32, 56, .9), rgba(12, 20, 38, .8));
  border: 1px solid var(--line);
  display: flex; align-items: center; gap: 22px; padding: 0 18px; font-size: 12px; color: var(--dim);
  overflow: hidden;
}
.as-ft i { font-style: normal; color: var(--main2); font-variant-numeric: tabular-nums; }
.as-ft-sep { width: 1px; height: 16px; background: rgba(110, 160, 240, .2); }
.as-ft-tip { margin-left: auto; letter-spacing: 1px; }
.as-ft-tip b { color: var(--green); font-weight: 500; }
.as-ft-tip.demo { color: #b99a5e; }
.as-ft-tip.demo b { color: #fbbf24; }

/* 脱敏提示 */
.as-maskbar {
  position: absolute; right: 24px; top: 92px; z-index: 5;
  font-size: 11px; color: #ffcf9c; background: rgba(255, 122, 26, .12);
  border: 1px solid rgba(255, 122, 26, .34); border-radius: 6px; padding: 3px 9px;
  letter-spacing: 1px;
}

/* 窄屏兜底：保证手机上也能看个大概 */
@media (max-width: 900px) {
  .as-stage { transform-origin: top left; }
}
