:root {
  color-scheme: light;
  --bg: #f5f7fb;
  --panel: #ffffff;
  --text: #172033;
  --muted: #6b778c;
  --line: #dde4ef;
  --blue: #1f6feb;
  --green: #168a5b;
  --red: #c9392f;
  --amber: #b76e00;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px 1fr;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, "Microsoft YaHei", sans-serif;
}

body[data-view="analysis"] {
  grid-template-columns: 260px minmax(0, 1fr);
}

body.front-locked {
  overflow: hidden;
}

.login-device-action {
  justify-self: end;
  width: max-content;
  min-height: 28px;
  height: 28px;
  padding: 0 2px;
  border: 0;
  background: transparent;
  color: #667085;
  font-size: 12px;
  font-weight: 600;
  box-shadow: none;
}

.login-device-action:hover {
  background: transparent;
  color: #344054;
  text-decoration: underline;
}

.device-unbind-dialog {
  width: min(760px, calc(100vw - 32px));
  max-height: min(820px, calc(100vh - 32px));
  padding: 0;
  border: 1px solid #dce4f0;
  border-radius: 8px;
  background: #fff;
  color: #172033;
  box-shadow: 0 24px 70px rgba(27, 39, 61, 0.22);
  overflow: hidden;
}

.device-unbind-dialog::backdrop {
  background: rgba(20, 30, 48, 0.34);
  backdrop-filter: blur(8px);
}

.device-unbind-shell {
  display: grid;
  max-height: min(820px, calc(100vh - 32px));
  overflow: auto;
}

.device-unbind-shell > header {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px;
  border-bottom: 1px solid #e8edf5;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
}

.device-unbind-shell > header span,
.device-unbind-shell > header h2 {
  display: block;
  margin: 0;
  letter-spacing: 0;
}

.device-unbind-shell > header span {
  color: #2563eb;
  font-size: 12px;
  font-weight: 800;
}

.device-unbind-shell > header h2 {
  margin-top: 4px;
  font-size: 22px;
}

.device-unbind-root {
  display: grid;
  gap: 0;
}

.device-unbind-overview {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: #e8edf5;
  border-bottom: 1px solid #e8edf5;
}

.device-unbind-overview > div {
  min-width: 0;
  padding: 18px 20px;
  background: #f8faff;
}

.device-unbind-overview span,
.device-unbind-overview strong {
  display: block;
  overflow-wrap: anywhere;
}

.device-unbind-overview span {
  color: #667085;
  font-size: 12px;
}

.device-unbind-overview strong {
  margin-top: 7px;
  font-size: 19px;
}

.device-unbind-section {
  display: grid;
  gap: 14px;
  padding: 22px 24px;
  border-bottom: 1px solid #edf1f6;
}

.device-unbind-heading h3,
.device-unbind-heading p {
  margin: 0;
  letter-spacing: 0;
}

.device-unbind-heading h3 {
  font-size: 16px;
}

.device-unbind-heading p {
  margin-top: 5px;
  color: #667085;
  font-size: 13px;
  line-height: 1.55;
}

.bound-device-card,
.device-unbind-history article {
  display: grid;
  align-items: center;
  gap: 14px;
  padding: 15px;
  border: 1px solid #e1e7f0;
  border-radius: 8px;
  background: #fff;
}

.bound-device-card {
  grid-template-columns: 42px minmax(0, 1fr) auto;
}

.bound-device-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #edf4ff;
  color: #2563eb;
  font-size: 12px;
  font-weight: 900;
}

.bound-device-card strong,
.bound-device-card span,
.bound-device-card small,
.device-unbind-history strong,
.device-unbind-history span,
.device-unbind-history small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.bound-device-card span,
.bound-device-card small,
.device-unbind-history span,
.device-unbind-history small {
  margin-top: 4px;
  color: #667085;
  font-size: 12px;
}

.device-state-chip,
.device-request-status {
  width: max-content;
  padding: 5px 8px;
  border-radius: 6px;
  background: #eaf8f0;
  color: #147a4b !important;
  font-size: 12px;
  font-weight: 800;
}

.device-pending-callout {
  padding: 13px 15px;
  border-left: 3px solid #f59e0b;
  background: #fff9eb;
}

.device-pending-callout strong,
.device-pending-callout span {
  display: block;
}

.device-pending-callout span {
  margin-top: 4px;
  color: #7a5b16;
  font-size: 13px;
}

.device-unbind-reason {
  display: grid;
  gap: 7px;
  color: #344054;
  font-size: 13px;
  font-weight: 700;
}

.device-unbind-reason textarea {
  width: 100%;
  resize: vertical;
  border: 1px solid #d6deea;
  border-radius: 8px;
  padding: 11px 12px;
  color: #172033;
  background: #fff;
  font: inherit;
  line-height: 1.5;
}

.device-unbind-history {
  display: grid;
  gap: 9px;
}

.device-unbind-history article {
  grid-template-columns: 74px minmax(0, 1fr);
}

.device-request-status.pending {
  background: #fff4dc;
  color: #9a6700 !important;
}

.device-request-status.approved {
  background: #eaf8f0;
  color: #147a4b !important;
}

.device-request-status.rejected {
  background: #fff0f0;
  color: #b42318 !important;
}

.device-unbind-empty {
  padding: 20px;
  border: 1px dashed #d6deea;
  border-radius: 8px;
  color: #667085;
  text-align: center;
}

@media (max-width: 640px) {
  .device-unbind-overview {
    grid-template-columns: 1fr;
  }

  .bound-device-card {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .bound-device-card .device-state-chip {
    grid-column: 2;
  }

  .device-unbind-history article {
    grid-template-columns: 1fr;
  }
}

.front-login-gate,
.admin-login-gate {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: block;
  overflow: auto;
  background: #f7f9fd;
}

.front-login-gate[hidden],
.admin-login-gate[hidden] {
  display: none !important;
}

.login-stage {
  width: 100%;
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.16fr) minmax(420px, 0.84fr);
  background: #fff;
}

.login-showcase {
  position: relative;
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 24px;
  padding: clamp(24px, 3vw, 42px);
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(31, 111, 235, 0.055) 1px, transparent 1px),
    linear-gradient(180deg, rgba(31, 111, 235, 0.045) 1px, transparent 1px),
    linear-gradient(135deg, #f8fbff 0%, #e9f3ff 56%, #f6f8fc 100%);
  background-size: 44px 44px, 44px 44px, auto;
}

.login-showcase::after {
  content: '';
  position: absolute;
  inset: auto 0 0 auto;
  width: 42%;
  height: 100%;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.48));
  pointer-events: none;
}

.login-brandline {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: #223049;
  font-weight: 800;
}

.login-brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(135deg, #7c4dff 0%, #1f6feb 50%, #15b8a6 100%);
  box-shadow: 0 12px 28px rgba(31, 111, 235, 0.22);
  overflow: hidden;
  background: #fff;
  border: 1px solid #dfe7f3;
}

.login-brand-mark img,
.mark img,
.admin-mark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.login-visual {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  min-height: 340px;
}

.login-illustration {
  position: relative;
  width: min(430px, 72vw);
  aspect-ratio: 1.2;
  transform: translateY(8px);
}

.login-illustration span {
  position: absolute;
  display: block;
}

.visual-platform {
  left: 19%;
  right: 16%;
  bottom: 14%;
  height: 27%;
  border: 1px solid rgba(37, 99, 235, 0.28);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.95), rgba(219,236,255,0.9)),
    linear-gradient(135deg, #1f6feb, #15b8a6);
  box-shadow:
    0 24px 40px rgba(31, 111, 235, 0.20),
    inset 0 -14px 0 rgba(31, 111, 235, 0.14);
  transform: skewY(-8deg) rotate(-1deg);
}

.visual-platform::before {
  content: '';
  position: absolute;
  inset: 18% 14%;
  border-radius: 8px;
  border: 1px solid rgba(31, 111, 235, 0.16);
  background: rgba(255,255,255,0.55);
}

.visual-panel {
  width: 25%;
  height: 30%;
  border: 1px solid rgba(31, 111, 235, 0.24);
  border-radius: 8px;
  background: linear-gradient(145deg, #ffffff, #d7ebff);
  box-shadow: 0 16px 34px rgba(40, 70, 120, 0.14);
}

.visual-panel::before {
  content: '';
  position: absolute;
  left: 12%;
  right: 12%;
  top: 20%;
  height: 8px;
  border-radius: 8px;
  background: #1f6feb;
  box-shadow: 0 20px 0 #15b8a6, 0 40px 0 #f59e0b;
}

.panel-left {
  left: 22%;
  top: 30%;
  transform: perspective(420px) rotateY(28deg) rotateZ(-5deg);
}

.panel-right {
  right: 12%;
  top: 24%;
  width: 28%;
  height: 34%;
  transform: perspective(420px) rotateY(-28deg) rotateZ(4deg);
}

.panel-top {
  left: 43%;
  top: 13%;
  width: 22%;
  height: 20%;
  transform: rotate(8deg);
}

.visual-tower {
  bottom: 29%;
  border-radius: 8px 8px 3px 3px;
  box-shadow: 0 12px 22px rgba(23, 32, 51, 0.16);
}

.tower-main {
  left: 46%;
  width: 12%;
  height: 33%;
  background: linear-gradient(180deg, #1f6feb, #173d9b);
}

.tower-main::before {
  content: '';
  position: absolute;
  left: -54%;
  right: -54%;
  bottom: -8px;
  height: 20px;
  border-radius: 8px;
  background: linear-gradient(135deg, #dff1ff, #80c8ff);
}

.tower-side {
  left: 36%;
  width: 7%;
  height: 23%;
  background: linear-gradient(180deg, #15b8a6, #0d9488);
}

.visual-box {
  width: 12%;
  height: 12%;
  border-radius: 6px;
  background: linear-gradient(135deg, #ffffff, #ffd79c);
  border: 1px solid rgba(245, 158, 11, 0.25);
  box-shadow: 0 12px 18px rgba(120, 70, 10, 0.12);
}

.box-one {
  left: 25%;
  bottom: 26%;
  transform: skewY(-8deg);
}

.box-two {
  right: 24%;
  bottom: 31%;
  transform: skewY(8deg);
}

.visual-route {
  height: 3px;
  border-radius: 8px;
  background: linear-gradient(90deg, rgba(31, 111, 235, 0.05), rgba(31, 111, 235, 0.9), rgba(21, 184, 166, 0.1));
  box-shadow: 0 0 0 1px rgba(255,255,255,0.55);
}

.route-one {
  left: 20%;
  right: 18%;
  bottom: 49%;
  transform: rotate(-8deg);
}

.route-two {
  left: 31%;
  right: 24%;
  top: 49%;
  transform: rotate(11deg);
}

.login-copy {
  position: relative;
  z-index: 1;
  width: min(520px, 100%);
  justify-self: center;
  padding-bottom: clamp(12px, 4vw, 52px);
  text-align: center;
}

.login-copy h2 {
  font-size: clamp(22px, 2vw, 30px);
  color: #223049;
}

.login-copy p {
  max-width: 460px;
  margin: 10px auto 0;
  color: #64748b;
  line-height: 1.7;
}

.login-auth-side {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: clamp(24px, 5vw, 70px);
  background: #ffffff;
}

.login-card,
.front-login-card {
  width: min(420px, 100%);
  display: grid;
  gap: 18px;
  border: 0;
  border-radius: 8px;
  background: #fff;
  padding: 0;
  box-shadow: none;
}

.login-heading {
  display: grid;
  gap: 8px;
}

.login-heading span {
  color: #1f6feb;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.login-heading h1 {
  font-size: clamp(30px, 3vw, 42px);
  color: #172033;
}

.login-heading p {
  color: var(--muted);
  line-height: 1.6;
}

.front-login-form,
.login-form {
  display: grid;
  gap: 12px;
}

.front-auth-tabs,
.forwarder-auth-tabs,
.login-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  padding: 5px;
  border: 1px solid #dfe7f3;
  border-radius: 8px;
  background: #f6f8fc;
}

.front-auth-tabs button,
.forwarder-auth-tabs button,
.login-tabs button {
  color: #475569;
  background: transparent;
  box-shadow: none;
}

.front-auth-tabs button.active,
.forwarder-auth-tabs button.active,
.login-tabs button.active {
  color: #fff;
  background: #1f6feb;
  box-shadow: 0 8px 18px rgba(31, 111, 235, 0.22);
}

.login-field {
  display: grid;
  gap: 7px;
  color: #475569;
  font-size: 13px;
  font-weight: 700;
}

.login-field input,
.front-login-form input,
.admin-login-card input,
.forwarder-single-auth-form input {
  width: 100%;
  height: 44px;
  border: 1px solid #dfe7f3;
  border-radius: 8px;
  padding: 0 13px;
  color: #172033;
  background: #fbfcff;
  outline: none;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.login-field input:focus,
.front-login-form input:focus,
.admin-login-card input:focus,
.forwarder-single-auth-form input:focus {
  border-color: #1f6feb;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(31, 111, 235, 0.11);
}

.login-primary {
  width: 100%;
  height: 44px;
  border-radius: 8px;
  font-weight: 800;
  background: linear-gradient(135deg, #1f6feb, #0f7be8);
  box-shadow: 0 13px 22px rgba(31, 111, 235, 0.22);
}

.front-login-message {
  min-height: 20px;
  color: var(--red);
  font-size: 12px;
}

.front-register-agent-hint {
  display: block;
  min-height: 16px;
  color: #21705c;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.45;
}

.front-login-form input.invite-code-locked {
  border-color: #badbce;
  color: #145b49;
  background: #f2faf7;
  font-weight: 750;
  cursor: default;
}

.login-message {
  margin-top: -4px;
}

.login-links {
  display: flex;
  justify-content: center;
  gap: 18px;
  color: var(--muted);
  font-size: 13px;
}

.login-links a {
  color: #1f6feb;
  text-decoration: none;
}

.login-links a:hover {
  text-decoration: underline;
}

.front-activation-dialog {
  width: min(380px, calc(100vw - 32px));
  padding: 0;
  border: 1px solid #dce4f0;
  border-radius: 12px;
  background: #fff;
  color: var(--text);
  box-shadow: 0 24px 70px rgba(27, 39, 61, 0.22);
}

.front-activation-dialog::backdrop {
  background: rgba(20, 30, 48, 0.34);
  backdrop-filter: blur(8px);
}

.front-activation-form {
  display: grid;
  gap: 14px;
  padding: 22px;
}

.front-activation-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.front-activation-heading span {
  color: #1f6feb;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.front-activation-heading h2 {
  margin: 5px 0 0;
  color: #172033;
  font-size: 22px;
}

.front-activation-intro {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

@media (max-width: 980px) {
  .login-stage,
  .forwarder-auth-unified.login-embedded {
    grid-template-columns: 1fr;
  }

  .login-showcase {
    min-height: 44vh;
    padding: 22px;
  }

  .login-visual {
    min-height: 240px;
  }

  .login-illustration {
    width: min(330px, 86vw);
  }

  .login-copy {
    padding-bottom: 8px;
  }

  .login-auth-side {
    min-height: auto;
    padding: 28px 20px 38px;
  }

  .forwarder-auth-unified.login-embedded {
    min-height: auto;
  }
}

@media (max-width: 620px) {
  .login-showcase {
    min-height: 34vh;
  }

  .login-visual {
    min-height: 190px;
  }

  .login-copy h2 {
    font-size: 22px;
  }

  .login-copy p {
    font-size: 13px;
  }

  .forwarder-auth-unified.login-embedded .forwarder-code-row {
    grid-template-columns: 1fr;
  }
}

.front-account-block {
  gap: 8px;
}

.front-account-block button {
  width: 100%;
  height: 32px;
  font-size: 12px;
}

body.forwarder-page {
  display: block;
}

.forwarder-shell {
  width: min(1320px, calc(100% - 32px));
  margin: 0 auto;
  padding: 20px 0 28px;
}

.forwarder-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.forwarder-top-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.forwarder-main {
  min-width: 0;
}

.forwarder-login-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.forwarder-auth-card {
  align-items: flex-start;
}

.forwarder-auth-unified {
  display: grid;
  grid-template-columns: minmax(220px, 320px) minmax(0, 1fr);
  align-items: flex-start;
}

.forwarder-auth-box {
  display: grid;
  gap: 10px;
  width: 100%;
}

.forwarder-auth-tabs {
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(90px, 1fr));
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafd;
}

.forwarder-auth-tabs button {
  color: var(--text);
  background: transparent;
}

.forwarder-auth-tabs button.active {
  color: #fff;
  background: var(--blue);
}

.forwarder-auth-card .product-login-form {
  justify-content: flex-start;
}

.forwarder-single-auth-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)) auto;
  align-items: center;
}

.forwarder-single-auth-form input {
  width: 100%;
}

.forwarder-code-row {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(130px, auto) minmax(150px, 1fr) auto;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  font-size: 12px;
}

.forwarder-code-row strong {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  margin-left: 6px;
  padding: 0 8px;
  border-radius: 6px;
  color: var(--text);
  background: #eef2f8;
  letter-spacing: 1px;
}

.forwarder-auth-unified.login-embedded {
  min-height: calc(100vh - 156px);
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(390px, 0.92fr);
  align-items: stretch;
  overflow: hidden;
  border: 1px solid #dfe7f3;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 48px rgba(23, 32, 51, 0.08);
}

.forwarder-auth-unified.login-embedded .login-showcase,
.forwarder-auth-unified.login-embedded .login-auth-side {
  min-height: auto;
}

.forwarder-auth-unified.login-embedded .login-auth-side {
  align-content: center;
}

.forwarder-auth-unified.login-embedded .forwarder-auth-box {
  gap: 18px;
}

.forwarder-auth-unified.login-embedded .forwarder-auth-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  padding: 5px;
  border-color: #dfe7f3;
  background: #f6f8fc;
}

.forwarder-auth-unified.login-embedded .forwarder-single-auth-form {
  display: grid;
  grid-template-columns: 1fr;
  align-items: stretch;
}

.forwarder-auth-unified.login-embedded .login-field input,
.forwarder-auth-unified.login-embedded .forwarder-code-row input {
  height: 44px;
  border-color: #dfe7f3;
  border-radius: 8px;
  background: #fbfcff;
}

.forwarder-auth-unified.login-embedded .product-login-form {
  justify-content: stretch;
}

.forwarder-auth-unified.login-embedded .forwarder-code-row {
  grid-template-columns: 1fr minmax(120px, 1fr) auto;
  padding-top: 2px;
}

.forwarder-message {
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
  font-size: 13px;
}

.forwarder-message.ok {
  border-color: #b9e7d2;
  color: var(--green);
  background: #f0fbf6;
}

.forwarder-message.bad {
  border-color: #f2c0bc;
  color: var(--red);
  background: #fff4f3;
}

.sidebar {
  border-right: 1px solid var(--line);
  background: #ffffff;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.brand {
  display: flex;
  gap: 12px;
  align-items: center;
}

.mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: #172033;
  font-weight: 700;
  overflow: hidden;
  border: 1px solid #dfe7f3;
  background: #fff;
}

h1, h2, h3, p { margin: 0; }

.brand h1 { font-size: 18px; }
.brand p { margin-top: 4px; color: var(--muted); font-size: 12px; }

.nav-list { flex: 1; display: flex; flex-direction: column; gap: 16px; }


.nav-group { display: grid; gap: 6px; }
.nav-group > span { color: var(--muted); font-size: 12px; padding: 0 10px; }
.nav-settings { margin-top: auto; }

.nav {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 38px;
  border: 0;
  border-radius: 6px;
  padding: 0 12px;
  text-align: left;
  color: var(--text);
  background: transparent;
  cursor: pointer;
  transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.nav-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: .86;
}

.nav:hover { background: #f3f6fb; transform: translateX(2px); }
.nav.active { color: #fff; background: var(--blue); }
.nav.active .nav-icon { opacity: 1; }
.nav:focus-visible { outline: 2px solid rgba(31, 111, 235, .45); outline-offset: 2px; }

.status-block {
  margin-top: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 6px;
}

.status-block span { color: var(--muted); font-size: 12px; }
.status-block strong { font-size: 14px; }

main { min-width: 0; padding: 22px; }

body[data-view="products"] main {
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

body[data-view="analysis"] main {
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 12px 16px 96px;
}

.toolbar {
  display: flex;
  gap: 16px;
  align-items: center;
  margin-bottom: 18px;
}

.toolbar h2 { font-size: 24px; }
.toolbar p { margin-top: 6px; color: var(--muted); }

.toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

body[data-view="box"] #boxActions {
  position: sticky;
  top: 8px;
  z-index: 74;
  padding: 6px 8px;
  margin-bottom: 10px;
  border: 1px solid #dbe2ea;
  border-radius: 10px;
  background: rgba(247, 248, 250, 0.96);
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.06);
}

.capture-queue-toolbar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 4px 6px;
  border: 1px solid #e0e6ee;
  border-radius: 8px;
  background: #fff;
}

body:not([data-view="box"]) .capture-queue-toolbar {
  display: none;
}

body[data-view="analysis"] .toolbar {
  gap: 10px;
  align-items: center;
  min-height: 42px;
  margin-bottom: 8px;
  padding: 6px 10px 6px 14px;
}

body[data-view="analysis"].ui-skin-ai-cockpit .toolbar,
body[data-view="analysis"].ui-skin-cockpit .toolbar,
body[data-view="analysis"].ui-skin-pipeline .toolbar {
  padding: 6px 10px 6px 14px;
  border-radius: 8px;
}

body[data-view="analysis"] .toolbar > div:first-child {
  display: grid;
  grid-template-columns: auto minmax(220px, 1fr);
  gap: 8px;
  align-items: baseline;
  min-width: 0;
  flex: 1 1 auto;
}

body[data-view="analysis"] .toolbar h2 {
  font-size: 18px;
  line-height: 1.2;
  white-space: nowrap;
}

body[data-view="analysis"] .toolbar p {
  overflow: hidden;
  margin-top: 0;
  font-size: 11px;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body[data-view="analysis"] .toolbar-actions {
  flex: 0 0 auto;
  gap: 6px;
}

body[data-view="analysis"] .toolbar-actions input[type="search"] {
  width: min(238px, 24vw);
  height: 30px;
}

body[data-view="analysis"] .toolbar-actions button {
  min-width: 56px;
  height: 30px;
  padding: 0 11px;
  white-space: nowrap;
}

input, button { font: inherit; }

input[type="search"], input[type="number"], select {
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 10px;
  background: #fff;
}

button {
  height: 36px;
  border: 0;
  border-radius: 6px;
  padding: 0 12px;
  background: var(--blue);
  color: #fff;
  cursor: pointer;
}

button:disabled {
  background: #b8c2d3;
  cursor: not-allowed;
}

button.secondary { color: var(--text); background: #eef2f8; }

.button-link {
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  padding: 0 10px;
  color: #fff;
  background: var(--blue);
  font-size: 12px;
  text-decoration: none;
}

.button-link.secondary {
  color: var(--text);
  background: #eef2f8;
}

.view { display: none; }
.view.active { display: block; }

#analysisView.view.active {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

#productsView.view.active {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.listing-workbench {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 0;
}

.listing-stage-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 0;
}

body[data-view="image"] main {
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 12px 16px 16px;
}

body[data-view="image"] .toolbar {
  margin-bottom: 10px;
}

.listing-workbench-view.active {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.listing-workbench {
  flex: 1 1 auto;
  min-height: 0;
}

.listing-stage-section {
  flex: 1 1 auto;
  min-height: 0;
}

#imageList {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  gap: 12px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0 6px 10px 0;
  scrollbar-gutter: stable;
}

#imageList > .batch-bar {
  flex: 0 0 auto;
  position: sticky;
  top: 0;
  z-index: 8;
}

#imageList > .product-card {
  flex: 0 0 auto;
  width: 100%;
}

.listing-stage-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 34px;
  padding: 0 2px;
}

.listing-stage-head > div {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
}

.listing-stage-head strong {
  color: var(--text);
  font-size: 15px;
}

.listing-stage-head span {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.stats div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 14px;
}

.stats span { color: var(--muted); font-size: 12px; }
.stats strong { display: block; margin-top: 8px; font-size: 26px; }

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

.module-card {
  height: 122px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  display: grid;
  align-content: start;
  gap: 8px;
  color: var(--text);
  background: var(--panel);
  text-align: left;
}

.module-card:hover { border-color: #9db9ee; background: #f9fbff; }
.module-card strong { font-size: 16px; }
.module-card span { color: var(--muted); font-size: 13px; line-height: 1.5; }

.section-head {
  margin-bottom: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.section-head h3 { font-size: 18px; }
.section-head p { margin-top: 6px; color: var(--muted); }

.list { display: grid; gap: 12px; }

.batch-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.batch-bar > div:first-child {
  display: grid;
  gap: 3px;
}

.batch-bar span {
  color: var(--muted);
  font-size: 12px;
}

.batch-actions, .sku-bulk-bar > div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.batch-actions button, .sku-bulk-bar button {
  height: 30px;
  padding: 0 10px;
  font-size: 12px;
}



.product-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  overflow: hidden;
}

.product-summary {
  display: grid;
  grid-template-columns: 22px 32px 72px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 8px 10px;
}

.checked-card .product-summary {
  grid-template-columns: 22px 32px 72px minmax(0, 1fr) minmax(360px, 0.9fr);
}

.product-pricing-slot {
  min-width: 0;
  align-self: stretch;
  display: grid;
  align-items: start;
}

.product-no {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  color: #fff;
  background: #172033;
  font-weight: 700;
  font-size: 13px;
}

.product-checkbox, .sku-checkbox {
  width: 16px;
  height: 16px;
  margin: 6px 0 0;
  accent-color: var(--blue);
}

.product-select-spacer, .sku-index-spacer {
  width: 16px;
  height: 16px;
}

.product-info { min-width: 0; }
.product-info h3 {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-size: 14px;
  line-height: 1.3;
}

.card {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 12px;
}

.thumb {
  width: 72px;
  height: 72px;
  border: 1px solid var(--line);
  border-radius: 6px;
  object-fit: cover;
  background: #eef2f8;
}

.card h3 { font-size: 16px; line-height: 1.35; }

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 5px 0;
  color: var(--muted);
  font-size: 12px;
}

.detail-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 5px 0;
  color: #33415c;
  font-size: 12px;
}

.source-detail-line {
  align-items: center;
}

.source-detail-line .detail-title-text {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.source-detail-line .source-check-link {
  color: #0b63ce;
  font-weight: 800;
  white-space: nowrap;
}

.analysis-card .source-detail-line span:last-child,
.image-card .source-detail-line span:last-child {
  flex: 0 0 auto;
}

.category-match-summary {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto auto;
  gap: 6px 10px;
  align-items: center;
  margin: 6px 0;
  padding: 7px 9px;
  border: 1px solid #d8e8fb;
  border-left: 4px solid var(--blue);
  border-radius: 8px;
  background: #f7fbff;
  font-size: 12px;
}

.category-match-summary.compact {
  max-width: 760px;
}

.category-match-summary.ok {
  border-color: #b9e7d2;
  border-left-color: var(--green);
  background: #f0fbf6;
}

.category-match-summary.warn {
  border-color: #f5c56a;
  border-left-color: #f59e0b;
  background: #fffaf0;
}

.category-match-summary.bad {
  border-color: #f2c0bc;
  border-left-color: var(--red);
  background: #fff4f3;
}

.category-match-summary > div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.category-match-summary strong,
.category-match-summary span,
.category-match-summary small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-match-summary strong {
  color: #172033;
}

.category-link-button {
  overflow: hidden;
  height: auto;
  min-width: 0;
  justify-content: flex-start;
  padding: 0;
  color: #344054;
  background: transparent;
  font-size: 12px;
  font-weight: 800;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-link-button:hover {
  color: #111827;
  background: transparent;
  text-decoration: underline;
}

.category-match-summary span,
.category-match-summary small,
.category-match-summary em {
  color: var(--muted);
  font-style: normal;
}

.category-score {
  display: grid;
  gap: 4px;
  min-width: 140px;
}

.category-score-track {
  overflow: hidden;
  display: block;
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: #e5edf7;
}

.category-score-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--blue);
}

.category-match-summary.ok .category-score-track i {
  background: var(--green);
}

.category-match-summary.warn .category-score-track i {
  background: #f59e0b;
}

.category-match-summary.bad .category-score-track i,
.category-match-summary.todo .category-score-track i {
  background: var(--red);
}

