:root {
  --app-height: 100dvh;
  color-scheme: dark;
  --ink: #071b38;
  --ink-2: #0d2a50;
  --coral: #e85f47;
  --teal: #139c8c;
  --cream: #f3e8d2;
  --white: #ffffff;
  --muted: #aebed1;
  --line: rgba(243, 232, 210, 0.2);
  --line-strong: rgba(243, 232, 210, 0.42);
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.24);
  font-family: "PingFang TC", "Microsoft JhengHei", "Noto Sans TC", "Segoe UI", Arial, sans-serif;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  min-height: 0;
  margin: 0;
  background: var(--ink);
  color: var(--cream);
  overflow: hidden;
}

body {
  height: var(--app-height);
  min-height: 0;
  overscroll-behavior: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
  touch-action: manipulation;
}

button:focus-visible {
  outline: 3px solid var(--cream);
  outline-offset: 3px;
}

img {
  display: block;
  -webkit-user-drag: none;
}

.app-shell,
.showcase {
  height: var(--app-height);
  min-height: 0;
}

.boot-screen {
  height: var(--app-height);
  min-height: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 22px;
}

.boot-screen p {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  margin: 0;
  font-size: 26px;
}

.boot-screen p span[lang="en"] {
  color: var(--muted);
  font-size: 18px;
}

.showcase {
  position: relative;
  display: grid;
  grid-template-rows: calc(74px + env(safe-area-inset-top)) minmax(0, 1fr) calc(46px + env(safe-area-inset-bottom));
  background: var(--ink);
  isolation: isolate;
  --showcase-accent: var(--coral);
  --showcase-glow: rgba(232, 95, 71, 0.18);
}

.showcase--manufacturing {
  --showcase-accent: var(--coral);
  --showcase-glow: rgba(232, 95, 71, 0.2);
}

.showcase--garment {
  --showcase-accent: var(--teal);
  --showcase-glow: rgba(19, 156, 140, 0.2);
}

.showcase--trading {
  --showcase-accent: var(--cream);
  --showcase-glow: rgba(243, 232, 210, 0.16);
}

.topbar {
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(300px, 1fr) auto minmax(300px, 1fr) 54px;
  align-items: center;
  gap: 22px;
  padding: calc(10px + env(safe-area-inset-top)) max(3vw, 24px) 10px;
  border-bottom: 1px solid var(--line);
  background: var(--ink);
}

.case-badge {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.case-badge::before {
  content: "";
  width: 5px;
  height: 38px;
  flex: 0 0 5px;
  background: var(--showcase-accent);
  box-shadow: 0 0 18px var(--showcase-glow);
}

.case-badge__index {
  min-width: 46px;
  color: var(--coral);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.bi {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.16;
}

.bi > span[lang="en"] {
  margin-top: 0.22em;
  color: currentColor;
  font-size: 0.62em;
  font-weight: 550;
  letter-spacing: 0.01em;
  opacity: 0.74;
}

.bi--case {
  min-width: 0;
  font-size: clamp(18px, 1.45vw, 25px);
  font-weight: 750;
  white-space: nowrap;
}

.bi--case > span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.case-progress {
  display: flex;
  align-items: center;
  gap: 8px;
}

.case-progress span {
  width: 38px;
  height: 4px;
  background: var(--line-strong);
}

.case-progress span.is-active {
  background: var(--showcase-accent);
  box-shadow: 0 0 12px var(--showcase-glow);
}

.top-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
}

.fullscreen-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  background: rgba(243, 232, 210, 0.06);
  color: var(--cream);
  cursor: pointer;
  white-space: nowrap;
}

.fullscreen-button:active {
  transform: translateY(1px);
}

.fullscreen-button__icon {
  font-size: 19px;
  line-height: 1;
}

.bi--fullscreen {
  font-size: 12px;
  font-weight: 800;
}

.bi--fullscreen > span[lang="en"] {
  font-size: 9px;
}

@media (display-mode: standalone), (display-mode: fullscreen) {
  .fullscreen-button { display: none; }
}

.auto-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.auto-badge > span:first-child {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 4px rgba(19, 156, 140, 0.14), 0 0 14px rgba(19, 156, 140, 0.65);
  animation: live-pulse 1.8s ease-in-out infinite;
}

.bi--auto {
  flex-direction: row;
  align-items: center;
  gap: 5px;
}

.bi--auto > span[lang="en"] {
  margin: 0;
  font-size: inherit;
  opacity: 0.65;
}

.brand-trigger {
  width: 50px;
  height: 50px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.brand-trigger img {
  width: 48px;
  height: 48px;
  border: 1px solid var(--line);
  border-radius: 12px;
}

.button {
  min-height: 64px;
  padding: 10px 20px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: var(--cream);
  color: var(--ink);
  cursor: pointer;
  font-weight: 800;
  transition: transform 140ms ease, background-color 140ms ease, border-color 140ms ease;
}

.button:active {
  transform: translateY(1px);
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.button--primary {
  background: var(--coral);
  color: var(--white);
}

.button--outline {
  border-color: var(--line-strong);
  background: transparent;
  color: var(--cream);
}

.button--ghost {
  border-color: transparent;
  background: transparent;
  color: var(--cream);
}

.button--compact {
  min-height: 50px;
  padding: 7px 15px;
  font-size: 18px;
}

.top-actions .button--compact {
  min-height: 42px;
  padding: 5px 11px;
  font-size: 14px;
}

.top-actions .bi--button {
  font-size: 14px;
}

.top-actions .bi--button > span[lang="en"] {
  min-height: 0;
  font-size: 10px;
}

.bi--button {
  align-items: center;
  width: 100%;
  font-size: 18px;
}

.bi--button > span[lang="en"] {
  min-height: 18px;
  font-size: 18px;
}

.mode-pill {
  padding: 7px 14px;
  border-left: 4px solid var(--teal);
  background: rgba(19, 156, 140, 0.14);
  color: var(--cream);
  font-size: 18px;
  font-weight: 700;
}

.stage {
  position: relative;
  min-height: 0;
  overflow: hidden;
  padding: clamp(22px, 3vw, 48px) max(5vw, 48px);
  touch-action: pan-y;
}

.stage::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 78% 42%, var(--showcase-glow), transparent 34%),
    linear-gradient(rgba(243, 232, 210, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(243, 232, 210, 0.025) 1px, transparent 1px);
  background-size: auto, 42px 42px, 42px 42px;
  mask-image: linear-gradient(to bottom, transparent, black 14%, black 86%, transparent);
}

.showcase--interactive .stage {
  padding-right: min(35vw, 470px);
}

.scene {
  position: relative;
  z-index: 1;
  width: min(100%, 1540px);
  height: 100%;
  min-height: 0;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(280px, 0.72fr) minmax(480px, 1.28fr);
  align-items: center;
  gap: clamp(28px, 4vw, 78px);
  animation: scene-enter 520ms ease both;
}

.scene__copy {
  position: relative;
  z-index: 2;
}

.scene__context {
  display: grid;
  gap: 12px;
  margin-bottom: 22px;
  animation: scene-copy-in 650ms 80ms ease both;
}

.scene__step {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
}

.scene__step > span:first-child {
  min-width: 48px;
  padding: 5px 8px;
  border: 1px solid var(--line-strong);
  color: var(--showcase-accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-align: center;
}

.bi--phase {
  font-size: 15px;
  font-weight: 800;
}

.bi--phase > span[lang="en"] {
  font-size: 10px;
}

.scene__question {
  padding: 10px 13px;
  border: 1px solid color-mix(in srgb, var(--showcase-accent) 32%, transparent);
  border-left: 4px solid var(--showcase-accent);
  background: color-mix(in srgb, var(--showcase-accent) 9%, transparent);
  box-shadow: 0 10px 30px color-mix(in srgb, var(--showcase-glow) 45%, transparent);
}

.bi--context-label {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.bi--context-label > span[lang="en"] {
  font-size: 9px;
}

.scene__question .bi--context-value {
  display: flex;
  flex-direction: column;
  margin-top: 5px;
  color: var(--cream);
  font-size: 17px;
  font-weight: 800;
}

.scene__question .bi--context-value > span[lang="en"] {
  font-size: 11px;
}

.scene__copy::before {
  content: "";
  display: block;
  width: 62px;
  height: 7px;
  margin-bottom: 22px;
  background: var(--coral);
}

.scene--garment .scene__copy::before {
  background: var(--teal);
}

.scene--trading .scene__copy::before {
  background: var(--cream);
}

.scene__copy h1,
.scene__copy p {
  margin: 0;
}

.bi--hero {
  font-size: clamp(39px, 4.4vw, 72px);
  font-weight: 850;
  letter-spacing: -0.045em;
}

.bi--hero > span[lang="en"] {
  max-width: 18ch;
  font-size: clamp(22px, 0.48em, 34px);
  letter-spacing: -0.025em;
}

.bi--message {
  max-width: 26ch;
  margin-top: 24px;
  color: var(--muted);
  font-size: clamp(22px, 2vw, 32px);
  font-weight: 650;
}

.bi--message > span[lang="en"] {
  max-width: 32ch;
  font-size: clamp(18px, 0.68em, 23px);
}

.scene__flow {
  display: grid;
  gap: 7px;
  margin-top: 28px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
  animation: scene-copy-in 650ms 180ms ease both;
}

.scene__flow-track {
  display: flex;
  align-items: stretch;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 2px;
}

.scene__flow-node {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 3px;
  padding: 7px 9px;
  border: 1px solid var(--line-strong);
  background: rgba(13, 42, 80, 0.76);
  color: var(--cream);
  font-size: 11px;
  font-weight: 850;
  line-height: 1.1;
}

.scene__flow-node small {
  color: var(--muted);
  font-size: 8px;
  font-weight: 600;
}

.scene__flow-track > i {
  align-self: center;
  color: var(--showcase-accent);
  font-size: 17px;
  font-style: normal;
  font-weight: 900;
}

.scene__visual {
  min-width: 0;
  max-height: 100%;
  filter: drop-shadow(0 18px 38px rgba(0, 0, 0, 0.16));
  animation: scene-visual-in 760ms 100ms cubic-bezier(0.2, 0.75, 0.25, 1) both;
}

.scene-progress {
  z-index: 12;
  display: grid;
  grid-template-columns: 1fr auto 34px;
  align-items: center;
  column-gap: 12px;
  row-gap: 3px;
  padding: 5px max(5vw, 48px) max(6px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: var(--ink);
}

.scene-dots {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 7px;
}

.scene-dots span {
  height: 3px;
  background: var(--line);
}

.scene-dots span.is-complete {
  background: var(--teal);
}

.scene-dots span.is-active {
  background: var(--cream);
}

.scene-counter {
  display: flex;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}

.scene-counter span[lang="en"]::before {
  content: "·";
  margin-right: 8px;
}

.showcase-playback {
  width: 30px;
  height: 30px;
  display: grid;
  place-content: center;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: transparent;
  color: var(--cream);
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
}

.showcase-playback:active {
  background: rgba(243, 232, 210, 0.12);
}

.visually-hidden {
  width: 1px !important;
  height: 1px !important;
  position: absolute !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
}

.scene-timer {
  grid-column: 1 / -1;
  height: 2px;
  overflow: hidden;
  background: transparent;
}

.scene-timer span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--coral);
}

.scene-timer.is-running span {
  animation: scene-time var(--scene-duration) linear forwards;
}

.paper-card,
.incoming-document,
.style-card,
.purchase-list,
.work-order,
.result-card,
.ai-panel,
.action-list,
.recovery-card,
.variant-stage,
.material-list,
.forecast-stage,
.replenishment-stage {
  border: 1px solid var(--line-strong);
  background: var(--ink-2);
  box-shadow: var(--shadow);
}

.split-stage {
  display: grid;
  grid-template-columns: minmax(220px, 0.9fr) 90px minmax(290px, 1.1fr);
  align-items: center;
  gap: 15px;
}

.incoming-document,
.paper-card,
.style-card {
  min-height: 350px;
  padding: 24px;
}

.incoming-document {
  transform: rotate(-2deg);
  background: var(--cream);
  color: var(--ink);
}

.document-type {
  display: inline-block;
  margin-bottom: 24px;
  padding: 4px 9px;
  background: var(--coral);
  color: var(--white);
  font-weight: 800;
}

.mapping-arrow {
  display: grid;
  justify-items: center;
  gap: 8px;
  color: var(--muted);
  text-align: center;
  font-size: 16px;
}

.mapping-arrow > span {
  color: var(--coral);
  font-size: 50px;
}

.paper-card__head {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  margin: -24px -24px 18px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-weight: 750;
}

.data-row {
  display: grid;
  grid-template-columns: minmax(140px, 0.8fr) minmax(0, 1.2fr);
  align-items: center;
  gap: 18px;
  min-height: 56px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
}

.data-row:last-child {
  border-bottom: 0;
}

.data-row > strong {
  justify-self: end;
  text-align: right;
  font-size: clamp(19px, 1.8vw, 28px);
}

.data-row > strong small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 15px;
}

.data-row--warning > strong {
  color: var(--coral);
}

.bi--label {
  color: var(--muted);
  font-size: 18px;
  font-weight: 650;
}

.bi--label > span[lang="en"] {
  font-size: 16px;
}

.product-blueprint,
.garment-intro,
.trade-flow {
  min-height: 410px;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 25px;
  border-block: 1px solid var(--line-strong);
  position: relative;
}

.blueprint-part--one {
  width: 180px;
  height: 180px;
  display: grid;
  place-content: center;
  border: 5px solid var(--cream);
  border-radius: 50%;
  color: var(--cream);
  font-size: 38px;
  font-weight: 900;
}

.blueprint-line {
  width: min(74%, 480px);
  height: 2px;
  background: var(--line-strong);
}

.blueprint-parts {
  display: flex;
  gap: 15px;
}

.blueprint-parts > span {
  min-width: 140px;
  padding: 14px;
  border: 1px solid var(--line-strong);
  text-align: center;
}

.intro-stat {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  background: var(--cream);
  color: var(--ink);
}

.intro-stat strong {
  color: var(--coral);
  font-size: 34px;
}

.bom-layout {
  display: grid;
  grid-template-columns: 1fr 180px;
  gap: 24px;
}

.bom-tree {
  display: grid;
  align-content: center;
  gap: 44px;
  min-height: 410px;
  padding: 28px;
  border: 1px solid var(--line-strong);
}

.bom-root,
.bom-level {
  display: flex;
  justify-content: center;
  gap: 13px;
  position: relative;
}

.bom-root::after,
.bom-level:not(.bom-level--leaf)::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -44px;
  width: 1px;
  height: 44px;
  background: var(--line-strong);
}

