/* caja 管理后台 — 设计系统（2026-06 现代化重写，仅改样式不动 markup） */
:root {
  --bg: #f3f5f9;
  --panel: #ffffff;
  --border: #e7ebf2;
  --border-strong: #d7dde8;
  --text: #1f2a37;
  --muted: #76828f;
  --primary: #4f6ef7;
  --primary-d: #3f5ae0;
  --primary-tint: #eef1fe;
  --green: #18a058; --green-bg: #e7f6ee;
  --red: #e5484d; --red-bg: #fdecec;
  --amber: #d98e04; --amber-bg: #fdf3e2;
  --radius: 12px; --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(24,39,75,.05), 0 2px 6px rgba(24,39,75,.05);
  --shadow-lg: 0 16px 48px rgba(24,39,75,.18);
}
* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, "PingFang SC", "Segoe UI", system-ui, sans-serif; background: var(--bg); color: var(--text); font-size: 14px; -webkit-font-smoothing: antialiased; }

button { cursor: pointer; border: 1px solid transparent; border-radius: var(--radius-sm); padding: 8px 14px; font-size: 14px; font-weight: 600; transition: background .15s, border-color .15s, box-shadow .15s, transform .05s; }
button:active { transform: translateY(1px); }
input, select, textarea { font-size: 14px; padding: 8px 11px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); font-family: inherit; color: var(--text); background: #fff; transition: border-color .15s, box-shadow .15s; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(79,110,247,.15); }

