:root {
  --red: #D6232A;
  --red-dark: #B81E24;
  --bg: #f4f5f7;
  --card: #ffffff;
  --border: #e5e7eb;
  --text: #2d3436;
  --muted: #8a919c;
  --shadow: 0 1px 3px rgba(0,0,0,.08);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, "Microsoft YaHei", "PingFang SC", sans-serif;
  background: var(--bg); color: var(--text); font-size: 14px;
}
.hidden { display: none !important; }

/* 登录 */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #2d3436 0%, #d6232a 100%); }
.login-card { background: #fff; border-radius: 14px; padding: 36px 32px; width: 360px; box-shadow: 0 10px 40px rgba(0,0,0,.25); }
.login-brand { display: flex; align-items: center; gap: 14px; margin-bottom: 24px; }
.logo { width: 46px; height: 46px; border-radius: 10px; background: var(--red); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 24px; font-weight: 700; }
.login-title { font-size: 20px; font-weight: 700; }
.login-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.login-card .input { margin-bottom: 12px; }
.login-err { color: var(--red); font-size: 12px; min-height: 18px; margin-top: 8px; }
.login-hint { text-align: center; color: var(--muted); font-size: 12px; margin-top: 12px; }

/* 布局 */
.app { display: flex; min-height: 100vh; }
.sidebar { width: 220px; background: #2d3436; color: #fff; display: flex; flex-direction: column; flex-shrink: 0;
  position: sticky; top: 0; height: 100vh; align-self: flex-start; }
.side-brand { display: flex; align-items: center; gap: 12px; padding: 20px 18px; border-bottom: 1px solid rgba(255,255,255,.1); }
.side-title { font-size: 16px; font-weight: 700; }
.side-nav { flex: 1; padding: 12px 10px; overflow-y: auto; min-height: 0; }
.nav-item { display: block; padding: 11px 14px; border-radius: 8px; color: #cfd3d8;
  cursor: pointer; margin-bottom: 4px; font-size: 14px; transition: .15s; text-decoration: none; }
.nav-item:hover { background: rgba(255,255,255,.08); color: #fff; }
.nav-item.active { background: var(--red); color: #fff; }
.nav-parent { display: flex; justify-content: space-between; align-items: center; }
.nav-arrow { font-size: 11px; opacity: .7; transition: .15s; }
.nav-parent.collapsed .nav-arrow { transform: rotate(-90deg); }
.nav-subitem { padding-left: 34px; font-size: 13px; }
.side-foot { padding: 14px; border-top: 1px solid rgba(255,255,255,.1); flex-shrink: 0; }
.side-user { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.role-tag { background: rgba(255,255,255,.15); padding: 2px 8px; border-radius: 20px; font-size: 11px; }

.main { flex: 1; padding: 24px; overflow-y: auto; }
.view-head { display: flex; align-items: center; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.view-head h2 { font-size: 20px; font-weight: 700; }
.toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.view-head .toolbar { margin-left: auto; }
/* 产品库：功能栏靠左，与「产品库」标题同一行左对齐 */
#view-products .view-head .toolbar { margin-left: 0; }

/* 组件 */
.input { border: 1px solid var(--border); border-radius: 8px; padding: 9px 12px; font-size: 14px;
  background: #fff; outline: none; transition: .15s; }
.input:focus { border-color: var(--red); }
.input-sm { padding: 6px 10px; font-size: 13px; }
.btn { border: none; border-radius: 8px; padding: 9px 16px; font-size: 14px; cursor: pointer;
  transition: .15s; font-weight: 500; }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-dark); }
.btn-outline { background: #fff; color: var(--red); border: 1px solid var(--red); }
.btn-outline:hover { background: #fff5f5; }
.btn-ghost { background: transparent; color: var(--muted); }
.btn-ghost:hover { background: #eee; }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-block { width: 100%; }
.btn-link { background: none; border: none; color: var(--red); cursor: pointer; font-size: 13px; }
.btn-link:hover { text-decoration: underline; }

.stat-bar { color: var(--muted); font-size: 13px; padding: 8px 2px; }
.stat-bar .stat { display: inline-block; background: #fafafa; border: 1px solid var(--border); border-radius: 8px;
  padding: 10px 18px; margin: 0 10px 8px 0; text-align: center; min-width: 110px; }
.stat-bar .stat-v { font-size: 18px; font-weight: 700; color: var(--red); }
.stat-bar .stat-k { font-size: 12px; color: var(--muted); margin-top: 2px; }
.hint { background: #fff7e6; border: 1px solid #ffd591; color: #ad6800; border-radius: 8px;
  padding: 10px 14px; font-size: 13px; margin-bottom: 14px; }

/* 产品卡片 */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.pcard { background: var(--card); border-radius: 10px; overflow: hidden; cursor: pointer;
  box-shadow: var(--shadow); transition: .15s; border: 1px solid var(--border); }
.pcard:hover { transform: translateY(-2px); box-shadow: 0 4px 14px rgba(0,0,0,.12); }
.pcard-img { width: 100%; height: 170px; object-fit: contain; background: #fafafa; padding: 8px; }
.pcard-body { padding: 10px 12px; }
.pcard-name { font-size: 13px; font-weight: 600; line-height: 1.4; height: 36px; overflow: hidden; }
.pcard-meta { font-size: 12px; color: var(--muted); margin-top: 4px; }
.pcard-status { display: flex; align-items: center; gap: 8px; margin-top: 5px; flex-wrap: wrap; }
.status-tag { font-size: 11px; font-weight: 600; background: #f3f4f6; border-radius: 3px; padding: 1px 6px; }
.stock-num { font-size: 12px; color: #5a6472; }
.stock-num.zero { color: #d03050; font-weight: 600; }
.restock-note { font-size: 11px; color: #b25b00; }
.pcard-price { margin-top: 10px; display: flex; flex-direction: column; gap: 7px; }
.price-item { display: flex; align-items: center; gap: 8px; }
.price-tag { font-style: normal; font-size: 11px; color: var(--muted); background: #f3f4f6; border-radius: 4px; padding: 2px 6px; flex-shrink: 0; }
.price-retail { color: var(--red); font-weight: 700; font-size: 17px; }
.price-supply { color: #1f2329; font-weight: 700; font-size: 15px; }
.price-cost { color: var(--muted); font-size: 13px; }

/* 表格 */
.table-wrap { background: var(--card); border-radius: 10px; box-shadow: var(--shadow); overflow: auto; }
.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; padding: 11px 12px; background: #fafafa; font-size: 13px;
  color: var(--muted); border-bottom: 1px solid var(--border); white-space: nowrap; }
.table td { padding: 9px 12px; border-bottom: 1px solid var(--border); font-size: 13px; vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table tbody tr:hover { background: #fafafa; }
.timg { width: 44px; height: 44px; object-fit: contain; background: #fafafa; border-radius: 6px; border: 1px solid var(--border); }
.price-input { width: 90px; border: 1px solid var(--border); border-radius: 6px; padding: 5px 8px; font-size: 13px; }

/* 弹窗 */
.modal { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; }
.modal-mask { position: absolute; inset: 0; background: rgba(0,0,0,.4); }
.modal-box { position: relative; background: #fff; border-radius: 12px; width: 760px; max-width: 92vw;
  max-height: 88vh; display: flex; flex-direction: column; box-shadow: 0 10px 40px rgba(0,0,0,.3); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px;
  border-bottom: 1px solid var(--border); }
.modal-body { padding: 20px; overflow-y: auto; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 20px; border-top: 1px solid var(--border); }

/* 表单 */
.form-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; background: #fff;
  padding: 14px; border-radius: 10px; box-shadow: var(--shadow); margin-bottom: 14px; }
.form-row label { color: var(--muted); font-size: 13px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-item { display: flex; flex-direction: column; gap: 5px; }
.form-item.full { grid-column: 1 / -1; }
.form-item label { font-size: 12px; color: var(--muted); }
.form-item textarea { min-height: 70px; resize: vertical; }
.secret-mark { color: var(--red); font-size: 11px; }
.chk { display: flex; align-items: center; gap: 5px; }

/* 分页 */
.pager { display: flex; gap: 8px; align-items: center; justify-content: center; margin-top: 16px; }
.pager button { border: 1px solid var(--border); background: #fff; border-radius: 6px; padding: 6px 12px; cursor: pointer; }
.pager button.active { background: var(--red); color: #fff; border-color: var(--red); }
.pager button:disabled { opacity: .4; cursor: default; }

/* toast */
.toast { position: fixed; top: 20px; left: 50%; transform: translateX(-50%); background: #2d3436;
  color: #fff; padding: 10px 20px; border-radius: 8px; z-index: 200; opacity: 0; pointer-events: none;
  transition: opacity .3s; font-size: 14px; }
.toast.show { opacity: 1; }

@media (max-width: 760px) {
  .sidebar { width: 64px; }
  .side-title, .side-user span, .nav-item { font-size: 0; }
  .nav-item::first-letter { font-size: 18px; }
}

/* 新建报价单：已选产品清单 */
.quote-cart { display: none; margin: 8px 0; padding: 8px 10px; background: #FFF7F5; border: 1px solid #F5C6C2; border-radius: 8px; font-size: 12px; }
.quote-cart.on { display: block; }
.quote-cart .qc-title { color: var(--red); font-weight: 700; margin-bottom: 6px; }
.quote-cart .qc-item { display: inline-flex; align-items: center; gap: 4px; background: #fff; border: 1px solid #eee; border-radius: 12px; padding: 2px 8px; margin: 2px 4px 2px 0; }
.quote-cart .qc-item b { color: var(--red); }
.quote-cart .qc-x { cursor: pointer; color: #999; font-weight: 700; }
.quote-cart .qc-x:hover { color: var(--red); }
.qn-pricemodes { display: inline-flex; gap: 12px; align-items: center; }
.qn-pricemodes .chk { display: inline-flex; align-items: center; gap: 4px; font-weight: 400; }

/* 客户360° 详情页 */
.cd-tabs { display: flex; gap: 4px; border-bottom: 2px solid var(--border); margin-bottom: 14px; flex-wrap: wrap; }
.cd-tab { border: none; background: none; padding: 9px 16px; font-size: 14px; cursor: pointer; color: #666;
  border-bottom: 2px solid transparent; margin-bottom: -2px; border-radius: 6px 6px 0 0; }
.cd-tab:hover { color: var(--red); background: #FFF7F5; }
.cd-tab.active { color: var(--red); font-weight: 700; border-bottom-color: var(--red); }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.cd-pane { animation: fadeIn .2s; }
.cd-h { font-size: 15px; font-weight: 700; margin: 16px 0 8px; color: #333; }
.cd-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; margin-bottom: 6px; }
.cd-card { background: #fafafa; border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; }
.cd-card .k { font-size: 12px; color: #999; margin-bottom: 3px; }
.cd-card .v { font-size: 14px; font-weight: 600; color: #333; word-break: break-all; }
.cd-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.cd-chip { display: inline-flex; align-items: center; gap: 6px; background: #FFF7F5; border: 1px solid #F5C6C2;
  color: #c0392b; border-radius: 14px; padding: 4px 12px; font-size: 13px; }
.cd-chip .x { cursor: pointer; color: #999; font-weight: 700; }
.cd-chip .x:hover { color: var(--red); }
.cd-chip.brand { background: #f0f7ff; border-color: #bdd7f5; color: #1E88E5; }
.cd-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.cd-sum { align-self: center; font-size: 13px; color: #666; }
.cd-bar { height: 8px; background: #fdeceb; border-radius: 4px; overflow: hidden; margin-top: 4px; }
.cd-bar i { display: block; height: 100%; background: var(--red); border-radius: 4px; }
@media (max-width: 900px) { .cd-2col { grid-template-columns: 1fr; } }

/* ===== 品牌导航栏 ===== */
.brand-bar-wrap { display: flex; align-items: flex-start; gap: 8px; margin: 4px 0 2px; }
.brand-bar { display: flex; flex-wrap: wrap; gap: 8px; overflow-y: auto; max-height: 252px;
  padding: 6px 2px 8px; flex: 1; scrollbar-width: thin; align-content: flex-start; }
.brand-bar::-webkit-scrollbar { width: 6px; }
.brand-bar::-webkit-scrollbar-thumb { background: #ddd; border-radius: 3px; }
.brand-chip { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px 5px 6px;
  background: #fff; border: 1px solid var(--border); border-radius: 20px; cursor: pointer;
  white-space: nowrap; flex-shrink: 0; transition: all .15s; font-size: 13px; color: #333; }
.brand-chip:hover { border-color: var(--red); color: var(--red); }
.brand-chip.active { background: var(--red); border-color: var(--red); color: #fff; font-weight: 600; }
.brand-chip .bl { width: 28px; height: 28px; border-radius: 50%; object-fit: contain; background: #fff;
  border: 1px solid #eee; flex-shrink: 0; }
.brand-chip.logo-only { padding: 6px 12px; }
.brand-chip.logo-only .bl { width: 80px; height: 60px; border-radius: 8px; border: none; background: transparent; }
.brand-chip .bl-text { width: 28px; height: 28px; border-radius: 50%; background: #f2f2f2; color: #888;
  display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; flex-shrink: 0; }
.brand-chip.active .bl-text { background: rgba(255,255,255,.25); color: #fff; }
.brand-chip .bc { font-size: 11px; color: #999; }
.brand-chip.active .bc { color: rgba(255,255,255,.85); }
#brand-manage-btn { flex-shrink: 0; }

/* 品牌管理弹窗 */
.bm-list { max-height: 380px; overflow-y: auto; }
.bm-row { display: flex; align-items: center; gap: 10px; padding: 8px 4px; border-bottom: 1px solid #f0f0f0; }
.bm-row img { width: 36px; height: 36px; border-radius: 6px; object-fit: contain; border: 1px solid #eee; background: #fff; }
.bm-row .bm-noimg { width: 36px; height: 36px; border-radius: 6px; background: #f2f2f2; color: #aaa;
  display: inline-flex; align-items: center; justify-content: center; font-size: 15px; font-weight: 700; }
.bm-row .bm-name { flex: 1; font-size: 14px; font-weight: 600; color: #333; }
.bm-row .bm-count { font-size: 12px; color: #999; margin-right: 6px; }
.bm-add { display: flex; gap: 8px; margin-top: 12px; }
.bm-add input { flex: 1; }

/* 品牌拖拽排序 */
.brand-chip.movable { cursor: grab; }
.brand-chip.movable:active { cursor: grabbing; }
.brand-chip.dragging { opacity: .35; border-style: dashed; }

/* 开团价徽标（智能识别结果行内） */
.gp-badge { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 10px;
  background: #fff7e6; border: 1px solid #ffd591; color: #d46b08; font-size: 12px; font-weight: 600; }

/* 输入联想下拉（品牌/品类模糊搜索） */
.ac-list { position: absolute; top: 100%; left: 0; right: 0; z-index: 80; background: var(--card);
  border: 1px solid var(--border); border-radius: 8px; box-shadow: 0 6px 20px rgba(0,0,0,.12);
  max-height: 252px; overflow: auto; margin-top: 4px; }
.ac-item { padding: 8px 12px; font-size: 14px; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ac-item:hover, .ac-item.active { background: #eef2ff; }

/* 品牌栏拖拽调高手柄 */
.brand-resize { height: 12px; cursor: ns-resize; display: flex; align-items: center; justify-content: center; }
.brand-resize::after { content: ""; width: 56px; height: 4px; border-radius: 2px; background: var(--border); transition: background .15s; }
.brand-resize:hover::after { background: #c7cdd8; }

/* 品牌介绍卡片 */
.brand-intro { background: var(--card); border: 1px solid var(--border); border-radius: 10px;
  box-shadow: var(--shadow); padding: 14px 16px; margin: 6px 0 10px; }
.bi-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.bi-logo { height: 36px; max-width: 120px; object-fit: contain; }
.bi-title { font-size: 16px; font-weight: 600; flex: 1; }
.bi-count { font-size: 12px; color: var(--muted); font-weight: 400; margin-left: 8px; }
.bi-text { font-size: 13px; line-height: 1.8; }
.bi-empty { color: var(--muted); }

/* 菜单箭头加大点击热区 */
.nav-arrow { padding: 4px 8px; margin-right: -6px; cursor: pointer; }

/* 详情图画廊（产品弹窗） */
.dimg-row { display: flex; flex-wrap: wrap; gap: 8px; }
.dimg-cell { position: relative; width: 86px; height: 86px; border: 1px solid var(--border); border-radius: 8px;
  overflow: hidden; background: #fafafa; }
.dimg-cell img { width: 100%; height: 100%; object-fit: cover; display: block; }
.dimg-cell a { display: block; width: 100%; height: 100%; }
.dimg-del { position: absolute; top: 2px; right: 2px; z-index: 2; width: 18px; height: 18px; line-height: 16px;
  border-radius: 50%; border: none; background: rgba(0,0,0,.55); color: #fff; font-size: 11px; cursor: pointer; }
.dimg-del:hover { background: var(--red); }

/* 导出报价单-价格列多选 */
.price-multi { position: relative; display: inline-block; }
.price-multi-btn { cursor: pointer; white-space: nowrap; }
.price-multi-panel { position: absolute; top: calc(100% + 4px); right: 0; z-index: 60; background: #fff; border: 1px solid #e3e6eb; border-radius: 8px; box-shadow: 0 6px 20px rgba(0,0,0,.12); padding: 8px 10px; min-width: 130px; }
.price-multi-panel label { display: flex; align-items: center; gap: 6px; padding: 5px 4px; font-size: 13px; cursor: pointer; white-space: nowrap; }
.price-multi-panel label:hover { background: #f5f6f8; border-radius: 4px; }

/* 用户弹窗-可见栏目勾选 */
.menu-checks { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; padding: 8px 10px; border: 1px solid #e3e6eb; border-radius: 8px; background: #fafbfc; }
.menu-checks label { display: flex; align-items: center; gap: 6px; font-size: 13px; cursor: pointer; padding: 3px 2px; font-weight: normal; }
.menu-checks label:hover { color: #d03050; }

/* ===== 产品详情（选品视图） ===== */
.pd-box { width: 900px; }
.pd-wrap { display: flex; gap: 22px; }
.pd-left { width: 330px; flex: none; }
.pd-mainimg { width: 330px; height: 330px; object-fit: contain; background: #fafafa; border: 1px solid #eee; border-radius: 10px; }
.pd-thumbs { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.pd-thumbs img { width: 54px; height: 54px; object-fit: contain; border: 1px solid #eee; border-radius: 6px; cursor: pointer; background: #fafafa; }
.pd-thumbs img.active { border-color: #d03050; border-width: 2px; }
.pd-right { flex: 1; min-width: 0; }
.pd-name { font-size: 18px; font-weight: 700; line-height: 1.45; }
.pd-meta { color: #8a919c; font-size: 13px; margin: 6px 0 12px; }
.pd-price-row { display: flex; gap: 14px; align-items: baseline; flex-wrap: wrap; background: #fff5f3; border-radius: 8px; padding: 12px 16px; }
.pd-price-main { color: #d03050; font-weight: 800; font-size: 26px; }
.pd-price-tag { color: #8a919c; font-size: 12px; }
.pd-price-inner { color: #b26a00; font-size: 13px; background: #fff8e6; border-radius: 4px; padding: 2px 8px; }
.pd-tiers { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.pd-tier { font-size: 13px; color: #444; background: #f2f5f9; border-radius: 4px; padding: 3px 10px; }
.pd-tier b { color: #d03050; }
.pd-params { margin-top: 16px; }
.pd-params-tit { font-size: 14px; font-weight: 700; margin-bottom: 8px; padding-left: 8px; border-left: 3px solid #d03050; }
.pd-params table { width: 100%; border-collapse: collapse; font-size: 13px; }
.pd-params td { border: 1px solid #eee; padding: 7px 10px; vertical-align: top; line-height: 1.5; }
.pd-params td.k { width: 110px; background: #fafafa; color: #777; white-space: nowrap; }
@media (max-width: 760px) {
  .pd-wrap { flex-direction: column; }
  .pd-left { width: 100%; }
  .pd-mainimg { width: 100%; height: auto; max-height: 320px; }
}

/* ===== PPT 方案页：左右双栏（选品 + 预览） ===== */
.ppt-layout { display: flex; gap: 16px; align-items: flex-start; }
.ppt-left { flex: 1; min-width: 0; }
.ppt-right { width: 400px; flex-shrink: 0; }
.ppt-panel-head { font-size: 15px; font-weight: 600; padding: 2px 0 8px; }
.ppt-table-wrap { max-height: calc(100vh - 430px); min-height: 260px; overflow: auto; }
/* 表头吸顶：滚动时全选框/列名常驻可见 */
.ppt-table-wrap .table th { position: sticky; top: 0; z-index: 2; }
.ppt-gen-bar {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 4px 4px;
}
.ppt-gen-bar .btn { padding: 8px 26px; font-size: 15px; }

#ppt-preview {
  max-height: calc(100vh - 360px); min-height: 260px; overflow: auto;
  display: flex; flex-direction: column; gap: 8px; padding-right: 2px;
}
.ppt-cover-card {
  background: linear-gradient(135deg, #fdf6f0, #fdeee4);
  border: 1px solid #f0dcc8; border-radius: 10px;
  padding: 16px 14px; text-align: center;
}
.ppt-cover-tag {
  display: inline-block; font-size: 11px; color: #b0793f;
  border: 1px solid #e3c9a8; border-radius: 10px; padding: 1px 10px; margin-bottom: 8px;
}
.ppt-cover-title { font-size: 17px; font-weight: 700; line-height: 1.35; }
.ppt-cover-meta { font-size: 12px; color: var(--muted); margin-top: 6px; }
/* PPT 节日主题预览卡（下拉框旁，16:9 迷你幻灯片） */
.ppt-theme-preview { width: 172px; height: 96px; border-radius: 8px; border: 1px solid var(--border);
  position: relative; overflow: hidden; flex-shrink: 0; box-shadow: var(--shadow); background: #fff; }
.ppt-theme-preview .tp-inner { width: 132px; height: 74px; position: relative;
  transform: scale(1.3); transform-origin: top left; }
#view-ppt #ppt-customer { max-width: 300px; }
#view-ppt #ppt-theme { max-width: 230px; }
.ppt-theme-preview .tp-deco { position: absolute; line-height: 1; opacity: .92; }
.ppt-theme-preview .tp-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 7px; }
.ppt-theme-preview .tp-name { position: absolute; left: 0; right: 0; bottom: 12px; text-align: center;
  font-size: 11px; font-weight: 700; padding: 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ppt-theme-preview .tp-tag { position: absolute; right: 4px; top: 3px; font-size: 10px; color: var(--muted);
  background: rgba(255,255,255,.75); border-radius: 8px; padding: 0 6px; }
.ppt-prev-item {
  display: flex; align-items: center; gap: 8px;
  background: var(--card); border: 1px solid var(--border); border-radius: 8px;
  padding: 6px 8px;
}
.ppt-prev-idx {
  flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%;
  background: var(--red); color: #fff; font-size: 12px;
  display: flex; align-items: center; justify-content: center;
}
.ppt-prev-item img {
  flex-shrink: 0; width: 44px; height: 44px; object-fit: contain;
  border: 1px solid var(--border); border-radius: 6px; background: #fff;
}
.ppt-prev-noimg {
  flex-shrink: 0; width: 44px; height: 44px; border-radius: 6px;
  border: 1px dashed var(--border); color: var(--muted);
  font-size: 11px; display: flex; align-items: center; justify-content: center;
}
.ppt-prev-info { flex: 1; min-width: 0; }
.ppt-prev-name {
  font-size: 13px; font-weight: 500; line-height: 1.3;
  overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.ppt-prev-sub { font-size: 12px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ppt-prev-ops { flex-shrink: 0; display: flex; flex-direction: column; gap: 2px; }
.ppt-prev-ops button {
  border: 1px solid var(--border); background: #fff; border-radius: 5px;
  width: 24px; height: 20px; font-size: 11px; line-height: 1; cursor: pointer; color: var(--muted);
}
.ppt-prev-ops button:hover:not(:disabled) { color: var(--red); border-color: var(--red); }
.ppt-prev-ops button:disabled { opacity: .3; cursor: default; }
.ppt-prev-summary { font-size: 12px; color: var(--muted); text-align: center; padding: 4px 0 2px; }

@media (max-width: 1100px) {
  .ppt-layout { flex-direction: column; }
  .ppt-right { width: 100%; }
}

/* ===== 批量删除模式（品牌多选 + 产品勾选）===== */
.btn-danger { background: #d03050; color: #fff !important; border: 1px solid #d03050; }
.btn-danger:hover { background: #b8254a; }
.btn-danger:disabled { background: #e5a7b5; border-color: #e5a7b5; cursor: not-allowed; }
.batch-bar { display: flex; align-items: center; gap: 10px; padding: 8px 12px; margin-top: 6px;
  background: #fff5f6; border: 1px dashed #d03050; border-radius: 10px; font-size: 13px; }
.batch-bar .batch-tip { color: #a04; flex: 1; }
.batch-bar #p-batch-count { font-weight: 700; color: #d03050; white-space: nowrap; }
.brand-chip.batch-sel { border-color: #d03050; box-shadow: 0 0 0 2px rgba(208,48,80,.35); position: relative; }
.brand-chip.batch-sel::after { content: "✔"; position: absolute; top: -6px; right: -6px; width: 16px; height: 16px;
  background: #d03050; color: #fff; border-radius: 50%; font-size: 10px; line-height: 16px; text-align: center; }
.pcard.batch { position: relative; }
.pcard.batch .batch-check { position: absolute; top: 8px; left: 8px; z-index: 3; width: 22px; height: 22px;
  border-radius: 50%; background: rgba(255,255,255,.92); border: 2px solid #d03050; color: #d03050;
  font-size: 13px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.pcard.batch-checked { outline: 2px solid #d03050; outline-offset: -2px; background: #fff5f6; }
.pcard.batch-checked .batch-check { background: #d03050; color: #fff; }

/* 批量删除按钮：位于「共N款产品」统计行右侧 */
.stat-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-right: 2px; }

/* ===== 多选下拉（PPT 选品-品牌多选）===== */
.msel { position: relative; display: inline-block; }
.msel-btn { min-width: 96px; text-align: left; cursor: pointer; white-space: nowrap; }
.msel-btn.msel-active { border-color: var(--red, #d03050); color: var(--red, #d03050); font-weight: 600; }
.msel-panel { position: absolute; top: calc(100% + 4px); left: 0; z-index: 60; min-width: 180px; max-height: 320px;
  overflow-y: auto; background: #fff; border: 1px solid #e5e5ea; border-radius: 10px; padding: 6px;
  box-shadow: 0 8px 24px rgba(0,0,0,.12); }
.msel-item { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 7px;
  cursor: pointer; font-size: 13px; user-select: none; }
.msel-item:hover { background: #f5f5f7; }
.msel-item.on { background: #fff5f6; }
.msel-item .msel-name { flex: 1; }
.msel-item .msel-count { color: #999; font-size: 12px; }
.msel-item input[type=checkbox] { margin: 0; accent-color: #d03050; }