.bom-root span,
.bom-level > span {
  padding: 13px 16px;
  border: 1px solid var(--line-strong);
  background: var(--ink-2);
  text-align: center;
  font-weight: 700;
}

.bom-root span {
  border-color: var(--cream);
  color: var(--cream);
}

.bom-level--leaf > span:first-child,
.bom-level--leaf > span:nth-child(2) {
  border-color: var(--coral);
}

.scene.bom-explainer {
  grid-template-columns: minmax(270px, 0.55fr) minmax(590px, 1.45fr);
  gap: clamp(26px, 3vw, 55px);
}

.scene.mfg-plain-language {
  grid-template-columns: minmax(300px, 0.68fr) minmax(560px, 1.32fr);
}

.scene.mfg-plain-language .bi--hero {
  font-size: clamp(38px, 3.5vw, 56px);
}

.mfg-product-story {
  min-height: 460px;
  display: grid;
  align-content: center;
  gap: 13px;
}

.mfg-product-card {
  min-height: 245px;
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  align-items: center;
  gap: 22px;
  padding: 22px;
  border: 1px solid var(--line-strong);
  background: var(--ink-2);
  box-shadow: var(--shadow);
}

.mfg-product-card__visual {
  width: 190px;
  height: 175px;
  display: grid;
  place-content: center;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(rgba(243, 232, 210, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(243, 232, 210, 0.06) 1px, transparent 1px),
    #0b2448;
  background-size: 18px 18px;
}

.mfg-product-card__visual::before,
.mfg-product-card__visual::after {
  content: "";
  position: absolute;
  top: 50%;
  height: 2px;
  background: var(--teal);
  transform: translateY(-50%);
}

.mfg-product-card__visual::before { left: 13px; width: 45px; }
.mfg-product-card__visual::after { right: 13px; width: 45px; }

.mfg-product-card__visual > span {
  position: absolute;
  border: 10px dotted var(--cream);
  border-radius: 50%;
  box-shadow: inset 0 0 0 4px var(--ink-2);
  animation: module-gear-spin 8s linear infinite;
}

.mfg-product-card__visual > span:first-child {
  top: 31px;
  left: 33px;
  width: 87px;
  height: 87px;
}

.mfg-product-card__visual > span:nth-child(2) {
  right: 29px;
  bottom: 28px;
  width: 62px;
  height: 62px;
  border-width: 8px;
  animation-direction: reverse;
}

.mfg-product-card__visual > i {
  z-index: 2;
  position: absolute;
  right: 11px;
  top: 10px;
  color: var(--coral);
  font-size: 27px;
  font-style: normal;
  font-weight: 900;
}

.mfg-product-card__visual::before,
.mfg-product-card__visual::after {
  display: none;
}

.mfg-product-card__visual svg {
  width: 176px;
  height: 150px;
  overflow: visible;
}

.mfg-product-card__visual svg path {
  fill: none;
  stroke: var(--cream);
  stroke-width: 9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mfg-product-card__visual svg .mfg-faucet-drop {
  fill: rgba(19, 156, 140, 0.22);
  stroke: var(--teal);
  stroke-width: 5;
  animation: faucet-drop 1.8s ease-in-out infinite;
  transform-origin: 174px 160px;
}

.mfg-product-card__copy {
  min-width: 0;
}

.mfg-product-card__eyebrow {
  display: block;
  margin-bottom: 10px;
  color: var(--teal);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.04em;
}

.mfg-product-card__eyebrow .bi {
  flex-direction: row;
  gap: 7px;
}

.mfg-product-card__eyebrow .bi > span[lang="en"] {
  margin: 0;
  font-size: inherit;
}

.mfg-product-card__copy > strong {
  display: block;
  color: var(--cream);
  font-size: clamp(23px, 2.3vw, 34px);
  line-height: 1.12;
}

.mfg-product-card__copy > strong .bi > span[lang="en"] {
  max-width: 26ch;
  font-size: 0.53em;
}

.mfg-product-card__copy > p {
  margin: 15px 0 11px;
  color: var(--muted);
  font-size: 17px;
  font-weight: 650;
}

.mfg-product-card__copy > p .bi > span[lang="en"] {
  font-size: 12px;
}

.mfg-product-card__copy > small {
  display: inline-block;
  padding: 5px 9px;
  border: 1px solid var(--line-strong);
  color: var(--muted);
  font-size: 10px;
}

.mfg-product-card__copy > small .bi {
  flex-direction: row;
  gap: 5px;
}

.mfg-product-card__copy > small .bi > span[lang="en"] {
  margin: 0;
  font-size: inherit;
}

.mfg-order-chain {
  display: grid;
  grid-template-columns: 1fr 42px 1fr;
  align-items: center;
  gap: 9px;
}

.mfg-order-chain > div {
  min-height: 94px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 3px 10px;
  padding: 12px 17px;
  border: 1px solid var(--line-strong);
  background: rgba(13, 42, 80, 0.86);
}

.mfg-order-chain > div > span {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
}

.mfg-order-chain > div > span .bi {
  flex-direction: row;
  gap: 6px;
}

.mfg-order-chain > div > span .bi > span[lang="en"] {
  margin: 0;
  font-size: inherit;
}

.mfg-order-chain > div > strong {
  color: var(--coral);
  font-size: 34px;
}

.mfg-order-chain > div > small {
  justify-self: end;
  color: var(--cream);
  font-size: 12px;
  font-weight: 750;
}

.mfg-order-chain > div > small .bi {
  align-items: flex-end;
}

.mfg-order-chain > i {
  color: var(--teal);
  text-align: center;
  font-size: 31px;
  font-style: normal;
  font-weight: 900;
}

.mfg-product-warning {
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 10px 14px;
  border: 1px solid rgba(232, 95, 71, 0.75);
  background: rgba(232, 95, 71, 0.13);
  color: var(--cream);
  font-size: 13px;
  font-weight: 750;
}

.mfg-product-warning > span:first-child {
  width: 27px;
  height: 27px;
  display: grid;
  flex: 0 0 27px;
  place-content: center;
  border-radius: 50%;
  background: var(--coral);
  color: var(--white);
  font-size: 16px;
  font-weight: 900;
}

.mfg-product-warning > i {
  color: var(--coral);
  font-size: 20px;
  font-style: normal;
}

.mfg-product-warning > strong {
  color: var(--coral);
}

.mfg-product-warning .bi > span[lang="en"] {
  font-size: 9px;
}

@keyframes module-gear-spin {
  to { transform: rotate(360deg); }
}

@keyframes faucet-drop {
  50% { transform: translateY(5px); opacity: 0.72; }
}

.bom-story {
  min-height: 470px;
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  align-content: center;
  gap: 12px 16px;
  padding: 18px;
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(rgba(243, 232, 210, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(243, 232, 210, 0.035) 1px, transparent 1px),
    var(--ink-2);
  background-size: 22px 22px;
  box-shadow: var(--shadow);
}

.bom-story__order {
  grid-row: 1;
  min-height: 70px;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 3px 12px;
  padding: 10px 14px;
  border: 1px solid var(--cream);
  background: var(--cream);
  color: var(--ink);
}

.bom-story__order > span {
  grid-column: 1 / -1;
  color: #516078;
  font-size: 11px;
  font-weight: 750;
}

.bom-story__order > span .bi {
  flex-direction: row;
  gap: 6px;
}

.bom-story__order > span .bi > span[lang="en"] {
  margin: 0;
  font-size: inherit;
}

.bom-story__order > strong {
  font-size: 24px;
  letter-spacing: 0.02em;
}

.bom-story__order > b {
  justify-self: end;
  display: flex;
  align-items: baseline;
  gap: 5px;
  color: var(--coral);
  font-size: 22px;
}

.bom-story__order > b .bi {
  font-size: 12px;
}

.bom-story__instruction {
  grid-row: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-left: 4px solid var(--teal);
  background: rgba(19, 156, 140, 0.1);
  color: var(--cream);
  font-size: 13px;
  font-weight: 750;
}

.bom-story__instruction > span {
  color: var(--teal);
  font-size: 27px;
  font-weight: 900;
}

.bom-story__instruction .bi > span[lang="en"] {
  font-size: 10px;
}

.bom-story__paths {
  grid-column: 1 / -1;
  display: grid;
  gap: 10px;
}

.bom-path {
  min-width: 0;
  display: grid;
  grid-template-columns: 72px minmax(84px, 0.9fr) 50px minmax(105px, 1.12fr) 50px minmax(112px, 1.18fr);
  align-items: stretch;
  gap: 6px;
  padding: 9px;
  border: 1px solid var(--line);
  background: rgba(7, 27, 56, 0.72);
}

.bom-path--long {
  grid-template-columns: 72px minmax(72px, 0.75fr) 45px minmax(88px, 0.92fr) 45px minmax(82px, 0.86fr) 45px minmax(100px, 1.05fr);
}

.bom-path__label {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 750;
}

.bom-path__label > span {
  color: var(--coral);
  font-size: 17px;
  font-weight: 900;
}

.bom-path__label .bi > span[lang="en"] {
  font-size: 8px;
}

.bom-path__node {
  min-width: 0;
  min-height: 78px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  padding: 7px 6px;
  border: 1px solid var(--line-strong);
  background: var(--ink-2);
  text-align: center;
  animation: bom-node-in 420ms ease both;
}

.bom-path__node small {
  display: flex;
  align-items: baseline;
  gap: 4px;
  color: var(--muted);
  font-size: 8px;
  white-space: nowrap;
}

.bom-path__node small .bi {
  display: inline-flex;
  flex-direction: row;
  gap: 3px;
}

.bom-path__node small .bi > span[lang="en"] {
  margin: 0;
  font-size: 7px;
}

.bom-path__node > strong {
  font-size: 14px;
}

.bom-path__name {
  min-width: 0;
  align-items: center;
  font-size: 11px;
  font-weight: 750;
}

.bom-path__name > span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bom-path__name > span[lang="en"] {
  font-size: 8px;
}

.bom-path__node > b {
  color: var(--cream);
  font-size: 20px;
}

.bom-path__node--result {
  border: 2px solid var(--coral);
  background: rgba(232, 95, 71, 0.14);
}

.bom-path__node--result > b {
  color: var(--coral);
  font-size: 25px;
}

.bom-path__operator {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 3px;
  position: relative;
  color: var(--teal);
  text-align: center;
}

.bom-path__operator::before,
.bom-path__operator::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 9px;
  height: 1px;
  background: var(--line-strong);
}

.bom-path__operator::before { left: -6px; }
.bom-path__operator::after { right: -6px; }

.bom-path__operator > span {
  font-size: 16px;
  font-weight: 900;
}

.bom-path__operator small {
  color: var(--muted);
  font-size: 8px;
}

.bom-path__operator small .bi {
  align-items: center;
}

.bom-path__operator small .bi > span[lang="en"] {
  font-size: 7px;
}

.bom-story__result {
  grid-column: 1 / -1;
  min-height: 66px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(13px, 2vw, 28px);
  padding: 9px 16px;
  border: 1px solid var(--line-strong);
  background: var(--cream);
  color: var(--ink);
}

.bom-story__result > div {
  display: flex;
  align-items: baseline;
  gap: 7px;
}

.bom-story__result > div > span {
  color: #536078;
  font-size: 11px;
  font-weight: 750;
}

.bom-story__result > div > span .bi > span[lang="en"] {
  font-size: 8px;
}

.bom-story__result strong {
  color: var(--coral);
  font-size: 27px;
}

.bom-story__result small {
  color: #536078;
  font-size: 10px;
  font-weight: 750;
}

.bom-story__result small .bi > span[lang="en"] {
  font-size: 8px;
}

.bom-story__result > i {
  color: var(--teal);
  font-size: 24px;
  font-style: normal;
  font-weight: 900;
}

@keyframes bom-node-in {
  from { opacity: 0; transform: translateY(8px); }
}

.metric-stack,
.metric-grid {
  display: grid;
  gap: 12px;
}

.metric {
  min-height: 104px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 15px;
  border-left: 4px solid var(--line-strong);
  background: rgba(13, 42, 80, 0.72);
}

.metric strong {
  margin-top: 6px;
  font-size: clamp(30px, 3vw, 48px);
}

.metric small {
  color: var(--muted);
}

.metric--success {
  border-left-color: var(--teal);
}

.metric--warning {
  border-left-color: var(--coral);
}

.metric--warning strong {
  color: var(--coral);
}

.materials-stage {
  display: grid;
  gap: 20px;
}

.metric-grid--four {
  grid-template-columns: repeat(4, 1fr);
}

.metric-grid--five {
  grid-template-columns: repeat(5, 1fr);
}

.metric-grid--four .metric,
.metric-grid--five .metric {
  min-height: 118px;
}

.material-list {
  padding: 12px 22px;
}

.material-row {
  min-height: 76px;
  display: grid;
  grid-template-columns: minmax(150px, 1.4fr) repeat(3, minmax(100px, 1fr));
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--line);
}

.material-row:last-child {
  border-bottom: 0;
}

.material-row > span:not(.bi) {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 14px;
}

.material-row strong {
  color: var(--cream);
  font-size: 25px;
}

.material-row--short {
  border-left: 4px solid var(--coral);
  padding-left: 14px;
}

.material-row--short > span:last-child strong {
  color: var(--coral);
}

.bi--row-title {
  font-size: 22px;
  font-weight: 750;
}

.impact-stage {
  display: grid;
  grid-template-columns: 0.8fr 70px 1.2fr;
  align-items: center;
  min-height: 420px;
}

.purchase-list {
  padding: 24px;
}

.purchase-list h2 {
  margin: 0 0 15px;
}

.impact-lines {
  display: grid;
  gap: 50px;
}

.impact-lines span {
  height: 1px;
  background: var(--coral);
}

.work-orders {
  display: grid;
  gap: 10px;
}

.work-order {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  border-left: 4px solid var(--coral);
}

.work-order > span:last-child {
  color: var(--muted);
}

.stop-date {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 18px;
  background: var(--coral);
  color: var(--white);
}

.stop-date strong {
  font-size: 31px;
}

.ai-panel {
  min-height: 420px;
  display: grid;
  grid-template-columns: 0.72fr 1.28fr;
  align-items: stretch;
}

.ai-conclusion {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 28px;
  padding: 32px;
  border-right: 1px solid var(--line-strong);
}

.ai-conclusion > .bi:first-child {
  color: var(--coral);
  font-size: 22px;
  font-weight: 850;
}

.ai-conclusion > strong .bi {
  font-size: clamp(35px, 4vw, 58px);
  font-weight: 850;
}

.ai-panel--safe .ai-conclusion > .bi:first-child,
.ai-panel--safe .ai-conclusion > strong {
  color: var(--teal);
}

.reason-list {
  display: grid;
  align-content: center;
  padding: 24px 30px;
}

.reason-list > div {
  display: grid;
  grid-template-columns: 42px 1fr;
  align-items: center;
  gap: 14px;
  min-height: 96px;
  border-bottom: 1px solid var(--line);
}

.reason-list > div:last-child {
  border-bottom: 0;
}

.reason-list > div > span:first-child {
  color: var(--coral);
  font-size: 18px;
  font-weight: 850;
}

.reason-list .bi {
  font-size: 20px;
}

.action-stage {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 22px;
  align-items: stretch;
}

.action-list {
  padding: 20px 28px;
}

.action-list > div {
  min-height: 145px;
  display: grid;
  grid-template-columns: 48px 1fr;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--line);
}

