/* Product page — Оптовой */
.om-product-page {
  padding: 24px 0 48px;
}
.om-product-page .om-breadcrumbs {
  margin-bottom: 20px;
}

.om-product-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
  margin-bottom: 32px;
}

/* Gallery */
.om-pgallery {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 16px;
}
.om-pgallery__thumbs {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.om-pgallery__thumb {
  width: 72px;
  height: 72px;
  padding: 0;
  border: 2px solid var(--om-border);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  overflow: hidden;
}
.om-pgallery__thumb.is-active {
  border-color: var(--om-blue);
}
.om-pgallery__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.om-pgallery__main {
  position: relative;
  background: var(--om-surface);
  border: 1px solid var(--om-border);
  border-radius: var(--om-radius-lg);
  min-height: 400px;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  cursor: zoom-in;
}
.om-pgallery__main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}
.om-pgallery__main:hover img {
  transform: scale(1.03);
}
.om-pgallery__badge {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 2;
}
.om-pgallery__zoom {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--om-text);
  display: grid;
  place-items: center;
  box-shadow: 0 2px 12px rgba(15, 23, 42, 0.12);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.25s, transform 0.25s;
  pointer-events: none;
}
.om-pgallery__main:hover .om-pgallery__zoom {
  opacity: 1;
  transform: translateY(0);
}

/* Lightbox */
.om-plightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
.om-plightbox.is-open {
  opacity: 1;
  visibility: visible;
}
.om-plightbox.is-closing {
  opacity: 0;
  visibility: visible;
}
.om-plightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.88);
  cursor: zoom-out;
}
.om-plightbox__dialog {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: min(960px, 100%);
  max-height: calc(100vh - 48px);
  transform: scale(0.9) translateY(16px);
  opacity: 0;
  transition: transform 0.35s cubic-bezier(0.34, 1.2, 0.64, 1), opacity 0.3s ease;
}
.om-plightbox.is-open .om-plightbox__dialog {
  transform: scale(1) translateY(0);
  opacity: 1;
}
.om-plightbox.is-closing .om-plightbox__dialog {
  transform: scale(0.95) translateY(8px);
  opacity: 0;
  transition-duration: 0.22s;
}
.om-plightbox__close {
  position: absolute;
  top: -48px;
  right: 0;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background 0.2s;
}
.om-plightbox__close:hover {
  background: rgba(255, 255, 255, 0.22);
}
.om-plightbox__stage {
  width: 100%;
  flex: 1;
  min-height: 0;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}
.om-plightbox__img {
  max-width: 100%;
  max-height: calc(100vh - 200px);
  object-fit: contain;
  border-radius: var(--om-radius);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.35);
}
.om-plightbox__thumbs {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--om-radius-lg);
  backdrop-filter: blur(8px);
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}
.om-plightbox__thumbs::-webkit-scrollbar { display: none; }
.om-plightbox__thumb {
  width: 72px;
  height: 72px;
  flex-shrink: 0;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 10px;
  background: none;
  cursor: pointer;
  overflow: hidden;
  opacity: 0.65;
  transition: opacity 0.2s, border-color 0.2s, transform 0.2s;
}
.om-plightbox__thumb:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}
.om-plightbox__thumb.is-active {
  border-color: #fff;
  opacity: 1;
}
.om-plightbox__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Info */
.om-pinfo__brand {
  font-size: 14px;
  color: var(--om-blue);
  font-weight: 600;
  margin-bottom: 8px;
}
.om-pinfo__title {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 12px;
}
.om-pinfo__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  font-size: 14px;
  color: var(--om-muted);
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--om-border);
}
.om-pinfo__rating {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #f59e0b;
  font-weight: 600;
}
.om-pinfo__meta a,
.om-pinfo__meta .om-pinfo__quick,
.om-pinfo__meta .om-pinfo__reviews-link {
  color: var(--om-blue);
  font-weight: 500;
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  cursor: pointer;
  text-decoration: none;
}
.om-pinfo__meta .om-pinfo__reviews-link:hover,
.om-pinfo__meta a:hover,
.om-pinfo__meta .om-pinfo__quick:hover {
  color: #0047cc;
  text-decoration: underline;
}
.om-pinfo__code { margin-left: auto; font-size: 13px; }

.om-pinfo__stock {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}

.om-price-block {
  background: var(--om-surface);
  border: 1px solid var(--om-border);
  border-radius: var(--om-radius-lg);
  padding: 20px;
  margin-bottom: 20px;
}
.om-price-block__label {
  font-size: 13px;
  color: var(--om-muted);
  margin-bottom: 4px;
}
.om-price-block__price {
  font-size: 32px;
  font-weight: 800;
  color: var(--om-text);
  margin-bottom: 4px;
}
.om-price-block__price span {
  font-size: 16px;
  font-weight: 500;
  color: var(--om-muted);
}
.om-price-block__tiers {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--om-border);
}
.om-price-block__tiers-title {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 10px;
}
.om-price-tier {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: 6px 0;
  color: var(--om-muted);
}
.om-price-tier strong { color: var(--om-text); }

.om-purchase {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 20px;
}
.om-qty {
  display: flex;
  align-items: center;
  border: 1px solid var(--om-border);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}
.om-qty__btn {
  width: 40px;
  height: 44px;
  border: none;
  background: var(--om-surface);
  font-size: 18px;
  cursor: pointer;
  color: var(--om-text);
}
.om-qty__btn:hover { background: var(--om-border); }
.om-qty__input {
  width: 64px;
  height: 44px;
  border: none;
  border-left: 1px solid var(--om-border);
  border-right: 1px solid var(--om-border);
  text-align: center;
  font-weight: 600;
  font-size: 15px;
}
.om-purchase__moq {
  font-size: 13px;
  color: var(--om-muted);
  width: 100%;
}