.category-match-summary b {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0 8px;
  color: #17663e;
  background: #dcfce7;
  font-size: 11px;
}

.category-match-summary.bad b {
  color: #b42318;
  background: #fee4e2;
}

.category-match-summary.warn b {
  color: #8a4b08;
  background: #fff0c2;
}

.category-match-summary small {
  grid-column: 1 / -1;
}

.category-commission-line {
  color: #17663e;
}

.category-review-line {
  color: #9f2f24;
  font-weight: 700;
}

.commission-readonly.category-commission-hit {
  border-color: #b9e7d2;
  background: #f0fbf6;
}

.commission-readonly.category-commission-hit strong,
.commission-readonly.category-commission-hit small {
  color: #17663e;
}

.commission-readonly.category-commission-manual {
  border-color: #f5c56a;
  background: #fffaf0;
}

.commission-readonly.category-commission-manual strong,
.commission-readonly.category-commission-manual small {
  color: #8a4b08;
}

.category-match-tokens {
  color: #52627a;
}

.sku-strip {
  display: grid;
  gap: 6px;
  margin-top: 8px;
}

.sku-chip {
  display: grid;
  grid-template-columns: 34px minmax(160px, 1fr) auto auto auto;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 4px 8px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fafcff;
  font-size: 12px;
}

.sku-thumb {
  width: 32px;
  height: 32px;
  border-radius: 5px;
  object-fit: cover;
  border: 1px solid var(--line);
}

.image-placeholder {
  display: grid;
  place-items: center;
  color: var(--muted);
  background: #eef2f8;
  font-size: 12px;
}

.image-error {
  color: transparent;
  background: repeating-linear-gradient(135deg, #eef2f8, #eef2f8 8px, #f8fafc 8px, #f8fafc 16px);
}

.sku-chip span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sku-chip strong {
  color: var(--blue);
}

.sku-chip small {
  color: var(--muted);
  white-space: nowrap;
}

.sku-more {
  color: var(--muted);
  font-size: 12px;
}

.sku-panel-box {
  display: grid;
  gap: 6px;
  padding: 8px 10px 10px 146px;
  border-top: 1px solid var(--line);
  background: #fbfcff;
}

.sku-panel-box[hidden] { display: none; }

.sku-bulk-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 38px;
  padding: 6px 8px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
}

.sku-bulk-bar strong {
  font-size: 12px;
}

.sku-row-detail {
  display: grid;
  grid-template-columns: 18px 24px 42px minmax(180px, 1fr) minmax(180px, 1.1fr) 86px 96px;
  gap: 8px;
  align-items: center;
  min-height: 52px;
  padding: 6px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
}

.sku-index {
  color: var(--muted);
  font-weight: 700;
  text-align: center;
}

.sku-thumb-large {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  object-fit: cover;
  background: #eef2f8;
}

.sku-reference-thumb {
  position: relative;
  width: max-content;
  max-width: 100%;
}

.sku-reference-thumb em {
  position: absolute;
  right: 2px;
  bottom: 2px;
  max-width: calc(100% - 4px);
  padding: 1px 3px;
  border-radius: 4px;
  background: rgba(17, 24, 39, 0.72);
  color: #fff;
  font-size: 9px;
  font-style: normal;
  line-height: 1.2;
  white-space: nowrap;
}

.sku-main, .sku-data {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.sku-main strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.sku-main span, .sku-data span {
  color: var(--muted);
  font-size: 12px;
}

.sku-data strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #33415c;
  font-size: 12px;
}

.sku-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
  min-width: 0;
}

.sku-actions button {
  height: 28px;
  padding: 0 10px;
  font-size: 12px;
}

.sku-state {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  height: 24px;
  border-radius: 999px;
  font-size: 12px;
}

.sku-state.ok {
  color: var(--green);
  background: #e8f6ef;
}

.badge {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: #eef2f8;
  color: #33415c;
  font-size: 12px;
}