.action-list > div:last-child {
  border-bottom: 0;
}

.action-list > div > span:first-child {
  width: 42px;
  height: 42px;
  display: grid;
  place-content: center;
  background: var(--cream);
  color: var(--ink);
  font-size: 22px;
  font-weight: 850;
}

.action-list .bi {
  font-size: 22px;
}

.recovery-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 25px;
  padding: 26px;
  border-top: 6px solid var(--coral);
}

.recovery-card--applied {
  border-top-color: var(--teal);
}

.recovery-card > strong .bi {
  color: var(--teal);
  font-size: 34px;
}

.result-card {
  width: min(100%, 720px);
  margin-inline: auto;
  padding: 28px 34px;
}

.result-card__total {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 18px;
  margin-top: 16px;
  padding-top: 22px;
  border-top: 3px solid var(--teal);
}

.result-card__total strong {
  color: var(--teal);
  font-size: clamp(40px, 5vw, 72px);
  letter-spacing: -0.04em;
}

.status {
  display: inline-block;
  padding: 5px 9px;
  border: 1px solid var(--line-strong);
  color: var(--cream);
  font-size: 16px;
}

.status--success {
  border-color: var(--teal);
  color: var(--teal);
}

.status--warning {
  border-color: var(--coral);
  color: var(--coral);
}

