/* 卓玛云丹 · 后台管理系统（接手方全新重做）
   深色 + 橙色，跟前台一套设计语言。原厂那套白底 Element Plus 整个弃用。 */

:root {
  --g1: #ffa94d;
  --g2: #f2762b;
  --bg: #0a0c10;
  --bg-2: #0e1116;
  --panel: #14181f;
  --panel-2: #1a1f28;
  --panel-hi: rgba(255, 255, 255, .04);
  --line: rgba(255, 255, 255, .08);
  --line-2: rgba(255, 255, 255, .14);
  --t1: #f2f4f8;
  --t2: rgba(255, 255, 255, .62);
  --t3: rgba(255, 255, 255, .38);
  --ok: #4ee0b0;
  --warn: #ffd166;
  --bad: #ff7a6b;
  --info: #6cc7ff;
  --sidebar: 236px;
  font-size: 14px;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg);
  color: var(--t1);
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
#app { height: 100vh; }
button { font-family: inherit; cursor: pointer; }
::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .12); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, .2); }

/* ══════════ 登录 ══════════ */
.za-login {
  height: 100vh;
  display: grid;
  place-items: center;
  background:
    radial-gradient(48rem 32rem at 20% 10%, rgba(255, 149, 61, .14), transparent 60%),
    radial-gradient(42rem 30rem at 82% 84%, rgba(124, 148, 255, .1), transparent 62%),
    var(--bg);
}
.za-login-card {
  width: 384px;
  max-width: 92vw;
  padding: 2.6rem 2.4rem;
  border-radius: 18px;
  background: linear-gradient(160deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .015)), var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .6);
}
.za-login-logo { display: flex; align-items: center; gap: .7rem; margin-bottom: .4rem; }
.za-login-logo .za-mark {
  width: 2.4rem; height: 2.4rem; border-radius: 9px;
  background: linear-gradient(135deg, var(--g1), var(--g2));
  display: grid; place-items: center; color: #2b1406; font-weight: 800; font-size: 1.1rem;
}
.za-login-logo b { font-size: 1.2rem; }
.za-login-sub { color: var(--t3); font-size: .85rem; margin: .5rem 0 2rem; }
.za-field { margin-bottom: 1.1rem; }
.za-field label { display: block; font-size: .82rem; color: var(--t2); margin-bottom: .45rem; }
.za-field input {
  width: 100%; height: 2.9rem; padding: 0 1rem;
  border: 1px solid var(--line); border-radius: 10px;
  background: rgba(255, 255, 255, .035); color: var(--t1); font-size: .95rem; outline: none;
  transition: border-color .15s ease;
}
.za-field input:focus { border-color: rgba(255, 169, 77, .5); }
.za-login-btn {
  width: 100%; height: 2.9rem; margin-top: .6rem; border: 0; border-radius: 10px;
  background: linear-gradient(135deg, var(--g1), var(--g2)); color: #2b1406;
  font-size: .98rem; font-weight: 700;
  box-shadow: 0 12px 26px -12px rgba(242, 118, 43, .9);
  transition: transform .15s ease, filter .15s ease;
}
.za-login-btn:hover { transform: translateY(-1px); filter: brightness(1.05); }
.za-login-btn:disabled { opacity: .6; transform: none; }
.za-login-err { margin-top: 1rem; font-size: .84rem; color: var(--bad); min-height: 1.1rem; }

/* ══════════ 主框架 ══════════ */
.za-shell { display: grid; grid-template-columns: var(--sidebar) 1fr; height: 100vh; }
.za-shell.za-collapsed { --sidebar: 66px; }

/* 侧边栏 */
.za-side {
  background: linear-gradient(180deg, var(--bg-2), var(--bg));
  border-right: 1px solid var(--line);
  display: flex; flex-direction: column;
  overflow: hidden;
}
.za-brand {
  display: flex; align-items: center; gap: .65rem;
  height: 60px; padding: 0 1.1rem; flex: none;
  border-bottom: 1px solid var(--line);
}
.za-brand .za-mark {
  width: 2rem; height: 2rem; border-radius: 8px; flex: none;
  background: linear-gradient(135deg, var(--g1), var(--g2));
  display: grid; place-items: center; color: #2b1406; font-weight: 800;
}
.za-brand-txt { overflow: hidden; white-space: nowrap; }
.za-brand-txt b { display: block; font-size: 1rem; line-height: 1.2; }
.za-brand-txt span { font-size: .68rem; color: var(--t3); }
.za-collapsed .za-brand-txt { display: none; }

