.product-modal .range-picker {
  position: relative;
  margin-left: auto;
}

.product-modal .range-picker-trigger {
  min-width: 248px;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border-soft);
  background: color-mix(in srgb, var(--surface-2) 94%, white 6%);
}

.product-modal .range-picker-trigger:hover,
.product-modal .range-picker-trigger:focus-visible,
.product-modal .range-picker-trigger[aria-expanded="true"] {
  border-color: #C9DBD2;
  box-shadow: 0 0 0 3px rgba(45,95,78,.08);
  outline: none;
}

.product-modal .range-picker-trigger-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--ink-3);
  font-weight: 600;
}

.product-modal .range-picker-trigger-value {
  font-size: 13px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.product-modal .range-popover,
.product-modal-floating-range {
  width: min(320px, calc(100vw - 24px));
  padding: 14px;
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  border-radius: var(--r-lg);
  box-shadow: 0 16px 34px rgba(26,24,20,.12);
  display: none;
}

.product-modal .range-popover {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 25;
}

.product-modal-floating-range {
  position: fixed;
  z-index: 120;
}

.product-modal .range-popover.open,
.product-modal-floating-range.open {
  display: block;
}

.product-modal .range-popover-title,
.product-modal-floating-range .range-popover-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--ink-3);
  font-weight: 600;
  margin-bottom: 10px;
}

.product-modal .range-fields,
.product-modal-floating-range .range-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.product-modal .range-field,
.product-modal-floating-range .range-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  color: var(--ink-3);
}

.product-modal .range-field input,
.product-modal-floating-range .range-field input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--r);
  padding: 8px 10px;
  font: inherit;
  color: var(--ink);
  outline: none;
  min-height: 40px;
}

.product-modal .range-field input:focus,
.product-modal .range-field input.flatpickr-input.active,
.product-modal-floating-range .range-field input:focus,
.product-modal-floating-range .range-field input.flatpickr-input.active {
  border-color: #C9DBD2;
  box-shadow: 0 0 0 3px rgba(45,95,78,.10);
}

.product-modal .range-actions,
.product-modal-floating-range .range-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 12px;
}

.product-modal .flatpickr-calendar,
.product-modal-floating-range .flatpickr-calendar {
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  box-shadow: 0 18px 38px rgba(26,24,20,.16);
  font-family: var(--f-ui);
}

.product-modal .flatpickr-months .flatpickr-month,
.product-modal .flatpickr-current-month input.cur-year,
.product-modal .flatpickr-weekday,
.product-modal .flatpickr-day,
.product-modal-floating-range .flatpickr-months .flatpickr-month,
.product-modal-floating-range .flatpickr-current-month input.cur-year,
.product-modal-floating-range .flatpickr-weekday,
.product-modal-floating-range .flatpickr-day {
  color: var(--ink);
}

.product-modal .flatpickr-months .flatpickr-prev-month,
.product-modal .flatpickr-months .flatpickr-next-month,
.product-modal-floating-range .flatpickr-months .flatpickr-prev-month,
.product-modal-floating-range .flatpickr-months .flatpickr-next-month {
  fill: var(--ink-3);
}

.product-modal .flatpickr-current-month .flatpickr-monthDropdown-months,
.product-modal .flatpickr-current-month input.cur-year,
.product-modal-floating-range .flatpickr-current-month .flatpickr-monthDropdown-months,
.product-modal-floating-range .flatpickr-current-month input.cur-year {
  font-weight: 600;
}

.product-modal .flatpickr-day.selected,
.product-modal .flatpickr-day.startRange,
.product-modal .flatpickr-day.endRange,
.product-modal .flatpickr-day.selected.inRange,
.product-modal .flatpickr-day.startRange.inRange,
.product-modal .flatpickr-day.endRange.inRange,
.product-modal-floating-range .flatpickr-day.selected,
.product-modal-floating-range .flatpickr-day.startRange,
.product-modal-floating-range .flatpickr-day.endRange,
.product-modal-floating-range .flatpickr-day.selected.inRange,
.product-modal-floating-range .flatpickr-day.startRange.inRange,
.product-modal-floating-range .flatpickr-day.endRange.inRange {
  background: var(--accent);
  border-color: var(--accent);
}