.jacket-shape {
  width: 230px;
  height: 280px;
  display: grid;
  place-content: center;
  border: 4px solid var(--cream);
  clip-path: polygon(25% 0, 39% 8%, 61% 8%, 75% 0, 100% 20%, 84% 42%, 78% 30%, 78% 100%, 22% 100%, 22% 30%, 16% 42%, 0 20%);
  background: var(--ink-2);
  font-size: 38px;
  font-weight: 850;
}

.operation-ribbon {
  display: flex;
  gap: 7px;
}

.operation-ribbon > span {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 11px;
  border: 1px solid var(--line);
}

.operation-ribbon b {
  color: var(--teal);
}

.style-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 20px;
  text-align: center;
}

.style-card > strong {
  font-size: 30px;
}

.fabric-swatches {
  display: flex;
  justify-content: center;
  gap: 12px;
}

.fabric-swatches i {
  width: 92px;
  height: 120px;
  background: #18314f;
}

.fabric-swatches i:last-child {
  background: #a38d67;
}

.variant-stage {
  padding: 20px 26px;
}

.size-head,
.size-row {
  display: grid;
  grid-template-columns: minmax(120px, 1.15fr) repeat(4, 1fr);
  gap: 10px;
  align-items: center;
}

.size-head {
  padding: 5px 0 12px;
  color: var(--muted);
  text-align: center;
  font-weight: 750;
}

.size-row {
  min-height: 110px;
  border-top: 1px solid var(--line);
}

.size-row > div:not(.color-name) {
  display: grid;
  justify-items: center;
  gap: 6px;
}

.size-row small {
  color: var(--muted);
}

.size-row strong {
  font-size: 31px;
}

.color-name {
  padding-left: 17px;
  border-left: 7px solid #294c79;
}

.color-name--khaki {
  border-left-color: #a38d67;
}

.variant-total {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 22px;
  padding-top: 18px;
  border-top: 2px solid var(--teal);
}

.variant-total strong {
  color: var(--teal);
  font-size: 45px;
}

.material-list--garment .material-row {
  grid-template-columns: minmax(170px, 1.5fr) repeat(2, 1fr) auto;
}

.process-stage {
  display: grid;
  gap: 26px;
}

.process-rail {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
}

.process-node {
  min-width: 0;
  padding: 15px 13px;
  border-top: 4px solid var(--line-strong);
  background: var(--ink-2);
}

.process-node--active {
  border-top-color: var(--coral);
}

.process-node__top {
  min-height: 84px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
}

.process-node__top strong {
  font-size: 29px;
}

.bi--compact {
  font-size: 17px;
  font-weight: 750;
}

.mini-progress {
  height: 5px;
  margin-top: 12px;
  background: var(--line);
}

.mini-progress span {
  display: block;
  height: 100%;
  background: var(--teal);
}

.process-node--active .mini-progress span {
  background: var(--coral);
}

.piecework-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.capacity-shift {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 18px;
  min-height: 350px;
  padding: 26px;
  border: 1px solid var(--line-strong);
}

.capacity-shift > div {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.capacity-shift strong {
  font-size: 64px;
}

.capacity-shift > span {
  color: var(--teal);
  font-size: 50px;
}

.capacity-shift__new strong {
  color: var(--teal);
}

.trade-flow {
  grid-template-columns: 1fr auto 1.1fr auto 1fr auto 1fr;
  align-content: center;
}

.trade-flow > div {
  min-width: 115px;
  min-height: 120px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line-strong);
}

.trade-flow i {
  color: var(--teal);
  font-size: 31px;
  font-style: normal;
}

.trade-flow strong,
.trade-flow > div > span:last-child {
  font-size: 30px;
  font-weight: 850;
}

.warehouse-box {
  border: 3px solid var(--cream) !important;
}

.stock-equation {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  align-items: center;
  gap: 18px;
}

.stock-equation > span {
  color: var(--muted);
  font-size: 52px;
}

.inventory-lanes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 25px;
}

.inventory-lane {
  min-height: 360px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 24px;
  border: 1px solid var(--line-strong);
}

.inventory-lane--available {
  border-top: 7px solid var(--teal);
}

.inventory-lane--incoming {
  border-top: 7px solid var(--cream);
}

.inventory-lane strong {
  font-size: 80px;
}

.inventory-lane small {
  color: var(--muted);
  font-size: 18px;
}

.return-flow {
  display: grid;
  grid-template-columns: 1fr auto 1fr 1fr;
  align-items: center;
  gap: 18px;
}

.return-total,
.return-branch {
  min-height: 240px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 20px;
  border: 1px solid var(--line-strong);
}

.return-flow > span {
  font-size: 44px;
}

.return-flow strong {
  font-size: 62px;
}

.return-branch--good {
  border-top: 7px solid var(--teal);
}

.return-branch--bad {
  border-top: 7px solid var(--coral);
}

.forecast-stage {
  min-height: 390px;
  display: grid;
  grid-template-columns: 0.7fr 1.3fr;
  grid-template-rows: 1fr auto;
  gap: 22px;
  padding: 28px;
}

.forecast-number {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
}

.forecast-number strong {
  color: var(--teal);
  font-size: clamp(64px, 8vw, 110px);
}

.forecast-number small {
  color: var(--muted);
  font-size: 18px;
}

.forecast-chart {
  min-height: 250px;
  display: flex;
  align-items: end;
  gap: 9px;
  border-bottom: 1px solid var(--line-strong);
}

.forecast-chart > span {
  flex: 1;
  min-height: 20px;
  position: relative;
  background: var(--teal);
  animation: bar-rise 700ms ease both;
}

.forecast-chart > span:last-child {
  background: var(--coral);
}

.forecast-chart i {
  position: absolute;
  bottom: -23px;
  left: 50%;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  transform: translateX(-50%);
}

.forecast-factors {
  grid-column: 1 / -1;
  display: flex;
  gap: 10px;
}

.forecast-factors > span {
  flex: 1;
  padding: 11px;
  border-left: 3px solid var(--line-strong);
}

.replenishment-stage {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  min-height: 400px;
}

.replenishment-equation {
  padding: 24px 30px;
  border-right: 1px solid var(--line-strong);
}

.replenishment-answer {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 18px;
  padding: 24px;
  text-align: center;
}

.replenishment-answer strong {
  color: var(--teal);
  font-size: 78px;
}

.replenishment-answer small {
  color: var(--muted);
}

.trial-panel {
  z-index: 30;
  position: fixed;
  top: calc(74px + env(safe-area-inset-top));
  right: 0;
  bottom: 0;
  width: min(34vw, 450px);
  padding: 20px;
  overflow-y: auto;
  border-left: 1px solid var(--line-strong);
  background: #091f40;
  box-shadow: -18px 0 45px rgba(0, 0, 0, 0.24);
}

.trial-panel__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 17px;
}

.mode-kicker {
  display: block;
  margin-bottom: 5px;
  color: var(--coral);
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.16em;
}

.bi--panel-title {
  font-size: 27px;
  font-weight: 850;
}

.case-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
  margin-bottom: 20px;
}

.case-tab {
  min-height: 76px;
  padding: 7px;
  border: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
}

.case-tab.is-selected {
  border-color: var(--teal);
  background: rgba(19, 156, 140, 0.13);
}

.bi--tab {
  align-items: center;
  font-size: 14px;
  font-weight: 800;
}

.bi--tab > span[lang="en"] {
  font-size: 11px;
}

.trial-controls {
  display: grid;
  gap: 20px;
}

.trial-navigation {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 5px;
  margin: -8px 0 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.trial-navigation .button {
  min-height: 60px;
  border: 1px solid var(--line);
}

.trial-group {
  display: grid;
  gap: 9px;
}

.trial-group h3 {
  margin: 0;
}

.choice-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
}

.choice-button {
  min-height: 74px;
  padding: 8px 5px;
  border: 1px solid var(--line-strong);
  background: var(--ink);
  cursor: pointer;
}

.choice-button.is-selected {
  border-color: var(--teal);
  background: var(--teal);
  color: var(--white);
}

.bi--choice {
  align-items: center;
  font-size: 18px;
  font-weight: 800;
}

.bi--choice > span[lang="en"] {
  min-height: 18px;
  font-size: 14px;
}

.trial-submit {
  width: 100%;
}

.control-overlay {
  z-index: 80;
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: min(720px, calc(100vw - 44px));
  padding: 20px;
  border: 1px solid var(--line-strong);
  background: #091f40;
  box-shadow: var(--shadow);
}

.control-overlay__head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}

.control-overlay__head small {
  display: flex;
  gap: 8px;
  margin-top: 5px;
  color: var(--muted);
}

.control-close {
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--cream);
  font-size: 28px;
  cursor: pointer;
}

.control-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.button--control {
  min-height: 72px;
  padding: 8px;
  border-color: var(--line);
  background: var(--ink);
  color: var(--cream);
}

.reset-overlay,
.case-menu {
  z-index: 60;
  position: fixed;
  inset: 0;
  display: grid;
  place-content: center;
  padding: 30px;
  background: rgba(7, 27, 56, 0.9);
}

.case-menu__panel {
  width: min(1080px, 90vw);
  padding: 32px;
  border: 1px solid var(--line-strong);
  background: var(--ink);
  box-shadow: var(--shadow);
}

.case-menu__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 26px;
}

.case-menu__head > span:first-child {
  color: var(--coral);
  font-weight: 900;
  letter-spacing: 0.14em;
}

.case-menu__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 24px;
}

.case-menu-card {
  min-height: 210px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start;
  padding: 22px;
  border: 1px solid var(--line-strong);
  border-top: 7px solid var(--coral);
  background: var(--ink-2);
  text-align: left;
  cursor: pointer;
}

.case-menu-card--garment {
  border-top-color: var(--teal);
}

.case-menu-card--trading {
  border-top-color: var(--cream);
}

.case-menu-card__number {
  color: var(--muted);
  font-size: 22px;
  font-weight: 850;
}

.bi--menu {
  font-size: 28px;
  font-weight: 850;
}

.reset-card {
  min-width: 330px;
  min-height: 220px;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 25px;
  padding: 30px;
  border: 1px solid var(--line-strong);
  background: var(--ink);
  box-shadow: var(--shadow);
  text-align: center;
}

.reset-card--error {
  border-top: 6px solid var(--coral);
}