.primary { background: var(--primary); color: #fff; box-shadow: 0 1px 2px rgba(79,110,247,.3); }
.primary:hover { background: var(--primary-d); }
.ghost { background: #fff; border: 1px solid var(--border-strong); color: var(--text); }
.ghost:hover { background: var(--primary-tint); border-color: var(--primary); color: var(--primary-d); }
.ghost.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.danger { background: var(--red-bg); color: var(--red); }
.ok { background: var(--green); color: #fff; }

/* ===== 登录页：左品牌右表单，跟对外落地页 pos.dm-tong.com 同一套观感 ===== */
.loginpg{min-height:100vh;display:grid;grid-template-columns:1.05fr .95fr}
.loginpg .lp-left{background:linear-gradient(160deg,#141c3f,#2a3670);color:#fff;
  padding:56px 52px;display:flex;flex-direction:column;justify-content:center;position:relative;overflow:hidden}
/* 背景那团光:纯装饰,别让它挡住文字 */
.loginpg .lp-left::after{content:'';position:absolute;right:-16%;top:-10%;width:70%;height:70%;
  background:radial-gradient(circle,rgba(99,124,240,.34),transparent 68%);pointer-events:none}
.lp-logo{display:flex;align-items:center;gap:11px;font-weight:800;font-size:19px;color:#fff;
  text-decoration:none;margin-bottom:34px;position:relative;z-index:1}
.lp-logo small{display:block;font-weight:600;font-size:11px;letter-spacing:.5px;color:#9fa9d6}
.lp-mark{width:36px;height:36px;border-radius:10px;flex:none;
  background:linear-gradient(135deg,#3f5ae0,#7b8bf5);display:grid;place-items:center;font-size:17px}
.loginpg .lp-left h2{font-size:29px;line-height:1.22;letter-spacing:-.5px;margin:0 0 30px;
  max-width:12em;position:relative;z-index:1}
.lp-pts{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:17px;
  position:relative;z-index:1}
/* 三个子元素(图标/标题/说明)塞进两列网格:图标占第一列并跨两行,
   标题和说明都钉在第二列 —— 不钉的话说明会掉进 30px 宽的第一列,一个词一行 */
.lp-pts li{display:grid;grid-template-columns:30px minmax(0,1fr);gap:2px 12px;align-items:start}
.lp-pts i{font-style:normal;font-size:19px;line-height:1.2;grid-column:1;grid-row:1/span 2}
.lp-pts b,.lp-pts span{grid-column:2}
.lp-pts b{display:block;font-size:14.5px;margin-bottom:2px}
.lp-pts span{font-size:13px;color:#b3bbdd;line-height:1.5}

.loginpg .lp-right{display:flex;flex-direction:column;align-items:center;justify-content:center;
  padding:40px 26px;background:#f7f8fc}
.lp-card{width:100%;max-width:372px;background:#fff;border:1px solid #e3e8f2;border-radius:16px;
  padding:32px 30px;box-shadow:0 18px 44px rgba(20,35,90,.09)}
.lp-card h1{font-size:22px;margin:0 0 5px;letter-spacing:-.3px}
.lp-sub{margin:0 0 22px;font-size:13.5px;color:#7a8598}
.lp-card label{display:block;font-size:12.5px;font-weight:700;color:#47536b;margin:0 0 6px}
.lp-card input{width:100%;padding:12px 13px;margin-bottom:16px;border:1px solid #d7deea;
  border-radius:10px;font-size:15px;background:#fff}
.lp-card input:focus{outline:none;border-color:#3f5ae0;box-shadow:0 0 0 3px rgba(63,90,224,.13)}
.lp-go{width:100%;padding:13px;border:0;border-radius:10px;background:#3f5ae0;color:#fff;
  font-size:15.5px;font-weight:700;cursor:pointer;transition:.15s}
.lp-go:hover{background:#2f45b8}
.lp-err{margin:14px 0 0;padding:10px 12px;border-radius:9px;background:#fdecea;color:#c0392b;font-size:13px}
.lp-foot{display:flex;align-items:center;gap:10px;margin-top:18px;padding-top:16px;border-top:1px solid #eef1f7}
.lp-foot a{font-size:13px;color:#3f5ae0;font-weight:600;text-decoration:none;flex:1}
.lp-foot a:hover{text-decoration:underline}
.lp-lang{border:1px solid #d7deea;background:#fff;border-radius:8px;padding:6px 12px;
  font-size:12.5px;color:#5c6b84;cursor:pointer}

@media(max-width:900px){
  .loginpg{grid-template-columns:1fr;min-height:auto}
  /* 手机上左边那块只留品牌条,卖点收起来——登录页第一要务是让人尽快登进去 */
  .loginpg .lp-left{padding:26px 22px}
  .loginpg .lp-left h2,.lp-pts{display:none}
  .lp-logo{margin-bottom:0}
  .loginpg .lp-right{padding:28px 20px 44px}
}

/* 平台运营入口换成暗红：一眼分得出「这不是客户页」，防止在客户面前误开 */
.loginpg.plat .lp-left{background:linear-gradient(160deg,#2a1414,#5c2020)}
.loginpg.plat .lp-left::after{background:radial-gradient(circle,rgba(232,89,63,.30),transparent 68%)}
.loginpg.plat .lp-logo small{color:#e0b3ab}
.loginpg.plat .lp-pts span{color:#dcc0bb}
.loginpg.plat .lp-go{background:#c0392b}
.loginpg.plat .lp-go:hover{background:#9c2c20}
.loginpg.plat .lp-card input:focus{border-color:#c0392b;box-shadow:0 0 0 3px rgba(192,57,43,.13)}

.login { max-width: 360px; margin: 12vh auto; background: var(--panel); padding: 32px; border-radius: 16px; box-shadow: var(--shadow-lg); border: 1px solid var(--border); }
.login h1 { font-size: 21px; margin: 0 0 18px; }
.login input { width: 100%; margin-bottom: 12px; padding: 11px; }
.login button { width: 100%; padding: 12px; }

.layout { display: grid; grid-template-columns: 216px 1fr; min-height: 100vh; }
.side { background: #fff; border-right: 1px solid var(--border); padding: 14px 12px; position: sticky; top: 0; height: 100vh; overflow-y: auto; overscroll-behavior: contain; }
.side::-webkit-scrollbar { width: 8px; }
.side::-webkit-scrollbar-thumb { background: #d7deea; border-radius: 4px; }
.side .brand { font-weight: 800; color: var(--text); padding: 6px 12px 16px; font-size: 18px; letter-spacing: .3px; }
.side a { display: block; padding: 10px 14px; color: #4a5765; cursor: pointer; font-size: 14px; font-weight: 600; border-radius: var(--radius-sm); margin: 2px 0; transition: background .12s, color .12s; }
.side a:hover { background: var(--bg); color: var(--text); }
.side a.active { background: var(--primary-tint); color: var(--primary-d); }
.side a.active::before { content: ""; display: inline-block; width: 3px; height: 14px; background: var(--primary); border-radius: 3px; margin-right: 9px; vertical-align: -2px; margin-left: -8px; }
.side a.go-pos { margin: 4px 4px 14px; padding: 12px; background: var(--primary); color: #fff; font-weight: 700; text-align: center; box-shadow: 0 2px 6px rgba(79,110,247,.35); }
.side a.go-pos:hover { background: var(--primary-d); color: #fff; }
.nav-group-h { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; margin: 2px 0; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; cursor: pointer; border-radius: var(--radius-sm); user-select: none; }
.nav-group-h:hover { background: var(--bg); }
.nav-caret { font-size: 10px; color: var(--border-strong); }
.nav-sub a { padding-left: 26px; font-weight: 500; font-size: 13.5px; }

.main { padding: 22px 26px; min-width: 0; }
.top { display: flex; align-items: center; margin-bottom: 18px; }

/* 侧栏收起：点击顶栏 ⟨/☰ 切换，给内容区更大操作空间（收起=单列，否则 main 会掉进 0 宽列） */
.layout.side-off { grid-template-columns: 1fr; }
.layout.side-off .side { display: none; }
.side-toggle { margin-right: 12px; font-size: 15px; padding: 4px 11px; line-height: 1.2; }

/* ML 操作分类 tab */
/* ML 卖家中心式顶部 tab：文字+蓝色下划线(对齐 mercadolibre 商品管理页) */
.ml-tabbar { display: flex; gap: 4px; margin-bottom: 14px; flex-wrap: wrap; border-bottom: 1px solid #e4e8f2; }
.ml-tabbar button { padding: 11px 16px; font-weight: 700; font-size: 14.5px; border: none; background: none; border-radius: 0; color: #56607a; border-bottom: 3px solid transparent; }
.ml-tabbar button:hover { color: #3483fa; background: none; }
.ml-tabbar button.on { color: #3483fa; border-bottom-color: #3483fa; background: none; }
.top h2 { margin: 0; font-size: 20px; font-weight: 700; } .grow { flex: 1; }
.muted { color: var(--muted); font-size: 13px; }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px,1fr)); gap: 14px; }
.card { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); transition: box-shadow .15s, transform .1s; }
.card.click:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); cursor: pointer; }
.card .k { color: var(--muted); font-size: 13px; } .card .v { font-size: 27px; font-weight: 800; margin-top: 8px; letter-spacing: -.5px; }

.bar { display: flex; gap: 8px; margin-bottom: 14px; align-items: center; flex-wrap: wrap; }
.panel { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 4px 16px 12px; box-shadow: var(--shadow); }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 11px 10px; border-bottom: 1px solid var(--border); font-size: 14px; }
thead th { color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .4px; border-bottom: 1px solid var(--border); }
tbody tr:last-child td { border-bottom: none; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
tbody tr { transition: background .1s; }
tbody tr:hover { background: #f8fafd; }
tr.click { cursor: pointer; }

.tag { font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 999px; background: #eef1f6; color: #5a6675; display: inline-block; }
.tag.low { background: var(--red-bg); color: var(--red); }

.modal-bg { position: fixed; inset: 0; background: rgba(17,26,46,.5); backdrop-filter: blur(2px); display: flex; align-items: flex-start; justify-content: center; padding: 6vh 10px; z-index: 50; }
.modal { background: #fff; border-radius: 16px; padding: 24px; width: 560px; max-width: 100%; max-height: 88vh; overflow: auto; box-shadow: var(--shadow-lg); }
.modal h3 { margin: 0 0 16px; font-size: 18px; }
.modal h4 { font-weight: 700; }
/* 窄弹窗(收票详情/回应 SII 等)：白底黑字，样式对齐 .modal 只是宽度由行内 max-width 决定 */
.modal-sm { background: #fff; color: var(--text); border-radius: 16px; padding: 24px; width: 100%; max-height: 88vh; overflow: auto; box-shadow: var(--shadow-lg); }
.modal-sm h3 { margin: 0 0 16px; font-size: 18px; color: var(--text); }
.modal-sm table td { padding: 7px 4px; border-bottom: 1px solid var(--border, #e6eaf0); color: var(--text); }
.modal-sm table tr:last-child td { border-bottom: 0; }
.modal-sm table td.muted { color: #55606d; font-weight: 500; }
.form-row { display: flex; gap: 12px; margin-bottom: 12px; }
.form-row label { flex: 1; display: flex; flex-direction: column; gap: 5px; font-size: 13px; color: var(--muted); font-weight: 500; }
.form-row label input, .form-row label select { width: 100%; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--text); color: #fff; padding: 11px 20px; border-radius: var(--radius-sm); z-index: 100; box-shadow: var(--shadow-lg); font-weight: 500; }
.linebtn { padding: 4px 11px; font-size: 13px; font-weight: 600; }
.additems td { padding: 6px 4px; } .additems input { width: 100%; }

/* 角色权限勾选矩阵 */
.perm-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 18px; margin: 6px 0; }
.perm-group { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 10px 12px; background: #fcfdff; }
.perm-group-title { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.perm-item { display: flex; align-items: center; gap: 6px; font-size: 13px; color: #5a6675; padding: 3px 0; cursor: pointer; }
.perm-item input { margin: 0; }

/* 滚动条 */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #d4dae4; border-radius: 6px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: #b9c2d0; }

/* 配送看板 */
.dlv-board { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.dlv-col { background: #f6f8fb; border: 1px solid var(--border); border-radius: var(--radius); padding: 10px; min-height: 200px; }
.dlv-col-h { font-weight: 700; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.dlv-cnt { font-size: 12px; min-width: 20px; height: 20px; line-height: 20px; text-align: center; border-radius: 10px; padding: 0 6px; }
.dlv-cards { display: flex; flex-direction: column; gap: 10px; }
.dlv-card { background: #fff; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 10px 12px; box-shadow: var(--shadow); }
.dlv-card-top { display: flex; justify-content: space-between; align-items: center; }
.dlv-amt { font-weight: 700; color: var(--primary-d); }
.dlv-addr { margin: 6px 0 2px; font-size: 13px; }
.dlv-courier { margin-top: 8px; }
.dlv-courier select { width: 100%; padding: 6px 8px; border: 1px solid var(--border-strong); border-radius: 6px; background: #fff; }
.dlv-actions { display: flex; gap: 6px; align-items: center; margin-top: 8px; }
.dlv-empty { text-align: center; color: var(--muted); padding: 20px 0; font-size: 13px; }
@media (max-width: 900px) { .dlv-board { grid-template-columns: 1fr; } }

/* ===== 价格标签 ===== */
.lbl-opt { display:block; padding:5px 0; font-size:14px; cursor:pointer; }
.lbl-opt input { margin-right:6px; }
.label-overlay { position:fixed; inset:0; background:#eef1f6; z-index:1200; overflow:auto; }
.label-toolbar { position:sticky; top:0; display:flex; align-items:center; gap:10px; padding:12px 18px; background:#fff; border-bottom:1px solid #e2e7f0; }
.label-toolbar .grow { flex:1; }
.label-sheet { display:flex; flex-wrap:wrap; gap:2mm; padding:16px; align-content:flex-start; }
.label { box-sizing:border-box; border:1px solid #cfd6e2; background:#fff; overflow:hidden; display:flex; flex-direction:column; }
.label.sz-50x30 { width:50mm; height:30mm; padding:1.6mm 2mm; }
.label.sz-a4 { width:48mm; height:30mm; padding:1.6mm 2mm; }
.label .l-name { font-size:8.5pt; font-weight:600; line-height:1.15; overflow:hidden;
  /* 按整行截断,不要露出半行字(max-height 会把第三行切一半,贴到货架上很难看) */
  display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; }
.label .l-mid { flex:1; display:flex; align-items:center; justify-content:space-between; gap:1mm; min-height:0; }
.label .l-info { min-width:0; }
.label .l-price { font-size:15pt; font-weight:800; line-height:1; }
.label .l-code { font-size:7pt; color:#333; }
.label .l-shelf { font-size:7pt; color:#c0392b; font-weight:600; }
.label .l-qr { width:13mm; height:13mm; flex:none; object-fit:contain; }
.label .l-barcode { width:100%; height:8mm; }
@media print {
  /* 浮层已 Teleport 到 body,这里按 body 直系子代藏。
     ⚠ 别改回 #app > *:—— 浮层若嵌在 .layout 里,父节点被藏会连坐整个子树,打出来是白纸。 */
  body > *:not(.label-overlay) { display:none !important; }
  .label-overlay { position:static; background:#fff; overflow:visible; }
  .label-toolbar { display:none !important; }
  .label-sheet { padding:0; gap:0; }
  .label { border:none; }
  .label-sheet.pg-50x30 .label { page-break-after:always; }
}

/* ===== MercadoLibre 经营看板 ===== */
.ml-kpis { display:grid; grid-template-columns:repeat(auto-fit,minmax(180px,1fr)); gap:12px; margin-bottom:16px; }
.ml-kpi { background:var(--panel); border:1px solid var(--border); border-radius:var(--radius); padding:15px 18px; box-shadow:var(--shadow); }
.ml-kpi .lab { color:var(--muted); font-size:11px; font-weight:700; text-transform:uppercase; letter-spacing:.5px; }
.ml-kpi .val { font-size:26px; font-weight:800; margin-top:6px; letter-spacing:-.6px; line-height:1.1; }
.ml-kpi .cur { font-size:13px; color:var(--muted); font-weight:600; margin-left:3px; }

.ml-shops { display:grid; grid-template-columns:repeat(auto-fill,minmax(230px,1fr)); gap:14px; margin-bottom:18px; }
.ml-shop { position:relative; background:var(--panel); border:1px solid var(--border); border-radius:var(--radius); padding:15px 16px; box-shadow:var(--shadow); cursor:pointer; transition:box-shadow .15s, transform .1s, border-color .15s; overflow:hidden; }
.ml-shop::before { content:""; position:absolute; left:0; top:0; bottom:0; width:4px; background:var(--primary); opacity:0; transition:opacity .15s; }
.ml-shop:hover { box-shadow:var(--shadow-lg); transform:translateY(-2px); }
.ml-shop.on { border-color:var(--primary); background:linear-gradient(180deg,var(--primary-tint),#fff 65%); }
.ml-shop.on::before { opacity:1; }
.ml-shop .flag { font-size:14px; font-weight:700; display:flex; align-items:center; gap:6px; }
.ml-shop .nick { font-size:15px; font-weight:600; margin:5px 0 2px; color:var(--text); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.ml-dot { width:8px; height:8px; border-radius:50%; background:var(--green); box-shadow:0 0 0 3px var(--green-bg); display:inline-block; }
.ml-shop .krow { display:flex; gap:22px; margin-top:12px; }
.ml-shop .krow .n { font-size:20px; font-weight:800; letter-spacing:-.5px; line-height:1.1; }
.ml-shop .krow .t { font-size:11px; color:var(--muted); margin-top:1px; }
.ml-shop .err { color:var(--red); font-size:12px; margin-top:8px; }

.ml-board { background:var(--panel); border:1px solid var(--border); border-radius:var(--radius); box-shadow:var(--shadow); overflow:hidden; }
.ml-board .hd { display:flex; align-items:center; gap:10px; padding:13px 16px; border-bottom:1px solid var(--border); font-weight:700; font-size:15px; }
.ml-live { display:inline-flex; align-items:center; gap:6px; font-size:12px; color:var(--green); font-weight:600; }
.ml-live .pz { width:7px; height:7px; border-radius:50%; background:var(--green); animation:mlpulse 1.6s infinite; }
@keyframes mlpulse { 0%{box-shadow:0 0 0 0 rgba(24,160,88,.5)} 70%{box-shadow:0 0 0 6px rgba(24,160,88,0)} 100%{box-shadow:0 0 0 0 rgba(24,160,88,0)} }

.ml-ord { display:flex; align-items:center; gap:13px; padding:12px 16px; border-bottom:1px solid var(--border); transition:background .1s; }
.ml-ord:hover { background:var(--bg); }
.ml-ord:last-child { border-bottom:none; }
.ml-ava { width:36px; height:36px; border-radius:50%; flex:none; display:flex; align-items:center; justify-content:center; color:#fff; font-weight:700; font-size:15px; }
.ml-ord .mid { flex:1; min-width:0; }
.ml-ord .top { display:flex; align-items:center; gap:8px; }
.ml-ord .buyer { font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.ml-badge { font-size:11px; color:var(--muted); background:var(--bg); padding:1px 7px; border-radius:6px; flex:none; }
.ml-ord .items { color:var(--text); font-size:13px; margin-top:3px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.ml-ord .items .q { color:var(--muted); }
.ml-ord .oid { font-family:ui-monospace,Menlo,monospace; font-size:11px; color:var(--muted); margin-top:2px; }
.ml-ord .right { text-align:right; flex:none; }
.ml-ord .amt { font-weight:800; font-size:16px; letter-spacing:-.4px; }
.ml-ord .amt .c { font-size:11px; color:var(--muted); font-weight:600; }
.ml-ord .when { font-size:12px; color:var(--muted); margin-top:3px; }
.ml-pill { display:inline-flex; align-items:center; gap:5px; padding:3px 9px; border-radius:20px; font-size:12px; font-weight:600; }
.ml-pill .pd { width:6px; height:6px; border-radius:50%; }
.ml-empty { padding:40px 16px; text-align:center; color:var(--muted); }

/* 商品列表字号（工具条可选，本机记忆）：字小行距同步收紧，一屏看更多行 */
table.prod-font-12 th, table.prod-font-12 td { font-size: 12px; padding: 6px 8px; }
table.prod-font-13 th, table.prod-font-13 td { font-size: 13px; padding: 8px 9px; }
table.prod-font-12 thead th, table.prod-font-13 thead th { font-size: 11px; }

/* 列表表头固定：页面下滚时表头钉在视口顶部（商品/库存/流水等所有 .panel 长表通用） */
.panel table thead th { position: sticky; top: 0; background: var(--panel); z-index: 5; box-shadow: 0 1px 0 var(--border); }

/* 商品页批量操作下拉 */
.bulk-item { display:block; padding:9px 12px; border-radius:7px; cursor:pointer; font-size:13.5px; color:#1f2530 }
.bulk-item:hover { background:#f0f4ff }

/* ML 在线商品：行内编辑单元格（点价格/库存原地改，对齐 ML 卖家中心体感） */
.ml-cell-edit { cursor:pointer; border-bottom:1px dashed transparent; padding-bottom:1px }
.ml-cell-edit:hover { border-bottom-color:#3f5ae0 }
.ml-cell-edit .ml-pen { opacity:0; font-size:11px; color:#3f5ae0; margin-left:4px }
.ml-cell-edit:hover .ml-pen { opacity:1 }


/* ===== ML 卖家中心复刻(商品管理页) ===== */
.mlx-cards { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 14px; }
.mlx-card { flex: 0 0 260px; background: var(--panel, #fff); border: 1px solid #e4e8f2; border-radius: 10px; padding: 14px 16px; cursor: pointer; transition: box-shadow .15s; }
.mlx-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,.08); }
.mlx-card.on { border-color: #3483fa; box-shadow: 0 0 0 1px #3483fa inset; }
.mlx-card .t { font-weight: 700; font-size: 13.5px; display: flex; justify-content: space-between; gap: 8px; }
.mlx-card .t .n { background: #eef3ff; color: #3483fa; border-radius: 12px; padding: 0 9px; font-size: 12.5px; }
.mlx-card .d { color: #7a8598; font-size: 12px; margin-top: 5px; }
.mlx-selbar { display: flex; align-items: center; gap: 6px; padding: 9px 16px; border-top: 1px solid #e4e8f2; border-bottom: 1px solid #e4e8f2; background: #fcfdff; flex-wrap: wrap; }
.mlx-act { border: none; background: none; padding: 7px 12px; border-radius: 8px; font-size: 13.5px; color: #56607a; cursor: pointer; }
.mlx-act:hover:not(:disabled) { background: #f0f4ff; color: #3483fa; }
.mlx-act:disabled { opacity: .4; cursor: default; }
.mlx-act.blue { color: #3483fa; font-weight: 600; }
.mlx-sep { width: 1px; height: 18px; background: #e4e8f2; margin: 0 4px; }
.mlx-dd { position: absolute; left: 0; top: 105%; z-index: 60; background: #fff; border: 1px solid #dde3ee; border-radius: 10px; box-shadow: 0 8px 24px rgba(0,0,0,.12); padding: 6px; white-space: nowrap; min-width: 190px; }
.mlx-table thead th { background: #f5f6fa; font-size: 12.5px; color: #56607a; }
.mlx-table td { vertical-align: top; padding-top: 12px; padding-bottom: 12px; }
.mlx-chev { border: 1px solid #dde3ee; background: #fff; border-radius: 6px; width: 22px; height: 20px; line-height: 1; font-size: 11px; color: #3483fa; cursor: pointer; padding: 0; }
.mlx-sub > td table th { background: none; }
/* ML 式状态开关 */
.mlx-switch { position: relative; display: inline-block; width: 36px; height: 20px; flex: 0 0 auto; }
.mlx-switch input { opacity: 0; width: 0; height: 0; }
.mlx-switch span { position: absolute; inset: 0; background: #ccd3e0; border-radius: 20px; transition: .18s; cursor: pointer; }
.mlx-switch span:before { content: ''; position: absolute; width: 16px; height: 16px; border-radius: 50%; background: #fff; top: 2px; left: 2px; transition: .18s; box-shadow: 0 1px 3px rgba(0,0,0,.25); }
.mlx-switch input:checked + span { background: #3483fa; }
.mlx-switch input:checked + span:before { transform: translateX(16px); }
.mlx-switch input:disabled + span { opacity: .45; cursor: default; }
/* 列表内复制小按钮：常态半隐,行悬停显现 */
.copybtn { margin-left: 5px; cursor: pointer; font-size: 11px; opacity: .25; text-decoration: none; user-select: none; }
tr:hover .copybtn { opacity: .75; }
.copybtn:hover { opacity: 1 !important; }
/* 商品主页：表格面板内滚动，表头钉住(整页 sticky 对长列表不生效,改为面板内滚动区) */
.panel-scroll { max-height: calc(100vh - 200px); overflow-y: auto; padding-top: 0; }
.panel-scroll table thead th { padding-top: 10px; }
.panel-scroll table thead th { position: sticky; top: 0; background: var(--panel); z-index: 6; box-shadow: 0 1px 0 var(--border); }

/* 不可用的行内操作：灰化但保留在原位（藏起来用户只会以为坏了），
   仍可点击 —— 点了用 toast 说明原因，触屏也有反馈（disabled 按钮点了没任何响应）。 */
.linebtn.act-off {
  color: #a8b3c2 !important;
  border-color: var(--line, #e3e6ea) !important;
  background: transparent;
  cursor: not-allowed;
}
.linebtn.act-off:hover { color: #8f9bab !important; }

/* 已停用的商品:留在列表里(历史订单/网站映射还挂着它),但要一眼看出来 —— 
   原来完全没标记,点完「删除」那一行纹丝不动,客户以为删除没生效。 */
tr.prod-off > td { opacity:.5; }
tr.prod-off > td:nth-child(2), tr.prod-off > td:nth-child(3) { opacity:.72; }

/* ===== 6×3cm 货架价签（左单价 / 右整箱价，主题色 --lc 可选） ===== */
/* 版式对齐客户样张：窄体全大写、价格特大、色块标签、底部税提示条。
   字号用 pt + 尺寸用 mm：热敏/激光都按物理尺寸出，不受屏幕 DPI 影响。 */
.shelf { box-sizing:border-box; width:60mm; height:30mm; padding:1.4mm 1.8mm; background:#fff;
  border:0.5mm solid var(--lc,#5c6b2a); display:flex; flex-direction:column; align-items:center;
  overflow:hidden; font-family:'Arial Narrow','Helvetica Neue',Arial,sans-serif; color:#000;
  /* ⚠ 不加这两行,Chrome 打印默认不印背景色 —— 色块标签和底部条会变成灰的,
     客户拿到的就是一张没颜色的标签(2026-08-07 反馈)。加了之后不用他手工去勾「背景图形」。 */
  -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.shelf .s-code { font-size:7pt; font-weight:800; letter-spacing:.2px; color:var(--lc,#5c6b2a); line-height:1.05; flex:none; }
/* 名称允许折到两行再截断:单行加省略号会把「BODY SPLASH ARABE MUJER」砍成「BODY SPLA…」,
   货架上看不出是什么货 */
/* ⚠ 名称是**唯一允许被挤掉**的东西:flex 1 1 auto + min-height:0,
   高度不够时它自己截断,而不是把下面的价格顶出卡片。
   2026-08-08 客户反馈「有些看不到价格」就是因为名称折两行后把价格挤没了 —— 
   价签上价格被切掉等于这张标签白印。 */
.shelf .s-name { font-weight:800; line-height:1.02; text-transform:uppercase; text-align:center;
  max-width:100%; overflow:hidden; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical;
  flex:0 1 auto; min-height:0; }
.shelf .s-sub { font-size:6pt; font-weight:700; line-height:1.1; text-transform:uppercase; text-align:center;
  max-width:100%; max-height:2.2em; overflow:hidden; flex:0 1 auto; min-height:0; }
.shelf .s-rule { width:100%; height:0.3mm; background:var(--lc,#5c6b2a); margin:0.5mm 0 0.4mm; flex:none; }
/* 价格区锁死:flex:none 保证它既不被压缩也不被挤出卡片。
   宁可名称少显示几个字,也不能让价格看不见。 */
.shelf .s-prices { flex:none; display:flex; align-items:center; justify-content:center; width:100%;
  margin:auto 0 0; padding-bottom:0.4mm; }
.shelf .s-col { flex:1; min-width:0; display:flex; flex-direction:column; align-items:center; justify-content:center; }
.shelf .s-div { width:0.3mm; background:#000; margin:0 1mm; flex:none; }
.shelf .s-tag { background:var(--lc,#5c6b2a); color:#fff; font-size:5.4pt; font-weight:800; letter-spacing:.2px;
  padding:0.4mm 1.4mm; text-transform:uppercase; white-space:nowrap; }
.shelf .s-x { font-size:5pt; font-weight:800; line-height:1.3; }
.shelf .s-amt { font-size:17pt; font-weight:800; line-height:1; letter-spacing:-.5px; white-space:nowrap; }
.shelf .s-amt .cur { color:var(--lc,#5c6b2a); font-size:12pt; margin-right:.3mm; }
/* ⚠ 这里的留白是**按 1px 抠出来的**,别随手加回去:
   30mm 的卡在标准字号下只差约 1px 就放不下名称,结果是名称底部被切掉一行像素——
   屏幕上几乎看不出,打印出来就是「半截字母」(2026-08-10 客户照片)。
   把分隔线上下和这条底部条各省 0.15~0.3mm,标准字号才能不缩字地放下。 */
.shelf .s-foot { width:100%; background:var(--lc,#5c6b2a); color:#fff; font-size:5.4pt; font-weight:800;
  text-align:center; letter-spacing:.3px; padding:0.35mm 0; margin-top:0.45mm; flex:none; }
.label-sheet.pg-60x30 { gap:2mm; }
@media print {
  .label-sheet.pg-60x30 { gap:0; }
  .label-sheet.pg-60x30 .shelf { page-break-after:always; }
}

/* 6×3 货架签 · A4 平铺版：普通打印机打一张 A4，27 枚，打完沿虚线裁 */
/* A4 可用宽 210−16=194mm，60×3=180mm 放得下 3 列；可用高 297−16=281mm，30×9=270mm 放得下 9 行 */
.label-sheet.pg-60x30a4 { gap: 0; }
.label-sheet.pg-60x30 .shelf, .label-sheet.pg-60x30a4 .shelf { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.label-sheet.pg-60x30a4 .shelf { border-style: dashed; border-width: 0.3mm; }
@media print {
  .label-sheet.pg-60x30a4 { gap: 0; }
  /* 不加 page-break-after —— 那是「每张一页」那一档的做法，这里要让它自然流满整页 */
  .label-sheet.pg-60x30a4 .shelf { break-inside: avoid; page-break-inside: avoid; }
}