.product-modal .flatpickr-day.inRange,
.product-modal-floating-range .flatpickr-day.inRange {
  background: color-mix(in srgb, var(--accent-soft) 82%, white 18%);
  border-color: color-mix(in srgb, var(--accent-soft) 82%, white 18%);
  box-shadow: -5px 0 0 color-mix(in srgb, var(--accent-soft) 82%, white 18%), 5px 0 0 color-mix(in srgb, var(--accent-soft) 82%, white 18%);
}

.product-modal .flatpickr-day:hover,
.product-modal-floating-range .flatpickr-day:hover {
  background: var(--accent-tint);
  border-color: var(--accent-tint);
}

.product-modal .flatpickr-day.today,
.product-modal-floating-range .flatpickr-day.today {
  border-color: var(--accent-soft);
}

.product-modal .flatpickr-day.today:hover,
.product-modal .flatpickr-day.today:focus,
.product-modal-floating-range .flatpickr-day.today:hover,
.product-modal-floating-range .flatpickr-day.today:focus {
  background: var(--accent-tint);
  border-color: var(--accent-soft);
}

.product-modal .sort-head {
  background: transparent;
  border: 0;
  padding: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.product-modal .sort-head::after {
  content: "↕";
  font-size: 11px;
  color: var(--ink-4);
}

.product-modal .sort-head.active {
  color: var(--ink);
}

.sort-head {
  background: transparent;
  border: 0;
  padding: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.sort-head::after {
  content: "\2195";
  font-size: 11px;
  color: var(--ink-4);
}

.sort-head[data-sort-dir="asc"]::after {
  content: "\2191";
}

.sort-head[data-sort-dir="desc"]::after {
  content: "\2193";
}

.sort-head.active {
  color: var(--ink);
}

.floating-action-popover {
  position: fixed;
  min-width: 214px;
  padding: 8px;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  background: color-mix(in srgb, var(--surface-2) 92%, white 8%);
  box-shadow: 0 20px 42px rgba(26,24,20,.16);
  backdrop-filter: blur(10px);
  display: grid;
  gap: 4px;
  z-index: 120;
}

.floating-action-popover[hidden] {
  display: none;
}

.floating-action-popover[data-placement="top"] {
  transform-origin: bottom right;
}

.floating-action-popover[data-placement="bottom"] {
  transform-origin: top right;
}

.th-head {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  position: relative;
  white-space: nowrap;
}

.metric-help {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}

.metric-help-trigger {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1px solid var(--border-soft);
  background: var(--surface-2);
  color: var(--ink-4);
  display: inline-grid;
  place-items: center;
  padding: 0;
  font-family: var(--f-mono);
  font-size: 9px;
  line-height: 1;
  text-transform: none;
  letter-spacing: 0;
  cursor: help;
  transition: background .12s ease, border-color .12s ease, color .12s ease;
}

.metric-help-trigger:hover,
.metric-help-trigger:focus-visible {
  background: var(--bg);
  border-color: var(--border);
  color: var(--ink);
  outline: none;
}

.metric-help-popover {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: min(290px, calc(100vw - 48px));
  padding: 12px 14px;
  border: 1px solid var(--border-soft);
  border-radius: var(--r);
  background: var(--surface-2);
  box-shadow: 0 12px 30px rgba(26,24,20,.12);
  color: var(--ink-2);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .16s ease, transform .16s ease, visibility .16s ease;
  pointer-events: none;
  z-index: 18;
  text-transform: none;
  letter-spacing: normal;
  font-weight: 400;
  white-space: normal;
}

.metric-help-popover::before {
  content: "";
  position: absolute;
  top: -6px;
  left: 18px;
  width: 12px;
  height: 12px;
  background: var(--surface-2);
  border-left: 1px solid var(--border-soft);
  border-top: 1px solid var(--border-soft);
  transform: rotate(45deg);
}

.metric-help-popover::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: 10px;
}

.metric-help.is-end .metric-help-popover {
  left: auto;
  right: 0;
}

.metric-help.is-end .metric-help-popover::before {
  left: auto;
  right: 18px;
}

.metric-help:hover .metric-help-popover,
.metric-help:focus-within .metric-help-popover {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.metric-help-popover-title {
  display: block;
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-3);
  font-weight: 500;
  margin-bottom: 6px;
}

.metric-help-popover-text {
  display: block;
  font-size: 12px;
  line-height: 1.45;
  color: var(--ink-2);
}

.product-modal-overlay {
  position: fixed;
  inset: 0;
  padding: 24px;
  background: rgba(17, 18, 15, .28);
  backdrop-filter: blur(4px);
  display: grid;
  place-items: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .18s ease, visibility .18s ease;
  z-index: 70;
}

.product-modal-overlay.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.product-modal {
  width: min(1240px, calc(100vw - 48px));
  max-height: calc(100vh - 48px);
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  border-radius: 22px;
  box-shadow: 0 28px 60px rgba(18, 18, 14, .18);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform: translateY(14px);
  transition: transform .18s ease;
}

.product-modal-overlay.open .product-modal {
  transform: translateY(0);
}

.product-modal-head {
  padding: 22px 26px 18px;
  border-bottom: 1px solid var(--border-soft);
  background: linear-gradient(180deg, rgba(251,249,244,.96) 0%, rgba(247,243,234,.94) 100%);
}

.product-modal-meta {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--ink-4);
  font-weight: 500;
  margin-bottom: 10px;
}

