/* 保证 hidden 属性优先于任何 display 布局规则 */
[hidden] { display: none !important; }

/* ==========================================================================
   发布后台样式 —— 与前台的鎏金新拟态同源，密度更高
   ========================================================================== */

:root {
  /* 鎏金主色（与前台一致） */
  --primary: #d4af37;
  --primary-2: #ffd966;
  --pink: #b8860b;
  --cyan: #c99a2e;
  --green: #48bb78;
  --amber: #ed8936;
  --red: #e53e3e;

  --text: #2d3748;
  --text-2: #4a5568;
  --text-3: #718096;
  --line: rgba(212, 175, 55, 0.16);
  --line-2: rgba(212, 175, 55, 0.1);

  --glass: rgba(255, 255, 255, 0.72);
  --glass-2: rgba(255, 255, 255, 0.55);
  --glass-3: rgba(255, 255, 255, 0.9);
  --stroke: rgba(255, 255, 255, 0.85);
  --tint: rgba(212, 175, 55, 0.08);

  --shadow-sm: 0 2px 10px rgba(180, 140, 40, 0.08);
  --shadow: 0 10px 34px rgba(180, 140, 40, 0.12);
  --shadow-lg: 0 30px 70px rgba(90, 70, 15, 0.22);

  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;

  --page: linear-gradient(180deg, #eef1f5 0%, #e8ecf1 40%, #f0ede4 100%);
  --side-w: 226px;
}

html[data-theme='dark'] {
  --text: #f2f2f7;
  --text-2: #b8b8c4;
  --text-3: #9a9aa6;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.05);

  --glass: rgba(20, 20, 29, 0.72);
  --glass-2: rgba(255, 255, 255, 0.04);
  --glass-3: rgba(20, 20, 29, 0.95);
  --stroke: rgba(255, 255, 255, 0.08);
  --tint: rgba(212, 175, 55, 0.1);

  --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.4);
  --shadow: 0 12px 36px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 30px 80px rgba(0, 0, 0, 0.6);

  --page: linear-gradient(180deg, #07070d 0%, #0b0a12 50%, #07070d 100%);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html {
  background: var(--page);
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'HarmonyOS Sans SC', 'Noto Sans SC',
    'Microsoft YaHei', system-ui, sans-serif;
  background: var(--page);
  color: var(--text);
  min-height: 100vh;
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

button {
  border: 0;
  background: none;
  cursor: pointer;
}

img,
svg {
  display: block;
  max-width: 100%;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* ---------------- 登录 ---------------- */
.login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  position: relative;
  overflow: hidden;
}

.login-bg {
  position: absolute;
  inset: 0;
  filter: blur(80px);
  opacity: 0.6;
  pointer-events: none;
}

.login-bg i {
  position: absolute;
  border-radius: 50%;
  display: block;
}

.login-bg i:nth-child(1) {
  width: 46vw;
  height: 46vw;
  min-width: 300px;
  min-height: 300px;
  left: -8vw;
  top: -8vw;
  background: radial-gradient(circle, #ffd966, transparent 68%);
}
.login-bg i:nth-child(2) {
  width: 40vw;
  height: 40vw;
  min-width: 260px;
  min-height: 260px;
  right: -10vw;
  bottom: -6vw;
  background: radial-gradient(circle, #d4af37, transparent 68%);
}
.login-bg i:nth-child(3) {
  width: 34vw;
  height: 34vw;
  min-width: 220px;
  min-height: 220px;
  right: 18vw;
  top: 4vw;
  background: radial-gradient(circle, #fff6c6, transparent 70%);
}

html[data-theme='dark'] .login-bg {
  opacity: 0.34;
}

.login-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 380px;
  padding: 34px 28px 26px;
  border-radius: 26px;
  background: var(--glass);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  text-align: center;
}

.login-logo {
  width: 74px;
  height: 74px;
  margin: 0 auto 14px;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 10px 26px rgba(30, 27, 75, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.login-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.login-card h1 {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.login-sub {
  font-size: 12px;
  color: var(--text-3);
  margin: 4px 0 22px;
}

.login-field {
  display: block;
  text-align: left;
  margin-bottom: 12px;
}

.login-field span {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 6px;
}

.login-field input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--glass-3);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

html[data-theme='dark'] .login-field input {
  background: rgba(255, 255, 255, 0.05);
}

.login-field input:focus {
  border-color: rgba(212, 175, 55, 0.55);
  box-shadow: 0 0 0 3.5px rgba(212, 175, 55, 0.12);
}

.login-err {
  text-align: left;
  font-size: 12px;
  color: var(--red);
  margin: 2px 0 8px;
}

.btn-login {
  width: 100%;
  height: 48px;
  margin-top: 10px;
  border-radius: 13px;
  color: #2b1d00;
  font-size: 15px;
  font-weight: 700;
  background: linear-gradient(135deg, #ffd966, #d4af37);
  box-shadow: 0 12px 26px -10px rgba(212, 175, 55, 0.8);
  transition: transform 0.15s, opacity 0.2s;
}

.btn-login:active {
  transform: scale(0.985);
}

.btn-login[disabled] {
  opacity: 0.6;
}

.login-back {
  display: inline-block;
  margin-top: 16px;
  font-size: 12px;
  color: var(--text-3);
}

.login-back:hover {
  color: var(--primary);
}

/* ---------------- 框架 ---------------- */
.app {
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--side-w);
  z-index: 90;
  display: flex;
  flex-direction: column;
  padding: 18px 12px 14px;
  background: var(--glass-2);
  border-right: 1px solid var(--line);
  backdrop-filter: blur(26px) saturate(170%);
  -webkit-backdrop-filter: blur(26px) saturate(170%);
}

.side-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 8px 18px;
}

.side-brand img {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.side-brand strong {
  display: block;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.side-brand span {
  font-size: 10.5px;
  color: var(--text-3);
  letter-spacing: 0.06em;
}

.side-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  overflow-y: auto;
}

.side-nav a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 40px;
  padding: 0 12px;
  border-radius: 11px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-2);
  transition: all 0.18s ease;
}

.side-nav a svg {
  width: 17px;
  height: 17px;
  flex: none;
  opacity: 0.75;
}

.side-nav a:hover {
  background: var(--tint);
  color: var(--text);
}

.side-nav a.active {
  color: #2b1d00;
  background: linear-gradient(135deg, #ffd966, #d4af37);
  box-shadow: 0 8px 20px -10px rgba(212, 175, 55, 0.9);
  font-weight: 600;
}

.side-nav a.active svg {
  opacity: 1;
}

.nav-badge {
  margin-left: auto;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--red);
  color: #fff;
  font-size: 10.5px;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.side-foot {
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.side-home {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 12px;
  border-radius: 9px;
  font-size: 12px;
  color: var(--text-3);
}

.side-home:hover {
  color: var(--primary);
  background: var(--tint);
}

.side-home svg {
  width: 15px;
  height: 15px;
}

.side-user {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 6px 0;
}

.avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  flex: none;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 700;
  color: #2b1d00;
  background: linear-gradient(135deg, #ffd966, #d4af37);
}

.user-meta {
  flex: 1;
  min-width: 0;
}

.user-meta strong {
  display: block;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-meta span {
  font-size: 10.5px;
  color: var(--text-3);
}

.main {
  margin-left: var(--side-w);
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 70;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
  min-height: 60px;
  padding: 10px 22px;
  background: color-mix(in srgb, var(--page) 72%, transparent);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid var(--line);
}

@supports not (background: color-mix(in srgb, red 10%, blue)) {
  .topbar {
    background: rgba(247, 248, 255, 0.85);
  }
  html[data-theme='dark'] .topbar {
    background: rgba(10, 10, 18, 0.85);
  }
}

.topbar h1 {
  flex: 1;
  min-width: 0;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.top-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.menu-btn {
  display: none;
}

.icon-btn {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  color: var(--text-3);
  border: 1px solid transparent;
  transition: all 0.18s;
}

.icon-btn:hover {
  color: var(--text);
  background: var(--tint);
  border-color: var(--line);
}

.icon-btn svg {
  width: 17px;
  height: 17px;
}

.view {
  padding: 20px 22px 60px;
  max-width: 1240px;
}

/* ---------------- 通用组件 ---------------- */
.card {
  background: var(--glass);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
}

.card-pad {
  padding: 16px 18px;
}

.section-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.section-head h2 {
  font-size: 14.5px;
  font-weight: 700;
}

.section-head .sub {
  font-size: 11.5px;
  color: var(--text-3);
}

.section-head .spacer {
  flex: 1;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 36px;
  padding: 0 14px;
  border-radius: 10px;
  font-size: 12.5px;
  font-weight: 600;
  border: 1px solid var(--line);
  background: var(--glass-3);
  color: var(--text-2);
  transition: all 0.18s ease;
  white-space: nowrap;
}

.btn:hover {
  border-color: rgba(212, 175, 55, 0.35);
  color: var(--text);
}

.btn:active {
  transform: scale(0.97);
}

.btn svg {
  width: 15px;
  height: 15px;
}

.btn-primary {
  color: #2b1d00;
  border-color: transparent;
  background: linear-gradient(135deg, #ffd966, #d4af37);
  box-shadow: 0 8px 20px -10px rgba(212, 175, 55, 0.9);
}

.btn-primary:hover {
  color: #fff;
  filter: brightness(1.05);
}

.btn-danger {
  color: var(--red);
  border-color: rgba(239, 68, 68, 0.2);
  background: rgba(239, 68, 68, 0.06);
}

.btn-danger:hover {
  color: #fff;
  background: var(--red);
  border-color: var(--red);
}

.btn-sm {
  height: 30px;
  padding: 0 10px;
  font-size: 11.5px;
  border-radius: 8px;
}

.btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 22px;
  padding: 0 8px;
  border-radius: 7px;
  font-size: 11px;
  font-weight: 600;
  background: var(--tint);
  color: var(--text-2);
  border: 1px solid transparent;
  white-space: nowrap;
}

.chip-green {
  color: #047857;
  background: rgba(16, 185, 129, 0.12);
  border-color: rgba(16, 185, 129, 0.2);
}
.chip-amber {
  color: #b45309;
  background: rgba(245, 158, 11, 0.14);
  border-color: rgba(245, 158, 11, 0.22);
}
.chip-violet {
  color: #6d28d9;
  background: rgba(212, 175, 55, 0.13);
  border-color: rgba(212, 175, 55, 0.22);
}
.chip-red {
  color: #b91c1c;
  background: rgba(239, 68, 68, 0.11);
  border-color: rgba(239, 68, 68, 0.2);
}
.chip-gray {
  color: var(--text-3);
}

html[data-theme='dark'] .chip-green {
  color: #6ee7b7;
}
html[data-theme='dark'] .chip-amber {
  color: #fcd34d;
}
html[data-theme='dark'] .chip-violet {
  color: #c4b5fd;
}
html[data-theme='dark'] .chip-red {
  color: #fca5a5;
}

/* 输入 */
.field {
  display: block;
  margin-bottom: 12px;
}

.field > span.label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 6px;
}

.field .hint {
  font-weight: 400;
  color: var(--text-3);
  font-size: 10.5px;
}

input[type='text'],
input[type='password'],
input[type='number'],
input[type='url'],
input[type='email'],
input[type='datetime-local'],
select,
textarea {
  width: 100%;
  height: 40px;
  padding: 0 13px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background-color: var(--glass-2);
  box-shadow: inset 0 1px 2px rgba(180, 140, 40, 0.05);
  outline: none;
  color: var(--text);
  font-size: 13px;
  transition: border-color 0.18s, box-shadow 0.18s, background-color 0.18s;
}

input::placeholder,
textarea::placeholder { color: var(--text-3); }

textarea {
  height: auto;
  padding: 10px 13px;
  line-height: 1.6;
  resize: vertical;
}

input:hover,
select:hover,
textarea:hover { border-color: rgba(212, 175, 55, 0.28); }

html[data-theme='dark'] input,
html[data-theme='dark'] select,
html[data-theme='dark'] textarea {
  background-color: rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.22);
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(212, 175, 55, 0.55);
  background-color: var(--glass-strong);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.14);
}

select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%),
    linear-gradient(135deg, var(--text-3) 50%, transparent 50%);
  background-position: calc(100% - 16px) 18px, calc(100% - 11px) 18px;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 30px;
  cursor: pointer;
}

.form-grid {
  display: grid;
  gap: 0 14px;
  grid-template-columns: 1fr 1fr;
}

.form-grid .full {
  grid-column: 1 / -1;
}

.check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text-2);
  cursor: pointer;
  user-select: none;
}

.check input {
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
}

/* 开关 */
.switch {
  position: relative;
  width: 38px;
  height: 22px;
  flex: none;
}

.switch input {
  position: absolute;
  opacity: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  cursor: pointer;
}

.switch i {
  position: absolute;
  inset: 0;
  border-radius: 11px;
  background: rgba(120, 120, 150, 0.28);
  transition: background 0.2s;
  pointer-events: none;
}

.switch i::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s;
}

