:root {
  --bg: #f3f2f7;
  --card: #ffffff;
  --text: #16161c;
  --muted: #6d6d78;
  --line: #eceaf1;
  --accent: #5c54d4;
  --accent-soft: #eeeafb;
  --danger: #c53d3d;
  --ok: #2a8a57;
  --warn: #b76a16;
  --shadow: 0 10px 30px rgba(28, 24, 48, 0.05);
  --side: 232px;
}
* { box-sizing: border-box; }
html, body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: "SF Pro Text", "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  letter-spacing: -0.01em;
}
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button { cursor: pointer; }
.login {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 16px;
  background: linear-gradient(180deg, #f7f6fb 0%, #f3f2f7 100%);
}
.login-card {
  width: min(420px, 100%);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 36px 32px 32px;
  box-shadow: var(--shadow);
}
.mark {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 22px;
  background: linear-gradient(145deg, #8b83ea, #5c54d4);
}
.login-card h1 { margin: 18px 0 6px; font-size: 24px; font-weight: 680; letter-spacing: -0.03em; }
.login-card .sub { margin: 0 0 24px; color: var(--muted); font-size: 14px; line-height: 1.55; }
label { display: block; font-size: 13px; color: var(--muted); margin: 0 0 8px; }
.field { margin-bottom: 16px; }
input[type="text"], input[type="password"], input[type="search"], select {
  width: 100%;
  height: 44px;
  border: 1px solid #e4e2ea;
  border-radius: 12px;
  padding: 0 14px;
  background: #fff;
  color: var(--text);
  outline: none;
}
input:focus, select:focus { border-color: #b9b4e6; box-shadow: 0 0 0 4px rgba(92, 84, 212, 0.08); }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 16px;
  border: 0;
  border-radius: 11px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
}
.btn:disabled { opacity: .55; cursor: default; }
.btn-block { width: 100%; height: 46px; border-radius: 12px; font-size: 15px; }
.btn-ghost { background: #fff; color: var(--text); border: 1px solid #e4e2ea; }
.btn-danger { background: #fff; color: var(--danger); border: 1px solid #f0d3d3; }
.err { color: var(--danger); font-size: 13px; min-height: 20px; margin: 0 0 12px; }
.app { display: grid; grid-template-columns: var(--side) 1fr; min-height: 100vh; }
.side { background: #fff; border-right: 1px solid var(--line); padding: 22px 14px; position: sticky; top: 0; height: 100vh; }
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px 22px; }
.brand strong { display: block; font-size: 15px; font-weight: 680; }
.brand span { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.nav a {
  display: flex;
  align-items: center;
  height: 40px;
  padding: 0 12px;
  border-radius: 10px;
  color: #3c3c46;
  margin-bottom: 4px;
}
.nav a:hover { background: #f6f5fa; }
.nav a.active { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.main { padding: 28px 36px 48px; min-width: 0; }
.top { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.top h2 { margin: 0; font-size: 26px; font-weight: 680; letter-spacing: -0.03em; }
.top p { margin: 6px 0 0; color: var(--muted); font-size: 13px; }
.who { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; }
.cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
.cards.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stat, .card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); }
.stat { padding: 18px 18px 16px; }
.stat .k { color: var(--muted); font-size: 13px; }
.stat .v { margin-top: 10px; font-size: 28px; font-weight: 680; letter-spacing: -0.04em; }
.stat .s { margin-top: 8px; color: var(--muted); font-size: 13px; }
.card { padding: 18px; }
.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; flex-wrap: wrap; }
.toolbar .grow { flex: 1; min-width: 220px; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--line); font-size: 13px; vertical-align: middle; }
th { color: var(--muted); font-weight: 560; font-size: 12px; }
tr:hover td { background: #fafafc; }
.clickable { cursor: pointer; }
.mono { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }
.muted { color: var(--muted); }
.pill { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 12px; background: #f1f0f5; color: #555; }
.pill.ok { background: #e8f6ee; color: var(--ok); }
.pill.warn { background: #fff4e5; color: var(--warn); }
.pill.bad { background: #fdecec; color: var(--danger); }
.pill.staff { background: var(--accent-soft); color: var(--accent); }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; color: var(--muted); font-size: 13px; }
.av, img.av {
  width: 32px; height: 32px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-size: 13px; font-weight: 650; object-fit: cover; flex: 0 0 auto;
}
.person { display: flex; align-items: center; gap: 10px; min-width: 0; }
.person .nm { font-weight: 600; }
.person .hd { color: var(--muted); font-size: 12px; }
.grid2 { display: grid; grid-template-columns: 1.1fr .9fr; gap: 14px; }
.kv { display: grid; grid-template-columns: 92px 1fr; gap: 8px 12px; font-size: 14px; }
.kv b { color: var(--muted); font-weight: 500; }
.back { color: var(--muted); font-size: 13px; margin-bottom: 10px; display: inline-flex; }
.back:hover { color: var(--text); }
.toast {
  position: fixed; right: 22px; bottom: 22px; background: #1c1c22; color: #fff; padding: 12px 14px;
  border-radius: 12px; font-size: 13px; max-width: 360px; box-shadow: 0 10px 30px rgba(0,0,0,.18); display: none;
}
.empty { padding: 36px 12px; text-align: center; color: var(--muted); }
.handle-row { display: flex; gap: 10px; align-items: center; }
.handle-row input { max-width: 280px; }
.hint { color: var(--muted); font-size: 12px; line-height: 1.55; margin-top: 8px; }
h3 { margin: 0 0 14px; font-size: 16px; font-weight: 650; }
@media (max-width: 1100px) {
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid2 { grid-template-columns: 1fr; }
  .main { padding: 22px 18px 40px; }
}
@media (max-width: 820px) {
  .app { grid-template-columns: 1fr; }
  .side { position: relative; height: auto; border-right: 0; border-bottom: 1px solid var(--line); }
}

.stack { display: flex; flex-direction: column; gap: 8px; }
.stack label { margin: 4px 0 0; }
.cover-preview {
  height: 92px;
  border-radius: 12px;
  background-size: cover;
  background-position: center;
  background-color: #eceaf1;
}
