/* Product Marketplace Omni — standalone CSS (no Tailwind dependency).
   Prefix pm- to avoid collisions. Responsive: desktop → mobile. */

.pm-wrap,
.pm-wrap *,
.pm-wrap *::before,
.pm-wrap *::after {
  box-sizing: border-box;
}

:root {
  --pm-border: #e2e8f0;
  --pm-bg: #f8fafc;
  --pm-text: #0f172a;
  --pm-muted: #64748b;
  --pm-accent: #2196F3;
  --pm-accent-soft: #E3F2FD;
  --pm-accent-mid: #90CAF9;
  --pm-accent-dark: #0D47A1;
  --pm-radius: 8px;
  --pm-radius-sm: 6px;
  --pm-shadow: 0 1px 3px rgba(15, 23, 42, .06);
}

/* Palette 0D47A1 → 2196F3 → 90CAF9 → E3F2FD flat 2D */
.text-blue-600 {
  color: #2196F3 !important;
}

.text-blue-700 {
  color: #0D47A1 !important;
}

.bg-blue-50 {
  background-color: #E3F2FD !important;
}

.border-blue-200 {
  border-color: #90CAF9 !important;
}

.bg-blue-100 {
  background-color: #90CAF9 !important;
}

.pm-wrap {
  padding: 4px;
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
}

/* header */
.pm-head {
  margin-bottom: 16px;
}

.pm-title {
  font-size: 20px;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

.pm-sub {
  margin: 4px 0 0;
  font-size: 14px;
  color: #6b7280;
}

/* toolbar */
.pm-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.pm-select {
  padding: 8px 12px;
  font-size: 14px;
  color: #374151;
  height: 40px;
  background: #fff;
  border: 1px solid var(--pm-border);
  border-radius: 8px;
  outline: none;
}

.pm-select:focus {
  border-color: var(--pm-accent);
  box-shadow: 0 0 0 3px var(--pm-accent-soft);
}

.pm-select2 {
  width: 170px;
}

.pm-toolbar .select2 {
  width: 170px !important;
}

.pm-toolbar .select2-container .select2-selection--single {
  height: 40px;
  border: 1px solid var(--pm-border);
  border-radius: 8px;
  display: flex;
  align-items: center;
  padding: 0 8px;
  font-size: 14px;
}

.pm-toolbar .select2-container .select2-selection--single .select2-selection__rendered {
  line-height: 38px;
  color: #374151;
}

.pm-toolbar .select2-container--default .select2-selection--single .select2-selection__arrow {
  height: 38px;
}

.pm-toolbar .select2-container .select2-selection--single,
.pm-duplicate-select2-container .select2-selection--single {
  background: #fff !important;
  border: 1px solid var(--pm-border) !important;
  border-radius: 8px !important;
  box-shadow: none !important;
  color: #374151 !important;
}

.pm-toolbar .select2-container--focus .select2-selection--single,
.pm-toolbar .select2-container--open .select2-selection--single,
.pm-duplicate-select2-container.select2-container--focus .select2-selection--single,
.pm-duplicate-select2-container.select2-container--open .select2-selection--single {
  border-color: #cbd5e1 !important;
  box-shadow: 0 0 0 2px #f1f5f9 !important;
}

.pm-toolbar .select2-selection__placeholder,
.pm-duplicate-select2-container .select2-selection__placeholder {
  color: #94a3b8 !important;
}

.pm-toolbar .select2-dropdown,
.pm-duplicate-select2-dropdown {
  border: 1px solid var(--pm-border) !important;
  border-radius: 8px !important;
  box-shadow: 0 8px 20px rgba(15, 23, 42, .1) !important;
  overflow: hidden;
}

.pm-toolbar .select2-results__option,
.pm-duplicate-select2-dropdown .select2-results__option {
  padding: 8px 10px !important;
  color: #475569 !important;
  font-size: 13px !important;
}

.pm-toolbar .select2-results__option--highlighted[aria-selected],
.pm-duplicate-select2-dropdown .select2-results__option--highlighted[aria-selected] {
  background: #f8fafc !important;
  color: #334155 !important;
}

.pm-toolbar .select2-results__option[aria-selected="true"],
.pm-duplicate-select2-dropdown .select2-results__option[aria-selected="true"] {
  background: #f1f5f9 !important;
  color: #334155 !important;
}

.pm-search {
  position: relative;
  flex: 1 1 220px;
  min-width: 180px;
}

.pm-search i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #9ca3af;
}

.pm-search input {
  width: 100%;
  height: 40px;
  padding: 0 16px 0 34px;
  font-size: 14px;
  background: #fff;
  border: 1px solid var(--pm-border);
  border-radius: 8px;
  outline: none;
}

.pm-search input:focus {
  border-color: var(--pm-accent);
  box-shadow: 0 0 0 3px var(--pm-accent-soft);
}

.pm-btn-reset-filters {
  height: 40px;
  padding: 0 12px;
  font-size: 12px;
  border-radius: 8px;
  font-weight: 500;
  color: #64748b;
  border-color: #cbd5e1;
  background: #ffffff;
}

.pm-btn-reset-filters:hover {
  color: #dc2626;
  border-color: #fca5a5;
  background: #fef2f2;
}

/* list card */
.pm-card {
  background: #fff;
  border: 1px solid var(--pm-border);
  border-radius: var(--pm-radius);
  overflow: hidden;
  box-shadow: var(--pm-shadow);
}

.pm-row {
  padding: 14px 16px;
  border-bottom: 1px solid #f3f4f6;
  transition: background .15s;
}

.pm-row:last-child {
  border-bottom: none;
}

.pm-row:hover {
  background: #f9fafb;
}

/* top row = CSS grid:  [thumb] [identity grows] [stats] [actions]
   collapses to 2-col then 1-col on small screens */
.pm-row-top {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px 16px;
}

.pm-thumb,
.pm-thumb-empty {
  width: 48px;
  height: 48px;
  border: 1px solid var(--pm-border);
  border-radius: 8px;
  flex-shrink: 0;
}

.pm-thumb {
  object-fit: cover;
}

.pm-thumb-empty {
  background: #f9fafb;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #d1d5db;
}

.pm-identity {
  min-width: 0;
}

.pm-name {
  font-weight: 500;
  font-size: 14px;
  color: #111827;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pm-meta {
  margin: 3px 0 0;
  font-size: 12px;
  color: #6b7280;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0;
}

.pm-meta .dot {
  margin: 0 8px;
  color: #d1d5db;
}

.pm-type {
  color: var(--pm-accent);
  font-weight: 500;
}

.pm-sku {
  color: #9ca3af;
}

.pm-muted {
  color: #9ca3af;
}

.pm-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .92em;
}

/* product-type chip */
.pm-typechip {
  display: inline-block;
  padding: 1px 8px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 999px;
}

.pm-type-single {
  color: #374151;
  background: #f3f4f6;
}

.pm-type-variant {
  color: #0D47A1;
  background: #E3F2FD;
}

.pm-type-child {
  color: var(--pm-accent);
  background: #E3F2FD;
}

.pm-type-bundle {
  color: #b45309;
  background: #fef3c7;
}

/* reserved suffix on stock value */
.pm-reserved {
  font-size: 12px;
  font-weight: 500;
  color: #d97706;
}

/* no-listing hint chip */
.pm-nolisting {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #9ca3af;
  font-style: italic;
}

.pm-badge-count {
  opacity: .95;
  font-weight: 700;
}

.pm-badge-sep {
  margin: 0 5px;
  opacity: .5;
  font-weight: 400;
}

/* stats block groups both stats side by side so grid stays clean */
.pm-stats {
  display: flex;
  gap: 16px;
}

.pm-stat {
  text-align: right;
}

.pm-stat-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .02em;
  color: #9ca3af;
  margin: 0;
}

.pm-stat-value {
  font-size: 15px;
  font-weight: 600;
  color: #111827;
  margin: 2px 0 0;
  font-variant-numeric: tabular-nums;
}

.pm-stat-value.empty {
  color: #dc2626;
}

/* actions block */
.pm-actions {
  display: flex;
  gap: 8px;
}

/* buttons */
.pm-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 6px;
  cursor: pointer;
  transition: all .15s;
  white-space: nowrap;
  line-height: 1;
}

.pm-btn-outline {
  color: #334155;
  background: #fff;
  border: 1px solid #cbd5e1;
}