.switch input:checked + i {
  background: linear-gradient(135deg, #ffd966, #d4af37);
}

.switch input:checked + i::after {
  transform: translateX(16px);
}

.switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 11px 0;
  border-bottom: 1px dashed var(--line);
}

.switch-row:last-child {
  border-bottom: 0;
}

.switch-row .sw-text strong {
  display: block;
  font-size: 12.8px;
  font-weight: 600;
}

.switch-row .sw-text span {
  font-size: 11px;
  color: var(--text-3);
}

/* ---------------- 数据总览 ---------------- */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(158px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.stat {
  position: relative;
  padding: 14px 15px;
  border-radius: var(--r-md);
  background: var(--glass);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.stat::after {
  content: '';
  position: absolute;
  right: -20px;
  top: -30px;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.16), transparent 70%);
}

.stat .k {
  font-size: 11px;
  color: var(--text-3);
  letter-spacing: 0.03em;
  display: flex;
  align-items: center;
  gap: 5px;
}

.stat .v {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-top: 4px;
  font-variant-numeric: tabular-nums;
}

.stat .d {
  font-size: 10.5px;
  color: var(--text-3);
  margin-top: 2px;
}

.stat .d em {
  font-style: normal;
  color: var(--green);
}

.grid-dash {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 12px;
}