.product-modal-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.product-modal-title {
  margin: 0;
  font-size: 32px;
  line-height: 1.04;
  font-weight: 350;
  color: var(--ink);
  font-variation-settings: "opsz" 48, "wght" 350;
}

.product-modal-sub {
  margin-top: 6px;
  font-size: 13px;
  color: var(--ink-3);
}

.product-modal-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border-soft);
  background: var(--surface-2);
  color: var(--ink-3);
  font-size: 18px;
  line-height: 1;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
}

.product-modal-close:hover {
  background: var(--bg);
  color: var(--ink);
  border-color: var(--border);
}

.product-metric-tabs,
.product-view-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.product-metric-tab,
.product-view-tab {
  border: 1px solid var(--border-soft);
  border-radius: var(--r);
  background: var(--surface-2);
  color: var(--ink-3);
  padding: 7px 11px;
  font-size: 12px;
  font-weight: 500;
}

.product-metric-tab:hover,
.product-view-tab:hover {
  color: var(--ink);
  border-color: var(--border);
}

.product-metric-tab.active,
.product-view-tab.active {
  background: var(--bg);
  color: var(--ink);
  border-color: var(--border);
}

.product-modal-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.product-modal-trend-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.product-modal-trend-controls[hidden] {
  display: none !important;
}

.product-modal-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-left: auto;
}

.store-picker {
  position: relative;
}

.store-picker-trigger {
  min-width: 220px;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.store-picker-trigger::after {
  content: "▾";
  font-size: 11px;
  color: var(--ink-4);
}

.store-picker-trigger.btn.btn-ghost {
  min-width: 220px;
  min-height: 36px;
  padding: 8px 12px;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid var(--border-soft);
  border-radius: var(--r);
  background: var(--surface-2);
  color: var(--ink-2);
  font-size: 12.5px;
  line-height: 1.2;
  text-align: left;
  white-space: nowrap;
}

.store-picker-trigger.btn.btn-ghost:hover,
.store-picker-trigger.btn.btn-ghost[aria-expanded="true"] {
  background: var(--bg);
  color: var(--ink);
  border-color: var(--border);
}

.store-picker-trigger.btn.btn-ghost::after {
  content: "\25BE";
  flex-shrink: 0;
  font-size: 11px;
  color: var(--ink-4);
}

.store-picker-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 320px;
  padding: 14px;
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  border-radius: var(--r-lg);
  box-shadow: 0 16px 34px rgba(26,24,20,.12);
  display: none;
  z-index: 26;
}

.store-picker-panel.open {
  display: block;
}

.store-picker-search {
  min-height: 34px;
  font-size: 12.5px;
  margin-bottom: 10px;
}

