/* ============================================================
   管理后台样式
   ============================================================ */
.admin-shell { display: flex; min-height: 100vh; }

/* ---------- 登录页 ---------- */
.login-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-card { width: 100%; max-width: 400px; padding: 36px 34px; text-align: center; animation: rise .7s var(--ease) both; }
.login-card .brand { justify-content: center; margin-bottom: 8px; }
.login-title { font-size: 22px; font-weight: 800; margin: 14px 0 4px; }
.login-sub { font-size: 13px; color: var(--text-3); margin-bottom: 26px; }
.login-hint { margin-top: 18px; font-size: 12px; color: var(--text-3); line-height: 1.7; }

/* ---------- 侧边栏 ---------- */
.sidebar {
  position: fixed; top: 0; left: 0; bottom: 0; z-index: 40;
  width: 236px; padding: 20px 14px;
  display: flex; flex-direction: column; gap: 6px;
  background: rgba(8, 14, 28, .72);
  border-right: 1px solid var(--border);
  backdrop-filter: blur(24px) saturate(150%);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  transition: transform .35s var(--ease);
}
.sidebar .brand { padding: 6px 10px 20px; font-size: 16.5px; }
.nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 12px;
  font-size: 14.5px; font-weight: 500; color: var(--text-2);
  transition: all .28s var(--ease);
  position: relative; overflow: hidden;
}
.nav-item .ic { width: 20px; height: 20px; color: var(--text-3); transition: color .28s; }
.nav-item:hover { color: var(--text); background: var(--surface); }
.nav-item.active {
  color: #052433; font-weight: 700;
  background: var(--grad);
  box-shadow: 0 12px 30px -12px rgba(34, 211, 238, .65);
}
.nav-item.active .ic { color: #052433; }
.sidebar-foot { margin-top: auto; display: flex; flex-direction: column; gap: 4px; padding-top: 14px; border-top: 1px solid var(--border); }
.sidebar-foot .nav-item { font-size: 13.5px; }

/* ---------- 主区域 ---------- */
.main { flex: 1; margin-left: 236px; padding: 26px 30px 60px; min-width: 0; }
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 26px; gap: 16px; flex-wrap: wrap;
}
.topbar-title { font-size: 22px; font-weight: 800; letter-spacing: -.01em; }
.topbar-title small { display: block; font-size: 12.5px; font-weight: 500; color: var(--text-3); margin-top: 3px; }
.topbar-right { display: flex; align-items: center; gap: 12px; }

/* ---------- 统计卡 ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card {
  padding: 20px; border-radius: 18px; position: relative; overflow: hidden;
  background: linear-gradient(168deg, rgba(255,255,255,.07), rgba(255,255,255,.025));
  border: 1px solid var(--border);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  transition: transform .35s var(--ease), border-color .35s, box-shadow .35s;
}
.stat-card:hover { transform: translateY(-4px); border-color: var(--border-2); box-shadow: var(--glow); }
.stat-card::before {
  content: ''; position: absolute; top: -40px; right: -40px;
  width: 130px; height: 130px; border-radius: 50%;
  background: radial-gradient(circle, var(--sc, rgba(56,189,248,.25)), transparent 70%);
}
.stat-icon {
  width: 42px; height: 42px; border-radius: 13px; margin-bottom: 14px;
  display: flex; align-items: center; justify-content: center;
  background: var(--sg, var(--grad-soft)); color: var(--sc2, var(--sky));
  border: 1px solid var(--border);
}
.stat-label { font-size: 13px; color: var(--text-2); font-weight: 500; }
.stat-value { font-size: 27px; font-weight: 800; margin-top: 4px; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.stat-value small { font-size: 15px; margin-right: 2px; }

/* ---------- 面板 / 表格 ---------- */
.panel { border-radius: 18px; overflow: hidden; margin-bottom: 24px; }
.panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  padding: 18px 22px; border-bottom: 1px solid var(--border);
}
.panel-head[data-panel-toggle] { cursor: pointer; user-select: none; transition: background .2s; }
.panel-head[data-panel-toggle]:hover { background: rgba(255,255,255,.03); }
.panel-head .panel-arrow { display: flex; align-items: center; color: var(--text-3); transition: transform .28s ease; }
.panel-head.open .panel-arrow { transform: rotate(180deg); }
.panel-title { font-size: 15.5px; font-weight: 700; display: flex; align-items: center; gap: 10px; }
.panel-tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.panel-body { max-height: 0; overflow: hidden; opacity: 0; transition: max-height .32s ease, opacity .25s ease; }
.panel-body.open { max-height: 920px; opacity: 1; }
.table-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th {
  text-align: left; padding: 12px 18px; font-size: 12px; font-weight: 600;
  color: var(--text-3); letter-spacing: .05em; white-space: nowrap;
  border-bottom: 1px solid var(--border);
  background: rgba(255,255,255,.02);
}
.tbl td { padding: 13px 18px; border-bottom: 1px solid rgba(255,255,255,.05); vertical-align: middle; }
.tbl tbody tr { transition: background .25s; }
.tbl tbody tr:hover { background: rgba(255,255,255,.04); }
.tbl .mono { font-family: var(--mono); font-size: 12.5px; }
.tbl .row-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.tbl .num { font-variant-numeric: tabular-nums; }
.tbl tbody tr:last-child td { border-bottom: none; }

/* ---------- 分页 ---------- */
.pager { display: flex; align-items: center; justify-content: space-between; padding: 14px 22px; color: var(--text-3); font-size: 13px; flex-wrap: wrap; gap: 12px; }
.pager-btns { display: flex; gap: 8px; }

/* ---------- 状态筛选 ---------- */
.filter-pills { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- 后台弹窗复用 ---------- */
.modal-actions { display: flex; gap: 12px; margin-top: 8px; }

/* ---------- 后台表格里的封面 ---------- */
.cell-cover { width: 34px; height: 34px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; font-size: 18px; background: var(--surface); border: 1px solid var(--border); }

/* ---------- 空行 ---------- */
.tbl-empty td { text-align: center; padding: 44px; color: var(--text-3); }

/* ---------- 移动端侧栏 ---------- */
.menu-btn { display: none; }
@media (max-width: 900px) {
  .sidebar { transform: translateX(-100%); box-shadow: var(--shadow); }
  .sidebar.open { transform: translateX(0); }
  .main { margin-left: 0; padding: 20px 16px 50px; }
  .menu-btn { display: inline-flex; }
  .sidebar-backdrop { position: fixed; inset: 0; z-index: 35; background: rgba(3,7,16,.6); backdrop-filter: blur(4px); }
}