.badge.ok { color: var(--green); background: #e8f6ef; }
.badge.warn { color: var(--amber); background: #fff4dc; }
.badge.bad { color: var(--red); background: #fdecea; }
.badge.muted { color: #64748b; background: #eef2f7; }

.price-box {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 8px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  align-content: start;
  background: #f8fafd;
}

.price-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  min-height: 22px;
}

.price-row span { color: var(--muted); font-size: 12px; white-space: nowrap; }
.price-row strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #33415c;
  font-size: 12px;
}
.price-row.main strong { color: var(--blue); font-size: 15px; }
.price-row.muted strong { color: var(--muted); font-weight: 500; }

.pricing-summary {
  display: grid;
  gap: 8px;
  margin: 0 10px 10px 136px;
  padding: 10px;
  border: 1px solid #d8e8fb;
  border-radius: 8px;
  background: #f7fbff;
}

.pricing-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.pricing-title strong { font-size: 13px; }
.pricing-title span { color: var(--muted); font-size: 12px; }

.pricing-compact {
  display: grid;
  grid-template-columns: repeat(6, minmax(82px, 1fr)) auto;
  gap: 6px;
  align-items: center;
  padding: 6px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
  font-size: 12px;
}

.product-pricing-slot .pricing-compact {
  height: 100%;
  grid-template-columns: repeat(6, minmax(0, 1fr)) auto;
  align-content: center;
  background: #fbfdff;
}

.pricing-compact.readonly {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  background: #fbfdff;
}

.pricing-compact.readonly.with-listing {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.pricing-compact.empty-price {
  grid-template-columns: 1fr;
  color: var(--muted);
}

.pricing-compact.empty-price.error {
  color: var(--red);
  border-color: #f2c4c0;
  background: #fff7f6;
}

.pricing-compact span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-compact .pricing-pill {
  display: grid;
  gap: 2px;
  min-height: 38px;
  align-content: center;
  padding: 5px 7px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
}

.pricing-compact .pricing-pill em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  line-height: 1;
}

.pricing-compact .pricing-pill b {
  min-width: 0;
  overflow: hidden;
  color: #26344d;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.18;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-compact .pricing-pill.profit b { color: #157347; }
.pricing-compact.readonly .pricing-pill.logistics { grid-column: span 2; }
.pricing-compact.readonly.with-listing .pricing-pill.logistics { grid-column: auto; }

.pricing-compact .pricing-listing-pill {
  display: grid;
  align-content: center;
  gap: 2px;
  min-width: 0;
  min-height: 38px;
  padding: 5px 7px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
}

.pricing-compact .pricing-listing-pill em,
.pricing-compact .pricing-listing-pill small {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-compact .pricing-listing-pill strong {
  min-width: 0;
  overflow: hidden;
  color: #26344d;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.18;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-compact button {
  height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.pricing-details {
  display: grid;
  gap: 8px;
}

.pricing-details[hidden] { display: none; }

.pricing-row {
  display: grid;
  grid-template-columns: 72px repeat(4, minmax(120px, 1fr));
  gap: 8px;
  align-items: center;
  min-height: 32px;
  padding: 6px 8px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
  font-size: 12px;
}

.pricing-row strong { color: var(--blue); }
.pricing-row span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pricing-row.error strong { color: var(--red); }
.pricing-row.error span { grid-column: span 4; color: var(--red); }

.pricing-error {
  display: flex;
  gap: 8px;
  align-items: center;
  min-height: 34px;
  padding: 8px 10px;
  border: 1px solid #f2c4c0;
  border-radius: 6px;
  color: var(--red);
  background: #fff7f6;
  font-size: 12px;
}

.pricing-editor {
  display: grid;
  grid-template-columns: minmax(86px, 0.34fr) minmax(0, 1fr) minmax(0, 1.08fr) minmax(0, 1.16fr);
  gap: 6px;
  align-items: stretch;
  padding: 7px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
}

.pricing-editor.active {
  border-color: #8bb8f4;
  box-shadow: inset 3px 0 0 #2563eb;
}

.pricing-editor label {
  display: grid;
  gap: 4px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
}

.pricing-editor input {
  width: 100%;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 8px;
  color: var(--text);
  background: #fff;
}

.pricing-editor input[readonly] {
  color: #33415c;
  background: #f8fafd;
}

.pricing-sku-title {
  display: grid;
  gap: 2px;
  min-width: 0;
  align-self: stretch;
  align-content: center;
  padding: 6px 7px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fbfcff;
}

.pricing-sku-title strong {
  overflow: hidden;
  color: #1f2a44;
  font-size: 12px;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-sku-title span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #52627a;
  font-size: 11px;
  line-height: 1.15;
}

.pricing-sku-title em {
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  line-height: 1.15;
  white-space: nowrap;
}

.pricing-col {
  display: grid;
  grid-template-columns: repeat(3, minmax(82px, 1fr));
  gap: 8px;
  align-items: end;
  min-width: 0;
  padding: 8px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fbfcff;
}

.pricing-col:nth-of-type(3) {
  grid-template-columns: repeat(4, minmax(72px, 1fr));
}

.pricing-col:nth-of-type(4) {
  grid-template-columns: repeat(4, minmax(82px, 1fr));
}

.pricing-left, .pricing-calc-panel {
  display: grid;
  grid-template-columns: repeat(3, minmax(82px, 1fr));
  gap: 8px;
  align-items: end;
  min-width: 0;
  padding: 8px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
}

.pricing-left { background: #fbfcff; }
.pricing-calc-panel { background: #f8fbff; }
.pricing-calc-title, .pricing-rules { grid-column: 1 / -1; }

.pricing-calc-title {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.pricing-calc-title span {
  color: var(--muted);
  font-size: 12px;
}

.pricing-calc-panel button {
  height: 32px;
  padding: 0 12px;
  font-size: 12px;
}

.pricing-calc-result {
  grid-column: 1 / -1;
  min-height: 32px;
  display: block;
  padding: 6px 8px;
  border-radius: 6px;
  color: #33415c;
  background: #eef6ff;
  font-size: 12px;
}

.pricing-wide { grid-column: span 2; }

.pricing-readonly {
  display: grid;
  gap: 4px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
}

.pricing-readonly strong {
  min-height: 32px;
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 8px;
  color: #33415c;
  background: #f8fafd;
}

.pricing-readonly small {
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.logistics-readonly small {
  color: #52627a;
}

.commission-readonly strong {
  color: #17663e;
  background: #f0fbf6;
}

.commission-readonly small {
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-rules {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.pricing-editor button {
  height: 32px;
  padding: 0 12px;
  font-size: 12px;
}

.card-actions {
  display: flex;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.card-actions button { height: 28px; padding: 0 10px; font-size: 12px; }
button.danger { color: #fff; background: var(--red); }

.action-price-badge {
  display: grid;
  align-content: center;
  gap: 1px;
  min-width: 96px;
  min-height: 30px;
  padding: 3px 7px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
  line-height: 1.1;
}

.action-price-badge em,
.action-price-badge small {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 9px;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.action-price-badge strong {
  min-width: 0;
  overflow: hidden;
  color: #26344d;
  font-size: 12px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-card {
  display: grid;
  gap: 0;
}

.category-summary {
  display: grid;
  grid-template-columns: 32px 72px minmax(260px, 1fr) minmax(360px, 0.85fr) auto;
  gap: 8px;
  align-items: start;
  padding: 7px 9px;
}

.image-summary {
  grid-template-columns: 18px 24px 42px minmax(0, 1fr) minmax(250px, 0.8fr) minmax(186px, 196px);
  gap: 6px;
  align-items: start;
  padding: 5px 7px;
}

.upload-summary {
  grid-template-columns: 18px 24px 48px minmax(220px, 1fr) minmax(330px, 0.9fr) 188px;
  gap: 6px 8px;
  align-items: center;
  min-width: 920px;
  padding: 5px 7px;
}

.category-price {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.category-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.category-actions button {
  height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.category-actions .source-review-action {
  border: 1px solid #f5b76b;
  color: #9a4b00;
  background: #fff4e6;
  font-weight: 800;
}

.category-actions .source-review-action:hover {
  background: #ffe7c2;
}

.category-actions .action-price-badge,
.card-actions .action-price-badge {
  flex: 0 1 auto;
}

.category-price .action-price-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
  min-height: 26px;
  padding: 4px 8px;
}

.category-price .action-price-badge em,
.category-price .action-price-badge small,
.category-price .action-price-badge strong {
  line-height: 1;
}

.category-price .action-price-badge em {
  flex: 0 0 auto;
  font-size: 10px;
}

.category-price .action-price-badge strong {
  flex: 1 1 auto;
  font-size: 12px;
}

.category-price .action-price-badge small {
  flex: 0 0 auto;
  margin-left: auto;
  font-size: 10px;
}

body[data-view="analysis"] #analysisList {
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  gap: 6px;
  padding: 0 6px 96px 0;
  scrollbar-gutter: stable;
}

body[data-view="analysis"] #analysisList .batch-bar {
  min-height: 42px;
  padding: 6px 8px;
}

body[data-view="analysis"] #analysisList .batch-bar > div:first-child {
  gap: 1px;
}

body[data-view="analysis"] #analysisList .batch-bar strong {
  font-size: 13px;
}

body[data-view="analysis"] #analysisList .batch-bar span {
  font-size: 11px;
}

body[data-view="analysis"] #analysisList .batch-actions {
  gap: 6px;
}

body[data-view="analysis"] #analysisList .batch-actions button {
  height: 28px;
  min-width: 78px;
  padding: 0 9px;
}

.analysis-card .category-summary {
  grid-template-columns: 16px 24px 42px minmax(260px, 0.86fr) minmax(440px, 1.24fr) 82px;
  gap: 4px 6px;
  align-items: center;
  min-height: 0;
  padding: 4px 6px;
}

.analysis-card .product-checkbox {
  margin: 0;
}

.analysis-card .product-no {
  width: 22px;
  height: 22px;
  font-size: 11px;
}

.analysis-card .thumb {
  width: 42px;
  height: 42px;
}

.analysis-main {
  display: contents;
}

.analysis-card .product-info {
  display: grid;
  grid-column: 4;
  align-content: center;
  gap: 3px;
  min-width: 0;
}

.analysis-card .product-info h3 {
  -webkit-line-clamp: 1;
  font-size: 13px;
  line-height: 1.25;
}

.analysis-card .category-actions {
  display: grid;
  grid-column: 6;
  grid-template-columns: 1fr;
  align-content: center;
  justify-content: stretch;
  min-width: 0;
  gap: 3px;
}

.analysis-card .category-actions button {
  width: 100%;
  height: 24px;
  min-height: 24px;
  padding: 0 7px;
  font-size: 11px;
}

.image-card .category-actions .action-price-badge {
  width: 100%;
  min-width: 0;
}

.analysis-card .meta,
.analysis-card .detail-line {
  overflow: hidden;
  flex-wrap: nowrap;
  gap: 5px;
  margin: 0;
  font-size: 11px;
  line-height: 1.25;
}

.analysis-card .meta span,
.analysis-card .detail-line span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analysis-card .badge {
  height: 20px;
  padding: 0 7px;
  font-size: 11px;
}

.analysis-metrics-grid {
  display: grid;
  grid-column: 5;
  grid-template-columns: minmax(390px, 1.2fr) minmax(220px, 0.8fr);
  gap: 5px;
  align-items: stretch;
  min-width: 0;
}

.analysis-match-slot {
  display: grid;
  align-items: center;
  min-width: 0;
}

.analysis-price-slot {
  display: grid;
  align-items: stretch;
  gap: 4px;
  min-width: 0;
}

.analysis-price-slot .pricing-compact {
  grid-template-columns: repeat(5, minmax(46px, 1fr));
  grid-template-rows: repeat(2, minmax(22px, 1fr));
  gap: 4px;
  align-items: stretch;
  height: 100%;
  min-height: 54px;
  padding: 4px;
}

.analysis-price-slot .pricing-compact .pricing-pill {
  min-height: 22px;
  padding: 3px 5px;
}

.analysis-price-slot .pricing-compact .pricing-pill.logistics {
  grid-column: 1 / span 5;
}

.analysis-price-slot .pricing-compact.readonly {
  grid-template-columns: repeat(5, minmax(46px, 1fr));
}

.analysis-price-slot .pricing-compact .pricing-pill b,
.analysis-price-slot .pricing-compact .pricing-pill em {
  font-size: 11px;
}

.analysis-price-slot .pricing-compact button {
  grid-column: 5;
  grid-row: 1 / -1;
  align-self: stretch;
  height: auto;
  min-height: 48px;
  padding: 0 6px;
}

.analysis-price-slot .action-price-badge {
  width: 100%;
  min-width: 0;
  min-height: 24px;
  padding: 3px 6px;
}

.analysis-price-slot .action-price-badge em,
.analysis-price-slot .action-price-badge small,
.analysis-price-slot .action-price-badge strong {
  font-size: 10px;
}

.analysis-price-slot .action-price-badge {
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
}

.analysis-price-placeholder {
  display: grid;
  gap: 3px;
  min-height: 42px;
  align-content: center;
  padding: 6px 8px;
  border: 1px dashed #d9e3f1;
  border-radius: 6px;
  background: #fbfdff;
  color: #52627a;
  font-size: 11px;
}

.analysis-price-placeholder.ready {
  border-color: #bfd9fb;
  background: #f5f9ff;
}

.analysis-price-placeholder.warn {
  border-color: #f5ca7a;
  background: #fff8e8;
  color: #8a5a08;
}

.analysis-price-placeholder strong,
.analysis-price-placeholder span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analysis-match-slot .category-match-summary {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 3px 6px;
  align-content: center;
  min-height: 54px;
  max-width: none;
  margin: 0;
  padding: 6px 7px;
  border-radius: 6px;
  font-size: 11px;
}

.analysis-match-slot .category-score {
  justify-items: end;
  min-width: 58px;
  gap: 2px;
}

.analysis-match-slot .category-score-track {
  height: 5px;
}

.analysis-match-slot .category-match-summary strong,
.analysis-match-slot .category-match-summary span,
.analysis-match-slot .category-match-summary em,
.analysis-match-slot .category-match-summary b,
.analysis-match-slot .category-match-summary small {
  font-size: 11px;
}

.analysis-match-slot .category-match-summary b {
  grid-column: 2;
  justify-self: end;
}

.analysis-match-slot .category-match-summary small {
  display: none;
}

.analysis-match-slot .category-match-summary small.category-commission-line,
.analysis-match-slot .category-match-summary small.category-missing-line,
.analysis-match-slot .category-match-summary small.category-id-line {
  display: block;
  grid-column: 1 / -1;
}

.category-missing-line {
  color: #8a4b08 !important;
}

.category-id-line {
  color: #17663e !important;
}

.seo-source-line {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
  margin-top: 6px;
  padding: 6px 8px;
  border: 1px solid #d9e8fb;
  border-radius: 6px;
  background: #f7fbff;
  color: #33415c;
  font-size: 12px;
}

.seo-source-line.ok {
  border-color: #ccefe0;
  background: #f4fcf8;
}

.seo-source-line.warn {
  border-color: #f4dda9;
  background: #fffaf0;
}

.seo-source-line strong {
  color: #26344d;
  font-size: 12px;
}

.seo-source-line span {
  color: var(--muted);
  font-size: 12px;
}

.analysis-next-note {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 6px 8px;
  border: 1px solid #e6edf7;
  border-left: 4px solid #8aa4c8;
  border-radius: 6px;
  background: #fbfdff;
  color: #52627a;
  font-size: 11px;
}

.analysis-next-note.ready {
  border-color: #ccefe0;
  border-left-color: var(--green);
  background: #f4fcf8;
}

.analysis-next-note.warn {
  border-color: #f4dda9;
  border-left-color: #f59e0b;
  background: #fffaf0;
}

.analysis-next-note strong,
.analysis-next-note span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-prepare-panel {
  display: grid;
  gap: 5px;
  min-width: 0;
  border: 1px solid #dbe7f4;
  border-left: 4px solid #2563eb;
  border-radius: 6px;
  background: #fbfdff;
  padding: 5px 6px;
}

.upload-prepare-panel.compact {
  grid-template-columns: minmax(96px, 0.3fr) minmax(0, 1fr);
  align-items: center;
  min-height: 52px;
  gap: 4px 6px;
  padding: 4px 5px;
}

.upload-prepare-panel.ok {
  border-color: #ccebdd;
  border-left-color: #16a34a;
  background: #f5fcf8;
}

.upload-prepare-panel.bad {
  border-color: #f1d4ae;
  border-left-color: #f59e0b;
  background: #fffaf0;
}

.upload-prepare-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

.upload-prepare-panel.compact .upload-prepare-head {
  display: grid;
  gap: 2px;
}

.upload-prepare-head strong {
  color: #152033;
  font-size: 12px;
  line-height: 1.2;
  white-space: nowrap;
}

.upload-prepare-head span {
  min-width: 0;
  overflow: hidden;
  color: #64748b;
  font-size: 11px;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-prepare-panel.compact .upload-prepare-head span {
  text-align: left;
}

.upload-prepare-checks {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  min-width: 0;
}

.upload-prepare-panel.compact .upload-prepare-checks {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.upload-prepare-panel.expanded .upload-prepare-checks {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.upload-prepare-check {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1px 5px;
  min-width: 0;
  min-height: 28px;
  align-content: center;
  padding: 3px 5px;
  border: 1px solid #e5edf6;
  border-radius: 5px;
  background: #fff;
}

.upload-prepare-panel.compact .upload-prepare-check {
  min-height: 22px;
  padding: 2px 4px;
}

.upload-prepare-check strong,
.upload-prepare-check span,
.upload-prepare-check em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-prepare-check strong {
  color: #334155;
  font-size: 10px;
}

.upload-prepare-check span {
  justify-self: end;
  color: #2563eb;
  font-size: 10px;
  font-weight: 800;
}

.upload-prepare-check.ok span {
  color: #15803d;
}

.upload-prepare-check.warn span {
  color: #b45309;
}

.upload-prepare-check.bad span {
  color: #b91c1c;
}

.upload-prepare-check em {
  grid-column: 1 / -1;
  color: #64748b;
  font-size: 10px;
  font-style: normal;
}

.upload-prepare-panel.compact .upload-prepare-check em {
  display: none;
}

.upload-prepare-alert {
  grid-column: 1 / -1;
  min-width: 0;
  overflow: hidden;
  color: #92400e;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-prepare-alert.ok {
  color: #15803d;
}

.upload-prepare-missing {
  display: grid;
  gap: 4px;
  padding: 5px 6px;
  border: 1px solid #f1d4ae;
  border-radius: 5px;
  background: #fffaf0;
}

.upload-prepare-missing strong {
  color: #7c2d12;
  font-size: 11px;
}

.upload-prepare-missing div {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.upload-prepare-missing span {
  max-width: 240px;
  overflow: hidden;
  border-radius: 999px;
  background: #fff;
  padding: 2px 7px;
  color: #7c2d12;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ozon-upload-prepare-slot {
  grid-column: 1 / -1;
}

.analysis-card .category-actions {
  align-items: center;
  flex-wrap: nowrap;
}

.analysis-card .category-actions button {
  height: 26px;
  min-width: 82px;
  padding: 0 8px;
  font-size: 11px;
  white-space: nowrap;
}

.upload-summary .category-actions {
  align-items: center;
  min-width: 0;
}

.category-card .upload-summary .product-info h3 {
  min-width: 0;
  -webkit-line-clamp: 1;
  font-size: 13px;
  line-height: 1.22;
}

.upload-inline-actions {
  align-self: center;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  justify-content: stretch;
  justify-self: end;
  width: 188px;
  max-width: 188px;
  min-width: 0;
}

.upload-inline-actions button {
  width: 100%;
  min-width: 0;
  height: 25px;
  padding: 0 6px;
  font-size: 11px;
  white-space: nowrap;
}

.upload-inline-actions .action-price-badge {
  min-height: 24px;
  padding: 3px 7px;
  font-size: 11px;
}

.upload-inline-actions .action-price-badge em,
.upload-inline-actions .action-price-badge small,
.upload-inline-actions .action-price-badge strong {
  font-size: 10px;
}

.upload-price-stack {
  gap: 4px;
  min-width: 330px;
}

.upload-summary .category-price .action-price-badge {
  min-height: 23px;
  padding: 3px 6px;
}

.upload-summary .category-price .action-price-badge em,
.upload-summary .category-price .action-price-badge small,
.upload-summary .category-price .action-price-badge strong {
  font-size: 10px;
}

.category-card .upload-summary .product-checkbox {
  margin: 0;
}

.category-card .upload-summary .product-no {
  width: 24px;
  height: 24px;
  font-size: 11px;
}

.category-card .upload-summary .thumb {
  width: 48px;
  height: 48px;
}

.upload-summary .product-info {
  display: grid;
  gap: 3px;
  align-content: center;
}

.upload-summary .meta,
.upload-summary .detail-line {
  overflow: hidden;
  flex-wrap: nowrap;
  gap: 5px;
  margin: 0;
  font-size: 11px;
  line-height: 1.22;
}

.upload-summary .meta span,
.upload-summary .detail-line span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

button.category-readable-chip,
.upload-summary .category-readable-chip {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  height: 22px;
  border: 1px solid #d8dee8;
  border-radius: 6px;
  background: #f7f8fa;
  color: #344054;
  padding: 0 7px;
  font-size: 11px;
  font-weight: 700;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body button.category-readable-chip {
  border-color: #d8dee8;
  background: #f7f8fa;
  color: #344054;
}

.category-readable-chip:hover,
.upload-summary .category-readable-chip:hover,
.category-inline-link:hover {
  filter: brightness(0.98);
  text-decoration: underline;
}

button.category-readable-chip.ok,
.upload-summary .category-readable-chip.ok {
  border-color: #d8dee8;
  background: #f7f8fa;
  color: #344054;
}

button.category-readable-chip.warn,
.upload-summary .category-readable-chip.warn {
  border-color: #ead7a4;
  background: #fffaf0;
  color: #7a4c00;
}

button.category-readable-chip.bad,
button.category-readable-chip.todo,
.upload-summary .category-readable-chip.bad,
.upload-summary .category-readable-chip.todo {
  border-color: #f3c5c5;
  background: #fff5f5;
  color: #b42318;
}

.category-inline-link {
  overflow: hidden;
  height: auto;
  min-width: 0;
  padding: 0;
  color: #22558d;
  background: transparent;
  font-size: 11px;
  font-weight: 700;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-summary .badge {
  height: 20px;
  padding: 0 7px;
  font-size: 11px;
}

.upload-summary .pricing-compact {
  gap: 4px;
  padding: 3px;
  min-width: 0;
}

.upload-summary .pricing-compact .pricing-pill {
  min-height: 28px;
  gap: 1px;
  padding: 3px 5px;
}

.upload-summary .pricing-compact .pricing-pill em {
  font-size: 10px;
}

.upload-summary .pricing-compact .pricing-pill b {
  font-size: 11px;
  line-height: 1.12;
}

.upload-summary .pricing-compact .pricing-listing-pill.action-price-badge {
  display: grid;
  min-height: 28px;
  padding: 3px 5px;
}

.upload-summary .pricing-compact .pricing-listing-pill.action-price-badge em,
.upload-summary .pricing-compact .pricing-listing-pill.action-price-badge small {
  flex: initial;
  margin: 0;
  font-size: 10px;
}

.upload-summary .pricing-compact .pricing-listing-pill.action-price-badge strong {
  flex: initial;
  font-size: 12px;
}

.upload-sku-preview {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 6px 7px;
  border: 1px solid #dfe8f4;
  border-radius: 6px;
  background: #fbfdff;
}

.upload-sku-preview.collapsed {
  margin-bottom: 5px;
  padding: 5px 7px;
}

.upload-sku-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: #334155;
  font-size: 12px;
}

.upload-sku-preview-head > div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.upload-sku-preview-head strong {
  font-size: 13px;
}

.upload-sku-preview-head span {
  overflow: hidden;
  color: #64748b;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-sku-preview-head .sku-data-toggle {
  flex: 0 0 auto;
  height: 24px;
  padding: 0 8px;
  font-size: 11px;
}

.upload-detail-panel {
  display: grid;
  gap: 6px;
  margin: 0 7px 7px;
  padding: 6px;
  border-top: 1px solid #e2e8f0;
  background: #fbfdff;
}

.upload-sku-preview-list {
  display: grid;
  gap: 5px;
}

.upload-sku-preview-row {
  display: grid;
  grid-template-columns: 56px minmax(280px, 1fr) minmax(280px, 0.9fr);
  gap: 8px;
  align-items: center;
  min-width: 0;
  padding: 5px 6px;
  border: 1px solid #e5edf6;
  border-radius: 6px;
  background: #fff;
}

.upload-sku-no {
  color: #1763a6;
  font-size: 11px;
  font-weight: 800;
}

.upload-sku-name {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.upload-sku-name strong,
.upload-sku-name small,
.upload-sku-meta span,
.upload-sku-meta em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-sku-name strong {
  color: #0f172a;
  font-size: 12px;
  line-height: 1.25;
}

.upload-sku-name small {
  color: #64748b;
  font-size: 10px;
}

.upload-sku-meta {
  display: grid;
  grid-template-columns: minmax(100px, 1fr) minmax(96px, 0.7fr) minmax(118px, 0.8fr);
  gap: 6px;
  min-width: 0;
  color: #475569;
  font-size: 10px;
}

.upload-sku-meta em {
  color: #157347;
  font-style: normal;
  font-weight: 800;
}

.image-card .thumb,
.category-card .thumb {
  width: 56px;
  height: 56px;
}

.image-card .product-info h3,
.category-card .product-info h3 {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.image-card .detail-line,
.category-card .detail-line {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.analysis-card .thumb {
  width: 42px;
  height: 42px;
}

.analysis-card .product-info h3 {
  display: block;
  overflow: hidden;
  -webkit-line-clamp: unset;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.analysis-card .analysis-match-slot,
.analysis-card .analysis-price-slot {
  align-self: center;
}

.analysis-card .pricing-summary {
  gap: 6px;
  margin: 0 8px 8px;
  padding: 6px;
  border-color: #d9e6f7;
  background: #f8fbff;
}

.analysis-card .pricing-title {
  min-height: 24px;
}

.analysis-card .pricing-title strong {
  font-size: 12px;
}

.analysis-card .pricing-title span {
  font-size: 11px;
}

.analysis-card .pricing-details {
  gap: 5px;
}

.analysis-card .pricing-editor {
  grid-template-columns: minmax(118px, 0.62fr) minmax(200px, 1fr) minmax(230px, 1.05fr) minmax(260px, 1.2fr);
  gap: 5px;
  padding: 4px;
  border-radius: 5px;
}

.analysis-card .pricing-editor.active {
  box-shadow: inset 2px 0 0 #2563eb;
}

.analysis-card .pricing-sku-title {
  grid-column: auto;
  gap: 1px;
}

.analysis-card .pricing-sku-title strong,
.analysis-card .pricing-sku-title span,
.analysis-card .pricing-sku-title em,
.analysis-card .pricing-editor label,
.analysis-card .pricing-readonly,
.analysis-card .pricing-readonly small {
  font-size: 10px;
}

.analysis-card .pricing-col {
  grid-template-columns: repeat(3, minmax(50px, 1fr));
  gap: 3px;
  padding: 4px;
  border-radius: 5px;
}

.analysis-card .pricing-col:nth-of-type(3) {
  grid-template-columns: repeat(4, minmax(46px, 1fr));
}

.analysis-card .pricing-col:nth-of-type(4) {
  grid-template-columns: repeat(4, minmax(54px, 1fr));
}

.analysis-card .pricing-editor label {
  gap: 1px;
  line-height: 1.1;
}

.analysis-card .pricing-editor input {
  height: 21px;
  padding: 0 5px;
  font-size: 11px;
}

.analysis-card .pricing-readonly {
  gap: 1px;
  line-height: 1.1;
}

.analysis-card .pricing-readonly strong {
  min-height: 21px;
  padding: 0 5px;
  font-size: 11px;
}

.analysis-card .pricing-readonly small {
  display: none;
}

.analysis-card .pricing-summary + .ozon-listing.category-listing {
  margin-top: -2px;
}

.image-card .category-actions {
  display: grid;
  grid-template-columns: 1fr;
  align-content: center;
  gap: 5px;
  min-width: 0;
}

.image-card .listing-main-actions {
  position: static;
  grid-column: 6;
  grid-template-columns: minmax(88px, 0.94fr) minmax(92px, 1fr);
  align-items: stretch;
  width: 100%;
  min-width: 0;
  min-height: 0;
  height: auto;
  align-self: start;
}

.image-card .category-actions button {
  width: 100%;
  height: 28px;
  padding: 0 6px;
  font-size: 11px;
  letter-spacing: 0;
  white-space: nowrap;
}

.listing-primary-actions,
.listing-secondary-actions {
  display: grid;
  gap: 5px;
  height: 100%;
  min-width: 0;
  grid-auto-rows: minmax(0, 1fr);
}

.image-card .listing-main-actions button {
  height: auto;
  min-height: 28px;
  align-self: stretch;
}

.listing-primary-actions {
  grid-template-columns: 1fr;
}

.listing-primary-actions button {
  border: 1px solid transparent;
  color: #fff;
  font-weight: 800;
}

.listing-primary-actions .listing-analyze-action {
  border-color: #286c4d;
  background: #2f7d59;
}

.listing-primary-actions .listing-image-action {
  border-color: #3f556b;
  background: #4b6278;
}

.listing-primary-actions .listing-upload-action {
  border-color: #293549;
  background: #344154;
}

.listing-primary-actions .listing-delete-action {
  border-color: #b3313e;
  color: #fff;
  background: var(--red);
}

.listing-primary-actions button:disabled {
  border-color: #d8dee8;
  color: #7a8494;
  background: #eef2f6;
}

.listing-secondary-actions {
  grid-template-columns: 1fr;
}

.listing-secondary-actions button {
  color: #334155;
  background: #f1f4f7;
}

.listing-secondary-actions .source-review-action {
  border-color: #edd7ad;
  color: #7a3f00;
  background: #fff7ec;
}

.listing-flow-slot {
  min-width: 0;
  max-width: 360px;
}

.listing-flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}

.listing-flow-step {
  display: grid;
  gap: 1px;
  min-width: 0;
  min-height: 36px;
  padding: 5px 6px;
  border: 1px solid #e3e7ee;
  border-radius: 6px;
  background: #fff;
}

.listing-flow-step b,
.listing-flow-step small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.listing-flow-step b {
  color: #1f2937;
  font-size: 11px;
}

.listing-flow-step small {
  color: #667085;
  font-size: 9px;
}

.listing-flow-step.done {
  border-color: #cfe8d7;
  background: #f7fbf8;
}

.listing-flow-step.active {
  border-color: #d7dde6;
  background: #f8f9fb;
  box-shadow: inset 3px 0 0 #7a8494;
}

.listing-flow-step.pending {
  color: #7a8494;
  background: #fbfcfd;
}

.listing-card-prepare {
  display: grid;
  grid-template-columns: minmax(220px, 0.85fr) minmax(340px, 1.05fr) minmax(380px, 1.2fr);
  grid-template-areas: "analysis analysis pricing";
  gap: 6px 8px;
  align-items: start;
  position: relative;
  z-index: 2;
  margin: -94px 204px 6px 20px;
}

.listing-card-prepare:has(> .upload-sku-preview) {
  grid-template-columns: minmax(220px, 0.85fr) minmax(340px, 1.05fr) minmax(380px, 1.2fr);
  grid-template-areas:
    "analysis analysis pricing"
    "sku sku sku";
}

.listing-card-prepare .ozon-listing,
.listing-card-prepare .upload-sku-preview {
  min-width: 0;
  margin: 0;
}

.listing-card-prepare > .listing-analysis-compact,
.listing-card-prepare > .listing-analysis-empty,
.listing-card-prepare > .ozon-listing {
  grid-area: analysis;
  min-width: 0;
}

.listing-card-prepare > .listing-pricing-panel {
  grid-area: pricing;
  min-width: 0;
  align-self: start;
}

.listing-card-prepare > .upload-sku-preview {
  grid-area: sku;
  min-width: 0;
  margin: 0;
}

.listing-card-prepare .ozon-listing {
  padding: 7px;
}

.listing-pricing-panel,
.listing-analysis-empty,
.listing-analysis-compact {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 6px;
  border: 1px solid #e2e7ef;
  border-radius: 8px;
  background: #fff;
}

.listing-analysis-compact {
  grid-template-columns: minmax(180px, 0.78fr) minmax(160px, 0.72fr);
  align-items: center;
}

.listing-card-prepare .listing-analysis-compact {
  grid-template-columns: minmax(0, 0.84fr) minmax(0, 1.16fr);
  grid-template-areas:
    "category checks"
    "title checks"
    "note note";
  gap: 5px 8px;
  align-items: center;
}

.listing-card-prepare .listing-analysis-compact .category-readable-chip,
.listing-card-prepare .listing-analysis-compact .listing-title-compact {
  align-self: center;
}

.listing-card-prepare .listing-analysis-compact .category-readable-chip {
  grid-area: category;
}

.listing-card-prepare .listing-analysis-compact .listing-title-compact {
  grid-area: title;
}

.listing-analysis-compact .category-readable-chip {
  height: 24px;
}

.listing-title-compact {
  overflow: hidden;
  color: #475467;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.listing-checks-mini {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px;
}

.listing-checks-mini span {
  display: grid;
  gap: 1px;
  min-width: 0;
  padding: 3px 5px;
  border: 1px solid #e4e9f1;
  border-radius: 6px;
  background: #fbfcfd;
}

.listing-checks-mini span.ok {
  border-color: #cfebd8;
  background: #f7fbf8;
}

.listing-checks-mini span.warn {
  border-color: #edd9a7;
  background: #fffaf0;
}

.listing-checks-mini span.bad {
  border-color: #efc3c3;
  background: #fff6f6;
}

.listing-checks-mini b,
.listing-checks-mini em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.listing-checks-mini b {
  color: #344054;
  font-size: 10px;
}

.listing-checks-mini em {
  color: #667085;
  font-size: 9px;
  font-style: normal;
}

.listing-review-note {
  grid-column: 1 / -1;
  overflow: hidden;
  padding: 5px 7px;
  border: 1px solid #edd0cc;
  border-radius: 6px;
  color: #9f2f24;
  background: #fff8f7;
  font-size: 11px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.listing-card-prepare .listing-analysis-compact .listing-checks-mini {
  grid-area: checks;
  grid-column: auto;
  align-self: stretch;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
}

.listing-card-prepare .listing-analysis-compact .listing-checks-mini span:nth-child(4) {
  grid-column: 3;
  grid-row: 2;
}

.listing-card-prepare .listing-analysis-compact .listing-checks-mini span:nth-child(5) {
  grid-column: 1;
  grid-row: 2;
}

.listing-card-prepare .listing-analysis-compact .listing-checks-mini span:nth-child(6) {
  grid-column: 2;
  grid-row: 2;
}

.listing-card-prepare .listing-analysis-compact .listing-review-note {
  grid-area: note;
  grid-column: 1 / -1;
}

.listing-pricing-panel .pricing-compact {
  margin: 0;
}

.listing-pricing-panel .pricing-compact.readonly.with-listing {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  grid-template-areas:
    "sale purchase freight profit"
    "commission logistics listing listing";
}

.listing-pricing-panel .pricing-compact.readonly.with-listing .pricing-pill:nth-child(1) {
  grid-area: sale;
}

.listing-pricing-panel .pricing-compact.readonly.with-listing .pricing-pill:nth-child(2) {
  grid-area: purchase;
}

.listing-pricing-panel .pricing-compact.readonly.with-listing .pricing-pill:nth-child(3) {
  grid-area: freight;
}

.listing-pricing-panel .pricing-compact.readonly.with-listing .pricing-pill:nth-child(4) {
  grid-area: profit;
}

.listing-pricing-panel .pricing-compact.readonly.with-listing .pricing-pill:nth-child(5) {
  grid-area: commission;
}

.listing-card-prepare:has(> .upload-sku-preview) .listing-pricing-panel .pricing-compact.readonly.with-listing {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
}

.listing-pricing-panel .pricing-compact .pricing-pill,
.listing-pricing-panel .pricing-compact .pricing-listing-pill.action-price-badge {
  min-width: 0;
  min-height: 34px;
  padding: 5px 7px;
  border-color: #edf1f7;
  background: #fff;
}

.listing-pricing-panel .pricing-compact .pricing-pill.logistics {
  grid-area: logistics;
}

.listing-card-prepare:has(> .upload-sku-preview) .listing-pricing-panel .pricing-compact .pricing-pill.logistics {
  grid-area: logistics;
}

.listing-pricing-panel .pricing-compact .pricing-listing-pill.action-price-badge {
  grid-area: listing;
}

.listing-pricing-panel .pricing-compact .pricing-listing-pill.action-price-badge em,
.listing-pricing-panel .pricing-compact .pricing-listing-pill.action-price-badge small {
  flex: initial;
  margin: 0;
  color: var(--muted);
  font-size: 11px;
}

.listing-pricing-panel .pricing-compact .pricing-listing-pill.action-price-badge strong {
  flex: initial;
  color: #26344d;
  font-size: 12px;
  font-weight: 700;
}

.listing-sku-toggle {
  justify-self: end;
  height: 26px;
  padding: 0 9px;
  font-size: 11px;
}

.listing-analysis-empty strong {
  color: #1f2937;
  font-size: 13px;
}

.listing-analysis-empty span,
.listing-analysis-empty em {
  color: #667085;
  font-size: 12px;
  line-height: 1.45;
}

.listing-analysis-empty em {
  font-style: normal;
}

.listing-analysis-empty.warn {
  border-color: #efd8a8;
  background: #fffaf1;
}

.listing-card-prepare .upload-prepare-checks {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}

.listing-card-prepare .upload-sku-preview-list {
  max-height: 180px;
  overflow: auto;
}

.image-workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  align-items: start;
  margin: 0 7px 6px 97px;
}

.image-workspace-grid.has-skus {
  grid-template-columns: minmax(0, 1fr);
}

.image-card .image-public-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  min-width: 0;
  margin: 0;
  gap: 3px;
  padding: 3px 4px;
}

.image-workspace-grid.has-skus .image-public-panel {
  grid-template-columns: max-content minmax(280px, 1fr);
  gap: 8px;
}

.image-card .image-public-panel .image-zone-title {
  grid-column: 1 / -1;
}

.image-workspace-grid.has-skus .image-card .image-public-panel .image-zone-title,
.image-workspace-grid.has-skus .image-public-panel .image-zone-title {
  grid-column: 1;
  grid-row: 1;
}

.image-card .image-public-panel .public-image-result {
  grid-column: 1;
  min-width: 0;
}

.image-workspace-grid.has-skus .image-public-panel .public-image-result {
  grid-column: 1;
  grid-row: 2;
  width: max-content;
  max-width: 100%;
}

.image-card .image-public-panel .image-sku-inline {
  grid-column: 1;
  grid-row: auto;
  align-self: start;
  min-width: 0;
  margin-top: 4px;
}

.image-workspace-grid.has-skus .image-public-panel .image-sku-inline {
  grid-column: 2;
  grid-row: 1 / span 2;
  margin-top: 0;
}

.upload-status-filter {
  height: 30px;
  min-width: 138px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 8px;
  color: var(--text);
  background: #fff;
  font-size: 12px;
}

.image-sku-list {
  display: grid;
  min-width: 0;
  gap: 4px;
  padding: 4px;
  border: 1px solid #d8e5f5;
  border-radius: 8px;
  background: #fbfcff;
}

.image-sku-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  min-height: 26px;
  padding: 3px 5px;
  border: 1px solid #e5ebf5;
  border-radius: 8px;
  background: #fff;
}

.image-sku-toolbar > div:first-child {
  display: grid;
  gap: 2px;
}

.image-sku-toolbar strong {
  color: #18233a;
  font-size: 12px;
}

.image-sku-toolbar span {
  color: var(--muted);
  font-size: 11px;
}

.image-sku-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
  gap: 4px;
  align-items: start;
}

.image-workspace-grid .image-sku-list {
  align-self: start;
  padding: 4px;
  background: #f8fbff;
}

.image-workspace-grid .image-sku-toolbar {
  gap: 6px;
  padding: 3px 5px;
}

.image-workspace-grid .image-sku-toolbar .batch-actions {
  gap: 5px;
}

.image-workspace-grid .image-sku-toolbar .batch-actions button {
  height: 24px;
  min-width: 72px;
  padding: 0 8px;
  font-size: 11px;
}

.image-workspace-grid .image-sku-grid {
  grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
  gap: 4px;
}

.image-workspace-grid .image-sku-row {
  grid-template-columns: 12px 12px 22px 34px 30px;
  grid-template-rows: 34px;
  gap: 3px;
  padding: 4px;
  border-color: #e5edf8;
}

.image-workspace-grid .image-sku-row .sku-thumb-large {
  width: 22px;
  height: 22px;
}

.image-workspace-grid .image-sku-row .sku-reference-thumb em {
  display: none;
}

.image-workspace-grid .image-sku-row .sku-index {
  font-size: 10px;
}

.image-workspace-grid .image-sku-row .sku-main {
  display: none;
}

.image-workspace-grid .image-sku-row .image-job-line {
  margin-top: 1px;
}

.image-workspace-grid .image-sku-row .image-result-box {
  grid-column: 4;
  grid-row: 1;
}

.image-workspace-grid .image-sku-row .generated-image-grid {
  grid-template-columns: 34px;
}

.image-workspace-grid .image-sku-row .generated-thumb {
  width: 34px;
  border-radius: 5px;
}

.image-workspace-grid .image-sku-row .generated-status {
  display: none;
}

.image-workspace-grid .image-sku-row .image-sku-actions button {
  width: 100%;
  height: 24px;
  padding: 0 3px;
  font-size: 10px;
}

.image-workspace-grid .image-sku-row .image-sku-actions {
  grid-column: 5;
  grid-row: 1;
  justify-self: stretch;
}

.image-sku-row {
  display: grid;
  grid-template-columns: 16px 20px 34px minmax(0, 1fr) 68px;
  grid-template-rows: auto 24px;
  gap: 5px 6px;
  align-items: center;
  min-height: 0;
  padding: 6px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
}

.image-sku-checkbox {
  margin: 0;
}

.image-sku-row .sku-main {
  gap: 1px;
}

.image-sku-row .sku-main strong {
  font-size: 11px;
}

.image-sku-row .sku-main span {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.image-sku-row .image-result-box {
  grid-column: 5;
  grid-row: 1 / span 2;
  align-self: center;
}

.image-sku-row .generated-image-grid {
  grid-template-columns: 64px;
  gap: 0;
}

.image-sku-row > button,
.image-sku-actions {
  grid-column: 4;
  grid-row: 2;
  justify-self: start;
}

.image-sku-row > button,
.image-sku-actions button {
  height: 24px;
  padding: 0 8px;
  font-size: 11px;
}

.image-sku-actions {
  display: flex;
  gap: 5px;
  align-items: center;
}

.image-sku-row .sku-thumb-large {
  width: 34px;
  height: 34px;
}

.image-sku-row .sku-index {
  font-size: 12px;
}

.image-sku-row .image-job-line {
  margin-top: 2px;
}

.image-sku-row .image-job-line .badge,
.image-sku-row .image-job-line span {
  max-width: 120px;
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.image-sku-row .generated-image-card {
  gap: 2px;
}

.image-sku-row .generated-image-card.sku-original-lock .generated-thumb {
  border-color: #a7b0bd;
  box-shadow: 0 0 0 1px rgba(31, 41, 55, 0.08);
}

.image-sku-row .generated-image-card.sku-original-lock .generated-status {
  background: rgba(31, 41, 55, 0.82);
  color: #fff;
}

.image-sku-row .generated-image-card > span {
  display: none;
}

.image-sku-row .generated-thumb {
  width: 64px;
  aspect-ratio: 1 / 1;
  border-radius: 6px;
}

.image-sku-row .generated-status {
  top: 4px;
  right: 4px;
  max-width: 56px;
  padding: 2px 4px;
  font-size: 9px;
}

.image-sku-row .generated-placeholder {
  gap: 4px;
  padding: 6px 5px;
}

.image-sku-row .generated-placeholder i {
  width: 22px;
  height: 22px;
  border-width: 2px;
}

.image-sku-row .generated-placeholder strong {
  font-size: 11px;
}

.image-sku-row .generated-placeholder u {
  display: none;
}

.category-card .ozon-listing.image-public-panel {
  gap: 3px;
  margin: 0 8px 6px 92px;
  padding: 4px;
}

.ozon-title.image-zone-title {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  padding: 2px 5px;
}

.ozon-title.image-zone-title strong {
  font-size: 12px;
}

.image-fold-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.image-fold-actions button {
  height: 26px;
  padding: 0 9px;
  font-size: 11px;
}

.public-image-result .generated-image-grid {
  grid-template-columns: repeat(auto-fill, minmax(72px, 82px));
  gap: 5px;
  justify-content: start;
}

.image-workspace-grid.has-skus .public-image-result .generated-image-grid {
  grid-template-columns: repeat(7, 82px);
  gap: 5px;
}

.image-workspace-grid.has-skus .generated-image-cell {
  gap: 3px;
}

.public-image-result .generated-image-card {
  gap: 0;
}

.public-image-result .generated-regenerate-button {
  height: 20px;
  font-size: 10px;
}

.public-image-result .generated-image-card > span {
  position: absolute;
  left: 5px;
  bottom: 5px;
  z-index: 2;
  max-width: calc(100% - 10px);
  padding: 1px 5px;
  border-radius: 999px;
  color: #33415c;
  background: rgba(255, 255, 255, 0.86);
  font-size: 10px;
  line-height: 1.35;
}

.public-image-result .generated-thumb {
  border-radius: 4px;
}

.public-image-result .generated-status {
  top: 4px;
  right: 4px;
  max-width: calc(100% - 8px);
  padding: 2px 5px;
  font-size: 9px;
}

.public-image-result .generated-placeholder {
  gap: 4px;
  padding: 6px 5px;
}

.public-image-result .generated-placeholder i {
  width: 22px;
  height: 22px;
  border-width: 2px;
}

.public-image-result .generated-placeholder strong {
  font-size: 12px;
}

.public-image-result .generated-placeholder u {
  display: none;
}

.upload-public-images {
  margin: 0 12px 12px 56px;
  padding: 8px;
  border: 1px solid #e0e7f0;
  border-radius: 6px;
  background: #f8fafc;
}

.upload-detail-panel .upload-public-images {
  margin: 0;
  padding: 6px;
}

.upload-public-images-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
  color: #334155;
  font-size: 12px;
}

.upload-public-images-head span {
  color: #64748b;
  font-size: 11px;
}

.upload-public-image-result .generated-image-grid {
  grid-template-columns: repeat(auto-fill, minmax(72px, 82px));
  gap: 5px;
}

.image-result-box { min-width: 0; }
.generated-image-strip { display: flex; flex-wrap: wrap; gap: 6px; }
.generated-image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
  gap: 8px;
  align-items: start;
}
.generated-image-cell {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.generated-image-card {
  height: auto;
  display: grid;
  gap: 5px;
  position: relative;
  color: inherit;
  text-decoration: none;
  min-width: 0;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: zoom-in;
  text-align: center;
}
.generated-image-card.empty {
  height: auto;
  border: 0;
  padding: 0;
  color: inherit;
  background: transparent;
  pointer-events: none;
  cursor: default;
}
.generated-image-card.complete .generated-thumb {
  border-color: #9ed8b2;
  box-shadow: 0 0 0 1px rgba(34, 154, 86, 0.12);
}
.generated-image-card.refreshing .generated-thumb {
  border-color: #a9c9ff;
  box-shadow: 0 0 0 1px rgba(62, 122, 255, 0.12);
}
.generated-image-card.refreshing::after {
  content: none;
}
.generated-image-card.refreshing::before {
  content: none;
}
.generated-image-card.generating {
  opacity: 1;
}
.generated-image-card span {
  color: var(--muted);
  font-size: 11px;
  text-align: center;
}
.generated-regenerate-button {
  width: 100%;
  height: 24px;
  padding: 0 8px;
  border-radius: 5px;
  font-size: 11px;
}
.generated-thumb {
  width: 100%;
  aspect-ratio: 3 / 4;
  border: 1px solid var(--line);
  border-radius: 5px;
  object-fit: cover;
}
.generated-status {
  position: absolute;
  top: 6px;
  right: 6px;
  max-width: calc(100% - 12px);
  padding: 3px 6px;
  border-radius: 999px;
  color: #157347;
  background: rgba(232, 255, 241, 0.94);
  border: 1px solid rgba(34, 154, 86, 0.18);
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.generated-placeholder {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  gap: 8px;
  padding: 8px;
  color: #31415f;
  background: #f8fbff;
}
.generated-placeholder::before {
  content: none;
}
.generated-placeholder.active {
  border-color: #b8d4ff;
  background: #f6faff;
  box-shadow: none;
  animation: none;
}
.generated-placeholder.active::before {
  animation: none;
}
.generated-placeholder.active::after {
  content: none;
}
.generated-placeholder i {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 3px solid #d8e5f7;
  border-top-color: #2f78ff;
  border-right-color: #2f78ff;
  z-index: 1;
}
.generated-placeholder.active i {
  animation: generated-spin 1.05s linear infinite;
}
.generated-placeholder strong {
  z-index: 1;
  color: #233456;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
}
.generated-placeholder small {
  display: none;
  gap: 4px;
  z-index: 1;
}
.generated-placeholder small b {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #3e7aff;
  animation: generated-dot 1s ease-in-out infinite;
}
.generated-placeholder small b:nth-child(2) { animation-delay: 0.16s; }
.generated-placeholder small b:nth-child(3) { animation-delay: 0.32s; }
.generated-placeholder u {
  display: none;
}
.generated-placeholder u::after {
  content: none;
}
@keyframes generated-spin {
  to { transform: rotate(360deg); }
}
@keyframes generated-border-spin {
  to { transform: rotate(360deg); }
}
@keyframes generated-sheen {
  0% { transform: translateX(-120%); }
  58%, 100% { transform: translateX(120%); }
}
@keyframes generated-dot {
  0%, 100% { transform: translateY(0); opacity: 0.42; }
  50% { transform: translateY(-4px); opacity: 1; }
}
@keyframes generated-progress {
  0% { transform: translateX(-110%); }
  55%, 100% { transform: translateX(245%); }
}
@keyframes generated-card-pulse {
  0%, 100% { filter: saturate(1); }
  50% { filter: saturate(1.08) brightness(1.03); }
}

.generated-placeholder strong,
.generated-placeholder-text {
  display: block;
  width: 100%;
  max-width: none;
  min-width: 0;
  min-height: 0;
  padding: 0;
  margin: 0;
  border: 0 !important;
  border-radius: 0 !important;
  color: #111827 !important;
  background: transparent !important;
  box-shadow: none !important;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.2;
  overflow: visible;
  text-overflow: clip;
  text-align: center;
  white-space: nowrap;
  word-break: keep-all;
  writing-mode: horizontal-tb;
}

.public-image-result .generated-placeholder strong,
.public-image-result .generated-placeholder-text,
.image-sku-row .generated-placeholder strong,
.image-sku-row .generated-placeholder-text {
  font-size: 12px;
  white-space: nowrap;
  word-break: keep-all;
}

.generated-placeholder:not(.active) {
  gap: 0;
  background: #eef3f9;
}

.generated-placeholder:not(.active) i {
  display: none;
}

.generated-placeholder.active strong {
  min-width: 0;
}

.generated-image-card.empty > span {
  display: none !important;
}

.image-pending-text {
  display: grid;
  min-height: 96px;
  place-items: center;
  border: 1px dashed #cfd8e5;
  border-radius: 6px;
  color: #111827;
  background: #eef3f9;
  font-size: 16px;
  font-weight: 800;
}

.image-workspace-grid .image-sku-grid {
  grid-template-columns: repeat(auto-fill, minmax(72px, 82px));
  gap: 5px;
  justify-content: start;
  max-height: 320px;
  overflow-y: auto;
  padding-right: 1px;
}

.image-workspace-grid .image-sku-row {
  grid-template-columns: 16px minmax(0, 1fr);
  grid-template-rows: 18px auto 24px;
  gap: 4px;
  padding: 4px;
  align-items: start;
  min-width: 0;
}

.image-sku-inline {
  margin-top: 4px;
  border-color: #e4ebf3;
  background: #fff;
}

.image-sku-inline::before {
  content: none;
}

.image-sku-inline .image-sku-toolbar {
  display: flex;
}

.image-sku-inline .batch-actions {
  flex-wrap: nowrap;
}

.image-workspace-grid .image-sku-row .sku-reference-thumb {
  display: none;
}

.image-workspace-grid .image-sku-row .image-result-box {
  grid-column: 1 / -1;
  grid-row: 2;
  align-self: stretch;
}

.image-workspace-grid .image-sku-row .generated-image-grid {
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
}

.image-workspace-grid .image-sku-row .generated-image-cell,
.image-workspace-grid .image-sku-row .generated-image-card {
  height: 100%;
}

.image-workspace-grid .image-sku-row .generated-image-card {
  min-height: 96px;
  gap: 0;
}

.image-workspace-grid .image-sku-row .generated-thumb {
  width: 100%;
  min-height: 96px;
  aspect-ratio: 3 / 4;
  border-radius: 4px;
}

.image-workspace-grid .image-sku-row .generated-status {
  display: block;
  top: 4px;
  right: 4px;
  max-width: calc(100% - 8px);
  padding: 2px 5px;
  font-size: 9px;
}

.image-workspace-grid .image-sku-row .generated-placeholder {
  padding: 5px;
}

.image-workspace-grid .image-sku-row .generated-placeholder strong,
.image-workspace-grid .image-sku-row .generated-placeholder-text {
  font-size: 12px;
}

.image-workspace-grid .image-sku-row .generated-image-card > span {
  position: absolute;
  left: 5px;
  bottom: 5px;
  z-index: 2;
  display: block;
  max-width: calc(100% - 10px);
  padding: 1px 5px;
  border-radius: 999px;
  color: #33415c;
  background: rgba(255, 255, 255, 0.88);
  font-size: 10px;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.image-workspace-grid .image-sku-row .image-sku-actions {
  grid-column: 1 / -1;
  grid-row: 3;
  align-self: end;
  display: grid;
}

.image-workspace-grid .image-sku-row .image-sku-actions button {
  height: 24px;
  min-width: 0;
  padding: 0 4px;
  font-size: 10px;
}

.image-workspace-grid .image-sku-row .sku-index {
  grid-column: 2;
  grid-row: 1;
  align-self: center;
  color: #52627a;
  font-size: 10px;
  font-weight: 800;
}

.image-workspace-grid .image-sku-row .sku-index::before {
  content: "SKU ";
}

.image-workspace-grid .image-sku-checkbox {
  grid-column: 1;
  grid-row: 1;
  align-self: center;
  margin: 0;
}

.image-sku-row > button,
.image-sku-actions button { height: 24px; padding: 0 8px; font-size: 11px; }
.image-job-line { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 5px; }
.image-job-line:empty { display: none; }

.upload-report-empty { padding: 14px; color: var(--muted); }
.upload-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.upload-table { width: 100%; min-width: 1120px; border-collapse: collapse; font-size: 12px; }
.upload-table th, .upload-table td { padding: 9px 10px; border-bottom: 1px solid #edf1f7; text-align: left; vertical-align: top; }
.upload-table th { color: var(--muted); background: #f8fafd; font-weight: 600; }
.upload-table tr:last-child td { border-bottom: 0; }
.upload-product-title { max-width: 260px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.upload-error { max-width: 360px; color: #4a5670; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.upload-status-head strong { display: flex; align-items: center; min-height: 24px; }
.upload-status-head em { color: var(--muted); font-size: 12px; font-style: normal; }
.upload-status-error { border-color: #f3c7c5; background: #fffafa; }

.upload-report-fold {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.upload-report-fold > summary,
.upload-debug-details > summary {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  min-height: 38px;
  padding: 8px 10px;
  cursor: pointer;
  list-style: none;
}

.upload-report-fold > summary::-webkit-details-marker,
.upload-debug-details > summary::-webkit-details-marker {
  display: none;
}

.upload-report-fold > summary span,
.upload-debug-details > summary {
  color: var(--muted);
  font-size: 12px;
}

.upload-report-fold[open] {
  padding-bottom: 10px;
}

.upload-report-fold .upload-table-wrap {
  margin: 0 10px;
}

.upload-debug-details {
  grid-column: 1 / -1;
  border: 1px solid #edf1f7;
  border-radius: 8px;
  background: #fff;
}

.upload-debug-details[open] {
  padding-bottom: 8px;
}

.upload-debug-details .ozon-panel {
  margin: 0 8px 8px;
}

.upload-debug-details .ozon-panel p {
  max-height: 220px;
  overflow: auto;
  font-family: Consolas, "Courier New", monospace;
  font-size: 11px;
  line-height: 1.45;
}

.ozon-listing {
  display: grid;
  gap: 8px;
  margin: 0 10px 10px 136px;
  padding: 10px;
  border: 1px solid #d8eadf;
  border-radius: 8px;
  background: #f7fffb;
}

.ozon-listing.empty {
  color: var(--muted);
  background: #fbfcff;
  border-color: #edf1f7;
}

.category-card .ozon-listing {
  margin: 0 10px 10px 114px;
}

.category-card .ozon-listing.category-listing {
  border-color: #d8eadf;
}

.analysis-card .ozon-listing.category-listing {
  grid-template-columns: minmax(220px, 0.56fr) minmax(360px, 1fr);
  gap: 6px;
  margin: 0 8px 8px;
  padding: 7px;
  border-color: #e2eaf5;
  background: #fbfdff;
}

.analysis-card .ozon-listing-head span,
.analysis-card .ozon-title span,
.analysis-card .ozon-panel > span {
  font-size: 11px;
}

.analysis-card .ozon-listing.category-listing .ozon-listing-head {
  grid-column: 1 / -1;
  min-height: 26px;
  padding: 0 2px;
}

.analysis-card .ozon-listing.category-listing .ozon-listing-head strong {
  font-size: 13px;
}

.analysis-card .ozon-listing.category-listing .category-match-title {
  grid-column: 1;
}

.analysis-card .ozon-listing.category-listing .ozon-title:not(.category-match-title) {
  grid-column: 2;
}

.analysis-card .ozon-title {
  gap: 3px;
  min-width: 0;
  padding: 6px 7px;
  border-color: #e5edf6;
  background: #fff;
}

.analysis-card .ozon-title strong {
  overflow: hidden;
  font-size: 13px;
  line-height: 1.35;
  text-overflow: ellipsis;
}

.analysis-card .ozon-listing.category-listing .ozon-title strong {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.analysis-card .ozon-grid {
  grid-column: 1 / -1;
  gap: 6px;
}

.analysis-card .ozon-panel {
  gap: 5px;
  padding: 6px 7px;
  border-color: #e5edf6;
}

.analysis-card .ozon-panel p {
  font-size: 12px;
  line-height: 1.5;
}

.analysis-card .ozon-grid-compact {
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
}

.analysis-card .ozon-grid-compact .ozon-panel.wide {
  grid-column: auto;
}

.analysis-card .ozon-grid-compact .ozon-description-panel {
  grid-column: 1 / -1;
}

.analysis-card .ozon-description-panel p {
  max-height: 72px;
  overflow: hidden;
}

.analysis-card .tag-chip {
  min-height: 20px;
  margin: 0 4px 4px 0;
  padding: 0 7px;
  font-size: 11px;
}

.ozon-listing-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.ozon-listing-head > div {
  display: grid;
  gap: 3px;
}

.ozon-listing-head span, .ozon-title span, .ozon-panel > span {
  color: var(--muted);
  font-size: 12px;
}

.ozon-listing-head button {
  height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.ozon-title {
  display: grid;
  gap: 4px;
  padding: 8px;
  border: 1px solid #e4f0e8;
  border-radius: 6px;
  background: #fff;
}

.ozon-title strong {
  font-size: 14px;
  line-height: 1.45;
}

.category-title-button {
  display: grid;
  justify-items: start;
  gap: 2px;
  height: auto;
  min-width: 0;
  padding: 4px 6px;
  border: 1px solid #e3e7ee;
  border-radius: 6px;
  color: #263241 !important;
  background: #fff !important;
  box-shadow: none !important;
  outline: 0 !important;
  text-align: left;
  appearance: none;
}

.category-title-button:hover,
.category-title-button:active,
.category-title-button:focus,
.category-title-button:focus-visible {
  border-color: #cfd6e1;
  color: #263241 !important;
  background: #f8f9fb !important;
  box-shadow: none !important;
  outline: 0 !important;
}

.category-title-button::selection,
.category-title-button *::selection {
  color: #263241;
  background: #e8eaee;
}

.category-title-button small {
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}

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

.ozon-panel {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 8px;
  border: 1px solid #e4f0e8;
  border-radius: 6px;
  background: #fff;
}

.ozon-panel.wide { grid-column: 1 / -1; }

.ozon-panel p {
  color: #33415c;
  font-size: 13px;
  line-height: 1.6;
  white-space: pre-wrap;
}

.tag-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  margin: 0 5px 5px 0;
  padding: 0 8px;
  border-radius: 999px;
  color: #225a3d;
  background: #e8f6ef;
  font-size: 12px;
}

.muted-text, .ozon-empty {
  color: var(--muted);
  font-size: 12px;
}

.ozon-attr-row {
  display: grid;
  grid-template-columns: minmax(120px, 0.55fr) minmax(160px, 1fr) minmax(90px, auto);
  gap: 8px;
  align-items: center;
  min-height: 30px;
  border-top: 1px solid #edf4ef;
  color: #33415c;
  font-size: 12px;
}

.ozon-attr-row:first-of-type { border-top: 0; }
.ozon-attr-row em { color: var(--muted); font-style: normal; }
.ozon-attr-row.matched em { color: var(--green); }
.ozon-attr-row.missing span,
.ozon-attr-row.missing em { color: var(--red); }
.ozon-empty.ok { color: var(--green); }

.settings-card, .guide, .placeholder {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 16px;
}

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



.settings-grid label, .form-grid label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
}

.settings-grid label.settings-check {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  color: var(--text);
}

.settings-grid label.settings-check input {
  width: 16px;
  height: 16px;
}

.settings-section-title {
  margin: 4px 0 12px;
  font-weight: 700;
  font-size: 14px;
}

.settings-section-title + .settings-grid {
  margin-bottom: 18px;
}

.provider-settings {
  display: grid;
  gap: 10px;
  margin: 0 0 14px;
  padding: 12px;
  border: 1px solid #edf1f7;
  border-radius: 8px;
  background: #fbfcff;
}

.provider-settings[hidden] {
  display: none;
}

.api-key-fold {
  padding: 0;
}

.api-key-fold > summary {
  padding: 12px;
  cursor: pointer;
  list-style: none;
}

.api-key-fold > summary::-webkit-details-marker {
  display: none;
}

.api-key-fold > .settings-grid {
  padding: 0 12px 12px;
}

.provider-settings-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.provider-settings-head strong {
  font-size: 13px;
}

.provider-settings-head span {
  color: var(--muted);
  font-size: 12px;
}

.provider-settings-note {
  margin: 0;
  color: #536071;
  font-size: 12px;
  line-height: 1.55;
}

.single-key-field {
  display: grid;
  gap: 6px;
  width: min(420px, 100%);
  color: var(--muted);
  font-size: 12px;
}

.single-key-field input {
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 10px;
}

.compact-api-grid {
  grid-template-columns: minmax(220px, 1.15fr) minmax(180px, 0.85fr) minmax(240px, 1fr);
  gap: 10px;
}

.seo-research-settings {
  background: #fff;
}

.seo-research-grid {
  grid-template-columns: minmax(280px, 1.4fr) minmax(180px, .8fr) repeat(2, minmax(110px, .45fr));
  gap: 10px;
}

.settings-grid input[type="password"], .settings-grid input[type="text"] {
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 10px;
}
.settings-grid textarea {
  min-height: 92px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
  resize: vertical;
}

.image-prompt-control {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid #e4ecf6;
  border-radius: 8px;
  background: #fbfdff;
}

.image-prompt-switch {
  margin: 0;
}

.image-prompt-control textarea[disabled] {
  background: #f4f6f9;
  color: #8a94a6;
  cursor: not-allowed;
}

.image-prompt-control small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.settings-grid select {
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 10px;
}

.model-loader {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px 8px;
  align-items: end;
  min-width: 0;
}

.model-loader label {
  min-width: 0;
}

.model-loader button {
  height: 30px;
  min-width: 52px;
  padding: 0 10px;
  font-size: 12px;
  white-space: nowrap;
}

.model-loader-small button {
  min-width: 46px;
  padding: 0 8px;
}

.model-loader span {
  grid-column: 1 / -1;
  min-height: 16px;
  color: var(--muted);
  font-size: 12px;
}

.ai-settings-actions {
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.settings-state {
  color: var(--muted);
  font-size: 12px;
}

.settings-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 14px;
}

.settings-actions button { min-width: 132px; }



.manual-calculator {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  gap: 6px;
  margin-bottom: 8px;
  padding: 8px 10px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 5px 14px rgba(23, 32, 51, 0.07);
}

.manual-calculator-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.manual-calculator-head span {
  color: var(--muted);
  font-size: 12px;
}

.manual-calculator-head {
  display: grid;
  grid-template-columns: max-content minmax(260px, 1fr);
  align-items: center;
  min-height: 18px;
  gap: 10px;
}

.manual-calculator-head strong {
  font-size: 13px;
  line-height: 1.2;
}

.manual-calculator-head span {
  overflow: hidden;
  line-height: 1.25;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.manual-calculator-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  align-items: end;
}

.manual-calculator-group {
  display: grid;
  gap: 6px;
  align-items: end;
}

.manual-calculator-base {
  grid-template-columns: repeat(7, minmax(62px, 1fr));
}

.manual-calculator-rules {
  grid-template-columns: repeat(7, minmax(62px, 1fr)) minmax(128px, auto);
}

.manual-calculator-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.manual-calculator-grid label {
  display: grid;
  gap: 2px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.2;
}

.manual-calculator-grid input, .manual-calculator-grid select {
  width: 100%;
  height: 28px;
  padding: 0 8px;
  font-size: 12px;
}

.manual-calculator-grid input[readonly],
.settings-grid input[readonly] {
  color: #52627a;
  background: #f5f7fb;
  cursor: default;
}

.manual-calculator-grid button {
  height: 28px;
  padding: 0 10px;
  font-size: 12px;
  white-space: nowrap;
}

.manual-calculator-result {
  min-height: 34px;
  display: block;
  overflow: visible;
  padding: 3px 5px;
  border: 1px solid #e0e8f3;
  border-radius: 6px;
  color: #33415c;
  background: #f8fbff;
  font-size: 12px;
  line-height: 1.25;
  white-space: normal;
}

.calc-result-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 3px;
}

.calc-result-title {
  display: grid;
  align-items: center;
  min-height: 28px;
  padding: 0 5px;
  color: #52627a;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.calc-result-card {
  display: grid;
  align-content: center;
  gap: 1px;
  min-width: 74px;
  min-height: 28px;
  padding: 3px 6px;
  border: 1px solid #e0e8f4;
  border-radius: 6px;
  background: #fff;
}

.calc-result-card em {
  color: #6a7890;
  font-size: 10px;
  font-style: normal;
  line-height: 1.1;
}

.calc-result-card strong {
  color: #172033;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.15;
}

.calc-result-card small {
  color: #6a7890;
  font-size: 10px;
  line-height: 1.1;
}

.calc-result-card.primary {
  min-width: 104px;
  border-color: #d5e6fa;
  background: #f6faff;
  box-shadow: none;
}

.calc-result-card.primary em,
.calc-result-card.primary small {
  color: #54708f;
}

.calc-result-card.primary strong {
  color: #1763a6;
  font-size: 14px;
}

.calc-result-card.profit strong {
  color: #157347;
}

.calc-result-card.wide {
  min-width: 118px;
}

.pricing-calc-result .calc-result-title {
  min-height: 28px;
}

.pricing-calc-result .calc-result-card {
  min-height: 26px;
  min-width: 70px;
  padding: 3px 5px;
}

.pricing-calc-result .calc-result-card.primary {
  min-width: 96px;
}

.pricing-calc-result .calc-result-card.primary strong {
  font-size: 13px;
}

.hint { margin-top: 12px; color: var(--muted); }

.guide { line-height: 1.7; }
.guide h3 + * { margin-top: 8px; }
.guide code { display: block; margin-top: 8px; padding: 10px; border-radius: 6px; background: #eef2f8; }

.placeholder h3 { font-size: 18px; }
.placeholder p { margin-top: 8px; color: var(--muted); line-height: 1.7; }

#editDialog {
  width: min(860px, calc(100vw - 32px));
  border: 0;
  border-radius: 8px;
  padding: 0;
}

#editDialog::backdrop, #categoryDialog::backdrop, .image-zoom-dialog::backdrop { background: rgba(23, 32, 51, 0.58); }
#editForm { padding: 22px; }
#editForm header, #editForm footer { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
#editSubtitle { margin-top: 6px; color: var(--muted); font-size: 12px; line-height: 1.4; }
#editForm footer { margin-top: 14px; justify-content: flex-end; }

.icon-button { width: 32px; padding: 0; color: var(--text); background: #eef2f8; }

#categoryDialog {
  width: min(920px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  border: 0;
  border-radius: 8px;
  padding: 0;
  background: #fff;
}

.category-dialog-shell {
  display: grid;
  gap: 10px;
  max-height: calc(100vh - 32px);
  overflow: auto;
  padding: 14px;
}

.category-dialog-shell header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.category-dialog-shell h3 {
  font-size: 16px;
  line-height: 1.3;
}

#categoryDialogSubtitle {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.category-current-box {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 10px;
  border: 1px solid #d9e8ff;
  border-radius: 8px;
  background: #f7fbff;
}

.category-current-box > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.category-current-box .wide {
  grid-column: 1 / -1;
}

.category-current-box span,
.category-manual-box summary,
.category-section-head span {
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
}

.category-current-box strong,
.category-current-box p {
  overflow: hidden;
  margin: 0;
  color: #172033;
  font-size: 13px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-picker-box {
  display: grid;
  gap: 10px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: #fff;
}

.category-search-box {
  display: grid;
  gap: 7px;
  padding: 9px;
  border: 1px solid #e3e7ee;
  border-radius: 8px;
  background: #fafbfc;
}

.category-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.category-section-head strong {
  color: #172033;
  font-size: 13px;
}

.category-picker-levels {
  display: grid;
  gap: 10px;
}

.category-picker-stack {
  display: grid;
  grid-auto-columns: minmax(210px, 1fr);
  grid-auto-flow: column;
  gap: 0;
  overflow-x: auto;
  border: 1px solid #d9dee7;
  border-radius: 8px;
  background: #fff;
}

.category-picker-column {
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
  min-height: 330px;
  border-right: 1px solid #e8ebf0;
}

.category-picker-column:last-child {
  border-right: 0;
}

.category-picker-column-title {
  padding: 10px 12px;
  border-bottom: 1px solid #e8ebf0;
  background: #f8f9fb;
  color: #667085;
  font-size: 12px;
  font-weight: 800;
}

.category-picker-options {
  display: grid;
  align-content: start;
  max-height: min(420px, calc(100vh - 210px));
  overflow: auto;
  padding: 6px;
}

#categoryDialog button.category-picker-option {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  width: 100%;
  height: 34px;
  padding: 0 8px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #273244;
  font-size: 13px;
  font-weight: 650;
  text-align: left;
}

#categoryDialog button.category-picker-option span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#categoryDialog button.category-picker-option i {
  color: #98a2b3;
  font-style: normal;
  font-size: 16px;
}

#categoryDialog button.category-picker-option:hover {
  background: #f3f4f6;
  color: #1f2937;
}

#categoryDialog button.category-picker-option.active {
  background: #eceff3;
  color: #111827;
  font-weight: 800;
}

#categoryDialog button.category-picker-option.active i {
  color: #667085;
}

.category-picked-card {
  display: grid;
  gap: 3px;
  padding: 8px 10px;
  border: 1px dashed #cbd5e1;
  border-radius: 7px;
  background: #f8fafc;
}

.category-picked-card.ready {
  border-color: #bde6cb;
  background: #f2fbf5;
}

.category-picked-card span {
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
}

.category-picked-card strong,
.category-picked-card p {
  overflow: hidden;
  margin: 0;
  color: #172033;
  font-size: 12px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-search-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
  align-items: end;
}

.category-search-form label {
  display: grid;
  gap: 4px;
  color: #334155;
  font-size: 12px;
  font-weight: 800;
}

.category-search-form input {
  height: 34px;
  border-color: #d9dee7;
  background: #fff;
  font-size: 13px;
}

.category-search-form button {
  height: 34px;
  min-width: 76px;
}

.category-search-state {
  color: #64748b;
  font-size: 11px;
}

.category-picker-state {
  color: #64748b;
  font-size: 11px;
}

.category-search-results {
  display: grid;
  gap: 6px;
  max-height: 180px;
  overflow: auto;
}

.category-result-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 8px;
  border: 1px solid #e2e8f0;
  border-radius: 7px;
  background: #fff;
}

.category-result-actions {
  display: flex;
  gap: 6px;
}

.category-result-actions button {
  min-width: 54px;
  height: 30px;
  padding: 0 10px;
}

.category-result-row > div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.category-result-row strong,
.category-result-row span,
.category-result-row em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-result-row strong {
  color: #172033;
  font-size: 13px;
}

.category-result-row span,
.category-result-row em {
  color: #64748b;
  font-size: 11px;
  font-style: normal;
}

.category-empty-result {
  padding: 8px 0;
  border: 0;
  border-radius: 0;
  color: #64748b;
  font-size: 13px;
}

.category-manual-box {
  display: grid;
  gap: 8px;
  padding-top: 4px;
}

.category-manual-box summary {
  cursor: pointer;
}

.category-manual-box .form-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.category-dialog-actions {
  display: flex;
  justify-content: flex-end;
  padding-top: 2px;
}

.category-dialog-actions button {
  min-width: 96px;
  height: 38px;
  background: #273244;
  color: #fff;
}

.category-dialog-actions button:hover {
  background: #111827;
}

.category-dialog-actions button:disabled {
  background: #d1d5db;
  color: #8b95a5;
}

.image-zoom-dialog {
  width: min(980px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  border: 0;
  border-radius: 8px;
  padding: 0;
  background: #fff;
}

.image-zoom-shell {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 12px;
  padding: 14px;
  max-height: calc(100vh - 32px);
}

.image-zoom-shell header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

#imageZoomImg {
  max-width: 100%;
  max-height: calc(100vh - 110px);
  object-fit: contain;
  justify-self: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fafc;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.form-grid input {
  height: 46px;
  font-size: 15px;
}

.form-grid label {
  font-size: 13px;
}

.empty {
  border: 1px dashed var(--line);
  border-radius: 8px;
  padding: 32px;
  color: var(--muted);
  text-align: center;
  background: #fff;
}

.empty.compact {
  padding: 16px;
  font-size: 12px;
}

.capture-import-panel {
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
  padding: 10px;
  border: 1px solid #d9e8fb;
  border-radius: 8px;
  background: #f8fbff;
}

.capture-import-head {
  display: grid;
  grid-template-columns: minmax(92px, 1fr) auto auto;
  gap: 10px;
  align-items: center;
}

#boxView .capture-import-head {
  grid-template-columns: auto auto auto minmax(0, 1fr);
  justify-content: start;
}

.capture-import-head > div {
  display: grid;
  gap: 2px;
}

.capture-import-head strong {
  color: #172033;
  font-size: 14px;
}

.capture-sku-mode-switch,
.capture-workflow-mode-switch {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  min-width: 0;
}

.capture-sku-mode-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 28px;
  min-height: 28px;
  padding: 0 12px;
  border: 1px solid #d6dde8;
  border-radius: 999px;
  background: #fff;
  color: #425168;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.capture-sku-mode-button span {
  width: 10px;
  height: 10px;
  border: 1px solid #a8b3c4;
  border-radius: 999px;
  background: #fff;
  box-shadow: inset 0 0 0 2px #fff;
}

.capture-sku-mode-button.active {
  border-color: #8fb5a4;
  background: #f4faf7;
  color: #275443;
}

.capture-sku-mode-button.active span {
  border-color: #2f6f5e;
  background: #2f6f5e;
}

.capture-queue-tools {
  display: grid;
  gap: 5px;
  justify-items: end;
  min-width: 0;
}

.capture-queue-controls {
  display: flex;
  flex-wrap: nowrap;
  gap: 5px;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
}

.capture-queue-controls button {
  height: 30px;
  min-height: 30px;
  min-width: 46px;
  padding: 0 10px;
  border-color: #d7dde6;
  background: #f5f6f8;
  color: #344054;
  font-weight: 700;
  font-size: 12px;
}

.capture-queue-controls .danger-soft {
  border-color: #e6c8c8;
  background: #f8eeee;
  color: #8a3333;
}

.capture-queue-state {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  min-height: 20px;
  padding: 0 8px;
  border: 1px solid #dde3ea;
  border-radius: 999px;
  background: #fff;
  color: #667085;
  font-size: 11px;
  line-height: 1.2;
  text-align: right;
  white-space: nowrap;
}

body[data-view="box"] #boxActions > #refresh {
  display: none;
}

body[data-view="customerService"] #boxActions > #search,
body[data-view="customerService"] #boxActions > #refresh {
  display: none;
}

.capture-queue-state.running {
  border-color: #d5ded8;
  background: #f4f7f5;
  color: #3f584a;
}

.capture-queue-state.paused {
  border-color: #e6dcc5;
  background: #faf7ef;
  color: #725c2e;
}

.capture-import-head span,
.capture-import-panel label,
.capture-import-panel summary,
.capture-import-panel small,
.capture-import-panel em,
.capture-import-panel p,
#captureImportState {
  color: var(--muted);
  font-size: 12px;
}

.capture-import-grid {
  display: grid;
  grid-template-columns: 120px minmax(360px, 1fr) auto;
  gap: 8px;
  align-items: end;
}

.capture-import-grid label,
.capture-link-combo-field {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.capture-import-grid input,
.capture-import-grid select,
.capture-bulk-panel textarea,
.capture-paste-box textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  font-size: 12px;
}

.capture-import-grid input,
.capture-import-grid select {
  height: 32px;
  padding: 0 8px;
}

.capture-import-grid button,
.capture-import-head button,
.capture-paste-box button {
  height: 28px;
  padding: 0 9px;
  font-size: 11px;
  white-space: nowrap;
}

#boxView button {
  height: 26px;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 5px;
  font-size: 11px;
  line-height: 1.1;
}

#boxView .capture-import-grid button,
#boxView .capture-import-head button,
#boxView .capture-paste-box button {
  height: 28px;
}

#boxView .capture-import-grid button {
  height: 32px;
  min-height: 32px;
}

#boxView .capture-sku-mode-button {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 28px;
  min-height: 28px;
  padding: 0 12px;
  border: 1px solid #d3dae3;
  border-radius: 999px;
  background: #f7f8fa;
  color: #3f4a5a;
  font-size: 12px;
  font-weight: 700;
}

#boxView .capture-sku-mode-button span {
  width: 10px;
  height: 10px;
  border: 1px solid #9aa5b4;
  border-radius: 999px;
  background: #fff;
  box-shadow: inset 0 0 0 2px #fff;
}

#boxView .capture-sku-mode-button.active {
  border-color: #91a699;
  background: #eef4f0;
  color: #263f34;
}

#boxView .capture-sku-mode-button.active span {
  border-color: #5d7a6b;
  background: #5d7a6b;
}

#boxView .capture-import-head .capture-sku-mode-switch,
#boxView .capture-import-head .capture-workflow-mode-switch {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
}

#boxView .capture-queue-controls button {
  height: 28px;
  min-height: 28px;
  padding: 0 9px;
}

#boxView .capture-job-list button {
  height: 26px;
  min-height: 26px;
  padding: 0 8px;
}

.capture-link-combo {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px;
  align-items: center;
}

.capture-link-combo-field,
.capture-file-field {
  grid-column: 2;
}

#queueSingleCapture,
#queueFileCapture {
  grid-column: 3;
}

#queueSingleCapture {
  align-self: start;
  margin-top: 21px;
}

#captureImportState {
  grid-column: 1 / -1;
  min-height: 0;
}