.chart-wrap {
  padding: 4px 2px 0;
}

.chart-legend {
  display: flex;
  gap: 14px;
  font-size: 11px;
  color: var(--text-3);
  margin-bottom: 6px;
}

.chart-legend i {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 3px;
  margin-right: 5px;
}

.rank-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
}

.rank-no {
  width: 18px;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.rank-name {
  flex: 1;
  min-width: 0;
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rank-num {
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--text-2);
}

.rank-bar {
  width: 100%;
  height: 4px;
  border-radius: 2px;
  background: var(--line);
  margin-top: 5px;
  overflow: hidden;
}

.rank-bar i {
  display: block;
  height: 100%;
  border-radius: 2px;
  background: linear-gradient(90deg, #d4af37, #ffd966);
}

/* ---------------- 版本列表 ---------------- */
.toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.search {
  position: relative;
  flex: 1;
  min-width: 180px;
  max-width: 320px;
}

.search svg {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 15px;
  height: 15px;
  color: var(--text-3);
}

.search input {
  padding-left: 32px;
}

.toolbar select {
  width: auto;
  min-width: 104px;
}

.vlist {
  display: grid;
  gap: 8px;
}

.vrow {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1.6fr) auto;
  align-items: center;
  gap: 14px;
  padding: 13px 15px;
  border-radius: var(--r-md);
  background: var(--glass);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
  transition: border-color 0.18s, transform 0.18s;
}

.vrow:hover {
  border-color: rgba(212, 175, 55, 0.3);
}

.vrow.pinned {
  border-color: rgba(212, 175, 55, 0.4);
  background: linear-gradient(120deg, rgba(212, 175, 55, 0.07), var(--glass));
}

.vtitle {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}

.vtitle strong {
  font-size: 14.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.vmeta {
  margin-top: 3px;
  font-size: 11px;
  color: var(--text-3);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  font-variant-numeric: tabular-nums;
}

.vnote {
  font-size: 11.8px;
  color: var(--text-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.55;
}

.vacts {
  display: flex;
  align-items: center;
  gap: 6px;
  justify-content: flex-end;
}

/* 文件卡片 */
.file-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}

.file-card {
  padding: 12px;
  border-radius: var(--r-md);
  background: var(--glass);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.file-thumb {
  height: 96px;
  border-radius: 9px;
  background: var(--tint);
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--text-3);
}

.file-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.file-thumb svg {
  width: 30px;
  height: 30px;
  opacity: 0.5;
}

.file-name {
  font-size: 12px;
  font-weight: 600;
  word-break: break-all;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.file-meta {
  font-size: 10.5px;
  color: var(--text-3);
  display: flex;
  justify-content: space-between;
  gap: 6px;
}

/* 反馈 */
.fb-item {
  padding: 14px 15px;
  border-radius: var(--r-md);
  background: var(--glass);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
  margin-bottom: 8px;
}

.fb-top {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 7px;
}

.fb-time {
  font-size: 11px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.fb-body {
  font-size: 13px;
  color: var(--text);
  line-height: 1.7;
  white-space: pre-wrap;
  word-break: break-word;
}

.fb-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
  font-size: 11px;
  color: var(--text-3);
}

.fb-foot .spacer {
  flex: 1;
}

.fb-foot select {
  width: auto;
  height: 30px;
  font-size: 11.5px;
}

/* 标签页 */
.tabs {
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: 12px;
  background: var(--tint);
  margin-bottom: 14px;
  overflow-x: auto;
  scrollbar-width: none;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.tabs button {
  flex: none;
  height: 32px;
  padding: 0 14px;
  border-radius: 9px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-3);
  transition: all 0.18s;
}

.tabs button.active {
  color: var(--text);
  background: var(--glass-3);
  box-shadow: var(--shadow-sm);
}

/* 预览图管理 */
.shot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(128px, 1fr));
  gap: 10px;
}

.shot {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  background: #111;
  aspect-ratio: 9 / 16;
  border: 1px solid var(--stroke);
}

.shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shot-ov {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 6px;
  padding: 8px;
  background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.72));
  opacity: 0;
  transition: opacity 0.2s;
}