.pm-btn-outline:hover {
  border-color: var(--pm-accent);
  color: var(--pm-accent);
  background: var(--pm-accent-soft);
}

.pm-btn-ghost {
  color: var(--pm-accent);
  background: #fff;
  border: 1px solid #cbd5e1;
}

.pm-btn-ghost:hover {
  background: var(--pm-accent-soft);
  border-color: var(--pm-accent);
  color: #0D47A1;
}

.pm-btn-primary {
  color: #fff;
  background: var(--pm-accent);
  border: 1px solid var(--pm-accent);
}

.pm-btn-primary:hover {
  background: #0D47A1;
  border-color: #0D47A1;
}

.pm-btn-outline i,
.pm-btn-ghost i {
  color: inherit;
}

.pm-btn-sm {
  padding: 6px 10px;
  font-size: 11px;
  height: 28px;
  border-radius: 6px;
  line-height: 1;
}

.pm-btn-disabled,
.pm-btn:disabled {
  opacity: .45;
  cursor: not-allowed;
  pointer-events: none;
  filter: none;
}

.pm-btn-duplicate {
  gap: 7px;
}

.pm-btn-duplicate .pm-btn-caret {
  margin-left: 1px;
  font-size: 9px;
  opacity: .75;
}

/* icon-only button (sync) */
.pm-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 1px solid var(--pm-border);
  border-radius: 6px;
  color: #64748b;
  background: #fff;
  cursor: pointer;
  transition: all .15s;
  text-decoration: none;
}

.pm-icon-btn:hover {
  border-color: var(--pm-accent);
  color: var(--pm-accent);
  background: #f5f3ff;
}

.pm-icon-btn-tokopedia {
  color: #111827;
}

.pm-icon-btn-tokopedia:hover {
  border-color: #111827;
  color: #000;
  background: #f3f4f6;
}

.pm-row-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  justify-content: center;
}

/* store chips */
.pm-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
}

.pm-chip-select {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border: 1px solid var(--pm-border);
  border-radius: 4px;
  background: #fff;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}

.pm-chip-select:hover {
  border-color: var(--pm-accent);
  background: #f5f3ff;
}

.pm-chip-select input {
  width: 12px;
  height: 12px;
  margin: 0;
  accent-color: var(--pm-accent);
  cursor: pointer;
}

.pm-badge {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 4px;
  color: #fff;
  white-space: nowrap;
}

.pm-badge.shopee {
  background: #ee4d2d;
}

.pm-badge.tiktok {
  background: #111827;
}

.pm-chip {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  max-width: 180px;
  font-size: 11px;
  color: #4b5563;
  background: #fff;
  border: 1px solid var(--pm-border);
  border-radius: 4px;
  cursor: pointer;
  transition: all .15s;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pm-chip:hover {
  border-color: var(--pm-accent);
  background: #f5f3ff;
  color: var(--pm-accent);
}

/* chip + inline sync button */
.pm-chip-group {
  display: inline-flex;
  align-items: stretch;
}

.pm-chip-group .pm-chip {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.pm-chip-sync {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 22px;
  width: 24px;
  margin-left: -1px;
  border: 1px solid var(--pm-border);
  border-top-right-radius: 4px;
  border-bottom-right-radius: 4px;
  background: #fff;
  color: #94a3b8;
  cursor: pointer;
  font-size: 10px;
  transition: all .15s;
}

.pm-chip-sync:hover {
  border-color: var(--pm-accent);
  color: var(--pm-accent);
  background: #f5f3ff;
}

/* open-in-marketplace link between store chip and sync button */
.pm-chip-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 22px;
  width: 24px;
  margin-left: -1px;
  border: 1px solid var(--pm-border);
  border-radius: 0;
  background: #fff;
  color: #94a3b8;
  cursor: pointer;
  font-size: 10px;
  text-decoration: none;
  transition: all .15s;
}

.pm-chip-link:hover {
  border-color: var(--pm-accent);
  color: var(--pm-accent);
  background: #f5f3ff;
}

/* skeleton */
.pm-skel-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 16px;
  border-bottom: 1px solid #f3f4f6;
}

.pm-skel {
  background: #f3f4f6;
  border-radius: 4px;
  animation: pmPulse 1.2s ease-in-out infinite;
}

.pm-skel.box {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  flex-shrink: 0;
}

.pm-skel.line {
  height: 12px;
}

.pm-skel.w33 {
  width: 33%;
}

.pm-skel.w50 {
  width: 50%;
}

.pm-skel.btn {
  width: 96px;
  height: 24px;
  flex-shrink: 0;
}

.pm-skel-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pm-skel-detail {
  padding: 16px 0;
}

.pm-skel-line {
  display: block;
}

@keyframes pmPulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: .5;
  }
}

/* empty */
.pm-empty {
  padding: 48px 16px;
  text-align: center;
}

.pm-empty i {
  font-size: 32px;
  color: #d1d5db;
}

.pm-empty p {
  margin: 12px 0 0;
  font-size: 14px;
  font-weight: 500;
  color: #374151;
}

/* pagination */
.pm-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
}

.pm-show {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  font-size: 14px;
  color: #6b7280;
  white-space: nowrap;
}

.pm-show select {
  width: 64px;
  min-width: 64px;
  height: 30px;
  padding: 4px 22px 4px 8px;
  border: 1px solid var(--pm-border);
  border-radius: 6px;
  background-color: #fff;
  color: #374151;
  line-height: 20px;
}

.pm-pager {
  display: flex;
  border: 1px solid var(--pm-border);
  border-radius: 6px;
  overflow: hidden;
  margin: 0;
  padding: 0;
}

.pm-pager li {
  border-right: 1px solid var(--pm-border);
  list-style: none;
}

.pm-pager li:last-child {
  border-right: none;
}

.pm-page {
  display: block;
  padding: 8px 12px;
  font-size: 14px;
  color: #4b5563;
  transition: background .15s;
  font-variant-numeric: tabular-nums;
}

.pm-page:hover {
  background: #f9fafb;
}

.pm-page.active {
  background: var(--pm-accent);
  color: #fff;
}

.pm-ellipsis {
  display: block;
  padding: 8px 12px;
  font-size: 14px;
  color: #9ca3af;
}

/* ===== detail page ===== */
.pm-detail-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: flex-start;
  gap: 16px;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--pm-border);
}

.pm-back {
  margin-top: 4px;
  color: #9ca3af;
  cursor: pointer;
  background: none;
  border: none;
  transition: color .15s;
  font-size: 16px;
}

.pm-back:hover {
  color: #111827;
}

