/* Stabilizes static catalog/detail pages generated outside the Bitrix markup. */
.catalog-section {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  align-items: stretch;
  justify-content: stretch;
  gap: 24px;
  width: 100%;
  padding: 24px 0 56px;
}

.catalog-section .product-item-small-card {
  width: 100%;
  min-width: 0;
  max-width: none;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  padding: 16px;
  margin: 0;
  border-radius: 16px;
  background: rgba(27, 20, 17, 0.36);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

.catalog-section .product-item-small-card .pl-picture {
  width: 100%;
  height: 320px;
  margin: 0 0 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.catalog-section .product-item-small-card .pl-picture a {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.catalog-section .product-item-small-card .catalog-img-in-slider {
  width: 100%;
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  aspect-ratio: auto;
  object-fit: contain;
  margin: 0;
}

.catalog-section .catalog_section_el-desk {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.catalog-section .catalog_section_el-desk .ib-item {
  min-height: 72px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  text-align: center;
}

.catalog-section .catalog-item-title,
.catalog-section .catalog-item-type {
  max-width: 100%;
  overflow-wrap: anywhere;
}

.catalog-section .section-props-horizont {
  margin-top: 12px;
}

.catalog-section .cart-buy-wrapper {
  width: 100%;
  margin-top: auto;
  padding-top: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.catalog-section .base-price {
  color: var(--default-color-orange);
  font-size: 28px;
  line-height: 1.15;
  font-weight: 800;
  text-align: center;
}

.catalog-section .guarantee-delivery-wrap {
  min-height: 38px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
}

.row.bx-site,
.row.bx-site > [class*="col-"],
#subpage-wrap {
  width: 100%;
  max-width: none;
  margin-right: 0;
  margin-left: 0;
  padding-right: 0;
  padding-left: 0;
  box-sizing: border-box;
}

#subpage-wrap .product-details-wrap,
.wrap-information,
.tovar-docs_new {
  width: min(1240px, calc(100% - 40px));
  margin-right: auto;
  margin-left: auto;
}

.product-details {
  align-items: flex-start;
}

.product-details-pictures {
  flex: 1 1 540px;
  width: auto;
  max-width: 620px;
  min-height: 0;
}

.product-details-in {
  flex: 1 1 420px;
  width: auto;
  max-width: 520px;
}

.product-pictures-wrap {
  min-height: 0;
}

.gallery-top {
  display: block;
  height: auto;
  min-height: 520px;
}

.gallery-top .swiper-slide,
.gallery-top .swiper-slide-containers {
  min-height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-details-pictures .catalog-img-in-slider {
  width: 100%;
  max-width: 460px;
  height: auto;
  max-height: 520px;
  object-fit: contain;
}

.wrapProductInfo {
  width: min(100%, 992px);
  margin-right: auto;
  margin-left: auto;
}

@media (max-width: 1024px) {
  .catalog-section {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  }

  .catalog-section .product-item-small-card .pl-picture {
    height: 280px;
  }

  .product-details {
    flex-direction: column;
  }

  .product-details-pictures,
  .product-details-in {
    width: 100%;
    max-width: none;
    flex-basis: auto;
  }
}

@media (max-width: 575px) {
  .wrap-catalog-section-filter.container {
    padding-right: 10px;
    padding-left: 10px;
  }

  .catalog-section {
    grid-template-columns: 1fr;
    gap: 18px;
    padding-top: 12px;
  }

  .catalog-section .product-item-small-card {
    padding: 14px;
  }

  .catalog-section .product-item-small-card .pl-picture {
    height: 260px;
  }

  .catalog-section .catalog_section_el-desk .ib-item {
    min-height: 0;
  }

  .catalog-section .section-props-horizont li {
    min-height: 0;
    padding: 8px 0;
  }

  #subpage-wrap .product-details-wrap,
  .wrap-information,
  .tovar-docs_new {
    width: calc(100% - 20px);
  }

  .gallery-top,
  .gallery-top .swiper-slide,
  .gallery-top .swiper-slide-containers {
    min-height: 360px;
  }

  .product-details-pictures .catalog-img-in-slider {
    max-height: 360px;
  }

  .product-details-in-wrap {
    margin-left: 0;
  }
}
