/* ============================================================
   PRTS TACTICAL SKIN — 聚星控制台
   零外部依赖：无 CDN、无 Google Fonts、无图标字体
   ============================================================ */

:root {
  --bg: #090a0f;
  --surface: #12151e;
  --surface-alt: #1a1f2c;
  --border: rgba(255, 255, 255, 0.18);
  --border-light: rgba(255, 255, 255, 0.11);

  --text: #e6edf5;
  --text-secondary: #b6c2d1;
  --text-muted: #8b98a8;

  --primary: #00e5ff;
  --primary-hover: #6ff0ff;
  --primary-bg: rgba(0, 229, 255, 0.10);
  --primary-border: rgba(0, 229, 255, 0.45);

  --success: #34d399;
  --success-bg: rgba(52, 211, 153, 0.12);
  --success-border: rgba(52, 211, 153, 0.40);
  --success-text: #6ee7b7;

  --warning: #ffea00;
  --warning-bg: rgba(255, 234, 0, 0.10);
  --warning-border: rgba(255, 234, 0, 0.40);
  --warning-text: #ffe95c;

  --danger: #ff2a55;
  --danger-hover: #ff5577;
  --danger-bg: rgba(255, 42, 85, 0.12);
  --danger-border: rgba(255, 42, 85, 0.45);
  --danger-text: #ff8ea3;

  --orange: #ff5500;
  --radius: 0px;
  --shadow: none;

  --font-mono: ui-monospace, "Cascadia Mono", "JetBrains Mono", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --font-ui: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
  font-family: var(--font-ui);
  font-size: 14px;
  line-height: 1.55;
  color: var(--text);
  background-color: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* === 战术点阵 + 网格背景 === */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    radial-gradient(rgba(255, 255, 255, 0.075) 1px, transparent 0),
    linear-gradient(to right, rgba(0, 229, 255, 0.022) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(0, 229, 255, 0.022) 1px, transparent 1px);
  background-size: 24px 24px, 96px 96px, 96px 96px;
}

/* === CRT 扫描线 === */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  background: linear-gradient(rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.34) 50%);
  background-size: 100% 4px;
  opacity: 0.55;
}

#prts-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }

.hidden { display: none !important; }
.mono { font-family: var(--font-mono); font-variant-ligatures: none; }
.danger { color: var(--danger-text); }
.warn { color: var(--warning-text); }

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

::selection { background: var(--primary); color: #05060a; }

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #06070a; }
::-webkit-scrollbar-thumb { background: rgba(0, 229, 255, 0.55); }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }

/* ============================================================
   开机序列
   ============================================================ */
#boot-screen {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: #06070a;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 28px clamp(16px, 4vw, 48px);
  transition: opacity 0.6s ease;
}
#boot-screen.boot-done { opacity: 0; pointer-events: none; }
.boot-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}
.boot-top .blink {
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--primary);
  margin-right: 8px;
  animation: prts-blink 1.1s steps(2, start) infinite;
}
.boot-top .cy { color: var(--primary); }
@keyframes prts-blink { 50% { opacity: 0.15; } }

.boot-mid {
  margin: auto;
  width: 100%;
  max-width: 560px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.boot-emblem { position: relative; width: 104px; height: 104px; margin-bottom: 26px; }
.boot-emblem svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.boot-emblem .ring-a { animation: prts-spin 26s linear infinite; color: rgba(0, 229, 255, 0.32); }
.boot-emblem .ring-b { animation: prts-spin-r 18s linear infinite; color: rgba(255, 234, 0, 0.45); }
@keyframes prts-spin { to { transform: rotate(360deg); } }
@keyframes prts-spin-r { from { transform: rotate(360deg); } to { transform: rotate(0); } }
.boot-core {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 26px;
  height: 26px;
  margin: -13px 0 0 -13px;
  transform: rotate(45deg);
  background: rgba(0, 229, 255, 0.18);
  border: 2px solid var(--primary);
  box-shadow: 0 0 18px rgba(0, 229, 255, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
}
.boot-core i { display: block; width: 7px; height: 7px; background: #fff; }

.boot-meter { width: 100%; font-family: var(--font-mono); }
.boot-meter-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 6px;
}
#boot-status {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#boot-percent { font-size: 22px; font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.boot-track {
  height: 8px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  padding: 1px;
  background: rgba(255, 255, 255, 0.06);
}
#boot-bar {
  height: 100%;
  width: 0%;
  background: var(--primary);
  box-shadow: 0 0 10px var(--primary);
  transition: width 0.12s linear;
}
#boot-console {
  height: 76px;
  overflow: hidden;
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.45);
}
#boot-console div { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

