:root {
  --navy: #1F3A5F;
  --navy-2: #284d78;
  --orange: #F28C28;
  --bg: #F6F7F9;
  --surface: #fff;
  --ink: #1d2939;
  --muted: #778397;
  --line: #e7ebf0;
  --green: #16844a;
  --green-bg: #e9f7ef;
  --yellow: #b7791f;
  --yellow-bg: #fff6df;
  --red: #c44141;
  --red-bg: #fff0ef;
  --blue: #3578c8;
  --blue-bg: #edf5ff;
  --grey: #8a93a1;
  --grey-bg: #f0f2f5;
  --shadow: 0 8px 24px rgba(24, 39, 58, .06);
  --radius: 14px;
  --font: "Microsoft YaHei", "PingFang SC", "Noto Sans CJK SC", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--bg); }
body { margin: 0; color: var(--ink); background: var(--bg); font: 14px/1.55 var(--font); }
button, input, select, textarea { color: inherit; font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .52; }
a { color: var(--navy-2); text-decoration: none; }
a:hover { text-decoration: underline; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.tiny { font-size: 12px; }
.eyebrow { color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.overline { font-size: 12px; color: var(--muted); }
.app-shell { width: 100%; height: 100vh; min-height: 0; display: grid; grid-template-columns: 228px minmax(0,1fr); overflow: hidden; }
.sidebar { position: sticky; top: 0; height: 100vh; padding: 22px 16px; color: #eaf0f7; background: var(--navy); display: flex; flex-direction: column; z-index: 10; }
.brand { display: flex; align-items: center; gap: 11px; padding: 2px 8px 25px; }
.brand-mark { width: 39px; height: 39px; display: grid; place-items: center; color: var(--navy); background: #fff; border-radius: 12px; font-size: 18px; font-weight: 900; }
.brand-name { font-size: 16px; font-weight: 800; letter-spacing: .02em; }
.brand-sub { color: #b7c9dd; font-size: 12px; margin-top: 1px; }
.nav-label { margin: 18px 10px 7px; color: #91a8c3; font-size: 12px; letter-spacing: .11em; }
.nav-list { display: grid; gap: 4px; }
.nav-link { width: 100%; border: 0; display: flex; align-items: center; gap: 11px; padding: 10px 11px; border-radius: 10px; background: transparent; color: #d8e3ef; text-align: left; transition: background .15s ease, color .15s ease; }
.nav-link:hover { background: rgba(255,255,255,.1); color: #fff; }
.nav-link.active { background: #fff; color: var(--navy); font-weight: 700; box-shadow: 0 4px 12px rgba(0,0,0,.12); }
.nav-icon { width: 20px; text-align: center; font-size: 16px; }
.nav-count { margin-left: auto; min-width: 21px; height: 21px; padding: 0 6px; display: grid; place-items: center; border-radius: 99px; color: #fff; background: rgba(242,140,40,.95); font-size: 12px; font-weight: 800; }
.sidebar-spacer { flex: 1; }
.sidebar-note { padding: 13px; border: 1px solid rgba(255,255,255,.16); border-radius: 12px; background: rgba(255,255,255,.06); color: #d5e0ec; font-size: 12px; }
.sidebar-note strong { display: block; margin-bottom: 4px; color: #fff; font-size: 12px; }
.sidebar-foot { padding: 14px 9px 0; color: #91a8c3; font-size: 12px; }
.main-area { min-width: 0; min-height: 0; height: 100%; display: flex; flex-direction: column; overflow: hidden; }
.topbar { flex: 0 0 70px; height: 70px; padding: 0 30px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.92); display: flex; align-items: center; justify-content: space-between; gap: 18px; position: relative; z-index: 8; backdrop-filter: blur(12px); }
.topbar-left, .topbar-right { display: flex; align-items: center; gap: 13px; }
.page-kicker { color: var(--muted); font-size: 12px; }
.page-name { font-size: 17px; font-weight: 800; }
.top-search { width: min(320px, 26vw); height: 38px; padding: 0 12px; border: 1px solid var(--line); border-radius: 10px; background: #fbfcfd; display: flex; gap: 8px; align-items: center; color: var(--muted); }
.top-search input { width: 100%; border: 0; outline: 0; background: transparent; font-size: 12px; }
.industry-select { min-width: 106px; height: 38px; padding: 0 11px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font-size: 12px; }
.user-chip { display: flex; align-items: center; gap: 9px; padding: 4px 8px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.avatar { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; background: #e9eff6; color: var(--navy); font-weight: 800; }
.user-name { font-size: 12px; font-weight: 700; }
.user-role { font-size: 12px; color: var(--muted); }
.icon-button { width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--muted); }
.content { width: 100%; max-width: 1800px; min-height: 0; flex: 1 1 auto; overflow: auto; margin: 0 auto; padding: 27px 30px 88px; overscroll-behavior: contain; }
.page-heading { margin: 0 0 18px; display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.page-heading h1 { margin: 0; font-size: clamp(22px, 2vw, 29px); line-height: 1.2; letter-spacing: -.025em; }
.page-heading p { margin: 7px 0 0; color: var(--muted); font-size: 12px; }
.heading-actions { display: flex; align-items: center; gap: 8px; }
.btn { min-height: 37px; padding: 8px 13px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--navy); font-weight: 700; font-size: 12px; transition: transform .12s ease, box-shadow .12s ease; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 14px rgba(24,39,58,.09); }
.btn.primary { border-color: var(--navy); background: var(--navy); color: #fff; }
.btn.accent { border-color: var(--orange); background: var(--orange); color: #fff; }
.btn.soft { border-color: transparent; background: #eff3f8; }
.btn.danger { border-color: #f2c9c6; background: var(--red-bg); color: var(--red); }
.btn.small { min-height: 30px; padding: 5px 9px; font-size: 12px; }
.btn.text { padding: 5px 8px; border-color: transparent; background: transparent; color: var(--navy-2); }
.card { min-width: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.card-head { padding: 17px 19px 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.card-title { margin: 0; font-size: 14px; font-weight: 800; }
.card-subtitle { margin-top: 4px; color: var(--muted); font-size: 12px; }
.card-body { padding: 15px 19px 18px; }
.grid { display: grid; gap: 14px; }
.stats-grid { grid-template-columns: repeat(4,minmax(0,1fr)); margin-bottom: 16px; }
.stat-card { padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.stat-label { color: var(--muted); font-size: 12px; }
.stat-value { margin-top: 5px; font-size: 25px; font-weight: 800; line-height: 1.05; letter-spacing: -.04em; }
.stat-foot { margin-top: 9px; color: var(--muted); font-size: 12px; }
.stat-mark { float: right; width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; background: #eef3f9; color: var(--navy); }
.dash-grid { grid-template-columns: minmax(0,1.45fr) minmax(290px,.8fr); align-items: start; }
.welcome-card { padding: 23px 25px; overflow: hidden; position: relative; border: 0; color: #fff; background: linear-gradient(115deg,#1F3A5F,#315d8c); }
.welcome-card:after { content: ""; position: absolute; width: 270px; height: 270px; right: -30px; top: -145px; border: 1px solid rgba(255,255,255,.2); border-radius: 50%; box-shadow: 0 0 0 35px rgba(255,255,255,.035), 0 0 0 72px rgba(255,255,255,.025); }
.welcome-card h2 { position: relative; z-index: 1; max-width: 660px; margin: 0; font-size: clamp(20px,2.6vw,29px); line-height: 1.25; }
.welcome-card p { position: relative; z-index: 1; max-width: 580px; margin: 10px 0 18px; color: #d9e6f4; font-size: 12px; }
.welcome-card .btn { position: relative; z-index: 1; }
.module-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; margin-top: 14px; }
.module-tile { min-height: 89px; padding: 13px; border: 1px solid var(--line); border-radius: 12px; background: #fff; text-align: left; }
.module-tile:hover { border-color: #b7c7da; box-shadow: 0 6px 18px rgba(24,39,58,.06); }
.module-tile .tile-icon { font-size: 18px; }
.module-tile strong { display: block; margin-top: 5px; font-size: 12px; }
.module-tile span { display: block; margin-top: 1px; color: var(--muted); font-size: 12px; }
.list { display: grid; gap: 8px; }
.list-row { min-width: 0; display: flex; align-items: center; gap: 11px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.list-row:last-child { border-bottom: 0; }
.list-dot { width: 9px; height: 9px; flex: 0 0 auto; border-radius: 50%; background: var(--blue); }
.list-main { min-width: 0; flex: 1; }
.list-main strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.list-main span { display: block; margin-top: 3px; color: var(--muted); font-size: 12px; }
.status-pill { flex: 0 0 auto; padding: 4px 8px; border-radius: 999px; background: var(--grey-bg); color: var(--grey); font-size: 12px; font-weight: 700; }
.status-pill.ok { color: var(--green); background: var(--green-bg); }
.status-pill.warn { color: var(--yellow); background: var(--yellow-bg); }
.status-pill.bad { color: var(--red); background: var(--red-bg); }
.status-pill.blue { color: var(--blue); background: var(--blue-bg); }
.module-stat { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.module-stat:last-child { border-bottom: 0; }
.module-stat strong { font-size: 12px; }
.module-stat span { color: var(--muted); font-size: 12px; }
.customer-banner { padding: 15px 17px; border: 1px solid #dbe6f2; border-radius: 14px; background: linear-gradient(100deg,#eef5fb,#fff); display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.customer-left { min-width: 0; display: flex; align-items: center; gap: 13px; }
.customer-avatar { width: 43px; height: 43px; flex: 0 0 auto; border-radius: 13px; display: grid; place-items: center; background: #dce8f4; color: var(--navy); font-size: 18px; font-weight: 800; }
.customer-name { font-size: 14px; font-weight: 800; }
.customer-sub { margin-top: 3px; color: var(--muted); font-size: 12px; }
.customer-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.tag { display: inline-flex; align-items: center; gap: 5px; padding: 4px 8px; border-radius: 999px; background: #edf2f7; color: #526278; font-size: 12px; font-weight: 700; }
.tag.orange { color: #9a5516; background: #fff1df; }
.tag.green { color: #176c42; background: #e5f5ec; }
.tag.blue { color: #2e68ad; background: var(--blue-bg); }
.tag.red { color: #a32f2f; background: var(--red-bg); }
.workbench-layout { display: grid; grid-template-columns: minmax(260px,.85fr) minmax(330px,1.15fr) minmax(360px,1.3fr); gap: 13px; align-items: start; margin-top: 14px; }
.workbench-panel { min-width: 0; overflow: hidden; }
.panel-title { padding: 14px 16px 11px; display: flex; align-items: center; justify-content: space-between; gap: 8px; border-bottom: 1px solid var(--line); }
.panel-title h2 { margin: 0; font-size: 12px; font-weight: 800; }
.panel-title .panel-caption { color: var(--muted); font-size: 12px; }
.panel-content { padding: 14px 15px 16px; }
.source-tools { display: flex; gap: 7px; margin-bottom: 12px; }
.source-paper { border: 1px solid #e8ddc9; border-radius: 10px; padding: 12px; background: linear-gradient(#fffdf7,#fffaf0); color: #4c4b46; font-family: "Microsoft YaHei",sans-serif; }
.source-paper img { display: block; width: 100%; max-height: 180px; object-fit: contain; margin: 0 auto 10px; border-radius: 6px; background: #f3efe5; }
.ocr-banner { margin-bottom: 10px; padding: 8px 10px; border-radius: 8px; background: var(--blue-bg); color: #2d619e; font-size: 12px; }
.source-line { padding: 5px 6px; border-left: 2px solid transparent; border-radius: 4px; font-size: 12px; line-height: 1.9; white-space: pre-wrap; }
.source-line.hit { border-left-color: var(--orange); background: #fff1dd; outline: 1px solid #f5c07d; }
.anchor { padding: 1px 5px; border-radius: 5px; color: #2563a8; background: #e9f2ff; font: 700 11px/1.4 var(--font); }
.anchor.hit { color: #fff; background: var(--orange); }
.source-footer { display: flex; justify-content: space-between; gap: 8px; margin-top: 10px; color: var(--muted); font-size: 11px; }
.source-entry { margin-top: 12px; }
.source-entry textarea { width: 100%; min-height: 85px; resize: vertical; padding: 10px; border: 1px solid var(--line); border-radius: 9px; outline-color: #8ea6c2; font-size: 12px; }
.scene-entry-card textarea { width: 100%; min-height: 82px; resize: vertical; padding: 9px; border: 1px solid var(--line); border-radius: 8px; outline-color: #8ea6c2; font-size: 12px; }
.scene-entry-card select { width: 100%; min-height: 34px; padding: 5px 8px; border: 1px solid var(--line); border-radius: 8px; background: #fff; font-size: 12px; }
.field-list { display: grid; gap: 8px; }
.field-card { padding: 10px 11px; border: 1px solid var(--line); border-radius: 10px; background: #fff; cursor: pointer; transition: border .12s ease, box-shadow .12s ease; }
.field-card:hover, .field-card.selected { border-color: #9db3cc; box-shadow: 0 0 0 2px rgba(53,120,200,.08); }
.field-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.field-label { font-size: 12px; font-weight: 800; }
.field-value { margin-top: 7px; display: flex; align-items: center; gap: 7px; }
.field-value input { min-width: 0; flex: 1; padding: 6px 8px; border: 1px solid #e6eaf0; border-radius: 7px; outline-color: #8ea6c2; background: #fbfcfd; font-size: 12px; }
.field-meta { margin-top: 6px; color: var(--muted); font-size: 11px; }
.field-basis { margin-top: 7px; padding: 8px; border-radius: 8px; background: var(--blue-bg); color: #365d8b; font-size: 12px; }
.field-basis strong { display: block; margin-bottom: 3px; color: #245994; }
.field-actions { display: flex; gap: 6px; margin-top: 8px; }
.state { display: inline-flex; align-items: center; gap: 5px; padding: 4px 7px; border-radius: 99px; font-size: 11px; font-weight: 800; white-space: nowrap; }
.state:before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.state.ok { color: var(--green); background: var(--green-bg); }
.state.confirm { color: var(--yellow); background: var(--yellow-bg); }
.state.conflict { color: var(--red); background: var(--red-bg); }
.state.missing { color: var(--grey); background: var(--grey-bg); }
.state.inferred { color: var(--blue); background: var(--blue-bg); }
.actions-column { display: grid; gap: 10px; }
.action-card { padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.action-head { display: flex; align-items: flex-start; gap: 9px; }
.action-icon { width: 31px; height: 31px; flex: 0 0 auto; border-radius: 10px; display: grid; place-items: center; background: #eef3f8; color: var(--navy); }
.action-title { margin: 0; font-size: 12px; font-weight: 800; }
.action-body { margin-top: 7px; color: #4f5c6d; font-size: 12px; white-space: pre-line; }
.action-footer { margin-top: 10px; display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.options-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; margin-top: 12px; }
.option-card { position: relative; min-width: 0; padding: 12px; border: 1px solid var(--line); border-radius: 11px; background: #fff; cursor: pointer; }
.option-card:hover { border-color: #9db3cc; }
.option-card.selected { border: 2px solid var(--navy); padding: 11px; box-shadow: 0 0 0 3px rgba(31,58,95,.08); }
.option-card.recommended { background: linear-gradient(150deg,#f2f7fb,#fff 65%); }
.option-ribbon { position: absolute; top: -8px; right: 10px; padding: 3px 7px; border-radius: 99px; color: #fff; background: var(--orange); font-size: 11px; font-weight: 800; }
.option-title { font-size: 13px; font-weight: 800; }
.option-total { margin-top: 9px; font-size: 21px; font-weight: 900; letter-spacing: -.04em; }
.option-total small { margin-left: 3px; color: var(--muted); font-size: 11px; font-weight: 500; letter-spacing: 0; }
.option-desc { margin-top: 5px; color: var(--muted); font-size: 12px; }
.option-lines { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line); display: grid; gap: 5px; }
.option-line { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; color: #5a6675; font-size: 13px; line-height: 1.5; }
.option-line .ol-name { min-width: 0; flex: 1; }
.option-line .ol-name b { font-size: 12px; }
.option-line .ol-price { flex: 0 0 auto; white-space: nowrap; font-size: 12px; }
.option-count { margin-top: 3px; color: var(--muted); font-size: 12px; }
.more-lines > summary { color: var(--muted); font-size: 12px; }
.option-highlight { margin-top: 8px; padding: 7px 8px; border-radius: 7px; color: #35516f; background: #edf4fa; font-size: 12px; line-height: 1.5; }
.option-drawbacks { margin-top: 6px; color: #9a5516; font-size: 12px; }
.message-preview { margin-top: 10px; width: 100%; min-height: 115px; padding: 10px; border: 1px solid var(--line); border-radius: 9px; resize: vertical; background: #fbfcfd; font-size: 12px; line-height: 1.7; }
.action-kind { display: inline-flex; align-items: center; gap: 5px; color: var(--muted); font-size: 11px; }
.action-status { display: inline-flex; padding: 4px 7px; border-radius: 99px; background: var(--yellow-bg); color: var(--yellow); font-size: 11px; font-weight: 700; }
/* P1-1：老板批过的审批卡只对上一版有效——整卡置灰，别再像对新版仍生效的“已批准” */
.action-card.outdated { opacity: .62; }
.action-card.outdated .action-title { color: var(--muted); }
.task-controls { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-top: 9px; }
.task-controls label { color: var(--muted); font-size: 11px; }
.task-controls input, .task-controls select { width: 100%; min-height: 32px; margin-top: 3px; padding: 5px 7px; border: 1px solid var(--line); border-radius: 7px; background: #fff; font-size: 12px; }
.source-link { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 9px; padding: 8px; border-radius: 8px; background: #f6f8fa; font-size: 12px; }
.block-card { border-color: #edc7c4; background: linear-gradient(145deg,#fff8f7,#fff 75%); }
.block-card .action-icon { background: var(--red-bg); color: var(--red); }
.block-title { color: #9e3030; }
.timeline { position: relative; display: grid; gap: 0; }
.timeline:before { content: ""; position: absolute; left: 9px; top: 11px; bottom: 11px; width: 1px; background: #dce3ea; }
.timeline-item { position: relative; display: grid; grid-template-columns: 19px minmax(0,1fr); gap: 10px; padding: 0 0 18px; }
.timeline-icon { position: relative; z-index: 1; width: 19px; height: 19px; border-radius: 50%; display: grid; place-items: center; border: 1px solid #d7e1ec; background: #fff; color: var(--navy); font-size: 11px; }
.timeline-icon.ok { color: var(--green); border-color: #bfe2cb; background: var(--green-bg); }
.timeline-icon.bad { color: var(--red); border-color: #f1c7c3; background: var(--red-bg); }
.timeline-copy { min-width: 0; }
.timeline-copy strong { display: block; font-size: 12px; }
.timeline-copy span { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.order-grid { display: grid; grid-template-columns: minmax(250px,.65fr) minmax(0,1.35fr); gap: 14px; align-items: start; }
.order-card { width: 100%; padding: 13px; border: 1px solid var(--line); border-radius: 11px; background: #fff; text-align: left; }
.order-card.selected { border-color: var(--navy); box-shadow: 0 0 0 3px rgba(31,58,95,.08); }
.order-card:hover { border-color: #9db3cc; }
.order-card strong { display: block; font-size: 12px; }
.order-card p { margin: 5px 0 8px; color: var(--muted); font-size: 12px; }
.order-card-foot { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
.order-detail { padding: 18px; }
.order-detail h2 { margin: 0; font-size: 17px; }
.order-detail-meta { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 9px; }
.erp-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 12px; margin: 14px 0; border-radius: 10px; background: #f8fafc; }
.erp-status { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 700; }
.erp-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); }
.erp-dot.failed { background: var(--red); box-shadow: 0 0 0 4px rgba(196,65,65,.12); }
.order-sections { display: grid; grid-template-columns: minmax(0,1.05fr) minmax(260px,.8fr); gap: 13px; margin-top: 13px; }
.customer-facts { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; margin-top: 10px; }
.fact { padding: 10px; border-radius: 9px; background: #f7f9fb; }
.fact strong { display: block; font-size: 12px; }
.fact span { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
.industry-chip { padding: 6px 9px; border: 1px solid var(--line); border-radius: 9px; background: #fff; color: var(--muted); font-size: 12px; }
.industry-chip.active { border-color: #b3c3d6; color: var(--navy); background: #edf3f9; font-weight: 800; }
.knowledge-layout { display: grid; grid-template-columns: minmax(0,1fr) minmax(260px,.7fr); gap: 14px; }
.search-row { display: flex; gap: 8px; }
.search-row input { min-width: 0; flex: 1; height: 39px; padding: 0 11px; border: 1px solid var(--line); border-radius: 9px; outline-color: #8ea6c2; background: #fff; font-size: 12px; }
.snippet { padding: 13px 0; border-bottom: 1px solid var(--line); }
.snippet:last-child { border-bottom: 0; }
.snippet p { margin: 0; font-size: 12px; }
.snippet-source { margin-top: 6px; color: var(--muted); font-size: 11px; }
.modal-backdrop { position: fixed; inset: 0; z-index: 30; padding: 18px; display: grid; place-items: center; background: rgba(18,31,48,.5); backdrop-filter: blur(3px); }
.modal { width: min(680px,100%); max-height: min(90vh,900px); overflow: auto; border-radius: 17px; background: #fff; box-shadow: 0 24px 80px rgba(11,24,38,.28); }
.modal-head { position: sticky; top: 0; padding: 17px 20px; border-bottom: 1px solid var(--line); background: #fff; display: flex; align-items: center; justify-content: space-between; z-index: 1; }
.modal-head h2 { margin: 0; font-size: 15px; }
.modal-body { padding: 20px; }
.copy-content { padding: 18px; border: 1px solid #e6ebf0; border-radius: 12px; background: #fbfcfd; color: #344054; font-size: 14px; line-height: 1.9; white-space: pre-wrap; }
.modal-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.toast-root { position: fixed; right: 20px; bottom: 20px; z-index: 50; display: grid; gap: 8px; pointer-events: none; }
.toast { max-width: min(380px,calc(100vw - 40px)); padding: 11px 14px; border-radius: 10px; background: #182b43; color: #fff; box-shadow: 0 10px 30px rgba(11,24,38,.22); font-size: 12px; animation: rise .18s ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.disclaimer { flex: 0 0 auto; min-height: 30px; padding: 7px 16px; border-top: 1px solid #e3e7ed; background: rgba(255,255,255,.96); color: #697586; text-align: center; font-size: 11px; }
.mobile-nav { display: none; }
.empty-state { padding: 25px 14px; color: var(--muted); text-align: center; font-size: 12px; }
.divider { height: 1px; margin: 13px 0; background: var(--line); }
.login-screen { min-height: 100vh; display: grid; grid-template-columns: minmax(0,1.1fr) minmax(390px,.9fr); background: #fff; }
.login-hero { position: relative; min-height: 100vh; padding: clamp(38px,7vw,100px); overflow: hidden; color: #fff; background: linear-gradient(140deg,#1F3A5F 3%,#284c73 56%,#1b304b); display: flex; flex-direction: column; justify-content: space-between; }
.login-hero:before { content: ""; position: absolute; width: 440px; height: 440px; border-radius: 50%; right: -135px; top: 18%; border: 1px solid rgba(255,255,255,.2); box-shadow: 0 0 0 52px rgba(255,255,255,.035), 0 0 0 102px rgba(255,255,255,.025); }
.login-hero:after { content: ""; position: absolute; width: 220px; height: 220px; border-radius: 50%; left: -75px; bottom: -100px; background: rgba(242,140,40,.18); filter: blur(5px); }
.login-hero > * { position: relative; z-index: 1; }
.login-hero .brand-mark { color: var(--navy); }
.hero-copy { max-width: 680px; margin: auto 0; }
.hero-copy .eyebrow { color: #bbcee3; }
.hero-copy h1 { margin: 14px 0; font-size: clamp(38px,5vw,65px); line-height: 1.12; letter-spacing: -.04em; word-break: keep-all; overflow-wrap: break-word; }
.hero-copy h1 em { color: #ffb86a; font-style: normal; }
.hero-copy p { max-width: 520px; color: #d5e2ef; font-size: 14px; line-height: 1.8; }
.hero-foot { color: #aec1d6; font-size: 12px; }
.login-side { display: grid; place-items: center; padding: 30px; background: #fbfcfd; }
.login-box { width: min(440px,100%); padding: 31px; border: 1px solid var(--line); border-radius: 18px; background: #fff; box-shadow: 0 15px 45px rgba(24,39,58,.08); }
.login-box h2 { margin: 0; font-size: 23px; }
.login-box > p { margin: 7px 0 22px; color: var(--muted); font-size: 12px; }
.form-row { display: grid; gap: 6px; margin-bottom: 13px; }
.form-row label { color: #4b5869; font-size: 12px; font-weight: 700; }
.form-row input { width: 100%; height: 42px; padding: 0 12px; border: 1px solid var(--line); border-radius: 9px; outline-color: #8ea6c2; background: #fff; font-size: 12px; }
.login-submit { width: 100%; height: 42px; margin-top: 4px; }
.demo-head { margin: 22px 0 10px; display: flex; justify-content: space-between; align-items: center; color: var(--muted); font-size: 12px; }
.demo-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.demo-account { min-width: 0; padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: #fff; text-align: left; }
.demo-account:hover { border-color: #9eb3ca; background: #f8fafc; }
.demo-account strong { display: block; font-size: 12px; }
.demo-account span { display: block; overflow: hidden; margin-top: 2px; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.demo-account .mini-role { display: inline-flex; margin-top: 6px; color: var(--navy); }
.login-mode { margin-top: 13px; padding: 9px 10px; border-radius: 8px; color: #426184; background: #eef4fa; font-size: 11px; }
.form-error { min-height: 17px; margin: 3px 0 0; color: var(--red); font-size: 12px; }
.drawer-backdrop { position: fixed; inset: 0; z-index: 25; background: rgba(18,31,48,.36); }
.knowledge-drawer { position: absolute; top: 0; right: 0; width: min(620px,92vw); height: 100%; display: flex; flex-direction: column; background: #fff; box-shadow: -16px 0 50px rgba(13,27,44,.17); animation: slide-in .18s ease-out; }
.drawer-head { padding: 18px 20px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.drawer-head h2 { margin: 4px 0 0; font-size: 18px; }
.drawer-content { min-height: 0; padding: 18px 20px; overflow: auto; }
.drawer-tabs { display: flex; gap: 7px; margin-top: 14px; }
.drawer-list { margin-top: 12px; }
@keyframes slide-in { from { transform: translateX(16px); opacity: .7; } to { transform: translateX(0); opacity: 1; } }

@media (min-width: 1900px) {
  .content { max-width: 2200px; padding-left: 42px; padding-right: 42px; }
  .workbench-layout { grid-template-columns: minmax(360px,.82fr) minmax(480px,1.08fr) minmax(560px,1.3fr); gap: 17px; }
  .panel-content { padding: 18px 19px 20px; }
  .field-list { gap: 10px; }
  .action-card { padding: 17px; }
}
@media (max-width: 1250px) {
  .app-shell { grid-template-columns: 204px minmax(0,1fr); }
  .sidebar { padding-left: 12px; padding-right: 12px; }
  .topbar { padding: 0 20px; }
  .content { padding: 22px 20px 85px; }
  .workbench-layout { grid-template-columns: minmax(220px,.8fr) minmax(270px,1fr); }
  .workbench-layout > :last-child { grid-column: 1 / -1; }
  .actions-column { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .dash-grid { grid-template-columns: minmax(0,1.2fr) minmax(250px,.8fr); }
}
@media (max-width: 850px) {
  .app-shell { display: flex; flex-direction: column; height: 100vh; height: 100dvh; }
  .sidebar { display: none; }
  .main-area { flex: 1 1 auto; height: auto; }
  .topbar { flex: 0 0 61px; height: 61px; padding: 0 14px; }
  .top-search { display: none; }
  .topbar-left { gap: 8px; }
  .topbar-right { gap: 7px; }
  .industry-select { min-width: 82px; height: 34px; padding: 0 7px; font-size: 10px; }
  .user-chip { padding: 3px 5px; border: 0; }
  .user-chip .avatar { width: 29px; height: 29px; }
  .user-role { display: none; }
  .content { width: 100%; max-width: none; flex: 1 1 auto; padding: 19px 14px 93px; }
  .page-heading { align-items: flex-start; }
  .page-heading p { max-width: 95%; }
  .stats-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
  .stat-card { padding: 13px; }
  .stat-value { font-size: 22px; }
  .dash-grid, .order-grid, .order-sections, .knowledge-layout { grid-template-columns: 1fr; }
  .module-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .workbench-layout { grid-template-columns: 1fr; }
  .workbench-layout > :last-child { grid-column: auto; }
  .actions-column { grid-template-columns: 1fr; }
  .mobile-nav { position: fixed; left: 0; right: 0; bottom: 30px; z-index: 12; display: flex; justify-content: space-around; gap: 4px; padding: 8px 5px 7px; border-top: 1px solid var(--line); background: rgba(255,255,255,.97); backdrop-filter: blur(12px); }
  .mobile-nav .nav-link { width: auto; min-width: 58px; padding: 5px 8px; display: grid; justify-items: center; gap: 1px; color: var(--muted); font-size: 9px; }
  .mobile-nav .nav-link.active { color: var(--navy); background: #eef3f8; box-shadow: none; }
  .mobile-nav .nav-icon { font-size: 15px; }
  .mobile-nav .nav-label-text { white-space: nowrap; }
  .disclaimer { padding: 7px 8px; font-size: 8px; line-height: 1.35; }
}
@media (max-width: 520px) {
  .topbar .page-kicker { display: none; }
  .page-name { font-size: 14px; }
  .topbar .user-name { max-width: 66px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 10px; }
  .topbar .user-chip { padding: 2px; }
  .icon-button { width: 31px; height: 31px; }
  .page-heading { display: block; }
  .heading-actions { margin-top: 12px; }
  .welcome-card { padding: 20px; }
  .welcome-card h2 { font-size: 22px; }
  .customer-banner { align-items: flex-start; padding: 12px; }
  .customer-left { align-items: flex-start; gap: 9px; }
  .customer-avatar { width: 36px; height: 36px; border-radius: 11px; font-size: 15px; }
  .customer-name { font-size: 11px; line-height: 1.4; }
  .customer-sub { font-size: 9px; }
  .customer-banner > .customer-tags { display: none; }
  .panel-title { padding: 12px; }
  .panel-content { padding: 12px; }
  .options-grid { grid-template-columns: 1fr; gap: 12px; }
  .option-card { padding: 13px; }
  .option-card.selected { padding: 12px; }
  .option-total { font-size: 23px; }
  .field-card { padding: 9px; }
  .task-controls { grid-template-columns: 1fr; }
  .order-detail { padding: 14px; }
  .customer-facts { grid-template-columns: 1fr; }
  .login-screen { display: block; }
  .login-hero { display: none; }
  .login-side { min-height: 100vh; padding: 20px 14px; }
  .login-box { padding: 23px 19px; }
}

/* ---- 真后台模式补充（L-Web3） ---- */
.hero-tile { border-color: rgba(255,255,255,.18); background: rgba(255,255,255,.08); color: #fff; }
.hero-tile span { color: #c8d7e7; }
.login-brand-mobile { display: none; }
.seed-line { margin-top: 10px; padding: 8px 10px; border-radius: 8px; background: var(--yellow-bg); color: var(--yellow); font-size: 12px; }
.seed-line.ok { background: var(--green-bg); color: var(--green); }
.seed-line.bad { background: var(--red-bg); color: var(--red); }
.seed-banner { margin-bottom: 14px; padding: 10px 13px; border-radius: 10px; background: var(--yellow-bg); color: var(--yellow); font-size: 12px; font-weight: 700; }
.seed-banner.bad { background: var(--red-bg); color: var(--red); }
.list-button { width: 100%; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; }
.button-row { display: inline-flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
.job-tabs { display: flex; gap: 8px; margin: 2px 0 12px; overflow-x: auto; padding-bottom: 2px; }
.job-tab { flex: 0 0 auto; max-width: 260px; display: grid; gap: 2px; padding: 8px 11px; border: 1px solid var(--line); border-radius: 10px; background: #fff; text-align: left; }
.job-tab strong { font-size: 12px; color: var(--navy); }
.job-tab span { overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.job-tab em { font-style: normal; color: var(--yellow); font-size: 11px; font-weight: 700; }
.job-tab em.bad { color: var(--red); }
.job-tab.active { border: 2px solid var(--navy); padding: 7px 10px; box-shadow: 0 0 0 3px rgba(31,58,95,.08); }
.live-card { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; padding: 13px 15px; border-color: #c9d9ec; background: var(--blue-bg); }
.live-card strong { display: block; color: var(--navy); font-size: 12px; }
.live-card span { display: block; margin-top: 3px; color: #365d8b; font-size: 12px; }
.live-spinner { width: 22px; height: 22px; flex: 0 0 auto; border: 3px solid #c9d9ec; border-top-color: var(--blue); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.live-done { margin-bottom: 12px; padding: 9px 12px; border-radius: 10px; background: var(--green-bg); color: var(--green); font-size: 12px; font-weight: 700; }
.line-price { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-size: 12px; }
.line-price input { width: 74px; padding: 4px 6px; border: 1px solid #c9d4e1; border-radius: 6px; background: #fff; font-size: 12px; text-align: right; }
.option-diff { margin: -2px 0 3px; color: var(--muted); font-size: 11px; line-height: 1.4; }
.option-margin { margin-top: 4px; color: #176c42; font-size: 12px; font-weight: 700; }
.margin-note { color: #176c42; font-style: normal; font-size: 12px; }
.timeline-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 5px; }
.field-readonly { padding: 6px 0; font-size: 12px; font-weight: 700; color: var(--ink, #1c2735); }
.field-card.inferred { border-color: #b9d2ee; background: #f7fbff; }
.message-preview.readonly { white-space: pre-wrap; }
.action-status.ok { background: var(--green-bg); color: var(--green); }
.action-status.bad { background: var(--red-bg); color: var(--red); }
.erp-dot.none { background: var(--grey, #9aa5b4); }
.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.data-table th { padding: 9px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 12px; text-align: left; }
.data-table td { padding: 10px 9px; border-bottom: 1px solid var(--line); vertical-align: top; }
.data-table .num { text-align: right; }
.data-table td.bad { color: var(--red); font-weight: 800; }
.stock-toolbar { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.stock-search { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }
.stock-search input { width: min(280px, 42vw); min-width: 170px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); }
.stock-note { margin: 0 0 10px; padding: 8px 10px; border-radius: 8px; background: var(--grey-bg); color: var(--muted); font-size: 12px; }
.stock-card .data-table td small { display: block; margin-top: 3px; color: var(--muted); font-size: 12px; }
.stock-more { margin-top: 10px; }
.stock-card { margin-top: 14px; }
.stock-card .stock-toolbar { padding: 14px 16px 0; }
.stock-card .stock-note { margin: 0 16px 10px; }
.stock-card .stock-more { margin: 10px 16px 14px; }
@media (max-width: 520px) {
  .stock-toolbar { align-items: stretch; flex-direction: column; }
  .stock-search { align-items: stretch; flex-direction: column; gap: 4px; }
  .stock-search input { width: 100%; min-width: 0; }
}
.source-entry .form-row label, .scene-entry-card .form-row label { font-size: 12px; }
.source-entry select { width: 100%; min-height: 32px; padding: 4px 8px; border: 1px solid var(--line); border-radius: 8px; background: #fff; font-size: 12px; }
.source-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; }
@media (max-width: 520px) {
  .login-brand-mobile { display: block; margin-bottom: 14px; color: var(--navy); }
  .login-brand-mobile strong { display: block; font-size: 18px; }
  .login-brand-mobile span { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
  .job-tab { max-width: 70vw; }
  .line-price input { width: 64px; }
  .button-row { justify-content: flex-start; }
  .action-footer { flex-wrap: wrap; }
}
.option-why { margin-bottom: 8px; }
.option-explain { margin: 0 0 10px; }
.option-explain summary { cursor: pointer; color: var(--blue); font-size: 12px; font-weight: 700; }
.option-explain .message-preview { margin-top: 6px; max-height: 260px; overflow: auto; font-size: 12px; }
@media (max-width: 520px) {
  .topbar .page-name { max-width: 30vw; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
}

/* ---------- L-Web4：切换岗位、老板后台、两可确认、先拦再查、新客福利 ---------- */
.switch-role { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.switch-banner { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; padding: 10px 12px; border: 1px solid #c9d9ec; border-radius: 11px; background: var(--blue-bg); }
.switch-banner > div:nth-child(2) { flex: 1; min-width: 0; }
.switch-banner strong { display: block; color: var(--navy); font-size: 12px; }
.switch-banner span { display: block; color: var(--muted); font-size: 12px; }
.switch-spinner { width: 18px; height: 18px; flex: 0 0 auto; border: 3px solid #c9d9ec; border-top-color: var(--blue); border-radius: 50%; animation: spin .8s linear infinite; }
#login-form.is-switching input { border-color: #8ea6c2; background: #fbfdff; }
#login-form.is-switching input#login-password { letter-spacing: 3px; }
.switch-grid { grid-template-columns: repeat(auto-fit, minmax(min(150px, 100%), 1fr)); }
.switch-grid .demo-account:disabled { opacity: .55; }
.copy-buffer { position: fixed; top: -1000px; left: -1000px; opacity: 0; }

.choice-banner { display: flex; align-items: center; gap: 12px; margin: 0 0 14px; padding: 12px 14px; border: 1px solid #f3cf9f; border-radius: 12px; background: #fff8ee; }
.choice-mark { width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 9px; background: var(--orange); color: #fff; font-weight: 800; }
.choice-copy { flex: 1; min-width: 0; }
.choice-copy strong { display: block; font-size: 13px; }
.choice-copy span { display: block; margin-top: 2px; color: #8a5a17; font-size: 12px; }
.blocked-note { display: inline-flex; align-items: center; padding: 3px 8px; border-radius: 8px; background: #fff3e3; color: #9a5b12; font-size: 12px; font-weight: 700; }
.choice-quote { margin-bottom: 12px; padding: 10px 12px; border-left: 3px solid var(--orange); border-radius: 0 9px 9px 0; background: #fbfcfd; color: #344054; font-size: 13px; }
.choice-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 10px; }
.choice-option { display: grid; gap: 4px; padding: 16px; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; text-align: left; }
.choice-option:hover { border-color: var(--orange); box-shadow: 0 6px 18px rgba(242,140,40,.15); }
.choice-option strong { color: var(--navy); font-size: 18px; }
.choice-option span { color: var(--muted); font-size: 12px; }
.choice-foot { margin-top: 12px; color: var(--muted); font-size: 12px; }

.coupon-card { position: relative; display: flex; align-items: stretch; margin-top: 12px; overflow: hidden; border: 1px solid #f3cf9f; border-radius: 12px; background: linear-gradient(110deg, #fff7ec, #fff 70%); }
.coupon-value { display: grid; place-content: center; min-width: 92px; padding: 10px 12px; border-right: 1.5px dashed #f3cf9f; color: #c2410c; text-align: center; }
.coupon-value b { font-size: 22px; line-height: 1.1; }
.coupon-value small { font-size: 12px; }
.coupon-copy { display: grid; gap: 1px; padding: 10px 12px; min-width: 0; }
.coupon-copy strong { font-size: 13px; }
.coupon-copy span { color: #6b4b2a; font-size: 12px; }
.coupon-tag { position: absolute; top: 8px; right: 8px; padding: 2px 7px; border-radius: 999px; background: var(--orange); color: #fff; font-size: 11px; font-weight: 800; }
.coupon-note { margin-top: 5px; color: var(--muted); font-size: 12px; }
.draft-coupon { margin-top: 7px; padding: 6px 9px; border-radius: 8px; background: #fff7ec; color: #9a5b12; font-size: 12px; }
.coupon-preview { margin-top: 6px; padding: 12px; border: 1px dashed var(--line); border-radius: 12px; background: #fbfcfd; }
.coupon-preview .coupon-card { margin-top: 0; }
.preview-label { margin-top: 10px; color: var(--muted); font-size: 12px; font-weight: 700; }
.preview-text { margin-top: 4px; color: #344054; font-size: 12px; line-height: 1.8; }
.coupon-off { margin-bottom: 8px; color: var(--muted); font-size: 12px; }

.block-lines { display: grid; gap: 6px; margin-top: 9px; }
.block-line { display: grid; grid-template-columns: 66px 1fr; gap: 8px; padding: 8px 10px; border-radius: 9px; background: var(--red-bg); font-size: 12px; }
.block-line em { color: var(--red); font-style: normal; font-weight: 800; }
.block-line.ok { background: var(--green-bg); }
.block-line.ok em { color: var(--green); }
.block-fast { margin-top: 8px; color: var(--blue); font-size: 12px; font-weight: 700; }
.stage-card { padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: #fbfcfd; }
.stage-list { display: grid; gap: 8px; margin-top: 8px; }
.stage-row { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 12px; }
.stage-row em { margin-left: auto; color: var(--muted); font-size: 12px; font-style: normal; }
.stage-icon { width: 18px; height: 18px; flex: 0 0 auto; display: grid; place-items: center; border: 2px solid #d5dde8; border-radius: 50%; font-size: 12px; font-weight: 800; }
.stage-row.done { color: var(--ink); }
.stage-row.done .stage-icon { border-color: var(--green); background: var(--green); color: #fff; }
.stage-row.running { color: var(--navy); font-weight: 700; }
.stage-row.running .stage-icon { border-color: #c9d9ec; border-top-color: var(--blue); animation: spin .8s linear infinite; }
.stage-row.error { color: var(--red); }
.stage-row.error .stage-icon { border-color: var(--red); color: var(--red); }

.admin-tabs { display: flex; gap: 6px; margin: 0 0 12px; overflow-x: auto; }
.admin-tab { flex: 0 0 auto; padding: 8px 14px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--muted); font-weight: 700; }
.admin-tab.active { border-color: var(--navy); background: var(--navy); color: #fff; }
.settings-pack { margin: 0 0 12px; color: var(--muted); font-size: 12px; }
.settings-card .card-body { display: grid; gap: 12px; }
.settings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 14px; }
.setting { display: grid; gap: 6px; align-content: start; }
.setting-label { color: #4b5869; font-size: 12px; font-weight: 800; }
.setting-help { color: var(--muted); font-size: 12px; line-height: 1.6; }
.input-suffix { display: flex; align-items: center; height: 40px; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.input-suffix:focus-within { border-color: #8ea6c2; }
.input-suffix input { width: 100%; min-width: 0; height: 100%; padding: 0 10px; border: 0; border-radius: 9px; background: transparent; outline: none; }
.input-suffix em { padding: 0 10px; color: var(--muted); font-size: 12px; font-style: normal; white-space: nowrap; }
.setting-input { width: 100%; min-height: 40px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.coupon-text { min-height: 74px; resize: vertical; line-height: 1.7; }
.tier-inputs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.tier-inputs label { display: grid; gap: 3px; }
.tier-inputs label > span { color: var(--muted); font-size: 12px; }
.sku-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.sku-head strong { display: block; font-size: 13px; }
.sku-head span { display: block; color: var(--muted); font-size: 12px; }
.sku-search { width: min(280px, 100%); height: 38px; padding: 0 12px; border: 1px solid var(--line); border-radius: 9px; }
.sku-table-wrap { max-height: 460px; overflow: auto; border: 1px solid var(--line); border-radius: 10px; }
.sku-table th { position: sticky; top: 0; z-index: 1; background: #fff; }
.sku-table tr.changed td { background: #fffaf0; }
.sku-floor-input { width: 110px; height: 34px; padding: 0 8px; border: 1px solid var(--line); border-radius: 8px; }
.sku-add { display: flex; gap: 8px; flex-wrap: wrap; }
.sku-add input { flex: 1; min-width: 160px; height: 34px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; }
.settings-foot { display: flex; align-items: center; justify-content: flex-end; gap: 12px; flex-wrap: wrap; padding-top: 4px; }
.settings-status { color: var(--muted); font-size: 12px; font-weight: 700; }
.settings-status.ok { color: var(--green); }
.settings-status.bad { color: var(--red); }
.settings-status.warn { color: #9a5b12; }
.switch-row { position: relative; display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }
.switch-row input { position: absolute; opacity: 0; pointer-events: none; }
.switch-ui { position: relative; width: 42px; height: 24px; flex: 0 0 auto; border-radius: 999px; background: #cfd6df; transition: background .15s; }
.switch-ui:after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .15s; }
.switch-row input:checked + .switch-ui { background: var(--green); }
.switch-row input:checked + .switch-ui:after { transform: translateX(18px); }
.switch-row input:focus-visible + .switch-ui { outline: 2px solid #8ea6c2; outline-offset: 2px; }
.switch-row strong { display: block; font-size: 13px; }
.switch-row small { display: block; color: var(--muted); font-size: 12px; }
@media (max-width: 520px) {
  .switch-role { min-height: 31px; padding: 4px 7px; }
  .switch-role .switch-label { display: none; }
  .choice-banner { flex-wrap: wrap; }
  .choice-option strong { font-size: 16px; }
  .block-line { grid-template-columns: 1fr; gap: 2px; }
  .sku-floor-input { width: 84px; }
  .sku-table th:nth-child(3), .sku-table td:nth-child(3) { display: none; }
  .settings-foot { justify-content: space-between; }
}

/* 处理中的作业：两栏（原文 + 分段回复），手机上拦截卡排在最前 */
.workbench-layout.staged-layout { grid-template-columns: minmax(260px,.85fr) minmax(0,2fr); }
.workbench-layout.staged-layout > :last-child { grid-column: auto; }
@media (max-width: 850px) {
  .workbench-layout.staged-layout { grid-template-columns: 1fr; }
  .workbench-layout.staged-layout > .staged-panel { order: -1; }
}
.settings-status[data-settings-warn] { flex-basis: 100%; text-align: right; font-weight: 600; line-height: 1.5; }
.export-modal .choice-option span { font-weight: 500; }

/* ---------- L-Web4 补充：操作日志（17.8.4）、手机顶栏的切换岗位 ---------- */
.switch-role .switch-label-short { display: none; }
.oplog-layout { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 14px; align-items: start; }
.oplog-head { flex-wrap: wrap; gap: 10px; }
.oplog-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.oplog-toggle { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 999px; font-size: 12px; font-weight: 700; cursor: pointer; }
.oplog-toggle b { min-width: 18px; padding: 1px 6px; border-radius: 999px; background: var(--red-bg); color: #a32f2f; text-align: center; font-size: 12px; }
.oplog-action { width: auto; min-width: 120px; height: 32px; padding: 0 8px; font-size: 12px; }
.oplog-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.oplog-row { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 12px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 11px; background: #fff; }
.oplog-row.denied { border-color: #efc2c2; background: #fff7f7; }
.oplog-time { color: var(--muted); font-size: 12px; font-weight: 700; line-height: 1.5; }
.oplog-main strong { display: block; font-size: 13px; line-height: 1.45; }
.oplog-row.denied .oplog-sentence { color: #a32f2f; }
.oplog-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 5px; font-size: 12px; }
.oplog-who { font-weight: 700; }
.oplog-path { max-width: 100%; overflow-wrap: anywhere; padding: 1px 6px; border-radius: 6px; background: #f2f5f9; color: #3b4b61; font-size: 12px; }
.oplog-reason { margin-top: 4px; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
@media (max-width: 1250px) {
  .oplog-layout { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .topbar { padding: 0 10px; gap: 6px; }
  .topbar-right { gap: 5px; }
  .topbar .page-name { max-width: 24vw; }
  .industry-select { min-width: 0; width: 62px; padding: 0 4px; }
  .topbar .user-chip > div:last-child { display: none; }
  .topbar .user-chip .avatar { width: 29px; height: 29px; }
  .switch-role { padding: 4px 8px; }
  .switch-role .switch-label-short { display: inline; }
  .oplog-row { grid-template-columns: 1fr; gap: 4px; }
  .oplog-tools { width: 100%; }
  .oplog-action { flex: 1 1 120px; }
}
.timeline-icon.skip { color: #8a96a8; border-color: #d5dbe3; background: #f1f3f6; }
.timeline-item.skipped .timeline-copy strong { color: #5f6b7c; }

/* L-Web6：收紧首页与工作台布局，同时保留折叠项的摘要入口。 */
.content { padding: 18px 24px 72px; }
.page-heading { margin-bottom: 11px; }
.page-tools { min-height: 28px; display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 10px; }
.page-tools-left, .page-tools-right { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.home-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 10px; }
.greet { min-width: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 6px 8px; }
.greet > strong { font-size: 18px; line-height: 1.25; }
.greet-pack { color: var(--muted); font-size: 12px; }
.home-chips { display: flex; justify-content: flex-end; gap: 6px; flex-wrap: wrap; }
.chip-btn { min-height: 32px; padding: 5px 9px; display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--line); border-radius: 9px; background: #fff; color: var(--navy); font-size: 12px; font-weight: 700; }
.chip-btn .cs { display: none; }
.stat-strip { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 7px; margin: 0 0 9px; }
.stat-strip-title { grid-column: 1 / -1; color: var(--muted); font-size: 12px; font-weight: 800; }
.stat-chip { min-width: 0; min-height: 52px; padding: 7px 10px; display: grid; grid-template-columns: minmax(0,1fr) auto; align-content: center; align-items: center; gap: 1px 7px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); text-align: left; }
.stat-chip-label { overflow: hidden; color: var(--muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.stat-chip b { grid-row: 1 / 3; grid-column: 2; font-size: 20px; line-height: 1; }
.stat-chip .stat-go { display: none; }
.stat-chip.warn { border-color: #f0dbb7; background: #fffaf0; }
.module-strip { margin: 0 0 10px; border: 1px solid var(--line); border-radius: 10px; background: rgba(255,255,255,.82); }
.module-strip > summary { min-height: 34px; padding: 7px 11px; color: #536174; font-size: 12px; font-weight: 700; cursor: pointer; }
.module-links { padding: 0 8px 8px; display: flex; gap: 6px; flex-wrap: wrap; }
.module-link { min-height: 30px; padding: 4px 8px; display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: #42536a; font-size: 12px; }
.module-link strong { font-size: 12px; }
.module-link.perm { color: var(--muted); background: #f6f7f9; }
.home-grid { display: grid; grid-template-columns: minmax(0,1.05fr) minmax(300px,.95fr); gap: 11px; align-items: start; }
.home-grid.single { grid-template-columns: 1fr; }
.home-col { min-width: 0; display: grid; align-content: start; gap: 10px; }
.mini-card, .home-card { overflow: hidden; }
.mini-head { min-height: 39px; padding: 9px 13px 7px; display: flex; align-items: center; justify-content: space-between; gap: 9px; }
.mini-head .card-title { font-size: 12px; }
.mini-body { padding: 0 13px 8px; }
.mini-row { min-width: 0; width: 100%; min-height: 38px; padding: 6px 0; display: flex; align-items: center; justify-content: space-between; gap: 8px; border: 0; border-bottom: 1px solid #eef1f4; background: transparent; text-align: left; }
.mini-row:last-child { border-bottom: 0; }
.mini-main { min-width: 0; flex: 1; display: grid; gap: 1px; }
.mini-main strong, .mini-main > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-main strong { font-size: 12px; }
.mini-main > span { color: var(--muted); font-size: 12px; }
.mini-right, .mini-note { flex: 0 0 auto; color: var(--muted); font-size: 12px; }
.todo-list { margin: 0; padding: 0 13px; list-style: none; }
.todo-row { min-width: 0; display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 4px 8px; padding: 7px 0; border-bottom: 1px solid #eef1f4; }
.todo-row:last-child { border-bottom: 0; }
.todo-main { min-width: 0; padding: 0; display: grid; gap: 1px; border: 0; background: transparent; text-align: left; }
.todo-main strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.todo-main > span { display: -webkit-box; overflow: hidden; color: var(--muted); font-size: 12px; line-height: 1.4; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.todo-row > .btn { flex: 0 0 auto; }
.more-link-inline { margin: 0 13px 8px; }

.wb-top { min-height: 34px; display: flex; align-items: center; gap: 8px; margin: 0 0 8px; }
.wb-top-right { margin-left: auto; }
.wb-tabs { min-width: 0; display: flex; align-items: center; gap: 5px; overflow-x: auto; }
.wb-banner { min-height: 55px; margin: 0 0 8px; padding: 8px 12px; justify-content: flex-start; gap: 10px; }
.wb-banner .customer-avatar { width: 34px; height: 34px; border-radius: 10px; font-size: 15px; }
.wb-banner .customer-name { font-size: 12px; }
.wb-banner .wb-meta { min-width: 0; overflow: hidden; color: var(--muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.wb-look-pill { margin-left: auto; }
.wb-grid { display: grid; grid-template-columns: minmax(0,1.25fr) minmax(300px,.82fr); gap: 11px; align-items: start; }
.wb-main, .wb-side { min-width: 0; display: grid; align-content: start; gap: 9px; }
.wb-main .action-card { padding: 11px; }
.wb-main .action-head { gap: 7px; }
.wb-main .action-icon { width: 27px; height: 27px; border-radius: 8px; }
.wb-main .action-title { font-size: 12px; }
.wb-side .side-card { min-width: 0; padding: 11px; overflow: hidden; }
.side-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin: 0 0 8px; }
.side-head h2 { margin: 0; font-size: 14px; }
.side-sub { color: var(--muted); font-size: 12px; line-height: 1.45; }
.review-list { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.review-row { padding: 9px 10px; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.frow-top { display: flex; align-items: center; flex-wrap: wrap; gap: 5px 7px; }
.flabel { color: var(--ink); font-size: 12px; font-weight: 700; line-height: 1.4; }
.frow-val { margin-top: 6px; }
.wb-side .cell { appearance: none; display: block; width: 100%; min-height: 34px; padding: 7px 9px; border: 1px solid #c7d2df; border-radius: 8px; outline: 0; background: #fbfcfd; color: var(--ink); font: inherit; font-size: 13px; line-height: 1.4; text-align: left; cursor: text; }
.wb-side .cell:hover { border-color: #91a9c4; background: #fff; }
.wb-side .cell:focus-visible { outline: 2px solid rgba(53,120,200,.45); outline-offset: 1px; }
.wb-side .cell em { color: var(--muted); font-style: normal; }
.wb-side .cell.ro { min-height: 0; padding: 3px 0; border: 0; background: transparent; cursor: default; }
.wb-side .state { padding: 3px 7px; font-size: 12px; }
.wb-side .frow-why { margin-top: 5px; color: #4f5c6d; font-size: 12px; line-height: 1.5; }
.wb-side .field-basis { margin-top: 6px; padding: 7px 9px; font-size: 12px; line-height: 1.5; }
.wb-side .field-basis summary { font-size: 12px; font-weight: 700; }
.wb-side .field-basis > span { display: block; margin-top: 4px; }
.inferred-summary { margin-top: 8px; border: 1px solid #d5e3f0; border-radius: 9px; background: #f7fbff; }
.inferred-summary-head { padding: 9px 10px 6px; color: #315a84; font-size: 13px; font-weight: 700; }
.inferred-items { display: grid; gap: 0; padding: 0 9px 5px; }
.inferred-item { border-top: 1px solid #e1eaf3; }
.inferred-item > summary { display: grid; grid-template-columns: auto minmax(0,1fr); align-items: baseline; gap: 3px 8px; padding: 8px 1px; cursor: pointer; }
.inferred-item > summary strong { color: #315a84; font-size: 12px; }
.inferred-values { min-width: 0; color: var(--ink); font-size: 13px; line-height: 1.45; overflow-wrap: anywhere; }
.inferred-basis-label { grid-column: 2; color: var(--muted); font-size: 12px; }
.inferred-field-list { padding: 0 2px 5px; }
.inferred-field-detail { padding: 7px 0; border-top: 1px solid #edf1f5; }
.inferred-field-top { display: grid; grid-template-columns: minmax(65px,.7fr) auto minmax(90px,1.3fr); align-items: center; gap: 5px 7px; }
.inferred-field-label { color: var(--muted); font-size: 12px; }
.inferred-field-top .state { justify-self: start; }
.inferred-field-value { min-width: 0; }
.inferred-field-top .anchor-link { grid-column: 3; justify-self: start; }
.inferred-original, .inferred-basis-missing { margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.inferred-basis-missing { color: #8a5a17; }
.draft-meaning { margin-top: 5px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.source-first { max-height: 118px; overflow: auto; color: #4c4b46; font-size: 12px; line-height: 1.55; white-space: pre-wrap; }
.source-card .source-paper { max-height: 360px; overflow: auto; font-size: 12px; }
.source-card .side-head { margin-bottom: 6px; }
.wb-bar { position: sticky; top: 7px; z-index: 7; min-height: 48px; margin: 0 0 9px; padding: 7px 9px; display: flex; align-items: center; justify-content: space-between; gap: 9px; border: 1px solid #d7e2ef; border-radius: 11px; background: rgba(255,255,255,.97); box-shadow: 0 5px 18px rgba(24,39,58,.1); }
.wb-bar-info { min-width: 0; flex: 1; color: #526278; font-size: 12px; }
.wb-bar-buttons { display: flex; align-items: center; justify-content: flex-end; gap: 6px; flex-wrap: wrap; }
.wb-bar .btn { min-height: 32px; }
.job-shortages { padding: 10px 12px; }
.job-shortages .mini-head { min-height: 28px; padding: 0 0 6px; }
.job-shortage-list { display: grid; gap: 5px; margin: 0; padding: 0; list-style: none; }
.job-shortage-list li { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 2px 8px; padding: 6px 0; border-top: 1px solid #eef1f4; font-size: 12px; }
.job-shortage-list li strong { min-width: 0; overflow-wrap: anywhere; }
.job-shortage-list li small { color: var(--muted); font-weight: 500; }
.job-shortage-sources { grid-column: 1 / -1; color: var(--muted); font-size: 11px; }
.job-shortage-sources .tag { margin-right: 3px; padding: 2px 6px; font-size: 11px; }
.order-lines { margin: 10px 0; padding: 0 10px 7px; }
.order-lines .mini-head { padding-left: 2px; }
.order-lines .table-wrap { overflow-x: auto; }
.order-lines .data-table { min-width: 420px; }
.order-lines .data-table th, .order-lines .data-table td { padding: 6px 7px; }

@media (max-width: 1000px) {
  .content { padding-left: 18px; padding-right: 18px; }
  .home-grid { grid-template-columns: minmax(0,1fr) minmax(260px,.9fr); }
  .wb-grid { grid-template-columns: minmax(0,1.15fr) minmax(280px,.85fr); }
}
@media (max-width: 850px) {
  .content { padding: 14px 14px 150px; }
  .home-head { align-items: flex-start; }
  .home-grid { grid-template-columns: 1fr; }
  .wb-grid { grid-template-columns: 1fr; }
  .wb-side { order: 2; }
  .wb-bar { position: sticky; top: 0; bottom: auto; z-index: 20; margin: 0 0 9px; padding: 8px; }
  .wb-bar-info { font-size: 9px; }
  .wb-bar .btn { min-height: 34px; }
  .toast-root { right: 10px; bottom: calc(94px + env(safe-area-inset-bottom)); }
  .mobile-nav { bottom: 30px; }
}
@media (max-width: 520px) {
  .content { padding: 12px 10px 150px; }
  .topbar { padding-right: 5px; padding-left: 5px; gap: 3px; }
  .topbar-left { min-width: 0; flex: 1 1 auto; }
  .topbar-title { min-width: 0; }
  .topbar-right { min-width: 0; flex: 0 0 auto; gap: 3px; }
  .topbar .page-name { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .topbar .new-msg { width: 30px; min-width: 30px; padding: 4px; }
  .topbar .new-msg-label { display: none; }
  .topbar .industry-select { width: 49px; min-width: 0; padding: 0 3px; }
  .topbar .drawer-icon, .topbar [data-logout] { width: 28px; height: 30px; }
  .topbar .user-chip .avatar { width: 26px; height: 26px; }
  .topbar .switch-role { min-width: 0; padding: 4px; }
  .page-heading { margin-bottom: 9px; }
  .page-tools { margin-bottom: 8px; }
  .home-head { display: grid; gap: 7px; margin-bottom: 8px; }
  .greet > strong { font-size: 16px; }
  .home-chips { justify-content: flex-start; }
  .chip-btn { min-height: 29px; padding: 4px 7px; font-size: 10px; }
  .chip-btn .cl { display: none; }
  .chip-btn .cs { display: inline; }
  .stat-strip { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 6px; margin-bottom: 7px; }
  .stat-chip { min-height: 43px; padding: 6px 8px; }
  .stat-chip b { font-size: 18px; }
  .module-strip { margin-bottom: 8px; }
  .home-col { gap: 8px; }
  .mini-head { min-height: 35px; padding: 7px 10px 5px; }
  .mini-body { padding: 0 10px 6px; }
  .mini-row { min-height: 34px; padding: 5px 0; }
  .todo-list { padding: 0 10px; }
  .todo-row { padding: 6px 0; }
  .todo-main > span { -webkit-line-clamp: 1; }
  .todo-row > .btn { min-height: 28px; padding: 4px 6px; }
  .more-link-inline { margin-left: 10px; }
  .wb-top { margin-bottom: 6px; }
  .wb-banner { min-height: 47px; padding: 6px 8px; gap: 6px; flex-wrap: wrap; }
  .wb-banner .customer-avatar { width: 29px; height: 29px; }
  .wb-banner .wb-meta { flex-basis: 100%; margin-left: 35px; }
  .wb-look-pill { margin-left: auto; padding: 4px 7px; font-size: 9px; }
  .wb-main, .wb-side { gap: 8px; }
  .wb-main .action-card { padding: 9px; }
  .wb-bar { align-items: center; }
  .wb-bar-info { display: none; }
  .wb-bar-buttons { width: 100%; justify-content: stretch; }
  .wb-bar-buttons .btn { flex: 1 1 auto; }
  .wb-bar .bar-dup { display: none; }
  .options-grid { grid-template-columns: 1fr; gap: 8px; }
  .option-card { padding: 10px; }
  .option-card.selected { padding: 9px; }
  .option-total { margin-top: 4px; font-size: 20px; }
  .option-lines { gap: 3px; margin-top: 5px; padding-top: 5px; }
  .option-line { line-height: 1.35; }
  .option-card .more-lines { margin-top: 4px; }
  .order-lines .data-table { min-width: 440px; }
}
