:root {
  --ink: #16211d;
  --muted: #66716c;
  --line: #dfe5e1;
  --soft-line: #edf0ee;
  --paper: #ffffff;
  --canvas: #f3f6f4;
  --green: #176b4d;
  --green-deep: #0f523b;
  --green-soft: #eaf5ef;
  --amber: #a76410;
  --amber-soft: #fff5df;
  --red: #b43838;
  --red-soft: #fff0ef;
  --blue: #2f5f9b;
  --blue-soft: #eef5fd;
  --shadow: 0 10px 30px rgba(25, 42, 34, .06);
  --radius: 16px;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--canvas); }
body {
  margin: 0;
  color: var(--ink);
  background: var(--canvas);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
.hidden { display: none !important; }
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.app-shell { min-height: 100vh; }

.topbar {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 max(24px, calc((100vw - 1180px) / 2));
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  color: white;
  background: var(--green);
  border-radius: 11px;
}
.brand-mark svg { width: 23px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 15px; letter-spacing: .02em; }
.brand small { margin-top: 2px; color: #8a938f; font-size: 10px; letter-spacing: .06em; text-transform: uppercase; }
.topbar-right { display: flex; align-items: center; gap: 18px; }
.service-state { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 13px; }
.service-state i { width: 7px; height: 7px; border-radius: 50%; background: #3aae78; box-shadow: 0 0 0 4px #e6f5ed; }
.icon-button { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; color: #65706b; background: transparent; border: 1px solid var(--line); border-radius: 50%; cursor: pointer; }
.icon-button:hover { color: var(--green); border-color: #b9cac1; }
.icon-button svg { width: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.account-link { color: var(--green); font-size: 12px; font-weight: 700; text-decoration: none; }
.account-name { max-width: 160px; color: var(--muted); font-size: 12px; overflow: hidden; text-decoration: none; text-overflow: ellipsis; white-space: nowrap; }
.logout-button { width: auto; padding: 0 11px; border-radius: 8px; font-size: 11px; font-weight: 700; }

main { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 54px 0 80px; }

input[type="date"]:not(:disabled):not([readonly]) {
  cursor: pointer;
}
.hero { display: flex; align-items: center; justify-content: space-between; gap: 38px; margin-bottom: 30px; }
.hero-copy { min-width: 0; flex: 1; }
.eyebrow { margin: 0 0 10px; color: var(--green); font-size: 11px; font-weight: 750; letter-spacing: .16em; text-transform: uppercase; }
.hero h1 { max-width: 760px; margin: 0; font-family: Georgia, "Songti SC", serif; font-size: clamp(31px, 3.6vw, 43px); font-weight: 500; line-height: 1.18; letter-spacing: -.025em; }
.hero-copy > p:last-child { max-width: 690px; margin: 13px 0 0; color: var(--muted); font-size: 14px; line-height: 1.7; }
.hero-navigation { display: grid; flex: none; min-width: 390px; gap: 13px; padding: 17px 18px; background: rgba(255, 255, 255, .82); border: 1px solid #d7e1db; border-radius: 14px; box-shadow: 0 10px 30px rgba(25, 55, 39, .05); }
.hero-navigation-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 18px; }
.hero-navigation-heading span { color: #7b8781; font-size: 10px; font-weight: 750; letter-spacing: .05em; }
.hero-navigation-heading strong { max-width: 240px; overflow: hidden; color: #26352e; font-size: 12px; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
.hero-navigation-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 8px; }
.hero-navigation-actions .button { min-height: 44px; padding: 0 16px; }
.hero-navigation > small { color: #7e8983; font-size: 10px; line-height: 1.55; text-align: right; }
.text-button { display: inline-flex; align-items: center; gap: 7px; flex: none; padding: 8px 0; color: var(--green); background: transparent; border: 0; font-weight: 650; cursor: pointer; }
.text-button svg { width: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; }

.workflow { margin-bottom: 24px; padding: 19px 26px; background: #e9eeeb; border-radius: 14px; }
.workflow ol { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0; padding: 0; list-style: none; }
.workflow li { position: relative; display: flex; align-items: center; gap: 11px; min-width: 0; color: #87908c; }
.workflow li:not(:last-child)::after { content: ""; position: absolute; z-index: 0; top: 17px; left: 58%; right: -9%; height: 1px; background: #ccd4d0; }
.workflow li > span { position: relative; z-index: 1; display: grid; place-items: center; flex: none; width: 34px; height: 34px; border: 1px solid #c9d1cd; border-radius: 50%; background: #f4f7f5; font-size: 12px; font-weight: 750; }
.workflow li div { position: relative; z-index: 1; padding-right: 10px; background: #e9eeeb; }
.workflow b, .workflow small { display: block; }
.workflow b { color: #66706b; font-size: 13px; }
.workflow small { margin-top: 2px; font-size: 10px; white-space: nowrap; }
.workflow li.is-active > span { color: white; background: var(--green); border-color: var(--green); box-shadow: 0 0 0 5px rgba(23, 107, 77, .1); }
.workflow li.is-active b { color: var(--green-deep); }
.workflow li.is-complete > span { color: white; background: #6c9280; border-color: #6c9280; }
.workflow li.is-complete::after { background: #90ad9e; }

.panel { margin-top: 18px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 26px 30px; border-bottom: 1px solid var(--soft-line); }
.panel-heading > div:first-child { display: flex; align-items: center; gap: 15px; }
.section-index { display: grid; place-items: center; flex: none; width: 38px; height: 38px; color: var(--green); background: var(--green-soft); border-radius: 10px; font-size: 11px; font-weight: 800; letter-spacing: .04em; }
.panel-heading h2 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 21px; font-weight: 600; }
.panel-heading p { margin: 5px 0 0; color: var(--muted); font-size: 12px; }

#uploadForm { padding: 30px; }
.upload-layout { display: grid; grid-template-columns: minmax(310px, .82fr) minmax(480px, 1.18fr); gap: 24px; align-items: stretch; }
.dropzone { display: flex; min-height: 218px; flex-direction: column; align-items: center; justify-content: center; padding: 28px; border: 1.5px dashed #afbeb6; border-radius: 14px; background: #fafcfb; cursor: pointer; transition: border-color .18s, background .18s, transform .18s; }
.dropzone:hover, .dropzone.is-dragging { border-color: var(--green); background: #f2f9f5; }
.dropzone.is-dragging { transform: translateY(-2px); }
.dropzone.has-file { border-style: solid; border-color: #8cb29f; background: var(--green-soft); }
.dropzone input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.upload-icon { display: grid; place-items: center; width: 52px; height: 52px; margin-bottom: 16px; color: var(--green); background: var(--green-soft); border-radius: 50%; }
.upload-icon svg { width: 25px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.drop-title { color: #26332d; font-size: 15px; font-weight: 680; }
.drop-hint { margin-top: 8px; color: #89918d; font-size: 12px; }
.selected-file { margin-top: 15px; padding: 8px 12px; color: var(--green-deep); background: white; border: 1px solid #bad2c5; border-radius: 8px; font-size: 12px; font-weight: 650; }
.upload-metadata { padding: 18px 20px; background: #f7faf8; border: 1px solid #dce6e0; border-radius: 14px; }
.upload-metadata-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.upload-metadata-heading strong, .upload-metadata-heading span { display: block; }
.upload-metadata-heading strong { color: #26332d; font-size: 14px; }
.upload-metadata-heading span { margin-top: 4px; color: var(--muted); font-size: 10px; line-height: 1.5; }
.upload-metadata-heading i { flex: none; padding: 4px 7px; color: #718078; background: white; border: 1px solid #d6e0da; border-radius: 999px; font-size: 9px; font-style: normal; font-weight: 700; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 26px; }
.form-grid-metadata { gap: 13px 15px; margin-top: 0; }
.field > span, .field > label { display: block; margin-bottom: 9px; color: #303b36; font-size: 13px; font-weight: 680; }
.field em { margin-left: 5px; color: #8a938e; font-size: 11px; font-style: normal; font-weight: 500; }
.field input { width: 100%; height: 44px; padding: 0 13px; color: var(--ink); background: white; border: 1px solid #ccd5d0; border-radius: 9px; outline: none; transition: border-color .18s, box-shadow .18s; }
.field input:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgba(23, 107, 77, .1); }
.field small { display: block; margin-top: 7px; color: #8a938f; font-size: 11px; }
.form-grid-metadata .field > span, .form-grid-metadata .field > label { margin-bottom: 6px; font-size: 11px; }
.form-grid-metadata .field input { height: 42px; padding: 0 10px; font-size: 12px; }
.form-grid-metadata .field small { min-height: 15px; margin-top: 5px; font-size: 10px; line-height: 1.45; }
.input-with-action { display: grid; grid-template-columns: minmax(0, 1fr) auto; }
.input-with-action input { border-radius: 9px 0 0 9px; }
.input-with-action button { min-width: 52px; min-height: 42px; padding: 0 10px; color: var(--green-deep); background: var(--green-soft); border: 1px solid #b9d2c5; border-left: 0; border-radius: 0 9px 9px 0; font-size: 10px; font-weight: 750; cursor: pointer; }
.input-with-action button:hover { background: #dceee4; }
.customer-type-preview { align-self: end; min-height: 59px; padding: 10px 12px; background: white; border: 1px solid #d5dfda; border-radius: 9px; }
.customer-type-preview span, .customer-type-preview strong { display: block; }
.customer-type-preview span { color: #77837d; font-size: 9px; font-weight: 700; }
.customer-type-preview strong { margin-top: 7px; color: #89938e; font-size: 11px; font-weight: 650; }
.customer-type-preview.is-domestic { border-color: #acd0bd; background: #f0f8f4; }
.customer-type-preview.is-domestic strong { color: var(--green-deep); }
.customer-type-preview.is-overseas { border-color: #b9cde2; background: #f3f7fb; }
.customer-type-preview.is-overseas strong { color: #315f88; }
.form-actions { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 28px; }
.form-actions p { display: flex; align-items: center; gap: 7px; margin: 0; color: #7b8580; font-size: 11px; }
.form-actions p svg { width: 17px; fill: none; stroke: #5d8d76; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.upload-transfer { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 18px; align-items: center; margin: 0 30px 30px; padding: 22px; background: linear-gradient(135deg, #f3faf6, #fbfdfc); border: 1px solid #cfe1d7; border-radius: 14px; }
.upload-transfer-icon { display: grid; place-items: center; width: 46px; height: 46px; color: white; background: var(--green); border-radius: 13px; box-shadow: 0 8px 20px rgba(23, 107, 77, .18); }
.upload-transfer-icon svg { width: 23px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.upload-transfer-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.upload-transfer-heading strong, .upload-transfer-heading span { display: block; }
.upload-transfer-heading strong { color: #26332d; font-size: 14px; }
.upload-transfer-heading span { max-width: 560px; margin-top: 4px; overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.upload-transfer-heading b { color: var(--green-deep); font-family: Georgia, "Songti SC", serif; font-size: 21px; }
.upload-transfer-track { height: 7px; margin-top: 14px; overflow: hidden; background: #dfeae4; border-radius: 99px; }
.upload-transfer-track i { display: block; width: 0; height: 100%; background: linear-gradient(90deg, #2b8a62, #55aa7f); border-radius: inherit; transition: width .25s ease; }
.upload-transfer p { margin: 10px 0 0; color: #65736c; font-size: 11px; }
.upload-transfer.is-paused { background: #fffaf0; border-color: #ecd7aa; }
.upload-transfer.is-paused .upload-transfer-icon { background: #b27a32; }
.upload-transfer-actions { display: flex; flex-direction: column; gap: 8px; min-width: 106px; }
.upload-transfer-actions .button { min-height: 38px; padding: 0 14px; font-size: 11px; }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 19px; border: 1px solid transparent; border-radius: 9px; font-size: 13px; font-weight: 700; text-decoration: none; cursor: pointer; transition: background .18s, border-color .18s, transform .18s, opacity .18s; }
.button:hover { transform: translateY(-1px); }
.button:disabled { opacity: .55; cursor: wait; transform: none; }
.button svg { width: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.button-primary { color: white; background: var(--green); border-color: var(--green); }
.button-primary:hover { background: var(--green-deep); }
.button-secondary { color: #324039; background: white; border-color: #cbd4cf; }
.button-secondary:hover { border-color: #94a79d; }

.message { margin-bottom: 18px; padding: 13px 16px; border: 1px solid #b9d7c8; border-radius: 10px; color: var(--green-deep); background: var(--green-soft); font-size: 13px; }
.message.is-error { color: #8c2929; background: var(--red-soft); border-color: #efc0bc; }
.mapping-action-message { margin: 18px 30px 0; padding: 12px 14px; color: #8c2929; background: var(--red-soft); border: 1px solid #efc0bc; border-radius: 9px; font-size: 12px; line-height: 1.6; }
.task-heading { padding-bottom: 22px; }
.task-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 14px; }
.upload-resume, .upload-next { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 16px 24px; color: var(--muted); font-size: 13px; }
.upload-resume { display: grid; grid-template-columns: minmax(210px, .62fr) minmax(0, 1.7fr); margin-top: 18px; background: var(--green-soft); border: 1px solid var(--line); border-radius: 10px; }
.upload-resume-copy strong, .upload-resume-copy span { display: block; }
.upload-resume-copy strong { color: var(--green-deep); font-size: 13px; }
.upload-resume-copy span { margin-top: 4px; font-size: 11px; line-height: 1.5; }
.upload-resume-title { display: flex; align-items: center; gap: 8px; }
.upload-resume-title i { padding: 3px 7px; color: #356d52; background: #d9ece2; border-radius: 99px; font-size: 9px; font-style: normal; font-weight: 750; }
.upload-resume-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.upload-task-link { display: grid; min-width: 0; min-height: 70px; padding: 10px 12px; color: #315744; background: white; border: 1px solid #cfe0d6; border-radius: 9px; text-decoration: none; transition: border-color .18s, box-shadow .18s, transform .18s; }
.upload-task-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-width: 0; }
.upload-task-link b { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.upload-task-link em.status-badge { padding: 4px 7px; font-size: 9px; font-style: normal; }
.upload-task-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 3px 10px; margin-top: 7px; color: var(--muted); }
.upload-task-meta small, .upload-task-meta time { font-size: 9px; font-style: normal; }
.upload-task-link:hover { border-color: #8fb7a1; box-shadow: 0 5px 14px rgba(43, 90, 67, .08); transform: translateY(-1px); }
.upload-next { border-top: 1px solid var(--soft-line); }
.upload-next-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; }
@media (max-width: 700px) {
  .sales-demand-page .topbar { height: auto; min-height: 64px; flex-wrap: wrap; gap: 12px; padding: 12px 16px; }
  .sales-demand-page .topbar-right { width: 100%; flex-wrap: wrap; gap: 12px; }
  .sales-demand-page .hero { align-items: flex-start; flex-direction: column; gap: 18px; }
}
@media (max-width: 580px) {
  .task-heading { flex-wrap: wrap; }
  .upload-next .button { width: 100%; }
  .upload-next-actions { width: 100%; }
  .upload-resume, .upload-next { padding: 16px 18px; }
  .upload-resume { grid-template-columns: 1fr; }
  .upload-resume-list { justify-content: stretch; }
  .upload-resume-list { grid-template-columns: 1fr; }
  .upload-task-link { width: 100%; max-width: none; }
  .upload-transfer { grid-template-columns: 1fr; margin: 0 18px 18px; }
  .upload-transfer-icon { display: none; }
  .upload-transfer-actions { flex-direction: row; }
  .upload-transfer-actions .button { flex: 1; }
}
.task-actions .text-button { padding: 6px 0; }
.status-badge { flex: none; padding: 7px 11px; border-radius: 999px; font-size: 11px; font-weight: 750; }
.status-pending { color: #6d5730; background: var(--amber-soft); }
.status-working { color: var(--blue); background: var(--blue-soft); }
.status-review { color: var(--amber); background: var(--amber-soft); }
.status-done { color: var(--green-deep); background: var(--green-soft); }
.status-error { color: var(--red); background: var(--red-soft); }
.status-layout { display: grid; grid-template-columns: 1fr 340px; gap: 36px; padding: 26px 30px; }
.status-main { min-width: 0; }
.progress-track { height: 7px; overflow: hidden; background: #edf1ef; border-radius: 99px; }
.progress-track i { display: block; width: 8%; height: 100%; background: var(--green); border-radius: inherit; transition: width .4s ease; }
.status-copy { display: flex; justify-content: space-between; gap: 24px; margin-top: 12px; font-size: 12px; }
.status-copy span { color: var(--muted); text-align: right; }
.task-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 13px 24px; margin: 0; padding-left: 28px; border-left: 1px solid var(--soft-line); }
.task-meta div:first-child { grid-column: 1 / -1; }
.task-meta dt { color: #8a938f; font-size: 10px; }
.task-meta dd { max-width: 190px; margin: 4px 0 0; overflow: hidden; color: #39443f; font-size: 12px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.task-failure-alert { margin-top: 0; margin-bottom: 26px; }
.task-failure-alert > div { min-width: 0; }
.task-failure-alert p { overflow-wrap: anywhere; }
.task-failure-alert small { display: block; margin-top: 5px; color: #795151; font-size: 10px; line-height: 1.55; }

.legend { display: flex; align-items: center; gap: 15px; color: var(--muted); font-size: 10px; }
.legend span { display: inline-flex; align-items: center; gap: 5px; }
.dot { width: 7px; height: 7px; border-radius: 50%; }
.dot-high { background: #3c996d; }.dot-mid { background: #d39737; }.dot-low { background: #c95252; }
.alert { display: flex; gap: 12px; margin: 20px 30px 0; padding: 14px 16px; border: 1px solid; border-radius: 10px; }
.alert svg { flex: none; width: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.alert strong { font-size: 13px; }
.alert p { margin: 3px 0 0; font-size: 11px; line-height: 1.6; }
.alert-danger { color: #9b3030; background: var(--red-soft); border-color: #efc2be; }
.alert-warning { color: #865513; background: var(--amber-soft); border-color: #eed49d; }
.metadata-confirm { display: grid; grid-template-columns: minmax(200px, .9fr) repeat(3, minmax(120px, 1fr)); gap: 14px; align-items: end; margin: 20px 30px 0; padding: 17px 18px; background: #f7faf8; border: 1px solid #dce6e0; border-radius: 10px; }
.metadata-confirm > div:first-child { grid-row: 1 / 3; align-self: center; }
.metadata-confirm h3 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 15px; }
.metadata-confirm p { margin: 5px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.metadata-confirm label span { display: block; margin-bottom: 6px; color: #68736d; font-size: 10px; font-weight: 700; }
.metadata-confirm input { width: 100%; height: 36px; padding: 0 9px; color: #25322c; background: white; border: 1px solid #ccd5d0; border-radius: 7px; outline: none; }
.metadata-confirm input:focus { border-color: var(--green); box-shadow: 0 0 0 2px rgba(23, 107, 77, .1); }
.group-section { margin: 24px 30px 0; padding: 20px; background: #f7faf8; border: 1px solid #dce6e0; border-radius: 12px; }
.subheading { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; }
.subheading h3 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 17px; }
.subheading p { margin: 5px 0 0; color: var(--muted); font-size: 11px; }
.group-count, .issue-count { padding: 5px 9px; color: var(--green-deep); background: var(--green-soft); border-radius: 999px; font-size: 10px; font-weight: 700; }
.group-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-top: 17px; }
.customer-group { padding: 16px; background: white; border: 1px solid #dce3df; border-radius: 10px; }
.customer-group.is-unconfirmed { border-color: #deb66d; }
.group-top { display: flex; justify-content: space-between; gap: 14px; }
.group-name { min-width: 0; }
.group-name label { display: block; margin-bottom: 5px; color: #7c8681; font-size: 10px; }
.group-name input { width: 100%; height: 34px; padding: 0 9px; border: 1px solid #ccd5d0; border-radius: 7px; color: #25322c; font-weight: 700; outline: none; }
.group-name input:focus { border-color: var(--green); }
.split-toggle { position: relative; display: flex; align-items: center; gap: 8px; flex: none; color: #44514b; font-size: 11px; font-weight: 650; cursor: pointer; }
.split-toggle input { width: 16px; height: 16px; accent-color: var(--green); }
.group-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 13px; }
.group-column { padding: 10px; background: #f7f9f8; border-radius: 8px; }
.group-column small, .group-column b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.group-column small { color: #8a938f; font-size: 9px; }.group-column b { margin-top: 4px; font-size: 11px; }
.split-note { display: flex; align-items: flex-start; gap: 8px; margin-top: 14px; color: #68736d; font-size: 10px; }
.split-note svg { flex: none; width: 18px; fill: none; stroke: var(--green); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

.mapping-table-wrap, .result-table-wrap { margin: 24px 30px 0; overflow-x: auto; border: 1px solid var(--line); border-radius: 10px; }
.mapping-table, .result-table { width: 100%; border-collapse: collapse; text-align: left; }
.mapping-table th, .result-table th { padding: 11px 14px; color: #76807b; background: #f6f8f7; border-bottom: 1px solid var(--line); font-size: 10px; font-weight: 750; letter-spacing: .03em; white-space: nowrap; }
.mapping-table td, .result-table td { padding: 14px; border-bottom: 1px solid var(--soft-line); font-size: 12px; vertical-align: top; }
.mapping-table tr:last-child td, .result-table tr:last-child td { border-bottom: 0; }
.mapping-table tr.is-guarded { background: #fffaf1; }
.source-field b { display: block; max-width: 250px; font-size: 12px; overflow-wrap: anywhere; }
.source-field small { display: block; max-width: 270px; margin-top: 5px; color: #87908c; font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.source-field code { display: inline-block; margin-right: 6px; padding: 2px 5px; color: #68736d; background: #edf1ef; border-radius: 4px; font-family: inherit; font-size: 9px; }
.mapping-select { width: 100%; min-width: 155px; height: 36px; padding: 0 30px 0 9px; color: #29352f; background: white; border: 1px solid #cbd4cf; border-radius: 7px; outline: none; }
.mapping-select:focus { border-color: var(--green); box-shadow: 0 0 0 2px rgba(23, 107, 77, .1); }
.mapping-select.is-changed { border-color: #c88828; background: #fffaf1; }
.confidence { display: flex; align-items: center; gap: 7px; white-space: nowrap; }
.confidence-bar { width: 48px; height: 5px; background: #e8ecea; border-radius: 99px; overflow: hidden; }
.confidence-bar i { display: block; height: 100%; border-radius: inherit; }
.confidence-high i { background: #3c996d; }.confidence-mid i { background: #d39737; }.confidence-low i { background: #c95252; }
.confidence b { font-size: 11px; }
.confidence-note { display: block; margin-top: 5px; color: var(--amber); font-size: 9px; white-space: normal; }
.evidence { max-width: 330px; margin: 0; padding: 0; color: #626d67; font-size: 10px; line-height: 1.55; list-style: none; }
.evidence li + li { margin-top: 3px; }
.evidence li::before { content: "·"; margin-right: 5px; color: var(--green); font-weight: 800; }
.mapping-footer { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; padding: 24px 30px 30px; }
.scope-picker { display: flex; gap: 8px; margin: 0; padding: 0; border: 0; }
.scope-picker legend { margin-bottom: 9px; color: #66716c; font-size: 10px; font-weight: 700; }
.scope-picker label { position: relative; cursor: pointer; }
.scope-picker input { position: absolute; opacity: 0; }
.scope-picker span { display: block; min-width: 116px; padding: 10px 11px; border: 1px solid #d5dcd8; border-radius: 8px; }
.scope-picker b, .scope-picker small { display: block; }
.scope-picker b { font-size: 11px; }.scope-picker small { margin-top: 3px; color: #88918d; font-size: 9px; }
.scope-picker input:checked + span { color: var(--green-deep); background: var(--green-soft); border-color: #91b9a4; box-shadow: inset 0 0 0 1px #91b9a4; }
.mapping-actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; justify-content: flex-end; }
.mapping-actions > span { width: 100%; color: #7d8782; font-size: 10px; text-align: right; }
.empty-state { padding: 34px; color: #7d8782; text-align: center; }
.empty-state span { display: grid; place-items: center; width: 34px; height: 34px; margin: 0 auto; color: white; background: #6a9b82; border-radius: 50%; }
.empty-state p { margin: 9px 0 0; font-size: 12px; }

.compact-heading { padding-top: 22px; padding-bottom: 22px; }
.issue-list { padding: 4px 30px 24px; }
.issue-item { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: start; padding: 15px 0; border-bottom: 1px solid var(--soft-line); }
.issue-item:last-child { border-bottom: 0; }
.issue-level { margin-top: 1px; padding: 4px 7px; border-radius: 5px; font-size: 9px; font-weight: 800; }
.issue-error { color: var(--red); background: var(--red-soft); }.issue-warning { color: var(--amber); background: var(--amber-soft); }.issue-info { color: var(--blue); background: var(--blue-soft); }
.issue-item b { display: block; font-size: 12px; }.issue-item p { margin: 4px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.issue-location { color: #8a938f; font-size: 9px; white-space: nowrap; }

.result-hero { display: flex; align-items: center; gap: 15px; padding: 27px 30px; border-bottom: 1px solid var(--soft-line); }
.success-icon { display: grid; place-items: center; flex: none; width: 42px; height: 42px; color: white; background: var(--green); border-radius: 50%; }
.success-icon svg { width: 23px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.result-outcome-partial .success-icon,
.result-outcome-empty .success-icon { background: #b27a32; }
.result-outcome-duplicate .success-icon { background: #728079; }
.result-hero > div:not(.result-hero-actions) { min-width: 0; flex: 1; }.result-hero h2 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 21px; }.result-hero p { margin: 5px 0 0; color: var(--muted); font-size: 11px; }
.result-hero-actions { display: flex; flex: none; gap: 9px; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; padding: 22px 30px; border-bottom: 1px solid var(--soft-line); }
.metric { padding: 0 20px; border-right: 1px solid var(--soft-line); }.metric:first-child { padding-left: 0; }.metric:last-child { border-right: 0; }
.metric span, .metric b { display: block; }.metric span { color: #828b87; font-size: 10px; }.metric b { margin-top: 5px; font-family: Georgia, serif; font-size: 23px; font-weight: 500; }
.metric b::after { margin-left: 4px; color: #8b948f; content: "条"; font-family: inherit; font-size: 10px; }
.metric-new b { color: var(--green); }
.metric-duplicate b { color: #9a6b2f; }
.metric-isolated b { color: #a86827; }
.result-table-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 22px 24px 10px; }
.result-table-heading strong { color: var(--ink); font-size: 11px; }
.result-table-heading span { color: #8a938f; font-size: 9px; }
.result-table-wrap { margin-bottom: 30px; }
.result-table td { max-width: 240px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; }
.result-price { display: inline-flex; align-items: baseline; gap: 6px; font-variant-numeric: tabular-nums; }
.result-price b { color: #27342e; font-size: 11px; font-weight: 700; }
.result-price small { color: #7c8781; font-size: 9px; font-weight: 700; letter-spacing: .03em; }
.result-table tbody tr.result-row-duplicate { background: #fffbf3; }
.result-table tbody tr.result-row-error { background: #fff8f7; }
.result-row-status { font-weight: 800; }
.result-row-status.status-valid { color: var(--green-deep); }
.result-row-status.status-warning { color: #8a641f; }
.result-row-status.status-duplicate { color: #9a681d; }
.result-row-status.status-error { color: var(--red); }
.result-row-status.status-neutral { color: #68736d; }
.result-pagination { display: flex; align-items: center; justify-content: center; gap: 12px; margin: -12px 24px 30px; }
.result-pagination span { min-width: 84px; color: var(--muted); text-align: center; font-size: 10px; }
.result-pagination .button { min-height: 34px; padding: 7px 14px; }

.help-dialog { width: min(480px, calc(100% - 32px)); padding: 0; border: 0; border-radius: 15px; box-shadow: 0 24px 80px rgba(13, 34, 24, .25); }
.help-dialog::backdrop { background: rgba(12, 24, 18, .42); backdrop-filter: blur(2px); }
.help-dialog form { position: relative; padding: 30px; }
.dialog-close { position: absolute; top: 15px; right: 17px; width: 32px; height: 32px; color: #6d7772; background: #f1f4f2; border: 0; border-radius: 50%; font-size: 22px; cursor: pointer; }
.help-dialog h2 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 23px; }
.help-dialog ol { margin: 24px 0 0; padding: 0; list-style: none; }
.help-dialog li { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-top: 1px solid var(--soft-line); }
.help-dialog li > span { display: grid; place-items: center; width: 29px; height: 29px; color: var(--green); background: var(--green-soft); border-radius: 8px; font-size: 10px; font-weight: 800; }
.help-dialog li p { margin: 0; }.help-dialog li b, .help-dialog li small { display: block; }.help-dialog li b { font-size: 12px; }.help-dialog li small { margin-top: 2px; color: var(--muted); font-size: 10px; }

.auth-page { min-height: 100vh; background: #e8efeb; }
.auth-layout { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(360px, 480px); width: min(1120px, calc(100% - 48px)); min-height: 100vh; margin: 0 auto; padding: 70px 0; gap: 70px; align-items: center; }
.auth-intro { display: flex; min-height: 570px; flex-direction: column; justify-content: space-between; padding: 8px 0; }
.auth-brand { width: fit-content; }
.auth-intro h1 { max-width: 620px; margin: 0; font-family: Georgia, "Songti SC", serif; font-size: clamp(38px, 5vw, 62px); font-weight: 500; line-height: 1.13; letter-spacing: -.035em; }
.auth-intro-copy { max-width: 580px; margin: 20px 0 0; color: var(--muted); font-size: 16px; line-height: 1.7; }
.auth-card { padding: 42px; background: var(--paper); border: 1px solid rgba(215, 225, 220, .8); border-radius: 20px; box-shadow: 0 24px 70px rgba(24, 50, 37, .12); }
.auth-card h2 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 31px; font-weight: 500; }
.auth-card > div:first-child > p:last-child { margin: 10px 0 0; color: var(--muted); font-size: 12px; }
.auth-card form { display: grid; gap: 20px; margin-top: 30px; }
.auth-card .field input { height: 48px; }
.auth-submit { width: 100%; min-height: 48px; margin-top: 4px; }
.auth-help { margin: 20px 0 0; color: #87908c; font-size: 10px; text-align: center; }
.auth-card .message { margin: 20px 0 -8px; }

.accounts-main { max-width: 980px; }
.accounts-hero { margin-bottom: 26px; }
.accounts-hero h1 { font-size: 38px; }
.account-create, .account-list-panel { margin-bottom: 24px; }
.account-form { display: grid; grid-template-columns: .9fr 1.25fr .85fr 1fr auto; gap: 14px; align-items: end; padding: 4px 30px 30px; }
.account-form select { width: 100%; height: 40px; padding: 0 10px; border: 1px solid #cbd4cf; border-radius: 7px; background: white; }
.account-list { padding: 0 30px 24px; }
.account-row { display: grid; grid-template-columns: minmax(150px, .8fr) minmax(320px, 1.5fr) auto; align-items: center; gap: 18px; padding: 17px 0; border-top: 1px solid var(--soft-line); }
.account-identity strong, .account-identity span { display: block; }
.account-identity strong { font-size: 13px; }
.account-identity span { margin-top: 4px; color: var(--muted); font-size: 10px; }
.account-actions { display: flex; gap: 8px; }
.account-access { display: grid; grid-template-columns: minmax(120px, .8fr) minmax(130px, 1fr) auto; gap: 8px; }
.account-access select, .account-access input { min-width: 0; height: 38px; padding: 0 10px; color: #324039; background: white; border: 1px solid #cbd4cf; border-radius: 7px; }
.button-danger { color: var(--red); background: var(--red-soft); border: 1px solid #efc6c3; }
.button-danger:hover { background: #ffe7e5; }
.reset-dialog .field { margin-top: 24px; }
.reset-dialog .form-actions { padding: 20px 0 0; justify-content: flex-end; }
.profile-form { display: grid; gap: 18px; max-width: 560px; padding: 4px 30px 30px; }
.profile-form .button { justify-self: start; }

.history-page { background: linear-gradient(180deg, #eef4f0 0, var(--canvas) 280px); }
.history-main { width: min(1600px, calc(100% - 32px)); padding-top: 42px; }
.history-hero { align-items: center; margin-bottom: 26px; }
.history-hero h1 { font-size: 40px; }
.history-hero > div:first-child > p:last-child { max-width: 650px; line-height: 1.7; }
.history-hero-summary { display: flex; align-items: center; gap: 14px; min-width: 220px; padding: 16px 18px; background: rgba(255, 255, 255, .78); border: 1px solid rgba(209, 222, 215, .9); border-radius: 14px; box-shadow: 0 10px 30px rgba(27, 54, 40, .05); backdrop-filter: blur(8px); }
.history-hero-icon, .history-heading-icon { display: grid; place-items: center; flex: none; color: var(--green); background: var(--green-soft); }
.history-hero-icon { width: 44px; height: 44px; border-radius: 12px; }
.history-hero-icon svg, .history-heading-icon svg { width: 21px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.history-hero-summary strong, .history-hero-summary span, .history-hero-summary small { display: block; }
.history-hero-summary strong { float: left; margin-right: 5px; font-family: Georgia, "Songti SC", serif; font-size: 25px; font-weight: 600; line-height: 1; }
.history-hero-summary span { padding-top: 6px; color: #45524c; font-size: 11px; font-weight: 700; }
.history-hero-summary small { clear: both; padding-top: 5px; color: #89928e; font-size: 9px; }
.history-filter-panel, .history-results-panel { margin-bottom: 24px; }
.history-filter-panel { overflow: visible; container-type: inline-size; }
.history-filter-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 26px 0; }
.history-filter-heading > div { display: flex; align-items: center; gap: 11px; }
.history-heading-icon { width: 34px; height: 34px; border-radius: 9px; }
.history-heading-icon svg { width: 17px; }
.history-filter-heading h2 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 18px; }
.history-filter-heading p { margin: 3px 0 0; color: var(--muted); font-size: 10px; }
.history-clear-link { padding: 6px 0; color: var(--green); background: transparent; border: 0; font-size: 11px; font-weight: 700; cursor: pointer; }
.history-clear-link:disabled { color: #a5ada9; cursor: default; }
.history-filter-form { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(170px, .8fr) minmax(280px, 1.25fr) minmax(180px, auto); gap: 14px; align-items: end; padding: 18px 26px 22px; }
.history-filter-form > * { min-width: 0; }
.history-input-with-icon { position: relative; display: block !important; margin: 0 !important; color: inherit !important; }
.history-input-with-icon svg { position: absolute; z-index: 1; top: 13px; left: 13px; width: 18px; fill: none; stroke: #8a958f; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
.history-input-with-icon input { padding-left: 40px; }
.history-owner-filter { min-width: 0; }
.history-owner-filter > span { display: flex; align-items: baseline; gap: 6px; }
.history-owner-filter > span small { display: inline; margin: 0; color: #87918c; font-size: 9px; font-weight: 650; }
.history-multiselect { position: relative; }
.history-multiselect summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; height: 44px; padding: 0 12px; color: var(--ink); background: white; border: 1px solid #ccd5d0; border-radius: 9px; outline: none; list-style: none; cursor: pointer; }
.history-multiselect summary::-webkit-details-marker { display: none; }
.history-multiselect summary:focus-visible { border-color: var(--green); box-shadow: 0 0 0 3px rgba(23, 107, 77, .14); }
.history-multiselect summary > span { min-width: 0; overflow: hidden; font-size: 12px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.history-multiselect summary i { flex: none; color: #78857e; font-size: 13px; font-style: normal; transition: transform .18s; }
.history-multiselect[open] summary { border-color: var(--green); box-shadow: 0 0 0 3px rgba(23, 107, 77, .1); }
.history-multiselect[open] summary i { transform: rotate(180deg); }
.history-multiselect-options { position: absolute; z-index: 30; top: calc(100% + 7px); left: 0; width: max(100%, 230px); max-height: 238px; padding: 6px; overflow-y: auto; background: white; border: 1px solid #d3ddd7; border-radius: 10px; box-shadow: 0 16px 34px rgba(28, 49, 38, .14); }
.history-owner-option { display: flex; align-items: center; gap: 9px; min-height: 36px; padding: 7px 9px; border-radius: 7px; color: #35413b; font-size: 11px; cursor: pointer; }
.history-owner-option:hover { background: #f1f7f3; }
.history-owner-option input { flex: none; width: 15px; height: 15px; padding: 0; accent-color: var(--green); box-shadow: none; }
.history-owner-option span { min-width: 0; overflow-wrap: anywhere; }
.history-multiselect-empty { display: block; padding: 12px 10px; color: #87918c; font-size: 10px; text-align: center; }
.history-multiselect-note { display: block; margin: 5px 4px 2px; padding: 8px; color: #7a6651; background: #fff8ee; border-radius: 6px; font-size: 9px; line-height: 1.45; }
.history-date-range > div { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; }
.history-date-range label,
.history-date-range input { min-width: 0; width: 100%; }
.history-date-range i { color: #8b948f; font-size: 10px; font-style: normal; }
.history-filter-actions { display: grid; grid-template-columns: repeat(2, minmax(82px, 1fr)); gap: 8px; min-width: 0; }
.history-filter-actions .button { min-width: 0; padding-right: 14px; padding-left: 14px; white-space: nowrap; }
.history-filter-actions .button span { white-space: nowrap; }
.history-active-filters { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 26px 18px; color: #7a847f; font-size: 10px; }
.history-active-filters > span { flex: none; font-weight: 700; }
.history-active-filters > div { display: flex; flex-wrap: wrap; gap: 7px; }
.history-filter-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 26px; padding: 0 9px; color: #315744; background: #f0f7f3; border: 1px solid #d3e4da; border-radius: 999px; font-size: 10px; cursor: pointer; }
.history-filter-chip b { font-weight: 700; }
.history-filter-chip i { color: #799084; font-size: 13px; font-style: normal; line-height: 1; }
.history-results-heading { padding: 20px 26px; }
.history-results-meta { display: flex; align-items: center; gap: 12px; color: #89928e; font-size: 10px; }
.history-export-button { min-width: 146px; min-height: 38px; padding: 8px 14px; }
.history-total { flex: none; padding: 7px 11px; color: var(--green-deep); background: var(--green-soft); border-radius: 999px; font-size: 11px; font-weight: 750; }
.history-table-wrap { margin: 14px 14px 0; overflow-x: hidden; border: 1px solid #dce3df; border-radius: 12px; }
.history-table { width: 100%; min-width: 0; border-collapse: separate; border-spacing: 0; table-layout: fixed; text-align: left; }
.history-col-date { width: 7.5%; }.history-col-type { width: 6.5%; }.history-col-code { width: 8.5%; }.history-col-brand { width: 6%; }.history-col-barcode { width: 10%; }.history-col-product-name { width: 20%; }.history-col-quantity { width: 6%; }.history-col-price { width: 7.5%; }.history-col-supplier { width: 8%; }.history-col-owner { width: 6.5%; }.history-col-region { width: 6%; }
.history-table th { padding: 10px 5px; color: #73807a; background: #f5f8f6; border-bottom: 1px solid #dce3df; font-size: 9px; font-weight: 800; letter-spacing: 0; line-height: 1.25; overflow-wrap: anywhere; white-space: normal; }
.history-table th:first-child { border-top-left-radius: 11px; }.history-table th:last-child { border-top-right-radius: 11px; }
.history-table td { padding: 12px 5px; border-bottom: 1px solid var(--soft-line); color: #35413b; font-size: 10px; line-height: 1.4; vertical-align: middle; }
.history-table tr:last-child td { border-bottom: 0; }
.history-table tbody tr { transition: background .16s; }
.history-table tbody tr:nth-child(even) { background: #fcfdfc; }
.history-table tbody tr:hover { background: #f4f9f6; }
.history-align-right, .history-number { text-align: right; }
.history-nowrap, .history-number { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.history-number { font-variant-numeric: tabular-nums; font-size: 11px !important; font-weight: 680; }
.history-date { color: #53605a; font-variant-numeric: tabular-nums; }
.history-product-name-cell { min-width: 0; }
.history-product-name { display: grid; gap: 5px; min-width: 0; }
.history-product-name-line { display: grid; grid-template-columns: 25px minmax(0, 1fr); align-items: start; gap: 7px; min-width: 0; color: #66716b; }
.history-product-name-language { display: inline-flex; align-items: center; justify-content: center; min-height: 19px; padding: 1px 3px; color: #64776d; background: #eef4f0; border-radius: 5px; font-size: 8px; font-weight: 800; line-height: 1.2; }
.history-product-name-value { min-width: 0; line-height: 1.45; overflow-wrap: anywhere; word-break: break-word; }
.history-product-name-line.is-primary { color: #27362f; }
.history-product-name-line.is-primary .history-product-name-value { font-weight: 720; }
.history-product-name-line.is-missing { color: #a0aaa5; }
.history-product-name-line.is-missing .history-product-name-language { color: #9aa49f; background: #f4f6f5; }
.history-product-name-empty { color: #9aa49f; }
.history-barcode { color: #56615b; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; font-size: 10px !important; }
.history-customer-code a { display: inline-block; max-width: 100%; overflow: hidden; color: var(--green-deep); font-weight: 800; text-decoration: none; text-overflow: ellipsis; vertical-align: middle; }
.history-customer-code a:hover { text-decoration: underline; }
.history-price { display: flex; align-items: baseline; justify-content: flex-end; gap: 5px; white-space: nowrap; }
.history-price b { color: #29362f; font-size: 11px; font-variant-numeric: tabular-nums; }
.history-price small { color: #7d8983; font-size: 8px; font-weight: 800; letter-spacing: .04em; }
.history-price.is-empty b { color: #a0a8a4; font-weight: 500; }
.history-empty { display: grid; justify-items: center; padding: 58px 20px 62px; text-align: center; }
.history-empty > span { display: grid; place-items: center; width: 48px; height: 48px; color: #7c9d8c; background: var(--green-soft); border-radius: 50%; }
.history-empty svg { width: 24px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.history-empty strong { margin-top: 14px; font-size: 14px; }
.history-empty p { margin: 7px 0 17px; color: var(--muted); font-size: 11px; }
.history-results-panel .history-table-wrap { transition: opacity .18s; }
.history-results-panel.is-loading .history-table-wrap { opacity: .52; }
.history-pagination { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 26px 24px; }
.history-pagination > span { color: var(--muted); font-size: 11px; }
.history-pagination > div { display: flex; gap: 8px; }
.history-pagination .button:disabled { cursor: not-allowed; }
.history-page-button { min-width: 92px; }

@container (max-width: 1100px) {
  .history-filter-form { grid-template-columns: minmax(0, 1.2fr) minmax(180px, .8fr); }
  .history-date-range { grid-column: 1 / -1; }
  .history-filter-actions { grid-column: 1 / -1; width: 190px; justify-self: end; }
}

@media (max-width: 1440px) {
  .history-filter-form { grid-template-columns: minmax(0, 1.2fr) minmax(180px, .8fr); }
  .history-date-range { grid-column: 1 / -1; }
  .history-filter-actions { grid-column: 1 / -1; width: 190px; justify-self: end; }
}

@media (max-width: 1120px) {
  main { width: min(100% - 28px, 720px); padding-top: 36px; }
  .hero { align-items: flex-start; flex-direction: column; gap: 12px; }
  .hero-navigation { width: 100%; min-width: 0; }
  .workflow { padding: 15px; }
  .workflow li { gap: 7px; }.workflow li > span { width: 29px; height: 29px; }.workflow li:not(:last-child)::after { top: 14px; }.workflow small { display: none; }
  .status-layout { grid-template-columns: 1fr; }.task-meta { padding: 18px 0 0; border-top: 1px solid var(--soft-line); border-left: 0; }
  .upload-layout { grid-template-columns: 1fr; }
  .group-grid { grid-template-columns: 1fr; }
  .metadata-confirm { grid-template-columns: 1fr 1fr; }.metadata-confirm > div { grid-column: 1 / -1; }
  .metadata-confirm > div:first-child { grid-row: auto; }
  .mapping-footer { align-items: stretch; flex-direction: column; }.mapping-actions > span { text-align: left; }
  .scope-picker { flex-wrap: wrap; }.scope-picker label { flex: 1; }.scope-picker span { min-width: 110px; }
  .auth-layout { grid-template-columns: 1fr; width: min(520px, calc(100% - 32px)); gap: 30px; padding: 34px 0; }
  .auth-intro { min-height: auto; gap: 60px; }
  .auth-intro h1 { font-size: 38px; }
  .account-form { grid-template-columns: 1fr 1fr; }
  .account-row { grid-template-columns: 1fr; }
  .account-access { max-width: 560px; }
  .history-main { width: min(100% - 28px, 820px); }
  .history-filter-form { grid-template-columns: 1fr 1fr; }
  .history-date-range { grid-column: 1 / -1; }
  .history-filter-actions { justify-self: end; }
}

@media (max-width: 700px) {
  .history-page .topbar { height: auto; min-height: 64px; flex-wrap: wrap; gap: 8px; padding-top: 10px; padding-bottom: 8px; }
  .history-page .topbar-right { flex: 1 1 100%; justify-content: flex-start; gap: 8px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: thin; }
  .history-page .account-name { display: none; }
  .history-page .topbar .text-button { font-size: 11px; }
  .history-main { width: calc(100% - 20px); }
  .history-hero-summary { width: 100%; }
  .history-filter-heading, .history-results-heading { padding-left: 18px; padding-right: 18px; }
  .history-filter-form { grid-template-columns: 1fr; padding-left: 18px; padding-right: 18px; }
  .history-date-range { grid-column: auto; }
  .history-date-range > div { grid-template-columns: 1fr; gap: 6px; }
  .history-date-range i { display: none; }
  .history-filter-actions { width: 100%; justify-self: stretch; }
  .history-active-filters { align-items: flex-start; padding-left: 18px; padding-right: 18px; }
  .history-results-heading { align-items: flex-start; flex-direction: column; gap: 12px; }
  .history-results-meta { width: 100%; justify-content: flex-end; flex-wrap: wrap; }
  .history-results-meta > span { display: none; }
  .history-table-wrap { margin: 14px 12px 0; overflow: visible; border: 0; border-radius: 0; }
  .history-table { min-width: 0; table-layout: auto; }
  .history-table colgroup, .history-table thead { display: none; }
  .history-table, .history-table tbody { display: block; }
  .history-table tbody { display: grid; gap: 10px; }
  .history-table tbody tr { display: grid; grid-template-columns: 1fr 1fr; padding: 15px; background: white !important; border: 1px solid #dfe6e2; border-radius: 11px; box-shadow: 0 4px 14px rgba(25, 42, 34, .04); }
  .history-table td { display: block; min-width: 0; padding: 8px 6px; border: 0; text-align: left; }
  .history-table td::before { content: attr(data-label); display: block; margin-bottom: 5px; color: #909994; font-size: 8px; font-weight: 800; letter-spacing: .05em; }
  .history-table td.history-product-name-cell { grid-column: 1 / -1; }
  .history-page .history-table td.history-nowrap,
  .history-page .history-table td.history-barcode { overflow: visible; text-overflow: clip; white-space: normal; overflow-wrap: anywhere; }
  .history-page .history-customer-code a { white-space: normal; overflow-wrap: anywhere; }
  .history-price { justify-content: flex-start; }
  .history-pagination { align-items: stretch; flex-direction: column; padding-left: 18px; padding-right: 18px; }
  .history-pagination > div { display: grid; grid-template-columns: 1fr 1fr; }
}

/* Multi-agent portal */
.agent-portal-main,
.agent-placeholder-main {
  padding: 72px 0 96px;
}

.agent-portal-hero {
  max-width: 760px;
  margin-bottom: 36px;
}

.agent-portal-hero h1,
.agent-placeholder-card h1 {
  margin: 8px 0 12px;
  color: var(--ink-strong, #14231e);
  font-size: clamp(2rem, 4vw, 3.4rem);
  letter-spacing: -0.04em;
}

.agent-portal-hero > p:last-child,
.agent-placeholder-card > p {
  color: var(--ink-soft, #66736e);
  line-height: 1.7;
}

.agent-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.agent-card {
  position: relative;
  min-height: 290px;
  padding: 30px;
  overflow: hidden;
  color: inherit;
  text-decoration: none;
  border: 1px solid rgba(30, 67, 54, 0.13);
  border-radius: 24px;
  background: linear-gradient(145deg, #fff 0%, #f4f8f5 100%);
  box-shadow: 0 18px 55px rgba(25, 53, 43, 0.08);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.agent-card:hover {
  transform: translateY(-3px);
  border-color: rgba(26, 111, 78, 0.32);
  box-shadow: 0 24px 65px rgba(25, 53, 43, 0.13);
}

.agent-card.is-planned {
  background: linear-gradient(145deg, #fff 0%, #f8f5ee 100%);
}

.agent-card-icon {
  display: grid;
  width: 56px;
  height: 56px;
  place-items: center;
  color: #fff;
  font-weight: 800;
  font-size: 1.25rem;
  border-radius: 17px;
  background: #176b4b;
  box-shadow: 0 12px 28px rgba(23, 107, 75, 0.22);
}

.is-planned .agent-card-icon,
.agent-placeholder-card .agent-card-icon {
  background: #9a6b2f;
  box-shadow: 0 12px 28px rgba(154, 107, 47, 0.2);
}

.agent-card-status {
  position: absolute;
  top: 30px;
  right: 30px;
  padding: 6px 10px;
  color: #176b4b;
  font-size: 0.78rem;
  font-weight: 700;
  border-radius: 999px;
  background: #e7f3ed;
}

.is-planned .agent-card-status {
  color: #7b5423;
  background: #f4eadb;
}

.agent-card h2 {
  margin: 34px 0 10px;
  font-size: 1.5rem;
}

.agent-card p {
  min-height: 52px;
  margin: 0 0 26px;
  color: var(--ink-soft, #66736e);
  line-height: 1.65;
}

.agent-card strong {
  color: #176b4b;
}

.agent-placeholder-main {
  display: grid;
  min-height: calc(100vh - 170px);
  place-items: center;
}

.agent-placeholder-card {
  width: min(760px, 100%);
  padding: 48px;
  text-align: center;
  border: 1px solid rgba(30, 67, 54, 0.13);
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(25, 53, 43, 0.1);
}

.agent-placeholder-card .agent-card-icon {
  margin: 0 auto 22px;
}

.placeholder-flow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 32px 0;
  color: #42514b;
  font-weight: 700;
}

.placeholder-flow span {
  padding: 9px 13px;
  border-radius: 10px;
  background: #f2f6f3;
}

.placeholder-flow i {
  color: #9aa59f;
  font-style: normal;
}

@media (max-width: 760px) {
  .agent-portal-main,
  .agent-placeholder-main { padding: 42px 0 72px; }
  .agent-card-grid { grid-template-columns: 1fr; }
  .agent-card { min-height: 250px; }
  .agent-placeholder-card { padding: 30px 20px; }
  .placeholder-flow { align-items: stretch; flex-direction: column; }
  .placeholder-flow i { transform: rotate(90deg); }
}

@media (max-width: 580px) {
  .topbar { height: 64px; padding: 0 16px; }.brand small, .service-state { display: none; }
  main { width: calc(100% - 20px); padding: 28px 0 50px; }.hero h1 { font-size: 29px; }
  .hero-navigation { gap: 12px; padding: 15px; }
  .hero-navigation-heading { align-items: flex-start; flex-direction: column; gap: 4px; }
  .hero-navigation-heading strong { max-width: 100%; text-align: left; }
  .hero-navigation-actions { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
  .hero-navigation-actions .button-primary { grid-column: 1 / -1; grid-row: 1; width: 100%; }
  .hero-navigation-actions .button-secondary { width: 100%; }
  .hero-navigation > small { text-align: left; }
  .workflow { overflow-x: auto; }.workflow ol { min-width: 540px; }
  .panel-heading, #uploadForm, .status-layout, .mapping-footer { padding-left: 18px; padding-right: 18px; }
  .upload-layout { gap: 16px; }
  .upload-metadata { padding: 16px; }
  .form-grid { grid-template-columns: 1fr; }.form-actions { align-items: stretch; flex-direction: column; }.form-actions .button { width: 100%; }
  .alert, .metadata-confirm, .group-section, .mapping-table-wrap, .result-table-wrap { margin-left: 18px; margin-right: 18px; }
  .metadata-confirm { grid-template-columns: 1fr; }.metadata-confirm > div { grid-column: auto; }
  .panel-heading.mapping-heading { align-items: flex-start; flex-direction: column; }.legend { padding-left: 53px; }
  .scope-picker { display: grid; grid-template-columns: 1fr; }.mapping-actions { display: grid; grid-template-columns: 1fr 1fr; }.mapping-actions > span { grid-column: 1 / -1; }.mapping-actions .button { padding-left: 10px; padding-right: 10px; }
  .result-hero { align-items: flex-start; flex-wrap: wrap; padding-left: 18px; padding-right: 18px; }.result-hero-actions { width: 100%; flex-direction: column; }.result-hero .button { width: 100%; }
  .metrics { grid-template-columns: 1fr 1fr; padding-left: 18px; padding-right: 18px; }.metric { padding: 12px; border-bottom: 1px solid var(--soft-line); }.metric:nth-child(2) { border-right: 0; }.metric:nth-last-child(-n+2) { border-bottom: 0; }
  .account-link, .service-state { display: none; }
  .account-name { max-width: 90px; }
  .auth-card { padding: 28px 22px; }
  .auth-intro { gap: 40px; }
  .auth-intro h1 { font-size: 31px; }
  .account-form { grid-template-columns: 1fr; padding-left: 18px; padding-right: 18px; }
  .account-list { padding-left: 18px; padding-right: 18px; }
  .account-row { align-items: stretch; grid-template-columns: 1fr; }
  .account-access { grid-template-columns: 1fr; max-width: none; }
  .account-actions { flex-wrap: wrap; }
}

/* Supplier quote agent */
.supplier-quote-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at 86% 130px, rgba(198, 157, 91, .12), transparent 300px),
    linear-gradient(180deg, #edf4f0 0, var(--canvas) 360px);
}

.supplier-quote-topbar {
  border-bottom-color: rgba(211, 223, 217, .9);
  background: rgba(250, 252, 251, .9);
  backdrop-filter: blur(14px);
}

.supplier-quote-brand-mark {
  background: linear-gradient(145deg, #176b4b, #2d8764);
}

.supplier-quote-history-button {
  border: 0;
  cursor: pointer;
}

.supplier-quote-main {
  width: min(1280px, calc(100% - 48px));
  padding: 48px 0 88px;
}

.supplier-quote-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 28px;
}

.supplier-quote-hero > div {
  max-width: 790px;
}

.supplier-quote-hero h1 {
  margin: 7px 0 13px;
  color: var(--ink);
  font-family: Georgia, "Songti SC", serif;
  font-size: clamp(34px, 4.3vw, 52px);
  font-weight: 500;
  line-height: 1.16;
  letter-spacing: -.035em;
}

.supplier-quote-hero > div > p:last-child {
  max-width: 730px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
}

.supplier-quote-new-button {
  flex: none;
}

.supplier-quote-new-button svg {
  width: 17px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.8;
}

.supplier-quote-workflow {
  margin-bottom: 24px;
  padding: 16px 20px;
  overflow: hidden;
  background: rgba(255, 255, 255, .78);
  border: 1px solid rgba(211, 223, 217, .92);
  border-radius: 14px;
  box-shadow: 0 10px 34px rgba(28, 54, 43, .05);
  backdrop-filter: blur(10px);
}

.supplier-quote-workflow ol {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin: 0;
  padding: 0;
  list-style: none;
}

.supplier-quote-workflow li {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: #8a948f;
}

.supplier-quote-workflow li:not(:last-child)::after {
  position: absolute;
  z-index: 0;
  top: 17px;
  right: 10px;
  left: 48px;
  height: 1px;
  content: "";
  background: #dce4df;
}

.supplier-quote-workflow li > span {
  z-index: 1;
  display: grid;
  width: 34px;
  height: 34px;
  flex: none;
  place-items: center;
  color: #75817b;
  background: #edf1ef;
  border: 1px solid #d7dfdb;
  border-radius: 10px;
  font-size: 10px;
  font-weight: 800;
}

.supplier-quote-workflow li > div {
  z-index: 1;
  max-width: calc(100% - 66px);
  padding-right: 8px;
  background: rgba(255, 255, 255, .9);
}

.supplier-quote-workflow b,
.supplier-quote-workflow small {
  display: block;
}

.supplier-quote-workflow b {
  color: #65716b;
  font-size: 11px;
}

.supplier-quote-workflow small {
  margin-top: 2px;
  overflow: hidden;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-quote-workflow li.is-active > span {
  color: #fff;
  background: var(--green);
  border-color: var(--green);
  box-shadow: 0 7px 18px rgba(23, 107, 75, .2);
}

.supplier-quote-workflow li.is-active b {
  color: var(--ink);
}

.supplier-quote-workflow li.is-complete > span {
  color: var(--green);
  background: var(--green-soft);
  border-color: #acd0bd;
}

.supplier-quote-workflow li.is-complete > span::before {
  content: "✓";
}

.supplier-quote-workflow li.is-complete > span {
  font-size: 0;
}

.supplier-quote-upload-panel,
.supplier-quote-status-panel,
.supplier-quote-issues-panel,
.supplier-quote-result-panel,
.supplier-quote-history-view {
  margin-bottom: 24px;
  border-color: rgba(211, 223, 217, .9);
  box-shadow: 0 16px 45px rgba(27, 51, 41, .065);
}

.supplier-quote-auto-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  color: var(--green-deep);
  background: var(--green-soft);
  border-radius: 999px;
  font-size: 9px;
  font-weight: 800;
  white-space: nowrap;
}

.supplier-quote-auto-badge i {
  width: 6px;
  height: 6px;
  background: #399169;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(57, 145, 105, .12);
}

.supplier-quote-upload-form {
  padding: 0 30px 30px;
}

.supplier-quote-dropzone {
  position: relative;
  display: grid;
  min-height: 205px;
  margin-bottom: 22px;
  padding: 30px;
  cursor: pointer;
  place-items: center;
  align-content: center;
  text-align: center;
  background:
    linear-gradient(#fbfdfc, #fbfdfc) padding-box,
    repeating-linear-gradient(90deg, #a8bdb2 0 8px, transparent 8px 14px) border-box;
  border: 1px solid transparent;
  border-radius: 13px;
  transition: background .18s ease, box-shadow .18s ease, transform .18s ease;
}

.supplier-quote-dropzone:hover,
.supplier-quote-dropzone.is-dragging {
  background:
    linear-gradient(#f3faf6, #f3faf6) padding-box,
    repeating-linear-gradient(90deg, var(--green) 0 8px, transparent 8px 14px) border-box;
  box-shadow: 0 0 0 3px rgba(23, 107, 75, .08);
}

.supplier-quote-dropzone.is-dragging {
  transform: translateY(-2px);
}

.supplier-quote-dropzone.has-file {
  background:
    linear-gradient(#f4faf7, #f4faf7) padding-box,
    repeating-linear-gradient(90deg, #5d9b7b 0 8px, transparent 8px 14px) border-box;
}

.supplier-quote-dropzone input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

.supplier-quote-upload-icon {
  display: grid;
  width: 48px;
  height: 48px;
  margin-bottom: 13px;
  color: var(--green);
  place-items: center;
  background: var(--green-soft);
  border-radius: 14px;
}

.supplier-quote-upload-icon svg {
  width: 24px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.6;
}

.supplier-quote-drop-title {
  color: #2f3c35;
  font-size: 13px;
  font-weight: 750;
}

.supplier-quote-drop-hint {
  margin-top: 7px;
  color: var(--muted);
  font-size: 10px;
}

.supplier-quote-selected-file {
  max-width: min(520px, 90%);
  margin-top: 14px;
  padding: 7px 11px;
  overflow: hidden;
  color: var(--green-deep);
  background: #fff;
  border: 1px solid #cee2d7;
  border-radius: 7px;
  font-size: 10px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-quote-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.supplier-quote-form-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 24px;
}

.supplier-quote-form-actions > p,
.supplier-quote-issues-footer > p {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: #78837e;
  font-size: 9px;
}

.supplier-quote-form-actions > p svg,
.supplier-quote-issues-footer > p svg {
  width: 16px;
  fill: none;
  stroke: var(--green);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5;
}

.supplier-quote-status-heading,
.supplier-quote-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 25px 30px 21px;
  border-bottom: 1px solid var(--soft-line);
}

.supplier-quote-status-heading > div,
.supplier-quote-section-heading > div {
  display: flex;
  align-items: center;
  gap: 14px;
}

.supplier-quote-status-heading h2,
.supplier-quote-section-heading h2 {
  margin: 0;
  font-family: Georgia, "Songti SC", serif;
  font-size: 20px;
}

.supplier-quote-status-heading p,
.supplier-quote-section-heading p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.6;
}

.supplier-quote-status-badge {
  flex: none;
  padding: 7px 11px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
}

.supplier-quote-status-badge.is-working {
  color: #315f83;
  background: var(--blue-soft);
}

.supplier-quote-status-badge.is-attention {
  color: #855719;
  background: var(--amber-soft);
}

.supplier-quote-status-badge.is-done {
  color: var(--green-deep);
  background: var(--green-soft);
}

.supplier-quote-status-badge.is-error {
  color: var(--red);
  background: var(--red-soft);
}

.supplier-quote-status-body {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(360px, .8fr);
  gap: 34px;
  padding: 27px 30px;
}

.supplier-quote-progress-block {
  min-width: 0;
}

.supplier-quote-progress-track {
  height: 7px;
  margin-bottom: 17px;
  overflow: hidden;
  background: #e5ebe7;
  border-radius: 99px;
}

.supplier-quote-progress-track i {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, #176b4b, #56a67e);
  border-radius: inherit;
  transition: width .4s ease;
}

.supplier-quote-progress-block strong {
  color: #28352f;
  font-size: 13px;
}

.supplier-quote-progress-block p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.65;
}

.supplier-quote-task-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 15px 20px;
  margin: 0;
  padding-left: 28px;
  border-left: 1px solid var(--soft-line);
}

.supplier-quote-task-meta dt {
  color: #8a938f;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .05em;
}

.supplier-quote-task-meta dd {
  margin: 5px 0 0;
  overflow: hidden;
  color: #35413b;
  font-size: 10px;
  font-weight: 720;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-quote-recognition-steps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  padding: 15px 30px;
  color: #87918c;
  background: #f7faf8;
  border-top: 1px solid var(--soft-line);
  font-size: 9px;
}

.supplier-quote-recognition-steps span {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
}

.supplier-quote-recognition-steps i {
  width: 7px;
  height: 7px;
  background: #cbd4cf;
  border-radius: 50%;
}

.supplier-quote-recognition-steps span.is-complete {
  color: var(--green-deep);
  font-weight: 750;
}

.supplier-quote-recognition-steps span.is-complete i {
  background: #45966f;
}

.supplier-quote-recognition-steps span.is-active {
  color: #315f83;
  font-weight: 750;
}

.supplier-quote-recognition-steps span.is-active i {
  background: #4a83af;
  box-shadow: 0 0 0 4px rgba(74, 131, 175, .12);
  animation: supplier-quote-pulse 1.4s ease-in-out infinite;
}

.supplier-quote-recognition-steps span.is-error {
  color: var(--red);
}

.supplier-quote-recognition-steps span.is-error i {
  background: var(--red);
}

@keyframes supplier-quote-pulse {
  50% { box-shadow: 0 0 0 7px rgba(74, 131, 175, 0); }
}

.supplier-quote-issue-count {
  flex: none;
  padding: 6px 10px;
  color: #875719;
  background: var(--amber-soft);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
}

.supplier-quote-issue-list {
  display: grid;
  gap: 12px;
  padding: 22px 30px 8px;
}

.supplier-quote-issue-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) minmax(210px, 260px);
  gap: 16px;
  align-items: start;
  padding: 18px;
  background: #fffdf9;
  border: 1px solid #eadcc3;
  border-radius: 11px;
}

.supplier-quote-issue-marker {
  display: grid;
  width: 30px;
  height: 30px;
  color: #8b5d22;
  place-items: center;
  background: #f8ecd9;
  border-radius: 8px;
  font-size: 9px;
  font-weight: 850;
}

.supplier-quote-issue-content {
  min-width: 0;
}

.supplier-quote-issue-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.supplier-quote-issue-heading h3 {
  margin: 1px 0 0;
  color: #2d3933;
  font-size: 12px;
}

.supplier-quote-issue-heading p {
  margin: 5px 0 0;
  color: #6f7974;
  font-size: 10px;
  line-height: 1.55;
}

.supplier-quote-issue-code {
  flex: none;
  max-width: 150px;
  padding: 4px 7px;
  overflow: hidden;
  color: #906225;
  background: #f8ecd9;
  border-radius: 5px;
  font-size: 8px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-quote-issue-context {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 12px 0 0;
}

.supplier-quote-issue-context div {
  min-width: 110px;
}

.supplier-quote-issue-context dt {
  color: #9a9183;
  font-size: 8px;
}

.supplier-quote-issue-context dd {
  max-width: 250px;
  margin: 3px 0 0;
  overflow: hidden;
  color: #534d43;
  font-size: 9px;
  font-weight: 720;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-quote-issue-evidence {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}

.supplier-quote-issue-evidence b,
.supplier-quote-issue-evidence span {
  padding: 4px 7px;
  border-radius: 5px;
  font-size: 8px;
}

.supplier-quote-issue-evidence b {
  padding-left: 0;
  color: #81786a;
}

.supplier-quote-issue-evidence span {
  color: #68736d;
  background: #f2f4f3;
}

.supplier-quote-issue-action {
  display: grid;
  gap: 10px;
  padding-left: 16px;
  border-left: 1px solid #eadfcb;
}

.supplier-quote-issue-action label > span {
  display: block;
  margin-bottom: 5px;
  color: #776e61;
  font-size: 8px;
  font-weight: 750;
}

.supplier-quote-issue-control,
.supplier-quote-scope {
  width: 100%;
  height: 38px;
  padding: 0 10px;
  color: #2d3933;
  background: #fff;
  border: 1px solid #d5c6aa;
  border-radius: 7px;
  outline: none;
  font-size: 10px;
}

.supplier-quote-scope {
  height: 32px;
  color: #65706a;
  border-color: #d9dedb;
  font-size: 9px;
}

.supplier-quote-issue-control:focus,
.supplier-quote-scope:focus {
  border-color: #a6783c;
  box-shadow: 0 0 0 3px rgba(166, 120, 60, .11);
}

.supplier-quote-issues-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 20px 30px 28px;
}

.supplier-quote-issues-footer > div {
  display: flex;
  gap: 9px;
}

.supplier-quote-result-hero {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 26px 30px;
  border-bottom: 1px solid var(--soft-line);
}

.supplier-quote-result-icon {
  display: grid;
  width: 42px;
  height: 42px;
  flex: none;
  color: #fff;
  place-items: center;
  background: var(--green);
  border-radius: 13px;
}

.supplier-quote-result-icon svg {
  width: 23px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.supplier-quote-result-hero > div {
  min-width: 0;
  flex: 1;
}

.supplier-quote-result-hero h2 {
  margin: 0;
  font-family: Georgia, "Songti SC", serif;
  font-size: 21px;
}

.supplier-quote-result-hero p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 10px;
}

.supplier-quote-download-button {
  flex: none;
}

.supplier-quote-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 20px 30px;
  border-bottom: 1px solid var(--soft-line);
}

.supplier-quote-metrics-note {
  margin: 0;
  padding: 10px 30px;
  border-bottom: 1px solid var(--soft-line);
  background: #fbfcfb;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

.supplier-quote-metric {
  min-width: 0;
  padding: 0 20px;
  border-right: 1px solid var(--soft-line);
}

.supplier-quote-metric:first-child {
  padding-left: 0;
}

.supplier-quote-metric:last-child {
  border-right: 0;
}

.supplier-quote-metric span,
.supplier-quote-metric b {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-quote-metric span {
  color: #858e89;
  font-size: 9px;
}

.supplier-quote-metric b {
  margin-top: 5px;
  color: #2d3933;
  font-family: Georgia, "Songti SC", serif;
  font-size: 20px;
  font-weight: 550;
}

.supplier-quote-result-table-wrap,
.supplier-quote-history-table-wrap {
  margin: 20px 24px 28px;
  overflow-x: auto;
  border: 1px solid #dce4df;
  border-radius: 11px;
}

.supplier-quote-result-table,
.supplier-quote-history-table {
  width: 100%;
  min-width: 1080px;
  border-collapse: separate;
  border-spacing: 0;
  text-align: left;
}

.supplier-quote-result-table th,
.supplier-quote-history-table th {
  padding: 12px 13px;
  color: #74807a;
  background: #f5f8f6;
  border-bottom: 1px solid #dce4df;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .025em;
  white-space: nowrap;
}

.supplier-quote-result-table td,
.supplier-quote-history-table td {
  max-width: 250px;
  padding: 14px 13px;
  overflow: hidden;
  color: #3a4640;
  border-bottom: 1px solid var(--soft-line);
  font-size: 10px;
  line-height: 1.5;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-quote-result-table tr:last-child td,
.supplier-quote-history-table tr:last-child td {
  border-bottom: 0;
}

.supplier-quote-result-table tbody tr:nth-child(even),
.supplier-quote-history-table tbody tr:nth-child(even) {
  background: #fcfdfc;
}

.supplier-quote-result-table tbody tr:hover,
.supplier-quote-history-table tbody tr:hover {
  background: #f3f8f5;
}

.supplier-quote-number-heading,
.supplier-quote-number-cell {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.supplier-quote-number-cell {
  font-weight: 720;
}

.supplier-quote-offer-cell {
  color: var(--green-deep) !important;
  background: rgba(231, 243, 237, .38);
}

.supplier-quote-barcode-cell {
  color: #53605a !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px !important;
}

.supplier-quote-product-cell {
  min-width: 180px;
  color: #26342d !important;
  font-weight: 720;
}

.supplier-quote-currency-cell {
  color: #586760 !important;
  font-size: 9px !important;
  font-weight: 800;
}

.supplier-quote-key-column span {
  display: inline-flex;
  max-width: 190px;
  padding: 4px 7px;
  overflow: hidden;
  color: var(--green-deep);
  background: var(--green-soft);
  border-radius: 5px;
  font-size: 8px;
  font-weight: 800;
  text-overflow: ellipsis;
}

.supplier-quote-empty {
  display: grid;
  justify-items: center;
  min-width: 100%;
  padding: 48px 20px;
  text-align: center;
}

.supplier-quote-empty > span {
  display: grid;
  width: 40px;
  height: 40px;
  color: var(--green);
  place-items: center;
  background: var(--green-soft);
  border-radius: 50%;
  font-weight: 800;
}

.supplier-quote-empty strong {
  margin-top: 11px;
  color: #35413b;
  font-size: 12px;
}

.supplier-quote-empty p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 10px;
}

.supplier-quote-empty .button {
  margin-top: 14px;
}

.supplier-quote-history-view {
  scroll-margin-top: 84px;
}

.supplier-quote-history-toolbar,
.supplier-quote-history-toolbar form,
.supplier-quote-history-pagination,
.supplier-quote-history-pagination > div {
  display: flex;
  align-items: center;
  gap: 8px;
}

.supplier-quote-history-toolbar {
  flex: none;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.supplier-quote-history-toolbar form {
  min-width: 280px;
}

.supplier-quote-history-toolbar input {
  min-width: 0;
  width: 190px;
  height: 42px;
  padding: 0 12px;
  color: var(--ink);
  background: white;
  border: 1px solid #cbd4cf;
  border-radius: 8px;
  font: inherit;
}

.supplier-quote-history-toolbar .button {
  min-height: 42px;
  padding-right: 15px;
  padding-left: 15px;
}

.supplier-quote-history-pagination {
  justify-content: space-between;
  padding: 0 24px 24px;
  color: var(--muted);
  font-size: 10px;
}

.supplier-quote-history-pagination .button {
  min-height: 38px;
  padding-right: 14px;
  padding-left: 14px;
}

.supplier-quote-history-table {
  min-width: 850px;
}

.supplier-quote-history-file {
  max-width: 300px !important;
}

.supplier-quote-history-supplier {
  color: var(--green-deep) !important;
  font-weight: 800;
}

.supplier-quote-history-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 7px;
  border-radius: 999px;
  font-size: 8px;
  font-weight: 800;
}

.supplier-quote-history-status::before {
  width: 5px;
  height: 5px;
  content: "";
  background: currentColor;
  border-radius: 50%;
}

.supplier-quote-history-status.is-done {
  color: var(--green-deep);
  background: var(--green-soft);
}

.supplier-quote-history-status.is-attention {
  color: #875719;
  background: var(--amber-soft);
}

.supplier-quote-history-status.is-working {
  color: #315f83;
  background: var(--blue-soft);
}

.supplier-quote-history-status.is-error {
  color: var(--red);
  background: var(--red-soft);
}

.supplier-quote-history-action {
  text-align: right;
}

.supplier-quote-history-action a {
  text-decoration: none;
}

.supplier-quote-page :focus-visible {
  outline: 3px solid rgba(23, 107, 75, .24);
  outline-offset: 3px;
}

.supplier-quote-page .button.is-loading {
  cursor: wait;
  opacity: .72;
}

@media (max-width: 960px) {
  .supplier-quote-main {
    width: min(100% - 28px, 820px);
    padding-top: 38px;
  }

  .supplier-quote-hero {
    align-items: flex-start;
  }

  .supplier-quote-status-body {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .supplier-quote-task-meta {
    padding: 20px 0 0;
    border-top: 1px solid var(--soft-line);
    border-left: 0;
  }

  .supplier-quote-issue-card {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .supplier-quote-issue-action {
    grid-column: 2;
    grid-template-columns: 1fr 1fr;
    padding: 14px 0 0;
    border-top: 1px solid #eadfcb;
    border-left: 0;
  }

  .supplier-quote-topbar .service-state {
    display: none;
  }
}

@media (max-width: 720px) {
  .supplier-quote-topbar {
    height: auto;
    min-height: 70px;
    padding: 10px 18px;
  }

  .supplier-quote-topbar .topbar-right {
    gap: 7px;
  }

  .supplier-quote-topbar .topbar-right > a:first-of-type,
  .supplier-quote-topbar .account-name {
    display: none;
  }

  .supplier-quote-main {
    width: calc(100% - 20px);
    padding-top: 30px;
  }

  .supplier-quote-hero {
    align-items: stretch;
    flex-direction: column;
    gap: 18px;
  }

  .supplier-quote-hero h1 {
    font-size: 34px;
  }

  .supplier-quote-new-button {
    align-self: flex-start;
  }

  .supplier-quote-workflow {
    overflow-x: auto;
  }

  .supplier-quote-workflow ol {
    min-width: 660px;
  }

  .supplier-quote-form-grid {
    grid-template-columns: 1fr;
  }

  .supplier-quote-status-heading,
  .supplier-quote-section-heading {
    align-items: flex-start;
  }

  .supplier-quote-history-view .supplier-quote-section-heading {
    flex-direction: column;
  }

  .supplier-quote-history-view .supplier-quote-section-heading > div,
  .supplier-quote-history-toolbar,
  .supplier-quote-history-toolbar form {
    width: 100%;
  }

  .supplier-quote-history-toolbar input {
    flex: 1;
    width: auto;
  }

  .supplier-quote-recognition-steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }

  .supplier-quote-recognition-steps span {
    justify-content: flex-start;
  }

  .supplier-quote-issue-card {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .supplier-quote-result-hero {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .supplier-quote-download-button {
    width: 100%;
  }

  .supplier-quote-metrics {
    grid-template-columns: repeat(2, 1fr);
  }

  .supplier-quote-metric {
    padding: 12px;
    border-bottom: 1px solid var(--soft-line);
  }

  .supplier-quote-metric:nth-child(2) {
    border-right: 0;
  }

  .supplier-quote-metric:nth-last-child(-n+2) {
    border-bottom: 0;
  }

  .supplier-quote-metric:nth-child(odd) {
    padding-left: 0;
  }
}

@media (max-width: 560px) {
  .supplier-quote-topbar .brand small {
    display: none;
  }

  .supplier-quote-topbar .supplier-quote-history-button {
    padding: 6px;
    font-size: 10px;
  }

  .supplier-quote-hero h1 {
    font-size: 29px;
  }

  .supplier-quote-history-toolbar form {
    min-width: 0;
  }

  .supplier-quote-history-pagination {
    align-items: flex-start;
    flex-direction: column;
    padding-right: 18px;
    padding-left: 18px;
  }

  .supplier-quote-upload-panel .panel-heading {
    align-items: flex-start;
    flex-direction: column;
    padding-right: 18px;
    padding-left: 18px;
  }

  .supplier-quote-upload-form {
    padding-right: 18px;
    padding-left: 18px;
  }

  .supplier-quote-dropzone {
    min-height: 190px;
    padding: 24px 16px;
  }

  .supplier-quote-form-actions,
  .supplier-quote-issues-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .supplier-quote-form-actions .button,
  .supplier-quote-issues-footer .button {
    width: 100%;
  }

  .supplier-quote-status-heading,
  .supplier-quote-section-heading {
    padding-right: 18px;
    padding-left: 18px;
  }

  .supplier-quote-status-body {
    padding-right: 18px;
    padding-left: 18px;
  }

  .supplier-quote-task-meta {
    grid-template-columns: 1fr 1fr;
  }

  .supplier-quote-recognition-steps {
    grid-template-columns: repeat(2, 1fr);
    padding-right: 18px;
    padding-left: 18px;
  }

  .supplier-quote-issue-list {
    padding-right: 12px;
    padding-left: 12px;
  }

  .supplier-quote-issue-card {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .supplier-quote-issue-marker {
    display: none;
  }

  .supplier-quote-issue-heading {
    flex-direction: column;
    gap: 8px;
  }

  .supplier-quote-issue-action {
    grid-column: 1;
    grid-template-columns: 1fr;
  }

  .supplier-quote-issues-footer {
    padding-right: 18px;
    padding-left: 18px;
  }

  .supplier-quote-issues-footer > div {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .supplier-quote-result-hero {
    padding-right: 18px;
    padding-left: 18px;
  }

  .supplier-quote-metrics {
    padding-right: 18px;
    padding-left: 18px;
  }

  .supplier-quote-result-table-wrap,
  .supplier-quote-history-table-wrap {
    margin-right: 10px;
    margin-left: 10px;
    overflow: visible;
    border: 0;
  }

  .supplier-quote-result-table,
  .supplier-quote-history-table {
    min-width: 0;
  }

  .supplier-quote-result-table thead,
  .supplier-quote-history-table thead {
    display: none;
  }

  .supplier-quote-result-table,
  .supplier-quote-result-table tbody,
  .supplier-quote-history-table,
  .supplier-quote-history-table tbody {
    display: block;
  }

  .supplier-quote-result-table tbody,
  .supplier-quote-history-table tbody {
    display: grid;
    gap: 10px;
  }

  .supplier-quote-result-table tr,
  .supplier-quote-history-table tr {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 12px;
    background: #fff !important;
    border: 1px solid #dfe6e2;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(25, 42, 34, .04);
  }

  .supplier-quote-result-table td,
  .supplier-quote-history-table td {
    display: block;
    max-width: none;
    min-width: 0;
    padding: 8px 6px;
    border: 0;
    text-align: left;
    white-space: normal;
  }

  .supplier-quote-result-table td::before,
  .supplier-quote-history-table td::before {
    display: block;
    margin-bottom: 4px;
    color: #929b96;
    content: attr(data-label);
    font-size: 7px;
    font-weight: 800;
    letter-spacing: .04em;
  }

  .supplier-quote-product-cell,
  .supplier-quote-key-column,
  .supplier-quote-history-file {
    grid-column: 1 / -1;
  }

  .supplier-quote-history-action {
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  .supplier-quote-page *,
  .supplier-quote-page *::before,
  .supplier-quote-page *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* Sales workspace: list-first navigation and compact enterprise pages. */
.sales-demand-page .sales-import-main {
  width: min(1440px, calc(100% - 64px));
  padding: 32px 0 72px;
}

.sales-back-link { font-size: 12px !important; }
.sales-back-link svg { width: 16px; }

.sales-import-head {
  min-height: 148px;
  margin-bottom: 18px;
  padding: 25px 28px;
}

.sales-import-head .hero-copy > p:last-child {
  max-width: 760px;
  margin-top: 9px;
  font-size: 14px;
}

.sales-import-head h1 { font-size: clamp(28px, 2.5vw, 36px); }
.sales-import-head .hero-navigation {
  min-width: 370px;
  padding: 14px 16px;
  box-shadow: none;
}

.sales-demand-page .workflow {
  margin-bottom: 18px;
  padding: 15px 24px;
  background: #e8eeea;
}

.sales-demand-page .workflow b { font-size: 14px; }
.sales-demand-page .workflow small { font-size: 11px; }
.sales-demand-page .panel-heading h2,
.sales-demand-page .result-hero h2 { font-size: 22px; }
.sales-demand-page .panel-heading p,
.sales-demand-page .result-hero p { font-size: 13px; }
.sales-demand-page .mapping-table th,
.sales-demand-page .result-table th { font-size: 12px; }
.sales-demand-page .mapping-table td,
.sales-demand-page .result-table td { font-size: 13px; }
.sales-demand-page .result-price b { font-size: 13px; }
.sales-demand-page .result-price small { font-size: 10px; }

.result-table-heading { margin: 24px 30px 12px; }
.result-table-heading > div { min-width: 0; }
.result-table-heading strong,
.result-table-heading span { display: block; }
.result-table-heading strong { font-size: 15px; }
.result-table-heading span { margin-top: 4px; font-size: 11px; }
.result-table-heading .button { flex: none; min-height: 38px; }

.history-page { background: #f3f6f4; }
.history-main {
  width: min(1680px, calc(100% - 48px));
  padding: 28px 0 64px;
}

.sales-demand-page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 20px;
  padding: 6px 2px 4px;
}

.sales-demand-page-copy { min-width: 0; }
.sales-demand-page-copy .eyebrow { margin-bottom: 6px; }
.sales-demand-title-row { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; }
.sales-demand-title-row h1 {
  margin: 0;
  font-family: Georgia, "Songti SC", serif;
  font-size: clamp(30px, 3vw, 38px);
  font-weight: 550;
  letter-spacing: -.025em;
}
.sales-demand-title-row > span {
  padding: 6px 10px;
  color: #37604d;
  background: #e5f1eb;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}
.sales-demand-title-row strong { font-size: 14px; }
.sales-demand-page-copy > p:last-child {
  margin: 8px 0 0;
  color: #69756f;
  font-size: 14px;
}
.sales-demand-import-button { min-height: 44px; padding-right: 20px; padding-left: 20px; }

.history-filter-panel,
.history-results-panel { margin-top: 0; border-radius: 14px; box-shadow: 0 6px 24px rgba(24, 55, 41, .045); }
.history-filter-panel { margin-bottom: 18px; }
.history-filter-heading { padding: 18px 22px 0; }
.history-filter-heading h2 { font-family: inherit; font-size: 17px; font-weight: 750; }
.history-filter-heading p { font-size: 12px; }
.history-filter-form {
  grid-template-columns: minmax(320px, 1.45fr) minmax(190px, .8fr) minmax(330px, 1.2fr) minmax(190px, auto);
  gap: 12px;
  padding: 16px 22px 20px;
}
.history-filter-form .field > span { margin-bottom: 7px; font-size: 13px; }
.history-multiselect summary > span { font-size: 13px; }
.history-owner-filter > span small { font-size: 11px; }
.history-owner-option { font-size: 12px; }
.history-filter-actions { grid-template-columns: 78px 96px; justify-content: end; }
.history-active-filters { padding: 0 22px 16px; font-size: 11px; }

.history-results-heading { padding: 19px 22px; }
.history-results-heading > div:first-child { gap: 0; }
.history-results-heading h2 { font-family: inherit; font-size: 18px; font-weight: 750; }
.history-results-heading p { font-size: 12px; }
.history-results-meta { gap: 10px; font-size: 12px; }
.history-total { font-size: 12px; }
.history-export-button { min-width: 142px; font-size: 13px; }

.history-table-wrap { margin: 0 12px; border-radius: 10px; }
.history-table th {
  padding: 12px 7px;
  color: #5f6d66;
  font-size: 11px;
  line-height: 1.35;
}
.history-table td {
  padding: 13px 7px;
  color: #2e3b34;
  font-size: 12px;
  line-height: 1.45;
}
.history-number,
.history-price b { font-size: 12px !important; }
.history-barcode { font-size: 11px !important; }
.history-price small { font-size: 9px; }
.history-customer-code a { font-size: 12px; }
.history-pagination { padding: 16px 22px 20px; }
.history-pagination > span { font-size: 12px; }

@media (max-width: 1440px) {
  .sales-demand-page .sales-import-main { width: min(100% - 40px, 1220px); }
  .history-main { width: calc(100% - 32px); }
  .history-table th { padding-right: 5px; padding-left: 5px; font-size: 10px; }
  .history-table td { padding-right: 5px; padding-left: 5px; font-size: 11px; }
}

@media (min-width: 1121px) and (max-width: 1440px) {
  .history-filter-form { grid-template-columns: minmax(0, 1.15fr) minmax(150px, .68fr) minmax(260px, 1.05fr) 178px; }
  .history-date-range { grid-column: auto; }
  .history-filter-actions { grid-column: auto; width: auto; justify-self: stretch; }
}

@media (max-width: 900px) {
  .sales-demand-page .sales-import-main { width: min(100% - 28px, 820px); padding-top: 24px; }
  .sales-import-head { align-items: flex-start; flex-direction: column; min-height: 0; }
  .sales-import-head .hero-navigation { width: 100%; min-width: 0; }
  .history-main { width: min(100% - 28px, 820px); padding-top: 24px; }
  .sales-demand-page-head { align-items: flex-start; }
  .history-filter-form { grid-template-columns: 1fr 1fr; }
  .history-keyword, .history-date-range { grid-column: 1 / -1; }
  .history-filter-actions { grid-column: auto; }
  .history-table-wrap { margin: 12px; overflow: visible; border: 0; border-radius: 0; }
  .history-table { min-width: 0; table-layout: auto; }
  .history-table colgroup,
  .history-table thead { display: none; }
  .history-table,
  .history-table tbody { display: block; }
  .history-table tbody { display: grid; gap: 10px; }
  .history-table tbody tr {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 15px;
    background: #fff !important;
    border: 1px solid #dfe6e2;
    border-radius: 11px;
    box-shadow: 0 4px 14px rgba(25, 42, 34, .04);
  }
  .history-table td { display: block; min-width: 0; padding: 8px 6px; border: 0; text-align: left; }
  .history-table td::before {
    display: block;
    margin-bottom: 5px;
    color: #7c8882;
    content: attr(data-label);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .04em;
  }
  .history-table td.history-product-name-cell { grid-column: 1 / -1; }
  .history-page .history-table td.history-nowrap,
  .history-page .history-table td.history-barcode { overflow: visible; text-overflow: clip; white-space: normal; overflow-wrap: anywhere; }
  .history-page .history-customer-code a { white-space: normal; overflow-wrap: anywhere; }
  .history-price { justify-content: flex-start; }
}

@media (max-width: 680px) {
  .sales-back-link { display: none; }
  .sales-demand-page .sales-import-main,
  .history-main { width: calc(100% - 20px); }
  .sales-demand-page-head { align-items: stretch; flex-direction: column; gap: 16px; }
  .sales-demand-import-button { width: 100%; }
  .history-filter-form { grid-template-columns: 1fr; }
  .history-keyword, .history-date-range { grid-column: auto; }
  .history-filter-actions { width: 100%; justify-self: stretch; }
  .result-table-heading { align-items: stretch; flex-direction: column; margin-right: 18px; margin-left: 18px; }
  .result-table-heading .button { width: 100%; }
}

/* 2026-09 WCDI platform-wide workspace refresh */
.workspace-main { margin-right: auto; margin-left: auto; }

.workspace-page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 142px;
  margin-bottom: 18px;
  padding: 24px 28px;
  background: #fff;
  border: 1px solid #dce4df;
  border-radius: 16px;
  box-shadow: 0 7px 24px rgba(25, 42, 34, .04);
}
.workspace-page-head > div:first-child { min-width: 0; }
.workspace-page-head .eyebrow { margin-bottom: 7px; color: var(--green); font-size: 10px; font-weight: 800; letter-spacing: .11em; }
.workspace-page-head h1 { margin: 0; color: #1d2c25; font-family: Georgia, "Songti SC", serif; font-size: 30px; font-weight: 550; line-height: 1.2; }
.workspace-page-head > div:first-child > p:last-child { max-width: 760px; margin: 9px 0 0; color: #66726c; font-size: 13px; line-height: 1.7; }
.workspace-page-actions { display: flex; align-items: center; gap: 16px; flex: none; }
.workspace-result-count { min-width: 92px; padding-right: 17px; border-right: 1px solid #e1e7e3; text-align: right; }
.workspace-result-count strong, .workspace-result-count span { display: block; }
.workspace-result-count strong { color: #1b6046; font-family: Georgia, serif; font-size: 27px; font-weight: 550; }
.workspace-result-count span { margin-top: 3px; color: #7a8580; font-size: 10px; }
.workspace-context-note { min-width: 260px; padding: 15px 17px; background: #f4f8f6; border: 1px solid #dce7e1; border-radius: 12px; }
.workspace-context-note span, .workspace-context-note strong, .workspace-context-note small { display: block; }
.workspace-context-note span { color: #77837d; font-size: 10px; font-weight: 800; letter-spacing: .08em; }
.workspace-context-note strong { margin-top: 5px; color: #264b3a; font-size: 13px; }
.workspace-context-note small { margin-top: 5px; color: #84908a; font-size: 11px; }
.workspace-data-panel { border-radius: 14px; box-shadow: 0 7px 24px rgba(25, 42, 34, .04); }

/* Workbench */
.platform-dashboard.platform-dashboard-v2 { width: min(1540px, calc(100% - 48px)); padding: 26px 0 52px; }
.platform-dashboard-hero.platform-dashboard-hero-v2 { grid-template-columns: minmax(0, 1fr) 350px; min-height: 250px; padding: 34px 38px; border-radius: 18px; box-shadow: 0 16px 45px rgba(21, 64, 47, .12); }
.platform-dashboard-hero-v2 h1 { font-size: clamp(32px, 3.6vw, 46px); }
.platform-dashboard-hero-v2 > div:first-child > p:last-of-type { max-width: 680px; margin-top: 13px; }
.platform-dashboard-hero-v2 .platform-hero-actions { margin-top: 22px; }
.platform-domain-summary { padding: 16px 18px; background: rgba(255,255,255,.075); border: 1px solid rgba(255,255,255,.13); border-radius: 14px; }
.platform-domain-summary > p { margin: 0 0 7px; color: #91aa9f; font-size: 10px; font-weight: 800; letter-spacing: .1em; }
.platform-domain-summary ul { margin: 0; padding: 0; list-style: none; }
.platform-domain-summary li { display: flex; align-items: center; gap: 11px; padding: 10px 0; border-top: 1px solid rgba(255,255,255,.09); }
.platform-domain-summary li > span { display: grid; width: 40px; height: 27px; flex: none; place-items: center; color: #dff3e9; background: rgba(85,193,141,.14); border-radius: 6px; font-size: 10px; font-weight: 800; }
.platform-domain-summary li > span.is-purchase { color: #ffe5be; background: rgba(222,160,85,.14); }
.platform-domain-summary li > span.is-collaboration { color: #dbe8ff; background: rgba(114,151,211,.15); }
.platform-domain-summary strong, .platform-domain-summary small { display: block; }
.platform-domain-summary strong { color: #fff; font-size: 11px; }
.platform-domain-summary small { margin-top: 3px; color: #91aa9f; font-size: 11px; }
.platform-business-section { margin-top: 28px; }
.platform-domain-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.platform-domain-card { min-width: 0; padding: 22px; background: #fff; border: 1px solid #dfe6e2; border-top: 3px solid #59aa82; border-radius: 14px; box-shadow: 0 7px 24px rgba(27,53,42,.04); }
.platform-domain-card.is-purchase { border-top-color: #d3a059; }
.platform-domain-card.is-collaboration { border-top-color: #6d91c8; }
.platform-domain-card-head { display: flex; align-items: center; justify-content: space-between; }
.platform-domain-card .platform-module-status { position: static; }
.platform-module-icon.is-collaboration { color: #4b70aa; background: #eaf0f9; }
.platform-domain-card > small { display: block; margin-top: 18px; color: #6b7771; font-size: 10px; font-weight: 800; letter-spacing: .1em; }
.platform-domain-card h3 { margin: 5px 0 8px; color: #203029; font-size: 19px; }
.platform-domain-card > p { min-height: 44px; margin: 0; color: #69756f; font-size: 12px; line-height: 1.7; }
.platform-domain-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.platform-domain-actions .button { min-height: 38px; padding: 0 15px; }
.platform-operation-grid { display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(280px, .7fr); gap: 14px; margin-top: 18px; }
.platform-data-flow.platform-data-flow-v2 { grid-template-columns: 220px minmax(0,1fr); margin: 0; padding: 23px 25px; border-radius: 14px; }
.platform-data-flow-v2 h2, .platform-roadmap h2 { font-size: 20px; }
.platform-roadmap { padding: 23px 24px; background: #fff; border: 1px solid #dfe6e2; border-radius: 14px; }
.platform-roadmap h2 { margin: 0; font-family: Georgia, "Songti SC", serif; font-weight: 550; }
.platform-roadmap ul { margin: 15px 0 0; padding: 0; list-style: none; }
.platform-roadmap li { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 9px 0; border-top: 1px solid #edf1ef; font-size: 11px; }
.platform-roadmap li small { flex: none; color: #839089; font-size: 11px; }

/* Supplier quote */
.supplier-quote-page .supplier-quote-main { width: min(1540px, calc(100% - 48px)); padding: 26px 0 54px; }
.supplier-quote-page .supplier-quote-page-head { margin-bottom: 18px; }
.supplier-quote-page .supplier-quote-workflow { margin-bottom: 18px; }
.supplier-quote-page .supplier-quote-upload-panel,
.supplier-quote-page .supplier-quote-status-panel,
.supplier-quote-page .supplier-quote-issues-panel,
.supplier-quote-page .supplier-quote-result-panel,
.supplier-quote-page .supplier-quote-history-view { border-radius: 14px; }
.supplier-quote-page .supplier-quote-history-view { margin-top: 0; scroll-margin-top: 86px; }
.supplier-quote-page .supplier-quote-history-table th { font-size: 11px; }
.supplier-quote-page .supplier-quote-history-table td { font-size: 12px; }

/* System and profile pages */
.accounts-page .accounts-main,
.profile-page .accounts-main { width: min(1400px, calc(100% - 48px)); max-width: none; padding: 26px 0 54px; }
.accounts-page .account-create,
.accounts-page .account-list-panel,
.profile-page .account-create { border-radius: 14px; box-shadow: 0 7px 24px rgba(25,42,34,.04); }
.accounts-page .account-form { grid-template-columns: minmax(150px,.9fr) minmax(190px,1.15fr) minmax(130px,.7fr) minmax(170px,1fr) auto; }
.profile-identity-card { display: flex; align-items: center; gap: 13px; min-width: 260px; padding: 13px 16px; background: #f4f8f6; border: 1px solid #dce7e1; border-radius: 12px; }
.profile-identity-avatar { display: grid; width: 42px; height: 42px; flex: none; place-items: center; color: #fff; background: #1b6649; border-radius: 11px; font-size: 15px; font-weight: 800; }
.profile-identity-card div strong, .profile-identity-card div span, .profile-identity-card div small { display: block; }
.profile-identity-card strong { color: #24352d; font-size: 13px; }
.profile-identity-card div > span { margin-top: 3px; color: #516058; font-size: 10px; }
.profile-identity-card small { margin-top: 3px; color: #84908a; font-size: 11px; }
.profile-page .profile-form { max-width: 760px; }
.rules-page .rules-summary { margin-top: 0; }
.rules-page .rules-table th { font-size: 11px; }
.rules-page .rules-table td { font-size: 12px; }
.rules-page .rule-identity strong { font-size: 13px; }

@media (max-width: 1180px) {
  .platform-dashboard-hero.platform-dashboard-hero-v2 { grid-template-columns: 1fr; }
  .platform-domain-summary { display: none; }
  .platform-domain-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .platform-domain-card.is-collaboration { grid-column: 1 / -1; }
  .platform-operation-grid { grid-template-columns: 1fr; }
  .accounts-page .account-form { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 900px) {
  .platform-dashboard-hero.platform-dashboard-hero-v2 { grid-template-columns: 1fr; }
  .platform-domain-summary { display: none; }
  .workspace-page-head { min-height: 0; }
}

@media (max-width: 700px) {
  .platform-dashboard.platform-dashboard-v2,
  .supplier-quote-page .supplier-quote-main,
  .accounts-page .accounts-main,
  .profile-page .accounts-main,
  .rules-page .rules-main { width: calc(100% - 20px); padding-top: 18px; }
  .workspace-page-head { align-items: stretch; flex-direction: column; gap: 16px; padding: 20px; }
  .platform-dashboard-hero.platform-dashboard-hero-v2 { padding: 28px 22px; border-radius: 16px; }
  .workspace-page-head h1 { font-size: 26px; }
  .workspace-page-actions { align-items: stretch; flex-direction: column; }
  .workspace-result-count { padding: 0 0 10px; border-right: 0; border-bottom: 1px solid #e1e7e3; text-align: left; }
  .workspace-context-note, .profile-identity-card { min-width: 0; }
  .platform-domain-grid { grid-template-columns: 1fr; }
  .platform-domain-card.is-collaboration { grid-column: auto; }
  .platform-data-flow.platform-data-flow-v2 { grid-template-columns: 1fr; }
  .accounts-page .account-form { grid-template-columns: 1fr; }
}

/* WCDI business data platform shell */
.platform-page {
  --platform-sidebar: #10271f;
  --platform-sidebar-soft: #19382e;
  --platform-accent: #55c18d;
  min-height: 100vh;
  background: #f3f6f4;
}

.platform-shell {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  min-height: 100vh;
}

.platform-sidebar {
  position: sticky;
  z-index: 30;
  top: 0;
  display: flex;
  height: 100vh;
  min-width: 0;
  flex-direction: column;
  padding: 25px 16px 18px;
  color: #dfece6;
  background:
    radial-gradient(circle at 20% 0, rgba(74, 164, 119, .2), transparent 230px),
    var(--platform-sidebar);
  box-shadow: 12px 0 40px rgba(15, 39, 31, .08);
}

.platform-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 46px;
  margin: 0 8px 31px;
  color: #fff;
  text-decoration: none;
}

.platform-brand-mark {
  display: grid;
  width: 40px;
  height: 40px;
  flex: none;
  place-items: center;
  color: #10271f;
  background: #ecf7f1;
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: 12px;
  font-family: Georgia, serif;
  font-size: 20px;
  font-weight: 800;
  box-shadow: 0 10px 28px rgba(0, 0, 0, .18);
}

.platform-brand strong,
.platform-brand small { display: block; }
.platform-brand strong { font-size: 17px; letter-spacing: .09em; }
.platform-brand small { margin-top: 3px; color: #94aea3; font-size: 10px; letter-spacing: .08em; }
.platform-menu-button { display: none; }

.platform-nav {
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, .15) transparent;
}

.platform-nav-group { margin-bottom: 24px; }
.platform-nav-group > p {
  margin: 0 12px 8px;
  color: #6f9183;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .16em;
}

.platform-nav-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 42px;
  margin: 3px 0;
  padding: 0 11px;
  color: #a9bdb5;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 650;
  text-decoration: none;
  transition: color .16s ease, background .16s ease, border-color .16s ease;
}

a.platform-nav-item:hover { color: #fff; background: rgba(255, 255, 255, .055); }
.platform-nav-item:focus-visible,
.platform-user:focus-visible {
  outline: 2px solid #79d7aa;
  outline-offset: 2px;
}
.platform-nav-item.is-active {
  color: #fff;
  background: var(--platform-sidebar-soft);
  border-color: rgba(111, 196, 153, .2);
  box-shadow: inset 3px 0 0 var(--platform-accent);
}

.platform-nav-item svg {
  width: 18px;
  height: 18px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.55;
}

.platform-nav-item > span { min-width: 0; flex: 1; }
.platform-nav-item > small {
  flex: none;
  padding: 3px 5px;
  color: #789187;
  background: rgba(255, 255, 255, .05);
  border-radius: 4px;
  font-size: 9px;
  font-weight: 700;
}

.platform-nav-item.is-disabled { color: #668078; cursor: default; }
.platform-nav-dot {
  width: 6px;
  height: 6px;
  flex: none;
  background: #50c487;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(80, 196, 135, .1);
}

.platform-user {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: auto;
  padding: 11px 10px;
  color: #dce9e3;
  background: rgba(255, 255, 255, .045);
  border: 1px solid rgba(255, 255, 255, .075);
  border-radius: 11px;
  text-decoration: none;
}

.platform-user:hover,
.platform-user.is-active { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .13); }
.platform-user-avatar {
  display: grid;
  width: 32px;
  height: 32px;
  flex: none;
  place-items: center;
  color: #174633;
  background: #dcefe5;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 800;
}

.platform-user > span:nth-child(2) { min-width: 0; flex: 1; }
.platform-user strong,
.platform-user small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.platform-user strong { font-size: 11px; }
.platform-user small { margin-top: 3px; color: #7f998f; font-size: 9px; }
.platform-user > svg {
  width: 14px;
  flex: none;
  fill: none;
  stroke: #6f8c80;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.platform-workspace { min-width: 0; }
.platform-page-heading,
.platform-page .platform-topbar .topbar-right { min-width: 0; }
.platform-page .platform-topbar {
  position: sticky;
  z-index: 20;
  top: 0;
  height: 68px;
  padding: 0 30px;
  background: rgba(255, 255, 255, .9);
  border-bottom-color: #dfe6e2;
  backdrop-filter: blur(16px);
}

.platform-page-heading span,
.platform-page-heading strong { display: block; }
.platform-page-heading span { margin-bottom: 3px; color: #637069; font-size: 10px; font-weight: 700; letter-spacing: .06em; }
.platform-page-heading strong { color: #1b2b24; font-size: 14px; letter-spacing: .01em; }
.platform-page .platform-topbar .topbar-right { gap: 13px; }
.platform-page .platform-topbar .text-button { font-size: 11px; text-decoration: none; }
.platform-page .platform-topbar .service-state {
  padding-right: 13px;
  border-right: 1px solid #e2e8e4;
  font-size: 11px;
}
.platform-page .platform-topbar .account-name { max-width: 110px; }

/* Shared business-page introduction */
.business-purpose-hero {
  position: relative;
  padding: 30px 32px;
  background:
    radial-gradient(circle at 90% 4%, rgba(74, 164, 119, .1), transparent 220px),
    linear-gradient(135deg, rgba(255, 255, 255, .98), rgba(244, 249, 246, .96));
  border: 1px solid #dce6e0;
  border-radius: 20px;
  box-shadow: 0 14px 38px rgba(24, 55, 41, .055);
}

.business-purpose-hero .eyebrow {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 8px;
  padding: 5px 9px;
  color: #236e50;
  background: #e6f3ec;
  border-radius: 999px;
  letter-spacing: .08em;
}

.history-hero.business-purpose-hero,
.rules-hero.business-purpose-hero,
.supplier-quote-hero.business-purpose-hero {
  margin-bottom: 24px;
}

.history-hero.business-purpose-hero .history-hero-summary,
.rules-hero.business-purpose-hero .rules-memory-state {
  background: #fff;
  box-shadow: 0 8px 24px rgba(27, 54, 40, .045);
}

/* Platform dashboard */
.platform-dashboard {
  width: min(1240px, calc(100% - 64px));
  padding: 42px 0 72px;
}

.platform-dashboard-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 48px;
  align-items: center;
  min-height: 320px;
  padding: 48px 50px;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 86% 4%, rgba(94, 201, 147, .3), transparent 260px),
    linear-gradient(135deg, #102b21 0%, #174b37 100%);
  border-radius: 22px;
  box-shadow: 0 24px 60px rgba(21, 64, 47, .14);
}

.platform-dashboard-hero::after {
  position: absolute;
  right: -80px;
  bottom: -150px;
  width: 380px;
  height: 380px;
  content: "";
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 50%;
  box-shadow: 0 0 0 55px rgba(255, 255, 255, .025), 0 0 0 110px rgba(255, 255, 255, .018);
}

.platform-dashboard-hero > * { position: relative; z-index: 1; }
.platform-dashboard-hero .eyebrow { color: #7dd7aa; }
.platform-dashboard-hero h1 {
  max-width: 650px;
  margin: 0;
  font-family: Georgia, "Songti SC", serif;
  font-size: clamp(34px, 4.2vw, 54px);
  font-weight: 500;
  line-height: 1.13;
  letter-spacing: -.035em;
}

.platform-dashboard-hero > div:first-child > p:last-of-type {
  max-width: 660px;
  margin: 18px 0 0;
  color: #b9cec5;
  font-size: 14px;
  line-height: 1.8;
}

.platform-hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.platform-dashboard-hero .button-primary { color: #143929; background: #eaf7f0; box-shadow: none; }
.platform-dashboard-hero .button-secondary { color: #dcebe4; background: rgba(255, 255, 255, .075); border-color: rgba(255, 255, 255, .2); }

.platform-capability-card {
  padding: 25px;
  background: rgba(255, 255, 255, .075);
  border: 1px solid rgba(255, 255, 255, .13);
  border-radius: 16px;
  backdrop-filter: blur(10px);
}

.platform-capability-card > span { color: #9cb9ac; font-size: 11px; font-weight: 700; letter-spacing: .1em; }
.platform-capability-card > strong { display: block; margin-top: 8px; font-family: Georgia, serif; font-size: 48px; font-weight: 500; line-height: 1; }
.platform-capability-card > p { margin: 7px 0 20px; color: #acc4b9; font-size: 12px; }
.platform-capability-card dl { margin: 0; }
.platform-capability-card dl > div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0;
  border-top: 1px solid rgba(255, 255, 255, .1);
  font-size: 11px;
}
.platform-capability-card dt { color: #fff; font-weight: 700; }
.platform-capability-card dd { margin: 0; color: #91aa9f; text-align: right; }

.platform-section { margin-top: 38px; }
.platform-section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}
.platform-section-heading h2,
.platform-data-flow h2 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 25px; font-weight: 550; }
.platform-section-heading > span { color: #5f6b65; font-size: 11px; }
.platform-module-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }

.platform-module-card {
  position: relative;
  min-height: 240px;
  padding: 26px;
  color: inherit;
  background: #fff;
  border: 1px solid #dfe6e2;
  border-radius: 16px;
  box-shadow: 0 9px 30px rgba(27, 53, 42, .045);
  text-decoration: none;
}

a.platform-module-card { transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
a.platform-module-card:hover { transform: translateY(-3px); border-color: #b7d1c3; box-shadow: 0 18px 42px rgba(27, 66, 49, .09); }
.platform-module-card.is-planned { color: #75817b; background: #f8faf9; border-style: dashed; }
.platform-module-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: #5f786d;
  background: #eef3f0;
  border-radius: 12px;
}
.platform-module-icon.is-sales { color: #176b4d; background: #e8f5ee; }
.platform-module-icon.is-supplier { color: #8b5d26; background: #fbf1e4; }
.platform-module-icon svg { width: 23px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.6; }
.platform-module-status {
  position: absolute;
  top: 26px;
  right: 26px;
  padding: 5px 8px;
  color: #176b4d;
  background: #e9f5ef;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 750;
}
.platform-module-card.is-planned .platform-module-status { color: #4f5c55; background: #edf1ef; }
.platform-module-card > small { display: block; margin-top: 22px; color: #5f6b65; font-size: 10px; font-weight: 750; letter-spacing: .1em; }
.platform-module-card h3 { margin: 6px 0 9px; color: #203029; font-size: 19px; }
.platform-module-card p { max-width: 500px; min-height: 43px; margin: 0 0 19px; color: #69756f; font-size: 13px; line-height: 1.7; }
.platform-module-card > strong { color: #176b4d; font-size: 12px; }
.platform-module-card.is-planned > strong { color: #526159; }

.platform-data-flow {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 34px;
  align-items: center;
  margin-top: 24px;
  padding: 28px 30px;
  background: #fff;
  border: 1px solid #dfe6e2;
  border-radius: 16px;
}
.platform-data-flow ol { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0; padding: 0; list-style: none; }
.platform-data-flow li { position: relative; display: flex; gap: 10px; min-width: 0; padding-right: 14px; }
.platform-data-flow li:not(:last-child)::after {
  position: absolute;
  top: 13px;
  right: 7px;
  width: 16px;
  content: "→";
  color: #adc0b6;
  font-size: 12px;
}
.platform-data-flow li > span {
  display: grid;
  width: 28px;
  height: 28px;
  flex: none;
  place-items: center;
  color: #176b4d;
  background: #eaf5ef;
  border-radius: 8px;
  font-size: 8px;
  font-weight: 800;
}
.platform-data-flow strong,
.platform-data-flow small { display: block; }
.platform-data-flow strong { margin-top: 1px; font-size: 12px; }
.platform-data-flow small { margin-top: 4px; color: #637069; font-size: 11px; line-height: 1.4; }

/* Account entry point follows the platform identity. */
.auth-page {
  background:
    radial-gradient(circle at 12% 14%, rgba(52, 137, 99, .13), transparent 360px),
    #e9f0ec;
}
.auth-page .auth-brand .platform-brand-mark { color: #fff; background: #153c2d; border-color: #153c2d; }
.auth-capability-list { display: grid; gap: 11px; margin: 28px 0 0; padding: 0; list-style: none; }
.auth-capability-list li { display: flex; align-items: center; gap: 10px; color: #4f6058; font-size: 11px; }
.auth-capability-list span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  color: #176b4d;
  background: #dbece3;
  border-radius: 8px;
  font-size: 8px;
  font-weight: 800;
}

@media (max-width: 1180px) {
  .platform-shell { grid-template-columns: 220px minmax(0, 1fr); }
  .platform-sidebar { padding-right: 12px; padding-left: 12px; }
  .platform-nav-item { padding-right: 9px; padding-left: 9px; font-size: 11px; }
  .platform-dashboard { width: min(1120px, calc(100% - 40px)); }
  .platform-dashboard-hero { grid-template-columns: minmax(0, 1fr) 300px; gap: 32px; padding: 42px; }
  .platform-data-flow { grid-template-columns: 220px minmax(0, 1fr); }
}

@media (max-width: 900px) {
  .platform-shell { display: block; }
  .platform-sidebar {
    position: relative;
    display: block;
    width: 100%;
    height: auto;
    padding: 13px 14px 11px;
    box-shadow: none;
  }
  .platform-brand { width: fit-content; min-height: 38px; margin: 0 96px 0 2px; }
  .platform-brand-mark { width: 34px; height: 34px; border-radius: 10px; font-size: 17px; }
  .platform-brand strong { font-size: 14px; }
  .platform-brand small { font-size: 8px; }
  .platform-menu-button {
    position: absolute;
    top: 15px;
    right: 56px;
    display: grid;
    width: 32px;
    height: 32px;
    padding: 0;
    place-items: center;
    color: #dce9e3;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 9px;
    cursor: pointer;
  }
  .platform-menu-button svg { width: 18px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-width: 1.7; }
  .platform-menu-button:focus-visible { outline: 2px solid #79d7aa; outline-offset: 2px; }
  .platform-nav { display: none; margin-top: 13px; padding: 14px 0 2px; overflow: visible; border-top: 1px solid rgba(255, 255, 255, .09); }
  .platform-sidebar.is-menu-open .platform-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 14px; }
  .platform-nav-group { display: block; margin: 0 0 12px; }
  .platform-nav-group > p { display: block; }
  .platform-nav-item { min-height: 38px; margin: 2px 0; padding: 0 10px; white-space: nowrap; }
  .platform-nav-item svg { width: 16px; }
  .platform-nav-item > small { display: inline-block; }
  .platform-user {
    position: absolute;
    top: 14px;
    right: 14px;
    margin: 0;
    padding: 3px;
    background: transparent;
    border: 0;
  }
  .platform-user > span:nth-child(2),
  .platform-user > svg { display: none; }
  .platform-page .platform-topbar { top: 0; }
  .platform-dashboard-hero { grid-template-columns: 1fr; min-height: auto; }
  .platform-capability-card { display: none; }
  .platform-data-flow { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .platform-sidebar.is-menu-open .platform-nav { grid-template-columns: 1fr; }
  .platform-page .platform-topbar {
    height: 60px;
    min-height: 60px;
    padding: 0 13px;
    flex-wrap: nowrap;
  }
  .platform-page .platform-topbar .topbar-right { flex: none; gap: 7px; overflow: visible; padding: 0; }
  .platform-page .platform-topbar .service-state,
  .platform-page .platform-topbar .account-name { display: none; }
  .platform-page-heading span { display: none; }
  .platform-page-heading strong { font-size: 13px; }
  .platform-dashboard { width: calc(100% - 20px); padding-top: 20px; }
  .platform-dashboard-hero { padding: 29px 23px; border-radius: 16px; }
  .platform-dashboard-hero h1 { font-size: 32px; }
  .business-purpose-hero { padding: 23px 20px; border-radius: 15px; }
  .platform-hero-actions { align-items: stretch; flex-direction: column; }
  .platform-hero-actions .button { width: 100%; }
  .platform-section-heading { align-items: flex-start; flex-direction: column; gap: 5px; }
  .platform-module-grid { grid-template-columns: 1fr; }
  .platform-module-card { min-height: 220px; padding: 22px; }
  .platform-module-status { top: 22px; right: 22px; }
  .platform-data-flow { gap: 22px; padding: 24px 21px; }
  .platform-data-flow ol { grid-template-columns: 1fr 1fr; gap: 18px 10px; }
  .platform-data-flow li:not(:last-child)::after { display: none; }
  .supplier-quote-page .platform-topbar .supplier-quote-history-button { display: inline-flex; }
  .auth-capability-list { margin-top: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .platform-page *,
  .platform-page *::before,
  .platform-page *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* WCDI UI/UX baseline v1 — 2026-09-29 */
.platform-nav-direct {
  margin: 2px 10px 12px;
}

.platform-nav-direct + .platform-nav-group,
.platform-nav-group + .platform-nav-direct {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 12px;
}

.platform-dashboard-v3,
.analytics-main {
  width: min(100%, 1680px);
  margin: 0 auto;
  padding: 32px clamp(24px, 3vw, 48px) 48px;
}

.dashboard-page-head,
.analytics-page-head {
  margin-bottom: 24px;
}

.dashboard-page-head h1,
.analytics-page-head h1 {
  font-size: clamp(28px, 2.2vw, 32px);
}

.dashboard-head-actions {
  flex-wrap: wrap;
}

.dashboard-section {
  margin-bottom: 24px;
}

.dashboard-section-heading,
.dashboard-data-card > header,
.analytics-card > header,
.analytics-capability-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}

.dashboard-section-heading h2,
.dashboard-data-card h2,
.analytics-card h2,
.analytics-capability-head h2 {
  margin: 2px 0 0;
  color: #13271f;
  font-size: 21px;
  line-height: 1.25;
}

.dashboard-section-heading > span,
.dashboard-data-card > header > span,
.analytics-card > header > span {
  color: #728078;
  font-size: 13px;
}

.dashboard-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.dashboard-metric-card {
  display: grid;
  min-width: 0;
  min-height: 132px;
  padding: 22px 24px;
  border: 1px solid #dfe9e3;
  border-radius: 14px;
  background: #fff;
  color: #26372f;
  box-shadow: 0 8px 24px rgba(19, 63, 46, 0.05);
  text-decoration: none;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.dashboard-metric-card:hover,
.dashboard-metric-card:focus-visible {
  border-color: #88bca5;
  box-shadow: 0 12px 28px rgba(19, 92, 64, 0.1);
  transform: translateY(-2px);
}

.dashboard-metric-card > span {
  font-size: 14px;
  font-weight: 700;
}

.dashboard-metric-card > strong {
  align-self: center;
  color: #116846;
  font-size: 32px;
  line-height: 1;
}

.dashboard-metric-card > small {
  color: #748179;
  font-size: 12px;
}

.dashboard-entry-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.dashboard-entry-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px;
  min-height: 176px;
  padding: 22px;
  border: 1px solid #dfe9e3;
  border-radius: 14px;
  background: #fff;
}

.dashboard-entry-card.is-sales { border-top: 3px solid #257357; }
.dashboard-entry-card.is-purchase { border-top: 3px solid #b17a24; }
.dashboard-entry-card.is-collaboration { border-top: 3px solid #5477a5; }
.dashboard-entry-card.is-products { border-top: 3px solid #528567; }

.dashboard-entry-card h3 {
  margin: 2px 0 7px;
  color: #172c23;
  font-size: 18px;
}

.dashboard-entry-card small,
.dashboard-entry-card p {
  color: #718078;
}

.dashboard-entry-card p {
  margin: 0;
  font-size: 14px;
  line-height: 1.65;
}

.dashboard-entry-card > .text-button {
  grid-column: 1 / -1;
  align-self: end;
  justify-self: start;
}

.dashboard-content-grid,
.dashboard-bottom-grid,
.analytics-overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}

.dashboard-bottom-grid {
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
}

.dashboard-data-card,
.analytics-card,
.analytics-panel {
  min-width: 0;
  border: 1px solid #dfe9e3;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(19, 63, 46, 0.045);
}

.dashboard-data-card,
.analytics-card {
  padding: 22px 24px;
}

.dashboard-table-wrap,
.supplier-quote-history-table-wrap,
.supplier-quote-detail-table-wrap {
  max-width: 100%;
  overflow-x: auto;
}

.dashboard-table-wrap table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.dashboard-table-wrap th,
.dashboard-table-wrap td {
  height: 48px;
  padding: 10px 12px;
  border-bottom: 1px solid #edf2ef;
  text-align: left;
}

.dashboard-table-wrap th {
  color: #718078;
  font-size: 12px;
  font-weight: 700;
}

.dashboard-table-wrap tbody tr {
  cursor: pointer;
}

.dashboard-table-wrap tbody tr:hover {
  background: #f4f9f6;
}

.dashboard-business-name {
  max-width: 240px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dashboard-number-cell {
  font-variant-numeric: tabular-nums;
  text-align: right !important;
}

.dashboard-empty,
.analytics-empty {
  display: grid;
  min-height: 120px;
  place-items: center;
  color: #7a8780;
  font-size: 14px;
  text-align: center;
}

.dashboard-notification-empty {
  min-height: 148px;
}

.dashboard-todo-list {
  display: grid;
}

.dashboard-todo-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 64px;
  padding: 12px 4px;
  border-bottom: 1px solid #edf2ef;
  color: #20372d;
  text-decoration: none;
}

.dashboard-todo-item:hover strong {
  color: #087449;
}

.dashboard-todo-item span {
  display: grid;
  gap: 5px;
}

.dashboard-todo-item small,
.dashboard-todo-item time {
  color: #79857f;
  font-size: 12px;
}

/* Supplier quotation business-line workspace */
.supplier-quote-line-filters {
  display: grid;
  grid-template-columns: minmax(130px, .8fr) minmax(220px, 1.35fr) minmax(150px, 1fr) minmax(310px, 1.4fr) minmax(130px, .8fr) auto;
  gap: 14px;
  align-items: end;
  margin: 0 0 20px;
  padding: 18px;
  border-radius: 12px;
  background: #f6faf7;
}

.supplier-quote-line-filters > label {
  display: grid;
  min-width: 0;
  gap: 7px;
}

.supplier-quote-line-filters > label > span:first-child {
  color: #31483e;
  font-size: 13px;
  font-weight: 700;
}

.supplier-quote-line-filters input,
.supplier-quote-line-filters select {
  width: 100%;
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  border: 1px solid #cbd9d1;
  border-radius: 8px;
  background: #fff;
  color: #20342b;
  font: inherit;
  font-size: 14px;
}

.supplier-quote-date-range {
  display: grid;
  grid-template-columns: minmax(125px, 1fr) auto minmax(125px, 1fr);
  align-items: center;
  gap: 7px;
}

.supplier-quote-date-range i {
  color: #7b8781;
  font-size: 12px;
  font-style: normal;
}

.supplier-quote-filter-actions {
  display: flex;
  gap: 8px;
}

.supplier-quote-history-table {
  min-width: 1120px;
  font-size: 13px;
}

.supplier-quote-history-table th,
.supplier-quote-history-table td {
  height: 50px;
}

.supplier-quote-history-product,
.supplier-quote-history-price {
  display: table-cell;
}

.supplier-quote-history-product strong,
.supplier-quote-history-price strong {
  display: block;
  color: #233b30;
  font-size: 13px;
}

.supplier-quote-history-product small,
.supplier-quote-history-price small {
  display: block;
  max-width: 330px;
  margin-top: 4px;
  overflow: hidden;
  color: #77837d;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-quote-history-action .text-button {
  border: 0;
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
}

.supplier-quote-detail-dialog {
  width: min(1040px, calc(100vw - 40px));
  max-height: calc(100vh - 56px);
  padding: 0;
  border: 0;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 24px 70px rgba(12, 43, 31, 0.24);
}

.supplier-quote-detail-dialog::backdrop,
.analytics-assistant-dialog::backdrop {
  background: rgba(9, 31, 23, 0.5);
}

.supplier-quote-detail-shell {
  display: grid;
  max-height: calc(100vh - 56px);
  padding: 26px;
  overflow: auto;
}

.supplier-quote-detail-shell > header,
.supplier-quote-detail-shell > footer {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.supplier-quote-detail-shell h2 {
  margin: 3px 0 5px;
  font-size: 24px;
}

.supplier-quote-detail-shell header p:last-child {
  margin: 0;
  color: #718078;
}

.supplier-quote-detail-meta {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin: 22px 0;
}

.supplier-quote-detail-meta > div {
  min-width: 0;
  padding: 13px;
  border-radius: 10px;
  background: #f4f8f5;
}

.supplier-quote-detail-meta dt {
  color: #77847d;
  font-size: 12px;
}

.supplier-quote-detail-meta dd {
  margin: 5px 0 0;
  overflow: hidden;
  color: #20372d;
  font-size: 14px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-quote-detail-table-wrap table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  font-size: 13px;
}

.supplier-quote-detail-table-wrap th,
.supplier-quote-detail-table-wrap td {
  padding: 12px;
  border-bottom: 1px solid #e8efeb;
  text-align: left;
}

.supplier-quote-detail-shell > footer {
  align-items: center;
  margin-top: 22px;
}

/* Data analysis center */
.analytics-page-head {
  align-items: flex-end;
}

.analytics-tabs {
  display: flex;
  gap: 4px;
  margin: 0 0 20px;
  padding: 5px;
  border: 1px solid #dce7e1;
  border-radius: 12px;
  background: #edf5f0;
}

.analytics-tabs button {
  min-width: 132px;
  height: 42px;
  padding: 0 20px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #567066;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.analytics-tabs button[aria-selected="true"] {
  background: #fff;
  color: #0c6945;
  box-shadow: 0 2px 10px rgba(21, 80, 57, 0.09);
}

.analytics-panel {
  padding: 22px;
}

.analytics-range-bar {
  display: grid;
  grid-template-columns: minmax(170px, 1fr) auto minmax(145px, auto) auto minmax(145px, auto) auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 20px;
}

.analytics-range-bar > div:first-child {
  display: grid;
  align-self: center;
}

.analytics-range-bar > div:first-child strong {
  font-size: 18px;
}

.analytics-range-bar > div:first-child span,
.analytics-range-bar label span {
  color: #78867f;
  font-size: 12px;
}

.analytics-range-bar label {
  display: grid;
  gap: 6px;
}

.analytics-range-bar input,
.analytics-builder select {
  height: 40px;
  padding: 0 10px;
  border: 1px solid #cbd9d1;
  border-radius: 8px;
  background: #fff;
  color: #20342b;
  font: inherit;
}

.analytics-range-presets {
  display: flex;
  align-self: center;
  gap: 3px;
  padding: 3px;
  border-radius: 8px;
  background: #edf4f0;
}

.analytics-range-presets button {
  height: 32px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #61756b;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}

.analytics-range-presets button.is-active {
  background: #fff;
  color: #0c6945;
  font-weight: 700;
}

.analytics-kpi-grid {
  display: grid;
  grid-template-columns: repeat(9, minmax(112px, 1fr));
  gap: 10px;
  margin-bottom: 20px;
}

.analytics-kpi-card {
  display: grid;
  min-width: 0;
  min-height: 122px;
  padding: 16px;
  border: 1px solid #dfe9e3;
  border-radius: 11px;
  background: #fbfdfb;
}

.analytics-kpi-card span {
  color: #526b60;
  font-size: 13px;
  font-weight: 700;
}

.analytics-kpi-card strong {
  align-self: center;
  color: #126d49;
  font-size: 24px;
  line-height: 1.15;
}

.analytics-kpi-card small {
  color: #7b8781;
  font-size: 11px;
  line-height: 1.35;
}

.analytics-kpi-card.is-unavailable {
  background: #f7f8f7;
}

.analytics-kpi-card.is-unavailable strong {
  color: #87918c;
  font-size: 15px;
}

.analytics-overview-grid {
  grid-template-columns: minmax(0, 1.55fr) minmax(320px, .75fr);
}

.analytics-chart {
  min-height: 260px;
  max-width: 100%;
  overflow-x: auto;
}

.analytics-chart-legend {
  display: flex;
  justify-content: flex-end;
  gap: 16px;
  min-height: 24px;
  color: #62746b;
  font-size: 12px;
}

.analytics-chart-legend span::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 6px;
  border-radius: 2px;
}

.analytics-chart-legend .is-demand::before { background: #26795a; }
.analytics-chart-legend .is-quote::before { background: #c8913a; }

.analytics-chart-bars {
  display: flex;
  align-items: stretch;
  gap: 10px;
  height: 220px;
  padding-top: 16px;
  border-bottom: 1px solid #dbe5df;
  width: max-content;
  min-width: 100%;
}

.analytics-chart-group {
  display: grid;
  flex: 0 0 38px;
  min-width: 38px;
  grid-template-rows: 1fr 24px;
  gap: 5px;
}

.analytics-chart-columns {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 3px;
  min-height: 0;
}

.analytics-chart-columns i {
  width: min(16px, 40%);
  min-height: 0;
  border-radius: 4px 4px 0 0;
}

.analytics-chart-columns .is-demand { background: #26795a; }
.analytics-chart-columns .is-quote { background: #c8913a; }
.analytics-chart-group small {
  overflow: hidden;
  color: #77837d;
  font-size: 10px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analytics-ranking {
  display: grid;
  gap: 12px;
}

.analytics-ranking-row {
  display: grid;
  grid-template-columns: minmax(110px, .8fr) minmax(100px, 1fr) 48px;
  align-items: center;
  gap: 12px;
}

.analytics-ranking-label {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 9px;
}

.analytics-ranking-label span {
  color: #90a099;
  font-size: 11px;
}

.analytics-ranking-label strong {
  overflow: hidden;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analytics-ranking-meter {
  height: 7px;
  border-radius: 99px;
  background: #eaf1ed;
  overflow: hidden;
}

.analytics-ranking-meter i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #2c8060;
}

.analytics-ranking-row > b {
  color: #344b40;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.analytics-ranking.is-wide {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 40px;
}

.analytics-contribution-card {
  margin-top: 20px;
}

.analytics-capability-head {
  align-items: flex-start;
  margin-bottom: 24px;
}

.analytics-capability-head p {
  max-width: 760px;
  margin: 7px 0 0;
  color: #6e7d75;
  line-height: 1.65;
}

.analytics-status-tag {
  padding: 7px 10px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 700;
}

.analytics-status-tag.is-limited {
  background: #fff3dc;
  color: #8c5a10;
}

.analytics-builder {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 14px;
  padding: 20px;
  border-radius: 12px;
  background: #f5f9f6;
}

.analytics-builder label {
  display: grid;
  gap: 7px;
  color: #41594e;
  font-size: 13px;
  font-weight: 700;
}

.analytics-dependency-note {
  margin-top: 20px;
  padding: 18px;
  border: 1px solid #ead8b7;
  border-radius: 11px;
  background: #fffbf3;
}

.analytics-dependency-note p {
  margin: 6px 0 0;
  color: #745f3c;
  line-height: 1.65;
}

.analytics-topic-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.analytics-topic-grid article {
  min-height: 180px;
  padding: 20px;
  border: 1px solid #dfe9e3;
  border-radius: 12px;
  background: #fbfdfc;
}

.analytics-topic-grid article > span {
  color: #8cab9d;
  font-size: 12px;
  font-weight: 800;
}

.analytics-topic-grid h3 {
  margin: 16px 0 8px;
  color: #1e392d;
  font-size: 18px;
}

.analytics-topic-grid p {
  min-height: 64px;
  margin: 0 0 16px;
  color: #6b7a72;
  font-size: 14px;
  line-height: 1.6;
}

.analytics-topic-grid small {
  color: #9a6b22;
  font-size: 12px;
  font-weight: 700;
}

.analytics-assistant-dialog {
  width: min(520px, calc(100vw - 32px));
  padding: 0;
  border: 0;
  border-radius: 16px;
  box-shadow: 0 24px 70px rgba(12, 43, 31, 0.24);
}

.analytics-assistant-dialog form {
  padding: 28px;
}

.analytics-assistant-dialog h2 {
  margin: 8px 0;
  font-size: 24px;
}

.analytics-assistant-dialog p:not(.eyebrow) {
  color: #68776f;
  line-height: 1.7;
}

@media (max-width: 1500px) {
  .supplier-quote-line-filters {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .supplier-quote-filter-actions {
    justify-content: flex-end;
  }
  .analytics-range-bar {
    grid-template-columns: minmax(160px, 1fr) auto minmax(145px, auto) auto minmax(145px, auto) auto;
  }
  .analytics-range-presets {
    grid-column: 1 / -1;
    justify-self: start;
    grid-row: 2;
  }
  .analytics-kpi-grid {
    grid-template-columns: repeat(5, minmax(120px, 1fr));
  }
}

@media (max-width: 1180px) {
  .dashboard-metric-grid,
  .dashboard-entry-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .dashboard-content-grid,
  .dashboard-bottom-grid,
  .analytics-overview-grid {
    grid-template-columns: 1fr;
  }
  .analytics-range-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .analytics-range-bar > div:first-child,
  .analytics-range-presets {
    grid-column: 1 / -1;
    grid-row: auto;
  }
  .analytics-kpi-grid {
    grid-template-columns: repeat(3, minmax(120px, 1fr));
  }
  .analytics-builder,
  .analytics-topic-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .platform-dashboard-v3,
  .analytics-main {
    padding: 22px 16px 36px;
  }
  .dashboard-metric-grid,
  .dashboard-entry-grid,
  .supplier-quote-line-filters,
  .analytics-kpi-grid,
  .analytics-builder,
  .analytics-topic-grid,
  .analytics-ranking.is-wide {
    grid-template-columns: 1fr;
  }
  .dashboard-entry-card {
    min-height: 0;
  }
  .analytics-tabs {
    overflow-x: auto;
  }
  .analytics-tabs button {
    min-width: 118px;
  }
  .analytics-range-bar {
    grid-template-columns: 1fr;
  }
  .analytics-range-bar > div:first-child,
  .analytics-range-presets {
    grid-column: 1;
  }
  .analytics-range-presets {
    max-width: 100%;
    overflow-x: auto;
  }
  .supplier-quote-detail-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.dashboard-table-wrap tbody tr:focus-visible {
  outline: 2px solid #21815e;
  outline-offset: -2px;
  background: #f0f8f3;
}

/* Keep sales data readable on desktop; wide tables scroll inside their panel. */
@media (min-width: 901px) {
  .history-table-wrap {
    overflow-x: auto;
  }
  .history-table {
    min-width: 1480px;
  }
  .history-table th {
    padding: 12px 9px;
    font-size: 13px;
  }
  .history-table td,
  .history-number,
  .history-price b,
  .history-customer-code a {
    font-size: 13px !important;
  }
  .history-barcode {
    font-size: 12px !important;
  }
  .history-price small {
    font-size: 11px;
  }
}

/* Sales demand import: compact, file-first workspace. */
.sales-demand-page .sales-import-head {
  min-height: 136px;
  padding: 22px 28px;
}

.sales-demand-page .sales-import-head .hero-navigation.is-home {
  min-width: 0;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.sales-demand-page .sales-import-head .hero-navigation.is-home .hero-navigation-heading,
.sales-demand-page .sales-import-head .hero-navigation.is-home > small {
  display: none;
}

.sales-demand-page .sales-import-head .hero-navigation.is-home .hero-navigation-actions {
  justify-content: flex-end;
}

.sales-demand-page .workflow {
  min-height: 68px;
  padding: 13px 24px;
}

.sales-demand-page #uploadView > .panel-heading {
  padding: 18px 24px;
}

.sales-demand-page #uploadForm {
  padding: 22px 24px 18px;
}

.sales-demand-page .upload-layout {
  grid-template-columns: minmax(0, 3fr) minmax(360px, 2fr);
  gap: 20px;
}

.sales-demand-page .dropzone {
  min-height: 252px;
  padding: 24px;
}

.upload-icon-check { display: none; }
.dropzone.has-file .upload-icon-arrow { display: none; }
.dropzone.has-file .upload-icon-check { display: block; }
.dropzone.has-file .upload-icon {
  color: #fff;
  background: var(--green);
}

.sales-demand-page .selected-file {
  max-width: min(560px, 100%);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sales-demand-page .upload-metadata {
  padding: 16px 18px;
}

.sales-demand-page .upload-metadata-heading { margin-bottom: 12px; }
.sales-demand-page .form-grid-metadata { gap: 10px 12px; }
.sales-demand-page .form-grid-metadata .field small { min-height: 0; }
.field-span-all { grid-column: 1 / -1; }

.sales-demand-page .customer-type-preview.field-span-all {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 42px;
  padding: 9px 11px;
}

.sales-demand-page .customer-type-preview.field-span-all strong { margin-top: 0; }

.upload-more-fields {
  margin-top: 10px;
  border-top: 1px solid #dce6e0;
}

.upload-more-fields summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 2px 2px;
  color: #446053;
  font-size: 11px;
  font-weight: 750;
  cursor: pointer;
}

.upload-more-fields summary small {
  color: #87918c;
  font-size: 9px;
  font-weight: 500;
}

.upload-more-fields .field { padding-top: 10px; }
.upload-more-fields .field > span { margin-bottom: 6px; font-size: 11px; }
.upload-more-fields .field input { height: 42px; font-size: 12px; }
.upload-more-fields .field small { margin-top: 5px; font-size: 10px; }

.sales-demand-page .form-actions {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--soft-line);
}

.form-action-buttons { display: flex; align-items: center; gap: 9px; }
.form-action-buttons .button-primary { min-width: 132px; }

.sales-demand-page .upload-resume {
  display: block;
  container-type: inline-size;
  margin-top: 16px;
  padding: 0;
  overflow: hidden;
  background: #fff;
  border-radius: 12px;
}

.sales-demand-page .upload-resume-copy {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--soft-line);
}

.sales-demand-page .upload-resume-actions > a {
  color: var(--green);
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.sales-demand-page .upload-resume-actions > a span { display: inline; }

.sales-demand-page .upload-resume-description { margin: 5px 0 0; color: #7b8981; font-size: 11px; line-height: 1.5; }
.sales-demand-page .upload-resume-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.sales-demand-page .upload-resume-actions .text-button { font-size: 11px; }
.sales-demand-page .upload-resume-message { margin: 0; padding: 22px 18px; color: #7b8981; font-size: 12px; text-align: center; }
.sales-demand-page .upload-resume-message.is-error { color: #986129; background: #fffaf2; }

.upload-resume-table-head,
.sales-demand-page .upload-task-link {
  display: grid;
  grid-template-columns: minmax(280px, 1.7fr) minmax(110px, .62fr) minmax(145px, .72fr) 92px 56px;
  gap: 12px;
  align-items: center;
}

.upload-resume-table-head {
  min-height: 34px;
  padding: 0 18px;
  color: #839089;
  background: #f6f9f7;
  font-size: 10px;
  font-weight: 750;
}

.sales-demand-page .upload-resume-list {
  display: block;
}

.sales-demand-page .upload-task-link {
  min-height: 46px;
  padding: 7px 18px;
  color: #3d4a44;
  background: #fff;
  border: 0;
  border-bottom: 1px solid #edf1ef;
  border-radius: 0;
  box-shadow: none;
}

.sales-demand-page .upload-task-link:last-child { border-bottom: 0; }
.sales-demand-page .upload-task-link:hover { background: #f5faf7; box-shadow: none; transform: none; }
.sales-demand-page .upload-task-link.is-current { background: #f0f7f3; box-shadow: inset 3px 0 var(--green); }
.sales-demand-page .upload-task-link:focus-visible { outline: 2px solid var(--green); outline-offset: -2px; }
.sales-demand-page .upload-task-file,
.sales-demand-page .upload-task-uploader,
.sales-demand-page .upload-task-time {
  min-width: 0;
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sales-demand-page .upload-task-file b { font-size: 11px; }
.sales-demand-page .upload-task-time { color: #6f7c75; font-style: normal; }
.sales-demand-page .upload-task-status em { padding: 4px 7px; font-size: 9px; font-style: normal; }
.sales-demand-page .upload-task-action { color: var(--green); font-size: 11px; text-align: right; }

@media (max-width: 1180px) {
  .sales-demand-page .upload-layout { grid-template-columns: 1fr; }
  .sales-demand-page .dropzone { min-height: 210px; }
}

@media (max-width: 760px) {
  .sales-demand-page .sales-import-head { min-height: 0; padding: 20px; }
  .sales-demand-page .sales-import-head .hero-navigation.is-home .hero-navigation-actions,
  .form-action-buttons { width: 100%; }
  .form-action-buttons { display: grid; grid-template-columns: 1fr 1fr; }
  .upload-resume-table-head { display: none; }
  .sales-demand-page .upload-resume-copy { flex-wrap: wrap; gap: 10px; }
  .sales-demand-page .upload-resume-title { flex-wrap: wrap; }
  .sales-demand-page .upload-task-link {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 5px 12px;
    padding: 12px 16px;
  }
  .sales-demand-page .upload-task-file { grid-column: 1 / -1; }
  .sales-demand-page .upload-task-time { grid-column: 1; }
  .sales-demand-page .upload-task-status { grid-column: 2; grid-row: 2; }
  .sales-demand-page .upload-task-uploader { grid-column: 1; }
  .sales-demand-page .upload-task-action { grid-column: 2; grid-row: 3; }
}
@container (max-width: 760px) {
  .upload-resume-table-head { display: none; }
  .sales-demand-page .upload-resume-copy { flex-wrap: wrap; gap: 10px; }
  .sales-demand-page .upload-resume-title { flex-wrap: wrap; }
  .sales-demand-page .upload-task-link { grid-template-columns: minmax(0, 1fr) auto; gap: 5px 12px; padding: 12px 16px; }
  .sales-demand-page .upload-task-file { grid-column: 1 / -1; }
  .sales-demand-page .upload-task-time { grid-column: 1; }
  .sales-demand-page .upload-task-status { grid-column: 2; grid-row: 2; }
  .sales-demand-page .upload-task-uploader { grid-column: 1; }
  .sales-demand-page .upload-task-action { grid-column: 2; grid-row: 3; }
}
.business-identity-filter { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; padding: 10px 14px; color: #355449; background: #eef7f2; border: 1px solid #cfe2d7; border-radius: 8px; font-size: 13px; }
.business-identity-filter span { color: #6b7c74; }
.business-identity-filter strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.business-identity-filter a { margin-left: auto; color: var(--green); font-weight: 700; text-decoration: none; }
.business-identity-filter a:hover, .business-identity-filter a:focus-visible { text-decoration: underline; }
.history-filter-chip.is-locked { cursor: default; }
