/* ===========================================================
   WMS 2.0 原型 · 设计系统
   =========================================================== */
:root {
  --blue-900: #0b3552;
  --blue-800: #075a8c;
  --blue-700: #0b6fa8;
  --blue-600: #169bd5;
  --blue-500: #1e98d7;
  --blue-100: #dbf1fe;
  --blue-50: #f0f8fe;
  --ink: #1f2d3d;
  --ink-2: #40566b;
  --ink-3: #64798d;
  --muted: #8a9aab;
  --line: #e4ebf2;
  --line-2: #d3dfe9;
  --bg: #f3f7fa;
  --white: #fff;
  --red: #d64545;
  --red-soft: #fdf1f1;
  --green: #2e9e6b;
  --amber: #b97614;
  --shadow-sm: 0 1px 2px rgba(16, 42, 67, 0.06);
  --shadow-md: 0 8px 24px rgba(16, 42, 67, 0.12);
  --shadow-lg: 0 24px 60px rgba(8, 32, 54, 0.24);
  --radius: 10px;
  --topbar-h: 64px;
  --sidebar-w: 184px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: "Inter", -apple-system, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--blue-600); text-decoration: none; }
a:hover { color: var(--blue-700); }
button { font-family: inherit; }
h1, h2, h3, h4, p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
svg { display: block; }
.ico { width: 16px; height: 16px; flex: none; }
.btn .ico { width: 14px; height: 14px; }
.page-btn .ico { width: 12px; height: 12px; }

