:root {
  --oms-slate-950: #0f172a;
  --oms-slate-900: #111827;
  --oms-slate-800: #1e293b;
  --oms-slate-700: #334155;
  --oms-slate-600: #475569;
  --oms-slate-500: #64748b;
  --oms-slate-400: #94a3b8;
  --oms-slate-300: #cbd5e1;
  --oms-slate-200: #e2e8f0;
  --oms-slate-100: #f1f5f9;
  --oms-slate-50: #f8fafc;
  --oms-blue-700: #1d4ed8;
  --oms-blue-600: #2563eb;
  --oms-blue-500: #3b82f6;
  --oms-blue-50: #eff6ff;
  --oms-green-600: #16a34a;
  --oms-green-500: #22c55e;
  --oms-green-50: #f0fdf4;
  --oms-pink-500: #ec4899;
  --oms-orange-500: #f97316;
  --oms-red-500: #ef4444;
  --oms-yellow-500: #fff044;
  --oms-purple-500: #a855f7;
  --oms-cyan-500: #06b6d4;
  --oms-brand-primary-bg: var(--oms-blue-600);
  --oms-brand-primary-bg-hover: var(--oms-blue-700);
  --oms-brand-primary-fg: #ffffff;
  --oms-store-allegro-bg: var(--oms-yellow-500);
  --oms-store-allegro-fg: #713f12;
  --oms-store-bokserkoland-bg: var(--oms-cyan-500);
  --oms-store-bokserkoland-fg: #ffffff;
  --oms-store-heelito-bg: var(--oms-slate-900);
  --oms-store-heelito-fg: #ffffff;
  --oms-store-cz-bg: var(--oms-pink-500);
  --oms-store-cz-fg: #ffffff;
  --oms-store-sk-bg: var(--oms-blue-500);
  --oms-store-sk-fg: #ffffff;
  --oms-store-hu-bg: var(--oms-green-500);
  --oms-store-hu-fg: #ffffff;
  --oms-store-lt-bg: var(--oms-orange-500);
  --oms-store-lt-fg: #ffffff;
  --oms-store-ro-bg: #0ea5e9;
  --oms-store-ro-fg: #ffffff;
  --oms-status-ready-bg: #f0b14f;
  --oms-status-ready-fg: #ffffff;
  --oms-status-packing-bg: #6d28d9;
  --oms-status-packing-fg: #ffffff;
  --oms-status-sent-bg: #22a564;
  --oms-status-sent-fg: #ffffff;
  --oms-status-completed-bg: #f54fd4;
  --oms-status-completed-fg: #ffffff;
  --oms-status-return-bg: #c026d3;
  --oms-status-return-fg: #ffffff;
  --oms-status-cancelled-bg: #dc2626;
  --oms-status-cancelled-fg: #ffffff;
  --oms-signal-paid-bg: #22c55e;
  --oms-signal-paid-fg: #ffffff;
  --oms-signal-unpaid-bg: #dc2626;
  --oms-signal-unpaid-fg: #ffffff;
  --oms-signal-cod-bg: #fef3c7;
  --oms-signal-cod-fg: #92400e;
  --oms-carrier-inpost-bg: var(--oms-cyan-500);
  --oms-carrier-inpost-fg: #ffffff;
  --oms-carrier-dpd-bg: #fee2e2;
  --oms-carrier-dpd-fg: #991b1b;
  --oms-carrier-dhl-bg: #fef9c3;
  --oms-carrier-dhl-fg: #854d0e;
  --oms-carrier-orlen-bg: var(--oms-pink-500);
  --oms-carrier-orlen-fg: #ffffff;
  --oms-carrier-poczta-bg: #f87171;
  --oms-carrier-poczta-fg: #ffffff;
  --oms-carrier-packeta-bg: #e0e7ff;
  --oms-carrier-packeta-fg: #3730a3;
  --oms-chip-default-bg: #e2e8f0;
  --oms-chip-default-fg: #334155;
  --oms-control-radius-sm: 8px;
  --oms-control-radius-md: 10px;
  --oms-focus-ring: 0 0 0 3px rgba(59, 130, 246, 0.18);
  --oms-modal-backdrop: rgba(15, 23, 42, 0.62);
  --oms-modal-backdrop-soft: rgba(15, 23, 42, 0.54);
  --oms-modal-surface-bg: #ffffff;
  --oms-modal-surface-muted: #f8fafc;
  --oms-modal-border: #dbe4f0;
  --oms-modal-radius: 14px;
  --oms-modal-radius-lg: 18px;
  --oms-modal-shadow: 0 34px 110px rgba(15, 23, 42, 0.34);
  --oms-modal-header-bg: linear-gradient(135deg, #ffffff 0%, #f8fbff 58%, #eef6ff 100%);
  --oms-modal-footer-bg: rgba(248, 250, 252, 0.95);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-width: 0;
  height: 100%;
}

/* iOS Safari samo powieksza zawijany tekst w szerokich tabelach (lista zamowien na
   telefonie): pozycje w 2 liniach rosly, jednoliniowe zostawaly male. */
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f5f7fa;
  color: var(--oms-slate-950);
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

select {
  font: inherit;
}

button {
  border: 0;
}

.oms-app {
  display: flex;
  height: 100vh;
  min-width: 0;
  overflow: hidden;
}

.oms-sidebar {
  display: flex;
  flex: 0 0 72px;
  width: 72px;
  min-width: 72px;
  flex-direction: column;
  background: var(--oms-slate-950);
  color: var(--oms-slate-300);
  overflow: hidden;
  transition: flex-basis 0.18s ease, width 0.18s ease, min-width 0.18s ease;
}

.oms-sidebar:hover,
.oms-sidebar:focus-within {
  flex-basis: 230px;
  width: 230px;
  min-width: 230px;
}

.oms-sidebar-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 58px;
  padding: 18px 8px;
  border-bottom: 1px solid var(--oms-slate-800);
}

.oms-sidebar:hover .oms-sidebar-top,
.oms-sidebar:focus-within .oms-sidebar-top {
  justify-content: space-between;
  padding-right: 16px;
  padding-left: 16px;
}

.oms-logo {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: white;
  text-decoration: none;
  font-size: 22px;
  line-height: 1;
  font-weight: 700;
}

.oms-logo span {
  color: var(--oms-blue-500);
}

.oms-logo-mark {
  width: 26px;
  height: 26px;
  flex: none;
  color: inherit;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-logo {
  width: 34px;
  justify-content: center;
  font-size: 0;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-logo {
  gap: 0;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-nav-section {
  color: transparent;
}

.oms-preview-badge {
  border: 1px solid rgba(59, 130, 246, 0.35);
  border-radius: 999px;
  padding: 4px 8px;
  color: #bfdbfe;
  background: rgba(59, 130, 246, 0.12);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  text-transform: uppercase;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-preview-badge,
.oms-sidebar:not(:hover):not(:focus-within) .oms-nav-label,
.oms-sidebar:not(:hover):not(:focus-within) .oms-sidebar-source-body,
.oms-sidebar:not(:hover):not(:focus-within) .oms-sidebar-sources-summary {
  display: none;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-nav-subitem {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.oms-sidebar-nav {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 12px 8px;
  overflow-y: auto;
}

/* applyRoleUi chowa elementy atrybutem hidden; kazdy wlasny display
   (np. flex na nav) nadpisuje UA [hidden]{display:none} i konto bez
   uprawnien widzialo Analityke/Integracje/Kontrole w menu. */
.oms-nav-item[hidden],
.oms-nav-subitem[hidden],
[data-oms-profile-view][hidden],
[data-requires-permission][hidden] {
  display: none !important;
}

.oms-nav-item,
.oms-nav-subitem {
  display: flex;
  width: 100%;
  min-height: 36px;
  align-items: center;
  gap: 10px;
  border-radius: 8px;
  color: var(--oms-slate-400);
  background: transparent;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}

.oms-nav-item {
  padding: 9px 12px;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-nav-item {
  justify-content: center;
  padding: 9px;
}

.oms-nav-subitem {
  margin-left: 28px;
  width: calc(100% - 28px);
  min-height: 34px;
  padding: 8px 12px;
  font-size: 13px;
}

.oms-nav-item:hover,
.oms-nav-subitem:hover,
.oms-nav-item.active,
.oms-nav-subitem.active {
  background: var(--oms-slate-800);
  color: white;
}

.oms-nav-item:disabled,
.oms-nav-subitem:disabled {
  cursor: not-allowed;
  opacity: 0.65;
}

.oms-nav-item svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  opacity: 0.84;
}

.oms-nav-section {
  margin-top: 18px;
  padding: 0 12px 8px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.oms-allegro-mark {
  display: inline-flex;
  width: 18px;
  height: 18px;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: #ff5a00;
  color: white;
  font-size: 10px;
  font-weight: 800;
}

.oms-sidebar-sources {
  display: grid;
  gap: 1px;
}

.oms-sidebar-source {
  position: relative;
  display: grid;
  width: 100%;
  min-height: 26px;
  grid-template-columns: 14px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  border-radius: 6px;
  background: transparent;
  padding: 3px 12px;
  color: rgba(148, 163, 184, 0.72);
  text-align: left;
}

.oms-sidebar-source:hover,
.oms-sidebar-source.active {
  background: rgba(30, 41, 59, 0.42);
  color: #cbd5e1;
}

.oms-sidebar-source:disabled {
  cursor: default;
  opacity: 0.68;
}

.oms-sidebar-source-filter {
  display: grid;
  min-width: 0;
  grid-template-columns: 4px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  padding: 0;
  text-align: left;
}

.oms-sidebar-source-filter:disabled {
  cursor: default;
}

.oms-sidebar-source-sync {
  display: inline-flex;
  width: 14px;
  height: 14px;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 0;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-sidebar-source {
  min-height: 24px;
  grid-template-columns: 14px;
  justify-content: center;
  padding: 4px 0;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-sidebar-source-filter {
  display: none;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-sidebar-source-sync {
  display: inline-flex;
}

.oms-sidebar-source-mark {
  display: inline-flex;
  width: 3px;
  height: 3px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.42);
  color: transparent;
  font-size: 0;
  font-weight: 900;
  line-height: 1;
  box-shadow: none;
  opacity: 0.72;
}

.oms-sidebar-source-mark.tone-allegro,
.oms-sidebar-source-mark.tone-pl,
.oms-sidebar-source-mark.tone-hp,
.oms-sidebar-source-mark.tone-cz,
.oms-sidebar-source-mark.tone-sk,
.oms-sidebar-source-mark.tone-hu,
.oms-sidebar-source-mark.tone-lt,
.oms-sidebar-source-mark.tone-ro {
  background: rgba(148, 163, 184, 0.42);
}

.oms-sidebar-source-body {
  display: grid;
  min-width: 0;
  gap: 0;
}

.oms-sidebar-source-body strong,
.oms-sidebar-source-body small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-sidebar-source-body strong {
  color: inherit;
  font-size: 11px;
  font-weight: 650;
}

.oms-sidebar-source-body small {
  display: none;
  color: rgba(148, 163, 184, 0.58);
  font-size: 9px;
  font-weight: 550;
}

.oms-sidebar-source:hover .oms-sidebar-source-body small,
.oms-sidebar-source.active .oms-sidebar-source-body small {
  display: none;
  color: rgba(191, 219, 254, 0.62);
}

.oms-sidebar-health-dot {
  display: inline-flex;
  width: 14px;
  height: 14px;
  align-items: center;
  justify-content: center;
  background: transparent;
  border-radius: 999px;
  box-shadow: none;
  cursor: pointer;
}

.oms-sidebar-health-dot::after {
  display: block;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: #64748b;
  content: "";
  opacity: 0.62;
  transition: opacity 140ms ease, transform 140ms ease;
}

.oms-sidebar-health-dot:hover::after {
  opacity: 0.86;
  transform: scale(1.25);
}

.oms-sidebar-health-dot.syncing::after {
  animation: oms-sidebar-health-sync 900ms ease-in-out infinite;
  background: #60a5fa;
  opacity: 0.9;
}

@keyframes oms-sidebar-health-sync {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.35);
  }
}

.oms-sidebar-health-dot.ok::after {
  background: #22c55e;
}

.oms-sidebar-health-dot.watch::after {
  background: #facc15;
}

.oms-sidebar-health-dot.error::after {
  background: #ef4444;
}

.oms-sidebar-health-dot.muted::after,
.oms-sidebar-health-dot.loading::after {
  background: #64748b;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-sidebar-health-dot {
  position: static;
}

.oms-sidebar-sources-summary {
  display: none;
}

.oms-sidebar-sync-all {
  position: relative;
  display: flex;
  width: calc(100% - 24px);
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
  overflow: hidden;
  margin: 8px 12px 12px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 6px;
  background: rgba(148, 163, 184, 0.10);
  padding: 6px 9px;
  color: rgba(226, 232, 240, 0.86);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

/* Delikatny przelot swiatla tylko w trakcie pobierania - sygnal, ze cos zyje. */
.oms-sidebar-sync-all::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 38%, rgba(255, 255, 255, 0.07) 50%, transparent 62%);
  transform: translateX(-120%);
  pointer-events: none;
}

.oms-sidebar-sync-all.syncing::before {
  animation: omsSyncAllShine 2.1s ease-in-out infinite;
}

/* Pasek postepu na dole przycisku - ile zrodel juz zeszlo. */
.oms-sidebar-sync-all::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: calc(var(--sync-progress, 0) * 1%);
  background: rgba(148, 163, 184, 0.75);
  transition: width 0.3s ease;
}

.oms-sidebar-sync-all:hover:not(:disabled) {
  border-color: rgba(148, 163, 184, 0.40);
  background: rgba(148, 163, 184, 0.20);
  color: #f8fafc;
}

.oms-sidebar-sync-all:active:not(:disabled) {
  background: rgba(148, 163, 184, 0.14);
}

.oms-sidebar-sync-all:focus-visible {
  outline: 2px solid rgba(148, 163, 184, 0.55);
  outline-offset: 2px;
}

.oms-sidebar-sync-all:disabled {
  cursor: default;
}

.oms-sidebar-sync-all[hidden] {
  display: none;
}

.oms-sync-all-icon {
  display: inline-flex;
  flex: 0 0 14px;
  width: 14px;
  height: 14px;
  color: rgba(148, 163, 184, 0.9);
}

.oms-sidebar-sync-all:hover:not(:disabled) .oms-sync-all-icon {
  color: rgba(226, 232, 240, 0.95);
}

.oms-sidebar-sync-all.syncing .oms-sync-all-icon {
  color: rgba(226, 232, 240, 0.95);
  animation: omsSyncAllSpin 1.1s linear infinite;
}

.oms-sync-all-icon svg {
  width: 100%;
  height: 100%;
}

.oms-sync-all-label {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-sync-all-count {
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.14);
  padding: 2px 6px;
  color: rgba(226, 232, 240, 0.85);
  font-size: 9px;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

.oms-sync-all-count:empty {
  display: none;
}

@keyframes omsSyncAllShine {
  0% { transform: translateX(-120%); }
  60%, 100% { transform: translateX(120%); }
}

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

@media (prefers-reduced-motion: reduce) {
  .oms-sidebar-sync-all::before,
  .oms-sidebar-sync-all.syncing .oms-sync-all-icon {
    animation: none;
  }
}

/* Zwiniety sidebar: zostaje sama ikona w szynie. */
.oms-sidebar:not(:hover):not(:focus-within) .oms-sidebar-sync-all {
  width: 40px;
  margin: 0 auto 8px;
  justify-content: center;
  padding: 7px 0;
}

.oms-sidebar:not(:hover):not(:focus-within) .oms-sync-all-label,
.oms-sidebar:not(:hover):not(:focus-within) .oms-sync-all-count {
  display: none;
}

.oms-sidebar-sources-empty {
  padding: 6px 12px 0;
  color: var(--oms-slate-500);
  font-size: 9px;
  font-weight: 550;
  line-height: 1.35;
}

.oms-toast-stack {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 2400;
  display: grid;
  width: min(360px, calc(100vw - 32px));
  gap: 8px;
  pointer-events: none;
}

.oms-toast {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.94);
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.24);
  color: #e5e7eb;
  padding: 10px 12px;
  pointer-events: auto;
}

.oms-toast strong,
.oms-toast span {
  display: block;
}

.oms-toast strong {
  margin-bottom: 2px;
  font-size: 12px;
  font-weight: 760;
}

.oms-toast span {
  color: rgba(226, 232, 240, 0.78);
  font-size: 11px;
  line-height: 1.35;
}

.oms-toast button {
  appearance: none;
  border: 0;
  background: transparent;
  color: rgba(226, 232, 240, 0.64);
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.oms-toast.success {
  border-color: rgba(34, 197, 94, 0.34);
}

.oms-toast.warning {
  border-color: rgba(250, 204, 21, 0.38);
}

.oms-toast.error {
  border-color: rgba(248, 113, 113, 0.44);
}

.oms-main {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.oms-topbar {
  display: flex;
  height: 56px;
  min-height: 56px;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--oms-slate-200);
  background: white;
  padding: 0 20px;
}

.oms-quick-access {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--oms-slate-600);
  background: transparent;
  font-weight: 600;
  cursor: pointer;
}

.oms-quick-access svg {
  width: 20px;
  height: 20px;
}

.oms-search {
  position: relative;
  display: block;
  flex: 1;
  max-width: 560px;
}

.oms-search:focus-within {
  z-index: 2600;
}

.oms-search input {
  width: 100%;
  height: 36px;
  border: 1px solid transparent;
  border-radius: 8px;
  outline: none;
  background: var(--oms-slate-100);
  padding: 0 36px;
  color: var(--oms-slate-950);
}

.oms-search input:focus {
  border-color: var(--oms-blue-500);
  background: white;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
}

.oms-search svg {
  position: absolute;
  left: 12px;
  top: 10px;
  width: 16px;
  height: 16px;
  color: var(--oms-slate-400);
}

.oms-search-results {
  position: absolute;
  z-index: 2600;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  max-height: min(430px, calc(100vh - 92px));
  overflow: auto;
  border: 1px solid #d8e0ec;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 20px 46px rgba(15, 23, 42, 0.18);
  padding: 8px;
}

.oms-search-results[hidden] {
  display: none;
}

.oms-search-results-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 8px 9px;
  color: #667085;
  font-size: 12px;
}

.oms-search-results-head strong {
  color: #1d2939;
  font-size: 12px;
  font-weight: 850;
}

.oms-search-results-status,
.oms-search-results-empty {
  margin: 2px 0 6px;
  border-radius: 8px;
  background: #f8fafc;
  padding: 10px;
  color: #667085;
  font-size: 13px;
  font-weight: 700;
}

.oms-search-results-status.error {
  background: #fff1f2;
  color: #be123c;
}

.oms-search-result {
  display: grid;
  width: 100%;
  grid-template-columns: minmax(0, 1.2fr) minmax(180px, 0.8fr);
  gap: 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  padding: 10px 11px;
  text-align: left;
  cursor: pointer;
}

.oms-search-result:hover,
.oms-search-result:focus {
  border-color: #b7cffd;
  outline: none;
  background: #f4f8ff;
}

.oms-search-result[aria-selected="true"] {
  border-color: #dbeafe;
}

.oms-search-result-main,
.oms-search-result-side {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 3px;
}

.oms-search-result-main strong,
.oms-search-result-side strong {
  overflow: hidden;
  color: #101828;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-search-result-main em,
.oms-search-result-side em {
  overflow: hidden;
  color: #667085;
  font-size: 12px;
  font-style: normal;
  font-weight: 650;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-search-result-side {
  align-items: flex-end;
  text-align: right;
}

.oms-top-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
}

.oms-current-link {
  height: 34px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 0 12px;
  color: var(--oms-slate-700);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.oms-current-link:hover {
  background: var(--oms-slate-50);
}

.oms-sound-toggle {
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 0;
  color: var(--oms-slate-600);
  font-size: 13px;
  font-weight: 750;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.oms-sound-toggle svg {
  width: 17px;
  height: 17px;
}

.oms-sound-toggle:hover {
  background: var(--oms-slate-50);
  color: var(--oms-slate-950);
}

.oms-sound-toggle.active {
  border-color: rgba(34, 197, 94, 0.35);
  background: var(--oms-green-50);
  color: #15803d;
}

.oms-sound-toggle.ping {
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.18);
}

.oms-sound-volume {
  display: inline-flex;
  height: 34px;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 0 9px;
  color: var(--oms-slate-600);
}

.oms-sound-volume[hidden] {
  display: none !important;
}

.oms-sound-volume svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}

.oms-sound-volume input {
  width: 88px;
  min-width: 88px;
  accent-color: #16a34a;
  cursor: pointer;
}

.oms-sound-volume::after {
  content: attr(data-volume);
  min-width: 34px;
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 750;
  text-align: right;
}

.oms-ui-mode-toggle {
  display: inline-flex;
  position: relative;
  z-index: 4;
  align-items: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 9px;
  background: var(--oms-slate-50);
  padding: 2px;
}

.oms-ui-mode-toggle[hidden] {
  display: none !important;
}

.oms-ui-mode-btn {
  min-width: 62px;
  height: 28px;
  border-radius: 7px;
  background: transparent;
  color: var(--oms-slate-500);
  cursor: pointer;
  font-size: 12px;
  font-weight: 850;
}

.oms-ui-mode-btn:hover {
  color: var(--oms-slate-950);
}

.oms-ui-mode-btn.active {
  background: var(--oms-blue-600);
  color: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.14);
}

.oms-icon-btn {
  position: relative;
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: transparent;
  color: var(--oms-slate-500);
  cursor: pointer;
}

.oms-theme-toggle {
  font-size: 16px;
  font-weight: 850;
}

.oms-icon-btn:hover {
  background: var(--oms-slate-100);
  color: var(--oms-slate-950);
}

.oms-icon-btn svg {
  width: 18px;
  height: 18px;
}

.oms-notification-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  display: inline-flex;
  min-width: 18px;
  height: 18px;
  align-items: center;
  justify-content: center;
  border: 2px solid white;
  border-radius: 999px;
  background: var(--oms-red-500);
  color: white;
  font-size: 10px;
  font-weight: 800;
}

.oms-notification-badge[hidden] {
  display: none !important;
}

.oms-notifications-shell {
  position: relative;
  display: inline-flex;
}

.oms-notifications-shell[hidden] {
  display: none !important;
}

.oms-notifications-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 80;
  width: min(380px, calc(100vw - 28px));
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.26);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 20px 44px rgba(15, 23, 42, 0.16);
  backdrop-filter: blur(14px);
}

.oms-notifications-panel[hidden] {
  display: none !important;
}

.oms-notifications-panel header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--oms-slate-200);
  padding: 12px 14px;
}

.oms-notifications-panel header div {
  display: grid;
  gap: 2px;
}

.oms-notifications-panel header strong {
  color: var(--oms-slate-950);
  font-size: 14px;
  font-weight: 900;
}

.oms-notifications-panel header small {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 700;
}

.oms-notifications-panel header button,
.oms-notification-item button {
  min-height: 30px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
  color: var(--oms-slate-700);
  cursor: pointer;
  font-size: 12px;
  font-weight: 850;
  padding: 0 10px;
}

.oms-notifications-panel header button:hover,
.oms-notification-item button:hover {
  border-color: rgba(37, 99, 235, 0.34);
  color: var(--oms-blue-700);
}

.oms-notifications-list {
  display: grid;
  max-height: 420px;
  overflow: auto;
  padding: 8px;
}

.oms-notification-empty {
  display: grid;
  gap: 4px;
  border-radius: 10px;
  color: var(--oms-slate-500);
  font-size: 13px;
  font-weight: 750;
  padding: 18px 14px;
  text-align: center;
}

.oms-notification-empty.error {
  background: #fef2f2;
  color: #991b1b;
  text-align: left;
}

.oms-notification-empty.loading::before {
  content: "";
  width: 18px;
  height: 18px;
  margin: 0 auto 6px;
  border: 2px solid var(--oms-slate-200);
  border-top-color: var(--oms-blue-600);
  border-radius: 999px;
  animation: oms-spin 0.8s linear infinite;
}

.oms-notification-item {
  display: grid;
  gap: 7px;
  border-left: 3px solid var(--oms-slate-300);
  border-radius: 10px;
  padding: 11px 12px;
}

.oms-notification-item + .oms-notification-item {
  margin-top: 6px;
}

.oms-notification-item.critical {
  border-left-color: var(--oms-red-500);
  background: #fff7f7;
}

.oms-notification-item.warning {
  border-left-color: #f59e0b;
  background: #fffbeb;
}

.oms-notification-item.info {
  border-left-color: var(--oms-blue-500);
  background: #f8fbff;
}

.oms-notification-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--oms-slate-500);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.oms-notification-item strong {
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 900;
}

.oms-notification-item p {
  margin: 0;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.oms-notification-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.oms-notification-meta span {
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.16);
  color: var(--oms-slate-600);
  font-size: 10px;
  font-weight: 850;
  padding: 4px 7px;
}

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

.oms-user-shell {
  position: relative;
}

.oms-user {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-left: 1px solid var(--oms-slate-200);
  border-top: 0;
  border-right: 0;
  border-bottom: 0;
  background: transparent;
  padding-left: 12px;
  color: var(--oms-slate-950);
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}

.oms-user:hover .oms-user-meta strong,
.oms-user:focus-visible .oms-user-meta strong {
  color: var(--oms-blue-700);
}

.oms-avatar {
  display: inline-flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--oms-blue-500);
  color: white;
  font-size: 13px;
  font-weight: 800;
  overflow: hidden;
}

.oms-avatar.has-image {
  background: var(--oms-slate-200);
}

.oms-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.oms-avatar.compact {
  width: 38px;
  height: 38px;
  font-size: 14px;
}

.oms-user-meta {
  display: inline-flex;
  flex-direction: column;
  gap: 1px;
  line-height: 1.1;
}

.oms-user-meta strong {
  font-size: 13px;
  font-weight: 800;
}

.oms-user-meta small {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 700;
}

.oms-user-chevron {
  width: 14px;
  height: 14px;
  color: var(--oms-slate-400);
}

.oms-profile-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  z-index: 70;
  width: 342px;
  overflow: hidden;
  border: 1px solid rgba(203, 213, 225, 0.92);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
}

.oms-profile-menu[hidden] {
  display: none;
}

.oms-profile-menu header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--oms-slate-100);
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.oms-profile-menu header strong,
.oms-profile-menu-grid strong {
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 900;
}

.oms-profile-menu header small {
  display: block;
  max-width: 200px;
  overflow: hidden;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-profile-menu-grid {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 8px 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--oms-slate-100);
}

.oms-profile-menu-grid span {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.oms-profile-sessions {
  display: grid;
  gap: 8px;
  border-bottom: 1px solid var(--oms-slate-100);
  background: #fbfdff;
  padding: 12px 14px;
}

.oms-profile-sessions-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.oms-profile-sessions-head strong {
  color: var(--oms-slate-950);
  font-size: 12px;
  font-weight: 900;
}

.oms-profile-sessions-head span,
.oms-profile-current-session,
.oms-profile-sessions-empty {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 800;
}

.oms-profile-sessions-head span.error {
  color: var(--oms-red-500);
}

.oms-profile-sessions-list {
  display: grid;
  gap: 6px;
  max-height: 184px;
  overflow: auto;
}

.oms-profile-session-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 11px;
  background: #ffffff;
  padding: 8px 9px;
}

.oms-profile-session-row.current {
  border-color: rgba(37, 99, 235, 0.28);
  background: #eff6ff;
}

.oms-profile-session-row div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.oms-profile-session-row strong,
.oms-profile-session-row small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-profile-session-row strong {
  color: var(--oms-slate-900);
  font-size: 12px;
  font-weight: 900;
}

.oms-profile-session-row small {
  color: var(--oms-slate-500);
  font-size: 10px;
  font-weight: 750;
}

.oms-profile-session-row button,
.oms-profile-revoke-others {
  border: 1px solid var(--oms-slate-200);
  border-radius: 9px;
  background: #ffffff;
  color: var(--oms-slate-700);
  cursor: pointer;
  font-size: 11px;
  font-weight: 900;
  padding: 6px 8px;
}

.oms-profile-session-row button:hover,
.oms-profile-revoke-others:hover {
  border-color: rgba(37, 99, 235, 0.34);
  color: var(--oms-blue-700);
}

.oms-profile-session-row button:disabled,
.oms-profile-revoke-others:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.oms-profile-revoke-others {
  width: 100%;
  min-height: 32px;
}

.oms-profile-station {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-bottom: 1px solid var(--oms-slate-100);
  background: #f8fbff;
}

.oms-profile-station[hidden] {
  display: none;
}

.oms-profile-station-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.oms-profile-station-head > div {
  display: grid;
  gap: 3px;
}

.oms-profile-station-head strong {
  color: var(--oms-slate-950);
  font-size: 12px;
  font-weight: 900;
}

.oms-profile-station-head small,
.oms-profile-station p {
  margin: 0;
  color: var(--oms-slate-500);
  font-size: 10px;
  font-weight: 750;
}

.oms-profile-station-head code {
  color: var(--oms-blue-700);
  font-family: inherit;
  font-weight: 900;
}

.oms-profile-station-head > span {
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--oms-slate-200);
  color: var(--oms-slate-600);
  font-size: 9px;
  font-weight: 900;
  padding: 5px 7px;
  text-transform: uppercase;
}

.oms-profile-station-head > span.assigned {
  background: #dcfce7;
  color: #166534;
}

.oms-profile-station-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.oms-profile-station-actions button {
  min-height: 36px;
  border: 1px solid rgba(37, 99, 235, 0.24);
  border-radius: 9px;
  background: #ffffff;
  color: var(--oms-blue-700);
  cursor: pointer;
  font: inherit;
  font-size: 10px;
  font-weight: 900;
  padding: 7px 8px;
}

.oms-profile-station-actions button:hover:not(:disabled),
.oms-profile-station-actions button:focus-visible:not(:disabled) {
  border-color: rgba(37, 99, 235, 0.5);
  background: #eff6ff;
}

.oms-profile-station-actions button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.oms-profile-station p.error {
  color: var(--oms-red-500);
}

.oms-profile-menu button[role="menuitem"] {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  border: 0;
  border-top: 1px solid var(--oms-slate-100);
  background: #ffffff;
  color: var(--oms-slate-700);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 850;
  padding: 12px 16px;
  text-align: left;
}

.oms-profile-menu button[role="menuitem"]:hover,
.oms-profile-menu button[role="menuitem"]:focus-visible {
  background: #f5f8ff;
  color: var(--oms-blue-700);
}

.oms-workspace {
  display: flex;
  min-height: 0;
  min-width: 0;
  flex: 1;
}

.oms-filters-panel {
  display: flex;
  flex: 0 0 220px;
  width: 220px;
  min-width: 220px;
  flex-direction: column;
  border-right: 1px solid var(--oms-slate-200);
  background: white;
}

.oms-filters-panel[hidden] {
  display: none;
}

.oms-filters-header {
  padding: 10px;
}

.oms-btn-primary,
.oms-btn-ghost,
.oms-btn-back,
.oms-btn-light,
.oms-ship-btn,
.oms-page-btn,
.oms-tool-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
}

.oms-btn-primary {
  width: 100%;
  height: 34px;
  border-radius: var(--oms-control-radius-sm);
  background: var(--oms-brand-primary-bg);
  color: var(--oms-brand-primary-fg);
  font-size: 13px;
  font-weight: 750;
  box-shadow: 0 1px 2px rgba(37, 99, 235, 0.18);
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.oms-btn-primary:hover:not(:disabled) {
  background: var(--oms-brand-primary-bg-hover);
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.18);
  transform: translateY(-1px);
}

.oms-btn-primary.compact {
  width: auto;
  padding: 0 14px;
}

.oms-btn-primary:disabled {
  cursor: not-allowed;
  opacity: 0.9;
}

.oms-btn-primary svg {
  width: 16px;
  height: 16px;
}

.oms-btn-primary:focus-visible,
.oms-btn-ghost:focus-visible,
.oms-btn-light:focus-visible,
.oms-ship-btn:focus-visible,
.oms-page-btn:focus-visible,
.oms-tool-btn:focus-visible,
.oms-btn-pack:focus-visible,
.oms-inline-action:focus-visible,
.oms-status-apply:focus-visible,
.oms-status-clear:focus-visible {
  outline: 0;
  box-shadow: var(--oms-focus-ring);
}

.oms-filter-group {
  flex: 1;
  overflow-y: auto;
  padding: 7px;
}

.oms-filter-item,
.oms-filter-subitem {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 8px;
  border-radius: 6px;
  background: transparent;
  color: var(--oms-slate-700);
  cursor: pointer;
  text-align: left;
}

.oms-filter-item {
  min-height: 31px;
  margin-bottom: 1px;
  padding: 6px 8px;
  font-size: 12.8px;
}

.oms-filter-subitem {
  min-height: 29px;
  padding: 5px 8px 5px 20px;
  color: var(--oms-slate-600);
  font-size: 12.5px;
}

.oms-filter-item:hover,
.oms-filter-subitem:hover {
  background: var(--oms-slate-100);
}

.oms-filter-item.active,
.oms-filter-subitem.active {
  background: var(--oms-blue-50);
  color: var(--oms-blue-700);
  font-weight: 600;
}

.oms-filter-item svg {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
}

.oms-count {
  margin-left: auto;
  border-radius: 999px;
  background: var(--oms-slate-200);
  padding: 2px 6px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 700;
}

.oms-filter-section {
  margin-top: 11px;
}

.oms-filter-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 5px 8px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 800;
}

.oms-filter-toggle {
  display: none;
}

.oms-mobile-filter-sections {
  display: block;
}

.oms-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex: 0 0 8px;
}

.oms-dot-yellow { background: var(--oms-yellow-500); }
.oms-dot-pink { background: var(--oms-pink-500); }
.oms-dot-red { background: var(--oms-red-500); }
.oms-dot-orange { background: var(--oms-orange-500); }
.oms-dot-cyan { background: var(--oms-cyan-500); }
/* Kolejka "Brak info" - fiolet, zeby nie mylil sie z problemem (rozowy). */
.oms-dot-purple { background: #8b5cf6; }
.oms-dot-lost { background: #b91c1c; }
.oms-dot-green { background: var(--oms-green-500); }
.oms-dot-blue { background: var(--oms-blue-500); }
.oms-dot-black { background: var(--oms-slate-900); }

.oms-orders-area {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  background: var(--oms-slate-50);
}

.oms-orders-area[hidden] {
  display: none;
}

.oms-dashboard-view {
  min-width: 0;
  flex: 1;
  overflow: auto;
  padding: 18px;
  background: #20262d;
  color: #e5e7eb;
}

.oms-dashboard-view[hidden] {
  display: none;
}

.oms-dashboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.oms-dashboard-header .oms-orders-title {
  color: #f8fafc;
}

.oms-dashboard-header .oms-orders-subtitle {
  color: #94a3b8;
}

.oms-dashboard-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.48fr) minmax(420px, 1fr);
  gap: 22px;
}

.oms-dashboard-card {
  min-height: 220px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 12px;
  background: #30363d;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.32);
}

.oms-dashboard-today-card {
  display: flex;
  min-height: 260px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 30px;
  text-align: center;
}

.oms-dashboard-link-card {
  appearance: none;
  border: 1px solid rgba(148, 163, 184, 0.12);
  cursor: pointer;
  font: inherit;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.oms-dashboard-link-card:hover {
  border-color: rgba(143, 183, 205, 0.45);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.36);
  transform: translateY(-1px);
}

.oms-dashboard-link-card:focus-visible {
  outline: 3px solid rgba(96, 165, 250, 0.5);
  outline-offset: 3px;
}

.oms-dashboard-big-number {
  color: #8fb7cd;
  font-size: clamp(64px, 8vw, 106px);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}

.oms-dashboard-card-title {
  margin-top: 14px;
  color: #f3f4f6;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.oms-dashboard-card-subtitle {
  margin-top: 10px;
  color: #a8b0ba;
  font-size: 15px;
  font-weight: 700;
}

.oms-dashboard-card-subtitle strong {
  color: #e5e7eb;
}

.oms-dashboard-store-split {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 18px;
}

.oms-dashboard-store-pill {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  padding: 6px 11px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.42);
  color: #cbd5e1;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.oms-dashboard-store-pill strong {
  color: #f8fafc;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}

.oms-dashboard-store-pill[data-store-tone="allegro"] {
  border-color: rgba(255, 152, 0, 0.45);
  color: #f8c07a;
}

.oms-dashboard-store-pill[data-store-tone="boks"] {
  border-color: rgba(96, 165, 250, 0.42);
  color: #a8c8f5;
}

.oms-dashboard-store-pill[data-store-tone="cz"] {
  border-color: rgba(244, 114, 182, 0.42);
  color: #f0aed2;
}

.oms-dashboard-store-pill[data-store-tone="tulinkovo"] {
  border-color: rgba(251, 191, 36, 0.42);
  color: #f3d391;
}

.oms-dashboard-store-pill[data-store-tone="sk"] {
  border-color: rgba(45, 212, 191, 0.42);
  color: #9fe3da;
}

.oms-dashboard-store-pill[data-store-tone="lt"] {
  border-color: rgba(163, 230, 53, 0.38);
  color: #cbe89a;
}

.oms-dashboard-store-pill[data-store-tone="hu"],
.oms-dashboard-store-pill[data-store-tone="ro"] {
  border-color: rgba(148, 163, 184, 0.32);
  color: #cbd5e1;
}

.oms-dashboard-store-pill[data-store-tone="heelito"] {
  border-color: rgba(192, 132, 252, 0.42);
  color: #ddbcfb;
}

.oms-dashboard-store-pill[data-store-tone="bestilo"] {
  border-color: rgba(56, 189, 248, 0.42);
  color: #a5dcf7;
}

.oms-dashboard-store-empty {
  color: #94a3b8;
  font-size: 13px;
  font-weight: 600;
}

.oms-dashboard-chart-card {
  min-height: 260px;
  padding: 26px 30px 22px;
}

.oms-dashboard-chart-legend {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 64px;
  color: #e5e7eb;
  font-size: 19px;
  font-weight: 800;
}

.oms-dashboard-chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.oms-dashboard-chart-legend i {
  width: 44px;
  height: 3px;
  display: inline-block;
  border-radius: 999px;
}

.oms-dashboard-chart-legend i.orders {
  background: #9aa1a8;
}

.oms-dashboard-chart-legend i.value {
  background: #1689e9;
}

.oms-dashboard-chart {
  min-height: 190px;
  margin-top: 14px;
}

.oms-dashboard-chart svg {
  width: 100%;
  height: 190px;
  overflow: visible;
}

.oms-dashboard-axis,
.oms-dashboard-axis-label,
.oms-dashboard-day-label {
  fill: #e5e7eb;
  font-size: 13px;
  font-weight: 700;
}

.oms-dashboard-day-label {
  fill: #d1d5db;
}

.oms-dashboard-chart-empty {
  display: grid;
  height: 100%;
  place-items: center;
  color: #9ca3af;
  font-weight: 700;
}

.oms-dashboard-source-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.oms-dashboard-source-pill {
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.35);
  color: #dbe3ed;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 800;
}

.oms-operations-dashboard {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid #dce3ea;
}

.oms-operations-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.oms-operations-header h2 {
  margin: 0;
  color: #17212b;
  font-size: 18px;
  line-height: 1.25;
}

.oms-operations-header p {
  margin: 4px 0 0;
  color: #66717d;
  font-size: 12px;
}

.oms-operations-overall,
.oms-operations-card-head span {
  border: 1px solid #cfd7df;
  border-radius: 6px;
  background: #f4f6f8;
  color: #3d4854;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  padding: 6px 8px;
  white-space: nowrap;
}

.oms-operations-overall[data-status="ok"],
.oms-operations-card[data-status="ok"] .oms-operations-card-head span {
  border-color: #96c7ac;
  background: #e9f6ee;
  color: #17643a;
}

.oms-operations-overall[data-status="warning"],
.oms-operations-card[data-status="warning"] .oms-operations-card-head span {
  border-color: #d7ba72;
  background: #fff7df;
  color: #70520b;
}

.oms-operations-overall[data-status="critical"],
.oms-operations-card[data-status="critical"] .oms-operations-card-head span {
  border-color: #dc9a9a;
  background: #fff0f0;
  color: #922d2d;
}

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

.oms-operations-card {
  min-width: 0;
  min-height: 166px;
  border: 1px solid #dce3ea;
  border-left: 3px solid #a8b1ba;
  border-radius: 6px;
  background: #fff;
  padding: 14px;
}

.oms-operations-card[data-status="ok"] { border-left-color: #399564; }
.oms-operations-card[data-status="warning"] { border-left-color: #b88a20; }
.oms-operations-card[data-status="critical"] { border-left-color: #c94b4b; }

.oms-operations-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.oms-operations-card h3 {
  min-width: 0;
  margin: 1px 0 0;
  color: #1e2933;
  font-size: 14px;
  line-height: 1.3;
}

.oms-operations-card > p {
  min-height: 36px;
  margin: 10px 0 12px;
  color: #5d6874;
  font-size: 12px;
  line-height: 1.45;
}

.oms-operations-card dl {
  display: grid;
  gap: 6px;
  margin: 0;
}

.oms-operations-card dl > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(72px, auto);
  align-items: start;
  gap: 8px;
}

.oms-operations-card dt,
.oms-operations-card dd {
  min-width: 0;
  margin: 0;
  font-size: 11px;
  line-height: 1.35;
}

.oms-operations-card dt { color: #78828d; }
.oms-operations-card dd {
  color: #2f3b46;
  font-weight: 650;
  overflow-wrap: anywhere;
  text-align: right;
}

.oms-operations-review,
.oms-operations-loading,
.oms-operations-error {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  border: 1px solid #dce3ea;
  border-radius: 6px;
  background: #f7f9fa;
  color: #4d5965;
  padding: 12px 14px;
  font-size: 12px;
}

.oms-operations-error {
  align-items: flex-start;
  flex-direction: column;
  border-color: #dc9a9a;
  background: #fff4f4;
  color: #842f2f;
}

.oms-operations-review-list {
  display: grid;
  margin-top: 12px;
  border-top: 1px solid #dce3ea;
}

.oms-operations-review-row {
  display: grid;
  grid-template-columns: minmax(220px, 1.2fr) minmax(360px, 1fr) auto;
  gap: 18px;
  border-bottom: 1px solid #dce3ea;
  border-left: 3px solid #b88a20;
  padding: 12px 14px;
}

.oms-operations-review-row[data-status="critical"] { border-left-color: #c94b4b; }

.oms-operations-review-row > div {
  min-width: 0;
}

.oms-operations-review-row strong,
.oms-operations-review-row span {
  display: block;
  overflow-wrap: anywhere;
}

.oms-operations-review-row strong {
  color: #25313c;
  font-size: 12px;
}

.oms-operations-review-row span {
  margin-top: 4px;
  color: #66717d;
  font-size: 11px;
  line-height: 1.4;
}

.oms-operations-review-row dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 12px;
  margin: 0;
}

.oms-operations-review-row dl > div {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 6px;
}

.oms-operations-review-row dt,
.oms-operations-review-row dd {
  min-width: 0;
  margin: 0;
  font-size: 11px;
  overflow-wrap: anywhere;
}

.oms-operations-review-row dt { color: #7a8590; }
.oms-operations-review-row dd { color: #34404c; font-weight: 650; }

.oms-operations-reconcile {
  align-self: center;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  border: 1px solid #c8d1da;
  border-radius: 6px;
  background: #fff;
  color: #34404c;
  padding: 7px 10px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.oms-operations-reconcile:hover { background: #f1f4f6; }
.oms-operations-reconcile:disabled { cursor: wait; opacity: 0.55; }
.oms-operations-reconcile svg { width: 14px; height: 14px; }

@media (max-width: 1100px) {
  .oms-operations-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .oms-operations-grid { grid-template-columns: minmax(0, 1fr); }
  .oms-operations-review { align-items: flex-start; flex-direction: column; }
  .oms-operations-review-row { grid-template-columns: minmax(0, 1fr); }
  .oms-operations-reconcile { justify-self: start; }
}

@media (max-width: 1180px) {
  .oms-dashboard-grid {
    grid-template-columns: 1fr;
  }
}

.oms-orders-header {
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--oms-slate-200);
  background: white;
  padding: 10px 18px;
}

.oms-orders-title {
  margin: 0;
  color: var(--oms-slate-950);
  font-size: 18px;
  font-weight: 700;
}

.oms-orders-subtitle {
  margin: 2px 0 0;
  color: var(--oms-slate-500);
  font-size: 12px;
}

.oms-header-actions {
  display: flex;
  gap: 8px;
}

.oms-btn-ghost,
.oms-btn-light {
  height: 32px;
  border: 1px solid var(--oms-slate-200);
  border-radius: var(--oms-control-radius-sm);
  background: white;
  padding: 0 12px;
  color: var(--oms-slate-600);
  font-size: 13px;
  font-weight: 600;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.oms-btn-ghost:hover,
.oms-btn-light:hover {
  border-color: var(--oms-slate-300);
  background: var(--oms-slate-50);
  color: var(--oms-slate-900);
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
  transform: translateY(-1px);
}

.oms-btn-light.primary {
  border-color: var(--oms-blue-500);
  background: var(--oms-brand-primary-bg);
  color: var(--oms-brand-primary-fg);
  font-weight: 850;
}

.oms-btn-light.primary:hover {
  background: var(--oms-brand-primary-bg-hover);
}

.oms-btn-light.is-notcollected {
  border-color: #f59e0b;
  background: #fffbeb;
  color: #b45309;
  font-weight: 800;
}

.oms-btn-light.is-notcollected:hover:not(:disabled) {
  background: #fef3c7;
}

.oms-btn-light.success {
  border-color: #86efac;
  background: #16a34a;
  color: #ffffff;
  font-weight: 850;
}

.oms-btn-light.success:hover {
  background: #15803d;
}

/* Kosz zamowien - stonowany, bo to akcja odwracalna, nie kasowanie danych. */
.oms-btn-light.danger {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
}

.oms-btn-light.danger:hover {
  background: #fee2e2;
}

.oms-btn-light.warning {
  border-color: #fde68a;
  background: #fffbeb;
  color: #92400e;
}

.oms-btn-light.warning:hover {
  background: #fef3c7;
}

.oms-inline-action {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: var(--oms-control-radius-sm);
  background: #ffffff;
  padding: 0 10px;
  color: var(--oms-blue-700);
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 900;
}

.oms-inline-action:hover {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-inline-action.correction {
  border-color: #fcd34d;
  background: #fffbeb;
  color: #92400e;
}

.oms-inline-action.correction:hover {
  border-color: #f59e0b;
  background: #fef3c7;
}

.oms-inline-action:disabled {
  cursor: not-allowed;
  opacity: 0.68;
}

.oms-btn-ghost:disabled,
.oms-btn-light:disabled {
  cursor: not-allowed;
  opacity: 0.7;
}

.oms-btn-ghost svg {
  width: 14px;
  height: 14px;
}

.oms-mirror-panel {
  border-bottom: 1px solid var(--oms-slate-200);
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  padding: 12px 16px;
}

.oms-mirror-main {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 10px;
}

.oms-mirror-kicker {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.oms-mirror-title {
  margin-top: 2px;
  color: var(--oms-slate-900);
  font-size: 13px;
  font-weight: 700;
}

.oms-mirror-status {
  display: inline-flex;
  min-width: 76px;
  height: 28px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
}

.oms-mirror-status.ok,
.oms-mirror-channel.ok .oms-mirror-channel-top span {
  background: var(--oms-green-50);
  color: var(--oms-green-600);
}

.oms-mirror-status.watch,
.oms-mirror-channel.watch .oms-mirror-channel-top span,
.oms-mirror-status.empty,
.oms-mirror-channel.empty .oms-mirror-channel-top span,
.oms-mirror-status.loading {
  background: #fff7ed;
  color: #c2410c;
}

.oms-mirror-status.stale,
.oms-mirror-channel.stale .oms-mirror-channel-top span,
.oms-mirror-status.error,
.oms-mirror-channel.error .oms-mirror-channel-top span {
  background: #fef2f2;
  color: #dc2626;
}

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

.oms-mirror-channel {
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 9px 10px;
}

.oms-mirror-channel-top,
.oms-mirror-channel-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.oms-mirror-channel-top strong {
  color: var(--oms-slate-950);
  font-size: 13px;
}

.oms-mirror-channel-top span {
  border-radius: 999px;
  padding: 3px 7px;
  font-size: 10.5px;
  font-weight: 800;
}

.oms-mirror-channel-name,
.oms-mirror-channel-meta,
.oms-mirror-channel-freshness,
.oms-mirror-footer,
.oms-mirror-empty {
  color: var(--oms-slate-500);
  font-size: 12px;
}

.oms-mirror-channel-name {
  margin-top: 5px;
  color: var(--oms-slate-700);
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.oms-mirror-channel-meta {
  margin-top: 8px;
}

.oms-mirror-channel-freshness {
  margin-top: 5px;
}

.oms-mirror-footer {
  margin-top: 9px;
}

.oms-mirror-empty {
  grid-column: 1 / -1;
}

.oms-toolbar {
  display: flex;
  align-items: center;
  gap: 6px;
  border-bottom: 1px solid var(--oms-slate-200);
  background: white;
  padding: 7px 16px;
  flex-wrap: wrap;
}

.oms-tool-group {
  display: flex;
  align-items: center;
  gap: 2px;
  margin-right: 8px;
  border-right: 1px solid var(--oms-slate-200);
  padding-right: 8px;
}

/* Kosz i archiwum na samym dole, odciete linia od kolejek roboczych. */
.oms-filter-archive-group {
  margin-top: 10px;
  border-top: 1px solid var(--oms-slate-200);
  padding-top: 8px;
}

/* Kosz i archiwum w lewej liscie: to widoki pomocnicze, nie kolejki robocze -
   stonowane, zeby nie konkurowaly wzrokowo z "Do spakowania". */
.oms-filter-item-muted {
  color: var(--oms-slate-500);
}

.oms-filter-item-muted svg {
  opacity: .75;
}

.oms-filter-item-muted.active {
  color: inherit;
}

.oms-filter-item-muted.active svg {
  opacity: 1;
}

/* Akcja niszczaca dostaje wlasny margines, zeby nie sasiadowala z nadawaniem
   przesylki na 2 px - pomylkowe klikniecie kosztowaloby operatora zamowienie. */
.oms-tool-group-destructive {
  margin-left: 10px;
  border-right: 0;
  padding-right: 0;
}

.oms-tool-btn.danger {
  color: #b42318;
}

.oms-tool-btn.danger:hover:not(:disabled) {
  border-color: #fecaca;
  background: #fef2f2;
  color: #991b1b;
}

.oms-tool-btn.paid:not(:disabled) {
  color: #067647;
}

.oms-tool-btn.paid:hover:not(:disabled) {
  border-color: #abefc6;
  background: #ecfdf3;
  color: #05603a;
}

.oms-bulk-status-control,
.oms-bulk-shipment-control {
  position: relative;
  display: inline-flex;
}

.oms-bulk-status-dropdown,
.oms-bulk-shipment-dropdown {
  position: absolute;
  z-index: 80;
  top: calc(100% + 8px);
  left: 0;
  width: min(340px, 82vw);
  max-height: 470px;
  overflow: auto;
  border: 1px solid #cbd5e1;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 22px 56px rgba(15, 23, 42, 0.18);
  padding: 8px;
}

.oms-bulk-status-dropdown[hidden],
.oms-bulk-shipment-dropdown[hidden] {
  display: none;
}

.oms-bulk-status-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 3px 4px 9px;
}

.oms-bulk-status-head strong {
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 900;
}

.oms-bulk-status-head span {
  border-radius: 999px;
  background: var(--oms-slate-100);
  padding: 3px 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 850;
}

.oms-bulk-status-list {
  padding-top: 4px;
}

.oms-bulk-status-error {
  margin-top: 8px;
  border-radius: 10px;
  background: #fef2f2;
  padding: 8px 9px;
  color: #991b1b;
  font-size: 12px;
  font-weight: 800;
}

.oms-bulk-shipment-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin-bottom: 8px;
}

.oms-bulk-shipment-summary > div,
.oms-bulk-shipment-providers,
.oms-bulk-shipment-progress,
.oms-bulk-shipment-result {
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: var(--oms-slate-50);
  padding: 8px 9px;
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 800;
}

.oms-bulk-shipment-summary strong {
  color: var(--oms-slate-950);
}

.oms-bulk-shipment-providers {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 8px;
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1d4ed8;
}

.oms-bulk-shipment-progress {
  margin-bottom: 8px;
  background: #fefce8;
  border-color: #fde68a;
  color: #92400e;
}

.oms-bulk-shipment-result {
  margin-bottom: 8px;
}

.oms-bulk-shipment-result.success {
  background: #ecfdf5;
  border-color: #bbf7d0;
  color: #166534;
}

.oms-bulk-shipment-result.warning {
  background: #fff7ed;
  border-color: #fed7aa;
  color: #9a3412;
}

.oms-bulk-shipment-result small {
  display: block;
  margin-top: 4px;
  font-weight: 700;
}

/* "Wyslij razem" - propozycja jednej paczki za kilka zamowien tego samego
   klienta. Wyrozniona na zielono, bo to akcja oszczedzajaca etykiete, a nie
   kolejny wariant zwyklego nadania. */
.oms-bulk-shipment-group {
  margin-bottom: 8px;
  border: 1px solid #bbf7d0;
  border-radius: 10px;
  background: #ecfdf5;
  padding: 9px;
}

.oms-bulk-shipment-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: #166534;
  font-size: 12.5px;
  font-weight: 900;
}

.oms-bulk-shipment-group-sum {
  margin-top: 6px;
  color: #166534;
  font-size: 12px;
  font-weight: 800;
}

.oms-bulk-shipment-group-hint {
  margin: 5px 0 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.35;
}

.oms-bulk-shipment-group .oms-bulk-shipment-primary {
  background: #16a34a;
}

.oms-bulk-shipment-primary {
  width: 100%;
  min-height: 34px;
  border-radius: 10px;
  background: var(--oms-blue-600);
  color: white;
  font-size: 12.5px;
  font-weight: 900;
}

.oms-bulk-shipment-primary:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.oms-bulk-shipment-blocked {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
  max-height: 160px;
  overflow: auto;
}

.oms-bulk-shipment-row {
  display: grid;
  grid-template-columns: minmax(80px, auto) minmax(0, 1fr);
  gap: 8px;
  border-radius: 9px;
  background: var(--oms-slate-50);
  padding: 7px 8px;
  color: var(--oms-slate-600);
  font-size: 11.5px;
  font-weight: 750;
}

.oms-bulk-shipment-row.blocked {
  background: #f8fafc;
  color: #64748b;
}

.oms-tool-btn {
  width: 28px;
  height: 28px;
  border-radius: var(--oms-control-radius-sm);
  background: transparent;
  color: var(--oms-slate-500);
  transition: background 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.oms-tool-btn:hover {
  background: var(--oms-slate-100);
  color: var(--oms-slate-950);
}

.oms-tool-btn.active {
  background: var(--oms-brand-primary-bg);
  color: var(--oms-brand-primary-fg);
  box-shadow: 0 1px 2px rgba(37, 99, 235, 0.18);
}

.oms-selection-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-right: 10px;
}

.oms-selected-chip {
  display: inline-flex;
  height: 28px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 999px;
  background: var(--oms-slate-50);
  padding: 0 10px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 800;
}

.oms-btn-pack {
  display: inline-flex;
  height: 30px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border-radius: var(--oms-control-radius-sm);
  background: var(--oms-brand-primary-bg);
  padding: 0 12px;
  color: var(--oms-brand-primary-fg);
  font-size: 12.5px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(37, 99, 235, 0.18);
  transition: background 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.oms-btn-pack:hover:not(:disabled) {
  background: var(--oms-brand-primary-bg-hover);
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.18);
  transform: translateY(-1px);
}

.oms-btn-pack svg {
  width: 15px;
  height: 15px;
}

.oms-btn-pack:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.oms-tool-btn:disabled {
  cursor: not-allowed;
}

.oms-tool-btn svg {
  width: 16px;
  height: 16px;
}

.oms-pagination-info {
  margin-left: auto;
  color: var(--oms-slate-500);
  font-size: 13px;
}

.oms-pagination-info strong {
  color: var(--oms-slate-950);
}

.oms-pagination-arrows {
  display: flex;
  gap: 4px;
  margin-left: 12px;
}

.oms-page-btn {
  width: 28px;
  height: 28px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 6px;
  background: white;
  color: var(--oms-slate-500);
}

.oms-page-btn:hover:not(:disabled) {
  background: var(--oms-slate-50);
}

.oms-page-btn:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.oms-table-container {
  min-height: 0;
  flex: 1;
  overflow: auto;
  background: white;
}

.oms-table {
  width: 100%;
  min-width: 1360px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
}

.oms-table-resizable {
  min-width: var(--oms-order-table-min-width, 1264px);
  table-layout: fixed;
}

.oms-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  border-bottom: 1px solid #d8dee8;
  background: var(--oms-slate-50);
  padding: 11px 10px;
  color: var(--oms-slate-500);
  text-align: left;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.oms-table-resizable th[data-order-column] {
  box-sizing: border-box;
  overflow: visible;
}

.oms-table-resizable th[data-order-column]:has(.oms-column-resize-handle) {
  padding-right: 18px;
}

.oms-column-resize-handle {
  position: absolute;
  top: 0;
  right: -4px;
  bottom: 0;
  z-index: 5;
  width: 9px;
  cursor: col-resize;
  touch-action: none;
}

.oms-column-resize-handle::after {
  content: "";
  position: absolute;
  top: 9px;
  right: 4px;
  bottom: 9px;
  width: 2px;
  border-radius: 99px;
  background: transparent;
}

.oms-column-resize-handle:hover::after,
.oms-column-resize-handle.active::after {
  background: var(--oms-blue-500);
}

.oms-column-resizing,
.oms-column-resizing * {
  cursor: col-resize !important;
  user-select: none !important;
}

.oms-table td {
  border-bottom: 1px solid #e8edf4;
  background: white;
  padding: 11px 10px;
  vertical-align: top;
}

.oms-table-resizable td {
  box-sizing: border-box;
  overflow-wrap: anywhere;
}

.oms-table tr:hover td {
  background: var(--oms-slate-50);
}

.oms-table tbody tr.oms-row-selectable {
  cursor: pointer;
}

.oms-table tbody tr.oms-row-locked {
  cursor: default;
}

.oms-table tbody tr.oms-row-action-limited {
  cursor: pointer;
}

.oms-table tbody tr.oms-row-channel-allegro td:first-child,
.oms-table tbody tr.oms-row-store-allegro td:first-child {
  box-shadow: inset 4px 0 0 var(--oms-yellow-500);
}

.oms-table tbody tr.oms-row-store-bokserkoland td:first-child {
  box-shadow: inset 4px 0 0 var(--oms-cyan-500);
}

.oms-table tbody tr.oms-row-store-heelito td:first-child {
  box-shadow: inset 4px 0 0 var(--oms-slate-900);
}

.oms-table tbody tr.oms-row-store-cz td:first-child {
  box-shadow: inset 4px 0 0 var(--oms-pink-500);
}

.oms-table tbody tr.oms-row-store-sk td:first-child {
  box-shadow: inset 4px 0 0 var(--oms-blue-500);
}

.oms-table tbody tr.oms-row-store-hu td:first-child {
  box-shadow: inset 4px 0 0 var(--oms-green-500);
}

.oms-table tbody tr.oms-row-store-lt td:first-child {
  box-shadow: inset 4px 0 0 var(--oms-orange-500);
}

.oms-table tbody tr.oms-row-store-ro td:first-child {
  box-shadow: inset 4px 0 0 #0ea5e9;
}

.oms-table tbody tr.oms-row-unpaid td {
  background: #fff7f7;
}

.oms-table tbody tr.oms-row-unpaid:hover td {
  background: #fee2e2;
}

.oms-table tbody tr.oms-row-unpaid.selected td {
  background: #fecaca;
}

.oms-table tbody tr.oms-row-packed-recheck td {
  background: #fff7ed;
}

.oms-table tbody tr.oms-row-packed-recheck:hover td,
.oms-table tbody tr.oms-row-packed-recheck.selected td {
  background: #ffedd5;
}

.oms-table tbody tr.oms-row-pack-match td {
  background: #f0fdfa;
}

.oms-table tbody tr.oms-row-pack-match:hover td,
.oms-table tbody tr.oms-row-pack-match.selected td {
  background: #ccfbf1;
}

.oms-table tr.selected td {
  background: var(--oms-blue-50);
}

.oms-table tr.selected:hover td {
  background: #dbeafe;
}

.oms-checkbox {
  display: inline-flex;
  width: 16px;
  height: 16px;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--oms-slate-300);
  border-radius: 4px;
  background: white;
  color: white;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
}

.oms-checkbox.checked {
  border-color: var(--oms-blue-600);
  background: var(--oms-blue-600);
}

.oms-checkbox:disabled {
  cursor: not-allowed;
  opacity: 0.25;
}

.oms-checkbox-head {
  margin: 0;
}

.oms-star {
  border: 0;
  background: transparent;
  color: var(--oms-slate-300);
  font-size: 17px;
  line-height: 1;
}

.oms-star-list-button {
  display: inline-flex;
  width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.oms-star-list-button:hover {
  background: #fef3c7;
  color: #d97706;
  transform: scale(1.04);
}

.oms-star.active {
  color: #f59e0b;
}

.oms-order-number {
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--oms-blue-600);
  font-weight: 800;
  cursor: pointer;
}

.oms-order-number:hover {
  text-decoration: underline;
}

.oms-order-sub {
  margin-top: 2px;
  color: var(--oms-slate-400);
  font-size: 12px;
}

.oms-customer {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.oms-customer-name {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--oms-slate-950);
  font-weight: 650;
}

.oms-flag {
  font-size: 14px;
}

.oms-source {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
}

.oms-source-badge,
.oms-operation-chip {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  border-radius: 5px;
  padding: 2px 7px;
  font-size: 11px;
  font-weight: 900;
  line-height: 1.3;
  white-space: nowrap;
}

.oms-source-badge {
  border: 1px solid rgba(148, 163, 184, 0.22);
}

.oms-row-signal-badges {
  display: flex;
  max-width: 100%;
  flex-wrap: wrap;
  gap: 4px;
}

.oms-operation-chip {
  border: 0;
  text-transform: none;
}

.oms-operation-chip.muted {
  opacity: 0.72;
}

.oms-source-badge.tone-bokserkoland {
  background: var(--oms-store-bokserkoland-bg);
  color: var(--oms-store-bokserkoland-fg);
}

.oms-source-badge.tone-heelito,
.oms-operation-chip.tone-heelito {
  background: var(--oms-store-heelito-bg);
  color: var(--oms-store-heelito-fg);
}

.oms-source-badge.tone-hu,
.oms-operation-chip.tone-hu {
  background: var(--oms-store-hu-bg);
  color: var(--oms-store-hu-fg);
}

.oms-operation-chip.tone-packeta {
  background: var(--oms-carrier-packeta-bg);
  color: var(--oms-carrier-packeta-fg);
}

.oms-source-badge.tone-allegro,
.oms-operation-chip.tone-allegro {
  background: var(--oms-store-allegro-bg);
  color: var(--oms-store-allegro-fg);
}

.oms-operation-chip.tone-allegro-yellow {
  background: var(--oms-store-allegro-bg);
  color: var(--oms-store-allegro-fg);
}

.oms-operation-chip.tone-dpd {
  background: var(--oms-carrier-dpd-bg);
  color: var(--oms-carrier-dpd-fg);
}

.oms-operation-chip.tone-dhl {
  background: var(--oms-carrier-dhl-bg);
  color: var(--oms-carrier-dhl-fg);
}

.oms-operation-chip.tone-inpost {
  background: var(--oms-carrier-inpost-bg);
  color: var(--oms-carrier-inpost-fg);
}

.oms-operation-chip.tone-cod {
  background: var(--oms-signal-cod-bg);
  color: var(--oms-signal-cod-fg);
}

.oms-operation-chip.tone-other {
  background: var(--oms-orange-500);
  color: #ffffff;
}

.oms-operation-chip.tone-unpaid {
  background: var(--oms-signal-unpaid-bg);
  color: var(--oms-signal-unpaid-fg);
}

.oms-operation-chip.tone-paid {
  background: var(--oms-signal-paid-bg);
  color: var(--oms-signal-paid-fg);
}

.oms-source-badge.tone-cz,
.oms-operation-chip.tone-cz {
  background: var(--oms-store-cz-bg);
  color: var(--oms-store-cz-fg);
}

.oms-operation-chip.tone-olza {
  background: #fae8ff;
  color: #a21caf;
}

.oms-source-badge.tone-sk,
.oms-operation-chip.tone-sk {
  background: var(--oms-store-sk-bg);
  color: var(--oms-store-sk-fg);
}

.oms-source-badge.tone-lt,
.oms-operation-chip.tone-lt {
  background: var(--oms-store-lt-bg);
  color: var(--oms-store-lt-fg);
}

.oms-source-badge.tone-ro,
.oms-operation-chip.tone-ro {
  background: var(--oms-store-ro-bg);
  color: var(--oms-store-ro-fg);
}

.oms-operation-chip.tone-orlen {
  background: var(--oms-carrier-orlen-bg);
  color: var(--oms-carrier-orlen-fg);
}

.oms-operation-chip.tone-poczta {
  background: var(--oms-carrier-poczta-bg);
  color: var(--oms-carrier-poczta-fg);
}

.oms-source-badge.tone-default,
.oms-operation-chip.tone-default {
  background: var(--oms-chip-default-bg);
  color: var(--oms-chip-default-fg);
}

.oms-products {
  display: flex;
  max-width: 520px;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.oms-table-resizable .oms-products {
  max-width: 100%;
}

.oms-product-thumbs {
  display: flex;
  gap: 5px;
  flex: 0 0 auto;
  flex-wrap: wrap;
}

.oms-thumb {
  position: relative;
  display: inline-flex;
  width: 50px;
  height: 50px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid var(--oms-slate-200);
  border-radius: 6px;
  background: var(--oms-slate-100);
  font-size: 18px;
}

.oms-thumb img,
.oms-prod-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.oms-thumb:has(img),
.oms-prod-thumb:has(img),
.oms-batch-product-thumb:has(img) {
  cursor: zoom-in;
}

.oms-thumb-hover-preview {
  position: fixed;
  z-index: 6000;
  width: min(320px, calc(100vw - 24px));
  border: 1px solid rgba(71, 85, 105, 0.42);
  border-radius: 13px;
  background: rgba(15, 23, 42, 0.94);
  box-shadow: 0 22px 58px rgba(15, 23, 42, 0.34), 0 3px 10px rgba(15, 23, 42, 0.18);
  opacity: 0;
  padding: 10px;
  pointer-events: none;
  transform: translateY(4px) scale(0.985);
  transform-origin: bottom center;
  transition: opacity 120ms ease, transform 120ms ease;
}

.oms-thumb-hover-preview::after {
  content: "";
  position: absolute;
  right: calc(50% - 9px);
  bottom: -9px;
  width: 18px;
  height: 18px;
  border-right: 1px solid rgba(71, 85, 105, 0.42);
  border-bottom: 1px solid rgba(71, 85, 105, 0.42);
  background: rgba(15, 23, 42, 0.94);
  transform: rotate(45deg);
}

.oms-thumb-hover-preview.below {
  transform-origin: top center;
}

.oms-thumb-hover-preview.below::after {
  top: -9px;
  bottom: auto;
  border: 0;
  border-top: 1px solid rgba(71, 85, 105, 0.42);
  border-left: 1px solid rgba(71, 85, 105, 0.42);
}

.oms-thumb-hover-preview.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.oms-thumb-hover-preview img {
  display: block;
  width: 100%;
  height: 224px;
  border-radius: 8px;
  background: #fff;
  object-fit: contain;
}

.oms-thumb-count {
  position: absolute;
  right: -2px;
  bottom: -2px;
  border-radius: 4px;
  background: var(--oms-slate-950);
  padding: 1px 4px;
  color: white;
  font-size: 10px;
  font-weight: 800;
}

.oms-thumb.match {
  border-color: #14b8a6;
  box-shadow: 0 0 0 2px rgba(20, 184, 166, 0.16);
  background: #ecfeff;
}

.oms-product-text {
  min-width: 0;
  color: var(--oms-slate-600);
  font-size: 13px;
  line-height: 1.46;
}

.oms-product-line {
  display: flex;
  width: fit-content;
  max-width: 100%;
  align-items: center;
  gap: 6px;
  border-radius: 7px;
  padding: 1px 4px 1px 0;
}

.oms-product-line.match {
  background: #ccfbf1;
  color: #0f766e;
  padding-left: 5px;
}

.oms-product-line-filter {
  border: 1px solid #99f6e4;
  border-radius: 999px;
  background: #f0fdfa;
  color: #0f766e;
  cursor: pointer;
  font-size: 10.5px;
  font-weight: 800;
  line-height: 1;
  opacity: 0;
  padding: 4px 6px;
  transition: opacity 0.12s ease, background 0.12s ease, border-color 0.12s ease;
  white-space: nowrap;
}

.oms-product-line:hover .oms-product-line-filter,
.oms-product-line.match .oms-product-line-filter {
  opacity: 1;
}

.oms-product-line-filter:hover {
  border-color: #14b8a6;
  background: #ccfbf1;
}

.oms-product-line-more {
  display: inline-flex;
  align-items: center;
  margin-top: 2px;
  border: 1px solid var(--oms-slate-200, #e2e8f0);
  border-radius: 999px;
  background: var(--oms-slate-50, #f8fafc);
  color: var(--oms-slate-600, #475569);
  cursor: pointer;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  padding: 4px 8px;
  white-space: nowrap;
  transition: background 0.12s ease, border-color 0.12s ease, color 0.12s ease;
}

.oms-product-line-more:hover {
  border-color: #94a3b8;
  background: #eef2f7;
  color: var(--oms-slate-800, #1e293b);
}

.oms-thumb-more {
  border: 1px dashed var(--oms-slate-300, #cbd5e1);
  background: var(--oms-slate-50, #f8fafc);
  color: var(--oms-slate-600, #475569);
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
}

.oms-thumb-more:hover {
  border-color: #94a3b8;
  background: #eef2f7;
  color: var(--oms-slate-900, #0f172a);
}

.oms-app[data-theme="dark"] .oms-product-line-more,
.oms-app[data-theme="dark"] .oms-thumb-more {
  border-color: rgba(148, 163, 184, 0.35);
  background: rgba(148, 163, 184, 0.12);
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-product-line-more:hover,
.oms-app[data-theme="dark"] .oms-thumb-more:hover {
  border-color: rgba(148, 163, 184, 0.6);
  background: rgba(148, 163, 184, 0.22);
  color: #f1f5f9;
}

.oms-product-text strong {
  color: var(--oms-slate-700);
}

.oms-amount {
  color: var(--oms-slate-950);
  font-weight: 800;
  text-align: right;
  white-space: nowrap;
}

.oms-shipping {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
}

.oms-row-info-icons {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  gap: 5px;
}

.oms-ship-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 6px;
  padding: 3px 7px;
  color: white;
  font-size: 11px;
  font-weight: 800;
}

.oms-ship-pill.pink { background: var(--oms-store-cz-bg); }
.oms-ship-pill.orange { background: var(--oms-store-lt-bg); }
.oms-ship-pill.blue { background: var(--oms-store-ro-bg); }
.oms-ship-pill.green { background: var(--oms-green-600); }
.oms-ship-pill.gray { background: var(--oms-slate-500); }

.oms-ship-method {
  color: var(--oms-blue-700);
  font-size: 12.5px;
  font-weight: 650;
  line-height: 1.25;
}

.oms-base-parity-list-hint {
  display: none;
}

.oms-icon-strip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.oms-list-status-badge {
  display: inline-flex;
  min-width: 24px;
  height: 20px;
  align-items: center;
  justify-content: center;
  border-radius: 5px;
  color: white;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0.01em;
}

.oms-list-status-badge.pink { background: var(--oms-pink-500); }
.oms-list-status-badge.orange { background: var(--oms-orange-500); }
.oms-list-status-badge.blue { background: #0ea5e9; }
.oms-list-status-badge.teal { background: #0f766e; }
.oms-list-status-badge.purple { background: #5b21b6; }
.oms-list-status-badge.amber { background: #d97706; }
.oms-list-status-badge.green { background: var(--oms-green-600); }
.oms-list-status-badge.fuchsia { background: #c026d3; }
.oms-list-status-badge.rose { background: #e11d48; }
.oms-list-status-badge.red { background: #dc2626; }
.oms-list-status-badge.gray { background: var(--oms-slate-500); }

.oms-order-status-chip {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  border-radius: 5px;
  padding: 3px 7px;
  color: #ffffff;
  font-size: 11px;
  font-weight: 950;
  line-height: 1.18;
  white-space: nowrap;
}

.oms-order-status-chip.tone-ready { background: var(--oms-status-ready-bg); color: var(--oms-status-ready-fg); }

.oms-order-status-chip.tone-hold {
  background: var(--oms-store-cz-bg);
}

.oms-order-status-chip.tone-packing { background: var(--oms-status-packing-bg); color: var(--oms-status-packing-fg); }

.oms-order-status-chip.tone-sent { background: var(--oms-status-sent-bg); color: var(--oms-status-sent-fg); }

.oms-order-status-chip.tone-completed { background: var(--oms-status-completed-bg); color: var(--oms-status-completed-fg); }

.oms-order-status-chip.tone-returns {
  background: var(--oms-status-return-bg);
  color: var(--oms-status-return-fg);
}

.oms-order-status-chip.tone-cancelled {
  background: var(--oms-status-cancelled-bg);
  color: var(--oms-status-cancelled-fg);
}

.oms-order-status-chip.tone-inpost { background: var(--oms-carrier-inpost-bg); color: var(--oms-carrier-inpost-fg); }
.oms-order-status-chip.tone-allegro-yellow { background: var(--oms-store-allegro-bg); color: var(--oms-store-allegro-fg); }
.oms-order-status-chip.tone-dpd { background: var(--oms-carrier-dpd-bg); color: var(--oms-carrier-dpd-fg); }
.oms-order-status-chip.tone-dhl { background: var(--oms-carrier-dhl-bg); color: var(--oms-carrier-dhl-fg); }
.oms-order-status-chip.tone-other { background: var(--oms-orange-500); color: #ffffff; }
.oms-order-status-chip.tone-unpaid { background: var(--oms-signal-unpaid-bg); color: var(--oms-signal-unpaid-fg); }
.oms-order-status-chip.tone-waiting-transfer { background: #a855f7; color: #ffffff; }
.oms-order-status-chip.tone-paid { background: var(--oms-signal-paid-bg); color: var(--oms-signal-paid-fg); }
.oms-order-status-chip.tone-heelito { background: var(--oms-store-heelito-bg); color: var(--oms-store-heelito-fg); }
.oms-order-status-chip.tone-hu { background: var(--oms-store-hu-bg); color: var(--oms-store-hu-fg); }
.oms-order-status-chip.tone-packeta { background: var(--oms-carrier-packeta-bg); color: var(--oms-carrier-packeta-fg); }
.oms-order-status-chip.tone-cz { background: var(--oms-store-cz-bg); color: var(--oms-store-cz-fg); }
.oms-order-status-chip.tone-olza { background: #fae8ff; color: #a21caf; }
.oms-order-status-chip.tone-sk { background: var(--oms-store-sk-bg); color: var(--oms-store-sk-fg); }
.oms-order-status-chip.tone-lt { background: var(--oms-store-lt-bg); color: var(--oms-store-lt-fg); }
.oms-order-status-chip.tone-ro { background: var(--oms-store-ro-bg); color: var(--oms-store-ro-fg); }
.oms-order-status-chip.tone-orlen { background: var(--oms-carrier-orlen-bg); color: var(--oms-carrier-orlen-fg); }
.oms-order-status-chip.tone-poczta { background: var(--oms-carrier-poczta-bg); color: var(--oms-carrier-poczta-fg); }
.oms-order-status-chip.tone-default { background: #94a3b8; color: #ffffff; }

.oms-row-small-warning {
  color: #9a3412;
  font-size: 11px;
  font-weight: 800;
}

.oms-mini-icon {
  display: inline-flex;
  width: 20px;
  height: 20px;
  align-items: center;
  justify-content: center;
  border-radius: 5px;
  color: white;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  vertical-align: middle;
}

.oms-mini-icon.paid { background: var(--oms-green-500); }
.oms-mini-icon.money { background: var(--oms-yellow-500); }
.oms-mini-icon.ship { background: #38a9e8; }
.oms-mini-icon.doc { background: var(--oms-blue-500); }
.oms-mini-icon.cancelled { background: #ef4444; }
/* Ta sama osoba ma wiecej niz jedno otwarte zamowienie - fiolet, zeby nie mylil
   sie z platnoscia ani z przesylka. */
.oms-mini-icon.duplicate-customer { background: #8b5cf6; }
.oms-mini-icon.missing {
  position: relative;
  background: linear-gradient(135deg, #cbd5e1 0 44%, rgba(71, 85, 105, 0.85) 45% 54%, #cbd5e1 55% 100%);
  color: #64748b;
}

.oms-mini-icon svg {
  width: 14px;
  height: 14px;
  stroke-width: 2.2;
}

.oms-has-tooltip {
  position: relative;
  cursor: help;
}

.oms-has-tooltip::before,
.oms-has-tooltip::after {
  position: absolute;
  left: 50%;
  z-index: 30;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease, transform 0.12s ease;
}

.oms-has-tooltip::after {
  content: attr(data-tooltip);
  bottom: calc(100% + 9px);
  min-width: 150px;
  max-width: 260px;
  transform: translate(-50%, 3px);
  border-radius: 4px;
  background: #374151;
  color: white;
  padding: 7px 9px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.22);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.35;
  text-align: center;
  white-space: pre-line;
}

.oms-has-tooltip::before {
  content: "";
  bottom: calc(100% + 3px);
  transform: translate(-50%, 3px);
  border: 6px solid transparent;
  border-top-color: #374151;
}

.oms-has-tooltip:hover::before,
.oms-has-tooltip:hover::after,
.oms-has-tooltip:focus-visible::before,
.oms-has-tooltip:focus-visible::after {
  opacity: 1;
  transform: translate(-50%, 0);
}

.oms-date-col {
  text-align: right;
  white-space: nowrap;
}

.oms-date-main {
  color: var(--oms-slate-950);
  font-size: 12px;
}

.oms-date-sub {
  color: var(--oms-blue-600);
  font-size: 12px;
}

.oms-empty-state,
.oms-error-state {
  padding: 48px 24px;
  color: var(--oms-slate-500);
  text-align: center;
}

.oms-error-state {
  color: var(--oms-red-500);
}

.oms-detail-view {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  overflow-y: auto;
  background: #f5f7fa;
  padding: 20px;
}

.oms-detail-view[hidden] {
  display: none;
}

.oms-detail-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.oms-btn-back {
  display: inline-flex;
  flex: 0 0 auto;
  height: 36px;
  min-width: 188px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--oms-blue-500);
  border-radius: 999px;
  background: white;
  padding: 0 16px;
  color: var(--oms-blue-600);
  font-size: 13.5px;
  font-weight: 700;
}

.oms-btn-back:hover {
  background: var(--oms-blue-50);
}

.oms-btn-back-label {
  white-space: nowrap;
}

.oms-detail-title {
  display: flex;
  flex: 1 1 auto;
  min-width: 0;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: var(--oms-slate-950);
  font-size: 22px;
  font-weight: 800;
}

.oms-detail-name {
  overflow: hidden;
  color: var(--oms-slate-600);
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-star-button {
  background: transparent;
  color: var(--oms-slate-300);
  cursor: pointer;
  font-size: 21px;
  line-height: 1;
}

.oms-star-button.active {
  color: #f59e0b;
}

.oms-card {
  overflow: hidden;
  margin-bottom: 16px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
  background: white;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.oms-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--oms-slate-100);
  padding: 14px 18px;
  font-size: 15px;
  font-weight: 800;
}

.oms-card-header-note {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 850;
}

.oms-order-info-header {
  flex-wrap: wrap;
}

.oms-order-info-header > span:first-child {
  min-width: 0;
  flex: 1 1 auto;
}

.oms-order-info-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.oms-order-operator-panel {
  height: 100%;
}

.oms-order-operator-panel-body {
  display: grid;
  gap: 14px;
  padding: 16px;
}

.oms-order-operator-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.oms-order-operator-buttons .oms-btn-light,
.oms-order-operator-buttons .oms-inline-action {
  min-height: 34px;
}

/* Kosz na prawej krawedzi, z dala od Pakuj. */
.oms-order-operator-buttons-end {
  display: inline-flex;
  margin-left: auto;
}

.oms-order-operator-buttons-end:empty {
  display: none;
}

/* Faktury na karcie zamowienia (25.09.2026): wiersz na dokument. */
.oms-card-invoices {
  display: grid;
  gap: 6px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
  background: var(--oms-slate-50);
  padding: 10px;
}

.oms-card-invoices-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 26px;
}

.oms-card-invoices-head > span {
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 850;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.oms-card-invoices-add {
  border: 0;
  background: none;
  padding: 2px 4px;
  color: var(--oms-blue-700);
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 850;
}

.oms-card-invoices-add:hover:not(:disabled) {
  text-decoration: underline;
}

.oms-card-invoice-row,
.oms-card-invoice-empty {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: #ffffff;
  padding: 8px 10px;
}

.oms-card-invoice-row.correction {
  border-color: #fcd34d;
  background: #fffbeb;
}

.oms-card-invoice-empty > span {
  color: var(--oms-slate-500);
  font-size: 13px;
  font-weight: 700;
}

.oms-card-invoice-main {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.oms-card-invoice-number {
  justify-self: start;
  border: 0;
  background: none;
  padding: 0;
  color: var(--oms-blue-700);
  cursor: pointer;
  font-size: 14px;
  font-weight: 900;
  text-align: left;
}

.oms-card-invoice-row.correction .oms-card-invoice-number {
  color: #92400e;
}

.oms-card-invoice-number:hover:not(:disabled) {
  text-decoration: underline;
}

.oms-card-invoice-meta {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 650;
}

.oms-card-invoice-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.oms-card-invoice-actions button {
  min-height: 28px;
  border: 1px solid var(--oms-slate-200);
  border-radius: var(--oms-control-radius-sm);
  background: #ffffff;
  padding: 0 10px;
  color: var(--oms-slate-700);
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 750;
}

.oms-card-invoice-actions button:hover:not(:disabled) {
  border-color: var(--oms-slate-300);
  background: var(--oms-slate-50);
}

.oms-card-invoice-actions button.danger {
  border-color: #fecaca;
  color: #b91c1c;
}

.oms-card-invoice-actions button.danger:hover:not(:disabled) {
  background: #fef2f2;
}

.oms-card-invoice-actions button:disabled,
.oms-card-invoices-add:disabled,
.oms-card-invoice-number:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.oms-card-invoices-error {
  border-radius: 8px;
  background: #fef2f2;
  color: #b91c1c;
  padding: 7px 9px;
  font-size: 12.5px;
  font-weight: 750;
}

.oms-app[data-theme="dark"] .oms-card-invoices {
  border-color: rgba(148, 163, 184, 0.18);
  background: #0b1220;
}

.oms-app[data-theme="dark"] .oms-card-invoice-row,
.oms-app[data-theme="dark"] .oms-card-invoice-empty,
.oms-app[data-theme="dark"] .oms-card-invoice-actions button {
  border-color: rgba(148, 163, 184, 0.22);
  background: #111827;
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-card-invoice-row.correction {
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.08);
}

.oms-app[data-theme="dark"] .oms-card-invoice-number,
.oms-app[data-theme="dark"] .oms-card-invoices-add {
  color: #93c5fd;
}

.oms-app[data-theme="dark"] .oms-card-invoice-row.correction .oms-card-invoice-number {
  color: #fcd34d;
}

.oms-app[data-theme="dark"] .oms-card-invoice-actions button.danger {
  border-color: rgba(248, 113, 113, 0.4);
  color: #fca5a5;
}

.oms-app[data-theme="dark"] .oms-card-invoices-error {
  background: rgba(220, 38, 38, 0.14);
  color: #fca5a5;
}

/* Nadanie z karty zamowienia. Kafle metod sa te same, co w asystencie pakowania,
   a ich palette zaprojektowano na ciemne tlo modala - dlatego blok na karcie tez
   jest ciemny. Inaczej zolte kafle Paczkomatow znikaja na bialej karcie. */
.oms-card-ship {
  margin-top: 10px;
  border: 1px solid #334155;
  border-radius: 12px;
  background: #1f2430;
  padding: 8px 10px;
}

.oms-card-ship > summary {
  cursor: pointer;
  color: #e5e7eb;
  font-size: 13px;
  font-weight: 850;
  list-style: none;
}

.oms-card-ship > summary::-webkit-details-marker {
  display: none;
}

.oms-card-ship > summary::before {
  content: "▸ ";
  color: #9ca3af;
}

.oms-card-ship[open] > summary::before {
  content: "▾ ";
}

.oms-card-ship .oms-delivery-methods-header {
  margin-top: 8px;
}

.oms-card-ship .oms-delivery-methods {
  padding-bottom: 0;
  border-bottom: 0;
}

.oms-card-ship .oms-batch-delivery-status {
  margin: 10px 0 0;
}

.oms-card-ship-hint {
  margin-top: 8px;
  border-radius: 8px;
  background: rgba(251, 191, 36, 0.16);
  color: #fde68a;
  padding: 7px 9px;
  font-size: 12px;
  font-weight: 800;
}

.oms-order-operator-mini {
  display: grid;
  gap: 8px;
}

.oms-order-operator-mini > div {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  border-top: 1px solid var(--oms-slate-100);
  padding-top: 8px;
}

.oms-order-operator-mini > .oms-order-operator-status-row {
  grid-template-columns: 76px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
}

.oms-order-operator-status-row > span {
  display: flex;
  align-items: center;
}

.oms-order-operator-status-row .oms-status-select {
  width: min(100%, 205px);
  justify-self: start;
}

.oms-order-operator-mini span {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
}

.oms-order-operator-mini strong {
  min-width: 0;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 850;
  overflow-wrap: anywhere;
}

.oms-order-operator-mini em {
  grid-column: 2;
  margin-top: -4px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 750;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.oms-order-operator-mini-state.ready {
  color: #166534;
}

.oms-order-operator-mini-state.wait {
  color: #92400e;
}

.oms-order-operator-mini-state.blocked {
  color: #991b1b;
}

.oms-order-operator-mini .oms-btn-light.compact {
  grid-column: 2;
  justify-self: start;
  min-height: 28px;
  padding: 4px 9px;
}

.oms-status-select {
  position: relative;
  min-width: 0;
}

.oms-status-transfer-row {
  display: inline-grid;
  grid-template-columns: minmax(0, 1fr) auto 28px;
  width: 100%;
  max-width: min(100%, 500px);
  align-items: stretch;
  vertical-align: middle;
  border-radius: 9px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.oms-status-current {
  display: inline-flex;
  width: auto;
  min-height: 32px;
  min-width: 0;
  align-items: center;
  gap: 7px;
  border: 1px solid #cbd5e1;
  border-right: 0;
  border-radius: 9px 0 0 9px;
  background: #ffffff;
  padding: 5px 8px;
  color: var(--oms-slate-900);
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.oms-status-current:hover {
  border-color: #93c5fd;
  background: #f8fbff;
}

.oms-status-current strong {
  min-width: 0;
  overflow: hidden;
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 850;
  letter-spacing: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-status-dot {
  display: inline-block;
  flex: 0 0 auto;
  width: 9px;
  height: 9px;
  border-radius: 3px;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.14), 0 0 0 2px rgba(148, 163, 184, 0.12);
}

.oms-status-caret {
  flex: 0 0 auto;
  margin-left: auto;
  color: var(--oms-slate-400);
  font-size: 9px;
  font-weight: 900;
}

.oms-status-dropdown {
  position: absolute;
  z-index: 45;
  top: calc(100% + 4px);
  left: 0;
  width: min(390px, 84vw);
  max-height: 470px;
  overflow: auto;
  border: 1px solid #cbd5e1;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.16);
  padding: 8px;
}

.oms-status-search {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid #e2e8f0;
  background: #ffffff;
  padding: 0 0 8px;
}

.oms-status-search input {
  width: 100%;
  min-width: 0;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  background: #f8fafc;
  padding: 9px 34px 9px 9px;
  color: var(--oms-slate-950);
  font: inherit;
  font-size: 14px;
  font-weight: 850;
  outline: 0;
}

.oms-status-search input:focus {
  border-color: #2563eb;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

.oms-status-search span {
  position: absolute;
  right: 10px;
  color: var(--oms-slate-400);
  font-size: 21px;
  line-height: 1;
}

.oms-status-group + .oms-status-group {
  border-top: 1px solid #edf2f7;
}

.oms-status-group-title,
.oms-status-section-title {
  padding: 11px 6px 6px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.oms-status-option {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  padding: 9px 10px;
  color: var(--oms-slate-800);
  font: inherit;
  font-size: 14px;
  font-weight: 850;
  text-align: left;
  cursor: pointer;
}

.oms-status-option:hover,
.oms-status-option.active {
  background: #eff6ff;
  color: #1d4ed8;
}

.oms-status-option[hidden],
.oms-status-group[hidden] {
  display: none;
}

.oms-status-change-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
}

.oms-status-change-row.active {
  color: var(--oms-slate-700);
}

.oms-status-pending {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 6px;
}

.oms-status-pending strong {
  color: var(--oms-slate-950);
}

.oms-status-apply,
.oms-status-clear {
  min-height: 32px;
  border: 1px solid #2563eb;
  border-radius: 0;
  background: #2563eb;
  padding: 5px 8px;
  color: #ffffff;
  font: inherit;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.oms-status-apply {
  border-right: 0;
}

.oms-status-apply:hover:not(:disabled) {
  border-color: #1d4ed8;
  background: #1d4ed8;
  box-shadow: inset 0 -1px 0 rgba(15, 23, 42, 0.16);
}

.oms-status-clear:hover:not(:disabled) {
  border-color: #cbd5e1;
  background: #f8fafc;
}

.oms-status-split-toggle {
  min-height: 32px;
  border: 1px solid #cbd5e1;
  border-left: 0;
  border-radius: 0 9px 9px 0;
  background: #ffffff;
  color: var(--oms-slate-600);
  font: inherit;
  font-size: 12px;
  font-weight: 950;
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease, color 0.16s ease;
}

.oms-status-split-toggle:hover {
  border-color: #93c5fd;
  background: #f8fbff;
  color: #1d4ed8;
}

.oms-status-apply:disabled,
.oms-status-clear:disabled,
.oms-status-split-toggle:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.oms-status-hint {
  color: var(--oms-slate-400);
}

.oms-status-error {
  margin-top: 7px;
  color: #b91c1c;
  font-size: 12px;
  font-weight: 850;
}

.oms-order-operator-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px 18px;
  margin-bottom: 16px;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  background: #ffffff;
  padding: 16px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.oms-order-operator-main {
  min-width: 0;
}

.oms-order-operator-kicker {
  color: var(--oms-blue-700);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.oms-order-operator-title {
  margin-top: 4px;
  color: var(--oms-slate-950);
  font-size: 20px;
  font-weight: 950;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.oms-order-operator-sub {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 7px;
  color: var(--oms-slate-500);
  font-size: 12.5px;
  font-weight: 800;
}

.oms-order-operator-sub span {
  border-radius: 999px;
  background: var(--oms-slate-100);
  padding: 4px 8px;
}

.oms-order-operator-actions {
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  justify-content: flex-end;
  gap: 8px;
}

.oms-order-operator-stats {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.oms-order-operator-stat {
  display: grid;
  gap: 4px;
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #f8fafc;
  padding: 10px 12px;
}

.oms-order-operator-stat.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-order-operator-stat.wait {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-order-operator-stat.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-operator-stat span {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.oms-order-operator-stat strong {
  min-width: 0;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.oms-order-operator-stat em {
  min-width: 0;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-style: normal;
  font-weight: 750;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.oms-products-table {
  width: 100%;
  border-collapse: collapse;
}

.oms-products-table th {
  border-bottom: 1px solid var(--oms-slate-200);
  background: var(--oms-slate-50);
  padding: 12px 16px;
  color: var(--oms-slate-500);
  text-align: left;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.oms-products-table td {
  border-bottom: 1px solid var(--oms-slate-100);
  padding: 14px 16px;
  font-size: 13.5px;
  vertical-align: top;
}

.oms-prod-thumb {
  display: inline-flex;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-100);
  font-size: 22px;
}

.oms-prod-id {
  color: var(--oms-blue-600);
  font-weight: 700;
}

.oms-prod-subline {
  margin-top: 4px;
  font-size: 11px;
  line-height: 1.25;
}

.oms-prod-link {
  color: var(--oms-blue-600);
  font-weight: 750;
  text-decoration: none;
}

.oms-prod-link:hover {
  text-decoration: underline;
}

.oms-prod-sku {
  margin-top: 4px;
  color: var(--oms-blue-600);
  font-size: 12px;
  line-height: 1.3;
}

.oms-prod-size {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  padding: 3px 8px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
}

.oms-inline-cell,
.oms-inline-value,
.oms-inline-amount {
  max-width: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  color: inherit;
  font: inherit;
  font-weight: 800;
  text-align: left;
  overflow-wrap: anywhere;
  cursor: pointer;
}

.oms-inline-cell:hover,
.oms-inline-value:hover {
  color: var(--oms-blue-700);
  text-decoration: underline;
}

.oms-inline-amount {
  border-radius: 7px;
  padding: 5px 9px;
}

.oms-inline-amount.settled {
  background: #dcfce7;
  color: #166534;
}

.oms-inline-amount.underpaid {
  background: #fee2e2;
  color: #991b1b;
}

.oms-inline-amount.overpaid {
  background: #fef3c7;
  color: #92400e;
}

.oms-card-actions {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--oms-slate-100);
  background: #fcfcfd;
  padding: 12px 16px;
}

.oms-manual-product-panel {
  border-top: 1px solid var(--oms-slate-100);
  background: #f8fafc;
  padding: 14px 16px;
}

.oms-manual-product-panel[hidden] {
  display: none;
}

.oms-manual-product-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 90px 120px 90px 90px;
  gap: 10px;
}

.oms-manual-product-choice {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
}

.oms-manual-product-grid label,
.oms-addr-edit-field,
.oms-product-edit-panel label {
  display: grid;
  gap: 5px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.oms-manual-product-grid input,
.oms-addr-edit-field input,
.oms-payment-edit-form input,
.oms-inline-edit-input,
.oms-product-edit-panel input,
.oms-product-edit-panel select {
  min-height: 34px;
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 7px 9px;
  color: var(--oms-slate-950);
  font: inherit;
  font-size: 13px;
  font-weight: 750;
}

.oms-product-menu-wrap {
  position: relative;
  display: inline-flex;
}

.oms-product-menu-button {
  display: inline-flex;
  width: 30px;
  height: 30px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 9px;
  background: white;
  color: var(--oms-slate-500);
  font-weight: 950;
  cursor: pointer;
}

.oms-product-menu {
  position: absolute;
  z-index: 20;
  right: 0;
  top: calc(100% + 6px);
  display: grid;
  min-width: 150px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: white;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.14);
  padding: 6px;
}

.oms-product-menu button {
  border: 0;
  border-radius: 8px;
  background: transparent;
  padding: 9px 10px;
  color: var(--oms-slate-700);
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}

.oms-product-menu button:hover {
  background: var(--oms-slate-50);
  color: var(--oms-slate-950);
}

.oms-product-edit-panel {
  display: grid;
  gap: 12px;
  border-top: 1px solid var(--oms-slate-100);
  background: #f8fafc;
  padding: 16px;
}

.oms-product-edit-head,
.oms-product-edit-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.oms-product-edit-head strong {
  color: var(--oms-slate-950);
  font-size: 16px;
}

.oms-product-edit-grid {
  display: grid;
  grid-template-columns: 100px 120px 90px 90px 160px 150px 180px minmax(180px, 1fr);
  gap: 10px;
}

.oms-product-edit-actions {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
}

.oms-manual-product-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
}

.oms-local-edit-badge {
  display: inline-flex;
  margin-top: 5px;
  border-radius: 999px;
  background: #eff6ff;
  padding: 3px 7px;
  color: var(--oms-blue-700);
  font-size: 11px;
  font-weight: 850;
}

.oms-detail-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 16px;
}

.oms-detail-side {
  min-width: 0;
}

.oms-info-section {
  padding: 18px;
}

.oms-info-row {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr);
  gap: 12px;
  padding: 7px 0;
  font-size: 13.5px;
}

.oms-info-label {
  color: var(--oms-slate-500);
}

.oms-info-value {
  min-width: 0;
  color: var(--oms-slate-950);
  font-weight: 700;
}

.oms-info-inline-row {
  align-items: center;
}

.oms-info-inline-row .oms-inline-edit-input {
  min-width: min(280px, 100%);
}

.oms-payment-inline {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--oms-slate-100);
  padding-bottom: 14px;
}

.oms-payment-total {
  color: var(--oms-slate-500);
}

.oms-invoice-pdf-card {
  display: grid;
  gap: 12px;
  margin-top: 14px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
  padding: 14px;
}

.oms-invoice-pdf-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.oms-invoice-pdf-title {
  color: var(--oms-slate-950);
  font-size: 14px;
  font-weight: 950;
}

.oms-invoice-pdf-subtitle {
  margin-top: 3px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.35;
}

.oms-invoice-pdf-badge {
  flex: 0 0 auto;
  border-radius: 999px;
  background: #ffffff;
  padding: 5px 9px;
  color: var(--oms-blue-700);
  font-size: 11px;
  font-weight: 950;
}

.oms-invoice-pdf-meta {
  display: grid;
  gap: 5px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 750;
}

.oms-invoice-pdf-meta strong {
  color: var(--oms-slate-900);
  font-weight: 900;
}

.oms-invoice-pdf-error {
  border: 1px solid #fecaca;
  border-radius: 8px;
  background: #fff7f7;
  padding: 9px 10px;
  color: #991b1b;
  font-size: 12px;
  font-weight: 850;
}

.oms-invoice-pdf-info {
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #ffffff;
  padding: 9px 10px;
  color: var(--oms-blue-700);
  font-size: 12px;
  font-weight: 850;
}

.oms-invoice-readiness {
  display: grid;
  gap: 9px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #ffffff;
  padding: 10px;
}

.oms-invoice-readiness.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-invoice-readiness.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-invoice-readiness.wait {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-invoice-readiness-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.oms-invoice-readiness-head strong,
.oms-invoice-readiness-head span {
  display: block;
}

.oms-invoice-readiness-head strong {
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-invoice-readiness-head span {
  margin-top: 2px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 760;
  overflow-wrap: anywhere;
}

.oms-invoice-readiness-head em {
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  padding: 4px 8px;
  color: var(--oms-slate-700);
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
}

.oms-invoice-readiness-meta,
.oms-invoice-readiness-checklist,
.oms-invoice-readiness-issues {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.oms-invoice-readiness-meta span,
.oms-invoice-readiness-checklist span,
.oms-invoice-readiness-issues span {
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.78);
  padding: 5px 7px;
  color: var(--oms-slate-600);
  font-size: 11.5px;
  font-weight: 820;
}

.oms-invoice-readiness-meta strong {
  color: var(--oms-slate-950);
  font-weight: 950;
}

.oms-invoice-readiness-checklist span.fail,
.oms-invoice-readiness-issues span {
  color: #991b1b;
}

.oms-invoice-readiness-checklist span.pass {
  color: #166534;
}

.oms-warehouse-reservation-card {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  border: 1px solid #d9f99d;
  border-radius: 8px;
  background: #f7fee7;
  padding: 14px;
}

.oms-warehouse-reservation-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.oms-warehouse-reservation-title {
  color: var(--oms-slate-950);
  font-size: 14px;
  font-weight: 950;
}

.oms-warehouse-reservation-subtitle {
  margin-top: 3px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.35;
}

.oms-warehouse-reservation-badge {
  flex: 0 0 auto;
  border-radius: 999px;
  background: #ffffff;
  padding: 5px 9px;
  color: #3f6212;
  font-size: 11px;
  font-weight: 950;
}

.oms-warehouse-reservation-badge.ready {
  color: #166534;
}

.oms-warehouse-reservation-badge.wait {
  color: #92400e;
}

.oms-warehouse-reservation-badge.blocked {
  color: #991b1b;
}

.oms-warehouse-reservation-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.oms-warehouse-reservation-metrics span {
  border-radius: 8px;
  background: #ffffff;
  padding: 8px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 850;
}

.oms-warehouse-reservation-metrics strong {
  display: block;
  margin-top: 3px;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
}

.oms-warehouse-reservation-lines {
  display: grid;
  gap: 6px;
}

.oms-warehouse-reservation-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
  align-items: center;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  padding: 8px 9px;
  font-size: 12px;
}

.oms-warehouse-reservation-line.ready {
  border-color: #bbf7d0;
}

.oms-warehouse-reservation-line.partial,
.oms-warehouse-reservation-line.blocked,
.oms-warehouse-reservation-line.missing,
.oms-warehouse-reservation-line.no_sku {
  border-color: #fecaca;
}

.oms-warehouse-reservation-line span,
.oms-warehouse-reservation-line strong,
.oms-warehouse-reservation-line em {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-warehouse-reservation-line span {
  color: var(--oms-slate-950);
  font-weight: 900;
}

.oms-warehouse-reservation-line strong {
  color: var(--oms-slate-700);
  font-weight: 950;
}

.oms-warehouse-reservation-line em {
  color: var(--oms-slate-500);
  font-style: normal;
  font-weight: 850;
}

.oms-warehouse-reservation-empty {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
}

.oms-warehouse-ledger {
  display: grid;
  gap: 5px;
  margin-top: 10px;
  border-top: 1px solid rgba(148, 163, 184, 0.24);
  padding-top: 9px;
}

.oms-warehouse-ledger strong,
.oms-warehouse-ledger span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-warehouse-ledger strong {
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 950;
}

.oms-warehouse-ledger span {
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-invoice-pdf-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.oms-invoice-diagnostics {
  border: 1px dashed #bfdbfe;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.oms-invoice-diagnostics summary {
  cursor: pointer;
  padding: 9px 10px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 950;
  list-style-position: inside;
}

.oms-invoice-diagnostics-body {
  display: grid;
  gap: 9px;
  border-top: 1px solid #dbeafe;
  padding: 10px;
}

.oms-invoice-doc-history {
  border: 1px dashed #bfdbfe;
  border-radius: 8px;
  background: #ffffff;
}

.oms-invoice-doc-history summary {
  cursor: pointer;
  padding: 9px 10px;
  color: var(--oms-blue-700);
  font-size: 12px;
  font-weight: 950;
  list-style-position: inside;
}

.oms-invoice-doc-history-list {
  display: grid;
  gap: 8px;
  border-top: 1px solid #dbeafe;
  padding: 10px;
}

.oms-invoice-doc-history-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 9px 10px;
}

.oms-invoice-doc-history-row.cancelled {
  opacity: 0.68;
}

.oms-invoice-doc-history-row strong,
.oms-invoice-doc-history-row span {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-invoice-doc-history-row strong {
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-invoice-doc-history-row span {
  margin-top: 3px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 750;
}

.oms-paid-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 6px;
  background: #15803d;
  padding: 3px 8px;
  color: white;
  font-size: 12px;
  font-weight: 800;
}

.oms-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  background: var(--oms-green-50);
  padding: 6px 10px;
  color: #15803d;
  font-size: 13px;
  font-weight: 800;
}

.oms-status-pill::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--oms-green-500);
}

.oms-automation-diagnosis {
  border-color: #dbe3ef;
  background: #fbfdff;
}

.oms-automation-confidence {
  display: inline-flex;
  min-width: 42px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--oms-slate-100);
  padding: 4px 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 900;
}

.oms-automation-reason,
.oms-automation-side-effects,
.oms-automation-footnote {
  margin-top: 10px;
  border-radius: 6px;
  padding: 9px 10px;
  font-size: 12px;
  line-height: 1.45;
}

.oms-automation-reason {
  background: white;
  color: var(--oms-slate-700);
}

.oms-automation-side-effects {
  background: #fff7ed;
  color: #9a3412;
  font-weight: 700;
}

.oms-automation-footnote {
  background: var(--oms-slate-50);
  color: var(--oms-slate-500);
}

.oms-toolbar-select {
  display: inline-flex;
  height: 34px;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 0 8px 0 10px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.oms-toolbar-select select {
  min-width: 118px;
  border: 0;
  background: transparent;
  color: var(--oms-slate-900);
  font-size: 13px;
  font-weight: 700;
  outline: none;
}

.oms-operator-filter-bar {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.oms-toolbar-select.compact {
  padding-inline: 8px;
}

.oms-toolbar-select.compact select {
  min-width: 94px;
}

.oms-pack-match-select {
  border-color: #99f6e4;
  background: #f0fdfa;
}

.oms-pack-match-select.active {
  border-color: #14b8a6;
  background: #ccfbf1;
  color: #0f766e;
}

.oms-pack-match-select select {
  min-width: 160px;
  max-width: 240px;
}

.oms-pack-match-active {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid #99f6e4;
  border-radius: 12px;
  background: #f0fdfa;
  color: #0f766e;
  margin: 0 0 10px;
  padding: 10px 12px;
}

.oms-pack-match-active div {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 2px;
}

.oms-pack-match-active strong {
  color: #115e59;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.oms-pack-match-active span {
  overflow: hidden;
  color: #134e4a;
  font-size: 13px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-pack-match-active button {
  flex: 0 0 auto;
  border: 1px solid #5eead4;
  border-radius: 999px;
  background: white;
  color: #0f766e;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  padding: 6px 10px;
}

.oms-pack-match-active button:hover {
  background: #ccfbf1;
}

.oms-toolbar-clear {
  height: 34px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  color: var(--oms-slate-600);
  padding: 0 11px;
  font-size: 12px;
  font-weight: 800;
}

.oms-toolbar-clear:hover {
  border-color: var(--oms-slate-300);
  background: white;
  color: var(--oms-slate-950);
}

html[data-flow-oms-ui="premium"] body {
  background: #eef2f7;
}

.oms-app[data-ui-mode="premium"] {
  background: #eef2f7;
  color: #182230;
}

.oms-app[data-ui-mode="premium"] .oms-sidebar {
  flex-basis: 64px;
  width: 64px;
  min-width: 64px;
  background: #101828;
  color: #98a2b3;
}

.oms-app[data-ui-mode="premium"] .oms-sidebar:hover,
.oms-app[data-ui-mode="premium"] .oms-sidebar:focus-within {
  flex-basis: 248px;
  width: 248px;
  min-width: 248px;
}

.oms-app[data-ui-mode="premium"] .oms-sidebar-top {
  min-height: 52px;
  border-bottom-color: rgba(255, 255, 255, 0.08);
  padding-block: 13px;
}

.oms-app[data-ui-mode="premium"] .oms-logo,
.oms-app[data-ui-mode="premium"] .oms-sidebar:not(:hover):not(:focus-within) .oms-logo::before {
  font-weight: 850;
  letter-spacing: 0;
}

.oms-app[data-ui-mode="premium"] .oms-preview-badge {
  border-color: rgba(84, 135, 255, 0.28);
  background: rgba(59, 130, 246, 0.14);
  color: #dbeafe;
}

.oms-app[data-ui-mode="premium"] .oms-sidebar-nav {
  padding: 10px 7px;
}

.oms-app[data-ui-mode="premium"] .oms-nav-item,
.oms-app[data-ui-mode="premium"] .oms-nav-subitem {
  min-height: 34px;
  border-radius: 7px;
}

.oms-app[data-ui-mode="premium"] .oms-nav-item {
  padding: 8px 11px;
}

.oms-app[data-ui-mode="premium"] .oms-nav-subitem {
  min-height: 31px;
  padding-block: 7px;
  font-size: 12.3px;
}

.oms-app[data-ui-mode="premium"] .oms-nav-item:hover,
.oms-app[data-ui-mode="premium"] .oms-nav-subitem:hover,
.oms-app[data-ui-mode="premium"] .oms-nav-item.active,
.oms-app[data-ui-mode="premium"] .oms-nav-subitem.active {
  background: #1d2939;
}

.oms-app[data-ui-mode="premium"] .oms-topbar {
  height: 50px;
  min-height: 50px;
  gap: 14px;
  border-bottom-color: #d7dee8;
  box-shadow: 0 1px 0 rgba(16, 24, 40, 0.03);
  padding: 0 16px;
}

.oms-app[data-ui-mode="premium"] .oms-quick-access {
  color: #475467;
  font-size: 13px;
  font-weight: 850;
}

.oms-app[data-ui-mode="premium"] .oms-search {
  max-width: 610px;
}

.oms-app[data-ui-mode="premium"] .oms-search input {
  height: 34px;
  border-color: #e4e7ec;
  border-radius: 7px;
  background: #f2f4f7;
  color: #1d2939;
  font-size: 13px;
}

.oms-app[data-ui-mode="premium"] .oms-current-link,
.oms-app[data-ui-mode="premium"] .oms-sound-toggle,
.oms-app[data-ui-mode="premium"] .oms-sound-volume,
.oms-app[data-ui-mode="premium"] .oms-icon-btn,
.oms-app[data-ui-mode="premium"] .oms-avatar {
  height: 32px;
}

.oms-app[data-ui-mode="premium"] .oms-icon-btn,
.oms-app[data-ui-mode="premium"] .oms-sound-toggle,
.oms-app[data-ui-mode="premium"] .oms-sound-volume,
.oms-app[data-ui-mode="premium"] .oms-current-link {
  border-color: #d7dee8;
  border-radius: 7px;
}

.oms-app[data-ui-mode="premium"] .oms-ui-mode-toggle {
  border-color: #d7dee8;
  border-radius: 7px;
  background: #f2f4f7;
}

.oms-app[data-ui-mode="premium"] .oms-ui-mode-btn {
  height: 28px;
  border-radius: 6px;
  color: #667085;
  font-size: 11.8px;
}

.oms-app[data-ui-mode="premium"] .oms-ui-mode-btn.active {
  background: #3478f6;
  color: #ffffff;
  box-shadow: inset 0 -1px 0 rgba(16, 24, 40, 0.16);
}

.oms-app[data-ui-mode="premium"] .oms-avatar {
  width: 32px;
  background: #3478f6;
}

.oms-app[data-ui-mode="premium"] .oms-filters-panel {
  flex-basis: 248px;
  width: 248px;
  min-width: 248px;
  border-right-color: #ccd5e2;
  background: #f7f9fc;
}

.oms-app[data-ui-mode="premium"] .oms-filters-header {
  padding: 9px 10px;
}

.oms-app[data-ui-mode="premium"] .oms-btn-primary {
  height: 34px;
  border-radius: 9px;
  background: #3478f6;
  box-shadow: inset 0 -1px 0 rgba(16, 24, 40, 0.18);
  font-weight: 850;
}

.oms-app[data-ui-mode="premium"] .oms-filter-group {
  padding: 7px 8px 10px;
}

.oms-app[data-ui-mode="premium"] .oms-filter-item,
.oms-app[data-ui-mode="premium"] .oms-filter-subitem {
  border-radius: 6px;
  color: #475467;
}

.oms-app[data-ui-mode="premium"] .oms-filter-item {
  min-height: 29px;
  padding: 5px 8px;
  font-size: 12.5px;
}

.oms-app[data-ui-mode="premium"] .oms-filter-subitem {
  min-height: 27px;
  padding-block: 4px;
  font-size: 12.3px;
}

.oms-app[data-ui-mode="premium"] .oms-filter-item.active,
.oms-app[data-ui-mode="premium"] .oms-filter-subitem.active {
  background: #eaf2ff;
  color: #175cd3;
}

.oms-app[data-ui-mode="premium"] .oms-count {
  background: #e4e7ec;
  color: #667085;
  font-size: 10.5px;
}

.oms-app[data-ui-mode="premium"] .oms-orders-area {
  background: #ffffff;
}

.oms-app[data-ui-mode="premium"] .oms-orders-header {
  min-height: 50px;
  border-bottom-color: #e1e7ef;
  background: #ffffff;
  padding: 8px 16px;
}

.oms-app[data-ui-mode="premium"] .oms-orders-title {
  font-size: 17px;
  font-weight: 850;
  letter-spacing: 0;
}

.oms-app[data-ui-mode="premium"] .oms-orders-subtitle {
  margin-top: 1px;
  font-size: 11.5px;
}

.oms-app[data-ui-mode="premium"] .oms-toolbar {
  gap: 5px;
  border-bottom-color: #d7dee8;
  background: #ffffff;
  padding: 7px 14px;
}

.oms-app[data-ui-mode="premium"] .oms-tool-group {
  gap: 0;
  margin-right: 7px;
  padding-right: 7px;
  border-right-color: #d7dee8;
}

/* Tryb premium zaciska grupy do zera - kosz musi zachowac swoj odstep. */
.oms-app[data-ui-mode="premium"] .oms-tool-group-destructive {
  margin-left: 10px;
  padding-right: 0;
  border-right: 0;
}

.oms-app[data-ui-mode="premium"] .oms-tool-btn,
.oms-app[data-ui-mode="premium"] .oms-page-btn {
  width: 28px;
  height: 28px;
  border: 1px solid #d7dee8;
  border-radius: 6px;
  background: #ffffff;
  color: #667085;
}

.oms-app[data-ui-mode="premium"] .oms-tool-btn:hover,
.oms-app[data-ui-mode="premium"] .oms-page-btn:hover:not(:disabled) {
  background: #f8fafc;
  color: #101828;
}

.oms-app[data-ui-mode="premium"] .oms-tool-btn.active {
  border-color: #3478f6;
  background: #3478f6;
  color: #ffffff;
}

.oms-app[data-ui-mode="premium"] .oms-btn-pack {
  height: 30px;
  border-radius: 7px;
  background: #3478f6;
  color: #ffffff;
  font-size: 12.5px;
  font-weight: 850;
}

.oms-app[data-ui-mode="premium"] .oms-selected-chip {
  height: 28px;
  border-color: #d7dee8;
  background: #f8fafc;
  font-size: 12px;
}

.oms-app[data-ui-mode="premium"] .oms-toolbar-select {
  height: 30px;
  border-color: #d7dee8;
  border-radius: 7px;
  background: #ffffff;
  color: #667085;
  font-size: 11.6px;
}

.oms-app[data-ui-mode="premium"] .oms-toolbar-select select {
  min-width: 105px;
  color: #182230;
  font-size: 12.3px;
  font-weight: 850;
}

.oms-app[data-ui-mode="premium"] .oms-toolbar-select.compact select {
  min-width: 82px;
}

.oms-app[data-ui-mode="premium"] .oms-toolbar-clear {
  height: 30px;
  border-color: #d7dee8;
  border-radius: 7px;
  background: #f8fafc;
  font-size: 11.8px;
}

.oms-app[data-ui-mode="premium"] .oms-pagination-info {
  color: #667085;
  font-size: 12.5px;
}

.oms-app[data-ui-mode="premium"] .oms-pagination-info strong {
  color: #101828;
  font-size: 14px;
  font-weight: 900;
}

.oms-app[data-ui-mode="premium"] .oms-table-container {
  background: #ffffff;
}

.oms-app[data-ui-mode="premium"] .oms-table {
  font-size: 12.45px;
}

.oms-app[data-ui-mode="premium"] .oms-table th {
  border-bottom-color: #ccd5e2;
  background: #f8fafc;
  padding: 8px 9px;
  color: #667085;
  font-size: 10.3px;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.oms-app[data-ui-mode="premium"] .oms-table td {
  border-bottom-color: #d9e1ec;
  padding: 7px 9px;
}

.oms-app[data-ui-mode="premium"] .oms-table tr:hover td {
  background: #f8fbff;
}

.oms-app[data-ui-mode="premium"] .oms-table tr.selected td,
.oms-app[data-ui-mode="premium"] .oms-table tr.selected:hover td {
  background: #eaf2ff;
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-unpaid td {
  background: #fff7f7;
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-unpaid:hover td,
.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-unpaid.selected td {
  background: #ffe8e8;
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-packed-recheck td {
  background: #fff8ed;
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-packed-recheck:hover td,
.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-packed-recheck.selected td {
  background: #ffefd5;
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-channel-allegro td:first-child,
.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-store-allegro td:first-child {
  box-shadow: inset 3px 0 0 var(--oms-yellow-500);
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-store-bokserkoland td:first-child {
  box-shadow: inset 3px 0 0 var(--oms-cyan-500);
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-store-heelito td:first-child {
  box-shadow: inset 3px 0 0 var(--oms-slate-900);
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-store-hu td:first-child {
  box-shadow: inset 3px 0 0 var(--oms-green-500);
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-store-cz td:first-child {
  box-shadow: inset 3px 0 0 var(--oms-pink-500);
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-store-sk td:first-child {
  box-shadow: inset 3px 0 0 var(--oms-blue-500);
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-store-lt td:first-child {
  box-shadow: inset 3px 0 0 var(--oms-orange-500);
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-store-ro td:first-child {
  box-shadow: inset 3px 0 0 #0ea5e9;
}

.oms-app[data-ui-mode="premium"] .oms-checkbox {
  width: 15px;
  height: 15px;
  border-color: #c7d0dd;
  border-radius: 4px;
}

.oms-app[data-ui-mode="premium"] .oms-order-number {
  color: #2370d8;
  font-size: 12.7px;
  font-weight: 900;
}

.oms-app[data-ui-mode="premium"] .oms-order-sub {
  color: #98a2b3;
  font-size: 11.3px;
}

.oms-app[data-ui-mode="premium"] .oms-customer-name {
  color: #182230;
  font-size: 12.7px;
  font-weight: 850;
}

.oms-app[data-ui-mode="premium"] .oms-source-badge,
.oms-app[data-ui-mode="premium"] .oms-operation-chip,
.oms-app[data-ui-mode="premium"] .oms-order-status-chip {
  border-radius: 4px;
  padding: 2px 6px;
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1.18;
  box-shadow: inset 0 -1px 0 rgba(16, 24, 40, 0.08);
}

.oms-app[data-ui-mode="premium"] .oms-row-signal-badges {
  gap: 5px;
}

.oms-app[data-ui-mode="premium"] .oms-products {
  gap: 5px;
}

.oms-app[data-ui-mode="premium"] .oms-product-thumbs {
  gap: 5px;
}

.oms-app[data-ui-mode="premium"] .oms-thumb {
  width: 56px;
  height: 56px;
  border-color: #d7dee8;
  border-radius: 6px;
  background: #f2f4f7;
  font-size: 15px;
}

.oms-app[data-ui-mode="premium"] .oms-thumb-count {
  border-radius: 4px;
  padding: 1px 4px;
  background: rgba(16, 24, 40, 0.86);
  font-size: 9.5px;
}

.oms-app[data-ui-mode="premium"] .oms-product-text {
  color: #5f6b7a;
  font-size: 12.35px;
  line-height: 1.35;
}

.oms-app[data-ui-mode="premium"] .oms-product-text strong {
  color: #344054;
}

.oms-app[data-ui-mode="premium"] .oms-amount {
  color: #182230;
  font-size: 12.5px;
  font-weight: 900;
}

.oms-app[data-ui-mode="premium"] .oms-shipping {
  gap: 5px;
}

.oms-app[data-ui-mode="premium"] .oms-row-info-icons {
  gap: 5px;
}

.oms-app[data-ui-mode="premium"] .oms-mini-icon,
.oms-app[data-ui-mode="premium"] .oms-list-status-badge {
  min-width: 18px;
  width: 18px;
  height: 18px;
  border-radius: 4px;
  font-size: 10px;
}

.oms-app[data-ui-mode="premium"] .oms-mini-icon svg {
  width: 12px;
  height: 12px;
}

.oms-app[data-ui-mode="premium"] .oms-ship-method {
  color: #2370d8;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.25;
}

.oms-app[data-ui-mode="premium"] .oms-date-main,
.oms-app[data-ui-mode="premium"] .oms-date-sub {
  font-size: 11.8px;
}

.oms-app[data-ui-mode="premium"] .oms-date-main {
  color: #344054;
}

.oms-app[data-ui-mode="premium"] .oms-date-sub {
  color: #2370d8;
}

.oms-app[data-ui-mode="premium"] .oms-empty-state,
.oms-app[data-ui-mode="premium"] .oms-error-state {
  color: #667085;
}

.oms-app[data-ui-mode="premium"] .oms-main,
.oms-app[data-ui-mode="premium"] .oms-workspace {
  background: #e8edf5;
}

.oms-app[data-ui-mode="premium"] .oms-topbar {
  background: #fbfcfe;
  border-bottom: 1px solid #c9d3e1;
}

.oms-app[data-ui-mode="premium"] .oms-search input {
  border-color: #d4dce8;
  background: #edf2f8;
}

.oms-app[data-ui-mode="premium"] .oms-ui-mode-toggle {
  border-color: #3478f6;
  background: #dbeafe;
  box-shadow: 0 0 0 2px rgba(52, 120, 246, 0.08);
}

.oms-app[data-ui-mode="premium"] .oms-ui-mode-btn.active {
  background: #155eef;
}

.oms-app[data-ui-mode="premium"] .oms-filters-panel {
  border-right: 3px solid #38bdf8;
  background: #f1f5f9;
  box-shadow: inset -1px 0 0 #d3dce9;
}

.oms-app[data-ui-mode="premium"] .oms-filter-section-title {
  color: #44546a;
  font-size: 11px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.oms-app[data-ui-mode="premium"] .oms-count {
  border: 1px solid #d0d8e5;
  background: #ffffff;
}

.oms-app[data-ui-mode="premium"] .oms-orders-area {
  background: #f5f7fb;
}

.oms-app[data-ui-mode="premium"] .oms-orders-header,
.oms-app[data-ui-mode="premium"] .oms-toolbar {
  background: #fbfcfe;
}

.oms-app[data-ui-mode="premium"] .oms-orders-header {
  border-bottom: 1px solid #cfd8e6;
}

.oms-app[data-ui-mode="premium"] .oms-toolbar {
  box-shadow: inset 0 -1px 0 #cfd8e6;
}

.oms-app[data-ui-mode="premium"] .oms-toolbar-select,
.oms-app[data-ui-mode="premium"] .oms-toolbar-clear,
.oms-app[data-ui-mode="premium"] .oms-tool-btn,
.oms-app[data-ui-mode="premium"] .oms-page-btn {
  border-color: #cbd5e1;
  box-shadow: 0 1px 1px rgba(16, 24, 40, 0.03);
}

.oms-app[data-ui-mode="premium"] .oms-table-container {
  background: #eef2f7;
}

.oms-app[data-ui-mode="premium"] .oms-table {
  border-right: 1px solid #cfd8e6;
  border-left: 1px solid #cfd8e6;
}

.oms-app[data-ui-mode="premium"] .oms-table th {
  border-bottom: 2px solid #c7d2e1;
  background: #edf2f8;
  color: #526174;
}

.oms-app[data-ui-mode="premium"] .oms-table td {
  border-bottom: 1px solid #cbd5e1;
  background: #ffffff;
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr:nth-child(even) td {
  background: #fbfdff;
}

.oms-app[data-ui-mode="premium"] .oms-table tr:hover td {
  background: #edf7ff;
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-unpaid td,
.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-unpaid:nth-child(even) td {
  background: #fff1f1;
}

.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-packed-recheck td,
.oms-app[data-ui-mode="premium"] .oms-table tbody tr.oms-row-packed-recheck:nth-child(even) td {
  background: #fff7e8;
}

.oms-app[data-ui-mode="premium"] .oms-order-number {
  text-decoration: none;
}

.oms-app[data-ui-mode="premium"] .oms-source-badge,
.oms-app[data-ui-mode="premium"] .oms-operation-chip,
.oms-app[data-ui-mode="premium"] .oms-order-status-chip {
  border: 1px solid rgba(16, 24, 40, 0.05);
}

.oms-app[data-ui-mode="premium"] .oms-thumb {
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.12);
}

.oms-pack-card {
  margin-bottom: 16px;
}

.oms-pack-state {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  background: var(--oms-slate-100);
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 800;
}

.oms-pack-state.in_progress {
  background: var(--oms-blue-50);
  color: var(--oms-blue-700);
}

.oms-pack-state.packed {
  background: var(--oms-green-50);
  color: var(--oms-green-600);
}

.oms-pack-state.blocked {
  background: #fef2f2;
  color: #dc2626;
}

.oms-pack-body {
  padding: 16px;
}

.oms-pack-summary {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  color: var(--oms-slate-500);
  font-size: 13px;
}

.oms-pack-summary strong {
  color: var(--oms-slate-950);
  font-size: 18px;
}

.oms-pack-list {
  display: grid;
  gap: 8px;
}

.oms-pack-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 10px 12px;
  cursor: pointer;
}

.oms-pack-row input {
  width: 18px;
  height: 18px;
  margin-top: 1px;
  accent-color: var(--oms-blue-600);
}

.oms-pack-row-main {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.oms-pack-row-main strong,
.oms-pack-row-main small {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-pack-row-main small {
  color: var(--oms-slate-500);
  font-size: 12px;
}

.oms-pack-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.oms-pack-empty {
  border: 1px dashed var(--oms-slate-300);
  border-radius: 8px;
  padding: 14px;
  color: var(--oms-slate-500);
  text-align: center;
}

.oms-confirm-modal[hidden] {
  display: none;
}

.oms-confirm-modal {
  position: fixed;
  inset: 0;
  z-index: 2400;
}

.oms-confirm-backdrop {
  display: grid;
  min-height: 100%;
  place-items: center;
  background: var(--oms-modal-backdrop);
  padding: 22px;
  backdrop-filter: blur(5px);
}

.oms-confirm-shell {
  width: min(560px, calc(100vw - 28px));
  overflow: hidden;
  border: 1px solid var(--oms-modal-border);
  border-radius: var(--oms-modal-radius);
  background: var(--oms-modal-surface-bg);
  box-shadow: var(--oms-modal-shadow);
}

.oms-confirm-head {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 22px 24px 18px;
}

.oms-confirm-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 8px;
  font-size: 22px;
  font-weight: 900;
}

.oms-confirm-icon.danger {
  background: #fef2f2;
  color: #b42318;
}

.oms-confirm-icon.warning {
  background: #fffbeb;
  color: #b45309;
}

.oms-confirm-icon.primary {
  background: #eff6ff;
  color: #1d4ed8;
}

.oms-confirm-kicker {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.oms-confirm-head h2 {
  margin: 3px 0 0;
  color: var(--oms-slate-900);
  font-size: 22px;
  line-height: 1.2;
}

.oms-confirm-body {
  border-top: 1px solid var(--oms-modal-border);
  padding: 20px 24px 22px;
}

.oms-confirm-body p {
  margin: 0;
  color: var(--oms-slate-700);
  font-size: 15px;
  line-height: 1.55;
}

.oms-confirm-meta {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}

.oms-confirm-meta div {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 10px 12px;
}

.oms-confirm-meta span {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
}

.oms-confirm-meta strong {
  min-width: 0;
  overflow-wrap: anywhere;
  color: var(--oms-slate-900);
  font-size: 13px;
  font-weight: 850;
}

.oms-confirm-reason {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}

.oms-confirm-reason span {
  color: var(--oms-slate-700);
  font-size: 13px;
  font-weight: 850;
}

.oms-confirm-reason textarea {
  width: 100%;
  min-height: 84px;
  resize: vertical;
  border: 1px solid var(--oms-slate-300);
  border-radius: var(--oms-control-radius-sm);
  padding: 11px 12px;
  color: var(--oms-slate-900);
  font: inherit;
  line-height: 1.45;
}

.oms-confirm-reason textarea:focus {
  border-color: var(--oms-blue-600);
  outline: 0;
  box-shadow: var(--oms-focus-ring);
}

.oms-confirm-reason input,
.oms-confirm-reason select {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--oms-slate-300);
  border-radius: var(--oms-control-radius-sm);
  padding: 8px 12px;
  color: var(--oms-slate-900);
  background: #fff;
  font: inherit;
}

.oms-confirm-reason input:focus,
.oms-confirm-reason select:focus {
  border-color: var(--oms-blue-600);
  outline: 0;
  box-shadow: var(--oms-focus-ring);
}

.oms-confirm-reason[hidden] {
  display: none;
}

.oms-station-reship-warning {
  display: grid;
  gap: 6px;
  margin: 12px 0;
  padding: 12px 14px;
  border: 2px solid #b42318;
  border-radius: var(--oms-control-radius-sm);
  background: #fef3f2;
  color: #7a271a;
}

.oms-station-reship-warning button {
  justify-self: start;
}

.oms-second-shipment-kind {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--oms-slate-300);
  border-radius: var(--oms-control-radius-sm);
  cursor: pointer;
}

.oms-second-shipment-kind:has(input:checked) {
  border-color: var(--oms-blue-600);
  box-shadow: var(--oms-focus-ring);
}

.oms-second-shipment-kind input {
  margin-top: 3px;
}

.oms-second-shipment-kind span {
  display: grid;
  gap: 4px;
}

.oms-second-shipment-kind small {
  color: var(--oms-slate-700);
  line-height: 1.4;
}

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

@media (max-width: 560px) {
  .oms-confirm-grid {
    grid-template-columns: 1fr;
  }
}

.oms-confirm-error {
  margin-top: 8px;
  color: #b42318;
  font-size: 13px;
  font-weight: 800;
}

.oms-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  border-top: 1px solid var(--oms-modal-border);
  background: var(--oms-modal-footer-bg);
  padding: 16px 24px;
}

.oms-confirm-cancel,
.oms-confirm-submit {
  min-height: 42px;
  border-radius: var(--oms-control-radius-sm);
  padding: 0 16px;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
}

.oms-confirm-cancel {
  border: 1px solid var(--oms-slate-300);
  background: #ffffff;
  color: var(--oms-slate-700);
}

.oms-confirm-submit {
  border: 1px solid transparent;
  color: #ffffff;
}

.oms-confirm-submit.danger {
  background: #dc2626;
}

.oms-confirm-submit.warning {
  background: #d97706;
}

.oms-confirm-submit.primary {
  /* --oms-blue nigdy nie bylo zdefiniowane - przycisk byl przezroczysty
     z bialym napisem (niewidoczny). Kolor marki jak reszta akcji glownych. */
  background: var(--oms-brand-primary-bg);
}

.oms-confirm-cancel:hover {
  background: var(--oms-slate-100);
}

.oms-confirm-submit:hover {
  filter: brightness(0.96);
}

body.oms-modal-open {
  overflow: hidden;
}

.oms-batch-pack-modal[hidden] {
  display: none;
}

.oms-batch-pack-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(2, 6, 23, 0.76);
  padding: 10px;
  backdrop-filter: blur(5px);
}

.oms-batch-pack-shell {
  display: grid;
  width: min(2026px, calc(100vw - 22px));
  height: min(1002px, calc(100vh - 22px));
  /* 2 wiersze auto na opcjonalne banery (blad sesji, drukarka offline) -
     body i stopka maja stale miejsce, baner nie zjada wiersza z trescia. */
  grid-template-rows: 72px auto auto auto minmax(0, 1fr) 92px;
  overflow: hidden;
  border: 1px solid #4b5563;
  border-radius: var(--oms-modal-radius);
  background: #30343b;
  color: #e5e7eb;
  box-shadow: var(--oms-modal-shadow);
}

.oms-batch-pack-shell > .oms-batch-pack-body {
  grid-row: 5;
}

.oms-batch-pack-shell > .oms-batch-pack-footer {
  grid-row: 6;
}

.oms-batch-pack-header {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
  padding: 0 28px;
}

.oms-batch-pack-title {
  color: #f8fafc;
  font-size: 20px;
  font-weight: 850;
}

.oms-batch-order-pill {
  position: absolute;
  left: 50%;
  top: 18px;
  transform: translateX(-50%);
  display: inline-flex;
  height: 34px;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.44);
  padding: 0 13px;
  color: #60a5fa;
  font-size: 18px;
  font-weight: 900;
  cursor: pointer;
  transition: background 140ms ease, color 140ms ease;
}

.oms-batch-order-pill:hover {
  background: rgba(37, 99, 235, 0.22);
  color: #93c5fd;
}

.oms-batch-order-pill span {
  font-size: 14px;
}

.oms-batch-close {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  color: #d1d5db;
  font-size: 38px;
  font-weight: 650;
  line-height: 1;
  cursor: pointer;
}

.oms-batch-close:hover {
  background: rgba(255, 255, 255, 0.08);
  color: white;
}

.oms-batch-session-banner {
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(15, 23, 42, 0.28);
  padding: 8px 28px;
  color: #cbd5e1;
  font-size: 13px;
  font-weight: 700;
}

.oms-batch-session-banner.error {
  background: rgba(127, 29, 29, 0.34);
  color: #fecaca;
}

.oms-batch-system-strip {
  display: flex;
  min-height: 38px;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(17, 24, 39, 0.62);
  padding: 6px 28px;
  color: #cbd5e1;
  font-size: 12px;
  font-weight: 800;
}

.oms-batch-system-strip:empty {
  min-height: 0;
  padding-block: 0;
}

.oms-batch-system-strip.error {
  color: #fecaca;
}

.oms-station-printer {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.55);
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 800;
  color: #cbd5e1;
}

.oms-station-printer select {
  max-width: 240px;
  border: none;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
  outline: none;
}

.oms-station-printer select option {
  color: #0f172a;
}

.oms-station-printer.offline {
  border-color: rgba(248, 113, 113, 0.55);
  color: #fecaca;
}

.oms-station-printer-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
  flex-wrap: wrap;
}

.oms-package-printer {
  position: relative;
  margin-left: auto;
}

.oms-package-printer > button {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  gap: 7px;
  border: 1px solid rgba(74, 222, 128, 0.45);
  border-radius: 999px;
  background: rgba(20, 83, 45, 0.34);
  padding: 4px 10px;
  color: #dcfce7;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.oms-package-printer.offline > button {
  border-color: rgba(248, 113, 113, 0.62);
  background: rgba(127, 29, 29, 0.38);
  color: #fee2e2;
}

.oms-package-printer.override > button {
  border-color: rgba(251, 146, 60, 0.9);
  background: rgba(154, 52, 18, 0.58);
  color: #ffedd5;
}

.oms-package-printer > button strong {
  border-radius: 999px;
  background: #f97316;
  padding: 2px 6px;
  color: #fff;
  font-size: 9px;
  letter-spacing: 0.04em;
}

.oms-package-printer-picker {
  position: absolute;
  z-index: 40;
  top: calc(100% + 8px);
  right: 0;
  display: grid;
  width: min(360px, calc(100vw - 40px));
  gap: 7px;
  border: 1px solid rgba(251, 146, 60, 0.68);
  border-radius: 12px;
  background: #1f2937;
  padding: 12px;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.45);
}

.oms-package-printer-picker > div {
  display: grid;
  gap: 3px;
  color: #ffedd5;
}

.oms-package-printer-picker small {
  color: #cbd5e1;
  font-size: 11px;
}

.oms-package-printer-picker > button {
  display: grid;
  gap: 2px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 9px;
  background: rgba(15, 23, 42, 0.7);
  padding: 9px 10px;
  color: #f8fafc;
  text-align: left;
  cursor: pointer;
}

.oms-package-printer-picker > button:hover {
  border-color: #fb923c;
  background: rgba(154, 52, 18, 0.28);
}

.oms-batch-session-error {
  border-bottom: 1px solid rgba(248, 113, 113, 0.28);
  background: rgba(127, 29, 29, 0.42);
  padding: 9px 28px;
  color: #fee2e2;
  font-size: 13px;
  font-weight: 850;
}

.oms-batch-compact-flags {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}

.oms-batch-compact-flags span {
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  border-radius: 999px;
  padding: 0 9px;
  background: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
  font-size: 11px;
  font-weight: 950;
}

.oms-batch-compact-flags .ok {
  background: rgba(22, 163, 74, 0.2);
  color: #bbf7d0;
}

.oms-batch-compact-flags .warning,
.oms-batch-compact-flags .cod {
  background: rgba(245, 158, 11, 0.2);
  color: #fde68a;
}

.oms-batch-compact-flags .error {
  background: rgba(220, 38, 38, 0.18);
  color: #fecaca;
}

.oms-batch-print-status {
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(17, 24, 39, 0.92);
  padding: 8px 28px;
  color: #cbd5e1;
  font-size: 12px;
  font-weight: 750;
}

.oms-batch-print-status strong {
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 11px;
  font-weight: 950;
}

.oms-batch-print-status.ok strong {
  background: #dcfce7;
  color: #166534;
}

.oms-batch-print-status.warn strong {
  background: #fef3c7;
  color: #92400e;
}

.oms-batch-print-status.off strong {
  background: #e2e8f0;
  color: #475569;
}

.oms-batch-print-queue {
  margin-left: auto;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  padding: 4px 9px;
  color: #e5e7eb;
  white-space: nowrap;
}

.oms-batch-print-queue.quiet {
  color: #94a3b8;
}

.oms-packing-ops-panel {
  margin: 0 0 12px;
  border: 1px solid rgba(59, 130, 246, 0.22);
  border-radius: 8px;
  background: #111827;
  padding: 12px;
  color: #d1d5db;
}

.oms-packing-ops-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.oms-packing-ops-title strong {
  color: #f9fafb;
  font-size: 15px;
}

.oms-packing-ops-title span,
.oms-packing-empty-line,
.oms-packing-problems {
  color: #9ca3af;
  font-size: 12px;
  font-weight: 700;
}

.oms-list-notice {
  margin: 0 0 12px;
  border: 1px solid #fed7aa;
  border-radius: 8px;
  background: #fff7ed;
  padding: 10px 12px;
  color: #9a3412;
  font-size: 13px;
  font-weight: 800;
}

.oms-archive-search {
  margin: 14px 0 12px;
  border: 1px solid #e4e7ec;
  border-radius: 8px;
  background: #fcfcfd;
  padding: 10px;
}

.oms-archive-search-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 12px;
  padding: 0 2px 8px;
  color: #667085;
  font-size: 12px;
  font-weight: 700;
}

.oms-archive-search-head strong {
  color: #101828;
  font-size: 13px;
  font-weight: 850;
}

.oms-archive-search-error {
  border-radius: 6px;
  background: #fef3f2;
  padding: 8px 10px;
  color: #b42318;
  font-size: 12px;
  font-weight: 700;
}

.oms-archive-search-row {
  display: grid;
  width: 100%;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: 12px;
  border: 1px solid transparent;
  border-top-color: #f2f4f7;
  border-radius: 6px;
  background: transparent;
  padding: 8px;
  text-align: left;
  cursor: pointer;
}

.oms-archive-search-row:hover,
.oms-archive-search-row:focus {
  border-color: #b7cffd;
  outline: none;
  background: #f4f8ff;
}

.oms-archive-search-main,
.oms-archive-search-side {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 2px;
}

.oms-archive-search-side {
  align-items: flex-end;
  text-align: right;
}

.oms-archive-search-main strong,
.oms-archive-search-side strong {
  color: #101828;
  font-size: 13px;
  font-weight: 850;
}

.oms-archive-search-main em,
.oms-archive-search-side em {
  overflow: hidden;
  color: #667085;
  font-size: 12px;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-archive-place {
  display: inline-block;
  margin-left: 6px;
  border-radius: 999px;
  background: #eef2f6;
  padding: 1px 7px;
  color: #475467;
  font-size: 11px;
  font-weight: 800;
  vertical-align: 1px;
}

.oms-archive-place.is-trash {
  background: #fef3f2;
  color: #b42318;
}

@media (max-width: 640px) {
  .oms-archive-search-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }

  .oms-archive-search-side {
    align-items: flex-start;
    text-align: left;
  }
}

.oms-app[data-theme="dark"] .oms-archive-search {
  border-color: rgba(148, 163, 184, 0.28);
  background: #0f172a;
}

.oms-app[data-theme="dark"] .oms-archive-search-head,
.oms-app[data-theme="dark"] .oms-archive-search-main em,
.oms-app[data-theme="dark"] .oms-archive-search-side em {
  color: #94a3b8;
}

.oms-app[data-theme="dark"] .oms-archive-search-head strong,
.oms-app[data-theme="dark"] .oms-archive-search-main strong,
.oms-app[data-theme="dark"] .oms-archive-search-side strong {
  color: #e5e7eb;
}

.oms-app[data-theme="dark"] .oms-archive-search-row {
  border-top-color: rgba(148, 163, 184, 0.14);
}

.oms-app[data-theme="dark"] .oms-archive-search-row:hover,
.oms-app[data-theme="dark"] .oms-archive-search-row:focus {
  border-color: rgba(96, 165, 250, 0.6);
  background: rgba(30, 64, 175, 0.24);
}

.oms-app[data-theme="dark"] .oms-archive-place {
  background: rgba(148, 163, 184, 0.2);
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-archive-place.is-trash {
  background: rgba(240, 68, 56, 0.2);
  color: #fda29b;
}

.oms-app[data-theme="dark"] .oms-archive-search-error {
  background: rgba(240, 68, 56, 0.16);
  color: #fda29b;
}

.oms-packing-session-card {
  display: flex;
  min-height: 46px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  padding-top: 8px;
  margin-top: 8px;
}

.oms-packing-session-main {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.oms-packing-session-head {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.oms-packing-session-card strong {
  color: #e5e7eb;
  font-size: 13px;
}

.oms-packing-session-card span {
  color: #9ca3af;
  font-size: 12px;
}

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

.oms-packing-session-cancel {
  display: inline-grid;
  width: 22px;
  height: 22px;
  min-height: 22px;
  place-items: center;
  border: 1px solid rgba(248, 113, 113, 0.4);
  border-radius: 999px;
  background: rgba(127, 29, 29, 0.22);
  color: #fecaca;
  font-size: 17px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
}

.oms-packing-session-cancel:hover {
  border-color: rgba(248, 113, 113, 0.78);
  background: rgba(185, 28, 28, 0.42);
  color: #fff;
}

.oms-packing-session-actions button,
.oms-batch-error-actions button,
.oms-batch-conflict-item button {
  min-height: 32px;
  border: 1px solid #4b5563;
  border-radius: 6px;
  background: #1f2937;
  padding: 0 10px;
  color: #e5e7eb;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.oms-packing-session-actions button:hover,
.oms-batch-error-actions button:hover,
.oms-batch-conflict-item button:hover {
  background: #374151;
}

.oms-packing-problems {
  margin-top: 8px;
  color: #fbbf24;
}

.oms-batch-pack-shell.error {
  grid-template-rows: auto 1fr;
}

.oms-batch-error-panel {
  padding: 28px;
  color: #e5e7eb;
}

.oms-batch-error-panel > strong {
  display: block;
  margin-bottom: 16px;
  color: #fecaca;
  font-size: 20px;
}

.oms-batch-conflict-list {
  display: grid;
  gap: 8px;
  max-width: 780px;
}

.oms-batch-conflict-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(160px, auto) auto;
  align-items: center;
  gap: 12px;
  border: 1px solid rgba(248, 113, 113, 0.35);
  border-radius: 8px;
  background: rgba(127, 29, 29, 0.18);
  padding: 10px 12px;
}

.oms-batch-conflict-item span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-batch-conflict-item em {
  color: #fca5a5;
  font-style: normal;
  font-weight: 800;
}

.oms-batch-error-actions {
  display: flex;
  gap: 8px;
  margin-top: 18px;
}

.oms-batch-pack-body {
  display: grid;
  min-height: 0;
  grid-template-columns: 292px minmax(0, 1fr);
}

.oms-batch-order-list {
  min-height: 0;
  overflow-y: auto;
  border-right: 1px solid rgba(148, 163, 184, 0.22);
  padding: 16px 18px;
}

.oms-batch-order-card {
  position: relative;
  display: grid;
  width: 100%;
  min-height: 74px;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  gap: 6px 10px;
  align-items: center;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  padding: 13px 14px;
  color: #d1d5db;
  text-align: left;
  cursor: pointer;
}

.oms-batch-order-card + .oms-batch-order-card {
  margin-top: 8px;
}

.oms-batch-order-card.active {
  background: #3478dc;
  color: white;
}

.oms-batch-order-card.packed {
  border-color: #22c55e;
  background: linear-gradient(135deg, rgba(22, 163, 74, 0.5), rgba(13, 128, 92, 0.32));
  box-shadow: inset 4px 0 0 #22c55e;
  color: #d1fae5;
}

.oms-batch-order-card.packed strong {
  color: #bbf7d0;
}

.oms-batch-order-card.packed em {
  border-color: #22c55e;
  background: #16a34a;
  color: #f0fdf4;
}

.oms-batch-order-card.active.packed {
  border-color: #86efac;
  background: linear-gradient(135deg, #16a34a, #0f766e);
  box-shadow: inset 4px 0 0 #bbf7d0;
}

.oms-batch-order-card.saving {
  opacity: 0.7;
}

.oms-batch-order-card.error {
  border-color: #f87171;
}

.oms-batch-order-card:hover:not(.active) {
  background: rgba(255, 255, 255, 0.06);
}

.oms-batch-order-card strong {
  color: inherit;
  font-size: 21px;
  font-weight: 900;
}

.oms-batch-order-card .oms-batch-order-number {
  min-width: 0;
  padding-right: 22px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-batch-order-card .oms-batch-order-customer {
  grid-column: 1;
  grid-row: 2;
  min-width: 0;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.8);
  font-size: 13px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-batch-order-card span:not(.oms-batch-order-remove) {
  min-width: 0;
  overflow: hidden;
  color: inherit;
  font-size: 14px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-batch-order-card span.oms-batch-order-customer {
  grid-column: 1;
  grid-row: 2;
  color: rgba(255, 255, 255, 0.8);
  font-size: 13px;
  font-weight: 800;
}

.oms-batch-order-card em {
  display: inline-flex;
  width: 52px;
  height: 32px;
  align-items: center;
  justify-content: center;
  grid-column: 2;
  grid-row: 1 / span 2;
  border: 2px solid rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.14);
  color: white;
  font-style: normal;
  font-size: 16px;
  font-weight: 900;
}

.oms-batch-order-card.packed em {
  border-color: #bbf7d0;
  background: #16a34a;
  color: white;
}

.oms-batch-order-card small {
  grid-column: 1 / -1;
  color: #fecaca;
  font-size: 11px;
  font-weight: 700;
}

.oms-batch-order-card .oms-batch-order-shipment {
  grid-column: 1 / -1;
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 6px;
  overflow: hidden;
  color: #d9f99d;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.oms-batch-order-card .oms-batch-order-shipment b,
.oms-batch-order-card .oms-batch-order-shipment span,
.oms-batch-order-card .oms-batch-order-shipment i {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-batch-order-card .oms-batch-order-shipment b {
  flex: 0 0 auto;
  color: #bbf7d0;
  font-style: normal;
}

.oms-batch-order-card .oms-batch-order-shipment span {
  flex: 1 1 auto;
  color: inherit;
  font-size: 11px;
  font-weight: 800;
}

.oms-batch-order-card .oms-batch-order-shipment i {
  flex: 0 0 auto;
  color: rgba(255, 255, 255, 0.72);
  font-size: 10px;
  font-style: normal;
  text-transform: uppercase;
}

.oms-batch-order-card .oms-batch-shipment-badge {
  color: #bfdbfe;
}

.oms-batch-order-card.active .oms-batch-shipment-badge {
  color: #eff6ff;
}

.oms-batch-order-card .oms-batch-shipment-badge.pending {
  color: #fde68a;
}

.oms-batch-order-card .oms-batch-shipment-badge.error {
  color: #fecaca;
}

.oms-batch-order-card.packed-recheck {
  border-color: rgba(251, 146, 60, 0.72);
  background: rgba(154, 52, 18, 0.18);
}

.oms-batch-order-card .oms-batch-order-recheck-note {
  color: #fed7aa;
  font-weight: 800;
}

.oms-batch-order-card.active.packed-recheck {
  border-color: #fbbf24;
  background: #3478dc;
}

.oms-batch-order-remove {
  position: absolute;
  top: 10px;
  right: 10px;
  display: inline-flex;
  width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
  border-radius: 5px;
  background: rgba(15, 23, 42, 0.36);
  color: rgba(255, 255, 255, 0.8);
  font-size: 18px;
  font-weight: 800;
}

.oms-batch-pack-stage {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  padding: 16px 30px 26px;
}

.oms-batch-meta {
  display: flex;
  min-height: 32px;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  color: #d1d5db;
  font-size: 15px;
  font-weight: 760;
}

.oms-batch-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.oms-batch-meta-main {
  color: #f3f4f6;
  font-weight: 900;
}

.oms-batch-meta-muted {
  max-width: min(560px, 100%);
  overflow: hidden;
  color: #9ca3af;
  text-overflow: ellipsis;
}

.oms-batch-meta svg,
.oms-delivery-method svg {
  width: 17px;
  height: 17px;
}

.oms-batch-customer-note {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 10px;
  border: 1px solid rgba(251, 191, 36, 0.55);
  border-left-width: 4px;
  border-radius: 8px;
  background: rgba(120, 53, 15, 0.35);
  padding: 9px 12px;
  color: #fef3c7;
}

.oms-batch-customer-note strong {
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fbbf24;
}

.oms-batch-customer-note span {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.35;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.oms-batch-order-card small.oms-batch-order-note-flag {
  color: #fbbf24;
  font-weight: 900;
}

.oms-batch-warehouse-reservation {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 12px;
  align-items: center;
  margin-top: 12px;
  border: 1px solid rgba(187, 247, 208, 0.45);
  border-radius: 8px;
  background: rgba(20, 83, 45, 0.28);
  padding: 10px 12px;
  color: #dcfce7;
}

.oms-batch-warehouse-reservation.wait {
  border-color: rgba(251, 191, 36, 0.5);
  background: rgba(120, 53, 15, 0.34);
  color: #fef3c7;
}

.oms-batch-warehouse-reservation.blocked {
  border-color: rgba(248, 113, 113, 0.55);
  background: rgba(127, 29, 29, 0.36);
  color: #fee2e2;
}

.oms-batch-warehouse-reservation strong,
.oms-batch-warehouse-reservation span,
.oms-batch-warehouse-reservation em,
.oms-batch-warehouse-reservation small {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-batch-warehouse-reservation strong {
  display: block;
  font-size: 13px;
  font-weight: 950;
}

.oms-batch-warehouse-reservation span {
  display: block;
  margin-top: 2px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-batch-warehouse-reservation em {
  justify-self: end;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  padding: 5px 9px;
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
  white-space: nowrap;
}

.oms-batch-warehouse-reservation small {
  grid-column: 1 / -1;
  color: rgba(255, 255, 255, 0.78);
  font-size: 11.5px;
  font-weight: 800;
}

.oms-batch-warehouse-reservation .oms-warehouse-ledger {
  grid-column: 1 / -1;
  border-top-color: rgba(255, 255, 255, 0.18);
}

.oms-batch-warehouse-reservation .oms-warehouse-ledger strong,
.oms-batch-warehouse-reservation .oms-warehouse-ledger span {
  color: rgba(255, 255, 255, 0.82);
}

.oms-batch-warehouse-post-preflight {
  grid-column: 1 / -1;
  display: grid;
  gap: 3px;
  border-radius: 8px;
  padding: 8px 10px;
}

.oms-batch-warehouse-post-preflight.ready {
  border: 1px solid rgba(187, 247, 208, 0.28);
  background: rgba(22, 101, 52, 0.34);
}

.oms-batch-warehouse-post-preflight.blocked {
  border: 1px solid rgba(248, 113, 113, 0.4);
  background: rgba(127, 29, 29, 0.28);
}

.oms-batch-warehouse-post-preflight strong,
.oms-batch-warehouse-post-preflight span,
.oms-batch-warehouse-post-preflight small {
  display: block;
  margin: 0;
}

.oms-batch-warehouse-document-confirmation {
  grid-column: 1 / -1;
  display: grid;
  gap: 3px;
  border-radius: 8px;
  padding: 8px 10px;
}

.oms-batch-warehouse-document-confirmation.ready {
  border: 1px solid rgba(187, 247, 208, 0.32);
  background: rgba(21, 128, 61, 0.36);
}

.oms-batch-warehouse-document-confirmation.blocked {
  border: 1px solid rgba(251, 146, 60, 0.42);
  background: rgba(124, 45, 18, 0.32);
}

.oms-batch-warehouse-document-confirmation strong,
.oms-batch-warehouse-document-confirmation span,
.oms-batch-warehouse-document-confirmation small {
  display: block;
  margin: 0;
}

.oms-batch-warehouse-actions {
  grid-column: 1 / -1;
  justify-self: end;
}

.oms-batch-warehouse-actions summary {
  cursor: pointer;
  color: rgba(255, 255, 255, 0.78);
  font-size: 11.5px;
  font-weight: 900;
}

.oms-batch-warehouse-actions > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 8px;
}

.oms-batch-warehouse-actions button {
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  padding: 7px 12px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 950;
  cursor: pointer;
}

.oms-batch-warehouse-actions button:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.2);
}

.oms-batch-warehouse-actions button:disabled {
  cursor: not-allowed;
  opacity: 0.46;
}

.oms-delivery-methods {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
  margin-top: 9px;
  padding-bottom: 12px;
  border-bottom: 2px solid rgba(148, 163, 184, 0.32);
}

/* "Wyslij razem" w asystencie pakowania - propozycja jednej paczki dla klienta,
   ktory ma tu wiecej niz jedno zamowienie. Ciemna paleta modala pakowania. */
.oms-batch-group {
  margin-top: 10px;
  border: 1px solid #4c1d95;
  border-radius: 12px;
  background: rgba(139, 92, 246, 0.12);
  padding: 10px 12px;
}

.oms-batch-group.active {
  border-color: #22c55e;
  background: rgba(34, 197, 94, 0.14);
}

.oms-batch-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #ede9fe;
  font-size: 13.5px;
  font-weight: 850;
}

.oms-batch-group.active .oms-batch-group-head {
  color: #dcfce7;
}

.oms-batch-group-head span {
  color: #a5b4fc;
  font-size: 11.5px;
  font-weight: 760;
  text-transform: uppercase;
}

.oms-batch-group-rows {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.oms-batch-group-row {
  display: flex;
  align-items: center;
  gap: 7px;
  border: 1px solid #4b5563;
  border-radius: 9px;
  background: rgba(17, 24, 39, 0.55);
  padding: 6px 9px;
  color: #e5e7eb;
  font-size: 12.5px;
  font-weight: 800;
  cursor: pointer;
}

.oms-batch-group-row.checked {
  border-color: #22c55e;
  color: #dcfce7;
}

.oms-batch-group-row input {
  width: 15px;
  height: 15px;
  accent-color: #22c55e;
  cursor: pointer;
}

.oms-batch-group-row span {
  color: #9ca3af;
  font-weight: 700;
}

.oms-batch-group-sum {
  margin-top: 8px;
  color: #dcfce7;
  font-size: 13px;
  font-weight: 850;
}

.oms-batch-group-hint {
  margin-top: 5px;
  color: #9ca3af;
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.4;
}

.oms-delivery-methods-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  color: #e5e7eb;
  font-size: 14px;
  font-weight: 850;
}

.oms-delivery-methods-header span {
  color: #9ca3af;
  font-size: 12px;
  font-weight: 760;
  text-transform: uppercase;
}

.oms-delivery-methods-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 12px;
}

.oms-delivery-method-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.18);
  padding: 4px 8px;
  color: var(--oms-slate-300);
  font-size: 11px;
  font-weight: 900;
}

.oms-delivery-method-legend-item i {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: currentColor;
}

.oms-delivery-method-legend-item.yellow { color: #facc15; }
.oms-delivery-method-legend-item.blue { color: #60a5fa; }
.oms-delivery-method-legend-item.red { color: #f87171; }
.oms-delivery-method-legend-item.purple { color: #c084fc; }
.oms-delivery-method-legend-item.green { color: #4ade80; }
.oms-delivery-method-legend-item.orange { color: #f59e0b; }
.oms-delivery-method-legend-item.olive { color: #a3e635; }
.oms-delivery-method-legend-item.black { color: #f8fafc; }

.oms-batch-recheck-warning {
  margin-top: 12px;
  border: 1px solid #fed7aa;
  border-radius: 8px;
  background: #7c2d12;
  padding: 10px 12px;
  color: #ffedd5;
  font-size: 13px;
  font-weight: 850;
}

.oms-delivery-method {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  gap: 7px;
  border: 1px solid #4b5563;
  border-radius: 999px;
  background: #2b2f36;
  padding: 0 12px 0 7px;
  color: #d1d5db;
  font-size: 13px;
  font-weight: 850;
  cursor: pointer;
}

.oms-delivery-method:hover,
.oms-delivery-method.active {
  border-color: #93c5fd;
  background: #374151;
}

.oms-delivery-method.yellow {
  border-color: rgba(255, 240, 68, 0.72);
  background: rgba(255, 240, 68, 0.18);
  color: #fff9b8;
}

.oms-delivery-method.blue {
  border-color: rgba(96, 165, 250, 0.58);
  background: rgba(30, 64, 175, 0.28);
  color: #dbeafe;
}

.oms-delivery-method.red {
  border-color: rgba(248, 113, 113, 0.58);
  background: rgba(127, 29, 29, 0.28);
  color: #fee2e2;
}

.oms-delivery-method.purple {
  border-color: rgba(192, 132, 252, 0.58);
  background: rgba(88, 28, 135, 0.28);
  color: #f3e8ff;
}

.oms-delivery-method.green {
  border-color: rgba(74, 222, 128, 0.52);
  background: rgba(20, 83, 45, 0.28);
  color: #dcfce7;
}

.oms-delivery-method.orange {
  border-color: rgba(245, 158, 11, 0.56);
  background: rgba(146, 64, 14, 0.28);
  color: #ffedd5;
}

.oms-delivery-method.olive {
  border-color: rgba(163, 230, 53, 0.46);
  background: rgba(63, 98, 18, 0.28);
  color: #ecfccb;
}

.oms-delivery-method.yellow:hover,
.oms-delivery-method.yellow.active {
  border-color: #fff044;
  background: rgba(255, 240, 68, 0.3);
}

.oms-delivery-method.blue:hover,
.oms-delivery-method.blue.active {
  border-color: #93c5fd;
  background: rgba(29, 78, 216, 0.52);
}

.oms-delivery-method.red:hover,
.oms-delivery-method.red.active {
  border-color: #fca5a5;
  background: rgba(153, 27, 27, 0.52);
}

.oms-delivery-method.purple:hover,
.oms-delivery-method.purple.active {
  border-color: #d8b4fe;
  background: rgba(107, 33, 168, 0.52);
}

.oms-delivery-method.green:hover,
.oms-delivery-method.green.active {
  border-color: #86efac;
  background: rgba(22, 101, 52, 0.52);
}

.oms-delivery-method.orange:hover,
.oms-delivery-method.orange.active {
  border-color: #fdba74;
  background: rgba(154, 52, 18, 0.52);
}

.oms-delivery-method.olive:hover,
.oms-delivery-method.olive.active {
  border-color: #bef264;
  background: rgba(77, 124, 15, 0.48);
}

.oms-delivery-method.suggested {
  border-color: #facc15;
  box-shadow: 0 0 0 1px rgba(250, 204, 21, 0.16);
}

.oms-delivery-method:disabled {
  cursor: progress;
  opacity: 0.72;
}

.oms-delivery-method-icon {
  display: inline-flex;
  width: 25px;
  height: 25px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: white;
}

.oms-delivery-method-text {
  display: inline-grid;
  gap: 2px;
  line-height: 1.05;
  text-align: left;
}

.oms-delivery-method-text small {
  color: var(--oms-slate-300);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.oms-delivery-method.yellow .oms-delivery-method-text small {
  color: #fef3c7;
}

.oms-delivery-method-text .oms-delivery-method-suggestion {
  color: #fde68a;
  font-size: 10px;
  text-transform: uppercase;
}

.oms-delivery-method.green .oms-delivery-method-icon { background: #43a047; }
.oms-delivery-method.yellow .oms-delivery-method-icon {
  background: #fff044;
  color: #1f2937;
}
.oms-delivery-method.orange .oms-delivery-method-icon { background: #f59e0b; }
.oms-delivery-method.purple .oms-delivery-method-icon { background: #8b22ee; }
.oms-delivery-method.blue .oms-delivery-method-icon { background: #3038f2; }
.oms-delivery-method.red .oms-delivery-method-icon { background: #d84315; }
.oms-delivery-method.black .oms-delivery-method-icon { background: #050608; }
.oms-delivery-method.olive .oms-delivery-method-icon { background: #8a8d5f; }
.oms-delivery-method.white .oms-delivery-method-icon {
  background: #f8fafc;
  color: #cbd5e1;
}

.oms-delivery-method-badge {
  margin-left: 4px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.08);
  padding: 3px 6px;
  color: currentColor;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0;
}

.oms-delivery-method.auto .oms-delivery-method-badge {
  background: rgba(22, 163, 74, 0.16);
}

.oms-delivery-method.planned .oms-delivery-method-badge {
  background: rgba(37, 99, 235, 0.14);
}

.oms-delivery-method.manual .oms-delivery-method-badge {
  background: rgba(185, 28, 28, 0.12);
}

.oms-delivery-method.warn {
  border-color: #fbbf24;
}

.oms-delivery-method.warn .oms-delivery-method-badge {
  background: #fef3c7;
  color: #92400e;
}

.oms-batch-method-notice {
  display: grid;
  gap: 4px;
  margin: -3px 0 12px;
  border: 1px solid #4b5563;
  border-radius: 8px;
  background: #252a31;
  padding: 10px 12px;
  color: #d1d5db;
  font-size: 13px;
}

.oms-batch-method-notice strong {
  color: #f8fafc;
  font-size: 14px;
}

.oms-batch-method-notice small {
  color: #9ca3af;
  font-size: 12px;
}

.oms-batch-method-notice.success {
  border-color: #22c55e;
  background: rgba(22, 101, 52, 0.24);
}

.oms-batch-method-notice.warning {
  border-color: #f59e0b;
  background: rgba(146, 64, 14, 0.2);
}

.oms-batch-method-notice.planned {
  border-color: #60a5fa;
  background: rgba(30, 64, 175, 0.22);
}

.oms-batch-method-notice.manual {
  border-color: #f87171;
  background: rgba(127, 29, 29, 0.22);
}

.oms-batch-delivery-status {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 12px;
  border-radius: 8px;
  background: #eff6ff;
  color: #1d4ed8;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 800;
}

.oms-batch-delivery-status.success {
  background: #ecfdf5;
  color: #047857;
}

.oms-batch-delivery-status.compact {
  min-height: 38px;
  padding: 8px 10px;
}

.oms-batch-delivery-status.compact strong {
  font-size: 13px;
  font-weight: 950;
}

.oms-batch-delivery-status.compact span,
.oms-batch-delivery-status.compact small {
  color: inherit;
  font-size: 12px;
  font-weight: 800;
}

.oms-batch-delivery-status.error {
  background: #fef2f2;
  color: #b91c1c;
}

.oms-batch-delivery-hint {
  flex-basis: 100%;
  color: #6b7280;
  font-size: 12px;
  font-weight: 700;
}

.oms-batch-delivery-hint.error {
  color: #b91c1c;
}

.oms-batch-inline-action {
  min-height: 26px;
  margin-left: 8px;
  border: 1px solid rgba(4, 120, 87, 0.25);
  border-radius: 7px;
  background: white;
  padding: 0 9px;
  color: #047857;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.oms-batch-inline-action:hover {
  background: #f0fdf4;
}

.oms-batch-label-button,
.oms-batch-print-button {
  min-height: 28px;
  border: 1px solid rgba(4, 120, 87, 0.25);
  border-radius: 7px;
  background: white;
  padding: 0 10px;
  color: #047857;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.oms-batch-label-button:hover,
.oms-batch-print-button:hover {
  background: #f0fdf4;
}

.oms-batch-product-list {
  flex: 1 1 auto;
  min-height: 0;
  margin-top: 0;
  overflow-y: auto;
  padding-bottom: 16px;
}

.oms-batch-diagnostics {
  flex: 0 0 auto;
  margin-top: 8px;
  border-top: 1px solid rgba(148, 163, 184, 0.22);
  padding-top: 8px;
  color: #94a3b8;
  font-size: 12px;
  font-weight: 800;
}

.oms-batch-diagnostics summary {
  width: fit-content;
  cursor: pointer;
  color: #94a3b8;
}

.oms-batch-diagnostics-body {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.oms-batch-diagnostics-line {
  color: #cbd5e1;
}

.oms-batch-diagnostics .oms-batch-print-status {
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 8px;
  padding: 8px 10px;
}

.oms-batch-diagnostics .oms-batch-warehouse-reservation,
.oms-batch-diagnostics .oms-delivery-methods-legend,
.oms-batch-diagnostics .oms-batch-method-notice {
  margin: 0;
}

.oms-batch-product-row {
  display: grid;
  min-height: 78px;
  grid-template-columns: 70px minmax(0, 1fr) 282px 72px;
  align-items: center;
  gap: 14px;
  border-bottom: 2px solid rgba(148, 163, 184, 0.28);
  padding: 8px 20px;
}

.oms-batch-product-row.complete {
  background: rgba(34, 197, 94, 0.06);
}

.oms-batch-product-row.saving {
  opacity: 0.74;
}

.oms-batch-product-thumb {
  display: inline-flex;
  width: 58px;
  height: 58px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 4px;
  background: #f8fafc;
  color: #94a3b8;
  font-size: 28px;
}

.oms-batch-product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.oms-batch-product-main {
  min-width: 0;
}

.oms-batch-product-name-line {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
}

.oms-batch-product-name {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  color: #f3f4f6;
  font-size: 26px;
  font-weight: 560;
  line-height: 1.12;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-batch-size-pill {
  flex: 0 0 auto;
  border: 1px solid rgba(250, 204, 21, 0.62);
  border-radius: 6px;
  background: rgba(250, 204, 21, 0.12);
  padding: 4px 10px;
  color: #fde68a;
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.oms-batch-product-meta {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
  margin-top: 5px;
  color: #60a5fa;
  font-size: 16px;
  font-weight: 500;
  white-space: nowrap;
}

.oms-batch-product-meta > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.oms-batch-allegro-link {
  flex: 0 0 auto;
  color: #93c5fd;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

/* Skład pozycji: co zejdzie z magazynu. Ten sam blok leci na jasnej karcie
   zamówienia i na ciemnej liście pakowania, więc kolory nadpisujemy niżej. */
.oms-line-components {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.3;
}

.oms-line-components:empty {
  display: none;
}

.oms-line-components-label {
  font-weight: 700;
  color: var(--oms-slate-500, #64748b);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.oms-line-components-muted {
  color: var(--oms-slate-400, #94a3b8);
}

.oms-line-component {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  padding: 2px 8px;
  border: 1px solid var(--oms-slate-200, #e2e8f0);
  border-radius: 999px;
  background: var(--oms-slate-50, #f8fafc);
  color: var(--oms-slate-700, #334155);
  font-weight: 600;
  white-space: nowrap;
}

.oms-line-component > em {
  font-style: normal;
  font-weight: 500;
  color: var(--oms-slate-500, #64748b);
}

.oms-line-component.short {
  border-color: #fca5a5;
  background: #fef2f2;
  color: #b91c1c;
}

.oms-line-component.short > em {
  color: #dc2626;
}

/* Miejsce na regale. Wyrozniamy je mocniej niz sklad, bo przy pakowaniu to jest
   pierwsza informacja, ktorej szuka oko: dokad isc po towar. */
.oms-line-location {
  display: inline-flex;
  align-items: center;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  padding: 2px 9px;
  color: #1d4ed8;
  font-weight: 850;
  white-space: nowrap;
}

.oms-batch-product-main .oms-line-location {
  border-color: rgba(147, 197, 253, 0.5);
  background: rgba(37, 99, 235, 0.22);
  color: #dbeafe;
}

.oms-batch-product-main .oms-line-components {
  font-size: 14px;
}

.oms-batch-product-main .oms-line-components-label,
.oms-batch-product-main .oms-line-components-muted {
  color: #94a3b8;
}

.oms-batch-product-main .oms-line-component {
  border-color: rgba(148, 163, 184, 0.35);
  background: rgba(148, 163, 184, 0.12);
  color: #e2e8f0;
}

.oms-batch-product-main .oms-line-component > em {
  color: #94a3b8;
}

.oms-batch-product-main .oms-line-component.short {
  border-color: rgba(248, 113, 113, 0.6);
  background: rgba(248, 113, 113, 0.16);
  color: #fecaca;
}

.oms-batch-product-main .oms-line-component.short > em {
  color: #fca5a5;
}

.oms-batch-allegro-link:hover {
  color: #bfdbfe;
  text-decoration: underline;
}

.oms-batch-product-controls {
  display: grid;
  height: 58px;
  grid-template-columns: 52px minmax(100px, 1fr) 52px;
  overflow: hidden;
  border: 2px solid #8b93a1;
  border-radius: 6px;
}

.oms-batch-product-controls button,
.oms-batch-product-done {
  border: 0;
  background: rgba(31, 41, 55, 0.72);
  color: #e5e7eb;
  font-size: 29px;
  cursor: pointer;
}

.oms-batch-product-controls button:hover,
.oms-batch-product-done:hover {
  background: rgba(255, 255, 255, 0.08);
}

.oms-batch-product-controls span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-inline: 2px solid #8b93a1;
  color: white;
  font-size: 18px;
  font-weight: 900;
}

.oms-batch-product-done {
  width: 68px;
  height: 58px;
  border: 2px solid #8b93a1;
  border-radius: 6px;
  background: rgba(31, 41, 55, 0.72);
  color: #86efac;
  font-size: 30px;
}

.oms-batch-product-done.done {
  border-color: #4ade80;
  background: rgba(34, 197, 94, 0.16);
  color: #bbf7d0;
}

.oms-batch-empty {
  padding: 24px;
  color: #cbd5e1;
  font-size: 16px;
}

.oms-batch-pack-footer {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.28);
  padding: 0 20px;
}

.oms-batch-footer-left,
.oms-batch-footer-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.oms-batch-footer-right {
  justify-content: flex-end;
}

.oms-batch-footer-left button,
.oms-size-switch,
.oms-footer-secondary,
.oms-footer-success {
  display: inline-flex;
  height: 54px;
  align-items: center;
  justify-content: center;
  border: 2px solid #5b6472;
  border-radius: 999px;
  background: rgba(31, 41, 55, 0.78);
  color: #e5e7eb;
  font-size: 16px;
  font-weight: 850;
  cursor: pointer;
}

.oms-batch-footer-left button {
  width: 54px;
  color: #cbd5e1;
  font-size: 24px;
}

.oms-size-switch {
  min-width: 142px;
  padding: 0 22px;
}

.oms-footer-secondary {
  min-width: 188px;
  padding: 0 24px;
}

.oms-footer-success {
  min-width: 180px;
  border-color: #48975d;
  background: #48975d;
  padding: 0 28px;
  color: white;
}

.oms-batch-footer-left button:hover:not(:disabled),
.oms-size-switch:hover,
.oms-footer-secondary:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.08);
}

.oms-footer-success:hover:not(:disabled) {
  background: #3f8f55;
}

.oms-batch-footer-left button:disabled,
.oms-footer-secondary:disabled,
.oms-footer-success:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.oms-address-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.oms-address-body {
  padding: 14px 16px;
}

.oms-address-edit {
  display: grid;
  gap: 12px;
}

.oms-address-current {
  border-bottom: 1px solid var(--oms-slate-100);
  padding-bottom: 10px;
}

.oms-address-edit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.oms-inline-edit-details {
  border-top: 1px solid var(--oms-slate-100);
  padding-top: 8px;
}

.oms-inline-edit-details summary {
  cursor: pointer;
  color: var(--oms-blue-700);
  font-size: 12px;
  font-weight: 900;
}

.oms-inline-edit-details[open] summary {
  margin-bottom: 10px;
}

.oms-inline-edit-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
}

.oms-addr-edit-field.wide {
  grid-column: 1 / -1;
}

.oms-addr-row {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 8px;
  padding: 4px 0;
  font-size: 13.5px;
}

.oms-addr-label {
  color: var(--oms-slate-500);
}

.oms-addr-value {
  min-width: 0;
  color: var(--oms-slate-950);
  font-weight: 700;
}

.oms-addr-inline-row {
  align-items: center;
}

.oms-inline-edit-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.oms-btn-light.compact {
  min-height: 34px;
  padding: 6px 10px;
  font-size: 12px;
}

.oms-shipping-card {
  padding: 18px;
}

.oms-shipping-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 15px;
  font-weight: 800;
}

.oms-shipping-title::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--oms-blue-600);
}

.oms-ship-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.oms-ship-btn {
  min-height: 32px;
  border: 1px solid var(--oms-blue-500);
  border-radius: 8px;
  background: white;
  padding: 7px 14px;
  color: var(--oms-blue-600);
  font-size: 13.5px;
  font-weight: 700;
}

.oms-shipping-note {
  color: var(--oms-slate-500);
  font-size: 13.5px;
  line-height: 1.45;
}

.oms-shipping-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
}

.oms-shipping-head > div {
  min-width: 0;
}

.oms-shipping-head .oms-btn-light {
  flex: 0 0 auto;
  white-space: nowrap;
}

.oms-shipping-diagnostics {
  margin-top: 14px;
  border: 1px dashed var(--oms-slate-200);
  border-radius: 8px;
  background: #fbfdff;
}

.oms-shipping-diagnostics summary {
  cursor: pointer;
  padding: 10px 12px;
  color: var(--oms-slate-600);
  font-size: 12.5px;
  font-weight: 900;
  list-style-position: inside;
}

.oms-shipping-diagnostics-body {
  border-top: 1px solid var(--oms-slate-100);
  padding: 0 12px 12px;
}

.oms-shipping-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
}

.oms-shipment-history {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.oms-shipment-next-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 14px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #f8fafc;
  padding: 12px 14px;
}

.oms-shipment-next-action.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-shipment-next-action.wait {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-shipment-next-action.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-shipment-next-action strong {
  display: block;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
}

.oms-shipment-next-action span {
  display: block;
  margin-top: 3px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.35;
}

.oms-shipment-next-pill {
  flex: 0 0 auto;
  margin-top: 0 !important;
  border-radius: 999px;
  background: #ffffff;
  padding: 5px 9px;
  color: var(--oms-slate-700) !important;
  font-size: 11px !important;
  font-weight: 950 !important;
}

.oms-shipment-history-empty {
  margin-top: 14px;
  border: 1px dashed var(--oms-slate-200);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--oms-slate-500);
  font-size: 13px;
  font-weight: 750;
}

.oms-shipment-history-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
  padding: 8px;
}

.oms-shipment-history-summary-chip {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  background: var(--oms-slate-100);
  padding: 4px 9px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 850;
}

.oms-shipment-history-summary-chip strong {
  color: var(--oms-slate-950);
  font-weight: 950;
}

.oms-shipment-history-summary-chip.active,
.oms-shipment-history-summary-chip.label,
.oms-shipment-history-summary-chip.printed {
  background: #dcfce7;
  color: #166534;
}

.oms-shipment-history-summary-chip.active strong,
.oms-shipment-history-summary-chip.label strong,
.oms-shipment-history-summary-chip.printed strong {
  color: #14532d;
}

.oms-shipment-history-summary-chip.cancelled {
  background: #fee2e2;
  color: #991b1b;
}

.oms-shipment-history-summary-chip.cancelled strong {
  color: #7f1d1d;
}

.oms-shipment-history.compact {
  gap: 10px;
}

.oms-shipment-table {
  overflow-x: auto;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.oms-shipment-table-head,
.oms-shipment-table-row {
  display: grid;
  grid-template-columns:
    minmax(118px, 0.85fr)
    minmax(150px, 1fr)
    minmax(130px, 0.95fr)
    minmax(190px, 1.25fr)
    minmax(230px, 1.35fr)
    minmax(250px, max-content);
  align-items: center;
  gap: 14px;
  min-width: 1030px;
}

.oms-shipment-table-head {
  border-bottom: 1px solid var(--oms-slate-200);
  padding: 12px 14px;
  color: var(--oms-slate-700);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.oms-shipment-table-row {
  min-height: 66px;
  padding: 12px 14px;
}

.oms-shipment-table-row + .oms-shipment-table-row {
  border-top: 1px solid var(--oms-slate-100);
}

.oms-shipment-table-row.active {
  background: #ffffff;
}

.oms-shipment-table-row.cancelled {
  background: #f8fafc;
  opacity: 0.72;
}

.oms-shipment-date,
.oms-shipment-account {
  color: var(--oms-slate-600);
  font-size: 13px;
  font-weight: 750;
}

.oms-shipment-carrier {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.oms-shipment-carrier strong {
  overflow: hidden;
  color: var(--oms-blue-600);
  font-size: 13px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-shipment-carrier span {
  overflow: hidden;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-shipment-number-row {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  gap: 7px;
}

.oms-shipment-number-link,
.oms-shipment-number-text {
  min-width: 0;
  max-width: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--oms-blue-600);
  font-size: 13px;
  font-weight: 850;
  overflow-wrap: anywhere;
  text-align: left;
}

.oms-shipment-number-link {
  text-decoration: none;
}

.oms-shipment-number-link:hover {
  color: var(--oms-blue-700);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.oms-shipment-copy-btn {
  flex: 0 0 auto;
  min-height: 28px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
  padding: 0 8px;
  color: var(--oms-slate-600);
  cursor: pointer;
  font-size: 11px;
  font-weight: 900;
}

.oms-shipment-copy-btn:hover {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: var(--oms-blue-700);
}

.oms-shipment-status-cell {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: center;
  gap: 3px 10px;
  min-width: 0;
}

.oms-shipment-status-cell strong {
  overflow: hidden;
  color: var(--oms-slate-700);
  font-size: 13px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-shipment-status-cell small {
  grid-column: 2;
  overflow: hidden;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-shipment-progress {
  display: block;
  width: 92px;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--oms-slate-100);
}

.oms-shipment-progress i {
  display: block;
  width: 22px;
  height: 100%;
  border-radius: inherit;
  background: var(--oms-blue-600);
}

.oms-shipment-progress.waiting i {
  width: 35%;
  background: #f59e0b;
}

.oms-shipment-progress.ordered i {
  width: 65%;
  background: var(--oms-blue-600);
}

.oms-shipment-progress.ready i,
.oms-shipment-progress.printed i {
  width: 100%;
  background: var(--oms-green-500);
}

.oms-shipment-progress.failed i,
.oms-shipment-progress.cancelled i {
  width: 100%;
  background: var(--oms-red-500);
}

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

.oms-shipment-row-actions .oms-btn-light.compact {
  min-height: 32px;
  white-space: nowrap;
}

.oms-shipment-history-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #f8fafc;
  padding: 10px 12px;
}

.oms-shipment-history-row.active {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-shipment-history-row.cancelled {
  border-color: var(--oms-slate-200);
  background: #ffffff;
  opacity: 0.72;
}

.oms-shipment-history-title {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--oms-slate-900);
  font-size: 13px;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.oms-shipment-current-pill {
  flex: 0 0 auto;
  border-radius: 999px;
  background: #dbeafe;
  padding: 3px 8px;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 900;
}

.oms-shipment-history-meta,
.oms-shipment-history-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.oms-shipment-history-meta {
  margin-top: 5px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
}

.oms-shipment-status-chip,
.oms-shipment-label-chip,
.oms-shipment-print-chip {
  border-radius: 999px;
  padding: 3px 8px;
  background: var(--oms-slate-100);
  color: var(--oms-slate-600);
}

.oms-shipment-status-chip.ready,
.oms-shipment-status-chip.ordered,
.oms-shipment-label-chip.ready {
  background: #dcfce7;
  color: #166534;
}

.oms-shipment-status-chip.waiting {
  background: #fef3c7;
  color: #92400e;
}

.oms-shipment-status-chip.cancelled,
.oms-shipment-label-chip.cancelled {
  background: #fee2e2;
  color: #991b1b;
}

.oms-shipment-print-chip.printed {
  background: #dcfce7;
  color: #166534;
}

.oms-shipment-print-chip.queued {
  background: #dbeafe;
  color: #1d4ed8;
}

.oms-shipment-print-chip.reserved {
  background: #fef3c7;
  color: #92400e;
}

.oms-shipment-print-chip.failed {
  background: #fee2e2;
  color: #991b1b;
}

.oms-shipment-history-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px dashed var(--oms-slate-300);
  border-radius: 8px;
  background: #ffffff;
  padding: 10px 12px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
}

.oms-shipment-history-toggle {
  min-height: 34px;
  border: 1px solid var(--oms-slate-300);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 0 12px;
  color: var(--oms-blue);
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.oms-shipment-history-toggle:hover {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-shipping-step {
  display: flex;
  min-height: 34px;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 8px 10px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.oms-shipping-step-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  border-radius: 50%;
  background: var(--oms-slate-300);
}

.oms-shipping-step.done {
  border-color: #bbf7d0;
  background: var(--oms-green-50);
  color: var(--oms-green-600);
}

.oms-shipping-step.done .oms-shipping-step-dot {
  background: var(--oms-green-600);
}

.oms-shipping-step.current {
  border-color: #bfdbfe;
  background: var(--oms-blue-50);
  color: var(--oms-blue-700);
}

.oms-shipping-step.current .oms-shipping-step-dot {
  background: var(--oms-blue-600);
}

.oms-shipping-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  margin-top: 14px;
}

.oms-shipping-meta {
  display: grid;
  gap: 7px;
}

.oms-shipping-meta-row {
  display: flex;
  min-height: 28px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--oms-slate-100);
  font-size: 13px;
}

.oms-shipping-meta-row span {
  color: var(--oms-slate-500);
}

.oms-shipping-meta-row strong {
  color: var(--oms-slate-950);
  font-weight: 800;
  text-align: right;
}

.oms-shipping-actions {
  display: flex;
  min-width: 220px;
  flex-direction: column;
  align-items: stretch;
  gap: 9px;
}

.oms-shipping-approval {
  display: flex;
  min-height: 32px;
  align-items: center;
  gap: 8px;
  color: var(--oms-slate-700);
  font-size: 13px;
  font-weight: 700;
}

.oms-shipping-alert,
.oms-shipping-success,
.oms-shipping-idempotency {
  margin-top: 12px;
  border-radius: 6px;
  padding: 9px 10px;
  font-size: 13px;
  font-weight: 700;
}

.oms-shipping-alert {
  background: #fff7ed;
  color: #9a3412;
}

.oms-shipping-alert.error {
  background: #fef2f2;
  color: #b91c1c;
}

.oms-shipping-success {
  background: #ecfdf5;
  color: #047857;
}

.oms-shipping-idempotency {
  background: var(--oms-slate-50);
  color: var(--oms-slate-700);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.oms-shipping-payload {
  max-height: 260px;
  margin: 12px 0 0;
  overflow: auto;
  border: 1px solid var(--oms-slate-200);
  border-radius: 6px;
  background: var(--oms-slate-950);
  padding: 12px;
  color: white;
  font-size: 12px;
  line-height: 1.45;
}

.oms-order-technical-panel {
  margin-bottom: 16px;
  border: 1px dashed var(--oms-slate-300);
  border-radius: 8px;
  background: #ffffff;
}

.oms-order-technical-panel summary {
  cursor: pointer;
  padding: 11px 14px;
  color: var(--oms-slate-600);
  font-size: 12.5px;
  font-weight: 950;
  list-style-position: inside;
}

.oms-order-technical-body {
  border-top: 1px solid var(--oms-slate-100);
  padding: 14px;
}

.oms-order-technical-body .oms-card {
  margin-bottom: 0;
  box-shadow: none;
}

.oms-order-technical-empty {
  color: var(--oms-slate-500);
  font-size: 13px;
  font-weight: 800;
}

.oms-operator-diagnostics {
  margin-top: 16px;
  border: 1px dashed var(--oms-slate-300);
  border-radius: 8px;
  background: #ffffff;
}

.oms-operator-diagnostics > summary {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 12px 14px;
  color: var(--oms-slate-700);
  font-size: 13px;
  font-weight: 950;
  list-style-position: inside;
}

.oms-operator-diagnostics > summary small {
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 800;
}

.oms-operator-diagnostics-body {
  display: grid;
  gap: 12px;
  border-top: 1px solid var(--oms-slate-100);
  padding: 12px;
}

.oms-order-activity {
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
}

.oms-order-activity summary {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 11px 12px;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
  list-style-position: inside;
}

.oms-order-activity summary span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-activity summary .oms-btn-light {
  flex: 0 0 auto;
  white-space: nowrap;
}

.oms-order-activity-list {
  display: grid;
  gap: 8px;
  border-top: 1px solid var(--oms-slate-100);
  padding: 10px;
}

.oms-order-activity-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 9px 10px;
}

.oms-order-activity-row.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-order-activity-row.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-activity-row.wait {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-order-activity-row strong,
.oms-order-activity-row span {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-activity-row strong {
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-activity-row span {
  margin-top: 3px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-order-activity-row em {
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.oms-order-activity-empty {
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 10px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
}

.oms-order-email-preview {
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
}

.oms-detail-email-preview {
  margin-top: 18px;
}

.oms-order-email-preview summary {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 11px 12px;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
  list-style-position: inside;
}

.oms-order-email-preview summary span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-email-preview-safety {
  display: grid;
  gap: 3px;
  border-top: 1px solid var(--oms-slate-100);
  background: #f8fafc;
  padding: 10px 12px;
}

.oms-order-email-preview-safety strong {
  color: #166534;
  font-size: 12px;
  font-weight: 950;
}

.oms-order-email-preview-safety span,
.oms-order-email-preview-foot {
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 780;
  line-height: 1.35;
}

.oms-order-email-preview-list {
  display: grid;
  gap: 8px;
  border-top: 1px solid var(--oms-slate-100);
  padding: 10px;
}

.oms-order-email-preview-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 9px 10px;
}

.oms-order-email-preview-row.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-order-email-preview-row.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-email-preview-row.wait {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-order-email-preview-row.simulation {
  border-style: dashed;
}

.oms-order-email-preview-row strong,
.oms-order-email-preview-row span,
.oms-order-email-preview-row small,
.oms-order-email-preview-row em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-email-preview-row strong {
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-email-preview-row strong b {
  display: inline-flex;
  margin-left: 6px;
  border-radius: 999px;
  background: #ede9fe;
  padding: 2px 6px;
  color: #5b21b6;
  font-size: 10px;
  font-style: normal;
  font-weight: 950;
  text-transform: uppercase;
}

.oms-order-email-preview-row span {
  margin-top: 3px;
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 820;
}

.oms-order-email-preview-row small,
.oms-order-email-preview-row em {
  margin-top: 3px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 760;
  line-height: 1.35;
}

.oms-order-email-attachments {
  display: grid;
  gap: 6px;
  margin-top: 8px;
}

.oms-order-email-attachments-title {
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.oms-order-email-attachment {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  border: 1px solid #bfdbfe;
  border-radius: 10px;
  background: #eff6ff;
  padding: 8px 9px;
}

.oms-order-email-attachment.invoice {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-order-email-attachment strong,
.oms-order-email-attachment small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-email-attachment strong {
  color: #14532d;
  font-size: 12px;
  font-weight: 950;
}

.oms-order-email-attachment small {
  margin-top: 2px;
  color: #166534;
  font-size: 11px;
  font-weight: 760;
}

.oms-order-email-attachment > span {
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.16);
  padding: 4px 8px;
  color: #166534;
  font-size: 10.5px;
  font-weight: 950;
  white-space: nowrap;
}

.oms-order-email-attachment-warning {
  border: 1px solid #fed7aa;
  border-radius: 10px;
  background: #fff7ed;
  padding: 8px 9px;
  color: #9a3412;
  font-size: 11.5px;
  font-weight: 880;
  line-height: 1.35;
}

.oms-order-email-preview-row code {
  border-radius: 6px;
  background: #e2e8f0;
  padding: 4px 6px;
  color: var(--oms-slate-700);
  font-size: 10.5px;
  font-weight: 850;
  white-space: nowrap;
}

.oms-order-email-preview-row details {
  margin-top: 8px;
}

.oms-order-email-preview-row details summary {
  cursor: pointer;
  color: #2563eb;
  font-size: 12px;
  font-weight: 850;
}

.oms-order-email-preview-row pre {
  margin: 8px 0 0;
  max-height: 220px;
  overflow: auto;
  white-space: pre-wrap;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 10px;
  background: #f8fafc;
  color: #334155;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  line-height: 1.45;
  padding: 10px 12px;
}

.oms-email-html-preview iframe {
  display: block;
  width: 100%;
  min-height: 360px;
  margin-top: 8px;
  border: 1px solid rgba(148, 163, 184, 0.45);
  border-radius: 10px;
  background: #ffffff;
}

.oms-order-email-preview-empty {
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 10px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
}

.oms-order-email-preview-foot {
  border-top: 1px solid var(--oms-slate-100);
  padding: 0 10px 10px;
}

.oms-order-email-outbox {
  display: grid;
  gap: 8px;
  border-top: 1px solid var(--oms-slate-100);
  padding: 10px;
}

.oms-order-email-outbox-head {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background: #f8fbff;
  padding: 10px;
}

.oms-order-email-outbox-head strong,
.oms-order-email-outbox-head span {
  display: block;
}

.oms-order-email-outbox-head strong {
  color: #172554;
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-email-outbox-head span,
.oms-order-email-outbox-head small {
  color: #64748b;
  font-size: 11.5px;
  font-weight: 800;
}

.oms-order-email-outbox-list {
  display: grid;
  gap: 8px;
}

.oms-order-email-outbox-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: #ffffff;
  padding: 10px;
}

.oms-order-email-outbox-row.failed,
.oms-order-email-outbox-row.preview_blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-email-outbox-row.retry_preview,
.oms-order-email-outbox-row.internal_test {
  border-color: #ddd6fe;
  background: #faf5ff;
}

.oms-order-email-outbox-main {
  min-width: 0;
}

.oms-order-email-outbox-main strong {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-email-outbox-main strong b {
  border-radius: 999px;
  background: #fee2e2;
  padding: 2px 7px;
  color: #991b1b;
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.oms-order-email-outbox-main em,
.oms-order-email-outbox-main small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-email-outbox-main em {
  margin-top: 3px;
  color: var(--oms-slate-700);
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.oms-order-email-outbox-main small {
  margin-top: 3px;
  color: var(--oms-slate-500);
  font-size: 11.3px;
  font-weight: 760;
  line-height: 1.35;
}

.oms-order-email-outbox-error {
  margin-top: 7px;
  border: 1px solid #fecaca;
  border-radius: 8px;
  background: #fef2f2;
  padding: 7px 8px;
  color: #991b1b;
  font-size: 11.5px;
  font-weight: 850;
  line-height: 1.35;
}

.oms-order-email-outbox-events {
  display: grid;
  gap: 5px;
  margin-top: 8px;
}

.oms-order-email-outbox-event {
  border-left: 2px solid #bfdbfe;
  padding-left: 8px;
}

.oms-order-email-outbox-event span,
.oms-order-email-outbox-event small,
.oms-order-email-outbox-event em {
  display: block;
  overflow-wrap: anywhere;
}

.oms-order-email-outbox-event span {
  color: #1d4ed8;
  font-size: 11.5px;
  font-weight: 950;
}

.oms-order-email-outbox-event small,
.oms-order-email-outbox-event em,
.oms-order-email-outbox-empty {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-style: normal;
  font-weight: 760;
  line-height: 1.35;
}

.oms-order-email-outbox-side {
  display: grid;
  justify-items: end;
  gap: 7px;
}

.oms-order-email-outbox-side code {
  border-radius: 999px;
  background: #e2e8f0;
  padding: 4px 8px;
  color: var(--oms-slate-700);
  font-size: 10.5px;
  font-weight: 900;
}

.oms-order-email-simulation {
  display: grid;
  gap: 10px;
  border-top: 1px solid var(--oms-slate-100);
  padding: 10px;
}

.oms-order-email-simulation-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  border: 1px solid #ddd6fe;
  border-radius: 10px;
  background: #faf5ff;
  padding: 10px;
}

.oms-order-email-simulation-head strong,
.oms-order-email-simulation-head span {
  display: block;
}

.oms-order-email-simulation-head strong {
  color: #4c1d95;
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-email-simulation-head span {
  margin-top: 3px;
  color: #6d28d9;
  font-size: 11.5px;
  font-weight: 780;
  line-height: 1.35;
}

.oms-order-email-simulation-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.oms-mini-action {
  border: 1px solid var(--oms-slate-200);
  border-radius: 999px;
  background: #ffffff;
  padding: 5px 9px;
  color: var(--oms-slate-700);
  font-size: 11px;
  font-weight: 900;
  cursor: pointer;
}

.oms-mini-action:hover:not(:disabled),
.oms-mini-action.active {
  border-color: #7c3aed;
  background: #7c3aed;
  color: #ffffff;
}

.oms-mini-action:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.oms-order-email-simulation-group {
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: #ffffff;
  overflow: hidden;
}

.oms-order-email-simulation-group > summary {
  display: flex;
  justify-content: space-between;
  cursor: pointer;
  border-bottom: 1px solid var(--oms-slate-100);
  padding: 9px 10px;
  color: var(--oms-slate-950);
  font-size: 12px;
  font-weight: 950;
}

.oms-order-email-simulation-group > summary span {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 850;
}

.oms-order-business-timeline {
  margin-bottom: 10px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
}

.oms-order-business-timeline summary {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 11px 12px;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
  list-style-position: inside;
}

.oms-order-business-timeline summary span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-business-timeline summary .oms-btn-light {
  flex: 0 0 auto;
  white-space: nowrap;
}

.oms-order-business-timeline-list {
  display: grid;
  gap: 8px;
  border-top: 1px solid var(--oms-slate-100);
  padding: 10px;
}

.oms-order-business-timeline-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 9px 10px;
}

.oms-order-business-timeline-row.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-order-business-timeline-row.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-business-timeline-row.wait {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-order-business-timeline-row strong,
.oms-order-business-timeline-row span,
.oms-order-business-timeline-row small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-business-timeline-row strong {
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-business-timeline-row span {
  margin-top: 3px;
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 850;
}

.oms-order-business-timeline-row small {
  margin-top: 2px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-order-business-timeline-row em {
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.oms-order-status-actions {
  margin-bottom: 10px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
}

.oms-order-status-actions summary {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 11px 12px;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
  list-style-position: inside;
}

.oms-order-status-actions summary span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-actions summary .oms-btn-light {
  flex: 0 0 auto;
  white-space: nowrap;
}

.oms-order-status-actions summary small {
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--oms-slate-100);
  padding: 3px 8px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.oms-order-status-actions-current {
  display: grid;
  gap: 3px;
  border-top: 1px solid var(--oms-slate-100);
  padding: 10px 12px 0;
}

.oms-order-status-actions-current strong,
.oms-order-status-actions-current span {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-actions-current strong {
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-status-actions-current span {
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-order-status-actions-list {
  display: grid;
  gap: 8px;
  padding: 10px;
}

.oms-order-status-action-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 9px 10px;
}

.oms-order-status-action-row.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-order-status-action-row.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-status-action-row.wait {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-order-status-action-row strong,
.oms-order-status-action-row span,
.oms-order-status-action-row small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-action-row strong {
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-status-action-row span {
  margin-top: 3px;
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 850;
}

.oms-order-status-action-row small {
  margin-top: 2px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-order-status-action-row em {
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.oms-order-status-overrides {
  margin-bottom: 10px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
}

.oms-order-status-overrides summary {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 11px 12px;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
  list-style-position: inside;
}

.oms-order-status-overrides summary span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-overrides summary small {
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--oms-slate-100);
  padding: 3px 8px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.oms-order-status-overrides summary .oms-btn-light {
  flex: 0 0 auto;
  white-space: nowrap;
}

.oms-order-status-overrides-list {
  display: grid;
  gap: 8px;
  border-top: 1px solid var(--oms-slate-100);
  padding: 10px;
}

.oms-order-status-override-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 9px 10px;
}

.oms-order-status-override-row.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-order-status-override-row.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-status-override-row.wait {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-order-status-override-row strong,
.oms-order-status-override-row span,
.oms-order-status-override-row small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-override-row strong {
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-status-override-row span {
  margin-top: 3px;
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 850;
}

.oms-order-status-override-row small {
  margin-top: 2px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-order-status-override-row em {
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.oms-order-status-overrides-empty {
  border: 1px dashed var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 10px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
}

.oms-order-status-action-tools {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: flex-end;
}

.oms-order-status-action-tools .oms-btn-light {
  min-height: 28px;
  padding: 4px 9px;
  font-size: 11px;
  font-weight: 900;
}

.oms-order-status-preflight {
  display: grid;
  gap: 10px;
  margin: 0 10px 10px;
  border: 1px solid #fde68a;
  border-radius: 8px;
  background: #fffbeb;
  padding: 10px;
}

.oms-order-status-preflight.wait {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-order-status-preflight.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-status-preflight-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.oms-order-status-preflight-head strong,
.oms-order-status-preflight-head span,
.oms-order-status-preflight-head em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-preflight-head strong {
  color: var(--oms-slate-950);
  font-size: 12.5px;
  font-weight: 950;
}

.oms-order-status-preflight-head span {
  margin-top: 3px;
  color: var(--oms-slate-600);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-order-status-preflight-head em {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  padding: 3px 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
  white-space: nowrap;
}

.oms-order-status-preflight-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 8px;
}

.oms-order-status-preflight-list span {
  display: grid;
  gap: 3px;
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  padding: 8px;
}

.oms-order-status-preflight-list span.pass {
  border-color: #bbf7d0;
}

.oms-order-status-preflight-list span.fail {
  border-color: #fecaca;
}

.oms-order-status-preflight-list strong,
.oms-order-status-preflight-list em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-preflight-list strong {
  color: var(--oms-slate-950);
  font-size: 11.5px;
  font-weight: 930;
}

.oms-order-status-preflight-list em {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-style: normal;
  font-weight: 760;
}

.oms-order-status-command-draft {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(148, 163, 184, 0.42);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 9px;
}

.oms-order-status-command-draft-head {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  justify-content: space-between;
}

.oms-order-status-command-draft-head strong,
.oms-order-status-command-draft-head em {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-command-draft-head strong {
  color: var(--oms-slate-950);
  font-size: 12px;
  font-weight: 950;
}

.oms-order-status-command-draft-head em {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.oms-order-status-command-draft-meta,
.oms-order-status-command-draft-plan {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  gap: 6px;
}

.oms-order-status-command-draft-meta span,
.oms-order-status-command-draft-plan span {
  min-width: 0;
  border-radius: 6px;
  background: rgba(248, 250, 252, 0.88);
  padding: 5px 7px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 780;
  overflow-wrap: anywhere;
}

.oms-order-status-command-draft-meta strong {
  display: block;
  margin-bottom: 2px;
  color: var(--oms-slate-950);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.oms-order-status-execution-readiness {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(148, 163, 184, 0.42);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.82);
  padding: 9px;
}

.oms-order-status-execution-readiness.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-order-status-execution-readiness.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-status-execution-readiness-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.oms-order-status-execution-readiness-head strong,
.oms-order-status-execution-readiness-head span,
.oms-order-status-execution-readiness-head em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-execution-readiness-head strong {
  color: var(--oms-slate-950);
  font-size: 12px;
  font-weight: 950;
}

.oms-order-status-execution-readiness-head span {
  margin-top: 3px;
  color: var(--oms-slate-600);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-order-status-execution-readiness-head em {
  border-radius: 999px;
  background: #ffffff;
  padding: 3px 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
  white-space: nowrap;
}

.oms-order-status-execution-readiness-meta {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  gap: 6px;
}

.oms-order-status-execution-readiness-meta span {
  min-width: 0;
  border-radius: 6px;
  background: #ffffff;
  padding: 5px 7px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 780;
  overflow-wrap: anywhere;
}

.oms-order-status-execution-readiness-meta strong {
  display: block;
  margin-bottom: 2px;
  color: var(--oms-slate-950);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.oms-order-status-execution-readiness-gates {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 8px;
}

.oms-order-status-execution-readiness-gates span {
  display: grid;
  gap: 3px;
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
  padding: 8px;
}

.oms-order-status-execution-readiness-gates span.pass {
  border-color: #bbf7d0;
}

.oms-order-status-execution-readiness-gates span.fail {
  border-color: #fecaca;
}

.oms-order-status-execution-readiness-gates strong,
.oms-order-status-execution-readiness-gates em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-execution-readiness-gates strong {
  color: var(--oms-slate-950);
  font-size: 11.5px;
  font-weight: 930;
}

.oms-order-status-execution-readiness-gates em {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-style: normal;
  font-weight: 760;
}

.oms-order-status-execution-smoke {
  display: grid;
  gap: 8px;
  border: 1px solid #fde68a;
  border-radius: 8px;
  background: #fffbeb;
  padding: 9px;
}

.oms-order-status-execution-smoke.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-status-execution-smoke-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.oms-order-status-execution-smoke-head strong,
.oms-order-status-execution-smoke-head span,
.oms-order-status-execution-smoke-head em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-execution-smoke-head strong {
  color: var(--oms-slate-950);
  font-size: 12px;
  font-weight: 950;
}

.oms-order-status-execution-smoke-head span {
  margin-top: 3px;
  color: var(--oms-slate-600);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-order-status-execution-smoke-head em {
  border-radius: 999px;
  background: #ffffff;
  padding: 3px 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
  white-space: nowrap;
}

.oms-order-status-execution-smoke-meta,
.oms-order-status-execution-smoke-required {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  gap: 6px;
}

.oms-order-status-execution-smoke-meta span,
.oms-order-status-execution-smoke-required span {
  min-width: 0;
  border-radius: 6px;
  background: #ffffff;
  padding: 5px 7px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 780;
  overflow-wrap: anywhere;
}

.oms-order-status-execution-smoke-meta strong {
  display: block;
  margin-bottom: 2px;
  color: var(--oms-slate-950);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.oms-order-status-execution-smoke-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 8px;
}

.oms-order-status-execution-smoke-steps span {
  display: grid;
  gap: 3px;
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
  padding: 8px;
}

.oms-order-status-execution-smoke-steps span.blocked {
  border-color: #fecaca;
}

.oms-order-status-execution-smoke-steps span.manual_required {
  border-color: #fde68a;
}

.oms-order-status-execution-smoke-steps strong,
.oms-order-status-execution-smoke-steps em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-execution-smoke-steps strong {
  color: var(--oms-slate-950);
  font-size: 11.5px;
  font-weight: 930;
}

.oms-order-status-execution-smoke-steps em {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-style: normal;
  font-weight: 760;
}

.oms-order-status-execution-smoke-result {
  display: grid;
  gap: 8px;
  border: 1px solid #fde68a;
  border-radius: 8px;
  background: #fffbeb;
  padding: 9px;
}

.oms-order-status-execution-smoke-result.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-order-status-execution-smoke-result.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-order-status-execution-smoke-result-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.oms-order-status-execution-smoke-result-head strong,
.oms-order-status-execution-smoke-result-head span,
.oms-order-status-execution-smoke-result-head em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-execution-smoke-result-head strong {
  color: var(--oms-slate-950);
  font-size: 12px;
  font-weight: 950;
}

.oms-order-status-execution-smoke-result-head span {
  margin-top: 3px;
  color: var(--oms-slate-600);
  font-size: 11.5px;
  font-weight: 760;
}

.oms-order-status-execution-smoke-result-head em {
  border-radius: 999px;
  background: #ffffff;
  padding: 3px 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
  white-space: nowrap;
}

.oms-order-status-execution-smoke-result-meta {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  gap: 6px;
}

.oms-order-status-execution-smoke-result-meta span {
  min-width: 0;
  border-radius: 6px;
  background: #ffffff;
  padding: 5px 7px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 780;
  overflow-wrap: anywhere;
}

.oms-order-status-execution-smoke-result-meta strong {
  display: block;
  margin-bottom: 2px;
  color: var(--oms-slate-950);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.oms-order-status-execution-smoke-result-checks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 8px;
}

.oms-order-status-execution-smoke-result-checks span {
  display: grid;
  gap: 3px;
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #ffffff;
  padding: 8px;
}

.oms-order-status-execution-smoke-result-checks span.pass {
  border-color: #bbf7d0;
}

.oms-order-status-execution-smoke-result-checks span.fail {
  border-color: #fecaca;
}

.oms-order-status-execution-smoke-result-checks span.missing {
  border-color: #fde68a;
}

.oms-order-status-execution-smoke-result-checks strong,
.oms-order-status-execution-smoke-result-checks em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-order-status-execution-smoke-result-checks strong {
  color: var(--oms-slate-950);
  font-size: 11.5px;
  font-weight: 930;
}

.oms-order-status-execution-smoke-result-checks em {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-style: normal;
  font-weight: 760;
}

.oms-bottom-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 16px;
}

.oms-round-primary {
  display: inline-flex;
  height: 38px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--oms-blue-600);
  padding: 0 18px;
  color: white;
  font-weight: 700;
}

.oms-accordion {
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  margin-bottom: 8px;
  background: white;
}

.oms-accordion-header {
  display: flex;
  justify-content: space-between;
  padding: 11px 14px;
  color: var(--oms-slate-700);
  font-size: 13.5px;
  font-weight: 700;
}

.oms-invoices-view {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  overflow-y: auto;
  background: #f5f7fa;
}

.oms-invoices-view[hidden] {
  display: none;
}

.oms-invoices-top {
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--oms-slate-200);
  background: white;
  padding: 10px 18px;
}

.oms-invoices-title {
  margin: 0;
  color: var(--oms-slate-950);
  font-size: 18px;
  font-weight: 850;
}

.oms-invoices-subtitle {
  margin: 2px 0 0;
  color: var(--oms-slate-500);
  font-size: 12px;
}

.oms-invoices-top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.oms-invoices-tabs {
  display: flex;
  gap: 20px;
  border-bottom: 1px solid var(--oms-slate-200);
  background: white;
  padding: 0 18px;
}

.oms-invoices-tabs button {
  min-height: 42px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--oms-slate-500);
  font-size: 13px;
  font-weight: 750;
}

.oms-invoices-tabs button.active {
  border-bottom-color: var(--oms-blue-600);
  color: var(--oms-slate-950);
}

.oms-invoices-filterbar {
  display: grid;
  grid-template-columns: minmax(180px, 1.1fr) minmax(180px, 1.2fr) minmax(130px, 0.7fr) minmax(110px, 0.55fr) minmax(130px, 0.7fr);
  gap: 10px;
  border-bottom: 1px solid var(--oms-slate-200);
  background: white;
  padding: 12px 18px;
}

.oms-invoices-filterbar label {
  display: grid;
  gap: 4px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 850;
}

.oms-invoices-filterbar input,
.oms-invoices-filterbar select {
  min-height: 36px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #fff;
  padding: 0 10px;
  color: var(--oms-slate-900);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
}

.oms-invoices-summary {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 12px 18px;
}

.oms-invoices-summary span {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  background: white;
  padding: 0 10px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 850;
}

.oms-invoices-summary strong {
  color: var(--oms-slate-950);
}

.oms-invoices-notice {
  margin: 0 18px 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
  padding: 10px 12px;
  color: var(--oms-blue-700);
  font-size: 13px;
  font-weight: 800;
}

.oms-invoice-accounting-panel {
  margin: 0 18px 14px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  padding: 14px;
}

.oms-invoice-accounting-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.oms-invoice-accounting-head strong {
  display: block;
  color: var(--oms-slate-950);
  font-size: 15px;
  font-weight: 900;
}

.oms-invoice-accounting-head span {
  display: block;
  margin-top: 2px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
}

.oms-invoice-accounting-titleblock {
  min-width: 0;
}

.oms-invoice-accounting-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.oms-invoice-accounting-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 12px;
  align-items: stretch;
}

/* ===== Eksport dla ksiegowosci (rola ksiegowy) =============================
   Ciemny hero z CTA, przelaczniki pigulkowe zamiast selectow, statystyki jako
   kafelki liczbowe i trzy karty plikow. Renderowane przez
   invoiceAccountingExportPanelHtml(). */
.oms-acc {
  margin: 0 18px 16px;
  border-radius: 18px;
  overflow: hidden;
  background: #fff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.10);
}

.oms-acc-hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 26px;
  color: #fff;
  background:
    radial-gradient(900px 260px at 0% 0%, rgba(59, 130, 246, 0.55), transparent 60%),
    radial-gradient(600px 220px at 100% 100%, rgba(14, 165, 233, 0.35), transparent 60%),
    linear-gradient(135deg, #0f172a 0%, #1e293b 55%, #1d4ed8 140%);
}

.oms-acc-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.6), transparent);
}

.oms-acc-hero-text { position: relative; min-width: 0; }

.oms-acc-eyebrow {
  display: inline-block;
  margin-bottom: 8px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #dbeafe;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.oms-acc-hero h2 {
  margin: 0;
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -0.02em;
  text-transform: capitalize;
}

.oms-acc-hero p {
  margin: 6px 0 0;
  color: #cbd5e1;
  font-size: 13px;
  font-weight: 650;
}

.oms-acc-hero-actions {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.oms-acc-btn-primary,
.oms-acc-btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 18px;
  border-radius: 12px;
  font: inherit;
  font-size: 13.5px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

.oms-acc-btn-primary {
  border: 0;
  color: #0f172a;
  background: linear-gradient(180deg, #ffffff, #dbeafe);
  box-shadow: 0 10px 24px rgba(59, 130, 246, 0.35), inset 0 1px 0 #fff;
}

.oms-acc-btn-primary svg { width: 18px; height: 18px; }

.oms-acc-btn-primary:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 14px 30px rgba(59, 130, 246, 0.45), inset 0 1px 0 #fff; }

.oms-acc-hero .oms-acc-btn-ghost {
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.oms-acc-hero .oms-acc-btn-ghost:hover:not(:disabled) { background: rgba(255, 255, 255, 0.16); }

.oms-acc-body .oms-acc-btn-ghost {
  border: 1px solid var(--oms-slate-200);
  background: #fff;
  color: var(--oms-slate-900);
}

.oms-acc-body .oms-acc-btn-ghost:hover:not(:disabled) { border-color: #93c5fd; background: var(--oms-blue-50); color: var(--oms-blue-700); }

.oms-acc-btn-primary:disabled,
.oms-acc-btn-ghost:disabled { opacity: 0.55; cursor: default; }

.oms-acc-body {
  display: grid;
  gap: 18px;
  padding: 20px 26px 24px;
  background: linear-gradient(180deg, #f8fafc 0%, #fff 120px);
}

.oms-acc-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 22px;
}

.oms-acc-control { display: grid; gap: 7px; min-width: 0; }

.oms-acc-control > label {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.oms-acc-segment {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 4px;
  border-radius: 12px;
  background: #e9eef5;
}

.oms-acc-segment button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 14px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--oms-slate-600);
  font: inherit;
  font-size: 13px;
  font-weight: 750;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.oms-acc-segment button i { font-style: normal; font-size: 15px; line-height: 1; }
.oms-acc-segment button small { color: var(--oms-slate-400); font-size: 11px; font-weight: 700; }
.oms-acc-segment button:hover { color: var(--oms-slate-900); }

.oms-acc-segment button.active {
  background: #fff;
  color: var(--oms-slate-950);
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12), 0 0 0 1px rgba(15, 23, 42, 0.04);
}

.oms-acc-segment button.active small { color: var(--oms-blue-600); }

.oms-acc-switch {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 44px auto 1fr;
  align-items: center;
  column-gap: 12px;
  width: fit-content;
  max-width: 100%;
  padding: 10px 14px 10px 10px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
  background: #fff;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.oms-acc-switch:hover:not(:disabled) { border-color: #93c5fd; }
.oms-acc-switch:disabled { opacity: 0.55; cursor: default; }

.oms-acc-switch i {
  position: relative;
  display: block;
  width: 44px;
  height: 26px;
  border-radius: 999px;
  background: #cbd5e1;
  transition: background 0.18s ease;
}

.oms-acc-switch i::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.3);
  transition: transform 0.18s ease;
}

.oms-acc-switch.on i { background: var(--oms-blue-600); }
.oms-acc-switch.on i::after { transform: translateX(18px); }
.oms-acc-switch span { color: var(--oms-slate-900); font-size: 13px; font-weight: 800; }
.oms-acc-switch small { color: var(--oms-slate-500); font-size: 12px; font-weight: 650; }

.oms-acc-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.oms-acc-stat {
  display: grid;
  align-content: center;
  gap: 2px;
  min-width: 92px;
  min-height: 64px;
  padding: 10px 14px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
  background: #fff;
}

.oms-acc-stat em { font-style: normal; font-size: 16px; line-height: 1; }
.oms-acc-stat strong { color: var(--oms-slate-950); font-size: 20px; font-weight: 900; letter-spacing: -0.02em; line-height: 1.1; }
.oms-acc-stat span { color: var(--oms-slate-500); font-size: 11.5px; font-weight: 750; }

.oms-acc-stat-main {
  min-width: 170px;
  border-color: transparent;
  background: linear-gradient(135deg, #1d4ed8, #3b82f6);
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.28);
}

.oms-acc-stat-main strong { color: #fff; font-size: 30px; }
.oms-acc-stat-main span { color: #dbeafe; }
.oms-acc-stat-soft { background: var(--oms-slate-50); }

.oms-acc-stat-hint {
  min-width: 0;
  flex: 1;
  border-style: dashed;
  background: transparent;
}

.oms-acc-stat-hint strong { font-size: 14px; }
.oms-acc-stat-hint span { font-size: 12.5px; }

.oms-acc-warning {
  padding: 10px 14px;
  border-radius: 10px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #9a3412;
  font-size: 12.5px;
  font-weight: 700;
}

.oms-acc-files {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding-top: 18px;
  border-top: 1px solid #e2e8f0;
}

/* Remanent bez zdjecia ma wygladac na nieaktywny, a nie na zepsuty przycisk -
   snapshot za biezacy miesiac powstaje dopiero ostatniego dnia. */
.oms-acc-file-pending {
  border-style: dashed;
  background: var(--oms-slate-50, #f8fafc);
}

.oms-acc-file-pending .oms-acc-file-icon {
  opacity: 0.55;
}

.oms-acc-file {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  column-gap: 12px;
  row-gap: 12px;
  align-items: start;
  padding: 14px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 14px;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.oms-acc-file:hover { border-color: #bfdbfe; box-shadow: 0 10px 24px rgba(37, 99, 235, 0.10); transform: translateY(-1px); }

.oms-acc-file-icon {
  display: inline-flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(135deg, #eff6ff, #dbeafe);
  color: var(--oms-blue-700);
}

.oms-acc-file-icon svg { width: 20px; height: 20px; }
.oms-acc-file-body { display: grid; gap: 3px; min-width: 0; }
.oms-acc-file-body strong { color: var(--oms-slate-950); font-size: 14px; font-weight: 900; }
.oms-acc-file-body span { color: var(--oms-slate-500); font-size: 12px; font-weight: 650; line-height: 1.4; }
.oms-acc-file > button, .oms-acc-file-row { grid-column: 1 / -1; }
.oms-acc-file > button { width: 100%; }
.oms-acc-file-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }

.oms-acc-file-row input[type="date"] {
  min-height: 42px;
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
  background: #fff;
  padding: 0 12px;
  color: var(--oms-slate-900);
  font: inherit;
  font-size: 13px;
  font-weight: 750;
}

@media (max-width: 1100px) {
  .oms-acc-controls, .oms-acc-files { grid-template-columns: 1fr; }
  .oms-acc-hero { flex-direction: column; align-items: flex-start; }
  .oms-acc-hero-actions { width: 100%; }
  .oms-acc-hero-actions button { flex: 1; }
}

.oms-invoice-accounting-grid label {
  display: grid;
  gap: 5px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 850;
}

.oms-invoice-accounting-grid select {
  min-height: 40px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #fff;
  padding: 0 12px;
  color: var(--oms-slate-900);
  font: inherit;
  font-size: 13px;
  font-weight: 750;
}

.oms-invoice-accounting-check {
  min-height: 40px;
  display: flex !important;
  grid-template-columns: none !important;
  align-items: center;
  gap: 10px !important;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #fff;
  padding: 0 12px;
  color: var(--oms-slate-700) !important;
  font-size: 12px !important;
  line-height: 1.25;
}

.oms-invoice-accounting-check input {
  width: 18px;
  height: 18px;
  accent-color: var(--oms-blue-600);
}

.oms-invoice-accounting-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 14px;
  border: 1px solid var(--oms-slate-100);
  border-radius: 10px;
  background: #fff;
  padding: 10px;
}

.oms-invoice-accounting-preview span {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  border-radius: 999px;
  background: var(--oms-slate-50);
  padding: 0 9px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 800;
}

.oms-invoice-accounting-preview strong {
  color: var(--oms-slate-950);
}

.oms-invoice-accounting-preview em {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
}

.oms-invoice-accounting-preview.muted {
  border-style: dashed;
  color: var(--oms-slate-500);
}

.oms-invoice-export-trigger {
  min-width: 104px;
}

.oms-invoices-view .oms-invoice-pdf-error {
  margin: 0 18px 12px;
}

.oms-invoices-table-wrap {
  margin: 0 18px 18px;
  overflow: auto;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
}

.oms-invoices-table {
  width: 100%;
  min-width: 980px;
  border-collapse: collapse;
  font-size: 13px;
}

.oms-invoices-table th {
  border-bottom: 1px solid var(--oms-slate-200);
  background: var(--oms-slate-50);
  padding: 11px 12px;
  color: var(--oms-slate-500);
  text-align: left;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}

.oms-invoices-table td {
  border-bottom: 1px solid var(--oms-slate-100);
  padding: 11px 12px;
  color: var(--oms-slate-700);
  vertical-align: middle;
}

.oms-invoices-table tr:last-child td {
  border-bottom: 0;
}

.oms-invoices-table tr.cancelled td {
  background: #fafafa;
  color: var(--oms-slate-400);
}

.oms-invoices-table td strong {
  display: block;
  color: var(--oms-slate-950);
  font-weight: 900;
}

.oms-invoices-table td span {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 650;
}

.oms-invoices-table .right {
  text-align: right;
  white-space: nowrap;
}

.oms-invoices-link {
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--oms-blue-600);
  font-size: 13px;
  font-weight: 850;
  cursor: pointer;
}

.oms-invoices-actions {
  display: flex;
  gap: 6px;
  justify-content: flex-end;
  white-space: nowrap;
}

.oms-invoices-actions button,
.oms-invoices-correction {
  min-height: 31px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 7px;
  background: white;
  padding: 0 10px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 850;
}

.oms-invoices-actions button.danger {
  border-color: #fecaca;
  color: #b91c1c;
}

.oms-invoices-actions button:disabled,
.oms-invoices-correction:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.oms-invoices-empty {
  padding: 34px 16px;
  color: var(--oms-slate-500);
  text-align: center;
  font-size: 13px;
  font-weight: 750;
}

@media (max-width: 1100px) {
  .oms-invoices-filterbar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .oms-invoice-accounting-grid {
    grid-template-columns: 1fr;
  }

  .oms-analytics-split {
    grid-template-columns: 1fr;
  }

  .oms-analytics-cost-form {
    grid-template-columns: 1fr;
  }

  .oms-analytics-product-cost-form {
    grid-template-columns: 1fr;
  }
}

.oms-analytics-view {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  overflow-y: auto;
  background: #f5f7fa;
}

.oms-analytics-view[hidden] {
  display: none;
}

.oms-analytics-top {
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--oms-slate-200);
  background: white;
  padding: 10px 18px;
}

.oms-analytics-top > div:first-child {
  min-width: 260px;
  flex: 1 1 320px;
}

.oms-analytics-title {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
}

.oms-analytics-subtitle {
  margin: 2px 0 0;
  color: var(--oms-slate-500);
  font-size: 12px;
}

.oms-analytics-actions,
.oms-chart-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.oms-analytics-actions {
  justify-content: flex-end;
}

.oms-date-pill,
.oms-month-select,
.oms-analytics-field {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 0 12px;
  color: var(--oms-slate-600);
  font-size: 13px;
}

.oms-analytics-field {
  padding-right: 8px;
  font-weight: 750;
}

.oms-analytics-field input,
.oms-analytics-cost-form input,
.oms-analytics-cost-form select,
.oms-analytics-product-cost-form input {
  min-height: 30px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 7px;
  background: white;
  padding: 0 9px;
  color: var(--oms-slate-900);
  font: inherit;
  font-weight: 750;
}

.oms-action-btn {
  display: inline-flex;
  height: 34px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  padding: 0 14px;
  color: white;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.oms-action-btn.purple { background: #7c3aed; }
.oms-action-btn.green { background: #059669; }
.oms-action-btn.orange { background: #ea580c; }
.oms-action-btn.red { background: #dc2626; }

.oms-btn-light.danger {
  border-color: #fecaca;
  background: #fff7f7;
  color: #b91c1c;
}

.oms-returns-view {
  flex: 1;
  min-width: 0;
  overflow: auto;
  background: #f4f6fa;
}

.oms-returns-view[hidden] {
  display: none;
}

.oms-returns-shell {
  display: grid;
  min-height: 100%;
  grid-template-columns: 250px minmax(0, 1fr);
  background: #f7f8fb;
}

.oms-returns-rail {
  border-right: 1px solid #d7dde8;
  background: linear-gradient(180deg, #f1eefc 0%, #f8f6ff 44%, #f4f6fa 100%);
  padding: 16px 12px 24px;
}

.oms-returns-create {
  display: flex;
  width: 100%;
  height: 52px;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border: 0;
  border-radius: 22px;
  background: linear-gradient(135deg, #8b5cf6 0%, #6d4fd8 100%);
  box-shadow: 0 12px 28px rgba(109, 79, 216, .25);
  color: #fff;
  cursor: pointer;
  font-size: 15px;
  font-weight: 900;
}

.oms-returns-create span {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 2px solid rgba(255, 255, 255, .72);
  border-radius: 999px;
  font-size: 22px;
  line-height: 1;
}

.oms-returns-rail-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 18px;
}

.oms-returns-rail-list button {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  width: 100%;
  min-height: 34px;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #36445a;
  cursor: pointer;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  padding: 5px 8px;
  text-align: left;
}

.oms-returns-rail-list button:hover,
.oms-returns-rail-list button.active {
  background: rgba(255, 255, 255, .75);
  color: #111827;
  box-shadow: inset 3px 0 0 #7c3aed;
}

.oms-returns-rail-list button strong {
  display: inline-grid;
  min-width: 26px;
  height: 24px;
  place-items: center;
  border: 1px solid #cfd8e6;
  border-radius: 999px;
  background: #fff;
  color: #64748b;
  font-size: 12px;
  font-weight: 950;
}

.oms-returns-rail-dot {
  display: inline-grid;
  min-width: 22px;
  height: 18px;
  place-items: center;
  border-radius: 5px;
  color: #fff;
  font-size: 10px;
  font-weight: 950;
  line-height: 1;
}

.oms-returns-rail-dot.slate { background: #64748b; }
.oms-returns-rail-dot.purple { background: #7c3aed; }
.oms-returns-rail-dot.blue { background: #2f7ddd; }
.oms-returns-rail-dot.green { background: #2f855a; }
.oms-returns-rail-dot.red { background: #dc2626; }

/* Zakladka "Do zwrotu kasy" z niezerowym licznikiem - czerwony akcent */
.oms-returns-rail-list button.has-money {
  background: #fef2f2;
  border: 1px solid #fecaca;
}
.oms-returns-rail-list button.has-money span:nth-child(2) { color: #b91c1c; font-weight: 700; }
.oms-returns-rail-list button.has-money strong { color: #b91c1c; }
.oms-app[data-theme="dark"] .oms-returns-rail-list button.has-money {
  background: rgba(220, 38, 38, 0.14);
  border-color: rgba(220, 38, 38, 0.4);
}
.oms-app[data-theme="dark"] .oms-returns-rail-list button.has-money span:nth-child(2),
.oms-app[data-theme="dark"] .oms-returns-rail-list button.has-money strong { color: #fca5a5; }

.oms-returns-rail-add {
  width: 100%;
  margin-top: 16px;
  border: 0;
  border-top: 1px solid #d9d3ea;
  background: transparent;
  color: #6b7280;
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
  padding: 14px 8px 4px;
  text-align: left;
}

.oms-returns-list-pane {
  min-width: 0;
  padding: 0 0 36px;
}

.oms-returns-topbar {
  display: flex;
  min-height: 86px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid #dce3ef;
  background: #fff;
  padding: 0 24px;
}

.oms-returns-topbar h1 {
  margin: 0;
  color: #111827;
  font-size: 22px;
  font-weight: 950;
  letter-spacing: -0.01em;
}

.oms-returns-topbar p {
  margin: 3px 0 0;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}

.oms-returns-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #d8e0eb;
  border-radius: 999px;
  background: #fff;
  color: #4b5563;
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
  padding: 10px 16px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, .04);
}

.oms-returns-filter-btn span {
  display: inline-grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid #d8e0eb;
  border-radius: 999px;
  color: #334155;
}

.oms-returns-toolbar {
  display: flex;
  min-height: 72px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid #e1e7f0;
  background: #fff;
  padding: 0 24px;
}

.oms-returns-toolgroup {
  display: flex;
  align-items: center;
  gap: 8px;
}

.oms-returns-toolgroup button {
  display: inline-grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid #d6dfeb;
  border-radius: 8px;
  background: #fff;
  color: #64748b;
  font-size: 15px;
  opacity: .9;
}

.oms-returns-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 16px;
  margin: 14px 24px 10px;
  color: #6b7890;
  font-size: 13px;
  font-weight: 700;
}

.oms-returns-table-card {
  border-top: 1px solid #d8e0eb;
  border-bottom: 1px solid #d8e0eb;
  border-radius: 0;
  background: #fff;
  box-shadow: none;
  overflow: auto;
}

.oms-returns-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1240px;
}

.oms-returns-table th {
  background: #f1f5f9;
  color: #5d6b82;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .04em;
  text-align: left;
  text-transform: uppercase;
  padding: 14px 16px;
  border-bottom: 1px solid #d9e3f2;
}

.oms-returns-table th:first-child,
.oms-returns-table th:nth-child(2) {
  width: 34px;
  padding-left: 10px;
  padding-right: 6px;
}

.oms-returns-table th span {
  color: #2563eb;
  font-size: 11px;
  text-transform: none;
}

.oms-returns-table td {
  padding: 12px 16px;
  border-bottom: 1px solid #e5edf7;
  vertical-align: top;
  color: #111827;
  font-weight: 700;
}

.oms-returns-table td:first-child,
.oms-returns-table td:nth-child(2) {
  padding-left: 10px;
  padding-right: 6px;
  text-align: center;
}

.oms-returns-row {
  cursor: pointer;
}

.oms-returns-row:hover td {
  background: #f8fbff;
}

.oms-returns-row:last-child td {
  border-bottom: 0;
}

.oms-returns-main {
  display: grid;
  gap: 4px;
}

.oms-returns-main strong {
  color: #1d4ed8;
}

.oms-return-number {
  width: fit-content;
  border: 0;
  background: transparent;
  color: #2563eb;
  cursor: pointer;
  font: inherit;
  font-weight: 950;
  padding: 0;
  text-align: left;
}

.oms-return-star {
  color: #94a3b8;
}

.oms-returns-main span,
.oms-returns-muted {
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.oms-return-products {
  align-items: flex-start;
}

.oms-return-product-line {
  display: block;
  margin-bottom: 2px;
}

.oms-returns-status {
  display: inline-flex;
  align-items: center;
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 900;
  line-height: 1.2;
}

.oms-returns-status.is-open {
  background: #7c3aed;
  color: #fff;
}

.oms-returns-status.is-reported {
  background: #2f7ddd;
  color: #fff;
}

.oms-returns-status.is-completed {
  background: #2f855a;
  color: #fff;
}

.oms-returns-status.is-muted {
  background: #e5e7eb;
  color: #475569;
}

.oms-returns-actions {
  text-align: right;
  white-space: nowrap;
}

.oms-app[data-theme="dark"] .oms-returns-view {
  background: #111827;
}

.oms-app[data-theme="dark"] .oms-returns-rail,
.oms-app[data-theme="dark"] .oms-returns-topbar,
.oms-app[data-theme="dark"] .oms-returns-toolbar,
.oms-app[data-theme="dark"] .oms-returns-table-card {
  border-color: rgba(148, 163, 184, .24);
  background: #1f2937;
  color: #dbeafe;
}

.oms-app[data-theme="dark"] .oms-returns-shell,
.oms-app[data-theme="dark"] .oms-returns-list-pane {
  background: #111827;
}

.oms-app[data-theme="dark"] .oms-returns-rail-list button {
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-returns-rail-list button:hover,
.oms-app[data-theme="dark"] .oms-returns-rail-list button.active {
  background: rgba(148, 163, 184, .1);
  color: #fff;
}

.oms-app[data-theme="dark"] .oms-returns-topbar h1 {
  color: #f8fafc;
}

.oms-app[data-theme="dark"] .oms-returns-filter-btn,
.oms-app[data-theme="dark"] .oms-returns-toolgroup button {
  border-color: rgba(148, 163, 184, .28);
  background: #111827;
  color: #dbeafe;
}

.oms-app[data-theme="dark"] .oms-returns-table th {
  border-color: rgba(148, 163, 184, .2);
  background: #273241;
  color: #a8b4c7;
}

.oms-app[data-theme="dark"] .oms-returns-table td {
  border-color: rgba(148, 163, 184, .18);
  color: #e5e7eb;
}

.oms-app[data-theme="dark"] .oms-returns-row:hover td {
  background: rgba(96, 165, 250, .08);
}

.oms-app[data-theme="dark"] .oms-returns-main span,
.oms-app[data-theme="dark"] .oms-returns-muted,
.oms-app[data-theme="dark"] .oms-returns-meta,
.oms-app[data-theme="dark"] .oms-returns-topbar p {
  color: #94a3b8;
}

@media (max-width: 980px) {
  .oms-returns-shell {
    grid-template-columns: 1fr;
  }

  .oms-returns-rail {
    border-right: 0;
    border-bottom: 1px solid #d7dde8;
  }

  .oms-returns-rail-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .oms-returns-toolbar,
  .oms-returns-topbar {
    align-items: flex-start;
    flex-direction: column;
    height: auto;
    padding: 16px;
  }
}

.oms-action-btn:disabled {
  cursor: not-allowed;
  opacity: 0.9;
}

.oms-analytics-status {
  border-bottom: 1px solid #bbf7d0;
  background: #f0fdf4;
  padding: 9px 18px;
  color: #166534;
  font-size: 13px;
  font-weight: 800;
}

.oms-analytics-status.error {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
}

.oms-analytics-content {
  padding: 18px;
}

.oms-control-view {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  overflow-y: auto;
  background: #f5f7fa;
}

.oms-control-view[hidden] {
  display: none;
}

.oms-control-content {
  padding: 18px;
}

.oms-control-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 14px;
}

.oms-control-grid-secondary {
  margin-top: 18px;
}

.oms-control-primary-grid {
  margin-bottom: 18px;
}

.oms-control-primary-grid > .oms-shipping-alert {
  grid-column: 1 / -1;
}

.oms-printer-download-grid {
  margin-bottom: 18px;
}

.oms-printer-download-summary {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-printer-download-card {
  border-color: #cbd5e1;
}

.oms-printer-download-actions {
  margin-top: 16px;
}

.oms-printer-download-actions a {
  text-decoration: none;
}

.oms-printer-token-input {
  width: 100%;
  min-height: 38px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 0 10px;
  color: var(--oms-slate-900);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
  font-weight: 700;
}

.oms-control-summary {
  display: flex;
  min-height: 88px;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  grid-column: 1 / -1;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 16px;
}

.oms-control-summary-title {
  color: var(--oms-slate-900);
  font-size: 18px;
  font-weight: 800;
}

.oms-control-summary-sub {
  margin-top: 4px;
  color: var(--oms-slate-500);
  font-size: 12px;
}

.oms-control-mini-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.oms-control-mini-stat {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  background: var(--oms-slate-100);
  padding: 4px 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 850;
}

.oms-control-mini-stat strong {
  color: var(--oms-slate-950);
  font-weight: 950;
}

.oms-control-mini-stat.active,
.oms-control-mini-stat.label {
  background: #dcfce7;
  color: #166534;
}

.oms-control-mini-stat.cancelled {
  background: #fee2e2;
  color: #991b1b;
}

.oms-control-mini-stat.warn {
  background: #fef3c7;
  color: #92400e;
}

.oms-control-filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.oms-control-filter-tab {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 999px;
  background: #ffffff;
  padding: 0 12px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.oms-control-filter-tab strong {
  color: var(--oms-slate-950);
  font-weight: 950;
}

.oms-control-filter-tab.active {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
}

.oms-control-filter-tab.active strong {
  color: #1e40af;
}

.oms-control-summary-state {
  border-radius: 999px;
  background: var(--oms-green-50);
  color: var(--oms-green-600);
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 800;
}

.oms-control-summary-state.offline {
  background: #fee2e2;
  color: #b91c1c;
}

.oms-control-card {
  min-height: 154px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 14px;
}

.oms-shipment-card {
  cursor: pointer;
}

.oms-print-agent-card {
  min-height: 132px;
}

.oms-print-job-card {
  min-height: 126px;
}

.oms-readiness-summary {
  min-height: 78px;
}

.oms-readiness-card {
  min-height: 134px;
}

.oms-readiness-card.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-readiness-card.warn {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-readiness-card.wait {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-readiness-card.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-base-parity-summary {
  min-height: 78px;
  border-color: #c7d2fe;
  background: #eef2ff;
}

.oms-base-parity-card {
  min-height: 132px;
}

.oms-base-parity-card.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-base-parity-card.warn {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-base-parity-card.wait {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-base-parity-card.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-base-parity-guardrails {
  min-height: 118px;
  grid-column: 1 / -1;
  border-color: #cbd5e1;
  background: #f8fafc;
}

.oms-base-automation-rules-card {
  grid-column: 1 / -1;
  border-color: #dbe7ff;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.oms-base-automation-rules-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 14px;
}

.oms-base-automation-rules-filters {
  display: grid;
  grid-template-columns: minmax(260px, 1.4fr) repeat(3, minmax(160px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.oms-base-automation-rules-filters label {
  display: grid;
  gap: 6px;
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.oms-base-automation-rules-filters input,
.oms-base-automation-rules-filters select {
  width: 100%;
  height: 40px;
  border: 1px solid #d6e1f0;
  border-radius: 12px;
  padding: 0 12px;
  color: #0f172a;
  background: #fff;
  font: inherit;
  font-weight: 700;
  box-shadow: 0 1px 2px rgba(15, 23, 42, .04);
}

.oms-base-automation-rules-filters input:focus,
.oms-base-automation-rules-filters select:focus {
  outline: none;
  border-color: #7aa2ff;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, .14);
}

.oms-base-automation-rules-table-wrap {
  overflow: auto;
  border: 1px solid #dbe7f5;
  border-radius: 16px;
  background: #fff;
}

.oms-base-automation-rules-table {
  width: 100%;
  min-width: 920px;
  border-collapse: separate;
  border-spacing: 0;
  color: #172033;
  font-size: 13px;
}

.oms-base-automation-rules-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 11px 12px;
  color: #66748a;
  background: #f1f6fc;
  border-bottom: 1px solid #dbe7f5;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .04em;
  text-align: left;
  text-transform: uppercase;
}

.oms-base-automation-rules-table td {
  padding: 11px 12px;
  border-bottom: 1px solid #edf2f8;
  vertical-align: top;
}

.oms-base-automation-rules-table tr:last-child td {
  border-bottom: 0;
}

.oms-base-automation-rules-table tr:hover td {
  background: #f8fbff;
}

.oms-base-automation-rules-table td small {
  display: block;
  margin-top: 3px;
  color: #7b8798;
  font-size: 12px;
  line-height: 1.35;
}

.oms-base-automation-rules-table .empty {
  padding: 28px 16px;
  color: #64748b;
  text-align: center;
}

.oms-base-rule-kind,
.oms-base-rule-status {
  display: inline-flex;
  align-items: center;
  max-width: 180px;
  min-height: 24px;
  padding: 4px 9px;
  border-radius: 999px;
  background: #eef2ff;
  color: #3746a3;
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.oms-base-rule-kind.shipping {
  background: #e0f2fe;
  color: #075985;
}

.oms-base-rule-kind.invoice {
  background: #dcfce7;
  color: #166534;
}

.oms-base-rule-kind.email {
  background: #fae8ff;
  color: #86198f;
}

.oms-base-rule-kind.status {
  background: #fef3c7;
  color: #92400e;
}

.oms-base-rule-status {
  max-width: 220px;
  background: #f1f5f9;
  color: #475569;
}

@media (max-width: 1180px) {
  .oms-base-automation-rules-filters {
    grid-template-columns: 1fr 1fr;
  }
}

.oms-base-cutover-summary {
  min-height: 78px;
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-base-cutover-summary.warn {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-base-cutover-summary.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-base-cutover-card {
  min-height: 132px;
}

.oms-base-cutover-card.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-base-cutover-card.warn {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-base-cutover-card.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-base-cutover-details {
  grid-column: 1 / -1;
  border-color: #cbd5e1;
  background: #f8fafc;
}

.oms-base-cutover-pairs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.oms-base-cutover-pairs.muted {
  color: #64748b;
  font-size: 13px;
}

.oms-base-cutover-pair {
  display: grid;
  grid-template-columns: 1fr auto auto 1fr;
  gap: 6px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid #dbe4f0;
  border-radius: 12px;
  background: #fff;
  font-size: 12px;
  color: #334155;
}

.oms-base-cutover-pair strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #0f172a;
}

.oms-base-cutover-pair span {
  color: #64748b;
}

.oms-base-cutover-pair em {
  color: #94a3b8;
  font-style: normal;
}

.oms-base-cutover-pair.critical {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-base-cutover-pair.warning,
.oms-base-cutover-pair.same_group {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-base-cutover-examples {
  display: grid;
  gap: 6px;
  margin-top: 14px;
}

.oms-base-cutover-examples-title {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .02em;
  text-transform: uppercase;
  color: #475569;
}

.oms-base-cutover-example {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: space-between;
  padding: 8px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #fff;
  font-size: 12px;
  color: #475569;
}

.oms-base-cutover-example strong {
  color: #1d4ed8;
}

.oms-country-shipping-summary {
  min-height: 78px;
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-country-shipping-card {
  min-height: 190px;
}

.oms-country-shipping-card.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-country-shipping-card.wait {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-country-shipping-card.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-country-shipping-methods {
  display: grid;
  gap: 8px;
  margin: 12px 0;
}

.oms-country-shipping-method {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid rgba(148, 163, 184, 0.38);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 850;
}

.oms-country-shipping-method span,
.oms-country-shipping-method strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-country-shipping-method span {
  color: var(--oms-slate-700);
}

.oms-country-shipping-method strong {
  color: var(--oms-slate-500);
  text-align: right;
}

.oms-go-live-summary {
  min-height: 78px;
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-go-live-card {
  min-height: 126px;
}

.oms-go-live-card.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-go-live-card.wait {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-go-live-card.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-go-live-runbook {
  min-height: 130px;
  grid-column: 1 / -1;
  border-color: #cbd5e1;
  background: #f8fafc;
}

.oms-shipping-input-summary {
  min-height: 78px;
  border-color: #fed7aa;
  background: #fff7ed;
}

.oms-inventory-visibility-summary {
  min-height: 78px;
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-inventory-visibility-channel {
  min-height: 154px;
}

.oms-inventory-visibility-channel.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-inventory-visibility-channel.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-inventory-visibility-actions {
  align-items: center;
  margin-top: 12px;
  margin-bottom: 10px;
}

.oms-inventory-visibility-actions span {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
}

.oms-inventory-visibility-issues {
  grid-column: 1 / -1;
}

.oms-inventory-visibility-plan {
  grid-column: 1 / -1;
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-inventory-visibility-detail {
  grid-column: 1 / -1;
  border-color: #c7d2fe;
  background: #f8f7ff;
}

.oms-inventory-visibility-review-draft {
  grid-column: 1 / -1;
  border-color: #fed7aa;
  background: #fff7ed;
}

.oms-inventory-visibility-review-list {
  grid-column: 1 / -1;
  border-color: #bae6fd;
  background: #f0f9ff;
}

.oms-inventory-visibility-writeback-smoke-results {
  grid-column: 1 / -1;
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-inventory-visibility-writeback-staging-smoke-runbook {
  grid-column: 1 / -1;
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-inventory-visibility-writeback-smoke-risk-diff {
  grid-column: 1 / -1;
  border-color: #fed7aa;
  background: #fff7ed;
}

.oms-inventory-visibility-writeback-go-no-go-packet {
  grid-column: 1 / -1;
  border-color: #fecaca;
  background: #fef2f2;
}

.oms-inventory-visibility-review-diff {
  grid-column: 1 / -1;
  border-color: #ddd6fe;
  background: #f5f3ff;
}

.oms-inventory-visibility-review-kpis {
  grid-column: 1 / -1;
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-inventory-visibility-review-queue {
  grid-column: 1 / -1;
  border-color: #fecaca;
  background: #fef2f2;
}

.oms-inventory-visibility-review-action-checklist {
  grid-column: 1 / -1;
  border-color: #fef08a;
  background: #fefce8;
}

.oms-inventory-visibility-review-writeback-plan {
  grid-column: 1 / -1;
  border-color: #e5e7eb;
  background: #f9fafb;
}

.oms-inventory-visibility-detail-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 12px;
}

.oms-inventory-visibility-review-actions {
  flex-wrap: wrap;
  margin-top: 12px;
}

.oms-inventory-visibility-list {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.oms-inventory-visibility-list span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid rgba(148, 163, 184, 0.38);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 7px 9px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.oms-inventory-visibility-list strong,
.oms-inventory-visibility-list em {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-inventory-visibility-list em {
  color: var(--oms-slate-500);
  font-style: normal;
  text-align: right;
}

.oms-inventory-visibility-detail-button {
  flex: 0 0 auto;
  min-height: 26px;
  border: 1px solid rgba(148, 163, 184, 0.45);
  border-radius: 7px;
  background: #ffffff;
  color: var(--oms-slate-700);
  cursor: pointer;
  font-size: 11px;
  font-weight: 850;
  padding: 4px 8px;
}

.oms-inventory-visibility-detail-button:disabled {
  cursor: wait;
  opacity: 0.58;
}

@media (max-width: 820px) {
  .oms-inventory-visibility-detail-grid {
    grid-template-columns: 1fr;
  }
}

.oms-shipping-input-card {
  min-height: 168px;
}

.oms-shipping-input-card.ready {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-shipping-input-card.wait {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-shipping-input-card.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-shipping-input-list {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.oms-shipping-input-list span {
  border: 1px solid rgba(148, 163, 184, 0.38);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.66);
  padding: 7px 9px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

/* Kontener listy dokumentow byl `oms-control-grid`, wiec KAZDE dziecko - naglowek,
   pasek statusow, filtry, alerty - ladowalo we wlasnej komorce siatki. Stad etykiety
   "Typ dokumentu / Miesiac / Szukaj" nachodzily na siebie w waskiej kolumnie.
   Panel jest teraz zwyklym stosem, a siatka obejmuje wylacznie karty. */
.oms-warehouse-documents-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.oms-warehouse-documents-panel > .oms-shipping-alert {
  margin: 0;
}

.oms-warehouse-document-drafts-summary {
  min-height: 78px;
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-warehouse-document-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(268px, 1fr));
  gap: 14px;
  align-items: start;
}

.oms-warehouse-document-filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #ffffff;
  padding: 14px;
}

.oms-warehouse-document-filter-bar .oms-warehouse-document-form-grid {
  flex: 1 1 520px;
  margin-top: 0;
}

.oms-warehouse-document-filter-bar .oms-control-actions {
  flex: 0 0 auto;
  margin: 0;
}

.oms-warehouse-technical-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.oms-warehouse-technical-summary {
  min-height: 78px;
  border-color: #c7d2fe;
  background: #eef2ff;
}

.oms-warehouse-readiness-summary {
  min-height: 78px;
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.oms-warehouse-readiness-grid {
  margin-bottom: 14px;
}

.oms-warehouse-readiness-grid .oms-control-card {
  min-height: 132px;
}

.oms-warehouse-document-create-card {
  grid-column: 1 / -1;
  border-color: #dbeafe;
  background: #ffffff;
}

.oms-warehouse-document-type-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.oms-warehouse-document-type-picker .oms-btn-light.primary {
  border-color: #0f172a;
  background: #0f172a;
  color: #ffffff;
}

.oms-warehouse-document-form-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.oms-warehouse-document-form-grid label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.oms-warehouse-document-form-grid label.wide {
  grid-column: span 2;
}

.oms-warehouse-document-form-grid label.muted {
  opacity: 0.58;
}

.oms-warehouse-document-form-grid span {
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.oms-warehouse-document-form-grid input {
  width: 100%;
  min-width: 0;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #ffffff;
  padding: 9px 10px;
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 800;
}

.oms-warehouse-document-form-grid input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
  outline: none;
}

.oms-warehouse-document-status-filters {
  margin-top: 12px;
  margin-bottom: 10px;
}

.oms-warehouse-document-status-filters .oms-btn-light.primary {
  border-color: #0f172a;
  background: #0f172a;
  color: #ffffff;
}

.oms-warehouse-document-draft-card {
  min-height: 0;
  border-color: #e2e8f0;
  border-radius: 12px;
  background: #ffffff;
  padding: 16px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.oms-warehouse-document-draft-card .oms-control-label {
  font-size: 15px;
  letter-spacing: -0.01em;
}

.oms-warehouse-document-draft-card .oms-control-meta {
  display: grid;
  gap: 4px;
  margin-top: 10px;
  color: var(--oms-slate-600);
  font-size: 12.5px;
  line-height: 1.45;
}

.oms-warehouse-document-draft-card .oms-control-actions {
  margin-top: 14px;
  gap: 6px;
}

.oms-warehouse-document-draft-card .oms-control-actions .oms-btn-light {
  padding: 6px 10px;
  font-size: 12px;
}

.oms-warehouse-document-draft-card.is-focused {
  border-color: #7fb3ff;
  background: linear-gradient(180deg, #ffffff 0%, #f2f7ff 100%);
  box-shadow: 0 0 0 3px rgba(47, 108, 229, 0.12), 0 14px 32px rgba(15, 23, 42, 0.08);
}

.oms-warehouse-document-lines {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.oms-warehouse-document-lines span {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  border: 1px solid rgba(148, 163, 184, 0.38);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 7px 9px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.oms-warehouse-document-lines strong,
.oms-warehouse-document-lines em {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-warehouse-document-lines em {
  flex: 0 0 auto;
  color: var(--oms-slate-500);
  font-style: normal;
  text-align: right;
  white-space: nowrap;
}

/* SKU potrafi miec 30 znakow bez spacji. Bez tego `overflow-wrap: anywhere`
   lamal go po jednej literze na wiersz i karta rosla na pol ekranu. */
.oms-warehouse-document-lines strong {
  overflow: hidden;
  overflow-wrap: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-document-impact {
  display: grid;
  gap: 9px;
  margin-top: 12px;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  background: #f0fdf4;
  padding: 10px;
}

.oms-warehouse-document-impact.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-warehouse-document-impact-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.oms-warehouse-document-impact-head strong {
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
}

.oms-warehouse-document-impact-head span {
  border-radius: 999px;
  background: rgba(22, 163, 74, 0.12);
  padding: 4px 8px;
  color: var(--oms-green-600);
  font-size: 11px;
  font-weight: 900;
}

.oms-warehouse-document-impact.blocked .oms-warehouse-document-impact-head span {
  background: #fee2e2;
  color: #b91c1c;
}

.oms-warehouse-document-impact-note {
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.oms-warehouse-document-impact-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.oms-warehouse-document-impact-metrics span {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  padding: 4px 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 850;
}

.oms-warehouse-document-impact-list {
  display: grid;
  gap: 6px;
}

.oms-warehouse-document-impact-list span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 7px 9px;
  font-size: 12px;
  font-weight: 800;
}

.oms-warehouse-document-impact-list strong,
.oms-warehouse-document-impact-list em {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-warehouse-document-impact-list em {
  color: var(--oms-slate-500);
  font-style: normal;
  text-align: right;
}

.oms-warehouse-document-impact-list.blocked span {
  border-color: #fecaca;
  background: #fff1f2;
  color: #991b1b;
}

.oms-warehouse-document-impact-list.warning span {
  border-color: #fde68a;
  background: #fffbeb;
  color: #92400e;
}

.oms-warehouse-document-audit {
  display: grid;
  gap: 10px;
  margin-top: 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #ffffff;
  padding: 10px;
}

.oms-warehouse-document-audit-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.oms-warehouse-document-audit-head strong {
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 950;
}

.oms-warehouse-document-audit-head span {
  border-radius: 999px;
  background: #e0f2fe;
  padding: 4px 8px;
  color: #0369a1;
  font-size: 11px;
  font-weight: 900;
}

.oms-warehouse-document-audit-section {
  display: grid;
  gap: 7px;
}

.oms-warehouse-document-audit-section > strong {
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 950;
}

.oms-warehouse-products-summary,
.oms-warehouse-products-card {
  grid-column: 1 / -1;
}

@media (max-width: 980px) {
  .oms-warehouse-document-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .oms-warehouse-document-form-grid {
    grid-template-columns: 1fr;
  }

  .oms-warehouse-document-form-grid label.wide {
    grid-column: span 1;
  }
}

.oms-warehouse-operator-summary {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  padding: 14px 16px;
}

.oms-warehouse-tabs {
  grid-column: 1 / -1;
  display: flex;
  gap: 28px;
  align-items: center;
  border-bottom: 1px solid #dbe3ef;
  background: #ffffff;
  padding: 0 18px;
  min-height: 50px;
}

.oms-warehouse-tabs button {
  border: 0;
  background: transparent;
  color: #475569;
  font-size: 15px;
  font-weight: 800;
  height: 50px;
  padding: 0;
  border-bottom: 2px solid transparent;
  cursor: pointer;
}

.oms-warehouse-tabs button.active {
  color: #2563eb;
  border-bottom-color: #2563eb;
}

.oms-warehouse-tabs button:disabled {
  color: #94a3b8;
  cursor: not-allowed;
}

.oms-warehouse-tabs button span {
  display: inline-flex;
  margin-left: 6px;
  padding: 2px 6px;
  border-radius: 5px;
  background: #f97316;
  color: #ffffff;
  font-size: 11px;
}

.oms-warehouse-toolbar {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.oms-warehouse-toolbar > div {
  display: grid;
  gap: 2px;
}

.oms-warehouse-toolbar label {
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.oms-warehouse-toolbar select {
  height: 36px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #f8fafc;
  color: #334155;
  padding: 0 10px;
  font-weight: 800;
}

.oms-warehouse-toolbar-spacer {
  flex: 1;
}

.oms-warehouse-products-actions {
  align-items: center;
  flex-wrap: wrap;
}

.oms-warehouse-products-search {
  min-width: 220px;
  max-width: 360px;
  height: 36px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 0 10px;
  font-size: 13px;
}

.oms-warehouse-sync-result {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 10px 0;
  padding: 10px 12px;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  background: #f0fdf4;
  color: #166534;
  font-size: 13px;
  font-weight: 800;
}

.oms-warehouse-sync-result span {
  color: #4b5563;
  font-weight: 700;
}

.oms-warehouse-products-list {
  display: grid;
  gap: 0;
  margin-top: 0;
  border: 1px solid #dbe3ef;
  border-top: 0;
  border-radius: 0 0 8px 8px;
  overflow: hidden;
}

.oms-warehouse-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  padding: 10px 12px;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}

.oms-warehouse-pagination > div {
  display: flex;
  align-items: center;
  gap: 6px;
}

.oms-warehouse-pagination strong {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}

.oms-warehouse-products-head {
  display: grid;
  grid-template-columns: 46px 64px minmax(260px, 1fr) 120px 140px 170px minmax(180px, 0.8fr) 46px;
  gap: 0;
  align-items: center;
  min-height: 44px;
  margin-top: 12px;
  border: 1px solid #dbe3ef;
  border-radius: 8px 8px 0 0;
  background: #f8fafc;
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.oms-warehouse-products-head span {
  padding: 0 10px;
}

.oms-warehouse-product-row {
  display: grid;
  grid-template-columns: 46px 64px minmax(260px, 1fr) 120px 140px 170px minmax(180px, 0.8fr) 46px;
  gap: 0;
  align-items: center;
  min-height: 58px;
  border: 0;
  border-top: 1px solid #dbe3ef;
  border-radius: 0;
  background: #ffffff;
  width: 100%;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.oms-warehouse-product-row.bundle {
  background: #f8fbff;
}

.oms-warehouse-product-row:hover,
.oms-warehouse-product-row.selected {
  background: #eaf4ff;
  box-shadow: inset 3px 0 0 #3b82f6;
}

.oms-warehouse-select {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #94a3b8;
}

.oms-warehouse-checkbox {
  width: 16px;
  height: 16px;
  border: 1px solid #aebccc;
  border-radius: 4px;
  background: #ffffff;
}

.oms-warehouse-star {
  font-size: 17px;
  line-height: 1;
}

.oms-warehouse-product-image {
  width: 46px;
  height: 46px;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: #f9fafb;
  color: #9ca3af;
  font-size: 11px;
  font-weight: 700;
}

.oms-warehouse-product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.oms-warehouse-product-main {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 0 10px;
}

.oms-warehouse-product-main strong,
.oms-warehouse-product-main span,
.oms-warehouse-product-main em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-product-main strong {
  font-size: 14px;
  color: #111827;
}

.oms-warehouse-product-main span,
.oms-warehouse-product-main em {
  font-size: 12px;
  color: #6b7280;
}

.oms-warehouse-product-issues {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 4px;
}

.oms-warehouse-product-issue {
  display: inline-flex;
  min-height: 18px;
  align-items: center;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0 7px;
  font-size: 10px;
  font-weight: 950;
  line-height: 1;
  white-space: nowrap;
}

.oms-warehouse-product-issue.cost {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #c2410c;
}

.oms-warehouse-product-issue.mapping {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
}

.oms-warehouse-product-variants {
  padding: 0 10px;
}

.oms-warehouse-variant-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  border: 1px solid #dbeafe;
  background: #eff6ff;
  color: #2563eb;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

button.oms-warehouse-variant-pill {
  cursor: pointer;
}

button.oms-warehouse-variant-pill:hover {
  border-color: #93c5fd;
  background: #dbeafe;
}

.oms-warehouse-variant-pill.bundle {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #c2410c;
}

.oms-warehouse-variant-pill.single,
.oms-warehouse-chip.muted,
.oms-warehouse-muted {
  color: #64748b;
}

.oms-warehouse-chip.muted {
  display: inline-flex;
  padding: 3px 7px;
  border-radius: 999px;
  background: #f1f5f9;
  font-size: 11px;
  font-weight: 800;
}

.oms-warehouse-product-stock {
  display: grid;
  gap: 2px;
  justify-items: start;
  padding: 0 10px;
  font-size: 12px;
  color: #6b7280;
}

.oms-warehouse-product-stock strong {
  font-size: 15px;
  color: #111827;
}

.oms-warehouse-product-stock.low strong {
  color: #b45309;
}

.oms-warehouse-product-stock.empty strong {
  color: #dc2626;
}

.oms-warehouse-product-price {
  padding: 0 10px;
  color: #111827;
  font-size: 13px;
  font-weight: 900;
}

.oms-warehouse-product-cost {
  display: grid;
  align-content: center;
  gap: 1px;
  width: 100%;
  min-height: 34px;
  border: 1px solid #dbeafe;
  border-radius: 7px;
  background: #eff6ff;
  padding: 0 9px;
  color: #1d4ed8;
  text-align: left;
  cursor: text;
}

.oms-warehouse-product-cost:hover:not(:disabled) {
  border-color: #93c5fd;
  background: #dbeafe;
}

.oms-warehouse-product-cost.readonly,
.oms-warehouse-product-cost.readonly:hover {
  cursor: default;
}

.oms-warehouse-product-cost:disabled {
  cursor: wait;
  opacity: 0.72;
}

.oms-warehouse-product-cost.missing {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #c2410c;
}

.oms-warehouse-product-cost strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 950;
}

.oms-warehouse-product-cost span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: inherit;
  font-size: 10px;
  font-weight: 800;
  opacity: 0.72;
}

.oms-warehouse-product-cost-edit {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 4px;
  align-items: center;
}

.oms-warehouse-product-cost-edit input {
  width: 100%;
  min-width: 0;
  height: 34px;
  border: 1px solid #93c5fd;
  border-radius: 7px;
  background: #ffffff;
  color: #111827;
  padding: 0 7px;
  font-size: 13px;
  font-weight: 900;
}

.oms-warehouse-product-cost-edit button {
  height: 34px;
  min-width: 32px;
  border: 1px solid #bfdbfe;
  border-radius: 7px;
  background: #ffffff;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 950;
  cursor: pointer;
}

.oms-warehouse-product-cost-edit button:hover:not(:disabled) {
  background: #dbeafe;
}

.oms-warehouse-product-channels {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 0 10px;
}

.oms-warehouse-channel {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 6px;
  border-radius: 4px;
  border: 0;
  background: #84a85f;
  color: #ffffff;
  text-decoration: none;
  font-size: 11px;
  font-weight: 900;
  cursor: default;
}

a.oms-warehouse-channel {
  cursor: pointer;
}

a.oms-warehouse-channel:hover,
a.oms-warehouse-channel:focus-visible {
  background: #6f914d;
  color: #ffffff;
  outline: 2px solid rgba(47, 111, 237, 0.24);
  outline-offset: 2px;
}

.oms-warehouse-product-link-id {
  color: #1f5fbf;
  text-decoration: none;
}

.oms-warehouse-product-link-id:hover,
.oms-warehouse-product-link-id:focus-visible {
  text-decoration: underline;
}

.oms-warehouse-row-menu {
  position: relative;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  justify-self: center;
}

.oms-warehouse-row-menu > button {
  width: 30px;
  height: 30px;
  border: 1px solid #dbe3ef;
  border-radius: 999px;
  background: #ffffff;
  color: #64748b;
  font-size: 18px;
  font-weight: 900;
  cursor: pointer;
}

.oms-warehouse-action-menu {
  position: absolute;
  right: 0;
  top: 34px;
  z-index: 8;
  width: 190px;
  border: 1px solid #dbe3ef;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.16);
  padding: 6px;
}

.oms-warehouse-action-menu button {
  width: 100%;
  min-height: 30px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #334155;
  font-size: 12px;
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}

.oms-warehouse-action-menu button:hover:not(:disabled) {
  background: #eff6ff;
  color: #1d4ed8;
}

.oms-warehouse-action-menu button:disabled {
  color: #94a3b8;
  cursor: not-allowed;
}

.oms-warehouse-variant-expansion {
  border-top: 1px solid #dbe3ef;
  background: #fbfdff;
  padding: 10px 14px 12px 110px;
  display: grid;
  gap: 8px;
}

.oms-warehouse-variant-expansion-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #475569;
  font-size: 12px;
}

.oms-warehouse-variant-expansion-head strong {
  color: #111827;
}

.oms-warehouse-variant-row {
  display: grid;
  grid-template-columns: 36px minmax(140px, 1fr) minmax(220px, 1.5fr) 100px 100px minmax(160px, 1fr);
  gap: 8px;
  align-items: center;
  min-height: 40px;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  background: #ffffff;
  padding: 6px 8px;
}

.oms-warehouse-variant-row img {
  width: 30px;
  height: 30px;
  border-radius: 4px;
  object-fit: cover;
}

.oms-warehouse-variant-row strong,
.oms-warehouse-variant-row em,
.oms-warehouse-variant-row b,
.oms-warehouse-variant-row i,
.oms-warehouse-variant-row small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-variant-row strong,
.oms-warehouse-variant-row b,
.oms-warehouse-variant-row i {
  color: #111827;
  font-size: 12px;
  font-style: normal;
}

.oms-warehouse-variant-row em,
.oms-warehouse-variant-row small {
  color: #64748b;
  font-size: 11px;
}

.oms-warehouse-product-detail {
  border-top: 1px solid #e5e7eb;
  margin-top: 14px;
  padding-top: 14px;
  display: grid;
  gap: 12px;
}

.oms-warehouse-product-detail-head {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.oms-warehouse-product-detail-thumb {
  width: 58px;
  height: 58px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f1f5f9;
  overflow: hidden;
  display: grid;
  place-items: center;
  color: #94a3b8;
  font-size: 11px;
  font-weight: 900;
}

.oms-warehouse-product-detail-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.oms-warehouse-product-detail-head > div:not(.oms-warehouse-product-detail-thumb) {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.oms-warehouse-product-detail-head strong {
  color: #111827;
  font-size: 14px;
}

.oms-warehouse-product-detail-head span,
.oms-warehouse-product-detail-head em {
  color: #6b7280;
  font-size: 12px;
  overflow-wrap: anywhere;
}

.oms-warehouse-product-detail-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.oms-warehouse-product-detail-grid section {
  display: grid;
  align-content: start;
  gap: 7px;
  min-width: 0;
}

.oms-warehouse-product-detail-grid section > strong {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}

.oms-warehouse-product-detail-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  border-bottom: 1px solid #e2e8f0;
}

.oms-warehouse-product-detail-tabs button {
  min-height: 34px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.oms-warehouse-product-detail-tabs button.active {
  color: #2563eb;
  border-bottom-color: #2563eb;
}

.oms-warehouse-product-detail-panel {
  display: grid;
  gap: 12px;
}

.oms-warehouse-product-detail-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.oms-warehouse-product-detail-metric {
  display: grid;
  align-content: start;
  gap: 3px;
  min-height: 70px;
  border: 1px solid #eef2f7;
  border-radius: 6px;
  background: #f8fafc;
  padding: 8px;
}

.oms-warehouse-product-detail-metric.editable {
  background: #ffffff;
}

.oms-warehouse-product-detail-metric.editable.local {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-warehouse-product-detail-metric button {
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 0;
  color: inherit;
  text-align: left;
  cursor: text;
}

.oms-warehouse-product-detail-metric button strong {
  display: block;
}

.oms-warehouse-field-input {
  width: 100%;
  min-height: 32px;
  border: 1px solid #93c5fd;
  border-radius: 6px;
  background: #ffffff;
  color: #0f172a;
  font-size: 13px;
  font-weight: 850;
  padding: 6px 7px;
  outline: none;
}

.oms-warehouse-local-marker,
.oms-warehouse-action-status {
  color: #2563eb;
  font-size: 11px;
  font-weight: 900;
}

.oms-warehouse-action-status {
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #eff6ff;
  padding: 8px 10px;
}

.oms-warehouse-product-detail-metric em,
.oms-warehouse-product-detail-metric small {
  color: #64748b;
  font-style: normal;
  font-size: 11px;
  font-weight: 800;
}

.oms-warehouse-product-detail-metric strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #111827;
  font-size: 13px;
  font-weight: 950;
}

.oms-warehouse-product-detail-missing {
  color: #94a3b8;
  font-size: 12px;
  font-weight: 850;
}

.oms-warehouse-product-detail-section {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.oms-warehouse-product-detail-section > strong {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}

.oms-warehouse-price-history {
  display: grid;
  gap: 8px;
}

.oms-warehouse-price-history-row {
  display: grid;
  gap: 4px;
  min-width: 0;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  padding: 9px 10px;
}

.oms-warehouse-price-history-row div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

.oms-warehouse-price-history-row strong {
  color: #111827;
  font-size: 13px;
  font-weight: 950;
}

.oms-warehouse-price-history-row span {
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  padding: 3px 8px;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.oms-warehouse-price-history-row em,
.oms-warehouse-price-history-row small,
.oms-warehouse-price-history-row p {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
  color: #64748b;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.oms-warehouse-price-history-row p {
  color: #475569;
}

.oms-warehouse-local-drafts {
  border-top: 1px solid #e2e8f0;
  padding-top: 8px;
}

.oms-warehouse-product-detail-note {
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.oms-warehouse-product-media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 10px;
}

.oms-warehouse-product-media-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f8fafc;
  padding: 8px 10px;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
}

.oms-warehouse-product-media-summary strong {
  color: #111827;
}

.oms-warehouse-product-media {
  display: grid;
  gap: 6px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f8fafc;
  padding: 8px;
}

.oms-warehouse-product-media img,
.oms-warehouse-product-media i {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 5px;
  display: grid;
  place-items: center;
  object-fit: cover;
  background: #e5e7eb;
  color: #94a3b8;
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
}

.oms-warehouse-product-media strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #334155;
  font-size: 12px;
}

.oms-warehouse-product-media em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #64748b;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.oms-warehouse-product-detail-row {
  display: grid;
  gap: 2px;
  min-width: 0;
  border: 1px solid #eef2f7;
  border-radius: 6px;
  padding: 7px;
  background: #f8fafc;
}

.oms-warehouse-product-detail-row span,
.oms-warehouse-product-detail-row strong,
.oms-warehouse-product-detail-row em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-product-detail-row span,
.oms-warehouse-product-detail-row em {
  color: #64748b;
  font-size: 11px;
}

.oms-warehouse-product-detail-row strong {
  color: #111827;
  font-size: 12px;
}

.oms-warehouse-variant-expansion.standalone {
  padding: 0;
  border-top: 0;
  background: transparent;
}

.oms-warehouse-product-modal[hidden] {
  display: none;
}

.oms-warehouse-product-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 12px;
}

.oms-warehouse-product-modal-backdrop {
  position: absolute;
  inset: 0;
  background: var(--oms-modal-backdrop-soft);
  backdrop-filter: blur(4px);
}

.oms-warehouse-product-modal-shell {
  position: relative;
  z-index: 1;
  width: min(1840px, calc(100vw - 24px));
  height: min(980px, calc(100vh - 24px));
  overflow: hidden;
  border: 1px solid var(--oms-modal-border);
  border-radius: var(--oms-modal-radius-lg);
  background: var(--oms-modal-surface-bg);
  box-shadow: var(--oms-modal-shadow);
}

.oms-warehouse-product-modal .oms-warehouse-product-detail {
  height: 100%;
  margin: 0;
  border-top: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.oms-warehouse-product-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 60px;
  border-bottom: 1px solid var(--oms-modal-border);
  background: var(--oms-modal-header-bg);
  padding: 0 22px 0 300px;
}

.oms-warehouse-product-modal-title {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.oms-warehouse-product-modal-title strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #111827;
  font-size: 14px;
  font-weight: 900;
}

.oms-warehouse-product-modal-title span {
  color: #a2aab7;
  font-size: 13px;
  font-weight: 850;
  white-space: nowrap;
}

.oms-warehouse-product-modal-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.oms-warehouse-product-modal-controls button {
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #9aa4b2;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.oms-warehouse-product-modal-controls button:disabled {
  color: #c7ced8;
  cursor: default;
}

.oms-warehouse-product-modal-controls button:hover:not(:disabled) {
  background: #f1f5f9;
  color: #475569;
}

.oms-warehouse-product-modal .oms-warehouse-action-status,
.oms-warehouse-product-modal .oms-invoice-pdf-error {
  margin: 10px 22px 0;
}

.oms-warehouse-product-modal .oms-warehouse-product-detail-tabs {
  border-bottom: 1px solid var(--oms-modal-border);
  background: var(--oms-modal-surface-muted);
  padding: 0 300px 0 300px;
  gap: 46px;
}

.oms-warehouse-product-modal .oms-warehouse-product-detail-tabs button {
  min-height: 54px;
  font-size: 14px;
  color: #5f6977;
}

.oms-warehouse-product-modal .oms-warehouse-product-detail-tabs button.active {
  color: #2563eb;
}

.oms-warehouse-product-modal .oms-warehouse-product-detail-panel {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 28px 300px 40px;
  align-content: start;
}

.oms-warehouse-base-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px 24px;
}

.oms-warehouse-base-field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.oms-warehouse-base-field.wide {
  grid-column: span 2;
}

.oms-warehouse-base-field.full {
  grid-column: 1 / -1;
}

.oms-warehouse-base-field > span {
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}

.oms-warehouse-base-field small {
  color: #2563eb;
  font-size: 11px;
  font-weight: 850;
}

.oms-warehouse-base-input-wrap {
  display: flex;
  min-width: 0;
}

.oms-warehouse-base-input {
  width: 100%;
  min-width: 0;
  height: 40px;
  border: 1px solid #cfd7e3;
  border-radius: 6px;
  background: #ffffff;
  color: #4b5563;
  padding: 0 12px;
  font: inherit;
  font-size: 14px;
  font-weight: 750;
  text-align: left;
}

button.oms-warehouse-base-input {
  cursor: text;
}

.oms-warehouse-base-input.muted {
  display: flex;
  align-items: center;
  background: #f2f4f8;
  color: #9098a5;
}

.oms-warehouse-base-input-wrap i,
.oms-warehouse-base-input-wrap em {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 40px;
  border: 1px solid #cfd7e3;
  border-left: 0;
  border-radius: 0 6px 6px 0;
  background: #f8fafc;
  color: #64748b;
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.oms-warehouse-base-field .oms-warehouse-base-input-wrap i ~ em,
.oms-warehouse-base-input-wrap em {
  min-width: 110px;
}

.oms-warehouse-base-input-wrap:has(i) .oms-warehouse-base-input,
.oms-warehouse-base-input-wrap:has(em) .oms-warehouse-base-input {
  border-radius: 6px 0 0 6px;
}

.oms-warehouse-base-field.local .oms-warehouse-base-input {
  border-color: #93c5fd;
  background: #eff6ff;
}

.oms-warehouse-product-modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--oms-modal-border);
  background: var(--oms-modal-footer-bg);
  padding: 12px 300px;
  backdrop-filter: blur(10px);
}

.oms-warehouse-product-modal-footer > div {
  display: flex;
  align-items: center;
  gap: 10px;
}

@media (max-width: 1280px) {
  .oms-warehouse-product-modal-head,
  .oms-warehouse-product-modal .oms-warehouse-product-detail-tabs,
  .oms-warehouse-product-modal .oms-warehouse-product-detail-panel,
  .oms-warehouse-product-modal-footer {
    padding-left: 36px;
    padding-right: 36px;
  }

  .oms-warehouse-product-modal .oms-warehouse-product-detail-tabs {
    gap: 24px;
  }
}

@media (max-width: 820px) {
  .oms-warehouse-product-modal {
    padding: 0;
  }

  .oms-warehouse-product-modal-shell {
    width: 100vw;
    height: 100vh;
    border-radius: 0;
  }

  .oms-warehouse-product-modal .oms-warehouse-product-detail {
    grid-template-rows: auto auto 1fr auto;
  }

  .oms-warehouse-product-modal-head,
  .oms-warehouse-product-modal .oms-warehouse-product-detail-tabs,
  .oms-warehouse-product-modal .oms-warehouse-product-detail-panel,
  .oms-warehouse-product-modal-footer {
    padding-left: 14px;
    padding-right: 14px;
  }

  .oms-warehouse-product-modal .oms-warehouse-product-detail-tabs {
    gap: 18px;
    overflow-x: auto;
  }

  .oms-warehouse-base-form,
  .oms-warehouse-product-detail-metrics,
  .oms-warehouse-product-detail-grid {
    grid-template-columns: 1fr;
  }

  .oms-warehouse-base-field.wide,
  .oms-warehouse-base-field.full {
    grid-column: 1;
  }

  .oms-warehouse-product-modal-footer {
    align-items: stretch;
  }
}

.oms-warehouse-deliveries-summary,
.oms-warehouse-delivery-status-filters {
  grid-column: 1 / -1;
}

.oms-warehouse-deliveries-head,
.oms-warehouse-delivery-row {
  display: grid;
  grid-template-columns: minmax(260px, 1.4fr) minmax(160px, 1fr) 120px 90px 100px 140px 150px 150px 46px;
  gap: 0;
  align-items: center;
}

.oms-warehouse-deliveries-head {
  grid-column: 1 / -1;
  min-height: 44px;
  border: 1px solid #dbe3ef;
  border-radius: 8px 8px 0 0;
  background: #f8fafc;
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.oms-warehouse-deliveries-head span,
.oms-warehouse-delivery-row > span,
.oms-warehouse-delivery-row > strong {
  min-width: 0;
  padding: 0 10px;
}

.oms-warehouse-deliveries-list {
  grid-column: 1 / -1;
  display: grid;
  border: 1px solid #dbe3ef;
  border-top: 0;
  border-radius: 0 0 8px 8px;
  overflow: hidden;
}

.oms-warehouse-delivery-row {
  width: 100%;
  min-height: 62px;
  border: 0;
  border-top: 1px solid #dbe3ef;
  background: #ffffff;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.oms-warehouse-delivery-row:hover,
.oms-warehouse-delivery-row.selected {
  background: #eaf4ff;
  box-shadow: inset 3px 0 0 #3b82f6;
}

.oms-warehouse-delivery-row span,
.oms-warehouse-delivery-row strong,
.oms-warehouse-delivery-row em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-delivery-row strong {
  color: #111827;
  font-size: 13px;
}

.oms-warehouse-delivery-row em {
  display: block;
  color: #64748b;
  font-size: 12px;
  font-style: normal;
}

.oms-warehouse-delivery-note {
  grid-column: 1 / -1;
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
}

.oms-warehouse-delivery-detail {
  grid-column: 1 / -1;
  display: grid;
  gap: 12px;
  border: 1px solid #dbe3ef;
  border-radius: 8px;
  background: #ffffff;
  padding: 14px;
}

.oms-warehouse-delivery-detail-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.oms-warehouse-delivery-detail-head > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.oms-warehouse-delivery-detail-head strong {
  color: #111827;
  font-size: 15px;
}

.oms-warehouse-delivery-detail-head span {
  color: #64748b;
  font-size: 12px;
  overflow-wrap: anywhere;
}

.oms-warehouse-delivery-lines-head,
.oms-warehouse-delivery-line {
  display: grid;
  grid-template-columns: 34px 64px minmax(240px, 1.4fr) minmax(120px, .8fr) minmax(120px, .8fr) 100px 130px 80px 130px;
  gap: 0;
  align-items: center;
}

.oms-warehouse-delivery-lines-head {
  min-height: 40px;
  border: 1px solid #dbe3ef;
  border-radius: 8px 8px 0 0;
  background: #f8fafc;
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.oms-warehouse-delivery-lines {
  display: grid;
  border: 1px solid #dbe3ef;
  border-top: 0;
  border-radius: 0 0 8px 8px;
  overflow: hidden;
}

.oms-warehouse-delivery-line {
  min-height: 68px;
  border-top: 1px solid #dbe3ef;
  background: #ffffff;
}

.oms-warehouse-delivery-lines-head span,
.oms-warehouse-delivery-line > span,
.oms-warehouse-delivery-line > strong {
  min-width: 0;
  padding: 0 8px;
}

.oms-warehouse-delivery-image {
  width: 46px;
  height: 46px;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #f9fafb;
  color: #9ca3af;
  font-size: 10px;
  font-weight: 900;
}

.oms-warehouse-delivery-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.oms-warehouse-delivery-product {
  display: grid;
  gap: 3px;
}

.oms-warehouse-delivery-product strong,
.oms-warehouse-delivery-product em,
.oms-warehouse-delivery-line > span,
.oms-warehouse-delivery-line > strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-delivery-product strong,
.oms-warehouse-delivery-line > strong {
  color: #111827;
  font-size: 13px;
}

.oms-warehouse-delivery-product em,
.oms-warehouse-delivery-line > span {
  color: #64748b;
  font-size: 12px;
  font-style: normal;
}

.oms-warehouse-delivery-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
}

.oms-warehouse-delivery-modal-shell {
  position: fixed;
  inset: 16px;
  z-index: 82;
  display: grid;
  grid-template-rows: auto auto auto auto minmax(0, 1fr) auto;
  min-height: 0;
  border: 1px solid var(--oms-modal-border);
  border-radius: var(--oms-modal-radius);
  background: var(--oms-modal-surface-bg);
  box-shadow: var(--oms-modal-shadow);
  overflow: hidden;
}

.oms-warehouse-delivery-modal-shell > header,
.oms-warehouse-delivery-modal-shell > footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 24px;
  border-bottom: 1px solid var(--oms-modal-border);
}

.oms-warehouse-delivery-modal-shell > footer {
  border-top: 1px solid var(--oms-modal-border);
  border-bottom: 0;
  background: var(--oms-modal-footer-bg);
}

.oms-warehouse-delivery-modal-shell > header > div {
  display: grid;
  gap: 3px;
}

.oms-warehouse-delivery-modal-shell > header strong {
  color: #111827;
  font-size: 18px;
  font-weight: 900;
  letter-spacing: -0.01em;
}

.oms-warehouse-delivery-modal-shell > header span {
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
}

.oms-warehouse-delivery-modal-shell > header button[aria-label] {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: var(--oms-control-radius-sm);
  background: transparent;
  color: #64748b;
  font-size: 26px;
  cursor: pointer;
}

.oms-warehouse-delivery-modal-shell > header button[aria-label]:hover {
  background: #f1f5f9;
  color: #111827;
}

.oms-warehouse-delivery-steps {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: flex-end;
  padding: 12px 24px;
  border-bottom: 1px solid var(--oms-modal-border);
  background: var(--oms-modal-surface-muted);
}

.oms-warehouse-delivery-steps button {
  border: 0;
  background: transparent;
  color: #8a94a6;
  font: inherit;
  font-weight: 850;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.oms-warehouse-delivery-steps button span {
  width: 26px;
  height: 26px;
  border: 2px solid #cbd5e1;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #64748b;
  background: #ffffff;
}

.oms-warehouse-delivery-steps button.active span,
.oms-warehouse-delivery-steps button.done span {
  border-color: #2f6ce5;
  background: #2f6ce5;
  color: #ffffff;
}

.oms-warehouse-delivery-steps button.active {
  color: #111827;
}

.oms-warehouse-delivery-panel {
  min-height: 0;
  overflow: auto;
  padding: 24px;
  background: #ffffff;
}

.oms-warehouse-delivery-toast-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 0;
  border-bottom: 1px solid #e5eaf3;
  background: #fbfdff;
  padding: 8px 24px;
}

.oms-warehouse-delivery-toast-stack .oms-warehouse-action-status,
.oms-warehouse-delivery-toast-stack .oms-invoice-pdf-error,
.oms-warehouse-delivery-panel > .oms-warehouse-action-status,
.oms-warehouse-delivery-panel > .oms-invoice-pdf-error {
  display: inline-flex;
  align-items: center;
  max-width: min(100%, 760px);
  min-height: 0;
  margin: 0;
  border-radius: 999px;
  line-height: 1.25;
}

.oms-warehouse-delivery-toast-stack .oms-warehouse-action-status,
.oms-warehouse-delivery-panel > .oms-warehouse-action-status {
  padding: 7px 12px;
}

.oms-warehouse-delivery-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px 22px;
  max-width: 1640px;
}

.oms-warehouse-delivery-form-grid label,
.oms-warehouse-delivery-edit-line label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: #5b6b83;
  font-size: 12px;
  font-weight: 850;
}

.oms-warehouse-delivery-form-grid input,
.oms-warehouse-delivery-form-grid select,
.oms-warehouse-delivery-edit-line input,
.oms-warehouse-delivery-extra-row input,
.oms-warehouse-delivery-extra-row select,
.oms-warehouse-delivery-search input,
.oms-warehouse-delivery-notes {
  min-width: 0;
  border: 1px solid #cfd8e6;
  border-radius: 10px;
  background: #ffffff;
  color: #111827;
  font: inherit;
  font-size: 14px;
  font-weight: 750;
  padding: 11px 13px;
  box-shadow: 0 1px 1px rgba(15, 23, 42, 0.02);
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.oms-warehouse-delivery-form-grid input:focus,
.oms-warehouse-delivery-form-grid select:focus,
.oms-warehouse-delivery-edit-line input:focus,
.oms-warehouse-delivery-extra-row input:focus,
.oms-warehouse-delivery-extra-row select:focus,
.oms-warehouse-delivery-search input:focus,
.oms-warehouse-delivery-notes:focus {
  outline: none;
  border-color: #6ea8ff;
  box-shadow: 0 0 0 3px rgba(47, 108, 229, 0.12);
}

.oms-warehouse-delivery-form-grid input:disabled,
.oms-warehouse-delivery-form-grid select:disabled,
.oms-warehouse-delivery-edit-line input:disabled,
.oms-warehouse-delivery-extra-row input:disabled,
.oms-warehouse-delivery-extra-row select:disabled,
.oms-warehouse-delivery-notes:disabled {
  background: #f8fafc;
  color: #94a3b8;
}

.oms-warehouse-delivery-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  margin-bottom: 10px;
  position: relative;
}

.oms-warehouse-delivery-search-results {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 10px;
  margin: 0 0 16px;
  padding: 10px;
  border: 1px solid #dbe7f5;
  border-radius: 12px;
  background: #f8fbff;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.8);
}

.oms-warehouse-delivery-search-results button {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  border: 1px solid #dbe6f4;
  border-radius: 10px;
  background: #ffffff;
  padding: 9px 10px;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
}

.oms-warehouse-delivery-search-results button:hover {
  border-color: #7fb3ff;
  background: #f0f7ff;
}

.oms-warehouse-delivery-search-img {
  width: 48px;
  height: 48px;
  border: 1px solid #e2e8f0;
  border-radius: 9px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #ffffff;
}

.oms-warehouse-delivery-search-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.oms-warehouse-delivery-search-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.oms-warehouse-delivery-search-copy strong,
.oms-warehouse-delivery-search-copy em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-delivery-search-copy strong {
  color: #111827;
  font-size: 13px;
  font-weight: 900;
}

.oms-warehouse-delivery-search-copy em {
  color: #64748b;
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
}

.oms-warehouse-delivery-edit-lines {
  display: grid;
  gap: 0;
  border: 1px solid #dbe3ef;
  border-radius: 12px;
  overflow: hidden;
  background: #ffffff;
}

.oms-warehouse-delivery-edit-lines.is-empty {
  border: 0;
  background: transparent;
  overflow: visible;
}

.oms-warehouse-delivery-lines-header {
  display: grid;
  grid-template-columns: 56px minmax(360px, 1.7fr) minmax(120px, 0.7fr) minmax(120px, 0.7fr) 88px 92px 118px 92px 112px 38px;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  background: #f5f8fc;
  border-bottom: 1px solid #dbe3ef;
  color: #5b6b83;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.oms-warehouse-delivery-edit-line {
  display: grid;
  grid-template-columns: 56px minmax(360px, 1.7fr) minmax(120px, 0.7fr) minmax(120px, 0.7fr) 88px 92px 118px 92px 112px 38px;
  gap: 10px;
  align-items: start;
  border: 0;
  border-bottom: 1px solid #e5eaf3;
  border-radius: 0;
  padding: 10px 12px;
  background: #ffffff;
}

.oms-warehouse-delivery-edit-line:last-child {
  border-bottom: 0;
}

.oms-warehouse-delivery-edit-line label {
  gap: 5px;
}

.oms-warehouse-delivery-product-field {
  position: relative;
  display: grid;
  gap: 5px;
  min-width: 0;
}

.oms-warehouse-delivery-product-field > span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.oms-warehouse-delivery-edit-line label > span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.oms-warehouse-delivery-edit-line input {
  width: 100%;
  min-height: 38px;
  padding: 8px 10px;
  border-radius: 9px;
}

.oms-warehouse-delivery-product-field input {
  font-size: 14px;
  font-weight: 900;
}

.oms-warehouse-delivery-inline-results {
  display: grid;
  gap: 6px;
  max-height: 360px;
  overflow: auto;
  margin-top: 6px;
  border: 1px solid #cfe0f5;
  border-radius: 12px;
  background: #ffffff;
  padding: 7px;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.14);
}

.oms-warehouse-delivery-inline-results.is-loading {
  border-color: #bfdbfe;
  background: #f8fbff;
}

.oms-warehouse-delivery-inline-results.is-hint {
  border-color: #dbe7f5;
  background: #fbfdff;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.07);
}

.oms-warehouse-delivery-inline-results button {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
  border: 1px solid transparent;
  border-radius: 10px;
  background: #ffffff;
  padding: 7px 8px;
  text-align: left;
  cursor: pointer;
}

.oms-warehouse-delivery-inline-results button:hover {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-warehouse-delivery-inline-results .oms-warehouse-delivery-search-img {
  width: 42px;
  height: 42px;
  border-radius: 10px;
}

.oms-warehouse-delivery-inline-results .oms-warehouse-delivery-search-copy strong {
  font-size: 12px;
}

.oms-warehouse-delivery-inline-results .oms-warehouse-delivery-search-copy em {
  font-size: 10px;
}

.oms-warehouse-delivery-inline-status {
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 10px;
  background: #f8fafc;
  color: #64748b;
  padding: 10px 12px;
  font-size: 12px;
  font-weight: 850;
}

.oms-warehouse-delivery-inline-spinner {
  width: 14px;
  height: 14px;
  border: 2px solid #bfdbfe;
  border-top-color: #2563eb;
  border-radius: 999px;
  animation: oms-warehouse-delivery-spin 0.75s linear infinite;
  flex: 0 0 auto;
}

@keyframes oms-warehouse-delivery-spin {
  to {
    transform: rotate(360deg);
  }
}

.oms-warehouse-delivery-edit-line em {
  color: #64748b;
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-delivery-line-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 1px;
}

.oms-warehouse-delivery-line-tools button {
  min-height: 28px;
  border: 1px solid #dbe4f0;
  border-radius: 999px;
  background: #f8fbff;
  color: #315077;
  cursor: pointer;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  padding: 0 10px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.oms-warehouse-delivery-line-tools button:hover {
  border-color: #93c5fd;
  background: #eff6ff;
  color: #1d4ed8;
  box-shadow: 0 6px 14px rgba(37, 99, 235, 0.12);
}

.oms-warehouse-delivery-line-tools button:disabled {
  cursor: wait;
  opacity: 0.7;
  box-shadow: none;
}

.oms-warehouse-delivery-line-tools span {
  color: #b45309;
  font-size: 11px;
  font-weight: 850;
}

.oms-warehouse-delivery-edit-line > strong {
  align-self: center;
  color: #111827;
  font-size: 14px;
  font-weight: 900;
  text-align: right;
  white-space: nowrap;
}

.oms-warehouse-delivery-edit-line > button {
  width: 34px;
  height: 34px;
  border: 1px solid #dbe3ef;
  border-radius: 9px;
  background: #ffffff;
  color: #64748b;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.oms-warehouse-delivery-edit-line > button:hover {
  border-color: #fecaca;
  color: #dc2626;
}

.oms-warehouse-delivery-notes {
  width: 100%;
  min-height: 280px;
  resize: vertical;
}

.oms-warehouse-delivery-price-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #475569;
  font-size: 13px;
  font-weight: 850;
}

.oms-warehouse-delivery-price-checkbox input {
  width: 16px;
  height: 16px;
}

/* Premium polish for warehouse deliveries. Kept as overrides so it is easy to rollback. */
.oms-warehouse-delivery-modal .oms-warehouse-product-modal-backdrop {
  background:
    radial-gradient(circle at 18% 12%, rgba(59, 130, 246, 0.22), transparent 28%),
    radial-gradient(circle at 82% 0%, rgba(16, 185, 129, 0.14), transparent 24%),
    var(--oms-modal-backdrop);
  backdrop-filter: blur(5px);
}

.oms-warehouse-delivery-modal-shell {
  inset: 14px;
  border: 1px solid rgba(148, 163, 184, 0.38);
  border-radius: var(--oms-modal-radius-lg);
  background: var(--oms-modal-surface-muted);
  box-shadow: var(--oms-modal-shadow);
}

.oms-warehouse-delivery-modal-shell > header {
  min-height: 76px;
  padding: 18px 28px;
  border-bottom: 1px solid var(--oms-modal-border);
  background: var(--oms-modal-header-bg);
}

.oms-warehouse-delivery-modal-shell > header > div {
  gap: 5px;
}

.oms-warehouse-delivery-modal-shell > header strong {
  font-size: 22px;
  letter-spacing: -0.02em;
}

.oms-warehouse-delivery-modal-shell > header span {
  width: fit-content;
  max-width: 100%;
  border: 1px solid #dbe7f5;
  border-radius: 999px;
  background: #ffffff;
  color: #53657d;
  padding: 5px 10px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.oms-warehouse-delivery-modal-shell > header button[aria-label] {
  border: 1px solid transparent;
  color: #64748b;
  font-size: 30px;
}

.oms-warehouse-delivery-modal-shell > header button[aria-label]:hover {
  border-color: #dbe3ef;
  background: #ffffff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

.oms-warehouse-delivery-steps {
  position: relative;
  gap: 22px;
  min-height: 64px;
  padding: 14px 30px;
  border-bottom: 1px solid var(--oms-modal-border);
  background: var(--oms-modal-surface-bg);
}

.oms-warehouse-delivery-steps::before {
  content: "";
  position: absolute;
  right: 62px;
  top: 31px;
  width: min(470px, 42vw);
  height: 2px;
  background: #dbe4f0;
}

.oms-warehouse-delivery-steps button {
  position: relative;
  z-index: 1;
  border-radius: 999px;
  color: #8a96aa;
  padding: 4px 0;
}

.oms-warehouse-delivery-steps button span {
  width: 30px;
  height: 30px;
  border-color: #cbd7e6;
  color: #718097;
  font-size: 13px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
}

.oms-warehouse-delivery-steps button.active span,
.oms-warehouse-delivery-steps button.done span {
  border-color: #2563eb;
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.24);
}

.oms-warehouse-delivery-steps button.active {
  color: #111827;
}

.oms-warehouse-delivery-modal-shell .oms-warehouse-product-detail-tabs {
  min-height: 48px;
  border-bottom: 1px solid var(--oms-modal-border);
  background: var(--oms-modal-surface-muted);
  padding: 0 24px;
  gap: 2px;
}

.oms-warehouse-delivery-modal-shell .oms-warehouse-product-detail-tabs button {
  position: relative;
  border-radius: 0;
  color: #65748a;
  padding: 0 12px;
  font-weight: 900;
}

.oms-warehouse-delivery-modal-shell .oms-warehouse-product-detail-tabs button:hover {
  color: #1d4ed8;
  background: #edf5ff;
}

.oms-warehouse-delivery-modal-shell .oms-warehouse-product-detail-tabs button.active {
  color: #1d4ed8;
  background: #ffffff;
  box-shadow: inset 0 -3px 0 #2563eb;
}

.oms-warehouse-delivery-panel {
  padding: 26px 28px 30px;
  background:
    linear-gradient(180deg, var(--oms-modal-surface-muted) 0%, var(--oms-modal-surface-bg) 42%),
    var(--oms-modal-surface-bg);
}

.oms-return-decision-panel {
  display: grid;
  grid-template-columns: minmax(180px, 220px) minmax(260px, 1fr) auto;
  gap: 10px 12px;
  align-items: end;
  margin-bottom: 16px;
  padding: 14px;
  border: 1px solid #dbe7f5;
  border-radius: 16px;
  background: linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.045);
}

.oms-return-decision-panel label {
  display: grid;
  gap: 6px;
}

.oms-return-decision-panel label > span {
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.oms-return-decision-panel select,
.oms-return-decision-panel input {
  min-height: 38px;
  border: 1px solid #d6e1ef;
  border-radius: 12px;
  background: #ffffff;
  color: #0f172a;
  font-size: 14px;
  font-weight: 800;
  padding: 0 12px;
}

.oms-return-decision-panel small {
  grid-column: 1 / -1;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.oms-return-warehouse-panel,
.oms-return-correction-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 14px;
  align-items: center;
  margin-bottom: 16px;
  padding: 14px;
  border: 1px solid #bbf7d0;
  border-radius: 16px;
  background: linear-gradient(135deg, #f0fdf4 0%, #ffffff 100%);
  box-shadow: 0 10px 28px rgba(22, 163, 74, 0.07);
}

.oms-return-correction-panel {
  border-color: #c4b5fd;
  background: linear-gradient(135deg, #f5f3ff 0%, #ffffff 100%);
  box-shadow: 0 10px 28px rgba(124, 58, 237, 0.08);
}

.oms-return-warehouse-panel strong,
.oms-return-warehouse-panel span,
.oms-return-warehouse-panel small,
.oms-return-correction-panel strong,
.oms-return-correction-panel span,
.oms-return-correction-panel small {
  display: block;
}

.oms-return-warehouse-panel strong {
  color: #14532d;
  font-size: 14px;
  font-weight: 950;
}

.oms-return-correction-panel strong {
  color: #4c1d95;
  font-size: 14px;
  font-weight: 950;
}

.oms-return-warehouse-panel span {
  margin-top: 3px;
  color: #475569;
  font-size: 12px;
  font-weight: 750;
}

.oms-return-correction-panel span {
  margin-top: 3px;
  color: #475569;
  font-size: 12px;
  font-weight: 750;
}

.oms-return-warehouse-panel small {
  grid-column: 1 / -1;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.oms-return-correction-panel small {
  grid-column: 1 / -1;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.oms-btn-light.violet {
  border-color: #c4b5fd;
  background: #ede9fe;
  color: #5b21b6;
}

.oms-btn-light.violet:hover:not(:disabled) {
  border-color: #a78bfa;
  background: #ddd6fe;
  color: #4c1d95;
}

.oms-return-detail-modal {
  grid-template-rows: auto minmax(0, 1fr) auto;
  background: #f4f6fa;
}

.oms-return-detail-modal > header.oms-return-detail-header {
  min-height: 82px;
  padding: 16px 26px;
  background:
    linear-gradient(90deg, rgba(124, 58, 237, 0.08), transparent 42%),
    #ffffff;
}

.oms-return-detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.oms-return-detail-title {
  display: flex !important;
  grid-template-columns: none !important;
  align-items: center;
  gap: 14px !important;
  min-width: 0;
}

.oms-return-detail-type {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid #c4b5fd !important;
  border-radius: 8px !important;
  background: linear-gradient(135deg, #7c3aed, #2563eb) !important;
  color: #ffffff !important;
  padding: 0 !important;
  font-size: 12px !important;
  font-weight: 900 !important;
  letter-spacing: 0.08em !important;
  line-height: 1;
  box-shadow: 0 10px 22px rgba(124, 58, 237, 0.22) !important;
}

.oms-return-detail-title > div {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.oms-return-detail-title strong {
  color: #111827;
  font-size: clamp(22px, 2vw, 30px) !important;
  font-weight: 850 !important;
  letter-spacing: -0.03em !important;
}

.oms-return-detail-title span:not(.oms-return-detail-type) {
  display: block;
  width: fit-content;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border: 0 !important;
  background: transparent !important;
  color: #667085 !important;
  padding: 0 !important;
  box-shadow: none !important;
  font-size: 14px !important;
  font-weight: 650 !important;
}

.oms-return-detail-header-actions {
  display: flex !important;
  grid-template-columns: none !important;
  align-items: center;
  justify-content: flex-end;
  gap: 10px !important;
}

.oms-return-detail-back {
  min-height: 40px;
  border: 1px solid #93c5fd;
  border-radius: 999px;
  background: #ffffff;
  color: #2563eb;
  font-size: 14px;
  font-weight: 850;
  padding: 0 18px;
  cursor: pointer;
}

.oms-return-detail-back:hover {
  border-color: #2563eb;
  background: #eff6ff;
}

.oms-return-detail-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 22px;
  min-height: 0;
  padding: 24px 28px 34px;
  overflow: auto;
}

.oms-return-detail-items-card,
.oms-return-detail-info-card {
  border: 1px solid #d8e1ee;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

.oms-return-detail-items-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.oms-return-detail-items-table th {
  height: 48px;
  border-bottom: 1px solid #d8e1ee;
  background: #f3f6fa;
  color: #344054;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.02em;
  text-align: left;
  text-transform: uppercase;
}

.oms-return-detail-items-table th:first-child {
  width: 82px;
  text-align: center;
}

.oms-return-detail-items-table th:nth-child(3),
.oms-return-detail-items-table th:nth-child(4) {
  width: 120px;
}

.oms-return-detail-items-table th:nth-child(5) {
  width: 230px;
}

.oms-return-detail-items-table th:nth-child(6) {
  width: 260px;
}

.oms-return-detail-items-table td {
  border-bottom: 1px solid #e3e9f2;
  padding: 12px 10px;
  vertical-align: middle;
}

.oms-return-detail-items-table tr:last-child td {
  border-bottom: 0;
}

.oms-return-detail-thumb {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  margin: 0 auto;
  border: 1px solid #dbe5f1;
  border-radius: 8px;
  background: #f8fafc;
  overflow: hidden;
}

.oms-return-detail-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.oms-return-detail-thumb span {
  color: #94a3b8;
  font-size: 24px;
}

.oms-return-detail-product {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.oms-return-detail-product strong {
  color: #1f2937;
  font-size: 15px;
  font-weight: 850;
  line-height: 1.3;
}

.oms-return-detail-product span {
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
}

.oms-return-detail-number {
  color: #111827;
  font-size: 18px;
  font-weight: 850;
  text-align: center;
}

.oms-return-detail-qty,
.oms-return-detail-line select,
.oms-return-detail-note {
  width: 100%;
  min-height: 40px;
  border: 1px solid #d6e1ef;
  border-radius: 8px;
  background: #ffffff;
  color: #111827;
  font-size: 14px;
  font-weight: 750;
  padding: 0 12px;
}

.oms-return-detail-qty {
  text-align: center;
}

.oms-return-detail-qty:focus,
.oms-return-detail-line select:focus,
.oms-return-detail-note:focus,
.oms-return-money-input input:focus,
.oms-return-decision-field input:focus,
.oms-return-decision-field select:focus {
  border-color: #7c3aed;
  outline: 0;
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
}

.oms-return-detail-info-card {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
  gap: 28px;
  padding: 24px;
}

.oms-return-detail-info-card.smart {
  grid-template-columns: minmax(280px, 0.75fr) minmax(520px, 1.25fr);
  align-items: stretch;
}

.oms-return-info-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 18px;
}

.oms-return-info-title span {
  color: #111827;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.oms-return-info-title strong {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border-radius: 999px;
  background: #eff6ff;
  color: #2563eb;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
}

.oms-return-detail-info-main h3 {
  margin: 0 0 22px;
  color: #1f2937;
  font-size: 22px;
  font-weight: 850;
  letter-spacing: -0.02em;
}

.oms-return-money-row {
  display: grid;
  grid-template-columns: 120px auto 1fr;
  align-items: center;
  gap: 10px;
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid #d8e1ee;
}

.oms-return-money-row span,
.oms-return-info-row span,
.oms-return-status-control span,
.oms-return-detail-docs span,
.oms-return-decision-field > span {
  color: #5f6f86;
  font-size: 13px;
  font-weight: 750;
}

.oms-return-money-row strong {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  width: fit-content;
  border-radius: 6px;
  background: #e5e7eb;
  color: #475569;
  padding: 0 12px;
  font-size: 15px;
  font-weight: 900;
}

.oms-return-money-row em {
  color: #475569;
  font-style: normal;
  font-size: 15px;
  font-weight: 800;
}

.oms-return-info-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 10px;
  min-height: 30px;
  align-items: center;
}

.oms-return-info-row strong {
  color: #1f2937;
  font-size: 14px;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.oms-return-detail-workflow {
  display: grid;
  align-content: start;
  gap: 12px;
}

.oms-return-workflow-stack {
  display: grid;
  gap: 14px;
}

.oms-return-settlement-card {
  border: 1px solid #d8b4fe;
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(124, 58, 237, 0.08), rgba(37, 99, 235, 0.06)),
    #ffffff;
  box-shadow: 0 12px 28px rgba(124, 58, 237, 0.10);
  padding: 16px;
}

.oms-return-settlement-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.oms-return-settlement-head h3 {
  margin: 0;
  color: #111827;
  font-size: 18px;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.oms-return-settlement-head p {
  max-width: 520px;
  margin: 4px 0 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
}

.oms-return-settlement-head > span {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  border-radius: 999px;
  background: #ede9fe;
  color: #5b21b6;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 900;
}

.oms-return-settlement-grid {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.oms-return-settlement-grid label {
  display: grid;
  gap: 6px;
}

.oms-return-settlement-grid label > span {
  color: #475569;
  font-size: 12px;
  font-weight: 850;
}

.oms-return-money-input {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  min-height: 44px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #ffffff;
  overflow: hidden;
}

.oms-return-money-input input {
  width: 100%;
  min-height: 42px;
  border: 0;
  background: transparent;
  color: #111827;
  font-size: 18px;
  font-weight: 900;
  padding: 0 12px;
}

.oms-return-money-input strong {
  border-left: 1px solid #e2e8f0;
  color: #64748b;
  padding: 0 12px;
  font-size: 13px;
  font-weight: 900;
}

.oms-return-settlement-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.oms-return-settlement-presets button {
  min-height: 34px;
  border: 1px solid #dbe4f0;
  border-radius: 999px;
  background: #ffffff;
  color: #475569;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.oms-return-settlement-presets button:hover {
  border-color: #7c3aed;
  color: #5b21b6;
}

.oms-return-settlement-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(124, 58, 237, 0.16);
}

.oms-return-settlement-footer > span {
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
}

.oms-return-settlement-footer > span strong {
  color: #111827;
  font-weight: 900;
}

.oms-btn-light.violet {
  border-color: #c4b5fd;
  background: #7c3aed;
  color: #ffffff;
}

.oms-btn-light.violet:hover:not(:disabled) {
  background: #6d28d9;
}

.oms-return-status-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 42px;
  border: 1px solid #dbe4f0;
  border-radius: 8px;
  background: #f8fafc;
  padding: 0 12px;
}

.oms-return-status-pill span {
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}

.oms-return-status-pill strong {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  border-radius: 999px;
  background: #ede9fe;
  color: #5b21b6;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
}

.oms-return-status-control,
.oms-return-decision-field {
  display: grid;
  gap: 6px;
}

.oms-return-status-control {
  grid-template-columns: 86px minmax(0, 1fr);
  align-items: center;
}

.oms-return-status-control select,
.oms-return-decision-field select,
.oms-return-decision-field input {
  min-height: 40px;
  border: 1px solid #d6e1ef;
  border-radius: 8px;
  background: #ffffff;
  color: #111827;
  font-size: 14px;
  font-weight: 800;
  padding: 0 12px;
}

.oms-return-status-control select:disabled {
  background: #f8fafc;
  color: #475569;
  opacity: 1;
}

.oms-return-detail-docs {
  display: grid;
  gap: 8px;
  padding: 12px 0;
  border-top: 1px solid #d8e1ee;
  border-bottom: 1px solid #d8e1ee;
}

.oms-return-detail-docs div {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.oms-return-detail-docs strong {
  color: #1f2937;
  font-size: 14px;
  font-weight: 800;
}

.oms-return-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 2px;
}

.oms-return-refund-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border: 1px solid #fbbf24;
  border-radius: 8px;
  background: #fffbeb;
  padding: 12px;
}

.oms-return-refund-card > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.oms-return-refund-card strong {
  color: #92400e;
  font-size: 13px;
  font-weight: 900;
}

.oms-return-refund-card span,
.oms-return-refund-card small {
  color: #78350f;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.4;
}

.oms-return-refund-card.success {
  border-color: #86efac;
  background: #f0fdf4;
}

.oms-return-refund-card.success strong,
.oms-return-refund-card.success span {
  color: #166534;
}

.oms-return-refund-card.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-return-refund-card.blocked strong,
.oms-return-refund-card.blocked span {
  color: #991b1b;
}

.oms-return-safe-note {
  margin: 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
}

.oms-app[data-theme="dark"] .oms-return-detail-modal {
  background: #111827;
}

.oms-app[data-theme="dark"] .oms-return-detail-modal > header.oms-return-detail-header,
.oms-app[data-theme="dark"] .oms-return-detail-items-card,
.oms-app[data-theme="dark"] .oms-return-detail-info-card {
  border-color: #334155;
  background: #172033;
}

.oms-app[data-theme="dark"] .oms-return-detail-items-table th {
  border-color: #334155;
  background: #1f2937;
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-return-detail-items-table td,
.oms-app[data-theme="dark"] .oms-return-money-row,
.oms-app[data-theme="dark"] .oms-return-detail-docs {
  border-color: #334155;
}

.oms-app[data-theme="dark"] .oms-return-detail-title strong,
.oms-app[data-theme="dark"] .oms-return-detail-product strong,
.oms-app[data-theme="dark"] .oms-return-detail-number,
.oms-app[data-theme="dark"] .oms-return-detail-info-main h3,
.oms-app[data-theme="dark"] .oms-return-info-row strong,
.oms-app[data-theme="dark"] .oms-return-detail-docs strong {
  color: #e5e7eb;
}

.oms-app[data-theme="dark"] .oms-return-detail-title span:not(.oms-return-detail-type),
.oms-app[data-theme="dark"] .oms-return-detail-product span,
.oms-app[data-theme="dark"] .oms-return-safe-note {
  color: #94a3b8 !important;
}

.oms-app[data-theme="dark"] .oms-return-settlement-card,
.oms-app[data-theme="dark"] .oms-return-money-input,
.oms-app[data-theme="dark"] .oms-return-status-pill,
.oms-app[data-theme="dark"] .oms-return-settlement-presets button,
.oms-app[data-theme="dark"] .oms-return-refund-card {
  border-color: #334155;
  background: #111827;
}

.oms-app[data-theme="dark"] .oms-return-settlement-head h3,
.oms-app[data-theme="dark"] .oms-return-info-title span,
.oms-app[data-theme="dark"] .oms-return-money-input input,
.oms-app[data-theme="dark"] .oms-return-settlement-footer > span strong,
.oms-app[data-theme="dark"] .oms-return-status-pill strong {
  color: #e5e7eb;
}

.oms-app[data-theme="dark"] .oms-return-refund-card strong,
.oms-app[data-theme="dark"] .oms-return-refund-card span,
.oms-app[data-theme="dark"] .oms-return-refund-card small {
  color: #e5e7eb;
}

@media (max-width: 1100px) {
  .oms-return-detail-info-card {
    grid-template-columns: 1fr;
  }

  .oms-return-detail-items-table {
    min-width: 980px;
  }

  .oms-return-detail-items-card {
    overflow-x: auto;
  }
}

.oms-warehouse-delivery-toast-stack {
  border-bottom-color: #dbe4f0;
  background:
    linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
  padding: 9px 28px;
}

.oms-warehouse-delivery-toast-stack .oms-warehouse-action-status,
.oms-warehouse-delivery-toast-stack .oms-invoice-pdf-error,
.oms-warehouse-delivery-toast-stack .oms-warehouse-delivery-autosave {
  width: fit-content;
  max-width: min(100%, 520px);
}

.oms-warehouse-delivery-form-grid {
  gap: 20px 24px;
}

.oms-warehouse-delivery-form-grid label {
  border: 1px solid #e4ebf5;
  border-radius: 14px;
  background: #ffffff;
  padding: 12px;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.035);
}

.oms-warehouse-delivery-upload-card {
  display: grid;
  gap: 6px;
  border: 1px solid #dbe7f5;
  border-radius: 14px;
  background:
    linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
  padding: 12px;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.035);
}

.oms-warehouse-delivery-upload-card > span {
  color: #65748a;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.015em;
  text-transform: uppercase;
}

.oms-warehouse-delivery-upload-card > strong {
  min-width: 0;
  color: #111827;
  font-size: 14px;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-delivery-upload-card > em,
.oms-warehouse-delivery-upload-card > small {
  color: #64748b;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.oms-warehouse-delivery-upload-card > small {
  color: #b91c1c;
}

.oms-warehouse-delivery-upload-card > div {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}

.oms-warehouse-delivery-upload-card input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.oms-warehouse-delivery-upload-card .oms-btn-light.disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.oms-warehouse-delivery-form-grid label > span,
.oms-warehouse-delivery-edit-line label > span {
  color: #65748a;
  font-size: 11px;
  letter-spacing: 0.015em;
  text-transform: uppercase;
}

.oms-warehouse-delivery-form-grid input,
.oms-warehouse-delivery-form-grid select,
.oms-warehouse-delivery-edit-line input,
.oms-warehouse-delivery-extra-row input,
.oms-warehouse-delivery-extra-row select,
.oms-warehouse-delivery-search input,
.oms-warehouse-delivery-notes {
  border-color: #d6e0ed;
  background: #fbfdff;
  color: #111827;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.oms-warehouse-delivery-form-grid input:hover,
.oms-warehouse-delivery-form-grid select:hover,
.oms-warehouse-delivery-edit-line input:hover,
.oms-warehouse-delivery-extra-row input:hover,
.oms-warehouse-delivery-extra-row select:hover,
.oms-warehouse-delivery-search input:hover,
.oms-warehouse-delivery-notes:hover {
  border-color: #b8c7da;
  background: #ffffff;
}

.oms-warehouse-delivery-search {
  grid-template-columns: minmax(0, 1fr) 82px;
  gap: 12px;
  margin-bottom: 16px;
  border: 1px solid #dbe7f5;
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(239, 246, 255, 0.9), rgba(255, 255, 255, 0.95));
  padding: 12px;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.055);
}

.oms-warehouse-delivery-search::before {
  content: "";
  position: absolute;
  left: 28px;
  top: 50%;
  width: 13px;
  height: 13px;
  transform: translateY(-58%);
  border: 2px solid #8aa0bd;
  border-radius: 999px;
  pointer-events: none;
}

.oms-warehouse-delivery-search::after {
  content: "";
  position: absolute;
  left: 40px;
  top: 50%;
  width: 8px;
  height: 2px;
  transform: translateY(5px) rotate(45deg);
  border-radius: 999px;
  background: #8aa0bd;
  pointer-events: none;
}

.oms-warehouse-delivery-search input {
  min-height: 44px;
  border-radius: 12px;
  padding-left: 42px;
  font-size: 15px;
  background: #ffffff;
}

.oms-warehouse-delivery-search .oms-btn-light {
  min-height: 44px;
  border-radius: 12px;
  font-weight: 900;
}

.oms-warehouse-delivery-search-results {
  grid-template-columns: repeat(auto-fill, minmax(420px, 1fr));
  gap: 12px;
  margin: 0 0 18px;
  padding: 12px;
  border-color: #cfe0f5;
  border-radius: 16px;
  background:
    linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.06);
}

.oms-warehouse-delivery-search-results button {
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 13px;
  min-height: 74px;
  border-color: #d9e5f3;
  border-radius: 14px;
  padding: 10px 12px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.045);
}

.oms-warehouse-delivery-search-results button:hover {
  transform: translateY(-1px);
  border-color: #93c5fd;
  background: #f5faff;
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.12);
}

.oms-warehouse-delivery-search-img {
  width: 54px;
  height: 54px;
  border-radius: 12px;
  border-color: #dbe4f0;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}

.oms-warehouse-delivery-search-copy strong {
  font-size: 14px;
  letter-spacing: -0.01em;
}

.oms-warehouse-delivery-edit-lines {
  position: relative;
  border-color: #cfdae9;
  border-radius: 16px;
  overflow-x: auto;
  background: #ffffff;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.07);
}

.oms-warehouse-delivery-edit-lines.is-empty {
  box-shadow: none;
}

.oms-warehouse-delivery-lines-header,
.oms-warehouse-delivery-edit-line {
  min-width: 1480px;
}

.oms-warehouse-delivery-lines-header {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 12px 14px;
  background: #eef4fb;
  color: #53657d;
  border-bottom-color: #cbd8e8;
}

.oms-warehouse-delivery-edit-line {
  min-height: 74px;
  padding: 12px 14px;
  background: #ffffff;
  transition: background 0.15s ease, box-shadow 0.15s ease;
}

.oms-warehouse-delivery-edit-line:nth-child(odd) {
  background: #fbfdff;
}

.oms-warehouse-delivery-edit-line:hover {
  background: #f5faff;
  box-shadow: inset 3px 0 0 #3b82f6;
}

.oms-warehouse-delivery-edit-line.is-new {
  background:
    linear-gradient(90deg, rgba(239, 246, 255, 0.95), #ffffff 34%);
  box-shadow: inset 3px 0 0 #93c5fd;
}

.oms-warehouse-delivery-edit-line.is-new:hover {
  background:
    linear-gradient(90deg, rgba(219, 234, 254, 0.98), #ffffff 38%);
}

.oms-warehouse-delivery-image {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  border-color: #dbe4f0;
  background: #f1f5f9;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.08);
}

.oms-warehouse-delivery-edit-line.is-new .oms-warehouse-delivery-image {
  border-style: dashed;
  border-color: #93c5fd;
  background: #eff6ff;
  color: #2563eb;
  font-size: 18px;
}

.oms-warehouse-delivery-edit-line input {
  min-height: 40px;
  border-radius: 11px;
  font-size: 13px;
}

.oms-warehouse-delivery-product-field input {
  font-size: 14px;
  letter-spacing: -0.01em;
  background: #ffffff;
}

.oms-warehouse-delivery-edit-line em {
  color: #6b7c93;
  font-size: 11px;
}

.oms-warehouse-delivery-edit-line > strong {
  border-radius: 999px;
  background: #eff6ff;
  color: #0f172a;
  padding: 8px 10px;
  text-align: center;
}

.oms-warehouse-inventory-count-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 16px;
}

.oms-warehouse-inventory-count-summary span,
.oms-warehouse-inventory-diff {
  display: grid;
  gap: 2px;
  align-items: center;
  border-radius: 14px;
  border: 1px solid #dbe6f4;
  background: #f8fbff;
  color: #0f172a;
  padding: 10px 12px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.oms-warehouse-inventory-count-summary strong,
.oms-warehouse-inventory-diff {
  font-variant-numeric: tabular-nums;
}

.oms-warehouse-inventory-count-summary em,
.oms-warehouse-inventory-diff span {
  color: #64748b;
  font-size: 10px;
  font-style: normal;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.oms-warehouse-inventory-count-summary .is-plus,
.oms-warehouse-inventory-diff.is-plus {
  border-color: #bbf7d0;
  background: #ecfdf3;
  color: #15803d;
}

.oms-warehouse-inventory-count-summary .is-minus,
.oms-warehouse-inventory-diff.is-minus {
  border-color: #fecaca;
  background: #fff1f2;
  color: #be123c;
}

.oms-warehouse-inventory-count-summary .is-zero,
.oms-warehouse-inventory-diff.is-zero {
  border-color: #dbe6f4;
  background: #f8fbff;
  color: #334155;
}

.oms-warehouse-inventory-diff.is-empty {
  color: #94a3b8;
}

.oms-warehouse-inventory-autosave {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  max-width: 100%;
  margin: 12px 0;
  padding: 8px 12px;
  border: 1px solid #dbe6f5;
  border-radius: 999px;
  background: #f8fbff;
  color: #52627a;
  font-size: 12px;
  line-height: 1.25;
}

.oms-warehouse-inventory-autosave strong {
  color: #172033;
  font-weight: 800;
}

.oms-warehouse-inventory-autosave span {
  color: #64748b;
  font-weight: 700;
}

.oms-warehouse-inventory-autosave.is-saving,
.oms-warehouse-inventory-autosave.is-dirty {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-warehouse-inventory-autosave.is-error {
  border-color: #fecaca;
  background: #fff1f2;
}

.oms-warehouse-inventory-autosave.is-error strong,
.oms-warehouse-inventory-autosave.is-error span {
  color: #be123c;
}

.oms-warehouse-delivery-edit-line > button {
  border-radius: 11px;
  background: #f8fafc;
}

.oms-warehouse-delivery-edit-line.is-new > button {
  visibility: hidden;
}

.oms-warehouse-delivery-extra-panel {
  display: grid;
  gap: 14px;
}

.oms-warehouse-delivery-extra-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid #dbe7f5;
  border-radius: 16px;
  background:
    linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
  padding: 16px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.055);
}

.oms-warehouse-delivery-extra-head strong {
  display: block;
  color: #111827;
  font-size: 16px;
  font-weight: 950;
  letter-spacing: -0.01em;
}

.oms-warehouse-delivery-extra-head span {
  display: block;
  margin-top: 2px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.oms-warehouse-delivery-extra-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.oms-warehouse-delivery-extra-summary span {
  border: 1px solid #dbe7f5;
  border-radius: 999px;
  background: #ffffff;
  color: #64748b;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 850;
}

.oms-warehouse-delivery-extra-summary strong {
  color: #111827;
}

.oms-warehouse-delivery-extra-list {
  display: grid;
  gap: 8px;
}

.oms-warehouse-delivery-extra-row {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 130px minmax(220px, 0.8fr) minmax(180px, 0.8fr) 120px 38px;
  gap: 10px;
  align-items: center;
  border: 1px solid #dbe4f0;
  border-radius: 14px;
  background: #ffffff;
  padding: 10px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
}

.oms-warehouse-delivery-extra-row strong {
  justify-self: end;
  border-radius: 999px;
  background: #eff6ff;
  color: #111827;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 950;
  white-space: nowrap;
}

.oms-warehouse-delivery-extra-row button {
  width: 34px;
  height: 34px;
  border: 1px solid #dbe3ef;
  border-radius: 10px;
  background: #ffffff;
  color: #64748b;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.oms-warehouse-delivery-extra-row button:hover {
  border-color: #fecaca;
  color: #dc2626;
}

.oms-warehouse-delivery-notes {
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.055);
}

.oms-warehouse-delivery-autosave {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: min(100%, 440px);
  margin: 0 0 12px 8px;
  border: 1px solid #dbe7f5;
  border-radius: 999px;
  background: #ffffff;
  color: #64748b;
  padding: 7px 11px;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.2;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.04);
}

.oms-warehouse-delivery-autosave.error {
  border-color: #fecaca;
  background: #fff7f7;
  color: #b91c1c;
}

.oms-warehouse-delivery-modal-shell > footer {
  min-height: 72px;
  padding: 14px 28px;
  border-top: 1px solid var(--oms-modal-border);
  background: var(--oms-modal-footer-bg);
  backdrop-filter: blur(10px);
  box-shadow: 0 -16px 36px rgba(15, 23, 42, 0.06);
}

.oms-warehouse-delivery-modal-shell > footer .oms-control-actions {
  margin-top: 0;
}

.oms-warehouse-delivery-price-checkbox {
  border: 1px solid #dbe4f0;
  border-radius: 999px;
  background: #ffffff;
  padding: 9px 12px;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
}

@media (max-width: 760px) {
  .oms-warehouse-product-row {
    grid-template-columns: 44px minmax(0, 1fr);
  }

  .oms-warehouse-product-stock {
    grid-column: 2;
    justify-items: start;
  }

  .oms-warehouse-product-price {
    grid-column: 2;
  }

  .oms-warehouse-variant-expansion {
    padding: 10px;
  }

  .oms-warehouse-variant-expansion-head {
    display: grid;
  }

  .oms-warehouse-variant-row {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .oms-warehouse-variant-row em,
  .oms-warehouse-variant-row b,
  .oms-warehouse-variant-row i,
  .oms-warehouse-variant-row small {
    grid-column: 2;
  }

  .oms-warehouse-product-row > .oms-control-status {
    grid-column: 2;
    justify-self: start;
  }

  .oms-warehouse-product-detail-head,
  .oms-warehouse-product-detail-grid,
  .oms-warehouse-product-detail-metrics {
    grid-template-columns: 1fr;
  }

  .oms-warehouse-product-detail-head {
    display: grid;
  }

  .oms-warehouse-deliveries-head,
  .oms-warehouse-delivery-row,
  .oms-warehouse-delivery-lines-head,
  .oms-warehouse-delivery-line {
    grid-template-columns: minmax(0, 1fr);
  }

  .oms-warehouse-deliveries-head {
    display: none;
  }

  .oms-warehouse-delivery-row {
    gap: 5px;
    padding: 10px;
  }

  .oms-warehouse-delivery-lines-head {
    display: none;
  }

  .oms-warehouse-delivery-line {
    gap: 5px;
    padding: 10px;
  }

  .oms-warehouse-delivery-modal-shell {
    inset: 8px;
  }

  .oms-warehouse-delivery-form-grid,
  .oms-warehouse-delivery-edit-line,
  .oms-warehouse-delivery-search {
    grid-template-columns: 1fr;
  }

  .oms-warehouse-delivery-steps,
  .oms-warehouse-delivery-modal-shell > footer {
    align-items: stretch;
    flex-direction: column;
  }
}

.oms-shipment-card.selected {
  border-color: var(--oms-green-500);
  box-shadow: 0 0 0 2px rgba(22, 163, 74, 0.12);
}

.oms-automation-grid {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr));
  gap: 12px;
}

.oms-automation-card {
  display: grid;
  min-width: 0;
  gap: 14px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 14px;
  background: #ffffff;
  padding: 16px;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.04);
}

.oms-automation-card-primary {
  min-height: 168px;
}

.oms-automation-card.on {
  border-color: #bfdbfe;
  background: linear-gradient(180deg, #eff6ff 0%, #ffffff 100%);
}

.oms-automation-card.off {
  border-color: #e2e8f0;
}

.oms-store-sync-summary {
  border-color: #c7d2fe;
  background: #eef2ff;
}

.oms-store-sync-card {
  display: grid;
  min-width: 0;
  min-height: 156px;
  gap: 14px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 14px;
  background: #ffffff;
  padding: 16px;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.04);
}

.oms-store-sync-card.on {
  border-color: #bfdbfe;
  background: linear-gradient(180deg, #eff6ff 0%, #ffffff 100%);
}

.oms-store-sync-card.off {
  border-color: #fed7aa;
  background: linear-gradient(180deg, #fff7ed 0%, #ffffff 100%);
}

.oms-automation-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.oms-automation-card-head > div {
  min-width: 0;
}

.oms-automation-group {
  color: var(--oms-slate-400);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

.oms-automation-title {
  margin-top: 5px;
  color: var(--oms-slate-950);
  font-size: 17px;
  font-weight: 950;
  overflow-wrap: break-word;
}

.oms-automation-subtitle {
  margin-top: 5px;
  color: var(--oms-slate-600);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.45;
  overflow-wrap: break-word;
}

.oms-modern-switch {
  position: relative;
  flex: 0 0 auto;
  width: 58px;
  height: 32px;
  border: 0;
  border-radius: 999px;
  background: #cbd5e1;
  cursor: pointer;
  transition: background 0.18s ease, opacity 0.18s ease;
}

.oms-modern-switch span {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: #ffffff;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.22);
  transition: transform 0.18s ease;
}

.oms-modern-switch.on {
  background: #2563eb;
}

.oms-modern-switch.on span {
  transform: translateX(26px);
}

.oms-modern-switch.locked {
  cursor: not-allowed;
  opacity: 0.55;
}

.oms-automation-state {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.4;
}

.oms-automation-pill {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 11px;
  font-weight: 950;
}

.oms-automation-pill.on {
  background: #dbeafe;
  color: #1d4ed8;
}

.oms-automation-pill.off {
  background: #f1f5f9;
  color: var(--oms-slate-600);
}

.oms-automation-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  border-top: 1px solid #eef2f7;
  padding-top: 12px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 800;
}

.oms-automation-meta strong {
  color: var(--oms-slate-700);
  text-align: right;
}

.oms-control-details {
  grid-column: 1 / -1;
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.035);
}

.oms-control-details summary {
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 14px;
  color: var(--oms-slate-900);
  font-size: 14px;
  font-weight: 950;
  cursor: pointer;
  list-style: none;
}

.oms-control-details summary::-webkit-details-marker {
  display: none;
}

.oms-control-details summary::after {
  content: "Rozwiń";
  border-radius: 999px;
  background: var(--oms-slate-100);
  padding: 5px 9px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 900;
}

.oms-control-details[open] summary::after {
  content: "Zwiń";
}

.oms-control-details summary em {
  margin-left: auto;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.oms-safety-flag-list {
  display: grid;
  gap: 8px;
  border-top: 1px solid #eef2f7;
  padding: 12px;
}

.oms-safety-flag-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: var(--oms-slate-50);
  padding: 12px;
}

.oms-safety-flag-row.on {
  border-color: #fecaca;
  background: #fff7ed;
}

.oms-safety-flag-main {
  display: flex;
  min-width: 0;
  align-items: flex-start;
  gap: 10px;
}

.oms-safety-flag-main strong,
.oms-safety-flag-main span {
  display: block;
}

.oms-safety-flag-main strong {
  color: var(--oms-slate-900);
  font-size: 13px;
  font-weight: 950;
}

.oms-safety-flag-main span {
  margin-top: 3px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.35;
}

.oms-safety-dot {
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  border-radius: 999px;
  margin-top: 4px;
  background: var(--oms-green-500);
}

.oms-safety-dot.on {
  background: #ef4444;
}

.oms-safety-dot.off {
  background: var(--oms-green-500);
}

.oms-safety-flag-side {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
}

.oms-safety-flag-side small {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 800;
}

.oms-control-history-list {
  border-top: 1px solid #eef2f7;
  padding: 12px;
}

.oms-feature-flag-actions {
  margin-top: 12px;
}

.oms-control-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.oms-fresh-test-order-result {
  display: grid;
  gap: 4px;
  margin-top: 12px;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  background: #f0fdf4;
  padding: 10px 12px;
}

.oms-fresh-test-order-result strong {
  color: var(--oms-slate-950);
  font-size: 14px;
  font-weight: 950;
}

.oms-fresh-test-order-result span {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.oms-fresh-test-order-result .oms-inline-error {
  color: #b91c1c;
}

.oms-control-footnote {
  margin-top: 12px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 700;
}

.oms-control-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.oms-control-label {
  color: var(--oms-slate-900);
  font-size: 15px;
  font-weight: 800;
}

.oms-control-key {
  margin-top: 4px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.oms-control-status {
  min-width: 46px;
  border-radius: 999px;
  padding: 6px 8px;
  text-align: center;
  font-size: 11px;
  font-weight: 900;
}

.oms-control-status.on {
  background: #fee2e2;
  color: #b91c1c;
}

.oms-control-status.off {
  background: var(--oms-green-50);
  color: var(--oms-green-600);
}

.oms-control-status.wait {
  background: #fef3c7;
  color: #92400e;
}

.oms-control-status.info {
  background: #dbeafe;
  color: #1d4ed8;
}

.oms-control-status.cancelled {
  background: #f1f5f9;
  color: #64748b;
}

.oms-control-meta {
  display: grid;
  gap: 8px;
  margin-top: 18px;
  color: var(--oms-slate-600);
  font-size: 12px;
  line-height: 1.45;
}

.oms-admin-users-card {
  grid-column: 1 / -1;
}

.oms-admin-users-list {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}

.oms-admin-user-row {
  display: grid;
  grid-template-columns: minmax(260px, 1.2fr) minmax(110px, 0.55fr) minmax(96px, 0.5fr) minmax(150px, 0.65fr) minmax(76px, 0.35fr);
  align-items: center;
  gap: 12px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
  background: #f8fafc;
  padding: 10px 12px;
}

.oms-admin-user-main {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
}

.oms-admin-user-main strong,
.oms-admin-user-main small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-admin-user-main strong {
  color: var(--oms-slate-900);
  font-size: 13px;
  font-weight: 900;
}

.oms-admin-user-main small,
.oms-admin-user-last,
.oms-admin-user-count {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 800;
}

.oms-admin-user-role {
  justify-self: start;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  padding: 5px 9px;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 900;
}

.oms-permission-matrix-card {
  grid-column: 1 / -1;
}

.oms-permission-role-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 14px;
}

.oms-permission-role-summary span {
  border: 1px solid var(--oms-slate-200);
  border-radius: 999px;
  background: #f8fafc;
  padding: 5px 8px;
  color: var(--oms-slate-600);
  font-size: 11px;
  font-weight: 850;
}

.oms-permission-matrix-table-wrap {
  margin-top: 14px;
  overflow-x: auto;
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
}

.oms-permission-matrix-table {
  width: 100%;
  min-width: 920px;
  border-collapse: collapse;
  background: white;
}

.oms-permission-matrix-table th,
.oms-permission-matrix-table td {
  border-bottom: 1px solid var(--oms-slate-200);
  padding: 10px;
  text-align: center;
  vertical-align: middle;
}

.oms-permission-matrix-table th {
  background: #f8fafc;
  color: var(--oms-slate-700);
  font-size: 11px;
  font-weight: 900;
}

.oms-permission-matrix-table th span,
.oms-permission-matrix-table th small {
  display: block;
}

.oms-permission-matrix-table th small {
  max-width: 150px;
  overflow: hidden;
  color: var(--oms-slate-400);
  font-size: 9px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-permission-module-cell {
  min-width: 220px;
  text-align: left !important;
}

.oms-permission-module-cell strong,
.oms-permission-module-cell small {
  display: block;
}

.oms-permission-module-cell strong {
  color: var(--oms-slate-900);
  font-size: 12px;
  font-weight: 900;
}

.oms-permission-module-cell small {
  margin-top: 3px;
  color: var(--oms-slate-500);
  font-size: 10px;
  font-weight: 750;
}

.oms-permission-pill {
  display: inline-flex;
  min-width: 42px;
  justify-content: center;
  border-radius: 999px;
  padding: 5px 8px;
  font-size: 10px;
  font-weight: 950;
}

.oms-permission-pill.allowed {
  background: var(--oms-green-50);
  color: var(--oms-green-700);
}

.oms-permission-pill.denied {
  background: #f1f5f9;
  color: var(--oms-slate-400);
}

.oms-user-activity-card {
  grid-column: 1 / -1;
}

.oms-user-activity-summary code {
  border: 1px solid var(--oms-slate-200);
  border-radius: 7px;
  background: #f8fafc;
  padding: 1px 5px;
  color: var(--oms-slate-700);
  font-size: 11px;
  font-weight: 850;
}

.oms-user-activity-list {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.oms-user-activity-row {
  display: grid;
  grid-template-columns: minmax(220px, 1.25fr) 128px 72px minmax(220px, 1fr) minmax(170px, 0.8fr);
  align-items: center;
  gap: 10px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 13px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  padding: 11px 12px;
}

.oms-user-activity-main,
.oms-user-activity-meta {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.oms-user-activity-main strong {
  overflow: hidden;
  color: var(--oms-slate-900);
  font-size: 13px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-user-activity-main small,
.oms-user-activity-meta,
.oms-user-activity-meta small,
.oms-user-activity-target {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 800;
}

.oms-user-activity-meta small,
.oms-user-activity-target {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-user-activity-source {
  justify-self: start;
  border: 1px solid #dbeafe;
  border-radius: 999px;
  background: #eff6ff;
  padding: 5px 9px;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
}

.oms-control-inline-field {
  display: grid;
  gap: 4px;
  min-width: 128px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 800;
}

.oms-control-inline-field input,
.oms-control-inline-field select {
  height: 34px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  color: var(--oms-slate-900);
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  padding: 0 10px;
}

.oms-invoice-monthly-card {
  align-content: start;
}

.oms-invoice-monthly-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.oms-invoice-monthly-groups div,
.oms-invoice-monthly-documents {
  display: grid;
  gap: 8px;
}

.oms-invoice-monthly-groups span,
.oms-invoice-monthly-document-row {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #f8fafc;
  padding: 9px 10px;
}

.oms-invoice-monthly-document-row.cancelled {
  background: #fff7ed;
  border-color: #fed7aa;
}

.oms-invoice-monthly-groups strong,
.oms-invoice-monthly-document-row strong {
  display: block;
  color: var(--oms-slate-900);
  font-size: 12px;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.oms-invoice-monthly-groups em,
.oms-invoice-monthly-document-row em {
  display: block;
  margin-top: 2px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.oms-invoice-numbering-card {
  grid-column: 1 / -1;
}

.oms-invoice-numbering-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.oms-invoice-numbering-row {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #f8fafc;
  padding: 10px 11px;
}

.oms-invoice-numbering-row.warning {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-invoice-numbering-row.blocked {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-invoice-numbering-row strong,
.oms-invoice-numbering-row em,
.oms-invoice-numbering-row span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.oms-invoice-numbering-row strong {
  display: block;
  color: var(--oms-slate-900);
  font-size: 12px;
  font-weight: 950;
}

.oms-invoice-numbering-row em {
  display: block;
  margin-top: 2px;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-style: normal;
  font-weight: 760;
}

.oms-invoice-numbering-row > span:last-child {
  flex: 0 0 auto;
  border-radius: 999px;
  background: white;
  padding: 5px 8px;
  color: var(--oms-slate-700);
  font-size: 11px;
  font-weight: 950;
}

.oms-shipment-events-panel {
  display: grid;
  grid-column: 1 / -1;
  gap: 12px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 14px;
}

.oms-shipment-events-list {
  display: grid;
  gap: 8px;
}

.oms-shipment-event-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--oms-slate-100);
  padding-top: 8px;
  color: var(--oms-slate-600);
  font-size: 12px;
}

.oms-wza-shell {
  display: grid;
  gap: 0;
  color: #202124;
}

.oms-wza-tabs {
  display: flex;
  align-items: flex-end;
  gap: 0;
  border-bottom: 1px solid #d7dde8;
  background: #f7f9fc;
}

.oms-wza-tabs button {
  appearance: none;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  padding: 18px 24px 12px;
  color: #1f2937;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.06em;
  text-align: left;
  cursor: pointer;
}

.oms-wza-tabs button.active {
  border-bottom-color: #3f6df6;
  color: #3f6df6;
}

.oms-wza-tabs span {
  margin-left: 8px;
  border-radius: 999px;
  background: #edf3ff;
  padding: 2px 7px;
  font-size: 11px;
  letter-spacing: 0;
}

.oms-wza-filter-panel {
  position: relative;
  display: grid;
  gap: 14px;
  border-bottom: 1px solid #dfe4ee;
  background: white;
  padding: 22px 24px 16px;
}

.oms-wza-filter-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.oms-wza-filter-head strong {
  display: block;
  color: #6b7280;
  font-size: 13px;
  font-weight: 700;
}

.oms-wza-filter-head span {
  display: block;
  margin-top: 3px;
  color: #7b8495;
  font-size: 12px;
  font-weight: 650;
}

.oms-wza-clear {
  appearance: none;
  border: 0;
  background: transparent;
  color: #00796b;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.12em;
  cursor: pointer;
}

.oms-wza-count-pill {
  position: absolute;
  right: 24px;
  bottom: 18px;
  border-radius: 999px;
  background: #e8fff0;
  padding: 6px 10px;
  color: #16a34a;
  font-size: 12px;
  font-weight: 850;
}

.oms-wza-carrier-filters {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding-right: 72px;
}

.oms-wza-carrier-filters button {
  appearance: none;
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid #d8deea;
  border-radius: 8px;
  background: #ffffff;
  padding: 5px 9px;
  color: #243041;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.oms-wza-carrier-filters button:hover {
  border-color: #3f6df6;
  background: #f8fbff;
}

.oms-wza-carrier-filters button.active {
  border-color: #3f6df6;
  box-shadow: 0 0 0 2px rgba(63, 109, 246, 0.12);
}

.oms-wza-carrier-filters button > strong {
  border-radius: 999px;
  background: #edf3ff;
  padding: 3px 7px;
  color: #3f6df6;
  font-size: 11px;
  font-weight: 950;
}

.oms-carrier-logo.filter {
  width: 92px;
  min-height: 28px;
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

.oms-carrier-logo.filter .oms-carrier-logo-img {
  max-width: 88px;
  max-height: 26px;
}

/* ORLEN Paczka to jedyny znak kwadratowy - przy wspolnym limicie wysokosci
   wygladalby o polowe mniejszy od pozostalych, wiec dostaje wlasny. */
.oms-carrier-logo.orlen.filter .oms-carrier-logo-img {
  max-height: 28px;
}

.oms-carrier-logo.filter strong {
  max-width: 92px;
  overflow: hidden;
  font-size: 12px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-wza-bulkbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  border-bottom: 1px solid #dfe4ee;
  background: #ffffff;
  padding: 12px 24px;
}

.oms-wza-bulkbar label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #202124;
  font-size: 13px;
  font-weight: 850;
}

.oms-wza-bulkbar input {
  width: 16px;
  height: 16px;
}

.oms-wza-bulkbar span {
  color: #6b7890;
  font-size: 13px;
  font-weight: 700;
}

.oms-wza-bulkbar button {
  appearance: none;
  border: 1px solid #00796b;
  border-radius: 6px;
  background: #ffffff;
  padding: 7px 12px;
  color: #00796b;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.oms-wza-bulkbar button.secondary {
  border-color: #d8deea;
  color: #243041;
}

.oms-wza-bulkbar [data-shipment-pickup-proposals-bulk] {
  margin-left: auto;
}

.oms-wza-bulkbar button:hover:not(:disabled) {
  background: #ecfdf5;
}

.oms-wza-bulkbar button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.oms-wza-bulk-slots {
  display: grid;
  gap: 10px;
  border-bottom: 1px solid #dfe4ee;
  background: #fbfcfe;
  padding: 10px 24px 12px;
}

.oms-wza-bulk-slots-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #243041;
  font-size: 13px;
  font-weight: 850;
}

.oms-wza-bulk-slots-head span {
  border-radius: 999px;
  background: #edf3ff;
  padding: 3px 8px;
  color: #3f6df6;
  font-size: 11px;
  font-weight: 950;
}

.oms-wza-bulk-slot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 8px;
}

.oms-wza-table {
  background: white;
  overflow-x: auto;
}

.oms-wza-head,
.oms-wza-row,
.oms-wza-pickup-row {
  display: grid;
  align-items: stretch;
  min-width: 1120px;
}

.oms-wza-table.shipments .oms-wza-head,
.oms-wza-table.shipments .oms-wza-row {
  grid-template-columns: 34px 1.05fr 0.72fr 0.92fr 0.82fr 0.72fr 0.52fr 0.9fr 92px;
}

.oms-wza-table.pickups .oms-wza-head,
.oms-wza-table.pickups .oms-wza-pickup-row {
  grid-template-columns: 1.1fr 0.9fr 0.7fr 1fr 1fr 92px;
}

.oms-wza-head {
  border-bottom: 2px solid #202124;
  color: #202124;
  font-size: 13px;
  font-weight: 850;
}

.oms-wza-head > div {
  padding: 13px 12px 9px;
}

.oms-wza-head input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin: 0;
}

.oms-wza-row,
.oms-wza-pickup-row {
  border-bottom: 1px solid #cfd5df;
  background: white;
  cursor: pointer;
}

.oms-wza-row:hover,
.oms-wza-pickup-row:hover,
.oms-wza-row.expanded {
  background: #f8fafc;
}

.oms-wza-row.expanded {
  box-shadow: inset 3px 0 0 #00796b;
}

.oms-wza-cell {
  min-width: 0;
  padding: 14px 12px;
  color: #243041;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.24;
}

.oms-wza-cell.check {
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

.oms-wza-cell.check input {
  width: 16px;
  height: 16px;
  margin-top: 2px;
}

.oms-wza-cell.number strong,
.oms-wza-cell.pickup-no strong {
  display: block;
  overflow-wrap: anywhere;
  color: #111827;
  font-size: 14px;
  font-weight: 850;
}

.oms-wza-cell.number span,
.oms-wza-cell.sender span,
.oms-wza-cell.pickup small {
  display: block;
  margin-top: 4px;
  overflow-wrap: anywhere;
  color: #6b7890;
  font-size: 12px;
  font-weight: 700;
}

.oms-carrier-logo {
  display: inline-flex;
  width: 136px;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  border: 1px solid #d8deea;
  border-radius: 8px;
  background: #ffffff;
  padding: 7px 12px;
  color: #111827;
  line-height: 1;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  overflow: hidden;
  white-space: nowrap;
}

.oms-carrier-logo strong {
  font-size: 15px;
  font-weight: 950;
  letter-spacing: 0;
}

.oms-carrier-logo-img {
  display: block;
  max-width: 112px;
  max-height: 36px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.oms-carrier-logo.row {
  width: 146px;
}

.oms-carrier-logo.hero {
  width: 100%;
  min-height: 76px;
  justify-content: center;
  border-radius: 10px;
  padding: 14px 16px;
}

.oms-carrier-logo.hero .oms-carrier-logo-img {
  max-width: 240px;
  max-height: 54px;
}

.oms-carrier-logo.board {
  width: 100%;
  min-height: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

.oms-carrier-logo.board .oms-carrier-logo-img {
  max-width: 150px;
  max-height: 46px;
}

.oms-carrier-logo.orlen.board .oms-carrier-logo-img {
  max-height: 54px;
}

.oms-carrier-logo.board strong {
  font-size: 20px;
}

/* Tablica podjazdow */
.oms-pickup-board {
  border-bottom: 1px solid #dfe4ee;
  background: #ffffff;
  padding: 16px 24px 18px;
}

.oms-pickup-board-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 12px;
}

.oms-pickup-board-head strong {
  color: #202124;
  font-size: 14px;
  font-weight: 800;
}

.oms-pickup-board-window {
  border: 1px solid #dfe4ee;
  border-radius: 999px;
  padding: 2px 9px;
  color: #6b7890;
  font-size: 11px;
  font-weight: 700;
}

.oms-pickup-cards {
  display: flex;
  gap: 12px;
  align-items: stretch;
  flex-wrap: wrap;
}

.oms-pickup-card {
  display: flex;
  width: 196px;
  min-height: 118px;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  border: 2px solid #d8deea;
  border-radius: 12px;
  background: #ffffff;
  padding: 14px 16px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
  cursor: pointer;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}

/* Ramka niesie kolor marki, wiec hover i stan aktywny nie moga jej przemalowac -
   inaczej kafle traca rozpoznawalnosc w jednym rzucie oka. */
.oms-pickup-card:hover:not(:disabled) {
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.14);
  transform: translateY(-1px);
}

.oms-pickup-card.active {
  box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.14), 0 6px 16px rgba(15, 23, 42, 0.12);
}

.oms-pickup-card.dpd {
  border-color: #111827;
  background: #fff6f7;
}

.oms-pickup-card.paxy {
  border-color: #111827;
  background: #eef0fb;
}

.oms-pickup-card.paxy .oms-pickup-card-since {
  color: #5b63a8;
}

/* Packeta: ta sama ramka co reszta kafli, cieple tlo pod czerwony znak marki. */
.oms-pickup-card.paxy.packeta {
  background: #fff1ee;
}

.oms-pickup-card.paxy.packeta .oms-pickup-card-since {
  color: #9a3412;
}

.oms-pickup-card.orlen {
  border-color: #111827;
  background: #fff1e3;
}

.oms-pickup-card:disabled {
  background: #f7f8fb;
  opacity: .5;
  cursor: default;
}

/* Kurier juz wezwany - kafel wylaczony, ale trzyma kolor marki. Zielony jest
   wylacznie potwierdzajacy napis. */
.oms-pickup-card.called:disabled {
  opacity: 1;
}

.oms-pickup-card.called:disabled .oms-pickup-card-count {
  color: #0f766e;
  font-weight: 800;
}

.oms-pickup-card.dhl.called:disabled .oms-pickup-card-count {
  color: #14532d;
}

.oms-pickup-card.dhl {
  border-color: #111827;
  background: #fff3c4;
}

.oms-pickup-card.dhl:disabled:not(.called) {
  background: #f7f8fb;
  border-color: #d8deea;
}

.oms-pickup-card-count {
  color: #4a5568;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.oms-pickup-card-since {
  margin-top: auto;
  color: #8894ab;
  font-size: 11px;
  font-weight: 600;
}

.oms-pickup-card.dhl .oms-pickup-card-since {
  color: #8a6a1a;
}

.oms-pickup-board-toggle {
  margin-top: 10px;
  border: 0;
  background: transparent;
  padding: 0;
  color: #00796b;
  font-size: 12px;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
}

.oms-pickup-card.dhl .oms-pickup-card-count {
  color: #6b4b00;
}

.oms-pickup-card.dhl:disabled .oms-pickup-card-count {
  color: #4a5568;
}

.oms-pickup-drawer {
  margin-top: 14px;
  border: 1px solid #cfe3df;
  border-radius: 12px;
  background: #f4fbf9;
  padding: 14px 16px;
}

.oms-pickup-drawer-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 10px;
  color: #0f766e;
  font-size: 13px;
  font-weight: 800;
}

.oms-pickup-drawer-head span {
  color: #4a5568;
  font-weight: 600;
}

.oms-pickup-picker {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  border: 1px solid #dfeeea;
  border-radius: 8px;
  background: #ffffff;
  padding: 8px 12px;
  font-size: 12px;
}

.oms-pickup-picker-label {
  color: #4a5568;
  font-weight: 700;
}

.oms-pickup-picker code {
  border-radius: 4px;
  background: #eef2f7;
  padding: 2px 6px;
  font-size: 11px;
}

.oms-pickup-picker-toggle {
  border: 0;
  background: transparent;
  padding: 0;
  color: #00796b;
  font-size: 12px;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
}

.oms-pickup-picker-list {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  width: 100%;
  margin-top: 8px;
  border-top: 1px solid #eef2f7;
  padding-top: 8px;
}

.oms-pickup-picker-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #dfe4ee;
  border-radius: 6px;
  background: #ffffff;
  padding: 5px 8px;
  cursor: pointer;
}

.oms-pickup-picker-item.chosen {
  border-color: #00796b;
  background: #e6f5f2;
}

.oms-pickup-picker-item span {
  color: #6b7890;
  font-size: 11px;
}

.oms-pickup-slots {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.oms-pickup-slot {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #cfe3df;
  border-radius: 999px;
  background: #ffffff;
  padding: 8px 14px;
  color: #202124;
  font-size: 12px;
  cursor: pointer;
}

.oms-pickup-slot-mark {
  width: 13px;
  height: 13px;
  flex: 0 0 auto;
  border: 2px solid #b7cbc6;
  border-radius: 50%;
  background: #ffffff;
}

.oms-pickup-slot.chosen {
  border-color: #00796b;
  background: #e6f5f2;
}

.oms-pickup-slot.chosen .oms-pickup-slot-mark {
  border-color: #00796b;
  background: radial-gradient(circle, #00796b 0 45%, #ffffff 50% 100%);
}

.oms-pickup-slot-day {
  font-weight: 800;
}

.oms-pickup-slot em {
  color: #4a5568;
  font-style: normal;
}

.oms-pickup-drawer-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.oms-pickup-order {
  border: 0;
  border-radius: 8px;
  background: #00796b;
  padding: 10px 20px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.oms-pickup-order:disabled {
  background: #b7cbc6;
  cursor: default;
}

.oms-carrier-logo.inpost {
  border-color: #ffcd00;
  background: #ffffff;
}

.oms-carrier-logo.inpost .oms-carrier-logo-img {
  transform: none;
  transform-origin: center;
}

.oms-carrier-logo.dpd {
  border-color: #dc0032;
}

/* Logo DHL niesie wlasne zolte tlo - kafel musi miec ten sam odcien, inaczej widac obwodke. */
.oms-carrier-logo.dhl {
  border-color: #f0c000;
  background: #fee97a;
}

.oms-carrier-logo.orlen {
  border-color: #d71920;
  padding-top: 5px;
  padding-bottom: 5px;
}

.oms-carrier-logo.orlen .oms-carrier-logo-img {
  max-height: 40px;
}

.oms-carrier-logo.orlen.hero .oms-carrier-logo-img {
  max-height: 56px;
}

.oms-carrier-logo.poczta {
  border-color: #d52b1e;
}

.oms-carrier-logo.courier {
  border-color: #0f766e;
  background: #f0fdfa;
  color: #0f766e;
}

.oms-wza-inline-action {
  display: inline-flex;
  align-items: center;
  margin-top: 8px;
  border: 1px solid #00796b;
  border-radius: 6px;
  background: white;
  padding: 5px 8px;
  color: #00796b;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.oms-wza-inline-action:hover {
  background: #ecfdf5;
}

.oms-wza-pickup-state {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 850;
}

.oms-wza-pickup-state.ordered {
  background: #e9fdf2;
  color: #047857;
}

.oms-wza-pickup-state.missing {
  background: #fff7ed;
  color: #c2410c;
}

.oms-wza-pickup-state.blocked {
  background: #f1f5f9;
  color: #64748b;
}

.oms-wza-pickup-state.neutral {
  background: #eef2ff;
  color: #4f46e5;
}

.oms-wza-cell.action {
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
}

.oms-wza-cell.action button {
  appearance: none;
  border: 0;
  background: transparent;
  color: #00796b;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.12em;
  cursor: pointer;
}

.oms-wza-expanded {
  display: grid;
  grid-template-columns: minmax(260px, 0.85fr) minmax(360px, 1.15fr);
  gap: 28px;
  border-bottom: 1px solid #cfd5df;
  background: #fbfcfe;
  padding: 22px 24px 26px 48px;
}

.oms-wza-detail-col h3 {
  margin: 0 0 12px;
  color: #80838a;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.oms-wza-detail-col dl {
  display: grid;
  gap: 8px;
  margin: 0;
}

.oms-wza-detail-col dl > div {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  gap: 12px;
}

.oms-wza-detail-col dt {
  color: #202124;
  font-size: 13px;
  font-weight: 650;
}

.oms-wza-detail-col dd {
  margin: 0;
  overflow-wrap: anywhere;
  color: #202124;
  font-size: 13px;
  font-weight: 750;
}

.oms-wza-pickup-actions {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.oms-wza-pickup-slots {
  display: grid;
  gap: 8px;
}

.oms-wza-slot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid #d7dde8;
  border-radius: 6px;
  background: white;
  padding: 10px 12px;
  color: #111827;
  cursor: pointer;
}

.oms-wza-slot.compact {
  display: grid;
  grid-template-columns: 52px minmax(86px, 1fr) 52px;
  min-height: 42px;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
}

.oms-wza-slot.compact span {
  color: #243041;
  font-size: 12px;
  font-weight: 900;
}

.oms-wza-slot.compact em {
  color: #475569;
  font-size: 12px;
  font-style: normal;
  font-weight: 750;
  white-space: nowrap;
}

.oms-wza-slot.compact strong {
  justify-self: end;
  font-size: 12px;
  letter-spacing: 0;
  white-space: nowrap;
}

.oms-wza-slot:hover {
  border-color: #00796b;
  background: #f0fdfa;
}

.oms-wza-slot strong {
  color: #00796b;
  font-size: 12px;
  letter-spacing: 0.08em;
}

.oms-wza-muted,
.oms-wza-empty {
  margin: 0;
  color: #7b8495;
  font-size: 13px;
  font-weight: 650;
}

.oms-wza-empty {
  min-width: 1120px;
  padding: 32px 24px;
  border-bottom: 1px solid #dfe4ee;
  background: white;
}

.oms-wza-events {
  display: grid;
  gap: 8px;
}

.oms-wza-detail-event {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid #e5e7eb;
  padding-top: 8px;
}

.oms-wza-detail-event strong,
.oms-wza-detail-event span,
.oms-wza-detail-event em {
  display: block;
  overflow-wrap: anywhere;
}

.oms-wza-detail-event strong {
  color: #111827;
  font-size: 12px;
  font-weight: 850;
}

.oms-wza-detail-event span,
.oms-wza-detail-event em {
  color: #6b7890;
  font-size: 12px;
  font-style: normal;
  font-weight: 650;
}

@media (max-width: 900px) {
  .oms-wza-expanded {
    grid-template-columns: 1fr;
    padding-left: 24px;
  }

  .oms-wza-tabs {
    overflow-x: auto;
  }

  .oms-wza-tabs button {
    white-space: nowrap;
  }
}

.oms-wza-workbench {
  display: grid;
  grid-template-columns: minmax(760px, 1fr) 480px;
  align-items: stretch;
  min-height: calc(100vh - 330px);
}

.oms-wza-workbench.pickups {
  grid-template-columns: 1fr;
}

.oms-wza-workbench .oms-wza-table {
  min-width: 0;
}

.oms-wza-workbench .oms-wza-head,
.oms-wza-workbench .oms-wza-row,
.oms-wza-workbench .oms-wza-pickup-row {
  min-width: 0;
}

.oms-wza-side-panel {
  position: sticky;
  top: 76px;
  align-self: start;
  display: grid;
  align-content: start;
  gap: 16px;
  max-height: calc(100vh - 92px);
  overflow-y: auto;
  border-left: 1px solid #dfe4ee;
  background: #fbfcfe;
  padding: 20px;
}

.oms-wza-side-panel.empty {
  min-height: 420px;
  align-content: center;
  justify-items: center;
  color: #6b7890;
  text-align: center;
}

.oms-wza-side-panel.empty strong {
  color: #111827;
  font-size: 16px;
}

.oms-wza-side-panel.empty span {
  max-width: 260px;
  font-size: 13px;
  font-weight: 650;
}

.oms-wza-side-top {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding-bottom: 2px;
}

.oms-wza-side-close {
  appearance: none;
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  color: #6b7890;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.oms-wza-side-top strong {
  display: block;
  overflow-wrap: anywhere;
  color: #111827;
  font-size: 18px;
  font-weight: 850;
}

.oms-wza-side-top span {
  display: block;
  margin-top: 4px;
  overflow-wrap: anywhere;
  color: #6b7890;
  font-size: 12px;
  font-weight: 700;
}

.oms-wza-carrier-hero {
  display: grid;
  gap: 10px;
  border: 1px solid #dfe4ee;
  border-radius: 10px;
  background: #ffffff;
  padding: 12px;
}

.oms-wza-carrier-hero > div:last-child {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.oms-wza-carrier-hero > div:last-child span {
  color: #6b7890;
  font-size: 12px;
  font-weight: 800;
}

.oms-wza-carrier-hero > div:last-child strong {
  color: #111827;
  font-size: 14px;
  font-weight: 900;
}

.oms-wza-action-panel {
  display: grid;
  gap: 14px;
  border: 1px solid #dfe4ee;
  border-radius: 10px;
  background: #ffffff;
  padding: 16px;
}

.oms-wza-action-panel.needs-action {
  border-color: #fdba74;
  background: linear-gradient(180deg, #fff7ed 0%, #ffffff 58%);
  box-shadow: 0 12px 30px rgba(194, 65, 12, 0.08);
}

.oms-wza-action-panel.done {
  border-color: #bbf7d0;
  background: linear-gradient(180deg, #f0fdf4 0%, #ffffff 58%);
}

.oms-wza-action-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.oms-wza-action-head span:first-child {
  display: block;
  margin-bottom: 4px;
  color: #9a3412;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.oms-wza-action-head strong {
  display: block;
  color: #111827;
  font-size: 20px;
  font-weight: 950;
  line-height: 1.1;
}

.oms-wza-action-panel p {
  margin: 0;
  color: #475569;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.oms-wza-primary-action {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  border: 1px solid #00796b;
  border-radius: 8px;
  background: #00796b;
  padding: 0 16px;
  color: #ffffff;
  font-size: 14px;
  font-weight: 950;
  cursor: pointer;
}

.oms-wza-primary-action:hover:not(:disabled) {
  background: #00695c;
}

.oms-wza-primary-action:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.oms-wza-side-card {
  display: grid;
  gap: 10px;
  border: 1px solid #dfe4ee;
  border-radius: 8px;
  background: white;
  padding: 16px;
}

.oms-wza-side-card.compact {
  gap: 12px;
}

.oms-wza-side-card.warning {
  border-color: #fdba74;
  background: #fffaf3;
}

.oms-wza-side-card h3 {
  margin: 0;
  color: #374151;
  font-size: 13px;
  font-weight: 850;
}

.oms-wza-side-card dl {
  display: grid;
  gap: 9px;
  margin: 0;
}

.oms-wza-side-card dl > div {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr);
  gap: 10px;
}

.oms-wza-side-card dt {
  color: #6b7890;
  font-size: 12px;
  font-weight: 700;
}

.oms-wza-side-card dd {
  margin: 0;
  overflow-wrap: anywhere;
  color: #111827;
  font-size: 13px;
  font-weight: 850;
}

.oms-wza-side-card > strong {
  overflow-wrap: anywhere;
  color: #111827;
  font-size: 13px;
  font-weight: 850;
}

.oms-wza-side-card > span {
  overflow-wrap: anywhere;
  color: #6b7890;
  font-size: 12.5px;
  font-weight: 650;
}

.oms-wza-warning-box {
  display: grid;
  gap: 8px;
}

.oms-wza-warning-box strong {
  color: #111827;
  font-size: 13.5px;
  font-weight: 850;
}

.oms-wza-warning-box span {
  color: #6b7890;
  font-size: 12.5px;
  font-weight: 650;
}

.oms-wza-side-panel .oms-wza-inline-action {
  justify-self: start;
}

.oms-wza-pickup-slots.strong {
  gap: 10px;
}

.oms-wza-pickup-slots.strong .oms-wza-slot {
  min-height: 48px;
  border-color: #0f766e;
  box-shadow: 0 1px 0 rgba(15, 118, 110, 0.08);
}

.oms-wza-pickup-slots.strong .oms-wza-slot strong {
  font-size: 13px;
  letter-spacing: 0;
}

@media (max-width: 1180px) {
  .oms-wza-workbench {
    grid-template-columns: 1fr;
  }

  .oms-wza-side-panel {
    position: static;
    max-height: none;
    overflow: visible;
    border-left: 0;
    border-top: 1px solid #dfe4ee;
  }
}

.oms-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.oms-kpi-card,
.oms-stores-card,
.oms-chart-card,
.oms-monthly-section {
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: white;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.oms-kpi-card {
  min-height: 132px;
  padding: 16px;
  text-align: left;
}

.oms-kpi-card.clickable {
  cursor: pointer;
}

.oms-kpi-card.clickable:hover {
  border-color: #bfdbfe;
  background: var(--oms-blue-50);
}

.oms-kpi-label,
.oms-summary-label,
.oms-metric-label {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.oms-kpi-value {
  margin-top: 8px;
  color: var(--oms-slate-950);
  font-size: 28px;
  font-weight: 850;
  line-height: 1;
}

.oms-kpi-value.green,
.oms-kpi-trend,
.oms-summary-value.green {
  color: #059669;
}

.oms-kpi-sub {
  margin-top: 8px;
  color: var(--oms-slate-500);
  font-size: 13px;
}

.oms-kpi-link {
  margin-top: 6px;
  color: var(--oms-blue-600);
  font-size: 12.5px;
  font-weight: 650;
}

.oms-stores-card {
  padding: 12px;
}

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

.oms-store-item {
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-50);
  padding: 10px 8px;
  text-align: center;
}

.oms-store-name {
  overflow: hidden;
  color: var(--oms-slate-600);
  font-size: 11.5px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-store-value {
  margin-top: 5px;
  color: var(--oms-slate-950);
  font-size: 15px;
  font-weight: 850;
}

.oms-store-orders {
  margin-top: 2px;
  color: var(--oms-slate-400);
  font-size: 11px;
}

.oms-more-stores {
  margin-top: 8px;
  border: 1px dashed var(--oms-slate-300);
  border-radius: 8px;
  padding: 7px;
  color: var(--oms-slate-500);
  text-align: center;
  font-size: 12.5px;
  font-weight: 650;
}

.oms-chart-card,
.oms-monthly-section {
  margin-bottom: 18px;
  padding: 18px;
}

.oms-chart-header,
.oms-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.oms-section-header.compact {
  align-items: flex-start;
  margin-bottom: 12px;
}

.oms-chart-title,
.oms-section-title {
  color: var(--oms-slate-950);
  font-size: 18px;
  font-weight: 850;
}

.oms-chart-title::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 8px;
  border-radius: 50%;
  background: #22c55e;
  vertical-align: middle;
}

.oms-section-subtitle {
  margin-top: 2px;
  color: var(--oms-slate-500);
  font-size: 13px;
}

.oms-section-title.small {
  margin-bottom: 10px;
  font-size: 14px;
}

.oms-analytics-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 14px;
  margin-top: 16px;
}

.oms-analytics-table-card {
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: white;
  padding: 14px;
}

.oms-analytics-cost-form {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) 112px 110px auto;
  gap: 8px;
  margin-bottom: 10px;
}

.oms-analytics-product-cost-form {
  display: grid;
  grid-template-columns: minmax(150px, 180px) minmax(130px, 160px) 140px;
  gap: 8px;
  margin-bottom: 10px;
}

.oms-analytics-product-cost-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.oms-analytics-product-cost-toolbar input {
  min-height: 30px;
  min-width: 190px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 7px;
  background: white;
  padding: 0 9px;
  color: var(--oms-slate-900);
  font: inherit;
  font-weight: 750;
}

.oms-analytics-cost-details {
  margin-top: 12px;
  border-top: 1px solid var(--oms-slate-100);
  padding-top: 10px;
}

.oms-analytics-cost-details summary {
  cursor: pointer;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 850;
}

.oms-analytics-table {
  overflow-x: auto;
}

.oms-analytics-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.oms-analytics-table th,
.oms-analytics-table td {
  border-bottom: 1px solid var(--oms-slate-100);
  padding: 8px 6px;
  text-align: left;
  white-space: nowrap;
}

.oms-analytics-table th {
  color: var(--oms-slate-500);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.oms-analytics-table .pos { color: #047857; font-weight: 850; }
.oms-analytics-table .neg { color: #b91c1c; font-weight: 850; }

.oms-table-icon-btn {
  min-height: 30px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 7px;
  background: var(--oms-slate-50);
  padding: 0 9px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.oms-empty-inline {
  border: 1px dashed var(--oms-slate-200);
  border-radius: 8px;
  padding: 12px;
  color: var(--oms-slate-500);
  font-size: 13px;
  font-weight: 750;
}

.oms-store-item.error {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-toggle-group {
  display: flex;
  border-radius: 8px;
  background: var(--oms-slate-100);
  padding: 3px;
}

.oms-toggle-btn {
  min-height: 28px;
  border-radius: 6px;
  background: transparent;
  padding: 0 11px;
  color: var(--oms-slate-500);
  font-size: 12.5px;
  font-weight: 700;
}

.oms-toggle-btn.active {
  background: white;
  color: var(--oms-slate-950);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
}

.oms-chart-container {
  position: relative;
  height: 280px;
  margin: 18px 0 14px;
}

.oms-y-axis {
  position: absolute;
  top: 0;
  left: 0;
  display: flex;
  width: 54px;
  height: 220px;
  flex-direction: column;
  justify-content: space-between;
  padding-right: 8px;
  color: var(--oms-slate-400);
  text-align: right;
  font-size: 11px;
}

.oms-chart-bars {
  display: flex;
  height: 220px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 4px;
  margin-left: 58px;
  border-bottom: 2px solid var(--oms-slate-200);
  padding: 0 10px;
}

.oms-bar-wrapper {
  position: relative;
  display: flex;
  height: 100%;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
}

.oms-bar-wrapper::before {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  z-index: 10;
  display: none;
  min-width: 210px;
  max-width: 280px;
  transform: translateX(-50%);
  border: 1px solid #d8dee8;
  border-radius: 8px;
  background: white;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.16);
  padding: 10px 12px;
  color: var(--oms-slate-700);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.45;
  pointer-events: none;
  text-align: left;
  white-space: pre-line;
  content: attr(data-tooltip);
}

.oms-bar-wrapper::after {
  position: absolute;
  bottom: calc(100% + 4px);
  left: 50%;
  z-index: 11;
  display: none;
  width: 10px;
  height: 10px;
  transform: translateX(-50%) rotate(45deg);
  border-right: 1px solid #d8dee8;
  border-bottom: 1px solid #d8dee8;
  background: white;
  content: "";
}

.oms-bar-wrapper:hover::before,
.oms-bar-wrapper:hover::after {
  display: block;
}

.oms-bar {
  width: 100%;
  max-width: 30px;
  min-height: 3px;
  border-radius: 5px 5px 0 0;
  background: #22c55e;
  transition: transform 0.16s ease, opacity 0.16s ease;
}

.oms-bar.negative {
  background: #ef4444;
}

.oms-bar:hover {
  opacity: 0.82;
  transform: translateY(-2px);
}

.oms-chart-line-view {
  position: relative;
  display: block;
  overflow: visible;
  border-bottom: 2px solid var(--oms-slate-200);
  padding: 0 10px 28px;
}

.oms-profit-line-chart {
  display: block;
  width: 100%;
  height: 220px;
  overflow: visible;
}

.oms-profit-line-path {
  fill: none;
  stroke: #2563eb;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 5;
}

.oms-profit-zero-line {
  stroke: var(--oms-slate-200);
  stroke-dasharray: 8 8;
  stroke-width: 2;
}

.oms-profit-line-point {
  fill: #2563eb;
  opacity: 0.9;
  stroke: white;
  stroke-width: 5;
}

.oms-profit-line-point.neg {
  fill: #ef4444;
}

.oms-line-labels {
  display: flex;
  justify-content: space-between;
  gap: 4px;
  margin-top: 8px;
  color: var(--oms-slate-400);
  font-size: 10.5px;
}

.oms-line-labels span {
  min-width: 0;
  text-align: center;
  white-space: nowrap;
}

.oms-chart-table-view {
  display: block;
  overflow: auto;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  padding: 0;
}

.oms-chart-table-view table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.oms-chart-table-view th,
.oms-chart-table-view td {
  border-bottom: 1px solid var(--oms-slate-100);
  padding: 9px 10px;
  text-align: right;
}

.oms-chart-table-view th:first-child,
.oms-chart-table-view td:first-child {
  text-align: left;
}

.oms-chart-table-view .pos {
  color: #047857;
  font-weight: 850;
}

.oms-chart-table-view .neg {
  color: #dc2626;
  font-weight: 850;
}

.oms-bar-label {
  margin-top: 8px;
  color: var(--oms-slate-400);
  font-size: 10.5px;
  white-space: nowrap;
}

.oms-chart-legend {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: var(--oms-slate-600);
  font-size: 12px;
}

.oms-legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: #22c55e;
}

.oms-summary-strip {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-top: 14px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: var(--oms-slate-50);
  padding: 14px;
}

.oms-summary-item {
  text-align: center;
}

.oms-summary-value {
  margin-top: 4px;
  color: var(--oms-slate-950);
  font-size: 15px;
  font-weight: 850;
}

.oms-country-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  margin-top: 14px;
  border-top: 1px solid var(--oms-slate-200);
  padding-top: 14px;
  color: var(--oms-slate-600);
  font-size: 12.5px;
}

.oms-country-item {
  display: inline-flex;
  gap: 6px;
}

.oms-country-item strong.pos {
  color: #059669;
}

.oms-country-item strong.neg {
  color: #dc2626;
}

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

.oms-metric-card {
  border: 1px solid;
  border-radius: 10px;
  padding: 16px;
}

.oms-metric-card.green { border-color: #bbf7d0; background: linear-gradient(135deg, #ecfdf5, #f0fdf4); }
.oms-metric-card.blue { border-color: #bfdbfe; background: linear-gradient(135deg, #eff6ff, #f0f9ff); }
.oms-metric-card.orange { border-color: #fed7aa; background: linear-gradient(135deg, #fff7ed, #ffedd5); }
.oms-metric-card.yellow { border-color: #fde68a; background: linear-gradient(135deg, #fefce8, #fef9c3); }
.oms-metric-card.purple { border-color: #ddd6fe; background: linear-gradient(135deg, #faf5ff, #f5f3ff); }

.oms-metric-card.green .oms-metric-label { color: #059669; }
.oms-metric-card.blue .oms-metric-label { color: #2563eb; }
.oms-metric-card.orange .oms-metric-label { color: #ea580c; }
.oms-metric-card.yellow .oms-metric-label { color: #ca8a04; }
.oms-metric-card.purple .oms-metric-label { color: #7c3aed; }

.oms-metric-value {
  margin-top: 12px;
  font-size: 24px;
  font-weight: 900;
  line-height: 1;
}

.oms-metric-card.green .oms-metric-value { color: #047857; }
.oms-metric-card.blue .oms-metric-value { color: #1d4ed8; }
.oms-metric-card.orange .oms-metric-value { color: #c2410c; }
.oms-metric-card.yellow .oms-metric-value { color: #a16207; }
.oms-metric-card.purple .oms-metric-value { color: #6d28d9; }

.oms-app[data-profiter-focus="true"] .oms-main,
.oms-app[data-profiter-focus="true"] .oms-workspace {
  background: #f6f7f9;
}

.oms-app[data-profiter-focus="true"] .oms-workspace {
  min-height: 0;
}

.oms-profiter3-view {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  background: #f6f7f9;
  color: #0f1217;
}

.oms-profiter3-view[hidden] {
  display: none;
}

.oms-profiter-shell {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: 16px 24px 48px;
}

.oms-profiter-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  min-height: 72px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid #e6e9ef;
  background: rgba(246, 247, 249, 0.92);
  padding: 10px 0;
  backdrop-filter: saturate(180%) blur(12px);
}

.oms-profiter-logo {
  margin: 0;
  color: #0f1217;
  font-size: 28px;
  font-weight: 800;
  line-height: 1.05;
}

.oms-profiter-date-label {
  margin: 4px 0 0;
  color: #5e6673;
  font-size: 13px;
  font-weight: 650;
}

.oms-profiter-date-picker,
.oms-profiter-actions,
.oms-profiter-month-field,
.oms-profiter-month-field label {
  display: flex;
  align-items: center;
  gap: 8px;
}

.oms-profiter-date-picker {
  border: 1px solid #e6e9ef;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.04);
  padding: 4px;
}

.oms-profiter-date-picker button {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 7px;
  background: transparent;
  color: #5e6673;
  font-size: 22px;
  font-weight: 700;
  cursor: pointer;
}

.oms-profiter-date-picker button:hover {
  background: #f3f5f7;
  color: #0f1217;
}

.oms-profiter-date-picker label,
.oms-profiter-month-field {
  gap: 8px;
  color: #5e6673;
  font-size: 12px;
  font-weight: 750;
}

.oms-profiter-date-picker input,
.oms-profiter-month-field input,
.oms-profiter-month-field select {
  min-height: 32px;
  border: 1px solid #edf0f4;
  border-radius: 7px;
  background: #fbfcfd;
  padding: 0 10px;
  color: #0f1217;
  font: inherit;
  font-size: 14px;
  font-weight: 750;
}

.oms-profiter-month-field select {
  min-width: 148px;
  cursor: pointer;
}

.oms-profiter-actions {
  justify-content: flex-end;
  flex-wrap: wrap;
}

.oms-profiter-action {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  padding: 0 14px;
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.oms-profiter-action.primary { background: #0f1217; }
.oms-profiter-action.success { background: #15803d; }
.oms-profiter-action.neutral { background: #2563eb; }

.oms-profiter-action:disabled {
  cursor: not-allowed;
  opacity: 0.72;
}

.oms-profiter-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.68fr) minmax(320px, 1fr);
  gap: 24px;
  align-items: start;
  margin-top: 24px;
}

.oms-profiter-card,
.oms-profiter-monthly,
.oms-profiter-admin-panel {
  border: 1px solid #e6e9ef;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.04);
}

.oms-profiter-main-card {
  position: relative;
  overflow: hidden;
  padding: 28px 32px 24px;
}

.oms-profiter-main-card.positive {
  border-color: rgba(22, 163, 74, 0.24);
}

.oms-profiter-main-card.negative {
  border-color: rgba(220, 38, 38, 0.24);
}

.oms-profiter-state-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.oms-profiter-state-pill,
.oms-profiter-state-date {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  border-radius: 8px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 850;
}

.oms-profiter-state-pill {
  background: #e8f5ec;
  color: #15803d;
}

.oms-profiter-state-date {
  background: #f6f7f9;
  color: #5e6673;
}

.oms-profiter-profit-hero {
  padding: 18px 0 24px;
  text-align: center;
}

.oms-profiter-profit-value {
  color: #16a34a;
  font-size: 76px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.oms-profiter-main-card.negative .oms-profiter-profit-value {
  color: #dc2626;
}

.oms-profiter-profit-label {
  margin-top: 10px;
  color: #5e6673;
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.oms-profiter-profit-note {
  max-width: 720px;
  margin: 10px auto 0;
  color: #5e6673;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.45;
}

.oms-profiter-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid #edf0f4;
}

.oms-profiter-kpi {
  position: relative;
  min-width: 0;
  padding: 18px 14px 14px;
  text-align: center;
}

.oms-profiter-kpi:not(:last-child)::after {
  position: absolute;
  top: 20%;
  right: 0;
  bottom: 20%;
  width: 1px;
  background: #edf0f4;
  content: "";
}

.oms-profiter-kpi span,
.oms-profiter-kpi em {
  display: block;
  overflow: hidden;
  color: #5e6673;
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.oms-profiter-kpi strong {
  display: block;
  overflow: hidden;
  margin-top: 8px;
  color: #0f1217;
  font-size: 24px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-profiter-kpi em {
  margin-top: 5px;
  text-transform: none;
}

.oms-profiter-alerts {
  margin-top: 18px;
  border-top: 1px solid #edf0f4;
  padding-top: 18px;
}

.oms-profiter-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
  color: #0f1217;
  font-size: 16px;
  font-weight: 800;
}

.oms-profiter-card-title small {
  color: #5e6673;
  font-size: 12px;
  font-weight: 700;
}

.oms-profiter-pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.oms-profiter-pill {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  gap: 8px;
  border: 1px solid #e6e9ef;
  border-radius: 999px;
  background: #fbfcfd;
  padding: 8px 12px;
  color: #5e6673;
  font-size: 13px;
  font-weight: 650;
}

.oms-profiter-pill.action {
  appearance: none;
  cursor: pointer;
  font: inherit;
  text-align: left;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.oms-profiter-pill.action:hover {
  border-color: rgba(255, 90, 0, 0.42);
  box-shadow: 0 10px 22px rgba(255, 90, 0, 0.12);
  transform: translateY(-1px);
}

.oms-profiter-pill.action:focus-visible {
  outline: 3px solid rgba(37, 99, 235, 0.22);
  outline-offset: 2px;
}

.oms-profiter-pill strong,
.oms-profiter-pill em {
  overflow: hidden;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-profiter-pill.warning {
  border-color: #fde68a;
  background: #fffbeb;
  color: #92400e;
}

.oms-profiter-pill.danger {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
}

.oms-profiter-pill.ok {
  border-color: #bbf7d0;
  background: #e8f5ec;
  color: #15803d;
}

.oms-profiter-sources-card,
.oms-profiter-ads-card,
.oms-profiter-trend-card {
  padding: 24px;
}

.oms-profiter-source-list,
.oms-profiter-ads-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.oms-profiter-source {
  width: 100%;
  appearance: none;
  position: relative;
  display: grid;
  min-height: 48px;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  overflow: hidden;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #fbfcfd;
  padding: 9px 12px;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.14s ease, transform 0.14s ease, box-shadow 0.14s ease;
}

.oms-profiter-source:hover {
  border-color: #cbd5e1;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.07);
  transform: translateY(-1px);
}

.oms-profiter-source.selected {
  border-color: rgba(37, 99, 235, 0.42);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.10), 0 12px 22px rgba(15, 23, 42, 0.08);
}

.oms-profiter-source::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--w, 0%);
  background: #e8f5ec;
  content: "";
}

.oms-profiter-source.negative::before {
  background: #fef2f2;
}

.oms-profiter-source.zero::before {
  display: none;
}

.oms-profiter-source > * {
  position: relative;
  z-index: 1;
}

.oms-profiter-source-rank {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid #e6e9ef;
  border-radius: 8px;
  background: #fff;
  color: #5e6673;
  font-size: 12px;
  font-weight: 800;
}

.oms-profiter-source.positive:nth-child(-n+3) .oms-profiter-source-rank {
  border-color: #0f1217;
  background: #0f1217;
  color: #fff;
}

.oms-profiter-source-main {
  min-width: 0;
}

.oms-profiter-source-main strong,
.oms-profiter-source-main span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-profiter-source-main strong {
  color: #0f1217;
  font-size: 14px;
  font-weight: 750;
}

.oms-profiter-source-main span {
  margin-top: 2px;
  color: #5e6673;
  font-size: 11px;
  font-weight: 650;
}

.oms-profiter-source-value {
  color: #16a34a;
  font-size: 14px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.oms-profiter-source.negative .oms-profiter-source-value {
  color: #dc2626;
}

.oms-profiter-source.zero .oms-profiter-source-value {
  color: #5e6673;
}

.oms-profiter-ads-card,
.oms-profiter-trend-card {
  min-height: 288px;
}

.oms-profiter-ads-card {
  grid-column: 1;
}

.oms-profiter-trend-card {
  grid-column: 2;
}

.oms-profiter-ad-row {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.oms-profiter-ad-icon {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 8px;
  background: #f3f4f6;
  color: #0f1217;
  font-size: 13px;
  font-weight: 900;
}

.oms-profiter-ad-icon.allegro { background: #fff1e8; color: #ff5a00; }
.oms-profiter-ad-icon.google { background: #eff6ff; color: #4285f4; }
.oms-profiter-ad-icon.meta { background: #eff6ff; color: #0866ff; }
.oms-profiter-ad-icon.sklik { background: #fdecec; color: #cc0000; }

.oms-profiter-ad-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
  color: #0f1217;
  font-size: 13px;
}

.oms-profiter-ad-top span {
  color: #5e6673;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.oms-profiter-ad-bar {
  overflow: hidden;
  height: 8px;
  border-radius: 999px;
  background: #f1f3f6;
}

.oms-profiter-ad-bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: #0f1217;
}

.oms-profiter-ad-bar i.allegro { background: #ff5a00; }
.oms-profiter-ad-bar i.google { background: #4285f4; }
.oms-profiter-ad-bar i.meta { background: #0866ff; }
.oms-profiter-ad-bar i.sklik { background: #cc0000; }
.oms-profiter-ad-bar i.other { background: #64748b; }

.oms-allegro-ads-quick-form {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding: 14px;
  border: 1px solid rgba(255, 90, 0, 0.22);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(255, 90, 0, 0.08), rgba(255, 255, 255, 0.74));
}

.oms-allegro-ads-quick-form label {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.oms-allegro-ads-quick-form > div {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) auto;
  gap: 8px;
}

.oms-allegro-ads-quick-form input {
  width: 100%;
  border: 1px solid #fed7aa;
  border-radius: 12px;
  background: #fffaf5;
  color: #0f172a;
  font-weight: 900;
  padding: 9px 11px;
}

.oms-allegro-ads-quick-form small {
  color: #7c2d12;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.oms-profiter-trend-wrap {
  min-height: 210px;
}

.oms-profiter-trend-chart {
  display: flex;
  height: 170px;
  align-items: flex-end;
  gap: 6px;
  border-bottom: 1px solid #edf0f4;
  padding: 0 4px;
}

.oms-profiter-bar-col {
  position: relative;
  display: flex;
  height: 100%;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  cursor: pointer;
}

.oms-profiter-bar-col:hover .oms-profiter-bar {
  transform: translateY(-2px);
  filter: saturate(1.08);
}

.oms-profiter-bar {
  width: 100%;
  max-width: 26px;
  min-height: 4px;
  border-radius: 6px 6px 3px 3px;
  background: #cbd5e1;
  transition: transform 0.14s ease, filter 0.14s ease, box-shadow 0.14s ease;
}

.oms-profiter-bar-col.positive .oms-profiter-bar { background: #16a34a; }
.oms-profiter-bar-col.negative .oms-profiter-bar { background: #dc2626; }
.oms-profiter-bar-col.selected .oms-profiter-bar {
  box-shadow: 0 0 0 2px #0f1217 inset, 0 4px 12px rgba(22, 163, 74, 0.24);
}

.oms-profiter-bar-col span {
  position: absolute;
  bottom: -22px;
  color: #5e6673;
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10.5px;
  font-weight: 700;
}

.oms-profiter-bar-col.selected span {
  color: #0f1217;
}

.oms-profiter-trend-legend {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 32px;
  color: #5e6673;
  font-size: 12px;
  font-weight: 650;
}

.oms-profiter-trend-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.oms-profiter-trend-legend i {
  width: 10px;
  height: 10px;
  border-radius: 3px;
}

.oms-profiter-trend-legend i.pos { background: #16a34a; }
.oms-profiter-trend-legend i.neg { background: #dc2626; }

.oms-profiter-trend-legend strong {
  margin-left: auto;
  color: #0f1217;
  font-weight: 800;
}

.oms-profiter-monthly {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: minmax(220px, 1.2fr) repeat(5, minmax(120px, auto));
  gap: 22px;
  align-items: center;
  padding: 24px 28px;
}

.oms-profiter-monthly-title {
  color: #0f1217;
  font-size: 15px;
  font-weight: 850;
}

.oms-profiter-monthly-sub {
  margin-top: 4px;
  color: #5e6673;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.35;
}

.oms-profiter-monthly-metric {
  text-align: right;
}

.oms-profiter-monthly-metric span {
  display: block;
  color: #5e6673;
  font-size: 10.5px;
  font-weight: 800;
  text-transform: uppercase;
}

.oms-profiter-monthly-metric strong {
  display: block;
  margin-top: 6px;
  color: #0f1217;
  font-size: 20px;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.oms-profiter-monthly-metric.positive strong {
  color: #16a34a;
}

.oms-profiter-monthly-meta {
  grid-column: 1 / -1;
  display: flex;
  gap: 16px;
  border-top: 1px solid #edf0f4;
  padding-top: 12px;
  color: #5e6673;
  font-size: 12px;
  font-weight: 650;
}

.oms-profiter-monthly-meta strong {
  color: #0f1217;
}

.oms-profiter-admin-panel {
  grid-column: 1 / -1;
  overflow: hidden;
}

.oms-profiter-admin-panel summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
  padding: 16px 20px;
  color: #0f1217;
  font-size: 14px;
  font-weight: 850;
}

.oms-profiter-admin-panel summary small {
  color: #5e6673;
  font-size: 12px;
  font-weight: 650;
}

.oms-profiter-admin-panel[open] summary {
  border-bottom: 1px solid #edf0f4;
}

.oms-profiter-admin-actions {
  display: flex;
  gap: 10px;
  padding: 16px 20px 0;
}

.oms-profiter-admin-panel .oms-analytics-split,
.oms-profiter-admin-panel > .oms-analytics-table-card {
  margin: 0;
  padding: 16px 20px 20px;
}

.oms-analytics-manual-form {
  grid-template-columns: minmax(150px, 1fr) minmax(100px, 120px) minmax(160px, 1fr) auto;
  margin-top: 10px;
}

.oms-manual-adjustment-list {
  display: grid;
  gap: 6px;
}

.oms-manual-adjustment-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #fbfcfd;
  padding: 8px 10px;
  color: #5e6673;
  font-size: 12px;
  font-weight: 700;
}

.oms-manual-adjustment-row strong {
  color: #0f1217;
  font-size: 13px;
}

.oms-manual-adjustment-row.positive em,
.oms-manual-adjustment-row.negative em {
  font-style: normal;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
}

.oms-manual-adjustment-row.positive em { color: #15803d; }
.oms-manual-adjustment-row.negative em { color: #dc2626; }

.oms-profiter-tooltip {
  position: fixed;
  z-index: 1000;
  width: max-content;
  max-width: min(420px, calc(100vw - 28px));
  border: 1px solid #dbe4ef;
  border-radius: 14px;
  background: rgba(15, 18, 23, 0.97);
  box-shadow: 0 22px 52px rgba(15, 23, 42, 0.26);
  padding: 14px;
  color: #f8fafc;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.45;
  pointer-events: none;
  white-space: pre-line;
}

.oms-profiter-tooltip.structured {
  min-width: 300px;
  border-color: rgba(148, 163, 184, 0.32);
  padding: 0;
  overflow: hidden;
  white-space: normal;
}

.oms-profiter-tooltip[hidden] {
  display: none;
}

.oms-profiter-tooltip-card {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.oms-profiter-tooltip-head {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #cbd5e1;
  font-size: 12px;
  font-weight: 800;
}

.oms-profiter-tooltip-head strong {
  color: #f8fafc;
  font-size: 13px;
}

.oms-profiter-tooltip-profit {
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.oms-profiter-tooltip-profit.positive,
.oms-profiter-tooltip-sources strong.positive,
.oms-profiter-tooltip-orders strong.positive {
  color: #86efac;
}

.oms-profiter-tooltip-profit.negative,
.oms-profiter-tooltip-sources strong.negative,
.oms-profiter-tooltip-orders strong.negative {
  color: #fca5a5;
}

.oms-profiter-tooltip-grid {
  display: grid;
  grid-template-columns: minmax(78px, 1fr) auto;
  gap: 5px 18px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  padding: 10px 0;
}

.oms-profiter-tooltip-grid span,
.oms-profiter-tooltip-sources em,
.oms-profiter-tooltip-muted {
  color: #94a3b8;
  font-size: 11px;
  font-weight: 750;
}

.oms-profiter-tooltip-grid strong {
  color: #f8fafc;
  font-size: 11.5px;
  font-weight: 900;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.oms-profiter-tooltip-section {
  color: #e2e8f0;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.oms-profiter-tooltip-sources,
.oms-profiter-tooltip-orders {
  display: grid;
  gap: 6px;
}

.oms-profiter-tooltip-sources > div,
.oms-profiter-tooltip-orders > div {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) auto;
  gap: 2px 14px;
  align-items: center;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.045);
  padding: 7px 9px;
}

.oms-profiter-tooltip-sources span,
.oms-profiter-tooltip-orders span {
  color: #f8fafc;
  font-size: 12px;
  font-weight: 850;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-profiter-tooltip-sources strong,
.oms-profiter-tooltip-orders strong {
  font-size: 12px;
  font-weight: 900;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.oms-profiter-tooltip-sources em {
  grid-column: 1 / -1;
  font-style: normal;
}

.oms-profiter-tooltip-muted {
  border-radius: 10px;
  background: rgba(148, 163, 184, 0.08);
  padding: 7px 9px;
}

@media (max-width: 1180px) {
  .oms-profiter-shell {
    padding-inline: 20px;
  }

  .oms-profiter-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .oms-profiter-grid,
  .oms-profiter-ads-card,
  .oms-profiter-trend-card {
    grid-column: 1;
    grid-template-columns: 1fr;
  }

  .oms-profiter-monthly {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .oms-profiter-monthly > div:first-child,
  .oms-profiter-monthly-meta {
    grid-column: 1 / -1;
  }
}

@media (max-width: 880px) {
  .oms-profiter-shell {
    padding-inline: 14px;
  }

  .oms-profiter-date-picker,
  .oms-profiter-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .oms-analytics-manual-form {
    grid-template-columns: 1fr;
  }

  .oms-profiter-main-card {
    padding: 20px;
  }

  .oms-profiter-profit-value {
    font-size: 48px;
  }

  .oms-profiter-kpis,
  .oms-profiter-monthly {
    grid-template-columns: 1fr;
  }

  .oms-profiter-kpi {
    text-align: left;
  }

  .oms-profiter-kpi:not(:last-child)::after {
    display: none;
  }

  .oms-profiter-monthly-metric {
    text-align: left;
  }

  .oms-profiter-trend-legend {
    align-items: flex-start;
    flex-direction: column;
  }

  .oms-profiter-trend-legend strong {
    margin-left: 0;
  }
}

.oms-analytics-command-view {
  background: #f3f6fb;
}

.oms-analytics-command-top {
  position: sticky;
  top: 0;
  z-index: 8;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid rgba(203, 213, 225, 0.86);
  background: rgba(255, 255, 255, 0.94);
  padding: 16px 20px;
  backdrop-filter: blur(14px);
}

.oms-analytics-heading {
  min-width: 280px;
  flex: 1 1 420px;
}

.oms-analytics-eyebrow {
  display: block;
  margin-bottom: 4px;
  color: #2563eb;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.oms-analytics-command-actions {
  align-items: flex-end;
  justify-content: flex-end;
  gap: 12px;
}

.oms-analytics-date-cluster,
.oms-analytics-primary-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.oms-analytics-preset-group {
  display: inline-flex;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: var(--oms-slate-100);
  padding: 3px;
}

.oms-analytics-preset {
  min-height: 28px;
  border-radius: 6px;
  background: transparent;
  padding: 0 10px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.oms-analytics-preset.active {
  background: #fff;
  color: var(--oms-slate-950);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
}

.oms-analytics-command-content {
  display: grid;
  width: 100%;
  max-width: 1480px;
  gap: 16px;
  margin: 0 auto;
  padding: 18px;
}

.oms-analytics-decision-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.55fr);
  gap: 16px;
}

.oms-analytics-decision-card,
.oms-analytics-insight-card,
.oms-analytics-market-section {
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.oms-analytics-decision-card {
  display: grid;
  gap: 18px;
  min-height: 238px;
  padding: 22px;
}

.oms-analytics-decision-card.positive {
  border-color: #bbf7d0;
  box-shadow: 0 14px 34px rgba(5, 150, 105, 0.08);
}

.oms-analytics-decision-card.negative {
  border-color: #fecaca;
  box-shadow: 0 14px 34px rgba(220, 38, 38, 0.08);
}

.oms-analytics-decision-card.neutral {
  border-color: #dbe4ef;
}

.oms-analytics-decision-head,
.oms-analytics-decision-main {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.oms-analytics-decision-badge,
.oms-analytics-decision-date {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  border-radius: 8px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
}

.oms-analytics-decision-badge {
  background: #e0f2fe;
  color: #0369a1;
}

.oms-analytics-decision-date {
  background: var(--oms-slate-100);
  color: var(--oms-slate-600);
}

.oms-analytics-profit-value {
  margin-top: 8px;
  color: var(--oms-slate-950);
  font-size: 44px;
  font-weight: 950;
  line-height: 1;
}

.oms-analytics-decision-card.positive .oms-analytics-profit-value {
  color: #047857;
}

.oms-analytics-decision-card.negative .oms-analytics-profit-value {
  color: #b91c1c;
}

.oms-analytics-decision-copy {
  display: grid;
  max-width: 420px;
  gap: 6px;
  padding-top: 22px;
  text-align: right;
}

.oms-analytics-decision-copy strong {
  color: var(--oms-slate-950);
  font-size: 18px;
  font-weight: 900;
}

.oms-analytics-decision-copy span {
  color: var(--oms-slate-500);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.45;
}

.oms-analytics-micro-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.oms-analytics-micro-grid > div {
  min-width: 0;
  border: 1px solid var(--oms-slate-200);
  border-radius: 8px;
  background: #f8fafc;
  padding: 12px;
}

.oms-analytics-micro-grid span,
.oms-analytics-micro-grid em {
  display: block;
  overflow: hidden;
  color: var(--oms-slate-500);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.oms-analytics-micro-grid strong {
  display: block;
  overflow: hidden;
  margin-top: 6px;
  color: var(--oms-slate-950);
  font-size: 18px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-analytics-micro-grid em {
  margin-top: 4px;
  text-transform: none;
}

.oms-analytics-insight-card {
  padding: 18px;
}

.oms-analytics-panel-title {
  margin-bottom: 12px;
  color: var(--oms-slate-950);
  font-size: 14px;
  font-weight: 900;
}

.oms-analytics-insight-list {
  display: grid;
  gap: 8px;
}

.oms-analytics-insight {
  display: grid;
  gap: 4px;
  border: 1px solid var(--oms-slate-200);
  border-left-width: 4px;
  border-radius: 8px;
  background: #f8fafc;
  padding: 10px 12px;
}

.oms-analytics-insight strong {
  color: var(--oms-slate-950);
  font-size: 13px;
  font-weight: 900;
}

.oms-analytics-insight span {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.oms-analytics-insight.ok {
  border-left-color: #10b981;
  background: #f0fdf4;
}

.oms-analytics-insight.warning {
  border-left-color: #f59e0b;
  background: #fffbeb;
}

.oms-analytics-insight.danger {
  border-left-color: #ef4444;
  background: #fef2f2;
}

.oms-analytics-insight.muted {
  border-left-color: #94a3b8;
}

.oms-analytics-market-section {
  padding: 16px;
}

.oms-analytics-market-section .oms-more-stores {
  margin-top: 0;
  border: 0;
  background: var(--oms-slate-100);
  padding: 6px 10px;
  text-align: left;
}

.oms-analytics-command-view .oms-stores-grid {
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}

.oms-analytics-command-view .oms-store-item {
  min-height: 92px;
  border-color: #dbe4ef;
  background: #fff;
  padding: 12px;
  text-align: left;
}

.oms-analytics-command-view .oms-store-item.positive {
  border-color: #bbf7d0;
  background: #f8fffb;
}

.oms-analytics-command-view .oms-store-item.negative {
  border-color: #fecaca;
  background: #fff7f7;
}

.oms-analytics-command-view .oms-store-name {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--oms-slate-600);
  font-size: 12px;
  font-weight: 850;
}

.oms-analytics-command-view .oms-store-name span {
  flex: 0 0 auto;
}

.oms-analytics-command-view .oms-store-value {
  margin-top: 10px;
  font-size: 18px;
  line-height: 1.05;
}

.oms-analytics-command-view .oms-store-value.pos {
  color: #047857;
}

.oms-analytics-command-view .oms-store-value.neg {
  color: #b91c1c;
}

.oms-analytics-command-view .oms-store-orders {
  margin-top: 6px;
  color: var(--oms-slate-500);
  font-size: 11.5px;
  font-weight: 750;
  line-height: 1.35;
}

.oms-analytics-chart-card,
.oms-analytics-month-section {
  margin-bottom: 0;
}

.oms-analytics-admin-panel {
  margin-top: 16px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background: #fff;
}

.oms-analytics-admin-panel summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  cursor: pointer;
  padding: 14px 16px;
  color: var(--oms-slate-950);
  font-size: 14px;
  font-weight: 900;
}

.oms-analytics-admin-panel summary small {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 750;
}

.oms-analytics-admin-panel[open] summary {
  border-bottom: 1px solid var(--oms-slate-100);
}

.oms-analytics-admin-panel .oms-analytics-split {
  padding: 0 16px 16px;
}

@media (max-width: 1180px) {
  .oms-analytics-decision-grid {
    grid-template-columns: 1fr;
  }

  .oms-analytics-micro-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 880px) {
  .oms-analytics-command-top,
  .oms-analytics-decision-main,
  .oms-analytics-decision-head,
  .oms-analytics-admin-panel summary {
    align-items: flex-start;
    flex-direction: column;
  }

  .oms-analytics-command-actions,
  .oms-analytics-date-cluster,
  .oms-analytics-primary-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .oms-analytics-decision-copy {
    max-width: none;
    padding-top: 0;
    text-align: left;
  }

  .oms-analytics-profit-value {
    font-size: 36px;
  }

  .oms-analytics-micro-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1180px) {
  .oms-filters-panel {
    flex-basis: 206px;
    width: 206px;
    min-width: 206px;
  }

  .oms-user span:last-child,
  .oms-current-link {
    display: none;
  }

  .oms-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .oms-mirror-grid {
    grid-template-columns: repeat(2, minmax(150px, 1fr));
  }

  .oms-metrics-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .oms-order-operator-card {
    grid-template-columns: 1fr;
  }

  .oms-order-operator-actions {
    justify-content: flex-start;
  }

  .oms-order-operator-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .oms-batch-pack-shell {
    width: calc(100vw - 16px);
  }

  .oms-batch-pack-body {
    grid-template-columns: 230px minmax(0, 1fr);
  }

  .oms-batch-product-row {
    grid-template-columns: 62px minmax(0, 1fr) 220px 62px;
  }

  .oms-batch-product-name {
    font-size: 21px;
  }

  .oms-footer-secondary,
  .oms-footer-success {
    min-width: 150px;
    padding-inline: 18px;
  }
}

@media (max-width: 880px) {
  .oms-app {
    min-width: 760px;
  }

  .oms-detail-grid,
  .oms-address-grid,
  .oms-address-edit-grid,
  .oms-manual-product-grid,
  .oms-bottom-grid,
  .oms-kpi-grid,
  .oms-mirror-grid,
  .oms-order-operator-stats,
  .oms-warehouse-reservation-metrics,
  .oms-metrics-grid {
    grid-template-columns: 1fr;
  }

  .oms-analytics-top,
  .oms-chart-header,
  .oms-section-header,
  .oms-summary-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .oms-analytics-actions,
  .oms-chart-controls {
    flex-wrap: wrap;
  }

  .oms-automation-card-head,
  .oms-safety-flag-row {
    align-items: flex-start;
  }

  .oms-safety-flag-row {
    flex-direction: column;
  }

  .oms-safety-flag-side {
    width: 100%;
    justify-content: space-between;
  }

  .oms-batch-pack-shell {
    height: calc(100vh - 16px);
    grid-template-rows: 64px auto auto auto minmax(0, 1fr) auto;
  }

  .oms-batch-pack-body {
    grid-template-columns: 1fr;
  }

  .oms-batch-order-list {
    display: flex;
    max-height: 112px;
    gap: 8px;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.22);
  }

  .oms-batch-order-card {
    min-width: 214px;
  }

  .oms-batch-product-row {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .oms-batch-product-controls,
  .oms-batch-product-done {
    grid-column: 2;
  }

  .oms-batch-pack-footer {
    grid-template-columns: 1fr;
    gap: 10px;
    padding-block: 12px;
  }

  .oms-batch-footer-left,
  .oms-batch-footer-right {
    justify-content: center;
    flex-wrap: wrap;
  }
}

/* Profiter 2.0 visual parity layer. Scoped to Analityka only. */
.oms-app[data-profiter-focus="true"] .oms-main,
.oms-app[data-profiter-focus="true"] .oms-workspace {
  background:
    radial-gradient(circle at 15% 0%, rgba(0, 212, 255, 0.14), transparent 32%),
    radial-gradient(circle at 80% 8%, rgba(255, 0, 128, 0.10), transparent 28%),
    #0d0d1a;
}

.oms-profiter2-view {
  --p2-bg: #0d0d1a;
  --p2-card: rgba(255, 255, 255, 0.055);
  --p2-card-strong: rgba(255, 255, 255, 0.085);
  --p2-border: rgba(255, 255, 255, 0.11);
  --p2-border-strong: rgba(255, 255, 255, 0.18);
  --p2-text: #e0e0ff;
  --p2-muted: #a0a0c0;
  --p2-muted-2: #72729a;
  --p2-blue: #00d4ff;
  --p2-pink: #ff0080;
  --p2-green: #00ff88;
  --p2-red: #ff4444;
  --p2-orange: #ffb000;
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  background:
    linear-gradient(180deg, rgba(13, 13, 26, 0.98), rgba(13, 13, 26, 0.98)),
    var(--p2-bg);
  color: var(--p2-text);
}

.oms-profiter2-shell {
  width: min(1520px, 100%);
  padding: 22px 28px 56px;
}

.oms-profiter2-header {
  min-height: 82px;
  border-bottom: 1px solid var(--p2-border);
  background: rgba(13, 13, 26, 0.82);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.20);
}

.oms-profiter2-eyebrow {
  margin: 0 0 4px;
  color: var(--p2-blue);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.oms-profiter2-view .oms-profiter-logo {
  color: var(--p2-text);
  font-size: 34px;
  letter-spacing: -0.03em;
}

.oms-profiter2-view .oms-profiter-date-label {
  color: var(--p2-muted);
}

.oms-profiter2-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}

.oms-profiter2-view .oms-profiter-date-picker,
.oms-profiter2-view .oms-profiter-month-field {
  border: 1px solid var(--p2-border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
  padding: 7px;
}

.oms-profiter2-view .oms-profiter-date-picker label,
.oms-profiter2-view .oms-profiter-month-field {
  color: var(--p2-muted);
}

.oms-profiter2-view .oms-profiter-date-picker button {
  color: var(--p2-text);
}

.oms-profiter2-view .oms-profiter-date-picker button:hover {
  background: rgba(255, 255, 255, 0.10);
  color: #fff;
}

.oms-profiter2-view .oms-profiter-date-picker input,
.oms-profiter2-view .oms-profiter-month-field select,
.oms-profiter2-view .oms-profiter-month-field input {
  border-color: rgba(255, 255, 255, 0.10);
  background: rgba(0, 0, 0, 0.18);
  color: var(--p2-text);
}

.oms-profiter2-view .oms-profiter-date-picker input:focus,
.oms-profiter2-view .oms-profiter-month-field select:focus,
.oms-profiter2-view .oms-profiter-month-field input:focus {
  border-color: rgba(0, 212, 255, 0.55);
  box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.15);
  outline: none;
}

.oms-profiter2-view .oms-profiter-action {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.20);
}

.oms-profiter2-view .oms-profiter-action.primary {
  background: linear-gradient(135deg, #00d4ff, #0077ff);
}

.oms-profiter2-view .oms-profiter-action.success {
  background: linear-gradient(135deg, #00ff88, #00b866);
  color: #06140c;
}

.oms-profiter2-view .oms-profiter-action.neutral {
  background: rgba(255, 255, 255, 0.08);
  color: var(--p2-text);
}

.oms-profiter2-stats-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 18px;
  margin-top: 22px;
}

.oms-profiter2-view .oms-profiter-card,
.oms-profiter2-view .oms-profiter-admin-panel {
  border: 1px solid var(--p2-border);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.085), rgba(255, 255, 255, 0.035));
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.26);
  color: var(--p2-text);
}

.oms-profiter2-profit-card {
  grid-column: span 2;
  min-height: 244px;
}

.oms-profiter2-kpi-card {
  display: flex;
  min-height: 244px;
  flex-direction: column;
  justify-content: center;
  padding: 22px;
}

.oms-profiter2-source-card {
  grid-column: span 2;
  min-height: 244px;
  padding: 22px;
}

.oms-profiter2-view .oms-profiter-state-pill {
  background: rgba(0, 255, 136, 0.14);
  color: var(--p2-green);
}

.oms-profiter2-view .oms-profiter-state-date {
  background: rgba(255, 255, 255, 0.08);
  color: var(--p2-muted);
}

.oms-profiter2-view .oms-profiter-profit-hero {
  padding: 24px 0 8px;
}

.oms-profiter2-view .oms-profiter-profit-value {
  color: var(--p2-green);
  font-size: clamp(42px, 5.2vw, 78px);
  letter-spacing: -0.055em;
  text-shadow: 0 0 30px rgba(0, 255, 136, 0.22);
}

.oms-profiter2-view .oms-profiter-main-card.negative .oms-profiter-profit-value {
  color: var(--p2-red);
  text-shadow: 0 0 30px rgba(255, 68, 68, 0.22);
}

.oms-profiter2-view .oms-profiter-profit-label,
.oms-profiter2-view .oms-profiter-profit-note {
  color: var(--p2-muted);
}

.oms-profiter2-kpi-card span,
.oms-profiter2-month-metric span,
.oms-profiter2-allegro-grid span {
  color: var(--p2-muted);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.oms-profiter2-kpi-card strong {
  display: block;
  margin-top: 12px;
  color: var(--p2-text);
  overflow: hidden;
  font-size: clamp(23px, 1.95vw, 30px);
  font-weight: 950;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-profiter2-kpi-card em {
  margin-top: 10px;
  color: var(--p2-blue);
  font-style: normal;
  font-weight: 850;
}

.oms-profiter2-ad-spend-card strong {
  color: var(--p2-pink);
}

.oms-profiter2-view .oms-profiter-card-title,
.oms-profiter2-card-head h2 {
  color: var(--p2-text);
}

.oms-profiter2-view .oms-profiter-card-title small,
.oms-profiter2-card-head p,
.oms-profiter2-card-head small {
  color: var(--p2-muted);
}

.oms-profiter2-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.oms-profiter2-card-head.compact {
  margin-bottom: 14px;
}

.oms-profiter2-card-head h2 {
  margin: 0;
  font-size: 21px;
  font-weight: 950;
  letter-spacing: -0.02em;
}

.oms-profiter2-card-head p {
  margin: 5px 0 0;
  font-size: 13px;
  font-weight: 650;
}

.oms-profiter2-view .oms-profiter-source {
  border-color: rgba(255, 255, 255, 0.10);
  background: rgba(255, 255, 255, 0.05);
}

.oms-profiter2-view .oms-profiter-source::before {
  background: linear-gradient(90deg, rgba(0, 255, 136, 0.20), rgba(0, 255, 136, 0.04));
}

.oms-profiter2-view .oms-profiter-source.negative::before {
  background: linear-gradient(90deg, rgba(255, 68, 68, 0.22), rgba(255, 68, 68, 0.04));
}

.oms-profiter2-view .oms-profiter-source:hover {
  border-color: rgba(0, 212, 255, 0.36);
  box-shadow: 0 12px 34px rgba(0, 212, 255, 0.10);
}

.oms-profiter2-view .oms-profiter-source-rank {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(13, 13, 26, 0.72);
  color: var(--p2-muted);
}

.oms-profiter2-view .oms-profiter-source.positive:nth-child(-n+3) .oms-profiter-source-rank {
  border-color: rgba(0, 212, 255, 0.42);
  background: rgba(0, 212, 255, 0.14);
  color: var(--p2-blue);
}

.oms-profiter2-view .oms-profiter-source-main strong,
.oms-profiter2-view .oms-profiter-ad-top,
.oms-profiter2-view .oms-profiter-trend-legend strong {
  color: var(--p2-text);
}

.oms-profiter2-view .oms-profiter-source-main span,
.oms-profiter2-view .oms-profiter-ad-top span,
.oms-profiter2-view .oms-profiter-trend-legend {
  color: var(--p2-muted);
}

.oms-profiter2-view .oms-profiter-source-value {
  color: var(--p2-green);
}

.oms-profiter2-view .oms-profiter-source.negative .oms-profiter-source-value {
  color: var(--p2-red);
}

.oms-profiter2-view .oms-profiter-source.zero .oms-profiter-source-value {
  color: var(--p2-muted);
}

.oms-profiter2-chart-card,
.oms-profiter2-month-card,
.oms-profiter2-alerts,
.oms-profiter2-bottom-grid,
.oms-profiter2-admin-panel {
  margin-top: 18px;
}

.oms-profiter2-chart-card,
.oms-profiter2-month-card {
  padding: 24px;
}

.oms-profiter2-chart-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}

.oms-profiter2-chart-switcher {
  display: inline-flex;
  border: 1px solid var(--p2-border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
}

.oms-profiter2-chart-switcher button {
  min-height: 32px;
  border-radius: 9px;
  padding: 0 12px;
  color: var(--p2-muted);
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.oms-profiter2-chart-switcher button.active,
.oms-profiter2-chart-switcher button:hover {
  background: rgba(0, 212, 255, 0.16);
  color: var(--p2-text);
}

.oms-profiter2-chart-stage {
  margin-top: 26px;
  overflow: visible;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.14);
  padding: 28px 18px 20px;
}

.oms-profiter2-view .oms-profiter-trend-chart {
  height: 230px;
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.oms-profiter2-view .oms-profiter-bar {
  max-width: 30px;
  background: rgba(255, 255, 255, 0.18);
}

.oms-profiter2-view .oms-profiter-bar-col.positive .oms-profiter-bar {
  background: linear-gradient(180deg, #00ff88, #00b866);
  box-shadow: 0 0 18px rgba(0, 255, 136, 0.18);
}

.oms-profiter2-view .oms-profiter-bar-col.negative .oms-profiter-bar {
  background: linear-gradient(180deg, #ff6464, #ff2222);
  box-shadow: 0 0 18px rgba(255, 68, 68, 0.18);
}

.oms-profiter2-view .oms-profiter-bar-col.selected .oms-profiter-bar {
  box-shadow: 0 0 0 2px #0d0d1a inset, 0 0 0 4px rgba(0, 212, 255, 0.6), 0 8px 24px rgba(0, 212, 255, 0.22);
}

.oms-profiter2-view .oms-profiter-bar-col span {
  color: var(--p2-muted);
}

.oms-profiter2-view .oms-profiter-bar-col.selected span {
  color: var(--p2-blue);
}

.oms-profiter2-view .oms-chart-bars {
  min-height: 250px;
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.oms-profiter2-view .oms-bar {
  background: linear-gradient(180deg, #00ff88, #00b866);
}

.oms-profiter2-view .oms-bar.negative {
  background: linear-gradient(180deg, #ff6464, #ff2222);
}

.oms-profiter2-view .oms-bar-label,
.oms-profiter2-view .oms-line-labels {
  color: var(--p2-muted);
}

.oms-profiter2-view .oms-profit-line-path {
  stroke: var(--p2-blue);
}

.oms-profiter2-view .oms-profit-line-point {
  fill: var(--p2-blue);
  stroke: #0d0d1a;
}

.oms-profiter2-view .oms-profit-line-point.neg {
  fill: var(--p2-red);
}

.oms-profiter2-view .oms-profit-zero-line {
  stroke: rgba(255, 255, 255, 0.16);
}

.oms-profiter2-view .oms-chart-table-view table,
.oms-profiter2-view .oms-profiter2-mini-table table,
.oms-profiter2-view .oms-analytics-table table {
  color: var(--p2-text);
}

.oms-profiter2-view .oms-chart-table-view th,
.oms-profiter2-view .oms-profiter2-mini-table th,
.oms-profiter2-view .oms-analytics-table th {
  color: var(--p2-muted);
}

.oms-profiter2-view .oms-chart-table-view td,
.oms-profiter2-view .oms-profiter2-mini-table td,
.oms-profiter2-view .oms-analytics-table td {
  border-color: rgba(255, 255, 255, 0.08);
}

.oms-profiter2-chart-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
  color: var(--p2-muted);
  font-size: 13px;
  font-weight: 750;
}

.oms-profiter2-chart-summary strong {
  color: var(--p2-text);
}

.oms-profiter2-month-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.oms-profiter2-month-metric {
  min-height: 116px;
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.045);
  padding: 16px;
  text-align: left;
  cursor: default;
}

.oms-profiter2-month-metric strong {
  display: block;
  margin-top: 12px;
  color: var(--p2-text);
  font-size: 23px;
  font-weight: 950;
  line-height: 1;
}

.oms-profiter2-month-metric em {
  display: block;
  margin-top: 8px;
  color: var(--p2-muted-2);
  font-style: normal;
  font-weight: 750;
}

.oms-profiter2-month-metric.green strong { color: var(--p2-green); }
.oms-profiter2-month-metric.blue strong { color: var(--p2-blue); }
.oms-profiter2-month-metric.orange strong { color: #ff8c42; }
.oms-profiter2-month-metric.yellow strong { color: #ffd447; }
.oms-profiter2-month-metric.purple strong { color: #b16cff; }

.oms-profiter2-bottom-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: 18px;
}

.oms-profiter2-view .oms-profiter-ads-card {
  min-height: 320px;
  padding: 24px;
}

.oms-profiter2-view .oms-profiter-ad-icon {
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 11px;
}

.oms-profiter2-view .oms-profiter-ad-icon.allegro { background: rgba(255, 90, 0, 0.16); color: #ff8a3d; }
.oms-profiter2-view .oms-profiter-ad-icon.google { background: rgba(66, 133, 244, 0.16); color: #7bb0ff; }
.oms-profiter2-view .oms-profiter-ad-icon.meta { background: rgba(8, 102, 255, 0.16); color: #5d9cff; }
.oms-profiter2-view .oms-profiter-ad-icon.sklik { background: rgba(204, 0, 0, 0.18); color: #ff6b6b; }

.oms-profiter2-view .oms-profiter-ad-bar {
  background: rgba(255, 255, 255, 0.10);
}

.oms-profiter2-allegro-card {
  padding: 24px;
}

.oms-profiter2-allegro-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.oms-profiter2-allegro-grid div {
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.045);
  padding: 14px;
}

.oms-profiter2-allegro-grid strong {
  display: block;
  margin-top: 8px;
  color: var(--p2-text);
  font-size: 18px;
  font-weight: 950;
}

.oms-profiter2-mini-table {
  overflow-x: auto;
}

.oms-profiter2-alerts {
  padding: 20px;
}

.oms-profiter2-view .oms-profiter-pill {
  border-color: rgba(255, 255, 255, 0.10);
  background: rgba(255, 255, 255, 0.06);
  color: var(--p2-muted);
}

.oms-profiter2-view .oms-profiter-pill.warning {
  border-color: rgba(255, 176, 0, 0.32);
  background: rgba(255, 176, 0, 0.10);
  color: #ffd447;
}

.oms-profiter2-view .oms-profiter-pill.danger {
  border-color: rgba(255, 68, 68, 0.32);
  background: rgba(255, 68, 68, 0.10);
  color: #ff8f8f;
}

.oms-profiter2-view .oms-profiter-pill.ok {
  border-color: rgba(0, 255, 136, 0.28);
  background: rgba(0, 255, 136, 0.10);
  color: var(--p2-green);
}

.oms-profiter2-admin-panel {
  overflow: hidden;
}

.oms-profiter2-view .oms-profiter-admin-panel summary {
  color: var(--p2-text);
}

.oms-profiter2-view .oms-profiter-admin-panel summary small,
.oms-profiter2-view .oms-section-subtitle,
.oms-profiter2-view .oms-empty-inline {
  color: var(--p2-muted);
}

.oms-profiter2-view .oms-profiter-admin-panel[open] summary,
.oms-profiter2-view .oms-analytics-table-card {
  border-color: rgba(255, 255, 255, 0.10);
}

.oms-profiter2-view .oms-analytics-table-card {
  background: rgba(255, 255, 255, 0.035);
}

.oms-profiter2-view .oms-section-title {
  color: var(--p2-text);
}

.oms-profiter2-view .oms-analytics-cost-form input,
.oms-profiter2-view .oms-analytics-cost-form select,
.oms-profiter2-view .oms-analytics-product-cost-form input,
.oms-profiter2-view .oms-analytics-product-cost-form select,
.oms-profiter2-view .oms-analytics-manual-form input,
.oms-profiter2-view .oms-analytics-manual-form select {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.20);
  color: var(--p2-text);
}

.oms-profiter2-view .oms-table-icon-btn,
.oms-profiter2-view .oms-btn-primary.compact {
  border-color: rgba(255, 255, 255, 0.12);
}

.oms-profiter2-view .oms-status,
.oms-profiter2-view .oms-analytics-status {
  border-color: rgba(0, 212, 255, 0.26);
  background: rgba(0, 212, 255, 0.10);
  color: var(--p2-text);
}

.oms-profiter2-view .oms-analytics-status.error {
  border-color: rgba(255, 68, 68, 0.32);
  background: rgba(255, 68, 68, 0.10);
  color: #ffb4b4;
}

@media (max-width: 1320px) {
  .oms-profiter2-stats-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .oms-profiter2-profit-card,
  .oms-profiter2-source-card {
    grid-column: span 3;
  }

  .oms-profiter2-month-grid,
  .oms-profiter2-allegro-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .oms-profiter2-shell {
    padding-inline: 16px;
  }

  .oms-profiter2-header,
  .oms-profiter2-card-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .oms-profiter2-toolbar,
  .oms-profiter2-view .oms-profiter-actions,
  .oms-profiter2-chart-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .oms-profiter2-stats-grid,
  .oms-profiter2-bottom-grid,
  .oms-profiter2-month-grid,
  .oms-profiter2-allegro-grid {
    grid-template-columns: 1fr;
  }

  .oms-profiter2-profit-card,
  .oms-profiter2-source-card {
    grid-column: auto;
  }
}

/* Profiter 2.0 legacy parity. This section intentionally mirrors the old
   /Users/apple/Desktop/velenoflow-dashboard dashboard proportions. */
.oms-p2-legacy {
  --bg-primary: #f5f7fb;
  --bg-secondary: #ffffff;
  --bg-tertiary: #eef2f7;
  --text-primary: #101828;
  --text-secondary: #667085;
  --accent-blue: #2563eb;
  --accent-pink: #db2777;
  --accent-green: #16a34a;
  --accent-red: #dc2626;
  --border-color: #d7dee8;
  --pane-bg: rgba(255, 255, 255, 0.92);
  --panel-bg: #ffffff;
  --panel-muted-bg: #f1f5f9;
  --soft-border: rgba(15, 23, 42, 0.10);
  --soft-hover: rgba(37, 99, 235, 0.08);
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.oms-app[data-profiter-focus="true"] .oms-main,
.oms-app[data-profiter-focus="true"] .oms-workspace {
  background: #e8edf5;
}

.oms-p2-shell {
  width: min(1540px, 100%);
  margin: 0 auto;
  padding: 24px 28px 56px;
}

.oms-p2-legacy .glass-pane {
  border: 1px solid var(--border-color);
  border-radius: 16px;
  background: var(--pane-bg);
  box-shadow: 0 10px 28px rgba(16, 24, 40, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.oms-p2-topbar {
  display: flex;
  min-height: 72px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
  padding: 14px 18px;
}

.oms-p2-title h1 {
  margin: 0;
  color: var(--text-primary);
  font-size: 28px;
  font-weight: 850;
  letter-spacing: -0.02em;
  line-height: 1.05;
}

.oms-p2-title p {
  margin: 5px 0 0;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 650;
}

.oms-p2-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}

.oms-p2-date-field {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  background: var(--bg-secondary);
  padding: 4px 6px 4px 12px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 700;
}

.oms-p2-date-field input {
  width: 142px;
  height: 30px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  padding: 0 8px;
  font: inherit;
  font-size: 13px;
  color-scheme: light;
}

.oms-p2-date-field button {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-primary);
  font-size: 20px;
  font-weight: 850;
  cursor: pointer;
}

.oms-p2-date-field button:hover {
  background: var(--soft-hover);
}

.oms-p2-legacy .btn-primary,
.oms-p2-legacy .btn-success,
.oms-p2-legacy .btn-warning,
.oms-p2-legacy .btn-secondary {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 0;
  border-radius: 10px;
  color: #fff;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.oms-p2-legacy .btn-lg {
  min-height: 40px;
  padding: 0 16px;
  font-size: 13px;
}

.oms-p2-legacy .btn-sm {
  min-height: 34px;
  padding: 0 12px;
  font-size: 12px;
}

.oms-p2-legacy .btn-primary {
  background: linear-gradient(135deg, #1f2937, #000);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.oms-p2-legacy .btn-success {
  background: linear-gradient(135deg, #10b981, #059669);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
}

.oms-p2-legacy .btn-warning {
  background: linear-gradient(135deg, #f97316, #ea580c);
  box-shadow: 0 4px 12px rgba(249, 115, 22, 0.36);
}

.oms-p2-legacy .btn-secondary {
  border: 1px solid var(--border-color);
  background: #ffffff;
  color: var(--text-primary);
  backdrop-filter: blur(10px);
}

.oms-p2-legacy .btn-primary:hover,
.oms-p2-legacy .btn-success:hover,
.oms-p2-legacy .btn-warning:hover,
.oms-p2-legacy .btn-secondary:hover {
  transform: translateY(-1px);
  filter: saturate(1.08);
}

.oms-p2-legacy button:disabled {
  cursor: not-allowed;
  opacity: 0.58;
  transform: none;
}

.oms-p2-stats-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 24px;
  margin-bottom: 32px;
}

.oms-p2-legacy .stat-card {
  min-height: 172px;
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94),
    box-shadow 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.oms-p2-legacy .stat-card:hover {
  box-shadow: 0 0 20px rgba(0, 191, 255, 0.2);
  transform: translateY(-5px);
}

.oms-p2-profit-card {
  grid-column: span 2;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px;
}

.oms-p2-profit-copy p,
.oms-p2-kpi-card p {
  margin: 0 0 8px;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 650;
}

.oms-p2-profit-copy strong {
  display: block;
  overflow-wrap: anywhere;
  color: var(--accent-green);
  font-size: clamp(32px, 2.55vw, 44px);
  font-weight: 850;
  line-height: 1.05;
}

.oms-p2-profit-card.negative .oms-p2-profit-copy strong {
  color: var(--accent-red);
}

.oms-p2-profit-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #4ade80;
  font-size: 13px;
  font-weight: 700;
}

.oms-p2-profit-meta span,
.oms-p2-profit-meta small {
  display: inline-flex;
  max-width: 100%;
  min-height: 26px;
  align-items: center;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.12);
  padding: 0 10px;
  color: #4ade80;
  white-space: nowrap;
}

.oms-p2-profit-meta span.quality-ok,
.oms-p2-chip.quality-ok {
  border: 1px solid rgba(34, 197, 94, 0.22);
  background: rgba(34, 197, 94, 0.12);
  color: #16a34a;
}

.oms-p2-profit-meta span.quality-warning,
.oms-p2-chip.quality-warning {
  border: 1px solid rgba(245, 158, 11, 0.28);
  background: rgba(245, 158, 11, 0.14);
  color: #b45309;
}

.oms-p2-profit-meta span.quality-danger,
.oms-p2-chip.quality-danger {
  border: 1px solid rgba(239, 68, 68, 0.28);
  background: rgba(239, 68, 68, 0.13);
  color: #dc2626;
}

.oms-p2-profit-meta span.quality-muted,
.oms-p2-chip.quality-muted {
  border: 1px solid var(--soft-border);
  background: var(--panel-muted-bg);
  color: var(--text-secondary);
}

.oms-p2-profit-meta small {
  background: var(--panel-muted-bg);
  color: var(--text-secondary);
}

.oms-p2-profit-note {
  margin: 10px 0 0;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.45;
}

.oms-p2-kpi-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 24px;
}

.oms-p2-kpi-card strong {
  display: block;
  overflow: visible;
  overflow-wrap: anywhere;
  color: var(--text-primary);
  font-size: clamp(28px, 2.05vw, 40px);
  font-weight: 850;
  line-height: 1.05;
  text-overflow: clip;
  white-space: normal;
}

.oms-p2-kpi-card span {
  display: block;
  margin-top: 8px;
  overflow: visible;
  overflow-wrap: anywhere;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 650;
  text-overflow: clip;
  white-space: normal;
}

.oms-p2-store-results {
  grid-column: span 2;
  min-height: 172px;
  border-radius: 16px;
  background: var(--panel-bg);
  padding: 16px;
}

.oms-p2-store-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.oms-p2-store-mini {
  appearance: none;
  min-width: 0;
  border: 1px solid var(--soft-border);
  border-radius: 12px;
  background: var(--panel-muted-bg);
  padding: 10px 8px;
  color: inherit;
  font: inherit;
  text-align: center;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.oms-p2-store-mini:hover {
  border-color: rgba(0, 191, 255, 0.35);
  transform: scale(1.03);
}

.oms-p2-store-mini.selected {
  border-color: rgba(37, 99, 235, 0.58);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12), 0 12px 28px rgba(15, 23, 42, 0.08);
}

.oms-p2-store-mini .head {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-bottom: 7px;
  color: var(--text-primary);
  font-size: 12px;
  font-weight: 750;
}

.oms-p2-store-mini .head span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-p2-store-mini .profit {
  overflow-wrap: anywhere;
  color: #9ca3af;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.15;
}

.oms-p2-store-mini.positive .profit { color: #4ade80; }
.oms-p2-store-mini.negative .profit { color: #f87171; }
.oms-p2-store-mini.error .profit { color: #fb7185; }

.oms-p2-store-mini .orders {
  margin-top: 5px;
  color: #6b7280;
  font-size: 11px;
  font-weight: 650;
}

.oms-p2-store-more {
  display: flex;
  min-height: 30px;
  align-items: center;
  justify-content: center;
  margin-top: 10px;
  border: 1px dashed rgba(148, 163, 184, 0.34);
  border-radius: 10px;
  color: #9ca3af;
  font-size: 12px;
  font-weight: 700;
}

.oms-p2-store-more button {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

.oms-p2-store-more button:hover {
  color: var(--accent-color, #2563eb);
}

.oms-analytics-drilldown-panel {
  margin-bottom: 32px;
  padding: 24px;
}

.oms-analytics-drilldown-panel[hidden] {
  display: none;
}

.oms-analytics-drilldown-body {
  display: grid;
  gap: 16px;
}

.oms-analytics-drilldown-summary {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
}

.oms-analytics-drilldown-summary > div {
  min-width: 0;
  border: 1px solid var(--soft-border);
  border-radius: 14px;
  background: var(--panel-muted-bg);
  padding: 12px;
}

.oms-analytics-drilldown-summary span {
  display: block;
  overflow: hidden;
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.03em;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.oms-analytics-drilldown-summary strong {
  display: block;
  margin-top: 6px;
  color: var(--text-primary);
  font-size: 15px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.oms-analytics-drilldown-summary strong.pos {
  color: #16a34a;
}

.oms-analytics-drilldown-summary strong.neg {
  color: #dc2626;
}

.oms-analytics-drilldown-table {
  overflow: auto;
  border: 1px solid var(--soft-border);
  border-radius: 16px;
  background: #fff;
}

.oms-analytics-drilldown-table table {
  width: 100%;
  min-width: 1040px;
  border-collapse: collapse;
}

.oms-analytics-drilldown-table th,
.oms-analytics-drilldown-table td {
  border-bottom: 1px solid var(--soft-border);
  padding: 10px 12px;
  color: var(--text-primary);
  font-size: 12px;
  font-weight: 750;
  text-align: right;
  vertical-align: top;
  white-space: nowrap;
}

.oms-analytics-drilldown-table th {
  background: var(--panel-muted-bg);
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.oms-analytics-drilldown-table th:nth-child(2),
.oms-analytics-drilldown-table th:nth-child(3),
.oms-analytics-drilldown-table td:nth-child(2),
.oms-analytics-drilldown-table td:nth-child(3) {
  text-align: left;
}

.oms-analytics-drilldown-table td strong,
.oms-analytics-drilldown-table td small,
.oms-analytics-drilldown-table td em {
  display: block;
}

.oms-analytics-drilldown-table td small {
  margin-top: 2px;
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 700;
}

.oms-analytics-drilldown-table td em {
  margin-top: 3px;
  color: #b45309;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  text-transform: uppercase;
}

.oms-analytics-missing-cost {
  display: block;
  margin: 4px 0 0 auto;
  border: 0;
  border-bottom: 1px solid rgba(180, 83, 9, 0.32);
  background: transparent;
  padding: 0 0 1px;
  color: #b45309;
  font: inherit;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.015em;
  text-transform: uppercase;
  cursor: pointer;
}

.oms-analytics-missing-cost:hover,
.oms-analytics-missing-cost:focus-visible {
  border-bottom-color: #92400e;
  color: #92400e;
  outline: none;
}

.oms-analytics-product-cost-editor {
  overflow: hidden;
  border: 1px solid rgba(180, 83, 9, 0.24);
  border-radius: 14px;
  background: #fffbeb;
  box-shadow: 0 10px 28px rgba(120, 53, 15, 0.08);
}

.oms-analytics-product-cost-editor-head,
.oms-analytics-product-cost-editor-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 16px;
}

.oms-analytics-product-cost-editor-head {
  border-bottom: 1px solid rgba(180, 83, 9, 0.16);
}

.oms-analytics-product-cost-editor-head > div {
  display: grid;
  gap: 2px;
}

.oms-analytics-product-cost-editor-head span {
  color: #b45309;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.oms-analytics-product-cost-editor-head strong {
  color: var(--text-primary);
  font-size: 16px;
  font-weight: 900;
}

.oms-analytics-product-cost-editor-head small,
.oms-analytics-product-cost-editor-row small {
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 700;
}

.oms-analytics-product-cost-editor-head > button {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  border: 1px solid rgba(180, 83, 9, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: #78350f;
  font: inherit;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.oms-analytics-product-cost-editor-list {
  display: grid;
}

.oms-analytics-product-cost-editor-row {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(190px, 240px);
  align-items: center;
  gap: 20px;
  padding: 13px 16px;
}

.oms-analytics-product-cost-editor-row + .oms-analytics-product-cost-editor-row {
  border-top: 1px solid rgba(180, 83, 9, 0.12);
}

.oms-analytics-product-cost-editor-row > span:first-child {
  display: grid;
  gap: 3px;
}

.oms-analytics-product-cost-editor-row strong {
  overflow: hidden;
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 850;
  text-overflow: ellipsis;
}

.oms-analytics-product-cost-editor-row.unavailable {
  opacity: 0.72;
}

.oms-analytics-product-cost-editor-row > em {
  color: #991b1b;
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
  text-align: right;
}

.oms-analytics-product-cost-editor-input {
  position: relative;
  display: grid;
}

.oms-analytics-product-cost-editor-input input {
  width: 100%;
  min-height: 42px;
  border: 1px solid rgba(180, 83, 9, 0.26);
  border-radius: 9px;
  background: #fff;
  padding: 9px 104px 9px 12px;
  color: var(--text-primary);
  font: inherit;
  font-size: 14px;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
}

.oms-analytics-product-cost-editor-input input:focus {
  border-color: #d97706;
  box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.12);
  outline: none;
}

.oms-analytics-product-cost-editor-input em {
  position: absolute;
  top: 50%;
  right: 11px;
  color: #92400e;
  font-size: 10px;
  font-style: normal;
  font-weight: 850;
  transform: translateY(-50%);
}

.oms-analytics-product-cost-editor-foot {
  border-top: 1px solid rgba(180, 83, 9, 0.16);
  background: rgba(255, 255, 255, 0.46);
}

.oms-analytics-product-cost-editor-foot > span {
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 750;
}

.oms-analytics-product-cost-editor-foot > span.error {
  color: #b91c1c;
}

.oms-analytics-product-cost-editor-foot > span.success {
  color: #15803d;
}

.oms-analytics-product-cost-editor-foot > div {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
}

@media (max-width: 760px) {
  .oms-analytics-product-cost-editor-head,
  .oms-analytics-product-cost-editor-foot {
    align-items: stretch;
  }

  .oms-analytics-product-cost-editor-foot,
  .oms-analytics-product-cost-editor-row {
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .oms-analytics-product-cost-editor-row {
    gap: 10px;
  }

  .oms-analytics-product-cost-editor-foot > div {
    justify-content: flex-end;
  }
}

.oms-analytics-drilldown-table tr.warn td {
  background: rgba(251, 191, 36, 0.10);
}

.oms-analytics-drilldown-table td.pos {
  color: #16a34a;
}

.oms-analytics-drilldown-table td.neg {
  color: #dc2626;
}

.oms-analytics-drilldown-loading,
.oms-analytics-drilldown-error {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px dashed var(--soft-border);
  border-radius: 14px;
  background: var(--panel-muted-bg);
  padding: 16px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 800;
}

.oms-analytics-drilldown-loading span {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(37, 99, 235, 0.18);
  border-top-color: #2563eb;
  border-radius: 999px;
  animation: oms-spin 0.8s linear infinite;
}

.oms-analytics-drilldown-error {
  border-color: rgba(220, 38, 38, 0.25);
  background: rgba(254, 242, 242, 0.9);
  color: #991b1b;
}

.oms-p2-chart-panel,
.oms-p2-month-panel,
.oms-p2-allegro-panel,
.oms-p2-ads-panel,
.oms-p2-proof-panel,
.oms-p2-data-quality-panel,
.oms-p2-alerts,
.oms-p2-legacy .oms-profiter-admin-panel {
  margin-bottom: 32px;
  padding: 24px;
}

.oms-profiter-drilldown-panel[hidden],
.oms-p2-proof-panel[hidden],
.oms-p2-allegro-panel[hidden],
.oms-p2-ads-panel[hidden],
.oms-p2-data-quality-panel[hidden] {
  display: none !important;
}

.oms-profiter-focus-pulse {
  animation: oms-profiter-focus-pulse 1.25s ease;
}

@keyframes oms-profiter-focus-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.30), var(--shadow-soft, 0 10px 30px rgba(15, 23, 42, 0.08));
  }
  100% {
    box-shadow: 0 0 0 16px rgba(37, 99, 235, 0), var(--shadow-soft, 0 10px 30px rgba(15, 23, 42, 0.08));
  }
}

.oms-p2-panel-head p {
  margin: 5px 0 0;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
}

.oms-p2-proof-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.oms-p2-proof-metric {
  min-width: 0;
  border: 1px solid var(--soft-border);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(248, 250, 252, 0.94));
  padding: 13px 14px;
}

.oms-p2-proof-metric span {
  display: block;
  overflow: hidden;
  color: var(--text-secondary);
  font-size: 10.5px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.oms-p2-proof-metric strong {
  display: block;
  margin-top: 6px;
  color: var(--text-primary);
  font-size: 18px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.oms-p2-proof-metric.cost strong {
  color: #475569;
}

.oms-p2-proof-metric.positive strong {
  color: #16a34a;
}

.oms-p2-proof-metric.negative strong {
  color: #dc2626;
}

.oms-p2-proof-table {
  max-height: 520px;
}

.oms-p2-proof-table th:first-child,
.oms-p2-proof-table td:first-child {
  text-align: left;
}

.oms-p2-ok-text {
  display: inline-flex;
  min-height: 22px;
  align-items: center;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.12);
  padding: 0 8px;
  color: #15803d;
  font-size: 10px;
  font-weight: 900;
}

.oms-p2-data-quality-panel {
  border-color: rgba(148, 163, 184, 0.22);
}

.oms-p2-data-quality-panel.quality-ok {
  border-color: rgba(34, 197, 94, 0.20);
}

.oms-p2-data-quality-panel.quality-warning {
  border-color: rgba(245, 158, 11, 0.24);
}

.oms-p2-data-quality-panel.quality-danger {
  border-color: rgba(239, 68, 68, 0.26);
}

.oms-p2-data-quality-list {
  display: grid;
  gap: 8px;
}

.oms-p2-data-quality-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--soft-border);
  border-radius: 14px;
  background: var(--panel-muted-bg);
  padding: 12px 14px;
}

.oms-p2-data-quality-item strong,
.oms-p2-data-quality-item span,
.oms-p2-data-quality-item em {
  display: block;
}

.oms-p2-data-quality-item strong {
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 900;
}

.oms-p2-data-quality-item span {
  margin-top: 2px;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.oms-p2-data-quality-item em {
  margin-top: 4px;
  color: #64748b;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.oms-p2-data-quality-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.oms-p2-data-quality-item button {
  min-height: 32px;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  background: #fff;
  color: var(--accent-blue);
  padding: 0 11px;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.oms-p2-data-quality-item button.primary {
  border-color: rgba(37, 99, 235, 0.26);
  background: rgba(37, 99, 235, 0.10);
  color: #1d4ed8;
}

.oms-p2-data-quality-item button.allegro {
  border-color: rgba(255, 90, 0, 0.30);
  background: rgba(255, 90, 0, 0.10);
  color: #c2410c;
}

.oms-p2-data-quality-item button.allegro:hover {
  border-color: rgba(255, 90, 0, 0.48);
  background: rgba(255, 90, 0, 0.16);
}

.oms-p2-data-quality-item.ok {
  border-color: rgba(34, 197, 94, 0.20);
  background: rgba(34, 197, 94, 0.08);
}

.oms-p2-data-quality-item.warning {
  border-color: rgba(245, 158, 11, 0.25);
  background: rgba(245, 158, 11, 0.10);
}

.oms-p2-data-quality-item.danger {
  border-color: rgba(239, 68, 68, 0.25);
  background: rgba(239, 68, 68, 0.09);
}

.oms-p2-data-quality-item.muted {
  border-style: dashed;
}

.oms-p2-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.oms-p2-panel-head h2 {
  margin: 0;
  color: var(--text-primary);
  font-size: 24px;
  font-weight: 850;
  letter-spacing: -0.02em;
}

.oms-p2-chart-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}

.oms-p2-month-select {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 750;
}

.oms-p2-month-select select {
  min-width: 160px;
  min-height: 36px;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 10px 24px -18px rgba(16, 24, 40, 0.40);
  color: var(--text-primary);
  padding: 0 12px;
  font: inherit;
  cursor: pointer;
}

.oms-p2-chart-switcher {
  display: flex;
  justify-content: center;
  margin: 8px 0 12px;
}

.oms-p2-chart-switcher::before {
  display: none;
}

.oms-p2-chart-switcher button {
  min-height: 30px;
  border: 0 !important;
  border-radius: 8px;
  background: transparent !important;
  box-shadow: none !important;
  padding: 0 12px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.oms-p2-chart-switcher button:hover,
.oms-p2-chart-switcher button.active {
  background: rgba(0, 191, 255, 0.1) !important;
  color: var(--accent-blue);
  box-shadow: 0 2px 8px rgba(0, 191, 255, 0.20);
}

.oms-p2-chart-stage {
  min-height: 322px;
  overflow: visible;
  border-radius: 8px;
  background: var(--panel-muted-bg);
  padding: 24px 18px 38px;
}

.oms-p2-legacy .oms-profiter-trend-chart {
  height: 250px;
  border-bottom: 1px solid var(--soft-border);
}

.oms-p2-legacy .oms-profiter-bar {
  max-width: 30px;
  border-radius: 7px 7px 3px 3px;
  background: rgba(100, 116, 139, 0.22);
}

.oms-p2-legacy .oms-profiter-bar-col.positive .oms-profiter-bar {
  background: linear-gradient(180deg, #00ff7f, #10b981);
  box-shadow: 0 0 14px rgba(0, 255, 127, 0.16);
}

.oms-p2-legacy .oms-profiter-bar-col.negative .oms-profiter-bar {
  background: linear-gradient(180deg, #ff6b6b, #ef4444);
}

.oms-p2-legacy .oms-profiter-bar-col.selected .oms-profiter-bar {
  box-shadow: 0 0 0 2px var(--bg-secondary) inset, 0 0 0 4px rgba(37, 99, 235, 0.30);
}

.oms-p2-legacy .oms-profiter-bar-col span,
.oms-p2-legacy .oms-bar-label,
.oms-p2-legacy .oms-line-labels {
  color: var(--text-secondary);
}

.oms-p2-legacy .oms-profiter-bar-col.selected span {
  color: var(--accent-blue);
}

.oms-p2-legacy .oms-chart-bars {
  min-height: 250px;
  border-bottom-color: var(--soft-border);
}

.oms-p2-legacy .oms-bar {
  background: linear-gradient(180deg, #00ff7f, #10b981);
}

.oms-p2-legacy .oms-bar.negative {
  background: linear-gradient(180deg, #ff6b6b, #ef4444);
}

.oms-p2-legacy .oms-profit-line-path {
  stroke: var(--accent-blue);
}

.oms-p2-legacy .oms-profit-line-point {
  fill: var(--accent-blue);
  stroke: var(--bg-primary);
}

.oms-p2-legacy .oms-profit-zero-line {
  stroke: rgba(100, 116, 139, 0.34);
}

.oms-p2-period-summary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-top: 16px;
  border-top: 1px solid var(--soft-border);
  padding-top: 12px;
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 650;
}

.oms-p2-period-summary span {
  margin-right: 6px;
  color: var(--text-secondary);
  font-weight: 700;
}

.oms-p2-period-summary strong,
.oms-p2-trend-today {
  color: var(--text-primary);
  font-weight: 850;
}

.oms-p2-trend-today {
  margin-top: 8px;
  text-align: center;
  color: var(--accent-blue);
  font-size: 12px;
}

.oms-p2-month-panel {
  border-color: rgba(59, 130, 246, 0.2);
  box-shadow: 0 16px 44px rgba(59, 130, 246, 0.08);
}

.oms-p2-month-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.oms-p2-month-icon {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.20), rgba(168, 85, 247, 0.20));
  font-size: 24px;
}

.oms-p2-month-head h2 {
  margin: 0;
  color: var(--text-primary);
  font-size: 24px;
  font-weight: 850;
}

.oms-p2-month-head p {
  margin: 4px 0 0;
  color: var(--accent-blue);
  font-size: 13px;
  font-weight: 650;
}

.oms-p2-month-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 24px;
}

.oms-p2-month-card {
  position: relative;
  min-height: 146px;
  overflow: hidden;
  border-radius: 16px;
  padding: 22px;
  text-align: left;
  cursor: pointer;
}

.oms-p2-month-card span {
  display: block;
  color: currentColor;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.oms-p2-month-card strong {
  display: block;
  margin-top: 20px;
  overflow-wrap: anywhere;
  color: currentColor;
  font-size: clamp(22px, 1.9vw, 32px);
  font-weight: 900;
  line-height: 1;
}

.oms-p2-month-card em {
  display: block;
  margin-top: 10px;
  color: currentColor;
  font-size: 13px;
  font-style: normal;
  font-weight: 650;
  opacity: 0.7;
}

.oms-p2-month-card.revenue {
  border: 1px solid rgba(16, 185, 129, 0.30);
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.10), rgba(5, 150, 105, 0.20));
  color: #34d399;
}

.oms-p2-month-card.income {
  border: 1px solid rgba(59, 130, 246, 0.30);
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.10), rgba(37, 99, 235, 0.20));
  color: #60a5fa;
}

.oms-p2-month-card.fixed {
  border: 1px solid rgba(249, 115, 22, 0.30);
  background: linear-gradient(135deg, rgba(249, 115, 22, 0.10), rgba(234, 88, 12, 0.20));
  color: #fb923c;
}

.oms-p2-month-card.variable {
  border: 1px solid rgba(234, 179, 8, 0.30);
  background: linear-gradient(135deg, rgba(234, 179, 8, 0.10), rgba(202, 138, 4, 0.20));
  color: #facc15;
}

.oms-p2-month-card.net {
  border: 1px solid rgba(139, 92, 246, 0.30);
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.10), rgba(124, 58, 237, 0.20));
  color: #a78bfa;
}

.oms-p2-allegro-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  margin-bottom: 20px;
}

.oms-p2-chip {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  border-radius: 999px;
  background: rgba(22, 163, 74, 0.14);
  padding: 0 12px;
  color: #86efac;
  font-size: 12px;
  font-weight: 800;
}

.oms-p2-allegro-stat {
  border-radius: 14px;
  padding: 18px;
}

.oms-p2-allegro-stat p {
  margin: 0 0 8px;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}

.oms-p2-allegro-stat strong {
  display: block;
  color: currentColor;
  font-size: 24px;
  font-weight: 900;
}

.oms-p2-allegro-stat.green {
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  color: #16a34a;
}

.oms-p2-allegro-stat.blue {
  background: linear-gradient(135deg, #eff6ff, #e0e7ff);
  color: #2563eb;
}

.oms-p2-allegro-stat.purple {
  background: linear-gradient(135deg, #faf5ff, #ede9fe);
  color: #7c3aed;
}

.oms-p2-allegro-stat.orange {
  background: linear-gradient(135deg, #fff7ed, #fee2e2);
  color: #ea580c;
}

.oms-p2-allegro-table {
  max-height: 420px;
  overflow: auto;
}

.oms-p2-legacy .oms-analytics-table table {
  color: var(--text-primary);
}

.oms-p2-legacy .oms-analytics-table th,
.oms-p2-legacy .oms-analytics-table td {
  border-color: var(--soft-border);
}

.oms-p2-legacy .oms-analytics-table th {
  color: var(--text-secondary);
}

.oms-p2-ads-panel {
  max-width: 760px;
}

.oms-p2-legacy .oms-profiter-card-title {
  color: var(--text-primary);
}

.oms-p2-legacy .oms-profiter-card-title small {
  color: var(--text-secondary);
}

.oms-p2-legacy .oms-profiter-ad-top {
  color: var(--text-primary);
}

.oms-p2-legacy .oms-profiter-ad-top span,
.oms-p2-legacy .oms-empty-inline {
  color: var(--text-secondary);
}

.oms-p2-legacy .oms-profiter-ad-bar {
  background: rgba(100, 116, 139, 0.16);
}

.oms-p2-legacy .oms-profiter-pill {
  border-color: var(--soft-border);
  background: var(--panel-muted-bg);
  color: var(--text-secondary);
}

.oms-p2-legacy .oms-profiter-pill.warning {
  border-color: rgba(245, 158, 11, 0.32);
  background: rgba(245, 158, 11, 0.10);
  color: #fbbf24;
}

.oms-p2-legacy .oms-profiter-pill.danger {
  border-color: rgba(248, 113, 113, 0.32);
  background: rgba(248, 113, 113, 0.10);
  color: #fca5a5;
}

.oms-p2-legacy .oms-profiter-pill.ok {
  border-color: rgba(52, 211, 153, 0.28);
  background: rgba(52, 211, 153, 0.10);
  color: #86efac;
}

.oms-p2-legacy .oms-profiter-admin-panel {
  overflow: hidden;
}

.oms-p2-legacy .oms-profiter-admin-panel summary {
  color: var(--text-primary);
}

.oms-p2-legacy .oms-profiter-admin-panel summary small,
.oms-p2-legacy .oms-section-subtitle,
.oms-p2-legacy .oms-empty-inline {
  color: var(--text-secondary);
}

.oms-p2-legacy .oms-analytics-table-card {
  border-color: var(--soft-border);
  background: rgba(255, 255, 255, 0.72);
}

.oms-p2-legacy .oms-section-title {
  color: var(--text-primary);
}

.oms-p2-legacy .oms-analytics-cost-form input,
.oms-p2-legacy .oms-analytics-cost-form select,
.oms-p2-legacy .oms-analytics-product-cost-form input,
.oms-p2-legacy .oms-analytics-product-cost-form select,
.oms-p2-legacy .oms-analytics-manual-form input,
.oms-p2-legacy .oms-analytics-manual-form select {
  border-color: var(--border-color);
  background: #ffffff;
  color: var(--text-primary);
}

.oms-p2-legacy .oms-btn-primary.compact,
.oms-p2-legacy .oms-btn-light.compact,
.oms-p2-legacy .oms-table-icon-btn {
  border-color: var(--border-color);
}

.oms-p2-legacy .oms-analytics-status {
  margin: 0 0 18px;
  border-color: rgba(0, 191, 255, 0.26);
  background: rgba(0, 191, 255, 0.10);
  color: var(--text-primary);
}

.oms-p2-legacy .oms-analytics-status.error {
  border-color: rgba(255, 77, 77, 0.32);
  background: rgba(255, 77, 77, 0.10);
  color: #fca5a5;
}

html[data-flow-oms-theme="dark"] body {
  background: #0d1320;
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] {
  background: #0d1320;
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-main,
.oms-app[data-theme="dark"] .oms-workspace,
.oms-app[data-theme="dark"] .oms-orders-area,
.oms-app[data-theme="dark"] .oms-table-container {
  background: #0d1320;
}

.oms-app[data-theme="dark"] .oms-topbar,
.oms-app[data-theme="dark"] .oms-orders-header,
.oms-app[data-theme="dark"] .oms-toolbar {
  border-color: rgba(148, 163, 184, 0.18);
  background: #111827;
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-quick-access,
.oms-app[data-theme="dark"] .oms-icon-btn,
.oms-app[data-theme="dark"] .oms-user-meta strong,
.oms-app[data-theme="dark"] .oms-orders-title,
.oms-app[data-theme="dark"] .oms-customer-name,
.oms-app[data-theme="dark"] .oms-product-text strong,
.oms-app[data-theme="dark"] .oms-amount,
.oms-app[data-theme="dark"] .oms-date-main {
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-user-meta small,
.oms-app[data-theme="dark"] .oms-orders-subtitle,
.oms-app[data-theme="dark"] .oms-order-sub,
.oms-app[data-theme="dark"] .oms-product-text,
.oms-app[data-theme="dark"] .oms-date-sub,
.oms-app[data-theme="dark"] .oms-pagination-info,
.oms-app[data-theme="dark"] .oms-filter-section-title {
  color: #94a3b8;
}

.oms-app[data-theme="dark"] .oms-search input,
.oms-app[data-theme="dark"] .oms-toolbar-select,
.oms-app[data-theme="dark"] .oms-toolbar-select select,
.oms-app[data-theme="dark"] .oms-toolbar-clear,
.oms-app[data-theme="dark"] .oms-tool-btn,
.oms-app[data-theme="dark"] .oms-page-btn,
.oms-app[data-theme="dark"] .oms-sound-toggle,
.oms-app[data-theme="dark"] .oms-sound-volume,
.oms-app[data-theme="dark"] .oms-current-link {
  border-color: rgba(148, 163, 184, 0.22);
  background: #1e293b;
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-sound-toggle.active {
  border-color: rgba(34, 197, 94, 0.32);
  background: rgba(34, 197, 94, 0.14);
  color: #86efac;
}

.oms-app[data-theme="dark"] .oms-sound-volume::after {
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-search input::placeholder,
.oms-app[data-theme="dark"] .oms-search svg {
  color: #94a3b8;
}

.oms-app[data-theme="dark"] .oms-search-results {
  border-color: rgba(148, 163, 184, 0.28);
  background: #0f172a;
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.42);
}

.oms-app[data-theme="dark"] .oms-search-results-head,
.oms-app[data-theme="dark"] .oms-search-result-main em,
.oms-app[data-theme="dark"] .oms-search-result-side em {
  color: #94a3b8;
}

.oms-app[data-theme="dark"] .oms-search-results-head strong,
.oms-app[data-theme="dark"] .oms-search-result-main strong,
.oms-app[data-theme="dark"] .oms-search-result-side strong {
  color: #e5e7eb;
}

.oms-app[data-theme="dark"] .oms-search-results-status,
.oms-app[data-theme="dark"] .oms-search-results-empty {
  background: rgba(30, 41, 59, 0.86);
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-search-result:hover,
.oms-app[data-theme="dark"] .oms-search-result:focus {
  border-color: rgba(96, 165, 250, 0.6);
  background: rgba(30, 64, 175, 0.24);
}

.oms-app[data-theme="dark"] .oms-filters-panel {
  border-right-color: rgba(56, 189, 248, 0.48);
  background: #111827;
  color: #cbd5e1;
  box-shadow: inset -1px 0 0 rgba(148, 163, 184, 0.14);
}

.oms-app[data-theme="dark"] .oms-filter-item,
.oms-app[data-theme="dark"] .oms-filter-subitem {
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-filter-item:hover,
.oms-app[data-theme="dark"] .oms-filter-subitem:hover,
.oms-app[data-theme="dark"] .oms-filter-item.active,
.oms-app[data-theme="dark"] .oms-filter-subitem.active {
  background: rgba(59, 130, 246, 0.16);
  color: #f8fafc;
}

.oms-app[data-theme="dark"] .oms-count {
  border-color: rgba(148, 163, 184, 0.22);
  background: #0f172a;
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-table {
  border-color: rgba(148, 163, 184, 0.18);
}

.oms-app[data-theme="dark"] .oms-table th {
  border-bottom-color: rgba(148, 163, 184, 0.22);
  background: #182235;
  color: #94a3b8;
}

.oms-app[data-theme="dark"] .oms-table td {
  border-bottom-color: rgba(148, 163, 184, 0.16);
  background: #0f172a;
}

.oms-app[data-theme="dark"] .oms-table tbody tr:nth-child(even) td {
  background: #111c2f;
}

.oms-app[data-theme="dark"] .oms-table tr:hover td {
  background: #172554;
}

.oms-app[data-theme="dark"] .oms-table tbody tr.oms-row-unpaid td,
.oms-app[data-theme="dark"] .oms-table tbody tr.oms-row-unpaid:nth-child(even) td {
  background: #33151a;
}

.oms-app[data-theme="dark"] .oms-table tbody tr.oms-row-packed-recheck td,
.oms-app[data-theme="dark"] .oms-table tbody tr.oms-row-packed-recheck:nth-child(even) td {
  background: #2f2113;
}

.oms-app[data-theme="dark"] .oms-detail-view,
.oms-app[data-theme="dark"] .oms-products-view,
.oms-app[data-theme="dark"] .oms-invoices-view,
.oms-app[data-theme="dark"] .oms-dashboard-view,
.oms-app[data-theme="dark"] .oms-integrations-view,
.oms-app[data-theme="dark"] .oms-control-view,
.oms-app[data-theme="dark"] .oms-controls-view,
.oms-app[data-theme="dark"] .oms-card,
.oms-app[data-theme="dark"] .oms-dashboard-card,
.oms-app[data-theme="dark"] .oms-operations-card,
.oms-app[data-theme="dark"] .oms-operations-loading,
.oms-app[data-theme="dark"] .oms-operations-review,
.oms-app[data-theme="dark"] .oms-control-card,
.oms-app[data-theme="dark"] .oms-detail-card,
.oms-app[data-theme="dark"] .oms-modal,
.oms-app[data-theme="dark"] .oms-empty-state,
.oms-app[data-theme="dark"] .oms-error-state {
  border-color: rgba(148, 163, 184, 0.18);
  background: #111827;
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-operations-dashboard {
  border-color: rgba(148, 163, 184, 0.18);
}

.oms-app[data-theme="dark"] .oms-operations-header h2,
.oms-app[data-theme="dark"] .oms-operations-card h3,
.oms-app[data-theme="dark"] .oms-operations-card dd {
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-operations-header p,
.oms-app[data-theme="dark"] .oms-operations-card > p,
.oms-app[data-theme="dark"] .oms-operations-card dt {
  color: #9ca9b8;
}

.oms-app[data-theme="dark"] .oms-operations-review-list,
.oms-app[data-theme="dark"] .oms-operations-review-row {
  border-color: rgba(148, 163, 184, 0.18);
}

.oms-app[data-theme="dark"] .oms-operations-review-row strong,
.oms-app[data-theme="dark"] .oms-operations-review-row dd {
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-operations-review-row span,
.oms-app[data-theme="dark"] .oms-operations-review-row dt {
  color: #9ca9b8;
}

.oms-app[data-theme="dark"] .oms-admin-user-row {
  border-color: rgba(148, 163, 184, 0.18);
  background: #0f172a;
}

.oms-app[data-theme="dark"] .oms-admin-user-main strong {
  color: #f8fafc;
}

.oms-app[data-theme="dark"] .oms-admin-user-main small,
.oms-app[data-theme="dark"] .oms-admin-user-last,
.oms-app[data-theme="dark"] .oms-admin-user-count {
  color: #94a3b8;
}

.oms-app[data-theme="dark"] .oms-admin-user-role {
  border-color: rgba(96, 165, 250, 0.34);
  background: rgba(37, 99, 235, 0.16);
  color: #bfdbfe;
}

.oms-app[data-theme="dark"] .oms-permission-role-summary span,
.oms-app[data-theme="dark"] .oms-permission-matrix-table-wrap {
  border-color: rgba(148, 163, 184, 0.18);
}

.oms-app[data-theme="dark"] .oms-permission-role-summary span,
.oms-app[data-theme="dark"] .oms-permission-matrix-table,
.oms-app[data-theme="dark"] .oms-permission-matrix-table th {
  background: #0f172a;
}

.oms-app[data-theme="dark"] .oms-permission-matrix-table th,
.oms-app[data-theme="dark"] .oms-permission-matrix-table td {
  border-bottom-color: rgba(148, 163, 184, 0.18);
}

.oms-app[data-theme="dark"] .oms-permission-module-cell strong {
  color: #f8fafc;
}

.oms-app[data-theme="dark"] .oms-permission-module-cell small,
.oms-app[data-theme="dark"] .oms-permission-role-summary span,
.oms-app[data-theme="dark"] .oms-permission-matrix-table th small {
  color: #94a3b8;
}

.oms-app[data-theme="dark"] .oms-permission-pill.denied {
  background: rgba(148, 163, 184, 0.12);
  color: #94a3b8;
}

.oms-app[data-theme="dark"] .oms-user-activity-summary code,
.oms-app[data-theme="dark"] .oms-user-activity-row {
  border-color: rgba(148, 163, 184, 0.18);
  background: #0f172a;
}

.oms-app[data-theme="dark"] .oms-user-activity-main strong {
  color: #f8fafc;
}

.oms-app[data-theme="dark"] .oms-user-activity-main small,
.oms-app[data-theme="dark"] .oms-user-activity-meta,
.oms-app[data-theme="dark"] .oms-user-activity-meta small,
.oms-app[data-theme="dark"] .oms-user-activity-target,
.oms-app[data-theme="dark"] .oms-user-activity-summary code {
  color: #94a3b8;
}

.oms-app[data-theme="dark"] .oms-user-activity-source {
  border-color: rgba(96, 165, 250, 0.34);
  background: rgba(37, 99, 235, 0.16);
  color: #bfdbfe;
}

.oms-app[data-theme="dark"] .oms-profile-menu,
.oms-app[data-theme="dark"] .oms-profile-menu header,
.oms-app[data-theme="dark"] .oms-profile-sessions,
.oms-app[data-theme="dark"] .oms-profile-session-row,
.oms-app[data-theme="dark"] .oms-profile-session-row button,
.oms-app[data-theme="dark"] .oms-profile-revoke-others,
.oms-app[data-theme="dark"] .oms-profile-menu button[role="menuitem"] {
  border-color: rgba(148, 163, 184, 0.18);
  background: #0f172a;
}

.oms-app[data-theme="dark"] .oms-profile-session-row.current {
  border-color: rgba(96, 165, 250, 0.34);
  background: rgba(37, 99, 235, 0.14);
}

.oms-app[data-theme="dark"] .oms-profile-menu header strong,
.oms-app[data-theme="dark"] .oms-profile-menu-grid strong,
.oms-app[data-theme="dark"] .oms-profile-sessions-head strong,
.oms-app[data-theme="dark"] .oms-profile-session-row strong {
  color: #f8fafc;
}

.oms-app[data-theme="dark"] .oms-profile-menu header small,
.oms-app[data-theme="dark"] .oms-profile-menu-grid span,
.oms-app[data-theme="dark"] .oms-profile-sessions-head span,
.oms-app[data-theme="dark"] .oms-profile-current-session,
.oms-app[data-theme="dark"] .oms-profile-sessions-empty,
.oms-app[data-theme="dark"] .oms-profile-session-row small,
.oms-app[data-theme="dark"] .oms-profile-session-row button,
.oms-app[data-theme="dark"] .oms-profile-revoke-others,
.oms-app[data-theme="dark"] .oms-profile-menu button[role="menuitem"] {
  color: #94a3b8;
}

.oms-app[data-theme="dark"] input,
.oms-app[data-theme="dark"] select,
.oms-app[data-theme="dark"] textarea {
  color-scheme: dark;
}

.oms-app[data-theme="dark"] .oms-p2-legacy {
  --bg-primary: #0d0d1a;
  --bg-secondary: #161625;
  --bg-tertiary: #202030;
  --text-primary: #e0e0ff;
  --text-secondary: #a0a0c0;
  --accent-blue: #00bfff;
  --accent-pink: #ff00ff;
  --accent-green: #00ff7f;
  --accent-red: #ff4d4d;
  --border-color: rgba(255, 255, 255, 0.1);
  --pane-bg: rgba(22, 22, 37, 0.6);
  --panel-bg: #161625;
  --panel-muted-bg: #202030;
  --soft-border: rgba(255, 255, 255, 0.10);
  --soft-hover: rgba(255, 255, 255, 0.08);
}

.oms-app[data-theme="dark"] .oms-p2-legacy .glass-pane {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.37);
}

.oms-app[data-theme="dark"] .oms-p2-legacy .btn-secondary {
  background: rgba(255, 255, 255, 0.10);
}

.oms-app[data-theme="dark"] .oms-p2-month-select select {
  border-color: rgba(100, 116, 139, 0.3);
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
  color: #ffffff;
}

.oms-app[data-theme="dark"] .oms-p2-date-field input {
  color-scheme: dark;
}

.oms-app[data-theme="dark"] .oms-p2-legacy .oms-analytics-cost-form input,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-analytics-cost-form select,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-analytics-product-cost-form input,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-analytics-product-cost-form select,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-analytics-manual-form input,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-analytics-manual-form select {
  background: rgba(0, 0, 0, 0.20);
}

@media (max-width: 1320px) {
  .oms-p2-stats-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .oms-p2-profit-card,
  .oms-p2-store-results {
    grid-column: span 3;
  }

  .oms-p2-month-grid,
  .oms-p2-allegro-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .oms-p2-shell {
    padding: 18px 16px 42px;
  }

  .oms-p2-topbar,
  .oms-p2-panel-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .oms-p2-actions,
  .oms-p2-chart-tools {
    width: 100%;
    justify-content: flex-start;
  }

  .oms-p2-stats-grid,
  .oms-p2-store-grid,
  .oms-p2-month-grid,
  .oms-p2-allegro-stats {
    grid-template-columns: 1fr;
  }

  .oms-p2-profit-card,
  .oms-p2-store-results {
    grid-column: auto;
  }

  .oms-p2-period-summary {
    flex-direction: column;
    gap: 8px;
  }
}

/* Stage795 mobile baseline: phone-sized screens keep the app shell stable. */
@media (max-width: 760px) {
  html,
  body {
    overflow-x: hidden;
  }

  .oms-app {
    min-width: 0;
    width: 100vw;
  }

  .oms-sidebar,
  .oms-sidebar:hover,
  .oms-sidebar:focus-within,
  .oms-app[data-ui-mode="premium"] .oms-sidebar,
  .oms-app[data-ui-mode="premium"] .oms-sidebar:hover,
  .oms-app[data-ui-mode="premium"] .oms-sidebar:focus-within {
    flex: 0 0 64px;
    width: 64px;
    min-width: 64px;
  }

  .oms-sidebar:hover .oms-sidebar-top,
  .oms-sidebar:focus-within .oms-sidebar-top {
    justify-content: center;
    padding-right: 8px;
    padding-left: 8px;
  }

  .oms-main,
  .oms-workspace,
  .oms-orders-area {
    min-width: 0;
  }

  .oms-topbar,
  .oms-app[data-ui-mode="premium"] .oms-topbar {
    height: auto;
    min-height: 56px;
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 10px;
  }

  .oms-quick-access {
    min-width: 0;
  }

  .oms-search,
  .oms-app[data-ui-mode="premium"] .oms-search {
    order: 3;
    flex: 0 0 100%;
    width: 100%;
    min-width: 100%;
    max-width: none;
  }

  .oms-current-link {
    display: none;
  }

  .oms-sound-toggle {
    width: 34px;
    justify-content: center;
    padding: 0;
  }

  .oms-sound-toggle span {
    display: none;
  }

  .oms-sound-volume {
    display: none;
  }

  .oms-top-actions {
    gap: 6px;
    margin-left: auto;
  }

  .oms-toolbar,
  .oms-app[data-ui-mode="premium"] .oms-toolbar,
  .oms-orders-header,
  .oms-app[data-ui-mode="premium"] .oms-orders-header {
    flex-wrap: wrap;
    align-items: stretch;
    gap: 8px;
    padding-right: 10px;
    padding-left: 10px;
  }

  .oms-toolbar-select,
  .oms-toolbar-clear,
  .oms-tool-btn,
  .oms-page-btn,
  .oms-btn-pack {
    min-width: 0;
  }

  .oms-table-container,
  .oms-app[data-ui-mode="premium"] .oms-table-container {
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .oms-table {
    min-width: 960px;
  }

  .oms-confirm-backdrop {
    align-items: end;
    padding: 10px;
  }

  .oms-confirm-shell {
    width: min(100%, 520px);
    border-radius: 16px;
  }

  .oms-warehouse-delivery-modal-shell {
    inset: 8px;
    max-width: calc(100vw - 16px);
    border-radius: 14px;
  }

  .oms-warehouse-delivery-modal-shell > header,
  .oms-warehouse-delivery-modal-shell > footer {
    padding: 12px;
  }

  .oms-warehouse-delivery-modal-shell > footer .oms-control-actions {
    width: 100%;
    justify-content: stretch;
  }

  .oms-warehouse-delivery-modal-shell > footer .oms-control-actions > * {
    flex: 1 1 auto;
  }

  .oms-warehouse-product-modal-head,
  .oms-warehouse-product-modal .oms-warehouse-product-detail-tabs,
  .oms-warehouse-product-modal .oms-warehouse-product-detail-panel,
  .oms-warehouse-product-modal-footer {
    padding-right: 14px;
    padding-left: 14px;
  }
}

/* Mobile polish: phone layout should be one column, not a squeezed desktop shell. */
@media (max-width: 760px) {
  html,
  body {
    width: 100%;
    height: 100%;
    overflow: hidden;
  }

  .oms-app {
    width: 100%;
    height: 100dvh;
    padding-bottom: calc(58px + env(safe-area-inset-bottom));
    flex-direction: column;
    background: var(--oms-slate-50);
    overflow: hidden;
  }

  .oms-sidebar,
  .oms-sidebar:hover,
  .oms-sidebar:focus-within,
  .oms-app[data-ui-mode="premium"] .oms-sidebar,
  .oms-app[data-ui-mode="premium"] .oms-sidebar:hover,
  .oms-app[data-ui-mode="premium"] .oms-sidebar:focus-within {
    position: fixed;
    z-index: 2200;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    min-width: 0;
    height: calc(58px + env(safe-area-inset-bottom));
    min-height: 58px;
    flex: 0 0 auto;
    flex-direction: row;
    border-top: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow: 0 -16px 34px rgba(15, 23, 42, 0.16);
  }

  .oms-sidebar-top,
  .oms-sidebar-sources,
  .oms-sidebar-sources-summary,
  .oms-sidebar-sync-all,
  .oms-nav-section,
  .oms-nav-subitem,
  .oms-preview-badge {
    display: none !important;
  }

  .oms-sidebar-nav {
    width: 100%;
    flex: 1;
    flex-direction: row;
    align-items: center;
    justify-content: space-around;
    gap: 4px;
    padding: 6px 10px calc(6px + env(safe-area-inset-bottom));
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
  }

  .oms-nav-item,
  .oms-sidebar:not(:hover):not(:focus-within) .oms-nav-item {
    width: 44px;
    min-width: 44px;
    height: 44px;
    justify-content: center;
    padding: 0;
    border-radius: 13px;
  }

  .oms-nav-item svg {
    width: 21px;
    height: 21px;
    margin: 0;
  }

  .oms-nav-label {
    display: none !important;
  }

  .oms-main,
  .oms-app[data-ui-mode="premium"] .oms-main {
    width: 100%;
    min-width: 0;
    height: calc(100dvh - 58px - env(safe-area-inset-bottom));
    flex: 1 1 auto;
    overflow: hidden;
  }

  .oms-topbar,
  .oms-app[data-ui-mode="premium"] .oms-topbar {
    position: relative;
    z-index: 60;
    border-bottom-color: rgba(148, 163, 184, 0.18);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
  }

  .oms-quick-access {
    max-width: calc(100vw - 190px);
    overflow: hidden;
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .oms-quick-access svg {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
  }

  .oms-search input {
    height: 38px;
    border-color: rgba(148, 163, 184, 0.26);
    background: #f8fafc;
    font-size: 13px;
  }

  .oms-search-results {
    max-height: calc(100dvh - 148px);
  }

  .oms-search-result {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .oms-search-result-side {
    align-items: flex-start;
    text-align: left;
  }

  .oms-sound-volume:not([hidden]) {
    position: fixed;
    z-index: 2400;
    top: 104px;
    right: 10px;
    display: inline-flex !important;
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.16);
  }

  .oms-workspace {
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }

  .oms-filters-panel,
  .oms-app[data-ui-mode="premium"] .oms-filters-panel {
    width: 100%;
    min-width: 0;
    max-height: 42dvh;
    flex: 0 0 auto;
    border-right: 0;
    border-bottom: 1px solid var(--oms-slate-200);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
    overflow: hidden;
  }

  .oms-filters-header {
    padding: 10px;
    background: white;
  }

  .oms-filter-group {
    max-height: calc(42dvh - 56px);
    padding: 4px 10px 10px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .oms-filter-section {
    margin-top: 8px;
  }

  .oms-filter-section-title {
    padding: 7px 4px 5px;
    font-size: 11px;
  }

  .oms-filter-item,
  .oms-filter-subitem {
    min-height: 32px;
    border-radius: 8px;
    font-size: 12px;
  }

  .oms-filter-subitem {
    padding-left: 14px;
  }

  .oms-orders-area,
  .oms-app[data-ui-mode="premium"] .oms-orders-area {
    width: 100%;
    min-width: 0;
    min-height: 54dvh;
    flex: 1 0 auto;
  }

  .oms-orders-header,
  .oms-app[data-ui-mode="premium"] .oms-orders-header {
    min-height: auto;
    flex-direction: column;
    align-items: stretch;
    padding: 10px;
  }

  .oms-orders-title {
    font-size: 17px;
    line-height: 1.15;
  }

  .oms-orders-subtitle {
    display: none;
  }

  .oms-header-actions {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
    justify-content: flex-start;
    -webkit-overflow-scrolling: touch;
  }

  .oms-header-actions > * {
    flex: 0 0 auto;
  }

  .oms-table-container,
  .oms-app[data-ui-mode="premium"] .oms-table-container {
    width: 100%;
    max-width: 100%;
    min-height: 360px;
    border-top: 1px solid var(--oms-slate-200);
  }

  .oms-table,
  .oms-table-resizable {
    min-width: 880px;
  }

  .oms-table th,
  .oms-table td,
  .oms-app[data-ui-mode="premium"] .oms-table th,
  .oms-app[data-ui-mode="premium"] .oms-table td {
    padding-right: 8px;
    padding-left: 8px;
  }

  .oms-toast-stack {
    right: 10px;
    bottom: calc(72px + env(safe-area-inset-bottom));
    left: 10px;
    width: auto;
  }

  .oms-toast {
    border-radius: 10px;
    padding: 10px 11px;
  }
}

/* Mobile compact pass: more room for the order list and tighter order details. */
@media (max-width: 760px) {
  .oms-filters-panel,
  .oms-app[data-ui-mode="premium"] .oms-filters-panel {
    max-height: min(31dvh, 238px);
  }

  .oms-filters-header {
    padding: 8px 10px 7px;
  }

  .oms-filters-header .oms-btn-primary {
    height: 32px;
    font-size: 12.5px;
  }

  .oms-filter-group {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px 6px;
    max-height: min(23dvh, 176px);
    padding: 3px 10px 8px;
  }

  .oms-filter-item {
    min-height: 29px;
    margin-bottom: 0;
    padding: 5px 7px;
    font-size: 11.8px;
  }

  .oms-filter-item:first-of-type {
    grid-column: 1 / -1;
  }

  .oms-filter-section {
    display: flex;
    grid-column: 1 / -1;
    align-items: center;
    gap: 5px;
    overflow-x: auto;
    overflow-y: hidden;
    margin-top: 1px;
    padding-bottom: 2px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .oms-filter-section::-webkit-scrollbar {
    display: none;
  }

  .oms-filter-section-title {
    min-width: 88px;
    flex: 0 0 auto;
    padding: 3px 0;
    font-size: 10px;
    white-space: nowrap;
  }

  .oms-filter-subitem {
    width: auto;
    min-height: 27px;
    flex: 0 0 auto;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 999px;
    background: #fff;
    padding: 4px 8px;
    font-size: 11px;
    white-space: nowrap;
  }

  .oms-filter-subitem.active {
    border-color: rgba(37, 99, 235, 0.34);
    box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.08);
  }

  .oms-count {
    padding: 1px 5px;
    font-size: 10px;
  }

  .oms-orders-area,
  .oms-app[data-ui-mode="premium"] .oms-orders-area {
    min-height: 66dvh;
  }

  .oms-table-container,
  .oms-app[data-ui-mode="premium"] .oms-table-container {
    min-height: 430px;
  }

  .oms-table,
  .oms-table-resizable {
    min-width: 800px;
  }

  .oms-app[data-detail-open="true"] .oms-filters-panel,
  .oms-app[data-detail-open="true"][data-ui-mode="premium"] .oms-filters-panel {
    display: none;
  }

  .oms-app[data-detail-open="true"] .oms-workspace {
    overflow: hidden;
  }

  .oms-detail-view {
    width: 100%;
    padding: 10px 10px calc(18px + env(safe-area-inset-bottom));
  }

  .oms-detail-header {
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
  }

  .oms-btn-back {
    height: 32px;
    min-width: 0;
    border-radius: 8px;
    padding: 0 11px;
    font-size: 12.5px;
  }

  .oms-btn-back-label {
    max-width: calc(100vw - 72px);
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .oms-detail-title {
    width: 100%;
    flex-basis: 100%;
    flex-wrap: wrap;
    gap: 6px;
    font-size: 17px;
    line-height: 1.2;
  }

  .oms-star-button {
    font-size: 18px;
  }

  .oms-detail-name {
    flex-basis: 100%;
    overflow: visible;
    font-size: 13px;
    line-height: 1.25;
    text-overflow: clip;
    white-space: normal;
  }

  #omsDetailContent {
    min-width: 0;
  }

  .oms-card {
    margin-bottom: 10px;
    border-radius: 8px;
  }

  .oms-card-header {
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 8px;
    padding: 9px 10px;
    font-size: 13px;
    line-height: 1.25;
  }

  .oms-card-header-note {
    font-size: 10.5px;
  }

  .oms-products-table {
    min-width: 660px;
  }

  .oms-products-table th {
    padding: 8px 10px;
    font-size: 10px;
  }

  .oms-products-table td {
    padding: 9px 10px;
    font-size: 12px;
  }

  .oms-prod-thumb {
    width: 36px;
    height: 36px;
    border-radius: 7px;
    font-size: 18px;
  }

  .oms-detail-grid,
  .oms-address-grid,
  .oms-address-edit-grid,
  .oms-bottom-grid,
  .oms-shipping-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .oms-info-section,
  .oms-order-operator-panel-body,
  .oms-address-body,
  .oms-shipping-card {
    padding: 10px;
  }

  .oms-info-row {
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 8px;
    padding: 5px 0;
    font-size: 12px;
  }

  .oms-info-value,
  .oms-shipping-meta-row strong {
    overflow-wrap: anywhere;
  }

  .oms-order-operator-mini > div,
  .oms-order-operator-mini > .oms-order-operator-status-row {
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 8px;
    padding-top: 6px;
  }

  .oms-order-operator-mini span,
  .oms-order-operator-mini strong {
    font-size: 12px;
  }

  .oms-card-actions,
  .oms-order-info-actions,
  .oms-order-operator-buttons,
  .oms-ship-buttons,
  .oms-shipping-actions {
    justify-content: flex-start;
    gap: 6px;
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
  }

  .oms-card-actions {
    padding: 9px 10px;
  }

  .oms-detail-view .oms-btn-light,
  .oms-detail-view .oms-ship-btn,
  .oms-detail-view .oms-inline-action {
    min-height: 30px;
    padding: 6px 9px;
    font-size: 11.5px;
    white-space: nowrap;
  }

  .oms-shipping-head {
    flex-direction: column;
    gap: 8px;
  }

  .oms-shipping-head .oms-btn-light,
  .oms-shipping-actions {
    width: 100%;
    min-width: 0;
  }

  .oms-shipping-meta-row {
    align-items: flex-start;
    min-height: 24px;
    font-size: 12px;
  }

  .oms-detail-email-preview {
    margin-top: 10px;
  }
}

/* Mobile filter accordion: readable collapsed state plus explicit expand/collapse. */
@media (max-width: 760px) {
  .oms-filters-panel,
  .oms-app[data-ui-mode="premium"] .oms-filters-panel {
    max-height: min(32dvh, 246px);
  }

  .oms-filters-panel.mobile-filters-expanded,
  .oms-app[data-ui-mode="premium"] .oms-filters-panel.mobile-filters-expanded {
    max-height: min(58dvh, 480px);
  }

  .oms-filter-group {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px 7px;
    max-height: min(24dvh, 190px);
    padding: 4px 10px 9px;
  }

  .oms-filters-panel.mobile-filters-expanded .oms-filter-group {
    display: block;
    max-height: min(50dvh, 404px);
    overflow-y: auto;
  }

  .oms-filter-item {
    min-height: 30px;
    padding: 5px 8px;
    font-size: 12px;
  }

  .oms-filter-item:first-of-type {
    grid-column: 1 / -1;
  }

  .oms-filter-toggle {
    display: flex;
    grid-column: 1 / -1;
    width: 100%;
    min-height: 32px;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border: 1px solid rgba(37, 99, 235, 0.22);
    border-radius: 8px;
    background: #eef6ff;
    padding: 6px 9px;
    color: var(--oms-blue-700);
    font-size: 12px;
    font-weight: 850;
    text-align: left;
  }

  .oms-filter-toggle strong {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    border-radius: 999px;
    background: #fff;
    padding: 3px 8px;
    color: var(--oms-blue-700);
    font-size: 11px;
    font-weight: 900;
  }

  .oms-mobile-filter-sections {
    display: none;
    grid-column: 1 / -1;
    padding-top: 3px;
  }

  .oms-filters-panel.mobile-filters-expanded .oms-mobile-filter-sections {
    display: block;
  }

  .oms-filter-section {
    display: block;
    overflow: visible;
    margin-top: 8px;
    padding-bottom: 0;
  }

  .oms-filter-section:first-child {
    margin-top: 5px;
  }

  .oms-filter-section-title {
    min-width: 0;
    padding: 6px 4px 4px;
    color: var(--oms-slate-500);
    font-size: 10.5px;
    white-space: nowrap;
  }

  .oms-filter-subitem {
    display: flex;
    width: 100%;
    min-height: 30px;
    flex: 0 1 auto;
    border: 0;
    border-radius: 8px;
    background: transparent;
    padding: 5px 8px 5px 14px;
    font-size: 12px;
    white-space: normal;
  }

  .oms-filter-subitem.active {
    background: var(--oms-blue-50);
    box-shadow: none;
  }
}

.oms-app[data-ui-mode="premium"] .oms-btn-pack:hover:not(:disabled) { background: #2563eb; }

/* ==========================================================================
   MOBILE (<=640px) - naprawa rozjazdu na telefonie, 2026-08-02
   Naglowki widokow ukladaja sie pionowo, paski zakladek przewijaja sie
   w poziomie, legenda wykresu zawija. Zadna regula nie dotyka desktopu.
   ========================================================================== */
@media (max-width: 640px) {

  /* 1. Naglowki widokow: tytul nad akcjami zamiast wypychania przycisku poza ekran */
  .oms-dashboard-header,
  .oms-analytics-top,
  .oms-orders-header {
    min-height: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .oms-dashboard-header > div:first-child,
  .oms-analytics-top > div:first-child,
  .oms-orders-header > div:first-child {
    min-width: 0;
    flex: 0 1 auto;
  }

  .oms-analytics-actions {
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 8px;
  }

  /* Przyciski akcji trzymaja naturalna szerokosc, nie rozciagaja sie na caly ekran */
  .oms-dashboard-header > button,
  .oms-orders-header > button {
    align-self: flex-start;
  }

  .oms-analytics-top {
    padding: 12px 14px;
  }

  .oms-analytics-title {
    font-size: 17px;
  }

  /* 2. Paski zakladek: przewijanie w poziomie zamiast ucinania ostatnich pozycji */
  .oms-warehouse-tabs,
  .oms-wza-tabs {
    gap: 18px;
    padding-right: 14px;
    padding-left: 14px;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .oms-warehouse-tabs::-webkit-scrollbar,
  .oms-wza-tabs::-webkit-scrollbar {
    display: none;
  }

  .oms-warehouse-tabs > button,
  .oms-wza-tabs > button {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  /* 3. Legenda wykresu: zawijanie zamiast ucinania drugiej serii */
  .oms-dashboard-chart-legend {
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 6px 18px;
    font-size: 13px;
  }

  .oms-dashboard-chart-legend i {
    width: 22px;
  }

  .oms-dashboard-chart-card {
    min-height: 0;
    padding: 18px 16px 16px;
  }

  /* 4. Zabezpieczenie przed przewijaniem calej strony w bok */
  .oms-main,
  .oms-dashboard-view,
  .oms-control-view,
  .oms-orders-area {
    min-width: 0;
    max-width: 100%;
  }
}

.oms-pickup-paid {
  border-radius: 999px;
  background: #fff4e5;
  padding: 2px 8px;
  color: #9a5b00;
  font-size: 11px;
  font-weight: 700;
}

.oms-pickup-paid-dot {
  border-radius: 4px;
  background: #fff4e5;
  padding: 1px 5px;
  color: #9a5b00;
  font-size: 10px;
  font-weight: 800;
}

/* Wariant "board" siedzi juz na kolorowym kaflu, wiec samo logo nie moze niesc
   wlasnego tla ani ramki. Musi stac PO regulach marek, bo te maja ta sama
   specyficznosc i inaczej wygrywalyby kolejnoscia. */
.oms-carrier-logo.board {
  height: 58px;
  min-height: 0;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  box-shadow: none;
}

/* Paxy: wordmark jest szeroki i niski, wiec w kaflu potrzebuje wlasnego limitu. */
.oms-carrier-logo.paxy.board .oms-carrier-logo-img {
  max-width: 128px;
  max-height: 40px;
}

/* Packeta: wordmark 3,6:1, przy tej szerokosci wysokosc zgadza sie z Olza. */
.oms-carrier-logo.packeta.board .oms-carrier-logo-img {
  max-width: 132px;
  max-height: 38px;
}

.oms-paxy-fields {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.oms-paxy-field {
  display: flex;
  min-width: 120px;
  flex: 1 1 120px;
  flex-direction: column;
  gap: 2px;
  border: 1px solid #dfe4ee;
  border-radius: 10px;
  background: #ffffff;
  padding: 9px 14px 10px;
  cursor: text;
  transition: border-color .15s, box-shadow .15s;
}

.oms-paxy-field:focus-within {
  border-color: #00796b;
  box-shadow: 0 0 0 3px rgba(0, 121, 107, 0.12);
}

.oms-paxy-field-label {
  color: #8894ab;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .07em;
}

.oms-paxy-field-value {
  display: flex;
  align-items: baseline;
  gap: 5px;
}

/* Pole tekstowe z inputmode=decimal zamiast number - number dokleja strzalki
   spinnera, ktore w tym ukladzie tylko halasuja. */
.oms-paxy-field input {
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 0;
  color: #111827;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.oms-paxy-field input:focus {
  outline: none;
}

.oms-paxy-field input::placeholder {
  color: #cbd3e1;
  font-weight: 700;
}

.oms-paxy-field em {
  color: #8894ab;
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
}

/* Olza: zwarty uklad wyceny - kwadraciki o stalej szerokosci, przyciski w tym
   samym rzedzie. Drawer nie rozciaga sie na cala szerokosc ekranu, zeby droga
   myszki Waga -> Wysokosc -> Oblicz byla krotka. */
.oms-pickup-drawer.olza {
  max-width: 820px;
}

.oms-paxy-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.oms-paxy-row .oms-paxy-fields {
  gap: 8px;
  margin-bottom: 0;
  flex-wrap: nowrap;
}

.oms-paxy-row .oms-paxy-field {
  flex: 0 0 auto;
  width: 118px;
  min-width: 0;
  box-sizing: border-box;
  justify-content: center;
  gap: 4px;
  border-radius: 12px;
  padding: 10px 12px 11px;
}

.oms-paxy-row .oms-paxy-field-label {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 10px;
  letter-spacing: .05em;
}

.oms-paxy-row .oms-paxy-field-value {
  align-items: baseline;
  gap: 6px;
}

.oms-paxy-row .oms-paxy-field input {
  font-size: 20px;
  line-height: 1.1;
}

.oms-paxy-row .oms-paxy-field em {
  flex: 0 0 auto;
  margin-left: auto;
  font-size: 11px;
}

.oms-paxy-row .oms-pickup-drawer-actions {
  gap: 8px;
  margin: 0;
}

.oms-paxy-row .oms-pickup-order,
.oms-paxy-row .oms-paxy-ship-button {
  height: 44px;
  padding: 0 18px;
  border-radius: 12px;
  font-size: 13px;
  white-space: nowrap;
}

@media (max-width: 640px) {
  .oms-paxy-row .oms-paxy-fields {
    flex-wrap: wrap;
  }
  .oms-paxy-row .oms-paxy-field {
    width: calc(50% - 4px);
  }
}

.oms-paxy-offers {
  margin-top: 14px;
  border: 1px solid #dfeeea;
  border-radius: 8px;
  background: #ffffff;
  overflow: hidden;
}

.oms-paxy-offers-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  border-bottom: 1px solid #eef2f7;
  padding: 10px 14px;
  font-size: 12px;
}

.oms-paxy-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.oms-paxy-table th {
  border-bottom: 1px solid #eef2f7;
  padding: 8px 14px;
  color: #6b7890;
  font-size: 11px;
  font-weight: 700;
  text-align: right;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.oms-paxy-table th:first-child,
.oms-paxy-table td:first-child {
  text-align: left;
}

.oms-paxy-table td {
  border-bottom: 1px solid #f4f6fa;
  padding: 7px 14px;
  color: #202124;
  text-align: right;
  white-space: nowrap;
}

.oms-paxy-table tr:last-child td {
  border-bottom: 0;
}

.oms-paxy-table tr.cheapest td {
  background: #f0fdf9;
  font-weight: 800;
}

.oms-paxy-table td em {
  margin-left: 8px;
  border-radius: 999px;
  background: #00796b;
  padding: 1px 7px;
  color: #ffffff;
  font-size: 10px;
  font-style: normal;
  font-weight: 800;
}

.oms-paxy-quote {
  margin-top: 14px;
  border: 1px solid #cfe3df;
  border-radius: 10px;
  background: #ffffff;
  padding: 14px 16px;
}

.oms-paxy-quote.oversized {
  border-color: #f0b429;
  background: #fffaf0;
}

.oms-paxy-quote-main {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.oms-paxy-quote-service {
  color: #202124;
  font-size: 13px;
  font-weight: 800;
}

.oms-paxy-quote-price {
  color: #0f766e;
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.oms-paxy-quote.oversized .oms-paxy-quote-price {
  color: #b45309;
}

.oms-paxy-quote-meta {
  margin-top: 4px;
  color: #6b7890;
  font-size: 12px;
}

.oms-paxy-quote-alert {
  margin-top: 12px;
  border-radius: 8px;
  background: #fef3c7;
  padding: 10px 12px;
  color: #7c4a03;
  font-size: 12px;
  line-height: 1.5;
}

.oms-paxy-ship-button {
  border: 0;
  border-radius: 8px;
  background: #111827;
  padding: 10px 20px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.oms-paxy-ship-button:disabled {
  background: #9aa3b2;
  cursor: default;
}

.oms-paxy-sent {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
  border: 1px solid #9fd3c7;
  border-radius: 10px;
  background: #f0fdf9;
  padding: 12px 14px;
  font-size: 12px;
}

.oms-paxy-sent strong {
  color: #0f766e;
  font-size: 13px;
  font-weight: 900;
}

.oms-paxy-sent code {
  border-radius: 4px;
  background: #ffffff;
  padding: 2px 7px;
  font-size: 12px;
  font-weight: 800;
}

.oms-paxy-print-warn {
  color: #b45309;
  font-weight: 700;
}

.oms-paxy-label-actions {
  display: inline-flex;
  gap: 6px;
  align-items: center;
}

.oms-paxy-label-button {
  border: 1px solid #cbd5f5;
  border-radius: 7px;
  background: #ffffff;
  padding: 5px 10px;
  color: #1f2937;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}

.oms-paxy-label-button:hover:not(:disabled) {
  border-color: #94a3b8;
  background: #f8fafc;
}

.oms-paxy-label-button:disabled {
  color: #9aa3b2;
  cursor: default;
}

.oms-paxy-history {
  margin-top: 10px;
  border-top: 1px solid #eef2f7;
  padding-top: 10px;
}

.oms-paxy-history-toggle {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 0;
  background: transparent;
  padding: 0;
  color: #6b7890;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.oms-paxy-history-toggle:hover {
  color: #00796b;
}

.oms-paxy-history-caret {
  width: 0;
  height: 0;
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
  border-left: 5px solid currentColor;
  transition: transform .15s;
}

.oms-paxy-history-caret.open {
  transform: rotate(90deg);
}

.oms-paxy-history-list {
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
}

.oms-paxy-history-list li {
  display: flex;
  align-items: baseline;
  gap: 10px;
  border-bottom: 1px solid #f4f6fa;
  padding: 6px 0;
  font-size: 12px;
}

.oms-paxy-history-list li:last-child {
  border-bottom: 0;
}

.oms-paxy-history-list code {
  min-width: 150px;
  border-radius: 4px;
  background: #f4f6fa;
  padding: 2px 7px;
  font-size: 11px;
  font-weight: 700;
}

.oms-paxy-history-list span {
  min-width: 104px;
  color: #6b7890;
}

.oms-paxy-history-list em {
  border-radius: 999px;
  padding: 2px 9px;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.oms-paxy-history-list em.tone-pending {
  background: #eef2f7;
  color: #4a5568;
}

.oms-paxy-history-list em.tone-active {
  background: #e0f2fe;
  color: #075985;
}

.oms-paxy-history-list em.tone-done {
  background: #dcfce7;
  color: #166534;
}

.oms-paxy-history-list em.tone-warn {
  background: #fef3c7;
  color: #92400e;
}

/* Numer listu prowadzi do sledzenia na inpost.pl - otwiera sie w nowej karcie,
   zeby nie wyrzucalo operatora z panelu w srodku pakowania. */
.oms-paxy-track {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: inherit;
  text-decoration: none;
}

.oms-paxy-track code {
  color: #202124;
}

.oms-paxy-track code {
  transition: background .15s, color .15s;
}

.oms-paxy-track:hover code {
  background: #e0f2fe;
  color: #075985;
  text-decoration: underline;
}

.oms-paxy-track::after {
  content: "↗";
  color: #9aa3b2;
  font-size: 10px;
}

.oms-paxy-track:hover::after {
  color: #075985;
}

/* Pasek powrotu do aktywnej sesji pakowania (2026-08-06) */
#omsPackingReturnBar {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 950;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #3478f6;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 12px 20px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(20, 40, 90, 0.35);
  transition: background 0.15s ease, transform 0.15s ease;
}

#omsPackingReturnBar:hover {
  background: #2861d8;
  transform: translateY(-1px);
}

/* Konflikt snapshotu: link akceptacji nowej wersji zamowienia (2026-08-06) */
/* Baner konfliktu snapshotu w glownym oknie pakowania (2026-09-03) */
.oms-batch-snapshot-conflict {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin: 0 0 10px;
  padding: 12px 14px;
  border: 1px solid #fca5a5;
  border-radius: 10px;
  background: #fef2f2;
  color: #b91c1c;
}

.oms-batch-snapshot-conflict strong {
  flex-basis: 100%;
  font-size: 13px;
  letter-spacing: 0.02em;
}

.oms-batch-snapshot-conflict span {
  flex: 1 1 240px;
  font-size: 13px;
  font-weight: 600;
}

.oms-batch-snapshot-conflict button {
  padding: 10px 16px;
  border: 0;
  border-radius: 8px;
  background: #2861d8;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.oms-batch-snapshot-conflict button:hover {
  background: #1d4fb8;
}

.oms-batch-refresh-snapshot {
  display: inline-block;
  margin-top: 2px;
  color: #2861d8;
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
}

/* Ostrzezenie magazynowe na karcie pakowania (2026-08-06) */
.oms-batch-order-card .oms-batch-order-warning {
  color: #fbbf24;
  font-weight: 600;
}

/* Licznik dnia pakowania (2026-08-06) */
.oms-daily-pack-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 12px;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.16);
  border: 1px solid rgba(34, 197, 94, 0.55);
  color: #4ade80;
  font-size: 12px;
  font-weight: 700;
  cursor: help;
  white-space: nowrap;
}

/* Panel statystyk dnia pakowania (2026-08-06) */
.oms-daily-stats-popover {
  position: fixed;
  z-index: 1400;
  width: 290px;
  background: #1b2430;
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 14px;
  box-shadow: 0 18px 44px rgba(2, 6, 23, 0.6);
  padding: 14px 16px;
  color: #e2e8f0;
  animation: omsDailyStatsIn 0.18s ease;
}

@keyframes omsDailyStatsIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.oms-daily-stats-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 15px;
  margin-bottom: 10px;
}

.oms-daily-stats-close {
  border: none;
  background: transparent;
  color: #94a3b8;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
}

.oms-daily-stats-close:hover { color: #f1f5f9; }

.oms-daily-stats-section {
  padding-top: 10px;
  margin-top: 4px;
  border-top: 1px solid rgba(148, 163, 184, 0.15);
}

.oms-daily-stats-caption {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #7d8aa0;
  margin-bottom: 8px;
}

.oms-daily-stats-packer {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 3px 0;
  font-size: 13px;
}

.oms-daily-stats-packer-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--packer-color, #4ade80);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.08);
  align-self: center;
  flex: 0 0 auto;
}
.oms-daily-stats-packer-name { font-weight: 700; color: var(--packer-color, #bbf7d0); }
.oms-daily-stats-packer-pace { flex: 1; color: #94a3b8; font-size: 12px; text-align: right; }
.oms-daily-stats-packer strong { min-width: 28px; text-align: right; color: var(--packer-color, #4ade80); font-size: 15px; }

/* Cienki pasek udzialu pakowacza w calym dniu - w jego kolorze */
.oms-daily-stats-packer-share {
  height: 4px;
  margin: 0 0 6px 17px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.12);
  overflow: hidden;
}
.oms-daily-stats-packer-share i { display: block; height: 100%; border-radius: 999px; }

.oms-daily-stats-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin: -2px 0 8px;
  font-size: 11px;
  color: #cbd5e1;
}
.oms-daily-stats-legend span { display: inline-flex; align-items: center; gap: 5px; }
.oms-daily-stats-legend i { width: 9px; height: 9px; border-radius: 999px; display: inline-block; }

.oms-daily-stats-hour {
  display: grid;
  grid-template-columns: 44px 1fr 30px;
  align-items: center;
  gap: 10px;
  padding: 2px 0;
  font-size: 12px;
}

.oms-daily-stats-hour-label { color: #94a3b8; font-variant-numeric: tabular-nums; }

.oms-daily-stats-hour-bar {
  display: block;
  height: 10px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.12);
  overflow: hidden;
}

.oms-daily-stats-hour-bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #16a34a, #4ade80);
}

/* Stackowany slupek godziny: segment = pakowacz w swoim kolorze */
.oms-daily-stats-hour-stack {
  display: flex;
  height: 100%;
  border-radius: 999px;
  overflow: hidden;
  gap: 1px;
}
.oms-daily-stats-hour-stack i {
  border-radius: 0;
  background: #4ade80;
  min-width: 3px;
}

.oms-daily-stats-hour strong { text-align: right; color: #e2e8f0; font-variant-numeric: tabular-nums; }

/* Serie identycznych koszykow w kolumnie pakowania (2026-08-06) */
.oms-batch-series-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 12px 2px 6px;
  font-size: 11px;
  color: #93c5fd;
}

.oms-batch-series-badge {
  background: rgba(59, 130, 246, 0.2);
  border: 1px solid rgba(59, 130, 246, 0.5);
  color: #93c5fd;
  border-radius: 999px;
  padding: 2px 9px;
  font-weight: 800;
  white-space: nowrap;
}

.oms-batch-series-label {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #7d8aa0;
}

.oms-batch-series-progress { font-weight: 700; color: #93c5fd; }

.oms-batch-order-card.in-series { border-left: 3px solid rgba(59, 130, 246, 0.45); }

.oms-batch-multi-client { color: #93c5fd; font-weight: 600; }

/* Panel podmiany skladu mixu - premium (2026-08-06) */
.oms-composition-link {
  margin-top: 8px;
  border: 1px dashed rgba(148, 163, 184, 0.35);
  background: transparent;
  color: #8b98ad;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 12px;
  cursor: pointer;
  width: 100%;
  text-align: center;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.oms-composition-link:hover { color: #e2e8f0; border-color: #94a3b8; }

.oms-composition-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1500;
  background: rgba(2, 6, 23, 0.66);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
}

.oms-composition-shell {
  width: min(520px, calc(100vw - 32px));
  max-height: 86vh;
  overflow: auto;
  background: linear-gradient(180deg, #1e2836, #18202c);
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  box-shadow: 0 28px 70px rgba(2, 6, 23, 0.75);
  padding: 20px 22px;
  color: #e2e8f0;
  animation: omsDailyStatsIn 0.18s ease;
}

.oms-composition-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 4px;
}

.oms-composition-title { display: flex; align-items: center; gap: 12px; }

.oms-composition-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: rgba(74, 222, 128, 0.12);
  border: 1px solid rgba(74, 222, 128, 0.35);
  color: #4ade80;
  font-size: 18px;
}

.oms-composition-title strong { display: block; font-size: 16px; }

.oms-composition-order {
  font-size: 12px;
  color: #8b98ad;
  font-variant-numeric: tabular-nums;
}

.oms-composition-hint { font-size: 12px; color: #8b98ad; margin: 8px 0 14px; }

.oms-composition-fixed {
  font-size: 12px;
  color: #9aa7ba;
  background: rgba(148, 163, 184, 0.07);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 10px;
  padding: 9px 12px;
  margin-bottom: 12px;
  display: grid;
  gap: 5px;
}

.oms-composition-fixed div { display: flex; align-items: center; gap: 8px; min-width: 0; }
.oms-composition-fixed div em {
  margin-left: auto;
  font-style: normal;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #7d8aa0;
  white-space: nowrap;
}

.oms-composition-rows { display: grid; gap: 8px; }

.oms-composition-row {
  display: grid;
  grid-template-columns: 1fr 118px 34px;
  gap: 8px;
  align-items: start;
}

.oms-qty-stepper {
  display: grid;
  grid-template-columns: 34px 1fr 34px;
  align-items: stretch;
  background: rgba(2, 6, 23, 0.55);
  border: 1px solid rgba(148, 163, 184, 0.26);
  border-radius: 10px;
  overflow: hidden;
}

.oms-qty-stepper button {
  border: none;
  background: rgba(148, 163, 184, 0.1);
  color: #cbd5e1;
  font-size: 17px;
  font-weight: 800;
  cursor: pointer;
  line-height: 1;
  transition: background 0.12s ease, color 0.12s ease;
}

.oms-qty-stepper button:hover { background: rgba(74, 222, 128, 0.18); color: #4ade80; }

.oms-qty-stepper .oms-composition-qty {
  border: none;
  border-radius: 0;
  background: transparent;
  text-align: center;
  padding: 9px 2px;
  -moz-appearance: textfield;
  appearance: textfield;
}

.oms-qty-stepper .oms-composition-qty::-webkit-outer-spin-button,
.oms-qty-stepper .oms-composition-qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.oms-qty-stepper .oms-composition-qty:focus { box-shadow: none; }

.oms-combo-main { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.oms-combo-main b { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.oms-combo-main i {
  font-style: normal;
  font-size: 11px;
  color: #8b98ad;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-combo { position: relative; min-width: 0; }

.oms-combo input,
.oms-composition-qty {
  width: 100%;
  background: rgba(2, 6, 23, 0.55);
  border: 1px solid rgba(148, 163, 184, 0.26);
  color: #e2e8f0;
  border-radius: 10px;
  padding: 9px 12px;
  font-size: 13px;
  min-width: 0;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.oms-combo input:focus,
.oms-composition-qty:focus {
  outline: none;
  border-color: rgba(74, 222, 128, 0.6);
  box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.12);
}

.oms-composition-qty { text-align: center; }

.oms-combo-list {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 20;
  max-height: 240px;
  overflow: auto;
  background: #121926;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(2, 6, 23, 0.7);
  padding: 4px;
}

.oms-combo-list button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  border: none;
  background: transparent;
  color: #e2e8f0;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 13px;
  cursor: pointer;
  text-align: left;
}

.oms-combo-list button:hover { background: rgba(74, 222, 128, 0.1); }
.oms-combo-list button span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.oms-combo-list button em { font-style: normal; font-size: 11px; color: #4ade80; white-space: nowrap; }

.oms-combo-empty { padding: 10px 12px; font-size: 12px; color: #7d8aa0; }

.oms-composition-remove {
  border: none;
  background: rgba(248, 113, 113, 0.1);
  color: #f87171;
  border-radius: 10px;
  height: 38px;
  cursor: pointer;
  font-size: 15px;
  transition: background 0.15s ease;
}

.oms-composition-remove:hover { background: rgba(248, 113, 113, 0.22); }

.oms-composition-add {
  margin-top: 10px;
  border: 1px dashed rgba(74, 222, 128, 0.4);
  background: transparent;
  color: #4ade80;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  transition: background 0.15s ease;
}

.oms-composition-add:hover { background: rgba(74, 222, 128, 0.08); }

.oms-composition-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(148, 163, 184, 0.14);
}

.oms-composition-total {
  font-weight: 800;
  font-size: 13px;
  padding: 6px 12px;
  border-radius: 999px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.oms-composition-total.ok {
  color: #4ade80;
  background: rgba(74, 222, 128, 0.12);
  border: 1px solid rgba(74, 222, 128, 0.4);
}

.oms-composition-total.bad {
  color: #fbbf24;
  background: rgba(251, 191, 36, 0.1);
  border: 1px solid rgba(251, 191, 36, 0.4);
}

.oms-composition-actions { display: flex; align-items: center; gap: 10px; }

.oms-composition-btn {
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: transparent;
  color: #cbd5e1;
  border-radius: 10px;
  padding: 9px 18px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.oms-composition-btn:hover { border-color: #94a3b8; background: rgba(148, 163, 184, 0.08); }

.oms-composition-btn.primary {
  border-color: #16a34a;
  background: linear-gradient(135deg, #16a34a, #15803d);
  color: #f0fdf4;
}

.oms-composition-btn.primary:hover { filter: brightness(1.08); }

.oms-composition-btn.primary:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  filter: none;
}

.oms-composition-error {
  margin-top: 10px;
  color: #f87171;
  font-size: 12px;
}

.oms-daily-stats-sub { font-size: 12px; color: #94a3b8; margin: -4px 0 6px; }

.oms-daily-stats-compare {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #94a3b8;
  margin-bottom: 4px;
}

.oms-daily-stats-compare span { font-weight: 800; }
.oms-daily-stats-compare.up span { color: #4ade80; }
.oms-daily-stats-compare.down span { color: #fbbf24; }

/* === Stacja zwrotów (skan kolektorem + one-click automat) === */
.oms-station {
  margin: 14px 16px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.oms-station-scanline {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border: 2px solid #6d4fd8;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(109, 79, 216, .14);
}

.oms-station-scan-icon {
  font-size: 22px;
  color: #6d4fd8;
}

.oms-station-input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  font-size: 17px;
  font-weight: 700;
  color: #1d2333;
  background: transparent;
  letter-spacing: .02em;
}

.oms-station-input::placeholder {
  color: #9aa3b8;
  font-weight: 500;
}

.oms-station-resolve {
  border: 0;
  border-radius: 12px;
  padding: 10px 18px;
  background: linear-gradient(135deg, #8b5cf6 0%, #6d4fd8 100%);
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.oms-station-resolve:disabled { opacity: .6; cursor: default; }

.oms-station-clear {
  border: 1px solid #d7dde8;
  border-radius: 12px;
  padding: 9px 13px;
  background: #f4f6fa;
  color: #5b6478;
  cursor: pointer;
  font-weight: 700;
}

.oms-station-error {
  padding: 10px 14px;
  border-radius: 12px;
  background: #fdecec;
  border: 1px solid #f3b6b6;
  color: #9c1f1f;
  font-weight: 600;
  font-size: 14px;
}

.oms-station-card {
  border: 1px solid #d7dde8;
  border-radius: 18px;
  background: #fff;
  padding: 16px 18px;
  box-shadow: 0 12px 30px rgba(29, 35, 51, .06);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.oms-station-order-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.oms-station-order-number {
  font-size: 20px;
  font-weight: 900;
  color: #1d2333;
}

.oms-station-order-meta {
  color: #5b6478;
  font-size: 14px;
  margin-top: 2px;
}

.oms-station-match { font-size: 12.5px; color: #8b93a7; }

.oms-station-badges { display: flex; flex-wrap: wrap; gap: 6px; }

.oms-station-badge {
  display: inline-block;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 700;
}

.oms-station-badge.is-existing { background: #eef2ff; color: #3b4bd8; border: 1px solid #c7d0f8; }
.oms-station-badge.is-allegro { background: #fff3e6; color: #b25e00; border: 1px solid #f5cf9e; }

.oms-station-items {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #f7f8fb;
  font-size: 14px;
  color: #2a3145;
}

.oms-station-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

.oms-station-action {
  border: 0;
  border-radius: 16px;
  padding: 16px 14px;
  font-size: 16px;
  font-weight: 900;
  color: #fff;
  cursor: pointer;
  text-align: center;
  line-height: 1.25;
  box-shadow: 0 10px 24px rgba(29, 35, 51, .12);
}

.oms-station-action span {
  display: block;
  font-size: 12px;
  font-weight: 600;
  opacity: .85;
  margin-top: 4px;
}

.oms-station-action.is-notcollected { background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%); }
.oms-station-action.is-return { background: linear-gradient(135deg, #10b981 0%, #059669 100%); }
.oms-station-action.is-partial { background: linear-gradient(135deg, #64748b 0%, #475569 100%); }
.oms-station-action:disabled { opacity: .55; cursor: default; }

.oms-station-run {
  border-top: 1px dashed #d7dde8;
  padding-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.oms-station-run-headline { font-weight: 800; font-size: 14.5px; }
.oms-station-run-headline.is-done { color: #067a55; }
.oms-station-run-headline.is-failed { color: #9c1f1f; }

.oms-station-step {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  color: #2a3145;
}

.oms-station-step-ico {
  display: inline-grid;
  width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.oms-station-step-ico.is-done { background: #d9f4e8; color: #067a55; }
.oms-station-step-ico.is-skipped { background: #eef1f6; color: #8b93a7; }
.oms-station-step-ico.is-pending { background: #fff3e6; color: #b25e00; }
.oms-station-step-ico.is-failed { background: #fdecec; color: #9c1f1f; }
.oms-station-step-ico.is-idle { background: #eef1f6; color: #b6bdcc; }

.oms-station-step-label { font-weight: 700; }
.oms-station-step-detail { color: #8b93a7; font-size: 12.5px; }

.oms-station-nohit {
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: #5b6478;
}

.oms-station-candidates { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }

.oms-station-candidate {
  text-align: left;
  border: 1px solid #d7dde8;
  border-radius: 10px;
  background: #f7f8fb;
  padding: 8px 12px;
  cursor: pointer;
  font-size: 13.5px;
  font-weight: 600;
  color: #2a3145;
}

.oms-station-candidate:hover { border-color: #6d4fd8; background: #f3f0ff; }

.oms-app[data-theme="dark"] .oms-station-scanline,
.oms-app[data-theme="dark"] .oms-station-card {
  background: #1c2233;
  border-color: #323b52;
  box-shadow: none;
}

.oms-app[data-theme="dark"] .oms-station-input { color: #e8ecf5; }
.oms-app[data-theme="dark"] .oms-station-items { background: #232a3d; color: #cdd4e4; }
.oms-app[data-theme="dark"] .oms-station-order-number { color: #e8ecf5; }
.oms-app[data-theme="dark"] .oms-station-step { color: #cdd4e4; }

/* === Stacja zwrotów: polish v2 (animacje, glow, WOW) === */
@keyframes omsStationCardIn {
  from { opacity: 0; transform: translateY(10px) scale(.99); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes omsStationStepIn {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes omsStationScanPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .55; transform: scale(1.12); }
}

@keyframes omsStationShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

.oms-station-scanline {
  position: relative;
  transition: box-shadow .2s ease, border-color .2s ease;
}

.oms-station-scanline:focus-within {
  border-color: #8b5cf6;
  box-shadow: 0 0 0 4px rgba(139, 92, 246, .18), 0 14px 34px rgba(109, 79, 216, .22);
}

.oms-station-scan-icon {
  animation: omsStationScanPulse 2.2s ease-in-out infinite;
}

.oms-station-card {
  animation: omsStationCardIn .28s cubic-bezier(.2, .8, .3, 1);
}

.oms-station-error {
  animation: omsStationShake .3s ease;
}

.oms-station-action {
  transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}

.oms-station-action:not(:disabled):hover {
  transform: translateY(-2px);
  filter: brightness(1.06);
  box-shadow: 0 16px 32px rgba(29, 35, 51, .2);
}

.oms-station-action:not(:disabled):active {
  transform: translateY(0) scale(.98);
}

.oms-station-step {
  animation: omsStationStepIn .25s ease both;
}

.oms-station-step:nth-child(2) { animation-delay: .03s; }
.oms-station-step:nth-child(3) { animation-delay: .06s; }
.oms-station-step:nth-child(4) { animation-delay: .09s; }
.oms-station-step:nth-child(5) { animation-delay: .12s; }
.oms-station-step:nth-child(6) { animation-delay: .15s; }
.oms-station-step:nth-child(7) { animation-delay: .18s; }
.oms-station-step:nth-child(8) { animation-delay: .21s; }
.oms-station-step:nth-child(9) { animation-delay: .24s; }

.oms-station-run-headline.is-done {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, #d9f4e8 0%, #c3efdc 100%);
  border: 1px solid #9adfc2;
  width: fit-content;
}

.oms-station-run-headline.is-failed {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #fdecec;
  border: 1px solid #f3b6b6;
  width: fit-content;
}

@media (max-width: 900px) {
  .oms-station { margin: 10px 8px 0; }
  .oms-station-actions { grid-template-columns: 1fr; }
  .oms-station-input { font-size: 16px; }
}

.oms-app[data-theme="dark"] .oms-station-run-headline.is-done {
  background: rgba(16, 185, 129, .16);
  border-color: rgba(16, 185, 129, .4);
  color: #5eead4;
}

.oms-app[data-theme="dark"] .oms-station-run-headline.is-failed {
  background: rgba(220, 60, 60, .16);
  border-color: rgba(220, 60, 60, .4);
  color: #fca5a5;
}

/* === Stacja zwrotów: confirm misclick + przycisk manual === */
.oms-station-action.is-manual { background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%); }

@keyframes omsStationConfirmPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(220, 38, 38, .45); }
  50% { box-shadow: 0 0 0 8px rgba(220, 38, 38, 0); }
}

.oms-station-action.is-confirm {
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  animation: omsStationConfirmPulse 1s ease-in-out infinite;
  outline: 2px solid #fecaca;
}

/* === Analityka zwrotów (kafle nad listą) === */
.oms-returns-analytics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin: 10px 16px 0;
}

.oms-returns-kpi {
  background: #fff;
  border: 1px solid #d7dde8;
  border-radius: 14px;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.oms-returns-kpi span { font-size: 11.5px; font-weight: 700; color: #8b93a7; text-transform: uppercase; letter-spacing: .04em; }
.oms-returns-kpi strong { font-size: 16px; font-weight: 900; color: #1d2333; }
.oms-returns-kpi em { font-style: normal; font-size: 12px; color: #5b6478; }
.oms-returns-kpi.is-wide { grid-column: span 2; }

.oms-app[data-theme="dark"] .oms-returns-kpi { background: #1c2233; border-color: #323b52; }
.oms-app[data-theme="dark"] .oms-returns-kpi strong { color: #e8ecf5; }

/* === Stacja: zaznaczanie pozycji + panel wymiany === */
.oms-station-item.is-toggle {
  border: 1px solid #c9e8d8;
  background: #eefaf4;
  border-radius: 10px;
  padding: 6px 10px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font: inherit;
  color: #1d2333;
}

.oms-station-item.is-toggle.is-off {
  border-color: #d7dde8;
  background: #f4f6fa;
  color: #9aa3b8;
  text-decoration: line-through;
}

.oms-station-item-check {
  display: inline-grid;
  width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 6px;
  background: #10b981;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.oms-station-item.is-off .oms-station-item-check { background: #d7dde8; }

.oms-station-action.is-exchange { background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%); }

.oms-station-exchange {
  display: flex;
  gap: 10px;
  align-items: stretch;
  flex-wrap: wrap;
}

.oms-station-exchange input[type="text"] {
  flex: 1;
  min-width: 220px;
  border: 2px solid #0ea5e9;
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 15px;
  font-weight: 700;
}

.oms-station-exchange input[type="number"] {
  width: 76px;
  border: 1px solid #d7dde8;
  border-radius: 12px;
  padding: 10px;
  font-size: 15px;
  font-weight: 700;
  text-align: center;
}

.oms-station-exchange .oms-station-action { flex: 0 0 auto; padding: 10px 18px; }

/* === Wymiana: autocomplete produktu === */
.oms-station-exchange-search { position: relative; flex: 1; min-width: 260px; }
.oms-station-exchange-search input[type="text"] { width: 100%; border: 2px solid #0ea5e9; border-radius: 12px; padding: 10px 14px; font-size: 15px; font-weight: 700; }
.oms-station-exchange-results {
  position: absolute; top: calc(100% + 4px); left: 0; right: 0; z-index: 60;
  background: #fff; border: 1px solid #d7dde8; border-radius: 12px;
  box-shadow: 0 14px 34px rgba(29,35,51,.16); overflow: hidden;
}
.oms-station-exchange-result { display: block; width: 100%; text-align: left; padding: 9px 13px; border: 0; background: #fff; cursor: pointer; }
.oms-station-exchange-result:hover { background: #f0f9ff; }
.oms-station-exchange-result strong { display: block; font-size: 13.5px; color: #1d2333; }
.oms-station-exchange-result span { font-size: 12px; color: #8b93a7; }
.oms-app[data-theme="dark"] .oms-station-exchange-results, .oms-app[data-theme="dark"] .oms-station-exchange-result { background: #1c2233; }
.oms-app[data-theme="dark"] .oms-station-exchange-result strong { color: #e8ecf5; }

/* Czytelny blad operacyjny: co jest zle -> co zrobic -> (opcjonalnie) tresc techniczna.
   Uzywany w asystencie pakowania i na karcie zamowienia, zawsze wewnatrz czerwonego boxa. */
.oms-error-explained {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
  flex-basis: 100%;
  text-align: left;
}

.oms-error-explained .oms-error-title {
  font-size: 13px;
  font-weight: 950;
  letter-spacing: 0.02em;
  line-height: 1.25;
}

.oms-error-explained .oms-error-fix {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.oms-error-explained .oms-error-tech {
  font-size: 11px;
  font-weight: 700;
  opacity: 0.75;
}

.oms-error-explained .oms-error-tech > summary {
  cursor: pointer;
  list-style: revert;
}

.oms-error-explained .oms-error-tech > span {
  display: block;
  margin-top: 4px;
  font-weight: 600;
  word-break: break-word;
}

/* Sekcje sklepow to rozbicie jednej grupy "Do spakowania", a nie osobne statusy.
   Podpis nad nimi ma to mowic wprost, zeby liczba przy sklepie nie wygladala na
   kolejne miejsce, w ktorym lezy to samo zamowienie. */
.oms-filter-sections-caption {
  margin: 14px 12px 6px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.6;
}

/* ===== Zwrot v2 - karta w stylu zamowienia (mockup 2026-08-09) ===== */
.oms-return-v2-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 26px;
  background: #ffffff;
  border-bottom: 1px solid var(--oms-slate-200);
}

.oms-return-v2-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--oms-slate-200);
  background: #ffffff;
  color: var(--oms-blue-600);
  font-weight: 600;
  font-size: 13px;
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
}

.oms-return-v2-back:hover {
  background: var(--oms-blue-50);
  border-color: var(--oms-blue-500);
}

.oms-return-v2-topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.oms-return-v2-ret {
  background: var(--oms-purple-500);
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  padding: 6px 14px;
  border-radius: 999px;
}

.oms-return-v2-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #ffffff;
  border: 1px solid var(--oms-slate-200);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--oms-slate-700);
}

.oms-return-v2-status i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--oms-green-500);
}

.oms-return-v2-status.is-accepted i { background: var(--oms-blue-500); }
.oms-return-v2-status.is-corrected i { background: var(--oms-purple-500); }
.oms-return-v2-status.is-closed i { background: var(--oms-slate-400); }

.oms-return-v2-x {
  border: none;
  background: transparent;
  font-size: 22px;
  color: var(--oms-slate-400);
  cursor: pointer;
  line-height: 1;
  padding: 4px 8px;
}

.oms-return-v2-x:hover { color: var(--oms-slate-700); }

.oms-return-v2-panel {
  padding: 18px 26px 26px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow: auto;
}

.oms-return-v2-title h1 {
  display: inline;
  margin: 0;
  font-size: 22px;
  font-weight: 800;
  color: var(--oms-slate-900);
}

.oms-return-v2-title span {
  margin-left: 10px;
  font-size: 14px;
  color: var(--oms-slate-500);
}

.oms-return-v2-card {
  background: #ffffff;
  border: 1px solid var(--oms-slate-200);
  border-radius: 16px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  overflow: hidden;
}

.oms-return-v2-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--oms-slate-100);
}

.oms-return-v2-card-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--oms-slate-900);
}

.oms-return-v2-card-meta {
  font-size: 12px;
  color: var(--oms-slate-500);
}

.oms-return-v2-store {
  font-size: 11px;
  font-weight: 700;
  background: var(--oms-slate-100);
  color: var(--oms-slate-700);
  padding: 4px 10px;
  border-radius: 999px;
}

.oms-return-v2-products table { width: 100%; }

.oms-return-v2-products-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 18px;
  border-top: 1px solid var(--oms-slate-100);
  background: var(--oms-slate-50);
}

.oms-return-v2-note {
  font-size: 12px;
  color: var(--oms-slate-500);
  background: var(--oms-slate-100);
  border-radius: 999px;
  padding: 7px 14px;
}

.oms-return-v2-columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 16px;
  align-items: start;
}

@media (max-width: 1100px) {
  .oms-return-v2-columns { grid-template-columns: 1fr; }
  .oms-return-v2-products-footer { flex-direction: column; align-items: stretch; }
}

.oms-return-v2-info-rows { padding: 4px 18px 8px; }

.oms-return-v2-info-rows .oms-return-info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 11px 0;
  border-bottom: 1px solid var(--oms-slate-100);
  font-size: 13px;
}

.oms-return-v2-info-rows .oms-return-info-row:last-child { border-bottom: none; }
.oms-return-v2-info-rows .oms-return-info-row span { color: var(--oms-slate-500); }

.oms-return-v2-info-rows .oms-return-info-row strong {
  color: var(--oms-slate-900);
  font-weight: 600;
  text-align: right;
}

.oms-return-v2-info-rows .oms-return-info-row span.oms-return-contact-value {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--oms-slate-900);
  font-weight: 600;
  text-align: right;
  min-width: 0;
}

.oms-return-contact-value a {
  color: var(--oms-slate-900);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-return-contact-value a:hover { text-decoration: underline; }

.oms-return-contact-copy {
  border: 1px solid var(--oms-slate-200);
  background: #fff;
  border-radius: 6px;
  cursor: pointer;
  font-size: 11px;
  line-height: 1;
  padding: 3px 5px;
  color: var(--oms-slate-500);
}

.oms-return-contact-copy:hover { color: var(--oms-slate-900); }
.oms-return-contact-copy.is-copied { color: #16a34a; border-color: #16a34a; }

.oms-app[data-theme="dark"] .oms-return-contact-value,
.oms-app[data-theme="dark"] .oms-return-contact-value a { color: #e2e8f0; }

.oms-app[data-theme="dark"] .oms-return-contact-copy {
  background: transparent;
  border-color: rgba(148, 163, 184, 0.4);
  color: #94a3b8;
}

.oms-return-v2-amount {
  color: var(--oms-red-500) !important;
  background: #fef2f2;
  padding: 3px 10px;
  border-radius: 999px;
  font-weight: 700 !important;
}

.oms-return-v2-orderlink {
  border: none;
  background: transparent;
  color: var(--oms-blue-600);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  padding: 0;
}

.oms-return-v2-orderlink:hover { text-decoration: underline; color: var(--oms-blue-700); }
.oms-return-v2-orderlink:disabled { color: var(--oms-slate-400); cursor: default; text-decoration: none; }

.oms-return-v2-info-footer {
  padding: 10px 18px;
  border-top: 1px solid var(--oms-slate-100);
  font-size: 11.5px;
  color: var(--oms-slate-400);
  background: var(--oms-slate-50);
}

.oms-return-v2-actions-card > .oms-return-workflow-stack {
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.oms-app[data-theme="dark"] .oms-return-v2-topbar,
.oms-app[data-theme="dark"] .oms-return-v2-card {
  background: #172033;
  border-color: #334155;
}

.oms-app[data-theme="dark"] .oms-return-v2-back,
.oms-app[data-theme="dark"] .oms-return-v2-status {
  background: #1f2937;
  border-color: #334155;
  color: #e5e7eb;
}

.oms-app[data-theme="dark"] .oms-return-v2-title h1,
.oms-app[data-theme="dark"] .oms-return-v2-card-title,
.oms-app[data-theme="dark"] .oms-return-v2-info-rows .oms-return-info-row strong {
  color: #e5e7eb;
}

.oms-app[data-theme="dark"] .oms-return-v2-products-footer,
.oms-app[data-theme="dark"] .oms-return-v2-info-footer {
  background: #1f2937;
  border-color: #334155;
}

.oms-app[data-theme="dark"] .oms-return-v2-note,
.oms-app[data-theme="dark"] .oms-return-v2-store {
  background: #1f2937;
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-return-v2-card-head { border-color: #334155; }
.oms-app[data-theme="dark"] .oms-return-v2-amount { background: rgba(239, 68, 68, 0.14); }

/* Twarde nadpisania v2: generyczne reguly shell-a (np. `> header > div` z
   display:grid) maja wyzsza specyficznosc i rozsypywaly topbar. */
.oms-warehouse-delivery-modal-shell > header.oms-return-v2-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 26px;
  border-bottom: 1px solid var(--oms-slate-200);
}

.oms-warehouse-delivery-modal-shell > header.oms-return-v2-topbar > div.oms-return-v2-topbar-right {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
}

.oms-return-v2-panel > .oms-return-v2-title { display: block; }
.oms-return-v2-panel > section.oms-return-v2-products { display: block; }
.oms-return-v2-panel > div.oms-return-v2-columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 16px;
  align-items: start;
}

/* Panel zwrotu v2 to flex-kolumna ze scrollem - dzieci NIE moga sie kurczyc,
   inaczej karta produktow jest zgniatana do zera na nizszych ekranach
   (znikajace "Produkty w zwrocie" 09.08). */
.oms-return-v2-panel > * { flex-shrink: 0; }

/* Sekcja Zwroty na karcie zamowienia */
.oms-order-returns-card .oms-order-returns-table td { vertical-align: middle; }
.oms-order-returns-row { cursor: pointer; }
.oms-order-returns-row:hover td { background: var(--oms-slate-50); }
.oms-order-returns-number { color: var(--oms-blue-600); font-weight: 700; }
.oms-app[data-theme="dark"] .oms-order-returns-row:hover td { background: #1f2937; }

/* Numer zwrotu Allegro (np. 57KO/2026) - ten numer jest na paczce */
.oms-return-allegro-ref {
  display: inline-block;
  background: var(--oms-store-allegro-bg);
  color: var(--oms-store-allegro-fg);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
  padding: 2px 9px;
  border-radius: 999px;
  width: fit-content;
}

/* Kolejki pakowania: kolor badge'a = kolor kropki w lewym menu (PACKING_QUEUE_COLORS
   w flow-oms-preview.js). Sklep niesie kolor, przewoznik niesie nazwe. */
.oms-order-status-chip.tone-queue-allegro-inpost,
.oms-operation-chip.tone-queue-allegro-inpost { background: #fff044; color: #111827; }
.oms-order-status-chip.tone-queue-allegro-dpd,
.oms-operation-chip.tone-queue-allegro-dpd { background: #fff044; color: #111827; }
.oms-order-status-chip.tone-queue-allegro-dhl,
.oms-operation-chip.tone-queue-allegro-dhl { background: #fff044; color: #111827; }
.oms-order-status-chip.tone-queue-allegro-orlen,
.oms-operation-chip.tone-queue-allegro-orlen { background: #fff044; color: #111827; }
.oms-order-status-chip.tone-queue-allegro-paxy,
.oms-operation-chip.tone-queue-allegro-paxy { background: #fff044; color: #111827; }
.oms-order-status-chip.tone-queue-allegro-packeta,
.oms-operation-chip.tone-queue-allegro-packeta { background: #fff044; color: #111827; }
.oms-order-status-chip.tone-queue-allegro-poczta,
.oms-operation-chip.tone-queue-allegro-poczta { background: #fff044; color: #111827; }
.oms-order-status-chip.tone-queue-allegro-other,
.oms-operation-chip.tone-queue-allegro-other { background: #fff044; color: #111827; }
.oms-order-status-chip.tone-queue-allegro-to_pack,
.oms-operation-chip.tone-queue-allegro-to_pack { background: #fff044; color: #111827; }
.oms-order-status-chip.tone-queue-pl-inpost,
.oms-operation-chip.tone-queue-pl-inpost { background: #06b6d4; color: #ffffff; }
.oms-order-status-chip.tone-queue-pl-dpd,
.oms-operation-chip.tone-queue-pl-dpd { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-pl-dhl,
.oms-operation-chip.tone-queue-pl-dhl { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-pl-orlen,
.oms-operation-chip.tone-queue-pl-orlen { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-pl-paxy,
.oms-operation-chip.tone-queue-pl-paxy { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-pl-packeta,
.oms-operation-chip.tone-queue-pl-packeta { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-pl-poczta,
.oms-operation-chip.tone-queue-pl-poczta { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-pl-other,
.oms-operation-chip.tone-queue-pl-other { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-pl-to_pack,
.oms-operation-chip.tone-queue-pl-to_pack { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-bt-inpost,
.oms-operation-chip.tone-queue-bt-inpost { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-bt-dpd,
.oms-operation-chip.tone-queue-bt-dpd { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-bt-dhl,
.oms-operation-chip.tone-queue-bt-dhl { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-bt-orlen,
.oms-operation-chip.tone-queue-bt-orlen { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-bt-paxy,
.oms-operation-chip.tone-queue-bt-paxy { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-bt-packeta,
.oms-operation-chip.tone-queue-bt-packeta { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-bt-poczta,
.oms-operation-chip.tone-queue-bt-poczta { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-bt-other,
.oms-operation-chip.tone-queue-bt-other { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-bt-to_pack,
.oms-operation-chip.tone-queue-bt-to_pack { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-hp-inpost,
.oms-operation-chip.tone-queue-hp-inpost { background: #111827; color: #ffffff; }
.oms-order-status-chip.tone-queue-hp-dpd,
.oms-operation-chip.tone-queue-hp-dpd { background: #111827; color: #ffffff; }
.oms-order-status-chip.tone-queue-hp-dhl,
.oms-operation-chip.tone-queue-hp-dhl { background: #111827; color: #ffffff; }
.oms-order-status-chip.tone-queue-hp-orlen,
.oms-operation-chip.tone-queue-hp-orlen { background: #111827; color: #ffffff; }
.oms-order-status-chip.tone-queue-hp-paxy,
.oms-operation-chip.tone-queue-hp-paxy { background: #111827; color: #ffffff; }
.oms-order-status-chip.tone-queue-hp-packeta,
.oms-operation-chip.tone-queue-hp-packeta { background: #111827; color: #ffffff; }
.oms-order-status-chip.tone-queue-hp-poczta,
.oms-operation-chip.tone-queue-hp-poczta { background: #111827; color: #ffffff; }
.oms-order-status-chip.tone-queue-hp-other,
.oms-operation-chip.tone-queue-hp-other { background: #111827; color: #ffffff; }
.oms-order-status-chip.tone-queue-hp-to_pack,
.oms-operation-chip.tone-queue-hp-to_pack { background: #111827; color: #ffffff; }
.oms-order-status-chip.tone-queue-cz-inpost,
.oms-operation-chip.tone-queue-cz-inpost { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-cz-dpd,
.oms-operation-chip.tone-queue-cz-dpd { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-cz-dhl,
.oms-operation-chip.tone-queue-cz-dhl { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-cz-orlen,
.oms-operation-chip.tone-queue-cz-orlen { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-cz-paxy,
.oms-operation-chip.tone-queue-cz-paxy { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-cz-packeta,
.oms-operation-chip.tone-queue-cz-packeta { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-cz-poczta,
.oms-operation-chip.tone-queue-cz-poczta { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-cz-other,
.oms-operation-chip.tone-queue-cz-other { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-cz-to_pack,
.oms-operation-chip.tone-queue-cz-to_pack { background: #ec4899; color: #ffffff; }
.oms-order-status-chip.tone-queue-tlk-inpost,
.oms-operation-chip.tone-queue-tlk-inpost { background: #22c55e; color: #ffffff; }
.oms-order-status-chip.tone-queue-tlk-dpd,
.oms-operation-chip.tone-queue-tlk-dpd { background: #22c55e; color: #ffffff; }
.oms-order-status-chip.tone-queue-tlk-dhl,
.oms-operation-chip.tone-queue-tlk-dhl { background: #22c55e; color: #ffffff; }
.oms-order-status-chip.tone-queue-tlk-orlen,
.oms-operation-chip.tone-queue-tlk-orlen { background: #22c55e; color: #ffffff; }
.oms-order-status-chip.tone-queue-tlk-paxy,
.oms-operation-chip.tone-queue-tlk-paxy { background: #22c55e; color: #ffffff; }
.oms-order-status-chip.tone-queue-tlk-packeta,
.oms-operation-chip.tone-queue-tlk-packeta { background: #22c55e; color: #ffffff; }
.oms-order-status-chip.tone-queue-tlk-poczta,
.oms-operation-chip.tone-queue-tlk-poczta { background: #22c55e; color: #ffffff; }
.oms-order-status-chip.tone-queue-tlk-other,
.oms-operation-chip.tone-queue-tlk-other { background: #22c55e; color: #ffffff; }
.oms-order-status-chip.tone-queue-tlk-to_pack,
.oms-operation-chip.tone-queue-tlk-to_pack { background: #22c55e; color: #ffffff; }
.oms-order-status-chip.tone-queue-tut-inpost,
.oms-operation-chip.tone-queue-tut-inpost { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-tut-dpd,
.oms-operation-chip.tone-queue-tut-dpd { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-tut-dhl,
.oms-operation-chip.tone-queue-tut-dhl { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-tut-orlen,
.oms-operation-chip.tone-queue-tut-orlen { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-tut-paxy,
.oms-operation-chip.tone-queue-tut-paxy { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-tut-packeta,
.oms-operation-chip.tone-queue-tut-packeta { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-tut-poczta,
.oms-operation-chip.tone-queue-tut-poczta { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-tut-other,
.oms-operation-chip.tone-queue-tut-other { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-tut-to_pack,
.oms-operation-chip.tone-queue-tut-to_pack { background: #8b5cf6; color: #ffffff; }
.oms-order-status-chip.tone-queue-sk-inpost,
.oms-operation-chip.tone-queue-sk-inpost { background: #3b82f6; color: #ffffff; }
.oms-order-status-chip.tone-queue-sk-dpd,
.oms-operation-chip.tone-queue-sk-dpd { background: #3b82f6; color: #ffffff; }
.oms-order-status-chip.tone-queue-sk-dhl,
.oms-operation-chip.tone-queue-sk-dhl { background: #3b82f6; color: #ffffff; }
.oms-order-status-chip.tone-queue-sk-orlen,
.oms-operation-chip.tone-queue-sk-orlen { background: #3b82f6; color: #ffffff; }
.oms-order-status-chip.tone-queue-sk-paxy,
.oms-operation-chip.tone-queue-sk-paxy { background: #3b82f6; color: #ffffff; }
.oms-order-status-chip.tone-queue-sk-packeta,
.oms-operation-chip.tone-queue-sk-packeta { background: #3b82f6; color: #ffffff; }
.oms-order-status-chip.tone-queue-sk-poczta,
.oms-operation-chip.tone-queue-sk-poczta { background: #3b82f6; color: #ffffff; }
.oms-order-status-chip.tone-queue-sk-other,
.oms-operation-chip.tone-queue-sk-other { background: #3b82f6; color: #ffffff; }
.oms-order-status-chip.tone-queue-sk-to_pack,
.oms-operation-chip.tone-queue-sk-to_pack { background: #3b82f6; color: #ffffff; }
.oms-order-status-chip.tone-queue-lt-inpost,
.oms-operation-chip.tone-queue-lt-inpost { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-lt-dpd,
.oms-operation-chip.tone-queue-lt-dpd { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-lt-dhl,
.oms-operation-chip.tone-queue-lt-dhl { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-lt-orlen,
.oms-operation-chip.tone-queue-lt-orlen { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-lt-paxy,
.oms-operation-chip.tone-queue-lt-paxy { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-lt-packeta,
.oms-operation-chip.tone-queue-lt-packeta { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-lt-poczta,
.oms-operation-chip.tone-queue-lt-poczta { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-lt-other,
.oms-operation-chip.tone-queue-lt-other { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-lt-to_pack,
.oms-operation-chip.tone-queue-lt-to_pack { background: #f97316; color: #ffffff; }
.oms-order-status-chip.tone-queue-hu-inpost,
.oms-operation-chip.tone-queue-hu-inpost { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-hu-dpd,
.oms-operation-chip.tone-queue-hu-dpd { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-hu-dhl,
.oms-operation-chip.tone-queue-hu-dhl { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-hu-orlen,
.oms-operation-chip.tone-queue-hu-orlen { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-hu-paxy,
.oms-operation-chip.tone-queue-hu-paxy { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-hu-packeta,
.oms-operation-chip.tone-queue-hu-packeta { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-hu-poczta,
.oms-operation-chip.tone-queue-hu-poczta { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-hu-other,
.oms-operation-chip.tone-queue-hu-other { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-hu-to_pack,
.oms-operation-chip.tone-queue-hu-to_pack { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-ro-inpost,
.oms-operation-chip.tone-queue-ro-inpost { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-ro-dpd,
.oms-operation-chip.tone-queue-ro-dpd { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-ro-dhl,
.oms-operation-chip.tone-queue-ro-dhl { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-ro-orlen,
.oms-operation-chip.tone-queue-ro-orlen { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-ro-paxy,
.oms-operation-chip.tone-queue-ro-paxy { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-ro-packeta,
.oms-operation-chip.tone-queue-ro-packeta { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-ro-poczta,
.oms-operation-chip.tone-queue-ro-poczta { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-ro-other,
.oms-operation-chip.tone-queue-ro-other { background: #64748b; color: #ffffff; }
.oms-order-status-chip.tone-queue-ro-to_pack,
.oms-operation-chip.tone-queue-ro-to_pack { background: #64748b; color: #ffffff; }

/* "Brak info" - kolor jak kropka w lewym menu (.oms-dot-purple) */
.oms-order-status-chip.tone-no-info,
.oms-operation-chip.tone-no-info { background: #8b5cf6; color: #ffffff; }
/* "Zagubione" - paczka zgubiona u przewoznika, kolor jak kropka .oms-dot-lost */
.oms-order-status-chip.tone-lost,
.oms-operation-chip.tone-lost { background: #b91c1c; color: #ffffff; }

/* Historia automatu na karcie zwrotu */
.oms-return-auto-card {
  margin: 6px 18px 12px;
  border: 1px solid var(--oms-slate-100);
  border-radius: 12px;
  background: var(--oms-slate-50);
  overflow: hidden;
}

.oms-return-auto-head {
  padding: 9px 14px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--oms-slate-500);
  border-bottom: 1px solid var(--oms-slate-100);
}

.oms-return-auto-step {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 14px;
  border-bottom: 1px solid var(--oms-slate-100);
  font-size: 12.5px;
}

.oms-return-auto-step:last-child { border-bottom: none; }

.oms-return-auto-icon {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 11px;
  font-weight: 800;
  flex: none;
  margin-top: 1px;
}

.oms-return-auto-step.is-ok .oms-return-auto-icon { background: var(--oms-green-50); color: var(--oms-green-600); }
.oms-return-auto-step.is-warn .oms-return-auto-icon { background: #fef9c3; color: #a16207; }
.oms-return-auto-step.is-bad .oms-return-auto-icon { background: #fef2f2; color: var(--oms-red-500); }
.oms-return-auto-step.is-muted .oms-return-auto-icon { background: var(--oms-slate-100); color: var(--oms-slate-500); }

.oms-return-auto-main { flex: 1; min-width: 0; }
.oms-return-auto-main strong { display: block; color: var(--oms-slate-900); font-weight: 600; }
.oms-return-auto-main span { display: block; color: var(--oms-slate-500); font-size: 11.5px; margin-top: 1px; word-break: break-word; }
.oms-return-auto-step time { flex: none; font-size: 11px; color: var(--oms-slate-400); white-space: nowrap; margin-top: 2px; }

.oms-app[data-theme="dark"] .oms-return-auto-card { background: #1f2937; border-color: #334155; }
.oms-app[data-theme="dark"] .oms-return-auto-head,
.oms-app[data-theme="dark"] .oms-return-auto-step { border-color: #334155; }
.oms-app[data-theme="dark"] .oms-return-auto-main strong { color: #e5e7eb; }

/* Selecty i inputy karty zwrotu w stylu panelu (natywne byly waskie i gole) */
.oms-return-v2 .oms-return-detail-items-table select,
.oms-return-v2 .oms-return-decision-field select {
  appearance: none;
  -webkit-appearance: none;
  height: 40px;
  min-width: 150px;
  padding: 0 36px 0 14px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  background-color: #ffffff;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  font-size: 13px;
  font-weight: 600;
  color: var(--oms-slate-900);
  cursor: pointer;
}

.oms-return-v2 .oms-return-detail-items-table select:hover,
.oms-return-v2 .oms-return-decision-field select:hover {
  border-color: var(--oms-slate-300);
}

.oms-return-v2 .oms-return-detail-items-table select:focus,
.oms-return-v2 .oms-return-decision-field select:focus {
  outline: none;
  border-color: var(--oms-blue-500);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.oms-return-v2 .oms-return-decision-field select { width: 100%; }

.oms-return-v2 .oms-return-detail-items-table input[type="number"] {
  height: 40px;
  width: 74px;
  padding: 0 6px 0 12px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  color: var(--oms-slate-900);
  text-align: center;
}

.oms-return-v2 .oms-return-detail-items-table input[type="text"] {
  height: 40px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  padding: 0 12px;
  font-size: 13px;
}

.oms-return-v2 .oms-return-decision-field input[type="text"] {
  height: 40px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  padding: 0 12px;
  font-size: 13px;
  width: 100%;
}

/* Akcje w topbarze - zawsze widoczne bez scrolla */
.oms-return-v2-topbar-right .oms-btn-light { white-space: nowrap; }

@media (max-width: 1250px) {
  .oms-return-v2-topbar { flex-wrap: wrap; }
  .oms-return-v2-topbar-right { flex-wrap: wrap; justify-content: flex-end; }
}

.oms-app[data-theme="dark"] .oms-return-v2 .oms-return-detail-items-table select,
.oms-app[data-theme="dark"] .oms-return-v2 .oms-return-decision-field select,
.oms-app[data-theme="dark"] .oms-return-v2 .oms-return-detail-items-table input[type="number"],
.oms-app[data-theme="dark"] .oms-return-v2 .oms-return-detail-items-table input[type="text"],
.oms-app[data-theme="dark"] .oms-return-v2 .oms-return-decision-field input[type="text"] {
  background-color: #1f2937;
  border-color: #334155;
  color: #e5e7eb;
}

/* Kolejka "Do zwrotu kasy": badge listy + guzik karty */
.oms-return-money-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.02em;
  padding: 3px 10px;
  border-radius: 999px;
}

.oms-btn-light.money-paid {
  background: #ecfdf5;
  border-color: #6ee7b7;
  color: #047857;
  font-weight: 700;
}
.oms-btn-light.money-paid:hover:not(:disabled) {
  background: #d1fae5;
  border-color: #34d399;
}

.oms-app[data-theme="dark"] .oms-return-money-badge {
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
  border-color: rgba(239, 68, 68, 0.35);
}
.oms-app[data-theme="dark"] .oms-btn-light.money-paid {
  background: rgba(16, 185, 129, 0.16);
  color: #6ee7b7;
  border-color: rgba(16, 185, 129, 0.35);
}

/* Akcja zbiorcza zwrotow */
.oms-checkbox.checked {
  background: var(--oms-blue-600);
  border-color: var(--oms-blue-600);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 900;
}
.oms-returns-row.is-selected > td { background: var(--oms-blue-50); }
.oms-returns-bulkbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  background: var(--oms-blue-50);
  border: 1px solid #bfdbfe;
  border-radius: 999px;
}
.oms-returns-bulk-count { font-size: 13px; color: var(--oms-slate-700); }
.oms-returns-toolgroup button[data-return-select-all] {
  font-size: 16px;
  cursor: pointer;
}
.oms-app[data-theme="dark"] .oms-returns-row.is-selected > td { background: rgba(59,130,246,0.14); }
.oms-app[data-theme="dark"] .oms-returns-bulkbar { background: rgba(59,130,246,0.14); border-color: rgba(59,130,246,0.4); }

/* Asystent zwrotow nieodebranych - tryb sesji */
.oms-station-modes { display: flex; gap: 8px; margin-bottom: 10px; }
.oms-station-mode {
  border: 1px solid var(--oms-slate-200);
  background: #fff;
  color: var(--oms-slate-600);
  font-size: 13px;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
}
.oms-station-mode.active {
  background: var(--oms-blue-600);
  border-color: var(--oms-blue-600);
  color: #fff;
}
.oms-station.is-nieodebrane { border-color: #bfdbfe; }
.oms-station-nieodebrane-empty {
  padding: 14px 16px;
  color: var(--oms-slate-500);
  font-size: 13px;
  background: var(--oms-slate-50);
  border-radius: 12px;
}
.oms-station-nieodebrane-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 4px 12px;
  flex-wrap: wrap;
}
.oms-station-nieodebrane-head > div { display: flex; gap: 8px; }
.oms-station-nieodebrane-list { display: flex; flex-direction: column; gap: 6px; }
.oms-station-nieodebrane-row {
  display: grid;
  grid-template-columns: minmax(90px, 160px) minmax(0, 1fr) auto 28px;
  align-items: center;
  gap: 12px;
  padding: 9px 12px;
  background: #fff;
  border: 1px solid var(--oms-slate-100);
  border-radius: 10px;
  font-size: 13px;
}
.oms-station-nieodebrane-num { font-weight: 800; color: var(--oms-slate-900); }
.oms-station-nieodebrane-name { color: var(--oms-slate-700); }
.oms-station-nieodebrane-store { color: var(--oms-slate-400); font-size: 11px; }
.oms-station-nieodebrane-remove {
  border: none; background: transparent; color: var(--oms-slate-400);
  font-size: 15px; cursor: pointer;
}
.oms-station-nieodebrane-remove:hover { color: var(--oms-red-500); }
.oms-app[data-theme="dark"] .oms-station-mode { background: #1f2937; border-color: #334155; color: #cbd5e1; }
.oms-app[data-theme="dark"] .oms-station-nieodebrane-row { background: #172033; border-color: #334155; }
.oms-app[data-theme="dark"] .oms-station-nieodebrane-empty { background: #1f2937; }

/* Ostrzezenie przy sklepie, ktorego zysk jest zawyzony przez brak kosztu.
   Ma byc widoczne przy liczbie, nie schowane w osobnym panelu. */
.oms-profiter-source-problem {
  display: block;
  margin-top: 2px;
  font-style: normal;
  font-size: 11px;
  font-weight: 600;
  color: #b42318;
}
.oms-profiter-source.negative .oms-profiter-source-problem,
.oms-profiter-source.positive .oms-profiter-source-problem { color: #b42318; }

/* Naprawa brakow kosztu w widoku dnia */
.oms-braki-naprawa { margin-top: 12px; padding: 12px; border: 1px solid #f0c4bf; border-radius: 10px; background: #fff7f6; }
.oms-braki-naglowek { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.oms-braki-naglowek strong { color: #b42318; font-size: 13px; }
.oms-braki-naglowek small { color: #7a5c58; font-size: 11px; }
.oms-braki-lista { display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow-y: auto; }
.oms-brak-wiersz { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; padding: 6px 8px; background: #fff; border: 1px solid #efe0de; border-radius: 8px; }
.oms-brak-opis { min-width: 0; }
.oms-brak-opis strong { display: block; font-size: 12px; color: #1f2937; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.oms-brak-opis span { font-size: 11px; color: #6b7280; }
.oms-brak-wiersz input { width: 110px; padding: 5px 8px; border: 1px solid #d5d7da; border-radius: 6px; font-size: 12px; }
.oms-braki-stopka { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.oms-braki-stopka span { font-size: 11px; color: #6b7280; }

/* Ostrzezenie o brakach na kaflu sklepu - musi byc widoczne tam, gdzie
   patrzy sie na wynik, a nie tylko na liscie zrodel nizej. */
.oms-p2-store-mini .oms-store-mini-problem {
  display: block; margin-top: 3px; font-style: normal;
  font-size: 10px; font-weight: 700; color: #b42318; line-height: 1.2;
}
.oms-profiter-pill.klikalna { cursor: pointer; }
.oms-profiter-pill.klikalna:hover { filter: brightness(0.97); }

/* Przelacznik zakresu przy podsumowaniu miesiaca */
.oms-zakres-przelacznik { display: flex; gap: 6px; margin-left: auto; }
.oms-zakres-przelacznik button {
  padding: 5px 12px; font-size: 12px; font-weight: 600; cursor: pointer;
  border: 1px solid #d5d7da; border-radius: 999px; background: #fff; color: #414651;
}
.oms-zakres-przelacznik button:hover { background: #f5f5f5; }
.oms-zakres-przelacznik button.aktywny { background: #1f2937; color: #fff; border-color: #1f2937; }
.oms-zakres-wynik { margin-top: 12px; padding: 12px; border: 1px solid #e9eaeb; border-radius: 10px; background: #fafafa; }
.oms-zakres-naglowek { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; flex-wrap: wrap; gap: 6px; }
.oms-zakres-naglowek strong { font-size: 15px; }
.oms-zakres-naglowek small { color: #6b7280; font-size: 11px; }
.oms-zakres-kpi { display: flex; gap: 18px; flex-wrap: wrap; margin-bottom: 10px; }
.oms-zakres-kpi div { font-size: 12px; color: #6b7280; }
.oms-zakres-kpi div b { display: block; font-size: 15px; color: #1f2937; }
.oms-zakres-tabela { width: 100%; border-collapse: collapse; font-size: 12px; }
.oms-zakres-tabela th { text-align: left; color: #6b7280; font-weight: 600; padding: 4px 6px; border-bottom: 1px solid #e9eaeb; }
.oms-zakres-tabela td { padding: 4px 6px; border-bottom: 1px solid #f2f2f2; }
.oms-zakres-tabela td.num { text-align: right; font-variant-numeric: tabular-nums; }
.oms-zakres-tabela tr.slaby td { color: #b42318; }
.oms-zakres-ostrzezenie { margin-top: 8px; font-size: 11px; color: #b42318; }

/* Przeliczanie zakresu dni od nowa */
.oms-przelicz-zakres { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 10px 0 4px; font-size: 12px; color: #414651; }
.oms-przelicz-zakres input[type="date"] { padding: 5px 8px; border: 1px solid #d5d7da; border-radius: 6px; font-size: 12px; }
.oms-przelicz-zakres #omsPrzeliczStatus { color: #6b7280; font-size: 11px; }
.oms-przelicz-zakres #omsPrzeliczStatus.pracuje { color: #b54708; font-weight: 600; }
.oms-przelicz-zakres #omsPrzeliczStatus.gotowe { color: #067647; font-weight: 600; }

/* Przelacznik trybu dzien/zakres w naglowku Profitera */
.oms-p2-tryb { display: inline-flex; gap: 2px; padding: 2px; background: #f0f1f3; border-radius: 999px; }
.oms-p2-tryb button {
  padding: 6px 16px; font-size: 12px; font-weight: 600; cursor: pointer;
  border: none; border-radius: 999px; background: transparent; color: #6b7280;
}
.oms-p2-tryb button.aktywny { background: #fff; color: #1f2937; box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.oms-zakres-szybki {
  padding: 4px 10px; font-size: 11px; font-weight: 600; cursor: pointer;
  border: 1px solid #d5d7da; border-radius: 999px; background: #fff; color: #414651;
}
.oms-zakres-szybki:hover { background: #f5f5f5; }

/* [hidden] przegrywa ze specyficznoscia .oms-p2-date-field { display:flex },
   wiec oba pola dat pokazywaly sie naraz. */
#omsPoleDnia[hidden],
#omsPoleZakresu[hidden] { display: none !important; }

/* Pole zakresu ma byc zwarte - dwie daty i skroty w jednej linii. */
#omsPoleZakresu { gap: 6px; flex-wrap: nowrap; }
#omsPoleZakresu span { font-size: 12px; color: #6b7280; white-space: nowrap; }
#omsPoleZakresu input[type="date"] { min-width: 132px; }
#omsPoleZakresu .oms-zakres-szybki { flex: none; margin-left: 2px; }
.oms-p2-tryb { flex: none; }
.oms-p2-actions { flex-wrap: wrap; gap: 8px; align-items: center; }


/* ── Edytor pozycji zwrotu (13.08.2026) ───────────────────────────────────
   Jeden sterownik ilosci na wiersz zamiast luznych pastylek: stepper
   [-][n][+] plus kontekstowy przelacznik "nie wrocilo"/"wrocilo cale".
   Kosz pokazuje sie na hover wiersza, zeby tabela zostala spokojna. */

.oms-return-detail-items-table th:last-child,
.oms-return-detail-items-table td.oms-return-detail-rowactions {
  width: 44px;
  padding-left: 0;
  padding-right: 14px;
}

.oms-return-qty-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 118px;
}

.oms-return-qty-stepper {
  display: inline-flex;
  align-items: stretch;
  border: 1px solid #d6e1ef;
  border-radius: 10px;
  background: #ffffff;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.oms-return-qty-stepper button {
  width: 32px;
  border: 0;
  background: #f8fafc;
  color: #475569;
  font-size: 16px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  transition: background 0.12s ease, color 0.12s ease;
}

.oms-return-qty-stepper button:hover:not(:disabled) {
  background: #ede9fe;
  color: #6d28d9;
}

.oms-return-qty-stepper button:disabled {
  color: #cbd5e1;
  cursor: not-allowed;
}

.oms-return-v2 .oms-return-detail-items-table .oms-return-qty-stepper .oms-return-detail-qty {
  width: 52px;
  min-height: 38px;
  border: 0;
  border-left: 1px solid #eef2f7;
  border-right: 1px solid #eef2f7;
  border-radius: 0;
  padding: 0;
  text-align: center;
  font-size: 15px;
  font-weight: 850;
  -moz-appearance: textfield;
}

.oms-return-v2 .oms-return-qty-stepper .oms-return-detail-qty::-webkit-outer-spin-button,
.oms-return-v2 .oms-return-qty-stepper .oms-return-detail-qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.oms-return-qty-stepper:focus-within {
  border-color: #7c3aed;
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
}

.oms-return-v2 .oms-return-detail-items-table .oms-return-qty-stepper .oms-return-detail-qty:focus {
  box-shadow: none;
  outline: 0;
}

.oms-return-qty-toggle {
  border: 0;
  background: none;
  padding: 0;
  color: #94a3b8;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: lowercase;
  white-space: nowrap;
  cursor: pointer;
  border-bottom: 1px dashed transparent;
}

.oms-return-qty-toggle:hover {
  color: #6d28d9;
  border-bottom-color: #c4b5fd;
}

.oms-return-detail-line.is-excluded {
  background: #fbfcfe;
}

.oms-return-detail-line.is-excluded .oms-return-detail-thumb,
.oms-return-detail-line.is-excluded .oms-return-detail-product,
.oms-return-detail-line.is-excluded .oms-return-detail-number,
.oms-return-detail-line.is-excluded select,
.oms-return-detail-line.is-excluded .oms-return-detail-note {
  opacity: 0.45;
}

.oms-return-detail-line.is-excluded .oms-return-detail-product strong {
  text-decoration: line-through;
  text-decoration-color: #cbd5e1;
}

.oms-return-detail-line.is-excluded .oms-return-qty-toggle {
  color: #7c3aed;
}

.oms-return-detail-line.is-manual .oms-return-detail-number {
  color: #7c3aed;
  font-weight: 900;
}

.oms-return-line-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #cbd5e1;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.12s ease, background 0.12s ease, color 0.12s ease;
}

.oms-return-detail-line:hover .oms-return-line-remove,
.oms-return-line-remove:focus-visible {
  opacity: 1;
}

.oms-return-line-remove:hover {
  background: #fef2f2;
  color: #dc2626;
}

/* Panel dopisywania pozycji spoza zamowienia */
.oms-return-add-line {
  padding: 14px 18px 16px;
  border-top: 1px solid var(--oms-slate-100);
  background: #fbfcfe;
}

.oms-return-add-line input {
  width: 100%;
  min-height: 42px;
  border: 1px solid #d6e1ef;
  border-radius: 10px;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 700;
  background: #ffffff;
}

.oms-return-add-line input:focus {
  border-color: #7c3aed;
  outline: 0;
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
}

.oms-return-add-results {
  display: grid;
  gap: 6px;
  margin-top: 10px;
  max-height: 220px;
  overflow-y: auto;
}

.oms-return-add-results button {
  display: flex;
  flex-direction: column;
  gap: 3px;
  text-align: left;
  border: 1px solid #e6edf6;
  background: #ffffff;
  border-radius: 10px;
  padding: 9px 12px;
  cursor: pointer;
  transition: border-color 0.12s ease, background 0.12s ease;
}

.oms-return-add-results button:hover {
  border-color: #c4b5fd;
  background: #faf9ff;
}

.oms-return-add-results strong {
  font-size: 13px;
  font-weight: 800;
  color: #111827;
}

.oms-return-add-results span {
  font-size: 11px;
  color: #64748b;
  font-weight: 750;
}

.oms-return-add-empty {
  margin-top: 10px;
  font-size: 12px;
  color: #64748b;
  font-weight: 750;
}

/* Stopka karty produktow */
.oms-return-footer-left,
.oms-return-footer-right {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.oms-return-footer-right {
  flex: none;
  gap: 10px;
}

.oms-return-add-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px dashed #c7d2e5;
  background: #ffffff;
  color: #475569;
  border-radius: 10px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color 0.12s ease, color 0.12s ease, background 0.12s ease;
}

.oms-return-add-btn span {
  font-size: 15px;
  line-height: 1;
  font-weight: 900;
}

.oms-return-add-btn:hover {
  border-color: #a78bfa;
  color: #6d28d9;
  background: #faf9ff;
}

.oms-return-dirty-flag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 850;
  color: #b45309;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 999px;
  padding: 4px 10px;
  white-space: nowrap;
}

.oms-return-dirty-flag[hidden] {
  display: none;
}

[data-return-save-btn].is-dirty {
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.18);
}

.oms-return-money-input input.is-over {
  border-color: #f59e0b;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.12);
}

@media (max-width: 1180px) {
  .oms-return-footer-left { flex-wrap: wrap; }
  .oms-return-v2-products-footer { align-items: flex-start; }
}

/* Pasek akcji karty zwrotu: rowne wysokosci i wyrazny podzial akcje | status */
.oms-return-v2-topbar-right > .oms-btn-light {
  min-height: 36px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 800;
  padding: 0 14px;
}

.oms-return-v2-topbar-right .oms-return-v2-ret {
  margin-left: 6px;
  position: relative;
}

.oms-return-v2-topbar-right .oms-return-v2-ret::before {
  content: "";
  position: absolute;
  left: -10px;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 22px;
  background: var(--oms-slate-200);
}

.oms-return-v2-back { font-weight: 700; }

/* Dark mode dla nowych elementow edytora pozycji */
.oms-app[data-theme="dark"] .oms-return-qty-stepper {
  background: #1f2937;
  border-color: #334155;
  box-shadow: none;
}

.oms-app[data-theme="dark"] .oms-return-qty-stepper button {
  background: #172033;
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-return-qty-stepper button:hover:not(:disabled) {
  background: #312e81;
  color: #ddd6fe;
}

.oms-app[data-theme="dark"] .oms-return-v2 .oms-return-detail-items-table .oms-return-qty-stepper .oms-return-detail-qty {
  background: #1f2937;
  color: #e5e7eb;
  border-color: #334155;
}

.oms-app[data-theme="dark"] .oms-return-detail-line.is-excluded {
  background: #141c2c;
}

.oms-app[data-theme="dark"] .oms-return-add-line,
.oms-app[data-theme="dark"] .oms-return-add-results button {
  background: #172033;
  border-color: #334155;
}

.oms-app[data-theme="dark"] .oms-return-add-line input {
  background: #1f2937;
  border-color: #334155;
  color: #e5e7eb;
}

.oms-app[data-theme="dark"] .oms-return-add-results strong { color: #e5e7eb; }

.oms-app[data-theme="dark"] .oms-return-add-btn {
  background: #172033;
  border-color: #3b4a63;
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-return-line-remove:hover {
  background: #3f1d1d;
  color: #fca5a5;
}

/* Panel dopisywania pozycji: waska kolumna zamiast pasa przez cala szerokosc */
.oms-return-add-line {
  max-width: 560px;
}

.oms-return-add-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.oms-return-add-head strong {
  display: block;
  font-size: 13px;
  font-weight: 850;
  color: #111827;
}

.oms-return-add-head span {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
}

.oms-return-add-close {
  border: 0;
  background: transparent;
  color: #94a3b8;
  font-size: 13px;
  line-height: 1;
  padding: 4px;
  cursor: pointer;
  border-radius: 6px;
}

.oms-return-add-close:hover {
  background: #eef2f7;
  color: #475569;
}

.oms-app[data-theme="dark"] .oms-return-add-head strong { color: #e5e7eb; }

/* ── Status zwrotu i kasowanie zwrotow (13.08.2026) ───────────────────────
   Pastylka statusu na liscie dziala jak flaga statusu zamowienia: klik
   otwiera liste, wybor zapisuje sie od razu. */
.oms-return-status-picker {
  position: relative;
  display: inline-flex;
}

.oms-return-status-trigger {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 0;
  cursor: pointer;
  font: inherit;
}

.oms-return-status-trigger i {
  font-style: normal;
  font-size: 10px;
  opacity: 0.6;
}

.oms-return-status-trigger:hover i { opacity: 1; }

.oms-return-status-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 40;
  display: grid;
  gap: 2px;
  min-width: 268px;
  padding: 6px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.16);
}

.oms-return-status-option {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  border: 0;
  background: transparent;
  border-radius: 8px;
  padding: 7px 9px;
  text-align: left;
  cursor: pointer;
}

.oms-return-status-option:hover { background: #f5f3ff; }
.oms-return-status-option.is-active { background: #eef2ff; }

.oms-return-status-option strong {
  display: block;
  font-size: 13px;
  font-weight: 800;
  color: #111827;
}

.oms-return-status-option small {
  display: block;
  font-size: 11px;
  font-weight: 650;
  color: #64748b;
}

.oms-returns-status.is-cancelled {
  background: #f1f5f9;
  color: #64748b;
}

.oms-returns-date-cell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.oms-return-row-delete {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #cbd5e1;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.12s ease, background 0.12s ease, color 0.12s ease;
}

.oms-returns-row:hover .oms-return-row-delete,
.oms-return-row-delete:focus-visible { opacity: 1; }

.oms-return-row-delete:hover {
  background: #fef2f2;
  color: #dc2626;
}

.oms-returns-bulk-status {
  display: inline-flex;
  gap: 6px;
  flex-wrap: wrap;
}

.oms-returns-bulk-status .oms-btn-light {
  padding: 6px 12px;
  font-size: 12px;
}

.oms-btn-light.danger {
  border-color: #fecaca;
  color: #b91c1c;
}

.oms-btn-light.danger:hover {
  background: #fef2f2;
  border-color: #f87171;
}

/* Karta zwrotu: status jako select + kosz obok zamkniecia */
.oms-return-card-status {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.oms-return-card-status select {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.oms-return-v2-delete {
  border: 0;
  background: transparent;
  color: #94a3b8;
  font-size: 15px;
  line-height: 1;
  padding: 6px 8px;
  border-radius: 8px;
  cursor: pointer;
}

.oms-return-v2-delete:hover {
  background: #fef2f2;
  color: #dc2626;
}

.oms-app[data-theme="dark"] .oms-return-status-menu {
  background: #172033;
  border-color: #334155;
}

.oms-app[data-theme="dark"] .oms-return-status-option strong { color: #e5e7eb; }
.oms-app[data-theme="dark"] .oms-return-status-option:hover { background: #1f2937; }

/* Warehouse v2 - operator UI, canonical OMS main */
.oms-warehouse-v2-view {
  --wh-bg: #f3f6fb;
  --wh-surface: #ffffff;
  --wh-surface-soft: #f8fafc;
  --wh-text: #10213a;
  --wh-muted: #68778e;
  --wh-border: #e2e8f1;
  --wh-accent: #465cf5;
  --wh-accent-soft: #eef0ff;
  --wh-green: #18a676;
  --wh-orange: #f29438;
  --wh-shadow: 0 14px 38px rgba(25, 42, 70, 0.07);
  background:
    radial-gradient(circle at 82% 2%, rgba(70, 92, 245, 0.08), transparent 30%),
    var(--wh-bg);
}

.oms-warehouse-v2-view .oms-analytics-top {
  padding-bottom: 12px;
}

.oms-warehouse-v2-view .oms-analytics-title {
  color: var(--wh-text);
  letter-spacing: -0.035em;
}

.oms-warehouse-v2-view .oms-control-content {
  display: grid;
  gap: 18px;
  padding-top: 4px;
}

.oms-warehouse-v2-view #omsWarehouseProductsGrid,
.oms-warehouse-v2-view #omsWarehouseDeliveriesGrid,
.oms-warehouse-v2-view #omsWarehouseInventoriesGrid,
.oms-warehouse-v2-view #omsWarehouseDocumentDraftsGrid {
  min-width: 0;
  margin: 0;
}

.oms-warehouse-v2-view #omsWarehouseProductsGrid > .oms-warehouse-v2 {
  grid-column: 1 / -1;
}

.oms-warehouse-v2 {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.oms-warehouse-v2 .oms-warehouse-tabs {
  display: inline-flex;
  width: max-content;
  max-width: 100%;
  min-height: 46px;
  gap: 4px;
  overflow-x: auto;
  border: 1px solid var(--wh-border);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.86);
  padding: 5px;
  box-shadow: 0 8px 24px rgba(25, 42, 70, 0.05);
  backdrop-filter: blur(12px);
}

.oms-warehouse-v2 .oms-warehouse-tabs button {
  height: 34px;
  min-width: max-content;
  border: 0;
  border-radius: 10px;
  padding: 0 15px;
  color: var(--wh-muted);
  font-size: 13px;
  font-weight: 850;
  transition: background 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.oms-warehouse-v2 .oms-warehouse-tabs button:hover {
  background: var(--wh-surface-soft);
  color: var(--wh-text);
}

.oms-warehouse-v2 .oms-warehouse-tabs button.active {
  border: 0;
  background: var(--wh-text);
  color: #ffffff;
  box-shadow: 0 7px 16px rgba(16, 33, 58, 0.18);
}

.oms-warehouse-sourcebar {
  position: relative;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 72px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background:
    radial-gradient(circle at 82% 10%, rgba(112, 130, 255, 0.34), transparent 26%),
    linear-gradient(120deg, #111d34 0%, #172642 58%, #293b71 100%);
  padding: 13px 18px;
  color: #ffffff;
  box-shadow: 0 16px 34px rgba(17, 29, 52, 0.16);
}

.oms-warehouse-sourcebar-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.12);
  font-size: 15px;
  font-weight: 950;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.oms-warehouse-sourcebar > div:nth-child(2) {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.oms-warehouse-sourcebar strong {
  font-size: 14px;
  font-weight: 950;
  letter-spacing: -0.01em;
}

.oms-warehouse-sourcebar span,
.oms-warehouse-sourcebar small {
  color: #bdc8df;
  font-size: 11px;
  font-weight: 750;
}

.oms-warehouse-sourcebar small {
  justify-self: end;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  padding: 6px 10px;
  white-space: nowrap;
}

.oms-warehouse-kpis {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.oms-warehouse-kpis button {
  position: relative;
  display: grid;
  gap: 2px;
  min-width: 0;
  min-height: 116px;
  overflow: hidden;
  border: 1px solid var(--wh-border);
  border-radius: 18px;
  background: linear-gradient(145deg, #ffffff 20%, #f9fbff 100%);
  padding: 15px 16px;
  color: var(--wh-text);
  text-align: left;
  cursor: pointer;
  box-shadow: 0 8px 26px rgba(25, 42, 70, 0.045);
  transition: transform 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.oms-warehouse-kpis button::after {
  content: '';
  position: absolute;
  right: -28px;
  top: -30px;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: rgba(70, 92, 245, 0.07);
}

.oms-warehouse-kpis button:nth-child(3)::after { background: rgba(242, 148, 56, 0.11); }
.oms-warehouse-kpis button:nth-child(4)::after { background: rgba(235, 87, 87, 0.09); }
.oms-warehouse-kpis button:nth-child(5)::after { background: rgba(24, 166, 118, 0.09); }

.oms-warehouse-kpis button:hover {
  z-index: 1;
  transform: translateY(-2px);
  border-color: #c9d2fd;
  box-shadow: 0 14px 32px rgba(25, 42, 70, 0.09);
}

.oms-warehouse-kpis em,
.oms-warehouse-kpis span {
  overflow: hidden;
  color: var(--wh-muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-warehouse-kpis em {
  color: #526178;
  font-size: 12px;
  font-weight: 900;
}

.oms-warehouse-kpis strong {
  margin-top: 4px;
  color: var(--wh-text);
  font-size: 29px;
  font-weight: 950;
  letter-spacing: -0.045em;
  line-height: 1;
}

.oms-warehouse-catalog-panel {
  min-width: 0;
  overflow: visible;
  border: 1px solid var(--wh-border);
  border-radius: 22px;
  background: var(--wh-surface);
  box-shadow: var(--wh-shadow);
}

.oms-warehouse-catalog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 22px 16px;
}

.oms-warehouse-catalog-head > div {
  display: grid;
  gap: 4px;
}

.oms-warehouse-eyebrow {
  color: var(--wh-accent);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.oms-warehouse-catalog-head h2 {
  margin: 0;
  color: var(--wh-text);
  font-size: 20px;
  font-weight: 950;
  letter-spacing: -0.025em;
}

.oms-warehouse-catalog-head p {
  margin: 0;
  color: var(--wh-muted);
  font-size: 12px;
  font-weight: 700;
}

.oms-warehouse-v2 .oms-warehouse-products-actions {
  display: flex;
  align-items: center;
  gap: 9px;
  border-top: 1px solid var(--wh-border);
  padding: 13px 22px;
}

.oms-warehouse-searchbox {
  display: flex;
  align-items: center;
  flex: 0 1 390px;
  min-width: 240px;
  height: 40px;
  border: 1px solid var(--wh-border);
  border-radius: 12px;
  background: var(--wh-surface-soft);
  padding: 0 11px;
  color: #8290a5;
}

.oms-warehouse-searchbox:focus-within {
  border-color: #9aa7fa;
  box-shadow: 0 0 0 3px rgba(70, 92, 245, 0.1);
}

.oms-warehouse-searchbox .oms-warehouse-products-search {
  width: 100%;
  min-width: 0;
  max-width: none;
  height: 38px;
  border: 0;
  background: transparent;
  padding: 0 4px 0 8px;
  color: var(--wh-text);
  outline: none;
}

.oms-warehouse-filterchips {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  overflow-x: auto;
  padding: 1px;
}

.oms-warehouse-filterchips button {
  min-width: max-content;
  height: 34px;
  border: 1px solid var(--wh-border);
  border-radius: 10px;
  background: var(--wh-surface);
  padding: 0 10px;
  color: var(--wh-muted);
  font-size: 11px;
  font-weight: 850;
  cursor: pointer;
}

.oms-warehouse-filterchips button:hover,
.oms-warehouse-filterchips button.active {
  border-color: #c7ceff;
  background: var(--wh-accent-soft);
  color: var(--wh-accent);
}

.oms-warehouse-v2 .oms-warehouse-products-head,
.oms-warehouse-v2 .oms-warehouse-product-row {
  grid-template-columns: 66px minmax(250px, 1.35fr) minmax(190px, 0.95fr) 142px 164px minmax(130px, 0.65fr) 42px;
}

.oms-warehouse-v2 .oms-warehouse-products-head {
  min-height: 42px;
  margin: 0;
  border: 0;
  border-top: 1px solid var(--wh-border);
  border-bottom: 1px solid var(--wh-border);
  border-radius: 0;
  background: #f8fafc;
  padding: 0 14px;
  color: #7a889c;
  letter-spacing: 0.04em;
}

.oms-warehouse-v2 .oms-warehouse-products-head span {
  padding: 0 8px;
}

.oms-warehouse-v2 .oms-warehouse-products-list {
  overflow: visible;
  margin: 0;
  border: 0;
  border-radius: 0;
}

.oms-warehouse-v2 .oms-warehouse-product-row {
  min-height: 78px;
  border-top: 0;
  border-bottom: 1px solid var(--wh-border);
  padding: 0 14px;
  transition: background 120ms ease, box-shadow 120ms ease;
}

.oms-warehouse-v2 .oms-warehouse-product-row.bundle {
  background: linear-gradient(90deg, rgba(70, 92, 245, 0.025), transparent 42%);
}

.oms-warehouse-v2 .oms-warehouse-product-row:hover,
.oms-warehouse-v2 .oms-warehouse-product-row.selected {
  background: #f7f9ff;
  box-shadow: inset 3px 0 0 var(--wh-accent);
}

.oms-warehouse-v2 .oms-warehouse-product-image {
  width: 54px;
  height: 54px;
  border-color: #e6eaf1;
  border-radius: 13px;
  background: #f1f4f8;
}

.oms-warehouse-v2 .oms-warehouse-product-main {
  gap: 4px;
  padding: 0 9px;
}

.oms-warehouse-v2 .oms-warehouse-product-main strong {
  color: var(--wh-text);
  font-size: 13px;
  font-weight: 950;
}

.oms-warehouse-v2 .oms-warehouse-product-main span,
.oms-warehouse-v2 .oms-warehouse-product-main em {
  color: var(--wh-muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 720;
}

.oms-warehouse-v2 .oms-warehouse-product-variants {
  min-width: 0;
  padding: 0 8px;
}

.oms-warehouse-variant-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  text-align: left;
  cursor: pointer;
}

.oms-warehouse-variant-list span,
.oms-warehouse-variant-list em {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  border: 1px solid #dce2ff;
  border-radius: 7px;
  background: #f4f5ff;
  padding: 0 7px;
  color: #4b5bd4;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
}

.oms-warehouse-variant-list:hover span {
  border-color: #bdc6ff;
  background: #eceeff;
}

.oms-warehouse-variant-list em {
  border-color: transparent;
  background: transparent;
  color: var(--wh-muted);
}

.oms-warehouse-v2 .oms-warehouse-variant-pill {
  min-height: 30px;
  border-radius: 9px;
}

.oms-warehouse-v2 .oms-warehouse-product-stock {
  gap: 3px;
  padding: 0 8px;
}

.oms-warehouse-v2 .oms-warehouse-product-stock strong {
  color: var(--wh-text);
  font-size: 14px;
}

.oms-warehouse-v2 .oms-warehouse-product-stock span {
  color: var(--wh-muted);
  font-size: 10px;
}

.oms-warehouse-v2 .oms-warehouse-product-stock.unknown strong {
  color: var(--wh-muted);
  font-weight: 750;
}

.oms-warehouse-v2 .oms-warehouse-product-cost {
  min-height: 40px;
  border-color: #dfe5ee;
  border-radius: 11px;
  background: var(--wh-surface-soft);
  color: var(--wh-text);
}

.oms-warehouse-v2 .oms-warehouse-product-cost.missing {
  border-color: #f2d4b2;
  background: #fff9f2;
  color: #b7661e;
}

.oms-warehouse-v2 .oms-warehouse-product-cost.readonly:hover {
  border-color: #dfe5ee;
  background: var(--wh-surface-soft);
}

.oms-warehouse-v2 .oms-warehouse-product-cost.missing.readonly:hover {
  border-color: #f2d4b2;
  background: #fff9f2;
}

.oms-warehouse-v2 .oms-warehouse-product-channels {
  gap: 5px;
  padding: 0 8px;
}

.oms-warehouse-v2 .oms-warehouse-channel {
  min-height: 23px;
  border-radius: 7px;
  background: #e9f7f2;
  color: #16815f;
  font-size: 10px;
}

.oms-warehouse-v2 .oms-warehouse-row-menu > button {
  border-color: transparent;
  background: transparent;
}

.oms-warehouse-v2 .oms-warehouse-row-menu > button:hover {
  border-color: var(--wh-border);
  background: var(--wh-surface-soft);
}

.oms-warehouse-v2 .oms-warehouse-variant-expansion {
  border-bottom: 1px solid var(--wh-border);
  background: #f7f9fe;
  padding: 14px 18px 16px 90px;
}

.oms-warehouse-v2 .oms-warehouse-pagination {
  border: 0;
  border-radius: 0 0 22px 22px;
  padding: 14px 20px 16px;
}

/* Deliveries, inventories and documents share the same visual language. */
.oms-warehouse-v2-view #omsWarehouseDeliveriesGrid,
.oms-warehouse-v2-view #omsWarehouseInventoriesGrid,
.oms-warehouse-v2-view #omsWarehouseDocumentDraftsGrid {
  grid-column: 1 / -1;
  gap: 14px;
  border: 1px solid var(--wh-border);
  border-radius: 22px;
  background: var(--wh-surface);
  padding: 18px;
  box-shadow: var(--wh-shadow);
}

.oms-warehouse-v2-view #omsWarehouseDeliveriesGrid[hidden],
.oms-warehouse-v2-view #omsWarehouseInventoriesGrid[hidden],
.oms-warehouse-v2-view #omsWarehouseDocumentDraftsGrid[hidden] {
  display: none !important;
}

.oms-warehouse-v2-view .oms-control-summary {
  min-height: 76px;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(135deg, #f8faff 0%, #f3f5ff 100%);
  padding: 15px 17px;
}

.oms-warehouse-v2-view .oms-control-summary-title {
  color: var(--wh-text);
  font-size: 16px;
  font-weight: 950;
  letter-spacing: -0.02em;
}

.oms-warehouse-v2-view .oms-control-summary-sub {
  color: var(--wh-muted);
  font-size: 11px;
  line-height: 1.55;
}

.oms-warehouse-v2-view .oms-control-summary-state {
  border: 1px solid #d6dcff;
  border-radius: 999px;
  background: #ffffff;
  color: var(--wh-accent);
  padding: 6px 10px;
  font-size: 10px;
}

.oms-warehouse-v2-view .oms-warehouse-toolbar {
  border-color: var(--wh-border);
  border-radius: 14px;
  background: var(--wh-surface-soft);
  padding: 10px 12px;
}

.oms-warehouse-v2-view .oms-warehouse-delivery-status-filters,
.oms-warehouse-v2-view .oms-warehouse-document-status-filters {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  padding: 2px 0;
}

.oms-warehouse-v2-view .oms-warehouse-deliveries-head {
  border-color: var(--wh-border);
  border-radius: 13px 13px 0 0;
  background: #f7f9fc;
}

.oms-warehouse-v2-view .oms-warehouse-deliveries-list {
  border-color: var(--wh-border);
  border-radius: 0 0 13px 13px;
}

.oms-warehouse-v2-view .oms-warehouse-delivery-row {
  min-height: 66px;
  border-color: var(--wh-border);
  background: var(--wh-surface);
}

.oms-warehouse-v2-view .oms-warehouse-delivery-row:hover,
.oms-warehouse-v2-view .oms-warehouse-delivery-row.selected {
  background: #f6f8ff;
  box-shadow: inset 3px 0 0 var(--wh-accent);
}

.oms-warehouse-v2-view .oms-warehouse-delivery-row > span:first-child strong {
  color: var(--wh-text);
}

.oms-warehouse-v2-view .oms-warehouse-delivery-note {
  border: 1px solid #dfe6ef;
  border-radius: 13px;
  background: #f8fafc;
  color: var(--wh-muted);
}

.oms-warehouse-v2-view .oms-warehouse-document-filter-bar {
  border: 1px solid var(--wh-border);
  border-radius: 15px;
  background: var(--wh-surface-soft);
  padding: 13px;
}

.oms-warehouse-v2-view .oms-warehouse-document-card-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.oms-warehouse-v2-view .oms-warehouse-document-draft-card {
  border: 1px solid var(--wh-border);
  border-radius: 17px;
  background: linear-gradient(145deg, #ffffff 15%, #fbfcff 100%);
  padding: 15px;
  box-shadow: 0 8px 22px rgba(25, 42, 70, 0.045);
  transition: transform 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.oms-warehouse-v2-view .oms-warehouse-document-draft-card:hover {
  transform: translateY(-2px);
  border-color: #cbd3ff;
  box-shadow: 0 14px 28px rgba(25, 42, 70, 0.08);
}

.oms-warehouse-product-modal-backdrop {
  background: rgba(10, 18, 34, 0.46);
  backdrop-filter: blur(8px);
}

.oms-warehouse-product-modal-shell {
  width: min(1180px, calc(100vw - 32px));
  height: min(900px, calc(100vh - 32px));
  border-radius: 24px;
  box-shadow: 0 30px 80px rgba(10, 18, 34, 0.28);
}

.oms-warehouse-product-modal-head {
  min-height: 70px;
  padding: 0 34px;
}

.oms-warehouse-product-modal-title strong {
  font-size: 17px;
  letter-spacing: -0.02em;
}

.oms-warehouse-product-modal .oms-warehouse-product-detail-tabs {
  gap: 28px;
  padding: 0 34px;
}

.oms-warehouse-product-modal .oms-warehouse-product-detail-panel {
  padding: 28px 34px 40px;
}

.oms-warehouse-product-modal-footer {
  padding: 13px 34px;
}

.oms-warehouse-base-input,
.oms-warehouse-product-detail-metric,
.oms-warehouse-product-detail-row,
.oms-warehouse-product-media {
  border-radius: 11px;
}

.oms-warehouse-v2-view .oms-warehouse-document-status-filters {
  align-items: center;
  flex-wrap: wrap;
}

.oms-warehouse-v2-view .oms-warehouse-document-actions-spacer {
  flex: 1 1 auto;
}

.oms-warehouse-v2-view .oms-warehouse-document-create-card {
  margin: 14px 0;
  border: 1px solid var(--wh-border);
  border-radius: 18px;
  background: var(--wh-surface);
  box-shadow: var(--wh-shadow);
}

.oms-warehouse-v2-view .oms-warehouse-document-create-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.oms-app[data-theme="dark"] .oms-warehouse-v2-view {
  --wh-bg: #0d1422;
  --wh-surface: #141e2f;
  --wh-surface-soft: #182437;
  --wh-text: #edf3ff;
  --wh-muted: #99a8bd;
  --wh-border: #29374b;
  --wh-accent: #8d9bff;
  --wh-accent-soft: #222d52;
  --wh-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.oms-app[data-theme="dark"] .oms-warehouse-v2-view .oms-analytics-top {
  border-color: var(--wh-border);
  background: var(--wh-bg);
}

.oms-app[data-theme="dark"] .oms-warehouse-v2-view .oms-analytics-title {
  color: var(--wh-text);
}

.oms-app[data-theme="dark"] .oms-warehouse-v2-view .oms-analytics-subtitle {
  color: var(--wh-muted);
}

.oms-app[data-theme="dark"] .oms-warehouse-v2 .oms-warehouse-tabs button.active {
  background: #6574f6;
  color: #ffffff;
}

.oms-app[data-theme="dark"] .oms-warehouse-v2 .oms-warehouse-tabs,
.oms-app[data-theme="dark"] .oms-warehouse-kpis button,
.oms-app[data-theme="dark"] .oms-warehouse-v2 .oms-warehouse-products-head,
.oms-app[data-theme="dark"] .oms-warehouse-v2 .oms-warehouse-product-row,
.oms-app[data-theme="dark"] .oms-warehouse-v2-view .oms-warehouse-document-draft-card {
  background: var(--wh-surface);
}

.oms-app[data-theme="dark"] .oms-warehouse-v2 .oms-warehouse-product-row:hover,
.oms-app[data-theme="dark"] .oms-warehouse-v2 .oms-warehouse-product-row.selected,
.oms-app[data-theme="dark"] .oms-warehouse-v2-view .oms-warehouse-delivery-row:hover {
  background: #19263b;
}

.oms-app[data-theme="dark"] .oms-warehouse-v2 .oms-warehouse-product-cost,
.oms-app[data-theme="dark"] .oms-warehouse-v2-view .oms-control-summary,
.oms-app[data-theme="dark"] .oms-warehouse-v2-view .oms-warehouse-toolbar,
.oms-app[data-theme="dark"] .oms-warehouse-v2-view .oms-warehouse-document-filter-bar {
  background: var(--wh-surface-soft);
}

.oms-app[data-theme="dark"] .oms-warehouse-v2 .oms-warehouse-product-cost strong,
.oms-app[data-theme="dark"] .oms-warehouse-kpis strong,
.oms-app[data-theme="dark"] .oms-warehouse-kpis em,
.oms-app[data-theme="dark"] .oms-warehouse-v2-view .oms-warehouse-delivery-row strong {
  color: var(--wh-text);
}

@media (max-width: 1280px) {
  .oms-warehouse-v2-view .oms-warehouse-document-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .oms-warehouse-v2 .oms-warehouse-products-head,
  .oms-warehouse-v2 .oms-warehouse-product-row {
    grid-template-columns: 66px minmax(230px, 1.2fr) minmax(170px, 0.8fr) 130px 150px minmax(110px, 0.55fr) 40px;
  }
}

@media (max-width: 1120px) {
  .oms-warehouse-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 980px) {
  .oms-warehouse-v2-view .oms-control-content { padding-left: 0; padding-right: 0; }
  .oms-warehouse-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .oms-warehouse-v2 .oms-warehouse-products-actions { align-items: stretch; flex-wrap: wrap; }
  .oms-warehouse-searchbox { flex: 1 1 70%; }
  .oms-warehouse-filterchips { flex: 1 1 100%; }
  .oms-warehouse-v2 .oms-warehouse-products-head { display: none; }
  .oms-warehouse-v2 .oms-warehouse-products-list { display: grid; gap: 10px; padding: 0 12px 12px; }
  .oms-warehouse-v2 .oms-warehouse-product-row {
    grid-template-columns: 58px minmax(0, 1fr) 120px 42px;
    grid-template-areas:
      'image main stock menu'
      'image variants cost menu'
      'image channels cost menu';
    min-height: 120px;
    border: 1px solid var(--wh-border);
    border-radius: 15px;
    padding: 10px;
  }
  .oms-warehouse-v2 .oms-warehouse-product-image { grid-area: image; }
  .oms-warehouse-v2 .oms-warehouse-product-main { grid-area: main; }
  .oms-warehouse-v2 .oms-warehouse-product-variants { grid-area: variants; }
  .oms-warehouse-v2 .oms-warehouse-product-stock { grid-area: stock; }
  .oms-warehouse-v2 .oms-warehouse-product-price { grid-area: cost; }
  .oms-warehouse-v2 .oms-warehouse-product-channels { grid-area: channels; }
  .oms-warehouse-v2 .oms-warehouse-row-menu { grid-area: menu; }
  .oms-warehouse-v2 .oms-warehouse-variant-expansion { margin: -11px 12px 0; padding: 14px; border: 1px solid var(--wh-border); border-radius: 0 0 15px 15px; }
}

@media (max-width: 720px) {
  .oms-warehouse-v2-view .oms-control-content { gap: 12px; }
  .oms-warehouse-v2 .oms-warehouse-tabs { width: 100%; }
  .oms-warehouse-sourcebar { grid-template-columns: 38px minmax(0, 1fr); border-radius: 15px; }
  .oms-warehouse-sourcebar-icon { width: 38px; height: 38px; }
  .oms-warehouse-sourcebar small { grid-column: 2; justify-self: start; }
  .oms-warehouse-kpis { gap: 8px; }
  .oms-warehouse-kpis button { min-height: 102px; border-radius: 15px; padding: 13px; }
  .oms-warehouse-kpis strong { font-size: 25px; }
  .oms-warehouse-catalog-panel,
  .oms-warehouse-v2-view #omsWarehouseDeliveriesGrid,
  .oms-warehouse-v2-view #omsWarehouseInventoriesGrid,
  .oms-warehouse-v2-view #omsWarehouseDocumentDraftsGrid { border-radius: 16px; }
  .oms-warehouse-catalog-head { padding: 17px 15px 13px; }
  .oms-warehouse-catalog-head h2 { font-size: 17px; }
  .oms-warehouse-v2 .oms-warehouse-products-actions { padding: 12px 15px; }
  .oms-warehouse-searchbox { flex-basis: 100%; min-width: 0; }
  .oms-warehouse-v2-view #omsWarehouseDeliveriesGrid,
  .oms-warehouse-v2-view #omsWarehouseInventoriesGrid,
  .oms-warehouse-v2-view #omsWarehouseDocumentDraftsGrid { padding: 12px; }
  .oms-warehouse-v2-view .oms-warehouse-document-card-grid { grid-template-columns: 1fr; }
  .oms-warehouse-product-modal-shell { width: 100vw; height: 100vh; border-radius: 0; }
  .oms-warehouse-product-modal-head,
  .oms-warehouse-product-modal .oms-warehouse-product-detail-tabs,
  .oms-warehouse-product-modal .oms-warehouse-product-detail-panel,
  .oms-warehouse-product-modal-footer { padding-left: 15px; padding-right: 15px; }
}

@media (max-width: 520px) {
  .oms-warehouse-kpis { grid-template-columns: 1fr 1fr; }
  .oms-warehouse-v2 .oms-warehouse-product-row {
    grid-template-columns: 52px minmax(0, 1fr) 34px;
    grid-template-areas:
      'image main menu'
      'variants variants variants'
      'stock cost cost'
      'channels channels channels';
  }
  .oms-warehouse-v2 .oms-warehouse-product-stock,
  .oms-warehouse-v2 .oms-warehouse-product-price { padding: 3px 8px; }
  .oms-warehouse-v2 .oms-warehouse-pagination { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  .oms-warehouse-kpis button,
  .oms-warehouse-v2 .oms-warehouse-product-row,
  .oms-warehouse-v2-view .oms-warehouse-document-draft-card { transition: none; }
}

/* Pobranie: checkbox w karcie zamowienia (wiersz pod Platnoscia) i w asystencie
   pakowania. Zwykly kontrolka, nie akcja - dlatego checkbox, nie przycisk. */
.oms-cod-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-weight: 700;
  user-select: none;
}

.oms-cod-checkbox input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin: 0;
  cursor: pointer;
  accent-color: var(--oms-blue-600, #2563eb);
}

.oms-cod-checkbox.compact {
  font-size: 11px;
  font-weight: 900;
}

.oms-cod-checkbox.is-locked,
.oms-cod-checkbox.is-locked input {
  cursor: not-allowed;
  opacity: 0.6;
}

.oms-cod-note {
  margin-left: 10px;
  font-size: 11px;
  font-weight: 600;
  opacity: 0.65;
}

/* --- Magazyn: macierz produkt x kanal (zakladka "Kanaly") --- */
.oms-matrix-channel-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px 18px 4px;
}
.oms-matrix-channel-chip {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 14px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 12px;
  background: #ffffff;
  cursor: pointer;
  text-align: left;
  font: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.oms-matrix-channel-chip:hover { border-color: #6574f6; }
.oms-matrix-channel-chip.active {
  border-color: #6574f6;
  box-shadow: 0 0 0 2px rgba(101, 116, 246, 0.18);
}
.oms-matrix-channel-chip strong { font-size: 13px; }
.oms-matrix-channel-chip span { font-size: 11px; color: #64748b; }
.oms-matrix-channel-chip span.warn { color: #b45309; font-weight: 600; }
.oms-matrix-channel-chip span.drift { color: #b91c1c; font-weight: 600; }

.oms-warehouse-matrix-table {
  margin: 12px 18px 0;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 12px;
  overflow-x: auto;
}
.oms-warehouse-matrix-head,
.oms-warehouse-matrix-row {
  display: grid;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  min-width: 720px;
}
.oms-warehouse-matrix-head {
  background: #f8fafc;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  position: sticky;
  top: 0;
}
.oms-warehouse-matrix-head span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.oms-warehouse-matrix-row {
  border-bottom: 1px solid rgba(15, 23, 42, 0.05);
  background: #ffffff;
}
.oms-warehouse-matrix-row:last-child { border-bottom: none; }
.oms-warehouse-matrix-row:hover { background: #f8faff; }
.oms-warehouse-matrix-product {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.oms-warehouse-matrix-product > div:last-child {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.oms-warehouse-matrix-product strong {
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.oms-warehouse-matrix-product span {
  font-size: 11px;
  color: #64748b;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.oms-warehouse-matrix-oms { display: flex; flex-direction: column; }
.oms-warehouse-matrix-oms strong { font-size: 13px; }
.oms-warehouse-matrix-oms span { font-size: 11px; color: #64748b; }

.oms-matrix-cell {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 26px;
  padding: 2px 8px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
}
.oms-matrix-cell.none { color: #94a3b8; background: transparent; }
.oms-matrix-cell.unknown { color: #475569; background: rgba(100, 116, 139, 0.12); }
.oms-matrix-cell.info { color: #1d4ed8; background: rgba(29, 78, 216, 0.1); }
.oms-matrix-cell.ok { color: #15803d; background: rgba(21, 128, 61, 0.1); }
.oms-matrix-cell.drift { color: #b91c1c; background: rgba(185, 28, 28, 0.1); }
.oms-matrix-cell.drift em { font-style: normal; font-size: 11px; opacity: 0.85; }
.oms-matrix-loading { padding: 6px 18px 0; font-size: 12px; }

.oms-app[data-theme="dark"] .oms-matrix-channel-chip,
.oms-app[data-theme="dark"] .oms-warehouse-matrix-row {
  background: var(--wh-surface);
  border-color: rgba(148, 163, 184, 0.18);
}
.oms-app[data-theme="dark"] .oms-warehouse-matrix-head {
  background: var(--wh-surface-soft);
  border-color: rgba(148, 163, 184, 0.18);
}
.oms-app[data-theme="dark"] .oms-warehouse-matrix-row:hover { background: #19263b; }
.oms-app[data-theme="dark"] .oms-warehouse-matrix-product strong,
.oms-app[data-theme="dark"] .oms-warehouse-matrix-oms strong,
.oms-app[data-theme="dark"] .oms-matrix-channel-chip strong { color: var(--wh-text); }
.oms-app[data-theme="dark"] .oms-warehouse-matrix-table { border-color: rgba(148, 163, 184, 0.18); }

/* KPI: wartosc magazynu (6. kafel) */
.oms-warehouse-kpis { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.oms-warehouse-kpis .oms-warehouse-kpi-value strong { color: #15803d; }
.oms-app[data-theme="dark"] .oms-warehouse-kpis .oms-warehouse-kpi-value strong { color: #4ade80; }
@media (max-width: 1480px) {
  .oms-warehouse-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .oms-warehouse-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Alerty niskich stanow: badge w nav + karta dashboardu */
.oms-nav-lowstock-badge {
  margin-left: auto;
  background: #fee2e2;
  color: #b91c1c;
}
.oms-sidebar.collapsed .oms-nav-lowstock-badge { display: none; }
.oms-app[data-theme="dark"] .oms-nav-lowstock-badge { background: rgba(185, 28, 28, 0.25); color: #fca5a5; }

.oms-dashboard-lowstock-card { margin-top: 14px; }
.oms-dashboard-lowstock-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.oms-dashboard-lowstock-list { display: flex; flex-direction: column; }
.oms-dashboard-lowstock-row {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px 6px;
  border: none;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  background: transparent;
  cursor: pointer;
  text-align: left;
  font: inherit;
}
.oms-dashboard-lowstock-row:last-child { border-bottom: none; }
.oms-dashboard-lowstock-row:hover { background: rgba(101, 116, 246, 0.06); }
.oms-dashboard-lowstock-image {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
  font-size: 9px;
  color: #94a3b8;
}
.oms-dashboard-lowstock-image img { width: 100%; height: 100%; object-fit: cover; }
.oms-dashboard-lowstock-name { display: flex; flex-direction: column; min-width: 0; }
.oms-dashboard-lowstock-name strong {
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.oms-dashboard-lowstock-name small { font-size: 11px; color: #64748b; }
.oms-dashboard-lowstock-stock { display: flex; flex-direction: column; align-items: flex-end; }
.oms-dashboard-lowstock-stock strong { font-size: 14px; color: #b45309; }
.oms-dashboard-lowstock-stock small { font-size: 11px; color: #64748b; }
.oms-app[data-theme="dark"] .oms-dashboard-lowstock-row { border-color: rgba(148, 163, 184, 0.14); }
.oms-app[data-theme="dark"] .oms-dashboard-lowstock-image { background: #1e293b; }

/* Historia ruchow w karcie produktu */
.oms-warehouse-movement-row b.oms-movement-in { color: #15803d; font-weight: 700; }
.oms-warehouse-movement-row b.oms-movement-out { color: #b91c1c; font-weight: 700; }
.oms-warehouse-movement-row b.oms-movement-neutral { color: #64748b; font-weight: 600; }
.oms-warehouse-movement-row small { color: #64748b; font-weight: 500; margin-left: 4px; }
.oms-app[data-theme="dark"] .oms-warehouse-movement-row b.oms-movement-in { color: #4ade80; }
.oms-app[data-theme="dark"] .oms-warehouse-movement-row b.oms-movement-out { color: #f87171; }

/* Dokumenty magazynowe: uklad tabelowy (Magazyn 2.0) */
.oms-warehouse-document-card-grid { display: flex !important; flex-direction: column; gap: 8px; }
.oms-warehouse-document-rowcard {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 12px;
  background: #ffffff;
  padding: 10px 14px;
}
.oms-warehouse-document-rowcard.is-focused { border-color: #6574f6; box-shadow: 0 0 0 2px rgba(101, 116, 246, 0.18); }
.oms-warehouse-document-rowline {
  display: grid;
  grid-template-columns: 48px minmax(220px, 1.4fr) 130px minmax(110px, 0.7fr) minmax(110px, 0.7fr) 110px auto;
  align-items: center;
  gap: 12px;
}
.oms-doc-type {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.03em;
}
.oms-doc-type.in { background: rgba(21, 128, 61, 0.12); color: #15803d; }
.oms-doc-type.out { background: rgba(185, 28, 28, 0.1); color: #b91c1c; }
.oms-doc-type.move { background: rgba(29, 78, 216, 0.1); color: #1d4ed8; }
.oms-doc-type.adjust { background: rgba(180, 83, 9, 0.12); color: #b45309; }
.oms-doc-main { display: flex; flex-direction: column; min-width: 0; }
.oms-doc-main strong { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.oms-doc-main small { font-size: 11px; color: #64748b; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.oms-doc-date, .oms-doc-qty { font-size: 12px; color: #475569; }
.oms-doc-value { font-size: 13px; font-weight: 600; }
.oms-doc-status {
  display: inline-flex;
  justify-content: center;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}
.oms-doc-status.draft { background: rgba(100, 116, 139, 0.14); color: #475569; }
.oms-doc-status.confirmed { background: rgba(21, 128, 61, 0.12); color: #15803d; }
.oms-doc-status.cancelled { background: rgba(185, 28, 28, 0.1); color: #b91c1c; }
.oms-doc-actions { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: wrap; }
.oms-warehouse-document-lines-details { margin-top: 6px; }
.oms-warehouse-document-lines-details summary {
  cursor: pointer;
  font-size: 12px;
  color: #6574f6;
  font-weight: 600;
  user-select: none;
}
@media (max-width: 1280px) {
  .oms-warehouse-document-rowline { grid-template-columns: 48px minmax(180px, 1.4fr) minmax(100px, 0.7fr) 110px auto; }
  .oms-doc-date, .oms-doc-qty { display: none; }
}
.oms-app[data-theme="dark"] .oms-warehouse-document-rowcard { background: var(--wh-surface); border-color: rgba(148, 163, 184, 0.18); }
.oms-app[data-theme="dark"] .oms-doc-main strong { color: var(--wh-text); }
.oms-app[data-theme="dark"] .oms-doc-date, .oms-app[data-theme="dark"] .oms-doc-qty { color: #94a3b8; }
#omsWarehouseChannelMatrixGrid[hidden] { display: none !important; }

/* Bulk akcje katalogu */
.oms-warehouse-v2 .oms-warehouse-products-head,
.oms-warehouse-v2 .oms-warehouse-product-row {
  grid-template-columns: 34px 66px minmax(250px, 1.35fr) minmax(190px, 0.95fr) 142px 164px minmax(130px, 0.65fr) 42px;
}
@media (max-width: 1280px) {
  .oms-warehouse-v2 .oms-warehouse-products-head,
  .oms-warehouse-v2 .oms-warehouse-product-row {
    grid-template-columns: 34px 66px minmax(230px, 1.2fr) minmax(170px, 0.8fr) 130px 150px minmax(110px, 0.55fr) 40px;
  }
}
@media (max-width: 980px) {
  .oms-warehouse-bulk-check { display: none !important; }
  .oms-warehouse-v2 .oms-warehouse-product-row {
    grid-template-columns: 58px minmax(0, 1fr) 120px 42px;
  }
}
.oms-warehouse-bulk-check {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: stretch;
  cursor: pointer;
}
.oms-warehouse-bulk-check input {
  width: 16px;
  height: 16px;
  accent-color: #6574f6;
  cursor: pointer;
}
.oms-warehouse-bulkbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 18px 10px;
  padding: 10px 14px;
  border: 1px solid rgba(101, 116, 246, 0.35);
  border-radius: 12px;
  background: rgba(101, 116, 246, 0.06);
  font-size: 13px;
}
.oms-warehouse-bulkbar label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #475569;
}
.oms-warehouse-bulkbar input {
  width: 110px;
  padding: 5px 8px;
  border: 1px solid rgba(15, 23, 42, 0.15);
  border-radius: 8px;
  font: inherit;
  font-size: 12px;
}
.oms-warehouse-bulkbar input[type="number"] { width: 84px; }
.oms-warehouse-bulkbar-spacer { flex: 1; }
.oms-warehouse-bulkbar em { font-style: normal; font-size: 12px; font-weight: 600; }
.oms-warehouse-bulkbar em.ok { color: #15803d; }
.oms-warehouse-bulkbar em.err { color: #b91c1c; }
.oms-app[data-theme="dark"] .oms-warehouse-bulkbar { background: rgba(101, 116, 246, 0.12); border-color: rgba(101, 116, 246, 0.4); }
.oms-app[data-theme="dark"] .oms-warehouse-bulkbar label { color: #94a3b8; }
.oms-app[data-theme="dark"] .oms-warehouse-bulkbar input { background: var(--wh-surface); color: var(--wh-text); border-color: rgba(148, 163, 184, 0.3); }

/* Przepisy zestawow (model bazowy) */
.oms-recipe-families { display: flex; flex-direction: column; gap: 10px; margin: 12px 18px 0; }
.oms-recipe-family {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 12px;
  background: #ffffff;
  padding: 12px 14px;
}
.oms-recipe-family-head { display: flex; align-items: center; gap: 12px; }
.oms-recipe-family-main { display: flex; flex-direction: column; min-width: 0; }
.oms-recipe-family-main strong { font-size: 13px; }
.oms-recipe-family-main small { font-size: 11px; color: #64748b; }
.oms-recipe-family-variants { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.oms-recipe-variant {
  padding: 5px 12px;
  border: 1px solid rgba(15, 23, 42, 0.14);
  border-radius: 999px;
  background: #ffffff;
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.oms-recipe-variant:hover { border-color: #6574f6; }
.oms-recipe-variant.active { border-color: #6574f6; box-shadow: 0 0 0 2px rgba(101, 116, 246, 0.18); }
.oms-recipe-variant.has_recipe { background: rgba(21, 128, 61, 0.1); color: #15803d; border-color: rgba(21, 128, 61, 0.25); }
.oms-recipe-variant.atomic { background: rgba(29, 78, 216, 0.08); color: #1d4ed8; border-color: rgba(29, 78, 216, 0.25); }
.oms-recipe-variant.set_without_recipe { background: rgba(185, 28, 28, 0.07); color: #b91c1c; border-color: rgba(185, 28, 28, 0.25); }
.oms-recipe-variant.multipack_undecided { background: rgba(180, 83, 9, 0.08); color: #b45309; border-color: rgba(180, 83, 9, 0.25); }

.oms-warehouse-recipe-editor {
  margin-top: 12px;
  border-top: 1px dashed rgba(15, 23, 42, 0.15);
  padding-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.oms-recipe-editor-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.oms-recipe-editor-head small { display: block; font-size: 11px; color: #64748b; }
.oms-recipe-components { display: flex; flex-direction: column; gap: 6px; }
.oms-recipe-component-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 84px auto;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 10px;
  background: #f8fafc;
}
.oms-recipe-component-main { display: flex; flex-direction: column; min-width: 0; }
.oms-recipe-component-main strong { font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.oms-recipe-component-main small { font-size: 11px; color: #64748b; }
.oms-recipe-component-row input {
  padding: 5px 8px;
  border: 1px solid rgba(15, 23, 42, 0.15);
  border-radius: 8px;
  font: inherit;
  font-size: 12px;
  text-align: center;
}
.oms-recipe-add { position: relative; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.oms-recipe-add input[type="search"] {
  flex: 1 1 280px;
  padding: 8px 12px;
  border: 1px solid rgba(15, 23, 42, 0.15);
  border-radius: 10px;
  font: inherit;
  font-size: 12px;
}
.oms-recipe-search-results {
  flex-basis: 100%;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 10px;
  overflow: hidden;
}
.oms-recipe-search-result {
  display: flex;
  flex-direction: column;
  padding: 7px 12px;
  border: none;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  background: #ffffff;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.oms-recipe-search-result:last-child { border-bottom: none; }
.oms-recipe-search-result:hover { background: rgba(101, 116, 246, 0.07); }
.oms-recipe-search-result strong { font-size: 12px; }
.oms-recipe-search-result small { font-size: 11px; color: #64748b; }
.oms-recipe-new-component { display: flex; gap: 8px; flex-wrap: wrap; }
.oms-recipe-new-component input {
  flex: 1 1 180px;
  padding: 7px 10px;
  border: 1px solid rgba(15, 23, 42, 0.15);
  border-radius: 8px;
  font: inherit;
  font-size: 12px;
}
.oms-recipe-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.oms-recipe-copy-result { display: flex; flex-direction: column; gap: 3px; font-size: 12px; }
.oms-recipe-copy-result .ok { color: #15803d; }
.oms-recipe-copy-result .warn { color: #b45309; }

#omsWarehouseRecipesGrid[hidden] { display: none !important; }
.oms-app[data-theme="dark"] .oms-recipe-family { background: var(--wh-surface); border-color: rgba(148, 163, 184, 0.18); }
.oms-app[data-theme="dark"] .oms-recipe-component-row { background: var(--wh-surface-soft); border-color: rgba(148, 163, 184, 0.16); }
.oms-app[data-theme="dark"] .oms-recipe-variant { background: var(--wh-surface); color: var(--wh-text); }
.oms-app[data-theme="dark"] .oms-recipe-search-result { background: var(--wh-surface); }
.oms-app[data-theme="dark"] .oms-recipe-family-main strong { color: var(--wh-text); }
.oms-app[data-theme="dark"] .oms-recipe-add input,
.oms-app[data-theme="dark"] .oms-recipe-new-component input,
.oms-app[data-theme="dark"] .oms-recipe-component-row input { background: var(--wh-surface); color: var(--wh-text); border-color: rgba(148, 163, 184, 0.3); }

/* Przelicznik jednostki zakupu w linii dostawy (model bazowy) */
.oms-warehouse-delivery-edit-line {
  grid-template-columns: 56px minmax(320px, 1.6fr) minmax(110px, 0.65fr) minmax(110px, 0.65fr) 128px 84px 88px 112px 90px 108px 38px;
}
.oms-warehouse-delivery-pack-inputs { display: flex; align-items: center; gap: 4px; }
.oms-warehouse-delivery-pack-inputs input { width: 52px; min-width: 0; text-align: center; }
.oms-warehouse-delivery-pack-inputs b { color: #94a3b8; font-weight: 600; }

/* Propozycja przepisu */
.oms-recipe-proposal {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 14px;
  border: 1px dashed rgba(101, 116, 246, 0.5);
  border-radius: 10px;
  background: rgba(101, 116, 246, 0.05);
}
.oms-recipe-proposal strong { font-size: 12px; color: #4f46e5; }
.oms-recipe-proposal span { font-size: 12px; color: #475569; }
.oms-recipe-proposal em { font-style: normal; font-size: 12px; font-weight: 600; }
.oms-recipe-proposal button { align-self: flex-start; }
.oms-app[data-theme="dark"] .oms-recipe-proposal { background: rgba(101, 116, 246, 0.12); }
.oms-app[data-theme="dark"] .oms-recipe-proposal span { color: #94a3b8; }

/* Magazyn 2.2: polka i oferta */
.oms-warehouse-tabs-divider {
  width: 1px;
  align-self: stretch;
  margin: 4px 6px;
  background: rgba(15, 23, 42, 0.12);
}
.oms-shelf-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  padding: 0 18px;
}
.oms-shelf-kpis > * {
  display: grid;
  gap: 2px;
  padding: 14px 16px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 16px;
  background: #ffffff;
  text-align: left;
  font: inherit;
  cursor: pointer;
}
.oms-shelf-kpis .oms-shelf-kpi-static { cursor: default; }
.oms-shelf-kpis > *.active { border-color: #6574f6; box-shadow: 0 0 0 2px rgba(101, 116, 246, 0.16); }
.oms-shelf-kpis em { font-style: normal; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: #64748b; }
.oms-shelf-kpis strong { font-size: 24px; line-height: 1.15; }
.oms-shelf-kpis span { font-size: 11px; color: #64748b; }
.oms-shelf-kpis .alert strong { color: #b45309; }

.oms-shelf-list { display: flex; flex-direction: column; margin: 12px 18px 0; border: 1px solid rgba(15, 23, 42, 0.08); border-radius: 14px; overflow: hidden; }
.oms-shelf-row {
  display: grid;
  grid-template-columns: 52px minmax(220px, 1.5fr) 180px 116px minmax(120px, 0.7fr);
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  background: #ffffff;
}
.oms-shelf-row.offer { grid-template-columns: 52px minmax(200px, 1.2fr) minmax(220px, 1.6fr) 110px 130px; }
.oms-shelf-row:last-child { border-bottom: none; }
.oms-shelf-row:hover { background: #f8faff; }
.oms-shelf-row.empty { background: rgba(180, 83, 9, 0.04); }
.oms-shelf-row.missing { background: rgba(185, 28, 28, 0.04); }
.oms-shelf-photo { width: 52px; height: 52px; border-radius: 10px; overflow: hidden; display: flex; align-items: center; justify-content: center; background: #f1f5f9; font-size: 10px; color: #94a3b8; }
.oms-shelf-photo img { width: 100%; height: 100%; object-fit: cover; }
.oms-shelf-name { display: flex; flex-direction: column; min-width: 0; }
.oms-shelf-name strong { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.oms-shelf-name small { font-size: 11px; color: #64748b; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.oms-shelf-stock { display: flex; flex-direction: column; }
.oms-shelf-stock strong { font-size: 15px; }
.oms-shelf-stock small { font-size: 11px; color: #64748b; }
.oms-shelf-stock.zero strong { color: #b45309; }
.oms-shelf-stock.low strong { color: #b45309; }
.oms-shelf-pack { display: flex; flex-direction: column; gap: 2px; }
.oms-shelf-pack span { font-size: 10px; text-transform: uppercase; letter-spacing: 0.04em; color: #94a3b8; }
.oms-shelf-pack input { width: 72px; padding: 5px 8px; border: 1px solid rgba(15, 23, 42, 0.15); border-radius: 8px; font: inherit; font-size: 13px; text-align: center; }
.oms-shelf-channels { display: flex; flex-wrap: wrap; gap: 4px; }
.oms-shelf-channels span { padding: 2px 7px; border-radius: 999px; background: rgba(101, 116, 246, 0.1); color: #4f46e5; font-size: 10px; font-weight: 600; }
.oms-shelf-channels em { font-style: normal; font-size: 11px; color: #94a3b8; }
.oms-shelf-recipe { font-size: 12px; color: #475569; }
.oms-shelf-recipe .warn { color: #b91c1c; font-weight: 600; }
.oms-shelf-buildable { display: flex; flex-direction: column; align-items: flex-end; }
.oms-shelf-buildable strong { font-size: 16px; color: #15803d; }
.oms-shelf-buildable small { font-size: 10px; color: #64748b; }
.oms-shelf-actions { display: flex; justify-content: flex-end; }

@media (max-width: 1280px) {
  .oms-shelf-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .oms-shelf-row, .oms-shelf-row.offer { grid-template-columns: 52px minmax(0, 1fr) 150px; }
  .oms-shelf-pack, .oms-shelf-channels, .oms-shelf-buildable { display: none; }
}
#omsWarehouseShelfGrid[hidden] { display: none !important; }
.oms-app[data-theme="dark"] .oms-shelf-row,
.oms-app[data-theme="dark"] .oms-shelf-kpis > * { background: var(--wh-surface); border-color: rgba(148, 163, 184, 0.18); }
.oms-app[data-theme="dark"] .oms-shelf-row:hover { background: #19263b; }
.oms-app[data-theme="dark"] .oms-shelf-name strong,
.oms-app[data-theme="dark"] .oms-shelf-stock strong,
.oms-app[data-theme="dark"] .oms-shelf-kpis strong { color: var(--wh-text); }
.oms-app[data-theme="dark"] .oms-shelf-photo { background: #1e293b; }
.oms-app[data-theme="dark"] .oms-shelf-pack input { background: var(--wh-surface); color: var(--wh-text); border-color: rgba(148, 163, 184, 0.3); }
.oms-app[data-theme="dark"] .oms-shelf-list { border-color: rgba(148, 163, 184, 0.18); }
.oms-shelf-usage { display: flex; flex-direction: column; }
.oms-shelf-usage strong { font-size: 15px; }
.oms-shelf-usage small { font-size: 10px; color: #64748b; }
.oms-shelf-usage em { font-style: normal; font-size: 11px; color: #b45309; }
.oms-app[data-theme="dark"] .oms-shelf-usage strong { color: var(--wh-text); }
/* ============================================================
   Profiter · Narzedzia danych i kosztow - premium UI (2026-08-21)
   Zakres: .oms-pc (details#omsProfiterAdminPanel) i karty w srodku.
   Kolory jada na tokenach .oms-p2-legacy, wiec dark mode dziala sam.
   ============================================================ */

.oms-pc {
  --pc-accent: #6366f1;
  --pc-accent-2: #8b5cf6;
  --pc-cyan: #0891b2;
  --pc-cyan-2: #06b6d4;
  --pc-danger: #e11d48;
  --pc-line: var(--soft-border);
  --pc-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --pc-shadow: 0 1px 2px rgba(16, 24, 40, 0.04), 0 18px 40px -28px rgba(16, 24, 40, 0.45);
}

.oms-p2-legacy .oms-pc.oms-profiter-admin-panel {
  border: 1px solid var(--pc-line);
  border-radius: 18px;
  background: var(--panel-bg);
  box-shadow: var(--pc-shadow);
}

/* ---- naglowek rozwijany ---- */
.oms-p2-legacy .oms-pc > summary {
  padding: 16px 20px;
  gap: 16px;
  list-style: none;
}

.oms-p2-legacy .oms-pc > summary::-webkit-details-marker { display: none; }

.oms-pc-sum-main {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
}

.oms-pc-sum-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--pc-accent), var(--pc-accent-2));
  box-shadow: 0 8px 18px -10px rgba(99, 102, 241, 0.9);
  color: #ffffff;
}

.oms-pc-sum-mark svg { width: 19px; height: 19px; }

.oms-pc-sum-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.oms-p2-legacy .oms-pc .oms-pc-sum-text > span {
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.oms-p2-legacy .oms-pc .oms-pc-sum-text small {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-secondary);
}

.oms-pc-sum-chevron {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  border-radius: 9px;
  border: 1px solid var(--pc-line);
  color: var(--text-secondary);
  transition: transform 180ms ease, background 180ms ease, color 180ms ease;
}

.oms-pc-sum-chevron svg { width: 15px; height: 15px; }
.oms-pc[open] .oms-pc-sum-chevron { transform: rotate(180deg); background: var(--soft-hover); color: var(--text-primary); }
.oms-p2-legacy .oms-pc[open] > summary { border-bottom: 1px solid var(--pc-line); }

/* ---- siatka kart ---- */
.oms-p2-legacy .oms-pc .oms-analytics-split {
  grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
  gap: 16px;
}

.oms-p2-legacy .oms-pc .oms-pc-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--pc-line);
  border-radius: 16px;
  background: var(--panel-bg);
  padding: 16px 16px 14px;
  box-shadow: var(--pc-shadow);
}

.oms-pc-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: linear-gradient(90deg, var(--pc-accent), var(--pc-accent-2));
  opacity: 0.9;
}

.oms-pc-card-products::before { background: linear-gradient(90deg, var(--pc-cyan), var(--pc-cyan-2)); }

.oms-pc-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.oms-pc-head-main {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  min-width: 0;
}

.oms-pc-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 11px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--pc-accent), var(--pc-accent-2));
  box-shadow: 0 10px 20px -12px rgba(99, 102, 241, 0.95);
}

.oms-pc-icon-products { background: linear-gradient(135deg, var(--pc-cyan), var(--pc-cyan-2)); box-shadow: 0 10px 20px -12px rgba(8, 145, 178, 0.95); }
.oms-pc-icon svg { width: 18px; height: 18px; }

.oms-p2-legacy .oms-pc .oms-pc-title {
  font-size: 13.5px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.oms-p2-legacy .oms-pc .oms-pc-sub {
  margin-top: 2px;
  font-size: 11.5px;
  font-weight: 550;
  line-height: 1.45;
  color: var(--text-secondary);
}

.oms-pc-total {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 1px;
  white-space: nowrap;
}

.oms-p2-legacy .oms-pc .oms-pc-total span {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.oms-p2-legacy .oms-pc .oms-pc-total strong {
  font-family: var(--pc-mono);
  font-size: 16px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

/* ---- formularze ---- */
.oms-p2-legacy .oms-pc .oms-pc-form {
  display: grid;
  grid-template-columns: minmax(140px, 1fr) auto 128px auto;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
}

.oms-p2-legacy .oms-pc .oms-pc-form-products {
  grid-template-columns: minmax(130px, 0.9fr) 132px minmax(150px, 1fr) auto;
}

.oms-p2-legacy .oms-pc .oms-pc-field {
  width: 100%;
  min-width: 0;
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  transition: border-color 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

.oms-p2-legacy .oms-pc select.oms-pc-field {
  padding-right: 30px;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'><path d='m6 9 6 6 6-6'/></svg>");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 14px 14px;
}

.oms-p2-legacy .oms-pc .oms-pc-field::placeholder { color: var(--text-secondary); font-weight: 500; opacity: 0.75; }

.oms-p2-legacy .oms-pc .oms-pc-field:hover { border-color: rgba(99, 102, 241, 0.45); }

.oms-p2-legacy .oms-pc .oms-pc-field:focus {
  outline: none;
  border-color: var(--pc-accent);
  box-shadow: 0 0 0 3.5px rgba(99, 102, 241, 0.16);
}

.oms-pc-money { position: relative; display: flex; align-items: center; }
.oms-pc-money input { padding-right: 30px !important; text-align: right; font-family: var(--pc-mono); font-variant-numeric: tabular-nums; }
.oms-p2-legacy .oms-pc .oms-pc-money > span {
  position: absolute;
  right: 11px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-secondary);
  pointer-events: none;
}

/* segmentowany przelacznik typu kosztu */
.oms-pc-seg {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border-radius: 11px;
  background: var(--bg-tertiary);
  border: 1px solid var(--pc-line);
}

.oms-pc-seg label { position: relative; display: inline-flex; }
.oms-pc-seg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }

.oms-p2-legacy .oms-pc .oms-pc-seg span {
  display: grid;
  place-items: center;
  min-width: 66px;
  height: 30px;
  padding: 0 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.oms-p2-legacy .oms-pc .oms-pc-seg input:checked + span {
  background: var(--panel-bg);
  color: var(--pc-accent);
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.10), 0 4px 10px -6px rgba(16, 24, 40, 0.35);
}

.oms-p2-legacy .oms-pc .oms-pc-seg input:focus-visible + span { box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25); }
.oms-p2-legacy .oms-pc .oms-pc-seg label:nth-child(2) input:checked + span { color: var(--pc-cyan); }

/* przyciski */
.oms-p2-legacy .oms-pc .oms-pc-add {
  height: 38px;
  padding: 0 18px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--pc-accent), var(--pc-accent-2));
  color: #ffffff;
  font: inherit;
  font-size: 12.5px;
  font-weight: 750;
  letter-spacing: 0.005em;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 10px 22px -12px rgba(99, 102, 241, 0.95);
  transition: transform 140ms ease, box-shadow 140ms ease, filter 140ms ease;
}

.oms-p2-legacy .oms-pc .oms-pc-add:hover { transform: translateY(-1px); filter: saturate(1.08); box-shadow: 0 14px 26px -12px rgba(99, 102, 241, 1); }
.oms-p2-legacy .oms-pc .oms-pc-add:active { transform: translateY(0); }
.oms-p2-legacy .oms-pc .oms-pc-form-products .oms-pc-add { background: linear-gradient(135deg, var(--pc-cyan), var(--pc-cyan-2)); box-shadow: 0 10px 22px -12px rgba(8, 145, 178, 0.95); }

.oms-p2-legacy .oms-pc .oms-pc-ghost-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 34px;
  padding: 0 13px;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  background: var(--panel-bg);
  color: var(--text-primary);
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color 140ms ease, background 140ms ease, color 140ms ease, transform 140ms ease;
}

.oms-p2-legacy .oms-pc .oms-pc-ghost-btn svg { width: 14px; height: 14px; opacity: 0.75; }
.oms-p2-legacy .oms-pc .oms-pc-ghost-btn:hover { border-color: var(--pc-accent); color: var(--pc-accent); background: var(--soft-hover); transform: translateY(-1px); }

.oms-p2-legacy .oms-pc .oms-profiter-admin-actions { padding: 16px 20px 0; }

/* ---- lista kosztow miesiaca ---- */
.oms-p2-legacy .oms-pc .oms-pc-list { max-height: 420px; overflow: auto; margin: 0; }
.oms-pc-list::-webkit-scrollbar { width: 8px; }
.oms-pc-list::-webkit-scrollbar-thumb { border-radius: 8px; background: rgba(100, 116, 139, 0.28); }

.oms-pc-group + .oms-pc-group { margin-top: 14px; }

.oms-pc-group-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 0 2px 6px;
}

.oms-p2-legacy .oms-pc .oms-pc-group-label {
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pc-accent);
}

.oms-pc-group[data-cost-type="variable"] .oms-pc-group-label { color: var(--pc-cyan); }

.oms-p2-legacy .oms-pc .oms-pc-group-count {
  flex: 1;
  min-width: 0;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.oms-p2-legacy .oms-pc .oms-pc-group-total {
  font-family: var(--pc-mono);
  font-size: 12.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text-primary);
}

.oms-p2-legacy .oms-pc .oms-pc-group-total em {
  margin-left: 7px;
  font-style: normal;
  font-family: Inter, sans-serif;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-secondary);
}

.oms-pc-group-bar {
  height: 3px;
  margin-bottom: 6px;
  border-radius: 3px;
  background: var(--bg-tertiary);
  overflow: hidden;
}

.oms-pc-group-bar i {
  display: block;
  height: 100%;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--pc-accent), var(--pc-accent-2));
  transition: width 320ms ease;
}

.oms-pc-group[data-cost-type="variable"] .oms-pc-group-bar i { background: linear-gradient(90deg, var(--pc-cyan), var(--pc-cyan-2)); }

.oms-pc-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 26px;
  align-items: center;
  gap: 10px;
  height: 40px;
  padding: 0 8px;
  border-radius: 10px;
  border-bottom: 1px solid var(--pc-line);
  transition: background 140ms ease;
}

.oms-pc-row:last-child { border-bottom: none; }
.oms-pc-row:hover { background: var(--soft-hover); }

.oms-p2-legacy .oms-pc .oms-pc-row-name {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  font-size: 13px;
  font-weight: 650;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.oms-p2-legacy .oms-pc .oms-pc-auto {
  flex: 0 0 auto;
  padding: 2px 6px;
  border-radius: 6px;
  background: rgba(245, 158, 11, 0.14);
  color: #b45309;
  font-style: normal;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.oms-p2-legacy .oms-pc .oms-pc-amt {
  font-family: var(--pc-mono);
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.oms-p2-legacy .oms-pc .oms-pc-del {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  opacity: 0;
  transition: opacity 140ms ease, background 140ms ease, color 140ms ease;
}

.oms-pc-del svg { width: 13px; height: 13px; }
.oms-pc-row:hover .oms-pc-del,
.oms-pc-del:focus-visible { opacity: 1; }
.oms-p2-legacy .oms-pc .oms-pc-del:hover { background: rgba(225, 29, 72, 0.12); color: var(--pc-danger); }

/* ---- pusty stan ---- */
.oms-pc-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 26px 16px;
  border: 1px dashed var(--pc-line);
  border-radius: 12px;
  text-align: center;
}

.oms-pc-empty-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 4px;
  border-radius: 11px;
  background: var(--bg-tertiary);
  color: var(--pc-accent);
  font-size: 17px;
  font-weight: 800;
}

.oms-p2-legacy .oms-pc .oms-pc-empty strong { font-size: 13px; font-weight: 750; color: var(--text-primary); }
.oms-p2-legacy .oms-pc .oms-pc-empty small { max-width: 320px; font-size: 11.5px; font-weight: 550; line-height: 1.5; color: var(--text-secondary); }

/* ---- toolbar i tabela kosztow produktow ---- */
.oms-p2-legacy .oms-pc .oms-pc-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 10px 0 12px;
}

.oms-pc-search { position: relative; flex: 1 1 220px; min-width: 180px; display: flex; align-items: center; }
.oms-pc-search svg { position: absolute; left: 11px; width: 15px; height: 15px; color: var(--text-secondary); opacity: 0.8; pointer-events: none; }
.oms-p2-legacy .oms-pc .oms-pc-search input { padding-left: 34px; }
.oms-p2-legacy .oms-pc .oms-pc-toolbar select.oms-pc-field { flex: 0 0 auto; width: auto; min-width: 168px; }

.oms-p2-legacy .oms-pc .oms-pc-tablewrap { max-height: 440px; overflow: auto; border-radius: 12px; border: 1px solid var(--pc-line); }

.oms-p2-legacy .oms-pc .oms-pc-table { width: 100%; border-collapse: separate; border-spacing: 0; }

.oms-p2-legacy .oms-pc .oms-pc-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 9px 12px;
  border-bottom: 1px solid var(--pc-line);
  background: var(--bg-tertiary);
  font-size: 9.5px;
  font-weight: 850;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  text-align: left;
  color: var(--text-secondary);
  white-space: nowrap;
}

.oms-p2-legacy .oms-pc .oms-pc-table th.num,
.oms-p2-legacy .oms-pc .oms-pc-table td.num { text-align: right; }

.oms-p2-legacy .oms-pc .oms-pc-table tbody td {
  padding: 9px 12px;
  border-bottom: 1px solid var(--pc-line);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-primary);
  vertical-align: middle;
}

.oms-p2-legacy .oms-pc .oms-pc-table tbody tr:last-child td { border-bottom: none; }
.oms-p2-legacy .oms-pc .oms-pc-table tbody tr:hover td { background: var(--soft-hover); }
.oms-p2-legacy .oms-pc .oms-pc-table td.mono { font-family: var(--pc-mono); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.oms-p2-legacy .oms-pc .oms-pc-table td.muted { font-size: 11.5px; font-weight: 550; color: var(--text-secondary); white-space: nowrap; }
.oms-p2-legacy .oms-pc .oms-pc-table td.row-action { width: 84px; text-align: right; }

.oms-p2-legacy .oms-pc .oms-pc-store {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid var(--pc-line);
  background: var(--bg-tertiary);
  font-size: 11px;
  font-weight: 700;
  color: var(--text-secondary);
  white-space: nowrap;
}

.oms-p2-legacy .oms-pc .oms-pc-edit {
  height: 27px;
  padding: 0 11px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--text-secondary);
  font: inherit;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  opacity: 0;
  transition: opacity 140ms ease, border-color 140ms ease, color 140ms ease, background 140ms ease;
}

.oms-p2-legacy .oms-pc .oms-pc-table tbody tr:hover .oms-pc-edit,
.oms-p2-legacy .oms-pc .oms-pc-edit:focus-visible { opacity: 1; border-color: var(--border-color); color: var(--text-primary); }
.oms-p2-legacy .oms-pc .oms-pc-edit:hover { border-color: var(--pc-cyan); color: var(--pc-cyan); background: rgba(8, 145, 178, 0.08); }

.oms-p2-legacy .oms-pc .oms-analytics-cost-hint {
  margin: 0 0 4px;
  padding: 9px 11px;
  border-radius: 10px;
  border: 1px solid var(--pc-line);
  background: var(--bg-tertiary);
  font-size: 11.5px;
  line-height: 1.5;
}

.oms-p2-legacy .oms-pc .oms-analytics-cost-details {
  margin-top: 12px;
  border-top: 1px solid var(--pc-line);
  padding-top: 10px;
}

.oms-p2-legacy .oms-pc .oms-analytics-cost-details > summary {
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-secondary);
}

.oms-p2-legacy .oms-pc .oms-analytics-cost-details > summary:hover { color: var(--pc-accent); }

/* ---- dark mode: doprecyzowanie tam, gdzie stare reguly biją tokeny ---- */
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-field {
  border-color: rgba(255, 255, 255, 0.14);
  background-color: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
}

/* shorthand `background` kasuje strzalke selecta, wiec w dark tylko background-color */
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc select.oms-pc-field {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a0a0c0' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'><path d='m6 9 6 6 6-6'/></svg>");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 14px 14px;
}

.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-field:hover { border-color: rgba(129, 140, 248, 0.55); }
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-field:focus { border-color: #818cf8; box-shadow: 0 0 0 3.5px rgba(129, 140, 248, 0.2); }
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc { --pc-accent: #818cf8; --pc-accent-2: #a78bfa; --pc-cyan: #22d3ee; --pc-cyan-2: #67e8f9; }
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-seg { background: rgba(255, 255, 255, 0.05); }
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-seg input:checked + span { background: rgba(255, 255, 255, 0.12); }
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-auto { background: rgba(245, 158, 11, 0.18); color: #fbbf24; }
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-table thead th,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-store,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-analytics-cost-hint,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-empty-mark,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-group-bar { background: rgba(255, 255, 255, 0.06); }

@media (max-width: 900px) {
  .oms-p2-legacy .oms-pc .oms-pc-form,
  .oms-p2-legacy .oms-pc .oms-pc-form-products {
    grid-template-columns: minmax(0, 1fr);
  }
  .oms-p2-legacy .oms-pc .oms-pc-seg { justify-content: stretch; }
  .oms-p2-legacy .oms-pc .oms-pc-seg span { flex: 1; }
  .oms-pc-del, .oms-p2-legacy .oms-pc .oms-pc-edit { opacity: 1; }
}

/* ---- Profiter panel kosztow: uklad kart i doprecyzowanie tabel ---- */
.oms-p2-legacy .oms-pc .oms-analytics-split {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.oms-p2-legacy .oms-pc .oms-pc-card-costs { grid-column: 1 / -1; }
.oms-p2-legacy .oms-pc .oms-pc-card-days::before { background: linear-gradient(90deg, #0ea5e9, #38bdf8); }
.oms-p2-legacy .oms-pc .oms-pc-card-manual::before { background: linear-gradient(90deg, #f59e0b, #fbbf24); }
.oms-pc-icon-days { background: linear-gradient(135deg, #0ea5e9, #38bdf8); box-shadow: 0 10px 20px -12px rgba(14, 165, 233, 0.95); }
.oms-pc-icon-manual { background: linear-gradient(135deg, #f59e0b, #fbbf24); box-shadow: 0 10px 20px -12px rgba(245, 158, 11, 0.95); }

.oms-p2-legacy .oms-pc .oms-pc-form { grid-template-columns: minmax(180px, 1fr) auto 150px auto; }
.oms-p2-legacy .oms-pc .oms-pc-form-manual { grid-template-columns: minmax(150px, 0.9fr) 128px minmax(150px, 1fr) auto; }

/* lista kosztow miesiaca: dwie kolumny grup, gdy karta jest szeroka */
@media (min-width: 1180px) {
  .oms-p2-legacy .oms-pc .oms-pc-card-costs .oms-pc-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 26px;
    align-items: start;
    max-height: none;
  }
  .oms-p2-legacy .oms-pc .oms-pc-card-costs .oms-pc-group + .oms-pc-group { margin-top: 0; }
}

/* szerokosci kolumn w tabelach */
.oms-p2-legacy .oms-pc .oms-pc-table td.num,
.oms-p2-legacy .oms-pc .oms-pc-table th.num { width: 132px; }
.oms-p2-legacy .oms-pc .oms-pc-table td.muted { width: 148px; }
.oms-p2-legacy .oms-pc .oms-pc-card-days .oms-pc-table td.muted { width: auto; }
.oms-p2-legacy .oms-pc .oms-pc-table td.pos { color: #15803d; }
.oms-p2-legacy .oms-pc .oms-pc-table td.neg { color: var(--pc-danger); }
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-table td.pos { color: #4ade80; }
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-table td.neg { color: #fb7185; }

/* korekty dnia: wiersze w tym samym jezyku co lista kosztow */
.oms-p2-legacy .oms-pc .oms-manual-adjustment-row {
  border: none;
  border-bottom: 1px solid var(--pc-line);
  border-radius: 10px;
  background: transparent;
  padding: 8px;
  color: var(--text-primary);
  font-size: 12.5px;
}

.oms-p2-legacy .oms-pc .oms-manual-adjustment-row:hover { background: var(--soft-hover); }
.oms-p2-legacy .oms-pc .oms-manual-adjustment-row:last-child { border-bottom: none; }

/* ---- Koszty miesiaca: ksiegowy uklad dwukolumnowy w szerokiej karcie ---- */
@media (min-width: 1180px) {
  .oms-p2-legacy .oms-pc .oms-pc-card-costs .oms-pc-list {
    display: block;
    max-height: none;
  }
}

.oms-p2-legacy .oms-pc .oms-pc-card-costs .oms-pc-group-rows {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 0 28px;
}

.oms-p2-legacy .oms-pc .oms-pc-card-costs .oms-pc-group + .oms-pc-group { margin-top: 18px; }

/* ---- ostatnie dostrojenie proporcji ---- */
.oms-p2-legacy .oms-pc .oms-pc-card-costs .oms-pc-form {
  grid-template-columns: minmax(220px, 460px) auto 170px auto;
  justify-content: start;
}

.oms-p2-legacy .oms-pc .oms-pc-form-manual {
  grid-template-columns: minmax(185px, 1fr) 122px minmax(150px, 1fr) auto;
}

.oms-p2-legacy .oms-pc .oms-pc-card-products .oms-pc-table th:nth-child(1),
.oms-p2-legacy .oms-pc .oms-pc-card-products .oms-pc-table td:nth-child(1) { width: 140px; }
.oms-p2-legacy .oms-pc .oms-pc-card-products .oms-pc-table th:nth-child(2),
.oms-p2-legacy .oms-pc .oms-pc-card-products .oms-pc-table td:nth-child(2) { width: 240px; }
.oms-p2-legacy .oms-pc .oms-pc-card-products .oms-pc-table td.muted { width: auto; }
.oms-p2-legacy .oms-pc .oms-pc-card-products .oms-pc-table td.row-action { width: 96px; }
.oms-p2-legacy .oms-pc .oms-pc-form-products { grid-template-columns: minmax(130px, 0.9fr) 132px minmax(210px, 0.5fr) auto; }

/* ============================================================
   Koszty miesiaca - edycja inline (dwie kolumny jak w starym dashboardzie)
   ============================================================ */
.oms-p2-legacy .oms-pc .oms-pc-card-costs .oms-pc-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 8px 30px;
  align-items: start;
  max-height: none;
}

.oms-p2-legacy .oms-pc .oms-pc-card-costs .oms-pc-group + .oms-pc-group { margin-top: 0; }
.oms-p2-legacy .oms-pc .oms-pc-card-costs .oms-pc-group-rows { display: block; }

.oms-p2-legacy .oms-pc .oms-pc-row {
  grid-template-columns: minmax(0, 1fr) auto 30px 30px;
  gap: 6px;
  height: 42px;
  padding: 0 4px;
}

.oms-p2-legacy .oms-pc .oms-pc-row.is-draft {
  grid-template-columns: minmax(0, 1fr) auto 30px;
  border-bottom-color: transparent;
  background: rgba(99, 102, 241, 0.06);
}

.oms-p2-legacy .oms-pc .oms-pc-row[data-auto="1"] { grid-template-columns: minmax(0, 1fr) auto auto 30px 30px; }

.oms-p2-legacy .oms-pc .oms-pc-cell {
  width: 100%;
  min-width: 0;
  height: 32px;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--text-primary);
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  transition: border-color 130ms ease, background 130ms ease, box-shadow 130ms ease;
}

.oms-p2-legacy .oms-pc .oms-pc-cell.num {
  width: 104px;
  padding-right: 22px;
  text-align: right;
  font-family: var(--pc-mono);
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.oms-p2-legacy .oms-pc .oms-pc-cell::placeholder { color: var(--text-secondary); font-weight: 500; opacity: 0.7; }
.oms-p2-legacy .oms-pc .oms-pc-row:hover .oms-pc-cell { border-color: var(--pc-line); background: var(--panel-bg); }

.oms-p2-legacy .oms-pc .oms-pc-cell:focus {
  outline: none;
  border-color: var(--pc-accent);
  background: var(--panel-bg);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.16);
}

.oms-pc-group[data-cost-type="variable"] .oms-pc-cell:focus { border-color: var(--pc-cyan); box-shadow: 0 0 0 3px rgba(8, 145, 178, 0.16); }

.oms-pc-cell-money { position: relative; display: flex; align-items: center; }
.oms-p2-legacy .oms-pc .oms-pc-cell-money > span {
  position: absolute;
  right: 7px;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-secondary);
  pointer-events: none;
}

/* przyciski w wierszu: widoczne dopiero przy najechaniu, zeby lista byla czysta */
.oms-p2-legacy .oms-pc .oms-pc-rowbtn {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  opacity: 0;
  transition: opacity 130ms ease, background 130ms ease, color 130ms ease;
}

.oms-pc-rowbtn svg { width: 14px; height: 14px; }
.oms-pc-row:hover .oms-pc-rowbtn,
.oms-pc-rowbtn:focus-visible,
.oms-pc-row.is-draft .oms-pc-rowbtn { opacity: 1; }
.oms-p2-legacy .oms-pc .oms-pc-rowbtn:hover { background: var(--soft-hover); color: var(--pc-accent); }
.oms-p2-legacy .oms-pc .oms-pc-rowbtn.danger:hover { background: rgba(225, 29, 72, 0.12); color: var(--pc-danger); }

/* stany zapisu wiersza */
.oms-pc-row[data-row-state="saving"] { background: rgba(99, 102, 241, 0.08); }
.oms-pc-row[data-row-state="error"] .oms-pc-cell { border-color: var(--pc-danger); }

.oms-p2-legacy .oms-pc .oms-pc-add-row {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 9px 12px;
  border: 1px dashed var(--pc-line);
  border-radius: 10px;
  background: transparent;
  color: var(--text-secondary);
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: border-color 140ms ease, color 140ms ease, background 140ms ease;
}

.oms-p2-legacy .oms-pc .oms-pc-add-row:hover { border-color: var(--pc-accent); color: var(--pc-accent); background: rgba(99, 102, 241, 0.06); }
.oms-pc-group[data-cost-type="variable"] .oms-pc-add-row:hover { border-color: var(--pc-cyan); color: var(--pc-cyan); background: rgba(8, 145, 178, 0.06); }

.oms-p2-legacy .oms-pc .oms-pc-group-empty {
  padding: 14px 8px;
  font-size: 12px;
  font-weight: 550;
  color: var(--text-secondary);
}

.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-row:hover .oms-pc-cell,
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-cell:focus { background: rgba(255, 255, 255, 0.06); }
.oms-app[data-theme="dark"] .oms-p2-legacy .oms-pc .oms-pc-row.is-draft { background: rgba(129, 140, 248, 0.12); }

/* ---- Profiter/koszty: precz z natywnymi spinnerami number ---- */
.oms-p2-legacy .oms-pc input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

.oms-p2-legacy .oms-pc input[type="number"]::-webkit-outer-spin-button,
.oms-p2-legacy .oms-pc input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
}

/* ---- skok z kafla miesiaca do edycji grupy kosztow ---- */
.oms-p2-legacy .oms-p2-month-card[data-cost-jump] { cursor: pointer; }
.oms-p2-legacy .oms-p2-month-card[data-cost-jump]:hover { transform: translateY(-2px); }

.oms-pc-group.is-flash {
  border-radius: 12px;
  animation: omsPcFlash 1.8s ease-out;
}

@keyframes omsPcFlash {
  0% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.45); background: rgba(99, 102, 241, 0.12); }
  60% { box-shadow: 0 0 0 6px rgba(99, 102, 241, 0); background: rgba(99, 102, 241, 0.06); }
  100% { box-shadow: none; background: transparent; }
}

.oms-pc-group[data-cost-type="variable"].is-flash { animation-name: omsPcFlashCyan; }

@keyframes omsPcFlashCyan {
  0% { box-shadow: 0 0 0 0 rgba(8, 145, 178, 0.45); background: rgba(8, 145, 178, 0.12); }
  60% { box-shadow: 0 0 0 6px rgba(8, 145, 178, 0); background: rgba(8, 145, 178, 0.06); }
  100% { box-shadow: none; background: transparent; }
}

.oms-p2-legacy .oms-pc .oms-pc-add-row:focus-visible {
  outline: none;
  border-color: var(--pc-accent);
  color: var(--pc-accent);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.18);
}

/* ---- Profiter: widoczny stan ladowania przy zmianie miesiaca ---- */
.oms-p2-legacy .oms-p2-loading {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  height: 36px;
  border: 1px solid rgba(99, 102, 241, 0.28);
  border-radius: 12px;
  background: rgba(99, 102, 241, 0.08);
  color: #4f46e5;
  font-size: 12px;
  font-weight: 700;
}

.oms-p2-legacy .oms-p2-loading[hidden] { display: none; }

.oms-p2-spinner {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(99, 102, 241, 0.28);
  border-top-color: #4f46e5;
  animation: omsP2Spin 700ms linear infinite;
}

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

/* dane w trakcie doczytywania: przygaszone i nieklikalne, zeby nie czytac starych liczb jak nowych */
.oms-p2-legacy .is-loading {
  position: relative;
  opacity: 0.45;
  pointer-events: none;
  transition: opacity 160ms ease;
}

.oms-app[data-theme="dark"] .oms-p2-legacy .oms-p2-loading {
  border-color: rgba(129, 140, 248, 0.35);
  background: rgba(129, 140, 248, 0.14);
  color: #c7d2fe;
}

.oms-app[data-theme="dark"] .oms-p2-spinner { border-color: rgba(199, 210, 254, 0.28); border-top-color: #c7d2fe; }

@media (prefers-reduced-motion: reduce) {
  .oms-p2-spinner { animation-duration: 2s; }
}

/* pasek postepu u gory Profitera - spinner przy selektorze bywa przeoczony */
.oms-p2-legacy .oms-p2-shell.is-busy { position: relative; }

.oms-p2-legacy .oms-p2-shell.is-busy::before {
  content: "";
  position: sticky;
  top: 0;
  z-index: 40;
  display: block;
  height: 3px;
  margin: 0 0 -3px;
  border-radius: 3px;
  background: linear-gradient(90deg, rgba(99, 102, 241, 0) 0%, #6366f1 35%, #22d3ee 65%, rgba(34, 211, 238, 0) 100%);
  background-size: 45% 100%;
  background-repeat: no-repeat;
  animation: omsP2Progress 1100ms ease-in-out infinite;
}

@keyframes omsP2Progress {
  0% { background-position: -45% 0; }
  100% { background-position: 145% 0; }
}

.oms-p2-legacy .oms-p2-loading b { font-weight: 750; }

/* Wyszukiwarka punktu odbioru na karcie zamowienia */
.oms-pickup-point-picker {
  margin-top: 10px;
  padding: 10px;
  border: 1px solid rgba(120, 140, 170, 0.28);
  border-radius: 10px;
  background: rgba(120, 140, 170, 0.06);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.oms-pickup-point-providers { display: flex; gap: 6px; flex-wrap: wrap; }

.oms-pickup-point-picker .oms-inline-edit-input { width: 100%; }

.oms-pickup-point-results {
  max-height: 260px;
  overflow-y: auto;
  border: 1px solid rgba(120, 140, 170, 0.22);
  border-radius: 8px;
  background: #fff;
}

.oms-pickup-point-option {
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-bottom: 1px solid rgba(120, 140, 170, 0.16);
  background: transparent;
  text-align: left;
  cursor: pointer;
  font: inherit;
}

.oms-pickup-point-option:last-child { border-bottom: 0; }
.oms-pickup-point-option:hover { background: rgba(52, 120, 246, 0.08); }

.oms-pickup-point-option-head { display: flex; gap: 8px; align-items: baseline; }
.oms-pickup-point-option-head strong { font-size: 13px; font-weight: 650; }
.oms-pickup-point-option-head em { font-size: 11px; font-style: normal; color: #7d8aa0; }
.oms-pickup-point-option-name { font-size: 12px; color: #2f3b4f; }
.oms-pickup-point-option-address { font-size: 11px; color: #7d8aa0; }
.oms-combo-empty.error { color: #c0392b; }

/* Magazyn: zakladka Kategorie v3 - katalog premium (2026-08-31) */
.oms-cat2 { --c2-ink:#101426; --c2-mute:#6b7492; --c2-line:#e6e9f2; --c2-card:#ffffff; --c2-bg:#f6f7fb; --c2-acc:#3b5bfd; --c2-acc-soft:#eef1ff; --c2-ok:#12925c; --c2-warn:#d97a06; --c2-bad:#d9382c;
  font-family:"Manrope","Inter",system-ui,sans-serif; color:var(--c2-ink); background:var(--c2-bg); border-radius:18px; padding:22px; display:flex; flex-direction:column; gap:18px; }
.oms-cat2 h2, .oms-cat2 h3 { font-family:"Sora","Manrope",sans-serif; margin:0; }
.oms-cat2-header { display:flex; align-items:flex-start; justify-content:space-between; gap:14px; }
.oms-cat2-header h2 { font-size:26px; font-weight:700; letter-spacing:-0.02em; }
.oms-cat2-header p { margin:4px 0 0; color:var(--c2-mute); font-size:13.5px; font-variant-numeric:tabular-nums; }
.oms-cat2-tiles { display:grid; grid-template-columns:repeat(auto-fill,minmax(200px,1fr)); gap:12px; }
.oms-cat2-tile { display:flex; align-items:center; gap:12px; padding:16px; background:var(--c2-card); border:1.5px solid var(--c2-line); border-radius:14px; cursor:pointer; font:inherit; color:inherit; text-align:left; transition:box-shadow .15s, border-color .15s, transform .12s; box-shadow:0 1px 2px rgba(16,20,38,.04); }
.oms-cat2-tile:hover { box-shadow:0 8px 24px rgba(16,20,38,.08); transform:translateY(-1px); }
.oms-cat2-tile.active { border-color:var(--c2-acc); box-shadow:0 0 0 3px var(--c2-acc-soft), 0 8px 24px rgba(59,91,253,.10); }
.oms-cat2-tile.unassigned { border-color:var(--c2-warn); }
.oms-cat2-tile-icon { width:46px; height:46px; border-radius:12px; background:var(--c2-acc-soft); display:flex; align-items:center; justify-content:center; font-size:24px; flex:none; }
.oms-cat2-tile-body { display:flex; flex-direction:column; gap:2px; min-width:0; }
.oms-cat2-tile-body strong { font-family:"Sora",sans-serif; font-size:15.5px; font-weight:700; }
.oms-cat2-tile.active .oms-cat2-tile-body strong { color:var(--c2-acc); }
.oms-cat2-tile-body span { color:var(--c2-mute); font-size:12.5px; font-variant-numeric:tabular-nums; }
.oms-cat2-chips { display:flex; flex-wrap:wrap; gap:8px; }
.oms-cat2-chips button { display:inline-flex; align-items:center; gap:8px; padding:9px 16px; border-radius:12px; border:1.5px solid var(--c2-line); background:var(--c2-card); color:var(--c2-ink); font:inherit; font-size:13.5px; font-weight:600; cursor:pointer; transition:border-color .15s; }
.oms-cat2-chips button span { color:var(--c2-mute); font-weight:600; font-size:12px; background:var(--c2-bg); border-radius:8px; padding:1px 7px; font-variant-numeric:tabular-nums; }
.oms-cat2-chips button:hover { border-color:var(--c2-acc); }
.oms-cat2-chips button.active { background:var(--c2-acc); border-color:var(--c2-acc); color:#fff; box-shadow:0 6px 16px rgba(59,91,253,.25); }
.oms-cat2-chips button.active span { background:rgba(255,255,255,.2); color:#fff; }
.oms-cat2-chips button.more { color:var(--c2-acc); border-style:dashed; }
.oms-cat2-list { background:var(--c2-card); border:1px solid var(--c2-line); border-radius:16px; overflow:visible; box-shadow:0 1px 2px rgba(16,20,38,.04); }
.oms-cat2-list-top { display:flex; align-items:center; justify-content:space-between; gap:14px; flex-wrap:wrap; padding:18px 20px 12px; }
.oms-cat2-list-top h3 { font-size:17px; font-weight:700; }
.oms-cat2-list-top h3 span { color:var(--c2-mute); font-weight:600; }
.oms-cat2-list-tools { display:flex; gap:10px; align-items:center; flex-wrap:wrap; }
.oms-cat2-search { display:flex; align-items:center; gap:8px; border:1.5px solid var(--c2-line); border-radius:11px; padding:8px 12px; min-width:240px; background:var(--c2-card); color:var(--c2-mute); }
.oms-cat2-search input { border:none; outline:none; background:transparent; font:inherit; color:var(--c2-ink); flex:1; }
.oms-cat2 select { font:inherit; font-size:13px; font-weight:600; padding:8px 10px; border-radius:11px; border:1.5px solid var(--c2-line); background:var(--c2-card); color:var(--c2-ink); }
.oms-cat2-head { display:grid; grid-template-columns:46px minmax(220px,520px) 150px 130px 150px 1fr 56px; gap:14px; padding:9px 20px; border-top:1px solid var(--c2-line); border-bottom:1px solid var(--c2-line); background:var(--c2-bg); color:var(--c2-mute); font-size:12px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; }
.oms-cat2-head span:first-child { grid-column:1 / span 2; }
.oms-cat2-row { position:relative; display:grid; grid-template-columns:46px minmax(220px,520px) 150px 130px 150px 1fr 56px; gap:14px; align-items:center; padding:12px 20px; border-bottom:1px solid var(--c2-line); }
.oms-cat2-row:last-of-type { border-bottom:none; }
.oms-cat2-row:hover { background:var(--c2-bg); }
.oms-cat2-thumb { width:46px; height:46px; border-radius:10px; overflow:hidden; background:var(--c2-bg); border:1px solid var(--c2-line); display:flex; align-items:center; justify-content:center; }
.oms-cat2-thumb img { width:100%; height:100%; object-fit:cover; display:block; }
.oms-cat2-name { display:flex; flex-direction:column; align-items:flex-start; gap:2px; min-width:0; }
.oms-cat2-name strong { font-size:14px; font-weight:700; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; max-width:100%; }
.oms-cat2-name strong b { color:var(--c2-acc); font-weight:800; }
.oms-cat2-name small { color:var(--c2-mute); font-size:12px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; max-width:100%; }
.oms-cat2-stock { display:flex; flex-direction:column; gap:1px; font-variant-numeric:tabular-nums; }
.oms-cat2-stock strong { font-size:13.5px; font-weight:700; }
.oms-cat2-stock em { font-style:normal; font-size:12px; font-weight:700; }
.oms-cat2-stock em.st-ok { color:var(--c2-ok); } .oms-cat2-stock em.st-low { color:var(--c2-warn); } .oms-cat2-stock em.st-out { color:var(--c2-bad); }
.oms-cat2-stock small { color:var(--c2-mute); font-size:11px; }
.oms-cat2-value { font-weight:700; font-variant-numeric:tabular-nums; }
.oms-cat2-value small { color:var(--c2-warn); font-weight:600; font-size:12px; }
.oms-cat2-actions { position:relative; text-align:right; }
.oms-cat2-kebab { width:36px; height:36px; border-radius:10px; border:1.5px solid var(--c2-line); background:var(--c2-card); color:var(--c2-ink); font-size:18px; line-height:1; cursor:pointer; }
.oms-cat2-kebab:hover { border-color:var(--c2-acc); color:var(--c2-acc); }
.oms-cat2-menu { position:absolute; right:0; top:42px; z-index:20; background:var(--c2-card); border:1px solid var(--c2-line); border-radius:12px; box-shadow:0 14px 34px rgba(16,20,38,.14); padding:6px; min-width:210px; }
.oms-cat2-menu button { display:block; width:100%; text-align:left; padding:9px 12px; border:none; background:none; font:inherit; font-size:13.5px; font-weight:600; color:var(--c2-ink); border-radius:8px; cursor:pointer; }
.oms-cat2-menu button:hover { background:var(--c2-acc-soft); color:var(--c2-acc); }
.oms-cat2-move { grid-column:1 / -1; display:flex; flex-wrap:wrap; align-items:end; gap:16px; padding:12px 14px; border:1.5px dashed var(--c2-line); border-radius:12px; background:var(--c2-bg); }
.oms-cat2-move label { display:flex; flex-direction:column; gap:5px; font-size:11.5px; font-weight:700; letter-spacing:.03em; text-transform:uppercase; color:var(--c2-mute); }
.oms-cat2-move select, .oms-cat2-move input { font:inherit; font-size:13.5px; padding:8px 10px; border-radius:10px; border:1.5px solid var(--c2-line); background:var(--c2-card); color:var(--c2-ink); min-width:180px; }
.oms-cat2-move small { color:var(--c2-mute); }
.oms-cat2-pager { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; padding:14px 20px; border-top:1px solid var(--c2-line); color:var(--c2-mute); font-size:13px; font-variant-numeric:tabular-nums; }
.oms-cat2-pager-btns { display:flex; align-items:center; gap:10px; }
.oms-cat2-pager-btns button { width:34px; height:34px; border-radius:10px; border:1.5px solid var(--c2-line); background:var(--c2-card); color:var(--c2-ink); font-size:15px; cursor:pointer; }
.oms-cat2-pager-btns button:disabled { opacity:.4; cursor:default; }
.oms-cat2-pager-btns strong { color:var(--c2-ink); }
.oms-cat-warn { color:#d97a06; }
@media (max-width:900px) { .oms-cat2-head { display:none; } .oms-cat2-row { grid-template-columns:46px 1fr 90px; } .oms-cat2-row .oms-cat2-value, .oms-cat2-row .oms-cat2-actions { display:none; } }
@media (prefers-color-scheme: dark) { .oms-cat2 { /* panel OMS ma wlasny jasny content - celowo jeden jasny motyw */ } }
/* Kategorie v3.1: rodziny z wariantami */
.oms-cat2-row { cursor:pointer; }
.oms-cat2-row.expanded { background:var(--c2-bg); }
.oms-cat2-pills { display:flex; flex-wrap:wrap; gap:5px; margin-top:5px; }
.oms-cat2-pills .vp { font-style:normal; font-size:11.5px; font-weight:700; padding:2px 8px; border-radius:8px; background:var(--c2-bg); border:1px solid var(--c2-line); color:var(--c2-mute); font-variant-numeric:tabular-nums; }
.oms-cat2-pills .vp b { color:var(--c2-ink); }
.oms-cat2-pills .vp-out { background:#fdecea; border-color:#f5c6c0; } .oms-cat2-pills .vp-out b { color:var(--c2-bad); }
.oms-cat2-pills .vp-low { background:#fdf3e3; border-color:#f2ddb8; } .oms-cat2-pills .vp-low b { color:var(--c2-warn); }
.oms-cat2-variants { grid-column:1 / -1; border:1px solid var(--c2-line); border-radius:12px; background:var(--c2-card); overflow:hidden; }
.oms-cat2-variant { display:grid; grid-template-columns:70px minmax(160px,420px) 150px 130px 140px 1fr; gap:12px; align-items:center; padding:9px 14px; border-bottom:1px solid var(--c2-line); font-size:13px; font-variant-numeric:tabular-nums; }
.oms-cat2-variant:last-child { border-bottom:none; }
.oms-cat2-variant strong { font-family:"Sora",sans-serif; }
.oms-cat2-variant .mono { font-family:ui-monospace,Menlo,monospace; font-size:11.5px; color:var(--c2-mute); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.oms-cat2-variant em { font-style:normal; font-weight:700; font-size:12px; }
.oms-cat2-variant em.st-ok { color:var(--c2-ok); } .oms-cat2-variant em.st-low { color:var(--c2-warn); } .oms-cat2-variant em.st-out { color:var(--c2-bad); }
@media (max-width:900px) { .oms-cat2-variant { grid-template-columns:60px 1fr 90px; } .oms-cat2-variant .mono, .oms-cat2-variant span:last-child { display:none; } }

/* Kategorie v3.2: kolumna sprzedazy + zbicie kolumn do srodka */
.oms-cat2-sold { display:flex; flex-direction:column; gap:1px; font-variant-numeric:tabular-nums; }
.oms-cat2-sold strong { font-size:13.5px; font-weight:700; }
.oms-cat2-sold small { color:var(--c2-mute); font-size:11px; }
.oms-cat2-value { display:flex; flex-direction:column; gap:1px; }
.oms-cat2-value small { color:var(--c2-mute); font-weight:600; font-size:11px; }
.oms-cat2-variant .sold { color:var(--c2-mute); }
@media (max-width:1100px) { .oms-cat2-head, .oms-cat2-row { grid-template-columns:46px minmax(200px,1fr) 140px 120px 130px 56px; } .oms-cat2-head span:nth-last-child(2), .oms-cat2-row > span:nth-last-child(2):not(.oms-cat2-actions) { display:none; } }

.oms-return-auto-pending {
  margin: 4px 0 0;
  padding-left: 16px;
  list-style: disc;
  font-size: 12px;
  line-height: 1.45;
  color: #92400e;
}
.oms-return-auto-pending li { margin: 2px 0; }

.oms-outlet-reclassification-modal[hidden] {
  display: none;
}

.oms-outlet-reclassification-modal {
  position: fixed;
  inset: 0;
  z-index: 10030;
  display: grid;
  place-items: center;
  padding: 24px;
}

.oms-outlet-reclassification-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.58);
  backdrop-filter: blur(3px);
}

.oms-outlet-reclassification-shell {
  position: relative;
  width: min(620px, 100%);
  max-height: calc(100vh - 48px);
  overflow: auto;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.26);
}

.oms-outlet-reclassification-shell > header,
.oms-outlet-reclassification-shell > footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px;
}

.oms-outlet-reclassification-shell > header {
  border-bottom: 1px solid #eef0f3;
}

.oms-outlet-reclassification-shell > footer {
  justify-content: flex-end;
  border-top: 1px solid #eef0f3;
}

.oms-outlet-reclassification-shell > header div {
  display: grid;
  gap: 3px;
}

.oms-outlet-reclassification-shell > header span,
.oms-outlet-reclassification-source span,
.oms-outlet-reclassification-form label > span {
  color: #7c2d12;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.oms-outlet-reclassification-shell > header strong {
  color: #111827;
  font-size: 20px;
}

.oms-outlet-reclassification-shell > header > button {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: #f3f4f6;
  color: #374151;
  cursor: pointer;
  font-size: 24px;
}

.oms-outlet-reclassification-source,
.oms-outlet-reclassification-note,
.oms-outlet-reclassification-success {
  display: grid;
  gap: 6px;
  margin: 20px 22px 0;
  padding: 16px;
  border: 1px solid #fed7aa;
  border-radius: 12px;
  background: #fff7ed;
}

.oms-outlet-reclassification-source strong,
.oms-outlet-reclassification-success strong {
  color: #111827;
  font-size: 15px;
}

.oms-outlet-reclassification-source em,
.oms-outlet-reclassification-success em,
.oms-outlet-reclassification-success span,
.oms-outlet-reclassification-note span {
  color: #667085;
  font-size: 12px;
  font-style: normal;
  line-height: 1.5;
}

.oms-outlet-reclassification-form {
  display: grid;
  grid-template-columns: 1fr 150px;
  gap: 14px;
  padding: 20px 22px 0;
}

.oms-outlet-reclassification-form label {
  display: grid;
  gap: 7px;
}

.oms-outlet-reclassification-form label.wide {
  grid-column: 1 / -1;
}

.oms-outlet-reclassification-form input,
.oms-outlet-reclassification-form select {
  min-height: 44px;
  width: 100%;
  border: 1px solid #d0d5dd;
  border-radius: 9px;
  background: #fff;
  padding: 0 12px;
  color: #101828;
  font: inherit;
}

.oms-outlet-reclassification-note {
  margin-bottom: 20px;
  border-color: #e4e7ec;
  background: #f9fafb;
}

.oms-outlet-reclassification-success {
  margin-bottom: 20px;
  border-color: #a7f3d0;
  background: #ecfdf5;
}

.oms-outlet-reclassification-shell .oms-empty-state,
.oms-outlet-reclassification-shell .oms-invoice-pdf-error {
  margin: 20px 22px;
}

@media (max-width: 680px) {
  .oms-outlet-reclassification-modal {
    align-items: end;
    padding: 0;
  }

  .oms-outlet-reclassification-shell {
    width: 100%;
    max-height: 92vh;
    border-radius: 18px 18px 0 0;
  }

  .oms-outlet-reclassification-form {
    grid-template-columns: 1fr;
  }

  .oms-outlet-reclassification-form label.wide {
    grid-column: auto;
  }
}

/* NIP w karcie "Dane do faktury" (2026-09-15) */
.oms-addr-note {
  display: inline-block;
  margin-left: 8px;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  vertical-align: middle;
}
.oms-addr-note-ok { background: #e6f4ea; color: #1e7e34; }
.oms-addr-note-warn { background: #fdecea; color: #b3261e; }

/* Pobieranie VelenoFlow Printer z paska gornego (dostepne takze dla kont magazynowych) */
.oms-printer-dl {
  position: relative;
  display: inline-flex;
}

.oms-printer-dl > summary {
  list-style: none;
}

.oms-printer-dl > summary::-webkit-details-marker {
  display: none;
}

.oms-printer-dl-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 80;
  display: grid;
  gap: 8px;
  width: min(340px, calc(100vw - 28px));
  border: 1px solid rgba(148, 163, 184, 0.26);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 20px 44px rgba(15, 23, 42, 0.16);
  padding: 14px;
  color: var(--oms-slate-700);
}

.oms-printer-dl-panel strong {
  color: var(--oms-slate-950);
  font-size: 14px;
  font-weight: 900;
}

.oms-printer-dl-panel small {
  color: var(--oms-slate-500);
  font-size: 12px;
}

.oms-printer-dl-links {
  display: grid;
  gap: 6px;
}

.oms-printer-dl-links a {
  justify-content: center;
  text-align: center;
  text-decoration: none;
}

.oms-printer-dl-panel ol {
  margin: 4px 0 0;
  padding-left: 18px;
  font-size: 12px;
  line-height: 1.45;
}

.oms-printer-dl-panel code {
  font-size: 11px;
  word-break: break-all;
}

.oms-app[data-theme="dark"] .oms-printer-dl-panel {
  border-color: rgba(148, 163, 184, 0.22);
  background: #0f172a;
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-printer-dl-panel strong {
  color: #f1f5f9;
}

@media (max-width: 760px) {
  .oms-printer-dl-panel {
    position: fixed;
    top: 64px;
    right: 10px;
    left: 10px;
    width: auto;
    z-index: 2400;
  }
}

/* Tryb dotykowy (przelacznik "Duże kafle" w asystencie pakowania i w "Nadaj paczkę").
   Stan na <html data-flow-oms-touch="on|off">, zapis per urzadzenie w localStorage.
   Poza trybem dotykowym kafle zostaja jak byly - ponizsze reguly ich nie dotykaja. */
.oms-touch-toggle {
  margin-left: auto;
  border: 1px solid #4b5563;
  border-radius: 999px;
  background: rgba(31, 41, 55, 0.72);
  padding: 5px 11px;
  color: #cbd5e1;
  font-size: 11.5px;
  font-weight: 850;
  white-space: nowrap;
  cursor: pointer;
}

.oms-touch-toggle.active {
  border-color: #4ade80;
  background: rgba(34, 197, 94, 0.18);
  color: #bbf7d0;
}

html[data-flow-oms-touch="on"] .oms-batch-pack-shell,
html[data-flow-oms-touch="on"] .oms-card-ship {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

html[data-flow-oms-touch="on"] .oms-touch-toggle {
  padding: 9px 16px;
  font-size: 13px;
}

html[data-flow-oms-touch="on"] .oms-delivery-methods {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  align-items: stretch;
  gap: 12px;
}

html[data-flow-oms-touch="on"] .oms-delivery-method {
  display: flex;
  min-height: 128px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-width: 2px;
  border-radius: 16px;
  padding: 14px 10px;
  font-size: 17px;
  text-align: center;
  user-select: none;
}

html[data-flow-oms-touch="on"] .oms-delivery-method.active {
  box-shadow: 0 0 0 3px rgba(147, 197, 253, 0.55);
}

html[data-flow-oms-touch="on"] .oms-delivery-method.suggested {
  box-shadow: 0 0 0 3px rgba(250, 204, 21, 0.45);
}

html[data-flow-oms-touch="on"] .oms-delivery-method:active:not(:disabled) {
  transform: scale(0.97);
}

html[data-flow-oms-touch="on"] .oms-delivery-method-icon {
  width: 52px;
  height: 52px;
}

html[data-flow-oms-touch="on"] .oms-delivery-method-icon svg {
  width: 28px;
  height: 28px;
}

html[data-flow-oms-touch="on"] .oms-delivery-method-text {
  justify-items: center;
  gap: 4px;
  line-height: 1.15;
  text-align: center;
}

html[data-flow-oms-touch="on"] .oms-delivery-method-text small {
  font-size: 12px;
  white-space: normal;
}

html[data-flow-oms-touch="on"] .oms-batch-contact-actions button,
html[data-flow-oms-touch="on"] .oms-batch-order-pill,
html[data-flow-oms-touch="on"] .oms-composition-link {
  min-height: 48px;
  padding-inline: 18px;
  font-size: 15px;
}

html[data-flow-oms-touch="on"] .oms-batch-close {
  min-width: 52px;
  min-height: 52px;
  font-size: 30px;
}

/* Sugerowana z zamowienia: pulsujaca poswiata + etykieta "SUGEROWANA" na
   krawedzi kafla. Ruch lapie wzrok lepiej niz sama ramka. Selektor z
   [data-flow-oms-touch] bije kolorowe :hover (lepki hover na dotyku). */
@keyframes omsSuggestedPulse {
  0%, 100% { box-shadow: 0 0 0 2px #facc15, 0 0 0 0 rgba(250, 204, 21, 0.55); }
  50% { box-shadow: 0 0 0 2px #facc15, 0 0 0 9px rgba(250, 204, 21, 0); }
}

html[data-flow-oms-touch] .oms-delivery-method.suggested {
  position: relative;
  border-color: #facc15;
  animation: omsSuggestedPulse 1.6s ease-in-out infinite;
}

html[data-flow-oms-touch="on"] .oms-delivery-method.suggested {
  border-width: 3px;
  padding-top: 22px;
}

html[data-flow-oms-touch="on"] .oms-delivery-method.suggested::before {
  content: "★ SUGEROWANA";
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  border-radius: 999px;
  background: #facc15;
  padding: 4px 12px;
  color: #111827;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

/* Etykieta na krawedzi mowi to samo, co maly napis w kaflu. */
html[data-flow-oms-touch="on"] .oms-delivery-method.suggested .oms-delivery-method-suggestion {
  display: none;
}

html[data-flow-oms-touch="on"] .oms-delivery-methods {
  padding-top: 14px;
}

@media (prefers-reduced-motion: reduce) {
  html[data-flow-oms-touch] .oms-delivery-method.suggested {
    animation: none;
    box-shadow: 0 0 0 3px #facc15;
  }
}

/* ===== Strona Faktury: naglowek, statystyki, tabela (2026-09-20) ============ */
.oms-invoices-top { min-height: 66px; padding: 12px 24px; }
.oms-invoices-title { font-size: 21px; font-weight: 900; letter-spacing: -0.01em; }
.oms-invoices-tabs { padding: 0 24px; }
.oms-invoices-filterbar { padding: 14px 24px; gap: 12px; }
.oms-invoices-filterbar input, .oms-invoices-filterbar select { min-height: 38px; border-radius: 10px; }
.oms-invoices-filterbar input:focus, .oms-invoices-filterbar select:focus { outline: 0; border-color: #93c5fd; box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15); }
.oms-invoices-notice { margin: 0 24px 12px; }
.oms-acc { margin: 0 24px 16px; }

.oms-inv-refresh { display: inline-flex; align-items: center; gap: 7px; min-height: 42px; padding: 0 14px; border-radius: 12px; font-weight: 800; }
.oms-inv-refresh svg { width: 16px; height: 16px; }

.oms-inv-export-cta {
  display: grid;
  grid-template-columns: 20px auto;
  grid-template-rows: auto auto;
  column-gap: 10px;
  align-items: center;
  min-height: 46px;
  padding: 6px 18px 6px 14px;
  border: 0;
  border-radius: 13px;
  background: linear-gradient(135deg, #1d4ed8, #3b82f6);
  color: #fff;
  font: inherit;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.oms-inv-export-cta svg { grid-row: 1 / -1; width: 20px; height: 20px; }
.oms-inv-export-cta span { font-size: 14px; font-weight: 900; line-height: 1.15; }
.oms-inv-export-cta small { color: #dbeafe; font-size: 11px; font-weight: 700; line-height: 1.15; }
.oms-inv-export-cta:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 14px 30px rgba(37, 99, 235, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.25); }
.oms-inv-export-cta.open { background: linear-gradient(135deg, #0f172a, #1e293b); box-shadow: 0 8px 20px rgba(15, 23, 42, 0.3); }
.oms-inv-export-cta:disabled { opacity: 0.5; cursor: default; }

.oms-inv-stats {
  display: grid;
  grid-template-columns: minmax(220px, 1.3fr) repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px;
  padding: 16px 24px 4px;
}
.oms-inv-stat {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 14px;
  background: #fff;
}
.oms-inv-stat span { color: var(--oms-slate-500); font-size: 11px; font-weight: 850; letter-spacing: 0.05em; text-transform: uppercase; }
.oms-inv-stat strong { color: var(--oms-slate-950); font-size: 22px; font-weight: 900; letter-spacing: -0.02em; line-height: 1.1; }
.oms-inv-stat small { color: var(--oms-slate-500); font-size: 12px; font-weight: 650; }
.oms-inv-stat-main { border-color: transparent; background: linear-gradient(135deg, #0f172a, #1e3a8a); box-shadow: 0 12px 28px rgba(15, 23, 42, 0.25); }
.oms-inv-stat-main span { color: #93c5fd; }
.oms-inv-stat-main strong { color: #fff; font-size: 30px; }
.oms-inv-stat-main small { color: #cbd5e1; }
.oms-inv-stat-soft { background: var(--oms-slate-50); }
.oms-inv-stat-soft strong { font-size: 15px; }

.oms-invoices-table-wrap { margin: 12px 24px 24px; border-radius: 14px; box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06); }
.oms-invoices-table th { position: sticky; top: 0; z-index: 1; padding: 12px 14px; background: #f8fafc; letter-spacing: 0.05em; }
.oms-invoices-table td { padding: 12px 14px; }
.oms-invoices-table tbody tr { transition: background 0.12s ease; }
.oms-invoices-table tbody tr:hover td { background: #f8fbff; }
.oms-inv-number { display: flex; align-items: center; gap: 10px; }
.oms-inv-flag { display: inline-flex; width: 30px; height: 30px; flex-shrink: 0; align-items: center; justify-content: center; border-radius: 9px; background: var(--oms-slate-50); border: 1px solid var(--oms-slate-100); font-style: normal; font-size: 15px; line-height: 1; }
.oms-inv-number strong { font-size: 13.5px; }
.oms-inv-kind { display: inline-block; padding: 1px 7px; border-radius: 999px; background: #eff6ff; color: var(--oms-blue-700); font-size: 10.5px; font-style: normal; font-weight: 850; letter-spacing: 0.03em; text-transform: uppercase; }
.oms-inv-kind.correction { background: #fff7ed; color: #c2410c; }
.oms-inv-buyer { color: var(--oms-slate-800); font-weight: 650; }
.oms-inv-amount { color: var(--oms-slate-950); font-size: 13.5px; font-weight: 900; font-variant-numeric: tabular-nums; }
.oms-inv-date { color: var(--oms-slate-500); font-weight: 650; white-space: nowrap; }
.oms-invoices-table tr.cancelled .oms-inv-amount { color: var(--oms-slate-400); text-decoration: line-through; }
.oms-invoices-actions button.oms-inv-pdf { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 12px; border-radius: 9px; border-color: #bfdbfe; background: #eff6ff; color: var(--oms-blue-700); }
.oms-invoices-actions button.oms-inv-pdf svg { width: 14px; height: 14px; }
.oms-invoices-actions button.oms-inv-pdf:hover:not(:disabled) { background: #dbeafe; }

@media (max-width: 1100px) {
  .oms-inv-stats { grid-template-columns: 1fr 1fr; }
  .oms-inv-export-cta small { display: none; }
}
.oms-inv-stat-main strong i { font-style: normal; color: #93c5fd; font-size: 20px; margin-left: 2px; }

/* ===== Faktury: filtry bez selectow (2026-09-20) ============================ */
.oms-inv-filters {
  display: grid;
  grid-template-columns: minmax(240px, 1.2fr) auto auto minmax(0, 1.6fr);
  gap: 12px 18px;
  align-items: end;
  border-bottom: 1px solid var(--oms-slate-200);
  background: #fff;
  padding: 14px 24px 16px;
}
.oms-inv-filter { display: grid; gap: 7px; min-width: 0; }
.oms-inv-filter > label { color: var(--oms-slate-500); font-size: 11px; font-weight: 850; letter-spacing: 0.05em; text-transform: uppercase; }
.oms-inv-filter .oms-acc-segment { width: fit-content; max-width: 100%; }
.oms-inv-search { position: relative; display: flex; align-items: center; }
.oms-inv-search svg { position: absolute; left: 12px; width: 16px; height: 16px; color: var(--oms-slate-400); pointer-events: none; }
.oms-inv-search input {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
  background: #f8fafc;
  padding: 0 12px 0 38px;
  color: var(--oms-slate-900);
  font: inherit;
  font-size: 13.5px;
  font-weight: 700;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.oms-inv-search input:focus { outline: 0; background: #fff; border-color: #93c5fd; box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15); }
.oms-inv-month {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 12px;
  background: #e9eef5;
}
.oms-inv-month > button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--oms-slate-600);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.oms-inv-month > button svg { width: 16px; height: 16px; }
.oms-inv-month > button:hover:not(:disabled) { background: #fff; color: var(--oms-slate-950); box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12); }
.oms-inv-month { position: relative; }
.oms-inv-month > .oms-inv-month-label { display: inline-flex; align-items: center; justify-content: center; gap: 6px; width: auto; min-width: 170px; padding: 0 10px; }
.oms-inv-month > .oms-inv-month-label strong { color: var(--oms-slate-950); font-size: 14px; font-weight: 900; text-transform: capitalize; }
.oms-inv-month > .oms-inv-month-label svg { width: 14px; height: 14px; color: var(--oms-slate-400); transition: transform 0.15s ease; }
.oms-inv-month > .oms-inv-month-label.open { background: #fff; box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12); }
.oms-inv-month > .oms-inv-month-label.open svg { transform: rotate(180deg); }
.oms-inv-month-picker {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 30;
  width: 300px;
  padding: 12px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 20px 48px rgba(15, 23, 42, 0.18);
}
.oms-inv-month-picker-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.oms-inv-month-picker-head strong { color: var(--oms-slate-950); font-size: 15px; font-weight: 900; }
.oms-inv-month-picker-head button { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border: 1px solid var(--oms-slate-200); border-radius: 9px; background: #fff; color: var(--oms-slate-600); cursor: pointer; }
.oms-inv-month-picker-head button svg { width: 14px; height: 14px; }
.oms-inv-month-picker-head button:hover:not(:disabled) { border-color: #93c5fd; color: var(--oms-blue-700); }
.oms-inv-month-picker-head button:disabled { opacity: 0.35; cursor: default; }
.oms-inv-month-picker-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.oms-inv-month-picker-grid button { min-height: 40px; border: 1px solid transparent; border-radius: 10px; background: var(--oms-slate-50); color: var(--oms-slate-800); font: inherit; font-size: 13px; font-weight: 800; cursor: pointer; transition: background 0.12s ease, color 0.12s ease, border-color 0.12s ease; }
.oms-inv-month-picker-grid button:hover { background: #eff6ff; color: var(--oms-blue-700); }
.oms-inv-month-picker-grid button.now { border-color: #bfdbfe; }
.oms-inv-month-picker-grid button.future { color: var(--oms-slate-400); }
.oms-inv-month-picker-grid button.active { background: linear-gradient(135deg, #1d4ed8, #3b82f6); color: #fff; box-shadow: 0 6px 14px rgba(37, 99, 235, 0.35); }
.oms-inv-month .oms-inv-month-today { width: auto; padding: 0 12px; font: inherit; font-size: 12px; font-weight: 800; color: var(--oms-blue-700); }
.oms-inv-month .oms-inv-month-today:disabled { opacity: 0.4; cursor: default; }
.oms-inv-order { color: var(--oms-slate-700); font-weight: 750; font-variant-numeric: tabular-nums; }
.oms-inv-source { display: inline-block; margin-left: 8px; padding: 1px 7px; border-radius: 999px; background: #fff7ed; color: #c2410c; font-size: 10.5px; font-style: normal; font-weight: 850; letter-spacing: 0.03em; text-transform: uppercase; }
@media (max-width: 1300px) { .oms-inv-filters { grid-template-columns: 1fr 1fr; } }
@media (max-width: 800px) { .oms-inv-filters { grid-template-columns: 1fr; } }

/* Naglowek Faktur: oba przyciski tej samej wysokosci, w jednej linii. */
.oms-invoices-top-actions { align-items: stretch; }
.oms-inv-refresh { min-height: 46px; height: 46px; }
.oms-inv-export-cta { height: 46px; min-height: 46px; box-sizing: border-box; align-content: center; }
.oms-inv-export-cta.open { grid-template-rows: auto; }
/* Okres w eksporcie: strzalki miesiaca wewnatrz segmentu. */
.oms-acc-period .oms-acc-period-step { width: 34px; padding: 0; justify-content: center; }
.oms-acc-period .oms-acc-period-step svg { width: 15px; height: 15px; }
.oms-acc-period .oms-acc-period-step:hover { background: #fff; box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12); }
.oms-acc-period button.active span { text-transform: capitalize; }

/* Kontrola importu: tabela sum per kraj/waluta pod statystykami eksportu. */
.oms-acc-import-check { margin-top: 14px; border: 1px solid var(--oms-slate-200); border-radius: 14px; background: #fff; overflow: hidden; }
.oms-acc-import-check-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--oms-slate-100); background: linear-gradient(180deg, #f8fafc, #fff); }
.oms-acc-import-check-head strong { display: block; color: var(--oms-slate-950); font-size: 14px; font-weight: 900; }
.oms-acc-import-check-head span { display: block; color: var(--oms-slate-500); font-size: 12px; font-weight: 650; }
.oms-acc-import-check-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.oms-acc-import-check-table th { padding: 9px 14px; background: #f8fafc; color: var(--oms-slate-500); font-size: 10.5px; font-weight: 900; letter-spacing: 0.05em; text-transform: uppercase; text-align: left; border-bottom: 1px solid var(--oms-slate-100); }
.oms-acc-import-check-table td { padding: 10px 14px; border-bottom: 1px solid var(--oms-slate-100); color: var(--oms-slate-700); font-variant-numeric: tabular-nums; font-weight: 650; }
.oms-acc-import-check-table td i { font-style: normal; margin-right: 4px; }
.oms-acc-import-check-table td strong { color: var(--oms-slate-950); font-weight: 900; }
.oms-acc-import-check-table td small { color: var(--oms-slate-400); font-size: 11px; font-weight: 700; }
.oms-acc-import-check-table .right { text-align: right; white-space: nowrap; }
.oms-acc-import-check-table tfoot td { background: #eff6ff; border-bottom: 0; color: var(--oms-blue-700); }
.oms-acc-import-check-table tfoot td strong { color: var(--oms-blue-700); }

/* Postep scalania zamowien. Operator musi widziec, ze cos sie dzieje i na czym
   stanelo - scalenie robi kilka zapisow do sklepu i magazynu, wiec cisza przez
   kilka sekund wyglada jak zawieszenie panelu. */
.oms-merge-progress-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.oms-merge-progress-item {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 9px 12px;
  border: 1px solid var(--oms-modal-border);
  border-radius: 10px;
  font-size: 13px;
  opacity: 0.55;
}

.oms-merge-progress-item.is-active {
  opacity: 1;
  border-color: #2563eb;
}

.oms-merge-progress-item.is-done {
  opacity: 1;
}

.oms-merge-progress-item.is-failed {
  opacity: 1;
  border-color: #dc2626;
}

.oms-merge-progress-ico {
  display: grid;
  width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 50%;
  background: var(--oms-modal-border);
  font-size: 12px;
}

.oms-merge-progress-item.is-done .oms-merge-progress-ico {
  background: #16a34a;
  color: #fff;
}

.oms-merge-progress-item.is-failed .oms-merge-progress-ico {
  background: #dc2626;
  color: #fff;
}

.oms-merge-progress-spinner {
  width: 14px;
  height: 14px;
  border: 2px solid rgba(37, 99, 235, 0.25);
  border-top-color: #2563eb;
  border-radius: 50%;
  animation: oms-merge-spin 0.7s linear infinite;
}

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

/* Filtr sklepu nad lista zamowien (23.09.2026). Pigulki z kropka w kolorze marki
   i licznikiem; aktywna pigulka ciemna, zeby bylo widac z daleka, jaki sklep jest
   wybrany. Desktop zawija, telefon przewija pasek w poziomie (strona nie). */
.oms-store-filter {
  display: flex;
  align-items: center;
  gap: 6px;
  border-bottom: 1px solid var(--oms-slate-200);
  background: white;
  padding: 8px 16px;
  flex-wrap: wrap;
}

@media (max-width: 760px) {
  .oms-store-filter {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .oms-store-filter::-webkit-scrollbar {
    display: none;
  }
}

.oms-store-filter:empty {
  display: none;
}

.oms-store-filter-label {
  flex-shrink: 0;
  margin-right: 4px;
  color: var(--oms-slate-400);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.oms-store-chip {
  --oms-store-chip-color: var(--oms-slate-400);
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  gap: 7px;
  height: 32px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 999px;
  background: white;
  color: var(--oms-slate-700);
  padding: 0 6px 0 11px;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.12s ease, border-color 0.12s ease, color 0.12s ease;
}

.oms-store-chip:hover {
  border-color: var(--oms-slate-300);
  background: var(--oms-slate-50);
  color: var(--oms-slate-900);
}

.oms-store-chip:focus-visible {
  outline: 2px solid var(--oms-blue-500);
  outline-offset: 2px;
}

.oms-store-chip-dot {
  width: 9px;
  height: 9px;
  flex-shrink: 0;
  border-radius: 999px;
  background: var(--oms-store-chip-color);
}

.oms-store-chip-count {
  min-width: 22px;
  border-radius: 999px;
  background: var(--oms-slate-100);
  color: var(--oms-slate-600);
  padding: 4px 7px;
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: center;
}

.oms-store-chip.active {
  border-color: var(--oms-slate-900);
  background: var(--oms-slate-900);
  color: white;
}

.oms-store-chip.active .oms-store-chip-count {
  background: rgba(255, 255, 255, 0.16);
  color: white;
}

.oms-store-chip.active .oms-store-chip-dot {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.35);
}

/* Zolty Allegro (#fff044) ginie na bialym - kropka w ciemniejszym odcieniu. */
.oms-store-chip.tone-allegro { --oms-store-chip-color: #eab308; }
.oms-store-chip.tone-pl { --oms-store-chip-color: var(--oms-store-bokserkoland-bg); }
.oms-store-chip.tone-hp { --oms-store-chip-color: var(--oms-slate-700); }
.oms-store-chip.tone-tut { --oms-store-chip-color: var(--oms-purple-500); }
.oms-store-chip.tone-cz { --oms-store-chip-color: var(--oms-store-cz-bg); }
.oms-store-chip.tone-tlk { --oms-store-chip-color: #10b981; }
.oms-store-chip.tone-sk { --oms-store-chip-color: var(--oms-store-sk-bg); }
.oms-store-chip.tone-lt { --oms-store-chip-color: var(--oms-store-lt-bg); }
.oms-store-chip.tone-hu { --oms-store-chip-color: var(--oms-store-hu-bg); }
.oms-store-chip.tone-ro { --oms-store-chip-color: var(--oms-store-ro-bg); }
.oms-store-chip.tone-hp.active .oms-store-chip-dot { background: white; }

/* Ilosci w pakowaniu (23.09.2026). Ilosc > 1 ma byc widoczna, ale bez krzyku:
   pomaranczowa cyfra w cienkiej ramce, ×1 szara bez ramki. Dwie glosniejsze
   wersje (wypelniony kafel z pulsem, potem pasek i tlo wiersza) Michal
   odrzucil jako przesadne. */
.oms-pack-qty {
  display: inline-flex;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  line-height: 1;
}

.oms-pack-qty.single {
  min-width: 38px;
  color: #64748b;
}

.oms-pack-qty.single .oms-pack-qty-num {
  font-size: 18px;
  font-weight: 700;
}

.oms-pack-qty.multi {
  min-width: 54px;
  min-height: 40px;
  border: 2px solid rgba(251, 146, 60, 0.7);
  padding: 3px 8px;
  color: #fdba74;
}

.oms-pack-qty.multi .oms-pack-qty-num {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.oms-pack-qty-units {
  margin-top: 2px;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
  white-space: nowrap;
}

/* Czarne 10+10 (05.10.2026): odroznienie od Mixu 10+10 (CHAMY), nazwy sa prawie
   takie same. Wiersz w grubej czarnej ramce z czarnym tlem + pigulka CZARNE.
   06.10.2026: tak samo pudelko Panda (czarne), Sarenka (rozowe) i damskie 10+10
   (czerwone). 13.10.2026: Zabawne 10 PAR (fiolet) vs 5 PAR (turkus). Na kolorowym
   tle niebieskie meta i pomaranczowe xN sa nieczytelne, wiec dostaja biel. */
.oms-batch-product-row.black-set,
.oms-batch-product-row.panda-set {
  border-radius: 8px;
  background: #0b0c0e;
  box-shadow: inset 0 0 0 4px #000, inset 0 0 0 6px rgba(255, 255, 255, 0.55);
}

.oms-batch-product-row.black-set.complete,
.oms-batch-product-row.panda-set.complete {
  background: #0b0c0e;
  box-shadow: inset 0 0 0 4px #000, inset 0 0 0 6px rgba(74, 222, 128, 0.7);
}

.oms-batch-product-row.black-set .oms-batch-product-thumb,
.oms-batch-product-row.panda-set .oms-batch-product-thumb {
  outline: 3px solid #000;
  outline-offset: 0;
}

.oms-batch-product-row.sarenka-set {
  --pack-set-color: #db2777;
  --pack-set-edge: #9d174d;
}

.oms-batch-product-row.damskie-set {
  --pack-set-color: #b91c1c;
  --pack-set-edge: #7f1d1d;
}

.oms-batch-product-row.zabawne10-set {
  --pack-set-color: #7c3aed;
  --pack-set-edge: #4c1d95;
}

.oms-batch-product-row.zabawne5-set,
.oms-batch-product-row.mix-set {
  --pack-set-color: #0f766e;
  --pack-set-edge: #134e4a;
}

.oms-batch-product-row.mix-set {
  --pack-set-color: #1d4ed8;
  --pack-set-edge: #1e3a8a;
}

.oms-batch-product-row.sarenka-set,
.oms-batch-product-row.damskie-set,
.oms-batch-product-row.zabawne10-set,
.oms-batch-product-row.zabawne5-set,
.oms-batch-product-row.mix-set,
.oms-batch-product-row.sarenka-set.complete,
.oms-batch-product-row.damskie-set.complete,
.oms-batch-product-row.zabawne10-set.complete,
.oms-batch-product-row.zabawne5-set.complete,
.oms-batch-product-row.mix-set.complete {
  border-radius: 8px;
  background: var(--pack-set-color);
  box-shadow: inset 0 0 0 4px var(--pack-set-edge), inset 0 0 0 6px rgba(255, 255, 255, 0.6);
}

.oms-batch-product-row.sarenka-set.complete,
.oms-batch-product-row.damskie-set.complete,
.oms-batch-product-row.zabawne10-set.complete,
.oms-batch-product-row.zabawne5-set.complete,
.oms-batch-product-row.mix-set.complete {
  box-shadow: inset 0 0 0 4px var(--pack-set-edge), inset 0 0 0 7px #4ade80;
}

.oms-batch-product-row.sarenka-set .oms-batch-product-thumb,
.oms-batch-product-row.damskie-set .oms-batch-product-thumb,
.oms-batch-product-row.zabawne10-set .oms-batch-product-thumb,
.oms-batch-product-row.zabawne5-set .oms-batch-product-thumb,
.oms-batch-product-row.mix-set .oms-batch-product-thumb {
  outline: 3px solid var(--pack-set-edge);
  outline-offset: 0;
}

.oms-batch-product-row.sarenka-set .oms-batch-product-name,
.oms-batch-product-row.damskie-set .oms-batch-product-name,
.oms-batch-product-row.zabawne10-set .oms-batch-product-name,
.oms-batch-product-row.zabawne5-set .oms-batch-product-name,
.oms-batch-product-row.mix-set .oms-batch-product-name {
  color: #fff;
}

.oms-batch-product-row.sarenka-set .oms-batch-product-meta,
.oms-batch-product-row.damskie-set .oms-batch-product-meta,
.oms-batch-product-row.zabawne10-set .oms-batch-product-meta,
.oms-batch-product-row.zabawne5-set .oms-batch-product-meta,
.oms-batch-product-row.mix-set .oms-batch-product-meta,
.oms-batch-product-row.sarenka-set .oms-batch-allegro-link,
.oms-batch-product-row.damskie-set .oms-batch-allegro-link,
.oms-batch-product-row.zabawne10-set .oms-batch-allegro-link,
.oms-batch-product-row.zabawne5-set .oms-batch-allegro-link,
.oms-batch-product-row.mix-set .oms-batch-allegro-link {
  color: rgba(255, 255, 255, 0.88);
}

.oms-batch-product-row.sarenka-set .oms-batch-size-pill,
.oms-batch-product-row.damskie-set .oms-batch-size-pill,
.oms-batch-product-row.zabawne10-set .oms-batch-size-pill,
.oms-batch-product-row.zabawne5-set .oms-batch-size-pill,
.oms-batch-product-row.mix-set .oms-batch-size-pill {
  background: rgba(0, 0, 0, 0.4);
}

.oms-batch-product-row.sarenka-set .oms-pack-qty.multi,
.oms-batch-product-row.damskie-set .oms-pack-qty.multi,
.oms-batch-product-row.zabawne10-set .oms-pack-qty.multi,
.oms-batch-product-row.zabawne5-set .oms-pack-qty.multi,
.oms-batch-product-row.mix-set .oms-pack-qty.multi {
  border-color: #fff;
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
}

.oms-pack-set-pill {
  flex: 0 0 auto;
  border: 2px solid #fff;
  border-radius: 6px;
  background: #000;
  padding: 5px 10px;
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  letter-spacing: 0.08em;
  line-height: 1;
  white-space: nowrap;
}

.oms-pack-set-pill.sarenka-set {
  border-color: #9d174d;
  background: #fff;
  color: #be185d;
}

.oms-pack-set-pill.damskie-set {
  border-color: #7f1d1d;
  background: #fff;
  color: #b91c1c;
}

.oms-pack-set-pill.zabawne10-set {
  border-color: #4c1d95;
  background: #fff;
  color: #6d28d9;
}

.oms-pack-set-pill.zabawne5-set {
  border-color: #134e4a;
  background: #fff;
  color: #0f766e;
}

.oms-pack-set-pill.mix-set {
  border-color: #1e3a8a;
  background: #fff;
  color: #1d4ed8;
}

.oms-batch-product-row.complete .oms-pack-qty.multi {
  border-color: rgba(74, 222, 128, 0.7);
  color: #86efac;
}

.oms-batch-product-controls .oms-pack-count {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.oms-pack-pips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px;
  max-width: 150px;
}

.oms-pack-pips i {
  width: 11px;
  height: 11px;
  border: 2px solid #fb923c;
  border-radius: 999px;
}

.oms-pack-pips i.on {
  border-color: #4ade80;
  background: #4ade80;
}

.oms-batch-product-done.multi {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.oms-batch-product-done.multi small {
  margin-top: 2px;
  color: #fdba74;
  font-size: 14px;
  font-weight: 900;
}

.oms-batch-product-done.multi.done small {
  color: #bbf7d0;
}

/* Stara regula ".oms-batch-product-controls span" dawala ramke kazdemu spanowi
   w srodku - wewnetrzne elementy licznika jej nie chca. */
.oms-batch-product-controls .oms-pack-count > span,
.oms-batch-product-controls .oms-pack-pips {
  display: flex;
  border: 0;
}

/* Pasek narzedzi listy - odswiezenie 23.09.2026. Uklad i zachowanie bez zmian
   (osobne przyciski, kreski miedzy grupami, te same kolory stanow) - tylko
   czysciej narysowane ikony, miekksza ramka i delikatny hover. Wersja z
   segmentami i nowymi znaczeniami ikon zostala odrzucona: ma byc jak bylo. */
.oms-app .oms-toolbar .oms-tool-btn {
  width: 30px;
  height: 30px;
  border-color: #dbe2ea;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.05);
  color: #475467;
  transition: background-color 0.14s ease, border-color 0.14s ease, color 0.14s ease, box-shadow 0.14s ease;
}

.oms-app .oms-toolbar .oms-tool-btn svg {
  width: 17px;
  height: 17px;
  stroke-width: 1.8;
}

.oms-app .oms-toolbar .oms-tool-btn:hover:not(:disabled) {
  border-color: #c3cfdd;
  box-shadow: 0 2px 5px rgba(16, 24, 40, 0.08);
  color: #101828;
}

.oms-app .oms-toolbar .oms-tool-btn:disabled {
  color: #98a2b3;
}

.oms-app[data-theme="dark"] .oms-toolbar .oms-tool-btn {
  border-color: rgba(148, 163, 184, 0.22);
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] .oms-toolbar .oms-tool-btn:disabled {
  color: #64748b;
}

/* Okienko potwierdzenia: pytania przepiete z window.confirm maja wielolinijkowa
   tresc (lista pozycji, wymiary paczki) - nowe linie musza zostac. */
.oms-confirm-body p {
  white-space: pre-line;
}

/* Rozwijane filtry nad lista (23.09.2026). Chrome 135+ pozwala ostylowac sama
   rozwinieta liste (appearance: base-select) - zamiast systemowej szarej listy
   jest karta z zaokragleniem, cieniem, hoverem i ptaszkiem przy wybranej opcji.
   Safari/Firefox nie znaja base-select i zostaja przy liscie systemowej. */
@supports (appearance: base-select) {
  .oms-app .oms-toolbar-select select,
  .oms-app .oms-toolbar-select select::picker(select) {
    appearance: base-select;
  }

  .oms-app .oms-toolbar-select select {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 0;
    background: transparent;
    padding: 0;
    color: var(--oms-slate-900);
    font: inherit;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
  }

  .oms-app .oms-toolbar-select select::picker-icon {
    content: '';
    width: 14px;
    height: 14px;
    margin-left: auto;
    background: currentColor;
    color: #64748b;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
    transition: rotate 0.16s ease;
  }

  .oms-app .oms-toolbar-select select:open::picker-icon {
    rotate: 180deg;
  }

  .oms-app .oms-toolbar-select select::picker(select) {
    min-width: max(anchor-size(width), 190px);
    max-width: 460px;
    max-height: min(60vh, 440px);
    margin-top: 8px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #ffffff;
    padding: 6px;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.14), 0 3px 8px rgba(15, 23, 42, 0.06);
    overflow-y: auto;
    opacity: 1;
    translate: 0 0;
    transition: opacity 0.14s ease, translate 0.14s ease, display 0.14s allow-discrete, overlay 0.14s allow-discrete;
  }

  @starting-style {
    .oms-app .oms-toolbar-select select:open::picker(select) {
      opacity: 0;
      translate: 0 -4px;
    }
  }

  .oms-app .oms-toolbar-select select option {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 34px;
    border-radius: 8px;
    padding: 7px 10px;
    color: #1e293b;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
  }

  .oms-app .oms-toolbar-select select option:hover,
  .oms-app .oms-toolbar-select select option:focus-visible {
    outline: 0;
    background: #f1f5f9;
  }

  .oms-app .oms-toolbar-select select option:checked {
    background: #eff6ff;
    color: #1d4ed8;
    font-weight: 750;
  }

  .oms-app .oms-toolbar-select select option::checkmark {
    order: 1;
    margin-left: auto;
    color: #2563eb;
    font-weight: 900;
  }

  .oms-app[data-theme="dark"] .oms-toolbar-select select {
    color: #e2e8f0;
  }

  .oms-app[data-theme="dark"] .oms-toolbar-select select::picker(select) {
    border-color: rgba(148, 163, 184, 0.24);
    background: #0f172a;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.45);
  }

  .oms-app[data-theme="dark"] .oms-toolbar-select select option {
    color: #e2e8f0;
  }

  .oms-app[data-theme="dark"] .oms-toolbar-select select option:hover,
  .oms-app[data-theme="dark"] .oms-toolbar-select select option:focus-visible {
    background: #1e293b;
  }

  .oms-app[data-theme="dark"] .oms-toolbar-select select option:checked {
    background: rgba(37, 99, 235, 0.22);
    color: #93c5fd;
  }
}

/* Pasek listy w dwoch rzedach (23.09.2026): akcje + paginacja, pod spodem filtry.
   Przyciski-ikony bez zmian (patrz odswiezenie ikon wyzej). */
.oms-app .oms-toolbar.oms-toolbar-v2 {
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 0;
  padding: 0;
}

.oms-toolbar-v2 .oms-toolbar-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
}

.oms-toolbar-v2 .oms-toolbar-row-filters {
  border-top: 1px solid #eef2f6;
  background: #fcfdfe;
}

.oms-toolbar-v2 .oms-toolbar-pager {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.oms-toolbar-v2 .oms-toolbar-pager .oms-pagination-info {
  margin-left: 0;
}

.oms-toolbar-v2 .oms-toolbar-divider {
  width: 1px;
  height: 22px;
  margin: 0 4px;
  background: #dbe2ea;
}

.oms-toolbar-v2 .oms-operator-filter-bar {
  display: contents;
}

.oms-toolbar-v2 .oms-toolbar-sort {
  display: inline-flex;
  margin-left: auto;
}

/* Filtr z wartoscia inna niz domyslna. */
.oms-app .oms-toolbar-v2 .oms-toolbar-select.is-set {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #2563eb;
  box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.08);
}

.oms-app .oms-toolbar-v2 .oms-toolbar-select.is-set select {
  color: #1d4ed8;
}

.oms-app .oms-toolbar-v2 .oms-toolbar-select {
  transition: border-color 0.14s ease, background-color 0.14s ease, box-shadow 0.14s ease;
}

.oms-app .oms-toolbar-v2 .oms-toolbar-select:hover {
  border-color: #c3cfdd;
}

.oms-app .oms-toolbar-v2 .oms-toolbar-clear {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  color: #2563eb;
}

.oms-app .oms-toolbar-v2 .oms-toolbar-clear:hover:not(:disabled) {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.oms-app .oms-toolbar-v2 .oms-toolbar-clear:disabled {
  color: #a3adbb;
  cursor: default;
}

.oms-toolbar-clear-count {
  min-width: 18px;
  border-radius: 999px;
  background: #2563eb;
  padding: 2px 6px;
  color: #ffffff;
  font-size: 11px;
  font-weight: 850;
  line-height: 1.2;
  text-align: center;
}

.oms-app[data-theme="dark"] .oms-toolbar-v2 .oms-toolbar-row-filters {
  border-top-color: rgba(148, 163, 184, 0.16);
  background: transparent;
}

.oms-app[data-theme="dark"] .oms-toolbar-v2 .oms-toolbar-select.is-set {
  border-color: rgba(96, 165, 250, 0.45);
  background: rgba(37, 99, 235, 0.18);
  color: #93c5fd;
}

.oms-app[data-theme="dark"] .oms-toolbar-v2 .oms-toolbar-select.is-set select {
  color: #bfdbfe;
}

@media (max-width: 760px) {
  .oms-toolbar-v2 .oms-toolbar-row {
    padding: 8px 10px;
  }

  .oms-toolbar-v2 .oms-toolbar-divider {
    display: none;
  }

  .oms-toolbar-v2 .oms-toolbar-pager,
  .oms-toolbar-v2 .oms-toolbar-sort {
    margin-left: 0;
  }
}

/* Filtry dopasowane do wartosci - sztywne min-width (82-118 px) ze starego
   ukladu rozpychaly rzad i lamaly go do dwoch linii. */
.oms-app .oms-toolbar-v2 .oms-toolbar-select select,
.oms-app .oms-toolbar-v2 .oms-toolbar-select.compact select {
  min-width: 0;
}

.oms-app .oms-toolbar-v2 .oms-toolbar-select {
  gap: 6px;
  padding: 0 8px 0 10px;
}

@supports (appearance: base-select) {
  .oms-app .oms-toolbar-v2 .oms-toolbar-select select::picker-icon {
    margin-left: 2px;
  }
}

.oms-toolbar-v2 .oms-toolbar-pager .oms-toolbar-sort {
  margin-left: 0;
  margin-right: 6px;
}

/* display:inline-flex wyzej przykrywal atrybut hidden. */
.oms-app .oms-toolbar-v2 .oms-toolbar-clear[hidden] {
  display: none;
}

/* Ciasniej o kilka px na filtr, zeby przy aktywnych wartosciach ("Do spakowania",
   "Brak faktury") "Wyczysc" miescil sie w tym samym rzedzie na 1600 px. */
.oms-toolbar-v2 .oms-toolbar-row-filters {
  gap: 5px;
}

.oms-app .oms-toolbar-v2 .oms-toolbar-row-filters .oms-toolbar-select {
  gap: 5px;
  padding: 0 6px 0 9px;
}

.oms-toolbar-v2 .oms-toolbar-divider {
  margin: 0 2px;
}

/* Filtr Komplet: bogate wiersze opcji (23.09.2026) - licznik w kolku, nazwa
   i drobny podpis, rozmiar jako pigulka. Tylko w base-select (Chrome 135+). */
@supports (appearance: base-select) {
  .oms-app #omsPackMatchSelect::picker(select) {
    width: min(520px, 92vw);
    max-width: min(520px, 92vw);
    max-height: min(70vh, 560px);
  }

  .oms-app #omsPackMatchSelect optgroup {
    padding-top: 4px;
  }

  .oms-app #omsPackMatchSelect optgroup::before,
  .oms-app #omsPackMatchSelect legend {
    display: block;
    padding: 8px 10px 4px;
    color: #94a3b8;
    font-size: 10.5px;
    font-weight: 850;
    letter-spacing: 0.07em;
    text-transform: uppercase;
  }

  .oms-app #omsPackMatchSelect option {
    align-items: center;
    gap: 10px;
    min-height: 40px;
    padding: 6px 10px;
    white-space: normal;
  }

  .oms-app #omsPackMatchSelect .oms-pm-sep {
    display: none;
  }

  .oms-app #omsPackMatchSelect .oms-pm-count {
    display: inline-flex;
    flex: 0 0 auto;
    min-width: 28px;
    height: 24px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #f1f5f9;
    padding: 0 7px;
    color: #334155;
    font-size: 12px;
    font-weight: 850;
    font-variant-numeric: tabular-nums;
  }

  .oms-app #omsPackMatchSelect option:checked .oms-pm-count {
    background: #2563eb;
    color: #ffffff;
  }

  .oms-app #omsPackMatchSelect .oms-pm-text {
    display: flex;
    flex: 1 1 auto;
    min-width: 0;
    flex-direction: column;
    gap: 1px;
  }

  .oms-app #omsPackMatchSelect .oms-pm-title,
  .oms-app #omsPackMatchSelect .oms-pm-line {
    overflow: hidden;
    color: inherit;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.3;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .oms-app #omsPackMatchSelect .oms-pm-line b {
    color: #ea580c;
    font-weight: 900;
  }

  .oms-app #omsPackMatchSelect .oms-pm-line em {
    border-radius: 5px;
    background: #fef3c7;
    padding: 0 5px;
    color: #92400e;
    font-style: normal;
    font-size: 11.5px;
    font-weight: 800;
  }

  .oms-app #omsPackMatchSelect .oms-pm-line i {
    color: #64748b;
    font-style: normal;
    font-weight: 600;
  }

  .oms-app #omsPackMatchSelect .oms-pm-sub {
    overflow: hidden;
    color: #64748b;
    font-size: 11.5px;
    font-weight: 600;
    line-height: 1.3;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .oms-app #omsPackMatchSelect .oms-pm-size {
    flex: 0 0 auto;
    border-radius: 6px;
    background: #fef3c7;
    padding: 3px 7px;
    color: #92400e;
    font-size: 12px;
    font-weight: 850;
    white-space: nowrap;
  }

  .oms-app #omsPackMatchSelect option::checkmark {
    order: 2;
    margin-left: 0;
  }

  .oms-app[data-theme="dark"] #omsPackMatchSelect .oms-pm-count {
    background: #1e293b;
    color: #e2e8f0;
  }

  .oms-app[data-theme="dark"] #omsPackMatchSelect .oms-pm-size,
  .oms-app[data-theme="dark"] #omsPackMatchSelect .oms-pm-line em {
    background: rgba(250, 204, 21, 0.16);
    color: #fde68a;
  }
}

/* Komplet v2: jedna linia na opcje (podpis i "+ gratis" w tej samej linii),
   wlasny przycisk z krotkim opisem wybranej opcji. */
@supports (appearance: base-select) {
  .oms-app #omsPackMatchSelect::picker(select) {
    max-height: min(82vh, 820px);
  }

  .oms-app #omsPackMatchSelect option {
    min-height: 34px;
    padding: 5px 10px;
  }

  .oms-app #omsPackMatchSelect .oms-pm-text {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: baseline;
    column-gap: 8px;
  }

  .oms-app #omsPackMatchSelect .oms-pm-line,
  .oms-app #omsPackMatchSelect .oms-pm-title {
    min-width: 0;
    max-width: 100%;
  }

  .oms-app #omsPackMatchSelect .oms-pm-tag {
    flex: 0 0 auto;
    color: #94a3b8;
    font-size: 11.5px;
    font-weight: 700;
    white-space: nowrap;
  }

  .oms-app #omsPackMatchSelect .oms-pm-button {
    display: inline-flex;
    max-width: 230px;
    align-items: center;
    gap: 6px;
    border: 0;
    background: transparent;
    padding: 0;
    color: inherit;
    font: inherit;
    cursor: pointer;
  }

  .oms-app #omsPackMatchSelect .oms-pm-current {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .oms-app #omsPackMatchSelect .oms-pm-button::after {
    content: '';
    width: 14px;
    height: 14px;
    flex: 0 0 auto;
    background: #64748b;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
    transition: rotate 0.16s ease;
  }

  .oms-app #omsPackMatchSelect:open .oms-pm-button::after {
    rotate: 180deg;
  }

  .oms-app .is-set #omsPackMatchSelect .oms-pm-button::after {
    background: #2563eb;
  }
}

@supports (appearance: base-select) {
  .oms-app #omsPackMatchSelect .oms-pm-button {
    max-width: 260px;
  }

  .oms-app #omsPackMatchSelect .oms-pm-current-size {
    flex: 0 0 auto;
    border-radius: 5px;
    background: #fef3c7;
    padding: 1px 6px;
    color: #92400e;
    font-size: 11.5px;
    font-weight: 850;
  }
}

.oms-app .oms-toolbar-v2 .oms-pack-match-select select {
  min-width: 0;
  max-width: 280px;
}

@supports (appearance: base-select) {
  .oms-app #omsPackMatchSelect .oms-pm-button {
    max-width: 100%;
  }
}

/* Gestosc listy zamowien (23.09.2026): wiecej zamowien na ekranie bez utraty
   informacji. Naglowek ciasniej, sklepy w jednym rzedzie, "Aktywne pakowanie"
   jako jedna linijka, gratisy jako dopisek, puste kolejki schowane. */
#omsListView #omsListSubtitle {
  display: none;
}

.oms-app #omsListView .oms-orders-header {
  min-height: 0;
  padding: 8px 18px;
}

.oms-app #omsListView .oms-orders-title {
  font-size: 18px;
}

.oms-app #omsListView .oms-header-actions .oms-btn-ghost {
  height: 32px;
}

.oms-store-filter {
  flex-wrap: nowrap;
  gap: 5px;
  padding: 6px 16px;
  overflow-x: auto;
  scrollbar-width: none;
}

.oms-store-filter::-webkit-scrollbar {
  display: none;
}

.oms-store-chip {
  height: 28px;
  gap: 6px;
  padding: 0 4px 0 9px;
  font-size: 12.5px;
}

.oms-store-chip-dot {
  width: 8px;
  height: 8px;
}

.oms-store-chip-count {
  min-width: 20px;
  padding: 3px 6px;
  font-size: 11.5px;
}

.oms-toolbar-v2 .oms-toolbar-row {
  padding-top: 6px;
  padding-bottom: 6px;
}

/* Aktywne pakowanie: jedna linijka nad tabela. */
.oms-packing-ops-panel.oms-packing-ops-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
  border: 0;
  border-bottom: 1px solid #e2e8f0;
  border-radius: 0;
  background: #f8fafc;
  padding: 6px 16px;
  color: #334155;
}

.oms-packing-ops-label {
  color: #64748b;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.oms-packing-session-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #dbe2ea;
  border-radius: 999px;
  background: #ffffff;
  padding: 3px 4px 3px 12px;
  font-size: 12.5px;
  white-space: nowrap;
}

.oms-packing-session-pill strong {
  color: #0f172a;
}

.oms-packing-session-pill small {
  color: #94a3b8;
  font-size: 11.5px;
}

.oms-packing-session-progress {
  display: inline-block;
  width: 54px;
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #e2e8f0;
}

.oms-packing-session-progress i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: #22c55e;
}

.oms-packing-session-pill button {
  height: 24px;
  border: 1px solid #dbe2ea;
  border-radius: 999px;
  background: #f8fafc;
  padding: 0 10px;
  color: #1e293b;
  font: inherit;
  font-size: 12px;
  font-weight: 750;
  cursor: pointer;
}

.oms-packing-session-pill button:hover {
  border-color: #93c5fd;
  background: #eff6ff;
  color: #1d4ed8;
}

.oms-packing-session-pill .oms-packing-session-cancel {
  width: 24px;
  padding: 0;
  color: #94a3b8;
}

.oms-packing-session-pill .oms-packing-session-cancel:hover {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
}

.oms-packing-session-pill.stale {
  border-style: dashed;
  background: #f8fafc;
  opacity: 0.75;
}

.oms-packing-ops-bar .oms-packing-problems {
  border-radius: 999px;
  background: #fef2f2;
  padding: 3px 10px;
  color: #b91c1c;
  font-size: 12px;
  font-weight: 800;
}

.oms-packing-ops-bar .oms-packing-empty-line {
  color: #94a3b8;
  font-size: 12.5px;
}

/* Kolejki z zerem schowane (hideEmptyQueueItems). */
.oms-filter-subitem[hidden],
.oms-filter-section[hidden] {
  display: none;
}

.oms-app[data-theme="dark"] .oms-packing-ops-panel.oms-packing-ops-bar {
  border-bottom-color: rgba(148, 163, 184, 0.16);
  background: #0f172a;
  color: #cbd5e1;
}

.oms-app[data-theme="dark"] .oms-packing-session-pill {
  border-color: rgba(148, 163, 184, 0.24);
  background: #1e293b;
}

.oms-app[data-theme="dark"] .oms-packing-session-pill strong {
  color: #f1f5f9;
}

.oms-app[data-theme="dark"] .oms-packing-session-pill button {
  border-color: rgba(148, 163, 184, 0.24);
  background: #0f172a;
  color: #e2e8f0;
}

/* Miniatury na liscie 52 px (bylo 56, na probe 44 - Michal: "troszke wieksze"). */
.oms-app #omsListView .oms-thumb {
  width: 52px;
  height: 52px;
}

/* Uchwyt zmiany szerokosci ostatniej kolumny wystawal 3 px i dawal poziomy scroll. */
.oms-table-resizable th:last-child .oms-column-resize-handle {
  right: 0;
}

/* Karta zamowienia: maile realnie wyslane do klienta (23.09.2026). */
.oms-sent-emails {
  border: 1px solid var(--oms-slate-200);
  border-radius: 12px;
  background: #ffffff;
  padding: 12px 16px;
}

.oms-sent-emails-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 6px;
}

.oms-sent-emails-head strong {
  color: #0f172a;
  font-size: 14px;
}

.oms-sent-emails-head span {
  color: #64748b;
  font-size: 12.5px;
}

.oms-sent-email {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 4px 10px;
  border-top: 1px solid #f1f5f9;
  padding: 7px 0;
  font-size: 13px;
}

.oms-sent-email-status {
  border-radius: 999px;
  background: #ecfdf5;
  padding: 1px 8px;
  color: #047857;
  font-size: 11.5px;
  font-weight: 800;
  white-space: nowrap;
}

.oms-sent-email.failed .oms-sent-email-status {
  background: #fef2f2;
  color: #b91c1c;
}

.oms-sent-email strong {
  overflow: hidden;
  color: #1e293b;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-sent-email small {
  color: #64748b;
  font-size: 12px;
  white-space: nowrap;
}

.oms-sent-email em {
  grid-column: 2 / -1;
  color: #b91c1c;
  font-size: 12px;
  font-style: normal;
}

.oms-app[data-theme="dark"] .oms-sent-emails {
  border-color: rgba(148, 163, 184, 0.22);
  background: #0f172a;
}

.oms-app[data-theme="dark"] .oms-sent-emails-head strong,
.oms-app[data-theme="dark"] .oms-sent-email strong {
  color: #e2e8f0;
}

/* Pakowanie na zywo: wyrazniejszy pasek, gdy ktos pakuje (feedback 23.09.2026:
   "zlewa sie, a fajnie widziec, czy ktos ma cos w pakowaniu"). */
.oms-packing-ops-panel.oms-packing-ops-bar.live {
  border-bottom-color: #c7d2fe;
  background: linear-gradient(90deg, #eef2ff 0%, #f5f7ff 60%, #f8fafc 100%);
  box-shadow: inset 4px 0 0 #6366f1;
}

.oms-packing-ops-bar.live .oms-packing-ops-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #4338ca;
  font-size: 12px;
}

.oms-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.5);
  animation: oms-live-dot 1.8s ease-out infinite;
}

@keyframes oms-live-dot {
  0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.5); }
  70% { box-shadow: 0 0 0 7px rgba(34, 197, 94, 0); }
  100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .oms-live-dot { animation: none; }
}

.oms-packing-ops-bar.live .oms-packing-session-pill:not(.stale) {
  border-color: #a5b4fc;
  box-shadow: 0 1px 3px rgba(79, 70, 229, 0.12);
}

.oms-packing-ops-bar.live .oms-packing-session-pill:not(.stale) strong {
  color: #3730a3;
}

.oms-app[data-theme="dark"] .oms-packing-ops-panel.oms-packing-ops-bar.live {
  border-bottom-color: rgba(129, 140, 248, 0.35);
  background: linear-gradient(90deg, rgba(79, 70, 229, 0.22) 0%, rgba(15, 23, 42, 0.9) 70%);
}

/* Lewy panel: zero wyszarzone, sklep z samymi zerami zwiniety do naglowka. */
.oms-filter-subitem.is-empty {
  opacity: 0.45;
}

.oms-filter-subitem.is-empty.active {
  opacity: 1;
}

.oms-filter-section.is-collapsed .oms-filter-subitem {
  display: none;
}

.oms-filter-section.is-all-empty .oms-filter-section-title {
  cursor: pointer;
  opacity: 0.55;
}

.oms-filter-section.is-all-empty .oms-filter-section-title::after {
  content: ' ▸';
  font-size: 10px;
}

.oms-filter-section.is-all-empty:not(.is-collapsed) .oms-filter-section-title::after {
  content: ' ▾';
}

/* Maile do klienta: rozwijana tresc wyslanego maila + przycisk "Napisz maila". */
.oms-sent-emails-head .oms-sent-emails-write {
  margin-left: auto;
  height: 30px;
}

details.oms-sent-email {
  display: block;
  padding: 0;
}

details.oms-sent-email > summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 4px 10px;
  padding: 7px 0;
  cursor: pointer;
  list-style: none;
}

details.oms-sent-email > summary::-webkit-details-marker {
  display: none;
}

details.oms-sent-email > summary:hover strong {
  color: #1d4ed8;
}

details.oms-sent-email > em {
  display: block;
  padding: 0 0 6px;
}

.oms-sent-email-kind {
  margin-left: 6px;
  border-radius: 999px;
  background: #eff6ff;
  padding: 1px 7px;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 800;
}

.oms-sent-email-body {
  margin: 0 0 10px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
  overflow: hidden;
}

.oms-sent-email-body iframe {
  display: block;
  width: 100%;
  height: 420px;
  border: 0;
  background: #ffffff;
}

.oms-sent-email-body pre {
  margin: 0;
  max-height: 420px;
  overflow: auto;
  padding: 12px 14px;
  color: #1e293b;
  font: 13px/1.5 inherit;
  white-space: pre-wrap;
}

/* Szybki mail do zaznaczonych: lista odbiorcow z wynikiem przy kazdym. */
.oms-quick-email-bulk-list {
  display: grid;
  max-height: 200px;
  overflow: auto;
  margin: 6px 0 10px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}

.oms-quick-email-bulk-row {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) auto;
  gap: 10px;
  border-top: 1px solid #f1f5f9;
  padding: 6px 10px;
  font-size: 13px;
}

.oms-quick-email-bulk-row:first-child {
  border-top: 0;
}

.oms-quick-email-bulk-row span {
  overflow: hidden;
  color: #475569;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-quick-email-bulk-row em {
  color: #64748b;
  font-style: normal;
  font-weight: 700;
}

.oms-quick-email-bulk-row.sent em { color: #047857; }
.oms-quick-email-bulk-row.failed em,
.oms-quick-email-bulk-row.skip em { color: #b91c1c; }
.oms-quick-email-bulk-row.sending em { color: #1d4ed8; }

/* Pakowanie na zywo - ciemne, kontrastowe tlo (feedback 23.09: "wjebal ciemne tlo,
   teraz nie widac"). Jasny pasek zostaje tylko, gdy nikt nie pakuje. */
.oms-packing-ops-panel.oms-packing-ops-bar.live {
  border-bottom: 0;
  background: linear-gradient(90deg, #111827 0%, #1e1b4b 100%);
  box-shadow: inset 4px 0 0 #818cf8;
  color: #e2e8f0;
}

.oms-packing-ops-bar.live .oms-packing-ops-label {
  color: #ffffff;
}

.oms-packing-ops-bar.live .oms-packing-session-pill {
  border-color: rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: none;
  color: #e2e8f0;
}

.oms-packing-ops-bar.live .oms-packing-session-pill strong,
.oms-packing-ops-bar.live .oms-packing-session-pill:not(.stale) strong {
  color: #ffffff;
}

.oms-packing-ops-bar.live .oms-packing-session-pill small {
  color: #a5b4fc;
}

.oms-packing-ops-bar.live .oms-packing-session-progress {
  background: rgba(255, 255, 255, 0.18);
}

.oms-packing-ops-bar.live .oms-packing-session-pill button {
  border-color: rgba(148, 163, 184, 0.4);
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

.oms-packing-ops-bar.live .oms-packing-session-pill button:hover {
  border-color: #a5b4fc;
  background: rgba(129, 140, 248, 0.3);
  color: #ffffff;
}

.oms-packing-ops-bar.live .oms-packing-session-pill .oms-packing-session-cancel {
  color: #cbd5e1;
}

.oms-packing-ops-bar.live .oms-packing-session-pill.stale {
  opacity: 0.6;
}

/* Lewy panel: liczby naglowkow sklepow w tej samej kolumnie co liczby kolejek.
   Strzalka zwinietego sklepu idzie PRZED nazwe - jako trzeci element flexa
   z space-between wypychala "(0)" na srodek. */
.oms-filter-section-title {
  justify-content: flex-start;
  gap: 6px;
}

.oms-filter-section-title > span {
  margin-left: auto;
  min-width: 30px;
  text-align: center;
}

.oms-filter-section.is-all-empty .oms-filter-section-title::after,
.oms-filter-section.is-all-empty:not(.is-collapsed) .oms-filter-section-title::after {
  content: none;
}

.oms-filter-section.is-all-empty .oms-filter-section-title::before {
  content: '▸';
  width: 8px;
  font-size: 10px;
}

.oms-filter-section.is-all-empty:not(.is-collapsed) .oms-filter-section-title::before {
  content: '▾';
}

.oms-filter-subitem .oms-count {
  min-width: 30px;
  text-align: center;
}

/* Kolorowe gwiazdki. */
.oms-star.active.star-yellow,
.oms-star-button.active.star-yellow { color: #f59e0b; }
.oms-star.active.star-red,
.oms-star-button.active.star-red { color: #dc2626; }
.oms-star.active.star-black,
.oms-star-button.active.star-black { color: #0f172a; }
.oms-app[data-theme="dark"] .oms-star.active.star-black,
.oms-app[data-theme="dark"] .oms-star-button.active.star-black { color: #e2e8f0; }

/* Karta zamowienia: odstep miedzy Informacje/Szybkie akcje a adresami - bez niego
   karty stykaly sie i nachodzily na siebie. */
.oms-detail-grid + .oms-address-grid,
.oms-detail-grid + * {
  margin-top: 16px;
}

/* Okno pakowania (23.09.2026): "Brak info" i "Szybki mail" jako male przyciski
   w linii z danymi klienta zamiast osobnego rzedu duzych przyciskow - wiecej
   miejsca na produkty. */
.oms-batch-meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
}

.oms-batch-meta-row .oms-batch-meta {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
}

.oms-batch-meta-row .oms-batch-contact-actions {
  display: inline-flex;
  flex: 0 0 auto;
  gap: 6px;
  margin: 0 0 0 auto;
}

.oms-batch-meta-row .oms-batch-contact-actions .oms-btn-light {
  height: 30px;
  min-height: 0;
  border-color: rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.06);
  padding: 0 11px;
  color: #cbd5e1;
  font-size: 12.5px;
  font-weight: 700;
}

.oms-batch-meta-row .oms-batch-contact-actions .oms-btn-light:hover:not(:disabled) {
  border-color: rgba(191, 219, 254, 0.6);
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

html[data-flow-oms-touch="on"] .oms-batch-meta-row .oms-batch-contact-actions .oms-btn-light {
  height: 40px;
  padding: 0 14px;
  font-size: 14px;
}

/* Gwiazdka przy kliencie w oknie pakowania i na karcie w lewej kolumnie. */
.oms-batch-star {
  margin-right: 5px;
  font-size: 1.1em;
  line-height: 1;
}

.oms-batch-star.star-yellow { color: #fbbf24; }
.oms-batch-star.star-red { color: #f87171; }
.oms-batch-star.star-black { color: #ffffff; text-shadow: 0 0 0 #000, 0 0 2px #000; }

.oms-batch-order-card .oms-batch-star.star-black { color: #0b1220; text-shadow: 0 0 1px #ffffff, 0 0 1px #ffffff; }

/* Wybor koloru gwiazdki. */
.oms-star-picker {
  position: fixed;
  z-index: 10000;
  display: inline-flex;
  gap: 4px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #ffffff;
  padding: 5px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.18), 0 2px 6px rgba(15, 23, 42, 0.08);
}

.oms-star-picker button {
  display: inline-flex;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.oms-star-picker button:hover {
  border-color: #e2e8f0;
  background: #f8fafc;
}

.oms-star-picker button.current {
  border-color: #93c5fd;
  background: #eff6ff;
}

.oms-star-picker .star-yellow { color: #f59e0b; }
.oms-star-picker .star-red { color: #dc2626; }
.oms-star-picker .star-black { color: #0f172a; }

.oms-star-picker .oms-star-picker-clear {
  color: #94a3b8;
  font-size: 16px;
}

/* Lewy panel bez zwijania: sklep z samymi zerami ma tylko wyszarzony naglowek. */
.oms-filter-section.is-all-empty .oms-filter-section-title {
  cursor: default;
}

.oms-filter-section.is-all-empty .oms-filter-section-title::before,
.oms-filter-section.is-all-empty:not(.is-collapsed) .oms-filter-section-title::before {
  content: none;
}

/* Okno pakowania bez naglowka "Metoda dostawy" (23.09.2026) - kafle same mowia,
   co to jest. Przelacznik "Duze kafle" siedzi przy Brak info / Szybki mail.
   Odstep u gory zostawia miejsce na etykiete "SUGEROWANA" nad kaflem. */
.oms-batch-delivery-methods {
  margin-top: 4px;
  padding-top: 12px;
}

.oms-batch-meta-row .oms-batch-contact-actions .oms-touch-toggle {
  height: 30px;
  padding: 0 11px;
  font-size: 12px;
}

html[data-flow-oms-touch="on"] .oms-batch-meta-row .oms-batch-contact-actions .oms-touch-toggle {
  height: 40px;
  font-size: 13px;
}

/* Przelacznik "Duze kafle" w linii z Brak info / Szybki mail - te same wymiary
   i ksztalt co sasiednie przyciski; zielony = wlaczone, szary = wylaczone. */
.oms-batch-meta-row .oms-batch-contact-actions .oms-touch-toggle {
  display: inline-flex;
  height: 30px;
  min-height: 0;
  align-items: center;
  margin: 0;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: var(--oms-control-radius-sm);
  background: rgba(255, 255, 255, 0.06);
  padding: 0 11px;
  color: #cbd5e1;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1;
}

.oms-batch-meta-row .oms-batch-contact-actions .oms-touch-toggle:hover {
  border-color: rgba(191, 219, 254, 0.6);
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

.oms-batch-meta-row .oms-batch-contact-actions .oms-touch-toggle.active {
  border-color: rgba(74, 222, 128, 0.7);
  background: rgba(34, 197, 94, 0.2);
  color: #bbf7d0;
}

html[data-flow-oms-touch="on"] .oms-batch-meta-row .oms-batch-contact-actions .oms-touch-toggle {
  height: 40px;
  padding: 0 14px;
  font-size: 14px;
}

/* Podpowiedz "jeszcze nizej": wygaszenie dolu listy + mala pigulka. Wysokosc 0 +
   sticky, wiec niczego nie przesuwa i nie zaslania, gdy lista miesci sie cala. */
.oms-batch-product-list {
  position: relative;
}

.oms-batch-scroll-hint {
  position: sticky;
  bottom: 0;
  z-index: 3;
  height: 0;
  pointer-events: none;
}

.oms-batch-scroll-hint[hidden] {
  display: none;
}

.oms-batch-scroll-hint-inner {
  position: absolute;
  right: 0;
  bottom: -16px;
  left: 0;
  display: flex;
  height: 84px;
  align-items: flex-end;
  justify-content: center;
  background: linear-gradient(180deg, rgba(31, 41, 55, 0) 0%, rgba(31, 41, 55, 0.85) 70%, rgba(31, 41, 55, 0.95) 100%);
  padding-bottom: 14px;
}

.oms-batch-scroll-hint button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(147, 197, 253, 0.45);
  border-radius: 999px;
  background: rgba(30, 58, 138, 0.55);
  padding: 6px 14px;
  color: #dbeafe;
  font: inherit;
  font-size: 13px;
  font-weight: 750;
  cursor: pointer;
  pointer-events: auto;
  animation: oms-scroll-hint-nudge 2.4s ease-in-out infinite;
}

.oms-batch-scroll-hint button:hover {
  background: rgba(37, 99, 235, 0.7);
  color: #ffffff;
}

@keyframes oms-scroll-hint-nudge {
  0%, 70%, 100% { transform: translateY(0); }
  80% { transform: translateY(3px); }
  90% { transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .oms-batch-scroll-hint button { animation: none; }
}

html[data-flow-oms-touch="on"] .oms-batch-scroll-hint button {
  padding: 9px 18px;
  font-size: 15px;
}

/* Uwagi wewnetrzne (24.09.2026). */
.oms-internal-note-card {
  margin: 16px 0;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #cbd5e1;
  border-radius: 12px;
  background: #ffffff;
  padding: 12px 16px;
}

.oms-internal-note-card.has-note {
  border-color: #fcd34d;
  border-left-color: #f59e0b;
  background: #fffbeb;
}

.oms-internal-note-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  margin-bottom: 8px;
}

.oms-internal-note-head strong {
  color: #0f172a;
  font-size: 14px;
}

.oms-internal-note-head span {
  color: #64748b;
  font-size: 12.5px;
}

.oms-internal-note-card textarea {
  display: block;
  width: 100%;
  min-height: 44px;
  resize: vertical;
  border: 1px solid #dbe2ea;
  border-radius: 8px;
  background: #ffffff;
  padding: 8px 10px;
  color: #0f172a;
  font: inherit;
  font-size: 14px;
  line-height: 1.45;
}

.oms-internal-note-card textarea:focus {
  outline: 0;
  border-color: #93c5fd;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.oms-internal-note-card p {
  margin: 0;
  color: #1e293b;
  white-space: pre-line;
}

.oms-internal-note-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

/* Pakowanie: baner uwagi wewnetrznej (niebieski - rozny od zoltych uwag klienta). */
.oms-batch-internal-note {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 10px;
  border: 1px solid rgba(96, 165, 250, 0.6);
  border-left-width: 4px;
  border-radius: 8px;
  background: rgba(30, 58, 138, 0.45);
  padding: 9px 12px;
  color: #dbeafe;
}

.oms-batch-internal-note strong {
  color: #ffffff;
  font-size: 13px;
}

.oms-batch-internal-note span {
  font-size: 15px;
  font-weight: 650;
  white-space: pre-line;
}

.oms-batch-internal-note small {
  color: #93c5fd;
  font-size: 11.5px;
}

html[data-flow-oms-touch="on"] .oms-batch-internal-note span {
  font-size: 17px;
}

.oms-batch-order-note-flag.internal {
  color: #93c5fd;
}

/* Lista: skrot uwagi pod metoda wysylki, pelna tresc w dymku. */
.oms-row-internal-note {
  display: -webkit-box;
  max-width: 100%;
  margin-top: 4px;
  overflow: hidden;
  border-radius: 6px;
  background: #fffbeb;
  padding: 2px 7px;
  color: #92400e;
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.oms-app[data-theme="dark"] .oms-internal-note-card {
  border-color: rgba(148, 163, 184, 0.22);
  background: #0f172a;
}

.oms-app[data-theme="dark"] .oms-internal-note-card.has-note {
  border-color: rgba(245, 158, 11, 0.5);
  background: rgba(120, 53, 15, 0.25);
}

.oms-app[data-theme="dark"] .oms-internal-note-head strong,
.oms-app[data-theme="dark"] .oms-internal-note-card p {
  color: #e2e8f0;
}

/* Wlasne listy rozwijane paska filtrow (24.09.2026) - identyczne w Safari, Chrome
   i na tabletach. Natywny select zostaje schowany pod przyciskiem. */
.oms-app .oms-toolbar-v2 .oms-toolbar-select select.oms-dd-native {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  clip-path: inset(50%);
}

.oms-toolbar-v2 .oms-toolbar-select {
  position: relative;
  cursor: pointer;
}

.oms-dd-button {
  display: inline-flex;
  max-width: 240px;
  align-items: center;
  gap: 6px;
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--oms-slate-900);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.oms-dd-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-dd-chevron {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  background: #64748b;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform 0.16s ease;
}

.oms-dd-button.open .oms-dd-chevron {
  transform: rotate(180deg);
}

.oms-dd-button:focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 3px;
  border-radius: 4px;
}

.oms-toolbar-v2 .oms-toolbar-select.is-set .oms-dd-button {
  color: #1d4ed8;
}

.oms-toolbar-v2 .oms-toolbar-select.is-set .oms-dd-chevron {
  background: #2563eb;
}

.oms-dd-popover {
  position: fixed;
  z-index: 3000;
  max-width: min(460px, calc(100vw - 16px));
  overflow-y: auto;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #ffffff;
  padding: 6px;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.14), 0 3px 8px rgba(15, 23, 42, 0.06);
  animation: oms-dd-in 0.14s ease-out;
  overscroll-behavior: contain;
}

.oms-dd-popover.up {
  animation-name: oms-dd-in-up;
}

@keyframes oms-dd-in {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes oms-dd-in-up {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .oms-dd-popover { animation: none; }
}

.oms-dd-option {
  display: flex;
  width: 100%;
  min-height: 34px;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  padding: 7px 10px;
  color: #1e293b;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
}

.oms-dd-option:hover,
.oms-dd-option:focus-visible {
  outline: 0;
  background: #f1f5f9;
}

.oms-dd-option.selected {
  background: #eff6ff;
  color: #1d4ed8;
  font-weight: 750;
}

.oms-dd-check {
  margin-left: auto;
  padding-left: 12px;
  color: #2563eb;
  font-style: normal;
  font-weight: 900;
}

.oms-dd-group {
  padding: 10px 10px 4px;
  color: #94a3b8;
  font-size: 10.5px;
  font-weight: 850;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

html[data-flow-oms-touch="on"] .oms-dd-option {
  min-height: 44px;
  font-size: 14px;
}

/* Komplet: wiersze z licznikiem w kolku, nazwa, rozmiar jako pigulka. */
.oms-dd-popover.oms-dd-rich {
  width: min(520px, calc(100vw - 16px));
  max-width: min(520px, calc(100vw - 16px));
}

.oms-dd-rich .oms-dd-option {
  white-space: normal;
}

.oms-dd-rich .oms-pm-sep {
  display: none;
}

.oms-dd-rich .oms-pm-count {
  display: inline-flex;
  flex: 0 0 auto;
  min-width: 28px;
  height: 24px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #f1f5f9;
  padding: 0 7px;
  color: #334155;
  font-size: 12px;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
}

.oms-dd-rich .oms-dd-option.selected .oms-pm-count {
  background: #2563eb;
  color: #ffffff;
}

.oms-dd-rich .oms-pm-text {
  display: flex;
  flex: 1 1 auto;
  min-width: 0;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 8px;
}

.oms-dd-rich .oms-pm-title,
.oms-dd-rich .oms-pm-line {
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-dd-rich .oms-pm-line b {
  color: #ea580c;
  font-weight: 900;
}

.oms-dd-rich .oms-pm-line em,
.oms-dd-rich .oms-pm-size {
  border-radius: 5px;
  background: #fef3c7;
  padding: 1px 6px;
  color: #92400e;
  font-style: normal;
  font-size: 11.5px;
  font-weight: 850;
  white-space: nowrap;
}

.oms-dd-rich .oms-pm-size {
  flex: 0 0 auto;
  padding: 3px 7px;
  font-size: 12px;
}

.oms-dd-rich .oms-pm-line i,
.oms-dd-rich .oms-pm-sub,
.oms-dd-rich .oms-pm-tag {
  color: #64748b;
  font-style: normal;
  font-size: 11.5px;
  font-weight: 600;
  white-space: nowrap;
}

.oms-dd-rich .oms-pm-tag {
  flex: 0 0 auto;
  color: #94a3b8;
  font-weight: 700;
}

.oms-app[data-theme="dark"] .oms-dd-button {
  color: #e2e8f0;
}

.oms-app[data-theme="dark"] ~ .oms-dd-popover,
html[data-theme="dark"] .oms-dd-popover {
  border-color: rgba(148, 163, 184, 0.24);
  background: #0f172a;
}

/* Komplet v3 (24.09.2026, po "brzydkie, nieintuicyjne"): jedna linia na opcje,
   rowne kolumny [licznik | nazwa | rozmiar | ptaszek], szare akcenty zamiast
   pomaranczowych i zoltych pigulek. */
.oms-dd-popover.oms-dd-rich {
  width: min(480px, calc(100vw - 16px));
  max-width: min(480px, calc(100vw - 16px));
}

.oms-dd-rich .oms-dd-option {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto 14px;
  align-items: center;
  gap: 12px;
  min-height: 36px;
  padding: 6px 10px;
  white-space: nowrap;
}

.oms-dd-rich .oms-dd-option:first-child {
  grid-template-columns: minmax(0, 1fr) 14px;
}

.oms-dd-rich .oms-pm-count {
  display: inline-flex;
  width: 34px;
  min-width: 0;
  height: 24px;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  background: #f1f5f9;
  padding: 0;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
}

.oms-dd-rich .oms-pm-name {
  min-width: 0;
  overflow: hidden;
  color: #0f172a;
  font-size: 13.5px;
  font-weight: 650;
  text-overflow: ellipsis;
}

.oms-dd-rich .oms-pm-name b {
  color: #64748b;
  font-weight: 800;
}

.oms-dd-rich .oms-pm-name small {
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
}

.oms-dd-rich .oms-pm-name i {
  color: #94a3b8;
  font-style: normal;
  font-weight: 600;
}

.oms-dd-rich .oms-pm-size {
  min-width: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
  color: #64748b;
  font-size: 12.5px;
  font-weight: 650;
  text-align: right;
}

.oms-dd-rich .oms-dd-check {
  margin-left: 0;
  padding-left: 0;
}

.oms-dd-rich .oms-dd-option.selected .oms-pm-count {
  background: #dbeafe;
  color: #1d4ed8;
}

.oms-dd-rich .oms-dd-option.selected .oms-pm-name,
.oms-dd-rich .oms-dd-option.selected .oms-pm-size {
  color: #1d4ed8;
}

.oms-dd-rich .oms-dd-group {
  margin-top: 4px;
  border-top: 1px solid #f1f5f9;
  padding-top: 10px;
}

.oms-dd-rich .oms-dd-group:first-of-type {
  margin-top: 0;
  border-top: 0;
}

/* Kto spakowal / kto nadal - etykieta w kolorze pakowacza (jak w statystykach). */
.oms-packer-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid color-mix(in srgb, var(--packer-color) 45%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--packer-color) 16%, #ffffff);
  padding: 2px 10px 2px 8px;
  color: #0f172a;
  font-size: 13px;
  font-weight: 750;
}

.oms-packer-chip::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--packer-color);
}

/* Jeden przycisk "Połącz" (24.09.2026): punkty w oknie potwierdzenia, blok
   "jedna paczka" na karcie zamowienia i przycisk w asystencie pakowania. */
.oms-confirm-points {
  margin: 10px 0 0;
  padding-left: 18px;
  display: grid;
  gap: 6px;
  font-size: 13.5px;
  line-height: 1.45;
}

.oms-mini-icon.combined-parcel { background: var(--oms-green-600); }

.oms-combine-card {
  display: grid;
  gap: 6px;
  margin-top: 10px;
  border: 1px solid var(--oms-slate-200);
  border-radius: 10px;
  padding: 10px 12px;
  background: var(--oms-slate-50);
}

.oms-combine-card.linked,
.oms-combine-card.sent {
  border-color: var(--oms-green-500);
  background: var(--oms-green-50);
}

.oms-combine-card.suggest {
  border-color: var(--oms-purple-500);
  background: rgba(168, 85, 247, 0.08);
}

.oms-combine-card-head {
  font-size: 13.5px;
  font-weight: 800;
  color: var(--oms-slate-900);
}

.oms-combine-card-head code {
  font-size: 12px;
  font-weight: 700;
}

.oms-combine-card-hint {
  font-size: 12.5px;
  line-height: 1.4;
  color: var(--oms-slate-600);
}

.oms-combine-card-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12.5px;
  border-top: 1px solid var(--oms-slate-200);
  padding-top: 5px;
}

.oms-combine-card-row small {
  font-weight: 700;
  color: var(--oms-green-600);
}

.oms-combine-card .oms-btn-light {
  justify-self: start;
}

html[data-theme="dark"] .oms-combine-card {
  border-color: var(--oms-slate-700);
  background: rgba(15, 23, 42, 0.6);
}

html[data-theme="dark"] .oms-combine-card.linked,
html[data-theme="dark"] .oms-combine-card.sent {
  border-color: var(--oms-green-600);
  background: rgba(34, 197, 94, 0.12);
}

html[data-theme="dark"] .oms-combine-card.suggest {
  background: rgba(168, 85, 247, 0.14);
}

html[data-theme="dark"] .oms-combine-card-head { color: var(--oms-slate-100); }
html[data-theme="dark"] .oms-combine-card-hint { color: var(--oms-slate-300); }
html[data-theme="dark"] .oms-combine-card-row { border-top-color: var(--oms-slate-700); }

.oms-batch-group-combine {
  margin-top: 8px;
  border: 0;
  border-radius: 9px;
  padding: 8px 14px;
  background: var(--oms-brand-primary-bg);
  color: var(--oms-brand-primary-fg);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.oms-batch-group-combine:hover { background: var(--oms-brand-primary-bg-hover); }

.oms-batch-group-warning {
  margin-top: 6px;
  border-radius: 8px;
  padding: 6px 9px;
  background: rgba(245, 158, 11, 0.16);
  color: #fcd34d;
  font-size: 12px;
  font-weight: 800;
}


/* ===== Dziennik kont v2 (admin-only, 27.09.2026) =====
   Wlasne tokeny widoku: jasny i ciemny motyw z jednego miejsca. Kolor konta idzie
   przez --acct-l / --acct-d (inline), kolor mapy dni przez --hb-* / --hf-*. */
.oms-activity-view {
  --act-plane: #f4f6fa;
  --act-surface: #ffffff;
  --act-surface-2: #f7f9fc;
  --act-border: #e6ebf2;
  --act-border-strong: #d5dde8;
  --act-grid: #edf1f6;
  --act-ink: #0f172a;
  --act-ink-2: #475569;
  --act-muted: #7b8aa0;
  --act-accent: #2563eb;
  --act-accent-soft: #eaf1ff;
  --act-good: #0a7d2c;
  --act-good-soft: rgba(12, 163, 12, 0.1);
  --act-bad: #c62f2f;
  --act-bad-soft: #fdeeee;
  --act-warn: #c2410c;
  --act-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 10px 28px -18px rgba(15, 23, 42, 0.25);
  --act-radius: 16px;
  --act-bar-bg: rgba(244, 246, 250, 0.95);
  --act-spark: #c9d3e0;
  background: var(--act-plane);
  color: var(--act-ink);
}

.oms-app[data-theme="dark"] .oms-activity-view {
  --act-plane: #0b1220;
  --act-surface: #121a2b;
  --act-surface-2: #172136;
  --act-border: #1f2a3e;
  --act-border-strong: #2b3a52;
  --act-grid: #1c2739;
  --act-ink: #e8edf5;
  --act-ink-2: #b1bccd;
  --act-muted: #7d8aa0;
  --act-accent: #60a5fa;
  --act-accent-soft: rgba(96, 165, 250, 0.14);
  --act-good: #34d399;
  --act-good-soft: rgba(52, 211, 153, 0.12);
  --act-bad: #f87171;
  --act-bad-soft: rgba(248, 113, 113, 0.13);
  --act-warn: #fb923c;
  --act-shadow: 0 1px 2px rgba(0, 0, 0, 0.35), 0 12px 32px -18px rgba(0, 0, 0, 0.7);
  --act-bar-bg: rgba(11, 18, 32, 0.95);
  --act-spark: #334155;
  background: var(--act-plane);
}

.oms-activity-view .acct { --acct: var(--acct-l, #94a3b8); }
.oms-app[data-theme="dark"] .oms-activity-view .acct { --acct: var(--acct-d, #64748b); }

/* ---- naglowek widoku ---- */
.oms-activity-view .oms-act-top {
  background: var(--act-surface);
  border-bottom-color: var(--act-border);
}
.oms-activity-view .oms-act-top .oms-analytics-title { color: var(--act-ink); letter-spacing: -0.01em; }
.oms-activity-view .oms-act-top .oms-analytics-subtitle { color: var(--act-muted); }
.oms-act-top-actions { display: flex; align-items: center; gap: 8px; }
.oms-act-head-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 14px;
  border: 1px solid var(--act-border-strong);
  border-radius: 10px;
  background: var(--act-surface);
  color: var(--act-ink);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.oms-act-head-btn:hover { background: var(--act-surface-2); border-color: var(--act-muted); }
.oms-act-head-btn svg { width: 16px; height: 16px; flex: 0 0 auto; }
.oms-act-head-btn.is-icon { width: 36px; padding: 0; justify-content: center; }
.oms-activity-view.is-loading .oms-act-refresh svg { animation: oms-act-spin 0.9s linear infinite; }
@keyframes oms-act-spin { to { transform: rotate(360deg); } }

/* ---- uklad ---- */
/* Widok to kolumna flex z przewijaniem: bez tego naglowek sciska sie na niskim ekranie. */
.oms-activity-view > .oms-act-top,
.oms-activity-view > .oms-activity-content { flex-shrink: 0; }
.oms-activity-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 0 22px 32px;
}
.oms-act-main { display: flex; flex-direction: column; gap: 16px; }
.oms-activity-view.is-stale .oms-act-kpis,
.oms-activity-view.is-stale .oms-act-main { opacity: 0.55; transition: opacity 0.2s ease; }
.oms-act-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---- pasek filtrow (przyklejony) ---- */
.oms-act-bar {
  position: sticky;
  top: 0;
  z-index: 6;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0 -22px;
  padding: 14px 22px 12px;
  border-bottom: 1px solid var(--act-border);
  background: var(--act-bar-bg);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  backdrop-filter: saturate(160%) blur(10px);
}
.oms-act-bar-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; }
.oms-act-seg {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border-radius: 12px;
  background: #e8edf4;
}
.oms-app[data-theme="dark"] .oms-act-seg { background: #1a2436; }
.oms-act-seg button {
  height: 32px;
  padding: 0 15px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--act-ink-2);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}
.oms-act-seg button:hover { color: var(--act-ink); }
.oms-act-seg button.is-active {
  background: var(--act-surface);
  color: var(--act-ink);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08), 0 3px 10px -4px rgba(15, 23, 42, 0.18);
}
.oms-act-nav { display: inline-flex; align-items: center; gap: 8px; }
.oms-act-icon {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid var(--act-border-strong);
  border-radius: 10px;
  background: var(--act-surface);
  color: var(--act-ink);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.oms-act-icon:hover:not(:disabled) { background: var(--act-surface-2); border-color: var(--act-muted); }
.oms-act-icon:disabled { opacity: 0.38; cursor: default; }
.oms-act-icon svg { width: 18px; height: 18px; }
.oms-act-period { display: flex; flex-direction: column; min-width: 176px; line-height: 1.2; }
.oms-act-period strong { font-size: 15px; font-weight: 800; letter-spacing: -0.01em; }
.oms-act-period span { font-size: 12px; font-weight: 600; color: var(--act-muted); }
.oms-act-today {
  height: 34px;
  padding: 0 13px;
  border: 0;
  border-radius: 10px;
  background: var(--act-accent-soft);
  color: var(--act-accent);
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}
.oms-act-today:disabled { opacity: 0.4; cursor: default; }
.oms-act-custom { display: inline-flex; flex-wrap: wrap; gap: 8px; }
.oms-act-custom label { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--act-muted); }
.oms-act-custom input {
  height: 34px;
  padding: 0 10px;
  border: 1px solid var(--act-border-strong);
  border-radius: 10px;
  background: var(--act-surface);
  color: var(--act-ink);
  font: inherit;
  font-size: 13px;
  color-scheme: light;
}
.oms-app[data-theme="dark"] .oms-act-custom input { color-scheme: dark; }
.oms-act-status { display: inline-flex; align-items: center; gap: 8px; margin-left: auto; font-size: 12px; font-weight: 700; }
.oms-act-status.is-live { color: var(--act-good); }
.oms-act-status.is-live i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  animation: oms-act-pulse 2.2s ease-out infinite;
}
.oms-act-status.is-error { color: var(--act-bad); }
@keyframes oms-act-pulse {
  0% { box-shadow: 0 0 0 0 rgba(12, 163, 12, 0.45); }
  70% { box-shadow: 0 0 0 7px rgba(12, 163, 12, 0); }
  100% { box-shadow: 0 0 0 0 rgba(12, 163, 12, 0); }
}

/* ---- konta (chipy) ---- */
.oms-act-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.oms-act-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 44px;
  padding: 0 16px 0 7px;
  border: 1px solid var(--act-border);
  border-radius: 999px;
  background: var(--act-surface);
  color: var(--act-ink);
  font: inherit;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease, background 0.15s ease;
}
.oms-act-chip:hover { border-color: var(--act-border-strong); transform: translateY(-1px); box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.35); }
.oms-act-chip.is-active {
  border-color: transparent;
  background: var(--act-ink);
  color: var(--act-surface);
  box-shadow: 0 8px 20px -10px rgba(15, 23, 42, 0.55);
}
.oms-act-chip.acct.is-active { box-shadow: 0 0 0 2px var(--acct), 0 8px 20px -10px rgba(15, 23, 42, 0.55); }
.oms-act-chip-all { padding-left: 9px; }
.oms-act-chip-name { font-size: 13px; font-weight: 800; white-space: nowrap; }
.oms-act-chip-meta { font-size: 12px; font-weight: 600; color: var(--act-muted); white-space: nowrap; }
.oms-act-chip.is-active .oms-act-chip-meta { color: inherit; opacity: 0.7; }
.oms-act-stack { display: inline-flex; align-items: center; }
.oms-act-stack .oms-act-avatar { margin-left: -9px; box-shadow: 0 0 0 2px var(--act-surface); }
.oms-act-stack .oms-act-avatar:first-child { margin-left: 0; }
.oms-act-chip.is-active .oms-act-stack .oms-act-avatar { box-shadow: 0 0 0 2px var(--act-ink); }
.oms-act-live-dot {
  position: absolute;
  top: 5px;
  left: 30px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #16a34a;
  box-shadow: 0 0 0 2px var(--act-surface);
  animation: oms-act-pulse 2.2s ease-out infinite;
}

/* ---- avatar ---- */
.oms-act-avatar {
  --size: 32px;
  position: relative;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: var(--size);
  height: var(--size);
  overflow: hidden;
  border-radius: 50%;
  background: var(--acct, #94a3b8);
  color: #ffffff;
  font-size: calc(var(--size) * 0.38);
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 0 0 2px var(--act-surface), 0 0 0 4px var(--acct, #94a3b8);
}
.oms-act-avatar img { display: block; width: 100%; height: 100%; object-fit: cover; }
.oms-act-avatar-empty { background: var(--act-grid); box-shadow: none; }

/* ---- kafle ---- */
.oms-act-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.oms-act-kpi {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  min-height: 138px;
  padding: 16px 18px 14px;
  border: 1px solid var(--act-border);
  border-radius: var(--act-radius);
  background: var(--act-surface);
  box-shadow: var(--act-shadow);
}
.oms-act-kpi-label { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700; color: var(--act-ink-2); }
.oms-act-kpi-label svg { width: 16px; height: 16px; flex: 0 0 auto; color: var(--act-muted); }
.oms-act-kpi-value { font-size: 28px; font-weight: 800; line-height: 1.12; letter-spacing: -0.02em; color: var(--act-ink); }
.oms-act-kpi-sub { font-size: 12px; font-weight: 600; color: var(--act-muted); }
.oms-act-kpi-foot { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; margin-top: auto; min-height: 30px; }
.oms-act-kpi-delta { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; min-width: 0; }
.oms-act-kpi.is-bad { border-color: rgba(198, 47, 47, 0.35); }
.oms-act-kpi.is-bad .oms-act-kpi-value,
.oms-act-kpi.is-bad .oms-act-kpi-label svg { color: var(--act-bad); }
.oms-act-kpi.is-skeleton { justify-content: center; gap: 12px; }
.oms-act-delta {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--act-surface-2);
  color: var(--act-ink-2);
  font-size: 11.5px;
  font-weight: 800;
  white-space: nowrap;
}
.oms-act-delta.tone-good { background: var(--act-good-soft); color: var(--act-good); }
.oms-act-delta.tone-bad { background: var(--act-bad-soft); color: var(--act-bad); }
.oms-act-delta-note { font-size: 11px; font-weight: 600; color: var(--act-muted); white-space: nowrap; }
.oms-act-spark { display: flex; flex: 0 1 150px; align-items: flex-end; gap: 2px; height: 30px; min-width: 60px; }
.oms-act-spark i {
  flex: 1 1 0;
  min-width: 2px;
  max-width: 12px;
  height: var(--h);
  min-height: 2px;
  border-radius: 3px 3px 0 0;
  background: var(--act-spark);
}
.oms-act-spark i.is-zero { background: var(--act-grid); }
.oms-act-spark i.is-now { background: var(--act-accent); }
.oms-act-spark i.is-future { background: transparent; }

/* ---- karty ---- */
.oms-act-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--act-border);
  border-radius: var(--act-radius);
  background: var(--act-surface);
  box-shadow: var(--act-shadow);
}
.oms-act-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  padding: 16px 18px 12px;
}
.oms-act-card-head h2 { margin: 0; font-size: 15px; font-weight: 800; letter-spacing: -0.01em; color: var(--act-ink); }
.oms-act-card-head p { margin: 3px 0 0; font-size: 12px; font-weight: 600; color: var(--act-muted); }
.oms-act-card-who { display: flex; align-items: center; gap: 14px; min-width: 0; }
.oms-act-btn {
  height: 34px;
  padding: 0 14px;
  border: 1px solid var(--act-border-strong);
  border-radius: 10px;
  background: var(--act-surface);
  color: var(--act-ink);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.oms-act-btn:hover { background: var(--act-surface-2); }
.oms-act-btn.is-primary { border-color: transparent; background: var(--act-accent); color: #ffffff; }
.oms-app[data-theme="dark"] .oms-act-btn.is-primary { color: #0b1220; }

/* ---- os dnia ---- */
.oms-act-gantt { padding: 0 10px 10px; }
.oms-act-gantt-axis,
.oms-act-gantt-row {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr) 250px;
  align-items: center;
  gap: 0 18px;
}
.oms-act-gantt-axis { height: 24px; padding: 0 10px; }
.oms-act-gantt-row {
  width: 100%;
  min-height: 66px;
  padding: 9px 10px;
  border: 0;
  border-top: 1px solid var(--act-grid);
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s ease;
}
.oms-act-gantt-row:hover,
.oms-act-gantt-row:focus-visible { background: var(--act-surface-2); }
.oms-act-gantt-row:focus-visible,
.oms-act-dayrow:focus-visible,
.oms-act-table tbody tr:focus-visible { outline: 2px solid var(--act-accent); outline-offset: -2px; }
.oms-act-who { display: flex; align-items: center; gap: 12px; min-width: 0; }
.oms-act-who > span:last-child { min-width: 0; }
.oms-act-who b,
.oms-act-person b { display: block; overflow: hidden; font-size: 13.5px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; color: var(--act-ink); }
.oms-act-who small,
.oms-act-person small { display: block; font-size: 12px; font-weight: 600; color: var(--act-muted); }
.oms-act-gstats { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; min-width: 0; text-align: right; }
.oms-act-gstats b { font-size: 15px; font-weight: 800; color: var(--act-ink); }
.oms-act-gstats small { font-size: 12px; font-weight: 600; color: var(--act-muted); }
.oms-act-ticks { position: relative; display: block; height: 100%; }
.oms-act-tick { position: absolute; top: 0; bottom: 0; display: flex; align-items: center; transform: translateX(-50%); }
.oms-act-tick.is-first { transform: none; }
.oms-act-tick.is-last { transform: translateX(-100%); }
.oms-act-tick em { font-size: 11px; font-style: normal; font-weight: 700; color: var(--act-muted); font-variant-numeric: tabular-nums; }
.oms-act-lane {
  position: relative;
  display: block;
  height: 30px;
  border-radius: 8px;
  background-color: var(--act-surface-2);
  background-image: linear-gradient(to right, var(--act-grid) 1px, transparent 1px);
  background-size: calc(100% / var(--hours, 10)) 100%;
}
.oms-act-lane.is-empty { background-image: none; }
.oms-act-lane-note { position: absolute; inset: 0; display: flex; align-items: center; padding-left: 12px; font-size: 12px; font-weight: 600; color: var(--act-muted); }
.oms-act-segbar {
  position: absolute;
  top: 7px;
  bottom: 7px;
  min-width: 6px;
  border-radius: 6px;
  background: var(--acct);
  box-shadow: 0 0 0 2px var(--act-surface-2);
  transition: transform 0.15s ease, filter 0.15s ease;
}
.oms-act-segbar:hover { filter: brightness(1.08) saturate(1.1); transform: scaleY(1.3); }
.oms-act-break {
  position: absolute;
  top: 50%;
  height: 2px;
  margin-top: -1px;
  border-radius: 1px;
  background: var(--act-border-strong);
}
.oms-act-break::before { content: ''; position: absolute; left: 0; right: 0; top: -8px; bottom: -8px; }
.oms-act-loginmark {
  position: absolute;
  top: 50%;
  width: 12px;
  height: 12px;
  margin: -6px 0 0 -6px;
  border: 2px solid var(--acct);
  border-radius: 50%;
  background: var(--act-surface);
}
.oms-act-now { position: absolute; top: -4px; bottom: -4px; width: 2px; margin-left: -1px; border-radius: 2px; background: #ef4444; }
.oms-act-now::before { content: ''; position: absolute; top: -3px; left: -3px; width: 8px; height: 8px; border-radius: 50%; background: #ef4444; }

/* ---- tabela zestawienia ---- */
.oms-act-table-wrap { overflow-x: auto; }
.oms-act-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; color: var(--act-ink); }
.oms-act-table th {
  padding: 9px 14px;
  border-bottom: 1px solid var(--act-border);
  background: var(--act-surface);
  color: var(--act-muted);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-align: right;
  white-space: nowrap;
}
.oms-act-table th[title] { cursor: help; }
.oms-act-table td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--act-grid);
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.oms-act-table th:first-child,
.oms-act-table td:first-child { text-align: left; padding-left: 18px; }
.oms-act-table tbody tr { cursor: pointer; transition: background 0.12s ease; }
.oms-act-table tbody tr:hover td { background: var(--act-surface-2); }
.oms-act-table tbody tr:last-child td { border-bottom: 0; }
.oms-act-table tfoot td { border-top: 1px solid var(--act-border); border-bottom: 0; background: var(--act-surface-2); font-weight: 800; }
.oms-act-person {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  max-width: 100%;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.oms-act-person > span:last-child { min-width: 0; }
.oms-act-barcell { display: inline-flex; flex-direction: column; align-items: flex-end; gap: 6px; min-width: 128px; }
.oms-act-barcell b { font-weight: 800; }
.oms-act-minibar { display: block; width: 100%; height: 4px; overflow: hidden; border-radius: 2px; background: var(--act-grid); }
.oms-act-minibar i { display: block; height: 100%; border-radius: 2px; background: var(--acct); }
.oms-act-bad { display: inline-flex; align-items: center; gap: 4px; font-style: normal; font-weight: 800; color: var(--act-bad); }
.oms-act-bad svg { width: 14px; height: 14px; }
.oms-act-zero { font-style: normal; color: var(--act-muted); }
.oms-act-inactive { margin: 0; padding: 12px 18px 14px; border-top: 1px solid var(--act-grid); font-size: 12px; font-weight: 600; color: var(--act-muted); }
.oms-act-inactive em { font-style: normal; font-weight: 500; }

/* ---- mapa dni ---- */
.oms-act-heat-wrap { overflow-x: auto; padding: 0 14px 4px; }
.oms-act-heat-table { width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 4px; }
.oms-act-heat-table th,
.oms-act-heat-table td { padding: 0; text-align: center; }
.oms-act-heat-table thead th { padding: 2px 0 6px; font-weight: 700; color: var(--act-muted); }
.oms-act-heat-table thead th span { display: block; font-size: 10.5px; font-weight: 700; }
.oms-act-heat-table thead th b { display: block; font-size: 13px; font-weight: 800; color: var(--act-ink); font-variant-numeric: tabular-nums; }
.oms-act-heat-table thead th.is-weekend b { color: var(--act-muted); }
.oms-act-heat-table thead th.is-today b { color: var(--act-accent); }
.oms-act-heat-table thead th.is-today span { color: var(--act-accent); }
.oms-act-heat-table th.oms-act-heat-who {
  position: sticky;
  left: 0;
  z-index: 1;
  width: 200px;
  padding-right: 12px;
  background: var(--act-surface);
  text-align: left;
}
.oms-act-heat-table tfoot th.oms-act-heat-who { font-size: 12px; font-weight: 800; color: var(--act-muted); }
.oms-act-heat-table tfoot td { padding-top: 4px; font-size: 11px; font-weight: 700; color: var(--act-muted); font-variant-numeric: tabular-nums; }
.oms-act-heat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  width: 100%;
  height: 50px;
  padding: 0 2px;
  border: 0;
  border-radius: 10px;
  background: var(--hb-l);
  color: var(--hf-l);
  font: inherit;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.oms-app[data-theme="dark"] .oms-act-heat { background: var(--hb-d); color: var(--hf-d); }
.oms-act-heat:hover,
.oms-act-heat:focus-visible { transform: translateY(-1px); box-shadow: 0 0 0 2px var(--act-surface), 0 0 0 4px var(--act-accent); outline: none; }
.oms-act-heat b { font-size: 12.5px; font-weight: 800; font-variant-numeric: tabular-nums; }
.oms-act-heat small { font-size: 10.5px; font-weight: 700; opacity: 0.85; font-variant-numeric: tabular-nums; }
.oms-act-heat.has-problem { box-shadow: inset 0 -3px 0 #ef4444; }
.oms-act-heat-empty,
.oms-act-heat-future { position: relative; display: block; height: 50px; border-radius: 10px; }
.oms-act-heat-empty { background: var(--act-surface-2); }
.oms-act-heat-empty.is-login::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 8px;
  height: 8px;
  margin: -4px 0 0 -4px;
  border: 2px solid var(--act-muted);
  border-radius: 50%;
}
.oms-act-heat-future { border: 1px solid var(--act-grid); }
.oms-act-heat-table.is-compact .oms-act-heat,
.oms-act-heat-table.is-compact .oms-act-heat-empty,
.oms-act-heat-table.is-compact .oms-act-heat-future { height: 46px; border-radius: 8px; }
.oms-act-heat-table.is-compact .oms-act-heat b { font-size: 11.5px; }
.oms-act-heat-table.is-compact .oms-act-heat small { font-size: 9.5px; }
.oms-act-heat-table.is-compact { border-spacing: 3px; }
.oms-act-heat-table .oms-act-heat-total { width: 112px; padding-left: 10px; text-align: right; }
.oms-act-heat-total b { display: block; font-size: 13px; font-weight: 800; color: var(--act-ink); white-space: nowrap; }
.oms-act-heat-total small { display: block; font-size: 11px; font-weight: 600; color: var(--act-muted); white-space: nowrap; }
.oms-act-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  padding: 10px 18px 16px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--act-muted);
}
.oms-act-legend-step { display: inline-flex; align-items: center; gap: 6px; }
.oms-act-legend-step i { display: inline-block; width: 18px; height: 12px; border-radius: 4px; background: var(--hb-l); }
.oms-app[data-theme="dark"] .oms-act-legend-step i { background: var(--hb-d); }
.oms-act-legend-step i.is-login { box-sizing: border-box; width: 12px; border: 2px solid var(--act-muted); border-radius: 50%; background: transparent; }
.oms-act-legend-step i.is-problem { background: var(--act-surface-2); box-shadow: inset 0 -3px 0 #ef4444; }

/* ---- jedno konto: dzien po dniu ---- */
.oms-act-days { padding: 0 10px 10px; }
.oms-act-daysaxis,
.oms-act-dayrow {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) 108px 112px 70px 70px 64px;
  align-items: center;
  gap: 0 14px;
}
.oms-act-daysaxis {
  height: 28px;
  padding: 0 10px;
  font-size: 11px;
  font-weight: 800;
  color: var(--act-muted);
}
.oms-act-daysaxis > span:nth-child(n + 3) { text-align: right; }
.oms-act-dayrow {
  width: 100%;
  min-height: 48px;
  padding: 6px 10px;
  border: 0;
  border-top: 1px solid var(--act-grid);
  background: transparent;
  color: var(--act-ink);
  font: inherit;
  text-align: left;
}
.oms-act-dayrow > span:nth-child(n + 3) { font-size: 13px; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
button.oms-act-dayrow { cursor: pointer; transition: background 0.12s ease; }
button.oms-act-dayrow:hover { background: var(--act-surface-2); }
.oms-act-dayrow.is-empty,
.oms-act-dayrow.is-future { color: var(--act-muted); }
.oms-act-dayrow.is-future { opacity: 0.6; }
.oms-act-daylabel b { display: block; font-size: 13px; font-weight: 800; }
.oms-act-daylabel small { display: block; min-height: 14px; font-size: 11.5px; font-weight: 600; color: var(--act-muted); }
.oms-act-dayrow.is-weekend .oms-act-daylabel b { color: var(--act-muted); }
.oms-act-weeksum {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 16px;
  margin: 2px 10px 12px;
  padding: 10px 14px;
  border-radius: 12px;
  background: var(--act-surface-2);
  font-size: 12px;
  font-weight: 600;
  color: var(--act-ink-2);
}
.oms-act-weeksum > b:first-child { color: var(--act-ink); }

/* ---- stany ---- */
.oms-act-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 52px 20px;
  text-align: center;
}
.oms-act-state > svg { width: 40px; height: 40px; color: var(--act-muted); }
.oms-act-state h3 { margin: 0; font-size: 15px; font-weight: 800; color: var(--act-ink); }
.oms-act-state p { max-width: 460px; margin: 0; font-size: 13px; color: var(--act-muted); }
.oms-act-state-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 6px; }
.oms-act-state.is-inline { padding: 36px 12px; }
.oms-act-loading { display: flex; flex-direction: column; gap: 14px; padding: 22px; }
.oms-act-skeleton {
  display: block;
  height: 14px;
  border-radius: 7px;
  background: linear-gradient(90deg, var(--act-surface-2) 0%, var(--act-grid) 50%, var(--act-surface-2) 100%);
  background-size: 200% 100%;
  animation: oms-act-shimmer 1.3s linear infinite;
}
.oms-act-skeleton.is-big { height: 28px; }
@keyframes oms-act-shimmer {
  from { background-position: 200% 0; }
  to { background-position: -200% 0; }
}

/* ---- szuflada: przebieg dnia ---- */
.oms-activity-drawer-root { position: fixed; inset: 0; z-index: 2300; }
.oms-activity-drawer-root[hidden] { display: none; }
.oms-act-drawer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.38);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
  animation: oms-act-fade 0.2s ease-out;
}
.oms-act-drawer {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  width: min(680px, 100vw);
  background: var(--act-surface);
  color: var(--act-ink);
  box-shadow: -24px 0 60px -20px rgba(15, 23, 42, 0.5);
  animation: oms-act-slide 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
}
@keyframes oms-act-slide {
  from { transform: translateX(32px); opacity: 0; }
  to { transform: none; opacity: 1; }
}
@keyframes oms-act-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}
.oms-act-drawer-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--act-border);
}
.oms-act-drawer-who { display: flex; align-items: center; gap: 14px; min-width: 0; }
.oms-act-drawer-who > div { min-width: 0; }
.oms-act-drawer-who h2 { margin: 0; font-size: 17px; font-weight: 800; letter-spacing: -0.01em; }
.oms-act-drawer-who p { margin: 2px 0 0; overflow: hidden; font-size: 12px; font-weight: 600; color: var(--act-muted); text-overflow: ellipsis; white-space: nowrap; }
.oms-act-drawer-nav { display: flex; align-items: center; gap: 6px; }
.oms-act-drawer-day { min-width: 148px; line-height: 1.2; text-align: center; }
.oms-act-drawer-day b { display: block; font-size: 14px; font-weight: 800; }
.oms-act-drawer-day small { display: block; font-size: 11.5px; font-weight: 600; color: var(--act-muted); }
.oms-act-drawer-close { margin-left: 4px; }
.oms-act-drawer-body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 16px 18px 32px;
}
.oms-act-drawer-body > * { flex-shrink: 0; }
.oms-act-drawer-loading { display: flex; flex-direction: column; gap: 14px; padding-top: 8px; }
.oms-act-dstats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.oms-act-dstat { min-width: 0; padding: 10px 12px; border: 1px solid var(--act-border); border-radius: 12px; background: var(--act-surface-2); }
.oms-act-dstat span { display: block; font-size: 11.5px; font-weight: 700; color: var(--act-muted); }
.oms-act-dstat b { display: block; margin-top: 3px; overflow: hidden; font-size: 15px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.oms-act-dstat.is-bad { border-color: rgba(198, 47, 47, 0.35); background: var(--act-bad-soft); }
.oms-act-dstat.is-bad b { color: var(--act-bad); }
.oms-act-dlane { padding: 10px 12px 12px; border: 1px solid var(--act-border); border-radius: 12px; }
.oms-act-dlane .oms-act-ticks { height: 20px; margin-bottom: 6px; }
.oms-act-sessions { border: 1px solid var(--act-border); border-radius: 12px; }
.oms-act-sessions-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; font-size: 13px; color: var(--act-ink-2); }
.oms-act-sessions-head b { color: var(--act-ink); }
.oms-act-sessions-head .oms-act-open-note { color: var(--act-accent); }
.oms-act-sessions-head button { flex: 0 0 auto; border: 0; background: none; color: var(--act-accent); font: inherit; font-size: 12.5px; font-weight: 800; cursor: pointer; }
.oms-act-sessions-list { max-height: 260px; overflow-y: auto; border-top: 1px solid var(--act-border); }
.oms-act-session {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--act-grid);
  font-size: 12.5px;
  font-variant-numeric: tabular-nums;
}
.oms-act-session:last-child { border-bottom: 0; }
.oms-act-pill { display: inline-flex; padding: 2px 9px; border-radius: 999px; background: var(--act-surface-2); color: var(--act-ink-2); font-size: 11px; font-weight: 800; }
.oms-act-pill.is-open { background: var(--act-accent-soft); color: var(--act-accent); }
.oms-act-pill.is-warn { background: rgba(234, 88, 12, 0.12); color: var(--act-warn); }
.oms-act-feed-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.oms-act-fchip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 12px;
  border: 1px solid var(--act-border);
  border-radius: 999px;
  background: var(--act-surface);
  color: var(--act-ink-2);
  font: inherit;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
}
.oms-act-fchip:hover { border-color: var(--act-border-strong); color: var(--act-ink); }
.oms-act-fchip em { font-style: normal; font-weight: 700; color: var(--act-muted); }
.oms-act-fchip.is-active { border-color: transparent; background: var(--act-ink); color: var(--act-surface); }
.oms-act-fchip.is-active em { color: inherit; opacity: 0.7; }
.oms-act-fchip.is-problems:not(.is-active) { border-color: rgba(198, 47, 47, 0.35); color: var(--act-bad); }
.oms-act-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--act-ink-2);
  cursor: pointer;
}
.oms-act-switch input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.oms-act-switch span { position: relative; flex: 0 0 auto; width: 34px; height: 20px; border-radius: 999px; background: var(--act-border-strong); transition: background 0.15s ease; }
.oms-act-switch span::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.3);
  transition: transform 0.15s ease;
}
.oms-act-switch input:checked + span { background: var(--act-accent); }
.oms-act-switch input:checked + span::after { transform: translateX(14px); }
.oms-act-switch input:focus-visible + span { box-shadow: 0 0 0 3px var(--act-accent-soft); }
.oms-act-feed-note { margin: 0; padding: 8px 12px; border-radius: 10px; background: var(--act-bad-soft); color: var(--act-bad); font-size: 12px; font-weight: 700; }
.oms-act-feed { display: flex; flex-direction: column; transition: opacity 0.2s ease; }
.oms-act-feed.is-refreshing { opacity: 0.55; }
.oms-act-feed-empty { margin: 8px 0; font-size: 13px; color: var(--act-muted); }
.oms-act-hour + .oms-act-hour { margin-top: 4px; }
.oms-act-hour h4 {
  position: sticky;
  top: -16px;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 10px 0 6px;
  background: var(--act-surface);
  font-size: 12px;
  font-weight: 800;
  color: var(--act-ink);
  font-variant-numeric: tabular-nums;
}
.oms-act-hour h4 em { font-size: 11.5px; font-style: normal; font-weight: 700; color: var(--act-muted); }
.oms-act-feed-item {
  position: relative;
  display: grid;
  grid-template-columns: 44px 12px minmax(0, 1fr);
  gap: 0 10px;
  padding: 5px 0;
  font-size: 13px;
}
.oms-act-feed-item::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 59px;
  width: 2px;
  background: var(--act-grid);
}
.oms-act-feed-item time { padding-top: 3px; font-size: 12px; font-weight: 700; color: var(--act-muted); font-variant-numeric: tabular-nums; }
.oms-act-feed-dot {
  --tone: #94a3b8;
  position: relative;
  z-index: 1;
  width: 12px;
  height: 12px;
  margin-top: 5px;
  border-radius: 50%;
  background: var(--tone);
  box-shadow: 0 0 0 3px var(--act-surface);
}
.oms-act-feed-item.is-marker .oms-act-feed-dot { border-radius: 3px; transform: scale(0.85); }
.oms-act-feed-body { min-width: 0; }
.oms-act-feed-line { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.oms-act-order {
  font-weight: 800;
  color: var(--act-ink);
  text-decoration: none;
  border-bottom: 1px solid var(--act-border-strong);
  font-variant-numeric: tabular-nums;
}
a.oms-act-order:hover { color: var(--act-accent); border-bottom-color: currentColor; }
.oms-act-step {
  --tone: #94a3b8;
  --tone-soft: rgba(148, 163, 184, 0.16);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--tone-soft);
  color: var(--act-ink);
  font-size: 12px;
  font-weight: 700;
}
.oms-act-step em { font-style: normal; font-weight: 700; opacity: 0.75; }
.oms-act-step.is-problem { color: var(--act-bad); }
.oms-act-step.is-technical { opacity: 0.7; }
.oms-act-feed-error {
  margin: 6px 0 2px;
  padding: 8px 10px;
  border-radius: 8px;
  background: var(--act-bad-soft);
  color: var(--act-bad);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.oms-act-feed-dot.tone-ok, .oms-act-step.tone-ok { --tone: #16a34a; --tone-soft: rgba(22, 163, 74, 0.12); }
.oms-act-feed-dot.tone-ship, .oms-act-step.tone-ship { --tone: #2563eb; --tone-soft: rgba(37, 99, 235, 0.11); }
.oms-act-feed-dot.tone-print, .oms-act-step.tone-print { --tone: #0891b2; --tone-soft: rgba(8, 145, 178, 0.12); }
.oms-act-feed-dot.tone-session, .oms-act-step.tone-session { --tone: #7c3aed; --tone-soft: rgba(124, 58, 237, 0.11); }
.oms-act-feed-dot.tone-edit, .oms-act-step.tone-edit { --tone: #d97706; --tone-soft: rgba(217, 119, 6, 0.13); }
.oms-act-feed-dot.tone-warn, .oms-act-step.tone-warn { --tone: #ea580c; --tone-soft: rgba(234, 88, 12, 0.12); }
.oms-act-feed-dot.tone-error, .oms-act-step.tone-error { --tone: #dc2626; --tone-soft: rgba(220, 38, 38, 0.12); }
.oms-app[data-theme="dark"] .oms-act-step { --tone-soft: rgba(148, 163, 184, 0.16); }
.oms-app[data-theme="dark"] .oms-act-step.tone-ok { --tone-soft: rgba(52, 211, 153, 0.16); }
.oms-app[data-theme="dark"] .oms-act-step.tone-ship { --tone-soft: rgba(96, 165, 250, 0.18); }
.oms-app[data-theme="dark"] .oms-act-step.tone-print { --tone-soft: rgba(34, 211, 238, 0.15); }
.oms-app[data-theme="dark"] .oms-act-step.tone-session { --tone-soft: rgba(167, 139, 250, 0.18); }
.oms-app[data-theme="dark"] .oms-act-step.tone-edit { --tone-soft: rgba(251, 191, 36, 0.16); }
.oms-app[data-theme="dark"] .oms-act-step.tone-warn { --tone-soft: rgba(251, 146, 60, 0.17); }
.oms-app[data-theme="dark"] .oms-act-step.tone-error { --tone-soft: rgba(248, 113, 113, 0.18); }

/* ---- dymek ---- */
.oms-activity-tip {
  position: fixed;
  z-index: 2350;
  max-width: 290px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #0f172a;
  color: #f8fafc;
  font-size: 12px;
  line-height: 1.4;
  box-shadow: 0 14px 32px -12px rgba(15, 23, 42, 0.6);
  pointer-events: none;
}
.oms-activity-tip[hidden] { display: none; }
.oms-app[data-theme="dark"] .oms-activity-tip { background: #e8edf5; color: #0f172a; }
.oms-activity-tip strong { display: block; margin-bottom: 4px; font-size: 12px; font-weight: 800; }
.oms-act-tip-row { display: flex; align-items: center; gap: 8px; }
.oms-act-tip-row i { flex: 0 0 auto; width: 12px; height: 3px; border-radius: 2px; }
.oms-act-tip-row b { font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.oms-act-tip-row span { opacity: 0.75; }
.oms-activity-tip p { margin: 6px 0 0; opacity: 0.7; }

@media (prefers-reduced-motion: reduce) {
  .oms-act-status.is-live i,
  .oms-act-live-dot,
  .oms-act-drawer,
  .oms-act-drawer-backdrop,
  .oms-act-skeleton,
  .oms-activity-view.is-loading .oms-act-refresh svg { animation: none; }
  .oms-act-chip:hover,
  .oms-act-heat:hover,
  .oms-act-segbar:hover { transform: none; }
}

@media (max-width: 1320px) {
  .oms-act-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 1100px) {
  .oms-act-gantt-axis,
  .oms-act-gantt-row { grid-template-columns: 190px minmax(0, 1fr) 200px; gap: 0 14px; }
}

@media (max-width: 900px) {
  .oms-activity-content { padding: 0 12px 24px; }
  .oms-act-bar { position: static; margin: 0 -12px; padding: 12px; }
  .oms-act-chips {
    flex-wrap: nowrap;
    margin: 0 -12px;
    padding: 2px 12px 6px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .oms-act-chips::-webkit-scrollbar { display: none; }
  .oms-act-chip { flex: 0 0 auto; }
  .oms-act-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .oms-act-kpi { min-height: 0; padding: 14px; }
  .oms-act-kpi-value { font-size: 23px; }
  .oms-act-gantt-axis,
  .oms-act-gantt-row { grid-template-columns: 132px minmax(0, 1fr); }
  .oms-act-gantt-row .oms-act-gstats,
  .oms-act-gantt-axis > span:last-child { display: none; }
  .oms-act-daysaxis,
  .oms-act-dayrow { grid-template-columns: 70px minmax(0, 1fr) 96px 52px; gap: 0 10px; }
  .oms-act-daysaxis > span:nth-child(3),
  .oms-act-dayrow > span:nth-child(3),
  .oms-act-daysaxis > span:nth-child(n + 6),
  .oms-act-dayrow > span:nth-child(n + 6) { display: none; }
  .oms-act-dstats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .oms-act-gantt .oms-act-tick.is-minor,
  .oms-act-days .oms-act-tick.is-minor { display: none; }
  .oms-act-status { margin-left: 0; }
  .oms-act-switch { margin-left: 0; }
}

@media (max-width: 560px) {
  .oms-act-seg button { padding: 0 11px; }
  .oms-act-period { min-width: 0; }
  .oms-act-chip { height: 40px; }
  .oms-act-drawer-head { padding: 14px; }
  .oms-act-drawer-body { padding: 14px 14px 28px; }
  .oms-act-drawer-nav { width: 100%; justify-content: space-between; }
  .oms-act-drawer-day { flex: 1 1 auto; }
  .oms-act-head-btn span { display: none; }
  .oms-act-head-btn { width: 36px; padding: 0; justify-content: center; }
}

/* Polacz: sekcje zamowien w jednym kartonie na ekranie pakowania lidera (29.09.2026). */
.oms-batch-partner-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 12px 0 6px;
  padding: 6px 10px;
  border-left: 4px solid #22c55e;
  border-radius: 6px;
  background: rgba(34, 197, 94, 0.12);
  color: #dcfce7;
  font-size: 15px;
  font-weight: 850;
}

.oms-batch-partner-head:first-child {
  margin-top: 0;
}

.oms-batch-partner-head span {
  color: #86efac;
  font-size: 11.5px;
  font-weight: 760;
  text-transform: uppercase;
}

/* ==========================================================================
   Magazyn 3.0 (29.09.2026): Przeglad / Towar / Regaly + karta produktu.
   Prefiks wh3-. Kolory tylko przez tokeny, ciemny motyw przez
   html[data-flow-oms-theme="dark"] (szuflada zyje poza .oms-app).
   ========================================================================== */
.wh3,
.wh3-nav {
  --wh3-card: #ffffff;
  --wh3-soft: #f6f7fb;
  --wh3-soft-2: #eef1f7;
  --wh3-ink: #0f172a;
  --wh3-ink-2: #334155;
  --wh3-mute: #64748b;
  --wh3-faint: #94a3b8;
  --wh3-line: #e6e9f1;
  --wh3-line-2: #f0f2f7;
  --wh3-acc: #2563eb;
  --wh3-acc-ink: #1d4ed8;
  --wh3-acc-soft: #eef3ff;
  --wh3-acc-rgb: 37, 99, 235;
  --wh3-nav-active: #0f172a;
  --wh3-nav-active-ink: #ffffff;
  --wh3-out: #e11d48;
  --wh3-out-ink: #be123c;
  --wh3-out-soft: #fff1f3;
  --wh3-out-line: #fecdd6;
  --wh3-crit: #ea580c;
  --wh3-crit-ink: #c2410c;
  --wh3-crit-soft: #fff5ed;
  --wh3-crit-line: #fed7aa;
  --wh3-low: #d97706;
  --wh3-low-ink: #a16207;
  --wh3-low-soft: #fffbeb;
  --wh3-low-line: #fde9b3;
  --wh3-ok: #16a34a;
  --wh3-ok-ink: #15803d;
  --wh3-ok-soft: #effaf3;
  --wh3-frozen: #0891b2;
  --wh3-frozen-ink: #0e7490;
  --wh3-frozen-soft: #ecfbfe;
  --wh3-frozen-line: #c5f1fa;
  --wh3-issue: #7c3aed;
  --wh3-issue-soft: #f4efff;
  --wh3-rack-bg: #eef2ff;
  --wh3-rack-ink: #3730a3;
  --wh3-rack-line: #dfe5ff;
  --wh3-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 6px 20px rgba(15, 23, 42, 0.05);
  --wh3-shadow-hover: 0 2px 4px rgba(15, 23, 42, 0.05), 0 14px 32px rgba(15, 23, 42, 0.09);
  --wh3-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  color: var(--wh3-ink);
  font-family: Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html[data-flow-oms-theme="dark"] .wh3,
html[data-flow-oms-theme="dark"] .wh3-nav {
  --wh3-card: #111827;
  --wh3-soft: #0f1623;
  --wh3-soft-2: #182233;
  --wh3-ink: #f1f5f9;
  --wh3-ink-2: #cbd5e1;
  --wh3-mute: #94a3b8;
  --wh3-faint: #64748b;
  --wh3-line: #243044;
  --wh3-line-2: #1a2436;
  --wh3-acc: #60a5fa;
  --wh3-acc-ink: #93c5fd;
  --wh3-acc-soft: rgba(96, 165, 250, 0.13);
  --wh3-acc-rgb: 96, 165, 250;
  --wh3-nav-active: #f1f5f9;
  --wh3-nav-active-ink: #0f172a;
  --wh3-out: #fb7185;
  --wh3-out-ink: #fda4af;
  --wh3-out-soft: rgba(251, 113, 133, 0.12);
  --wh3-out-line: rgba(251, 113, 133, 0.32);
  --wh3-crit: #fb923c;
  --wh3-crit-ink: #fdba74;
  --wh3-crit-soft: rgba(251, 146, 60, 0.12);
  --wh3-crit-line: rgba(251, 146, 60, 0.32);
  --wh3-low: #fbbf24;
  --wh3-low-ink: #fcd34d;
  --wh3-low-soft: rgba(251, 191, 36, 0.1);
  --wh3-low-line: rgba(251, 191, 36, 0.28);
  --wh3-ok: #4ade80;
  --wh3-ok-ink: #86efac;
  --wh3-ok-soft: rgba(74, 222, 128, 0.1);
  --wh3-frozen: #22d3ee;
  --wh3-frozen-ink: #67e8f9;
  --wh3-frozen-soft: rgba(34, 211, 238, 0.1);
  --wh3-frozen-line: rgba(34, 211, 238, 0.28);
  --wh3-issue: #a78bfa;
  --wh3-issue-soft: rgba(167, 139, 250, 0.12);
  --wh3-rack-bg: rgba(129, 140, 248, 0.16);
  --wh3-rack-ink: #c7d2fe;
  --wh3-rack-line: rgba(129, 140, 248, 0.3);
  --wh3-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  --wh3-shadow-hover: 0 8px 28px rgba(0, 0, 0, 0.45);
}

#omsWarehouseHubGrid.oms-wh3-host {
  display: block;
  min-width: 0;
  margin: 0;
}

/* .oms-control-grid ma display:grid, ktory przebija atrybut hidden */
#omsWarehouseHubGrid[hidden],
#omsWarehouseCategoriesGrid[hidden] {
  display: none !important;
}

.wh3 *,
.wh3-nav * {
  box-sizing: border-box;
}

.wh3 button,
.wh3-nav button {
  font: inherit;
  color: inherit;
}

.wh3 :focus-visible,
.wh3-nav :focus-visible {
  outline: 2px solid var(--wh3-acc);
  outline-offset: 2px;
}

/* --- nawigacja sekcji ---------------------------------------------------- */
.wh3-nav {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  min-width: 0;
}

.wh3-sections {
  display: flex;
  gap: 4px;
  width: max-content;
  max-width: 100%;
  padding: 5px;
  overflow-x: auto;
  scrollbar-width: none;
  background: var(--wh3-card);
  border: 1px solid var(--wh3-line);
  border-radius: 15px;
  box-shadow: var(--wh3-shadow);
}

.wh3-sections::-webkit-scrollbar {
  display: none;
}

.wh3-sections button {
  position: relative;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 16px;
  border: 0;
  border-radius: 11px;
  background: transparent;
  color: var(--wh3-ink-2);
  font-size: 14px;
  font-weight: 650;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.wh3-sections button svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  opacity: 0.75;
}

.wh3-sections button:hover {
  background: var(--wh3-soft-2);
  color: var(--wh3-ink);
}

.wh3-sections button.active {
  background: var(--wh3-nav-active);
  color: var(--wh3-nav-active-ink);
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.18);
}

.wh3-sections button.active svg {
  opacity: 1;
}

.wh3-badge {
  display: inline-grid;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  place-items: center;
  border-radius: 999px;
  background: var(--wh3-out);
  color: #fff;
  font-size: 11.5px;
  font-style: normal;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.wh3-subtabs {
  display: flex;
  gap: 26px;
  overflow-x: auto;
  scrollbar-width: none;
  border-bottom: 1px solid var(--wh3-line);
}

.wh3-subtabs::-webkit-scrollbar {
  display: none;
}

.wh3-subtabs button {
  flex: 0 0 auto;
  padding: 8px 1px 11px;
  border: 0;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  background: transparent;
  color: var(--wh3-mute);
  font-size: 13.5px;
  font-weight: 650;
  cursor: pointer;
}

.wh3-subtabs button:hover {
  color: var(--wh3-ink);
}

.wh3-subtabs button.active {
  border-bottom-color: var(--wh3-acc);
  color: var(--wh3-ink);
}

/* --- elementy wspolne ---------------------------------------------------- */
.wh3 {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
  min-width: 0;
}

.wh3-card {
  min-width: 0;
  padding: 18px 20px;
  border: 1px solid var(--wh3-line);
  border-radius: 18px;
  background: var(--wh3-card);
  box-shadow: var(--wh3-shadow);
}

.wh3-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.wh3-card-head h3,
.wh3-dsec h3 {
  margin: 0;
  color: var(--wh3-ink);
  font-size: 15px;
  font-weight: 750;
  letter-spacing: -0.015em;
}

.wh3-card-head p {
  margin: 3px 0 0;
  color: var(--wh3-mute);
  font-size: 12.5px;
  line-height: 1.4;
}

.wh3-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--wh3-mute);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.wh3-link {
  flex: 0 0 auto;
  padding: 4px 0;
  border: 0;
  background: transparent;
  color: var(--wh3-acc) !important;
  font-size: 13px !important;
  font-weight: 650 !important;
  cursor: pointer;
  white-space: nowrap;
}

.wh3-link:hover {
  color: var(--wh3-acc-ink) !important;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.wh3-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 36px;
  padding: 0 14px;
  border: 1px solid var(--wh3-line);
  border-radius: 10px;
  background: var(--wh3-card);
  color: var(--wh3-ink) !important;
  font-size: 13.5px !important;
  font-weight: 650 !important;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.wh3-btn:hover {
  background: var(--wh3-soft-2);
}

.wh3-btn.primary {
  border-color: var(--wh3-acc);
  background: var(--wh3-acc);
  color: #fff !important;
}

.wh3-btn.primary:hover {
  background: var(--wh3-acc-ink);
}

.wh3-btn.ghost {
  border-color: transparent;
  background: transparent;
  color: var(--wh3-acc) !important;
}

.wh3-btn:disabled {
  opacity: 0.55;
  cursor: default;
}

.wh3-tag {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--wh3-soft-2);
  color: var(--wh3-ink-2);
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0;
  vertical-align: 1px;
  white-space: nowrap;
}

.wh3-fresh {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--wh3-mute);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  white-space: nowrap;
}

.wh3-fresh i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--wh3-ok);
  box-shadow: 0 0 0 3px var(--wh3-ok-soft);
}

.wh3-fresh.loading i {
  background: var(--wh3-acc);
  animation: wh3-pulse 1s ease-in-out infinite;
}

@keyframes wh3-pulse {
  50% { opacity: 0.3; }
}

.wh3-pill {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--wh3-soft-2);
  color: var(--wh3-ink-2);
  font-size: 11.5px;
  font-weight: 750;
  white-space: nowrap;
}

.wh3-pill.st-out { background: var(--wh3-out-soft); color: var(--wh3-out-ink); }
.wh3-pill.st-critical { background: var(--wh3-crit-soft); color: var(--wh3-crit-ink); }
.wh3-pill.st-low { background: var(--wh3-low-soft); color: var(--wh3-low-ink); }
.wh3-pill.st-ok { background: var(--wh3-ok-soft); color: var(--wh3-ok-ink); }
.wh3-pill.st-frozen { background: var(--wh3-frozen-soft); color: var(--wh3-frozen-ink); }
.wh3-pill.st-gone { background: var(--wh3-soft-2); color: var(--wh3-mute); }

.wh3-empty {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 56px 24px;
  color: var(--wh3-mute);
  text-align: center;
}

.wh3-empty strong {
  color: var(--wh3-ink);
  font-size: 16px;
}

.wh3-error strong {
  color: var(--wh3-out-ink);
}

.wh3-mini-empty {
  padding: 18px 4px;
  color: var(--wh3-faint);
  font-size: 13px;
  list-style: none;
}

.wh3-note {
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
}

.wh3-note.ok { background: var(--wh3-ok-soft); color: var(--wh3-ok-ink); }
.wh3-note.bad { background: var(--wh3-out-soft); color: var(--wh3-out-ink); }

/* miniatury: zdjecie nad grafika zastepcza (po bledzie img znika) */
.wh3-thumb {
  position: relative;
  display: block;
  flex: 0 0 auto;
  overflow: hidden;
  background: var(--wh3-soft-2);
}

.wh3-thumb img {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #fff;
}

.wh3-thumb-sm { width: 38px; height: 38px; border-radius: 10px; }
.wh3-thumb-md { width: 50px; height: 50px; border-radius: 12px; }
.wh3-thumb-lg { width: 100%; height: 100%; border-radius: 0; }
.wh3-thumb-xl { width: 88px; height: 88px; border-radius: 18px; }

.wh3-art {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #eef2f7, #dde3ec);
}

.wh3-art b {
  font-size: 22px;
  line-height: 1;
  filter: saturate(0.9);
}

.wh3-thumb-sm .wh3-art b { font-size: 17px; }
.wh3-thumb-lg .wh3-art b { font-size: 54px; }
.wh3-thumb-xl .wh3-art b { font-size: 38px; }

.wh3-art-bokserki { background: linear-gradient(135deg, #e7ecff, #cdd6ff); }
.wh3-art-skarpety { background: linear-gradient(135deg, #e3f8ea, #c3efd3); }
.wh3-art-stopki { background: linear-gradient(135deg, #fdeaf4, #f9cfe4); }
.wh3-art-boxy { background: linear-gradient(135deg, #fff4d6, #fde3a4); }
.wh3-art-inne { background: linear-gradient(135deg, #eef1f6, #d9dfe9); }
.wh3-art-outlet { background: linear-gradient(135deg, #ffe8ec, #ffcdd6); }
.wh3-art-nieprzypisane { background: linear-gradient(135deg, #f1f3f7, #e2e6ee); }

html[data-flow-oms-theme="dark"] .wh3-art { background: linear-gradient(135deg, #1b2333, #232e42); }
html[data-flow-oms-theme="dark"] .wh3-art-bokserki { background: linear-gradient(135deg, #1d2445, #283466); }
html[data-flow-oms-theme="dark"] .wh3-art-skarpety { background: linear-gradient(135deg, #15302a, #1c4136); }
html[data-flow-oms-theme="dark"] .wh3-art-stopki { background: linear-gradient(135deg, #34192b, #472239); }
html[data-flow-oms-theme="dark"] .wh3-art-boxy { background: linear-gradient(135deg, #352a13, #4a3a17); }
html[data-flow-oms-theme="dark"] .wh3-art-outlet { background: linear-gradient(135deg, #3a1a22, #4f222d); }
html[data-flow-oms-theme="dark"] .wh3-swatch { border-color: #111827; }

.wh3-swatch {
  position: absolute;
  right: 5px;
  bottom: 5px;
  width: 11px;
  height: 11px;
  border: 2px solid #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.25);
}

.wh3-swatch.rainbow {
  background: conic-gradient(#ef4444, #f59e0b, #eab308, #22c55e, #06b6d4, #3b82f6, #a855f7, #ef4444);
}

.wh3-thumb-sm .wh3-swatch { width: 9px; height: 9px; right: 3px; bottom: 3px; border-width: 1.5px; }
.wh3-thumb-lg .wh3-swatch,
.wh3-thumb-xl .wh3-swatch { width: 16px; height: 16px; right: 10px; bottom: 10px; }

/* regaly jako chip */
.wh3-rack {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 8px;
  border: 1px solid var(--wh3-rack-line);
  border-radius: 7px;
  background: var(--wh3-rack-bg);
  color: var(--wh3-rack-ink);
  font-family: var(--wh3-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.wh3-rack + .wh3-rack {
  margin-left: 4px;
}

.wh3-rack-none {
  border-style: dashed;
  border-color: var(--wh3-line);
  background: transparent;
  color: var(--wh3-faint);
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0;
}

.wh3-rack-more {
  background: transparent;
}

/* pasek rozmiarow */
.wh3-sizes {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  min-width: 0;
}

.wh3-size {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  height: 26px;
  padding: 4px 7px 0;
  border: 1px solid var(--wh3-line);
  border-radius: 7px;
  background: var(--wh3-card);
  white-space: nowrap;
}

.wh3-size em {
  color: var(--wh3-mute);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 650;
}

.wh3-size b {
  color: var(--wh3-ink);
  font-size: 12.5px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}

.wh3-size.st-out { border-color: var(--wh3-out-line); background: var(--wh3-out-soft); }
.wh3-size.st-out em,
.wh3-size.st-out b { color: var(--wh3-out-ink); }
.wh3-size.st-critical { border-color: var(--wh3-crit-line); background: var(--wh3-crit-soft); }
.wh3-size.st-critical b { color: var(--wh3-crit-ink); }
.wh3-size.st-low { border-color: var(--wh3-low-line); background: var(--wh3-low-soft); }
.wh3-size.st-low b { color: var(--wh3-low-ink); }
.wh3-size.st-frozen { border-color: var(--wh3-frozen-line); background: var(--wh3-frozen-soft); }
.wh3-size.st-frozen b { color: var(--wh3-frozen-ink); }
.wh3-size.st-gone { border-style: dashed; border-color: var(--wh3-out-line); background: transparent; }
.wh3-size.st-gone b { color: var(--wh3-out-ink); opacity: 0.7; }
.wh3-size.st-empty { background: var(--wh3-soft); }
.wh3-size.st-empty b { color: var(--wh3-faint); font-weight: 600; }
.wh3-size-more { border-style: dashed; background: transparent; }

/* sparkline, miernik zapasu, rynki */
.wh3-spark {
  display: block;
  overflow: visible;
}

.wh3-spark polyline {
  fill: none;
  stroke: var(--wh3-acc);
  stroke-width: 1.7;
  stroke-linejoin: round;
  stroke-linecap: round;
}

.wh3-spark .area {
  fill: rgba(var(--wh3-acc-rgb), 0.1);
  stroke: none;
}

.wh3-spark circle {
  fill: var(--wh3-acc);
}

.wh3-spark.flat line {
  stroke: var(--wh3-line);
  stroke-width: 1.5;
  stroke-dasharray: 3 3;
}

.wh3-meter {
  display: block;
  width: 100%;
  max-width: 130px;
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--wh3-line-2);
}

.wh3-meter i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--wh3-ok);
}

.wh3-meter.st-out i { background: var(--wh3-out); }
.wh3-meter.st-critical i { background: var(--wh3-crit); }
.wh3-meter.st-low i { background: var(--wh3-low); }
.wh3-meter.st-frozen i { background: repeating-linear-gradient(135deg, var(--wh3-frozen) 0 5px, transparent 5px 9px); opacity: 0.5; }
.wh3-meter.st-gone i { background: var(--wh3-faint); }

.wh3-meter-label {
  display: block;
  margin-top: 5px;
  color: var(--wh3-mute);
  font-size: 12px;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wh3-meter-label.st-out,
.wh3 small.st-out { color: var(--wh3-out-ink); }
.wh3-meter-label.st-critical,
.wh3 small.st-critical { color: var(--wh3-crit-ink); }
.wh3-meter-label.st-low,
.wh3 small.st-low { color: var(--wh3-low-ink); }
.wh3-meter-label.st-ok,
.wh3 small.st-ok { color: var(--wh3-ok-ink); }
.wh3-meter-label.st-frozen,
.wh3 small.st-frozen { color: var(--wh3-frozen-ink); }
.wh3-meter-label.st-gone,
.wh3 small.st-gone { color: var(--wh3-mute); }

.wh3-markets {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
}

.wh3-mk {
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 7px;
  border-radius: 6px;
  background: var(--wh3-soft-2);
  color: var(--wh3-ink-2);
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
  letter-spacing: 0.02em;
}

.wh3-mk-pl { background: #e0f7fb; color: #0e7490; }
.wh3-mk-cz { background: #fde7f3; color: #be185d; }
.wh3-mk-sk { background: #e3edff; color: #1d4ed8; }
.wh3-mk-lt { background: #ffedde; color: #c2410c; }
.wh3-mk-hu { background: #e3f8ea; color: #15803d; }
.wh3-mk-allegro { background: #fff3c4; color: #92400e; }

html[data-flow-oms-theme="dark"] .wh3-mk { filter: brightness(0.9); background: var(--wh3-soft-2); color: var(--wh3-ink-2); }

/* --- Przeglad ------------------------------------------------------------ */

.wh3-row {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(300px, 1fr);
  gap: 14px;
  align-items: start;
}

.wh3-row-even {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.wh3-racktile-top em {
  position: absolute;
  top: -6px;
  right: -6px;
  display: grid;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  place-items: center;
  border: 2px solid var(--wh3-card);
  border-radius: 999px;
  background: var(--wh3-out);
  color: #fff;
  font-size: 10.5px;
  font-style: normal;
  font-weight: 800;
}

.wh3-chart-kpi {
  display: grid;
  justify-items: end;
  text-align: right;
}

.wh3-chart-kpi strong {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.wh3-chart-kpi small {
  color: var(--wh3-mute);
  font-size: 12px;
}

.wh3-chart-kpi b.up { color: var(--wh3-ok-ink); }
.wh3-chart-kpi b.down { color: var(--wh3-out-ink); }

.wh3-bars {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  gap: 8px;
  align-items: end;
}

.wh3-bar {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.wh3-bar-track {
  position: relative;
  display: flex;
  align-items: flex-end;
  height: var(--h, 120px);
  border-bottom: 1px solid var(--wh3-line);
}

.wh3-bar-track i {
  position: relative;
  display: block;
  width: 100%;
  min-height: 0;
  border-radius: 6px 6px 2px 2px;
  background: rgba(var(--wh3-acc-rgb), 0.22);
  transition: background 0.15s;
}

.wh3-bar:hover .wh3-bar-track i {
  background: rgba(var(--wh3-acc-rgb), 0.42);
}

.wh3-bar.now .wh3-bar-track i {
  background: var(--wh3-acc);
}

.wh3-bar-track b {
  position: absolute;
  bottom: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  color: var(--wh3-ink-2);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.wh3-bar small {
  overflow: hidden;
  color: var(--wh3-faint);
  font-size: 10.5px;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.wh3-bars {
  padding-top: 20px;
}

.wh3-feed {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.wh3-feed-item {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--wh3-line-2);
}

.wh3-feed-item:last-child {
  border-bottom: 0;
}

.wh3-feed-dot {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 10px;
  background: var(--wh3-soft-2);
  color: var(--wh3-mute);
  font-weight: 900;
}

.wh3-feed-item.k-in .wh3-feed-dot { background: var(--wh3-ok-soft); color: var(--wh3-ok-ink); }
.wh3-feed-item.k-out .wh3-feed-dot { background: var(--wh3-out-soft); color: var(--wh3-out-ink); }

.wh3-feed-body {
  display: grid;
  min-width: 0;
}

.wh3-feed-body strong {
  font-size: 13.5px;
  font-weight: 650;
}

.wh3-feed-body strong small {
  color: var(--wh3-faint);
  font-family: var(--wh3-mono);
  font-size: 11px;
  font-weight: 600;
}

.wh3-feed-body > small {
  overflow: hidden;
  color: var(--wh3-mute);
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-feed-item time {
  color: var(--wh3-faint);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* --- Towar --------------------------------------------------------------- */
.wh3-stock,
.wh3-racks {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  min-width: 0;
}

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

.wh3-search {
  position: relative;
  display: flex;
  flex: 1 1 360px;
  align-items: center;
  min-width: 0;
}

.wh3-search svg {
  position: absolute;
  left: 14px;
  width: 18px;
  height: 18px;
  color: var(--wh3-faint);
  pointer-events: none;
}

.wh3-search input {
  width: 100%;
  height: 46px;
  padding: 0 16px 0 42px;
  border: 1px solid var(--wh3-line);
  border-radius: 13px;
  background: var(--wh3-card);
  color: var(--wh3-ink);
  font: inherit;
  font-size: 14.5px;
  box-shadow: var(--wh3-shadow);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  -webkit-appearance: none;
  appearance: none;
}

.wh3-search input::placeholder {
  color: var(--wh3-faint);
}

.wh3-search input:focus {
  border-color: var(--wh3-acc);
  box-shadow: 0 0 0 4px rgba(var(--wh3-acc-rgb), 0.14);
}

.wh3-search-big input {
  height: 52px;
  font-size: 15.5px;
}

.wh3-select {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 46px;
  padding: 0 6px 0 14px;
  border: 1px solid var(--wh3-line);
  border-radius: 13px;
  background: var(--wh3-card);
  box-shadow: var(--wh3-shadow);
}

.wh3-select span {
  color: var(--wh3-mute);
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
}

.wh3-select select {
  height: 36px;
  padding: 0 28px 0 8px;
  border: 0;
  border-radius: 9px;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 8px center;
  color: var(--wh3-ink);
  font: inherit;
  font-size: 13.5px;
  font-weight: 650;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

.wh3-viewtoggle {
  display: inline-flex;
  gap: 2px;
  height: 46px;
  padding: 4px;
  border: 1px solid var(--wh3-line);
  border-radius: 13px;
  background: var(--wh3-card);
  box-shadow: var(--wh3-shadow);
}

.wh3-viewtoggle button {
  display: grid;
  width: 40px;
  place-items: center;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--wh3-mute);
  cursor: pointer;
}

.wh3-viewtoggle button svg {
  width: 18px;
  height: 18px;
}

.wh3-viewtoggle button.active {
  background: var(--wh3-soft-2);
  color: var(--wh3-ink);
}

.wh3-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
}

.wh3-chips + .wh3-chips {
  margin-top: 9px;
}

.wh3-chips button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 34px;
  padding: 0 12px;
  border: 1px solid var(--wh3-line);
  border-radius: 999px;
  background: var(--wh3-card);
  color: var(--wh3-ink-2);
  font-size: 13px;
  font-weight: 650;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.wh3-chips button:hover {
  border-color: var(--wh3-faint);
  color: var(--wh3-ink);
}

.wh3-chips button i {
  font-style: normal;
}

.wh3-chips button span {
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--wh3-soft-2);
  color: var(--wh3-mute);
  font-size: 11.5px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}

.wh3-chips button.active {
  border-color: var(--wh3-nav-active);
  background: var(--wh3-nav-active);
  color: var(--wh3-nav-active-ink);
}

.wh3-chips button.active span {
  background: rgba(255, 255, 255, 0.18);
  color: inherit;
}

html[data-flow-oms-theme="dark"] .wh3-chips button.active span {
  background: rgba(15, 23, 42, 0.14);
}

.wh3-chips-status button .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--wh3-faint);
}

.wh3-chips-status .tone-out .dot { background: var(--wh3-out); }
.wh3-chips-status .tone-critical .dot { background: var(--wh3-crit); }
.wh3-chips-status .tone-low .dot { background: var(--wh3-low); }
.wh3-chips-status .tone-frozen .dot { background: var(--wh3-frozen); }
.wh3-chips-status .tone-gone .dot { background: var(--wh3-faint); }
.wh3-chips-status .tone-out span { background: var(--wh3-out-soft); color: var(--wh3-out-ink); }
.wh3-chips-status .tone-critical span { background: var(--wh3-crit-soft); color: var(--wh3-crit-ink); }
.wh3-chips-status .tone-issue,
.wh3-chips-status .tone-norack { border-style: dashed; }

.wh3-toggle {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
  color: var(--wh3-mute);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
}

.wh3-toggle input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--wh3-acc);
}

.wh3-results-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 2px 2px 10px;
  color: var(--wh3-mute);
  font-size: 13px;
}

.wh3-results-head strong {
  color: var(--wh3-ink);
}

.wh3-thead,
.wh3-item {
  display: grid;
  grid-template-columns: 50px minmax(200px, 1.45fr) 92px minmax(200px, 2fr) 92px 128px 148px 14px;
  grid-template-areas: "thumb name rack sizes stock tempo days go";
  align-items: center;
  gap: 16px;
}

.wh3-thead {
  padding: 0 20px 8px;
  color: var(--wh3-faint);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.wh3-list {
  overflow: hidden;
  border: 1px solid var(--wh3-line);
  border-radius: 18px;
  background: var(--wh3-card);
  box-shadow: var(--wh3-shadow);
}

.wh3-item {
  position: relative;
  width: 100%;
  min-height: 72px;
  padding: 11px 20px;
  border: 0;
  border-bottom: 1px solid var(--wh3-line-2);
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s;
}

.wh3-item:last-child {
  border-bottom: 0;
}

.wh3-item:hover {
  background: var(--wh3-soft);
}

.wh3-item::before {
  content: "";
  position: absolute;
  top: 12px;
  bottom: 12px;
  left: 0;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: transparent;
}

.wh3-item.st-out::before { background: var(--wh3-out); }
.wh3-item.st-critical::before { background: var(--wh3-crit); }
.wh3-item.st-low::before { background: var(--wh3-low); }
.wh3-item.st-gone::before { background: var(--wh3-line); }
.wh3-item.st-empty { opacity: 0.6; }

.wh3-item > .wh3-thumb { grid-area: thumb; }
.wh3-item-name { grid-area: name; }
.wh3-item-rack { grid-area: rack; }
.wh3-item-sizes { grid-area: sizes; }
.wh3-item-stock { grid-area: stock; }
.wh3-item-tempo { grid-area: tempo; }
.wh3-item-days { grid-area: days; }
.wh3-item-go { grid-area: go; }

.wh3-item-name {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.wh3-item-name strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--wh3-ink);
  font-size: 14.5px;
  font-weight: 650;
  line-height: 1.3;
  letter-spacing: -0.01em;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.wh3-item-name small {
  overflow: hidden;
  color: var(--wh3-mute);
  font-size: 12.5px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-item-rack {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  min-width: 0;
}

.wh3-item-rack .wh3-rack + .wh3-rack {
  margin-left: 0;
}

.wh3-item-stock {
  display: grid;
  justify-items: end;
  text-align: right;
}

.wh3-item-stock strong {
  color: var(--wh3-ink);
  font-size: 17px;
  font-weight: 780;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.wh3-item-stock small {
  color: var(--wh3-mute);
  font-size: 12px;
  white-space: nowrap;
}

.wh3-item-tempo {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.wh3-item-tempo strong {
  color: var(--wh3-ink-2);
  font-size: 13.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.wh3-item-tempo strong small {
  color: var(--wh3-mute);
  font-size: 11.5px;
  font-weight: 600;
}

.wh3-item-tempo .muted {
  color: var(--wh3-faint);
  font-size: 12px;
}

.wh3-item-days {
  min-width: 0;
}

.wh3-item-go {
  color: var(--wh3-faint);
  font-size: 22px;
  line-height: 1;
}

.wh3-more {
  justify-self: center;
  margin-top: 14px;
  height: 42px;
  padding: 0 22px;
  border: 1px solid var(--wh3-line);
  border-radius: 12px;
  background: var(--wh3-card);
  color: var(--wh3-ink) !important;
  font-size: 13.5px !important;
  font-weight: 700 !important;
  cursor: pointer;
  box-shadow: var(--wh3-shadow);
}

.wh3-more:hover {
  border-color: var(--wh3-acc);
  color: var(--wh3-acc) !important;
}

[data-wh3-region="results"],
[data-wh3-region="chips"] {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  min-width: 0;
}

/* kafelki */
.wh3-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 14px;
}

.wh3-tile {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--wh3-line);
  border-radius: 18px;
  background: var(--wh3-card);
  text-align: left;
  cursor: pointer;
  box-shadow: var(--wh3-shadow);
  transition: transform 0.15s, box-shadow 0.15s;
}

.wh3-tile:hover {
  transform: translateY(-2px);
  box-shadow: var(--wh3-shadow-hover);
}

.wh3-tile-img {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  background: var(--wh3-soft-2);
}

.wh3-tile-img > .wh3-thumb {
  position: absolute;
  inset: 0;
}

.wh3-tile-rack {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  display: flex;
  gap: 4px;
}

.wh3-tile-rack .wh3-rack {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.wh3-tile-img > .wh3-pill {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.12);
}

.wh3-tile-img > .wh3-pill:not([class*="st-"]),
.wh3-tile-img > .wh3-pill.st-ok,
.wh3-tile-img > .wh3-pill.st-empty {
  background: rgba(255, 255, 255, 0.92);
  color: var(--wh3-ink-2);
}

.wh3-tile-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 9px;
  padding: 12px 14px 14px;
}

.wh3-tile-body > strong {
  display: -webkit-box;
  min-height: 2.6em;
  overflow: hidden;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.3;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.wh3-tile-foot {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 8px;
  border-top: 1px solid var(--wh3-line-2);
}

.wh3-tile-foot b {
  font-size: 15px;
  font-weight: 780;
  font-variant-numeric: tabular-nums;
}

.wh3-tile-foot small {
  color: var(--wh3-mute);
  font-size: 12px;
}

/* --- Regaly -------------------------------------------------------------- */
.wh3-racks .wh3-toolbar .wh3-fresh {
  margin-left: auto;
}

.wh3-racks-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(340px, 1fr);
  gap: 20px;
  align-items: start;
}

.wh3-racks-board {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(164px, 1fr));
  gap: 12px;
  align-content: start;
  min-width: 0;
}

.wh3-racktile {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 124px;
  padding: 12px 14px;
  border: 1px solid var(--wh3-line);
  border-radius: 16px;
  background:
    linear-gradient(rgba(var(--wh3-acc-rgb), calc(var(--heat, 0.2) * 0.2)), rgba(var(--wh3-acc-rgb), calc(var(--heat, 0.2) * 0.2))),
    var(--wh3-card);
  text-align: left;
  cursor: pointer;
  box-shadow: var(--wh3-shadow);
  transition: transform 0.15s, box-shadow 0.15s, opacity 0.2s, border-color 0.15s;
}

.wh3-racktile:hover {
  transform: translateY(-2px);
  box-shadow: var(--wh3-shadow-hover);
}

.wh3-racktile.active {
  border-color: var(--wh3-acc);
  box-shadow: 0 0 0 3px rgba(var(--wh3-acc-rgb), 0.2), var(--wh3-shadow-hover);
}

.wh3-racktile.dim {
  opacity: 0.32;
}

.wh3-racktile.hit {
  border-color: var(--wh3-ok);
  box-shadow: 0 0 0 3px var(--wh3-ok-soft), var(--wh3-shadow-hover);
}

.wh3-racktile.none {
  border-style: dashed;
  background: transparent;
  box-shadow: none;
}

.wh3-racktile-top {
  display: flex;
  align-items: center;
  gap: 8px;
}

.wh3-racktile-top strong {
  color: var(--wh3-ink);
  font-family: var(--wh3-mono);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.wh3-racktile.none .wh3-racktile-top strong {
  font-family: inherit;
  font-size: 16px;
}

.wh3-hitcount {
  margin-left: auto;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--wh3-ok);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
}

.wh3-racktile-what {
  display: -webkit-box;
  flex: 1;
  overflow: hidden;
  color: var(--wh3-ink-2);
  font-size: 12px;
  line-height: 1.35;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.wh3-racktile-foot {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px;
  white-space: nowrap;
}

.wh3-racktile-foot b {
  font-size: 13px;
  font-weight: 780;
  font-variant-numeric: tabular-nums;
}

.wh3-racktile-foot small {
  color: var(--wh3-mute);
  font-size: 11.5px;
}

.wh3-racks-panel {
  position: sticky;
  top: 12px;
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 160px);
  padding: 0;
  overflow: hidden;
}

.wh3-panel-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--wh3-line-2);
}

.wh3-panel-head h3 {
  margin: 2px 0 0;
  font-family: var(--wh3-mono);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.wh3-panel-head h3.plain {
  font-family: inherit;
  font-size: 20px;
}

.wh3-panel-head > span {
  color: var(--wh3-mute);
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
}

.wh3-panel-hint {
  margin: 12px 20px 0;
  color: var(--wh3-mute);
  font-size: 12.5px;
  line-height: 1.45;
}

.wh3-panel-list {
  display: grid;
  align-content: start;
  padding: 6px 12px 14px;
  overflow-y: auto;
}

.wh3-panel-intro {
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 64px 28px;
  color: var(--wh3-mute);
  font-size: 13.5px;
  text-align: center;
}

.wh3-panel-intro strong {
  color: var(--wh3-ink);
  font-size: 16px;
}

.wh3-rackitem {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 9px 8px;
  border: 0;
  border-bottom: 1px solid var(--wh3-line-2);
  border-radius: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.wh3-rackitem:hover {
  border-radius: 10px;
  background: var(--wh3-soft);
}

.wh3-rackitem-name {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.wh3-rackitem-name strong {
  overflow: hidden;
  font-size: 13.5px;
  font-weight: 650;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-rackitem-name .wh3-size {
  height: 22px;
  padding: 2px 6px 0;
}

.wh3-rackitem-right {
  display: grid;
  justify-items: end;
  gap: 2px;
}

.wh3-rackitem-right b {
  font-size: 15px;
  font-weight: 780;
  font-variant-numeric: tabular-nums;
}

.wh3-rackitem-right small {
  color: var(--wh3-mute);
  font-size: 11px;
}

/* --- szuflada produktu --------------------------------------------------- */
.wh3-drawer-root {
  position: fixed;
  inset: 0;
  z-index: 110;
}

.wh3-drawer-root[hidden] {
  display: none;
}

.wh3-drawer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.34);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  animation: wh3-fade 0.18s ease-out;
}

.wh3-drawer {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  width: min(580px, 100vw);
  background: var(--wh3-card);
  box-shadow: -24px 0 60px rgba(15, 23, 42, 0.2);
  animation: wh3-slide 0.24s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes wh3-slide {
  from { transform: translateX(32px); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@keyframes wh3-fade {
  from { opacity: 0; }
}

.wh3-drawer-head {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) 36px;
  align-items: start;
  gap: 16px;
  padding: 22px 22px 18px 24px;
  border-bottom: 1px solid var(--wh3-line-2);
}

.wh3-drawer-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  min-width: 0;
}

.wh3-drawer-title .wh3-eyebrow {
  width: 100%;
}

.wh3-drawer-title h2 {
  width: 100%;
  margin: 0 0 2px;
  color: var(--wh3-ink);
  font-size: 20px;
  font-weight: 780;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.wh3-drawer-close {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid var(--wh3-line);
  border-radius: 10px;
  background: var(--wh3-card);
  color: var(--wh3-mute) !important;
  font-size: 22px !important;
  line-height: 1;
  cursor: pointer;
}

.wh3-drawer-close:hover {
  background: var(--wh3-soft-2);
  color: var(--wh3-ink) !important;
}

.wh3-drawer-body {
  display: grid;
  flex: 1;
  align-content: start;
  gap: 18px;
  padding: 18px 24px 28px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.wh3-where {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--wh3-rack-line);
  border-radius: 14px;
  background: var(--wh3-rack-bg);
}

.wh3-where-icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 12px;
  background: var(--wh3-card);
  color: var(--wh3-rack-ink);
}

.wh3-where-icon svg {
  width: 20px;
  height: 20px;
}

.wh3-where-body {
  display: grid;
  flex: 1;
  min-width: 140px;
}

.wh3-where-body small {
  color: var(--wh3-rack-ink);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  opacity: 0.8;
}

.wh3-where-body strong {
  color: var(--wh3-ink);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.wh3-loc-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: -8px;
}

.wh3-loc-form input {
  width: 140px;
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--wh3-acc);
  border-radius: 10px;
  background: var(--wh3-card);
  color: var(--wh3-ink);
  font-family: var(--wh3-mono);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  box-shadow: 0 0 0 4px rgba(var(--wh3-acc-rgb), 0.12);
  outline: none;
}

.wh3-loc-form small {
  width: 100%;
  color: var(--wh3-mute);
  font-size: 12px;
}

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

.wh3-stats > div {
  display: grid;
  gap: 2px;
  padding: 12px 12px 11px;
  border-radius: 12px;
  background: var(--wh3-soft);
}

.wh3-stats em {
  color: var(--wh3-mute);
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.wh3-stats strong {
  color: var(--wh3-ink);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.wh3-stats small {
  overflow: hidden;
  color: var(--wh3-mute);
  font-size: 11.5px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-stats > .st-out { background: var(--wh3-out-soft); }
.wh3-stats > .st-out strong { color: var(--wh3-out-ink); }
.wh3-stats > .st-critical { background: var(--wh3-crit-soft); }
.wh3-stats > .st-critical strong { color: var(--wh3-crit-ink); }
.wh3-stats > .st-low { background: var(--wh3-low-soft); }
.wh3-stats > .st-low strong { color: var(--wh3-low-ink); }
.wh3-stats > .st-ok { background: var(--wh3-ok-soft); }
.wh3-stats > .st-ok strong { color: var(--wh3-ok-ink); }
.wh3-stats > .st-frozen { background: var(--wh3-frozen-soft); }
.wh3-stats > .st-frozen strong { color: var(--wh3-frozen-ink); }

.wh3-dsec {
  display: grid;
  gap: 10px;
}

.wh3-dsec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.wh3-dsec-head span {
  color: var(--wh3-mute);
  font-size: 12.5px;
}

.wh3-dsec-head b {
  color: var(--wh3-ink);
}

.wh3-vhead,
.wh3-vrow {
  display: grid;
  grid-template-columns: minmax(96px, 1.4fr) 58px 50px 58px 54px 104px;
  align-items: center;
  gap: 10px;
}

.wh3-vhead {
  padding: 0 10px;
  color: var(--wh3-faint);
  font-size: 10.5px;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.wh3-vhead span:nth-child(n+2):nth-child(-n+5) {
  text-align: right;
}

.wh3-vlist {
  overflow: hidden;
  border: 1px solid var(--wh3-line);
  border-radius: 14px;
}

.wh3-vrow {
  width: 100%;
  min-height: 48px;
  padding: 7px 10px;
  border: 0;
  border-bottom: 1px solid var(--wh3-line-2);
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.wh3-vrow:last-child {
  border-bottom: 0;
}

.wh3-vrow:hover {
  background: var(--wh3-acc-soft);
}

.wh3-vrow-name {
  display: grid;
  min-width: 0;
}

.wh3-vrow-name strong {
  overflow: hidden;
  font-size: 13.5px;
  font-weight: 750;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-vrow-name small {
  overflow: hidden;
  color: var(--wh3-faint);
  font-family: var(--wh3-mono);
  font-size: 10.5px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-vrow .num {
  color: var(--wh3-ink-2);
  font-size: 13.5px;
  font-weight: 600;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.wh3-vrow .num.strong {
  color: var(--wh3-ink);
  font-weight: 800;
}

.wh3-vrow .num.muted {
  color: var(--wh3-faint);
}

.wh3-vrow.st-out .num.strong { color: var(--wh3-out-ink); }
.wh3-vrow.st-out { background: var(--wh3-out-soft); }
.wh3-vrow.st-critical .num.strong { color: var(--wh3-crit-ink); }
.wh3-vrow.st-empty { opacity: 0.55; }

.wh3-vrow-days {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.wh3-vrow-days small {
  color: var(--wh3-mute);
  font-size: 11.5px;
  font-weight: 650;
  white-space: nowrap;
}

.wh3-dhint {
  color: var(--wh3-faint);
  font-size: 12px;
}

.wh3-facts {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--wh3-soft);
}

.wh3-facts > div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.wh3-facts small {
  color: var(--wh3-mute);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.wh3-facts strong {
  color: var(--wh3-ink);
  font-size: 14px;
  font-weight: 700;
}

.wh3-drawer-foot {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  padding: 14px 24px;
  border-top: 1px solid var(--wh3-line);
  background: var(--wh3-card);
}

.wh3-drawer-foot .wh3-btn.primary {
  margin-right: auto;
}

/* --- szkielet ladowania -------------------------------------------------- */
.wh3-skeleton {
  display: grid;
  gap: 14px;
}

.wh3-sk {
  border-radius: 16px;
  background: linear-gradient(90deg, var(--wh3-soft-2) 0%, var(--wh3-line-2) 40%, var(--wh3-soft-2) 80%);
  background-size: 200% 100%;
  animation: wh3-shimmer 1.2s linear infinite;
}

.wh3-sk-hero { height: 128px; border-radius: 22px; }
.wh3-sk-bar { height: 46px; }
.wh3-sk-card { height: 260px; }
.wh3-sk-row { height: 72px; }

.wh3-sk-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

@keyframes wh3-shimmer {
  to { background-position: -200% 0; }
}

@media (prefers-reduced-motion: reduce) {
  .wh3 *,
  .wh3-drawer,
  .wh3-drawer-backdrop {
    animation: none !important;
    transition: none !important;
  }

}

/* --- responsywnosc ------------------------------------------------------- */
@media (max-width: 1480px) {
  .wh3-thead,
  .wh3-item {
    grid-template-columns: 50px minmax(180px, 1.35fr) 80px minmax(180px, 1.8fr) 86px 112px 132px 12px;
    gap: 14px;
  }

}

@media (max-width: 1180px) {
  .wh3-thead {
    display: none;
  }

  .wh3-item {
    grid-template-columns: 50px minmax(0, 1fr) auto 96px 128px;
    grid-template-areas:
      "thumb name rack stock days"
      "thumb sizes sizes sizes sizes";
    row-gap: 8px;
  }

  .wh3-item-tempo,
  .wh3-item-go {
    display: none;
  }

  .wh3-row,
  .wh3-row-even {
    grid-template-columns: 1fr;
  }

  .wh3-racks-layout {
    grid-template-columns: 1fr;
  }

  .wh3-racks-panel {
    position: static;
    max-height: none;
  }

}

@media (max-width: 760px) {
  .wh3-sk-grid {
    grid-template-columns: 1fr;
  }

  .wh3-item {
    grid-template-columns: 44px minmax(0, 1fr) auto;
    grid-template-areas:
      "thumb name stock"
      "sizes sizes sizes"
      "rack days days";
    gap: 8px 12px;
    padding: 12px 14px;
  }

  .wh3-item > .wh3-thumb {
    width: 44px;
    height: 44px;
  }

  .wh3-select span {
    display: none;
  }

  /* chipy w jednym przewijanym rzedzie zamiast siedmiu linii */
  .wh3-chips {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .wh3-chips::-webkit-scrollbar {
    display: none;
  }

  .wh3-chips button,
  .wh3-toggle {
    flex: 0 0 auto;
  }

  .wh3-toggle {
    margin-left: 0;
  }

  .wh3-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .wh3-drawer-head {
    grid-template-columns: 64px minmax(0, 1fr) 36px;
    padding: 16px;
  }

  .wh3-drawer-head .wh3-thumb-xl {
    width: 64px;
    height: 64px;
    border-radius: 14px;
  }

  .wh3-drawer-body {
    padding: 16px;
  }

  .wh3-vhead,
  .wh3-vrow {
    grid-template-columns: minmax(80px, 1fr) 50px 58px 86px;
  }

  .wh3-vhead span:nth-child(3),
  .wh3-vhead span:nth-child(5),
  .wh3-vrow > .num:nth-child(3),
  .wh3-vrow > .num:nth-child(5) {
    display: none;
  }

  .wh3-facts {
    grid-template-columns: 1fr;
  }

}

html[data-flow-oms-theme="dark"] .wh3-btn.primary {
  color: #0b1120 !important;
}

html[data-flow-oms-theme="dark"] .wh3-tile-rack .wh3-rack,
html[data-flow-oms-theme="dark"] .wh3-tile-img > .wh3-pill {
  background: rgba(15, 23, 42, 0.86);
}

html[data-flow-oms-theme="dark"] .wh3-tile-img > .wh3-pill.st-ok,
html[data-flow-oms-theme="dark"] .wh3-tile-img > .wh3-pill.st-empty {
  background: rgba(15, 23, 42, 0.86);
  color: var(--wh3-ink-2);
}

/* --- Magazyn 3.0 v2: zdjecia, wyszukiwarka, kafle, polki ------------------ */
.wh3-thumb-xxs { width: 22px; height: 22px; border-radius: 50%; }
.wh3-thumb-xs { width: 32px; height: 32px; border-radius: 50%; }
.wh3-thumb-hero { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 0; background: transparent; }
.wh3-thumb-hero img { object-fit: contain; background: transparent; }
.wh3-thumb-xxs .wh3-art b { font-size: 11px; }
.wh3-thumb-xs .wh3-art b { font-size: 14px; }
.wh3-thumb-hero .wh3-art b { font-size: 72px; }
.wh3-thumb-xxs .wh3-swatch,
.wh3-thumb-xs .wh3-swatch { display: none; }

.wh3-chips button > .wh3-thumb-xxs {
  margin-left: -6px;
  box-shadow: 0 0 0 2px var(--wh3-card);
}

.wh3-chips button.active > .wh3-thumb-xxs {
  box-shadow: 0 0 0 2px var(--wh3-nav-active);
}

/* stos zdjec */
.wh3-stack {
  display: inline-flex;
  align-items: center;
  padding-left: 8px;
}

.wh3-stack > .wh3-thumb {
  margin-left: -9px;
  border: 2px solid var(--wh3-card);
  box-sizing: content-box;
  background: var(--wh3-soft-2);
}

.wh3-stack-more {
  display: grid;
  min-width: 32px;
  height: 32px;
  margin-left: -9px;
  padding: 0 6px;
  place-items: center;
  border: 2px solid var(--wh3-card);
  border-radius: 999px;
  background: var(--wh3-soft-2);
  color: var(--wh3-ink-2);
  font-size: 11.5px;
  font-weight: 800;
  box-sizing: content-box;
}

/* hero Przegladu */
.wh3-hero2 {
  /* nad kaflami: podpowiedzi wyszukiwarki wychodza poza karte */
  position: relative;
  z-index: 5;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 1fr);
  gap: 28px;
  align-items: center;
  padding: 26px 28px;
  border: 1px solid var(--wh3-line);
  border-radius: 24px;
  background:
    radial-gradient(90% 140% at 0% 0%, rgba(var(--wh3-acc-rgb), 0.1), transparent 60%),
    radial-gradient(70% 120% at 100% 100%, rgba(124, 58, 237, 0.06), transparent 60%),
    var(--wh3-card);
  box-shadow: var(--wh3-shadow);
}

.wh3-hero2-main {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.wh3-hero2-main h2 {
  margin: 0 0 6px;
  color: var(--wh3-ink);
  font-size: 30px;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.035em;
}

.wh3-hero2-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.wh3-hero2-stats > div {
  display: grid;
  gap: 2px;
  padding: 14px 16px;
  border-radius: 16px;
  background: var(--wh3-soft);
}

.wh3-hero2-stats em {
  color: var(--wh3-mute);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.wh3-hero2-stats strong {
  color: var(--wh3-ink);
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.wh3-hero2-stats small {
  overflow: hidden;
  color: var(--wh3-mute);
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* wyszukiwarka "gdzie lezy" */
.wh3-spot {
  position: relative;
  z-index: 20;
}

.wh3-spot-box {
  position: relative;
  display: flex;
  align-items: center;
}

.wh3-spot-box > svg {
  position: absolute;
  left: 18px;
  color: var(--wh3-acc);
  pointer-events: none;
}

.wh3-spot-box input {
  width: 100%;
  height: 58px;
  padding: 0 64px 0 52px;
  border: 1.5px solid var(--wh3-line);
  border-radius: 18px;
  background: var(--wh3-card);
  color: var(--wh3-ink);
  font: inherit;
  font-size: 16.5px;
  font-weight: 500;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 10px 30px rgba(var(--wh3-acc-rgb), 0.08);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  -webkit-appearance: none;
  appearance: none;
}

.wh3-spot-box input::placeholder { color: var(--wh3-faint); }

.wh3-spot-box input:focus {
  border-color: var(--wh3-acc);
  box-shadow: 0 0 0 5px rgba(var(--wh3-acc-rgb), 0.14), 0 10px 30px rgba(var(--wh3-acc-rgb), 0.12);
}

.wh3-spot-box kbd {
  position: absolute;
  right: 16px;
  display: grid;
  min-width: 26px;
  height: 26px;
  place-items: center;
  border: 1px solid var(--wh3-line);
  border-radius: 8px;
  background: var(--wh3-soft);
  color: var(--wh3-mute);
  font-family: var(--wh3-mono);
  font-size: 12px;
  font-weight: 700;
}

.wh3-spot-results {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  display: grid;
  max-height: min(520px, 70vh);
  padding: 8px;
  overflow-y: auto;
  border: 1px solid var(--wh3-line);
  border-radius: 18px;
  background: var(--wh3-card);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
  animation: wh3-pop 0.14s ease-out;
}

.wh3-spot-results[hidden] { display: none; }

@keyframes wh3-pop {
  from { opacity: 0; transform: translateY(-4px); }
}

.wh3-spot-row {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.wh3-spot-row:hover,
.wh3-spot-row.active {
  background: var(--wh3-acc-soft);
}

.wh3-spot-name {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.wh3-spot-name strong {
  overflow: hidden;
  font-size: 14.5px;
  font-weight: 650;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-spot-name .wh3-size {
  height: 22px;
  padding: 2px 6px 0;
}

.wh3-spot-where {
  display: grid;
  justify-items: end;
  gap: 4px;
}

.wh3-spot-where .wh3-rack {
  height: 28px;
  padding: 0 10px;
  font-size: 14px;
}

.wh3-spot-where small {
  color: var(--wh3-mute);
  font-size: 12px;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

.wh3-spot-empty {
  padding: 18px;
  color: var(--wh3-mute);
  font-size: 13.5px;
}

.wh3-spot-all {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 6px;
  margin: 4px 10px 6px;
  padding: 6px 0;
  border: 0;
  background: transparent;
  color: var(--wh3-acc) !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  cursor: pointer;
}

/* kafle "co wymaga uwagi" */
.wh3-tiles2 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.wh3-tile2 {
  --tone: var(--wh3-acc);
  --tone-soft: var(--wh3-acc-soft);
  position: relative;
  display: grid;
  gap: 10px;
  padding: 16px 18px 16px;
  border: 1.5px solid var(--wh3-line);
  border-radius: 20px;
  background: var(--wh3-card);
  text-align: left;
  cursor: pointer;
  box-shadow: var(--wh3-shadow);
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s, background 0.15s;
}

.wh3-tile2.st-out { --tone: var(--wh3-out); --tone-soft: var(--wh3-out-soft); }
.wh3-tile2.st-critical { --tone: var(--wh3-crit); --tone-soft: var(--wh3-crit-soft); }
.wh3-tile2.st-frozen { --tone: var(--wh3-frozen); --tone-soft: var(--wh3-frozen-soft); }
.wh3-tile2.st-norack { --tone: var(--wh3-issue); --tone-soft: var(--wh3-issue-soft); }

.wh3-tile2:hover {
  transform: translateY(-2px);
  box-shadow: var(--wh3-shadow-hover);
}

.wh3-tile2.active {
  border-color: var(--tone);
  background: linear-gradient(180deg, var(--tone-soft), var(--wh3-card) 70%);
  box-shadow: 0 0 0 3px var(--tone-soft), var(--wh3-shadow-hover);
}

.wh3-tile2-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wh3-tile2-icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 13px;
  background: var(--tone-soft);
  color: var(--tone);
}

.wh3-tile2-top strong {
  color: var(--tone);
  font-size: 34px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}

.wh3-tile2-title {
  color: var(--wh3-ink);
  font-size: 15px;
  font-weight: 750;
  letter-spacing: -0.015em;
}

.wh3-tile2-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 36px;
}

.wh3-tile2-foot small {
  color: var(--wh3-mute);
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.wh3-tile2.active::after {
  content: "";
  position: absolute;
  bottom: -9px;
  left: 50%;
  width: 14px;
  height: 14px;
  border-right: 1.5px solid var(--tone);
  border-bottom: 1.5px solid var(--tone);
  background: var(--wh3-card);
  transform: translateX(-50%) rotate(45deg);
}

/* lista do zrobienia */
.wh3-todo-list {
  display: grid;
}

.wh3-todo-row {
  display: grid;
  grid-template-columns: 50px minmax(160px, 1.3fr) minmax(0, 1.4fr) auto 118px;
  align-items: center;
  gap: 14px;
  width: calc(100% + 16px);
  margin: 0 -8px;
  padding: 9px 8px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s;
}

.wh3-todo-row:hover {
  background: var(--wh3-soft);
}

.wh3-todo-row + .wh3-todo-row {
  box-shadow: 0 -1px 0 var(--wh3-line-2);
}

.wh3-todo-name {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.wh3-todo-name strong {
  overflow: hidden;
  font-size: 14.5px;
  font-weight: 650;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-todo-name em {
  overflow: hidden;
  color: var(--wh3-mute);
  font-size: 12.5px;
  font-style: normal;
  font-weight: 650;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-todo-name em.st-out { color: var(--wh3-out-ink); }
.wh3-todo-name em.st-critical { color: var(--wh3-crit-ink); }
.wh3-todo-name em.st-frozen { color: var(--wh3-frozen-ink); }

.wh3-todo-sizes {
  min-width: 0;
  overflow: hidden;
}

.wh3-todo-sizes .wh3-sizes {
  flex-wrap: nowrap;
}

.wh3-todo-right {
  display: grid;
  justify-items: end;
  text-align: right;
}

.wh3-todo-right b {
  color: var(--wh3-ink);
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.wh3-todo-right b.st-critical { color: var(--wh3-crit-ink); }

.wh3-todo-right small {
  color: var(--wh3-mute);
  font-size: 11.5px;
  white-space: nowrap;
}

/* regaly na Przegladzie */
.wh3-rackmini2-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
  gap: 10px;
}

.wh3-rackmini2 {
  position: relative;
  display: grid;
  justify-items: start;
  gap: 8px;
  padding: 10px 12px 10px;
  border: 1px solid var(--wh3-line);
  border-radius: 14px;
  background: var(--wh3-soft);
  cursor: pointer;
  text-align: left;
  transition: transform 0.12s, box-shadow 0.15s, background 0.15s;
}

.wh3-rackmini2:hover {
  transform: translateY(-1px);
  background: var(--wh3-card);
  box-shadow: var(--wh3-shadow-hover);
}

.wh3-rackmini2-code {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--wh3-ink);
  font-family: var(--wh3-mono);
  font-size: 15px;
  font-weight: 800;
}

.wh3-rackmini2-code em {
  display: grid;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  place-items: center;
  border-radius: 999px;
  background: var(--wh3-out);
  color: #fff;
  font-family: Inter, sans-serif;
  font-size: 10.5px;
  font-style: normal;
  font-weight: 800;
}

.wh3-rackmini2 .wh3-stack {
  padding-left: 9px;
}

.wh3-rackmini2 small {
  color: var(--wh3-mute);
  font-size: 11.5px;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

/* najszybciej schodzi - karty ze zdjeciem */
.wh3-mover2-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.wh3-mover2 {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.wh3-mover2-img {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 16px;
  background: var(--wh3-soft-2);
  transition: transform 0.15s, box-shadow 0.15s;
}

.wh3-mover2:hover .wh3-mover2-img {
  transform: translateY(-2px);
  box-shadow: var(--wh3-shadow-hover);
}

.wh3-mover2-img > .wh3-thumb {
  position: absolute;
  inset: 0;
}

.wh3-mover2-img em {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border-radius: 9px;
  background: rgba(15, 23, 42, 0.82);
  color: #fff;
  font-size: 12.5px;
  font-style: normal;
  font-weight: 800;
}

.wh3-mover2 > strong {
  display: -webkit-box;
  min-height: 2.5em;
  overflow: hidden;
  font-size: 13.5px;
  font-weight: 650;
  line-height: 1.25;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.wh3-mover2-foot {
  display: flex;
  align-items: baseline;
  gap: 4px;
  min-width: 0;
}

.wh3-mover2-foot b {
  font-size: 15px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.wh3-mover2-foot small {
  color: var(--wh3-mute);
  font-size: 12px;
}

.wh3-mover2-foot .wh3-pill {
  margin-left: auto;
}

.wh3-hygiene {
  margin: 0;
  padding: 0 4px;
  color: var(--wh3-mute);
  font-size: 12.5px;
}

.wh3-hygiene button {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--wh3-acc) !important;
  font-size: 12.5px !important;
  font-weight: 650 !important;
  cursor: pointer;
}

.wh3-hygiene button:hover { text-decoration: underline; text-underline-offset: 3px; }

/* polka ze zdjeciami na kafelku regalu */
.wh3-racktile-shelf {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  min-height: 46px;
  padding: 0 2px 6px;
  border-bottom: 3px solid var(--wh3-line);
  border-radius: 0 0 3px 3px;
}

.wh3-racktile-shelf > .wh3-thumb {
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12);
}

.wh3-racktile-more {
  align-self: center;
  color: var(--wh3-mute);
  font-size: 12px;
  font-weight: 800;
}

.wh3-racktile.hit .wh3-racktile-shelf {
  border-bottom-color: var(--wh3-ok);
}

.wh3-racktile-what {
  -webkit-line-clamp: 2;
}

/* szuflada: duze zdjecie */
.wh3-drawer-hero {
  position: relative;
  flex: 0 0 auto;
  height: 250px;
  background:
    radial-gradient(80% 90% at 50% 40%, var(--wh3-card), var(--wh3-soft-2));
}

.wh3-drawer-hero-rack {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 12px;
  border-radius: 11px;
  background: var(--wh3-nav-active);
  color: var(--wh3-nav-active-ink);
  font-family: var(--wh3-mono);
  font-size: 15px;
  font-weight: 800;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.22);
}

.wh3-drawer-hero-note {
  position: absolute;
  bottom: 10px;
  left: 16px;
  z-index: 2;
  padding: 3px 8px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--wh3-mute);
  font-size: 11px;
  font-weight: 650;
}

html[data-flow-oms-theme="dark"] .wh3-drawer-hero-note {
  background: rgba(15, 23, 42, 0.8);
}

.wh3-drawer-hero .wh3-drawer-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

html[data-flow-oms-theme="dark"] .wh3-drawer-hero .wh3-drawer-close {
  background: rgba(15, 23, 42, 0.8);
}

.wh3-drawer-head {
  grid-template-columns: minmax(0, 1fr);
  padding: 18px 24px 14px;
}

.wh3-vrow-name {
  display: flex;
  align-items: center;
  gap: 9px;
}

.wh3-vrow-name > span {
  display: grid;
  min-width: 0;
}

/* legenda */
.wh3-legend {
  margin-top: 10px;
  color: var(--wh3-mute);
  font-size: 12.5px;
}

.wh3-legend summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: max-content;
  color: var(--wh3-acc);
  font-weight: 650;
  cursor: pointer;
  list-style: none;
}

.wh3-legend summary::-webkit-details-marker { display: none; }

.wh3-legend summary::before {
  content: "?";
  display: grid;
  width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 50%;
  background: var(--wh3-acc-soft);
  font-size: 11px;
  font-weight: 800;
}

.wh3-legend-body {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 8px 18px;
  margin-top: 10px;
  padding: 14px 16px;
  border: 1px solid var(--wh3-line);
  border-radius: 14px;
  background: var(--wh3-card);
}

.wh3-legend-body > span {
  display: flex;
  align-items: center;
  gap: 8px;
  line-height: 1.35;
}

.wh3-legend-body i.wh3-size {
  flex: 0 0 auto;
  font-style: normal;
}

.wh3-legend-body > span b { color: var(--wh3-ink); }

/* delikatne wejscie kart */
@media (prefers-reduced-motion: no-preference) {
  .wh3-tile2,
  .wh3-hero2,
  .wh3-todo,
  .wh3-movers2 {
    animation: wh3-rise 0.32s cubic-bezier(0.2, 0.8, 0.2, 1) both;
  }

  .wh3-tile2:nth-child(2) { animation-delay: 0.04s; }
  .wh3-tile2:nth-child(3) { animation-delay: 0.08s; }
  .wh3-tile2:nth-child(4) { animation-delay: 0.12s; }
}

@keyframes wh3-rise {
  from { opacity: 0; transform: translateY(8px); }
}

@media (max-width: 1480px) {
  .wh3-mover2-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .wh3-mover2-grid > .wh3-mover2:nth-child(n+4) { display: none; }
}

@media (max-width: 1280px) {
  .wh3-hero2 { grid-template-columns: 1fr; }
  .wh3-tiles2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .wh3-todo-row { grid-template-columns: 50px minmax(0, 1fr) auto 108px; }
  .wh3-todo-sizes { display: none; }
}

@media (max-width: 760px) {
  .wh3-hero2 { padding: 18px; }
  .wh3-hero2-main h2 { font-size: 23px; }
  .wh3-hero2-stats strong { font-size: 21px; }
  .wh3-tiles2 { grid-template-columns: 1fr 1fr; gap: 10px; }
  .wh3-tile2 { padding: 12px; }
  .wh3-tile2-top strong { font-size: 26px; }
  .wh3-tile2-foot small { display: none; }
  .wh3-tile2.active::after { display: none; }
  .wh3-todo-row { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .wh3-todo-rack { display: none; }
  .wh3-mover2-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .wh3-mover2-grid > .wh3-mover2:nth-child(n+3) { display: none; }
  .wh3-drawer-hero { height: 200px; }
  .wh3-spot-row { grid-template-columns: 44px minmax(0, 1fr) auto; gap: 10px; }
  .wh3-spot-box input { font-size: 15px; }
  .wh3-spot-box kbd { display: none; }
}

/* duze zdjecie w karcie: bez grafiki zastepczej po bokach (zdjecia sklepu maja biale tlo) */
.wh3-drawer-hero:has(img) {
  background: #ffffff;
}

.wh3-thumb-hero:has(img) .wh3-art {
  display: none;
}

.wh3-thumb-hero img {
  background: #ffffff;
}

/* --- spokojniej (29.09 23:30): mniej ramek i kolorow ---------------------- */
.wh3-tile2 {
  gap: 8px;
}

.wh3-tile2-foot {
  min-height: 0;
  color: var(--wh3-mute);
  font-size: 12.5px;
  line-height: 1.35;
}

.wh3-tile2-foot > span {
  min-width: 0;
}

.wh3-todo {
  padding: 20px 24px;
}

.wh3-todo-row {
  grid-template-columns: 48px minmax(0, 1fr) auto 150px;
  gap: 16px;
  padding: 10px 8px;
}

.wh3-todo-row .wh3-thumb-md {
  width: 48px;
  height: 48px;
}

/* rozmiary: bez ramek, kolor tylko przy problemie */
.wh3-size {
  border-color: transparent;
  background: var(--wh3-soft-2);
}

.wh3-size.st-out { border-color: transparent; background: var(--wh3-out-soft); }
.wh3-size.st-critical { border-color: transparent; background: var(--wh3-crit-soft); }
.wh3-size.st-low { border-color: transparent; background: var(--wh3-low-soft); }
.wh3-size.st-frozen { border-color: transparent; background: var(--wh3-frozen-soft); }
.wh3-size.st-gone { border-color: transparent; background: transparent; box-shadow: inset 0 0 0 1px var(--wh3-line); }
.wh3-size.st-empty { background: transparent; box-shadow: inset 0 0 0 1px var(--wh3-line-2); }

@media (max-width: 1280px) {
  .wh3-todo-row { grid-template-columns: 48px minmax(0, 1fr) auto 118px; }
}

@media (max-width: 760px) {
  .wh3-todo-row { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .wh3-tile2-foot > span { display: none; }
}

.wh3-chips .wh3-more-filters {
  border-style: dashed;
  background: transparent;
  color: var(--wh3-mute);
}

/* --- Oferta w stylu listy zamowien (29.09 23:40) --------------------------- */
.wh3-offers {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  min-width: 0;
}

.wh3-ostores {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.wh3-ostores .oms-store-filter-label {
  margin-right: 4px;
}

.oms-store-chip.tone-bt { --oms-store-chip-color: var(--oms-slate-500); }
.oms-store-chip.tone-none { --oms-store-chip-color: transparent; border-style: dashed; }

.oms-source-badge.tone-tut { background: #a855f7; color: #fff; }
.oms-source-badge.tone-tlk { background: #10b981; color: #fff; }
.oms-source-badge.tone-bt { background: #475569; color: #fff; }

.wh3-otable {
  overflow: hidden;
  border: 1px solid var(--wh3-line);
  border-radius: 14px;
  background: var(--wh3-card);
  box-shadow: var(--wh3-shadow);
}

.wh3-orow {
  position: relative;
  display: grid;
  grid-template-columns: 52px minmax(200px, 1.35fr) 78px minmax(150px, 1fr) minmax(240px, 1.7fr) 104px 96px 124px;
  align-items: center;
  gap: 14px;
  min-height: 66px;
  padding: 8px 16px 8px 18px;
  border-bottom: 1px solid var(--wh3-line-2);
  cursor: pointer;
  transition: background 0.1s;
}

.wh3-orow:last-child { border-bottom: 0; }
.wh3-orow:hover { background: var(--wh3-soft); }

.wh3-orow::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 3px;
  background: transparent;
}

.wh3-orow.st-out::before,
.wh3-orow.st-broken::before { background: var(--wh3-out); }
.wh3-orow.st-critical::before { background: var(--wh3-crit); }
.wh3-orow.st-low::before { background: var(--wh3-low); }
.wh3-orow.st-norecipe::before { background: var(--wh3-issue); }

.wh3-ohead {
  min-height: 40px;
  padding-top: 0;
  padding-bottom: 0;
  border-bottom: 1px solid var(--wh3-line);
  background: var(--wh3-soft);
  color: var(--wh3-mute);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: default;
}

.wh3-ohead:hover { background: var(--wh3-soft); }

.wh3-orow-name {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.wh3-orow-name strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--wh3-ink);
  font-size: 13.5px;
  font-weight: 700;
  line-height: 1.3;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.wh3-orow-name small {
  overflow: hidden;
  color: var(--wh3-mute);
  font-size: 11.5px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-orow-name small b {
  color: var(--wh3-ink-2);
  font-family: var(--wh3-mono);
  font-weight: 600;
}

.wh3-orow-size b {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 8px;
  border-radius: 7px;
  background: var(--wh3-soft-2);
  color: var(--wh3-ink);
  font-size: 12.5px;
  font-weight: 800;
  white-space: nowrap;
}

.wh3-orow-size small { color: var(--wh3-faint); }

.wh3-orow-stores {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  min-width: 0;
}

.wh3-nolink {
  color: var(--wh3-faint);
  font-size: 12px;
  font-style: italic;
}

.wh3-orow-recipe {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.wh3-oline {
  display: block;
  overflow: hidden;
  color: var(--wh3-ink-2);
  font-size: 12.5px;
  line-height: 1.35;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wh3-oline i {
  color: var(--wh3-ink);
  font-style: normal;
  font-weight: 800;
}

.wh3-oline b {
  color: var(--wh3-ink);
  font-weight: 700;
}

.wh3-oline em {
  color: var(--wh3-ok-ink);
  font-style: normal;
  font-weight: 700;
}

.wh3-oline em.bad { color: var(--wh3-out-ink); }

.wh3-oline .wh3-rack {
  height: 18px;
  padding: 0 5px;
  font-size: 10.5px;
  vertical-align: 1px;
}

.wh3-oline.own i {
  color: var(--wh3-mute);
  font-weight: 700;
}

.wh3-oline.missing { color: var(--wh3-out-ink); }

.wh3-orecipe-warn {
  color: var(--wh3-issue);
  font-size: 12.5px;
  font-weight: 700;
}

.wh3-orow-avail,
.wh3-orow-sold {
  display: grid;
  justify-items: end;
  text-align: right;
}

.wh3-orow-avail b {
  color: var(--wh3-ok-ink);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.wh3-orow-avail.st-out b,
.wh3-orow-avail.st-broken b { color: var(--wh3-out-ink); }
.wh3-orow-avail.st-critical b { color: var(--wh3-crit-ink); }
.wh3-orow-avail.st-low b { color: var(--wh3-low-ink); }
.wh3-orow-avail.st-norecipe b { color: var(--wh3-issue); }

.wh3-orow-avail small,
.wh3-orow-sold small {
  color: var(--wh3-mute);
  font-size: 11px;
  white-space: nowrap;
}

.wh3-orow-sold b {
  color: var(--wh3-ink);
  font-size: 14px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}

.wh3-orow-act {
  display: flex;
  justify-content: flex-end;
}

.wh3-orow-act .wh3-btn {
  height: 32px;
  padding: 0 11px;
  font-size: 12.5px !important;
}

.wh3-ohead .wh3-orow-act,
.wh3-ohead > span:nth-child(6),
.wh3-ohead > span:nth-child(7) {
  text-align: right;
}

.wh3-opager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 2px;
  color: var(--wh3-mute);
  font-size: 13px;
}

.wh3-opager b { color: var(--wh3-ink); }

.wh3-opager-btns {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.wh3-opager-btns .wh3-btn {
  width: 34px;
  padding: 0;
  font-size: 18px !important;
}

.wh3-chips-status .tone-ok .dot { background: var(--wh3-ok); }
.wh3-chips-status .tone-norecipe .dot { background: var(--wh3-issue); }

@media (max-width: 1380px) {
  .wh3-orow {
    grid-template-columns: 48px minmax(180px, 1.3fr) 70px minmax(130px, 1fr) minmax(200px, 1.5fr) 92px 84px 112px;
    gap: 12px;
  }
}

@media (max-width: 1100px) {
  .wh3-ohead { display: none; }
  .wh3-orow {
    grid-template-columns: 48px minmax(0, 1fr) auto;
    grid-template-areas:
      "img name avail"
      "img stores stores"
      "img recipe recipe";
    row-gap: 6px;
  }
  .wh3-orow-img { grid-area: img; align-self: start; }
  .wh3-orow-name { grid-area: name; }
  .wh3-orow-avail { grid-area: avail; }
  .wh3-orow-stores { grid-area: stores; }
  .wh3-orow-recipe { grid-area: recipe; }
  .wh3-orow-size,
  .wh3-orow-sold,
  .wh3-orow-act { display: none; }
}

.wh3-item-stores {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  margin-top: 2px;
}

.wh3-item-stores .oms-source-badge {
  padding: 1px 5px;
  font-size: 10px;
  line-height: 1.25;
}

/* Okienko "Zrob wszystko" na karcie zwrotu (01.10.2026): kwota jako karta
   na gorze, kroki automatu jako lista z ikonami zamiast sciany tekstu. */
.oms-ra-amount {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border: 1px solid #bbf7d0;
  border-radius: 12px;
  background: #f0fdf4;
  padding: 14px 16px;
}

.oms-ra-amount.reduced {
  border-color: #fde68a;
  background: #fffbeb;
}

.oms-ra-amount-main {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.oms-ra-amount-main span {
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.oms-ra-amount-main strong {
  color: var(--oms-slate-900);
  font-size: 28px;
  font-weight: 900;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.oms-ra-amount-main small {
  color: var(--oms-slate-600, #475569);
  font-size: 13px;
  font-weight: 600;
}

.oms-ra-chip {
  flex-shrink: 0;
  border-radius: 999px;
  background: #dcfce7;
  color: #166534;
  padding: 6px 12px;
  font-size: 12.5px;
  font-weight: 850;
  white-space: nowrap;
}

.oms-ra-amount.reduced .oms-ra-chip {
  background: #fef3c7;
  color: #92400e;
}

.oms-ra-steps-title {
  margin: 18px 0 8px;
  color: var(--oms-slate-500);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.oms-ra-steps {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.oms-ra-steps li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  border-radius: 10px;
  padding: 8px 10px;
}

.oms-ra-steps li.money {
  border: 1px solid #fecaca;
  background: #fef2f2;
}

.oms-ra-steps li.manual {
  border: 1px solid #fde68a;
  background: #fffbeb;
}

.oms-ra-step-icon {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 999px;
  background: #dcfce7;
  color: #15803d;
}

.oms-ra-step-icon svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.oms-ra-steps li.money .oms-ra-step-icon {
  background: #fee2e2;
  color: #b91c1c;
}

.oms-ra-steps li.manual .oms-ra-step-icon {
  background: #fef3c7;
  color: #b45309;
}

.oms-ra-steps li.off .oms-ra-step-icon {
  background: var(--oms-slate-100);
  color: var(--oms-slate-500);
}

.oms-ra-step-text {
  display: grid;
  gap: 1px;
  min-width: 0;
}

.oms-ra-step-text b {
  color: var(--oms-slate-900);
  font-size: 14.5px;
  font-weight: 750;
}

.oms-ra-steps li.off .oms-ra-step-text b {
  color: var(--oms-slate-500);
}

.oms-ra-step-text small {
  color: var(--oms-slate-500);
  font-size: 12.5px;
  line-height: 1.35;
}

.oms-ra-steps li.money .oms-ra-step-text small {
  color: #b91c1c;
  font-weight: 700;
}

.oms-ra-hint {
  margin-top: 14px;
  border-top: 1px dashed var(--oms-slate-200);
  padding-top: 12px;
  color: var(--oms-slate-600, #475569);
  font-size: 13px;
}

/* Profiter: zysk miesiaca per sklep/zrodlo (karty pod wykresem). */
.oms-p2-store-month {
  margin-top: 18px;
  border-top: 1px solid var(--soft-border);
  padding-top: 16px;
}

.oms-p2-store-month[hidden] {
  display: none !important;
}

.oms-p2-sm-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 12px;
  margin-bottom: 12px;
}

.oms-p2-sm-head span {
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.oms-p2-sm-head em {
  color: var(--text-secondary);
  font-size: 12px;
  font-style: normal;
  font-weight: 550;
  opacity: 0.85;
}

.oms-p2-sm-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 12px;
}

.oms-p2-sm-card {
  min-width: 0;
  border: 1px solid var(--soft-border);
  border-radius: 14px;
  background: var(--bg-secondary);
  padding: 14px 16px 12px;
}

.oms-p2-sm-card header {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.oms-p2-sm-flag {
  flex: 0 0 auto;
  font-size: 17px;
  line-height: 1;
}

.oms-p2-sm-card header b {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  color: var(--text-primary);
  font-size: 13.5px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oms-p2-sm-card header i {
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(22, 163, 74, 0.12);
  padding: 2px 8px;
  color: var(--accent-green);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.oms-p2-sm-card strong {
  display: block;
  margin-top: 10px;
  color: var(--accent-green);
  font-size: 19px;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
  line-height: 1.15;
  white-space: nowrap;
}

.oms-p2-sm-card.neg strong {
  color: var(--accent-red);
}

.oms-p2-sm-card.zero strong {
  color: var(--text-secondary);
}

.oms-p2-sm-bar {
  height: 4px;
  margin-top: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--bg-tertiary);
}

.oms-p2-sm-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--accent-green);
}

.oms-p2-sm-card.neg .oms-p2-sm-bar span {
  background: var(--accent-red);
}

.oms-p2-sm-card p {
  margin: 9px 0 0;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
}

@media (max-width: 760px) {
  .oms-p2-sm-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }

  .oms-p2-sm-card {
    padding: 12px 14px 10px;
  }
}

/* ── Oko w Analityce: ukryj wyniki (02.10.2026) ───────────────────────────
   Klasa .oms-p2-ukryte na #omsAnalyticsView rozmywa wartosci, wykres i tabele,
   a etykiety, daty i formularze kosztow zostaja czytelne. Szarosc zdejmuje
   zielony/czerwony, zeby kolor nie zdradzal znaku wyniku. */
.oms-p2-oko {
  display: inline-flex;
  flex: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  background: var(--bg-secondary);
  padding: 0;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.oms-p2-oko:hover {
  color: var(--text-primary);
}

.oms-p2-oko:focus-visible {
  outline: 2px solid var(--accent-blue);
  outline-offset: 2px;
}

.oms-p2-oko svg {
  width: 20px;
  height: 20px;
}

.oms-p2-oko .oms-p2-oko-ukryte,
.oms-p2-oko[aria-pressed="true"] .oms-p2-oko-widac {
  display: none;
}

.oms-p2-oko[aria-pressed="true"] .oms-p2-oko-ukryte {
  display: block;
}

.oms-p2-oko[aria-pressed="true"] {
  border-color: var(--accent-blue);
  background: var(--accent-blue);
  color: #ffffff;
}

#omsAnalyticsView.oms-p2-ukryte :is(
  #omsAnalyticsProfit,
  #omsAnalyticsDecisionText,
  #omsAnalyticsOrders,
  #omsAnalyticsOrdersSub,
  #omsAnalyticsAdSpend,
  #omsAnalyticsAdSpendSub,
  #omsAnalyticsStores,
  #omsAnalyticsMoreStores,
  #omsAnalyticsOrderDrilldownMeta,
  #omsAnalyticsOrderDrilldownBody,
  #omsProfiterDayProofMeta,
  #omsProfiterDayProofSummary,
  #omsProfiterDayProofTable,
  .oms-p2-period-summary strong,
  #omsProfiterTrendToday,
  #omsProfiterStoreMonth,
  #omsZakresWynik,
  #omsPrzeliczStatus,
  .oms-p2-month-card strong,
  #omsMetricRevenueSub,
  .oms-p2-allegro-stat strong,
  #omsProfiterAllegroOrdersTable,
  #omsProfiterAdsTotal,
  #omsProfiterAdsList,
  #omsAnalyticsInsightList,
  #omsAnalyticsDailyTable,
  #omsAnalyticsManualAdjustmentsSummary
),
#omsAnalyticsView.oms-p2-ukryte #omsAnalyticsStatus:not(.error) {
  filter: blur(9px) grayscale(1);
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}

/* Duze liczby potrzebuja mocniejszego rozmycia - przy 9px dalo sie odczytac
   rzad wielkosci z dlugosci liczby. Status z :not(.error) stoi wyzej osobno,
   bo w :is() podbilby specyficznosc calej listy i ta regula by przegrala. */
#omsAnalyticsView.oms-p2-ukryte :is(
  #omsAnalyticsProfit,
  #omsAnalyticsOrders,
  #omsAnalyticsAdSpend
) {
  filter: blur(18px) grayscale(1);
}

/* Wykres znika caly: nawet mocno rozmyte slupki zdradzaly wysokosc dnia. */
#omsAnalyticsView.oms-p2-ukryte .oms-p2-chart-stage {
  position: relative;
}

#omsAnalyticsView.oms-p2-ukryte #omsAnalyticsBars {
  visibility: hidden;
}

#omsAnalyticsView.oms-p2-ukryte .oms-p2-chart-stage::after {
  content: "Wykres ukryty";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 650;
}

#omsAnalyticsView.oms-p2-ukryte #omsProfiterTooltip {
  display: none !important;
}


/* ===== Priorytetowe pakowanie (15.10.2026) ===== */
/* Kafel w menu: szary gdy pusto, czerwony licznik gdy cos czeka, pulsuje po terminie. */
.oms-filter-item-priority.is-empty,
.oms-filter-subitem-priority.is-empty { opacity: 0.55; }
.oms-filter-item-priority.is-hot .oms-count,
.oms-filter-subitem-priority.is-hot .oms-count {
  background: var(--oms-red-500, #ef4444);
  color: #fff;
}
.oms-filter-item-priority.is-hot .oms-dot-red,
.oms-filter-subitem-priority.is-hot .oms-dot-red {
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.22);
}
.oms-filter-item-priority.is-overdue .oms-count,
.oms-filter-subitem-priority.is-overdue .oms-count {
  background: #b91c1c;
  animation: oms-priority-pulse 1.4s ease-in-out infinite;
}
.oms-filter-item-priority.active,
.oms-filter-subitem-priority.active {
  background: rgba(239, 68, 68, 0.1);
  color: #b91c1c;
}
@keyframes oms-priority-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(185, 28, 28, 0.45); }
  50% { box-shadow: 0 0 0 6px rgba(185, 28, 28, 0); }
}

/* Pigulka na wierszu listy. */
.oms-operation-chip.tone-priority {
  background: #dc2626;
  color: #fff;
  letter-spacing: 0.04em;
}
.oms-operation-chip.tone-priority.is-overdue {
  background: #7f1d1d;
  animation: oms-priority-pulse 1.4s ease-in-out infinite;
}
.oms-table tbody tr.oms-row-priority td:first-child {
  box-shadow: inset 4px 0 0 #dc2626;
}

/* Chip nad tabela (obok "Dziś: N"). */
.oms-priority-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 12px;
  border-radius: 999px;
  background: rgba(220, 38, 38, 0.16);
  border: 1px solid rgba(220, 38, 38, 0.6);
  color: #fca5a5;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}
.oms-priority-chip:hover { background: rgba(220, 38, 38, 0.3); }
.oms-priority-chip.is-overdue {
  background: #b91c1c;
  border-color: #b91c1c;
  color: #fff;
  animation: oms-priority-pulse 1.4s ease-in-out infinite;
}

/* Sesja pakowania: chip w pasku systemowym, badge w naglowku, flaga na karcie z lewej. */
.oms-batch-compact-flags .priority {
  background: #dc2626;
  color: #fff;
  letter-spacing: 0.04em;
}
.oms-batch-priority-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 3px 10px;
  border-radius: 999px;
  background: #dc2626;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.05em;
  white-space: nowrap;
}
.oms-batch-order-note-flag.priority {
  background: #dc2626;
  color: #fff;
  font-weight: 900;
  letter-spacing: 0.04em;
}
.oms-batch-order-card.active .oms-batch-order-note-flag.priority { background: #fff; color: #b91c1c; }
.oms-batch-compact-flags .priority { font-size: 12px; min-height: 26px; padding: 0 12px; }

/* Karta zamowienia: baner na gorze. */
.oms-detail-priority-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  padding: 10px 14px;
  border-radius: 10px;
  background: #dc2626;
  color: #fff;
  font-size: 13px;
}
.oms-detail-priority-banner strong { letter-spacing: 0.05em; }
.oms-detail-priority-banner.is-overdue { background: #7f1d1d; }

/* Tryb dotykowy: wieksze badge. */
html[data-flow-oms-touch="on"] .oms-batch-priority-badge { font-size: 15px; padding: 6px 14px; }
html[data-flow-oms-touch="on"] .oms-batch-compact-flags .priority { font-size: 13px; min-height: 30px; }

@media (max-width: 760px) {
  .oms-batch-priority-badge { margin-left: 4px; font-size: 11px; padding: 2px 8px; }
  .oms-priority-chip { font-size: 11px; padding: 2px 9px; }
}
