/* ribbon · 申请人端与共用基础样式
   色板与字体按 docs/API-CONTRACT.md §7；管理端只引用，不修改。 */

:root {
  --ink: #08121f;
  --panel: #0e1f33;
  --panel-2: #132a44;
  --line: #1f3350;
  --sky: #2f86c4;
  --sky-2: #5fb3e8;
  --gold: #c8a45c;
  --paper: #f5f7fa;
  --text: #e9eff6;
  --muted: #93a7bd;

  --paper-ink: #142231;
  --paper-muted: #5f6f80;
  --paper-line: #d8dfe8;
  --paper-tint: #eef2f7;

  --font-serif: "Noto Serif SC", "Songti SC", "STSong", serif;
  --font-sans: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  --font-symbol: "Segoe UI Symbol", "Noto Sans Symbols 2", "DejaVu Sans", system-ui, sans-serif;

  --radius: 8px;
  --shadow: 0 18px 38px rgba(0, 0, 0, .32);
  --ease: 150ms ease;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background-color: var(--ink);
  background-image:
    repeating-linear-gradient(90deg, rgba(255, 255, 255, .012) 0 1px, transparent 1px 3px),
    radial-gradient(1100px 480px at 50% -12%, rgba(47, 134, 196, .18), transparent 62%),
    radial-gradient(820px 420px at 100% 0%, rgba(200, 164, 92, .07), transparent 65%);
  background-attachment: fixed;
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; }
img { border: 0; }
a { color: inherit; }
button, input, textarea, select { font: inherit; }
::selection { background: rgba(47, 134, 196, .38); }

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

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  padding: 8px 14px; border-radius: 0 0 4px 0;
  background: var(--paper); color: var(--paper-ink); text-decoration: none;
}
.skip-link:focus { left: 0; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.noscript-note {
  max-width: 680px; margin: 40px auto; padding: 16px;
  border: 1px solid var(--gold); color: var(--text); text-align: center;
}

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 14px max(28px, calc((100% - 1440px) / 2 + 28px));
  background: rgba(8, 18, 31, .93);
  border-bottom: 1px solid rgba(200, 164, 92, .34);
  box-shadow: 0 10px 28px rgba(0, 0, 0, .26);
  backdrop-filter: blur(9px);
}
.brand { display: flex; align-items: center; gap: 14px; min-width: 0; }
.crest {
  width: 52px; height: 53px; flex: none; object-fit: contain;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .5));
}
.brand-copy { min-width: 0; }
.brand-org {
  margin: 0 0 2px;
  font-size: 10px; letter-spacing: .22em; color: var(--muted);
  white-space: nowrap;
}
.brand-title {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 21px; font-weight: 600; line-height: 1.25;
  letter-spacing: .14em; color: #f2e6c8;
  white-space: nowrap;
}
.topbar-side { display: flex; align-items: center; gap: 12px; min-width: 0; }