.za-nav { flex: 1; overflow-y: auto; padding: .7rem .5rem; }
.za-nav-group { margin-bottom: .3rem; }
.za-nav-title {
  padding: .7rem .75rem .35rem; font-size: .68rem; letter-spacing: .12em;
  color: var(--t3); text-transform: uppercase;
}
.za-collapsed .za-nav-title { text-align: center; font-size: 0; }
.za-nav-item {
  display: flex; align-items: center; gap: .7rem;
  padding: .6rem .75rem; margin: 1px 0; border-radius: 9px;
  color: var(--t2); font-size: .9rem; cursor: pointer; user-select: none;
  border: 0; background: transparent; width: 100%; text-align: left;
  transition: color .14s ease, background .14s ease;
}
.za-nav-item:hover { color: var(--t1); background: rgba(255, 255, 255, .05); }
.za-nav-item.za-on {
  color: #fff;
  background: linear-gradient(135deg, rgba(255, 169, 77, .2), rgba(242, 118, 43, .13));
  box-shadow: inset 0 0 0 1px rgba(255, 169, 77, .28);
}
.za-nav-item svg { width: 1.15rem; height: 1.15rem; flex: none; }
.za-nav-item .za-nav-label { overflow: hidden; white-space: nowrap; }
.za-collapsed .za-nav-label { display: none; }
.za-collapsed .za-nav-item { justify-content: center; padding: .6rem 0; }
.za-nav-badge {
  margin-left: auto; min-width: 1.1rem; height: 1.1rem; padding: 0 .3rem;
  border-radius: 999px; background: var(--g2); color: #fff;
  font-size: .68rem; display: grid; place-items: center;
}
.za-collapsed .za-nav-badge { display: none; }

.za-side-foot { flex: none; padding: .7rem; border-top: 1px solid var(--line); }

/* 顶栏 */
.za-main { display: flex; flex-direction: column; overflow: hidden; }
.za-top {
  height: 60px; flex: none;
  display: flex; align-items: center; gap: 1rem;
  padding: 0 1.5rem; border-bottom: 1px solid var(--line);
  background: var(--bg-2);
}
.za-collapse-btn {
  width: 2.1rem; height: 2.1rem; border: 1px solid var(--line); border-radius: 8px;
  background: transparent; color: var(--t2); display: grid; place-items: center;
}
.za-collapse-btn:hover { color: var(--t1); border-color: var(--line-2); }
.za-crumb { font-size: 1.05rem; font-weight: 600; }
.za-crumb span { color: var(--t3); font-weight: 400; font-size: .85rem; margin-left: .6rem; }
.za-top-right { margin-left: auto; display: flex; align-items: center; gap: .8rem; }
.za-admin-chip {
  display: flex; align-items: center; gap: .55rem;
  padding: .38rem .5rem .38rem .38rem; border-radius: 999px;
  border: 1px solid var(--line); background: rgba(255, 255, 255, .03);
  font-size: .86rem;
}
.za-admin-chip i {
  width: 1.7rem; height: 1.7rem; border-radius: 50%; font-style: normal;
  background: linear-gradient(135deg, var(--g1), var(--g2)); color: #2b1406;
  display: grid; place-items: center; font-weight: 700; font-size: .82rem;
}
.za-logout {
  padding: .45rem .95rem; border-radius: 8px; border: 1px solid var(--line);
  background: transparent; color: var(--t2); font-size: .84rem;
}
.za-logout:hover { color: var(--bad); border-color: rgba(255, 122, 107, .4); }

.za-body { flex: 1; overflow-y: auto; padding: 1.6rem; }

/* ══════════ 通用组件 ══════════ */
.za-card {
  background: linear-gradient(160deg, var(--panel-hi), transparent), var(--panel);
  border: 1px solid var(--line); border-radius: 14px;
}
.za-card-head {
  display: flex; align-items: center; gap: .7rem;
  padding: 1rem 1.25rem; border-bottom: 1px solid var(--line);
}
.za-card-head h3 { margin: 0; font-size: 1rem; font-weight: 600; }
.za-card-head .za-sub { color: var(--t3); font-size: .82rem; }
.za-card-body { padding: 1.25rem; }

.za-btn {
  height: 2.4rem; padding: 0 1.1rem; border-radius: 9px;
  border: 1px solid var(--line); background: rgba(255, 255, 255, .04);
  color: var(--t2); font-size: .88rem;
  display: inline-flex; align-items: center; gap: .4rem;
  transition: color .14s ease, border-color .14s ease, background .14s ease;
}
.za-btn:hover { color: var(--t1); border-color: var(--line-2); }
.za-btn-primary {
  border: 0; background: linear-gradient(135deg, var(--g1), var(--g2)); color: #2b1406; font-weight: 700;
}
.za-btn-primary:hover { filter: brightness(1.06); }
.za-btn svg { width: 1rem; height: 1rem; }
.za-btn-sm { height: 2rem; padding: 0 .8rem; font-size: .82rem; }

.za-input {
  height: 2.4rem; padding: 0 .9rem; border-radius: 9px;
  border: 1px solid var(--line); background: rgba(255, 255, 255, .035);
  color: var(--t1); font-size: .88rem; outline: none;
}
.za-input:focus { border-color: rgba(255, 169, 77, .45); }

/* KPI 卡片 */
.za-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.za-kpi {
  padding: 1.25rem 1.35rem; border-radius: 14px;
  background: linear-gradient(160deg, var(--panel-hi), transparent), var(--panel);
  border: 1px solid var(--line); position: relative; overflow: hidden;
}
.za-kpi::after {
  content: ""; position: absolute; right: -20px; top: -20px;
  width: 90px; height: 90px; border-radius: 50%;
  background: radial-gradient(circle, var(--kpi-glow, rgba(255,169,77,.16)), transparent 70%);
}
.za-kpi-label { font-size: .82rem; color: var(--t3); display: flex; align-items: center; gap: .4rem; }
.za-kpi-label svg { width: 1rem; height: 1rem; opacity: .7; }
.za-kpi-val { font-size: 1.9rem; font-weight: 700; margin-top: .4rem; font-variant-numeric: tabular-nums; line-height: 1.1; }
.za-kpi-sub { font-size: .78rem; color: var(--t3); margin-top: .35rem; }
.za-kpi-sub b { color: var(--ok); font-weight: 600; }