.shot:hover .shot-ov {
  opacity: 1;
}

.shot-ov .name {
  color: #fff;
  font-size: 10.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.shot-btns {
  display: flex;
  gap: 4px;
}

.shot-btns button {
  width: 24px;
  height: 24px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  display: grid;
  place-items: center;
  backdrop-filter: blur(6px);
}

.shot-btns button svg {
  width: 12px;
  height: 12px;
}

.shot-btns button:hover {
  background: rgba(255, 255, 255, 0.34);
}

.shot-add {
  border: 1.5px dashed var(--line);
  border-radius: 12px;
  background: var(--tint);
  aspect-ratio: 9 / 16;
  display: grid;
  place-items: center;
  color: var(--text-3);
  font-size: 11.5px;
  gap: 6px;
  transition: all 0.18s;
}

.shot-add:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.shot-add svg {
  width: 22px;
  height: 22px;
}

/* 简单列表（FAQ / 权限） */
.row-item {
  display: flex;
  gap: 12px;
  padding: 13px 14px;
  border-radius: var(--r-md);
  background: var(--glass);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
  margin-bottom: 8px;
  align-items: flex-start;
}

.row-item .grow {
  flex: 1;
  min-width: 0;
}

.row-item h4 {
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.row-item p {
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-3);
  line-height: 1.65;
  white-space: pre-wrap;
}

.row-acts {
  display: flex;
  gap: 4px;
  flex: none;
}

/* 占位/空态 */
.empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-3);
  font-size: 12.5px;
}