.store-picker-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.store-picker-action {
  background: transparent;
  border: 0;
  padding: 0;
  color: var(--ink-3);
  font-size: 12px;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.store-picker-action:hover {
  color: var(--ink);
}

.store-picker-selected {
  font-size: 12px;
  color: var(--ink-3);
  margin-bottom: 10px;
}

.store-picker-list {
  display: grid;
  gap: 4px;
  max-height: 240px;
  overflow: auto;
  padding-right: 2px;
}

.store-picker-option {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 4px;
  border-radius: var(--r);
}

.store-picker-option:hover {
  background: var(--bg);
}

.store-picker-option input {
  margin: 2px 0 0;
  accent-color: #2D5F4E;
}

.store-picker-option-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.store-picker-option-name {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink);
}

.store-picker-sales-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  background: var(--border);
  flex: 0 0 auto;
}

.store-picker-sales-dot.has-sales {
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(45,95,78,.12);
}

.store-picker-sales-dot.is-hidden {
  opacity: 0;
  box-shadow: none;
}

.store-picker-option-meta {
  font-size: 11px;
  color: var(--ink-4);
}

.product-modal-body {
  padding: 22px 26px 26px;
  overflow-y: auto;
  overflow-x: hidden;
  max-height: calc(100vh - 210px);
}

.product-modal-panel[hidden] {
  display: none !important;
}

.product-modal-card {
  border: 1px solid var(--border-soft);
  border-radius: 18px;
  background: var(--surface);
  padding: 18px;
}

.product-modal-card-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.product-modal-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 1fr));
  gap: 10px;
  min-width: 360px;
}

.product-modal-kpi {
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  padding: 8px 12px 7px;
}

.product-modal-kpi-label {
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--ink-4);
  line-height: 1.1;
  margin-bottom: 4px;
}

.product-modal-kpi-value {
  font-size: 16px;
  line-height: 1.1;
  font-weight: 500;
  color: var(--ink);
}

.product-modal-chart {
  width: 100%;
  height: 320px;
  display: block;
  position: relative;
  overflow: hidden;
}

.product-panel-loader {
  height: 100%;
  display: grid;
  align-content: center;
  gap: 12px;
  padding: 22px;
}

.product-loading-hint {
  position: relative;
  margin-top: 6px;
  width: min(620px, 74%);
  min-height: 34px;
  display: flex;
  align-items: center;
  padding: 0 16px;
  border-radius: 999px;
  overflow: hidden;
  background: linear-gradient(90deg, rgba(230,224,210,.75) 0%, rgba(251,249,244,.97) 50%, rgba(230,224,210,.75) 100%);
  background-size: 240% 100%;
  animation: productSkeletonPulse 1.1s ease-in-out infinite, productLoadingHintFadeIn .22s ease-out both;
}

.product-loading-hint::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(250,247,240,.94) 0%, rgba(247,243,234,.88) 100%);
  opacity: .96;
}

.product-loading-hint::before {
  content: "";
  position: absolute;
  inset: 0;
  width: 38%;
  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,.42) 50%, rgba(255,255,255,0) 100%);
  transform: translateX(-140%);
  animation: productLoadingHintSweep 1.8s ease-in-out infinite;
  z-index: 1;
}

.product-loading-hint-text {
  position: relative;
  z-index: 2;
  color: color-mix(in srgb, var(--ink-3) 90%, var(--ink-2) 10%);
  font-size: 12.5px;
  line-height: 1.35;
  letter-spacing: .01em;
  font-weight: 450;
}