.capture-bulk-toggle {
  min-width: 56px;
}

.capture-bulk-toggle.active {
  border-color: #b8cbe5;
  background: #edf5ff;
  color: #1c5da8;
}

.capture-bulk-panel[hidden] {
  display: none;
}

.capture-bulk-panel textarea {
  min-height: 64px;
  padding: 8px;
  resize: vertical;
}

.capture-import-inline-state,
#captureImportState {
  line-height: 1.45;
}

.capture-import-inline-state:empty,
.capture-import-inline-state[hidden] {
  display: none;
}

.capture-paste-box {
  display: grid;
  gap: 8px;
  padding: 8px;
  border: 1px solid #edf1f7;
  border-radius: 8px;
  background: #fff;
}

.capture-paste-box > summary {
  cursor: pointer;
  list-style: none;
}

.capture-paste-box > summary::-webkit-details-marker {
  display: none;
}

.capture-paste-box textarea {
  min-height: 74px;
  padding: 8px;
  resize: vertical;
}

.capture-paste-box > div {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}

.capture-job-list {
  display: grid;
  gap: 6px;
}

.capture-job-log {
  display: grid;
  gap: 6px;
  border: 1px solid #dfe6ef;
  border-radius: 8px;
  background: #fff;
}

.capture-job-log-head {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  padding: 6px 8px;
  border-bottom: 1px solid #edf1f7;
  background: #f8fafc;
}