#skip-boot {
  margin-top: 22px;
  padding: 6px 14px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: rgba(255, 255, 255, 0.6);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
#skip-boot:hover { color: var(--primary); border-color: var(--primary); }

.boot-bot { display: flex; flex-direction: column; gap: 8px; }
.hazard-stripes {
  height: 5px;
  background: repeating-linear-gradient(-45deg, var(--warning), var(--warning) 8px, #090a0f 8px, #090a0f 16px);
  opacity: 0.7;
}
.boot-bot-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.38);
}

/* ============================================================
   登录页
   ============================================================ */
.auth-wrapper {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px 16px;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: linear-gradient(150deg, rgba(22, 27, 38, 0.94) 0%, rgba(13, 16, 23, 0.97) 100%);
  border: 1px solid var(--border);
  padding: 28px 26px 26px;
  position: relative;
}
.auth-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 64px;
  height: 2px;
  background: var(--primary);
  box-shadow: 0 0 10px var(--primary);
}
.auth-card::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 22px;
  height: 22px;
  background: linear-gradient(225deg, rgba(0, 229, 255, 0.85) 50%, transparent 50%);
}

.brand-header { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.brand-logo {
  width: 36px;
  height: 36px;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  color: #05060a;
  font-weight: 800;
  font-size: 17px;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 9px), calc(100% - 9px) 100%, 0 100%);
}
.brand-title {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #fff;
}
.brand-sub {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border-light);
}

.auth-tabs { display: flex; gap: 0; margin-bottom: 20px; border-bottom: 1px solid var(--border); }
.auth-tab {
  flex: 1;
  padding: 10px 8px;
  background: transparent;
  border: 0;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: color 0.18s, border-color 0.18s, background 0.18s;
  margin-bottom: -1px;
}
.auth-tab:hover { color: var(--text); background: rgba(255, 255, 255, 0.03); }
.auth-tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
  background: var(--primary-bg);
}

/* ============================================================
   按钮 —— 斜切角
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 16px;
  border: 1px solid transparent;
  background: var(--primary);
  color: #05060a;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.03em;
  line-height: 1.25;
  cursor: pointer;
  white-space: nowrap;
  text-align: center;
  clip-path: polygon(9px 0, 100% 0, 100% calc(100% - 9px), calc(100% - 9px) 100%, 0 100%, 0 9px);
  transition: background 0.16s, color 0.16s, box-shadow 0.16s;
}
.btn:hover:not(:disabled) { background: var(--primary-hover); text-decoration: none; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
/* focus 环必须画在按钮外面。原来用 inset 内阴影，深色按钮上完全看不见 ——
   键盘 Tab 到主按钮时没有任何视觉反馈，属于 WCAG 2.4.7 失败。
   改用 outline + offset，任何底色上都可见，且不影响布局。 */
.btn:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; box-shadow: none; }

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.22);
}
.btn-secondary:hover:not(:disabled) {
  background: rgba(0, 229, 255, 0.12);
  border-color: var(--primary-border);
  color: #fff;
}