.pm-detail-head .pm-title {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pm-summary {
  display: flex;
  align-items: center;
  border: 1px solid var(--pm-border);
  border-radius: var(--pm-radius);
  background: #fafafa;
  overflow: hidden;
}

.pm-summary-cell {
  flex: 1;
  padding: 10px 14px;
  text-align: center;
  border-right: 1px solid var(--pm-border);
}

.pm-summary-cell:last-child {
  border-right: none;
}

.pm-summary-lbl {
  margin: 0 0 3px;
  font-size: 10px;
  font-weight: 600;
  color: var(--pm-muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  white-space: nowrap;
}

.pm-summary-val {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.15;
  color: #111827;
  margin: 0;
  font-variant-numeric: tabular-nums;
}

.pm-summary-val.empty {
  color: #dc2626;
}

.pm-subnav {
  display: flex;
  gap: 0;
  padding: 0 12px;
  margin-bottom: 16px;
  border-bottom: 1px solid #f1f5f9;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.pm-subnav-link {
  padding: 10px 12px;
  font-size: 12px;
  font-weight: 500;
  color: var(--pm-muted);
  border-radius: 0;
  border-bottom: 2px solid transparent;
  text-decoration: none;
  white-space: nowrap;
  transition: all .15s;
  margin-bottom: -1px;
}

.pm-subnav-link:hover {
  color: var(--pm-text);
}

.pm-subnav-link.is-active {
  color: var(--pm-accent);
  background: transparent;
  border-bottom-color: var(--pm-accent);
  font-weight: 600;
}

.pm-sku-copy {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding: 8px 12px;
  border: 1px dashed var(--pm-border);
  border-radius: var(--pm-radius-sm);
  background: var(--pm-bg);
  font-size: 13px;
}

.pm-copy-btn {
  border: 1px solid var(--pm-border);
  background: #fff;
  border-radius: 6px;
  width: 28px;
  height: 28px;
  cursor: pointer;
  color: var(--pm-muted);
}

.pm-copy-btn:hover {
  border-color: var(--pm-accent);
  color: var(--pm-accent);
}

.pm-desc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.pm-desc--clamped .pm-desc-body {
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pm-desc:not(.pm-desc--clamped) .pm-desc-body {
  display: block;
}

#pm-sec-overview,
#pm-sec-listing,
#pm-sec-mpinfo,
#pm-sec-variant,
#pm-sec-bundle,
#pm-sec-stock {
  scroll-margin-top: 12px;
}

.pm-section {
  background: #fff;
  border: 1px solid var(--pm-border);
  border-radius: var(--pm-radius);
  overflow: hidden;
  margin-top: 16px;
  box-shadow: none;
}

.pm-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px;
  border-bottom: 1px solid #f1f5f9;
}

.pm-channel-filter {
  display: flex;
  gap: 6px;
}

.pm-channel-filter .pm-chip.is-active {
  border-color: var(--pm-accent);
  background: var(--pm-accent-soft);
  color: var(--pm-accent);
}

.pm-section-head h4 {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

.pm-section-head p {
  margin: 2px 0 0;
  font-size: 12px;
  color: #64748b;
}

.pm-bulk-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 16px;
  border-bottom: 1px solid #f3f4f6;
  background: #fafafa;
  font-size: 12px;
  color: #6b7280;
}

.pm-bulk-toolbar input[type="checkbox"] {
  accent-color: var(--pm-accent);
}

.pm-list-toolbar {
  display: flex;
  align-items: center;
  min-height: 42px;
  gap: 14px;
  margin-bottom: 12px;
  padding: 0 4px;
  font-size: 12px;
  color: #6b7280;
}

.pm-list-toolbar .pm-select-all {
  padding-right: 14px;
  border-right: 1px solid var(--pm-border);
}

.pm-list-toolbar .pm-btn {
  padding: 7px 11px;
  font-size: 12px;
}

.pm-selection-count {
  color: var(--pm-accent);
  font-weight: 600;
}

.pm-select-all {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  cursor: pointer;
  color: #6b7280;
}

.pm-select-all input {
  margin: 0;
}

.pm-bulk-count {
  color: var(--pm-accent);
  font-weight: 600;
}

.pm-bulk-toolbar .pm-btn {
  padding: 5px 10px;
  font-size: 11px;
}

.pm-sync-progress-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  padding: 9px 10px;
  border: 1px solid var(--pm-border);
  border-radius: 8px;
  background: #fafafa;
  color: #6b7280;
  font-size: 12px;
}

.pm-sync-row-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
  font-size: 11px;
  font-weight: 600;
}

.pm-sync-row-status.pending {
  color: #9ca3af;
}

.pm-sync-row-status.syncing {
  color: var(--pm-accent);
}

.pm-sync-row-status.success {
  color: #047857;
}

.pm-sync-row-status.error {
  color: #b91c1c;
}

.pm-sync-error {
  display: block;
  max-width: 180px;
  margin-top: 3px;
  color: #b91c1c;
  font-size: 10px;
  line-height: 1.3;
}

.pm-modal-close-disabled {
  opacity: .35;
  cursor: not-allowed;
  pointer-events: none;
}

.pm-btn-disabled {
  opacity: .45;
  cursor: not-allowed !important;
  pointer-events: none;
  filter: grayscale(.2);
}

.pm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.pm-table thead th {
  padding: 8px 14px;
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  text-align: left;
  border-bottom: 1px solid #e2e8f0;
  background: #f8fafc;
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.pm-table thead th.right {
  text-align: right;
}

.pm-table thead th.center {
  text-align: center;
}

.pm-table tbody td {
  padding: 10px 14px;
  border-bottom: 1px solid #f1f5f9;
  color: #0f172a;
  vertical-align: middle;
  font-size: 12px;
}

.pm-table tbody tr:last-child td {
  border-bottom: none;
}

.pm-table tbody tr:hover {
  background: #fbfcfe;
}

.pm-table tbody tr.pm-table-subhead th {
  background: #f8fafc;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  text-align: left;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 9px 14px;
  border-top: 1px solid #e2e8f0;
  border-bottom: 1px solid #e2e8f0;
}

.pm-table tbody tr.pm-table-subhead:hover {
  background: #f8fafc;
}

.pm-table td.right {
  text-align: right;
  font-weight: 600;
  color: #111827;
  font-variant-numeric: tabular-nums;
}

.pm-table td.right.empty {
  color: #dc2626;
}

.pm-table td.center {
  text-align: center;
}

.pm-badge-rule {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 500;
  color: #475569;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  padding: 1.5px 7px;
  white-space: nowrap;
}

.pm-row-actions {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.pm-sku-variants-collapse {
  margin-top: 3px;
  font-size: 11px;
}

.pm-sku-variants-summary {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  padding: 1.5px 6px;
  border-radius: 4px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  color: #334155;
  transition: all 0.15s ease;
  user-select: none;
  list-style: none;
  font-size: 10.5px;
}

.pm-sku-variants-summary::-webkit-details-marker {
  display: none;
}

.pm-sku-variants-summary:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.pm-sku-variants-collapse[open] .pm-sku-variants-summary {
  background: #e0f2fe;
  border-color: #bae6fd;
  color: #0369a1;
}

.pm-sku-variants-dropdown {
  margin-top: 4px;
  padding: 6px 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 140px;
  max-width: 260px;
  overflow-y: auto;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}

.pm-sku-variant-entry {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  line-height: 1.3;
}

.pm-truncate {
  max-width: 240px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pm-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* ==========================================================================
   Grouped Listing Table (Published Consumers / Rincian Listing Toko)
   ========================================================================== */
.pm-table tbody tr.pm-consumer-subhead th {
  background: #f8fafc;
  color: #1e293b;
  font-size: 12px;
  font-weight: 600;
  text-align: left;
  text-transform: none;
  letter-spacing: normal;
  padding: 9px 12px;
  border-top: 1px solid #e2e8f0;
  border-bottom: 1px solid #e2e8f0;
}

/* compact listing table (stacked cells, small fonts) */
.pm-listing-table {
  font-size: 12px;
}

.pm-listing-table tbody td {
  padding: 6px 10px;
  font-size: 12px;
  vertical-align: middle;
}

.pm-listing-table .pm-th-sub {
  display: block;
  margin-top: 1px;
  font-size: 10px;
  font-weight: 400;
  color: #c0c4cc;
  text-transform: none;
  letter-spacing: 0;
}

/* Inline SKU + Compact Auto-scroll Product Name Ticker */
.pm-sku-inline-wrap {
  display: flex;
  align-items: center;
  gap: 5px;
  max-width: 100%;
}

.pm-sku-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  font-weight: 600;
  color: #0f172a;
  white-space: nowrap;
  flex-shrink: 0;
}

.pm-sku-sep {
  font-size: 9px;
  color: #94a3b8;
  flex-shrink: 0;
}

.pm-sku-name-ticker {
  font-size: 10px;
  color: #64748b;
  max-width: 160px;
  white-space: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  cursor: default;
  display: inline-block;
  vertical-align: middle;
  padding: 1px 0;
  transition: max-width 0.25s ease, color 0.15s ease;
}

.pm-sku-name-ticker::-webkit-scrollbar {
  display: none;
}

.pm-sku-name-ticker:hover {
  max-width: 280px;
  color: #1e293b;
}

.pm-cell-stack {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.pm-cell-stack-right {
  align-items: flex-end;
}

.pm-cell-sub {
  font-size: 11px;
  color: #9ca3af;
}

.pm-cell-sub.empty {
  color: #dc2626;
}

.pm-channel-store {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.pm-store {
  font-weight: 600;
  font-size: 12px;
  color: #111827;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pm-listing-name {
  font-size: 12px;
  color: #111827;
  line-height: 1.3;
  max-width: 260px;
  word-break: break-word;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pm-price {
  font-weight: 700;
  font-size: 12px;
  color: #111827;
  font-variant-numeric: tabular-nums;
}

/* status pill + mp status pill — konsisten (capsule) */
.pm-status,
.pm-mpstatus {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 999px;
  text-transform: capitalize;
  white-space: nowrap;
  line-height: 1.4;
}

.pm-status::before,
.pm-mpstatus::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
  background: currentColor;
}

.pm-status-publish,
.pm-mpstatus-NORMAL {
  color: #047857;
  background: #d1fae5;
}

.pm-status-unpublish,
.pm-mpstatus-UNLIST {
  color: #6b7280;
  background: #f3f4f6;
}

.pm-status-draft {
  color: #b45309;
  background: #fef3c7;
}

.pm-mpstatus-archived {
  color: #b45309;
  background: #fef3c7;
}

.pm-mpstatus-activate,
.pm-mpstatus-normal {
  color: #047857;
  background: #d1fae5;
}

.pm-mpstatus-pending,
.pm-mpstatus-auditing,
.pm-mpstatus-pre-approved,
.pm-mpstatus-scheduled {
  color: #92400e;
  background: #fef3c7;
}

.pm-mpstatus-failed,
.pm-mpstatus-seller-deactivated,
.pm-mpstatus-platform-deactivated,
.pm-mpstatus-freeze,
.pm-mpstatus-deleted {
  color: #b91c1c;
  background: #fee2e2;
}

.pm-mpstatus-draft,
.pm-mpstatus-initial,
.pm-mpstatus-none,
.pm-mpstatus-unknown {
  color: #6b7280;
  background: #f3f4f6;
}

.pm-mpstatus {
  text-transform: none;
}

/* actions — icon row + detail row */
.pm-row-actions {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}

.pm-row-actions .pm-icon-btn {
  width: 26px;
  height: 26px;
  font-size: 12px;
}

.pm-row-actions-detail {
  display: flex;
  justify-content: center;
  margin-top: 4px;
}

.pm-row-actions-detail .pm-btn-outline {
  padding: 3px 12px;
  font-size: 11px;
}

/* relation banner (variant parent link) */
.pm-relation {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 12px 16px;
  margin-top: 16px;
  background: #f5f3ff;
  border: 1px solid #ddd6fe;
  border-radius: 12px;
}

.pm-relation-label {
  font-size: 13px;
  color: #6b7280;
}

.pm-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--pm-accent);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  text-align: left;
}

.pm-link:hover {
  text-decoration: underline;
}

/* inline store tag inside variant table */
.pm-tag {
  display: inline-block;
  margin: 2px 4px 2px 0;
  padding: 2px 8px;
  font-size: 11px;
  color: #4b5563;
  background: #f3f4f6;
  border-radius: 4px;
  white-space: nowrap;
}

/* overview: image + attribute grid */
.pm-overview {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 16px;
  margin-top: 16px;
  align-items: start;
}

.pm-overview-media {}

.pm-hero-img,
.pm-hero-empty {
  width: 100%;
  aspect-ratio: 1 / 1;
  max-width: 220px;
  border: 1px solid var(--pm-border);
  border-radius: var(--pm-radius);
  object-fit: cover;
}

.pm-hero-empty {
  background: #f9fafb;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #d1d5db;
  font-size: 40px;
}

.pm-overview-info {
  min-width: 0;
}

.pm-info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px 24px;
  background: #fff;
  border: 1px solid var(--pm-border);
  border-radius: var(--pm-radius);
  padding: 16px 20px;
}

.pm-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.pm-info-lbl {
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--pm-muted);
}