.capture-job-log-head strong {
  color: #172033;
  font-size: 12px;
}

.capture-job-log-head span {
  color: var(--muted);
  font-size: 11px;
}

.capture-job-workspace {
  display: grid;
  grid-template-columns: minmax(360px, .92fr) minmax(420px, 1.18fr);
  gap: 10px;
  align-items: start;
}

.capture-job-column,
.capture-job-detail-panel {
  min-width: 0;
  border: 1px solid #dfe8f5;
  border-radius: 8px;
  background: #fff;
}

.capture-job-column {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.capture-job-column-head,
.capture-job-detail-head {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  min-width: 0;
  padding: 7px 8px;
  border-bottom: 1px solid #edf1f7;
  background: #f8fbff;
}

.capture-job-column-head strong,
.capture-job-detail-head strong {
  overflow: hidden;
  color: #172033;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.capture-job-column-head span,
.capture-job-detail-head span,
.capture-job-detail-head em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
}

.capture-job-rows {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: min(58vh, 620px);
  overflow: auto;
  overscroll-behavior: contain;
  padding: 6px;
  scrollbar-gutter: stable;
}

.capture-job-rows.compact {
  max-height: min(28vh, 260px);
}

.capture-job-detail-panel {
  display: grid;
  gap: 8px;
  max-height: min(72vh, 760px);
  overflow: auto;
  padding: 0 8px 8px;
}

.capture-job-detail-panel.empty-detail {
  min-height: 180px;
  align-content: center;
  justify-items: center;
  padding: 24px;
  color: var(--muted);
  text-align: center;
}

.capture-job-detail-head {
  position: sticky;
  top: 0;
  z-index: 2;
  margin: 0 -8px;
  border-radius: 8px 8px 0 0;
}

.capture-job-detail-head > div:nth-child(2) {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.capture-job-detail-head > div:nth-child(2) span {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
}

.capture-job-detail-no {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border: 1px solid #b9d7ff;
  border-radius: 7px;
  color: #075bb8;
  background: #eaf3ff;
  font-weight: 800;
  font-size: 15px;
}

.capture-job-bulk-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: space-between;
  padding: 5px 7px;
  border: 1px solid #d8e8fb;
  border-radius: 6px;
  background: #f6fbff;
}

.capture-job-bulk-bar > div {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
}

.capture-job-bulk-bar strong {
  color: #172033;
  font-size: 12px;
}

.capture-job-bulk-bar span {
  color: var(--muted);
  font-size: 11px;
}

.capture-job-empty {
  padding: 8px;
  border: 1px dashed #d8e3f3;
  border-radius: 6px;
  color: var(--muted);
  background: #fff;
  font-size: 12px;
}

.capture-job-row {
  display: grid;
  gap: 6px;
  min-height: 58px;
  padding: 5px 6px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
  content-visibility: auto;
  contain-intrinsic-size: 64px;
}

.capture-job-row.active {
  border-color: #9dccff;
  background: #f3f8ff;
  box-shadow: inset 3px 0 0 #1f6fe5;
}

.capture-job-main {
  display: grid;
  grid-template-columns: 18px 40px minmax(0, 1fr) minmax(178px, auto);
  gap: 6px;
  align-items: center;
  min-width: 0;
}

.capture-product-checkbox {
  justify-self: center;
}

.capture-job-product-bulk {
  border-color: #dfe7f3;
  background: #fbfcff;
}

.capture-job-number {
  display: grid;
  justify-items: center;
  align-content: center;
  width: 38px;
  height: 32px;
  border: 1px solid #c8ddfb;
  border-radius: 7px;
  color: #075bb8;
  background: #eef6ff;
}

.capture-job-number b {
  line-height: 1;
  font-size: 15px;
  font-weight: 850;
}

.capture-job-number small {
  margin-top: 1px;
  color: #527197;
  line-height: 1;
  font-size: 9px;
}

.capture-job-row > div,
.capture-job-main > div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.capture-job-main > .capture-job-actions {
  display: flex;
  min-width: 0;
}

.capture-job-info {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.capture-job-info small {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
  min-width: 0;
}

.capture-job-info small em {
  color: var(--muted);
  font-style: normal;
}

.capture-job-info small .badge {
  max-width: 104px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.capture-job-row strong,
.capture-job-row em,
.capture-job-row p {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.capture-job-row strong {
  color: #172033;
  font-size: 12px;
  line-height: 1.15;
}

.capture-job-row em {
  font-style: normal;
  font-size: 11px;
}

.capture-job-row p {
  margin: 0;
  color: #52627a;
  font-size: 11px;
  line-height: 1.2;
}

.capture-job-url {
  overflow: hidden;
  color: #0b63ce;
  text-decoration: none;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}

.capture-job-url:hover {
  text-decoration: underline;
}

.capture-job-url.muted {
  color: var(--muted);
  font-style: normal;
}

.capture-job-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-content: center;
  justify-content: flex-end;
  min-width: 0;
}

.capture-job-actions button {
  flex: 0 0 auto;
  max-width: 100%;
  white-space: nowrap;
}

.capture-toggle-button {
  border-color: #b9d7ff;
  color: #0b63ce;
  background: #eaf3ff;
  font-weight: 700;
  min-width: 68px;
}

.capture-toggle-button.active {
  border-color: #0b63ce;
  color: #fff;
  background: #1f6fe5;
}

.inline-link-button {
  display: inline-flex;
  align-items: center;
  width: auto;
  max-width: 100%;
  height: auto;
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: #0b63ce;
  background: transparent;
  text-align: left;
  font: inherit;
  cursor: pointer;
}

.inline-link-button:hover {
  text-decoration: underline;
}

.capture-job-manual {
  display: grid;
  gap: 7px;
  padding: 8px;
  border: 1px solid #fecaca;
  border-left: 4px solid #dc2626;
  border-radius: 6px;
  background: #fff7f7;
}

.capture-job-manual-head,
.capture-job-manual-meta,
.capture-job-manual-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: space-between;
}

.capture-job-manual-head strong {
  color: #991b1b;
  font-size: 13px;
}

.capture-job-manual-head span,
.capture-job-manual-meta span {
  color: #6b7280;
  font-size: 11px;
}

.capture-job-manual-reason {
  display: grid;
  gap: 3px;
  padding: 7px;
  border: 1px solid #fee2e2;
  border-radius: 6px;
  background: #fff;
}

.capture-job-manual-reason b {
  color: #7f1d1d;
  font-size: 11px;
}

.capture-job-manual-reason p {
  overflow: visible;
  margin: 0;
  color: #374151;
  white-space: normal;
  font-size: 12px;
  line-height: 1.35;
}

.capture-job-manual-actions {
  justify-content: flex-end;
}

.capture-work-overlay {
  position: fixed;
  top: 86px;
  bottom: auto;
  right: 22px;
  z-index: 80;
  pointer-events: none;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  width: min(430px, calc(100vw - 34px));
  padding: 12px;
  border: 1px solid #b8dafc;
  border-radius: 8px;
  background: rgba(248, 252, 255, .98);
  box-shadow: 0 16px 42px rgba(18, 52, 89, .16);
}

.capture-work-orbit {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, #1f6fe5, #36c5f0, #22c55e, #1f6fe5);
  animation: captureSpin 1.1s linear infinite;
}

.capture-work-orbit::before {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: inherit;
  background: #f8fcff;
}

.capture-work-orbit i {
  position: absolute;
  inset: 13px;
  z-index: 1;
  border-radius: inherit;
  background: #1f6fe5;
  box-shadow: 0 0 0 6px rgba(31, 111, 229, .12);
}

.capture-work-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.capture-work-copy strong {
  color: #0f2754;
  font-size: 14px;
}

.capture-work-copy span,
.capture-work-copy em,
.capture-work-stats span {
  overflow: hidden;
  color: #53647d;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
  font-style: normal;
}

.capture-work-stats {
  display: grid;
  gap: 1px;
  justify-items: end;
  color: #0f2754;
}

.capture-work-stats b {
  font-size: 18px;
}

body[data-view="box"] .workflow-automation-overlay {
  top: auto;
  bottom: 24px;
}

body[data-view="box"] .capture-work-overlay {
  top: 132px;
}

.workflow-automation-overlay {
  position: fixed;
  top: 86px;
  right: 22px;
  z-index: 82;
  pointer-events: auto;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  width: min(460px, calc(100vw - 34px));
  padding: 12px;
  border: 1px solid #d3d9e2;
  border-radius: 8px;
  background: rgba(252, 253, 255, 0.98);
  box-shadow: 0 16px 36px rgba(31, 41, 55, 0.14);
  backdrop-filter: blur(4px);
}

.workflow-automation-overlay.paused {
  border-color: #d9caa8;
  background: rgba(255, 250, 239, 0.98);
}

.workflow-automation-overlay.stopped {
  border-color: #d8dbe1;
  background: rgba(245, 247, 249, 0.98);
}

.workflow-automation-orbit {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, #5b6473, #7c8f8b, #14b8a6, #5b6473);
  animation: captureSpin 1.1s linear infinite;
}

.workflow-automation-orbit::before {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: inherit;
  background: #fdfdfd;
}

.workflow-automation-orbit i {
  position: absolute;
  inset: 13px;
  z-index: 1;
  border-radius: inherit;
  background: #445062;
  box-shadow: 0 0 0 6px rgba(68, 80, 98, 0.12);
}

.workflow-automation-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.workflow-automation-copy strong {
  color: #101828;
  font-size: 14px;
}

.workflow-automation-copy span,
.workflow-automation-copy em,
.workflow-automation-copy small {
  overflow: hidden;
  color: #556070;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
  font-style: normal;
}

.workflow-automation-bar {
  overflow: hidden;
  height: 6px;
  border-radius: 999px;
  background: #e5e9ef;
}

.workflow-automation-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #566173, #6f8b7b);
}

.workflow-automation-overlay.paused .workflow-automation-bar i {
  background: linear-gradient(90deg, #9b7c3f, #b89a58);
}

.workflow-automation-overlay.stopped .workflow-automation-bar i {
  background: linear-gradient(90deg, #66707e, #8b95a3);
}

.workflow-automation-stats {
  display: grid;
  gap: 6px;
  justify-items: end;
  min-width: 0;
}

.workflow-automation-stats b {
  color: #101828;
  font-size: 18px;
}

.workflow-automation-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.workflow-automation-actions button {
  height: 28px;
  min-height: 28px;
  padding: 0 10px;
  border-color: #d7dde5;
  background: #fff;
  color: #344054;
  font-size: 12px;
  font-weight: 700;
}

.workflow-automation-actions .danger-soft {
  border-color: #e2c7c7;
  background: #fbf1f1;
  color: #8a3333;
}

.workflow-automation-actions button.danger {
  border-color: #e2c7c7;
  background: #fbf1f1;
  color: #8a3333;
}

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

.capture-job-product {
  display: grid;
  gap: 6px;
  padding: 8px;
  border: 1px solid #e7edf6;
  border-radius: 6px;
  background: #f8fafd;
}

.capture-job-product.empty {
  color: var(--muted);
  font-size: 12px;
}

.capture-job-product-summary {
  display: grid;
  grid-template-columns: 32px 64px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: start;
  padding: 5px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
}

.capture-job-product-info {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.capture-job-product-info h3 {
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  margin: 0;
  color: #172033;
  font-size: 13px;
  line-height: 1.35;
}

.capture-job-product-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

.capture-job-product-actions button {
  white-space: nowrap;
}

.capture-job-sku-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: space-between;
  padding: 5px 7px;
  border: 1px solid #e3edf8;
  border-radius: 6px;
  background: #fdfefe;
}

.capture-job-sku-toolbar > div {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
}

.capture-job-sku-toolbar strong {
  color: #172033;
  font-size: 11px;
}

.capture-job-sku-toolbar span {
  color: var(--muted);
  font-size: 11px;
}

.capture-job-product-head {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.capture-job-product-head > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.capture-job-product-head strong,
.capture-job-product-head em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.capture-job-product-head small,
.capture-job-product-head em {
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
}

.capture-job-sku-list {
  display: grid;
  gap: 4px;
  max-height: 280px;
  overflow: auto;
}

.capture-job-sku-row {
  display: grid;
  grid-template-columns: 18px 26px 38px minmax(0, 1fr) minmax(120px, .8fr) auto;
  gap: 6px;
  align-items: center;
  padding: 4px 5px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
}

.capture-job-sku-row span {
  color: var(--muted);
  font-weight: 700;
  text-align: center;
}

.capture-job-sku-row strong,
.capture-job-sku-row em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.capture-job-sku-row em {
  color: #52627a;
  font-style: normal;
}

.capture-job-sku-row button {
  min-height: 24px;
  padding: 0 7px;
  white-space: nowrap;
}

@media (max-width: 1180px) {
  .image-workspace-grid {
    margin: 0 8px 8px;
  }

  .listing-card-prepare {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "analysis"
      "pricing";
    margin: 0 8px 8px;
    max-width: none;
  }

  .listing-card-prepare:has(> .upload-sku-preview) {
    grid-template-columns: minmax(320px, 0.9fr) minmax(320px, 1.1fr);
    grid-template-areas:
      "analysis analysis"
      "pricing sku";
  }

  .listing-card-prepare .listing-analysis-compact {
    grid-template-columns: minmax(220px, 0.84fr) minmax(0, 1.16fr);
    grid-template-areas:
      "category checks"
      "title checks"
      "note note";
  }

  .image-summary {
    grid-template-columns: 16px 22px 40px minmax(0, 1fr) minmax(240px, 0.8fr) minmax(164px, 0.36fr);
    padding: 5px 7px;
  }

  .image-card .listing-main-actions {
    position: static;
    top: auto;
    right: auto;
    width: auto;
    min-width: 164px;
  }

  .image-workspace-grid.has-skus {
    grid-template-columns: minmax(0, 1fr);
  }

  .image-workspace-grid.has-skus .public-image-result .generated-image-grid {
    grid-template-columns: repeat(auto-fill, minmax(72px, 82px));
  }

  .image-workspace-grid .image-sku-grid {
    grid-template-columns: repeat(auto-fill, minmax(72px, 82px));
  }

  .analysis-card .category-summary {
    grid-template-columns: 16px 24px 42px minmax(0, 1fr) 82px;
  }

  .analysis-card .analysis-main {
    display: grid;
    grid-column: 4;
    gap: 5px;
    min-width: 0;
  }

  .analysis-card .product-info,
  .analysis-card .analysis-metrics-grid {
    grid-column: auto;
  }

  .analysis-metrics-grid {
    grid-template-columns: minmax(320px, 1.1fr) minmax(220px, 0.9fr);
  }

  .manual-calculator-base {
    grid-template-columns: repeat(4, minmax(74px, 1fr));
  }

  .manual-calculator-rules {
    grid-template-columns: repeat(4, minmax(74px, 1fr));
  }

  .manual-calculator-actions {
    grid-column: span 2;
  }

  .upload-sku-preview {
    margin-left: 72px;
  }

  .upload-sku-preview-row {
    grid-template-columns: 50px minmax(240px, 1fr);
  }

  .upload-sku-meta {
    grid-column: 2;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  body { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .image-card .image-public-panel {
    grid-template-columns: minmax(0, 1fr);
  }
  .image-workspace-grid.has-skus .image-public-panel {
    grid-template-columns: minmax(0, 1fr);
  }
  .image-card .image-public-panel .public-image-result,
  .image-card .image-public-panel .image-sku-inline {
    grid-column: 1;
    grid-row: auto;
  }
  .image-workspace-grid.has-skus .image-public-panel .image-zone-title,
  .image-workspace-grid.has-skus .image-public-panel .public-image-result,
  .image-workspace-grid.has-skus .image-public-panel .image-sku-inline {
    grid-column: 1;
    grid-row: auto;
  }
  .image-workspace-grid .image-sku-grid {
    max-height: none;
  }
  body[data-view="image"] main {
    height: auto;
    overflow: visible;
    padding: 12px 14px 80px;
  }
  .listing-workbench-view.active {
    height: auto;
    overflow: visible;
  }
  #imageList {
    max-height: none;
    overflow: visible;
    padding-right: 0;
  }
  #imageList .batch-bar {
    position: static;
  }
  .toolbar, .card, .product-summary, .checked-card .product-summary { grid-template-columns: 1fr; display: grid; }
  body[data-view="analysis"] .toolbar > div:first-child { grid-template-columns: 1fr; }
  body[data-view="analysis"] .toolbar-actions { flex-wrap: wrap; }
  body[data-view="analysis"] .toolbar-actions input[type="search"] { width: 100%; }
  .category-summary { grid-template-columns: 1fr; }
  .listing-stage-head,
  .listing-stage-head > div {
    display: grid;
    gap: 4px;
  }

  .listing-stage-head span {
    white-space: normal;
  }

  .analysis-card .category-summary { grid-template-columns: 16px 24px 42px minmax(0, 1fr); }
  .analysis-card .analysis-main { display: grid; grid-column: 4; grid-template-columns: 1fr; }
  .analysis-card .product-info,
  .analysis-card .analysis-metrics-grid { grid-column: auto; }
  .analysis-metrics-grid { grid-template-columns: 1fr; }
  .analysis-card .analysis-match-slot,
  .analysis-card .analysis-price-slot,
  .analysis-card .category-actions { grid-column: 1 / -1; }
  .analysis-card .category-actions { justify-content: flex-start; }
  .upload-prepare-checks,
  .upload-prepare-panel.expanded .upload-prepare-checks {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .analysis-card .ozon-listing.category-listing {
    grid-template-columns: 1fr;
    margin: 0 8px 8px;
  }
  .analysis-card .ozon-listing.category-listing .category-match-title,
  .analysis-card .ozon-listing.category-listing .ozon-title:not(.category-match-title) {
    grid-column: 1;
  }
  .analysis-card .ozon-grid-compact {
    grid-template-columns: 1fr;
  }
  .analysis-card .ozon-grid-compact .ozon-panel.wide {
    grid-column: 1;
  }
  .upload-sku-preview {
    margin: 0 8px 10px;
  }
  .listing-card-prepare {
    grid-template-columns: 1fr;
    grid-template-areas:
      "analysis"
      "pricing"
      "sku";
    margin: 0 8px 8px;
  }
  .listing-card-prepare:has(> .upload-sku-preview) {
    grid-template-columns: 1fr;
    grid-template-areas:
      "analysis"
      "pricing"
      "sku";
  }
  .listing-analysis-compact {
    grid-template-columns: 1fr;
  }
  .listing-card-prepare .listing-analysis-compact {
    grid-template-columns: 1fr;
    grid-template-areas:
      "category"
      "title"
      "checks"
      "note";
  }
  .listing-checks-mini {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .listing-card-prepare .listing-analysis-compact .listing-checks-mini span:nth-child(4),
  .listing-card-prepare .listing-analysis-compact .listing-checks-mini span:nth-child(5),
  .listing-card-prepare .listing-analysis-compact .listing-checks-mini span:nth-child(6) {
    grid-column: auto;
    grid-row: auto;
  }
  .listing-card-prepare .listing-pricing-panel .pricing-compact.readonly.with-listing {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(4, minmax(0, 1fr));
    grid-template-areas:
      "sale purchase"
      "freight profit"
      "commission logistics"
      "listing listing";
  }
  .listing-primary-actions,
  .listing-secondary-actions,
  .listing-flow {
    grid-template-columns: 1fr;
  }
  .upload-sku-preview-head {
    align-items: flex-start;
    flex-direction: column;
  }
  .upload-sku-preview-row,
  .upload-sku-meta {
    grid-template-columns: 1fr;
  }
  .upload-sku-meta {
    grid-column: auto;
  }
  .analysis-match-slot .category-match-summary { grid-template-columns: 1fr; }
  .registered-product-toolbar, .registered-product-summary, .product-account-card { align-items: stretch; flex-direction: column; display: flex; }
  .capture-import-head { grid-template-columns: 1fr; align-items: stretch; }
  .capture-sku-mode-switch { justify-content: flex-start; flex-wrap: wrap; }
  .capture-link-combo { grid-template-columns: minmax(0, 1fr) auto; }
  .capture-link-combo-field,
  .capture-file-field,
  #queueSingleCapture,
  #queueFileCapture {
    grid-column: 1;
  }
  #queueSingleCapture {
    margin-top: 0;
  }
  #captureImportState {
    grid-column: 1;
  }
  .capture-paste-box > div { align-items: stretch; flex-direction: column; }
  .capture-import-grid, .capture-job-workspace, .capture-job-main, .capture-job-sku-row, .capture-job-product-summary,
  .customer-service-workspace, .customer-service-row { grid-template-columns: 1fr; }
  .customer-service-bulk-bar { grid-template-columns: 1fr; }
  .customer-service-bulk-actions { justify-content: flex-start; }
  .customer-service-status-filters { justify-content: flex-start; }
  .customer-service-row-main { grid-template-columns: 18px 52px minmax(0, 1fr); }
  .customer-service-row-main .analysis-product-thumb { grid-column: 2; grid-row: 2; }
  .customer-service-row-main .customer-service-no { grid-column: 2; grid-row: 1; }
  .customer-service-row-main .customer-service-row-info { grid-column: 3; grid-row: 1 / span 2; }
  .customer-service-row-main .customer-service-row-actions { grid-column: 1 / -1; }
  .customer-service-row-info { grid-template-columns: 1fr; }
  .capture-job-rows, .capture-job-detail-panel, .customer-service-rows { max-height: none; }
  .capture-job-actions, .customer-service-row-actions { justify-content: flex-start; max-width: none; }
  .capture-work-overlay {
    top: auto;
    right: 12px;
    bottom: 12px;
    left: 12px;
    width: auto;
    grid-template-columns: 36px minmax(0, 1fr);
  }
  .capture-work-stats { display: none; }
  .registered-product-filters { justify-content: stretch; }
  .registered-product-filters input, .registered-product-filters select, .registered-product-filters button { width: 100%; }
  .price-box { text-align: left; }
  .stats, .settings-grid, .module-grid, .form-grid { grid-template-columns: 1fr; }
  .compact-api-grid { grid-template-columns: 1fr; }
  .provider-settings-head { align-items: flex-start; flex-direction: column; }
  .sku-chip { grid-template-columns: 34px 1fr auto; }
  .sku-chip small { grid-column: 2 / -1; }
  .sku-panel-box { padding: 10px; }
  .pricing-summary { margin: 0 0 10px; }
  .ozon-listing { margin: 0 0 10px; }
  .category-card .ozon-listing { margin: 0 0 10px; }
  .category-card .ozon-listing.image-public-panel { margin: 0 0 8px; }
  .image-workspace-grid,
  .image-workspace-grid.has-skus {
    grid-template-columns: 1fr;
    margin: 0 0 8px;
  }
  .image-workspace-grid .image-sku-grid {
    grid-template-columns: repeat(auto-fill, minmax(72px, 82px));
    justify-content: start;
  }
  .image-workspace-grid.has-skus .public-image-result .generated-image-grid {
    grid-template-columns: repeat(auto-fill, minmax(72px, 82px));
  }
  .ozon-grid { grid-template-columns: 1fr; }
  .ozon-attr-row { grid-template-columns: 1fr; padding: 6px 0; }
  .pricing-title { align-items: flex-start; flex-direction: column; }
  .pricing-compact { grid-template-columns: 1fr; }
  .product-pricing-slot .pricing-compact { grid-template-columns: 1fr; }
  .pricing-compact.readonly { grid-template-columns: 1fr; }
  .pricing-compact .pricing-pill.logistics { grid-column: auto; }
  .pricing-row { grid-template-columns: 1fr; }
  .pricing-row.error span { grid-column: auto; }
  .pricing-editor { grid-template-columns: 1fr; }
  .pricing-col, .pricing-col:nth-of-type(3), .pricing-col:nth-of-type(4) { grid-template-columns: 1fr; }
  .pricing-left, .pricing-calc-panel { grid-template-columns: 1fr; }
  .pricing-wide, .pricing-rules { grid-column: auto; }
  .manual-calculator { position: static; }
  .manual-calculator-head { align-items: flex-start; grid-template-columns: 1fr; }
  .manual-calculator-head span { text-align: left; }
  .manual-calculator-grid, .manual-calculator-base, .manual-calculator-rules { grid-template-columns: 1fr; }
  .manual-calculator-actions { grid-template-columns: 1fr; }
  .calc-result-title { width: 100%; min-height: auto; }
  .calc-result-card { flex: 1 1 112px; }
  .calc-result-card.primary { flex-basis: 132px; }
  .batch-bar, .sku-bulk-bar { align-items: stretch; flex-direction: column; }
  .batch-actions, .sku-bulk-bar > div { justify-content: flex-start; }
  .image-sku-toolbar { align-items: stretch; flex-direction: column; }
  .image-sku-grid {
    grid-template-columns: repeat(auto-fill, minmax(72px, 82px));
    justify-content: start;
  }
  .image-zone-title { align-items: flex-start; flex-direction: column; }
  .image-fold-actions { justify-content: flex-start; }
  .sku-row-detail { grid-template-columns: 18px 28px 52px minmax(0, 1fr); }
  .sku-data { grid-column: 4 / -1; }
  .sku-actions { grid-column: 4 / -1; justify-content: flex-start; }
}

.product-account-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.product-account-card h3 { font-size: 18px; }
.product-account-card p { margin-top: 4px; color: var(--muted); font-size: 12px; }

#productsView .product-account-card,
#productsView .registered-product-toolbar {
  flex: 0 0 auto;
}

.product-list {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.product-list-body {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.product-list-empty {
  flex: 1 1 auto;
  display: grid;
  place-items: center;
  min-height: 220px;
}

.product-login-form {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.product-login-form input {
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 10px;
}

.product-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.product-feedback-table {
  width: 100%;
  min-width: 1120px;
  border-collapse: collapse;
  font-size: 12px;
}

.product-feedback-table th, .product-feedback-table td {
  padding: 9px 10px;
  border-bottom: 1px solid #edf1f7;
  text-align: left;
  vertical-align: top;
}

.product-feedback-table th {
  color: var(--muted);
  background: #f8fafd;
  font-weight: 600;
}

.registered-product-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.registered-product-toolbar > div:first-child {
  display: grid;
  gap: 3px;
}

.registered-product-toolbar span {
  color: var(--muted);
  font-size: 12px;
}

.registered-product-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.registered-product-filters input,
.registered-product-filters select {
  height: 34px;
  min-width: 150px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 10px;
  background: #fff;
}

.registered-product-filters input { min-width: 250px; }

.product-report-toolbar {
  margin-bottom: 10px;
  padding: 9px 10px;
  background: #fbfcff;
}

.product-report-toolbar strong {
  font-size: 14px;
}

.product-report-table-shell {
  flex: 1 1 auto;
  min-height: 0;
  max-height: 100%;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.product-report-table {
  width: 100%;
  min-width: 930px;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
  font-size: 12px;
}

.product-report-table th,
.product-report-table td {
  padding: 8px 9px;
  border-bottom: 1px solid #edf1f7;
  text-align: left;
  vertical-align: middle;
}

.product-report-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: #5d6b82;
  background: #f6f8fc;
  font-weight: 700;
  white-space: nowrap;
}

.product-report-table tr:last-child td {
  border-bottom: none;
}

.product-report-group-row:hover td {
  background: #fbfdff;
}

.product-report-table td {
  color: #253044;
  line-height: 1.35;
  word-break: break-word;
}

.product-report-table td small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.product-report-table th:nth-child(1),
.product-report-table td:nth-child(1) { width: 250px; }
.product-report-table th:nth-child(2),
.product-report-table td:nth-child(2) { width: 155px; }
.product-report-table th:nth-child(3),
.product-report-table td:nth-child(3) { width: 92px; }
.product-report-table th:nth-child(4),
.product-report-table td:nth-child(4) { width: 84px; }
.product-report-table th:nth-child(5),
.product-report-table td:nth-child(5) { width: 100px; }
.product-report-table th:nth-child(6),
.product-report-table td:nth-child(6) { width: 120px; }
.product-report-table th:nth-child(7),
.product-report-table td:nth-child(7) { width: 130px; }

.product-report-name {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

.product-report-name strong {
  display: -webkit-box;
  overflow: hidden;
  color: #172033;
  font-size: 12px;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.product-report-meta-line {
  display: flex !important;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
}

.product-report-meta-line span:not(.product-source-badge) {
  color: #607089;
}

.product-report-thumb {
  width: 42px;
  height: 42px;
  border: 1px solid #e4ebf5;
  border-radius: 6px;
  background: #f7f9fc;
  object-fit: cover;
}

.product-report-thumb.image-placeholder {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 11px;
}

.product-register-table .product-report-name {
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 10px;
}

.product-register-table .product-report-thumb {
  width: 54px;
  height: 54px;
}

.product-source-badge {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.product-source-badge.uploaded {
  color: #0f6a46;
  background: #e6f6ee;
}

.product-source-badge.store {
  color: #56657a;
  background: #eef2f7;
}

.product-report-sku-pill {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  color: #174a8b;
  background: #eaf2ff;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.product-report-sku-toggle {
  display: block;
  width: fit-content;
  height: 24px;
  margin-top: 6px;
  padding: 0 8px;
  font-size: 11px;
}

.product-report-id-cell strong,
.product-report-cost-cell strong,
.product-report-profit-cell strong {
  display: block;
  color: #172033;
  font-weight: 700;
  line-height: 1.35;
}

.product-report-sku-cell {
  text-align: left;
}

.product-report-detail-row td {
  padding: 0;
  background: #f8fafd;
}

.product-report-sku-detail {
  padding: 8px 10px 10px;
  overflow-x: auto;
}

.product-report-sku-detail table {
  width: 100%;
  min-width: 920px;
  border-collapse: collapse;
  table-layout: fixed;
  background: #fff;
  border: 1px solid #e4ebf5;
  border-radius: 6px;
  overflow: hidden;
}

.product-report-sku-detail th,
.product-report-sku-detail td {
  padding: 7px 8px;
  border-bottom: 1px solid #edf1f7;
  font-size: 11px;
  vertical-align: top;
}

.product-report-sku-detail th {
  color: #617089;
  background: #f4f7fb;
  font-weight: 700;
}

.product-report-sku-detail tr:last-child td {
  border-bottom: none;
}

.product-report-sku-detail th:nth-child(1),
.product-report-sku-detail td:nth-child(1) { width: 34px; }
.product-report-sku-detail th:nth-child(2),
.product-report-sku-detail td:nth-child(2) { width: 50px; }
.product-report-sku-detail th:nth-child(3),
.product-report-sku-detail td:nth-child(3) { width: 220px; }
.product-report-sku-detail th:nth-child(4),
.product-report-sku-detail td:nth-child(4) { width: 120px; }
.product-report-sku-detail th:nth-child(5),
.product-report-sku-detail td:nth-child(5) { width: 150px; }
.product-report-sku-detail th:nth-child(6),
.product-report-sku-detail td:nth-child(6) { width: 82px; }
.product-report-sku-detail th:nth-child(7),
.product-report-sku-detail td:nth-child(7) { width: 115px; }
.product-report-sku-detail th:nth-child(8),
.product-report-sku-detail td:nth-child(8) { width: 150px; }

.product-report-sku-thumb {
  width: 42px;
  height: 42px;
  border: 1px solid #e4ebf5;
  border-radius: 6px;
  background: #f7f9fc;
  object-fit: cover;
}

.product-report-sku-thumb.image-placeholder {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 10px;
}

.product-report-sku-name strong {
  display: -webkit-box;
  overflow: hidden;
  color: #172033;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.product-report-sku-spec {
  color: #2d3a4f;
}

.product-report-sku-row .sku-index {
  color: #6b778c;
  font-weight: 700;
  text-align: center;
}

.profit-cell {
  color: var(--green);
  font-weight: 700;
}

.product-report-table small.profit-cell {
  color: var(--green);
  font-weight: 700;
}

.muted-cell {
  color: var(--muted);
}

.product-report-table a {
  color: var(--blue);
  font-weight: 700;
  text-decoration: none;
}

.product-report-table a:hover {
  text-decoration: underline;
}

.product-register-table {
  min-width: 1600px;
}

.product-register-table th,
.product-register-table td {
  padding: 9px 10px;
}

.product-register-table th:nth-child(1),
.product-register-table td:nth-child(1) { width: 82px; }
.product-register-table th:nth-child(2),
.product-register-table td:nth-child(2) { width: 320px; }
.product-register-table th:nth-child(3),
.product-register-table td:nth-child(3) { width: 110px; }
.product-register-table th:nth-child(4),
.product-register-table td:nth-child(4) { width: 88px; }
.product-register-table th:nth-child(5),
.product-register-table td:nth-child(5) { width: 120px; }
.product-register-table th:nth-child(6),
.product-register-table td:nth-child(6) { width: 90px; }
.product-register-table th:nth-child(7),
.product-register-table td:nth-child(7) { width: 95px; }
.product-register-table th:nth-child(8),
.product-register-table td:nth-child(8) { width: 82px; }
.product-register-table th:nth-child(9),
.product-register-table td:nth-child(9) { width: 95px; }
.product-register-table th:nth-child(10),
.product-register-table td:nth-child(10) { width: 90px; }
.product-register-table th:nth-child(11),
.product-register-table td:nth-child(11) { width: 170px; }
.product-register-table th:nth-child(12),
.product-register-table td:nth-child(12) { width: 180px; }
.product-register-table th:nth-child(13),
.product-register-table td:nth-child(13) { width: 74px; }

.product-register-date {
  color: #536176;
  font-weight: 700;
  white-space: nowrap;
}

.product-register-link-cell a {
  display: block;
  overflow: hidden;
  max-width: 100%;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.product-register-stock-cell {
  position: relative;
  overflow: visible;
}

.product-register-action-cell {
  text-align: center;
  white-space: nowrap;
}

.product-register-action-cell .danger-soft {
  min-width: 52px;
  padding: 6px 10px;
}

.product-register-stock-box {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: start;
}

.product-register-stock-summary {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.product-register-stock-summary strong {
  color: #172033;
  font-size: 14px;
  line-height: 1.2;
}

.product-register-stock-summary small {
  margin-top: 0 !important;
  color: #7a8699;
  font-size: 10px !important;
}

.product-stock-open {
  height: 28px;
  padding: 0 8px;
  font-size: 11px;
  white-space: nowrap;
}

.ozon-stock-popover {
  position: fixed;
  top: 92px;
  right: 32px;
  z-index: 80;
  display: grid;
  gap: 10px;
  box-sizing: border-box;
  width: 340px;
  max-width: calc(100vw - 48px);
  max-height: calc(100vh - 128px);
  overflow: auto;
  margin-top: 0;
  border: 1px solid #d8e1ee;
  border-radius: 8px;
  padding: 12px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(20, 32, 51, 0.14);
}

.ozon-stock-popover-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ozon-stock-popover-head strong {
  color: #172033;
  font-size: 14px;
}

.icon-close {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border: 0;
  border-radius: 6px;
  padding: 0;
  color: #8a97aa;
  background: transparent;
  font-size: 22px;
  line-height: 1;
}

.icon-close:hover {
  color: #42526a;
  background: #f1f4f8;
}

.ozon-stock-popover label {
  display: grid;
  gap: 5px;
  color: #647085;
  font-size: 12px;
}

.ozon-stock-popover select,
.ozon-stock-popover input {
  width: 100%;
  height: 42px;
  border: 1px solid #d8e1ee;
  border-radius: 7px;
  padding: 0 10px;
  color: #172033;
  background: #fff;
  font-size: 13px;
}

.ozon-stock-popover input:disabled {
  color: #536176;
  background: #f7f9fc;
}

.ozon-stock-popover-note {
  border: 1px solid #e3e8f0;
  border-radius: 7px;
  padding: 8px 10px;
  color: #5f6f85;
  background: #f8fafc;
  font-size: 12px;
  line-height: 1.35;
}

.ozon-stock-popover-actions {
  display: flex;
  gap: 8px;
  padding-top: 2px;
}

.ozon-stock-popover-actions button {
  min-width: 78px;
  height: 38px;
  border-radius: 7px;
  font-size: 13px;
}

.registered-product-card {
  display: grid;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 12px;
}

.registered-product-card + .registered-product-card { margin-top: 10px; }

.registered-product-summary {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) minmax(150px, 220px) auto;
  gap: 12px;
  align-items: center;
}

.registered-product-main {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.registered-product-main h3 {
  font-size: 15px;
  line-height: 1.35;
}

.registered-product-stats {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
}

.registered-sku-wrap {
  border-color: #dfe6f2;
}

.registered-sku-wrap .product-feedback-table {
  min-width: 1680px;
}

.registered-sku-wrap .product-feedback-table td small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.sku-analytics-row td {
  padding: 0 10px 12px;
  background: #fbfcff;
}

.sku-analytics-panel {
  display: grid;
  gap: 12px;
  border: 1px solid #dfe6f2;
  border-radius: 8px;
  padding: 12px;
  background: #fff;
}

.sku-analytics-panel.empty-panel {
  color: var(--muted);
  font-size: 12px;
}

.sku-analytics-head,
.sku-trend-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.sku-analytics-head {
  align-items: flex-start;
}

.sku-analytics-head > div:first-child {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.sku-analytics-head strong,
.sku-trend-title {
  font-size: 13px;
}

.sku-analytics-head span {
  color: var(--muted);
  font-size: 12px;
}

.analytics-status-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  color: var(--muted);
  font-size: 11px;
}

.analytics-status-strip > span:not(.badge):not(.archive-badge) {
  min-height: 24px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 4px 7px;
  background: #f8fafd;
}

.archive-cell.archived {
  background: #fff5f5;
}

.archive-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border: 1px solid #dfe6f2;
  border-radius: 6px;
  padding: 4px 8px;
  color: var(--muted);
  background: #f8fafd;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.archive-badge.archived {
  border-color: #f1b4b4;
  color: #b42318;
  background: #fff1f1;
}

.archive-badge.muted {
  color: #8a94a6;
}

.analytics-source-line {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 8px 10px;
  color: #4b5563;
  background: #f8fafd;
  font-size: 11px;
  line-height: 1.45;
}

.analytics-official-board {
  overflow: hidden;
  border: 1px solid #dfe6f2;
  border-radius: 8px;
  background: #fff;
}

.analytics-board-row {
  display: grid;
  grid-template-columns: minmax(150px, 1.15fr) minmax(120px, .85fr) minmax(120px, .85fr) minmax(220px, 1.2fr);
  min-height: 42px;
  border-bottom: 1px solid #edf1f7;
}

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

.analytics-board-row > span,
.analytics-board-row > strong,
.analytics-board-row > em {
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 8px 10px;
  border-right: 1px solid #edf1f7;
  line-height: 1.35;
}

.analytics-board-row > *:last-child {
  border-right: 0;
}

.analytics-board-head {
  color: var(--muted);
  background: #f8fafd;
  font-size: 12px;
  font-weight: 700;
}

.analytics-board-head small {
  color: #8a94a6;
  font-size: 10px;
  font-weight: 500;
}

.analytics-board-row > strong {
  font-size: 14px;
}

.analytics-board-row > strong.empty-value {
  color: #8a94a6;
  font-weight: 600;
}

.analytics-board-row > em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  word-break: break-word;
}

@media (max-width: 900px) {
  .sku-analytics-head {
    display: grid;
  }

  .analytics-status-strip {
    justify-content: flex-start;
  }

  .analytics-board-row {
    grid-template-columns: minmax(120px, 1fr) minmax(96px, .8fr) minmax(96px, .8fr) minmax(170px, 1fr);
  }
}

.analytics-period-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.analytics-summary {
  display: grid;
  gap: 8px;
  min-width: 0;
  border: 1px solid #edf1f7;
  border-radius: 8px;
  padding: 10px;
  background: #f8fafd;
}

.analytics-summary > strong {
  font-size: 12px;
}

.analytics-summary small,
.analytics-warning {
  color: #9a5b00;
  font-size: 11px;
  line-height: 1.45;
}

.analytics-chip-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(110px, 1fr));
  gap: 6px;
}

.analytics-chip {
  display: grid;
  gap: 3px;
  min-height: 46px;
  border: 1px solid #e2e8f0;
  border-radius: 7px;
  padding: 7px 8px;
  background: #fff;
}

.analytics-chip em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  line-height: 1.25;
}

.analytics-chip strong {
  font-size: 13px;
}

.sku-trend-wrap {
  max-height: 260px;
  overflow: auto;
  border: 1px solid #edf1f7;
  border-radius: 8px;
}

.sku-trend-table {
  width: 100%;
  min-width: 1180px;
  border-collapse: collapse;
  font-size: 11px;
}

.sku-trend-table th,
.sku-trend-table td {
  padding: 7px 8px;
  border-bottom: 1px solid #edf1f7;
  text-align: left;
  white-space: nowrap;
}

.sku-trend-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: var(--muted);
  background: #f8fafd;
  font-weight: 700;
}

.data-analysis-root {
  display: grid;
  gap: 12px;
}

.customer-service-root {
  display: grid;
  gap: 12px;
}

.local-assistant-panel {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #cfe4ff;
  border-radius: 8px;
  background: #f7fbff;
}

.local-assistant-panel.verification-needed {
  border-color: #f5c56a;
  background: #fff9ed;
}

.local-assistant-panel > div:first-child {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.local-assistant-panel strong {
  font-size: 14px;
}

.local-assistant-panel small,
.local-assistant-panel p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.local-assistant-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.local-assistant-grid span {
  min-height: 30px;
  padding: 7px 9px;
  border: 1px solid #dce8f8;
  border-radius: 6px;
  color: #33415c;
  background: #fff;
  font-size: 12px;
}

.local-assistant-actions button {
  width: 100%;
  min-height: 32px;
  padding: 0 12px;
  font-size: 12px;
}

.local-assistant-actions button.assistant-started,
.local-assistant-actions button.assistant-started:disabled {
  color: #1f5b45;
  border: 1px solid #9fc9b6;
  background: #e7f2ed;
  opacity: 1;
}

.local-assistant-actions button.assistant-pause {
  color: #7a4b16;
  border-color: #e4c99b;
  background: #fffaf2;
}

.local-assistant-actions button.assistant-resume,
.local-assistant-actions button.assistant-resume:disabled {
  color: #1f5b45;
  border-color: #9fc9b6;
  background: #e7f2ed;
  opacity: 1;
}

.local-assistant-actions {
  display: grid;
  grid-template-columns: repeat(6, minmax(86px, 1fr));
  gap: 8px;
  align-items: center;
}

.customer-service-agent-panel {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid #cddbf0;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 0%, #f6faff 100%);
  box-shadow: 0 6px 18px rgba(19, 41, 75, .07);
}

.customer-service-agent-panel.customer-service-overall-progress {
  display: grid;
  gap: 8px;
  padding: 10px 12px;
}

.customer-service-inquiry-state {
  min-height: 20px;
  color: #172033;
  font-size: 14px;
  font-weight: 900;
  line-height: 1.35;
}

.customer-service-overall-progress .customer-service-agent-progressbar {
  width: 100%;
}

.customer-service-overall-progress .customer-service-agent-progressbar span {
  min-width: 0;
}

.customer-service-agent-progressbar {
  position: relative;
  overflow: hidden;
  align-self: center;
  height: 28px;
  border: 1px solid #bfd7f5;
  border-radius: 999px;
  background: #edf5ff;
}

.customer-service-agent-progressbar span {
  position: absolute;
  inset: 3px auto 3px 3px;
  width: var(--agent-progress, 0%);
  min-width: 12px;
  max-width: calc(100% - 6px);
  border-radius: inherit;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,.36) 0 8px, transparent 8px 16px),
    linear-gradient(90deg, rgba(31, 111, 229, .98), rgba(20, 184, 166, .92));
  background-size: 23px 100%, 100% 100%;
  background-position: 0 0, 0 0;
  box-shadow: 0 0 18px rgba(31, 111, 229, .24);
  animation: agent-progress-flow .85s linear infinite;
}

.customer-service-agent-progressbar.done span {
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,.36) 0 8px, transparent 8px 16px),
    linear-gradient(90deg, rgba(12, 148, 98, .98), rgba(20, 184, 166, .92));
  box-shadow: 0 0 18px rgba(12, 148, 98, .22);
}

.customer-service-agent-progressbar em {
  position: absolute;
  inset: 0 10px 0 auto;
  display: grid;
  place-items: center;
  color: #172033;
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
}

@keyframes agent-progress-flow {
  from {
    background-position: 0 0, 0 0;
  }
  to {
    background-position: 23px 0, 0 0;
  }
}

.capture-customer-service-box {
  display: grid;
  gap: 8px;
  margin-top: 8px;
  padding: 10px;
  border: 1px solid #dfe6f2;
  border-radius: 8px;
  background: #fbfcff;
}

.capture-customer-service-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.capture-customer-service-head strong {
  font-size: 13px;
}

.capture-customer-service-head small {
  color: var(--muted);
  font-size: 12px;
}

.capture-customer-service-box textarea,
.capture-customer-service-complete textarea {
  width: 100%;
  min-height: 68px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px;
  color: #33415c;
  background: #fff;
  font: inherit;
  font-size: 12px;
  line-height: 1.5;
  resize: vertical;
}

.capture-customer-service-complete {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(180px, 1fr) auto;
  gap: 8px;
  align-items: stretch;
}

.capture-customer-service-complete button {
  min-height: 36px;
  align-self: end;
  white-space: nowrap;
}

.customer-service-progress {
  grid-column: 1 / -1;
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid #dce8f8;
  border-left: 4px solid var(--blue);
  border-radius: 8px;
  background: #ffffff;
}

.customer-service-progress.done {
  border-color: #b9e7d2;
  border-left-color: var(--green);
  background: #f0fbf6;
}

.customer-service-progress.active {
  border-color: #f5c56a;
  border-left-color: #f59e0b;
  background: #fffaf0;
}

.customer-service-progress.partial {
  border-color: #e4c99b;
  border-left-color: #b7791f;
  background: #fffaf2;
}

.customer-service-progress.bad {
  border-color: #f2c0bc;
  border-left-color: var(--red);
  background: #fff4f3;
}

.customer-service-progress.todo {
  border-color: #d8e0ec;
  border-left-color: #8b97aa;
  background: #f8fafd;
}

.customer-service-progress-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

.customer-service-progress-head strong {
  color: #172033;
  font-size: 14px;
}

.customer-service-progress-head span {
  overflow: hidden;
  color: #42526b;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.customer-service-progress-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 6px;
}

.customer-service-progress-step {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 2px 7px;
  align-items: center;
  min-height: 52px;
  padding: 7px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.78);
}