.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover:not(:disabled) { background: var(--danger-hover); }
.btn-danger:focus-visible { box-shadow: inset 0 0 0 2px #05060a; }

.btn-success { background: var(--success); color: #04120c; }
.btn-success:hover:not(:disabled) { background: #5ee9b4; }

.btn-sm { padding: 5px 10px; font-size: 12px; clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px); }

a.btn { text-decoration: none; }

/* ============================================================
   表单
   ============================================================ */
.input, .select, .textarea {
  width: 100%;
  padding: 9px 11px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--text);
  font-size: 13px;
  transition: border-color 0.16s, box-shadow 0.16s, background 0.16s;
}
.input::placeholder, .textarea::placeholder { color: rgba(255, 255, 255, 0.28); }
.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: rgba(0, 229, 255, 0.05);
  box-shadow: 0 0 0 1px rgba(0, 229, 255, 0.35);
}
.input.mono, .textarea.mono { font-family: var(--font-mono); font-size: 12px; }
.select {
  appearance: none;
  padding-right: 30px;
  background-image: linear-gradient(45deg, transparent 50%, var(--primary) 50%), linear-gradient(135deg, var(--primary) 50%, transparent 50%);
  background-position: calc(100% - 15px) calc(50% + 1px), calc(100% - 10px) calc(50% + 1px);
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
.select option { background: #12151e; color: var(--text); }
.textarea { min-height: 90px; resize: vertical; }
input[type="file"].input { padding: 7px 9px; font-size: 12px; }
input[type="file"]::file-selector-button {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 4px 10px;
  margin-right: 10px;
  font-size: 12px;
  cursor: pointer;
}

.label {
  display: block;
  margin-bottom: 5px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.form-group { margin-bottom: 15px; }
.code-block, code {
  font-family: var(--font-mono);
  font-size: 12px;
}
code {
  background: rgba(0, 229, 255, 0.10);
  border: 1px solid rgba(0, 229, 255, 0.22);
  padding: 1px 5px;
  color: #9beeff;
}

/* ============================================================
   徽章
   ============================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border: 1px solid transparent;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.5;
  white-space: nowrap;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%);
}
.badge-primary { background: var(--primary-bg); color: var(--primary); border-color: var(--primary-border); }
.badge-success { background: var(--success-bg); color: var(--success-text); border-color: var(--success-border); }
.badge-warning { background: var(--warning-bg); color: var(--warning-text); border-color: var(--warning-border); }
.badge-danger { background: var(--danger-bg); color: var(--danger-text); border-color: var(--danger-border); }
.badge-neutral { background: rgba(255, 255, 255, 0.07); color: var(--text-secondary); border-color: rgba(255, 255, 255, 0.16); }

/* ============================================================
   主应用外壳
   ============================================================ */
#app-view { position: relative; z-index: 1; min-height: 100vh; display: flex; flex-direction: column; }

.app-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(9, 10, 15, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.user-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.user-email {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-secondary);
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.prts-clock {
  font-family: var(--font-mono);
  text-align: right;
  line-height: 1.1;
  padding-left: 14px;
  border-left: 1px solid var(--border);
  margin-right: 4px;
}
.prts-clock b { display: block; font-size: 15px; font-weight: 700; letter-spacing: 0.08em; color: #fff; font-variant-numeric: tabular-nums; }
.prts-clock span { display: block; font-size: 10px; letter-spacing: 0.1em; color: var(--primary); margin-top: 3px; }

.prts-sfx {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  background: var(--primary-bg);
  border: 1px solid var(--primary-border);
  color: var(--primary);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  cursor: pointer;
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
}
.prts-sfx[aria-pressed="false"] {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.18);
  color: var(--text-muted);
}
.prts-sfx i { width: 6px; height: 6px; background: currentColor; display: block; }
.prts-sfx[aria-pressed="true"] i { animation: prts-blink 1.4s steps(2, start) infinite; }

/* 顶部导航 */
.nav-bar {
  position: sticky;
  top: 62px;
  z-index: 39;
  background: rgba(12, 14, 20, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav-inner::-webkit-scrollbar { display: none; }
.nav-btn {
  flex: none;
  padding: 11px 16px;
  background: transparent;
  border: 0;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.16s, border-color 0.16s, background 0.16s;
}
.nav-btn::before { content: "// "; color: rgba(255, 255, 255, 0.2); }
.nav-btn:hover { color: #fff; background: rgba(255, 255, 255, 0.04); }
.nav-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
  background: var(--primary-bg);
}
.nav-btn.active::before { color: var(--primary); }

.main-container {
  max-width: 1280px;
  width: 100%;
  margin: 0 auto;
  padding: 22px 20px 40px;
  flex: 1;
}
.view-section { display: flex; flex-direction: column; gap: 16px; }

/* ============================================================
   卡片 —— 斜切角 + 悬停扫描光
   ============================================================ */
.card {
  position: relative;
  background-image:
    linear-gradient(105deg, transparent 34%, rgba(0, 229, 255, 0.075) 50%, transparent 66%),
    linear-gradient(150deg, rgba(22, 27, 38, 0.90) 0%, rgba(13, 16, 23, 0.96) 100%);
  background-size: 260% 100%, 100% 100%;
  background-position: 175% 0, 0 0;
  background-repeat: no-repeat;
  border: 1px solid var(--border);
  padding: 18px;
  overflow: hidden;
  transition: background-position 0.8s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.25s, box-shadow 0.25s;
}
.card:hover { background-position: -55% 0, 0 0; }
.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 40px;
  height: 2px;
  background: var(--primary);
  opacity: 0.85;
}
.card::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 20px;
  height: 20px;
  background: linear-gradient(225deg, rgba(255, 255, 255, 0.22) 50%, transparent 50%);
  transition: background 0.25s;
  pointer-events: none;
}
.card:hover { border-color: rgba(0, 229, 255, 0.42); box-shadow: 0 10px 28px -14px rgba(0, 229, 255, 0.28); }
.card:hover::after { background: linear-gradient(225deg, var(--primary) 50%, transparent 50%); }

.card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-light);
}
.card-title {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
}
.card-title::before {
  content: "";
  width: 3px;
  height: 14px;
  background: var(--primary);
  box-shadow: 0 0 8px var(--primary);
  flex: none;
}
.card-sub {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 5px;
  line-height: 1.6;
}

/* 统计块 */
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }

.stat-box {
  position: relative;
  background: rgba(0, 0, 0, 0.38);
  border: 1px solid var(--border-light);
  padding: 12px 14px;
  overflow: hidden;
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.25s, box-shadow 0.25s;
}
.stat-box:hover {
  transform: translateY(-3px);
  border-color: rgba(0, 229, 255, 0.55);
  box-shadow: 0 10px 24px -12px rgba(0, 229, 255, 0.35), inset 0 0 14px rgba(0, 229, 255, 0.05);
}
.stat-box:hover::before { opacity: 1; width: 3px; box-shadow: 0 0 10px var(--primary); }
.stat-box::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--primary);
  opacity: 0.6;
}
.stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.stat-value {
  font-family: var(--font-mono);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.15;
  color: #fff;
  font-variant-numeric: tabular-nums;
}
.stat-meta { font-size: 11px; color: var(--text-muted); margin-top: 5px; font-family: var(--font-mono); }