.pm-info-val {
  font-size: 14px;
  color: #111827;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* description accordion */
.pm-desc {
  margin-top: 12px;
  background: #fff;
  border: 1px solid var(--pm-border);
  border-radius: var(--pm-radius);
  padding: 12px 16px;
}

.pm-desc summary {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  cursor: pointer;
}

.pm-desc-body {
  margin-top: 8px;
  font-size: 13px;
  color: #4b5563;
  white-space: pre-line;
  line-height: 1.6;
  max-height: 260px;
  overflow-y: auto;
}

/* variant types */
.pm-vtypes {
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pm-vtype {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.pm-vtype-name {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  min-width: 60px;
}

.pm-vtype-opts {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

/* media thumbnails */
.pm-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.pm-thumb-sm {
  width: 44px;
  height: 44px;
  border: 1px solid var(--pm-border);
  border-radius: 6px;
  object-fit: cover;
}

.pm-thumb-video {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f3f4f6;
  color: #6b7280;
}

/* selling point */
.pm-selling {
  margin-top: 12px;
  background: #fff;
  border: 1px solid var(--pm-border);
  border-radius: var(--pm-radius);
  padding: 12px 16px;
}

.pm-selling p {
  margin: 4px 0 0;
  font-size: 13px;
  color: #4b5563;
}

/* marketplace info accordions */
.pm-mpinfo {
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pm-mpinfo-item {
  border: 1px solid var(--pm-border);
  border-radius: 10px;
  overflow: hidden;
}

.pm-mpinfo-item summary {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  cursor: pointer;
  font-size: 13px;
}

.pm-mpinfo-item summary::-webkit-details-marker {
  display: none;
}

.pm-mpinfo-ids {
  color: #6b7280;
  font-size: 12px;
}

.pm-mpinfo-body {
  border-top: 1px solid #f3f4f6;
}

.pm-table-flat {
  font-size: 13px;
}

/* per-variant sub-table inside a listing row */
.pm-models-row td {
  background: #fafafa;
  padding: 0;
}

.pm-models-row .pm-table-flat {
  margin: 0 12px 12px;
}

.pm-models-row .pm-table-flat th {
  color: #6b7280;
  font-weight: 500;
  font-size: 11px;
  text-transform: uppercase;
}

.pm-listing-sub-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
}

.pm-models-toggle-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  font-size: 11px;
  font-weight: 500;
  border-radius: 6px;
  background: #ffffff;
  color: #334155;
  border: 1px solid #cbd5e1;
  cursor: pointer;
  transition: all 0.15s;
  line-height: 1;
}

.pm-models-toggle-chip:hover {
  border-color: var(--pm-accent);
  color: var(--pm-accent);
  background: var(--pm-accent-soft);
}

.pm-models-toggle-chip.is-active {
  border-color: var(--pm-accent);
  color: var(--pm-accent);
  background: var(--pm-accent-soft);
  font-weight: 600;
}

.pm-expand-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  background: #f8fafc;
  border-top: 1px solid #f1f5f9;
}

/* Stock Distribution Card */
.pm-stock-dist-body {
  padding: 14px 16px;
}

.pm-stock-dist-summary {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pm-stock-dist-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
}

.pm-stock-dist-desc {
  font-size: 12px;
  color: #64748b;
  margin: 0;
}

.pm-stock-dist-edit-body {
  padding: 16px;
  background: #fafafa;
  border-top: 1px solid #f1f5f9;
}

.pm-stock-dist-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 640px;
  margin: 0 auto;
}

.pm-stock-dist-option {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
  cursor: pointer;
  transition: all 0.15s;
}

.pm-stock-dist-option:hover {
  border-color: #cbd5e1;
  background: #ffffff;
}

.pm-stock-dist-option.is-selected {
  border-color: #ddd6fe;
  background: #faf5ff;
}

.pm-stock-dist-option input[type="radio"] {
  margin-top: 2px;
  accent-color: var(--pm-accent);
}

.pm-stock-dist-option-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.pm-stock-dist-option-info strong {
  font-size: 13px;
  font-weight: 600;
  color: #1e293b;
}

.pm-stock-dist-option-info span {
  font-size: 12px;
  color: #64748b;
}

.pm-stock-dist-buffer-input-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.pm-stock-dist-buffer-label {
  font-size: 12px;
  font-weight: 600;
  color: #475569;
}

.pm-stock-dist-buffer-input {
  width: 90px;
  padding: 5px 8px;
  font-size: 12px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #ffffff;
  color: #0f172a;
  outline: none;
}

.pm-stock-dist-buffer-input:focus {
  border-color: var(--pm-accent);
  box-shadow: 0 0 0 2px var(--pm-accent-soft);
}

.pm-stock-dist-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #e2e8f0;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}

/* Minimalist Stock Distribution Strip & Panel — single outer border, inner dividers only */
.pm-dist-view-panel {
  padding: 0;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.pm-dist-summary-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 12px 16px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.pm-dist-strip-col {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 130px;
}

.pm-dist-strip-label {
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.pm-dist-strip-value {
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
}

.pm-dist-strip-divider {
  width: 1px;
  height: 32px;
  background: #e2e8f0;
}

.pm-dist-strip-col-highlight {
  background: #ffffff;
  padding: 6px 12px;
  border-radius: 6px;
  border: 1px solid #cbd5e1;
}

.pm-dist-sub-note {
  font-size: 11px;
  color: #64748b;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  line-height: 1.4;
  padding: 8px 12px 0;
  margin-top: 4px;
}

/* Edit Panel — muted, single accent, no pastel banners */
.pm-dist-edit-panel {
  padding: 14px 16px;
  background: #f8fafc;
  border-top: 1px solid #f1f5f9;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pm-dist-mode-selector {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.pm-dist-mode-card {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 12px 14px;
  background: #fff;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: all 0.15s ease;
}

.pm-dist-mode-card:hover {
  border-color: #cbd5e1;
}

.pm-dist-mode-card.is-active {
  border-color: var(--pm-accent);
  background: var(--pm-accent-soft);
}

.pm-dist-mode-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  color: #0f172a;
}

.pm-dist-mode-desc {
  font-size: 11px;
  color: #64748b;
  margin: 0;
  line-height: 1.4;
}

.pm-dist-mode-example {
  font-size: 11px;
  color: #94a3b8;
  font-style: italic;
  margin-top: 2px;
}

.pm-dist-buffer-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  padding: 6px 8px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 11px;
}

.pm-dist-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid #e2e8f0;
}