.empty svg {
  width: 34px;
  height: 34px;
  margin: 0 auto 10px;
  opacity: 0.3;
}

.skeleton-row {
  height: 62px;
  border-radius: var(--r-md);
  background: linear-gradient(90deg, var(--tint) 25%, rgba(212, 175, 55, 0.1) 37%, var(--tint) 63%);
  background-size: 400% 100%;
  animation: sk 1.3s ease infinite;
  margin-bottom: 8px;
}

@keyframes sk {
  0% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0 50%;
  }
}

/* ---------------- 弹窗 ---------------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-mask {
  position: absolute;
  inset: 0;
  background: rgba(12, 10, 28, 0.5);
  backdrop-filter: blur(5px);
  animation: fade 0.2s ease;
}

@keyframes fade {
  from {
    opacity: 0;
  }
}

.modal-box {
  position: relative;
  width: 100%;
  max-width: 640px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  border-radius: 20px;
  background: var(--glass-3);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(30px) saturate(180%);
  animation: pop 0.24s cubic-bezier(0.34, 1.3, 0.64, 1);
  overflow: hidden;
}

.modal-box.wide {
  max-width: 760px;
}

.modal-box.slim {
  max-width: 440px;
}

@keyframes pop {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
}

.modal-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px 18px;
  border-bottom: 1px solid var(--line);
  flex: none;
}

.modal-head h3 {
  font-size: 14.5px;
  font-weight: 700;
}

.modal-head .icon-btn {
  margin-left: auto;
}

.modal-body {
  padding: 16px 18px;
  overflow-y: auto;
}

.modal-foot {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px 18px;
  border-top: 1px solid var(--line);
  flex: none;
  background: var(--glass-2);
}

/* 上传区 */
.drop {
  border: 1.5px dashed var(--line);
  border-radius: var(--r-md);
  padding: 16px;
  text-align: center;
  background: var(--tint);
  transition: all 0.18s;
  cursor: pointer;
}

.drop:hover,
.drop.over {
  border-color: var(--primary);
  background: rgba(212, 175, 55, 0.09);
}

.drop svg {
  width: 24px;
  height: 24px;
  margin: 0 auto 6px;
  color: var(--primary);
  opacity: 0.85;
}

.drop strong {
  font-size: 12.5px;
  font-weight: 600;
  display: block;
}

.drop span {
  font-size: 11px;
  color: var(--text-3);
}

.up-file {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--r-md);
  background: rgba(16, 185, 129, 0.07);
  border: 1px solid rgba(16, 185, 129, 0.2);
  margin-top: 8px;
}

.up-file .nm {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  font-weight: 600;
  word-break: break-all;
}

.up-file .sz {
  font-size: 10.5px;
  color: var(--text-3);
}

.hash-mini {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 10px;
  color: var(--text-3);
  word-break: break-all;
  line-height: 1.5;
}

/* Toast */
.toast {
  position: fixed;
  left: 50%;
  bottom: 30px;
  transform: translate(-50%, 14px);
  z-index: 400;
  max-width: 80vw;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 12.5px;
  color: #fff;
  background: rgba(20, 18, 38, 0.94);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.3);
  opacity: 0;
  pointer-events: none;
  transition: all 0.26s;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.toast.err {
  background: rgba(180, 30, 45, 0.95);
}

/* 危险确认 */
.confirm-text {
  font-size: 13px;
  color: var(--text-2);
  line-height: 1.7;
}

.confirm-text b {
  color: var(--text);
}

