/* ==========================================================================
   三齐ERP · 设计系统
   ========================================================================== */
:root {
  --brand: #0F7A5F;
  --brand-600: #0B6350;
  --brand-700: #084A3C;
  --brand-50: #EAF5F1;
  --brand-100: #D3EBE3;
  --ink: #10231D;
  --ink-2: #2C413A;
  --sub: #61736C;
  --mute: #8A9A94;
  --line: #E5EBE8;
  --line-2: #EFF3F1;
  --bg: #F3F6F4;
  --card: #FFFFFF;
  --gold: #C79A2E;
  --amber: #B0720C;
  --amber-bg: #FDF3E2;
  --rose: #C2445A;
  --rose-bg: #FCEDEF;
  --blue: #2F6FEB;
  --blue-bg: #EDF3FE;
  --dark: #0C2A23;
  --shadow-sm: 0 1px 2px rgba(16, 35, 29, .05);
  --shadow: 0 6px 24px -12px rgba(16, 35, 29, .18), 0 2px 6px -2px rgba(16, 35, 29, .06);
  --radius: 12px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--ink);
  font-size: 13.5px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-thumb { background: #CDD8D3; border-radius: 8px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background: #B4C3BD; background-clip: padding-box; border: 2px solid transparent; }
::-webkit-scrollbar-track { background: transparent; }

.tnum { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }

/* ============================ 登录页 ============================ */
.login-wrap { display: grid; grid-template-columns: 1.05fr 1fr; min-height: 100vh; }
.login-left {
  position: relative; overflow: hidden; color: #E9F3EF; padding: 56px 64px;
  background: radial-gradient(120% 90% at 0% 0%, #14503F 0%, #0C2A23 55%, #071C17 100%);
  display: flex; flex-direction: column; justify-content: space-between;
}
.login-left::before {
  content: ""; position: absolute; right: -160px; top: -100px; width: 620px; height: 620px; border-radius: 50%;
  background: radial-gradient(circle, rgba(28, 160, 122, .28), transparent 62%);
}
.login-left::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 320px; opacity: .16;
  background-image: radial-gradient(#7FBFAA 1px, transparent 1px); background-size: 22px 22px;
  mask-image: linear-gradient(to top, #000, transparent);
}
.login-brand { position: relative; z-index: 1; display: flex; align-items: center; gap: 14px; }
.login-brand .mark { width: 46px; height: 46px; border-radius: 13px; background: linear-gradient(145deg, #23A57F, #0B6350); display: grid; place-items: center; font-weight: 700; font-size: 19px; color: #fff; letter-spacing: -1px; box-shadow: 0 8px 24px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.25); }
.login-brand b { font-size: 19px; letter-spacing: .5px; }
.login-brand span { display: block; font-size: 11.5px; color: #8FB8AB; letter-spacing: 2.2px; }
.login-hero { position: relative; z-index: 1; margin: 40px 0 auto; max-width: 460px; }
.login-hero h1 { font-size: 34px; line-height: 1.35; margin: 0 0 16px; font-weight: 600; letter-spacing: .5px; }
.login-hero h1 em { font-style: normal; color: #6FD3B0; }
.login-hero p { color: #9DBFB4; font-size: 14px; line-height: 1.9; margin: 0; }
.login-feats { position: relative; z-index: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 34px; }
.login-feat { border: 1px solid rgba(255,255,255,.1); background: rgba(255,255,255,.045); border-radius: 10px; padding: 12px 14px; }
.login-feat b { display: block; font-size: 13px; color: #DCEFE8; margin-bottom: 2px; }
.login-feat span { font-size: 11.5px; color: #86AAA0; }
.login-foot { position: relative; z-index: 1; font-size: 11.5px; color: #6E9187; display: flex; gap: 18px; }
.login-right { display: grid; place-items: center; padding: 40px; background: #FBFCFB; }
.login-box { width: 100%; max-width: 356px; }
.login-box h2 { font-size: 23px; margin: 0 0 6px; font-weight: 600; letter-spacing: .3px; }
.login-box > p { color: var(--sub); font-size: 13px; margin: 0 0 30px; }
.login-field { margin-bottom: 16px; }
.login-field label { display: block; font-size: 12.5px; color: var(--ink-2); margin-bottom: 7px; font-weight: 500; }
.login-field .input { height: 42px; padding: 0 12px; background: #fff; }
.login-btn { width: 100%; height: 44px; margin-top: 8px; font-size: 14.5px; }
.login-tip { margin-top: 18px; font-size: 12px; color: var(--mute); background: var(--brand-50); border: 1px solid var(--brand-100); border-radius: 8px; padding: 10px 12px; line-height: 1.7; }
.login-tip b { color: var(--brand-600); font-weight: 600; }
.login-err { color: var(--rose); font-size: 12.5px; margin-top: 10px; min-height: 18px; }

/* ============================ 布局 ============================ */
.app { display: grid; grid-template-columns: 228px 1fr; min-height: 100vh; }

.side {
  background: linear-gradient(180deg, #0D302A 0%, #0A2520 60%, #081E1A 100%);
  color: #B7CCC5; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh;
  border-right: 1px solid rgba(255,255,255,.04);
}
.side-brand { display: flex; align-items: center; gap: 11px; padding: 18px 18px 16px; border-bottom: 1px solid rgba(255,255,255,.06); }
.side-brand .mark { width: 34px; height: 34px; border-radius: 9px; background: linear-gradient(145deg, #22A881, #0A5B49); display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 15px; letter-spacing: -.5px; box-shadow: inset 0 1px 0 rgba(255,255,255,.25); }
.side-brand .txt b { display: block; color: #F1F8F5; font-size: 15px; letter-spacing: .6px; line-height: 1.25; }
.side-brand .txt span { font-size: 9.5px; letter-spacing: 2.4px; color: #6E948A; }
.side-shop { margin: 12px 12px 4px; padding: 9px 10px; border-radius: 8px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.06); display: flex; align-items: center; gap: 8px; font-size: 12px; }
.side-shop .dot { width: 6px; height: 6px; border-radius: 50%; background: #38D39F; box-shadow: 0 0 0 3px rgba(56,211,159,.16); }
.side-shop span { color: #C8DAD4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-nav { flex: 1; overflow-y: auto; padding: 8px 10px 20px; }
.side-group { font-size: 10px; letter-spacing: 1.6px; color: #5C7E74; padding: 14px 10px 6px; text-transform: uppercase; }
.nav-item { display: flex; align-items: center; gap: 10px; padding: 8.5px 10px; border-radius: 8px; font-size: 13px; color: #A9C0B9; cursor: pointer; position: relative; margin-bottom: 1px; transition: background .15s, color .15s; }
.nav-item svg { width: 16px; height: 16px; opacity: .82; flex: none; }
.nav-item:hover { background: rgba(255,255,255,.055); color: #E7F2EE; }
.nav-item.active { background: linear-gradient(90deg, rgba(26,150,116,.34), rgba(26,150,116,.08)); color: #FFFFFF; font-weight: 500; }
.nav-item.active::before { content: ""; position: absolute; left: -10px; top: 9px; bottom: 9px; width: 3px; border-radius: 0 3px 3px 0; background: #3FCB9D; }
.nav-item .n { margin-left: auto; font-size: 10.5px; background: rgba(255,255,255,.1); color: #D5E6E0; padding: 0 6px; border-radius: 20px; line-height: 17px; font-variant-numeric: tabular-nums; }
.nav-item .n.hot { background: #C2445A; color: #fff; }
.side-foot { padding: 12px; border-top: 1px solid rgba(255,255,255,.06); font-size: 11px; color: #5C7E74; display: flex; justify-content: space-between; align-items: center; }
.side-foot .up { display: flex; align-items: center; gap: 5px; color: #6FD3B0; }

.main { min-width: 0; display: flex; flex-direction: column; }
.top {
  height: 58px; background: rgba(255,255,255,.88); backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 16px; padding: 0 22px;
  position: sticky; top: 0; z-index: 30;
}
.crumb { font-size: 12.5px; color: var(--mute); display: flex; align-items: center; gap: 7px; white-space: nowrap; }
.crumb b { color: var(--ink); font-weight: 600; font-size: 14px; }
.top-search { margin-left: auto; position: relative; width: 280px; }
.top-search .input { height: 34px; padding-left: 32px; background: #F6F8F7; border-color: transparent; font-size: 12.5px; }
.top-search .input:focus { background: #fff; }
.top-search svg { position: absolute; left: 10px; top: 9px; width: 15px; height: 15px; color: var(--mute); }
.top-search .kbd { position: absolute; right: 8px; top: 7px; font-size: 10px; color: var(--mute); border: 1px solid var(--line); border-radius: 4px; padding: 0 4px; background: #fff; }
.search-pop { position: absolute; top: 40px; left: 0; right: 0; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); padding: 6px; max-height: 380px; overflow: auto; z-index: 60; }
.search-pop .g { font-size: 10.5px; color: var(--mute); padding: 7px 8px 3px; letter-spacing: .5px; }
.search-pop .it { display: flex; gap: 8px; align-items: center; padding: 7px 8px; border-radius: 6px; cursor: pointer; font-size: 12.5px; }
.search-pop .it:hover { background: var(--brand-50); }
.search-pop .it .t { font-weight: 500; }
.search-pop .it .s { color: var(--mute); font-size: 11.5px; margin-left: auto; }
.top-ico { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; color: var(--sub); cursor: pointer; position: relative; }
.top-ico:hover { background: #F1F5F3; color: var(--ink); }
.top-ico svg { width: 17px; height: 17px; }
.top-ico .bdg { position: absolute; top: 4px; right: 5px; min-width: 15px; height: 15px; border-radius: 20px; background: var(--rose); color: #fff; font-size: 9.5px; display: grid; place-items: center; padding: 0 4px; border: 2px solid #fff; }
.top-user { display: flex; align-items: center; gap: 9px; padding-left: 14px; border-left: 1px solid var(--line); cursor: pointer; }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(145deg, #1E9C79, #0B6350); color: #fff; display: grid; place-items: center; font-size: 12px; font-weight: 600; }
.top-user .nm { font-size: 12.5px; line-height: 1.2; }
.top-user .nm span { display: block; font-size: 10.5px; color: var(--mute); }

.content { padding: 20px 22px 40px; max-width: 1560px; width: 100%; }

/* ============================ 通用组件 ============================ */
.page-hd { display: flex; align-items: flex-end; gap: 14px; margin-bottom: 16px; flex-wrap: wrap; }
.page-hd h1 { font-size: 19px; margin: 0; font-weight: 600; letter-spacing: .2px; }
.page-hd .desc { color: var(--mute); font-size: 12.5px; padding-bottom: 2px; }
.page-hd .right { margin-left: auto; display: flex; gap: 8px; align-items: center; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.card-hd { display: flex; align-items: center; gap: 10px; padding: 14px 16px 0; }
.card-hd h3 { font-size: 14px; margin: 0; font-weight: 600; }
.card-hd .sub { font-size: 11.5px; color: var(--mute); }
.card-hd .right { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.card-bd { padding: 14px 16px 16px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 32px; padding: 0 13px;
  border-radius: 7px; border: 1px solid var(--line); background: #fff; color: var(--ink-2);
  font-size: 12.5px; cursor: pointer; white-space: nowrap; transition: background .15s, border-color .15s, box-shadow .15s;
}
.btn:hover { background: #F7FAF9; border-color: #D5DFDA; }
.btn:active { transform: translateY(.5px); }
.btn svg { width: 14px; height: 14px; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #fff; box-shadow: 0 1px 2px rgba(15,122,95,.25); }
.btn-primary:hover { background: var(--brand-600); border-color: var(--brand-600); }
.btn-ghost { background: transparent; border-color: transparent; color: var(--sub); }
.btn-ghost:hover { background: #F1F5F3; color: var(--ink); }
.btn-danger { color: var(--rose); border-color: #F0D3D8; background: #fff; }
.btn-danger:hover { background: #FDF2F4; }
.btn-sm { height: 27px; padding: 0 9px; font-size: 12px; border-radius: 6px; }
.btn-link { border: none; background: none; color: var(--brand); font-size: 12.5px; cursor: pointer; padding: 0; }
.btn-link:hover { color: var(--brand-600); text-decoration: underline; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

.input, .select, .textarea {
  height: 32px; border: 1px solid var(--line); border-radius: 7px; padding: 0 10px; background: #fff;
  font-size: 12.5px; outline: none; transition: border-color .15s, box-shadow .15s; width: 100%;
}
.input:focus, .select:focus, .textarea:focus { border-color: #58B79C; box-shadow: 0 0 0 3px rgba(15,122,95,.1); }
.textarea { height: auto; padding: 8px 10px; resize: vertical; min-height: 66px; line-height: 1.6; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238A9A94' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 9px center; padding-right: 26px; cursor: pointer; }
.input-sm, .select-sm { height: 28px; font-size: 12px; border-radius: 6px; }
.field { margin-bottom: 13px; }
.field > label { display: block; font-size: 12px; color: var(--sub); margin-bottom: 6px; }
.field > label i { color: var(--rose); font-style: normal; }

.tag { display: inline-flex; align-items: center; gap: 4px; height: 21px; padding: 0 7px; border-radius: 5px; font-size: 11.5px; line-height: 1; white-space: nowrap; }
.tag.jade { background: var(--brand-50); color: var(--brand-600); }
.tag.blue { background: var(--blue-bg); color: var(--blue); }
.tag.amber { background: var(--amber-bg); color: var(--amber); }
.tag.violet { background: #F1EDFD; color: #7A5AF8; }
.tag.rose { background: var(--rose-bg); color: var(--rose); }
.tag.gray { background: #F2F5F4; color: var(--sub); }
.tag .d { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.tag.solid { color: #fff; }
.tag.solid.jade { background: var(--brand); }
.tag.solid.amber { background: #D08A1A; }
.tag.solid.rose { background: var(--rose); }
.tag.solid.blue { background: var(--blue); }
.tag.solid.gray { background: #97A7A1; }

.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 14px; overflow-x: auto; }
.tab { padding: 9px 13px; font-size: 13px; color: var(--sub); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; display: flex; align-items: center; gap: 6px; }
.tab:hover { color: var(--ink); }
.tab.on { color: var(--brand-600); border-bottom-color: var(--brand); font-weight: 600; }
.tab .c { font-size: 11px; background: #F1F4F3; color: var(--sub); border-radius: 20px; padding: 0 6px; line-height: 16px; font-variant-numeric: tabular-nums; }
.tab.on .c { background: var(--brand-50); color: var(--brand-600); }

.segmented { display: inline-flex; background: #F2F5F4; border-radius: 8px; padding: 2px; }
.segmented button { border: none; background: transparent; height: 26px; padding: 0 11px; border-radius: 6px; font-size: 12px; color: var(--sub); cursor: pointer; }
.segmented button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(16,35,29,.12); font-weight: 500; }

/* 表格 */
.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 12.5px; }
table.data th {
  text-align: left; font-weight: 500; color: var(--sub); font-size: 11.5px; letter-spacing: .2px;
  background: #FAFCFB; padding: 9px 12px; border-bottom: 1px solid var(--line); white-space: nowrap;
  position: sticky; top: 0; z-index: 1;
}
table.data td { padding: 10px 12px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
table.data th { position: relative; }
table.data.fixed-cols { table-layout: fixed; }
table.data.fixed-cols td, table.data.fixed-cols th { overflow: hidden; }
table.data .rz { position: absolute; top: 0; right: 0; width: 8px; height: 100%; cursor: col-resize; z-index: 2; }
table.data .rz:hover { background: rgba(15, 122, 95, .18); }
/* 线上订单号：等宽数字 + 点击复制 */
.ono { cursor: copy; font-variant-numeric: tabular-nums; }
.ono:hover { color: var(--brand-700); text-decoration: underline dotted; }
tbody .ono { font-size: 12px; letter-spacing: -.2px; }
table.data tbody tr:hover td { background: #FAFCFB; }
table.data tbody tr:last-child td { border-bottom: none; }
table.data .r { text-align: right; }
table.data .c { text-align: center; }
table.data .mono { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }
.tsk { display: flex; align-items: center; gap: 9px; }
.tsk .thumb { width: 36px; height: 36px; border-radius: 7px; flex: none; display: grid; place-items: center; font-size: 11px; color: #fff; font-weight: 600; letter-spacing: -.5px; }
.tsk .t1 { font-size: 12.5px; line-height: 1.35; color: var(--ink); }
.tsk .t2 { font-size: 11px; color: var(--mute); }
.sub2 { font-size: 11px; color: var(--mute); line-height: 1.4; }
.link { color: var(--brand); cursor: pointer; }
.link:hover { text-decoration: underline; }
.check { width: 14px; height: 14px; accent-color: var(--brand); cursor: pointer; vertical-align: -2px; }

.pager { display: flex; align-items: center; gap: 6px; padding: 12px 16px; border-top: 1px solid var(--line-2); font-size: 12.5px; color: var(--sub); }
.pager .sp { margin-left: auto; display: flex; gap: 4px; align-items: center; }
.pager button { min-width: 28px; height: 28px; border: 1px solid var(--line); background: #fff; border-radius: 6px; cursor: pointer; font-size: 12px; padding: 0 7px; }
.pager button:hover:not([disabled]) { border-color: #B9CFC7; }
.pager button.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.pager button[disabled] { opacity: .45; cursor: not-allowed; }

/* KPI */
.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 14px; }
.kpi { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px 12px; position: relative; overflow: hidden; box-shadow: var(--shadow-sm); }
.kpi .lb { font-size: 12px; color: var(--sub); display: flex; align-items: center; gap: 6px; }
.kpi .lb svg { width: 14px; height: 14px; opacity: .5; }
.kpi .v { font-size: 25px; font-weight: 600; letter-spacing: -.5px; margin: 6px 0 2px; font-variant-numeric: tabular-nums; }
.kpi .v small { font-size: 12px; font-weight: 500; color: var(--sub); margin-left: 3px; letter-spacing: 0; }
.kpi .ft { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--mute); }
.kpi .dl { font-weight: 500; display: inline-flex; align-items: center; gap: 2px; }
.kpi .dl.up { color: #0E8A65; }
.kpi .dl.down { color: var(--rose); }
.kpi .spark { position: absolute; right: 10px; bottom: 8px; opacity: .8; }
.kpi.accent { background: linear-gradient(135deg, #0E5F4A 0%, #0B3D33 100%); border-color: #0B3D33; color: #fff; }
.kpi.accent .lb { color: #A8CDC2; }
.kpi.accent .ft { color: #7FA79B; }
.kpi.accent .dl.up { color: #5FE0B4; }
.kpi.accent .v { color: #fff; }
.kpi.accent::after { content: ""; position: absolute; right: -30px; top: -40px; width: 150px; height: 150px; border-radius: 50%; background: radial-gradient(circle, rgba(50,200,160,.25), transparent 65%); }

.grid-2 { display: grid; grid-template-columns: 1.62fr 1fr; gap: 14px; }
.grid-2b { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.mb14 { margin-bottom: 14px; }

/* 图表 */
.chart { width: 100%; display: block; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 11.5px; color: var(--sub); }
.legend i { width: 8px; height: 8px; border-radius: 2px; display: inline-block; margin-right: 5px; vertical-align: 0; }
.chart-tip { font-size: 11.5px; color: var(--mute); }

/* 待办 */
.todo { display: flex; align-items: center; gap: 11px; padding: 10px 0; border-bottom: 1px dashed var(--line); cursor: pointer; }
.todo:last-child { border-bottom: none; }
.todo:hover .tl { color: var(--brand-600); }
.todo .ic { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; flex: none; }
.todo .ic svg { width: 15px; height: 15px; }
.todo .tl { font-size: 12.5px; transition: color .15s; }
.todo .ts { font-size: 11px; color: var(--mute); }
.todo .n { margin-left: auto; font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; }
.bg-amber { background: var(--amber-bg); color: var(--amber); }
.bg-blue { background: var(--blue-bg); color: var(--blue); }
.bg-violet { background: #F1EDFD; color: #7A5AF8; }

/* 列表设置弹窗 */
.colset { max-height: 430px; overflow: auto; padding: 2px; }
.colset-item { display: flex; align-items: center; gap: 8px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 7px; margin-bottom: 6px; background: #fff; cursor: grab; font-size: 12.5px; }
.colset-item:hover { border-color: var(--brand); }
.colset-item.dragging { opacity: .45; }
.colset-item .cs-label { flex: 1; }
.colset-item .colset-ops { display: flex; align-items: center; gap: 2px; opacity: .55; }
.colset-item .colset-ops button { border: none; background: none; cursor: pointer; font-size: 13px; line-height: 1; color: var(--sub); padding: 2px 4px; }
.colset-item .colset-ops button:hover { color: var(--brand-700); }
.colset-item .cs-grip { font-size: 13px; color: var(--mute); cursor: grab; }
.bg-rose { background: var(--rose-bg); color: var(--rose); }
.bg-jade { background: var(--brand-50); color: var(--brand); }

/* 排行 */
.rank { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.rank:last-child { border-bottom: none; }
.rank .no { width: 18px; height: 18px; border-radius: 5px; display: grid; place-items: center; font-size: 10.5px; font-weight: 600; background: #F1F5F3; color: var(--sub); flex: none; }
.rank:nth-child(1) .no { background: #FCF1DC; color: #A9781A; }
.rank:nth-child(2) .no { background: #EFF2F5; color: #62737E; }
.rank:nth-child(3) .no { background: #FBF0E6; color: #A9713F; }
.rank .nm { font-size: 12.5px; line-height: 1.3; min-width: 0; }
.rank .nm span { display: block; font-size: 11px; color: var(--mute); }
.rank .bar { margin-left: auto; width: 74px; height: 5px; border-radius: 4px; background: #EFF3F1; overflow: hidden; }
.rank .bar i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, #35B48F, #0F7A5F); }
.rank .am { width: 62px; text-align: right; font-size: 12px; font-variant-numeric: tabular-nums; }

/* 抽屉 / 弹窗 */
.overlay { position: fixed; inset: 0; background: rgba(10, 26, 22, .38); backdrop-filter: blur(1.5px); z-index: 80; opacity: 0; pointer-events: none; transition: opacity .2s; }
.overlay.on { opacity: 1; pointer-events: auto; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: 560px; max-width: 94vw; background: #fff; z-index: 90; transform: translateX(100%); transition: transform .26s cubic-bezier(.32,.72,.3,1); display: flex; flex-direction: column; box-shadow: -16px 0 48px rgba(10,26,22,.16); }
.drawer.on { transform: none; }
.drawer-hd { padding: 16px 20px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 10px; }
.drawer-hd h3 { margin: 0; font-size: 15px; font-weight: 600; }
.drawer-hd .x { margin-left: auto; cursor: pointer; color: var(--mute); width: 28px; height: 28px; display: grid; place-items: center; border-radius: 6px; }
.drawer-hd .x:hover { background: #F1F5F3; color: var(--ink); }
.drawer-bd { flex: 1; overflow-y: auto; padding: 18px 20px; }
.drawer-ft { padding: 12px 20px; border-top: 1px solid var(--line); display: flex; gap: 8px; justify-content: flex-end; background: #FBFCFB; }

.modal { position: fixed; z-index: 100; top: 50%; left: 50%; transform: translate(-50%, -46%) scale(.98); width: 520px; max-width: 94vw; background: #fff; border-radius: 14px; box-shadow: 0 30px 80px rgba(10,26,22,.28); opacity: 0; pointer-events: none; transition: opacity .18s, transform .18s; display: flex; flex-direction: column; max-height: 88vh; }
.modal.on { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%) scale(1); }
.modal-hd { padding: 16px 20px 12px; display: flex; align-items: center; }
.modal-hd h3 { margin: 0; font-size: 15px; font-weight: 600; }
.modal-hd .x { margin-left: auto; cursor: pointer; color: var(--mute); }
.modal-bd { padding: 4px 20px 16px; overflow-y: auto; }
.modal-ft { padding: 12px 20px; border-top: 1px solid var(--line); display: flex; gap: 8px; justify-content: flex-end; background: #FBFCFB; border-radius: 0 0 14px 14px; }

.kv { display: grid; grid-template-columns: 88px 1fr; gap: 8px 12px; font-size: 12.5px; }
.kv .k { color: var(--mute); }
.sect-t { font-size: 12px; color: var(--mute); letter-spacing: .6px; margin: 18px 0 8px; display: flex; align-items: center; gap: 8px; }
.sect-t::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.sect-t:first-child { margin-top: 0; }

.toast-wrap { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast { background: #0F2A23; color: #EAF5F1; padding: 9px 16px; border-radius: 8px; font-size: 12.5px; box-shadow: 0 10px 30px rgba(10,26,22,.28); animation: tin .24s ease; display: flex; align-items: center; gap: 8px; }
.toast.err { background: #7A2130; }
@keyframes tin { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

.empty { padding: 46px 20px; text-align: center; color: var(--mute); font-size: 12.5px; }
.empty svg { width: 42px; height: 42px; opacity: .35; margin-bottom: 10px; }

.progress { height: 6px; border-radius: 4px; background: #EFF3F1; overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--brand); border-radius: 4px; }

.toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.toolbar .sp { flex: 1; }
.bulkbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; background: #FAFCFB; border: 1px solid var(--line); border-radius: 8px; padding: 7px 12px; font-size: 12.5px; color: #6B7C76; margin: 0 16px 10px; }
.bulkbar .bk-label { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; color: #42544E; padding-right: 9px; border-right: 1px solid var(--line); }
.bulkbar .bk-count { white-space: nowrap; }
.bulkbar .bk-count b { color: var(--brand-700); font-variant-numeric: tabular-nums; }
.bulkbar .link2 { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.bulkbar .link2 .btn { opacity: .6; transition: opacity .12s; }
.bulkbar .link2 .btn:hover { opacity: 1; }
.bulkbar.on { background: var(--brand-50); border-color: var(--brand-100); color: var(--brand-700); }
.bulkbar.on .bk-label { color: var(--brand-700); border-right-color: var(--brand-100); }
.bulkbar.on .link2 .btn { opacity: 1; }

.mini-tip { font-size: 11.5px; color: var(--mute); line-height: 1.7; }
.stat-row { display: flex; gap: 26px; flex-wrap: wrap; }
.stat-row > div b { display: block; font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; }
.stat-row > div span { font-size: 11.5px; color: var(--mute); }

/* 店铺卡 */
.shop-card { display: flex; align-items: center; gap: 11px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.shop-logo { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; color: #fff; font-size: 10.5px; font-weight: 700; flex: none; letter-spacing: -.3px; }
.shop-card .nm { font-size: 12.5px; line-height: 1.35; }
.shop-card .st { font-size: 11px; color: var(--mute); }

/* 响应式 */
@media (max-width: 1240px) {
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .app { grid-template-columns: 64px 1fr; }
  .side-brand .txt, .side-shop, .side-group, .nav-item span, .side-foot { display: none; }
  .nav-item { justify-content: center; }
  .login-wrap { grid-template-columns: 1fr; }
  .login-left { display: none; }
  .top-search { width: 160px; }
}

/* ---- 订单管理增强：快捷筛选 / 高级搜索 / 行操作菜单 ---- */
.chips { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 16px 0; }
.chips .cl { font-size: 12px; color: var(--sub); margin-right: 2px; }
.chip { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 11px; border: 1px solid var(--line); border-radius: 13px; font-size: 12px; color: #41504A; background: #fff; cursor: pointer; user-select: none; transition: .15s; }
.chip b { font-weight: 600; font-variant-numeric: tabular-nums; }
.chip:hover { border-color: #9DBFB4; color: var(--brand-600); }
.chip.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.chip.on b { color: #fff; }
.chip.warn b { color: #C2445A; }
.chip.on.warn b { color: #fff; }
.adv { display: none; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 14px; padding: 12px 16px; border-bottom: 1px dashed var(--line); background: #FAFCFB; }
.adv.open { display: grid; }
.adv .field { margin: 0; }
.omenu { position: fixed; z-index: 1400; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 12px 32px rgba(16,35,29,.16); padding: 5px; min-width: 138px; }
.omenu button { display: block; width: 100%; text-align: left; padding: 7px 11px; border: 0; background: none; border-radius: 7px; font-size: 12.5px; cursor: pointer; color: #2C3B35; }
.omenu button:hover { background: #F0F5F3; }
.omenu button.danger { color: #C2445A; }
.omenu button[disabled] { color: #B8C4BF; cursor: not-allowed; }
.omenu .sep { height: 1px; background: var(--line); margin: 4px 6px; }