/* 图表 */
.za-grid-2 { display: grid; grid-template-columns: 1.6fr 1fr; gap: 1rem; margin-top: 1rem; }
.za-chart { width: 100%; display: block; overflow: visible; }
.za-bar-row { display: flex; align-items: center; gap: .8rem; margin-bottom: .85rem; }
.za-bar-name { width: 8.5rem; flex: none; font-size: .84rem; color: var(--t2); text-align: right; }
.za-bar-track { flex: 1; height: .7rem; border-radius: 5px; background: rgba(255, 255, 255, .05); overflow: hidden; }
.za-bar-fill { height: 100%; border-radius: 5px; background: linear-gradient(90deg, var(--g2), var(--g1)); }
.za-bar-val { width: 5.5rem; flex: none; font-size: .82rem; color: var(--t2); font-variant-numeric: tabular-nums; }

/* 表格 */
.za-table { width: 100%; border-collapse: collapse; }
.za-table th {
  text-align: left; padding: .8rem 1rem; font-size: .78rem; font-weight: 600;
  color: var(--t3); border-bottom: 1px solid var(--line); white-space: nowrap;
}
.za-table td {
  padding: .9rem 1rem; font-size: .88rem; border-bottom: 1px solid rgba(255, 255, 255, .045);
  vertical-align: middle;
}
.za-table tr:hover td { background: rgba(255, 255, 255, .025); }
.za-table .za-mono { font-variant-numeric: tabular-nums; }
.za-t-strong { font-weight: 600; }
.za-t-dim { color: var(--t3); font-size: .8rem; }

.za-tag {
  display: inline-block; padding: .12rem .55rem; border-radius: 999px;
  font-size: .72rem; font-weight: 600;
}
.za-tag-ok { background: rgba(78, 224, 176, .16); color: var(--ok); }
.za-tag-warn { background: rgba(255, 209, 102, .16); color: var(--warn); }
.za-tag-bad { background: rgba(255, 122, 107, .16); color: var(--bad); }
.za-tag-info { background: rgba(108, 199, 255, .16); color: var(--info); }
.za-tag-plain { background: rgba(255, 255, 255, .07); color: var(--t2); }

/* 工具条 */
.za-toolbar { display: flex; align-items: center; gap: .7rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.za-toolbar .za-spacer { flex: 1; }

/* 空态 / 加载 */
.za-empty { padding: 3.5rem 1rem; text-align: center; color: var(--t3); font-size: .9rem; }
.za-loading { padding: 3rem; text-align: center; color: var(--t3); }
.za-skeleton { height: 1rem; border-radius: 5px; background: linear-gradient(100deg, rgba(255,255,255,.04) 30%, rgba(255,255,255,.09) 50%, rgba(255,255,255,.04) 70%); background-size: 200% 100%; animation: za-sk 1.3s linear infinite; }
@keyframes za-sk { from { background-position: 200% 0; } to { background-position: -200% 0; } }

/* 分页 */
.za-pager { display: flex; align-items: center; justify-content: flex-end; gap: .7rem; margin-top: 1rem; }
.za-pager span { font-size: .84rem; color: var(--t3); }

/* toast */
.za-toast {
  position: fixed; left: 50%; bottom: 2.5rem; transform: translateX(-50%) translateY(1rem);
  padding: .75rem 1.4rem; border-radius: 10px;
  background: var(--panel-2); border: 1px solid var(--line-2); color: var(--t1);
  font-size: .9rem; box-shadow: 0 16px 40px rgba(0, 0, 0, .5);
  opacity: 0; pointer-events: none; transition: opacity .2s ease, transform .2s ease; z-index: 300;
}
.za-toast.za-show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* 建设中占位 */
.za-soon { padding: 4rem 2rem; text-align: center; }
.za-soon svg { width: 3.5rem; height: 3.5rem; color: var(--t3); opacity: .5; margin-bottom: 1rem; }
.za-soon h3 { margin: 0 0 .5rem; font-size: 1.15rem; }
.za-soon p { color: var(--t3); font-size: .9rem; max-width: 30rem; margin: 0 auto; line-height: 1.7; }

/* 模态 */
.za-modal {
  position: fixed; inset: 0; z-index: 250; display: grid; place-items: center;
  background: rgba(4, 6, 9, .6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  padding: 1.5rem;
}
.za-modal-card {
  width: min(30rem, 94vw); border-radius: 16px;
  background: var(--panel); border: 1px solid var(--line-2);
  box-shadow: 0 34px 90px rgba(0, 0, 0, .7); overflow: hidden;
}
.za-modal-head { display: flex; align-items: center; justify-content: space-between; padding: 1.1rem 1.3rem; border-bottom: 1px solid var(--line); font-weight: 600; }
.za-modal-head button { border: 0; background: transparent; color: var(--t3); font-size: 1.4rem; width: 1.9rem; height: 1.9rem; border-radius: 7px; }
.za-modal-head button:hover { color: #fff; background: rgba(255,255,255,.08); }
.za-modal-body { padding: 1.3rem; }
.za-modal-foot { display: flex; justify-content: flex-end; gap: .7rem; padding: 1rem 1.3rem; border-top: 1px solid var(--line); }

@media (max-width: 1100px) {
  .za-kpis { grid-template-columns: repeat(2, 1fr); }
  .za-grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .za-shell { grid-template-columns: 0 1fr; }
  .za-kpis { grid-template-columns: 1fr; }
}

/* ===== 充值套餐卡片（后台，点卡片编辑）===== */
.za-fbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin: 0 0 1.1rem; }
.za-ftabs { display: inline-flex; gap: .4rem; padding: .25rem; border-radius: 10px; background: rgba(255, 255, 255, .04); }
.za-ftab { border: 0; background: none; cursor: pointer; font-family: inherit; padding: .45rem 1.1rem; border-radius: 8px; font-size: .88rem; color: var(--t2); transition: background .16s, color .16s; }
.za-ftab:hover { color: var(--t1); }
.za-ftab.za-on { background: linear-gradient(135deg, #ffa94d, #f2762b); color: #2b1406; font-weight: 700; }
.za-ftab-pe.za-on { background: rgba(255, 169, 77, .14); color: #ffa94d; }
.za-pcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr)); gap: .85rem; }
.za-pcard { position: relative; display: flex; flex-direction: column; border-radius: 14px; padding: 1.15rem 1rem 1rem; cursor: pointer;
  background: linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .015)); border: 1px solid var(--line);
  transition: transform .18s ease, border-color .18s ease, box-shadow .2s ease; }