/* ---------------- 响应式 ---------------- */
@media (max-width: 1080px) {
  .grid-dash {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-lg);
    background: var(--glass-3);
    width: 236px;
  }

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

  .drawer-mask {
    position: fixed;
    inset: 0;
    z-index: 85;
    background: rgba(10, 10, 20, 0.4);
    backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s;
  }

  body.drawer-open .drawer-mask {
    opacity: 1;
    visibility: visible;
  }

  .main {
    margin-left: 0;
  }

  .menu-btn {
    display: grid;
  }

  .topbar {
    padding: 8px 14px;
    min-height: 56px;
  }
  .top-actions {
    width: 100%;
    margin-left: 0;
  }

  .topbar h1 {
    font-size: 15px;
  }

  .view {
    padding: 14px 14px 80px;
  }

  .vrow {
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .vacts {
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .modal {
    padding: 0;
    align-items: flex-end;
  }

  .modal-box {
    max-width: 100%;
    max-height: 92vh;
    border-radius: 20px 20px 0 0;
  }

  .modal-body {
    padding: 14px;
  }

  .stat-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .file-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .shot-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 420px) {
  .shot-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .stat .v {
    font-size: 21px;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

/* ==========================================================================
   UI 统一：模板按钮 / 回复区 / 搜索框 / 表单控件
   ========================================================================== */

/* 快捷模板按钮条 */
.tpl-bar { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 8px; }

/* 表单顶部「填写指引」条 */
.form-guide {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 11px 13px;
  margin-bottom: 14px;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, .22);
  background: linear-gradient(135deg, rgba(212, 175, 55, .10), rgba(212, 175, 55, .07));
  font-size: 12px;
  line-height: 1.7;
  color: var(--text-2);
}
.form-guide svg { flex: none; width: 15px; height: 15px; color: var(--primary); margin-top: 3px; }
.form-guide b { color: var(--text); }
.form-guide ol { margin: 2px 0 0; padding-left: 18px; }
.form-guide li { margin: 1px 0; }
.form-guide .fg-demo { color: var(--text-3); }

.tpl-chip {
  height: 30px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--glass-2);
  color: var(--text-2);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: transform .18s cubic-bezier(.22,.9,.28,1), background .18s, color .18s, box-shadow .18s;
}
.tpl-chip:hover {
  transform: translateY(-1px);
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  color: #fff;
  border-color: transparent;
  box-shadow: 0 6px 16px rgba(212, 175, 55, .28);
}
.tpl-chip:active { transform: translateY(0); }
.tpl-chip-soft { background: var(--tint); }

/* 表单控件统一（任何弹窗内都一致） */
.form-grid .field input,
.form-grid .field select,
.form-grid .field textarea {
  width: 100%;
  min-height: 42px;
  padding: 10px 13px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--glass-3);
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  transition: border-color .2s, box-shadow .2s, background .2s;
}
.form-grid .field textarea { min-height: 92px; resize: vertical; line-height: 1.6; }
.form-grid .field input:focus,
.form-grid .field select:focus,
.form-grid .field textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, .13);
}
.form-grid .field .label {
  display: block;
  margin-bottom: 6px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-2);
}
.form-grid .field .hint { font-weight: 500; font-size: 11.5px; color: var(--text-3); margin-left: 4px; }

/* 搜索框统一 */
.search {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-width: 210px;
}
.search > svg {
  position: absolute;
  left: 12px;
  width: 15px; height: 15px;
  color: var(--text-3);
  pointer-events: none;
}
.search input {
  width: 100%;
  height: 40px;
  padding: 0 13px 0 34px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--glass-3);
  color: var(--text);
  font-size: 13.5px;
  transition: border-color .2s, box-shadow .2s;
}
.search input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, .13);
}

/* 反馈回复 */
.reply-quote {
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--glass-2);
  border: 1px solid var(--line-2);
  border-left: 3px solid var(--primary);
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--text-2);
  max-height: 160px;
  overflow: auto;
}

.fb-reply {
  margin-top: 10px;
  padding: 11px 13px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(16,185,129,.08), rgba(52,211,153,.05));
  border: 1px solid rgba(16,185,129,.22);
  font-size: 13px;
  line-height: 1.65;
  color: var(--text-2);
}
.fb-reply-tag {
  display: inline-block;
  margin-right: 7px;
  padding: 2px 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--green), #34d399);
  color: #fff;
  font-size: 10.5px;
  font-weight: 800;
  vertical-align: 1px;
}

/* 按钮尺寸统一 */
.btn-sm { height: 32px; padding: 0 11px; font-size: 12.5px; border-radius: 10px; }

/* 反馈卡片布局收紧：状态选择与操作按钮同行右对齐 */
.fb-top { flex-wrap: nowrap; }
.fb-top select {
  flex: none;
  width: 108px;
  height: 32px;
  padding: 0 9px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--glass-3);
  color: var(--text-2);
  font-size: 12.5px;
  font-family: inherit;
}
.fb-top select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(212,175,55,.13); }
.fb-top .btn-sm { flex: none; }