/* 进度条 */
.progress-track {
  height: 6px;
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.07);
  overflow: hidden;
  margin-top: 8px;
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, rgba(0, 229, 255, 0.55), var(--primary));
  box-shadow: 0 0 10px rgba(0, 229, 255, 0.6);
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* 三态框 */
.state-box {
  padding: 30px 18px;
  text-align: center;
  border: 1px dashed rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.3);
  color: var(--text-muted);
  font-size: 13px;
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
}
.state-box strong { color: var(--text); }

/* 提示条 */
.alert {
  border: 1px solid var(--border);
  border-left-width: 3px;
  padding: 10px 13px;
  font-size: 13px;
  line-height: 1.65;
  background: rgba(0, 0, 0, 0.35);
  color: var(--text-secondary);
}
.alert-info { border-left-color: var(--primary); background: rgba(0, 229, 255, 0.07); color: #bfeaf3; }
.alert-success { border-left-color: var(--success); background: var(--success-bg); color: var(--success-text); }
.alert-warning { border-left-color: var(--warning); background: var(--warning-bg); color: var(--warning-text); }
.alert-danger { border-left-color: var(--danger); background: var(--danger-bg); color: var(--danger-text); }
.alert strong { color: inherit; }
.steps-list { margin: 8px 0 0 18px; padding: 0; }
.steps-list li { margin-bottom: 5px; line-height: 1.7; }

/* 表格 */
.table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--border-light);
  background: rgba(0, 0, 0, 0.28);
}
.table-wrap table { width: 100%; border-collapse: collapse; font-size: 12.5px; min-width: 640px; }
.table-wrap th {
  position: sticky;
  top: 0;
  background: #171c27;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.table-wrap td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
  vertical-align: middle;
}
.table-wrap tbody tr { transition: background 0.15s; }
.table-wrap tbody tr:hover { background: rgba(0, 229, 255, 0.05); }
.table-wrap tbody tr:last-child td { border-bottom: 0; }
.table-wrap td.mono, .table-wrap td .mono { font-family: var(--font-mono); font-size: 11.5px; }

/* 子标签 */
.sub-tabs { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
.sub-tab {
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  cursor: pointer;
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
  transition: all 0.16s;
}
.sub-tab:hover { color: #fff; border-color: var(--primary-border); }
.sub-tab.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #05060a;
  font-weight: 700;
}

/* 代码块 */
.code-block {
  background: #06070a;
  border: 1px solid var(--border);
  border-left: 2px solid var(--primary);
  padding: 14px;
  overflow-x: auto;
  white-space: pre;
  line-height: 1.7;
  color: #9beeff;
  font-family: var(--font-mono);
  font-size: 12px;
  tab-size: 2;
}

/* 弹窗 */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(3px);
  overflow-y: auto;
}
.modal-card {
  position: relative;
  width: 100%;
  max-width: 460px;
  background: #10131c;
  border: 1px solid var(--primary);
  box-shadow: 0 0 40px rgba(0, 229, 255, 0.2);
  padding: 22px;
  clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 18px, 100% 100%, 14px 100%, 0 calc(100% - 14px));
}
.modal-card::before {
  content: "";
  display: block;
  height: 5px;
  margin: -22px -22px 16px;
  background: repeating-linear-gradient(-45deg, var(--warning), var(--warning) 8px, #090a0f 8px, #090a0f 16px);
  opacity: 0.75;
}
.modal-title {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 14px;
  letter-spacing: 0.02em;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-light);
}
.modal-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  flex-wrap: wrap;
  margin-top: 18px;
}

/* ============================================================
   底部终端
   ============================================================ */