@keyframes productLoadingHintSweep {
  from {
    transform: translateX(-140%);
  }

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

@keyframes productLoadingHintFadeIn {
  from {
    opacity: 0;
    transform: translateY(4px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.product-panel-loader-bar,
.table-skeleton-line {
  display: block;
  overflow: hidden;
  max-width: 100%;
  height: 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(230,224,210,.75) 0%, rgba(251,249,244,.96) 50%, rgba(230,224,210,.75) 100%);
  background-size: 240% 100%;
  animation: productSkeletonPulse 1.1s ease-in-out infinite;
}

.product-panel-loader-bar-lg,
.table-skeleton-line-lg {
  height: 16px;
}

.product-panel-loader-bar:nth-child(1) {
  width: 72%;
}

.product-panel-loader-bar:nth-child(2) {
  width: 100%;
}

.product-panel-loader-bar:nth-child(3) {
  width: 88%;
}

.catalog-table-wrap {
  position: relative;
}

.catalog-table-wrap.is-loading-page .data-table tbody {
  opacity: 0.24;
  transition: opacity .18s ease;
}

.catalog-table-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 56px 18px 18px;
  background: linear-gradient(180deg, rgba(246,243,236,.34) 0%, rgba(246,243,236,.72) 100%);
  backdrop-filter: blur(2px);
  z-index: 6;
}

.catalog-table-overlay[hidden] {
  display: none !important;
}

.catalog-table-overlay-card {
  width: min(520px, calc(100% - 8px));
  padding: 14px 16px 16px;
  border: 1px solid var(--border-soft);
  border-radius: var(--r-lg);
  background: rgba(251,249,244,.96);
  box-shadow: 0 16px 34px rgba(26,24,20,.10);
  display: grid;
  gap: 12px;
}

.catalog-loading-shell {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  padding: 8px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: rgba(255,255,255,.76);
  color: var(--ink-3);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
}

.catalog-loading-dots {
  display: inline-flex;
  gap: 5px;
}

.catalog-loading-dots span {
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: var(--accent);
  opacity: .34;
  animation: catalogLoaderDotPulse 1s ease-in-out infinite;
}

.catalog-loading-dots span:nth-child(2) {
  animation-delay: .14s;
}

.catalog-loading-dots span:nth-child(3) {
  animation-delay: .28s;
}

.catalog-table-overlay-lines {
  display: grid;
  gap: 10px;
}

.catalog-table-overlay-line {
  height: 12px;
  border-radius: 999px;
}

.catalog-table-overlay-line:nth-child(1) {
  width: 78%;
}

.catalog-table-overlay-line:nth-child(2) {
  width: 100%;
}

.catalog-table-overlay-line:nth-child(3) {
  width: 88%;
}

.catalog-table-skeleton-row td {
  padding: 13px 12px 13px 0;
  border-bottom: 1px solid var(--border-soft);
}

.catalog-table-skeleton-row td:first-child {
  padding-left: 8px;
}

.catalog-table-skeleton-xs {
  width: 42px;
}

.catalog-table-skeleton-sm {
  width: 68px;
}

.catalog-table-skeleton-md {
  width: 108px;
}

.catalog-table-skeleton-lg {
  width: 168px;
}

.catalog-table-skeleton-xl {
  width: 240px;
}

.catalog-table-skeleton-action {
  width: 84px;
  height: 28px;
  border-radius: 8px;
}

.catalog-table-skeleton-meta {
  display: inline-block;
  width: 112px;
  height: 10px;
}

.table-loading-row td {
  padding-top: 14px;
  padding-bottom: 14px;
}

.product-chart-grid {
  stroke: rgba(164, 153, 130, .28);
  stroke-width: 1;
}

.product-modal-chart svg {
  width: 100%;
  height: 100%;
  display: block;
}

.product-chart-axis {
  fill: var(--ink-4);
  font-size: 10px;
}

.product-chart-line {
  fill: none;
  stroke-width: 2.25;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: .96;
}

.product-chart-focus-group {
  opacity: 0;
  transition: opacity .12s ease;
  pointer-events: none;
}

.product-chart-focus-group.active {
  opacity: 1;
}

.product-chart-focus-guide {
  stroke: rgba(26,24,20,.18);
  stroke-width: 1;
  stroke-dasharray: 4 4;
}

.product-chart-focus-point-ring {
  fill: rgba(251,249,244,.98);
  stroke: rgba(26,24,20,.16);
  stroke-width: 1.25;
}

.product-chart-focus-point-core {
  stroke: rgba(251,249,244,.96);
  stroke-width: 1.4;
}

.product-chart-hover {
  fill: transparent;
  cursor: crosshair;
}

.product-modal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 12px;
}

.legend-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid var(--border-soft);
  background: var(--surface-2);
  color: var(--ink-3);
  font-size: 12px;
  font-weight: 500;
  transition: background .12s ease, border-color .12s ease, color .12s ease, opacity .12s ease;
}