.za-pcard:hover { transform: translateY(-3px); border-color: rgba(255, 169, 77, .55); box-shadow: 0 16px 38px -18px rgba(242, 118, 43, .55); }
.za-pcard-hot { border-color: rgba(255, 169, 77, .32); }
.za-pcard-badge { position: absolute; top: -.6rem; left: 1rem; padding: .16rem .65rem; border-radius: 999px; font-size: .68rem; font-weight: 700; color: #2b1406; background: linear-gradient(135deg, #ffd08a, #f2762b); }
.za-pcard-hd { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.za-pcard-name { font-size: 1.05rem; font-weight: 700; color: var(--t1); }
.za-pcard-price { margin-top: .55rem; font-size: 1.55rem; font-weight: 800; color: #fff; }
.za-pcard-price em { font-size: .76rem; font-weight: 500; font-style: normal; color: var(--t3); }
.za-pcard-feats { margin-top: .7rem; display: flex; flex-direction: column; gap: .28rem; font-size: .76rem; color: var(--t2); line-height: 1.4; min-height: 4rem; }
.za-pcard-foot { display: flex; align-items: center; gap: .4rem; margin-top: .9rem; padding-top: .7rem; border-top: 1px solid var(--line); }
.za-pcard-edit { margin-left: auto; font-size: .78rem; color: #ffa94d; white-space: nowrap; }
.za-pcard-add { align-items: center; justify-content: center; gap: .3rem; border-style: dashed; color: var(--t3); min-height: 13rem; }
.za-pcard-add:hover { color: #ffa94d; border-color: rgba(255, 169, 77, .55); box-shadow: none; transform: translateY(-3px); }
.za-pcard-plus { font-size: 1.9rem; line-height: 1; }

/* ===== 成本利润 · 类目卡片 ===== */
.za-cpcards { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: .9rem; }
.za-cpcard { border-radius: 14px; padding: 1.1rem 1.15rem; background: linear-gradient(180deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, .012)); border: 1px solid var(--line); }
.za-cpcard-h { display: flex; align-items: center; justify-content: space-between; font-size: 1.05rem; font-weight: 700; color: var(--t1); margin-bottom: .85rem; }
.za-cpcard-rows { display: flex; flex-direction: column; gap: .5rem; }
.za-cpcard-rows > div { display: flex; align-items: center; justify-content: space-between; font-size: .85rem; }
.za-cpcard-rows > div span { color: var(--t3); }
.za-cpcard-rows > div b { color: var(--t1); font-variant-numeric: tabular-nums; }
.za-cpr-hi { padding-top: .55rem; margin-top: .1rem; border-top: 1px dashed var(--line); }
.za-cpr-hi b { color: #ffa94d !important; font-size: 1.05rem; }

/* ===== 计费调价 · 分类切换 + 单模型多规格 ===== */
.za-price-page { width: min(100%, 1480px); margin: 0 auto; }
.za-price-intro {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 2rem;
  padding: 1.35rem 1.5rem; border: 1px solid rgba(255, 169, 77, .18); border-radius: 16px;
  background:
    radial-gradient(34rem 16rem at 0 0, rgba(255, 169, 77, .12), transparent 65%),
    linear-gradient(145deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .012)), var(--panel);
}
.za-price-eyebrow { display: block; margin-bottom: .45rem; color: var(--g1); font-size: .68rem; font-weight: 700; letter-spacing: .15em; }
.za-price-intro h2 { margin: 0; font-size: 1.35rem; letter-spacing: -.01em; }
.za-price-intro p { max-width: 54rem; margin: .55rem 0 0; color: var(--t2); font-size: .86rem; line-height: 1.75; }
.za-price-rule {
  min-width: 18rem; padding: .85rem 1rem; border: 1px solid var(--line); border-radius: 12px;
  background: rgba(7, 9, 13, .34); text-align: right;
}
.za-price-rule span, .za-price-rule small { display: block; color: var(--t3); font-size: .72rem; }
.za-price-rule strong { display: block; margin: .2rem 0; color: var(--g1); font-size: 1.15rem; font-variant-numeric: tabular-nums; }

.za-price-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; margin: 1rem 0; }
.za-price-tab {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: .8rem;
  min-height: 4.6rem; padding: .8rem 1rem; border: 1px solid var(--line); border-radius: 14px;
  background: linear-gradient(155deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, .01)), var(--panel);
  color: var(--t2); text-align: left; transition: transform .16s ease, border-color .16s ease, background .16s ease, box-shadow .16s ease;
}
.za-price-tab:hover { transform: translateY(-1px); color: var(--t1); border-color: var(--line-2); }
.za-price-tab.za-on {
  color: var(--t1); border-color: rgba(255, 169, 77, .48);
  background: linear-gradient(145deg, rgba(255, 169, 77, .16), rgba(242, 118, 43, .055)), var(--panel);
  box-shadow: 0 14px 36px -24px rgba(242, 118, 43, .8), inset 0 0 0 1px rgba(255, 169, 77, .08);
}
.za-price-tab-icon {
  width: 2.35rem; height: 2.35rem; border-radius: 10px; display: grid; place-items: center;
  background: rgba(255, 255, 255, .055); color: var(--t2); font-weight: 700;
}
.za-price-tab.za-on .za-price-tab-icon { color: #2b1406; background: linear-gradient(135deg, var(--g1), var(--g2)); }
.za-price-tab-copy { min-width: 0; }
.za-price-tab-copy b, .za-price-tab-copy small { display: block; }
.za-price-tab-copy b { color: inherit; font-size: .98rem; }
.za-price-tab-copy small { margin-top: .2rem; overflow: hidden; color: var(--t3); font-size: .7rem; text-overflow: ellipsis; white-space: nowrap; }
.za-price-tab-count { padding: .25rem .55rem; border-radius: 999px; background: rgba(255, 255, 255, .055); color: var(--t3); font-size: .7rem; white-space: nowrap; }
.za-price-tab.za-on .za-price-tab-count { background: rgba(255, 169, 77, .13); color: var(--g1); }

.za-price-category-head {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  margin: 1.1rem 0 .75rem; padding: 0 .15rem;
}
.za-price-category-head > div:first-child { display: flex; align-items: center; gap: .75rem; }
.za-price-category-head > div:first-child > span {
  width: 2.2rem; height: 2.2rem; display: grid; place-items: center; border-radius: 9px;
  background: rgba(255, 169, 77, .11); color: var(--g1); font-size: .8rem; font-weight: 700;
}
.za-price-category-head h3 { margin: 0; font-size: 1.02rem; }
.za-price-category-head p { margin: .18rem 0 0; color: var(--t3); font-size: .74rem; }
.za-price-category-kpis { display: flex; align-items: center; gap: .5rem; }
.za-price-category-kpis span { padding: .35rem .65rem; border: 1px solid var(--line); border-radius: 8px; color: var(--t3); font-size: .72rem; }
.za-price-category-kpis b { color: var(--t1); font-size: .82rem; }

.za-price-models { display: flex; flex-direction: column; gap: .85rem; }
.za-price-model {
  overflow: hidden; border: 1px solid var(--line); border-radius: 16px;
  background: linear-gradient(155deg, rgba(255, 255, 255, .035), transparent 42%), var(--panel);
}
.za-price-model-head {
  display: grid; grid-template-columns: auto minmax(16rem, 1fr) auto; align-items: center; gap: 1rem;
  padding: 1rem 1.15rem; border-bottom: 1px solid var(--line);
}
.za-price-model-mark {
  width: 2.8rem; height: 2.8rem; display: grid; place-items: center; border-radius: 12px;
  color: #2b1406; font-size: .9rem; font-weight: 800;
  background: linear-gradient(135deg, #ffd08a, var(--g2)); box-shadow: 0 10px 24px -14px rgba(242, 118, 43, .9);
}
.za-price-model-name { min-width: 0; }
.za-price-model-name > div:first-child { display: flex; align-items: center; gap: .55rem; flex-wrap: wrap; }
.za-price-model-name h3 { margin: 0; color: var(--t1); font-size: 1.03rem; }
.za-price-model-name p { margin: .28rem 0 0; overflow: hidden; color: var(--t2); font-size: .76rem; text-overflow: ellipsis; white-space: nowrap; }
.za-price-model-meta { display: flex; align-items: center; gap: .4rem; margin-top: .4rem; flex-wrap: wrap; }
.za-price-model-meta span { padding: .16rem .45rem; border-radius: 6px; background: rgba(255, 255, 255, .045); color: var(--t3); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .66rem; }
.za-price-model-kpis { display: grid; grid-template-columns: repeat(3, minmax(6.7rem, auto)); gap: .45rem; }
.za-price-model-kpis > div { min-height: 3.15rem; padding: .55rem .7rem; border: 1px solid var(--line); border-radius: 9px; background: rgba(7, 9, 13, .25); }
.za-price-model-kpis span, .za-price-model-kpis b { display: block; }
.za-price-model-kpis span { color: var(--t3); font-size: .65rem; }
.za-price-model-kpis b { margin-top: .2rem; color: var(--t1); font-size: .78rem; font-variant-numeric: tabular-nums; white-space: nowrap; }

.za-price-spec-wrap { overflow-x: auto; }
.za-price-spec-head, .za-price-spec-row {
  display: grid; grid-template-columns: minmax(13rem, 1.35fr) minmax(8rem, .72fr) minmax(11rem, 1fr) minmax(11rem, 1fr) minmax(8rem, .72fr) 8.4rem;
  align-items: center; column-gap: 1rem; min-width: 1080px;
}
.za-price-spec-head { padding: .68rem 1.15rem; color: var(--t3); font-size: .68rem; font-weight: 600; letter-spacing: .02em; }
.za-price-spec-row { padding: .78rem 1.15rem; border-top: 1px solid rgba(255, 255, 255, .045); transition: background .14s ease; }
.za-price-spec-row:hover { background: rgba(255, 255, 255, .018); }
.za-price-spec-id strong, .za-price-spec-id span, .za-price-spec-id em { display: block; }
.za-price-spec-id strong { color: var(--t1); font-size: .88rem; }
.za-price-spec-id span { margin-top: .25rem; color: var(--t3); font-size: .69rem; }
.za-price-spec-id em { width: fit-content; margin-top: .35rem; padding: .15rem .42rem; border-radius: 5px; background: rgba(255, 209, 102, .11); color: var(--warn); font-size: .62rem; font-style: normal; }
.za-price-billing strong, .za-price-billing span { display: block; }
.za-price-billing strong { color: var(--t1); font-size: .79rem; }
.za-price-billing span { margin-top: .24rem; color: var(--t3); font-size: .68rem; }
.za-price-edit { min-width: 0; }
.za-price-input { display: flex; align-items: center; height: 2.35rem; overflow: hidden; border: 1px solid var(--line); border-radius: 9px; background: rgba(255, 255, 255, .035); transition: border-color .14s ease, background .14s ease; }
.za-price-input:focus-within { border-color: rgba(255, 169, 77, .5); background: rgba(255, 169, 77, .035); }
.za-price-input input { min-width: 0; width: 100%; height: 100%; padding: 0 .75rem; border: 0; outline: 0; background: transparent; color: var(--t1); font: inherit; font-size: .84rem; font-variant-numeric: tabular-nums; }
.za-price-input span { align-self: stretch; display: grid; place-items: center; padding: 0 .62rem; border-left: 1px solid var(--line); color: var(--t3); font-size: .68rem; white-space: nowrap; }
.za-price-edit > small { display: block; margin-top: .25rem; overflow: hidden; color: var(--t3); font-size: .65rem; text-overflow: ellipsis; white-space: nowrap; }
.za-price-profit strong, .za-price-profit span, .za-price-profit small { display: block; }
.za-price-profit strong { color: var(--ok); font-size: .92rem; font-variant-numeric: tabular-nums; }
.za-price-profit strong.za-neg { color: var(--bad); }
.za-price-profit span { margin-top: .16rem; color: var(--ok); font-size: .68rem; }
.za-price-profit span.za-wait { color: var(--warn); }
.za-price-profit small { margin-top: .14rem; color: var(--t3); font-size: .63rem; }
.za-price-save { width: 100%; justify-content: center; white-space: nowrap; }
.za-price-spec-row input:disabled, .za-price-spec-row button:disabled { cursor: wait; opacity: .58; }
.za-price-footnote {
  margin-top: .85rem; padding: .85rem 1rem; border: 1px solid var(--line); border-radius: 11px;
  background: rgba(255, 255, 255, .018); color: var(--t3); font-size: .72rem; line-height: 1.75;
}
.za-price-footnote b { color: var(--t2); }

@media (max-width: 1260px) {
  .za-price-model-head { grid-template-columns: auto minmax(0, 1fr); }
  .za-price-model-kpis { grid-column: 1 / -1; grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 920px) {
  .za-price-intro { grid-template-columns: 1fr; gap: 1rem; }
  .za-price-rule { min-width: 0; text-align: left; }
  .za-price-tabs { grid-template-columns: 1fr; }
  .za-price-category-head { align-items: flex-start; flex-direction: column; }
  .za-price-category-kpis { width: 100%; }
  .za-price-category-kpis span { flex: 1; text-align: center; }
}
@media (max-width: 720px) {
  .za-price-intro { padding: 1.1rem; }
  .za-price-tab { min-height: 4.25rem; }
  .za-price-model-head { grid-template-columns: auto minmax(0, 1fr); padding: .9rem; }
  .za-price-model-kpis { grid-template-columns: 1fr; }
}

/* ===== AI 模型健康·卡片仪表盘 ===== */
.za-health-page { width: min(100%, 1480px); margin: 0 auto; }
.za-health-hero {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 2rem;
  padding: 1.4rem 1.5rem; border: 1px solid rgba(108, 199, 255, .17); border-radius: 16px;
  background:
    radial-gradient(38rem 18rem at 0 0, rgba(108, 199, 255, .11), transparent 68%),
    linear-gradient(145deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .012)), var(--panel);
}
.za-health-hero > div:first-child > span { display: block; margin-bottom: .42rem; color: var(--info); font-size: .68rem; font-weight: 700; letter-spacing: .15em; }
.za-health-hero h2 { margin: 0; font-size: 1.35rem; letter-spacing: -.01em; }
.za-health-hero p { max-width: 54rem; margin: .55rem 0 0; color: var(--t2); font-size: .86rem; line-height: 1.75; }
.za-health-actions { display: flex; flex-direction: column; align-items: flex-end; gap: .55rem; }
.za-health-actions small { color: var(--t3); font-size: .72rem; }
.za-health-actions .za-btn { min-width: 10rem; justify-content: center; }
.za-health-actions .za-btn:disabled { cursor: wait; opacity: .58; }

.za-health-summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: .8rem; margin: 1rem 0; }
.za-health-summary > div {
  min-width: 0; padding: .9rem 1rem; border: 1px solid var(--line); border-radius: 13px;
  background: linear-gradient(150deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, .01)), var(--panel);
}
.za-health-summary span, .za-health-summary b, .za-health-summary small { display: block; }
.za-health-summary span { color: var(--t3); font-size: .72rem; }
.za-health-summary b { margin-top: .12rem; color: var(--t1); font-size: 1.65rem; line-height: 1.2; font-variant-numeric: tabular-nums; }
.za-health-summary small { margin-top: .25rem; overflow: hidden; color: var(--t3); font-size: .65rem; text-overflow: ellipsis; white-space: nowrap; }
.za-health-summary .za-hs-ok { border-color: rgba(78, 224, 176, .18); background: linear-gradient(145deg, rgba(78, 224, 176, .065), transparent), var(--panel); }
.za-health-summary .za-hs-ok b { color: var(--ok); }
.za-health-summary .za-hs-bad { border-color: rgba(255, 122, 107, .18); background: linear-gradient(145deg, rgba(255, 122, 107, .06), transparent), var(--panel); }
.za-health-summary .za-hs-bad b { color: var(--bad); }

.za-health-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9rem; }
.za-health-card {
  position: relative; min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 16px;
  background: linear-gradient(155deg, rgba(255, 255, 255, .038), transparent 42%), var(--panel);
  transition: border-color .18s ease, box-shadow .2s ease;
}
.za-health-card::before { content: ""; position: absolute; z-index: 2; top: 0; left: 0; right: 0; height: 2px; background: rgba(255, 255, 255, .12); }
.za-health-card.za-health-healthy { border-color: rgba(78, 224, 176, .22); box-shadow: inset 0 0 0 1px rgba(78, 224, 176, .025); }
.za-health-card.za-health-healthy::before { background: linear-gradient(90deg, transparent, var(--ok), transparent); }
.za-health-card.za-health-unhealthy { border-color: rgba(255, 122, 107, .3); box-shadow: inset 0 0 0 1px rgba(255, 122, 107, .035); }
.za-health-card.za-health-unhealthy::before { background: linear-gradient(90deg, transparent, var(--bad), transparent); }
.za-health-card.za-health-checking { border-color: rgba(108, 199, 255, .34); }
.za-health-card.za-health-checking::before { width: 42%; right: auto; background: linear-gradient(90deg, transparent, var(--info), transparent); animation: za-health-scan 1.1s ease-in-out infinite; }
@keyframes za-health-scan { 0% { left: -42%; } 100% { left: 100%; } }

.za-health-card-top { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: .85rem; padding: 1.05rem 1.1rem .85rem; }
.za-health-model-mark {
  width: 2.65rem; height: 2.65rem; display: grid; place-items: center; border-radius: 11px;
  background: rgba(108, 199, 255, .1); color: var(--info); font-size: .82rem; font-weight: 800;
}
.za-health-healthy .za-health-model-mark { background: rgba(78, 224, 176, .1); color: var(--ok); }
.za-health-unhealthy .za-health-model-mark { background: rgba(255, 122, 107, .1); color: var(--bad); }
.za-health-model-name { min-width: 0; }
.za-health-model-name > div { display: flex; align-items: center; gap: .45rem; flex-wrap: wrap; }
.za-health-model-name h3 { margin: 0; overflow: hidden; color: var(--t1); font-size: 1rem; text-overflow: ellipsis; white-space: nowrap; }
.za-health-model-name p { margin: .28rem 0 0; overflow: hidden; color: var(--t3); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .67rem; text-overflow: ellipsis; white-space: nowrap; }
.za-health-state { display: flex; align-items: center; gap: .55rem; min-width: 7rem; justify-content: flex-end; }
.za-health-state > i {
  width: 2.1rem; height: 2.1rem; display: grid; place-items: center; border-radius: 50%;
  background: rgba(255, 255, 255, .065); color: var(--t3); font-size: .82rem; font-style: normal; font-weight: 800;
}
.za-health-state strong, .za-health-state span { display: block; text-align: right; }
.za-health-state strong { color: var(--t2); font-size: .85rem; }
.za-health-state span { margin-top: .12rem; color: var(--t3); font-size: .64rem; font-variant-numeric: tabular-nums; }
.za-health-healthy .za-health-state > i { background: rgba(78, 224, 176, .14); color: var(--ok); box-shadow: 0 0 0 5px rgba(78, 224, 176, .04); }
.za-health-healthy .za-health-state strong { color: var(--ok); }
.za-health-unhealthy .za-health-state > i { background: rgba(255, 122, 107, .14); color: var(--bad); box-shadow: 0 0 0 5px rgba(255, 122, 107, .04); }
.za-health-unhealthy .za-health-state strong { color: var(--bad); }
.za-health-checking .za-health-state > i { background: rgba(108, 199, 255, .12); color: var(--info); animation: za-health-pulse 1s ease-in-out infinite; }
.za-health-checking .za-health-state strong { color: var(--info); }
@keyframes za-health-pulse { 50% { transform: scale(.88); opacity: .58; } }

.za-health-message { display: flex; align-items: center; gap: .5rem; margin: 0 1.1rem; padding: .62rem .72rem; border: 1px solid var(--line); border-radius: 9px; background: rgba(6, 9, 13, .3); }
.za-health-message b { overflow: hidden; color: var(--t2); font-size: .73rem; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.za-health-signal { width: .5rem; height: .5rem; flex: none; border-radius: 50%; background: var(--t3); box-shadow: 0 0 0 4px rgba(255, 255, 255, .025); }
.za-health-healthy .za-health-signal { background: var(--ok); box-shadow: 0 0 0 4px rgba(78, 224, 176, .07); }
.za-health-unhealthy .za-health-signal { background: var(--bad); box-shadow: 0 0 0 4px rgba(255, 122, 107, .07); }
.za-health-checking .za-health-signal { background: var(--info); animation: za-health-pulse 1s ease-in-out infinite; }

.za-health-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 1rem; row-gap: .65rem; padding: .9rem 1.1rem; }
.za-health-facts > div { min-width: 0; }
.za-health-facts span, .za-health-facts b { display: block; }
.za-health-facts span { color: var(--t3); font-size: .63rem; }
.za-health-facts b { margin-top: .2rem; overflow: hidden; color: var(--t2); font-size: .71rem; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.za-health-facts .za-health-mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .66rem; }

.za-health-specs { margin: 0 1.1rem .9rem; padding: .72rem; border: 1px solid var(--line); border-radius: 10px; background: rgba(255, 255, 255, .014); }
.za-health-spec-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: .5rem; }
.za-health-spec-title span { color: var(--t3); font-size: .65rem; }
.za-health-spec-title small { color: var(--t3); font-size: .62rem; }
.za-health-spec-list { display: flex; align-items: stretch; gap: .42rem; overflow-x: auto; padding-bottom: .08rem; }
.za-health-spec-list > span { min-width: 7rem; padding: .42rem .52rem; border-radius: 7px; background: rgba(255, 255, 255, .04); }
.za-health-spec-list b, .za-health-spec-list small { display: block; white-space: nowrap; }
.za-health-spec-list b { color: var(--t2); font-size: .68rem; }
.za-health-spec-list small { margin-top: .18rem; color: var(--t3); font-size: .59rem; }
.za-health-card-foot { display: flex; align-items: center; justify-content: space-between; padding: .68rem 1.1rem; border-top: 1px solid var(--line); color: var(--t3); font-size: .65rem; }
.za-health-retry {
  min-width: 7.4rem; padding: .45rem .75rem; border: 1px solid rgba(108, 199, 255, .28); border-radius: 8px;
  background: rgba(108, 199, 255, .09); color: var(--info); cursor: pointer; font: inherit; font-size: .68rem; font-weight: 700;
  transition: background .16s ease, border-color .16s ease, transform .16s ease;
}
.za-health-retry:hover { transform: translateY(-1px); border-color: rgba(108, 199, 255, .58); background: rgba(108, 199, 255, .16); }
.za-health-retry:focus-visible { outline: 2px solid rgba(108, 199, 255, .42); outline-offset: 2px; }
.za-health-retry:disabled { cursor: wait; opacity: .55; transform: none; }
.za-health-healthy .za-health-retry { border-color: rgba(78, 224, 176, .28); background: rgba(78, 224, 176, .08); color: var(--ok); }
.za-health-unhealthy .za-health-retry { border-color: rgba(255, 122, 107, .32); background: rgba(255, 122, 107, .08); color: var(--bad); }
.za-health-note { margin-top: .85rem; padding: .8rem .95rem; border: 1px solid var(--line); border-radius: 10px; background: rgba(255, 255, 255, .016); color: var(--t3); font-size: .7rem; line-height: 1.75; }
.za-health-note b { color: var(--t2); }

@media (max-width: 1180px) {
  .za-health-grid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .za-health-hero { grid-template-columns: 1fr; gap: 1rem; }
  .za-health-actions { align-items: flex-start; }
  .za-health-summary { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
  .za-health-summary { grid-template-columns: 1fr; }
  .za-health-card-top { grid-template-columns: auto minmax(0, 1fr); }
  .za-health-state { grid-column: 1 / -1; justify-content: flex-start; }
  .za-health-state strong, .za-health-state span { text-align: left; }
  .za-health-facts { grid-template-columns: 1fr; }
  .za-health-card-foot { align-items: stretch; flex-direction: column; gap: .55rem; }
  .za-health-retry { width: 100%; }
}
