/* 本地字体：Archivo（可变字重 500-900）+ IBM Plex Mono，
   取自 Google Fonts latin 子集，避免运行时依赖外部 CDN。中文回退系统字体。 */
@font-face {
  font-family: "Archivo";
  src: url("fonts/archivo-var-latin.woff2") format("woff2");
  font-weight: 500 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("fonts/ibm-plex-mono-400-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("fonts/ibm-plex-mono-500-latin.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("fonts/ibm-plex-mono-600-latin.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* ============================================================
   公会中心 · 纸感血红主题（参照 forevernight.kimi.site/position）
   基于 1.36.2 布局，只替换视觉层；组件精修见文件末尾。
   ============================================================ */
:root {
  /* 参考站设计令牌 */
  --paper: #fff0eb;
  --paper-2: #f6e3dc;
  --ink: #160000;
  --ink-2: #2a0808;
  --ink-panel: #2b2320;
  --red: #f40c3f;
  --red-dark: #b00529;
  --gold: #f2b544;
  --warn: #9a7b2d;
  --ok: #0e7a3d;
  --mute: #6f6159;
  --danger: #c8102e;
  --line: rgba(22, 0, 0, 0.18);
  --line-inv: rgba(255, 240, 235, 0.22);

  /* 兼容别名：原 CSS 大量 var(--xxx) 引用，保持名字不变，只换含义 */
  --bg: var(--paper);
  --bg-2: var(--paper-2);
  --panel: #ffffff;
  --panel-2: #ffffff;
  --panel-3: var(--paper-2);
  --line-2: var(--ink);
  --text: var(--ink);
  --text-2: var(--ink-panel);
  --muted: var(--mute);
  --muted-2: #9a857a;
  --gold: var(--red-dark);
  --gold-2: var(--red);
  --gold-dim: rgba(244, 12, 63, 0.08);
  --red-dim: rgba(200, 16, 46, 0.08);
  --green: var(--ok);
  --green-dim: rgba(14, 122, 61, 0.08);
  --blue: #1d5f8b;
  --blue-dim: rgba(29, 95, 139, 0.08);
  --amber: var(--warn);
  --radius: 0px;
  --radius-sm: 0px;
  --shadow: 0 1px 2px rgba(22, 0, 0, 0.08);
  --sans: "Archivo", -apple-system, "PingFang SC", "Microsoft YaHei", "Noto Sans TC", "Noto Sans KR", "Noto Sans Thai", sans-serif;
  --mono: "IBM Plex Mono", "Cascadia Code", Consolas, ui-monospace, monospace;
  --serif: var(--sans);
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.7;
  letter-spacing: 0.01em;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font-family: inherit; }
button { cursor: pointer; }
::selection { background: rgba(244, 12, 63, 0.28); }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #d9c9c4; border-radius: 0; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: #b9a29b; }

.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.gold { color: var(--gold); }
.red { color: var(--red); }
.green { color: var(--green); }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.center { text-align: center; }
.mono { font-family: var(--mono); font-size: 12px; }
.hidden { display: none !important; }

/* ---------------- 布局 ---------------- */
.app { min-height: 100vh; }

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 238px;
  display: flex;
  flex-direction: column;
  padding: 20px 14px 16px;
  background: var(--ink);
  border-right: 1px solid var(--line);
  z-index: 40;
  transition: transform 0.22s ease;
}

.brand { display: flex; align-items: center; gap: 11px; padding: 4px 8px 22px; }
.brand-mark { width: 34px; height: 38px; flex: none; filter: none; }
.brand-mark svg { width: 100%; height: 100%; display: block; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text b { font-size: 15.5px; letter-spacing: 0.02em; }
.brand-text small { margin-top: 4px; font-size: 9px; letter-spacing: 0.24em; color: var(--muted-2); }

.nav { display: flex; flex-direction: column; gap: 3px; }
.nav a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  height: 42px;
  padding: 0 12px;
  border-radius: 0;
  color: var(--text-2);
  font-size: 13.5px;
  transition: background 0.15s, color 0.15s;
}
.nav a .ico { width: 18px; height: 18px; color: var(--muted); display: inline-flex; }
.nav a .ico svg { width: 100%; height: 100%; }
.nav a:hover { background: rgba(22, 0, 0, 0.035); color: var(--text); }
.nav a.active {
  color: var(--gold-2);
  background: var(--ink-2);
}
.nav a.active::before {
  content: "";
  position: absolute;
  left: 0; top: 10px; bottom: 10px;
  width: 2px; border-radius: 0;
  background: var(--gold);
  box-shadow: none;
}
.nav a.active .ico { color: var(--gold); }
.nav-badge {
  margin-left: auto;
  min-width: 20px;
  height: 19px;
  padding: 0 6px;
  border-radius: 0;
  background: var(--red);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: none;
  align-items: center;
  justify-content: center;
}
.nav-badge.show { display: inline-flex; }
.nav-badge.soft { background: rgba(244, 12, 63, 0.16); color: var(--gold-2); }

.sidebar-foot { margin-top: auto; padding: 14px 10px 0; border-top: 1px solid var(--line); }
.conn { display: flex; align-items: center; gap: 7px; font-size: 11.5px; color: var(--muted); }
.conn .dot { width: 7px; height: 7px; border-radius: 0; background: var(--muted-2); box-shadow: none; }
.conn.ok .dot { background: var(--green); box-shadow: none; }
.conn.bad .dot { background: var(--red); box-shadow: none; }
.ver { margin-top: 6px; font-size: 10.5px; color: var(--muted-2); letter-spacing: 0.04em; }

.main { margin-left: 238px; min-height: 100vh; display: flex; flex-direction: column; min-width: 0; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 14px;
  height: 76px;
  padding: 0 30px;
  background: rgba(11, 13, 17, 0.78);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.menu-btn { display: none !important; }
.titles { min-width: 0; flex: 1; }
.titles h1 { margin: 0; font-size: 19px; font-weight: 620; letter-spacing: 0.01em; }
.titles p { margin: 3px 0 0; font-size: 12px; color: var(--muted); }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.guild-chip {
  display: flex; align-items: center; gap: 8px;
  height: 34px; padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: rgba(22, 0, 0, 0.02);
  font-size: 12.5px;
  color: var(--text-2);
  max-width: 240px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.guild-chip .crest { color: var(--gold); font-size: 10px; }
.avatar {
  width: 34px; height: 34px; border-radius: 0;
  border: 1px solid rgba(244, 12, 63, 0.35);
  background: var(--ink-2);
  color: var(--gold-2);
  font-size: 13px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

.view { width: 100%; max-width: 1560px; margin: 0 auto; padding: 26px 30px 70px; flex: 1; }

.admin-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  width: 100%;
  max-width: 1560px;
  margin: 0 auto;
  padding: 18px 30px 0;
}
.admin-tabs[hidden] { display: none; }
.admin-tabs .chip { flex: none; }
.setting-block[hidden] { display: none !important; }

/* ---------------- 通用组件 ---------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 34px;
  padding: 0 14px;
  border: 1px solid var(--line-2);
  border-radius: 0;
  background: #ffffff;
  color: var(--text);
  font-size: 13px;
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, transform 0.05s;
}
.btn .ico { width: 15px; height: 15px; display: inline-flex; }
.btn .ico svg { width: 100%; height: 100%; }
.btn:hover { background: var(--paper-2); border-color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn.gold {
  background: var(--red);
  border-color: var(--red);
  color: var(--paper);
  font-weight: 650;
  box-shadow: none;
}
.btn.gold:hover { filter: brightness(1.06); background: var(--red-dark); }
.btn.ghost { background: transparent; }
.btn.ghost:hover { background: rgba(22, 0, 0, 0.04); }
.btn.danger { color: var(--danger); border-color: rgba(200, 16, 46, 0.35); background: rgba(200, 16, 46, 0.08); }
.btn.danger:hover { background: rgba(200, 16, 46, 0.16); }
.btn.sm { height: 29px; padding: 0 10px; font-size: 12px; border-radius: 0; }
.btn.lg { height: 40px; padding: 0 20px; font-size: 13.5px; }
.btn.block { width: 100%; }
.icon-btn {
  width: 34px; height: 34px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line);
  border-radius: 0;
  background: rgba(22, 0, 0, 0.02);
  color: var(--muted);
}
.icon-btn:hover { color: var(--text); background: rgba(22, 0, 0, 0.05); }
.icon-btn svg { width: 18px; height: 18px; }

.card {
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 0;
  box-shadow: none;
  overflow: hidden;
  min-width: 0;
}
.card.pad { padding: 20px 22px; }
.card-head {
  display: flex; align-items: center; gap: 12px;
  padding: 17px 20px 14px;
  border-bottom: 1px solid rgba(22, 0, 0, 0.04);
}
.card-head h2 { margin: 0; font-size: 14px; font-weight: 620; letter-spacing: 0.01em; }
.card-head .hint { font-size: 11.5px; color: var(--muted); }
.card-head .spacer { flex: 1; }
.card-body { padding: 18px 20px; }
.card-foot { padding: 12px 20px; border-top: 1px solid rgba(22, 0, 0, 0.05); }

.grid { display: grid; gap: 16px; }
.grid > * { min-width: 0; }
.kpis > * { min-width: 0; }
.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cols-main { grid-template-columns: minmax(0, 1.9fr) minmax(0, 1fr); }
.cols-side { grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); }
.span-2 { grid-column: span 2; }

/* ---------------- KPI ---------------- */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 16px; }
.kpi {
  position: relative;
  display: flex; flex-direction: column; gap: 6px;
  padding: 18px 19px 16px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 0;
  overflow: hidden;
}
.kpi::after {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px;
  background: var(--red);
  opacity: 0.55;
}
.kpi .top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.kpi .label { font-size: 12.5px; color: var(--muted); letter-spacing: 0.02em; }
.kpi .kpi-ico {
  width: 30px; height: 30px; border-radius: 0;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--gold); background: var(--gold-dim);
}
.kpi .kpi-ico svg { width: 16px; height: 16px; }
.kpi .value { font-size: 30px; font-weight: 660; letter-spacing: -0.02em; line-height: 1.1; }
.kpi .value small { font-size: 13px; font-weight: 500; color: var(--muted); margin-left: 3px; }
.kpi .sub { font-size: 11.5px; color: var(--muted); display: flex; gap: 6px; align-items: center; }
.kpi .sub b { color: var(--text-2); font-weight: 600; }
.kpi.red .kpi-ico { color: var(--red); background: var(--red-dim); }
.kpi.green .kpi-ico { color: var(--green); background: var(--green-dim); }
.kpi.blue .kpi-ico { color: var(--blue); background: var(--blue-dim); }

/* ---------------- 表格 ---------------- */
.table-wrap { width: 100%; overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 13px; }
table.data th {
  padding: 10px 14px;
  text-align: left;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-2);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
  background: rgba(22, 0, 0, 0.012);
}
table.data td { padding: 11px 14px; border-bottom: 1px solid rgba(22, 0, 0, 0.035); vertical-align: middle; }
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr { transition: background 0.12s; }
table.data tbody tr:hover { background: rgba(22, 0, 0, 0.022); }
table.data tr.clickable { cursor: pointer; }
table.data .actions { display: flex; gap: 6px; justify-content: flex-end; }
.cell-main { font-weight: 560; }
.cell-sub { margin-top: 2px; font-size: 11.5px; color: var(--muted); }
.mono-cell { font-family: var(--mono); font-size: 11.5px; color: var(--muted); }

/* 官方装备图标（render.albiononline.com，经 /api/items/icon 本地缓存代理） */
.item-cell { display: flex; align-items: center; gap: 9px; min-width: 0; }
.item-cell > div { min-width: 0; }
.item-icon {
  width: 30px; height: 30px; flex: 0 0 30px;
  object-fit: contain;
  border-radius: 3px;
  background: rgba(22, 0, 0, 0.045);
  image-rendering: -webkit-optimize-contrast;
}
.items-table .item-icon { width: 26px; height: 26px; flex-basis: 26px; }
.item-icon.sm { width: 22px; height: 22px; flex-basis: 22px; border-radius: 2px; }
.icon-strip { display: flex; gap: 3px; margin-bottom: 3px; flex-wrap: wrap; }

/* 品质图标：官方渲染图自带品质边框，这里只补一圈淡外框 + 悬停反馈 */
.quality-strip { display: flex; gap: 4px; align-items: center; }
.quality-strip .q-icon {
  width: 32px; height: 32px; flex: 0 0 32px;
  object-fit: contain;
  padding: 1px;
  cursor: zoom-in;
  border-radius: 3px;
  border: 1px solid rgba(22, 0, 0, 0.14);
  background: rgba(255, 255, 255, 0.7);
  transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}
.quality-strip .q-icon:hover { transform: translateY(-2px) scale(1.1); box-shadow: 0 4px 10px rgba(22, 0, 0, 0.2); }
.quality-strip .q1 { border-color: rgba(154, 163, 173, 0.95); background: rgba(154, 163, 173, 0.12); }
.quality-strip .q2 { border-color: rgba(63, 191, 95, 0.95); background: rgba(63, 191, 95, 0.12); }
.quality-strip .q3 { border-color: rgba(59, 130, 246, 0.95); background: rgba(59, 130, 246, 0.12); }
.quality-strip .q4 { border-color: rgba(168, 85, 247, 0.95); background: rgba(168, 85, 247, 0.12); }
.quality-strip .q5 { border-color: rgba(232, 163, 61, 1); background: rgba(232, 163, 61, 0.14); }
/* 官方渲染偶发取不到时，先把空框藏起来，别留成灰块 */
.item-icon.broken, .quality-strip .q-icon.broken { visibility: hidden; background: transparent; border-color: transparent; }

/* 品质放大对照弹窗 */
.q-preview { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.q-card { margin: 0; background: var(--paper-2); border: 1px solid var(--line); border-top-width: 3px; }
.q-card img { display: block; width: 100%; height: auto; }
.q-card figcaption { display: flex; align-items: center; justify-content: space-between; gap: 4px; padding: 6px 8px; border-top: 1px solid var(--line); font-size: 11px; color: var(--mute); }
.q-card figcaption b { font-size: 12.5px; color: var(--ink); }
.q-card.q1 { border-top-color: #9aa3ad; }
.q-card.q2 { border-top-color: #3fbf5f; }
.q-card.q3 { border-top-color: #3b82f6; }
.q-card.q4 { border-top-color: #a855f7; }
.q-card.q5 { border-top-color: #e8a33d; }
.q-preview-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 12px; flex-wrap: wrap; }

@media (max-width: 760px) {
  .quality-strip .q-icon { width: 25px; height: 25px; flex-basis: 25px; }
  .q-preview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.pill {
  display: inline-flex; align-items: center; gap: 5px;
  height: 22px; padding: 0 9px;
  border-radius: 0;
  font-size: 11.5px;
  border: 1px solid transparent;
  white-space: nowrap;
}
.pill::before { content: ""; width: 5px; height: 5px; border-radius: 0; background: currentColor; }
.pill.pending { color: var(--warn); background: rgba(154, 123, 45, 0.09); border-color: rgba(154, 123, 45, 0.22); }
.pill.approved { color: #1d5f8b; background: rgba(29, 95, 139, 0.09); border-color: rgba(29, 95, 139, 0.22); }
.pill.paid { color: var(--ok); background: rgba(14, 122, 61, 0.09); border-color: rgba(14, 122, 61, 0.22); }
.pill.rejected { color: var(--danger); background: rgba(200, 16, 46, 0.09); border-color: rgba(200, 16, 46, 0.22); }
.pill.new { color: var(--mute); background: rgba(22, 0, 0, 0.04); border-color: rgba(22, 0, 0, 0.08); }
.pill.ignored { color: var(--muted); background: rgba(22, 0, 0, 0.025); border-color: rgba(22, 0, 0, 0.06); }
.pill.requested { color: #7a4f9e; background: rgba(122, 79, 158, 0.09); border-color: rgba(122, 79, 158, 0.22); }
.pill.over { color: var(--danger); background: rgba(200, 16, 46, 0.08); border-color: rgba(200, 16, 46, 0.25); }
.pill.commander { height: 16px; padding: 0 5px; font-size: 10px; color: var(--warn); background: rgba(154, 123, 45, 0.12); border-color: rgba(154, 123, 45, 0.3); }

.tag {
  display: inline-flex; align-items: center;
  height: 20px; padding: 0 7px;
  border-radius: 0;
  background: rgba(22, 0, 0, 0.04);
  border: 1px solid rgba(22, 0, 0, 0.05);
  font-size: 10.5px;
  color: var(--muted);
  white-space: nowrap;
}
.tag.gold { color: var(--gold); background: var(--gold-dim); border-color: rgba(244, 12, 63, 0.18); }
.tag.red { color: var(--danger); background: var(--red-dim); border-color: rgba(200, 16, 46, 0.2); }

/* ---------------- 工具条 / 过滤 ---------------- */
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 14px; }
.toolbar .spacer { flex: 1; }
.search {
  position: relative;
  width: 250px;
  max-width: 100%;
}
.search svg { position: absolute; left: 10px; top: 50%; width: 15px; height: 15px; transform: translateY(-50%); color: var(--muted-2); }
.search input { padding-left: 32px; height: 34px; }
.chips { display: flex; gap: 5px; padding: 3px; background: var(--paper-2); border: 1px solid var(--line); border-radius: 0; }
.chip {
  height: 28px; padding: 0 12px;
  border: 0; border-radius: 0;
  background: transparent; color: var(--muted);
  font-size: 12.5px;
}
.chip:hover { color: var(--text); }
.chip.active { background: var(--panel-3); color: var(--gold-2); box-shadow: none; }

/* ---------------- 输入 ---------------- */
input[type="text"], input[type="number"], input[type="search"], input[type="password"], select, textarea {
  width: 100%;
  height: 36px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #ffffff;
  color: var(--text);
  font-size: 13px;
  transition: border-color 0.15s, box-shadow 0.15s;
}
textarea { height: auto; min-height: 76px; padding: 9px 11px; resize: vertical; line-height: 1.55; }
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: rgba(244, 12, 63, 0.55);
  box-shadow: none;
}
input::placeholder, textarea::placeholder { color: #9a857a; }
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--mute) 50%), linear-gradient(135deg, var(--mute) 50%, transparent 50%); background-position: calc(100% - 15px) 15px, calc(100% - 10px) 15px; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 28px; }
option { background: #ffffff; color: var(--text); }

.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.form-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label { font-size: 11.5px; color: var(--muted); letter-spacing: 0.02em; }
.field .hint { font-size: 11px; color: var(--muted-2); line-height: 1.5; }
.field.full { grid-column: 1 / -1; }
.input-row { display: flex; gap: 8px; align-items: center; }
.input-row > * { min-width: 0; }
.map-row { display: flex; gap: 8px; align-items: center; margin: 14px 0 2px; }
.map-row input { flex: 1; }
.map-row .btn { flex: none; height: 36px; }
.suffix { position: relative; }
.suffix input { padding-right: 36px; }
.suffix span { position: absolute; right: 11px; top: 50%; transform: translateY(-50%); font-size: 11.5px; color: var(--muted-2); pointer-events: none; }

.switch { position: relative; display: inline-flex; width: 40px; height: 22px; flex: none; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 2; }
.switch i { position: absolute; inset: 0; background: #d9c9c4; border-radius: 0; transition: background 0.18s; }
.switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 0; background: var(--mute); transition: transform 0.18s, background 0.18s; }
.switch input:checked + i { background: rgba(244, 12, 63, 0.32); }
.switch input:checked + i::after { transform: translateX(18px); background: var(--gold-2); }
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 9px 0; border-bottom: 1px dashed rgba(22, 0, 0, 0.05); }
.switch-row:last-child { border-bottom: 0; }
.switch-row .t { font-size: 13px; }
.switch-row .d { margin-top: 2px; font-size: 11.5px; color: var(--muted); }

/* ---------------- 进度 ---------------- */
.progress { width: 100%; height: 6px; border-radius: 0; background: rgba(22, 0, 0, 0.06); overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: 0; background: var(--red); }
.progress.warn > i { background: var(--warn); }
.progress.over > i { background: var(--danger); }

/* ---------------- 空状态 / 加载 ---------------- */
.empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 54px 20px; color: var(--muted); text-align: center; }
.empty svg { width: 38px; height: 38px; opacity: 0.35; }
.empty b { color: var(--text-2); font-weight: 600; font-size: 13.5px; }
.empty span { font-size: 12px; max-width: 420px; line-height: 1.6; }
.loading { display: flex; align-items: center; gap: 10px; padding: 60px 10px; color: var(--muted); font-size: 13px; }
.spinner {
  width: 16px; height: 16px; border-radius: 0;
  border: 2px solid rgba(244, 12, 63, 0.25);
  border-top-color: var(--gold);
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------------- 图表 ---------------- */
.chart { width: 100%; height: 236px; display: block; overflow: visible; }
.chart .bar { fill: url(#goldBar); transition: filter 0.15s; }
.chart .bar:hover { filter: brightness(1.25); }
.chart .axis { stroke: rgba(22, 0, 0, 0.06); stroke-width: 1; }
.chart .lbl { fill: var(--mute); font-size: 10px; font-family: var(--sans); }
.chart .death-dot { fill: var(--red); opacity: 0.85; }
.chart .death-line { stroke: rgba(200, 16, 46, 0.35); stroke-width: 1; fill: none; }
.legend { display: flex; gap: 14px; font-size: 11.5px; color: var(--muted); }
.legend i { display: inline-block; width: 8px; height: 8px; border-radius: 0; margin-right: 5px; }

/* ---------------- 列表 ---------------- */
.list { display: flex; flex-direction: column; }
.list-item {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 20px;
  border-bottom: 1px solid rgba(22, 0, 0, 0.035);
}
.list-item:last-child { border-bottom: 0; }
.list-item:hover { background: rgba(22, 0, 0, 0.02); }
.list-item .avatar-sq {
  width: 34px; height: 34px; border-radius: 0; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: var(--panel-3);
  border: 1px solid rgba(22, 0, 0, 0.05);
  color: var(--gold-2);
  font-size: 12px; font-weight: 700;
}
.list-item .grow { flex: 1; min-width: 0; }
.list-item .t { font-size: 13px; font-weight: 560; display: flex; gap: 7px; align-items: center; }
.list-item .d { margin-top: 2px; font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-item .amt { font-size: 13px; font-weight: 650; color: var(--gold-2); white-space: nowrap; }

.rank-row { display: flex; align-items: center; gap: 11px; padding: 8px 0; }
.rank-row .idx { width: 20px; font-size: 11px; color: var(--muted-2); font-variant-numeric: tabular-nums; }
.rank-row .idx.top { color: var(--gold); }
.rank-row .nm { width: 92px; font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-row .barwrap { flex: 1; height: 6px; background: rgba(22, 0, 0, 0.05); border-radius: 0; overflow: hidden; }
.rank-row .barwrap i { display: block; height: 100%; background: var(--red); border-radius: 0; }
.rank-row .amt { width: 74px; text-align: right; font-size: 12px; color: var(--text-2); font-variant-numeric: tabular-nums; }

/* ---------------- 弹窗 ---------------- */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 80;
  display: flex; align-items: center; justify-content: center;
  padding: 22px;
  background: rgba(22, 0, 0, 0.72);
  backdrop-filter: blur(6px);
  animation: fade 0.16s ease;
}
.modal {
  width: min(760px, 100%);
  max-height: 90vh;
  display: flex; flex-direction: column;
  background: #ffffff;
  border: 1px solid var(--line-2);
  border-radius: 0;
  box-shadow: none;
  animation: pop 0.18s ease;
}
.modal.wide { width: min(1000px, 100%); }
.modal.xwide { width: min(1180px, 100%); }
.modal > header { display: flex; align-items: flex-start; gap: 12px; padding: 18px 22px 14px; border-bottom: 1px solid var(--line); }
.modal > header h3 { margin: 0; font-size: 16px; font-weight: 620; }
.modal > header p { margin: 3px 0 0; font-size: 12px; color: var(--muted); }
.modal > header .close { margin-left: auto; }
.modal .body { padding: 20px 22px; overflow: auto; }
.modal footer { display: flex; justify-content: flex-end; gap: 9px; padding: 14px 22px; border-top: 1px solid var(--line); background: rgba(22, 0, 0, 0.12); }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(0.985); } }

/* ---------------- Toast ---------------- */
.toast-root { position: fixed; right: 22px; bottom: 22px; z-index: 120; display: flex; flex-direction: column; gap: 9px; }
.toast {
  display: flex; align-items: center; gap: 10px;
  min-width: 240px; max-width: 400px;
  padding: 12px 15px;
  border-radius: 0;
  background: #ffffff;
  border: 1px solid var(--line-2);
  box-shadow: none;
  font-size: 13px;
  animation: slidein 0.2s ease;
}
.toast.ok { border-color: rgba(14, 122, 61, 0.35); }
.toast.err { border-color: rgba(200, 16, 46, 0.4); }
.toast .dot { width: 7px; height: 7px; border-radius: 0; background: var(--gold); flex: none; }
.toast.ok .dot { background: var(--green); }
.toast.err .dot { background: var(--red); }
@keyframes slidein { from { opacity: 0; transform: translateX(14px); } }

/* ---------------- 详情 ---------------- */
.detail-head {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--paper-2);
}
.detail-head .big { font-size: 22px; font-weight: 650; }
.detail-head .sub { font-size: 12px; color: var(--muted); margin-top: 3px; }
.detail-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 14px 0 4px; font-size: 12.5px; color: var(--muted); }
.detail-meta b { color: var(--text-2); font-weight: 560; }
.section-label { display: flex; align-items: center; gap: 8px; margin: 18px 0 9px; font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted-2); }
.section-label::after { content: ""; flex: 1; height: 1px; background: var(--line); }

.items-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.items-table th { padding: 7px 9px; color: var(--muted-2); font-weight: 500; font-size: 10.5px; text-align: left; border-bottom: 1px solid var(--line); }
.items-table td { padding: 8px 9px; border-bottom: 1px solid rgba(22, 0, 0, 0.035); }
.items-table tr.excluded td { color: var(--muted-2); }
.items-table tr.excluded .nm { text-decoration: line-through; text-decoration-color: rgba(22, 0, 0, 0.15); }
.items-table .nm { font-weight: 540; }
.items-table .ty { margin-top: 1px; font-size: 10.5px; color: var(--muted-2); font-family: var(--mono); }

.totals { margin-top: 14px; margin-left: auto; width: min(330px, 100%); display: flex; flex-direction: column; gap: 6px; }
.totals .row { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--muted); }
.totals .row b { color: var(--text-2); font-weight: 560; }
.totals .row.big { padding-top: 8px; margin-top: 2px; border-top: 1px solid var(--line); font-size: 14px; color: var(--text); }
.totals .row.big b { font-size: 20px; color: var(--gold-2); }

.timeline { display: flex; flex-direction: column; gap: 0; margin-top: 4px; }
.timeline .step { display: flex; gap: 12px; }
.timeline .rail { width: 14px; display: flex; flex-direction: column; align-items: center; }
.timeline .rail i { width: 8px; height: 8px; border-radius: 0; background: var(--panel-3); border: 1px solid var(--line-2); margin-top: 4px; }
.timeline .step.done .rail i { background: var(--gold); border-color: var(--gold); box-shadow: none; }
.timeline .rail::after { content: ""; width: 1px; flex: 1; background: var(--line); min-height: 18px; }
.timeline .step:last-child .rail::after { display: none; }
.timeline .txt { padding-bottom: 12px; font-size: 12.5px; }
.timeline .txt b { font-weight: 560; }
.timeline .txt span { display: block; margin-top: 2px; font-size: 11px; color: var(--muted); }

/* ---------------- 装备编辑器 ---------------- */
.gear-rows { display: flex; flex-direction: column; gap: 8px; }
.gear-row {
  display: grid;
  grid-template-columns: 72px minmax(0, 1.35fr) 58px 54px 66px 58px 150px 26px;
  gap: 7px;
  align-items: center;
}
.gear-row .slot { font-size: 11.5px; color: var(--muted); }
.gear-row select, .gear-row input { height: 32px; font-size: 12px; padding: 0 8px; }
.gear-row .unit { text-align: left; font-size: 11.5px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gear-row .unit .ok { color: var(--text); font-weight: 560; }
.g-clear {
  width: 24px; height: 24px; padding: 0; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid transparent; background: transparent;
  color: var(--muted-2); cursor: pointer;
}
.g-clear svg { width: 13px; height: 13px; }
.g-clear:hover { color: var(--danger); border-color: currentColor; }
.g-clear[data-empty="1"] { opacity: 0; pointer-events: none; }
/* 成员搜索框跟同一行其他输入框等高 */
#req-member { height: 42px; }
.gear-row.off { opacity: 0.55; }
.gear-row.off select { pointer-events: auto; }

/* ------------- 配装模板：官方装备栏布局 ------------- */
.gear-board { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; align-items: start; }
.gear-col { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.gear-col-head {
  display: flex; align-items: center; gap: 9px;
  font-size: 10.5px; letter-spacing: 0.14em; color: var(--mute);
}
.gear-col-head::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.gear-col-body { display: flex; flex-direction: column; gap: 7px; }
.gear-slot {
  display: flex; gap: 10px; align-items: stretch;
  padding: 7px 9px;
  border: 1px solid var(--line);
  background: #fff;
}
.gear-slot:hover, .gear-slot:focus-within { border-color: var(--ink); }
.gear-slot.has-item { border-color: var(--ink); }
.gear-slot .slot-face {
  width: 52px; flex: none;
  display: flex; align-items: center; justify-content: center;
  border: 1px dashed var(--line); background: rgba(22, 0, 0, 0.03);
}
.gear-slot.has-item .slot-face { border-style: solid; border-color: var(--ink); background: #fff; }
.slot-face .slot-ghost { font-size: 15px; font-weight: 600; color: var(--muted-2); }
.slot-face .slot-img { width: 44px; height: 44px; object-fit: contain; }
.slot-face .slot-img.broken { display: none; }
.gear-slot .slot-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.gear-slot .slot-head { display: flex; align-items: center; gap: 8px; min-height: 18px; }
.gear-slot .slot-name { flex: none; font-size: 11px; letter-spacing: 0.06em; color: var(--mute); }
.gear-slot .unit {
  flex: 1; min-width: 0; text-align: right;
  font-size: 10.5px; color: var(--muted-2);
  font-variant-numeric: tabular-nums;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.gear-slot.has-item .unit { color: var(--ink); font-weight: 560; }
.gear-slot select, .gear-slot input { height: 30px; font-size: 12px; padding: 0 7px; }
.gear-slot .g-base { width: 100%; }
.gear-slot .slot-foot { display: grid; grid-template-columns: 56px 48px minmax(0, 1fr) 64px; gap: 6px; }
.gear-slot .slot-count { position: relative; display: flex; align-items: center; }
.gear-slot .slot-count span { position: absolute; left: 7px; font-size: 11px; color: var(--mute); pointer-events: none; }
.gear-slot .slot-count input { width: 100%; padding-left: 18px; text-align: right; -moz-appearance: textfield; }
.gear-slot .slot-count input::-webkit-outer-spin-button,
.gear-slot .slot-count input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.gear-slot .g-clear { width: 20px; height: 20px; margin-left: auto; }
/* 官方自定义配装：下拉按官方分类分组（板甲/皮甲/剑/弓…） */
.gear-slot select optgroup { font-size: 11px; font-style: normal; color: var(--mute); }
.gear-slot select option { font-size: 12px; color: var(--ink); }
/* 双手武器占用副手：整格锁定 */
.gear-slot.slot-locked { opacity: 0.65; background: rgba(22, 0, 0, 0.02); }
.gear-slot.slot-locked .slot-face { border-style: dashed; }
.gear-slot.slot-locked .unit { color: var(--mute); }
.gear-slot.slot-locked .g-clear { visibility: hidden; }
@media (max-width: 900px) {
  .gear-board { grid-template-columns: 1fr; }
}
.quote-box {
  display: flex; align-items: center; gap: 18px;
  padding: 13px 16px;
  margin-top: 14px;
  border: 1px solid rgba(244, 12, 63, 0.22);
  border-radius: 0;
  background: var(--paper-2);
}
.quote-box .item { font-size: 11px; color: var(--muted); }
.quote-box .item b { display: block; margin-top: 2px; font-size: 15px; color: var(--text); font-weight: 620; }
.quote-box .item.total b { color: var(--gold-2); font-size: 21px; }
.quote-box .spacer { flex: 1; }

/* ---------------- 页头 / 设置 ---------------- */
.settings-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.settings-cards { column-count: 2; column-gap: 16px; }
.settings-cards > .card { width: 100%; margin: 0 0 16px; break-inside: avoid; display: inline-block; }
.setting-block { padding: 18px 20px; }
.setting-block h3 { margin: 0 0 4px; font-size: 13.5px; font-weight: 620; }
.setting-block .desc { margin: 0 0 16px; font-size: 11.5px; color: var(--muted); line-height: 1.6; }
.divider { height: 1px; background: var(--line); margin: 16px 0; }

.kv { display: flex; justify-content: space-between; gap: 14px; padding: 8px 0; border-bottom: 1px dashed rgba(22, 0, 0, 0.05); font-size: 12.5px; }
.kv:last-child { border-bottom: 0; }
.kv span { color: var(--muted); }
.kv b { font-weight: 560; text-align: right; word-break: break-all; }

.help { border: 1px solid var(--line); border-radius: 0; background: rgba(22, 0, 0, 0.14); padding: 12px 14px; font-size: 11.8px; line-height: 1.75; color: var(--muted); }
.help code { color: var(--gold-2); font-family: var(--mono); font-size: 11px; background: rgba(22, 0, 0, 0.04); padding: 1px 5px; border-radius: 0; }
.help b { color: var(--text-2); }

.pager { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 18px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-delay: 0s !important;
    transition-duration: 0.001ms !important;
  }
}

/* ---------------- 响应式 ---------------- */
@media (max-width: 1280px) {
  .cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cols-main, .cols-side { grid-template-columns: minmax(0, 1fr); }
  .settings-grid { grid-template-columns: minmax(0, 1fr); }
  .settings-cards { column-count: 1; }
}
@media (max-width: 1024px) {
  .sidebar { transform: translateX(-100%); }
  .app.nav-open .sidebar { transform: none; box-shadow: none; }
  .main { margin-left: 0; }
  .menu-btn { display: inline-flex !important; }
  .topbar { padding: 0 18px; }
  .view { padding: 22px 18px 64px; }
}
@media (max-width: 860px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cols-2, .cols-3 { grid-template-columns: minmax(0, 1fr); }
  .guild-chip { display: none; }
  .titles p { display: none; }
  .form-grid, .form-grid.three { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 620px) {
  .kpis { grid-template-columns: minmax(0, 1fr); }
  .topbar { height: 66px; gap: 8px; padding: 0 12px; }
  .topbar-right { gap: 6px; }
  .topbar-right .btn.sm { padding: 0 9px; }
  .btn-label { display: none; }
  .view { padding: 16px 12px 60px; }
  .gear-row { grid-template-columns: 46px minmax(0, 1fr) 40px 40px 50px 40px 22px; gap: 5px; }
  .gear-row select, .gear-row input { font-size: 11px; padding: 0 5px; }
  .gear-row .unit { display: none; }
  .g-clear { width: 22px; height: 22px; }
  .search { width: 100%; }
  .toast-root { left: 12px; right: 12px; bottom: 12px; }
}

/* ============================================================
   登录页 / 账号
   ============================================================ */

.auth-screen {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  overflow: auto;
  background: var(--paper);
}

.auth-card {
  width: 100%;
  max-width: 400px;
  padding: 30px 30px 22px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 0;
  box-shadow: none;
}

.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.auth-mark { width: 40px; height: 44px; display: block; flex: none; }
.auth-mark svg { width: 100%; height: 100%; display: block; }
.auth-brand b { display: block; font-size: 14.5px; letter-spacing: 0.02em; }
.auth-brand small { display: block; font-size: 9px; letter-spacing: 0.22em; color: var(--muted-2); margin-top: 2px; }
.auth-card h2 { margin: 0 0 6px; font-size: 19px; font-weight: 640; letter-spacing: 0.01em; }
.auth-sub { margin: 0 0 20px; font-size: 12.5px; line-height: 1.6; color: var(--muted); }
.auth-card .field { margin-bottom: 14px; }
.auth-card .field input { height: 38px; }
.auth-error { min-height: 18px; margin: 2px 0 10px; font-size: 12px; color: var(--danger); }
.auth-foot { margin-top: 18px; text-align: center; font-size: 11px; color: var(--muted-2); }

.acct-row {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--panel-2);
}
.acct-avatar {
  width: 38px;
  height: 38px;
  flex: none;
  border-radius: 0;
  display: grid;
  place-items: center;
  font-weight: 650;
  color: var(--paper);
  background: var(--ink);
}
.acct-row .t { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; }
.acct-row .d { margin-top: 3px; font-size: 11.5px; color: var(--muted); }
.grow { flex: 1; min-width: 0; }
.tag.green { color: var(--ok); background: var(--green-dim); border-color: rgba(14, 122, 61, 0.22); }

@media (max-width: 520px) {
  .auth-card { padding: 24px 20px 18px; }
}

/* ---------------- 定位规则页 ---------------- */
.help-card {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  padding: 14px 16px;
  margin-bottom: 16px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--paper-2);
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--text-2);
}
.help-card b { color: var(--gold); }

.role-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 1100px) { .role-grid { grid-template-columns: 1fr; } }

.role-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.role-card-head b { font-size: 14px; }
.role-card .form-grid { margin-top: 12px; }

.slot-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: 0;
  font-size: 12px;
  color: var(--text-2);
  cursor: pointer;
  user-select: none;
}
.chip:hover { border-color: var(--line-2); background: rgba(22, 0, 0, 0.03); }
.chip input { width: 13px; height: 13px; margin: 0; accent-color: var(--gold); }
.chip:has(input:checked) { border-color: rgba(244, 12, 63, 0.45); background: var(--gold-dim); color: var(--gold-2); }

.check-row { display: flex; align-items: center; gap: 8px; margin: 6px 0 14px; font-size: 12.5px; color: var(--text-2); cursor: pointer; }
.check-row input { width: 15px; height: 15px; margin: 0; accent-color: var(--gold); }

.weapon-map { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 1100px) { .weapon-map { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .weapon-map { grid-template-columns: 1fr; } }
.wm-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--panel-2);
}
.wm-row span { font-size: 12px; color: var(--text-2); white-space: nowrap; }
.wm-row select { height: 30px; padding: 0 8px; font-size: 12px; }