.legend-btn:hover {
  border-color: var(--border);
  color: var(--ink);
}

.legend-btn.active {
  background: var(--bg);
  color: var(--ink);
  border-color: var(--border);
}

.legend-btn:not(.active) {
  opacity: .52;
}

.product-modal-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.product-chart-tooltip {
  position: absolute;
  width: max-content;
  min-width: 280px;
  max-width: min(420px, calc(100vw - 32px));
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  background: rgba(251,249,244,.96);
  box-shadow: 0 14px 32px rgba(26,24,20,.14);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(4px);
  transition: opacity .14s ease, transform .14s ease, visibility .14s ease;
  z-index: 6;
}

.product-chart-tooltip.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.product-chart-tooltip-date {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--ink-4);
  font-weight: 600;
  margin-bottom: 7px;
}

.product-chart-tooltip-note {
  font-size: 11px;
  color: var(--ink-3);
  margin-bottom: 8px;
}

.product-chart-tooltip-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.product-chart-tooltip-row-total {
  padding-bottom: 6px;
  margin-bottom: 6px;
  border-bottom: 1px solid rgba(26,24,20,.08);
}

.product-chart-tooltip-row + .product-chart-tooltip-row {
  margin-top: 4px;
}

.product-chart-tooltip-key {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: var(--ink-3);
  flex: 1 1 auto;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-chart-tooltip-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.product-chart-tooltip-val {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
  font-family: var(--f-mono);
  flex: 0 0 auto;
  white-space: nowrap;
  text-align: right;
}

.product-chart-animate {
  animation: productChartReveal .72s cubic-bezier(.2,.7,.2,1) both;
}

.product-chart-line-animate {
  animation: productChartLineReveal .72s cubic-bezier(.2,.7,.2,1) forwards;
}

.product-modal-table-note {
  font-size: 12px;
  color: var(--ink-3);
}

.modal-store-table-wrap {
  max-height: none;
  overflow: visible;
}

.modal-store-table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
}

.modal-store-table th,
.modal-store-table td {
  padding-right: 10px;
}

.modal-store-table th:first-child,
.modal-store-table td:first-child {
  width: 18%;
}

.modal-store-table th:nth-child(2),
.modal-store-table td:nth-child(2) {
  width: 12%;
}

.modal-store-table .td-name {
  white-space: normal;
}

.modal-store-table thead th {
  position: sticky;
  top: 0;
  background: var(--surface);
  z-index: 1;
}

.modal-store-table td:first-child .td-name {
  gap: 6px;
}

.modal-store-table .is-selected {
  color: #1E4B3F;
}

@keyframes productChartReveal {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes productChartLineReveal {
  from {
    stroke-dashoffset: var(--dash-length, 1000);
  }
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes productSkeletonPulse {
  0% {
    background-position: 100% 0;
  }
  100% {
    background-position: -100% 0;
  }
}

@keyframes catalogLoaderDotPulse {
  0%, 100% {
    opacity: .28;
    transform: translateY(0);
  }
  50% {
    opacity: 1;
    transform: translateY(-1px);
  }
}

@media (max-width: 980px) {
  .product-modal {
    width: calc(100vw - 24px);
    max-height: calc(100vh - 24px);
  }

  .product-modal-head,
  .product-modal-body {
    padding-left: 18px;
    padding-right: 18px;
  }

  .product-modal-card-head {
    flex-direction: column;
  }

  .product-modal-kpis {
    min-width: 0;
    width: 100%;
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .product-modal-overlay {
    padding: 12px;
  }

  .product-modal-title {
    font-size: 26px;
  }

  .product-modal-toolbar,
  .product-modal-trend-controls,
  .product-modal-controls,
  .product-modal-title-row {
    align-items: stretch;
  }

  .store-picker-trigger {
    width: 100%;
  }

  .store-picker-panel {
    width: min(320px, calc(100vw - 44px));
    right: auto;
    left: 0;
  }
}