.spinner {
  width: 48px;
  height: 48px;
  border: 5px solid var(--line-strong);
  border-top-color: var(--teal);
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}

.storage-notice {
  z-index: 100;
  position: fixed;
  left: 20px;
  bottom: 58px;
  max-width: 420px;
  padding: 14px 18px;
  border-left: 5px solid var(--coral);
  background: var(--cream);
  color: var(--ink);
}

.storage-notice small {
  display: block;
  margin-top: 5px;
}

@keyframes scene-enter {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes scene-copy-in {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes scene-visual-in {
  from { opacity: 0; transform: translateY(18px) scale(0.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes live-pulse {
  50% { opacity: 0.55; transform: scale(0.8); }
}

@keyframes scene-time {
  from { width: 0; }
  to { width: 100%; }
}

@keyframes bar-rise {
  from { height: 0; }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 1260px) {
  .topbar {
    grid-template-columns: minmax(250px, 1fr) auto minmax(245px, 1fr) 50px;
    gap: 12px;
  }

  .scene {
    grid-template-columns: minmax(260px, 0.65fr) minmax(420px, 1.35fr);
    gap: 30px;
  }

  .showcase--interactive .stage {
    padding-right: min(38vw, 440px);
    padding-left: 30px;
  }

  .trial-panel {
    width: min(38vw, 420px);
  }

  .showcase--interactive .scene {
    grid-template-columns: 1fr;
    align-content: start;
    gap: 18px;
  }

  .showcase--interactive .scene__copy {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
    align-items: end;
    gap: 18px;
  }

  .showcase--interactive .scene__context,
  .showcase--interactive .scene__flow {
    grid-column: 1 / -1;
  }

  .showcase--interactive .scene__copy::before {
    position: absolute;
    top: -12px;
    margin: 0;
  }

  .showcase--interactive .bi--message {
    margin-top: 0;
  }

  .showcase--interactive .product-blueprint,
  .showcase--interactive .garment-intro,
  .showcase--interactive .trade-flow,
  .showcase--interactive .bom-tree,
  .showcase--interactive .ai-panel,
  .showcase--interactive .forecast-stage {
    min-height: 300px;
  }

  .bi--hero {
    font-size: clamp(35px, 4vw, 55px);
  }

  .metric-grid--five {
    grid-template-columns: repeat(3, 1fr);
  }

  .trade-flow {
    gap: 10px;
  }

  .trade-flow > div {
    min-width: 90px;
  }
}

@media (max-width: 1020px) {
  html,
  body {
    overflow: auto;
  }

  .showcase {
    min-height: 0;
    grid-template-rows: auto minmax(0, 1fr) calc(46px + env(safe-area-inset-bottom));
  }

  .topbar {
    grid-template-columns: 1fr auto 50px;
    min-height: 74px;
  }

  .case-progress {
    display: none;
  }

  .auto-badge {
    display: none;
  }

  .stage,
  .showcase--interactive .stage {
    padding: 28px 32px;
  }

  .showcase--interactive .stage {
    padding-bottom: 470px;
  }

  .scene {
    grid-template-columns: 1fr;
    align-content: start;
    gap: 24px;
  }

  .scene__copy {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: end;
    gap: 20px;
  }

  .scene__context,
  .scene__flow {
    grid-column: 1 / -1;
  }

  .scene__copy::before {
    position: absolute;
    top: -12px;
  }

  .bi--message {
    margin-top: 0;
  }

  .trial-panel {
    top: auto;
    left: 0;
    width: 100%;
    height: 440px;
    border-top: 1px solid var(--line-strong);
    border-left: 0;
  }

  .trial-controls {
    grid-template-columns: 1fr 1fr 1fr;
    align-items: end;
  }

  .trial-submit {
    min-height: 90px;
  }
}

@media (max-height: 760px) and (min-width: 1021px) {
  .showcase {
    grid-template-rows: calc(66px + env(safe-area-inset-top)) minmax(0, 1fr) calc(38px + env(safe-area-inset-bottom));
  }

  .topbar {
    padding-top: calc(7px + env(safe-area-inset-top));
    padding-bottom: 7px;
  }

  .trial-panel {
    top: calc(66px + env(safe-area-inset-top));
    padding-top: 13px;
  }

  .stage {
    padding-top: 20px;
    padding-bottom: 18px;
  }

  .scene-progress {
    row-gap: 2px;
    padding-top: 3px;
    padding-bottom: max(3px, env(safe-area-inset-bottom));
  }

  .showcase-playback {
    width: 26px;
    height: 26px;
  }

  .bi--hero {
    font-size: clamp(34px, 3.6vw, 55px);
  }

  .bi--message {
    margin-top: 16px;
  }

  .incoming-document,
  .paper-card,
  .style-card,
  .product-blueprint,
  .garment-intro,
  .trade-flow,
  .bom-tree,
  .ai-panel,
  .forecast-stage {
    min-height: 330px;
  }

  .metric {
    min-height: 88px;
  }

  .trial-group {
    gap: 5px;
  }

  .choice-button {
    min-height: 64px;
  }
}

@media (orientation: landscape) and (max-width: 1020px) {
  html,
  body {
    overflow: hidden;
  }

  .showcase {
    height: var(--app-height);
    min-height: 0;
    grid-template-rows: calc(66px + env(safe-area-inset-top)) minmax(0, 1fr) calc(38px + env(safe-area-inset-bottom));
  }

  .topbar {
    min-height: 0;
    padding-top: calc(7px + env(safe-area-inset-top));
    padding-bottom: 7px;
  }

  .stage,
  .showcase--interactive .stage {
    min-height: 0;
    padding: 20px 26px;
  }

  .scene-progress {
    row-gap: 2px;
    padding: 3px 26px max(3px, env(safe-area-inset-bottom));
  }

  .showcase-playback {
    width: 26px;
    height: 26px;
  }
}

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

  .scene-timer.is-running span {
    animation-duration: var(--scene-duration) !important;
  }
}

/* Interactive ERP workspace */
.erp-app {
  --erp-accent: #e85f47;
  --erp-accent-soft: #fff0ec;
  --erp-sidebar: #10233f;
  --erp-sidebar-2: #182e4d;
  --erp-bg: #f3f6fa;
  --erp-surface: #ffffff;
  --erp-ink: #17243a;
  --erp-muted: #68768a;
  --erp-line: #dde4ec;
  --erp-success: #15846f;
  --erp-warning: #c88216;
  --erp-danger: #d64c43;
  --erp-info: #3978c8;
  position: fixed;
  inset: 0;
  z-index: 150;
  display: grid;
  grid-template-columns: 236px minmax(0, 1fr);
  height: var(--app-height);
  overflow: hidden;
  background: var(--erp-bg);
  color: var(--erp-ink);
  color-scheme: light;
  user-select: none;
}

.erp-app--teal {
  --erp-accent: #139c8c;
  --erp-accent-soft: #e7f6f3;
}

.erp-app--blue {
  --erp-accent: #3978c8;
  --erp-accent-soft: #eaf2fb;
}

.erp-app button:focus-visible,
.erp-app input:focus-visible,
.erp-app select:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--erp-accent) 35%, transparent);
  outline-offset: 1px;
}

.erp-app button,
.erp-app input,
.erp-app select {
  font: inherit;
}

.erp-sidebar {
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 18px 14px 16px;
  background: var(--erp-sidebar);
  color: #f7fafc;
  box-shadow: 4px 0 18px rgba(20, 34, 55, 0.12);
}

.erp-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 52px;
  padding: 0 9px 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.erp-brand img {
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 9px;
}

.erp-brand div {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.erp-brand strong {
  font-size: 19px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.erp-brand small {
  margin-top: 2px;
  color: #9eb0c8;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.13em;
}

.erp-case-switcher {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  margin: 15px 2px 19px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 9px;
  background: rgba(0, 0, 0, 0.13);
}

.erp-case-switcher__item {
  min-width: 0;
  min-height: 48px;
  padding: 5px 2px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #aebed1;
  cursor: pointer;
}

.erp-case-switcher__item.is-active {
  background: var(--erp-accent);
  color: #fff;
  box-shadow: 0 5px 12px rgba(0, 0, 0, 0.18);
}

.erp-case-switcher__item .bi {
  width: 100%;
  align-items: center;
  font-size: 12px;
  font-weight: 850;
}

.erp-case-switcher__item .bi > span[lang="en"] {
  font-size: 9px;
}

.erp-nav-label {
  margin: 0 10px 8px;
  color: #758aa5;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.09em;
}

.erp-nav-label .bi > span[lang="en"] {
  display: none;
}

.erp-nav {
  display: grid;
  gap: 4px;
}

.erp-nav__item {
  min-height: 57px;
  display: grid;
  grid-template-columns: 31px minmax(0, 1fr);
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #c2cede;
  text-align: left;
  cursor: pointer;
}

.erp-nav__item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.erp-nav__item.is-active {
  background: var(--erp-sidebar-2);
  color: #fff;
  box-shadow: inset 3px 0 0 var(--erp-accent);
}

.erp-nav__icon {
  color: #8fa4bf;
  font-size: 19px;
  text-align: center;
}

.erp-nav__item.is-active .erp-nav__icon {
  color: var(--erp-accent);
}

.erp-nav__label {
  min-width: 0;
  font-size: 14px;
  font-weight: 750;
}

.erp-nav__label > span[lang="en"] {
  color: #8fa4bf;
  font-size: 10px;
}

.erp-sidebar__foot {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding: 13px 9px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #b7c5d7;
  font-size: 11px;
}

.erp-sidebar__foot > div {
  min-width: 0;
}

.erp-sidebar__foot small {
  display: block;
  margin-top: 2px;
  color: #758aa5;
  font-size: 9px;
}

.erp-live-dot {
  width: 9px;
  height: 9px;
  flex: 0 0 9px;
  border: 2px solid rgba(115, 224, 194, 0.25);
  border-radius: 50%;
  background: #49cba7;
  box-shadow: 0 0 0 3px rgba(73, 203, 167, 0.12);
}

.erp-main {
  min-width: 0;
  display: grid;
  grid-template-rows: 70px minmax(0, 1fr);
  overflow: hidden;
}

.erp-topbar {
  z-index: 3;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 10px 22px;
  border-bottom: 1px solid var(--erp-line);
  background: var(--erp-surface);
  box-shadow: 0 2px 7px rgba(31, 48, 73, 0.04);
}

.erp-breadcrumb {
  min-width: 190px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--erp-muted);
  font-size: 12px;
  font-weight: 700;
}

.erp-breadcrumb > span:first-child {
  color: var(--erp-accent);
  font-weight: 900;
}

.erp-breadcrumb i {
  color: #bec8d4;
  font-style: normal;
}

.erp-breadcrumb .bi > span[lang="en"] {
  display: none;
}

.erp-search {
  width: min(370px, 32vw);
  height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  padding: 0 12px;
  border: 1px solid var(--erp-line);
  border-radius: 8px;
  background: #f8fafc;
  color: var(--erp-muted);
}

.erp-search input {
  min-width: 0;
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--erp-ink);
  font-size: 12px;
}

.erp-site {
  display: flex;
  flex-direction: column;
  color: var(--erp-ink);
  font-size: 12px;
  font-weight: 750;
  white-space: nowrap;
}

.erp-site .bi > span[lang="en"] {
  display: none;
}

.erp-site small {
  margin-top: 2px;
  color: var(--erp-muted);
  font-size: 10px;
}

.erp-user {
  width: 38px;
  height: 38px;
  display: grid;
  flex: 0 0 38px;
  place-content: center;
  border-radius: 50%;
  background: var(--erp-accent-soft);
  color: var(--erp-accent);
  font-size: 12px;
  font-weight: 900;
}

.erp-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 14px;
  border: 1px solid transparent;
  border-radius: 7px;
  background: var(--erp-surface);
  color: var(--erp-ink);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.erp-button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.erp-button--primary {
  border-color: var(--erp-accent);
  background: var(--erp-accent);
  color: #fff;
  box-shadow: 0 5px 13px color-mix(in srgb, var(--erp-accent) 22%, transparent);
}

.erp-button--secondary {
  border-color: var(--erp-line);
  background: #fff;
}

.erp-button--back {
  min-width: 126px;
  border-color: #cfd8e3;
  background: #f8fafc;
  color: #314056;
}

.erp-bi-button {
  align-items: center;
  font-size: 12px;
  line-height: 1.05;
  white-space: nowrap;
}

.erp-bi-button > span[lang="en"] {
  margin-top: 3px;
  font-size: 9px;
}

.erp-content {
  min-width: 0;
  min-height: 0;
  overflow: auto;
  padding: 24px 26px 38px;
  background:
    linear-gradient(90deg, rgba(36, 65, 100, 0.025) 1px, transparent 1px),
    linear-gradient(rgba(36, 65, 100, 0.025) 1px, transparent 1px),
    var(--erp-bg);
  background-size: 26px 26px;
}

.erp-page-head {
  min-height: 76px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.erp-page-head h1,
.erp-page-head p {
  margin: 0;
}

.erp-page-head h1 .bi {
  font-size: clamp(23px, 2vw, 31px);
  font-weight: 850;
  letter-spacing: -0.025em;
}

.erp-page-head h1 .bi > span[lang="en"] {
  color: var(--erp-muted);
  font-size: 0.48em;
  letter-spacing: 0;
}

.erp-page-head p {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 6px;
  color: var(--erp-muted);
  font-size: 12px;
}

.erp-page-head p > .bi:first-child {
  display: block;
}

.erp-page-head p > .bi:first-child span[lang="en"] {
  display: none;
}

.erp-story-banner {
  display: grid;
  grid-template-columns: minmax(250px, 0.9fr) minmax(320px, 1.1fr);
  gap: 14px;
  margin-bottom: 16px;
  padding: 14px 16px;
  border: 1px solid color-mix(in srgb, var(--erp-accent) 28%, var(--erp-line));
  border-left: 4px solid var(--erp-accent);
  background: var(--erp-surface);
}

.erp-story-banner__question,
.erp-story-banner__flow {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.erp-story-banner__flow {
  padding-left: 16px;
  border-left: 1px solid var(--erp-line);
}

.erp-story-label {
  color: var(--erp-muted);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.08em;
}

.erp-story-label > span[lang="en"] {
  display: none;
}

.erp-story-question {
  color: var(--erp-ink);
  font-size: 16px;
  font-weight: 850;
}

.erp-story-question > span[lang="en"] {
  display: block;
  margin-top: 3px;
  color: var(--erp-muted);
  font-size: 10px;
  font-weight: 650;
}

.erp-story-flow {
  color: var(--erp-accent);
  font-size: 14px;
  font-weight: 850;
}

.erp-story-flow > span[lang="en"] {
  display: block;
  margin-top: 3px;
  color: var(--erp-muted);
  font-size: 10px;
  font-weight: 650;
}

.erp-page-eyebrow {
  display: block;
  margin-bottom: 4px;
  color: var(--erp-accent);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.08em;
}

.erp-page-eyebrow .bi {
  display: inline-flex;
  flex-direction: row;
  gap: 6px;
}

.erp-page-eyebrow .bi > span[lang="en"] {
  margin: 0;
  font-size: inherit;
}

.erp-status {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  border: 1px solid #d7dee7;
  border-radius: 999px;
  background: #f3f5f8;
  color: #58677b;
  font-size: 10px;
  font-weight: 800;
  vertical-align: middle;
}

.erp-status--success { border-color: #b9ded4; background: #eaf7f3; color: var(--erp-success); }
.erp-status--warning { border-color: #ead3a9; background: #fff6e5; color: #9b620b; }
.erp-status--danger { border-color: #efc4c0; background: #fff0ef; color: var(--erp-danger); }
.erp-status--info { border-color: #c5d9f1; background: #edf5fd; color: var(--erp-info); }

.erp-bi-status {
  align-items: center;
  line-height: 1;
}

.erp-bi-status > span[lang="en"] {
  margin-top: 2px;
  font-size: 8px;
}

.erp-workflow {
  display: grid;
  grid-template-columns: repeat(5, minmax(110px, 1fr));
  margin-bottom: 20px;
  padding: 14px 18px;
  border: 1px solid var(--erp-line);
  border-radius: 10px;
  background: var(--erp-surface);
  box-shadow: 0 5px 16px rgba(37, 54, 77, 0.04);
}

.erp-workflow__step {
  min-width: 0;
  display: grid;
  grid-template-columns: 29px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  position: relative;
  color: #8a96a7;
  font-size: 11px;
}

.erp-workflow__step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 14px;
  right: 9px;
  left: calc(100% - 24px);
  height: 1px;
  background: var(--erp-line);
}

.erp-workflow__step > span:first-child {
  width: 29px;
  height: 29px;
  display: grid;
  place-content: center;
  border: 1px solid #cbd4df;
  border-radius: 50%;
  background: #fff;
  font-size: 10px;
  font-weight: 850;
}

.erp-workflow__step .bi > span[lang="en"] {
  font-size: 8px;
}

.erp-workflow__step.is-done { color: var(--erp-success); }
.erp-workflow__step.is-done > span:first-child { border-color: var(--erp-success); background: var(--erp-success); color: #fff; }
.erp-workflow__step.is-active { color: var(--erp-accent); font-weight: 800; }
.erp-workflow__step.is-active > span:first-child { border: 2px solid var(--erp-accent); color: var(--erp-accent); box-shadow: 0 0 0 4px var(--erp-accent-soft); }

.erp-workspace {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  align-items: start;
  gap: 18px;
}

.erp-workspace__main {
  min-width: 0;
  display: grid;
  gap: 16px;
}

.erp-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--erp-line);
  border-radius: 10px;
  background: var(--erp-surface);
  box-shadow: 0 6px 18px rgba(35, 51, 73, 0.055);
}

.erp-card__head {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 9px 16px;
  border-bottom: 1px solid var(--erp-line);
  background: #fbfcfd;
}

.erp-card__title {
  color: var(--erp-ink);
  font-size: 15px;
  font-weight: 850;
}

.erp-card__title > span[lang="en"] {
  color: var(--erp-muted);
  font-size: 10px;
}

.erp-card__body {
  min-width: 0;
}

.erp-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.erp-kpi {
  min-height: 128px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 16px 18px;
  overflow: hidden;
  border: 1px solid var(--erp-line);
  border-radius: 10px;
  background: var(--erp-surface);
  box-shadow: 0 5px 16px rgba(37, 54, 77, 0.045);
}

.erp-kpi::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: #aab7c7;
}

.erp-kpi--danger::before { background: var(--erp-danger); }
.erp-kpi--warning::before { background: var(--erp-warning); }
.erp-kpi--success::before { background: var(--erp-success); }
.erp-kpi--info::before { background: var(--erp-info); }

.erp-kpi__label {
  color: var(--erp-muted);
  font-size: 11px;
  font-weight: 750;
}

.erp-kpi__label .bi > span[lang="en"] { font-size: 8px; }

.erp-kpi > strong {
  margin: 8px 0 5px;
  color: var(--erp-ink);
  font-size: clamp(22px, 2vw, 29px);
  line-height: 1;
}

.erp-kpi > small {
  color: var(--erp-muted);
  font-size: 10px;
}

.erp-kpi > small .bi { display: block; }
.erp-kpi > small .bi > span[lang="en"] { display: none; }

.erp-ai-card {
  position: sticky;
  top: 0;
  min-width: 0;
  overflow: hidden;
  padding: 18px;
  border: 1px solid #d3dce7;
  border-top: 5px solid var(--erp-accent);
  border-radius: 10px;
  background: linear-gradient(165deg, #fff 0%, #f6f9fc 100%);
  box-shadow: 0 9px 28px rgba(30, 49, 76, 0.1);
}

.erp-ai-card.is-risk { border-top-color: var(--erp-danger); }
.erp-ai-card.is-resolved { border-top-color: var(--erp-success); }

.erp-ai-card__brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--erp-ink);
  font-size: 12px;
  font-weight: 850;
}

.erp-ai-card__brand > span {
  width: 27px;
  height: 27px;
  display: grid;
  place-content: center;
  border-radius: 7px;
  background: var(--erp-sidebar);
  color: #fff;
}

.erp-ai-card__brand .bi > span[lang="en"] { font-size: 8px; }

.erp-ai-card__signal {
  margin-top: 17px;
}

.erp-ai-card__number {
  display: flex;
  align-items: flex-end;
  gap: 7px;
  margin: 14px 0 10px;
  color: var(--erp-accent);
  font-size: 50px;
  line-height: 0.9;
}

.erp-ai-card.is-risk .erp-ai-card__number { color: var(--erp-danger); }
.erp-ai-card.is-resolved .erp-ai-card__number { color: var(--erp-success); }

.erp-ai-card__number small {
  padding-bottom: 4px;
  color: var(--erp-muted);
  font-size: 10px;
}

.erp-ai-card p {
  margin: 13px 0;
  color: #44536a;
  font-size: 12px;
  line-height: 1.55;
}

.erp-ai-card p .bi > span[lang="en"] {
  font-size: 9px;
}

.erp-ai-card ul {
  display: grid;
  gap: 7px;
  margin: 13px 0 16px;
  padding: 12px 12px 12px 28px;
  border-radius: 7px;
  background: #f0f3f7;
  color: #526177;
  font-size: 10px;
}

.erp-ai-card li .bi > span[lang="en"] { font-size: 8px; }

.erp-button--ai {
  width: 100%;
  min-height: 50px;
  border-color: var(--erp-sidebar);
  background: var(--erp-sidebar);
  color: #fff;
}

.erp-ai-card__foot {
  display: block;
  margin-top: 10px;
  color: var(--erp-muted);
  text-align: center;
  font-size: 8px;
}

.erp-ai-compare,
.erp-ai-equation {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 13px 0 16px;
  padding: 11px 8px;
  border: 1px solid var(--erp-line);
  border-radius: 8px;
  background: #fff;
}

.erp-ai-compare span {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--erp-muted);
  font-size: 9px;
}

.erp-ai-compare strong { margin-top: 4px; color: var(--erp-ink); font-size: 21px; }
.erp-ai-compare i { color: var(--erp-accent); font-style: normal; }
.erp-ai-equation { gap: 5px; color: var(--erp-muted); font-size: 11px; }
.erp-ai-equation span,
.erp-ai-equation strong { color: var(--erp-ink); }

.erp-document-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  border-bottom: 1px solid var(--erp-line);
}

.erp-field-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  padding: 8px 16px;
}