/* 定位规则 · 附魔矩阵与武器细分 */
.ench-matrix {
  display: grid;
  grid-template-columns: 44px repeat(5, 1fr);
  gap: 6px;
  align-items: center;
  max-width: 380px;
  margin-top: 6px;
}
.em-head { text-align: center; font-size: 11px; color: var(--muted); }
.em-tier { font-size: 12px; font-weight: 600; color: var(--text-2); }
.em-cell { display: grid; place-items: center; padding: 3px 0; cursor: pointer; }
.em-cell input { width: 15px; height: 15px; margin: 0; accent-color: var(--gold); }

.weapon-groups { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 900px) { .weapon-groups { grid-template-columns: 1fr; } }
.wg-row { border: 1px solid var(--line); border-radius: 0; background: var(--panel-2); overflow: hidden; }
.wg-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px; }
.wg-head span { font-size: 12.5px; color: var(--text-2); }
.wg-head em { font-style: normal; font-size: 11px; color: var(--muted-2); margin-left: 4px; }
.wg-head select { height: 28px; padding: 0 6px; font-size: 12px; }
.wg-details { border-top: 1px solid var(--line); }
.wg-details summary { padding: 7px 10px; font-size: 11.5px; color: var(--muted); cursor: pointer; list-style: none; }
.wg-details summary::-webkit-details-marker { display: none; }
.wg-details summary::before { content: "▸ "; }
.wg-details[open] summary::before { content: "▾ "; }
.wg-list { max-height: 260px; overflow: auto; padding: 4px 10px 10px; display: grid; gap: 6px; }
.wg-item { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.wg-item span { font-size: 12px; color: var(--text-2); }
.wg-item select { height: 26px; width: 132px; padding: 0 6px; font-size: 11.5px; }

/* 我的数据 · 概览数字 */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; }
@media (max-width: 900px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.stat {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--panel-2);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.stat span { font-size: 11.5px; color: var(--muted); }
.stat b { font-size: 18px; font-weight: 650; color: var(--gold-2); font-variant-numeric: tabular-nums; }

/* 成员搜索下拉 */
.pick-list {
  max-height: 190px;
  overflow: auto;
  margin-top: 6px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--panel-2);
}
.needs-picker { position: relative; width: 260px; max-width: 100%; }
.needs-picker .pick-list {
  position: absolute;
  z-index: 40;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  margin-top: 0;
  background: var(--panel-2);
  box-shadow: none;
}
.pick-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 12px;
  font-size: 13px;
  cursor: pointer;
  border-bottom: 1px solid rgba(22, 0, 0, 0.04);
}
.pick-item:last-child { border-bottom: 0; }
.pick-item:hover { background: rgba(244, 12, 63, 0.1); }
.pick-item .muted { font-size: 11px; }
.pick-empty { padding: 10px 12px; font-size: 12px; color: var(--muted); }
.pick-clear { color: var(--red); justify-content: flex-start; }