.om-pinfo__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 12px;
  margin-bottom: 24px;
}
.om-pinfo__actions > .om-btn,
.om-pinfo__actions > .om-inline-form {
  flex: 1 1 0;
  min-width: 160px;
}
.om-pinfo__actions .om-inline-form {
  display: flex;
  margin: 0;
}
.om-pinfo__actions .om-btn {
  flex: 1;
  width: 100%;
  min-height: 48px;
  padding-inline: 16px;
  white-space: nowrap;
  text-align: center;
}

.om-supplier-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--om-border);
  border-radius: var(--om-radius-lg);
  background: #fff;
}
.om-supplier-card--product {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 14px;
}
.om-supplier-card--product .om-supplier-card__body {
  min-width: 0;
}
.om-supplier-card--product .om-supplier-trust {
  grid-column: 1 / -1;
  margin-top: 0;
  padding-top: 12px;
  border-top: 1px solid var(--om-border);
}
.om-supplier-card__icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: var(--om-blue-light);
  color: var(--om-blue);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.om-supplier-card__name { font-weight: 700; font-size: 15px; }
.om-supplier-card__meta { font-size: 13px; color: var(--om-muted); }
.om-supplier-card__link {
  margin-left: auto;
  font-size: 13px;
  font-weight: 600;
  color: var(--om-blue);
  white-space: nowrap;
}

/* Trust row */
.om-ptrust {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 32px;
  padding: 20px;
  background: var(--om-surface);
  border-radius: var(--om-radius-lg);
}
.om-ptrust__item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 500;
}
.om-ptrust__icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #fff;
  display: grid;
  place-items: center;
  color: var(--om-blue);
  flex-shrink: 0;
}

/* Tabs */
.om-ptabs__nav {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--om-border);
  margin-bottom: 24px;
}
.om-ptabs__btn {
  padding: 12px 20px;
  border: none;
  background: none;
  font-size: 14px;
  font-weight: 500;
  color: var(--om-muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  white-space: nowrap;
}
.om-ptabs__btn.is-active {
  color: var(--om-blue);
  border-bottom-color: var(--om-blue);
  font-weight: 600;
}
.om-ptabs__panel { display: none; }
.om-ptabs__panel.is-active { display: block; }
.om-ptabs__panel p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--om-muted);
  margin-bottom: 16px;
}
.om-specs {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.om-specs th,
.om-specs td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--om-border);
  text-align: left;
}
.om-specs th {
  width: 40%;
  color: var(--om-muted);
  font-weight: 500;
  background: var(--om-surface);
}
.om-specs td { font-weight: 500; }

/* Product reviews tab */
.om-previews {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.om-previews__summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  padding: 20px 24px;
  background: var(--om-surface);
  border: 1px solid var(--om-border);
  border-radius: var(--om-radius-lg);
}
.om-previews__score {
  font-size: 40px;
  font-weight: 800;
  line-height: 1;
  color: var(--om-text);
}
.om-previews__stars {
  display: inline-flex;
  align-items: center;
  color: #f59e0b;
}
.om-previews__stars .om-stars svg {
  width: 20px;
  height: 20px;
}
.om-previews__count {
  font-size: 14px;
  color: var(--om-muted);
}

/* Related / category slider */
.om-related {
  margin-top: 32px;
}
.om-related__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 16px;
  margin-bottom: 20px;
}
.om-related__title {
  font-size: 24px;
  font-weight: 800;
  margin: 0;
}
.om-related__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.om-products-slider__track {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  padding-bottom: 4px;
}
.om-products-slider__track::-webkit-scrollbar {
  display: none;
}
.om-products-slider__track > .om-product {
  flex: 0 0 calc(20% - 13px);
  min-width: 200px;
  max-width: 240px;
  scroll-snap-align: start;
}

@media (max-width: 1100px) {
  .om-product-hero { grid-template-columns: 1fr; }
  .om-ptrust { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .om-ptabs__nav {
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }
  .om-ptabs__nav::-webkit-scrollbar {
    display: none;
  }
  .om-pgallery { grid-template-columns: 1fr; }
  .om-pgallery__thumbs {
    flex-direction: row;
    order: 2;
    overflow-x: auto;
  }
  .om-pgallery__thumb { flex-shrink: 0; }
  .om-pinfo__code { margin-left: 0; width: 100%; }
  .om-ptrust { grid-template-columns: 1fr; }
  .om-supplier-card { flex-wrap: wrap; }
  .om-supplier-card__link { margin-left: 0; width: 100%; }
  .om-plightbox { padding: 16px; }
  .om-plightbox__close {
    top: 8px;
    right: 8px;
    background: rgba(15, 23, 42, 0.5);
  }
  .om-plightbox__img { max-height: calc(100vh - 180px); }
  .om-plightbox__thumb { width: 56px; height: 56px; }
  .om-related__title { font-size: 20px; }
  .om-products-slider__track > .om-product {
    flex: 0 0 calc(50% - 8px);
    min-width: 160px;
  }
}

.om-product-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  margin: 32px 0 8px;
  padding-top: 24px;
  border-top: 1px solid var(--om-border);
}
.om-product-tags__label {
  font-size: 14px;
  font-weight: 600;
  color: var(--om-muted);
}
.om-product-tags__list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.om-product-tags__list li {
  margin: 0;
  padding: 0;
}
.om-product-tags__item {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--om-surface);
  border: 1px solid var(--om-border);
  font-size: 13px;
  font-weight: 500;
  color: var(--om-text);
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.om-product-tags__item:hover {
  border-color: var(--om-blue);
  color: var(--om-blue);
  background: var(--om-blue-light);
}