.pm-dist-consumers-toggle-wrap {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-top: 8px;
}

.pm-pagination-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: #fff;
  border-top: 1px solid #f3f4f6;
  font-size: 11px;
  color: #64748b;
}

.pm-consumer-row {
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.pm-consumer-row:hover td {
  background-color: #f1f5f9 !important;
}

.pm-row-stock-warn td {
  background: #fffbeb !important;
}

.pm-row-stock-warn .pm-stock-input {
  border-color: #f59e0b !important;
}

/* global sync progress bar (top of viewport) */
.pm-syncbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 9999;
  pointer-events: none;
  opacity: 0;
  transition: opacity .2s;
}

.pm-syncbar.active {
  opacity: 1;
}

.pm-syncbar i {
  display: block;
  height: 100%;
  width: 40%;
  background: linear-gradient(90deg, transparent, var(--pm-accent), transparent);
  animation: pm-sync-slide 1s infinite linear;
}

.pm-syncbar.ok i {
  width: 100%;
  background: #22c55e;
  animation: none;
  transition: width .3s;
}

.pm-syncbar.fail i {
  width: 100%;
  background: #ef4444;
  animation: none;
  transition: width .3s;
}

@keyframes pm-sync-slide {
  from {
    transform: translateX(-100%);
  }

  to {
    transform: translateX(350%);
  }
}

/* sync modal (syncProductShopeeApi.js) — replaces previous inline styles */
.pm-syncmodal {
  --pm-sync-accent: var(--pm-accent);
}

.pm-syncmodal .syncmodal-popup {
  border-radius: 16px;
  padding: 0;
  overflow: hidden;
}

.pm-syncmodal-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
}

.pm-syncmodal-row+.pm-syncmodal-row {
  border-top: 1px solid #f1f5f9;
}

.pm-syncmodal-chip {
  display: inline-block;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 500;
  color: #475569;
  background: #f1f5f9;
  border-radius: 6px;
}

.pm-syncmodal-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 11px 12px;
  margin-top: 16px;
  font-size: 12px;
  line-height: 1.4;
  border-radius: 10px;
  background: #fffbeb;
  color: #b45309;
}

/* sync button busy state (icon buttons in listing rows / chips) */
.pm-icon-btn.syncing,
.pm-chip-sync.syncing {
  opacity: .55;
  pointer-events: none;
}

/* update price/stock modals */
.pm-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, .45);
  padding: 16px;
}

.swal2-container,
.pm-duplicate-swal-container {
  z-index: 99999 !important;
}

.pm-modal-box {
  width: 100%;
  max-width: 560px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 8px;
  border: 1px solid var(--pm-border);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  overflow: hidden;
}

.pm-modal-box.pm-modal-box--wide {
  max-width: 768px;
}

.pm-modal-box.pm-sku-consumers-modal-box {
  max-width: 780px;
  width: 95vw;
}

.pm-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid var(--pm-border);
  background: #fff;
}

.pm-modal-head h4 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: #0f172a;
}

.pm-modal-close {
  border: none;
  background: none;
  color: #9ca3af;
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
}

.pm-modal-close:hover {
  color: #374151;
}

.pm-modal-body {
  padding: 16px 18px;
  overflow-y: auto;
}

.pm-modal-note {
  margin: 0 0 12px;
  font-size: 12px;
  color: #6b7280;
}

.pm-price-input,
.pm-stock-input {
  width: 130px;
  padding: 6px 10px;
  font-size: 13px;
  border: 1px solid var(--pm-border);
  border-radius: 6px;
  text-align: right;
}

.pm-price-input:focus,
.pm-stock-input:focus {
  outline: none;
  border-color: var(--pm-accent);
  box-shadow: 0 0 0 3px var(--pm-accent-soft);
}

.pm-modal-foot {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px 18px;
  border-top: 1px solid var(--pm-border);
  background: #f8fafc;
}

.pm-modal-box:has(.pm-bulk-report) {
  max-width: 760px;
}

.pm-modal-foot .pm-btn,
.pm-modal-foot .duplicate-sync-btn {
  min-height: 36px;
}

.pm-source-modal {
  max-width: 520px;
}

.pm-modal-subtitle {
  margin: 3px 0 0;
  font-size: 11px;
  color: #9ca3af;
}

.pm-source-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pm-source-option {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px;
  border: 1px solid var(--pm-border);
  border-radius: 8px;
  background: #fff;
  text-align: left;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}

.pm-source-option:hover {
  border-color: var(--pm-accent);
  background: #faf8ff;
}

.pm-source-option>i {
  margin-left: auto;
  color: #90CAF9;
  font-size: 12px;
}

.pm-source-option-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 2px;
}

.pm-source-option-copy strong {
  color: #111827;
  font-size: 12px;
}

.pm-source-option-copy small {
  overflow: hidden;
  color: #9ca3af;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pm-source-back {
  align-self: flex-start;
  padding: 0 0 4px;
  border: 0;
  background: none;
  color: var(--pm-accent);
  font-size: 12px;
  cursor: pointer;
}

.pm-source-back:hover {
  color: #6d28d9;
}

.pm-duplicate-modal {
  z-index: 1100;
}

.pm-duplicate-modal-box {
  width: 100%;
  max-width: 580px;
  max-height: 86vh;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.25);
  transition: max-width 0.25s ease;
}

.pm-duplicate-modal-box.is-synced {
  max-width: 1060px;
}

.pm-duplicate-subtitle {
  margin: 2px 0 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 400;
}

.pm-duplicate-modal-box .pm-modal-head {
  padding: 16px 24px;
}

.pm-duplicate-modal-box .pm-modal-foot {
  padding: 14px 24px;
}

.pm-duplicate-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 20px 24px;
  overflow-y: auto;
  max-height: calc(86vh - 125px);
}

.pm-duplicate-cols {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 20px;
  align-items: start;
  width: 100%;
}

@media (max-width: 860px) {
  .pm-duplicate-cols {
    grid-template-columns: 1fr;
  }
}

.pm-duplicate-col-left,
.pm-duplicate-col-right {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.pm-duplicate-source-card {
  padding: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
}

.pm-duplicate-section-label {
  margin-bottom: 6px;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.pm-duplicate-source-main {
  display: flex;
  align-items: center;
  min-width: 0;
}

.pm-duplicate-source-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 4px;
}

.pm-duplicate-source-line {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.pm-duplicate-source-line strong {
  overflow: hidden;
  color: #0f172a;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pm-duplicate-product-name {
  overflow: hidden;
  color: #334155;
  font-size: 13px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pm-duplicate-sku {
  color: #64748b;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
}

.pm-duplicate-target {
  padding: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
}

.pm-duplicate-target-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid #f1f5f9;
}

.pm-duplicate-target-head p {
  margin: 0;
  color: #64748b;
  font-size: 12px;
}

.pm-duplicate-target-head strong {
  color: var(--pm-accent);
  font-weight: 600;
}

.pm-duplicate-add {
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  border-radius: 8px;
  color: #fff;
  background: var(--pm-accent);
  border: 1px solid var(--pm-accent);
}

.pm-duplicate-add:hover {
  background: #0D47A1;
  border-color: #0D47A1;
  color: #fff;
}

.pm-duplicate-add i {
  color: inherit;
}

.pm-duplicate-store-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 480px;
  padding-top: 10px;
  overflow-y: auto;
}

.pm-duplicate-store-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px;
  background: #ffffff;
  transition: border-color 0.15s;
}