.who { display: flex; align-items: center; gap: 14px; min-width: 0; }
.who-copy { min-width: 0; text-align: right; }
.who-name {
  display: flex; align-items: baseline; justify-content: flex-end; gap: 8px;
  margin: 0; font-family: var(--font-serif); font-size: 14px; font-weight: 600;
  letter-spacing: .08em; color: #f0e3c6;
}
.who-name .who-rank { font-family: var(--font-sans); font-size: 11.5px; font-weight: 400; color: var(--muted); }
.who-meta {
  margin: 2px 0 0; max-width: 460px;
  font-size: 11px; color: var(--muted); letter-spacing: .02em;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.who-divider { width: 1px; height: 26px; flex: none; background: linear-gradient(180deg, transparent, rgba(200, 164, 92, .55), transparent); }

/* ---------- 主体 ---------- */
.shell {
  width: 100%; max-width: 1440px; margin: 0 auto;
  padding: 26px 28px 44px;
}
.site-foot {
  width: 100%; max-width: 1440px; margin: 0 auto;
  padding: 14px 28px 26px;
  display: flex; justify-content: space-between; gap: 16px;
  border-top: 1px solid rgba(31, 51, 80, .75);
  font-size: 11px; letter-spacing: .14em; color: #72869c;
}

/* ---------- 身份选择 ---------- */
body.view-login .crest { display: none; }
.login {
  display: grid;
  grid-template-columns: minmax(240px, .62fr) minmax(0, 1.38fr);
  gap: clamp(34px, 4vw, 62px); align-items: center;
  min-height: calc(100vh - 236px);
  padding: 24px 0 32px;
}
.login-lead {
  display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between;
  gap: 26px; min-height: 432px; padding: 22px 0 18px 6px;
}
.login-crest {
  width: clamp(122px, 12vw, 164px); height: auto; object-fit: contain;
  filter: drop-shadow(0 14px 28px rgba(0, 0, 0, .55));
}
.login-lead-copy { position: relative; padding-left: 18px; }
.login-lead-copy::before {
  content: ""; position: absolute; left: 0; top: 4px; bottom: 4px; width: 1px;
  background: linear-gradient(180deg, rgba(200, 164, 92, .9), rgba(200, 164, 92, .08));
}
.login-title {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(28px, 2.8vw, 36px); font-weight: 600;
  letter-spacing: .2em; color: #f1e5c8;
}
.login-sub { margin: 8px 0 0; font-size: 12px; letter-spacing: .16em; color: var(--muted); }
.login-stat {
  align-self: stretch; margin: 0; padding-top: 15px;
  border-top: 1px solid rgba(200, 164, 92, .22);
  font-size: 11px; letter-spacing: .1em; color: var(--muted);
}

.id-panel { width: 100%; max-width: 1000px; margin: 0 auto; min-width: 0; }
.id-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; align-items: stretch; }
.id-card {
  position: relative; isolation: isolate;
  display: flex; flex-direction: column; gap: 7px;
  min-height: 196px; padding: 17px 17px 15px;
  background: var(--paper); color: var(--paper-ink);
  border: 1px solid rgba(200, 164, 92, .5); border-radius: var(--radius);
  box-shadow: 0 14px 30px rgba(0, 0, 0, .3);
  text-align: left; cursor: pointer;
  transition: border-color var(--ease), box-shadow var(--ease), transform var(--ease);
}
.id-card::before {
  content: ""; position: absolute; inset: 0 0 auto; height: 2px;
  background: linear-gradient(90deg, transparent, rgba(200, 164, 92, .85), transparent);
}
.id-card:hover { transform: translateY(-2px); border-color: var(--gold); box-shadow: 0 20px 36px rgba(0, 0, 0, .38); }
.id-card[aria-busy="true"] { opacity: .6; pointer-events: none; }
.id-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.id-order { font-family: var(--font-serif); font-size: 12px; letter-spacing: .18em; color: #9a7d42; }
.id-cat {
  padding: 2px 7px; border: 1px solid #d5dde7; border-radius: 3px;
  font-size: 10px; letter-spacing: .08em; color: #52667b; white-space: nowrap;
}
.id-name { margin: 7px 0 0; font-family: var(--font-serif); font-size: 22px; font-weight: 600; letter-spacing: .12em; color: #16273a; }
.id-role { margin: 0; font-size: 12.5px; color: #34485e; }
.id-unit { margin: 0; font-size: 11.5px; line-height: 1.5; color: #6a7b8c; }
.id-foot {
  margin-top: auto; padding-top: 10px; border-top: 1px solid #e1e7ee;
  display: flex; align-items: baseline; justify-content: space-between; gap: 8px;
}
.id-years { font-size: 11px; color: #62758a; letter-spacing: .04em; }
.id-enter { font-size: 11.5px; color: #1f6d9e; letter-spacing: .06em; white-space: nowrap; }
.id-card:hover .id-enter { color: #0f4d73; }

.admin-entry {
  margin-top: 14px; padding: 13px 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  border: 1px solid var(--line); border-radius: 6px;
  background: linear-gradient(90deg, rgba(47, 134, 196, .14), rgba(19, 42, 68, .5) 55%, rgba(19, 42, 68, .2));
  text-decoration: none;
  transition: border-color var(--ease), background var(--ease);
}
.admin-entry:hover { border-color: rgba(95, 179, 232, .55); background: linear-gradient(90deg, rgba(47, 134, 196, .22), rgba(19, 42, 68, .55)); }
.admin-entry-main { display: flex; align-items: baseline; gap: 14px; min-width: 0; flex-wrap: wrap; }
.admin-entry-title { font-family: var(--font-serif); font-size: 14px; letter-spacing: .1em; color: var(--text); }
.admin-entry-sub { font-size: 11px; letter-spacing: .06em; color: var(--muted); }
.admin-entry-arrow { font-size: 17px; color: var(--sky-2); }

/* ---------- 工作台 ---------- */
.board {
  display: grid;
  grid-template-columns: minmax(0, 1.03fr) minmax(0, 1fr) minmax(0, 1.12fr);
  gap: 18px; align-items: start;
}
.col { display: flex; flex-direction: column; gap: 18px; min-width: 0; }

.panel {
  position: relative; overflow: hidden;
  padding: 18px;
  background: linear-gradient(180deg, rgba(19, 42, 68, .55), rgba(14, 31, 51, .94));
  border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(200, 164, 92, .16), var(--shadow);
}
.panel::before {
  content: ""; position: absolute; inset: 0 0 auto; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(200, 164, 92, .6), transparent);
  opacity: .75; pointer-events: none;
}
.panel-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 12px; margin-bottom: 13px;
}
.panel-head-main { min-width: 0; }
.panel-title {
  margin: 0;
  font-family: var(--font-serif); font-size: 17px; font-weight: 600;
  letter-spacing: .1em; color: #eef2f7;
}
.panel-meta { margin: 3px 0 0; font-size: 11px; letter-spacing: .06em; color: var(--muted); }
.panel-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.count-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 26px; height: 21px; padding: 0 8px;
  border: 1px solid rgba(200, 164, 92, .42); border-radius: 11px;
  font-size: 11px; color: var(--gold); letter-spacing: .04em;
  background: rgba(200, 164, 92, .07); white-space: nowrap;
}

/* 浅色纸卡（表单区） */
.paper, .panel--paper {
  background: var(--paper); color: var(--paper-ink);
  border: 1px solid #e2e7ee; border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 18px 34px rgba(0, 0, 0, .3);
}
.panel--paper::before { background: linear-gradient(90deg, transparent, rgba(200, 164, 92, .85), transparent); opacity: 1; }
.panel--paper .panel-title { color: #18293b; }
.panel--paper .panel-meta { color: var(--paper-muted); }
.paper a { color: #1f6d9e; }

/* ---------- 按钮 ---------- */
.btn {
  appearance: none; -webkit-appearance: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 14px;
  border: 1px solid var(--line); border-radius: 5px;
  background: var(--panel-2); color: var(--text);
  font-family: var(--font-sans); font-size: 12.5px; line-height: 1.2;
  letter-spacing: .02em; white-space: nowrap; text-decoration: none;
  cursor: pointer;
  transition: background var(--ease), border-color var(--ease), color var(--ease);
}
.btn:hover { background: #183654; border-color: rgba(95, 179, 232, .55); }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .42; cursor: not-allowed; }
.btn:disabled:hover { background: var(--panel-2); border-color: var(--line); }
.btn-primary { background: var(--sky); border-color: var(--sky); color: #fff; }
.btn-primary:hover { background: #3a97d8; border-color: #3a97d8; }
.btn-primary:disabled:hover { background: var(--sky); border-color: var(--sky); }
.btn-gold { background: transparent; border-color: rgba(200, 164, 92, .55); color: var(--gold); }
.btn-gold:hover { background: rgba(200, 164, 92, .12); border-color: var(--gold); }
.btn-ghost { background: transparent; }
.btn-sm { padding: 5px 9px; font-size: 11.5px; }
.btn-block { width: 100%; }
.btn-link { border: 0; background: none; padding: 2px 0; color: var(--sky-2); text-decoration: underline; text-underline-offset: 3px; }
.panel--paper .btn { background: #fff; border-color: #c9d4e0; color: #1c2d40; }
.panel--paper .btn:hover { background: #edf2f8; border-color: #9fb3c8; }
.panel--paper .btn-primary { background: var(--sky); border-color: var(--sky); color: #fff; }
.panel--paper .btn-primary:hover { background: #3a97d8; border-color: #3a97d8; }

/* ---------- 状态与标签 ---------- */
.chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 7px;
  border: 1px solid var(--line); border-radius: 3px;
  background: rgba(19, 42, 68, .65);
  font-size: 10.5px; line-height: 1.35; letter-spacing: .04em;
  color: var(--muted); white-space: nowrap;
}
.chip--gold { border-color: rgba(200, 164, 92, .45); color: var(--gold); background: rgba(200, 164, 92, .07); }
.chip--sky { border-color: rgba(95, 179, 232, .4); color: var(--sky-2); background: rgba(47, 134, 196, .1); }
.chip--paper { border-color: #ccd6e2; color: #4e6278; background: #edf1f6; }
.chip--ok { border-color: rgba(112, 190, 148, .45); color: #9fd6b6; background: rgba(54, 124, 88, .16); }
.chip--pending { border-color: rgba(200, 164, 92, .5); color: #dcc38d; background: rgba(200, 164, 92, .1); }
.chip--bad { border-color: rgba(199, 104, 83, .5); color: #e7a797; background: rgba(156, 65, 48, .16); }
.chip--draft { border-color: var(--line); color: var(--muted); }

.form-status {
  margin: 8px 0 0; min-height: 0;
  font-size: 11.5px; line-height: 1.5; color: #a5422a;
}
.form-status:empty { display: none; }
.form-status.is-ok { color: #2b6b4a; }
.form-status--dark { color: #eab3a4; }
.form-status--dark.is-ok { color: #a8dcc0; }
.form-status[data-kind="ok"] { color: #2b6b4a; }
.form-status--dark[data-kind="ok"] { color: #a8dcc0; }

.empty {
  margin: 0; padding: 22px 10px;
  text-align: center; font-size: 12px; letter-spacing: .08em; color: var(--muted);
}
.empty--paper { color: var(--paper-muted); }
.empty strong { display: block; margin-bottom: 3px; color: #c7d5e5; font-weight: 500; }
.empty--paper strong { color: #33475c; }

/* ---------- 勋表托架 ---------- */
.rack-stage {
  padding: 9px;
  border: 1px solid rgba(200, 164, 92, .22); border-radius: 6px;
  background: radial-gradient(130% 110% at 50% 0%, #0b1c2f, #040b14 78%);
  box-shadow: inset 0 1px 18px rgba(0, 0, 0, .55);
}
.rack-stage svg { display: block; width: 100%; height: auto; }
.rack-empty-note {
  margin: 10px 0 1px; text-align: center;
  font-size: 11.5px; letter-spacing: .12em; color: var(--muted);
}
.rack-overflow {
  margin: 9px 2px 0; text-align: center;
  font-size: 10.5px; letter-spacing: .06em; color: #cbb47f;
}
.rb-bar-svg { display: block; }
.rb-ghost { cursor: pointer; }
.rb-ghost .rb-ghost-box {
  fill: rgba(47, 134, 196, .05);
  stroke: rgba(147, 167, 189, .4);
  stroke-width: 1; stroke-dasharray: 4 4;
  transition: fill var(--ease), stroke var(--ease);
}
.rb-ghost:hover .rb-ghost-box, .rb-ghost:focus .rb-ghost-box {
  fill: rgba(47, 134, 196, .16); stroke: var(--gold);
}
.rb-ghost .rb-ghost-plus { stroke: rgba(147, 167, 189, .7); }
.rb-ghost:hover .rb-ghost-plus, .rb-ghost:focus .rb-ghost-plus { stroke: #e2cf9e; }
.rb-token { display: inline-block; flex: none; vertical-align: middle; }

/* ---------- 我的荣誉 ---------- */
.honor-list { list-style: none; margin: 0; padding: 0; }
.honor {
  display: grid; grid-template-columns: 74px minmax(0, 1fr) auto;
  gap: 10px; align-items: center;
  padding: 11px 0; border-top: 1px solid rgba(31, 51, 80, .8);
}
.honor:first-child { border-top: 0; }
.honor-bar { min-width: 0; }
.honor-bar svg { width: 74px; height: auto; }
.honor-main { min-width: 0; }
.honor-name {
  display: flex; align-items: baseline; flex-wrap: wrap; gap: 5px;
  font-size: 12.5px; line-height: 1.4; color: #dde7f2;
}
.honor-name .variant { font-size: 11px; color: #9fb3c8; }
.honor-name .honor-qty { font-size: 10.5px; color: var(--gold); }
.honor-meta {
  margin: 3px 0 0;
  font-size: 10.5px; line-height: 1.5; color: var(--muted);
  overflow-wrap: anywhere;
}
.honor-meta .doc { color: #b8c8d8; }
.honor-action { align-self: start; margin-top: 1px; }

/* ---------- 可申领图鉴 ---------- */
.catalog-panel { display: flex; flex-direction: column; }
.catalog-tools { margin-bottom: 9px; }
.bundles {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px; min-width: 0; max-width: 100%;
  padding: 0 0 10px; margin-bottom: 9px;
  border-bottom: 1px solid rgba(31, 51, 80, .8);
}
.bundles:empty { display: none; }
.bundle {
  width: auto; min-width: 0; max-width: 100%;
  display: flex; flex-direction: column; gap: 4px;
  padding: 9px 10px;
  border: 1px solid rgba(200, 164, 92, .32); border-radius: 5px;
  background: linear-gradient(180deg, rgba(200, 164, 92, .1), rgba(200, 164, 92, .02));
}
.bundle-name { font-family: var(--font-serif); font-size: 13px; color: #e4cf9f; letter-spacing: .04em; }
.bundle-desc { font-size: 10.5px; line-height: 1.45; color: var(--muted); overflow-wrap: anywhere; word-break: break-word; }
.bundle-items { font-size: 10px; line-height: 1.4; color: #8398ac; overflow-wrap: anywhere; word-break: break-word; }
.bundle .btn { margin-top: 4px; white-space: normal; }
.bundle.is-na { opacity: .55; }
.bundle.is-na .bundle-name { color: #a4946f; }
.cat-scroll {
  max-height: calc(100vh - 310px); min-height: 280px; min-width: 0;
  overflow: auto; overscroll-behavior: contain;
  padding-right: 4px;
  scrollbar-width: thin; scrollbar-color: #2a4669 transparent;
}
.cat-scroll::-webkit-scrollbar { width: 8px; }
.cat-scroll::-webkit-scrollbar-thumb { background: #233d5a; border-radius: 4px; }
.cat-scroll::-webkit-scrollbar-track { background: transparent; }
.cat-class { border-top: 1px solid rgba(31, 51, 80, .85); }
.cat-class:first-child { border-top: 0; }
.cat-class > summary {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 2px; cursor: pointer;
  list-style: none; user-select: none;
  font-size: 12.5px; letter-spacing: .04em; color: #d5e1ee;
}
.cat-class > summary::-webkit-details-marker { display: none; }
.cat-class > summary::after {
  content: "▾"; margin-left: 2px; color: #738aa0; font-size: 10px;
  transition: transform var(--ease);
}
.cat-class[open] > summary::after { transform: rotate(180deg); }
.cat-class > summary .class-name { flex: 1; min-width: 0; }
.cat-class > summary .count { color: var(--muted); font-size: 10.5px; }
.cat-class > summary .rb-token { color: var(--gold); }
.cat-body { padding: 0 0 4px; }
.cat-item { padding: 7px 0 9px; border-top: 1px dashed rgba(31, 51, 80, .8); }
.cat-item:first-child { border-top: 0; }
.cat-item-head {
  display: flex; align-items: baseline; gap: 7px; flex-wrap: wrap;
  margin-bottom: 4px;
  font-size: 12px; color: #cfdbe8;
}
.cat-item-head .item-name { min-width: 0; }
.cat-item-head .sub-tag {
  padding: 0 4px; border: 1px solid rgba(95, 179, 232, .28); border-radius: 2px;
  font-size: 9.5px; color: #8eb6d3;
}
.cat-item-head .who-note { margin-left: auto; font-size: 9.5px; color: #7b91a7; white-space: nowrap; }
.variants { display: flex; flex-direction: column; }
.variant-row {
  display: grid; grid-template-columns: 68px minmax(0, 1fr) auto;
  gap: 9px; align-items: center;
  padding: 3px 0; border-radius: 3px;
}
.variant-row.is-na { opacity: .42; }
.variant-row.is-claimed { opacity: .62; }
.v-bar { min-width: 0; }
.v-bar svg { width: 64px; height: 20px; display: block; }
.v-name {
  display: flex; align-items: baseline; gap: 6px; min-width: 0;
  font-size: 11.5px; color: #aabdd0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.v-name .v-state { flex: none; font-size: 9.5px; color: var(--gold); letter-spacing: .04em; }
.v-name .v-state.is-claimed { color: #7d91a6; }
.v-actions { display: flex; align-items: center; gap: 4px; }
.variant-row.is-na .btn { border-color: var(--line); color: #73879c; }
.empty-search { padding: 18px 8px; text-align: center; font-size: 11.5px; color: var(--muted); }

/* ---------- 申领单（纸卡） ---------- */
.claim-items { list-style: none; margin: 0; padding: 0; }
.claim-items:empty { display: none; }
.claim-row {
  display: grid; grid-template-columns: 46px minmax(0, 1fr) auto;
  gap: 9px; align-items: center;
  padding: 8px 0; border-bottom: 1px solid var(--paper-line);
}
.claim-row:first-child { border-top: 1px solid var(--paper-line); }
.claim-bar svg { width: 46px; height: auto; display: block; }
.claim-info { min-width: 0; }
.claim-name {
  display: flex; align-items: center; flex-wrap: wrap; gap: 4px;
  font-size: 12px; line-height: 1.4; color: #1b2c3e;
}
.claim-name .variant { font-size: 10.5px; color: #657a8f; }
.claim-select {
  height: 22px; max-width: 112px; padding: 0 3px;
  border: 1px solid #cfd9e4; border-radius: 3px;
  background: #fff; color: #2c4258;
  font-family: var(--font-sans); font-size: 10.5px; line-height: 1;
}
.claim-select:focus { outline: 2px solid rgba(47, 134, 196, .3); outline-offset: 1px; }
.claim-sub {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  margin-top: 2px; font-size: 10px; color: var(--paper-muted);
}
.claim-sub .mode { color: #8a6c2e; }
.claim-sub .mode.is-new { color: #a34b2e; }
.claim-actions { display: flex; align-items: center; gap: 5px; }
.stepper { display: inline-flex; align-items: center; gap: 0; }
.stepper button {
  width: 21px; height: 21px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid #cfd9e4; background: #fff; color: #40556b;
  font-size: 12px; line-height: 1; cursor: pointer;
}
.stepper button:first-child { border-radius: 3px 0 0 3px; }
.stepper button:last-child { border-radius: 0 3px 3px 0; }
.stepper button:hover { background: #eef3f8; border-color: #a9bbcd; }
.stepper .qty { min-width: 26px; padding: 0 3px; text-align: center; font-size: 11px; color: #24384c; font-variant-numeric: tabular-nums; }
.claim-remove {
  width: 21px; height: 21px; margin-left: 3px;
  border: 1px solid transparent; border-radius: 3px;
  background: none; color: #9a7b6e; font-size: 14px; line-height: 1; cursor: pointer;
}
.claim-remove:hover { border-color: #d8bfb3; color: #a5422a; background: #f8efeb; }

.claim-total {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-top: 2px; padding: 9px 0 7px;
  border-top: 1px solid var(--paper-line);
  font-size: 11.5px; color: var(--paper-muted); letter-spacing: .08em;
}
.claim-total strong {
  font-family: var(--font-serif); font-size: 19px; font-weight: 600;
  color: #1a2d40; letter-spacing: .02em;
}

.field { display: flex; flex-direction: column; gap: 4px; margin-top: 9px; }
.field > span { font-size: 11px; letter-spacing: .04em; color: #4d6175; }
.field > span em { font-style: normal; margin-left: 4px; font-size: 10px; color: #ae4a2b; }
.field .hint { font-size: 10px; color: var(--paper-muted); }
.input {
  width: 100%; padding: 8px 9px;
  border: 1px solid #cfd9e4; border-radius: 4px;
  background: #fff; color: var(--paper-ink);
  font-family: var(--font-sans); font-size: 12.5px; line-height: 1.45;
  transition: border-color var(--ease), box-shadow var(--ease);
}
.input::placeholder { color: #93a3b3; }
.input:focus { outline: none; border-color: var(--sky); box-shadow: 0 0 0 2px rgba(47, 134, 196, .18); }
textarea.input { resize: vertical; min-height: 38px; }
.input:disabled { background: #eef1f5; color: #778a9c; }
.input--dark {
  border-color: var(--line); background: #0b1a2b; color: var(--text);
}
.input--dark::placeholder { color: #6f849b; }
.input--dark:focus { border-color: var(--sky-2); box-shadow: 0 0 0 2px rgba(95, 179, 232, .18); }

/* ---------- 申领记录 ---------- */
.claim-log { list-style: none; margin: 0; padding: 0; }
.log-item { padding: 10px 0; border-top: 1px solid rgba(31, 51, 80, .8); }
.log-item:first-child { border-top: 0; }
.log-head { display: flex; align-items: center; gap: 8px; min-width: 0; }
.log-kind { font-size: 12px; color: #d4e0ec; letter-spacing: .04em; }
.log-when { margin-left: auto; flex: none; font-size: 10.5px; color: var(--muted); letter-spacing: .02em; }
.log-items { margin: 4px 0 0; font-size: 10.5px; line-height: 1.55; color: var(--muted); overflow-wrap: anywhere; }
.log-note { margin: 3px 0 0; font-size: 10.5px; line-height: 1.5; color: #d0b485; overflow-wrap: anywhere; }
.log-note.is-reject { color: #dfa593; }
.log-list-empty { padding: 16px 4px; }

/* ---------- 弹窗 ---------- */
.dialog {
  width: min(660px, calc(100vw - 32px)); max-height: 86vh;
  margin: auto; padding: 0;
  border: 1px solid rgba(200, 164, 92, .38); border-radius: var(--radius);
  background: var(--panel); color: var(--text);
  box-shadow: 0 30px 70px rgba(0, 0, 0, .62);
}
.dialog[open] { display: flex; flex-direction: column; }
.dialog::backdrop { background: rgba(3, 8, 15, .72); backdrop-filter: blur(2px); }
.dialog-head {
  flex: none; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(19, 42, 68, .6), rgba(14, 31, 51, .2));
}
.dialog-title { margin: 0; font-family: var(--font-serif); font-size: 16px; font-weight: 600; letter-spacing: .1em; color: #f0e5ca; }
.dialog-body { flex: 1; min-height: 0; overflow: auto; padding: 16px 18px; }
.dialog-foot {
  flex: none; display: flex; align-items: center; justify-content: flex-end; gap: 8px;
  padding: 12px 18px; border-top: 1px solid var(--line);
  background: rgba(8, 18, 31, .35);
}
.dialog-note { margin: 0 0 12px; font-size: 12px; line-height: 1.6; color: var(--paper-muted); }
.dialog--paper .dialog-body { background: var(--paper); color: var(--paper-ink); }
.dialog--paper .dialog-note { color: #4c6074; }
.dialog--paper .field > span { color: #4d6175; }
.dialog--paper .input { border-color: #cfd9e4; background: #fff; color: var(--paper-ink); }
.dialog--paper .form-status { color: #a5422a; }
.dialog--paper .form-status[data-kind="ok"] { color: #2b6b4a; }
.icon-btn {
  width: 28px; height: 28px; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid transparent; border-radius: 4px;
  background: none; color: var(--muted);
  font-size: 20px; line-height: 1; cursor: pointer;
}
.icon-btn:hover { color: var(--text); border-color: var(--line); background: rgba(19, 42, 68, .7); }

.pick-section { margin-top: 14px; }
.pick-section:first-child { margin-top: 0; }
.pick-title {
  display: flex; align-items: center; gap: 8px;
  margin: 0 0 6px; font-size: 11px; font-weight: 500; letter-spacing: .12em; color: var(--muted);
}
.pick-title::after { content: ""; flex: 1; height: 1px; background: rgba(31, 51, 80, .9); }
.pick-list { display: flex; flex-direction: column; }
.pick-row {
  display: grid; grid-template-columns: 62px minmax(0, 1fr) auto;
  gap: 10px; align-items: center;
  padding: 8px 0; border-top: 1px solid rgba(31, 51, 80, .75);
}
.pick-row:first-child { border-top: 0; }
.pick-bar svg { width: 60px; height: auto; display: block; }
.pick-name { font-size: 12px; line-height: 1.4; color: #d7e2ee; }
.pick-sub { margin-top: 1px; font-size: 10px; color: var(--muted); }
.pick-bundles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.pick-empty { padding: 16px 4px; font-size: 11.5px; color: var(--muted); text-align: center; }

/* ---------- 提示 ---------- */
.toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 80;
  max-width: min(520px, calc(100vw - 32px));
  padding: 10px 16px;
  border: 1px solid #dce3ec; border-left: 3px solid var(--sky); border-radius: 5px;
  background: var(--paper); color: var(--paper-ink);
  font-size: 12.5px; line-height: 1.5;
  box-shadow: 0 14px 36px rgba(0, 0, 0, .48);
  transform: translate(-50%, 12px); opacity: 0; pointer-events: none;
  transition: opacity var(--ease), transform var(--ease);
}
.toast.is-on { transform: translate(-50%, 0); opacity: 1; }
.toast.is-error { border-left-color: #b74a32; }

/* ---------- 通用表格（管理端可复用） ---------- */
.table { width: 100%; border-collapse: collapse; font-size: 12px; }
.table th {
  padding: 8px 10px; text-align: left; white-space: nowrap;
  font-weight: 500; font-size: 10.5px; letter-spacing: .08em; color: var(--muted);
  border-bottom: 1px solid var(--line);
}
.table td { padding: 9px 10px; vertical-align: top; border-bottom: 1px solid rgba(31, 51, 80, .7); }
.table tbody tr:last-child td { border-bottom: 0; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table .nowrap { white-space: nowrap; }
.paper .table th, .panel--paper .table th { color: var(--paper-muted); border-bottom-color: var(--paper-line); }
.paper .table td, .panel--paper .table td { border-bottom-color: var(--paper-line); }

/* ---------- 响应式 ---------- */
@media (max-width: 1180px) {
  .board { gap: 14px; }
  .panel { padding: 16px; }
  .cat-scroll { max-height: 560px; }
  .bundles { gap: 6px; }
  .bundle { padding: 8px 9px; }
}
@media (max-width: 980px) {
  .topbar { position: static; padding: 13px 20px; flex-wrap: wrap; }
  .topbar-side { width: 100%; justify-content: flex-end; }
  .who { width: 100%; justify-content: flex-end; }
  .who-meta { max-width: none; white-space: normal; }
  .shell { padding: 20px 20px 38px; }
  .login { grid-template-columns: 1fr; gap: 28px; min-height: 0; padding: 20px 0 26px; }
  .login-lead { flex-direction: row; align-items: center; gap: 22px; min-height: 0; padding: 0; }
  .login-crest { width: 104px; }
  .login-stat { display: none; }
  .id-panel { max-width: none; }
  .id-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .id-card { min-height: 0; }
  .board { grid-template-columns: 1fr; }
  .col--catalog { grid-column: auto; }
  .cat-scroll { max-height: none; min-height: 0; overflow: visible; padding-right: 0; }
  .site-foot { padding: 12px 20px 24px; }
}
@media (max-width: 720px) {
  .brand-org { font-size: 9px; letter-spacing: .14em; }
  .brand-title { font-size: 17px; letter-spacing: .1em; }
  .crest { width: 44px; height: 45px; }
  .shell { padding: 16px 14px 32px; }
  .topbar { padding: 12px 14px; }
  .login-lead { gap: 16px; }
  .login-crest { width: 84px; }
  .login-title { font-size: 25px; }
  .id-list { grid-template-columns: 1fr; }
  .id-card { min-height: 0; }
  .bundles, .pick-bundles { grid-template-columns: 1fr; }
  .panel { padding: 14px; }
  .rack-stage { padding: 6px; }
  .honor { grid-template-columns: 64px minmax(0, 1fr) auto; gap: 8px; }
  .honor-bar svg { width: 64px; }
  .variant-row { grid-template-columns: 60px minmax(0, 1fr) auto; gap: 7px; }
  .v-bar svg { width: 56px; height: 18px; }
  .cat-item-head .who-note { display: none; }
  .claim-row { grid-template-columns: 42px minmax(0, 1fr) auto; }
  .claim-bar svg { width: 42px; }
  .site-foot { flex-direction: column; gap: 4px; }
  .dialog { width: calc(100vw - 20px); max-height: 92vh; }
  .dialog-body { padding: 14px; }
  .dialog-head { padding: 12px 14px; }
  .dialog-foot { padding: 10px 14px; }
  .who { gap: 8px; }
  .who-name { font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