.customer-service-progress-step em {
  grid-row: 1 / span 2;
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #5b667a;
  background: #edf2f8;
  font-style: normal;
  font-size: 12px;
  font-weight: 800;
}

.customer-service-progress-step strong {
  overflow: hidden;
  color: #26344d;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.customer-service-progress-step span {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.customer-service-progress-step.done {
  border-color: #b9e7d2;
}

.customer-service-progress-step.done em {
  color: #fff;
  background: var(--green);
}

.customer-service-progress-step.active {
  border-color: #f5c56a;
  background: #fff8e8;
}

.customer-service-progress-step.active em {
  color: #fff;
  background: #f59e0b;
}

.customer-service-progress-step.partial {
  border-color: #e4c99b;
  background: #fff8ec;
}

.customer-service-progress-step.partial em {
  color: #fff;
  background: #b7791f;
}

.customer-service-progress-step.bad {
  border-color: #f2c0bc;
  background: #fff4f3;
}

.customer-service-progress-step.bad em {
  color: #fff;
  background: var(--red);
}

.customer-service-progress.compact {
  gap: 5px;
  padding: 6px;
}

.customer-service-progress.compact .customer-service-progress-head strong {
  font-size: 12px;
}

.customer-service-progress.compact .customer-service-progress-head span {
  font-size: 11px;
}

.customer-service-progress.compact .customer-service-progress-steps {
  grid-template-columns: repeat(4, minmax(72px, 1fr));
  gap: 4px;
}

.customer-service-progress.compact .customer-service-progress-step {
  min-height: 36px;
  padding: 4px;
  grid-template-columns: 20px minmax(0, 1fr);
}

.customer-service-progress.compact .customer-service-progress-step em {
  width: 18px;
  height: 18px;
  font-size: 10px;
}

.customer-service-progress.compact .customer-service-progress-step strong {
  font-size: 11px;
}

.customer-service-progress.compact .customer-service-progress-step span {
  font-size: 10px;
}

.customer-service-bulk-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px 12px;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  border: 1px solid #d8e8fb;
  border-radius: 8px;
  background: #f6fbff;
}

.customer-service-bulk-main,
.customer-service-bulk-actions {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
  align-items: center;
  min-width: 0;
}

.customer-service-bulk-main {
  gap: 8px 10px;
}

.customer-service-bulk-main strong {
  flex: 0 0 auto;
  white-space: nowrap;
}

.customer-service-bulk-tools {
  display: flex;
  flex: 1 1 auto;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.customer-service-bulk-search-input {
  flex: 1 1 220px;
  min-width: 160px;
  height: 30px;
  padding: 0 10px;
  border: 1px solid #cdd8e9;
  border-radius: 6px;
  background: #fff;
  font-size: 11px;
  line-height: 1.1;
}

.customer-service-status-filters {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
}

.customer-service-status-filter {
  flex: 0 0 auto;
  height: 30px;
  padding: 0 12px;
  border-radius: 6px;
}

.customer-service-status-filter.active {
  color: #fff;
  background: #1d5bd6;
  border-color: #1d5bd6;
  box-shadow: 0 4px 10px rgba(29, 91, 214, 0.18);
}

.customer-service-bulk-actions {
  justify-content: flex-end;
  gap: 6px;
  max-width: 100%;
  overflow-x: auto;
}

.customer-service-bulk-actions button {
  flex: 0 0 auto;
}

#customerServiceRoot .customer-service-batch-inquiry-button {
  color: #fff;
  background: #0f7a5f;
  border-color: #0f7a5f;
  font-weight: 650;
  box-shadow: 0 6px 14px rgba(15, 122, 95, 0.18);
}

#customerServiceRoot .customer-service-batch-inquiry-button:disabled {
  color: #6b7280;
  background: #e8edf3;
  border-color: #d9e1ec;
  box-shadow: none;
}

.customer-service-bulk-bar strong {
  color: #172033;
  font-size: 13px;
}

.customer-service-bulk-bar span {
  color: var(--muted);
  font-size: 11px;
}