.pm-duplicate-store-card:hover {
  border-color: #cbd5e1;
}

.pm-duplicate-store-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pm-duplicate-store-select {
  width: 100%;
  height: 38px;
  padding: 0 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  font-size: 12px;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.pm-duplicate-store-select:focus {
  border-color: var(--pm-accent);
  box-shadow: 0 0 0 2px #90CAF9;
}

.pm-duplicate-select2-container {
  width: 100% !important;
}

.pm-duplicate-select2-container .select2-selection--single {
  display: flex !important;
  align-items: center;
  height: 38px !important;
  border-radius: 7px !important;
}

.pm-duplicate-select2-container.select2-container--focus .select2-selection--single,
.pm-duplicate-select2-container.select2-container--open .select2-selection--single {
  border-color: var(--pm-accent) !important;
  box-shadow: 0 0 0 2px #90CAF9 !important;
}

.pm-duplicate-select2-container .select2-selection__rendered {
  padding-left: 10px !important;
  color: #374151 !important;
  font-size: 12px !important;
  line-height: 36px !important;
}

.pm-duplicate-select2-container .select2-selection__placeholder {
  color: #94a3b8 !important;
}

.pm-duplicate-select2-container .select2-selection__arrow {
  top: 5px !important;
  right: 5px !important;
  height: 28px !important;
}

.pm-duplicate-select2-dropdown {
  z-index: 1200 !important;
}

.pm-duplicate-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
}

.pm-duplicate-remove:hover {
  background: #fef2f2;
  color: #dc2626;
}

.pm-duplicate-modal-foot {
  justify-content: flex-end;
  flex-wrap: wrap;
}

.pm-modal-marketplace-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border-radius: 0px !important;
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.2;
}

.pm-modal-marketplace-badge.Shopee {
  color: #c2410c;
  background: #ffedd5;
  border: 1px solid #fed7aa;
}

.pm-modal-marketplace-badge.Tiktok {
  color: #111827;
  background: #f3f4f6;
  border: 1px solid var(--pm-border);
}

.pm-target-marketplace {
  color: var(--pm-accent);
  font-size: 12px;
  font-weight: 500;
}

.duplicate-sync-state {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid #cbd5e1;
  color: #334155;
  background: #fff;
}

.duplicate-sync-state.syncing {
  color: #1e40af;
}

.duplicate-sync-state.ready {
  color: #15803d;
}

.duplicate-sync-state.error {
  color: #b91c1c;
}

.duplicate-sync-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 13px;
  border: 1px solid var(--pm-accent);
  border-radius: 8px;
  background: var(--pm-accent);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition: background .15s, border-color .15s, box-shadow .15s;
}

.duplicate-sync-btn:hover {
  border-color: #334155;
  background: #334155;
  box-shadow: 0 2px 5px rgba(15, 23, 42, .12);
}

.duplicate-sync-btn:disabled {
  opacity: .55;
  cursor: not-allowed;
  box-shadow: none;
}

.duplicate-sync-btn i {
  font-size: 12px;
}

.btnSubmitDuplicateProductStore {
  min-height: 36px;
  font-size: 13px;
  font-weight: 600;
}

.duplicate-cancel-btn {
  min-height: 36px;
  font-size: 13px;
  font-weight: 500;
}

/* Modal Preview & On-the-Fly Edit Section */
.pm-duplicate-preview-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 14px;
  margin-top: 0;
}

.pm-duplicate-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.pm-duplicate-preview-title {
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
  display: flex;
  align-items: center;
  gap: 6px;
}

.pm-badge-synced {
  font-size: 11px;
  font-weight: 700;
  color: #02140f;
  background: #00ff7d;
  border: 1px solid #00cc64;
  border-radius: 999px;
  padding: 2px 8px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.pm-duplicate-preview-note {
  margin: 0 0 10px;
  font-size: 11px;
  color: #64748b;
}

.pm-duplicate-preview-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
}

@media (max-width: 560px) {
  .pm-duplicate-preview-grid {
    grid-template-columns: 1fr;
  }
}

.pm-duplicate-field-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pm-duplicate-field-label {
  font-size: 11px;
  font-weight: 600;
  color: #475569;
}

.pm-duplicate-field-input {
  width: 100%;
  padding: 8px 10px;
  font-size: 13px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #ffffff;
  color: #0f172a;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.pm-duplicate-field-input:focus {
  border-color: var(--pm-accent);
  box-shadow: 0 0 0 3px var(--pm-accent-soft);
}

.pm-duplicate-details-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding-top: 10px;
  border-top: 1px dashed #cbd5e1;
}

.pm-duplicate-detail-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  font-size: 11px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  color: #334155;
}

.pm-chip-has-video {
  color: #02140f !important;
  background: #00ff7d !important;
  border-color: #00cc64 !important;
  font-weight: 700;
}

.pm-chip-no-video {
  color: #334155 !important;
  background: #fff !important;
  border-color: #cbd5e1 !important;
}

.pm-duplicate-img-thumbs {
  display: flex;
  gap: 6px;
  margin-top: 8px;
  overflow-x: auto;
}

.pm-duplicate-img-thumb {
  width: 38px;
  height: 38px;
  border-radius: 6px;
  object-fit: cover;
  border: 1px solid #cbd5e1;
  flex-shrink: 0;
}

/* Rich Editor Toolbar & Textarea */
.pm-duplicate-editor-box {
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  overflow: hidden;
  background: #ffffff;
}

.pm-duplicate-editor-toolbar {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  background: #f1f5f9;
  border-bottom: 1px solid #e2e8f0;
}

.pm-duplicate-editor-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  background: #ffffff;
  color: #475569;
  font-size: 11px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.pm-duplicate-editor-btn:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.pm-duplicate-textarea {
  width: 100%;
  min-height: 110px;
  max-height: 220px;
  padding: 8px 10px;
  font-size: 12px;
  border: 0;
  outline: none;
  resize: vertical;
  line-height: 1.5;
  font-family: inherit;
}

.pm-duplicate-wysiwyg {
  width: 100%;
  min-height: 110px;
  max-height: 220px;
  padding: 8px 10px;
  font-size: 12px;
  border: 0;
  outline: none;
  overflow-y: auto;
  resize: vertical;
  line-height: 1.5;
  font-family: inherit;
  background: #ffffff;
}

.pm-duplicate-wysiwyg img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  margin: 4px 0;
  display: block;
}

/* Variant Models Edit Table */
.pm-duplicate-models-box {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  overflow: hidden;
  margin-bottom: 10px;
}

.pm-duplicate-models-title {
  font-size: 11px;
  font-weight: 700;
  color: #475569;
  padding: 6px 10px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.pm-duplicate-models-list {
  max-height: 160px;
  overflow-y: auto;
}

.pm-duplicate-model-row {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 8px;
  align-items: center;
  padding: 6px 10px;
  border-bottom: 1px solid #f1f5f9;
}

.pm-duplicate-model-row:last-child {
  border-bottom: none;
}

.pm-duplicate-model-name {
  font-size: 11px;
  font-weight: 600;
  color: #334155;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* TikTok Listing Platforms Box */
.pm-duplicate-platforms-box {
  margin-top: 10px;
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pm-duplicate-platforms-header {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.pm-duplicate-platforms-options {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pm-duplicate-platform-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  color: #334155;
  cursor: pointer;
  transition: all 0.15s;
  user-select: none;
}

.pm-duplicate-platform-chip.is-selected {
  border-color: var(--pm-accent);
  background: var(--pm-accent);
  color: #fff;
}

.pm-duplicate-platform-chip input {
  width: 14px;
  height: 14px;
  accent-color: var(--pm-accent);
}

/* Logistics Box per Store */
.pm-duplicate-logistics-box {
  margin-top: 8px;
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pm-duplicate-logistics-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid #e2e8f0;
}

.pm-duplicate-logistics-title {
  font-size: 11px;
  font-weight: 700;
  color: #334155;
  display: flex;
  align-items: center;
  gap: 6px;
}

.pm-duplicate-sync-logistic-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--pm-accent);
  background: #fff;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.pm-duplicate-sync-logistic-btn:hover {
  background: #E3F2FD;
  border-color: #90CAF9;
  color: #6d28d9;
}

.pm-duplicate-logistics-toggle-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.pm-duplicate-toggle-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}

.pm-duplicate-toggle-checkbox {
  width: 15px;
  height: 15px;
  accent-color: var(--pm-accent);
  cursor: pointer;
}

.pm-duplicate-toggle-text {
  font-size: 11px;
  font-weight: 600;
  color: #475569;
}

.pm-duplicate-logistics-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 180px;
  overflow-y: auto;
  padding-top: 4px;
  border-top: 1px dashed #cbd5e1;
}