.prts-footer {
  position: relative;
  z-index: 20;
  border-top: 1px solid var(--border);
  background: rgba(7, 8, 12, 0.94);
  backdrop-filter: blur(8px);
}
.prts-footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 9px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.term-log { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.term-tag {
  flex: none;
  padding: 2px 7px;
  background: rgba(255, 255, 255, 0.09);
  border-left: 2px solid var(--primary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--primary);
}
#term-log-text {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
#term-log-text time { color: rgba(255, 255, 255, 0.42); margin-right: 6px; }

.term-right { display: flex; align-items: center; gap: 14px; }
.spectrum { display: flex; align-items: flex-end; gap: 3px; height: 20px; }
.spectrum span {
  display: block;
  width: 3px;
  background: var(--primary);
  opacity: 0.8;
  transition: height 0.16s linear, background 0.16s;
}
.term-copy {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.35);
  white-space: nowrap;
}

/* ============================================================
   响应式
   ============================================================ */
@media (max-width: 900px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .header-inner { height: auto; padding: 10px 14px; }
  .prts-clock { display: none; }
  .nav-bar { top: 0; position: relative; }
  .nav-inner { padding: 0 10px; gap: 2px; }
  .nav-btn { padding: 9px 9px; font-size: 11px; letter-spacing: 0; }
  .nav-btn::before { content: none; }
  .main-container { padding: 16px 12px 32px; }
  .card { padding: 14px; }
  .stat-value { font-size: 19px; }
  .grid-2, .grid-4 { grid-template-columns: 1fr; }
  .modal-card { padding: 18px; }
  .modal-card::before { margin: -18px -18px 14px; }
  .user-email { max-width: 130px; }
  .term-copy { display: none; }
}
@media (max-width: 420px) {
  .auth-card { padding: 22px 18px; }
  .brand-title { font-size: 17px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  #boot-screen { display: none !important; }
}


/* ==================== 登录页品牌区 ==================== */
.auth-wrapper { gap: 60px; }

.auth-brand {
  flex: 0 1 470px;
  max-width: 470px;
  position: relative;
  z-index: 1;
  animation: brandIn 0.9s cubic-bezier(0.16, 1, 0.3, 1) both;
}
@keyframes brandIn {
  from { opacity: 0; transform: translateX(-18px); }
  to { opacity: 1; transform: none; }
}

.brand-rule {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  color: var(--primary);
  text-transform: uppercase;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 22px;
}
.brand-rule-tail { margin-left: auto; color: var(--text-muted); letter-spacing: 0.12em; }

.brand-h1 {
  margin: 0;
  font-size: clamp(44px, 5vw, 68px);
  line-height: 0.95;
  font-weight: 900;
  letter-spacing: 0.04em;
  color: var(--text);
  text-shadow: 0 0 40px rgba(0, 229, 255, 0.18);
}
.brand-h1-i {
  color: var(--primary);
  text-shadow: 0 0 28px rgba(0, 229, 255, 0.55);
}

.brand-latin {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.55em;
  color: var(--text-muted);
  margin: 10px 0 22px;
  text-transform: uppercase;
}

.brand-p {
  margin: 0 0 26px;
  font-size: 13px;
  line-height: 1.9;
  color: var(--text-secondary);
}

.brand-specs {
  list-style: none;
  margin: 0 0 26px;
  padding: 0;
  display: grid;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}
.brand-specs li {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 9px 12px;
  background: rgba(9, 10, 15, 0.72);
  font-size: 12px;
}
.brand-specs b {
  flex: 0 0 74px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  color: var(--primary);
  font-weight: 500;
}
.brand-specs span { color: var(--text-secondary); }

.brand-ruler {
  height: 14px;
  background-image: repeating-linear-gradient(to right,
    rgba(255, 255, 255, 0.22) 0 1px, transparent 1px 8px),
    repeating-linear-gradient(to right,
    rgba(255, 255, 255, 0.42) 0 1px, transparent 1px 40px);
  background-position: 0 100%, 0 100%;
  background-size: 100% 6px, 100% 14px;
  background-repeat: no-repeat;
  opacity: 0.7;
  margin-bottom: 14px;
}

.brand-stripes {
  height: 5px;
  opacity: 0.55;
  margin-bottom: 12px;
  -webkit-mask-image: linear-gradient(to right, #000 0%, #000 46%, transparent 100%);
          mask-image: linear-gradient(to right, #000 0%, #000 46%, transparent 100%);
}

.brand-foot {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  color: var(--text-muted);
  text-transform: uppercase;
}

@media (max-width: 1080px) {
  .auth-brand { flex-basis: 380px; }
  .brand-latin { letter-spacing: 0.4em; }
}
@media (max-width: 900px) {
  .auth-brand { display: none; }
  .auth-wrapper { gap: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .auth-brand { animation: none; }
}


/* === 强制覆盖内联浅色（403 横幅） === */
#global-403-banner {
  background: rgba(255, 42, 85, 0.16);
  color: var(--danger-text);
  padding: 12px 16px;
  font-weight: 600;
  border-bottom: 1px solid var(--danger-border);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
}

/* 请求日志：估算 Token 的 ≈ 标记。刻意做得不抢眼——
   它是「这个数不精确」的提示，不是告警。 */
.tok-est {
  color: var(--text-muted);
  font-size: .85em;
  margin-left: 2px;
  opacity: .7;
  cursor: help;
}

/* ============================================================
   PRTS — 管理台视图（内嵌进 index.html）
   与 _prts.css 共用色板变量；只补 admin 需要的结构
   ============================================================ */

/* === 顶栏管理员入口 === */
.admin-entry {
  display: none;
  align-items: center;
  gap: 6px;
  padding: 5px 11px 5px 9px;
  border: 1px solid var(--primary-border);
  background: var(--primary-bg);
  color: var(--primary);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  cursor: pointer;
  white-space: nowrap;
}
.admin-entry.is-on { display: inline-flex; }
.admin-entry:hover { background: rgba(0, 229, 255, 0.2); color: #d6fbff; }
.admin-entry svg { width: 13px; height: 13px; flex: none; }
.admin-entry .ae-badge {
  padding: 1px 5px;
  background: var(--warning);
  color: #090a0f;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
}

/* === 管理视图公共骨架 === */
.view-section[data-admin] > .adm-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 0 0 14px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--border-light);
}
.adm-head h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text);
}
.adm-head h2::before {
  content: "//";
  color: var(--primary);
  font-family: var(--font-mono);
  font-weight: 400;
  opacity: 0.7;
}
.adm-head .adm-hint {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}