@media (max-width: 960px) {
  .customer-service-bulk-bar {
    grid-template-columns: 1fr;
  }

  .customer-service-bulk-main,
  .customer-service-bulk-actions {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .customer-service-bulk-tools,
  .customer-service-status-filters {
    flex-wrap: wrap;
  }
}

.customer-service-workspace {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  align-items: start;
}

.customer-service-column {
  min-width: 0;
  border: 1px solid #dfe8f5;
  border-radius: 8px;
  background: #fff;
}

.customer-service-column {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.customer-service-column-head {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  min-width: 0;
  padding: 8px;
  border-bottom: 1px solid #edf1f7;
  background: #f8fbff;
}

.customer-service-column-head strong {
  overflow: hidden;
  color: #172033;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.customer-service-column-head span {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
}

.customer-service-rows {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: min(68vh, 760px);
  overflow: auto;
  padding: 8px;
}

.customer-service-row {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 5px;
  align-items: center;
  min-height: 0;
  padding: 6px 8px;
  border: 1px solid #edf1f7;
  border-radius: 6px;
  background: #fff;
}

.customer-service-row.active {
  border-color: #9dccff;
  background: #f3f8ff;
  box-shadow: inset 3px 0 0 #1f6fe5;
}

.customer-service-row.single-processing {
  border-color: #f2c14e;
  background: linear-gradient(180deg, #fffdf4 0%, #fff8df 100%);
  box-shadow: inset 4px 0 0 #f59e0b, 0 6px 16px rgba(245, 158, 11, .12);
}

.customer-service-row.single-processing .customer-service-no {
  border-color: #f0b94a;
  color: #8a4b08;
  background: #fff4cc;
}

.customer-service-row-main {
  display: grid;
  grid-template-columns: 18px 42px 52px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.customer-service-row-main .analysis-product-thumb {
  width: 52px;
  height: 52px;
  overflow: hidden;
  font-size: 10px;
}

.customer-service-row-main .analysis-product-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.customer-service-no {
  display: grid;
  justify-items: center;
  align-content: center;
  width: 38px;
  height: 32px;
  border: 1px solid #c8ddfb;
  border-radius: 7px;
  color: #075bb8;
  background: #eef6ff;
}

.customer-service-no b {
  line-height: 1;
  font-size: 15px;
  font-weight: 850;
}

.customer-service-no small {
  margin-top: 1px;
  color: #527197;
  line-height: 1;
  font-size: 9px;
}

.customer-service-row-info {
  display: grid;
  grid-template-columns: minmax(170px, .62fr) minmax(560px, 1.8fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
}

.customer-service-title-meta {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.customer-service-row-info strong {
  overflow: hidden;
  color: #172033;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.customer-service-row-info small {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
  min-width: 0;
}

.customer-service-row-info em {
  color: var(--muted);
  font-style: normal;
  font-size: 11px;
}

.customer-service-final-state {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 30px;
  padding: 0 7px;
  border: 1px solid transparent;
  border-radius: 6px;
}

.customer-service-final-state strong {
  white-space: nowrap;
  font-size: 11px;
  font-weight: 800;
}

.customer-service-final-state.done {
  border-color: #b9e7d2;
  color: #17663e;
  background: #effbf5;
}

.customer-service-final-state.pending {
  border-color: #d4deeb;
  color: #58677d;
  background: #f5f8fc;
}

.customer-service-final-state.manual {
  border-color: #f2c0bc;
  color: #a52a20;
  background: #fff4f3;
}

.customer-service-row-actions {
  display: grid;
  grid-template-columns: 64px 88px 70px 44px;
  gap: 6px;
  align-items: center;
  justify-content: end;
  justify-self: end;
  align-self: end;
  width: 284px;
  max-width: 100%;
  margin-bottom: 10px;
}

.customer-service-row:has(.customer-service-sku-reason) .customer-service-row-actions {
  align-self: end;
  margin-bottom: 33px;
}

.customer-service-action-slot {
  display: flex;
  align-items: stretch;
  min-width: 0;
  min-height: 30px;
}

.customer-service-action-slot > button,
.customer-service-action-slot > .customer-service-final-state {
  width: 100%;
  min-width: 0;
}

#customerServiceRoot button {
  height: 30px;
  min-height: 30px;
  padding: 0 9px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.1;
}

#customerServiceRoot .customer-service-single-button {
  color: #fff;
  background: #0f7a5f;
}

.customer-service-list {
  display: grid;
  gap: 10px;
}

.customer-service-card {
  display: grid;
  gap: 8px;
  align-items: start;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.customer-service-row.customer-service-card {
  gap: 5px;
  padding: 6px 8px;
  border-color: #dfe8f5;
  box-shadow: none;
}

.customer-service-row .customer-service-sku-data {
  margin: 0;
  min-width: 0;
}
.customer-service-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.customer-service-actions button,
.customer-service-actions .button-link {
  min-height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.customer-service-result {
  grid-column: 1 / -1;
  display: grid;
  gap: 4px;
  min-height: 30px;
  padding: 8px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  color: var(--muted);
  background: #f8fafd;
  font-size: 12px;
}

.customer-service-result.ok {
  border-color: #b9e7d2;
  color: #17663e;
  background: #f0fbf6;
}

.customer-service-result.bad {
  border-color: #f2c0bc;
  color: #b42318;
  background: #fff4f3;
}

.customer-service-result.warn {
  border-color: #f5c56a;
  color: #8a4b08;
  background: #fff8e8;
}

.customer-service-result.warn a {
  color: #8a4b08;
  word-break: break-all;
}

.customer-service-sku-data {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.customer-service-sku-data.empty {
  color: var(--muted);
  font-size: 12px;
}

.customer-service-sku-data-tools {
  display: flex;
  justify-content: flex-end;
  min-width: 0;
}

.customer-service-sku-filter-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  min-width: 160px;
}

.customer-service-sku-filter {
  width: 138px;
  height: 26px;
  padding: 0 8px;
  border: 1px solid #d7dee9;
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  font-size: 11px;
}

.customer-service-sku-filter:focus {
  border-color: #9aa8bd;
  outline: none;
  box-shadow: 0 0 0 2px rgba(148, 163, 184, .18);
}

.customer-service-sku-table {
  display: grid;
  gap: 0;
}

.customer-service-sku-data-row {
  display: grid;
  grid-template-columns: minmax(330px, 1fr) 54px;
  grid-template-areas:
    "sku-title sku-title"
    "package sku-actions"
    "sku-reason sku-reason";
  gap: 6px;
  align-items: center;
  min-height: 26px;
  margin: 0;
  padding: 4px 0;
  border: 0;
  border-top: 1px solid #e2e8f0;
  border-radius: 0;
  background: transparent;
  font-size: 11px;
}

.customer-service-sku-data-row.empty-match {
  grid-template-areas: none;
  grid-template-columns: 1fr;
  color: var(--muted);
}

.customer-service-sku-row-title {
  grid-area: sku-title;
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  padding-bottom: 1px;
}

.customer-service-sku-data-row em {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: #8b97aa;
  font-style: normal;
  font-weight: 800;
}

.customer-service-sku-data-row.done em {
  background: var(--green);
}

.customer-service-sku-data-row.todo em {
  background: #8b97aa;
}

.customer-service-sku-data-row.bad {
  border-color: #f2c0bc;
  background: transparent;
}

.customer-service-sku-data-row.bad em {
  background: #c13b31;
}

.customer-service-sku-data-row strong,
.customer-service-sku-data-row span {
  overflow: hidden;
  min-width: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.customer-service-sku-data-row strong {
  color: #26344d;
  font-size: 11px;
}

.customer-service-sku-data-row span {
  color: #172033;
}

.customer-service-package-inputs {
  grid-area: package;
  display: grid;
  grid-template-columns: repeat(4, minmax(62px, 1fr));
  gap: 7px;
  min-width: 0;
}

.customer-service-package-inputs label {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 4px;
  min-width: 0;
  color: #506078;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.customer-service-package-inputs input {
  width: 100%;
  height: 30px;
  min-width: 0;
  padding: 0 8px;
  border: 1px solid #cbd8e8;
  border-radius: 6px;
  background: #fbfdff;
  color: #172033;
  font-size: 12px;
  font-weight: 700;
  box-shadow: inset 0 1px 2px rgba(43, 67, 101, .05);
}

.customer-service-package-inputs input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

.customer-service-package-inputs input[type="number"]::-webkit-inner-spin-button,
.customer-service-package-inputs input[type="number"]::-webkit-outer-spin-button {
  margin: 0;
  appearance: none;
  -webkit-appearance: none;
}

.customer-service-package-inputs input:focus {
  border-color: #9aa8bd;
  outline: none;
  box-shadow: 0 0 0 2px rgba(148, 163, 184, .16);
}

.customer-service-sku-row-actions {
  grid-area: sku-actions;
  display: grid;
  grid-template-columns: 1fr;
  min-width: 0;
}

.customer-service-sku-save {
  min-width: 0;
  height: 30px !important;
  min-height: 30px !important;
}

.customer-service-sku-reason {
  grid-area: sku-reason;
  justify-self: start;
  max-width: min(100%, 360px);
  min-height: 23px;
  padding: 3px 8px;
  border: 1px solid #f2c0bc;
  border-radius: 5px;
  background: #fff8f7;
  color: #a52a20 !important;
  font-weight: 750;
  line-height: 1.35;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.data-center-root {
  display: grid;
  gap: 12px;
}

.data-center-toolbar,
.data-center-kpi,
.data-center-panel {
  border: 1px solid #dfe5ee;
  border-radius: 8px;
  background: #fff;
}

.data-center-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 12px;
}

.data-center-toolbar > div:first-child {
  display: grid;
  gap: 5px;
  flex: 1 1 auto;
  min-width: 0;
}

.data-center-toolbar strong,
.data-center-panel-head strong {
  color: #1d2738;
  font-size: 15px;
}

.data-center-toolbar span,
.data-center-panel-head span,
.data-center-kpi small,
.data-center-source,
.data-center-table span {
  color: #6b778c;
  font-size: 12px;
}

.data-center-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.data-center-period-tabs {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid #d8dedf;
  border-radius: 7px;
  background: #fff;
}

.data-center-period-tabs button {
  height: 34px;
  min-width: 54px;
  border: 0;
  border-right: 1px solid #e7eceb;
  border-radius: 0;
  color: #596675;
  background: #fff;
  font-size: 12px;
}

.data-center-period-tabs button:last-child {
  border-right: 0;
}

.data-center-period-tabs button.active {
  color: #214137;
  background: #eef4f1;
  box-shadow: inset 0 0 0 1px #94afa5;
}

.data-center-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.data-center-kpi {
  display: grid;
  gap: 9px;
  min-height: 76px;
  padding: 13px;
  background: #fbfcfb;
}

.data-center-kpi span {
  color: #66717f;
  font-size: 12px;
}

.data-center-kpi strong {
  color: #182232;
  font-size: 24px;
  line-height: 1.05;
}

.data-center-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.data-center-panel {
  display: grid;
  gap: 10px;
  min-width: 0;
  padding: 12px;
}

.data-center-panel.large {
  grid-column: 1 / -1;
  min-height: 342px;
}

.data-center-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.data-center-chart-svg {
  width: 100%;
  height: 296px;
  display: block;
  overflow: visible;
}

.data-center-chart-svg path,
.data-center-chart-svg line {
  fill: none;
  vector-effect: non-scaling-stroke;
}

.data-center-chart-axis {
  stroke: #c8d2d1;
  stroke-width: 1;
}

.data-center-chart-grid {
  stroke: #e7eceb;
  stroke-width: 1;
  stroke-dasharray: 3 5;
}

.data-center-chart-tick {
  stroke: #b9c5c2;
  stroke-width: 1;
}

.data-center-chart-x,
.data-center-chart-y {
  fill: #66717f;
  font-size: 10px;
}

.data-center-chart-x {
  text-anchor: middle;
}

.data-center-chart-y {
  text-anchor: end;
}

.data-center-chart-y.right {
  text-anchor: start;
}

.data-center-chart-svg polyline {
  fill: none;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.data-center-chart-line.primary {
  stroke-width: 3.2;
  opacity: 0.9;
}

.data-center-chart-line.alt {
  stroke-width: 2.2;
  opacity: 0.96;
}

.data-center-chart-point {
  stroke: #ffffff;
  stroke-width: 1.4;
}

.data-center-chart-legend text {
  fill: #4b5968;
  font-size: 11px;
}

.data-center-chart-empty,
.data-center-empty-row {
  min-height: 92px;
  display: grid;
  place-items: center;
  border: 1px dashed #d7dedc;
  border-radius: 7px;
  color: #748191;
  background: #fafbfa;
  font-size: 13px;
}

.data-center-status-row {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) 52px;
  align-items: center;
  gap: 8px;
  min-height: 30px;
}

.data-center-status-row span {
  overflow: hidden;
  color: #374151;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.data-center-status-row em {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #edf1f0;
}

.data-center-status-row i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #789488;
}

.data-center-status-row strong {
  color: #263243;
  font-size: 12px;
  text-align: right;
}

.data-center-source {
  padding: 0 2px 2px;
  line-height: 1.55;
}

.data-center-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.data-center-table th,
.data-center-table td {
  border-bottom: 1px solid #edf1f4;
  padding: 9px 7px;
  color: #263243;
  font-size: 12px;
  text-align: left;
  vertical-align: middle;
}

.data-center-table th {
  color: #687483;
  background: #fafbfc;
  font-weight: 700;
}

.data-center-table td:nth-child(n+3),
.data-center-table th:nth-child(n+3) {
  text-align: right;
}

.data-center-table td:last-child,
.data-center-table th:last-child {
  text-align: left;
}

.data-center-table tr:last-child td {
  border-bottom: 0;
}

.data-center-product-cell {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.data-center-product-cell strong,
.data-center-table.compact td:nth-child(2) {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.data-center-product-cell span {
  display: block;
  overflow: hidden;
  margin-top: 3px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.data-center-thumb {
  width: 42px;
  height: 42px;
  border: 1px solid #e1e7ed;
  border-radius: 7px;
  object-fit: cover;
  background: #f5f7f8;
}

.data-center-table.compact td:first-child {
  display: grid;
  gap: 3px;
}

.data-center-table.compact td:first-child strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.data-analysis-toolbar,
.data-analysis-summary,
.data-analysis-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

/* Apple-tech data center surface */
.data-center-root {
  --dc-bg: #0b1119;
  --dc-surface: rgba(19, 29, 42, 0.86);
  --dc-surface-strong: rgba(25, 38, 54, 0.96);
  --dc-line: rgba(150, 190, 220, 0.17);
  --dc-muted: #91a4b8;
  --dc-text: #f3f8fc;
  --dc-cyan: #66d8ff;
  --dc-blue: #6d9dff;
  display: grid;
  gap: 18px;
  padding: 4px;
  color: var(--dc-text);
}

.data-center-root::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: #0b1119;
}

.data-center-toolbar,
.data-center-kpi,
.data-center-panel {
  border: 1px solid var(--dc-line);
  border-radius: 14px;
  background: var(--dc-surface);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .18), inset 0 1px 0 rgba(255, 255, 255, .045);
  backdrop-filter: blur(18px);
}

.data-center-toolbar {
  align-items: center;
  gap: 20px;
  padding: 18px 20px;
}

.data-center-toolbar strong,
.data-center-panel-head strong {
  color: var(--dc-text);
  font-size: 16px;
  letter-spacing: 0;
}

.data-center-toolbar span,
.data-center-panel-head span,
.data-center-kpi small,
.data-center-source,
.data-center-table span {
  color: var(--dc-muted);
}

.data-center-actions { gap: 10px; }
.data-center-period-tabs { border-color: var(--dc-line); background: rgba(5, 11, 18, .45); }
.data-center-period-tabs button {
  min-width: 58px;
  color: #9db0c2;
  background: transparent;
  border-color: var(--dc-line);
}
.data-center-period-tabs button.active {
  color: #07131c;
  background: var(--dc-cyan);
  box-shadow: none;
}
.data-center-actions > button,
.data-center-screen-trigger {
  min-height: 38px;
  border: 1px solid rgba(102, 216, 255, .35);
  border-radius: 10px;
  padding: 0 14px;
  color: #dff7ff;
  background: rgba(46, 107, 141, .34);
  font-weight: 700;
}
.data-center-actions > button:hover,
.data-center-screen-trigger:hover { background: rgba(71, 143, 180, .52); }

.data-center-kpis { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.data-center-kpi {
  min-height: 112px;
  gap: 12px;
  padding: 17px;
  background: var(--dc-surface-strong);
}
.data-center-kpi span { color: var(--dc-muted); font-size: 12px; }
.data-center-kpi strong { color: var(--dc-text); font-size: clamp(22px, 2.2vw, 31px); font-weight: 700; }

.data-center-grid { gap: 16px; }
.data-center-panel { gap: 14px; padding: 18px; }
.data-center-panel.large { min-height: 360px; }
.data-center-chart-svg { height: 300px; }
.data-center-chart-axis { stroke: rgba(159, 193, 215, .45); }
.data-center-chart-grid { stroke: rgba(159, 193, 215, .14); }
.data-center-chart-tick { stroke: rgba(159, 193, 215, .3); }
.data-center-chart-x, .data-center-chart-y { fill: #8fa6ba; }
.data-center-chart-legend text { fill: #b4c8d8; }
.data-center-status-row em { background: rgba(148, 176, 197, .15); }
.data-center-status-row i { background: var(--dc-cyan); }
.data-center-status-row span, .data-center-status-row strong { color: #dceaf2; }
.data-center-table th, .data-center-table td { border-color: var(--dc-line); color: #dceaf2; }
.data-center-table th { color: #95adbf; background: rgba(7, 15, 24, .45); }
.data-center-thumb { border-color: var(--dc-line); background: #101b28; }
.data-center-empty-row, .data-center-chart-empty { border-color: var(--dc-line); color: #8499aa; background: rgba(5, 12, 20, .3); }

.data-center-upload-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.data-center-upload-grid > div {
  display: grid; gap: 8px; min-height: 72px; padding: 12px;
  border: 1px solid var(--dc-line); border-radius: 10px; background: rgba(4, 12, 20, .35);
}
.data-center-upload-grid span, .data-center-upload-rail span { color: var(--dc-muted); font-size: 12px; }
.data-center-upload-grid strong { color: var(--dc-text); font-size: 22px; }
.data-center-upload-grid .is-positive { color: #7ce6b0; }
.data-center-upload-grid .is-alert, .data-center-upload-rail .is-alert { color: #ff9d9d; }

.data-center-bigscreen-shell[hidden] { display: none; }
.data-center-bigscreen-shell { position: fixed; inset: 0; z-index: 1000; }
.data-center-bigscreen-backdrop { position: absolute; inset: 0; background: rgba(3, 8, 14, .78); backdrop-filter: blur(10px); }
.data-center-bigscreen {
  position: relative; width: min(1440px, calc(100vw - 48px)); max-height: calc(100vh - 48px); overflow: auto;
  margin: 24px auto; padding: 26px; border: 1px solid rgba(123, 210, 255, .28); border-radius: 18px;
  color: var(--dc-text); background: #0a131e; box-shadow: 0 28px 100px rgba(0, 0, 0, .5);
}
.data-center-bigscreen-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-bottom: 18px; border-bottom: 1px solid var(--dc-line); }
.data-center-bigscreen-head div { display: grid; gap: 6px; }
.data-center-bigscreen-head span { color: var(--dc-cyan); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.data-center-bigscreen-head h2 { margin: 0; font-size: 28px; }
.data-center-screen-close { min-height: 40px; border: 1px solid var(--dc-line); border-radius: 10px; padding: 0 16px; color: #d8e8f2; background: rgba(255,255,255,.06); }
.data-center-bigscreen-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 18px; }
.data-center-bigscreen-kpis article { display: grid; gap: 10px; padding: 18px; border: 1px solid rgba(110, 194, 230, .22); border-radius: 12px; background: rgba(20, 34, 50, .72); }
.data-center-bigscreen-kpis span, .data-center-bigscreen-kpis em { color: var(--dc-muted); font-size: 12px; font-style: normal; }
.data-center-bigscreen-kpis strong { font-size: clamp(28px, 3.3vw, 46px); }
.data-center-bigscreen-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 14px; margin-top: 14px; }
.data-center-bigscreen-grid > article { min-width: 0; padding: 18px; border: 1px solid rgba(110, 194, 230, .2); border-radius: 12px; background: rgba(16, 29, 44, .72); }
.data-center-bigscreen-title { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.data-center-bigscreen-title span { color: var(--dc-muted); font-size: 12px; }
.data-center-upload-rail { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 0; border-top: 1px solid var(--dc-line); }
.data-center-upload-rail strong { font-size: 20px; }

@media (max-width: 1100px) {
  .data-center-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .data-center-upload-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .data-center-bigscreen-grid { grid-template-columns: 1fr 1fr; }
  .data-center-bigscreen-grid > article:first-child { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .data-center-toolbar { align-items: stretch; flex-direction: column; padding: 15px; }
  .data-center-actions { flex-wrap: wrap; justify-content: stretch; }
  .data-center-period-tabs { flex: 1 1 100%; }
  .data-center-period-tabs button { flex: 1; min-width: 0; }
  .data-center-actions > button { flex: 1; }
  .data-center-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .data-center-grid { grid-template-columns: 1fr; }
  .data-center-panel.large { min-height: 300px; }
  .data-center-chart-svg { height: 250px; }
  .data-center-upload-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .data-center-bigscreen { width: calc(100vw - 20px); max-height: calc(100vh - 20px); margin: 10px auto; padding: 16px; border-radius: 14px; }
  .data-center-bigscreen-kpis, .data-center-bigscreen-grid { grid-template-columns: 1fr; }
  .data-center-bigscreen-grid > article:first-child { grid-column: auto; }
}

body[data-view="dashboard"] { background: #0b1119; color: #e8f2f8; }
body[data-view="dashboard"] .sidebar { border-color: rgba(150, 190, 220, .15); background: #0f1823; }
body[data-view="dashboard"] .brand h1, body[data-view="dashboard"] .nav { color: #e8f2f8; }
body[data-view="dashboard"] .brand p, body[data-view="dashboard"] .nav-group > span, body[data-view="dashboard"] .status-block span { color: #91a4b8; }
body[data-view="dashboard"] .nav.active { color: #07131c; background: #66d8ff; }
body[data-view="dashboard"] .status-block { border-color: rgba(150, 190, 220, .17); background: rgba(19, 29, 42, .72); }
body[data-view="dashboard"] main { background: #0b1119; }
body[data-view="dashboard"] .toolbar h2 { color: #f3f8fc; }
body[data-view="dashboard"] .toolbar p { color: #91a4b8; }

.data-analysis-toolbar {
  display: grid;
  gap: 10px;
  padding: 12px;
}

.analysis-toolbar-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.analysis-toolbar-head > div:first-child {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.analysis-toolbar-head strong {
  font-size: 15px;
}

.analysis-toolbar-head span,
.data-analysis-time {
  color: var(--muted);
  font-size: 12px;
}

.analysis-sync-actions,
.analysis-filter-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.analysis-sync-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.analysis-filter-row {
  flex-wrap: wrap;
  min-width: 0;
}

.analysis-period-tabs {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid #d8e1ee;
  border-radius: 8px;
  background: #fff;
}

.analysis-period-tabs button {
  height: 40px;
  min-width: 58px;
  border: 0;
  border-right: 1px solid #e5ebf3;
  border-radius: 0;
  color: #526276;
  background: #fff;
  font-size: 13px;
}

.analysis-period-tabs button:last-child {
  border-right: 0;
}

.analysis-period-tabs button.active {
  color: #0459ff;
  background: #eef5ff;
  box-shadow: inset 0 0 0 2px #0b63ff;
}

.analysis-date-pill,
.analysis-compare-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  height: 40px;
  border: 1px solid #d8e1ee;
  border-radius: 8px;
  padding: 0 12px;
  background: #fff;
  color: #526276;
  font-size: 13px;
  white-space: nowrap;
}

.analysis-date-pill {
  min-width: 230px;
}

.analysis-compare-pill {
  min-width: 185px;
}

.analysis-calendar-icon {
  position: relative;
  display: inline-block;
  width: 15px;
  height: 15px;
  border: 2px solid #8aa0b8;
  border-top-width: 4px;
  border-radius: 3px;
  flex: 0 0 auto;
}

.analysis-calendar-icon::before,
.analysis-calendar-icon::after {
  content: "";
  position: absolute;
  top: -7px;
  width: 2px;
  height: 5px;
  border-radius: 2px;
  background: #8aa0b8;
}

.analysis-calendar-icon::before {
  left: 2px;
}

.analysis-calendar-icon::after {
  right: 2px;
}

.analysis-caret {
  margin-left: auto;
  color: #8aa0b8;
}

.analysis-filter-row select,
.analysis-filter-row input {
  height: 40px;
  border: 1px solid #d8e1ee;
  border-radius: 8px;
  background: #fff;
}

.analysis-filter-row select {
  min-width: 128px;
}

.analysis-filter-row input {
  width: min(340px, 100%);
}

.data-analysis-summary {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  overflow: hidden;
}

.data-analysis-summary > div {
  display: grid;
  gap: 5px;
  min-height: 62px;
  padding: 11px 12px;
  border-right: 1px solid var(--line);
  background: #fbfcff;
}

.data-analysis-summary > div:last-child {
  border-right: 0;
}

.data-analysis-summary span {
  color: var(--muted);
  font-size: 12px;
}

.data-analysis-summary strong {
  font-size: 20px;
  line-height: 1;
}

.danger-text {
  color: #b42318 !important;
}

.data-analysis-card {
  display: grid;
  gap: 12px;
  padding: 12px;
}

.data-analysis-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.data-analysis-card-head h3 {
  margin-bottom: 7px;
  font-size: 15px;
  line-height: 1.35;
}

.data-analysis-card .sku-analytics-panel {
  border-color: #e2e8f0;
}

.data-analysis-time {
  display: grid;
  gap: 5px;
  justify-items: end;
  white-space: nowrap;
}

.analysis-uploaded-mark {
  border: 1px solid #b7d7c5;
  border-radius: 6px;
  padding: 3px 7px;
  color: #146c43;
  background: #eefbf3;
  font-weight: 700;
}

.analysis-table-shell {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.analysis-table-scroll {
  overflow: auto;
  max-height: calc(100vh - 310px);
}

.analysis-official-table {
  width: 100%;
  min-width: 2520px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 12px;
}

.analysis-official-table th,
.analysis-official-table td {
  min-height: 48px;
  border-right: 1px solid #dfe6f2;
  border-bottom: 1px solid #dfe6f2;
  padding: 9px 10px;
  text-align: right;
  vertical-align: middle;
  white-space: nowrap;
}

.analysis-official-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  color: #607087;
  background: #f5f8fc;
  font-weight: 700;
}

.analysis-official-table th small {
  color: #7b8ca2;
  font-size: 11px;
  font-weight: 600;
}

.analysis-official-table thead tr:nth-child(2) th {
  top: 39px;
}

.analysis-official-table .analysis-product-head,
.analysis-official-table .analysis-product-cell {
  position: sticky;
  left: 0;
  z-index: 3;
  width: 355px;
  min-width: 355px;
  max-width: 355px;
  text-align: left;
  box-shadow: 1px 0 0 #dfe6f2;
}

.analysis-official-table .analysis-product-head {
  z-index: 4;
}

.analysis-official-table .analysis-product-cell {
  background: #fff;
}

.analysis-total-row td {
  background: #fbfcff;
  font-weight: 700;
}

.analysis-total-row .analysis-product-cell {
  background: #fbfcff;
}

.analysis-product-info {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.analysis-product-info.no-image {
  grid-template-columns: minmax(0, 1fr);
}

.analysis-product-info > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.analysis-product-info strong {
  overflow: hidden;
  color: #142033;
  font-size: 13px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analysis-product-info span,
.analysis-product-info small {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analysis-product-info em {
  width: max-content;
  border: 1px solid #b7d7c5;
  border-radius: 6px;
  padding: 2px 6px;
  color: #146c43;
  background: #eefbf3;
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
}

.analysis-product-thumb {
  width: 46px;
  height: 46px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  object-fit: cover;
  background: #f8fafd;
}

.analysis-product-thumb.image-placeholder {
  display: grid;
  place-items: center;
  color: #8a94a6;
  font-size: 11px;
}

.analysis-official-table td.rate-cell {
  font-weight: 700;
}

.analysis-sort-mark {
  display: inline-flex;
  margin-left: 6px;
  color: #0459ff;
  font-weight: 800;
}

.analysis-official-table td.empty-value {
  color: #9aa6b2;
  font-weight: 600;
}

.analysis-official-table tr.is-archived-row .analysis-product-cell,
.analysis-official-table tr.is-archived-row td {
  background: #fff8f8;
}

@media (max-width: 1100px) {
  .data-analysis-toolbar {
    grid-template-columns: 1fr;
  }

  .data-analysis-card-head {
    display: grid;
  }

  .analysis-period-bar {
    flex-wrap: wrap;
  }

  .data-analysis-summary {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .data-analysis-time {
    justify-items: start;
  }
}

@media (max-width: 720px) {
  .data-analysis-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1650px) {
  .customer-service-row-main {
    grid-template-columns: 18px 42px 52px minmax(0, 1fr) auto;
    align-items: center;
  }

  .customer-service-row-info {
    grid-template-columns: minmax(0, 1fr);
    gap: 2px;
  }

  .customer-service-sku-data-row {
    grid-template-columns: minmax(0, 1fr) 54px;
  }

  .customer-service-row-main .customer-service-row-actions {
    grid-column: 5;
    grid-row: 1;
    justify-content: end;
    max-width: none;
  }
}

@media (max-width: 1180px) {
  .data-center-toolbar {
    display: grid;
  }

  .data-center-actions {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .data-center-kpis,
  .data-center-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .local-assistant-actions {
    grid-template-columns: repeat(3, minmax(86px, 1fr));
  }

  .customer-service-row-info {
    grid-template-columns: 1fr;
  }

}

@media (max-width: 980px) {
  .customer-service-row-main {
    grid-template-columns: 18px 52px minmax(0, 1fr);
  }

  .customer-service-row-main .analysis-product-thumb {
    grid-column: 2;
    grid-row: 2;
  }

  .customer-service-row-main .customer-service-no {
    grid-column: 2;
    grid-row: 1;
  }

  .customer-service-row-main .customer-service-row-info {
    grid-column: 3;
    grid-row: 1 / span 2;
  }

  .customer-service-row-main .customer-service-row-actions {
    grid-column: 1 / -1;
    justify-content: start;
    align-self: stretch;
    margin-bottom: 0;
  }

  .customer-service-row-info {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .data-center-kpis,
  .data-center-grid {
    grid-template-columns: 1fr;
  }

  .data-center-period-tabs {
    width: 100%;
  }

  .data-center-period-tabs button {
    flex: 1;
    min-width: 0;
  }

  .data-center-status-row {
    grid-template-columns: 88px minmax(0, 1fr) 42px;
  }

  .data-center-table {
    min-width: 620px;
  }

  .data-center-panel.table-panel {
    overflow-x: auto;
  }

  .customer-service-progress.compact .customer-service-progress-steps,
  .customer-service-progress-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-service-sku-data-row {
    grid-template-columns: 1fr;
    grid-template-areas:
      "sku-title"
      "package"
      "sku-actions"
      "sku-reason";
  }

  .customer-service-package-inputs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-service-sku-data-tools,
  .customer-service-sku-filter-tools {
    align-items: stretch;
  }

  .customer-service-sku-filter-tools {
    width: 100%;
    min-width: 0;
  }

  .customer-service-sku-filter {
    width: 100%;
  }

  .customer-service-sku-row-actions { max-width: 220px; }

  .customer-service-row-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
  }

  .customer-service-final-slot {
    grid-column: 1 / -1;
  }

  .customer-service-sku-data-row.empty-match {
    grid-template-columns: 1fr;
  }

  .customer-service-sku-data-row.empty-match span {
    grid-column: 1;
  }

  .local-assistant-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .capture-customer-service-complete {
    grid-template-columns: 1fr;
  }
}

.fulfillment-root {
  display: grid;
  gap: 14px;
}

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

.fulfillment-panel {
  display: grid;
  gap: 12px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 14px;
}

.fulfillment-panel.wide {
  grid-column: 1 / -1;
}

.fulfillment-overview {
  gap: 14px;
}

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

.fulfillment-status-card {
  display: grid;
  gap: 6px;
  border: 1px solid #dfe6f2;
  border-radius: 8px;
  padding: 12px;
  background: #fbfcff;
}

.fulfillment-status-card span {
  color: var(--muted);
  font-size: 12px;
}

.fulfillment-status-card strong {
  font-size: 22px;
}

.fulfillment-status-strip {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}

.fulfillment-status-strip button {
  display: grid;
  gap: 4px;
  min-height: 54px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px;
  background: #fff;
  color: var(--text);
  cursor: pointer;
}

.fulfillment-status-strip button.active {
  border-color: var(--blue);
  color: var(--blue);
  background: #eef5ff;
}

.fulfillment-status-strip span {
  font-size: 12px;
}

.fulfillment-status-strip strong {
  font-size: 16px;
}

.compact-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 0;
}

.compact-head h3 {
  font-size: 16px;
}

.compact-head p {
  max-width: 680px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.fulfillment-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
  gap: 8px;
  align-items: center;
}

.fulfillment-form input,
.fulfillment-form select,
.fulfillment-inline-form input,
.fulfillment-handling-form select {
  min-width: 0;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 10px;
  background: #fff;
  color: var(--text);
  font-size: 12px;
}

.forwarder-auth-form {
  grid-template-columns: minmax(180px, 1fr) minmax(220px, 2fr) auto auto;
}

.forwarder-auth-form .button-link {
  height: 34px;
}

.fulfillment-subtitle {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.warehouse-form {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.warehouse-form button {
  min-height: 34px;
}

.inline-check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.mini-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.mini-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  font-size: 12px;
}

.mini-table th,
.mini-table td {
  padding: 9px 10px;
  border-bottom: 1px solid #edf1f7;
  text-align: left;
  vertical-align: top;
}

.mini-table th {
  color: var(--muted);
  background: #f8fafd;
  font-weight: 600;
}

.mini-table td small,
.fulfillment-table small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.warehouse-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.warehouse-card {
  display: grid;
  gap: 6px;
  min-width: 0;
  border: 1px solid #dfe6f2;
  border-radius: 8px;
  padding: 10px;
  background: #fbfcff;
}

.warehouse-card strong {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
}

.warehouse-card span,
.warehouse-card small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.warehouse-card button {
  justify-self: start;
}

.authorization-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.authorization-actions button {
  height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.fulfillment-inline-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(120px, 1fr));
  gap: 6px;
}

.fulfillment-inline-form .inline-check {
  grid-column: 1 / -1;
}

.fulfillment-handling-form {
  display: grid;
  grid-template-columns: minmax(90px, 1fr);
  gap: 6px;
}

.fulfillment-handling-form button {
  width: 100%;
}

.order-action-stack {
  display: grid;
  gap: 6px;
}

.fulfillment-table {
  min-width: 1480px;
}

.fulfillment-table td:nth-child(2) {
  min-width: 220px;
  line-height: 1.45;
}

.fulfillment-table td:nth-child(6) {
  min-width: 180px;
}

.fulfillment-table td:nth-child(7) {
  min-width: 280px;
}

.fulfillment-table td:nth-child(8) {
  min-width: 120px;
}

@media (max-width: 980px) {
  .fulfillment-grid,
  .fulfillment-summary-grid,
  .fulfillment-status-strip,
  .warehouse-list,
  .fulfillment-form,
  .warehouse-form,
  .forwarder-auth-form,
  .forwarder-login-grid,
  .compact-head {
    grid-template-columns: 1fr;
  }

  .forwarder-topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .forwarder-auth-unified,
  .forwarder-single-auth-form,
  .forwarder-code-row {
    grid-template-columns: 1fr;
  }

  .compact-head {
    display: grid;
  }

  .fulfillment-form button,
  .warehouse-form button,
  .forwarder-auth-form .button-link {
    width: 100%;
  }
}

@media (max-width: 760px) {
  .local-assistant-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .upload-prepare-checks,
  .upload-prepare-panel.expanded .upload-prepare-checks {
    grid-template-columns: 1fr;
  }

  .local-assistant-grid {
    grid-template-columns: 1fr;
  }

  .local-assistant-actions {
    grid-template-columns: 1fr;
  }
}

/* Data center stays aligned with the light application shell. */
body[data-view="dashboard"] {
  background: var(--bg);
  color: var(--text);
}

body[data-view="dashboard"] .sidebar {
  border-color: var(--line);
  background: #fff;
}

body[data-view="dashboard"] main {
  background: var(--bg);
}

body[data-view="dashboard"] .brand h1,
body[data-view="dashboard"] .nav {
  color: var(--text);
}

body[data-view="dashboard"] .brand p,
  body[data-view="dashboard"] .nav-group > span,
body[data-view="dashboard"] .status-block span {
  color: var(--muted);
}

body[data-view="dashboard"] .nav.active {
  color: #0757c9;
  background: #eaf3ff;
}

body[data-view="dashboard"] .status-block {
  border-color: var(--line);
  background: #fff;
}

body[data-view="dashboard"] .toolbar h2 {
  color: var(--text);
}

body[data-view="dashboard"] .toolbar p {
  color: var(--muted);
}

.data-center-root {
  --dc-line: #dce5ef;
  --dc-muted: #68778a;
  --dc-text: #172033;
  --dc-cyan: #007aff;
  --dc-blue: #0b63ce;
  display: grid;
  gap: 16px;
  padding: 0;
  color: var(--dc-text);
}

.data-center-root::before {
  display: none;
}

.data-center-toolbar,
.data-center-kpi,
.data-center-panel {
  border-color: var(--dc-line);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(32, 55, 82, .06);
  backdrop-filter: none;
}

.data-center-toolbar {
  gap: 16px;
  padding: 14px 16px;
}

.data-center-toolbar strong,
.data-center-panel-head strong {
  color: var(--dc-text);
}

.data-center-toolbar span,
.data-center-panel-head span,
.data-center-kpi small,
.data-center-source,
.data-center-table span {
  color: var(--dc-muted);
}

.data-center-period-tabs {
  border-color: #d6e0eb;
  background: #fff;
}

.data-center-period-tabs button {
  color: #526276;
  background: #fff;
  border-color: #e4ebf2;
}

.data-center-period-tabs button.active {
  color: #0757c9;
  background: #eaf3ff;
  box-shadow: inset 0 0 0 1px #82b7f6;
}

.data-center-actions > button,
.data-center-screen-trigger {
  border-color: #b9d5f5;
  color: #0757c9;
  background: #f3f8ff;
}

.data-center-actions > button:hover,
.data-center-screen-trigger:hover {
  background: #e6f1ff;
}

.data-center-kpi {
  min-height: 92px;
  padding: 14px;
  background: #fff;
}

.data-center-kpi span {
  color: var(--dc-muted);
}

.data-center-kpi strong {
  color: var(--dc-text);
}

.data-center-panel {
  padding: 14px;
}

.data-center-chart-axis {
  stroke: #b7c8d9;
}

.data-center-chart-grid {
  stroke: #e5edf5;
}

.data-center-chart-tick {
  stroke: #c7d5e2;
}

.data-center-chart-x,
.data-center-chart-y {
  fill: #66778c;
}

.data-center-chart-legend text {
  fill: #3f5369;
}

.data-center-chart-line {
  fill: none;
  stroke-width: 3.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.data-center-chart-line.primary {
  stroke-width: 3.6;
  opacity: 1;
}

.data-center-chart-line.alt {
  stroke-width: 3;
  opacity: 1;
}

.data-center-chart-area {
  stroke: none !important;
  pointer-events: none;
}

.data-center-chart-point {
  stroke: #fff;
  stroke-width: 1.8;
}

.data-center-empty-row,
.data-center-chart-empty {
  border-color: #dce5ef;
  color: #73849a;
  background: #f8fbfe;
}

/* Full-screen command-center scene. */
.data-center-bigscreen-shell {
  position: fixed;
  inset: 0;
  z-index: 1000;
}

.data-center-bigscreen-backdrop {
  background: rgba(1, 10, 18, .84);
  backdrop-filter: blur(12px);
}

.data-center-bigscreen {
  width: min(1540px, calc(100vw - 40px));
  max-height: calc(100vh - 40px);
  margin: 20px auto;
  padding: 24px;
  overflow: auto;
  border: 1px solid rgba(71, 190, 255, .32);
  border-radius: 18px;
  color: #ecf7ff;
  background: #061421;
  box-shadow: 0 28px 100px rgba(0, 0, 0, .54), inset 0 1px 0 rgba(255, 255, 255, .05);
}

.data-center-bigscreen-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  position: relative;
  padding-bottom: 16px;
  border-color: rgba(103, 202, 255, .2);
}

.data-center-bigscreen-head div:first-child {
  display: grid;
  gap: 6px;
}

.data-center-bigscreen-head span {
  color: #57d4ff;
  font-size: 12px;
  letter-spacing: .08em;
}

.data-center-bigscreen-head h2 {
  margin: 0;
  color: #f5fbff;
  font-size: 28px;
}

.data-center-bigscreen-brand {
  position: absolute;
  left: 50%;
  top: 50%;
  max-width: 52%;
  overflow: hidden;
  color: #e8f8ff;
  font-size: clamp(16px, 2vw, 28px);
  font-weight: 800;
  letter-spacing: .04em;
  line-height: 1.2;
  text-align: center;
  text-overflow: ellipsis;
  text-shadow: 0 0 18px rgba(87, 212, 255, .34);
  transform: translate(-50%, -50%);
  white-space: nowrap;
}

.data-center-bigscreen-head-actions {
  display: flex !important;
  align-items: center;
  gap: 12px;
}

.data-center-live-indicator {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #7cf0bd !important;
  letter-spacing: 0 !important;
}

.data-center-live-indicator::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #35e69a;
  box-shadow: 0 0 12px rgba(53, 230, 154, .9);
  content: '';
  animation: dataCenterLivePulse 1.8s ease-in-out infinite;
}

.data-center-screen-close {
  min-height: 40px;
  border: 1px solid rgba(103, 202, 255, .25);
  border-radius: 9px;
  padding: 0 15px;
  color: #d8edf8;
  background: rgba(255, 255, 255, .06);
}

.data-center-screen-close:hover {
  border-color: rgba(103, 202, 255, .55);
  background: rgba(54, 160, 210, .18);
}

.data-center-bigscreen-layout {
  display: grid;
  grid-template-columns: minmax(215px, .78fr) minmax(440px, 1.8fr) minmax(215px, .78fr);
  gap: 14px;
  margin-top: 16px;
}

.data-center-bigscreen-side,
.data-center-bigscreen-main {
  display: grid;
  align-content: start;
  gap: 14px;
  min-width: 0;
}

.data-center-bigscreen-main {
  padding: 0;
  background: transparent;
}

.data-center-screen-panel,
.data-center-screen-hero,
.data-center-map-stage {
  min-width: 0;
  border: 1px solid rgba(82, 193, 239, .22);
  border-radius: 12px;
  background: linear-gradient(150deg, rgba(16, 43, 65, .9), rgba(6, 24, 39, .92));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .045), 0 10px 34px rgba(0, 0, 0, .18);
}

.data-center-screen-panel {
  position: relative;
  display: grid;
  gap: 12px;
  overflow: hidden;
  padding: 15px;
}

.data-center-screen-panel::after {
  position: absolute;
  top: 9px;
  right: 9px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ffad38;
  box-shadow: 0 0 10px rgba(255, 173, 56, .9);
  content: '';
}

.data-center-bigscreen-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.data-center-bigscreen-title strong {
  color: #eaf8ff;
  font-size: 14px;
}

.data-center-bigscreen-title span {
  color: #7f9caf;
  font-size: 11px;
}

.data-center-screen-number {
  display: grid;
  gap: 4px;
  padding: 10px 0 6px;
}

.data-center-screen-number strong {
  color: #4edcff;
  font-size: 36px;
  line-height: 1;
  text-shadow: 0 0 20px rgba(78, 220, 255, .3);
}

.data-center-screen-number span,
.data-center-screen-caption {
  color: #8da8b9;
  font-size: 11px;
}

.data-center-screen-stat-row,
.data-center-upload-rail {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0 0;
  border-top: 1px solid rgba(123, 189, 220, .16);
}

.data-center-screen-stat-row span,
.data-center-upload-rail span {
  color: #8da8b9;
  font-size: 11px;
}

.data-center-screen-stat-row strong,
.data-center-upload-rail strong {
  color: #dff7ff;
  font-size: 15px;
}

.data-center-screen-money {
  color: #f4fcff;
  font-size: 30px;
  line-height: 1.05;
  text-shadow: 0 0 22px rgba(75, 212, 255, .22);
}

.data-center-screen-hero {
  display: grid;
  justify-items: center;
  gap: 7px;
  padding: 20px 18px 17px;
  border-color: rgba(75, 212, 255, .38);
  text-align: center;
  background: linear-gradient(150deg, rgba(13, 77, 112, .9), rgba(6, 28, 45, .95));
}

.data-center-screen-hero span {
  color: #66dfff;
  font-size: 12px;
  letter-spacing: .12em;
}

.data-center-screen-hero strong {
  color: #f7fdff;
  font-size: 48px;
  line-height: 1.05;
  text-shadow: 0 0 28px rgba(112, 236, 255, .45);
}

.data-center-screen-hero small {
  color: #9fc2d3;
  font-size: 12px;
}

.data-center-screen-trend .data-center-chart-svg {
  height: 190px;
}

.data-center-screen-pending-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.data-center-screen-pending-grid > div {
  display: grid;
  gap: 4px;
  min-height: 70px;
  align-content: center;
  padding: 9px;
  border: 1px solid rgba(94, 187, 228, .2);
  background: rgba(4, 18, 30, .45);
  text-align: center;
}

.data-center-screen-pending-grid strong {
  color: #46d7ff;
  font-size: 22px;
}

.data-center-screen-pending-grid strong.is-alert,
.data-center-screen-panel .is-alert {
  color: #ffad54;
}

.data-center-screen-pending-grid span {
  color: #86a1b2;
  font-size: 10px;
}

.data-center-screen-status .data-center-status-row,
.data-center-screen-order-status .data-center-status-row {
  grid-template-columns: 76px minmax(0, 1fr) 38px;
  min-height: 27px;
}

.data-center-screen-status .data-center-status-row span,
.data-center-screen-order-status .data-center-status-row span,
.data-center-screen-status .data-center-status-row strong,
.data-center-screen-order-status .data-center-status-row strong {
  color: #cfe5ef;
  font-size: 10px;
}

.data-center-screen-status .data-center-status-row em,
.data-center-screen-order-status .data-center-status-row em {
  height: 6px;
  background: rgba(148, 190, 208, .14);
}

.data-center-screen-status .data-center-status-row i,
.data-center-screen-order-status .data-center-status-row i {
  background: linear-gradient(90deg, #00a8ff, #32e1c4);
}

.data-center-bigscreen .data-center-chart-empty,
.data-center-bigscreen .data-center-empty-row {
  border-color: rgba(110, 194, 230, .2);
  color: #8499aa;
  background: rgba(5, 12, 20, .3);
}

.data-center-bigscreen .data-center-chart-axis { stroke: rgba(159, 193, 215, .45); }
.data-center-bigscreen .data-center-chart-grid { stroke: rgba(159, 193, 215, .14); }
.data-center-bigscreen .data-center-chart-tick { stroke: rgba(159, 193, 215, .3); }
.data-center-bigscreen .data-center-chart-x,
.data-center-bigscreen .data-center-chart-y { fill: #8fa6ba; }
.data-center-bigscreen .data-center-chart-legend text { fill: #b4c8d8; }

.data-center-map-stage {
  display: grid;
  gap: 10px;
  padding: 14px;
  overflow: hidden;
}

.data-center-map-hud {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.data-center-map-hud span {
  color: #4ebfe8;
  font-size: 10px;
  letter-spacing: .15em;
}

.data-center-map-hud strong {
  color: #dceff7;
  font-size: 13px;
}

.data-center-map-surface {
  position: relative;
  display: grid;
  min-height: 430px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(71, 186, 235, .16);
  background: linear-gradient(150deg, #071c2c 0%, #061522 72%, #082238 100%);
}

.data-center-map-grid {
  position: absolute;
  inset: 0;
  opacity: .35;
  background-image: linear-gradient(rgba(66, 163, 207, .12) 1px, transparent 1px), linear-gradient(90deg, rgba(66, 163, 207, .12) 1px, transparent 1px);
  background-size: 34px 34px;
  transform: perspective(420px) rotateX(54deg) scale(1.5) translateY(22%);
  transform-origin: center bottom;
}

.data-center-map-svg {
  position: relative;
  z-index: 2;
  width: 94%;
  height: auto;
  max-height: 390px;
  overflow: visible;
  transform: perspective(1100px) rotateX(8deg);
  transform-origin: center 86%;
}

.data-center-map-image {
  opacity: .96;
  filter: saturate(1.18) contrast(1.1) drop-shadow(0 0 18px rgba(20, 165, 255, .26));
}

.data-center-map-depth path {
  fill: none;
  stroke: rgba(42, 190, 255, .72);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 3 5;
  vector-effect: non-scaling-stroke;
  filter: drop-shadow(0 0 5px rgba(29, 177, 255, .72));
}

.data-center-map-depth path + path {
  stroke: rgba(8, 92, 164, .86);
  stroke-width: 3.6;
  stroke-dasharray: none;
  filter: drop-shadow(0 0 6px rgba(13, 118, 211, .58));
}

.data-center-map-land {
  stroke: #44cfff;
  stroke-width: 2.2;
  filter: drop-shadow(0 0 9px rgba(30, 200, 255, .5));
  animation: dataCenterMapLand 4.5s ease-in-out infinite;
  display: none;
}

.data-center-map-network path {
  fill: none;
  stroke: rgba(42, 156, 204, .42);
  stroke-width: .65;
  stroke-dasharray: 1 9;
  opacity: .58;
  vector-effect: non-scaling-stroke;
  animation: dataCenterMapNetwork 14s linear infinite;
}

.data-center-map-network path:nth-child(2) { animation-delay: -2s; }
.data-center-map-network path:nth-child(3) { animation-delay: -4s; }
.data-center-map-network path:nth-child(4) { animation-delay: -6s; }
.data-center-map-network path:nth-child(5) { animation-delay: -8s; }
.data-center-map-network path:nth-child(6) { animation-delay: -10s; }
.data-center-map-network path:nth-child(7) { animation-delay: -12s; }

.data-center-map-routes path {
  fill: none;
  stroke: #55ddff;
  stroke-width: 1.2;
  stroke-linecap: round;
  stroke-dasharray: 3 9;
  opacity: .78;
  vector-effect: non-scaling-stroke;
  filter: drop-shadow(0 0 4px rgba(59, 211, 255, .56));
  animation: dataCenterMapRoute 6s linear infinite;
}

.data-center-map-routes path:nth-child(2) { animation-delay: -2s; }
.data-center-map-routes path:nth-child(3) { animation-delay: -4s; }
.data-center-map-routes path:nth-child(4) { animation-delay: -1.1s; }
.data-center-map-routes path:nth-child(5) { animation-delay: -3.1s; }
.data-center-map-routes path:nth-child(6) { animation-delay: -5.1s; }
.data-center-map-routes path:nth-child(7) { animation-delay: -1.8s; }
.data-center-map-routes path:nth-child(8) { animation-delay: -3.8s; }
.data-center-map-routes path:nth-child(9) { animation-delay: -5.8s; }
.data-center-map-routes path:nth-child(10) { animation-delay: -2.6s; }
.data-center-map-routes path:nth-child(2),
.data-center-map-routes path:nth-child(5),
.data-center-map-routes path:nth-child(8) {
  stroke: #ffb45b;
  filter: drop-shadow(0 0 5px rgba(255, 165, 75, .72));
}

.data-center-map-nodes circle {
  fill: #4be5ff;
  stroke: #d6fbff;
  stroke-width: 1.35;
  vector-effect: non-scaling-stroke;
  filter: drop-shadow(0 0 5px rgba(62, 221, 255, .85));
  animation: none;
}

.data-center-map-nodes circle:nth-child(3n) { fill: #ffd36a; stroke: #fff3c8; filter: drop-shadow(0 0 5px rgba(255, 196, 92, .88)); }

.data-center-map-orbit {
  position: absolute;
  z-index: 3;
  top: 80%;
  left: 50%;
  border: 1px solid rgba(71, 207, 255, .33);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  box-shadow: 0 0 16px rgba(42, 194, 255, .12), inset 0 0 12px rgba(42, 194, 255, .08);
  will-change: transform;
  animation: none;
}

.data-center-map-orbit::before {
  content: "";
  position: absolute;
  inset: -5px;
  border: 0;
  border-radius: inherit;
  background: conic-gradient(from 0deg, transparent 0deg 18deg, rgba(105, 235, 255, .96) 18deg 31deg, transparent 31deg 62deg, rgba(50, 166, 255, .82) 62deg 70deg, transparent 70deg 146deg, rgba(72, 220, 255, .9) 146deg 154deg, transparent 154deg 360deg);
  -webkit-mask: radial-gradient(ellipse at center, transparent 0 68%, #000 69% 72%, transparent 73%);
  mask: radial-gradient(ellipse at center, transparent 0 68%, #000 69% 72%, transparent 73%);
  filter: drop-shadow(0 0 6px rgba(72, 220, 255, .78));
  animation: dataCenterMapOrbitArc 3.8s linear infinite;
}

.data-center-map-orbit::after {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: inherit;
  background: repeating-conic-gradient(from 0deg, rgba(67, 224, 255, .72) 0deg 1deg, transparent 1deg 9deg);
  -webkit-mask: radial-gradient(ellipse at center, transparent 0 77%, #000 78% 80%, transparent 81%);
  mask: radial-gradient(ellipse at center, transparent 0 77%, #000 78% 80%, transparent 81%);
  opacity: .7;
  animation: dataCenterMapOrbitSegments 8s linear infinite reverse;
}

.data-center-map-orbit.orbit-one { width: 230px; height: 92px; }
.data-center-map-orbit.orbit-two { width: 330px; height: 132px; opacity: .62; }
.data-center-map-orbit.orbit-three { width: 430px; height: 172px; opacity: .4; }
.data-center-map-orbit.orbit-two::before { animation-duration: 4.9s; animation-delay: -1.4s; }
.data-center-map-orbit.orbit-three::before { animation-duration: 6.2s; animation-delay: -2.7s; }
.data-center-map-orbit.orbit-two::after { animation-duration: 10s; animation-delay: -.6s; }
.data-center-map-orbit.orbit-three::after { animation-duration: 12s; animation-delay: -1.1s; }

.data-center-map-scanline {
  position: absolute;
  z-index: 3;
  top: -12%;
  left: 0;
  width: 100%;
  height: 2px;
  background: #58e7ff;
  box-shadow: 0 0 18px 4px rgba(74, 221, 255, .5);
  opacity: .7;
  animation: dataCenterMapScan 5.5s ease-in-out infinite;
}

.data-center-map-legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: #83a6b8;
  font-size: 10px;
}

.data-center-map-legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.data-center-map-legend em {
  color: #5e899d;
  font-style: normal;
}

.map-legend-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.map-legend-dot.cyan { background: #45ddff; box-shadow: 0 0 8px rgba(69, 221, 255, .8); }
.map-legend-dot.orange { background: #ffae45; box-shadow: 0 0 8px rgba(255, 174, 69, .8); }

@keyframes dataCenterLivePulse { 0%, 100% { opacity: .55; transform: scale(.84); } 50% { opacity: 1; transform: scale(1.15); } }
@keyframes dataCenterMapImage { 0%, 100% { opacity: .86; filter: saturate(1.08) contrast(1.04) drop-shadow(0 0 12px rgba(20, 165, 255, .18)); } 50% { opacity: 1; filter: saturate(1.26) contrast(1.12) drop-shadow(0 0 22px rgba(20, 190, 255, .34)); } }
@keyframes dataCenterMapLand { 0%, 100% { opacity: .82; } 50% { opacity: 1; } }
@keyframes dataCenterMapRoute { to { stroke-dashoffset: -72; } }
@keyframes dataCenterMapNetwork { to { stroke-dashoffset: -52; opacity: .8; } }
@keyframes dataCenterMapOrbitArc { from { background-position: -118% 0; } to { background-position: 118% 0; } }
@keyframes dataCenterMapOrbitSegments { from { opacity: .55; } to { opacity: .8; } }
@keyframes dataCenterMapScan { 0% { top: -12%; opacity: 0; } 15% { opacity: .8; } 85% { opacity: .8; } 100% { top: 112%; opacity: 0; } }

@media (max-width: 1180px) {
  .data-center-bigscreen-layout { grid-template-columns: minmax(190px, .7fr) minmax(360px, 1.5fr) minmax(190px, .7fr); }
  .data-center-map-surface { min-height: 360px; }
}

@media (max-width: 860px) {
  .data-center-bigscreen { width: calc(100vw - 20px); max-height: calc(100vh - 20px); margin: 10px auto; padding: 15px; }
  .data-center-bigscreen-layout { grid-template-columns: 1fr; }
  .data-center-bigscreen-main { order: -1; }
  .data-center-bigscreen-side-left,
  .data-center-bigscreen-side-right { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .data-center-screen-trend,
  .data-center-screen-status { grid-column: 1 / -1; }
  .data-center-map-surface { min-height: 330px; }
}

@media (max-width: 560px) {
  .data-center-bigscreen-head { align-items: flex-start; flex-direction: column; }
  .data-center-bigscreen-brand { position: static; max-width: 100%; order: 2; transform: none; white-space: normal; }
  .data-center-bigscreen-head-actions { width: 100%; justify-content: space-between; }
  .data-center-bigscreen-side-left,
  .data-center-bigscreen-side-right { grid-template-columns: 1fr; }
  .data-center-screen-trend,
  .data-center-screen-status { grid-column: auto; }
  .data-center-screen-hero strong { font-size: 34px; }
  .data-center-map-surface { min-height: 270px; }
  .data-center-map-legend { align-items: flex-start; flex-direction: column; }
}

/* Reference-map treatment: the artwork stays fixed while only route dashes and orbit light bands move. */
.data-center-map-surface {
  min-height: 0;
  aspect-ratio: 1.63 / 1;
  border-color: rgba(50, 176, 255, .28);
  background: #020a15;
  isolation: isolate;
}

.data-center-map-grid,
.data-center-map-scanline {
  display: none;
}

.data-center-map-reference {
  position: absolute;
  z-index: 1;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: .96;
  filter: saturate(1.08) contrast(1.06) brightness(.9) drop-shadow(0 0 20px rgba(20, 153, 255, .25));
  pointer-events: none;
}

.data-center-map-svg {
  z-index: 4;
  width: 100%;
  height: 100%;
  max-height: none;
  transform: none;
  pointer-events: none;
}

.data-center-map-image,
.data-center-map-land,
.data-center-map-depth,
.data-center-map-nodes {
  display: none;
}

.data-center-map-network,
.data-center-map-routes {
  mix-blend-mode: screen;
}

.data-center-map-network path {
  stroke: rgba(63, 185, 255, .34);
  stroke-width: .72;
  stroke-dasharray: 1 12;
  opacity: .58;
  animation: dataCenterMapNetwork 11s linear infinite;
}

.data-center-map-routes path {
  stroke: rgba(82, 209, 255, .72);
  stroke-width: .9;
  stroke-dasharray: 1.5 18;
  opacity: .7;
  filter: drop-shadow(0 0 3px rgba(71, 197, 255, .72));
  animation: dataCenterMapRoute 5.5s linear infinite;
}

.data-center-map-routes path:nth-child(2),
.data-center-map-routes path:nth-child(5),
.data-center-map-routes path:nth-child(8) {
  stroke: #ffb760;
  opacity: .78;
  filter: drop-shadow(0 0 4px rgba(255, 158, 67, .78));
}

.data-center-map-orbit {
  z-index: 5;
  top: 83%;
  border-color: rgba(48, 194, 255, .34);
  box-shadow: 0 0 18px rgba(25, 168, 255, .18), inset 0 0 14px rgba(42, 194, 255, .1);
  animation: none;
  will-change: auto;
}

.data-center-map-orbit.orbit-one { width: 47%; height: 15%; }
.data-center-map-orbit.orbit-two { width: 67%; height: 21%; opacity: .68; }
.data-center-map-orbit.orbit-three { width: 87%; height: 27%; opacity: .48; }

.data-center-map-orbit::before {
  inset: -5px;
  background: linear-gradient(90deg, transparent 0 36%, rgba(83, 215, 255, .12) 43%, rgba(172, 249, 255, .98) 50%, rgba(83, 215, 255, .12) 57%, transparent 64%);
  background-size: 235% 100%;
  background-position: -118% 0;
  -webkit-mask: radial-gradient(ellipse at center, transparent 0 67%, #000 68% 73%, transparent 74%);
  mask: radial-gradient(ellipse at center, transparent 0 67%, #000 68% 73%, transparent 74%);
  animation: dataCenterMapOrbitHorizontal 4.2s linear infinite alternate;
}

.data-center-map-orbit::after {
  inset: -11px;
  background: repeating-conic-gradient(from 0deg, rgba(91, 225, 255, .7) 0deg 1deg, transparent 1deg 11deg);
  -webkit-mask: radial-gradient(ellipse at center, transparent 0 77%, #000 78% 80%, transparent 81%);
  mask: radial-gradient(ellipse at center, transparent 0 77%, #000 78% 80%, transparent 81%);
  opacity: .7;
  animation: none;
}

.data-center-map-orbit.orbit-two::before { animation-duration: 5.4s; animation-delay: -1.2s; }
.data-center-map-orbit.orbit-three::before { animation-duration: 7s; animation-delay: -2.4s; }
.data-center-map-orbit.orbit-two::after { animation-duration: 11s; animation-delay: -.8s; }
.data-center-map-orbit.orbit-three::after { animation-duration: 14s; animation-delay: -1.6s; }

@media (max-width: 560px) {
  .data-center-map-surface { aspect-ratio: 1.48 / 1; }
}

@keyframes dataCenterMapOrbitHorizontal {
  from { background-position: -118% 0; }
  to { background-position: 118% 0; }
}