.pm-duplicate-logistic-group {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.pm-duplicate-logistic-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: #334155;
  cursor: pointer;
  padding: 5px 8px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  transition: all 0.15s;
}

.pm-duplicate-logistic-item:hover {
  border-color: #cbd5e1;
  background: #ffffff;
}

.pm-duplicate-logistic-item.is-selected {
  border-color: var(--pm-accent);
  background: var(--pm-accent);
  font-weight: 600;
  color: #fff;
}

.pm-duplicate-logistic-item input {
  width: 14px;
  height: 14px;
  accent-color: var(--pm-accent);
}

.pm-duplicate-logistic-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pm-duplicate-logistic-children {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding-left: 24px;
  padding-top: 2px;
}

.pm-duplicate-logistic-child-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  font-size: 10px;
  color: #64748b;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  opacity: 0.7;
}

.pm-duplicate-logistic-child-badge.is-active {
  color: #fff;
  background: var(--pm-accent);
  border-color: var(--pm-accent);
  opacity: 1;
  font-weight: 600;
}

.pm-duplicate-logistics-empty {
  font-size: 11px;
  color: #64748b;
  padding: 6px 0;
  font-style: italic;
}

.pm-bulk-report {
  min-width: 0;
}

@media (min-width: 640px) {
  .pm-bulk-report {
    min-width: 640px;
  }
}

.pm-bulk-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #374151;
}

.pm-bulk-form input,
.pm-bulk-form select {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--pm-border);
  border-radius: 6px;
  font-size: 13px;
}

.pm-bulk-status-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.pm-bulk-platforms-label {
  margin-top: 8px;
}

.pm-bulk-price-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 260px;
  overflow-y: auto;
  padding: 2px;
}

.pm-bulk-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border: 1px solid var(--pm-border);
  border-radius: 8px;
  background: #fff;
}

.pm-bulk-price-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  font-size: 12px;
}

.pm-bulk-price-meta .pm-cell-sub {
  font-size: 11px;
}

.pm-bulk-price-row input {
  width: 140px;
  flex: 0 0 140px;
}

.pm-bulk-current {
  margin-bottom: 14px;
  border: 1px solid var(--pm-border);
  border-radius: 10px;
  overflow: hidden;
}

.pm-bulk-current-head {
  display: flex;
  justify-content: space-between;
  padding: 8px 10px;
  background: #fafafa;
  border-bottom: 1px solid #f3f4f6;
  color: #6b7280;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .02em;
}

.pm-bulk-current-list {
  max-height: 190px;
  overflow-y: auto;
}

.pm-bulk-current-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 10px;
  border-bottom: 1px solid #f3f4f6;
  font-size: 12px;
}

.pm-bulk-current-row:last-child {
  border-bottom: none;
}

.pm-bulk-current-row strong,
.pm-bulk-current-row span {
  display: block;
}

.pm-bulk-current-row>div:first-child span {
  margin-top: 2px;
  color: #9ca3af;
  font-size: 11px;
}

.pm-bulk-current-values {
  display: flex;
  gap: 10px;
  color: #374151;
  white-space: nowrap;
}

.pm-edit-current {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  padding: 9px 10px;
  border: 1px solid var(--pm-border);
  border-radius: 8px;
  background: #fafafa;
  font-size: 12px;
  color: #6b7280;
}

.pm-edit-current strong {
  color: #111827;
  font-size: 14px;
}

.pm-edit-sync-state {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 12px;
  padding: 9px 10px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  background: #fff;
  color: #334155;
  font-size: 12px;
  font-weight: 600;
}

.pm-edit-sync-state.syncing {
  color: #1e40af;
}

.pm-edit-sync-state.ready {
  color: #15803d;
}

.pm-edit-sync-state.error {
  color: #b91c1c;
}

/* Single Modal Stock Distribution Option Card */
.pm-single-dist-toggle-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 14px 0;
  padding: 12px 14px;
  background: #fbfbfe;
  border: 1px solid #e0e7ff;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.pm-single-dist-toggle-card:hover {
  background: #f5f3ff;
  border-color: #c7d2fe;
}

.pm-single-dist-toggle-card input[type="checkbox"] {
  margin-top: 2px;
  width: 17px;
  height: 17px;
  accent-color: #2196F3;
  border-radius: 4px;
  cursor: pointer;
  flex-shrink: 0;
}

.pm-single-dist-toggle-content {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.pm-single-dist-toggle-title {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  font-weight: 600;
  color: #1e1b4b;
}

.pm-single-dist-toggle-desc {
  margin: 0;
  font-size: 11.5px;
  color: #64748b;
  line-height: 1.35;
}

/* Dual platform status chip for TikTok & Tokopedia - Pixel Perfect Capsule */
.pm-tiktok-statuses-stack {
  display: flex;
  flex-direction: column;
  gap: 3px;
  align-items: flex-start;
  margin-top: 3px;
}

.pm-platform-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 999px;
}

.pm-platform-badge strong {
  font-weight: 700;
  opacity: 0.9;
}

/* ============ RESPONSIVE ============ */

/* tablet: actions drop below identity+stats */
@media (max-width: 900px) {
  .pm-row-top {
    grid-template-columns: 48px minmax(0, 1fr) auto;
    grid-template-areas:
      "thumb identity stats"
      "thumb actions  actions";
  }

  .pm-row-top .pm-thumb,
  .pm-row-top .pm-thumb-empty {
    align-self: start;
  }

  .pm-row-top .pm-actions {
    justify-content: flex-start;
    margin-top: 4px;
  }

  .pm-overview {
    grid-template-columns: 160px minmax(0, 1fr);
  }

  .pm-hero-img,
  .pm-hero-empty {
    width: 160px;
    height: 160px;
  }

  .pm-info-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* mobile: single column stack */
@media (max-width: 560px) {
  .pm-title {
    font-size: 18px;
  }

  .pm-toolbar {
    gap: 8px;
  }

  .pm-select {
    flex: 1 1 auto;
    width: 100%;
  }

  .pm-search {
    flex: 1 1 100%;
  }

  .pm-row-top {
    grid-template-columns: 44px minmax(0, 1fr);
    grid-template-areas:
      "thumb identity"
      "stats stats"
      "actions actions";
    gap: 10px 12px;
  }

  .pm-thumb,
  .pm-thumb-empty {
    width: 44px;
    height: 44px;
  }

  .pm-stats {
    justify-content: space-between;
    gap: 12px;
    padding-top: 4px;
    border-top: 1px solid #f3f4f6;
  }

  .pm-stat {
    flex: 1;
    text-align: left;
  }

  .pm-actions {
    justify-content: stretch;
  }

  .pm-actions .pm-btn {
    flex: 1;
    justify-content: center;
  }

  /* detail header stacks */
  .pm-detail-head {
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-areas:
      "back identity"
      "summary summary";
    gap: 12px;
  }

  .pm-back {
    grid-area: back;
  }

  .pm-detail-head .pm-identity {
    grid-area: identity;
  }

  .pm-summary {
    grid-area: summary;
    width: 100%;
  }

  .pm-summary-cell {
    flex: 1;
  }

  .pm-foot {
    flex-direction: column;
    align-items: stretch;
  }

  .pm-pager {
    justify-content: center;
  }

  /* overview stacks */
  .pm-overview {
    grid-template-columns: 1fr;
  }

  .pm-hero-img,
  .pm-hero-empty {
    max-width: 100%;
    aspect-ratio: 16 / 10;
  }

  .pm-info-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 12px;
  }

  .pm-bulk-toolbar .pm-btn {
    flex: 1 1 auto;
  }

  .pm-list-toolbar {
    align-items: stretch;
    flex-wrap: wrap;
    gap: 8px 12px;
    min-height: 0;
    padding: 0;
  }

  .pm-list-toolbar .pm-select-all {
    flex: 1 1 100%;
    padding: 0 0 8px;
    border-right: 0;
    border-bottom: 1px solid var(--pm-border);
  }

  .pm-list-toolbar .pm-btn {
    flex: 1 1 auto;
  }

  .pm-bulk-report {
    min-width: 0;
  }

  .pm-sync-progress-summary {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .pm-sync-error {
    max-width: 130px;
  }

  .pm-bulk-current-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }

  .pm-bulk-current-values {
    flex-wrap: wrap;
    gap: 6px 10px;
    white-space: normal;
  }

  .pm-duplicate-target-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .pm-duplicate-add {
    width: 100%;
    justify-content: center;
  }

  .pm-duplicate-modal-foot {
    align-items: stretch;
    flex-direction: column;
  }

  .pm-duplicate-modal-foot .pm-btn,
  .pm-duplicate-modal-foot .duplicate-sync-btn {
    width: 100%;
    justify-content: center;
  }
}