/* ---------- 顶栏 ---------- */
.topbar {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 0 20px 0 18px;
  background: linear-gradient(92deg, #dbf1fe 0%, #eaf7ff 62%, #f4fbff 100%);
  border-bottom: 1px solid #b9d8ea;
  z-index: 30;
}
.brand { display: flex; align-items: center; gap: 10px; min-width: calc(var(--sidebar-w) - 18px); }
.brand-mark {
  width: 32px; height: 32px; border-radius: 8px;
  background: linear-gradient(145deg, #0b6fa8, #169bd5);
  color: #fff; font-weight: 800; font-size: 16px;
  display: grid; place-items: center;
  box-shadow: 0 2px 6px rgba(11, 111, 168, 0.35);
}
.brand-name { font-size: 16px; font-weight: 700; color: var(--blue-900); letter-spacing: 0.2px; }
.brand-name small { display: block; font-size: 10px; font-weight: 500; color: var(--blue-700); letter-spacing: 1.6px; }
.topbar-spacer { flex: 1; }
.scope-switch { display: flex; align-items: center; gap: 12px; }
.wh-switch { display: flex; align-items: center; gap: 8px; color: var(--ink-2); font-size: 12.5px; }
.wh-switch .select { height: 32px; min-width: 118px; background: rgba(255,255,255,.85); }
.user-chip { display: flex; align-items: center; gap: 9px; padding-left: 14px; border-left: 1px solid #b9d8ea; }
.user-chip .avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: #fff url("../assets/img/avatar.png") center/cover no-repeat;
  border: 1px solid #cfe4f2;
  flex: none;
}
.menu-btn {
  display: none;
  width: 34px; height: 34px; border: 1px solid #b9d8ea; border-radius: 8px;
  background: rgba(255,255,255,.7); color: var(--ink-2);
  align-items: center; justify-content: center; cursor: pointer;
  flex: none;
}
.menu-btn:hover { background: #fff; color: var(--blue-700); }
.user-chip b { display: block; font-size: 13px; font-weight: 600; color: var(--ink); line-height: 1.2; }
.user-chip span { display: block; font-size: 11px; color: var(--ink-3); }
.user-chip .logout {
  margin-left: 4px; color: var(--ink-3); font-size: 12px;
  padding: 4px 8px; border-radius: 6px;
}
.user-chip .logout:hover { background: #fff; color: var(--red); text-decoration: none; }

/* ---------- 侧栏 ---------- */
.sidebar {
  position: fixed;
  top: var(--topbar-h); bottom: 0; left: 0;
  width: var(--sidebar-w);
  background: #fff;
  border-right: 1px solid var(--line);
  display: flex; flex-direction: column;
  z-index: 20;
}
.nav { flex: 1; padding: 10px 10px 16px; overflow-y: auto; overflow-x: hidden; }
.nav::-webkit-scrollbar { width: 6px; }
.nav::-webkit-scrollbar-thumb { background: #dbe6ef; border-radius: 3px; }

.nav-group { position: relative; margin-bottom: 4px; }
.nav-group + .nav-group { border-top: 1px solid #f1f5f9; padding-top: 4px; }
.nav-item {
  position: relative;
  display: flex; align-items: center; gap: 9px;
  height: 40px; padding: 0 12px; margin-bottom: 2px;
  border-radius: 8px;
  color: var(--ink-2); font-size: 13px; font-weight: 500;
  cursor: pointer; user-select: none;
  transition: background .15s, color .15s;
}
.nav-item .nav-ico { width: 16px; height: 16px; color: #8fa5b8; flex: none; }
.nav-item .caret { margin-left: auto; width: 12px; height: 12px; color: #a9bac9; transition: transform .18s; }
.nav-item:hover { background: var(--blue-50); color: var(--blue-700); }
.nav-item:hover .nav-ico { color: var(--blue-600); }
.nav-item.active {
  background: #e8f4fd; color: var(--blue-800); font-weight: 600;
  box-shadow: inset 3px 0 0 var(--blue-600);
}
.nav-item.active .nav-ico { color: var(--blue-700); }
.nav-item.disabled { color: #aebccb; cursor: default; }
.nav-item.disabled:hover { background: transparent; color: #aebccb; }
.nav-item.disabled:hover .nav-ico { color: #c3d0dc; }

.nav-flyout {
  position: relative;
  display: none;
  padding: 2px 0 6px 28px;
}
.nav-group.open > .nav-flyout { display: block; }
.nav-group.open > .nav-item .caret { transform: rotate(90deg); }
.nav-flyout .nav-item {
  height: auto; min-height: 34px; margin: 1px 0; padding: 6px 10px;
  font-size: 12.8px; font-weight: 400; gap: 8px;
  line-height: 1.45; white-space: normal;
}
.nav-flyout .nav-item.active { box-shadow: inset 3px 0 0 var(--blue-600); }
.nav-flyout .nav-dot { width: 5px; height: 5px; border-radius: 50%; background: #c3d2df; flex: none; margin-top: 6px; }
.nav-flyout .nav-item.active .nav-dot,
.nav-flyout .nav-item:hover .nav-dot { background: var(--blue-600); }

.sidebar-foot {
  padding: 12px 16px 16px;
  border-top: 1px solid var(--line);
  font-size: 11px; color: var(--muted); line-height: 1.7;
}
.sidebar-foot b { color: var(--ink-3); font-weight: 600; }

/* ---------- 主内容 ---------- */
.content {
  margin-left: var(--sidebar-w);
  padding: calc(var(--topbar-h) + 20px) 22px 28px;
  min-height: 100vh;
}
.page-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 16px; margin-bottom: 14px;
}
.page-head h1 { font-size: 19px; font-weight: 700; color: var(--ink); letter-spacing: .2px; }
.breadcrumb { font-size: 12px; color: var(--muted); margin-top: 3px; }
.breadcrumb b { color: var(--ink-3); font-weight: 500; }

/* ---------- 卡片 / 工具条 ---------- */
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.filter-bar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px;
  padding: 14px 16px;
  margin-bottom: 12px;
}
.filter-bar .filter { display: flex; align-items: center; gap: 8px; }
.filter-bar .filter > label { color: var(--ink-3); font-size: 12.5px; white-space: nowrap; }
.filter-bar .spacer { flex: 1; }

.toolbar {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}
.toolbar .spacer { flex: 1; }
.toolbar .bulk-tip { color: var(--ink-3); font-size: 12px; }
.toolbar .bulk-tip b { color: var(--blue-700); font-weight: 600; }

/* ---------- 表单控件 ---------- */
.input, .select, .textarea {
  height: 34px; padding: 0 10px;
  border: 1px solid var(--line-2);
  border-radius: 7px;
  background: #fff;
  color: var(--ink);
  font-size: 13px;
  font-family: inherit;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.input::placeholder, .textarea::placeholder { color: #a7b6c4; }
.input:focus, .select:focus, .textarea:focus {
  border-color: var(--blue-500);
  box-shadow: 0 0 0 3px rgba(30, 152, 215, 0.13);
}
.input:disabled { background: #f2f5f8; color: #93a3b3; cursor: not-allowed; }
.input[readonly] { background: #f7fafc; color: var(--ink-2); cursor: default; }
.select:disabled { background-color: #f2f5f8; color: #93a3b3; cursor: not-allowed; }
.select {
  appearance: none; padding-right: 28px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%238a9aab' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center;
}
.textarea { height: auto; min-height: 74px; padding: 8px 10px; resize: vertical; line-height: 1.6; }
.input.w-sm { width: 108px; }
.input.w-md { width: 158px; }
.input.w-lg { width: 200px; }
.select.w-md { width: 150px; }
.date-range { display: flex; align-items: center; gap: 6px; }
.date-range .input { width: 126px; }
.date-range .sep { color: var(--muted); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 34px; padding: 0 14px;
  border-radius: 7px;
  border: 1px solid var(--line-2);
  background: #fff;
  color: var(--ink-2);
  font-size: 13px; font-weight: 500;
  cursor: pointer; white-space: nowrap;
  transition: background .15s, border-color .15s, color .15s, box-shadow .15s;
}
.btn:hover { border-color: #b9cbd9; background: #f8fbfd; color: var(--blue-700); }
.btn:active { transform: translateY(1px); }
.btn .ico { width: 14px; height: 14px; }
.btn-primary {
  background: var(--blue-500); border-color: var(--blue-500); color: #fff;
  box-shadow: 0 2px 6px rgba(30, 152, 215, 0.25);
}
.btn-primary:hover { background: #178cc7; border-color: #178cc7; color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; color: var(--blue-600); padding: 0 8px; }
.btn-ghost:hover { background: var(--blue-50); border-color: transparent; }
.btn-sm { height: 30px; padding: 0 11px; font-size: 12.5px; }
.btn-danger { color: var(--red); }
.btn-danger:hover { color: var(--red); border-color: #efc2c2; background: var(--red-soft); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

.check { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ink-2); cursor: pointer; }
.check input[type="checkbox"], .check input[type="radio"] { accent-color: var(--blue-500); width: 14px; height: 14px; margin: 0; }

/* ---------- 表格 ---------- */
.table-wrap { overflow-x: auto; }
.table { width: 100%; min-width: 980px; border-collapse: separate; border-spacing: 0; font-size: 12.8px; table-layout: fixed; }
.table th {
  height: 42px; padding: 0 10px;
  background: #f7fafc;
  color: var(--ink-2);
  font-weight: 600; text-align: center; white-space: nowrap;
  border-bottom: 1px solid var(--line);
}
.table td {
  height: 42px; padding: 0 10px;
  text-align: center; color: var(--ink);
  border-bottom: 1px solid #eff4f8;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.table tbody tr:hover td { background: #f8fbfe; }
.table tbody tr:last-child td { border-bottom: none; }
.table .col-check { width: 44px; }
.table .col-actions { white-space: nowrap; }
.table .col-index { width: 46px; color: var(--muted); }
.table td.left, .table th.left { text-align: left; }
.table td.wrap { white-space: normal; line-height: 1.55; padding: 8px 10px; text-align: left; }
.table .mono { font-family: "SFMono-Regular", Consolas, monospace; font-size: 12px; }
.table .link { color: var(--blue-600); cursor: pointer; }
.table .link:hover { text-decoration: underline; }
.table .link.danger { color: #d07070; }
.table .link.danger:hover { color: var(--red); }
.table .link + .link { margin-left: 10px; }
.table .muted { color: var(--muted); }
.table .tag {
  display: inline-flex; align-items: center; gap: 5px;
  height: 22px; padding: 0 9px; border-radius: 11px;
  font-size: 11.5px; font-weight: 500;
}
.tag-on { background: #eaf7f0; color: #237a51; }
.tag-off { background: #f2f5f8; color: #7d8d9d; }
.tag-info { background: #eaf4fd; color: #146fa9; }
.tag-warn { background: #fdf5e7; color: #9a6812; }
.tag-err { background: #fdeeee; color: #b63c3c; }
.table .tag::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: .8; }

.empty {
  padding: 60px 20px; text-align: center; color: var(--muted);
}
.empty svg { margin: 0 auto 10px; opacity: .5; }

/* ---------- 分页 ---------- */
.pager {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px;
  border-top: 1px solid var(--line);
  color: var(--ink-3); font-size: 12.5px;
}
.pager .total { margin-right: auto; }
.pager .total b { color: var(--ink); font-weight: 600; }
.pager .pager-nav { display: flex; align-items: center; gap: 4px; }
.page-btn {
  min-width: 30px; height: 30px; padding: 0 6px;
  border: 1px solid transparent; border-radius: 7px;
  background: transparent; color: var(--ink-2);
  font-size: 12.5px; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.page-btn:hover { background: var(--blue-50); color: var(--blue-700); }
.page-btn.active { background: var(--blue-500); color: #fff; border-color: var(--blue-500); font-weight: 600; }
.page-btn[disabled] { color: #c2ced9; cursor: default; background: transparent; }
.page-size { height: 30px; font-size: 12.5px; }
.pager .goto { display: flex; align-items: center; gap: 6px; }
.pager .goto .input { width: 46px; height: 30px; text-align: center; padding: 0 4px; }

/* ---------- 说明 ---------- */
.page-note {
  margin-top: 14px;
  padding: 10px 14px;
  background: #fffdf7;
  border: 1px solid #f3e6c8;
  border-left: 3px solid #e3b65b;
  border-radius: 8px;
  color: #8a6a2c;
  font-size: 12.2px;
  line-height: 1.85;
  white-space: pre-line;
}
.page-note b { color: #7a5a1c; }

/* ---------- 弹窗 ---------- */
.modal-mask {
  position: fixed; inset: 0;
  background: rgba(12, 34, 54, 0.46);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  z-index: 100;
  animation: fadeIn .16s ease;
}
.modal {
  width: 520px; max-width: 100%;
  max-height: calc(100vh - 48px);
  display: flex; flex-direction: column;
  background: #fff; border-radius: 12px;
  box-shadow: var(--shadow-lg);
  animation: popIn .18s cubic-bezier(.2,.9,.3,1.2);
  overflow: hidden;
}
.modal.modal-lg { width: 760px; }
.modal.modal-xl { width: 1360px; max-width: calc(100vw - 48px); }
.modal.modal-xl .modal-body { padding: 20px 22px; }
.modal.modal-sm { width: 400px; }
.modal-head {
  display: flex; align-items: center; gap: 10px;
  height: 54px; padding: 0 18px;
  border-bottom: 1px solid var(--line);
}
.modal-head h3 { font-size: 15px; font-weight: 650; color: var(--ink); }
.modal-head .modal-sub { font-size: 12px; color: var(--muted); }
.modal-close {
  margin-left: auto; width: 30px; height: 30px; border: none; border-radius: 7px;
  background: transparent; color: #8a9aab; cursor: pointer;
  display: grid; place-items: center;
}
.modal-close:hover { background: #f1f5f9; color: var(--ink); }
.modal-body { padding: 18px; overflow-y: auto; }
.modal-foot {
  display: flex; justify-content: flex-end; gap: 10px;
  padding: 13px 18px;
  border-top: 1px solid var(--line);
  background: #fbfdfe;
}
.modal-foot .spacer { flex: 1; }
.modal-foot .btn { min-width: 78px; }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; }
.form-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.form-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.form-grid .span-2 { grid-column: span 2; }
.form-grid.cols-3 .span-2 { grid-column: span 2; }
.form-grid.cols-4 .span-2 { grid-column: span 2; }
.form-grid .span-3 { grid-column: span 3; }
.form-grid .span-4 { grid-column: span 4; }
.form-grid.cols-4 .form-section-title { grid-column: span 4; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > label { font-size: 12.5px; color: var(--ink-2); }
.field > label .req { color: var(--red); margin-right: 2px; }
.field .hint { font-size: 11.5px; color: var(--muted); }
.field .input, .field .select, .field .textarea { width: 100%; }
.field a { display: inline-flex; align-items: center; gap: 6px; font-size: 12.8px; }
.field a .ico { width: 14px; height: 14px; }
.field .inline-group { display: flex; align-items: center; gap: 6px; }
.field .inline-group .input { flex: 1; }
.field .inline-group .unit { color: var(--muted); font-size: 12px; }
.radio-row { display: flex; align-items: center; gap: 18px; height: 34px; }
.checkbox-grid { display: flex; flex-wrap: wrap; gap: 10px 18px; padding: 4px 0; }
.owner-wait {
  display: flex; align-items: center; justify-content: center;
  min-height: 40px; padding: 8px 12px;
  border: 1px dashed var(--line-2); border-radius: 8px;
  background: #fbfdff; color: var(--muted); font-size: 12px;
}

.form-section-title {
  grid-column: span 2;
  display: flex; align-items: center; gap: 8px;
  margin: 4px 0 0;
  font-size: 12.5px; font-weight: 600; color: var(--ink-2);
}
.form-section-title::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* 确认框 */
.confirm-body { display: flex; gap: 14px; padding: 22px 20px; }
.confirm-icon {
  width: 38px; height: 38px; border-radius: 50%; flex: none;
  display: grid; place-items: center;
  background: #fdf1e6; color: #d08a2c;
}
.confirm-icon.danger { background: var(--red-soft); color: var(--red); }
.confirm-text b { display: block; font-size: 13.5px; color: var(--ink); margin-bottom: 4px; }
.confirm-text p { font-size: 12.5px; color: var(--ink-3); line-height: 1.7; }

/* ---------- Toast ---------- */
.toast-wrap {
  position: fixed; right: 24px; bottom: 24px; z-index: 200;
  display: flex; flex-direction: column; gap: 10px;
  pointer-events: none;
}
.toast {
  display: flex; align-items: center; gap: 9px;
  min-width: 220px; max-width: 360px;
  padding: 11px 14px;
  background: #1f2d3d; color: #fff;
  border-radius: 9px; font-size: 12.8px;
  box-shadow: 0 12px 30px rgba(9, 28, 45, .28);
  animation: toastIn .22s ease;
}
.toast .ico { width: 16px; height: 16px; color: #6fd3a0; flex: none; }
.toast.error .ico { color: #ff9d9d; }
.toast.hide { animation: toastOut .2s ease forwards; }

/* ---------- 首页 ---------- */
.home-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 16px; }
.profile-card { display: flex; align-items: center; gap: 20px; padding: 24px; }
.profile-avatar {
  width: 96px; height: 96px; border-radius: 50%;
  background: center/cover no-repeat url("../assets/img/avatar.png");
  border: 4px solid #eef7fd; box-shadow: 0 6px 18px rgba(16, 42, 67, .12);
  flex: none;
}
.profile-info h2 { font-size: 17px; font-weight: 650; color: var(--ink); }
.profile-info .uname { margin-top: 4px; color: var(--ink-3); font-size: 13px; }
.profile-info .validity {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 12px; padding: 4px 10px; border-radius: 20px;
  background: var(--blue-50); color: var(--blue-700); font-size: 12px;
}
.profile-info .validity .ico { width: 14px; height: 14px; }
.quick-link .qi .ico { width: 17px; height: 17px; }
.home-illus { display: flex; align-items: center; justify-content: center; padding: 12px; }
.home-illus img { max-width: 100%; max-height: 240px; }
.quick-links { margin-top: 16px; padding: 18px 20px 6px; }
.quick-links h3 { font-size: 13.5px; font-weight: 650; color: var(--ink); margin-bottom: 14px; }
.quick-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.quick-link {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px; border: 1px solid var(--line); border-radius: 9px;
  color: var(--ink-2); font-size: 12.8px; background: #fff;
  transition: all .15s;
}
.quick-link:hover { border-color: #b9dcf3; background: var(--blue-50); color: var(--blue-800); text-decoration: none; }
.quick-link .qi {
  width: 30px; height: 30px; border-radius: 8px;
  background: #eef7fd; color: var(--blue-600);
  display: grid; place-items: center; flex: none;
}

/* ---------- 工作台 / 待办 / 异常 / 今日作业 ---------- */
.dash-head-tools { display: flex; align-items: center; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.dash-scope {
  display: inline-flex; align-items: center; gap: 6px;
  height: 30px; padding: 0 11px; border-radius: 16px;
  border: 1px solid #cfe8f7; background: #eef8ff; color: #2a6d96;
  font-size: 12px; white-space: nowrap;
}
.dash-scope .ico { width: 14px; height: 14px; }

.work-hero {
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  padding: 16px 20px; margin-bottom: 16px;
  background: linear-gradient(110deg, #fff 0%, #f8fcff 60%, #edf8fe 100%);
}
.work-hero-left { display: flex; align-items: center; gap: 14px; min-width: 0; }
.profile-avatar.sm { width: 46px; height: 46px; border-width: 3px; }
.work-hero h2 { font-size: 15.5px; font-weight: 650; color: var(--ink); }
.work-hero p { margin-top: 4px; font-size: 12px; color: var(--ink-3); }
.work-hero p b { color: var(--ink-2); font-weight: 600; }
.work-hero-right { display: flex; align-items: center; justify-content: flex-end; gap: 9px; flex-wrap: wrap; }
.work-hero .validity {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 20px;
  background: var(--blue-50); color: var(--blue-700); font-size: 11.5px;
}
.work-hero .validity .ico { width: 14px; height: 14px; }
.hero-chip {
  padding: 4px 10px; border-radius: 8px;
  border: 1px solid var(--line); background: rgba(255,255,255,.8);
  color: var(--ink-3); font-size: 11.5px;
}
.hero-chip b { color: var(--ink-2); font-weight: 600; margin-left: 3px; }

.dash-sec-head { display: flex; align-items: center; gap: 10px; margin: 18px 0 10px; }
.dash-sec-head h3 { font-size: 14px; font-weight: 650; color: var(--ink); }
.dash-sec-head > span { font-size: 12px; color: var(--muted); }
.dash-sec-head > span b { color: var(--blue-700); font-weight: 650; }
.dash-sec-head > a { margin-left: auto; font-size: 12px; color: var(--blue-600); }
.dash-sec-head .dash-sec-tip { margin-left: auto; font-size: 11.5px; color: #a0afbd; }

.dash-todo-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.dash-todo {
  appearance: none; -webkit-appearance: none;
  display: flex; flex-direction: column; align-items: flex-start; gap: 3px;
  padding: 13px 14px 11px;
  border: 1px solid var(--line); border-radius: 10px; background: #fff;
  color: var(--ink); font-family: inherit; text-align: left; text-decoration: none;
  cursor: pointer; box-shadow: var(--shadow-sm);
  transition: transform .15s, box-shadow .15s, border-color .15s;
}
.dash-todo:hover { transform: translateY(-2px); border-color: #b9dcf3; box-shadow: 0 8px 20px rgba(16, 42, 67, .09); text-decoration: none; }
.dash-todo.active { border-color: #8fc4e8; box-shadow: 0 0 0 2px rgba(30, 152, 215, .12), 0 8px 20px rgba(16, 42, 67, .08); }
.dash-todo .t-icon { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; margin-bottom: 2px; }
.dash-todo .t-icon .ico { width: 15px; height: 15px; }
.dash-todo .t-label { font-size: 11.8px; color: var(--ink-3); }
.dash-todo .t-count { font-size: 24px; line-height: 1.1; font-weight: 750; color: var(--ink); }
.dash-todo .t-count small { font-size: 10.5px; color: var(--muted); font-weight: 500; margin-left: 2px; }
.dash-todo .t-sub { font-size: 10.5px; color: #a2b1bf; }
.dash-todo.tone-amber .t-icon { background: #fdf5e7; color: #b97614; }
.dash-todo.tone-blue .t-icon { background: #eaf4fd; color: #1e98d7; }
.dash-todo.tone-cyan .t-icon { background: #e9f8fb; color: #2595a8; }
.dash-todo.tone-indigo .t-icon { background: #eef1fc; color: #6178c7; }
.dash-todo.tone-violet .t-icon { background: #f3eefc; color: #8161bf; }
.dash-todo.tone-red .t-icon { background: #fdf1f1; color: #c25b5b; }

.dash-kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.dash-kpi {
  appearance: none; -webkit-appearance: none;
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
  padding: 13px 16px;
  border: 1px solid var(--line); border-radius: 10px; background: #fff;
  color: var(--ink); font-family: inherit; text-align: left;
  box-shadow: var(--shadow-sm);
}
button.dash-kpi { cursor: pointer; transition: border-color .15s, box-shadow .15s; }
button.dash-kpi:hover { border-color: #b9dcf3; box-shadow: 0 8px 18px rgba(16, 42, 67, .08); }
button.dash-kpi.active { box-shadow: 0 0 0 2px rgba(30, 152, 215, .12); }
.dash-kpi::after {
  content: ""; position: absolute; right: -18px; top: -22px;
  width: 68px; height: 68px; border-radius: 50%;
  background: rgba(30, 152, 215, .055);
}
.dash-kpi .k-label { font-size: 12px; color: var(--ink-3); }
.dash-kpi .k-value { font-size: 24px; font-weight: 750; line-height: 1.15; color: var(--ink); }
.dash-kpi .k-value small { font-size: 10.5px; font-weight: 500; color: var(--muted); margin-left: 3px; }
.dash-kpi .k-sub { font-size: 11.5px; color: var(--muted); }
.dash-kpi.tone-blue { border-left: 3px solid #1e98d7; }
.dash-kpi.tone-blue .k-value { color: #0b6fa8; }
.dash-kpi.tone-green { border-left: 3px solid #2e9e6b; }
.dash-kpi.tone-green .k-value { color: #237a51; }
.dash-kpi.tone-amber { border-left: 3px solid #d29a35; }
.dash-kpi.tone-amber .k-value { color: #9a6812; }
.dash-kpi.tone-violet { border-left: 3px solid #8161bf; }
.dash-kpi.tone-violet .k-value { color: #6d4eab; }
.dash-kpi.tone-red { border-left: 3px solid #cf6666; }
.dash-kpi.tone-red .k-value { color: #b63c3c; }

.dash-grid-2 { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 16px; }
.dash-spaced { margin-top: 16px; }
.dash-panel { overflow: hidden; }
.panel-head { display: flex; align-items: center; gap: 8px; padding: 13px 18px; border-bottom: 1px solid var(--line); }
.panel-head h3 { font-size: 13.5px; font-weight: 650; color: var(--ink); }
.panel-head .sp { flex: 1; }
.panel-head > a { font-size: 12px; color: var(--blue-600); }
.panel-head .panel-tip { font-size: 11.5px; color: var(--muted); }
.panel-body { padding: 16px 18px; }
.badge-soft {
  display: inline-flex; align-items: center; padding: 1px 8px; border-radius: 10px;
  background: #fdf1f1; color: #b63c3c; font-size: 10.5px; font-weight: 500;
}
.dash-empty-sm { font-size: 12px; color: var(--muted); padding: 20px 0; text-align: center; }

.donut-wrap { display: flex; align-items: center; gap: 26px; min-height: 190px; }
.dash-donut { position: relative; width: 146px; height: 146px; border-radius: 50%; flex: none; }
.dash-donut-hole {
  position: absolute; inset: 26px; border-radius: 50%; background: #fff;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  box-shadow: inset 0 0 0 1px #f1f6fa;
}
.dash-donut-hole b { font-size: 25px; font-weight: 750; color: var(--ink); line-height: 1.1; }
.dash-donut-hole span { font-size: 10.5px; color: var(--muted); margin-top: 2px; }
.donut-legend { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; min-width: 0; }
.donut-legend-row { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--ink-3); min-width: 0; }
.donut-legend-row .dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.donut-legend-row .name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.donut-legend-row b { font-size: 12px; font-weight: 600; color: var(--ink); }

.stage-list { display: grid; gap: 10px; min-height: 190px; align-content: center; }
.stage-row { display: flex; align-items: center; gap: 12px; font-size: 12px; }
.stage-name { width: 34px; color: var(--ink-3); flex: none; }
.stage-track { flex: 1; height: 8px; border-radius: 5px; background: #f1f6fa; overflow: hidden; }
.stage-track i { display: block; height: 100%; border-radius: 5px; min-width: 4px; }
.stage-row b { width: 24px; text-align: right; color: var(--ink); font-size: 12px; font-weight: 600; }

.mini-table-wrap { padding: 0 18px 10px; }
.mini-table { width: 100%; border-collapse: collapse; font-size: 12.2px; table-layout: fixed; }
.mini-table th {
  height: 36px; padding-right: 8px; border-bottom: 1px solid var(--line);
  color: var(--muted); font-size: 11.5px; font-weight: 500; text-align: left;
}
.mini-table td {
  padding: 10px 8px 10px 0; border-bottom: 1px solid #f2f6f9;
  color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.mini-table tr:last-child td { border-bottom: none; }
.mini-table .tag {
  display: inline-flex; align-items: center; gap: 5px;
  height: 22px; padding: 0 9px; border-radius: 11px;
  font-size: 11.5px; font-weight: 500;
}
.mini-table .tag::before {
  content: ""; width: 5px; height: 5px; border-radius: 50%;
  background: currentColor; opacity: .8;
}

.todo-table { min-width: 940px; }
.exc-table { min-width: 1080px; }
.exc-filter { margin-bottom: 0; border-bottom: 1px solid var(--line); padding: 13px 16px; }
.exc-filter .filter > label { color: var(--ink-3); font-size: 12.5px; white-space: nowrap; }
.exc-filter .spacer { flex: 1; }

.hour-chart { display: flex; align-items: flex-end; gap: 10px; padding: 18px 2px 0; }
.hour-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 0; }
.hour-col > b { font-size: 10.5px; color: var(--muted); font-weight: 500; }
.hour-track {
  width: 100%; max-width: 32px; height: 168px;
  display: flex; align-items: flex-end;
  border-radius: 6px; background: linear-gradient(to top, #f6fafc, #fff);
}
.hour-track i { display: block; width: 100%; min-height: 6px; border-radius: 6px 6px 3px 3px; background: linear-gradient(180deg, #63bce8, #1e98d7); }
.hour-col > span { font-size: 10.5px; color: var(--muted); white-space: nowrap; }

.people-list { display: grid; gap: 11px; padding: 4px 2px; }
.person-row { display: grid; grid-template-columns: 22px 54px minmax(0, 1fr) 42px; align-items: center; gap: 8px; font-size: 12px; }
.person-rank {
  width: 20px; height: 20px; border-radius: 6px;
  display: grid; place-items: center;
  background: #f2f7fb; color: var(--ink-3); font-size: 10.5px; font-weight: 600;
}
.person-rank.top { background: #eaf4fd; color: #146fa9; }
.person-name { color: var(--ink-2); }
.person-track { height: 8px; border-radius: 5px; background: #f1f6fa; overflow: hidden; }
.person-track i { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg, #8fd0ef, #1e98d7); }
.person-row b { text-align: right; font-size: 12px; font-weight: 600; color: var(--ink); }

.today-strip { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.today-mini { padding: 11px 13px; border: 1px solid var(--line); border-radius: 9px; background: #fbfdff; }
.today-mini span { display: block; font-size: 11.5px; color: var(--muted); margin-bottom: 3px; }
.today-mini b { font-size: 21px; font-weight: 700; color: var(--ink); line-height: 1.15; }
.today-mini em { font-style: normal; font-size: 10.5px; color: var(--muted); margin-left: 2px; }

/* ---------- 数据分析 ---------- */
.an-filter { margin-bottom: 16px; }
.an-chart-body { padding: 10px 14px 4px; }
.an-trend-chart { width: 100%; height: auto; display: block; }
.an-grid-line { stroke: #edf3f8; stroke-width: 1; }
.an-axis-text { fill: #8a9aab; font-size: 10px; }
.an-trend-path { fill: none; stroke: #1e98d7; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.an-line-dot { fill: #fff; stroke: #1e98d7; stroke-width: 2; }
table.table.an-table { min-width: 920px; }
.an-funnel { display: grid; gap: 10px; padding: 4px 0; }
.an-funnel-row { display: grid; grid-template-columns: 90px minmax(0, 1fr) 78px; gap: 12px; align-items: center; }
.an-funnel-name { font-size: 12px; color: var(--ink-3); }
.an-funnel-track { height: 24px; border-radius: 7px; background: #f1f6fa; overflow: hidden; }
.an-funnel-track i {
  display: flex; height: 100%; align-items: center; justify-content: flex-end;
  padding-right: 8px; border-radius: 7px; min-width: 42px;
  color: #fff; font-style: normal; font-size: 10.5px; font-weight: 600;
}
.an-funnel-count { text-align: right; font-size: 12px; font-weight: 600; color: var(--ink); }
@media (max-width: 640px) {
  .an-funnel-row { grid-template-columns: 74px minmax(0, 1fr) 60px; gap: 8px; }
  .an-funnel-name { font-size: 11px; }
}

@media (max-width: 1180px) {
  .dash-todo-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .dash-grid-2 { grid-template-columns: 1fr; }
  .today-strip { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .donut-wrap { justify-content: center; }
  .form-grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .form-grid.cols-4 .form-section-title { grid-column: span 2; }
  .form-grid.cols-4 .span-4 { grid-column: span 2; }
}
@media (max-width: 900px) {
  .dash-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .work-hero { flex-direction: column; align-items: flex-start; }
  .work-hero-right { justify-content: flex-start; }
  .dash-todo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dash-head-tools { justify-content: flex-start; }
}
@media (max-width: 640px) {
  .dash-todo-grid, .dash-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .donut-wrap { flex-direction: column; align-items: flex-start; }
  .hour-chart { gap: 4px; }
  .hour-col > span { font-size: 9px; }
  .today-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dash-scope { font-size: 11px; }
}
@media (max-width: 420px) {
  .dash-todo-grid, .dash-kpi-grid { grid-template-columns: 1fr; }
}

/* ---------- 总体说明 ---------- */
.doc { max-width: 1120px; }
.doc-card { padding: 26px 30px; }
.doc h1 { font-size: 22px; font-weight: 700; margin-bottom: 6px; }
.doc .doc-meta { color: var(--muted); font-size: 12px; margin-bottom: 22px; }
.doc h2 {
  display: flex; align-items: center; gap: 9px;
  font-size: 14.5px; font-weight: 650; color: var(--ink);
  margin: 24px 0 10px;
}
.doc h2::before { content: ""; width: 4px; height: 15px; border-radius: 2px; background: var(--blue-500); }
.doc p, .doc li { color: var(--ink-2); font-size: 13px; line-height: 1.9; }
.doc ul { padding-left: 4px; }
.doc ul li { position: relative; padding-left: 14px; }
.doc ul li::before { content: ""; position: absolute; left: 2px; top: 11px; width: 5px; height: 5px; border-radius: 50%; background: #b7d7ea; }
.doc .kv { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.doc .kv span {
  padding: 3px 10px; border-radius: 14px; font-size: 12px;
  background: #f2f8fc; color: #3d6f8f;
}
.doc .doc-img { margin-top: 20px; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.doc .doc-img img { width: 100%; display: block; }
.doc .flow { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.doc .flow span {
  padding: 5px 12px; border-radius: 7px; font-size: 12.5px;
  background: #f4f9fd; border: 1px solid #dcecf7; color: var(--ink-2);
}
.doc .flow i { color: #a8c4d6; font-style: normal; }

/* ---------- 货品新增页 ---------- */
.form-card { padding: 20px 22px 22px; }
.form-card .form-grid { gap: 16px 22px; }

/* ---------- 入库开单 ---------- */
.inb-form { padding: 20px 22px 16px; }
.inb-form .form-grid { gap: 14px 18px; }
.inb-lines-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 14px; margin: 20px 0 10px; flex-wrap: wrap;
}
.inb-lines-head h3 { font-size: 13.5px; font-weight: 650; color: var(--ink); }
.inb-lines-head span { display: block; margin-top: 3px; font-size: 11.5px; color: var(--muted); }
.inb-line-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
table.table.inb-lines-table { min-width: 1280px; }
.inb-lines-table th { white-space: nowrap; }
.inb-lines-table td { padding: 6px 5px; vertical-align: middle; white-space: nowrap; }
.inb-in {
  width: 100%; min-width: 58px; height: 30px; padding: 0 7px;
  border: 1px solid var(--line-2); border-radius: 6px;
  background: #fff; color: var(--ink); font-size: 12px; font-family: inherit; outline: none;
}
.inb-in:focus { border-color: var(--blue-500); box-shadow: 0 0 0 2px rgba(30, 152, 215, .12); }
.inb-in[readonly] { background: #f7fafc; color: var(--ink-3); }
.inb-lines-table input[type="date"] { min-width: 114px; }
.inb-line-empty {
  padding: 30px 20px; text-align: center;
  border: 1px dashed var(--line-2); border-radius: 10px;
  background: #fbfdff; color: var(--muted);
}
.inb-line-empty .ico { width: 30px; height: 30px; margin: 0 auto 8px; opacity: .45; }
.inb-line-empty > div { font-size: 13px; color: var(--ink-3); }
.inb-line-empty p { margin-top: 4px; font-size: 11.5px; }
.inb-summary {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end;
  gap: 8px 24px; padding: 14px 2px 2px;
  font-size: 12px; color: var(--ink-3);
}
.inb-summary b { margin-left: 3px; font-size: 13px; font-weight: 650; color: var(--ink); }
.inb-summary span:last-child b { color: var(--blue-700); }
table.table.inb-detail-table { min-width: 1100px; }
table.table.arrival-detail-table { min-width: 820px; }
table.table.arr-lines-table { min-width: 900px; }
table.table.outbound-detail-table { min-width: 820px; }
table.table.out-lines-table { min-width: 900px; }
.inb-detail-head {
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px; overflow: hidden;
  background: var(--line); border: 1px solid var(--line); border-radius: 10px;
}
.inb-detail-head.arrival { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.inb-detail-cell { min-width: 0; padding: 9px 12px; background: #fff; }
.inb-detail-cell .k { display: block; margin-bottom: 3px; font-size: 11px; color: var(--muted); }
.inb-detail-cell .v {
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-size: 12.5px; font-weight: 500; color: var(--ink-2);
}
.inb-detail-cell.wrap .v { white-space: normal; line-height: 1.55; }
.inb-detail-cell.wide { grid-column: span 2; }
.inb-detail-cell.full { grid-column: 1 / -1; }
.inb-detail-cell .mono { font-family: "SFMono-Regular", Consolas, monospace; font-size: 12px; }
.inb-detail-cell .tag {
  display: inline-flex; align-items: center; gap: 5px;
  height: 22px; padding: 0 9px; border-radius: 11px;
  font-size: 11.5px; font-weight: 500;
}
.inb-detail-cell .tag::before {
  content: ""; width: 5px; height: 5px; border-radius: 50%;
  background: currentColor; opacity: .8;
}
.inb-detail-lines { margin-top: 14px; }
.inb-detail-lines h3 { margin-bottom: 10px; font-size: 13px; font-weight: 650; color: var(--ink); }
.detail-tabs {
  display: flex; gap: 2px; margin: 0 0 14px;
  border-bottom: 1px solid var(--line);
}
.detail-tabs button {
  position: relative; display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px 9px; border: none; border-radius: 8px 8px 0 0;
  background: none; font-size: 13px; font-weight: 500; color: var(--ink-3); cursor: pointer;
}
.detail-tabs button:hover { color: var(--blue-700); background: var(--blue-50); }
.detail-tabs button.active { color: var(--blue-700); font-weight: 650; }
.detail-tabs button.active::after {
  content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px;
  height: 2px; border-radius: 2px; background: var(--blue-600);
}
.detail-tabs button em {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: #eef3f8; color: var(--ink-3); font-size: 11px; font-style: normal; font-weight: 600;
}
.detail-tabs button.active em { background: var(--blue-100); color: var(--blue-700); }
.dt-pane.hidden { display: none; }
.inb-op-summary {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px;
}
.inb-op-card {
  min-width: 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff;
}
.inb-op-card .k { display: block; margin-bottom: 4px; font-size: 11px; color: var(--muted); }
.inb-op-card .v {
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-size: 12.5px; font-weight: 500; color: var(--ink-2);
}
.inb-op-card .v b { color: var(--blue-700); }
.inb-op-table { min-width: 900px; }
.inb-op-table .op-type { font-weight: 600; color: var(--ink); white-space: nowrap; }
.inb-op-table .mono { font-family: "SFMono-Regular", Consolas, monospace; font-size: 12px; }
.ret-goods-head { display: flex; align-items: center; justify-content: space-between; margin: 16px 0 8px; }
.ret-goods-head h3 { font-size: 13px; font-weight: 650; color: var(--ink); }
.ret-goods-head span { font-size: 12px; color: var(--muted); }
.ret-goods-bar { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.ret-goods-bar label { font-size: 12px; color: var(--ink-3); }
.ret-goods-bar .select { width: 200px; }
.ret-goods-bar .ret-goods-combo { width: 280px; }
.ret-goods-bar .ret-goods-combo .input { width: 100%; }
.ret-goods-bar .input[type="number"] { width: 92px; }
.ret-goods-table { min-width: 720px; }
.ret-goods-table td { vertical-align: middle; }
.ret-goods-table .ret-qty { width: 78px; height: 30px; padding: 0 8px; text-align: right; }
.cat-lv1 { font-weight: 600; color: var(--ink); }
.cat-lv2 { position: relative; display: inline-block; padding-left: 18px; color: var(--ink-2); }
.cat-lv2::before { content: "└"; position: absolute; left: 2px; color: #b3c2d1; font-weight: 400; }
.ai-replenish-wrap { margin: 0; }
.ai-replenish-frame {
  display: block; width: 100%; height: calc(100vh - 112px); min-height: 680px;
  border: 0; border-radius: 10px; background: transparent;
}
@media (max-width: 900px) {
  .inb-op-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1180px) {
  .inb-detail-head { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .inb-detail-head.arrival { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .inb-detail-head { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .inb-detail-head, .inb-detail-head.arrival { grid-template-columns: 1fr; }
  .inb-detail-cell.wide { grid-column: span 1; }
}
table.table.inb-receive-table { min-width: 640px; }
.inb-receive-table td { vertical-align: middle; }
.inb-putaway-items {
  margin-top: 14px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden;
}
.inb-putaway-row {
  display: grid; grid-template-columns: 96px minmax(0, 1fr) 150px 88px 24px;
  align-items: center; gap: 10px;
  padding: 9px 12px; border-bottom: 1px solid var(--line);
  font-size: 12px; color: var(--ink-2);
}
.inb-putaway-row:last-child { border-bottom: none; }
.inb-putaway-row em { font-style: normal; font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.inb-putaway-row b { text-align: right; color: var(--ink); }
.inb-putaway-qty { height: 30px; padding: 0 8px; text-align: right; }
.inb-putaway-unit { font-size: 11.5px; color: var(--muted); }
.inb-putaway-hint { margin-top: 8px; font-size: 11.5px; line-height: 1.55; color: var(--muted); }
.spec-group { padding: 9px 0 4px; border-bottom: 1px dashed var(--line); }
.spec-group:last-child { border-bottom: none; }
.spec-group > b { display: block; margin-bottom: 5px; font-size: 12px; font-weight: 600; color: var(--ink-2); }
.spec-tip {
  padding: 11px 13px; border: 1px dashed var(--line-2); border-radius: 8px;
  background: #fbfdff; color: var(--muted); font-size: 12px;
}
.batch-goods-list {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
  max-height: 340px; overflow-y: auto; padding: 2px;
}
.batch-goods-item {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 11px; border: 1px solid var(--line); border-radius: 8px;
  font-size: 12px; cursor: pointer;
}
.batch-goods-item:hover { border-color: #b9dcf3; background: var(--blue-50); }
.batch-goods-item input { accent-color: var(--blue-500); }
.batch-goods-item b { font-weight: 600; color: var(--ink-2); }
.batch-goods-item em { margin-left: auto; font-style: normal; font-size: 10.5px; color: var(--muted); }
.gp-toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 11px; }
.gp-search { position: relative; flex: 1; }
.gp-search .ico { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); width: 14px; height: 14px; color: var(--muted); }
.gp-search .input { width: 100%; height: 34px; padding-left: 31px; }
.gp-count { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.gp-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px; max-height: 350px; overflow-y: auto; padding: 1px;
}
.gp-grid.compact { max-height: 218px; }
.gp-card {
  position: relative; display: flex; align-items: flex-start; gap: 10px;
  padding: 12px; border: 1px solid var(--line); border-radius: 10px;
  background: #fff; cursor: pointer;
  transition: border-color .15s, background .15s, box-shadow .15s;
}
.gp-card:hover { border-color: #b9dcf3; background: #fbfdff; }
.gp-card.selected {
  border-color: var(--blue-500); background: #f4faff;
  box-shadow: 0 0 0 3px rgba(30, 152, 215, .10);
}
.gp-card input { position: absolute; opacity: 0; pointer-events: none; }
.gp-checkmark {
  position: absolute; right: 10px; top: 10px;
  width: 16px; height: 16px; border-radius: 50%;
  border: 1px solid var(--line-2); background: #fff;
  display: grid; place-items: center; color: #fff;
}
.gp-card.selected .gp-checkmark { border-color: var(--blue-500); background: var(--blue-500); }
.gp-checkmark::after {
  content: ""; width: 6px; height: 3px; margin-top: -2px;
  border-left: 1.8px solid currentColor; border-bottom: 1.8px solid currentColor;
  transform: rotate(-45deg); opacity: 0;
}
.gp-card.selected .gp-checkmark::after { opacity: 1; }
.gp-icon {
  width: 34px; height: 34px; border-radius: 9px;
  display: grid; place-items: center; flex: none;
  background: var(--blue-50); color: var(--blue-600);
}
.gp-icon .ico { width: 16px; height: 16px; }
.gp-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding-right: 14px; }
.gp-main b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; font-weight: 600; color: var(--ink); }
.gp-main em { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-style: normal; font-size: 10.5px; color: var(--muted); }
.gp-main i { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-style: normal; font-size: 10.5px; color: var(--ink-3); }
.split-title {
  display: flex; align-items: center; justify-content: space-between;
  margin: 22px 0 10px;
}
.split-title h3 { font-size: 13.5px; font-weight: 650; color: var(--ink); }
.page-actions {
  display: flex; justify-content: flex-end; gap: 10px;
  margin-top: 18px;
}

/* ---------- 权限树 ---------- */
.perm-box {
  border: 1px solid var(--line-2); border-radius: 8px;
  padding: 12px 14px; max-height: 240px; overflow-y: auto;
  background: #fbfdfe;
}
.perm-group { margin-bottom: 10px; }
.perm-group:last-child { margin-bottom: 0; }
.perm-parent { display: flex; align-items: center; gap: 7px; font-size: 12.8px; font-weight: 600; color: var(--ink-2); }
.perm-children { display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 7px 0 0 22px; }
.perm-children .check { font-weight: 400; color: var(--ink-3); }
.perm-buttons { display: flex; flex-wrap: wrap; gap: 8px 14px; padding: 6px 0 0 42px; }
.perm-buttons .check { font-size: 12px; color: var(--ink-3); }

/* ---------- 日期快捷键（演示用） ---------- */
.range-presets { display: flex; gap: 6px; }
.range-presets button {
  border: 1px solid var(--line-2); background: #fff; border-radius: 6px;
  height: 34px; padding: 0 9px; font-size: 12px; color: var(--ink-3); cursor: pointer;
}
.range-presets button:hover { border-color: var(--blue-500); color: var(--blue-700); }

/* ---------- 库位可视化 ---------- */
.map-legend { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--ink-3); }
.map-legend span { display: inline-flex; align-items: center; gap: 6px; }
.map-legend .lg { width: 10px; height: 10px; border-radius: 3px; border: 1px solid #c9dfef; background: #fff; }
.map-legend .lg.used { background: #e8f4fd; border-color: #8fc4e8; }
.map-legend .lg.lock { background: #fdf3df; border-color: #e6bf76; }
.map-legend .lg.off { background: #f2f5f8; border-color: #d5dfe8; }
.map-legend .lg.free { background: #fff; border-color: #c9dfef; }

.map-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; margin-bottom: 14px; }
.map-stat { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 12px 16px; box-shadow: var(--shadow-sm); }
.map-stat span { display: block; font-size: 11.5px; color: var(--muted); margin-bottom: 4px; }
.map-stat b { font-size: 21px; font-weight: 700; color: var(--ink); line-height: 1.2; }
.map-stat b small { font-size: 11px; color: var(--muted); font-weight: 400; margin-left: 2px; }
.map-stat.used b { color: #0b6fa8; }
.map-stat.free b { color: #2e9e6b; }
.map-stat.lock b { color: #b97614; }
.map-stat.off b { color: #8a9aab; }

.map-wrap { display: grid; gap: 14px; }
.map-zone { padding: 16px 18px; }
.map-zone-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.map-zone-head h3 { font-size: 13.5px; font-weight: 650; color: var(--ink); }
.map-zone-head span { font-size: 11.5px; color: var(--muted); }
.map-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 10px; }
.slot-tile {
  position: relative; display: flex; flex-direction: column; gap: 2px;
  min-height: 82px; padding: 11px 12px;
  border: 1px solid #dbe7f1; border-radius: 9px; background: #fff;
  text-align: left; font-family: inherit; cursor: pointer;
  transition: transform .12s, box-shadow .12s;
}
.slot-tile:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(16, 42, 67, .10); }
.slot-tile b { font-size: 13px; color: var(--ink); }
.slot-tile .qty { font-size: 12px; color: var(--ink-2); }
.slot-tile i { font-style: normal; font-size: 11px; color: var(--muted); }
.slot-tile .dot { position: absolute; right: 10px; top: 10px; width: 7px; height: 7px; border-radius: 50%; background: #c3d2df; }
.slot-tile.used { background: #f2f9fe; border-color: #b9dcf3; }
.slot-tile.used .dot { background: #1e98d7; }
.slot-tile.lock { background: #fdf7ea; border-color: #ecd4a4; }
.slot-tile.lock .dot { background: #d29a35; }
.slot-tile.free .dot { background: #9fb3c4; }
.slot-tile.off { background: #f4f6f8; border-style: dashed; border-color: #d7e0e8; cursor: default; }
.slot-tile.off b, .slot-tile.off .qty, .slot-tile.off i { color: #a6b4c2; }
.slot-tile.off .dot { background: #c9d4de; }
.table.table-narrow { min-width: 0; }

/* ---------- 树形表格 ---------- */
.tree-cell { display: flex; align-items: center; gap: 6px; text-align: left; }
.tree-cell .tree-guide { color: #c2cfdb; }
.tree-cell .tree-toggle {
  width: 16px; height: 16px; flex: none; border-radius: 4px;
  display: grid; place-items: center; color: #8a9aab; cursor: pointer;
}
.tree-cell .tree-toggle:hover { background: #eef4f9; color: var(--blue-700); }
.tree-cell .tree-toggle svg { width: 10px; height: 10px; transition: transform .15s; }
.tree-cell .tree-toggle.closed svg { transform: rotate(-90deg); }
.tree-cell .tree-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.table tr.row-hidden { display: none; }

/* ---------- 详情列表 ---------- */
.detail-list { display: grid; gap: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.detail-list .dl-row { display: grid; grid-template-columns: 118px 1fr; border-bottom: 1px solid var(--line); }
.detail-list .dl-row:last-child { border-bottom: none; }
.detail-list .dl-k { padding: 10px 12px; background: #f8fbfd; color: var(--ink-3); font-size: 12.5px; }
.detail-list .dl-v { padding: 10px 12px; color: var(--ink); font-size: 12.8px; word-break: break-all; white-space: pre-wrap; }
.detail-list .dl-v.mono { font-family: "SFMono-Regular", Consolas, monospace; font-size: 12px; color: #335468; }

/* ---------- 仓内策略 · AI模块 ---------- */
.ai-summary-chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 30px; padding: 0 12px; border-radius: 16px;
  border: 1px solid #cfe8f7; background: #eef8ff; color: #2a6d96;
  font-size: 12px; white-space: nowrap;
}
.ai-summary-chip .ico { width: 14px; height: 14px; }
.ai-summary-chip b { color: #0b6fa8; font-weight: 700; }

.ai-banner {
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 22px 26px; margin-bottom: 16px; border-radius: 12px;
  background: linear-gradient(118deg, #0b3552 0%, #0b6fa8 62%, #1e98d7 100%);
  color: #fff; box-shadow: 0 12px 30px rgba(11, 75, 114, .18);
}
.ai-banner::before, .ai-banner::after {
  content: ""; position: absolute; border-radius: 50%;
  background: rgba(255, 255, 255, .07); pointer-events: none;
}
.ai-banner::before { width: 260px; height: 260px; right: 130px; top: -170px; }
.ai-banner::after { width: 180px; height: 180px; left: -90px; bottom: -130px; }
.ai-banner-copy { position: relative; z-index: 1; min-width: 0; }
.ai-kicker {
  display: inline-block; margin-bottom: 7px;
  color: rgba(255, 255, 255, .62); font-size: 10.5px; font-weight: 600;
  letter-spacing: 2px; text-transform: uppercase;
}
.ai-banner h2 { color: #fff; font-size: 19px; font-weight: 700; letter-spacing: .2px; }
.ai-banner p { margin-top: 7px; color: rgba(255, 255, 255, .75); font-size: 12.5px; line-height: 1.7; }
.ai-banner-stat {
  position: relative; z-index: 1; flex: none; min-width: 138px;
  padding: 12px 18px; border-radius: 10px; text-align: center;
  border: 1px solid rgba(255, 255, 255, .22); background: rgba(255, 255, 255, .11);
}
.ai-banner-stat span { display: block; color: rgba(255, 255, 255, .7); font-size: 11.5px; }
.ai-banner-stat b { display: block; color: #fff; font-size: 28px; font-weight: 750; line-height: 1.18; }
.ai-banner-stat b em { margin-left: 2px; font-style: normal; font-size: 13px; font-weight: 500; opacity: .62; }
.ai-banner-stat small { display: block; color: rgba(255, 255, 255, .6); font-size: 11px; }

.ai-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.ai-card {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; min-height: 172px;
  padding: 16px; border: 1px solid var(--line); border-radius: 11px;
  background: #fff; box-shadow: var(--shadow-sm);
  transition: border-color .16s, box-shadow .16s, transform .16s;
}
.ai-card::after {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px;
  background: transparent; transition: background .16s;
}
.ai-card:hover { border-color: #c6dfef; box-shadow: 0 8px 20px rgba(16, 42, 67, .08); transform: translateY(-1px); }
.ai-card.on { border-color: #b9dcf3; background: linear-gradient(180deg, #fff 0%, #f9fcff 100%); }
.ai-card.on::after { background: linear-gradient(90deg, #1e98d7, #62c7eb); }
.ai-card-head { display: flex; align-items: flex-start; gap: 11px; }
.ai-icon { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; flex: none; }
.ai-icon .ico { width: 19px; height: 19px; }
.ai-icon.tone-blue { background: #eaf4fd; color: #0b6fa8; }
.ai-icon.tone-violet { background: #f2edfc; color: #6d4eab; }
.ai-icon.tone-green { background: #eaf7f0; color: #237a51; }
.ai-icon.tone-amber { background: #fdf5e7; color: #9a6812; }
.ai-icon.tone-red { background: #fdeeee; color: #b63c3c; }
.ai-card-title { flex: 1; min-width: 0; padding-top: 1px; }
.ai-card-title h3 { color: var(--ink); font-size: 14px; font-weight: 650; line-height: 1.35; }
.ai-card-title span { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.ai-status {
  flex: none; display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 8px; border-radius: 10px;
  background: #f2f5f8; color: #7d8d9d; font-size: 10.5px; font-weight: 500;
}
.ai-status::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: .8; }
.ai-status.on { background: #eaf7f0; color: #237a51; }
.ai-desc { flex: 1; margin: 13px 0 14px; color: var(--ink-3); font-size: 12px; line-height: 1.7; }
.ai-card-foot {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 11px; border-top: 1px solid #eef4f8;
  color: var(--ink-2); font-size: 12px;
}
.ai-switch {
  position: relative; width: 42px; height: 24px; padding: 0;
  border: none; border-radius: 999px; background: #d6e0e9;
  cursor: pointer; transition: background .18s;
}
.ai-switch i {
  position: absolute; left: 3px; top: 3px;
  width: 18px; height: 18px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 3px rgba(16, 42, 67, .25);
  transition: transform .18s;
}
.ai-switch[aria-checked="true"] { background: var(--blue-500); }
.ai-switch[aria-checked="true"] i { transform: translateX(18px); }
.ai-switch:focus-visible { outline: 3px solid rgba(30, 152, 215, .22); outline-offset: 2px; }

@media (max-width: 1180px) {
  .ai-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .ai-grid { grid-template-columns: 1fr; }
  .ai-banner { flex-direction: column; align-items: flex-start; padding: 20px; }
  .ai-banner-stat { width: 100%; text-align: left; }
}

/* ---------- 开放平台 · 关仓协同 ---------- */
.cc-shell { overflow: hidden; }
.cc-hero {
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 20px 24px; color: #fff;
  background: linear-gradient(112deg, #0b3552 0%, #0b6fa8 64%, #1a8aa8 100%);
}
.cc-hero::before, .cc-hero::after {
  content: ""; position: absolute; border-radius: 50%;
  background: rgba(255, 255, 255, .07); pointer-events: none;
}
.cc-hero::before { width: 240px; height: 240px; right: 120px; top: -160px; }
.cc-hero::after { width: 160px; height: 160px; left: -70px; bottom: -120px; }
.cc-hero-main { position: relative; z-index: 1; display: flex; align-items: center; gap: 14px; min-width: 0; }
.cc-hero-icon {
  width: 46px; height: 46px; flex: none; border-radius: 12px;
  display: grid; place-items: center;
  border: 1px solid rgba(255, 255, 255, .2); background: rgba(255, 255, 255, .13);
}
.cc-hero-icon .ico { width: 22px; height: 22px; }
.cc-hero-copy { min-width: 0; }
.cc-kicker {
  display: inline-block; margin-bottom: 5px;
  color: rgba(255, 255, 255, .62); font-size: 10.5px; font-weight: 600;
  letter-spacing: 2px; text-transform: uppercase;
}
.cc-hero-copy h2 { color: #fff; font-size: 19px; font-weight: 700; letter-spacing: .2px; }
.cc-hero-copy p { margin-top: 6px; color: rgba(255, 255, 255, .74); font-size: 12.5px; line-height: 1.7; }
.cc-stat {
  position: relative; z-index: 1; flex: none; min-width: 124px;
  padding: 10px 16px; text-align: center; border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, .22); background: rgba(255, 255, 255, .11);
}
.cc-stat span { display: block; color: rgba(255, 255, 255, .7); font-size: 11.5px; }
.cc-stat b { display: block; color: #fff; font-size: 27px; font-weight: 750; line-height: 1.18; }
.cc-stat b em { margin-left: 2px; font-style: normal; font-size: 13px; font-weight: 500; opacity: .62; }
.cc-stat small { display: block; color: rgba(255, 255, 255, .6); font-size: 11px; }

.cc-list-head {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 13px 20px; border-bottom: 1px solid var(--line); background: #fbfdfe;
}
.cc-list-head > div { display: flex; align-items: baseline; gap: 10px; }
.cc-list-head h3 { color: var(--ink); font-size: 13.5px; font-weight: 650; }
.cc-list-head span { color: var(--muted); font-size: 11.5px; }
.cc-row {
  display: grid; grid-template-columns: 34px 38px minmax(0, 1fr) 72px 42px;
  align-items: center; gap: 14px; padding: 13px 20px;
  border-bottom: 1px solid #eff4f8;
  transition: background .15s;
}
.cc-row:last-child { border-bottom: 0; }
.cc-row:hover { background: #f8fbfe; }
.cc-row.on { background: linear-gradient(90deg, #fbfeff 0%, #f6fcff 100%); }
.cc-num { color: #a4b4c3; font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cc-row.on .cc-num { color: var(--blue-600); }
.cc-icon {
  width: 36px; height: 36px; border-radius: 10px;
  display: grid; place-items: center; flex: none;
}
.cc-icon .ico { width: 17px; height: 17px; }
.cc-icon.tone-blue { background: #eaf4fd; color: #0b6fa8; }
.cc-icon.tone-violet { background: #f2edfc; color: #6d4eab; }
.cc-icon.tone-green { background: #eaf7f0; color: #237a51; }
.cc-icon.tone-amber { background: #fdf5e7; color: #9a6812; }
.cc-icon.tone-red { background: #fdeeee; color: #b63c3c; }
.cc-main { min-width: 0; }
.cc-main b { display: block; color: var(--ink); font-size: 13px; font-weight: 600; line-height: 1.45; }
.cc-main span { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.cc-state {
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  padding: 3px 8px; border-radius: 10px;
  background: #f2f5f8; color: #7d8d9d; font-size: 10.5px; font-weight: 500;
}
.cc-state::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: .8; }
.cc-state.on { background: #eaf7f0; color: #237a51; }
.cc-switch {
  position: relative; width: 40px; height: 22px; padding: 0;
  border: none; border-radius: 999px; background: #d6e0e9;
  cursor: pointer; transition: background .18s;
}
.cc-switch i {
  position: absolute; left: 3px; top: 3px;
  width: 16px; height: 16px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 3px rgba(16, 42, 67, .25);
  transition: transform .18s;
}
.cc-switch[aria-checked="true"] { background: var(--blue-500); }
.cc-switch[aria-checked="true"] i { transform: translateX(18px); }
.cc-switch:focus-visible { outline: 3px solid rgba(30, 152, 215, .22); outline-offset: 2px; }

.cc-config { border-bottom: 1px solid var(--line); }
.cc-config-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px 18px; flex-wrap: wrap;
  padding: 14px 20px 10px;
}
.cc-config-title h3 { color: var(--ink); font-size: 13.5px; font-weight: 650; }
.cc-config-title span { display: block; margin-top: 3px; color: var(--muted); font-size: 11.5px; }
.cc-config-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cc-conn {
  display: inline-flex; align-items: center; gap: 5px;
  height: 26px; padding: 0 9px; border-radius: 13px;
  background: #f2f5f8; color: #7d8d9d; font-size: 11px; white-space: nowrap;
}
.cc-conn i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.cc-conn.on { background: #eaf7f0; color: #237a51; }
.cc-config-body { padding: 0 20px 13px; }
.cc-config-body .form-grid { gap: 12px 16px; }
.cc-config-foot {
  display: flex; justify-content: flex-end; gap: 16px; flex-wrap: wrap;
  padding-top: 10px; color: var(--muted); font-size: 11px;
}

@media (max-width: 640px) {
  .cc-hero { flex-direction: column; align-items: flex-start; padding: 18px; }
  .cc-stat { width: 100%; text-align: left; }
  .cc-config-head { flex-direction: column; align-items: flex-start; padding: 14px; }
  .cc-config-actions { width: 100%; }
  .cc-config-body { padding: 0 14px 12px; }
  .cc-config-foot { flex-direction: column; align-items: flex-start; gap: 4px; }
  .cc-list-head { padding: 12px 14px; }
  .cc-row { grid-template-columns: 28px 34px minmax(0, 1fr) 40px; gap: 10px; padding: 12px 14px; }
  .cc-state { display: none; }
}

/* ---------- 响应式 ---------- */
@media (max-width: 1180px) {
  .home-grid { grid-template-columns: 1fr; }
  .quick-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  :root { --sidebar-w: 0px; }
  .menu-btn { display: inline-flex; }
  .sidebar { width: 184px; transform: translateX(-100%); transition: transform .2s; }
  .sidebar.show { transform: none; width: 184px; box-shadow: var(--shadow-md); }
  .content { margin-left: 0; padding-left: 16px; padding-right: 16px; }
  .topbar { padding: 0 12px; gap: 10px; }
  .brand { min-width: 0; }
  .brand-name small, .wh-switch > span, .user-chip div span { display: none; }
}
@media (max-width: 640px) {
  .brand-name { display: none; }
  .user-chip { display: none; }
  .wh-switch .select { min-width: 104px; }
  .filter-bar, .toolbar { padding: 10px 12px; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .span-2, .form-grid .span-3, .form-section-title { grid-column: span 1; }
  .form-grid.cols-3 { grid-template-columns: 1fr; }
  .form-grid.cols-4 { grid-template-columns: 1fr; }
  .form-grid.cols-4 .span-2, .form-grid.cols-4 .span-4, .form-grid.cols-4 .form-section-title { grid-column: span 1; }
  .batch-goods-list { grid-template-columns: 1fr; }
  .gp-grid { grid-template-columns: 1fr; }
  .quick-grid { grid-template-columns: 1fr; }
  .modal { width: 100%; }
  .pager .goto, .pager .page-size { display: none; }
}

/* ---------- 动画 ---------- */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes popIn { from { opacity: 0; transform: translateY(8px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes toastIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(8px); } }

/* ---------- AI 入库 ---------- */
.btn-ai { background: linear-gradient(135deg, #4f7cf7 0%, #1aa7d8 100%); border-color: transparent; }
.btn-ai:hover { background: linear-gradient(135deg, #4472ee 0%, #1699c8 100%); border-color: transparent; color: #fff; }
.modal-foot .btn:disabled { opacity: .55; cursor: not-allowed; }

.ai-hero { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 1px solid #d8e7f5; border-radius: 10px; background: linear-gradient(120deg, #f2f9ff, #eef4ff 55%, #f6fbff); margin-bottom: 14px; }
.ai-hero-ico { flex: 0 0 44px; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #4f7cf7, #1aa7d8); box-shadow: 0 6px 16px rgba(46, 120, 220, .25); }
.ai-hero-ico .ico { width: 22px; height: 22px; }
.ai-hero-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.ai-hero-txt b { font-size: 14px; color: var(--blue-900); }
.ai-hero-txt span { font-size: 12px; color: var(--ink-3); line-height: 1.6; }
.ai-formats { display: flex; gap: 6px; flex: 0 0 auto; }
.ai-formats span { font-size: 11px; color: #3d7db2; background: #fff; border: 1px solid #d8e7f5; border-radius: 5px; padding: 2px 7px; }

.ai-drop { position: relative; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 34px 20px; border: 1.5px dashed #b9d3e8; border-radius: 12px; background: #fbfdff; cursor: pointer; transition: all .18s ease; }
.ai-drop:hover, .ai-drop.drag { border-color: var(--blue-500); background: var(--blue-50); box-shadow: inset 0 0 0 3px rgba(30, 152, 215, .06); }
.ai-drop b { font-size: 13.5px; color: var(--ink); }
.ai-drop > span { font-size: 12px; color: var(--muted); }
.ai-drop-ico { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; background: #eaf5fd; color: var(--blue-600); }
.ai-drop-ico .ico { width: 20px; height: 20px; }
.ai-drop.has { flex-direction: row; align-items: center; padding: 12px 14px; border-style: solid; }
.ai-thumb { position: relative; flex: 0 0 64px; width: 64px; height: 64px; border-radius: 8px; overflow: hidden; background: #eef5fb; display: grid; place-items: center; color: var(--blue-700); border: 1px solid var(--line); }
.ai-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ai-thumb .ico { width: 24px; height: 24px; }
.ai-thumb em { font-size: 10px; font-weight: 600; }
.ai-scan { position: absolute; left: 0; right: 0; top: 0; height: 2px; background: linear-gradient(90deg, transparent, #37c0f5, transparent); box-shadow: 0 0 8px #37c0f5; animation: aiScan 1.5s ease-in-out infinite; }
@keyframes aiScan { 0% { transform: translateY(2px); opacity: .9; } 50% { transform: translateY(56px); opacity: .6; } 100% { transform: translateY(2px); opacity: .9; } }
.ai-file-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; text-align: left; }
.ai-file-info b { font-size: 13px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ai-file-info span { font-size: 11.5px; color: var(--muted); }
.ai-file-info em { font-style: normal; font-size: 11.5px; color: var(--blue-700); }
.ai-repick { flex: 0 0 auto; font-size: 12px; color: var(--blue-700); }

.ai-steps { margin-top: 14px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 10px; background: #fff; display: flex; flex-direction: column; gap: 10px; }
.ai-step { display: flex; align-items: center; gap: 10px; font-size: 12.5px; color: var(--ink-3); }
.ai-step i { flex: 0 0 20px; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 11px; background: #eef3f8; color: #8496a8; }
.ai-step em { margin-left: auto; font-style: normal; font-size: 11.5px; color: var(--muted); }
.ai-step.active { color: var(--ink); font-weight: 600; }
.ai-step.active i { background: #e3f3fd; color: var(--blue-700); }
.ai-step.done { color: var(--ink-2); }
.ai-step.done i { background: #e6f7ef; color: var(--green); }
.ai-step.done em { color: var(--green); }
.ai-spin { width: 12px; height: 12px; border-radius: 50%; border: 2px solid #bcd9ec; border-top-color: var(--blue-600); animation: aiSpin .8s linear infinite; }
@keyframes aiSpin { to { transform: rotate(360deg); } }

.ai-tip { margin-top: 12px; padding: 10px 14px; border-radius: 8px; background: #f7fbff; border: 1px solid #e2eef8; font-size: 12px; color: var(--ink-3); line-height: 1.7; }

.ai-result-bar { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 9px; background: #f0faf5; border: 1px solid #cfeedf; margin-bottom: 14px; font-size: 12.3px; color: #2c6b4c; }
.ai-result-bar .ico { width: 16px; height: 16px; color: var(--green); }
.ai-result-bar b { color: #1d5c3e; white-space: nowrap; }
.ai-result-bar .sp { flex: 1; }
.ai-result-bar span { color: #5c7f6c; }

.ai-lines-table { min-width: 980px; }
.ai-lines-table td { padding: 6px 5px; vertical-align: middle; white-space: nowrap; }
.ai-lines-table .select { min-width: 150px; }
.ai-lines-table .inb-in { min-width: 64px; }
.ai-tag { display: inline-block; margin-left: 8px; padding: 0 6px; height: 16px; line-height: 16px; border-radius: 4px; font-size: 10px; font-weight: 600; color: #fff; background: linear-gradient(135deg, #4f7cf7, #1aa7d8); vertical-align: 1px; }
.ai-footnote { margin-top: 12px; font-size: 11.8px; color: var(--muted); line-height: 1.8; }

/* ---------- 波次开单：出库单选择 ---------- */
.wave-pick-bar { display: flex; align-items: center; gap: 10px; padding: 2px 0 0; flex-wrap: wrap; }
.wave-pick-bar .input { width: 150px; height: 32px; }
.wave-pick-bar .select { width: 118px; height: 32px; padding: 0 24px 0 9px; font-size: 12px; }
.wave-pick-stat { margin-left: auto; font-size: 12px; color: var(--ink-3); }
.wave-pick-stat b { color: var(--blue-700); font-weight: 700; }
.wave-pick-stat [data-pick-group] { color: var(--blue-800); }
.wave-pick-tools { display: flex; gap: 14px; font-size: 12px; }
.wave-pick-tools a { color: var(--blue-700); }
.wave-pick-scroll { margin-top: 8px; border: 1px solid var(--line); border-radius: 8px; max-height: 320px; overflow: auto; background: #fff; }
.wave-pick-table { width: 100%; min-width: 1080px; border-collapse: collapse; font-size: 12px; }
.wave-pick-table th { position: sticky; top: 0; z-index: 1; background: #f7fafc; color: var(--ink-3); font-weight: 600; text-align: left; padding: 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.wave-pick-table td { padding: 7px 8px; border-bottom: 1px solid #f1f5f9; color: var(--ink-2); white-space: nowrap; }
.wave-pick-table tbody tr:last-child td { border-bottom: 0; }
.wave-pick-table tbody tr:hover td { background: #f7fbff; }
.wave-pick-table tbody tr.is-on td { background: #eef8fe; }
.wave-pick-table tbody tr.is-locked td { opacity: .42; }
.wave-pick-table .num { font-variant-numeric: tabular-nums; }
.wave-pick-table .tag-wave { display: inline-block; padding: 0 6px; height: 18px; line-height: 18px; border-radius: 4px; background: #eef3f8; color: var(--ink-3); font-size: 11px; }
.wave-pick-table td .muted { color: var(--muted); }

/* ---------- 波次详情：出库单明细 ---------- */
.wave-detail-lines { margin-top: 16px; }
.wave-detail-lines h3 { font-size: 13px; font-weight: 600; color: var(--ink-2); margin: 0 0 8px; }
.wave-detail-table { min-width: 1080px; }
.wave-detail-table td { padding: 7px 8px; vertical-align: top; }
.wave-detail-table td.spec { white-space: normal; }
.wave-detail-table tbody tr:hover td { background: #f7fbff; }

/* ---------- 波次单打印（A4） ---------- */
.print-preview { background: #e8edf2; border-radius: 8px; padding: 16px; max-height: calc(100vh - 250px); overflow: auto; }
.wave-sheet {
  width: 210mm; min-height: 297mm; box-sizing: border-box; margin: 0 auto 18px;
  background: #fff; color: #1f2d3d; padding: 13mm 12mm 12mm;
  font-size: 11px; line-height: 1.5;
  box-shadow: 0 6px 24px rgba(10, 40, 80, .18);
}
.wave-sheet:last-child { margin-bottom: 0; }
.ws-head { display: flex; align-items: flex-end; gap: 12px; padding-bottom: 8px; border-bottom: 2px solid #0b6fa8; }
.ws-brand b { display: block; font-size: 14px; color: #0b6fa8; letter-spacing: .5px; }
.ws-brand span { font-size: 8px; color: #8a9aab; letter-spacing: 1px; }
.ws-title { flex: 1; text-align: center; }
.ws-title h2 { margin: 0; font-size: 20px; letter-spacing: 6px; font-weight: 700; }
.ws-title em { font-style: normal; font-size: 8px; color: #8a9aab; letter-spacing: 2.5px; }
.ws-no { text-align: right; }
.ws-no span { display: block; font-size: 9px; color: #8a9aab; }
.ws-no b { font-size: 12px; font-family: ui-monospace, Menlo, Consolas, monospace; }
.ws-meta { display: flex; flex-wrap: wrap; gap: 6px 18px; padding: 8px 2px 10px; font-size: 10.5px; border-bottom: 1px solid #d7e1ea; }
.ws-meta span { color: #8a9aab; margin-right: 4px; }
.ws-meta b { color: #1f2d3d; font-weight: 600; }
.ws-table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 10px; }
.ws-table th, .ws-table td { border: 1px solid #c9d6e2; padding: 4px 5px; text-align: left; vertical-align: top; }
.ws-table th { background: #eef4f9; font-weight: 600; color: #33475b; white-space: nowrap; }
.ws-table td.mono { font-family: ui-monospace, Menlo, Consolas, monospace; }
.ws-table td.spec { white-space: normal; }
.ws-table td.num { text-align: right; }
.ws-table td.check { text-align: center; color: #8a9aab; }
.ws-empty { margin-top: 10px; padding: 24px; border: 1px dashed #c9d6e2; text-align: center; color: #8a9aab; }
.ws-foot { display: flex; justify-content: space-between; align-items: flex-end; margin-top: 16px; font-size: 10px; color: #55687a; }
.ws-sign { letter-spacing: 1px; }
.ws-page { color: #8a9aab; }

@media print {
  @page { size: A4 portrait; margin: 0; }
  body { background: #fff; overflow: visible; }
  body > * { display: none !important; }
  .modal-mask { display: block !important; position: static !important; background: none !important; padding: 0 !important; inset: auto !important; animation: none !important; opacity: 1 !important; }
  .modal { width: auto !important; max-width: none !important; max-height: none !important; border-radius: 0 !important; box-shadow: none !important; animation: none !important; }
  .modal-head, .modal-foot { display: none !important; }
  .modal-body { padding: 0 !important; overflow: visible !important; }
  .print-preview { background: none !important; padding: 0 !important; max-height: none !important; overflow: visible !important; }
  .wave-sheet { margin: 0 !important; box-shadow: none !important; min-height: 296mm; page-break-after: always; break-after: page; }
  .wave-sheet:last-child { page-break-after: auto; break-after: auto; }
}

/* ---------- 出库单：新建波次 ---------- */
.wave-create { display: flex; flex-direction: column; gap: 16px; padding: 8px 6px; }
.wave-create .wc-row { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--ink-2); flex-wrap: wrap; }
.wave-create .wc-row > span { color: var(--ink-3); }
.wave-create .wc-row > b { color: var(--ink); font-size: 14px; }
.wave-create .wc-row .input { width: 200px; }
.wave-create .wc-row .check { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); }
.wave-create [data-wc-count] { color: var(--blue-700); font-size: 18px; }
.wave-create-inline { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 10px 22px; border-top: 1px dashed var(--line); margin-top: 12px; padding-top: 12px; }
.wave-create-inline .wc-row { flex-wrap: nowrap; white-space: nowrap; }

/* ---------- 分拣单：波次联想 ---------- */
.combo { position: relative; }
.combo-list { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 6; background: #fff; border: 1px solid var(--line-2); border-radius: 8px; box-shadow: var(--shadow-md); max-height: 240px; overflow: auto; }
.combo-item { display: flex; align-items: baseline; gap: 10px; padding: 8px 10px; cursor: pointer; border-bottom: 1px solid #f2f6f9; }
.combo-item:last-child { border-bottom: 0; }
.combo-item:hover, .combo-item.on { background: var(--blue-50); }
.combo-item b { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12.5px; color: var(--ink); white-space: nowrap; }
.combo-item span { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.combo-empty { padding: 10px 12px; font-size: 12px; color: var(--muted); }

/* ---------- 波次单：条码与库位明细 ---------- */
.ws-no .ws-barcode { display: block; width: 52mm; height: 14mm; margin: 3px 0 0 auto; }
.ws-table td.slots { white-space: normal; line-height: 1.55; }
.ws-short { color: #b97614; }

/* ---------- 波次单：页眉条码与页脚调整 ---------- */
.ws-code { text-align: right; }
.ws-code .ws-barcode { display: block; width: 52mm; height: 14mm; margin: 0 0 0 auto; }
.wave-sheet .ws-foot { display: flex; flex-direction: column; gap: 10px; margin-top: 16px; font-size: 10px; color: #55687a; }
.wave-sheet .ws-foot-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; }

/* ---------- 分拣单：波次货品选择 ---------- */
.sort-pick-bar { display: flex; align-items: center; gap: 14px; font-size: 12px; color: var(--ink-3); }
.sort-pick-bar b { color: var(--blue-700); }
.sort-pick-bar a { color: var(--blue-700); }
.sort-pick-scroll { margin-top: 6px; border: 1px solid var(--line); border-radius: 8px; max-height: 280px; overflow: auto; background: #fff; }
.sort-pick-table { width: 100%; min-width: 660px; border-collapse: collapse; font-size: 12px; }
.sort-pick-table th { position: sticky; top: 0; z-index: 1; background: #f7fafc; color: var(--ink-3); font-weight: 600; text-align: left; padding: 7px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.sort-pick-table td { padding: 6px 8px; border-bottom: 1px solid #f1f5f9; color: var(--ink-2); vertical-align: top; }
.sort-pick-table tbody tr:last-child td { border-bottom: 0; }
.sort-pick-table tbody tr:hover td { background: #f7fbff; }
.sort-pick-table tbody tr.is-on td { background: #eef8fe; }
.sort-pick-table td.slots { white-space: normal; line-height: 1.5; }
.sort-pick-table td.num { font-variant-numeric: tabular-nums; }

/* ---------- 分拣单：库位分行表格 ---------- */
.sort-pick-table { min-width: 900px; }
.sort-pick-table td, .sort-pick-table th { white-space: nowrap; }
.sort-pick-table td:nth-child(3), .sort-pick-table td:nth-child(4) { white-space: normal; }

/* ---------- 波次单：页脚固定在 A4 底部 ---------- */
.wave-sheet { display: flex; flex-direction: column; }
.wave-sheet .ws-foot { margin-top: auto; }

/* ---------- 分拣单：条码列 ---------- */
.sort-pick-table { min-width: 980px; }
.sort-pick-table td:nth-child(4), .sort-pick-table td:nth-child(5) { white-space: normal; }

/* ---------- 出库验货（订单复核） ---------- */
.chk-card { padding: 16px 18px; margin-bottom: 14px; }
.chk-scan-bar { display: flex; align-items: center; gap: 10px; }
.chk-scan-bar .input { width: 360px; height: 38px; }
.chk-scan-bar .hint { font-size: 12px; color: var(--muted); }
.chk-empty { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 42px 0 30px; color: var(--muted); font-size: 12.5px; }
.chk-empty .ico { width: 30px; height: 30px; color: #b7c6d4; }
.chk-order { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.chk-order-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.chk-order-head b { font-size: 15px; color: var(--ink); }
.chk-order-head .sp { flex: 1; }
.chk-order-head .time { font-size: 12px; color: var(--muted); }
.chk-info { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 24px; padding: 12px 14px; background: #f7fafc; border: 1px solid var(--line); border-radius: 8px; }
.chk-info .it { display: flex; gap: 6px; font-size: 12.5px; color: var(--ink-2); min-width: 0; }
.chk-info .it > span { color: var(--muted); flex: 0 0 auto; }
.chk-info .it > b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chk-info .it:nth-child(7) { grid-column: span 2; }
.chk-goods-head { display: flex; align-items: center; gap: 12px; margin: 16px 0 8px; }
.chk-goods-head h3 { font-size: 13.5px; color: var(--ink); }
.chk-goods-head .sp { flex: 1; }
.chk-goods-scan { display: flex; align-items: center; gap: 8px; }
.chk-goods-scan > .ico { width: 14px; height: 14px; color: var(--muted); }
.chk-goods-scan .input { width: 280px; height: 34px; }
.chk-goods-scan .cnt { font-size: 12px; color: var(--muted); }
.chk-goods-scan .cnt b { color: var(--blue-700); }
.chk-goods-table { min-width: 760px; }
.chk-goods-table td b.done { color: var(--green); font-weight: 600; }
.chk-actions { display: flex; align-items: center; gap: 10px; margin-top: 14px; }
.chk-actions .sp { flex: 1; }
.chk-actions .hint { font-size: 12px; color: var(--muted); }
.chk-hist-head { display: flex; align-items: baseline; gap: 10px; }
.chk-hist-head h3 { font-size: 14px; color: var(--ink); }
.chk-hist-head .hint { font-size: 12px; color: var(--muted); }
.chk-hist-filter { display: flex; align-items: center; gap: 16px; padding: 12px 0 10px; border-bottom: 1px solid var(--line); margin-bottom: 10px; }
.chk-hist-filter .filter { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--ink-3); }
.chk-hist-filter .spacer { flex: 1; }
.chk-hist-table { min-width: 820px; }
.chk-card .pager { margin-top: 10px; }
.page-now { font-size: 12px; color: var(--ink-3); padding: 0 6px; }

/* ---------- 复核记录：货品列 ---------- */
.chk-hist-table { min-width: 1120px; table-layout: fixed; }
.chk-hist-table td.chk-h-name, .chk-hist-table td.chk-h-spec { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- 分拣单详情：货品表 ---------- */
.sort-detail-table { min-width: 900px; }
.sort-detail-table td.spec { white-space: normal; }

/* ---------- 动态储位优化 ---------- */
.so-head-actions { display: flex; align-items: center; gap: 10px; }
.so-head-actions .btn .ico { width: 14px; height: 14px; }
.so-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.so-kpis .dash-kpi { padding: 14px 16px; }
.so-panel { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; padding: 18px 20px; margin-bottom: 12px; }
.so-health { display: flex; align-items: center; gap: 16px; flex: 1 1 460px; min-width: 320px; }
.so-ring {
  position: relative; flex: 0 0 auto; width: 88px; height: 88px; border-radius: 50%;
  background: conic-gradient(#1e98d7 calc(var(--score) * 1%), #eaf0f5 0);
  display: flex; align-items: center; justify-content: center;
}
.so-ring::before { content: ""; position: absolute; inset: 8px; border-radius: 50%; background: #fff; }
.so-ring > div { position: relative; text-align: center; }
.so-ring b { display: block; font-size: 23px; line-height: 1.1; color: #0b6fa8; }
.so-ring span { font-size: 10px; color: var(--muted); }
.so-health-text h3 { font-size: 14px; font-weight: 650; color: var(--ink); margin-bottom: 5px; }
.so-health-text p { font-size: 12.3px; color: var(--ink-3); line-height: 1.7; }
.so-health-text p b { color: var(--blue-700); font-weight: 600; }
.so-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.so-chips span { font-size: 11px; color: #4b6f86; background: #f2f8fc; border: 1px solid #dcebf5; border-radius: 20px; padding: 2px 9px; }
.so-abc { flex: 1 1 300px; min-width: 250px; max-width: 420px; padding-left: 22px; border-left: 1px solid var(--line); }
.so-abc-head { display: flex; align-items: baseline; justify-content: space-between; font-size: 12px; color: var(--ink-3); margin-bottom: 8px; }
.so-abc-head small { font-size: 11px; color: var(--muted); }
.so-abc-bar { display: flex; height: 22px; border-radius: 6px; overflow: hidden; background: #f2f5f8; }
.so-abc-bar i { display: block; height: 100%; min-width: 2px; }
.so-abc-bar i.a { background: #2e9e6b; }
.so-abc-bar i.b { background: #4b9ed0; }
.so-abc-bar i.c { background: #b6c5d2; }
.so-abc-bar i.empty { background: #eef3f7; }
.so-abc-legend { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 8px; font-size: 11.5px; color: var(--ink-3); }
.so-abc-legend span { display: inline-flex; align-items: center; gap: 5px; }
.so-abc-legend i { width: 8px; height: 8px; border-radius: 2px; }
.so-abc-legend i.a { background: #2e9e6b; }
.so-abc-legend i.b { background: #4b9ed0; }
.so-abc-legend i.c { background: #b6c5d2; }
.so-filter { margin-bottom: 12px; }
.so-analyzed { font-size: 11.5px; color: var(--muted); }
.so-list-title { font-size: 13px; color: var(--ink); }
.so-legend { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--muted); }
.so-legend i { width: 10px; height: 10px; border-radius: 3px; background: #f3eefc; border: 1px solid #e0d3f5; }
.so-table { min-width: 1100px; }
.so-table th { white-space: nowrap; }
.so-table td { vertical-align: middle; }
.so-cell-sub { margin-top: 1px; font-size: 11px; color: var(--muted); }
.so-goods { display: flex; flex-direction: column; gap: 1px; line-height: 1.35; }
.so-goods b { font-size: 12px; font-weight: 600; color: #335468; }
.so-goods span { font-size: 11.5px; color: var(--ink-3); }
.so-slot { display: flex; flex-direction: column; gap: 1px; line-height: 1.3; }
.so-slot span { font-size: 11px; color: var(--muted); }
.so-slot b { font-size: 12px; color: var(--ink-2); font-weight: 600; }
.so-swap-tip { display: inline-block; width: max-content; margin-top: 2px; padding: 0 4px; font-size: 10px; color: #6d4eab; background: #f3eefc; border: 1px solid #e4d9f8; border-radius: 3px; }
.so-reason {
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  font-size: 11.5px; color: var(--ink-3); line-height: 1.55; white-space: normal;
}
.so-benefit { font-size: 12px; font-weight: 500; color: #237a51; }
.so-type { display: inline-block; padding: 2px 7px; border-radius: 4px; font-size: 11px; white-space: nowrap; }
.so-type-violet { background: #f3eefc; color: #6d4eab; border: 1px solid #e6dbf7; }
.so-type-amber { background: #fdf5e7; color: #9a6812; border: 1px solid #f3e2bd; }
.so-type-green { background: #eaf7f0; color: #237a51; border: 1px solid #cfeadd; }
.so-type-blue { background: #eaf4fd; color: #146fa9; border: 1px solid #d4e8f8; }
.so-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 46px 0; color: var(--muted); font-size: 12.5px; }
.so-empty .ico { width: 28px; height: 28px; color: #b7c6d4; }
.so-reason-box {
  margin-top: 12px; padding: 10px 12px;
  background: #f7fbff; border: 1px solid #d9eaf6; border-left: 3px solid #1e98d7; border-radius: 8px;
  font-size: 12.5px; color: #335468; line-height: 1.7;
}
.so-reason-box b { color: #146fa9; }
.so-benefit-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
.so-benefit-cards > div { padding: 10px 12px; background: #f8fbfd; border: 1px solid var(--line); border-radius: 8px; font-size: 11px; color: var(--muted); }
.so-benefit-cards b { display: block; margin-top: 4px; font-size: 14px; font-weight: 650; color: var(--ink); }
@media (max-width: 1180px) { .so-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .so-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .so-abc { max-width: none; padding-left: 0; border-left: 0; }
  .so-benefit-cards { grid-template-columns: 1fr; }
}

/* ---------- 开放平台 · 接口配置 ---------- */
.ifc-shell { padding-bottom: 6px; }
.ifc-tabs { margin: 0; padding: 0 20px; }
.ifc-pane .cc-config-head { padding-top: 15px; }
.ifc-pane .cc-config-body { padding-bottom: 15px; }

/* ---------- 出库单：批量生成物流单 ---------- */
.lgno-progress { padding: 4px 0 2px; }
.lgno-progress-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; font-size: 12.5px; color: var(--ink-2); }
.lgno-progress-head b { color: var(--blue-700); font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.lgno-bar { height: 8px; border-radius: 4px; background: #eef3f8; overflow: hidden; }
.lgno-bar i { display: block; height: 100%; width: 0; border-radius: 4px; background: var(--blue-500); transition: width .16s; }
.lgno-progress .hint { margin-top: 9px; font-size: 11.5px; color: var(--muted); word-break: break-all; }

/* ---------- 开放平台 · 物流单接口配置 ---------- */
.lgi-shell { display: flex; align-items: stretch; min-height: 500px; overflow: hidden; }
.lgi-side {
  flex: 0 0 268px; display: flex; flex-direction: column;
  padding: 14px 12px; border-right: 1px solid var(--line); background: #fbfdfe;
}
.lgi-side-head { display: flex; flex-direction: column; gap: 10px; padding: 2px 4px 12px; border-bottom: 1px solid var(--line); }
.lgi-side-title { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.lgi-side-title b { color: var(--ink); font-size: 13px; font-weight: 650; }
.lgi-side-title span { color: var(--muted); font-size: 11.5px; }
.lgi-side-head .btn { width: 100%; justify-content: center; }
.lgi-list { display: flex; flex-direction: column; gap: 4px; margin-top: 10px; padding-right: 2px; overflow: auto; min-height: 220px; max-height: calc(100vh - 330px); }
.lgi-item {
  display: flex; align-items: center; gap: 9px; width: 100%; padding: 8px 9px;
  border: 1px solid transparent; border-radius: 8px; background: transparent;
  font-family: inherit; text-align: left; cursor: pointer; transition: background .15s, border-color .15s;
}
.lgi-item:hover { background: #f2f8fc; }
.lgi-item.active { background: #eaf6fe; border-color: #cfe6f7; }
.lgi-avatar {
  flex: 0 0 auto; display: grid; place-items: center; width: 30px; height: 30px;
  border-radius: 8px; background: #eef4f9; color: #4b6f86; font-size: 11px; font-weight: 700; letter-spacing: .4px;
}
.lgi-item.active .lgi-avatar { background: #d9eefb; color: #0b6fa8; }
.lgi-info { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.lgi-info b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); font-size: 12.5px; font-weight: 600; }
.lgi-info small { color: var(--muted); font-size: 10.5px; letter-spacing: .3px; }
.lgi-state { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 4px; color: #8a9aab; font-size: 10.5px; white-space: nowrap; }
.lgi-state i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.lgi-state.on { color: #237a51; }
.lgi-state.off { color: #b97614; }
.lgi-side-empty { padding: 30px 8px; color: var(--muted); font-size: 12px; text-align: center; }
.lgi-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.lgi-main .cc-config-head { padding-top: 18px; }
.lgi-main .cc-config-body { flex: 1; }
.lgi-empty { align-items: center; justify-content: center; gap: 8px; padding: 60px 20px; color: var(--muted); font-size: 12.5px; }
.lgi-empty .ico { width: 30px; height: 30px; color: #b7c6d4; }
@media (max-width: 900px) {
  .lgi-shell { flex-direction: column; }
  .lgi-side { flex: none; border-right: 0; border-bottom: 1px solid var(--line); }
  .lgi-list { flex-direction: row; flex-wrap: wrap; max-height: 230px; }
  .lgi-item { width: calc(50% - 3px); }
}
@media (max-width: 560px) {
  .lgi-item { width: 100%; }
}