/* === KPI 统计条 === */
.adm-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  gap: 1px;
  margin-bottom: 16px;
  background: var(--border-light);
  border: 1px solid var(--border);
}
.adm-stat {
  display: flex;
  flex-direction: column;
  align-items: baseline;
  gap: 2px;
  padding: 12px 14px;
  min-width: 0;
  background: var(--surface);
  position: relative;
}
.adm-stat::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 2px; height: 100%;
  background: var(--primary);
  opacity: 0.55;
}
.adm-stat .k {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  text-transform: uppercase;
}
.adm-stat .v {
  font-family: var(--font-mono);
  font-size: 22px;
  font-weight: 600;
  line-height: 1.15;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.adm-stat .v.warn { color: var(--warning-text); }
.adm-stat .v.bad { color: var(--danger-text); }
.adm-stat .v.good { color: var(--success-text); }
.adm-stat .s {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

/* === 工具栏（搜索/筛选） === */
.adm-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.adm-toolbar input[type="text"],
.adm-toolbar input[type="search"],
.adm-toolbar select {
  flex: 1 1 190px;
  min-width: 0;
  padding: 7px 10px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12px;
  border-radius: 0;
}
.adm-toolbar input:focus,
.adm-toolbar select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 1px rgba(0, 229, 255, 0.35);
}

/* === 管理表格 === */
.adm-table-wrap {
  border: 1px solid var(--border);
  background: var(--surface);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.adm-table {
  width: 100%;
  min-width: 660px;
  table-layout: auto;
  border-collapse: collapse;
  font-size: 12.5px;
}
.adm-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 9px 10px;
  background: var(--surface-alt);
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: left;
  white-space: nowrap;
}
.adm-table tbody td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-secondary);
  vertical-align: middle;
}
.adm-table tbody tr:last-child td { border-bottom: none; }
.adm-table tbody tr:hover td { background: rgba(0, 229, 255, 0.055); }
.adm-table td:first-child { width: 1%; white-space: nowrap; }
.adm-table td.num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}
.adm-table td.mono {
  font-family: var(--font-mono);
  font-size: 11.5px;
  white-space: nowrap;
}
.adm-table td.mail {
  max-width: 210px;
  min-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text);
}
.adm-table td.acts {
  white-space: nowrap;
  text-align: right;
}