/* large monitors: denser attribute grid, keep content readable (capped by .pm-wrap) */
@media (min-width: 1280px) {
  .pm-info-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .pm-overview {
    grid-template-columns: 260px minmax(0, 1fr);
  }

  .pm-hero-img,
  .pm-hero-empty {
    max-width: 260px;
  }
}

/* Enhanced Informative Bulk Stock Modal */
.pm-modal-box.pm-bulk-modal-box {
  max-width: 1040px;
  width: 96vw;
}

.pm-modal-box.pm-global-sku-modal-box {
  max-width: 1380px;
  width: 97vw;
}

.pm-bulk-action-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 10px 14px;
  background: #fafbfc;
  border: 1px solid #f1f5f9;
  border-radius: 10px;
  margin-bottom: 14px;
}

.pm-bulk-stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  background: #ffffff;
  border: 1px solid #f1f5f9;
  border-radius: 8px;
  font-size: 12px;
  color: #334155;
  font-weight: 500;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
}

.pm-bulk-stat-pill strong {
  color: #0f172a;
  font-weight: 700;
}

.pm-segmented-control {
  display: inline-flex;
  background: #f1f5f9;
  padding: 2.5px;
  border-radius: 8px;
}

.pm-segmented-btn {
  border: none;
  background: transparent;
  padding: 5px 12px;
  font-size: 11.5px;
  font-weight: 600;
  color: #64748b;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.pm-segmented-btn:hover {
  color: #334155;
}

.pm-segmented-btn.is-active {
  background: #ffffff;
  color: #0D47A1;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.pm-btn-violet {
  background: #2196F3;
  color: #ffffff;
  border: 1px solid #2196F3;
  font-weight: 600;
}

.pm-btn-violet:hover {
  background: #0D47A1;
  color: #ffffff;
}

.pm-bulk-stock-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid #f1f5f9;
  border-radius: 8px;
  overflow: hidden;
  background: #ffffff;
}

.pm-bulk-stock-table th {
  background: #f8fafc;
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 9px 12px;
  border-bottom: 1px solid #f1f5f9;
  white-space: nowrap;
}

.pm-bulk-stock-table td {
  padding: 8px 12px;
  border-bottom: 1px solid #f8fafc;
  font-size: 12px;
  vertical-align: middle;
  background: #ffffff;
}

.pm-bulk-stock-table tr:last-child td {
  border-bottom: none;
}

.pm-bulk-stock-tr:hover td {
  background: #fcfdfe;
}

.pm-bulk-stock-tr.pm-row-stock-warn td {
  background: #fffdf5 !important;
}

.pm-bulk-stock-tr.is-row-disabled td {
  opacity: 0.5;
  background: #fafbfc;
}

.pm-stock-input {
  width: 105px;
  padding: 5px 8px;
  font-size: 12.5px;
  font-weight: 600;
  color: #0f172a;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  text-align: right;
  transition: all 0.15s ease;
  background: #ffffff;
}

.pm-stock-input:focus {
  border-color: #2196F3;
  outline: none;
  box-shadow: 0 0 0 2.5px rgba(99, 102, 241, 0.12);
  background: #ffffff;
}

.pm-stock-input.is-auto-filled {
  border-color: #90CAF9;
  background: #faf5ff;
}

.pm-btn-icon-sm {
  width: 32px !important;
  height: 28px !important;
  min-width: 32px !important;
  padding: 0 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  border-radius: 6px !important;
  font-size: 13px !important;
  line-height: 1 !important;
}

/* ==========================================================================
   Activity Log — minimal audit-trail feed (single outer border, divider rows)
   2D flat: no shadow, 1px borders only
   ========================================================================== */
.pm-log-section {
  margin-top: 16px;
}

.pm-log-card {
  background: #fff;
  border: 1px solid var(--pm-border);
  border-radius: var(--pm-radius);
  overflow: hidden;
  box-shadow: none;
}

.pm-log-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-bottom: 1px solid #f1f5f9;
}

.pm-log-header h4 {
  font-size: 13px;
  font-weight: 600;
  color: #0f172a;
  margin: 0;
  display: flex;
  align-items: center;
}

.pm-log-header p {
  display: none;
}

.pm-log-filter-bar {
  display: flex;
  align-items: center;
  gap: 0;
  border-bottom: 1px solid #f1f5f9;
  padding: 0 12px;
  overflow-x: auto;
  margin: 0;
}

.pm-log-filter-btn {
  padding: 9px 10px;
  font-size: 11px;
  font-weight: 500;
  border: none;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: #64748b;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-bottom: -1px;
}

.pm-log-filter-btn:hover {
  color: #0f172a;
}

.pm-log-filter-btn.is-active {
  color: #0f172a;
  border-bottom-color: var(--pm-accent);
  font-weight: 600;
}

.pm-log-list {
  display: flex;
  flex-direction: column;
}

.pm-log-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  background: #fff;
  border-bottom: 1px solid #f1f5f9;
  transition: background 0.15s ease;
}

.pm-log-item:last-child {
  border-bottom: none;
}

.pm-log-item:hover {
  background: #f8fafc;
}

.pm-log-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.pm-log-time {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  color: #94a3b8;
  white-space: nowrap;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

.pm-log-time-date {
  font-weight: 500;
  color: #64748b;
}

.pm-log-time-hour {
  font-size: 11px;
  color: #94a3b8;
}

.pm-log-time-hour::before {
  content: "·";
  margin-right: 6px;
  color: #cbd5e1;
}

.pm-log-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 6px;
  font-size: 10px;
  font-weight: 600;
  border-radius: 4px;
  background: #f3f4f6;
  color: #475569;
  border: none;
  white-space: nowrap;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.pm-log-tag i {
  font-size: 10px;
  opacity: 0.7;
}

.pm-log-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
  gap: 1px;
}

.pm-log-title {
  font-size: 12px;
  font-weight: 500;
  color: #1e293b;
  margin: 0;
  line-height: 1.4;
  word-break: break-word;
}

.pm-log-user-info {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: #94a3b8;
  margin-top: 1px;
}

.pm-log-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.pm-log-status {
  font-size: 11px;
  font-weight: 500;
  color: #94a3b8;
  white-space: nowrap;
}

.pm-log-status.is-success {
  color: #059669;
}

.pm-log-status.is-partial {
  color: #b45309;
}

.pm-log-status.is-failed {
  color: #dc2626;
}

.pm-log-detail-link {
  font-size: 11px;
  font-weight: 500;
  color: #64748b;
  background: none;
  border: none;
  cursor: pointer;
  padding: 2px 6px;
}

.pm-log-detail-link:hover {
  color: var(--pm-accent);
}

.pm-log-empty {
  padding: 28px 16px;
  text-align: center;
  color: #94a3b8;
  font-size: 12px;
}

.pm-log-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  border-top: 1px solid #f3f4f6;
  font-size: 11px;
  color: #64748b;
  background: #fff;
}

/* Scope Info Banner */
.pm-scope-info-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  margin-top: 2px;
  margin-bottom: 16px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 11.5px;
  color: #334155;
  line-height: 1.4;
}

.pm-scope-info-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pm-scope-info-icon {
  color: #2563eb;
  font-size: 12px;
  flex-shrink: 0;
}

.pm-scope-info-left strong {
  color: #0f172a;
  font-weight: 600;
}

.pm-scope-info-tag {
  font-size: 10px;
  font-weight: 500;
  color: #64748b;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 2px 8px;
  border-radius: 12px;
  white-space: nowrap;
}

/* Bulk Table Store Cell */
.pm-bulk-store-cell {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.pm-bulk-store-header {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pm-bulk-store-count {
  font-size: 11px;
  font-weight: 500;
  color: #64748b;
  margin-left: 2px;
}

.pm-bulk-store-names {
  font-size: 11px;
  color: #64748b;
  line-height: 1.3;
}