.fb-foot { flex-wrap: wrap; row-gap: 6px; }
.fb-foot > span { white-space: nowrap; }

@media (max-width: 720px) {
  .fb-top { flex-wrap: wrap; }
}

/* ==========================================================================
   浏览统计页：迷你数据格 / 趋势条 / 分布条 / 明细表（手机端与桌面端适配）
   ========================================================================== */
.mini-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
  margin-bottom: 14px;
}
.ms {
  padding: 11px 12px;
  border-radius: 12px;
  background: var(--glass-2);
  border: 1px solid var(--line-2);
  display: flex;
  flex-direction: column;
  gap: 3px;
  transition: transform .2s cubic-bezier(.22,.9,.28,1), box-shadow .2s;
}
.ms:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.ms b {
  font-size: 21px;
  font-weight: 800;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(135deg, var(--primary), var(--primary-2) 60%, var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.ms span { font-size: 11.5px; color: var(--text-3); font-weight: 600; }

.trend {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 74px;
  padding: 6px 4px;
  border-radius: 12px;
  background: var(--glass-2);
  border: 1px solid var(--line-2);
}
.trend-col {
  flex: 1;
  height: 100%;
  display: flex;
  align-items: flex-end;
  border-radius: 4px;
}
.trend-col i {
  display: block;
  width: 100%;
  min-height: 2px;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--primary-2), var(--primary));
  transition: height .5s cubic-bezier(.22,.9,.28,1);
}
.trend-col:hover i { background: linear-gradient(180deg, var(--pink), var(--primary-2)); }
.trend-foot {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 11px;
  color: var(--text-3);
}

.dist-title { font-size: 12px; font-weight: 800; color: var(--text-2); margin-bottom: 7px; }
.dist-row { display: flex; align-items: center; gap: 9px; margin-bottom: 7px; }
.dist-k {
  flex: none;
  width: 92px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.dist-bar {
  flex: 1;
  height: 8px;
  border-radius: 999px;
  background: var(--line-2);
  overflow: hidden;
}
.dist-bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--primary), var(--primary-2));
  transition: width .6s cubic-bezier(.22,.9,.28,1);
}
.dist-n { flex: none; width: 40px; text-align: right; font-size: 12px; font-weight: 700; color: var(--text-3); font-variant-numeric: tabular-nums; }

.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table-wrap .tbl { min-width: 720px; }
.tbl .nowrap { white-space: nowrap; }
.tbl .ref { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.pager { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.pager-txt { font-size: 12.5px; color: var(--text-3); font-weight: 600; }

.ua-box { max-height: 220px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; word-break: break-all; }

/* 手机端：统计格两列、表格横向滚动 */
@media (max-width: 900px) {
  .mini-stats { grid-template-columns: repeat(2, 1fr); }
  .ms b { font-size: 19px; }
}
@media (max-width: 560px) {
  .dist-k { width: 68px; font-size: 11.5px; }
  .trend { height: 58px; }
}

/* 浏览明细表：紧凑列宽，时间/运营商缩写后不再撑爆表格 */
.table-wrap .tbl.visit-tbl { min-width: 0; width: 100%; }
.table-wrap .tbl.visit-tbl th,
.table-wrap .tbl.visit-tbl td { padding: 8px 10px; vertical-align: middle; font-size: 12.5px; }
.table-wrap .tbl.visit-tbl td { white-space: nowrap; }
/* 时间列：上行完整年月日时分（看得准），下行小字相对时间（不用自己算） */
.table-wrap .tbl.visit-tbl td.v-time { white-space: nowrap; line-height: 1.35; }
.v-abs { display: block; font-variant-numeric: tabular-nums; }
.v-rel { display: block; font-size: 11px; color: var(--text-3); margin-top: 1px; }
.table-wrap .tbl.visit-tbl .cell-device { max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
.table-wrap .tbl.visit-tbl td.ref { max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-2); }

/* 手机端：表格整表变卡片列表，每行一张卡，字段名+值左右排布，一眼看全 */
@media (max-width: 720px) {
  .visit-tbl thead { display: none; }
  .table-wrap .tbl.visit-tbl,
  .table-wrap .tbl.visit-tbl tbody,
  .table-wrap .tbl.visit-tbl tr,
  .table-wrap .tbl.visit-tbl td { display: block; width: 100%; }
  .table-wrap .tbl.visit-tbl tr {
    background: var(--glass-2);
    border: 1px solid var(--line-2);
    border-radius: 12px;
    padding: 8px 12px;
    margin-bottom: 8px;
  }
  .table-wrap .tbl.visit-tbl td {
    border: none;
    padding: 3px 0;
    display: flex;
    align-items: baseline;
    gap: 10px;
    white-space: normal;
    text-align: right;
  }
  .table-wrap .tbl.visit-tbl td::before {
    content: attr(data-label);
    flex: none;
    width: 52px;
    text-align: left;
    font-size: 11.5px;
    color: var(--text-3);
  }
  .table-wrap .tbl.visit-tbl td[data-label='']::before,
  .table-wrap .tbl.visit-tbl td[data-label='操作']::before { display: none; }
  .table-wrap .tbl.visit-tbl td[data-label='操作'] { justify-content: flex-end; }
  .table-wrap .tbl.visit-tbl .cell-device { max-width: none; overflow: visible; }
  .table-wrap .tbl.visit-tbl td.ref { max-width: none; }
  .table-wrap .tbl.visit-tbl .v-time { color: var(--text); font-weight: 600; }
  /* 手机端时间两行：绝对时间与 label 同行，相对时间换行右对齐 */
  .table-wrap .tbl.visit-tbl td.v-time { flex-wrap: wrap; }
  .table-wrap .tbl.visit-tbl td.v-time .v-rel { flex-basis: 100%; text-align: right; }
}

/* 转化率卡片 / 顶部行内开关 */
.conv-box {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 9px;
  margin-bottom: 12px;
}
.conv-item {
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(16,185,129,.24);
  background: linear-gradient(135deg, rgba(16,185,129,.10), rgba(52,211,153,.05));
  display: flex;
  flex-direction: column;
  gap: 3px;
  transition: transform .2s cubic-bezier(.22,.9,.28,1), box-shadow .2s;
}
.conv-item:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.conv-item b {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  color: #059669;
}
.conv-item span { font-size: 11.5px; color: var(--text-3); font-weight: 600; }

.switch-inline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--glass-2);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-2);
  cursor: pointer;
  user-select: none;
}
.switch-inline input { display: none; }
.switch-inline i {
  width: 34px; height: 19px;
  border-radius: 999px;
  background: var(--line);
  position: relative;
  transition: background .22s;
  flex: none;
}
.switch-inline i::after {
  content: '';
  position: absolute;
  top: 2px; left: 2px;
  width: 15px; height: 15px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,.2);
  transition: transform .22s cubic-bezier(.22,.9,.28,1);
}
.switch-inline input:checked + i { background: linear-gradient(135deg, var(--primary), var(--primary-2)); }
.switch-inline input:checked + i::after { transform: translateX(15px); }