/* 行内控件 */
.adm-table select,
.adm-table input[type="number"] {
  padding: 4px 7px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 11.5px;
  border-radius: 0;
  max-width: 108px;
}
.adm-table select:focus,
.adm-table input:focus {
  outline: none;
  border-color: var(--primary);
}
/* 数字输入必须显式定宽：继承到 input{width:100%} 时在 table-cell 里会塌成 0 */
.adm-table input.adm-num {
  width: 84px;
  max-width: 84px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
/* 档位说明可编辑：给足宽度，否则一行只显示几个字 */
.adm-table input.adm-desc {
  width: 100%;
  min-width: 180px;
  max-width: 320px;
  text-align: left;
}
.adm-table .mini {
  padding: 3px 8px;
  margin-left: 4px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  cursor: pointer;
  border-radius: 0;
}
.adm-table .mini:hover {
  border-color: var(--primary-border);
  color: var(--primary);
  background: var(--primary-bg);
}
.adm-table .mini.danger:hover {
  border-color: var(--danger-border);
  color: var(--danger-text);
  background: var(--danger-bg);
}
.adm-table .mini.ok:hover {
  border-color: var(--success-border);
  color: var(--success-text);
  background: var(--success-bg);
}

/* 状态标签 */
.tag {
  display: inline-block;
  padding: 1px 7px;
  border: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}
.tag.ok { color: var(--success-text); border-color: var(--success-border); background: var(--success-bg); }
.tag.bad { color: var(--danger-text); border-color: var(--danger-border); background: var(--danger-bg); }
.tag.warn { color: var(--warning-text); border-color: var(--warning-border); background: var(--warning-bg); }
.tag.brand { color: var(--primary); border-color: var(--primary-border); background: var(--primary-bg); }
.tag.dim { color: var(--text-muted); }

/* 分页 */
.adm-pager {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 9px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-muted);
}
.adm-pager button {
  padding: 4px 10px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  cursor: pointer;
  border-radius: 0;
}
.adm-pager button:hover:not([disabled]) {
  border-color: var(--primary-border);
  color: var(--primary);
}
.adm-pager button[disabled] { opacity: 0.35; cursor: not-allowed; }

/* 空态 / 错误态 */
.adm-state {
  padding: 26px 14px;
  text-align: center;
  border: 1px dashed var(--border);
  background: var(--surface);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 12px;
}
.adm-state.err {
  border-color: var(--danger-border);
  background: var(--danger-bg);
  color: var(--danger-text);
}
.adm-state .retry {
  margin-left: 10px;
  padding: 3px 9px;
  background: transparent;
  border: 1px solid currentColor;
  color: inherit;
  font-family: var(--font-mono);
  font-size: 11px;
  cursor: pointer;
}

/* 上游健康块 */
.up-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-light);
}
.up-row:last-child { border-bottom: none; }
.up-name {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text);
}
.up-meta {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-muted);
  word-break: break-all;
}
.up-dot {
  width: 7px; height: 7px;
  display: inline-block;
  margin-right: 6px;
  background: var(--text-muted);
  box-shadow: 0 0 6px currentColor;
}
.up-dot.on { background: var(--success); color: var(--success); }
.up-dot.off { background: var(--danger); color: var(--danger); }

/* 一次性明文 */
.secret-box {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  margin: 10px 0;
  border: 1px solid var(--warning-border);
  background: var(--warning-bg);
}
.secret-box code {
  flex: 1;
  min-width: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--warning-text);
  word-break: break-all;
  user-select: all;
}

/* 375 断点 */
@media (max-width: 720px) {
  .adm-stats { grid-template-columns: repeat(2, 1fr); }
  .adm-stat .v { font-size: 19px; }
  .adm-head h2 { font-size: 14px; }
  .adm-toolbar input[type="text"] { flex: 1 1 100%; }
  .adm-table { min-width: 600px; }
  .admin-entry .ae-label { display: none; }
}

/* ---------- 请求日志：Tokens 入/出 双行显示 ---------- */
/* 之前把 prompt+completion 加成一个大数字，看不出是「输入大」还是
   「输出大」——排查成本时才分得清。两行竖排比横排省宽度，375px 下不挤。 */
.tok-cell {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 1px;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
}
.tok-in  { color: var(--text-muted); font-size: 11px; }
.tok-out { color: var(--text); font-size: 12px; }
/* ≈ 标记：上游没回 usage，这个数是网关按字符数估的，不是精确计费值 */
.tok-tag {
  color: var(--text-muted);
  font-size: 10px;
  opacity: .75;
  margin-left: 2px;
}

/* 请求日志 9 列在窄屏挤成一团。Tokens 改单行（入/出横排），
   首字是次要诊断信息，≤900px 直接隐藏 —— 它仍可用「耗时」近似判断。 */
@media (min-width: 901px) {
  .tok-cell { flex-direction: row; align-items: baseline; gap: 6px; }
  .tok-in, .tok-out { font-size: 12px; }
}
@media (max-width: 900px) {
  .col-ttft { display: none; }
  .adm-table { min-width: 540px; }
}