/* ============================================================
   纸感血红 · 组件精修层（v1.36.2-p1）
   保留上方全部布局/响应式规则，这里只覆盖视觉表现。
   ============================================================ */
html { font-size: 16.5px; }
@media (min-width: 1024px) { html { font-size: 18px; } }
h1, h2, h3, .titles h1, .card-head h2, .modal > header h3,
.auth-card h2, .setting-block h3, .kpi .value { letter-spacing: -0.02em; }
::selection { background: var(--ink); color: var(--paper); }
:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
::-webkit-scrollbar-thumb { background: #d9c9c4; border: 0; border-radius: 0; }
::-webkit-scrollbar-thumb:hover { background: #b9a29b; }
.num, .mono, .mono-cell, .kpi .value, .stat b, .rank-row .idx, .rank-row .amt,
.gear-row .unit, .detail-head .big, .totals .row.big b, .quote-box .item b,
.items-table .ty, .help code, .ver, .brand-text small, .auth-brand small,
.list-item .amt, .guild-chip { font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* 深墨红框架：侧栏 + 顶栏 */
.sidebar { background: var(--ink); border-right: 1px solid var(--line-inv); padding: 18px 0 12px; }
.brand { padding: 4px 16px 20px; }
.brand-mark { filter: none; }
.brand-text b { color: var(--paper); font-size: 15.5px; font-weight: 800; letter-spacing: -0.01em; }
.brand-text small { color: var(--paper); opacity: 0.55; font-size: 10px; letter-spacing: 0.22em; }
.nav { gap: 0; padding: 0 8px; }
.nav a { height: 44px; padding: 0 14px; border-radius: 0; border-bottom: 1px solid var(--line-inv); color: var(--paper); opacity: 0.78; font-size: 13.5px; font-weight: 600; }
.nav a .ico { color: var(--paper); opacity: 0.6; }
.nav a:hover { background: var(--ink-2); color: var(--paper); opacity: 1; }
.nav a.active { background: var(--ink-2); color: var(--paper); opacity: 1; }
.nav a.active::before { left: 0; top: 0; bottom: 0; width: 3px; border-radius: 0; background: var(--red); box-shadow: none; }
.nav a.active .ico { color: var(--red); }
.nav-badge { border-radius: 0; background: var(--red); color: var(--paper); font-family: var(--mono); font-weight: 600; }
.nav-badge.soft { background: var(--ink-2); color: var(--paper); }
.sidebar-foot { margin: auto 8px 0; padding: 12px 8px 0; border-top: 1px solid var(--line-inv); }
.conn { color: var(--paper); opacity: 0.7; }
.conn .dot { border-radius: 50%; background: var(--paper); opacity: 0.5; box-shadow: none; }
.conn.ok .dot { background: #5fd0a0; opacity: 1; box-shadow: none; }
.conn.bad .dot { background: var(--red); opacity: 1; box-shadow: none; }
.ver { color: var(--paper); opacity: 0.55; letter-spacing: 0.04em; }

.topbar { height: 72px; background: var(--ink); border-bottom: 1px solid var(--line-inv); backdrop-filter: none; }
.titles h1 { color: var(--paper); font-size: 21px; font-weight: 800; }
.titles p { color: var(--paper); opacity: 0.6; font-size: 12px; }
.guild-chip { border-radius: 0; border: 1px solid var(--line-inv); background: transparent; color: var(--paper); font-size: 12px; }
.guild-chip .crest { color: var(--red); }
.avatar { border-radius: 0; border: 1px solid var(--red); background: var(--red); color: var(--paper); font-family: var(--mono); }
.icon-btn { border-radius: 0; background: #ffffff; border-color: var(--line); color: var(--ink); }
.icon-btn:hover { background: var(--paper-2); color: var(--ink); }
.menu-btn { background: transparent; border-color: var(--line-inv); color: var(--paper); }
.menu-btn:hover { background: var(--ink-2); color: var(--paper); }
.view { padding: 28px 30px 80px; }

/* 按钮：直角、大写、字距 */
.btn { height: 40px; padding: 0 16px; border: 1px solid var(--ink); border-radius: 0; background: #ffffff; color: var(--ink); font-size: 12.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.btn:hover { background: var(--paper-2); border-color: var(--ink); }
.btn.gold { background: var(--red); border-color: var(--red); color: var(--paper); }
.btn.gold:hover { background: var(--red-dark); border-color: var(--red-dark); filter: none; }
.btn.ghost { background: #ffffff; color: var(--ink); }
.btn.ghost:hover { background: var(--paper-2); }
.btn.danger { color: var(--danger); border-color: var(--danger); background: #ffffff; }
.btn.danger:hover { background: rgba(200, 16, 46, 0.07); }
.btn.sm { height: 34px; padding: 0 12px; font-size: 11.5px; }
.btn.lg { height: 44px; padding: 0 22px; }
.topbar .btn.ghost { background: transparent; border-color: var(--line-inv); color: var(--paper); }
.topbar .btn.ghost:hover { background: var(--ink-2); }

/* 卡片 / KPI：白纸 + 墨红硬边 */
.card { background: #ffffff; border: 1px solid var(--ink); border-radius: 0; box-shadow: none; }
.card.pad { padding: 20px 22px; }
.card-head { padding: 14px 18px 12px; border-bottom: 1px solid var(--ink); }
.card-head h2 { font-size: 13px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; }
.card-head .hint { color: var(--mute); }
.card-body { padding: 18px; }
.card-foot { border-top: 1px solid var(--line); }
.kpi { background: #ffffff; border: 1px solid var(--ink); border-radius: 0; padding: 16px 18px; }
.kpi::after { height: 3px; background: var(--red); opacity: 1; top: 0; }
.kpi .label { color: var(--mute); font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.kpi .kpi-ico { border-radius: 0; color: var(--red); background: rgba(244, 12, 63, 0.08); }
.kpi .value { font-size: 31px; font-weight: 800; font-family: var(--mono); color: var(--ink); }
.kpi .value small { font-family: var(--sans); }
.kpi .sub b { color: var(--ink); }

/* 表格：大写小字距表头 + 墨红下边线 */
table.data { font-size: 13.5px; }
table.data th { padding: 10px 14px; font-size: 10.5px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; color: var(--mute); border-bottom: 1px solid var(--ink); background: var(--paper); }
table.data td { padding: 11px 14px; border-bottom: 1px solid var(--line); }
table.data tbody tr:hover { background: var(--paper-2); }
.cell-sub { color: var(--mute); }
.mono-cell { color: var(--mute); }

/* 标签：1px currentColor 边框、无底色、直角 */
.pill { height: 24px; padding: 0 8px; border-radius: 0; border: 1px solid currentColor; font-size: 11px; font-weight: 700; letter-spacing: 0.04em; }
.pill::before { border-radius: 0; width: 5px; height: 5px; }
.pill.pending, .pill.approved, .pill.paid, .pill.rejected, .pill.new,
.pill.ignored, .pill.requested, .pill.over, .pill.commander { background: transparent; border-color: currentColor; }
.pill.pending, .pill.commander { color: var(--warn); }
.pill.approved { color: #1d5f8b; }
.pill.paid { color: var(--ok); }
.pill.rejected, .pill.over { color: var(--danger); }
.pill.new, .pill.ignored { color: var(--mute); }
.pill.requested { color: #7a4f9e; }
.tag { border-radius: 0; background: transparent; border: 1px solid currentColor; color: var(--mute); font-size: 10.5px; font-weight: 700; }
.tag.gold { color: var(--red-dark); background: transparent; border-color: currentColor; }
.tag.red { color: var(--danger); background: transparent; border-color: currentColor; }
.tag.green { color: var(--ok); background: transparent; border-color: currentColor; }

/* 工具条 / 筛选 chip */
.toolbar { gap: 10px; margin-bottom: 16px; }
.chips { background: #ffffff; border: 1px solid var(--ink); border-radius: 0; padding: 0; }
.chip { border-radius: 0; border: 1px solid var(--ink); background: #ffffff; color: var(--ink); font-size: 12px; font-weight: 700; letter-spacing: 0.04em; }
.chip:hover { background: var(--paper-2); color: var(--ink); border-color: var(--ink); }
.chip.active { background: var(--ink); color: var(--paper); box-shadow: none; }
.chip:has(input:checked) { border-color: var(--red); background: rgba(244, 12, 63, 0.08); color: var(--red-dark); }
.chip input { accent-color: var(--red); }
.slot-chips .chip { min-height: 34px; padding: 5px 12px; }

/* 输入 */
input[type="text"], input[type="number"], input[type="search"], input[type="password"], select, textarea {
  height: 42px; border: 1px solid var(--ink); border-radius: 0; background: #ffffff;
  color: var(--ink); font-size: 13.5px;
}
input:focus, select:focus, textarea:focus { border-color: var(--red); box-shadow: 0 0 0 2px rgba(244, 12, 63, 0.35); }
input::placeholder, textarea::placeholder { color: var(--mute); opacity: 0.7; }
select { background-position: calc(100% - 15px) 19px, calc(100% - 10px) 19px; }
option { background: #ffffff; color: var(--ink); }
.field > label { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mute); }
.field .hint { color: var(--mute); }
.search input { height: 42px; }
.gear-row select, .gear-row input { border-radius: 0; height: 34px; }
.suffix span { color: var(--mute); }
textarea { line-height: 1.7; }

/* 开关 / 进度 */
.switch i { border-radius: 0; background: #d9c9c4; }
.switch i::after { border-radius: 0; background: #ffffff; border: 1px solid var(--ink); }
.switch input:checked + i { background: var(--red); }
.switch input:checked + i::after { background: #ffffff; }
.switch-row { border-bottom: 1px solid var(--line); }
.switch-row .d { color: var(--mute); }
.progress { border-radius: 0; height: 6px; background: var(--paper-2); }
.progress > i { border-radius: 0; }
.progress.warn > i { background: var(--warn); }
.progress.over > i { background: var(--danger); }
.rank-row .barwrap { border-radius: 0; background: var(--paper-2); }
.rank-row .barwrap i { border-radius: 0; }
.rank-row .idx.top { color: var(--red); }
.check-row input, .em-cell input { accent-color: var(--red); }

/* 图表 / 空状态 / 加载 */
.chart .axis { stroke: var(--line); }
.chart .lbl { fill: var(--mute); font-family: var(--mono); font-size: 10px; }
.chart .death-dot { fill: var(--danger); }
.chart .death-line { stroke: rgba(200, 16, 46, 0.45); }
.legend { color: var(--mute); }
.legend i { border-radius: 0; }
.spinner { border: 2px solid rgba(244, 12, 63, 0.2); border-top-color: var(--red); }
.empty b { color: var(--ink); }
.loading { color: var(--mute); }

/* 列表 */
.list-item { border-bottom: 1px solid var(--line); }
.list-item:hover { background: var(--paper-2); }
.list-item .avatar-sq { border-radius: 0; background: var(--ink); border: 1px solid var(--ink); color: var(--paper); font-family: var(--mono); }
.list-item .amt { color: var(--red-dark); }
.list-item .d { color: var(--mute); }

/* 弹窗 / Toast */
.modal-backdrop { background: rgba(22, 0, 0, 0.72); backdrop-filter: none; }
.modal { background: #ffffff; border: 1px solid var(--ink); border-radius: 0; box-shadow: none; }
.modal > header { border-bottom: 1px solid var(--ink); }
.modal > header h3 { font-size: 17px; font-weight: 800; }
.modal > header p { color: var(--mute); }
.modal footer { border-top: 1px solid var(--ink); background: var(--paper-2); }
.toast { background: #ffffff; border: 1px solid var(--ink); border-radius: 0; box-shadow: 0 1px 2px rgba(22, 0, 0, 0.08); }
.toast.ok { border-color: var(--ok); }
.toast.err { border-color: var(--danger); }
.toast .dot { background: var(--red); }
.toast.ok .dot { background: var(--ok); }
.toast.err .dot { background: var(--danger); }

/* 详情 / 装备编辑器 / 设置 */
.detail-head { border-radius: 0; border: 1px solid var(--ink); background: var(--paper-2); }
.detail-meta { color: var(--mute); }
.detail-meta b { color: var(--ink); }
.section-label { color: var(--mute); font-weight: 800; letter-spacing: 0.1em; }
.section-label::after { background: var(--ink); }
.items-table th { color: var(--mute); font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; border-bottom: 1px solid var(--ink); }
.items-table td { border-bottom: 1px solid var(--line); }
.items-table tr.excluded td { color: var(--mute); }
.totals .row.big { border-top: 1px solid var(--ink); }
.totals .row.big b { color: var(--red-dark); }
.timeline .rail i { border-radius: 0; }
.timeline .step.done .rail i { background: var(--red); border-color: var(--red); box-shadow: none; }
.timeline .txt span { color: var(--mute); }
.quote-box { border-radius: 0; border: 1px solid var(--ink); background: var(--paper-2); }
.quote-box .item b { font-weight: 800; }
.quote-box .item.total b { color: var(--red-dark); }
.setting-block h3 { font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; }
.setting-block .desc { color: var(--mute); }
.divider { background: var(--line); }
.kv { border-bottom: 1px solid var(--line); color: var(--ink); }
.kv span { color: var(--mute); }
.help { border-radius: 0; border: 1px solid var(--line); background: var(--paper-2); color: var(--ink); }
.help code { font-family: var(--mono); background: #ffffff; border-radius: 0; color: var(--red-dark); }
.help b { color: var(--ink); }
.pager { border-top: 1px solid var(--ink); color: var(--mute); }

/* 登录 / 账号 */
.auth-card { background: #ffffff; border: 1px solid var(--ink); border-radius: 0; box-shadow: none; padding: 32px 30px 24px; }
.auth-brand b { font-size: 15px; font-weight: 800; }
.auth-brand small { color: var(--mute); letter-spacing: 0.22em; }
.auth-mark { filter: none; }
.auth-card h2 { font-size: 22px; font-weight: 800; }
.auth-sub { color: var(--mute); line-height: 1.7; }
.auth-card .field input { height: 42px; }
.auth-error { color: var(--danger); }
.auth-foot { color: var(--mute); }
.acct-row { border-radius: 0; border: 1px solid var(--ink); background: #ffffff; }
.acct-avatar { border-radius: 0; background: var(--ink); color: var(--paper); }
.acct-row .d { color: var(--mute); }

/* 定位规则页 / 我的数据 */
.help-card { border-radius: 0; border: 1px solid var(--ink); background: var(--paper-2); color: var(--ink); }
.help-card b { color: var(--red-dark); }
.wm-row, .wg-row { border-radius: 0; border: 1px solid var(--ink); background: #ffffff; }
.wm-row span, .wg-head span { color: var(--ink); }
.wg-head em, .wg-details summary { color: var(--mute); }
.wg-details { border-top: 1px solid var(--line); }
.wg-item span { color: var(--ink); }
.stat { border-radius: 0; border: 1px solid var(--ink); background: #ffffff; }
.stat span { color: var(--mute); }
.stat b { color: var(--red-dark); }
.em-head, .em-tier { color: var(--mute); }
.pick-list { border-radius: 0; border: 1px solid var(--ink); background: #ffffff; box-shadow: 0 1px 2px rgba(22, 0, 0, 0.08); }
.needs-picker .pick-list { box-shadow: 0 1px 2px rgba(22, 0, 0, 0.08); }
.pick-item { border-bottom: 1px solid var(--line); }
.pick-item:hover { background: var(--paper-2); }
.pick-clear { color: var(--danger); }
.pick-empty { color: var(--mute); }

/* 响应式补充 */
@media (max-width: 1024px) {
  .app.nav-open .sidebar { box-shadow: 2px 0 0 var(--ink); }
}

/* 战报网（第三方站点）外链 */
.tag-link { color: var(--gold); border-color: rgba(244, 12, 63, 0.18); cursor: pointer; }
.tag-link:hover { background: var(--gold-dim); }

/* 待发放：成员卡片可折叠（收起后只留一行汇总，避免整页太长） */
.dispatch-head { cursor: pointer; user-select: none; }
.dispatch-head:hover { background: rgba(22, 0, 0, 0.025); }
.dispatch-head:focus-visible { outline: 2px solid var(--red); outline-offset: -2px; }
.dispatch-caret {
  display: inline-flex; align-items: center; justify-content: center;
  width: 16px; height: 16px; flex: 0 0 16px;
  color: var(--muted);
  transition: transform 0.16s ease;
}
.dispatch-caret svg { width: 15px; height: 15px; }
.dispatch-card.is-collapsed .dispatch-caret { transform: rotate(-90deg); }
.dispatch-card.is-collapsed .dispatch-body { display: none; }
.dispatch-card.is-collapsed .card-head { border-bottom: 0; }
/* 表头里的「合并已发放」按钮：不参与压缩，窄屏换行也不挤掉汇总文字 */
.dispatch-head { flex-wrap: wrap; row-gap: 8px; }
.dispatch-head > .btn { flex: 0 0 auto; }
.dispatch-head > .btn:disabled { opacity: 0.6; cursor: progress; }
/* 待发放按「区」分类：一区一段，段头写清人数/单数/件数，右侧可整区收起 */
.zone-chips { margin: 0 2px 14px; }
.zone-block { margin-bottom: 20px; }
.zone-block:last-child { margin-bottom: 0; }
.zone-head {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin-bottom: 10px; padding: 0 2px 8px; border-bottom: 1px solid var(--line);
}
.zone-head h3 { font-size: 13px; font-weight: 700; letter-spacing: 0.04em; }
.zone-head .hint { font-size: 11.5px; }
.zone-head .hint b { color: var(--ink); font-weight: 650; }
.zone-head > .btn { flex: 0 0 auto; }

/* 成员名后面的「区 / 号」徽标：等宽数字，跟名字同一行，窄屏可换行 */
.zone-tag {
  flex: 0 0 auto; align-self: center;
  height: 22px; font-family: var(--mono); font-size: 11.5px;
  color: var(--ink-2); background: rgba(22, 0, 0, 0.05);
  border-color: rgba(22, 0, 0, 0.1); font-variant-numeric: tabular-nums;
}

/* 配装模板库：卡片网格，两张并排在宽屏、窄屏自动落成一列 */
.loadout-grid {
  display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fill, minmax(430px, 1fr));
}
.loadout-card { display: flex; flex-direction: column; }
.loadout-head { flex-wrap: wrap; row-gap: 6px; }
.loadout-head h2 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 60%; }
.loadout-items {
  display: grid; gap: 2px 18px; padding: 12px 20px 6px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 520px) { .loadout-items { grid-template-columns: 1fr; } }
.loadout-item { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 3px 0; }
/* 图标按钮：点开就是这件装备的 5 种品质，角标标出模板里存的品质 */
.loadout-item .lo-icon {
  position: relative; flex: 0 0 40px; width: 40px; height: 40px;
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0; border: 1px solid transparent; background: transparent; cursor: zoom-in;
}
.loadout-item .lo-icon:hover { border-color: var(--line-2); }
.loadout-item .lo-icon .item-icon { width: 36px; height: 36px; flex: 0 0 36px; object-fit: contain; }
.loadout-item .lo-icon .q-badge {
  position: absolute; right: -1px; bottom: -1px;
  min-width: 13px; height: 13px; padding: 0 3px;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--mono); font-size: 9px; font-style: normal; line-height: 1;
  color: var(--ink); background: var(--paper-2); border: 1px solid var(--line-2);
}
.loadout-item .lo-icon .q-badge.q2 { border-color: rgba(63, 191, 95, 0.95); }
.loadout-item .lo-icon .q-badge.q3 { border-color: rgba(59, 130, 246, 0.95); }
.loadout-item .lo-icon .q-badge.q4 { border-color: rgba(168, 85, 247, 0.95); }
.loadout-item .lo-icon .q-badge.q5 { border-color: rgba(232, 163, 61, 1); }
.loadout-item .item-icon { width: 30px; height: 30px; flex: 0 0 30px; }
.loadout-item .cell-main {
  font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.loadout-item .lo-count {
  font-family: var(--mono); font-size: 12px; color: var(--ink-2);
  font-variant-numeric: tabular-nums;
}
.loadout-note {
  padding: 2px 20px 10px; font-size: 12px; color: var(--muted); line-height: 1.6;
}
.loadout-foot {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  margin-top: auto; padding: 10px 20px 12px; border-top: 1px solid var(--line);
}
.loadout-foot .btn { flex: 0 0 auto; }

/* 筛选标签上的数量（待审核 / 已驳回 / 已发放…）：小一号、等宽数字，选中时更亮 */
.chip-num { font-size: 11px; font-variant-numeric: tabular-nums; opacity: 0.62; }
.chip.active .chip-num { opacity: 0.92; }

/* ---------------- 补装单里的配装模板 ---------------- */
.req-lo-bar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin: 0 0 10px; padding: 7px 10px;
  border: 1px dashed var(--line); background: rgba(255, 255, 255, 0.62);
}
.req-lo-bar[hidden] { display: none; }
.req-lo-label {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; letter-spacing: 0.08em; color: var(--muted);
}
.req-lo-label svg { width: 13px; height: 13px; }
.req-lo-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.req-lo-chips .chip { display: inline-flex; align-items: center; gap: 6px; }
.req-lo-chips .chip b {
  font-family: var(--mono); font-size: 10px; font-weight: 500; color: var(--muted-2);
}
.req-lo-chips .chip.armed { color: var(--danger); border-color: var(--danger); background: var(--red-dim); }
.req-lo-chips .chip.armed::after { content: "再点确认"; font-size: 10px; }
.req-lo-panel {
  margin-bottom: 12px; padding: 10px;
  border: 1px solid var(--line); background: #ffffff;
}
.req-lo-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(268px, 1fr));
  gap: 8px; max-height: 258px; overflow: auto;
}
.req-lo-card {
  display: flex; flex-direction: column; gap: 6px;
  padding: 8px 10px; border: 1px solid var(--line); background: #ffffff; cursor: pointer;
}
.req-lo-card:hover { border-color: var(--red); background: rgba(244, 12, 63, 0.03); }
.req-lo-head { display: flex; align-items: center; gap: 6px; min-width: 0; }
.req-lo-name {
  font-weight: 600; font-size: 13px; min-width: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.req-lo-stat { margin-left: auto; flex: none; font-size: 10.5px; color: var(--muted-2); white-space: nowrap; }
.req-lo-items { display: flex; flex-direction: column; gap: 2px; margin-bottom: 2px; }
.req-lo-item { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: 11.5px; color: var(--muted); }
.req-lo-tier { flex: none; font-family: var(--mono); font-size: 10px; color: var(--muted-2); }
.req-lo-nm { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.req-lo-ct { flex: none; font-family: var(--mono); font-size: 10px; }
.req-lo-more { font-size: 10.5px; color: var(--muted-2); }
.req-lo-foot { display: flex; align-items: center; gap: 8px; margin-top: auto; }
.req-lo-foot .hint {
  flex: 1; min-width: 0; font-size: 10.5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.req-lo-foot .btn.armed { color: var(--danger); border-color: var(--danger); }

@media (max-width: 720px) {
  .req-lo-grid { grid-template-columns: 1fr; max-height: 220px; }
}