@media (max-width: 900px) {
  .conv-box { grid-template-columns: repeat(2, 1fr); }
  .conv-item b { font-size: 19px; }
}

/* 富文本编辑器 */
.rt-bar { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 7px; }
.rt-btn {
  min-width: 32px; height: 30px;
  padding: 0 9px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: var(--glass-3);
  color: var(--text-2);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: transform .16s, background .16s, color .16s;
}
.rt-btn:hover { transform: translateY(-1px); background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff; border-color: transparent; }

.rt-editor {
  min-height: 96px;
  max-height: 260px;
  overflow: auto;
  padding: 11px 13px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--glass-3);
  color: var(--text);
  font-size: 14px;
  line-height: 1.7;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.rt-editor:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(212,175,55,.13); }
.rt-editor:empty::before { content: attr(data-placeholder); color: var(--text-3); }
.rt-editor mark { background: linear-gradient(180deg, transparent 55%, rgba(245,158,11,.5) 0); padding: 0 2px; }
.rt-editor a { color: var(--primary); text-decoration: underline; }
.rt-editor ul { margin: 4px 0; padding-left: 20px; }

/* 转化率数字自适应：长数字自动缩小，单位小号 */
.conv-item b { font-size: clamp(17px, 2.2vw, 22px); word-break: break-all; }
.conv-item b i { font-style: normal; font-size: .62em; margin-left: 1px; }
.conv-item span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- 总后台：App 用户表 ---------- */
.utbl { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 12.8px; }
.utbl th {
  text-align: left; font-size: 11.5px; font-weight: 700; letter-spacing: .02em;
  color: var(--text-3); text-transform: uppercase; padding: 10px 12px;
  border-bottom: 1px solid var(--line-2); white-space: nowrap;
}
.utbl td { padding: 11px 12px; border-bottom: 1px solid var(--line-2); color: var(--text-2); }
.utbl tbody tr:last-child td { border-bottom: 0; }
.utbl tbody tr { transition: background .18s ease; }
.utbl tbody tr:hover { background: var(--glass-2); }
.utbl td b { color: var(--text); font-weight: 700; }
@media (max-width: 760px) {
  .utbl th:nth-child(5), .utbl td:nth-child(5),
  .utbl th:nth-child(6), .utbl td:nth-child(6) { display: none; }
}

.mini-stats.four { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .mini-stats.four { grid-template-columns: repeat(2, 1fr); } }