/* === 公开模型大厅（/models） === */
body.public-models #app-view > .app-header,
body.public-models #app-view > .nav-bar { display: none; }
body.public-models #public-header { display: block; }
body.public-models .main-container { padding-top: 24px; }

/* === P3 CSP Level 2: 纯 CSS 类替代内联 style 属性 === */
.u-w100 { width: 100%; }
.u-w100-mt6 { width: 100%; margin-top: 6px; }
.u-flex-row { display: flex; align-items: center; gap: 10px; }
.u-flex-gap6-wrap { display: flex; gap: 6px; flex-wrap: wrap; }
.u-flex-gap8 { display: flex; gap: 8px; }
.u-flex-gap8-wrap { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.u-flex-between { display: flex; justify-content: space-between; align-items: center; }
.u-flex-between-wrap { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.u-flex-between-mb6 { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; flex-wrap: wrap; gap: 8px; }
.u-mt-8 { margin-top: 8px; }
.u-mt-10 { margin-top: 10px; }
.u-mt-12 { margin-top: 12px; }
.u-mt-14 { margin-top: 14px; }
.u-mt-16 { margin-top: 16px; }
.u-mb-10 { margin-bottom: 10px; }
.u-mb-14 { margin-bottom: 14px; }
.u-mb-18 { margin-bottom: 18px; }
.u-ml-8 { margin-left: 8px; }
.u-m-0 { margin: 0; }
.u-align-right { text-align: right; }
.u-text-danger { color: var(--danger-text); }
.u-text-danger-bold { color: var(--danger-text); font-weight: 600; }
.u-text-danger-lead { color: var(--danger-text); font-weight: 700; font-size: 15px; }
.u-text-ok { color: var(--success-text); }
.u-text-primary { color: var(--primary); }
.u-text-plain { color: var(--text); }

.banner-403-inner { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.brand-logo-sm { width: 28px; height: 28px; font-size: 15px; }
.brand-title-sm { font-weight: 700; font-size: 16px; }
.redeem-form { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.redeem-input-wrap { flex: 1; min-width: 220px; }
.redeem-ok-title { font-weight: 700; font-size: 14px; margin-bottom: 6px; }
.sub-tabs-inline { margin-bottom: 0; align-items: center; }
.hall-search-input { max-width: 220px; }
.hall-family-select { width: 120px; }
.key-form-grid { align-items: end; }
.logs-pagination { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.docs-key-label { font-size: 13px; font-weight: 600; color: var(--text-secondary); }
.docs-key-select { width: auto; min-width: 160px; }
.adm-invite-num { flex: 0 0 82px; }
.adm-invite-hint { margin: -2px 0 10px; }
.adm-invite-created { margin: 0 0 12px; padding: 12px; border: 1px solid var(--success-border); background: var(--success-bg); }
.adm-invite-created-title { color: var(--success-text); font-size: 12px; }
.adm-invite-codes { margin: 0; white-space: pre-wrap; word-break: break-all; color: var(--text); font-size: 12px; line-height: 1.7; }
.confirm-body-text { color: var(--text-secondary); font-size: 14px; }
.summary-history-title { font-size: 14px; font-weight: 700; margin-bottom: 8px; color: var(--text-secondary); }

.adm-toast-fallback { position: fixed; right: 16px; bottom: 16px; z-index: 400; max-width: min(340px, 80vw); padding: 9px 13px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font: 12px/1.5 var(--font-mono); pointer-events: none; transition: opacity .25s; opacity: 0; }
.adm-toast-fallback.is-visible { opacity: 1; }
.adm-stat-v-sm { font-size: 13px; letter-spacing: 0; }
.up-row-single { grid-template-columns: 1fr; }
.adm-hint-wrap { white-space: normal; line-height: 1.7; }
.adm-hint-wrap-mt8 { margin-top: 8px; white-space: normal; line-height: 1.7; }
.adm-hint-wrap-mb8 { margin-bottom: 8px; white-space: normal; line-height: 1.7; }
.adm-hint-wrap-my8 { margin: 8px 0; white-space: normal; line-height: 1.7; }
.adm-hint-wrap-mb10 { margin: 0 0 10px; white-space: normal; line-height: 1.7; }
.adm-cell-wrap-200 { white-space: normal; max-width: 200px; }
.adm-cell-wrap-280 { white-space: normal; max-width: 280px; }
.adm-cell-wrap-340 { white-space: normal; max-width: 340px; }
.adm-cap-nodes { margin: 0 0 8px; padding: 8px 10px; border: 1px solid var(--border); border-radius: 4px; font-size: 12px; }