.erp-field {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 12px;
}

.erp-field > span {
  color: var(--erp-muted);
  font-size: 10px;
  font-weight: 700;
}

.erp-field > span .bi > span[lang="en"] { font-size: 8px; }

.erp-field > strong {
  min-width: 0;
  margin-top: 6px;
  overflow: hidden;
  color: var(--erp-ink);
  font-size: 13px;
  text-overflow: ellipsis;
}

.erp-field > strong > .bi > span[lang="en"] { font-size: 9px; }

.erp-field > small {
  color: var(--erp-muted);
  font-size: 9px;
}

.erp-document-total {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 20px;
  border-left: 1px solid var(--erp-line);
  background: #f8fafc;
}

.erp-document-total > span { color: var(--erp-muted); font-size: 11px; }
.erp-document-total > strong { margin: 9px 0 5px; color: var(--erp-accent); font-size: 24px; }
.erp-document-total > small { color: var(--erp-muted); font-size: 9px; }

.erp-table-wrap {
  width: 100%;
  min-width: 0;
  overflow: auto;
}

.erp-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  color: var(--erp-ink);
  font-size: 11px;
}

.erp-table th {
  height: 47px;
  padding: 7px 11px;
  border-bottom: 1px solid var(--erp-line);
  background: #f4f7fa;
  color: #5f6e82;
  text-align: left;
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.erp-table th .bi > span[lang="en"] { font-size: 8px; }

.erp-table td {
  height: 56px;
  padding: 9px 11px;
  border-bottom: 1px solid #e7ecf2;
  background: #fff;
  vertical-align: middle;
  white-space: nowrap;
}

.erp-table tr:last-child td { border-bottom: 0; }
.erp-table tr:hover td { background: #fbfcfe; }
.erp-table tr.is-highlight td { background: #fff9ed; }
.erp-table td small { display: block; margin-top: 3px; color: var(--erp-muted); font-size: 9px; }
.erp-table td .bi > span[lang="en"] { font-size: 8px; }
.erp-table--dense td { height: 47px; padding-block: 6px; }

.erp-table-action {
  min-height: 35px;
  padding: 4px 8px;
  border: 1px solid var(--erp-accent);
  border-radius: 5px;
  background: var(--erp-accent-soft);
  color: var(--erp-accent);
  font-size: 9px;
  font-weight: 800;
  cursor: pointer;
}

.erp-table-action .erp-bi-button > span[lang="en"] { font-size: 7px; }

.erp-text-danger,
.is-danger { color: var(--erp-danger) !important; }
.erp-text-success { color: var(--erp-success) !important; }

.erp-inline-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.erp-inline-summary > span {
  min-height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  border: 1px solid var(--erp-line);
  border-radius: 8px;
  background: #fff;
  color: var(--erp-muted);
  font-size: 10px;
}

.erp-inline-summary strong { color: var(--erp-ink); font-size: 18px; }

.erp-bom-name {
  display: flex;
  align-items: center;
  gap: 7px;
  padding-left: calc(var(--level) * 16px);
}

.erp-bom-name > span { color: var(--erp-accent); }

.erp-audit-note {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 15px;
  border: 1px solid #bed7ef;
  border-radius: 8px;
  background: #edf6fe;
  color: #43617e;
  font-size: 10px;
}

.erp-audit-note > span {
  width: 22px;
  height: 22px;
  display: grid;
  flex: 0 0 22px;
  place-content: center;
  border-radius: 50%;
  background: var(--erp-info);
  color: #fff;
  font-weight: 900;
}

.erp-progress-cell {
  min-width: 112px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.erp-progress-cell > span {
  width: 70px;
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #e4e9ef;
}

.erp-progress-cell i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--erp-accent);
}

.erp-progress-cell strong { font-size: 10px; }

.erp-size-matrix {
  padding: 15px;
}

.erp-size-matrix__head,
.erp-size-matrix__row {
  display: grid;
  grid-template-columns: minmax(135px, 1.4fr) repeat(5, minmax(58px, 0.7fr));
  align-items: center;
}

.erp-size-matrix__head {
  min-height: 42px;
  padding: 0 11px;
  background: #f3f6f9;
  color: var(--erp-muted);
  font-size: 10px;
}

.erp-size-matrix__head > strong { text-align: center; }

.erp-size-matrix__row {
  min-height: 58px;
  padding: 0 11px;
  border-bottom: 1px solid var(--erp-line);
}

.erp-size-matrix__row > span { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 750; }
.erp-size-matrix__row > strong { text-align: center; font-size: 13px; }
.erp-size-matrix__row > strong:last-child { color: var(--erp-accent); }

.erp-color-chip {
  width: 18px;
  height: 18px;
  display: inline-block;
  border: 2px solid #d9e0e8;
  border-radius: 4px;
}

.erp-color-chip.is-navy { background: #243d65; }
.erp-color-chip.is-khaki { background: #b7a27b; }

.erp-size-matrix__total {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 22px;
  padding: 15px 11px 2px;
  color: var(--erp-muted);
  font-size: 11px;
}

.erp-size-matrix__total strong { color: var(--erp-ink); font-size: 18px; }

.erp-process-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 11px;
  padding: 16px;
}

.erp-process-tile {
  padding: 12px;
  border: 1px solid var(--erp-line);
  border-radius: 7px;
  background: #fbfcfd;
}

.erp-process-tile.is-bottleneck { border-color: #eac57f; background: #fff9ee; }
.erp-process-tile header { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 11px; font-weight: 750; }
.erp-process-tile header .bi > span[lang="en"] { font-size: 8px; }
.erp-process-tile header > span { color: var(--erp-accent); }
.erp-process-tile > div { height: 6px; margin: 13px 0 7px; overflow: hidden; border-radius: 999px; background: #e1e7ed; }
.erp-process-tile > div i { display: block; height: 100%; background: var(--erp-accent); }
.erp-process-tile > small { color: var(--erp-muted); font-size: 9px; }

.erp-total-strip {
  min-height: 82px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 4px 20px;
  padding: 14px 18px;
  border: 1px solid var(--erp-line);
  border-left: 5px solid var(--erp-accent);
  border-radius: 8px;
  background: #fff;
}

.erp-total-strip > span { color: var(--erp-muted); font-size: 11px; }
.erp-total-strip > strong { grid-row: 1 / span 2; grid-column: 2; color: var(--erp-accent); font-size: 25px; }
.erp-total-strip > small { color: var(--erp-muted); font-size: 9px; }

.erp-stock-equation {
  display: grid;
  grid-template-columns: repeat(7, auto);
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--erp-line);
  border-radius: 10px;
  background: #fff;
}

.erp-stock-equation > div {
  min-width: 110px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px;
  border-radius: 7px;
  background: #f4f7fa;
  color: var(--erp-muted);
  font-size: 10px;
}

.erp-stock-equation > div strong { margin-top: 8px; color: var(--erp-ink); font-size: 25px; }
.erp-stock-equation > div.is-result { background: var(--erp-accent-soft); color: var(--erp-accent); }
.erp-stock-equation > div.is-result strong { color: var(--erp-accent); }
.erp-stock-equation > i { color: #9aa8b9; font-style: normal; font-size: 20px; }

.erp-return-rule {
  display: flex;
  align-items: center;
  gap: 13px;
  margin: 13px;
  padding: 11px 14px;
  border: 1px dashed #c9d3df;
  border-radius: 7px;
  background: #f7f9fb;
  color: var(--erp-muted);
  font-size: 10px;
}

.erp-return-rule > span { color: var(--erp-success); font-size: 22px; font-weight: 900; }

.erp-two-column {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(270px, 0.65fr);
  align-items: start;
  gap: 16px;
}

.erp-forecast-inputs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--erp-line);
}

.erp-forecast-chart {
  min-height: 280px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  padding: 22px 20px 18px;
}

.erp-forecast-chart__axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-bottom: 22px;
  color: #9aa7b7;
  font-size: 8px;
}

.erp-forecast-chart__bars {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  align-items: end;
  gap: 9px;
  position: relative;
  border-bottom: 1px solid #cbd4de;
  background: repeating-linear-gradient(to bottom, transparent 0, transparent 54px, #edf1f5 55px);
}

.erp-forecast-chart__bars > div {
  height: 210px;
  display: flex;
  flex-direction: column;
  justify-content: end;
  align-items: center;
  position: relative;
}

.erp-forecast-chart__bars i {
  width: min(34px, 70%);
  display: block;
  border-radius: 5px 5px 0 0;
  background: #9eb5cf;
}

.erp-forecast-chart__bars > div:last-child i { background: var(--erp-accent); }
.erp-forecast-chart__bars small { position: absolute; top: calc(100% + 7px); color: var(--erp-muted); font-size: 8px; white-space: nowrap; }
.erp-forecast-chart__bars strong { position: absolute; bottom: calc(var(--bar-height, 50%) + 3px); display: none; }

.erp-card--calc .erp-card__body { padding: 14px; }

.erp-replenishment-calc {
  display: grid;
  gap: 0;
}

.erp-replenishment-calc > div {
  min-height: 61px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 8px;
  border-bottom: 1px solid var(--erp-line);
  color: var(--erp-muted);
  font-size: 10px;
}

.erp-replenishment-calc > div strong { color: var(--erp-ink); font-size: 17px; }
.erp-replenishment-calc > div.is-total { margin-top: 8px; padding: 14px 12px; border: 0; border-radius: 7px; background: var(--erp-accent-soft); color: var(--erp-accent); }
.erp-replenishment-calc > div.is-total strong { color: var(--erp-accent); font-size: 27px; }

.erp-task-list {
  display: grid;
}

.erp-task-list button {
  min-height: 76px;
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr) 18px;
  align-items: center;
  gap: 11px;
  padding: 12px 17px;
  border: 0;
  border-bottom: 1px solid var(--erp-line);
  background: #fff;
  color: var(--erp-ink);
  text-align: left;
  cursor: pointer;
}

.erp-task-list button:last-child { border-bottom: 0; }
.erp-task-list button:hover { background: #f8fafc; }
.erp-task-list button div { font-size: 12px; font-weight: 750; }
.erp-task-list button small { display: block; margin-top: 5px; color: var(--erp-muted); font-size: 9px; font-weight: 500; }
.erp-task-list button > strong { color: var(--erp-accent); font-size: 18px; }

.erp-task-dot { width: 9px; height: 9px; display: block; border-radius: 50%; background: #aab5c2; }
.erp-task-dot.is-danger { background: var(--erp-danger); }
.erp-task-dot.is-warning { background: var(--erp-warning); }
.erp-task-dot.is-info { background: var(--erp-info); }

.erp-drawer-backdrop {
  z-index: 190;
  position: fixed;
  inset: 0;
  background: rgba(17, 31, 51, 0.43);
  backdrop-filter: blur(2px);
}

.erp-drawer {
  z-index: 200;
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(470px, 92vw);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  background: #fff;
  color: var(--erp-ink);
  box-shadow: -18px 0 45px rgba(18, 35, 58, 0.2);
  animation: erp-drawer-in 180ms ease both;
}

.erp-drawer > header {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--erp-line);
}

.erp-drawer > header > div > span {
  display: block;
  margin-bottom: 4px;
  color: var(--erp-accent);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.1em;
}

.erp-drawer__title { font-size: 20px; font-weight: 850; }
.erp-drawer__title > span[lang="en"] { color: var(--erp-muted); font-size: 11px; }

.erp-drawer > header > button {
  width: 40px;
  height: 40px;
  border: 1px solid var(--erp-line);
  border-radius: 7px;
  background: #fff;
  color: var(--erp-muted);
  font-size: 25px;
  cursor: pointer;
}

.erp-drawer form {
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.erp-drawer__body {
  display: grid;
  align-content: start;
  gap: 19px;
  overflow: auto;
  padding: 24px 20px;
}

.erp-drawer footer {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 9px;
  padding: 14px 20px max(14px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--erp-line);
  background: #f9fbfc;
}

.erp-form-field {
  display: grid;
  gap: 7px;
  color: var(--erp-ink);
  font-size: 12px;
  font-weight: 750;
}

.erp-form-field > .bi > span[lang="en"] { color: var(--erp-muted); font-size: 9px; }

.erp-form-field input,
.erp-form-field select {
  width: 100%;
  height: 52px;
  padding: 0 13px;
  border: 1px solid #cbd5e1;
  border-radius: 7px;
  outline: 0;
  background: #fff;
  color: var(--erp-ink);
  font-size: 16px;
  user-select: text;
}

.erp-form-field input:focus,
.erp-form-field select:focus { border-color: var(--erp-accent); }
.erp-form-field small { color: var(--erp-muted); font-size: 9px; font-weight: 500; line-height: 1.5; }

.erp-form-readonly {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid var(--erp-line);
  border-radius: 7px;
  background: #f7f9fb;
}

.erp-toast {
  z-index: 230;
  position: fixed;
  right: 26px;
  bottom: 25px;
  max-width: min(440px, calc(100vw - 40px));
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 17px;
  border: 1px solid #b9ded4;
  border-radius: 9px;
  background: #fff;
  color: var(--erp-ink);
  box-shadow: 0 12px 35px rgba(22, 44, 68, 0.2);
  animation: erp-toast-in 180ms ease both;
  font-size: 11px;
}

.erp-toast > span {
  width: 28px;
  height: 28px;
  display: grid;
  flex: 0 0 28px;
  place-content: center;
  border-radius: 50%;
  background: var(--erp-success);
  color: #fff;
  font-weight: 900;
}

.erp-toast small { display: block; margin-top: 4px; color: var(--erp-muted); font-size: 8px; }

@keyframes erp-drawer-in {
  from { transform: translateX(35px); opacity: 0; }
}

@keyframes erp-toast-in {
  from { transform: translateY(12px); opacity: 0; }
}

@media (max-width: 1250px) {
  .erp-app { grid-template-columns: 210px minmax(0, 1fr); }
  .erp-workspace { grid-template-columns: minmax(0, 1fr); }
  .erp-ai-card { position: static; display: grid; grid-template-columns: 1fr 150px 1.1fr 240px; align-items: center; gap: 13px; }
  .erp-ai-card__brand { grid-column: 1; }
  .erp-ai-card__signal { grid-column: 2; grid-row: 1; margin: 0; }
  .erp-ai-card__number { grid-column: 1; grid-row: 2 / span 2; margin: 0; }
  .erp-ai-card p { grid-column: 2 / span 2; grid-row: 2; margin: 0; }
  .erp-ai-card ul,
  .erp-ai-compare,
  .erp-ai-equation { grid-column: 2 / span 2; grid-row: 3; margin: 0; }
  .erp-ai-card .erp-button--ai { grid-column: 4; grid-row: 1 / span 3; }
  .erp-ai-card__foot { display: none; }
  .erp-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .erp-two-column { grid-template-columns: 1fr; }
  .erp-story-banner { grid-template-columns: 1fr; }
  .erp-story-banner__flow { padding-top: 10px; padding-left: 0; border-top: 1px solid var(--erp-line); border-left: 0; }
}

@media (max-width: 980px) {
  .erp-app { grid-template-columns: 76px minmax(0, 1fr); }
  .erp-sidebar { padding-inline: 8px; }
  .erp-brand { justify-content: center; padding-inline: 0; }
  .erp-brand > div,
  .erp-nav-label,
  .erp-nav__label,
  .erp-sidebar__foot > div { display: none; }
  .erp-case-switcher { grid-template-columns: 1fr; margin-block: 12px; }
  .erp-case-switcher__item { min-height: 44px; }
  .erp-case-switcher__item .bi > span:first-child { display: none; }
  .erp-case-switcher__item .bi > span[lang="en"] { margin: 0; font-size: 9px; }
  .erp-nav__item { grid-template-columns: 1fr; justify-items: center; padding-inline: 4px; }
  .erp-nav__icon { font-size: 20px; }
  .erp-sidebar__foot { justify-content: center; padding-inline: 0; }
  .erp-search { display: none; }
  .erp-breadcrumb { margin-right: auto; }
  .erp-content { padding-inline: 18px; }
  .erp-workflow { overflow-x: auto; }
  .erp-workflow__step { min-width: 130px; }
  .erp-ai-card { display: block; }
  .erp-ai-card__signal,
  .erp-ai-card__number,
  .erp-ai-card p,
  .erp-ai-card ul,
  .erp-ai-compare,
  .erp-ai-equation,
  .erp-ai-card .erp-button--ai { margin-top: 13px; }
  .erp-ai-card__foot { display: block; }
  .erp-field-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .erp-stock-equation { grid-template-columns: 1fr auto 1fr; overflow-x: auto; justify-content: start; }
  .erp-stock-equation > div { min-width: 150px; }
  .erp-stock-equation > div:nth-of-type(3),
  .erp-stock-equation > div:nth-of-type(4),
  .erp-stock-equation > i:nth-of-type(3) { display: none; }
}

@media (max-width: 700px) {
  .erp-app { grid-template-columns: 62px minmax(0, 1fr); }
  .erp-sidebar { padding-inline: 5px; }
  .erp-brand img { width: 38px; height: 38px; }
  .erp-main { grid-template-rows: 61px minmax(0, 1fr); }
  .erp-topbar { gap: 9px; padding: 8px 11px; }
  .erp-breadcrumb { min-width: 0; flex: 1; overflow: hidden; }
  .erp-breadcrumb .bi { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .erp-site,
  .erp-user { display: none; }
  .erp-button--back { min-width: 97px; padding-inline: 7px; }
  .erp-content { padding: 16px 11px 28px; }
  .erp-story-banner { gap: 10px; margin-bottom: 12px; padding: 12px; }
  .erp-story-banner__flow { padding-top: 9px; }
  .erp-story-question { font-size: 14px; }
  .erp-page-head { min-height: 0; align-items: end; }
  .erp-page-head > .erp-button { display: none; }
  .erp-page-head h1 .bi { font-size: 22px; }
  .erp-page-head p > .bi:first-child { display: none; }
  .erp-workflow { grid-template-columns: repeat(5, 120px); margin-bottom: 12px; padding: 10px; }
  .erp-kpi-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .erp-kpi { min-height: 112px; padding: 13px; }
  .erp-kpi > strong { font-size: 21px; }
  .erp-card__head { align-items: flex-start; }
  .erp-card__head > .erp-button { min-height: 40px; padding-inline: 8px; }
  .erp-document-grid { grid-template-columns: 1fr; }
  .erp-document-total { border-top: 1px solid var(--erp-line); border-left: 0; }
  .erp-field-grid { grid-template-columns: 1fr 1fr; padding-inline: 7px; }
  .erp-field { padding: 9px; }
  .erp-inline-summary { grid-template-columns: 1fr 1fr; gap: 7px; }
  .erp-process-board { grid-template-columns: 1fr 1fr; }
  .erp-size-matrix { overflow-x: auto; }
  .erp-size-matrix__head,
  .erp-size-matrix__row { min-width: 620px; }
  .erp-forecast-inputs { grid-template-columns: 1fr 1fr; }
  .erp-toast { right: 12px; bottom: 12px; }
}
