/*
 * Chocolenka — category cards and product detail
 * Keeps Shoptet markup, cart actions and structured product data untouched.
 */

:root {
  --ch-product-ink: #321b0d;
  --ch-product-brown: #6a3b17;
  --ch-product-orange: #d9801a;
  --ch-product-orange-hover: #b96512;
  --ch-product-cream: #fbf7f0;
  --ch-product-line: #ead9c6;
  --ch-product-muted: #756457;
  --ch-product-shadow: 0 10px 28px rgba(53, 29, 13, .075);
}

/* Search product cards — keep them identical to the refined category grid. */
body.type-search #products-found #products.products-block {
  gap: 22px 0;
  align-items: stretch;
}

body.type-search #products-found #products.products-block > .product {
  padding: 11px;
  border: 1px solid var(--ch-product-line);
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(53, 29, 13, .045);
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease;
}

body.type-search #products-found #products.products-block > .product:hover {
  z-index: 2;
  border-color: #d9b991;
  box-shadow: var(--ch-product-shadow);
  transform: translateY(-3px);
}

body.type-search #products-found #products.products-block .image {
  position: relative;
  border-radius: 11px;
  background: #f4ede4;
}

body.type-search #products-found #products.products-block .image::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(77, 43, 20, .05);
}

body.type-search #products-found #products.products-block .product:hover .image img {
  transform: scale(1.035);
}

body.type-search #products-found #products.products-block .p-in {
  padding: 15px 3px 3px;
}

body.type-search #products-found #products.products-block .name {
  min-height: 45px;
  color: var(--ch-product-ink);
  font-weight: 800;
  line-height: 1.45;
}

body.type-search #products-found #products.products-block .name:hover {
  color: var(--ch-product-orange);
}

body.type-search #products-found #products.products-block .ratings-wrapper {
  min-height: 35px;
  margin-top: 9px;
}

body.type-search #products-found #products.products-block .stars-wrapper::after {
  color: var(--ch-product-muted);
}

body.type-search #products-found #products.products-block .availability {
  padding: 6px 10px;
  font-weight: 800;
  line-height: 1.15;
}

body.type-search #products-found #products.products-block .p-bottom {
  padding-top: 8px;
}

body.type-search #products-found #products.products-block .p-bottom > div[data-micro="offer"] {
  min-height: 47px;
}

body.type-search #products-found #products.products-block .price-final {
  font-size: 22px;
  line-height: 1.1;
}

body.type-search #products-found #products.products-block .btn-cart,
body.type-search #products-found #products.products-block .btn-primary {
  min-height: 44px;
  padding: 10px 15px;
  border-color: var(--ch-product-orange);
  border-radius: 9px;
  background: var(--ch-product-orange);
  font-weight: 800;
}

body.type-search #products-found #products.products-block .btn-cart:hover,
body.type-search #products-found #products.products-block .btn-primary:hover {
  border-color: var(--ch-product-orange-hover);
  background: var(--ch-product-orange-hover);
}

body.type-search #products-found #products.products-block .flag {
  padding: 6px 9px;
}

@media (max-width: 767px) {
  body.type-search #products-found #products.products-block {
    margin-right: -4px;
    margin-left: -4px;
    gap: 12px 0;
  }

  body.type-search #products-found #products.products-block > .product {
    padding: 7px;
    border-radius: 11px;
  }

  body.type-search #products-found #products.products-block .image {
    border-radius: 8px;
  }

  body.type-search #products-found #products.products-block .name {
    min-height: 39px;
    line-height: 1.42;
  }

  body.type-search #products-found #products.products-block .ratings-wrapper {
    min-height: 30px;
    margin-top: 6px;
    gap: 4px;
  }

  body.type-search #products-found #products.products-block .star {
    transform: scale(.86);
  }

  body.type-search #products-found #products.products-block .availability {
    padding: 5px 7px;
  }

  body.type-search #products-found #products.products-block .p-bottom > div[data-micro="offer"] {
    min-height: 0;
  }

  body.type-search #products-found #products.products-block .btn-cart,
  body.type-search #products-found #products.products-block .btn-primary {
    padding: 8px 5px;
    font-size: 11px;
  }
}

/* Category subcategory tiles
   Keep Shoptet's original links and responsive column widths; only refine
   the visual treatment to match the Chocolenka product-card system. */
body.type-category .category-top > .subcategories.with-image {
  margin-top: 26px;
  margin-right: -7px;
  margin-left: -7px;
  align-items: stretch;
}

body.type-category .category-top > .subcategories.with-image > li {
  padding: 7px;
}

body.type-category .category-top > .subcategories.with-image > li > a {
  position: relative;
  height: 166px;
  padding: 0;
  overflow: hidden;
  display: grid;
  grid-template-rows: 108px minmax(57px, 1fr);
  grid-template-columns: minmax(0, 1fr);
  border: 1px solid #ead8c3;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 7px 22px rgba(55, 30, 14, 0.06);
  color: #321b0d;
  isolation: isolate;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

body.type-category .category-top > .subcategories.with-image > li > a .image {
  width: 100%;
  height: 108px;
  min-height: 108px;
  margin: 0;
  padding: 9px 12px 7px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #fff;
}

body.type-category .category-top > .subcategories.with-image > li > a .image img {
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 92px;
  object-fit: contain;
  transform: translateZ(0);
  transition: transform 220ms ease;
}

body.type-category .category-top > .subcategories.with-image > li > a .text {
  width: 100%;
  height: auto;
  min-height: 57px;
  padding: 10px 11px 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  border-top: 1px solid #f0e3d5;
  background: #fffaf4;
  color: #321b0d;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.22;
  text-align: center;
}

body.type-category .category-top > .subcategories.with-image > li > a:hover,
body.type-category .category-top > .subcategories.with-image > li > a:focus-visible {
  border-color: #d9801a;
  box-shadow: 0 11px 28px rgba(55, 30, 14, 0.12);
  color: #321b0d;
  transform: translateY(-3px);
}

body.type-category .category-top > .subcategories.with-image > li > a:hover .image img,
body.type-category .category-top > .subcategories.with-image > li > a:focus-visible .image img {
  transform: scale(1.045);
}

body.type-category .category-top > .subcategories.with-image > li > a:focus-visible {
  outline: 3px solid rgba(217, 128, 26, 0.28);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  body.type-category .category-top > .subcategories.with-image > li > a,
  body.type-category .category-top > .subcategories.with-image > li > a .image img {
    transition: none;
  }
}

@media (max-width: 767px) {
  body.type-category .category-top > .subcategories.with-image {
    margin-top: 20px;
    margin-right: -5px;
    margin-left: -5px;
  }

  body.type-category .category-top > .subcategories.with-image > li {
    padding: 5px;
  }

  body.type-category .category-top > .subcategories.with-image > li > a {
    height: 148px;
    grid-template-rows: 94px minmax(54px, 1fr);
    border-radius: 12px;
  }

  body.type-category .category-top > .subcategories.with-image > li > a .image {
    height: 94px;
    min-height: 94px;
    padding: 7px 9px 5px;
  }

  body.type-category .category-top > .subcategories.with-image > li > a .image img {
    max-height: 82px;
  }

  body.type-category .category-top > .subcategories.with-image > li > a .text {
    min-height: 54px;
    padding: 8px 7px 9px;
    font-size: 13px;
  }

  body.type-category .category-top > .subcategories.with-image > li > a:hover,
  body.type-category .category-top > .subcategories.with-image > li > a:focus-visible {
    transform: none;
  }
}

/* Category product cards */
body.type-category #products.products-page.products-block {
  gap: 22px 0;
  align-items: stretch;
}

body.type-category #products.products-page.products-block > .product {
  padding: 11px;
  border: 1px solid var(--ch-product-line);
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(53, 29, 13, .045);
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease;
}

body.type-category #products.products-page.products-block > .product:hover {
  z-index: 2;
  border-color: #d9b991;
  box-shadow: var(--ch-product-shadow);
  transform: translateY(-3px);
}

body.type-category #products.products-page.products-block .product > .p {
  height: 100%;
  display: flex;
  flex-direction: column;
}

body.type-category #products.products-page.products-block .image {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 11px;
  background: #f4ede4;
}

body.type-category #products.products-page.products-block .image::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(77, 43, 20, .05);
}

body.type-category #products.products-page.products-block .image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform .32s ease;
}

body.type-category #products.products-page.products-block .product:hover .image img {
  transform: scale(1.035);
}

body.type-category #products.products-page.products-block .p-in {
  min-width: 0;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  padding: 15px 3px 3px;
}

body.type-category #products.products-page.products-block .p-in-in {
  min-width: 0;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
}

body.type-category #products.products-page.products-block .name {
  min-height: 45px;
  margin: 0;
  display: -webkit-box;
  overflow: hidden;
  color: var(--ch-product-ink);
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.45;
  text-decoration: none;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

body.type-category #products.products-page.products-block .name:hover {
  color: var(--ch-product-orange);
}

body.type-category #products.products-page.products-block .ratings-wrapper {
  min-height: 35px;
  margin-top: 9px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: nowrap;
}

body.type-category #products.products-page.products-block .stars-wrapper {
  width: auto !important;
  max-width: max-content;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border: 0;
  background: transparent;
  line-height: 1;
}

body.type-category #products.products-page.products-block .stars-wrapper::after {
  content: attr(data-micro-rating-value) " / 5 (" attr(data-micro-rating-count) ")";
  color: var(--ch-product-muted);
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

body.type-category #products.products-page.products-block .stars {
  display: inline-flex;
  align-items: center;
}

body.type-category #products.products-page.products-block .star {
  margin-right: 1px;
}

body.type-category #products.products-page.products-block .availability {
  width: auto !important;
  max-width: max-content;
  flex: 0 0 auto;
  margin-left: auto;
  padding: 6px 10px;
  border-radius: 999px;
  background: #edf6e9;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.15;
  white-space: nowrap;
}

body.type-category #products.products-page.products-block .availability span {
  color: #248315 !important;
}

body.type-category #products.products-page.products-block .p-bottom {
  margin-top: auto;
  padding-top: 8px;
}

body.type-category #products.products-page.products-block .p-bottom > div[data-micro="offer"] {
  min-height: 47px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

body.type-category #products.products-page.products-block .prices {
  min-width: 0;
  margin: 0;
}

body.type-category #products.products-page.products-block .price-final {
  color: #24170f;
  font-family: inherit;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.1;
  white-space: nowrap;
}

body.type-category #products.products-page.products-block .p-tools {
  margin: 0 0 0 auto;
}

body.type-category #products.products-page.products-block .btn-cart,
body.type-category #products.products-page.products-block .btn-primary {
  min-height: 44px;
  padding: 10px 15px;
  border: 1px solid var(--ch-product-orange);
  border-radius: 9px;
  background: var(--ch-product-orange);
  color: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 800;
  box-shadow: none;
  transition: background .18s ease, border-color .18s ease, transform .18s ease;
}

body.type-category #products.products-page.products-block .btn-cart:hover,
body.type-category #products.products-page.products-block .btn-primary:hover {
  border-color: var(--ch-product-orange-hover);
  background: var(--ch-product-orange-hover);
  transform: translateY(-1px);
}

body.type-category #products.products-page.products-block .p-desc {
  display: none;
}

body.type-category #products.products-page.products-block .flags {
  top: 10px;
  left: 10px;
}

body.type-category #products.products-page.products-block .flag {
  margin-bottom: 4px;
  padding: 6px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.1;
  box-shadow: 0 4px 12px rgba(35, 20, 10, .12);
}

/* Product detail */
body.type-detail .p-detail-inner {
  color: var(--ch-product-ink);
}

body.type-detail .p-detail-inner-header {
  margin: 18px 0 20px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}

body.type-detail .p-detail-inner-header h1 {
  margin: 0;
  color: var(--ch-product-ink);
  font-family: inherit;
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 800;
  line-height: 1.15;
}

body.type-detail .p-detail-inner-header .p-code {
  flex: 0 0 auto;
  padding: 6px 10px;
  border: 1px solid var(--ch-product-line);
  border-radius: 999px;
  color: var(--ch-product-muted);
  background: var(--ch-product-cream);
  font-size: 11px;
}

body.type-detail .product-top {
  margin: 0;
  padding: 24px;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(330px, .85fr);
  gap: 24px 30px;
  border: 1px solid var(--ch-product-line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 26px rgba(53, 29, 13, .055);
}

body.type-detail .product-top > .col-xs-12:first-child {
  width: 100%;
  grid-column: 1 / -1;
  padding: 0;
  float: none;
}

body.type-detail .product-top .p-image-wrapper,
body.type-detail .product-top .p-info-wrapper {
  width: 100%;
  padding: 0;
  float: none;
}

body.type-detail .p-detail-info {
  display: flex;
  align-items: center;
  gap: 10px 16px;
  flex-wrap: wrap;
  color: var(--ch-product-muted);
  font-size: 12px;
}

body.type-detail .p-detail-info .stars-wrapper {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

body.type-detail .p-image {
  overflow: hidden;
  border: 1px solid var(--ch-product-line);
  border-radius: 14px;
  background: #f4ede4;
}

body.type-detail .p-main-image {
  display: block;
}

body.type-detail .p-main-image img {
  width: 100%;
  height: auto;
  display: block;
}

body.type-detail .p-thumbnails-wrapper {
  margin-top: 12px;
}

body.type-detail .p-thumbnail {
  overflow: hidden;
  border: 1px solid var(--ch-product-line);
  border-radius: 9px;
  background: #fff;
  opacity: .78;
  transition: opacity .18s ease, border-color .18s ease;
}

body.type-detail .p-thumbnail:hover,
body.type-detail .p-thumbnail.highlighted {
  border-color: var(--ch-product-orange);
  opacity: 1;
}

body.type-detail .p-info-wrapper {
  align-self: start;
  padding: 28px !important;
  border: 1px solid var(--ch-product-line);
  border-radius: 14px;
  background: var(--ch-product-cream);
}

body.type-detail .p-final-price-wrapper {
  margin-bottom: 18px;
}

body.type-detail .p-final-price-wrapper .price-final {
  display: block;
  color: var(--ch-product-ink);
  font-family: inherit;
  font-size: clamp(32px, 3vw, 42px);
  font-weight: 800;
  line-height: 1.05;
}

body.type-detail .p-final-price-wrapper .price-additional {
  margin-top: 5px;
  display: block;
  color: var(--ch-product-muted);
  font-size: 12px;
}

body.type-detail .availability-value {
  width: max-content;
  margin: 0 0 16px;
  padding: 8px 13px;
  border-radius: 999px;
  background: #edf6e9;
  font-weight: 800;
}

body.type-detail .availability-value .availability-label,
body.type-detail .availability-value .availability-label span {
  color: #248315 !important;
}

body.type-detail .detail-parameters {
  margin: 0 0 16px;
}

body.type-detail .detail-parameters th,
body.type-detail .detail-parameters td {
  padding: 0;
  border: 0;
}

body.type-detail .detail-parameters .shipping-options {
  color: var(--ch-product-brown);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(106, 59, 23, .3);
  text-underline-offset: 3px;
}

body.type-detail .add-to-cart {
  margin: 0 0 18px;
  display: flex;
  align-items: stretch;
  gap: 10px;
}

body.type-detail .add-to-cart .quantity {
  width: 94px;
  min-width: 94px;
  height: 50px;
  border: 1px solid var(--ch-product-line);
  border-radius: 10px;
  background: #fff;
}

body.type-detail .add-to-cart .quantity input {
  height: 48px;
  border: 0;
  background: transparent;
  font-weight: 800;
}

body.type-detail .add-to-cart .increase,
body.type-detail .add-to-cart .decrease {
  border-color: var(--ch-product-line);
  background: #fff;
}

body.type-detail .add-to-cart .btn-conversion {
  min-height: 50px;
  flex: 1 1 auto;
  padding: 12px 22px;
  border: 1px solid var(--ch-product-orange);
  border-radius: 10px;
  background: var(--ch-product-orange);
  color: #fff;
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  box-shadow: 0 8px 18px rgba(209, 123, 27, .18);
}

body.type-detail .add-to-cart .btn-conversion:hover {
  border-color: var(--ch-product-orange-hover);
  background: var(--ch-product-orange-hover);
}

body.type-detail .p-info-wrapper > p[data-testid="productCardDescr"] {
  margin: 0;
}

body.type-detail .p-info-wrapper > p[data-testid="productCardDescr"] a {
  color: var(--ch-product-brown);
  font-weight: 700;
}

body.type-detail .social-buttons-wrapper {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--ch-product-line);
}

body.type-detail .p-detail-tabs {
  margin-top: 30px;
  padding: 6px;
  display: flex;
  gap: 5px;
  border: 1px solid var(--ch-product-line);
  border-radius: 12px;
  background: var(--ch-product-cream);
}

body.type-detail .p-detail-tabs > li {
  margin: 0;
}

body.type-detail .p-detail-tabs > li > a {
  padding: 10px 16px;
  border: 0;
  border-radius: 8px;
  color: var(--ch-product-brown);
  font-weight: 700;
}

body.type-detail .p-detail-tabs > li.active > a,
body.type-detail .p-detail-tabs > li > a:hover {
  background: var(--ch-product-brown);
  color: #fff;
}

body.type-detail .tab-content {
  padding: 26px;
  border: 1px solid var(--ch-product-line);
  border-top: 0;
  border-radius: 0 0 14px 14px;
  background: #fff;
}

/* Product-detail recommendations
   Keep Shoptet's native products and carousel controls; visually align the
   cards with the category grid and the added-to-cart recommendations. */
body.type-detail .products-related-header {
  margin: 40px 0 16px;
  color: var(--ch-product-ink);
  font-family: inherit;
  font-size: clamp(23px, 2.2vw, 30px);
  font-weight: 800;
  line-height: 1.2;
}

body.type-detail .products-related.products-block {
  margin-right: -8px;
  margin-left: -8px;
  overflow: visible;
}

body.type-detail .products-related.products-block > .product {
  height: auto !important;
  padding: 8px !important;
  border: 0 !important;
}

body.type-detail .products-related .product > .p {
  width: 100% !important;
  min-width: 0;
  height: 100% !important;
  min-height: 408px;
  padding: 11px !important;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--ch-product-line);
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 6px 20px rgba(53, 29, 13, .06);
  transition:
    transform .2s ease,
    border-color .2s ease,
    box-shadow .2s ease;
}

body.type-detail .products-related .product > .p:hover {
  border-color: #d9b991;
  box-shadow: var(--ch-product-shadow);
  transform: translateY(-3px);
}

body.type-detail .products-related .image {
  width: 100% !important;
  height: auto !important;
  aspect-ratio: 4 / 3;
  margin: 0 0 13px !important;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 11px;
  background: #fff;
}

body.type-detail .products-related .image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  transition: transform .28s ease;
}

body.type-detail .products-related .product > .p:hover .image img {
  transform: scale(1.025);
}

body.type-detail .products-related .p-in {
  height: auto !important;
  min-height: 0;
  min-width: 0;
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  padding: 0 2px 2px;
}

body.type-detail .products-related .p-in-in {
  height: auto !important;
  min-height: 79px;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

body.type-detail .products-related .name {
  height: auto !important;
  min-height: 46px;
  margin: 0;
  display: -webkit-box;
  overflow: hidden;
  color: var(--ch-product-ink) !important;
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.42;
  text-decoration: none;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

body.type-detail .products-related .name:hover {
  color: var(--ch-product-orange) !important;
}

body.type-detail .products-related .ratings-wrapper {
  height: auto !important;
  min-height: 31px;
  margin-top: 8px;
  display: flex;
  align-items: center;
}

body.type-detail .products-related .availability {
  width: max-content !important;
  max-width: 100%;
  margin-left: auto;
  padding: 6px 10px;
  border-radius: 999px;
  background: #edf6e9;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.15;
}

body.type-detail .products-related .availability span {
  color: #248315 !important;
}

body.type-detail .products-related .p-bottom {
  height: auto !important;
  min-height: 53px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid #f0e4d7;
}

body.type-detail .products-related .p-bottom > div[data-micro="offer"] {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

body.type-detail .products-related .prices {
  min-width: 0;
  margin: 0;
}

body.type-detail .products-related .price-final {
  color: #24170f;
  font-family: inherit;
  font-size: 21px;
  font-weight: 800;
  line-height: 1.1;
  white-space: nowrap;
}

body.type-detail .products-related .p-tools {
  margin: 0 0 0 auto;
}

body.type-detail .products-related .p-tools .btn {
  min-height: 40px;
  padding: 9px 14px;
  border: 1px solid var(--ch-product-orange);
  border-radius: 9px;
  background: var(--ch-product-orange);
  color: #fff;
  font-family: inherit;
  font-size: 12px;
  font-weight: 800;
  box-shadow: none;
  transition:
    background .18s ease,
    border-color .18s ease,
    transform .18s ease;
}

body.type-detail .products-related .p-tools .btn:hover {
  border-color: var(--ch-product-orange-hover);
  background: var(--ch-product-orange-hover);
  color: #fff;
  transform: translateY(-1px);
}

body.type-detail .products-related .flags {
  top: 10px;
  left: 10px;
}

body.type-detail .products-related .flag {
  padding: 6px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.1;
}

@media (max-width: 991px) {
  body.type-detail .product-top {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  body.type-detail .product-top > .col-xs-12:first-child {
    grid-column: auto;
  }

  body.type-detail .p-info-wrapper {
    padding: 22px !important;
  }
}

@media (max-width: 767px) {
  body.type-category #products.products-page.products-block {
    margin-left: -4px;
    margin-right: -4px;
    gap: 12px 0;
  }

  body.type-category #products.products-page.products-block > .product {
    padding: 7px;
    border-radius: 11px;
  }

  body.type-category #products.products-page.products-block .image {
    border-radius: 8px;
  }

  body.type-category #products.products-page.products-block .p-in {
    padding: 10px 2px 2px;
  }

  body.type-category #products.products-page.products-block .name {
    min-height: 39px;
    font-size: 13px;
    line-height: 1.42;
  }

  body.type-category #products.products-page.products-block .ratings-wrapper {
    min-height: 30px;
    margin-top: 6px;
    gap: 4px;
  }

  body.type-category #products.products-page.products-block .stars-wrapper::after {
    display: none;
  }

  body.type-category #products.products-page.products-block .star {
    margin-right: 0;
    transform: scale(.86);
    transform-origin: left center;
  }

  body.type-category #products.products-page.products-block .availability {
    padding: 5px 7px;
    font-size: 9px;
  }

  body.type-category #products.products-page.products-block .p-bottom {
    padding-top: 5px;
  }

  body.type-category #products.products-page.products-block .p-bottom > div[data-micro="offer"] {
    min-height: 0;
    display: block;
  }

  body.type-category #products.products-page.products-block .price-final {
    margin-bottom: 8px;
    font-size: 18px;
  }

  body.type-category #products.products-page.products-block .p-tools,
  body.type-category #products.products-page.products-block .p-tools form,
  body.type-category #products.products-page.products-block .btn-cart,
  body.type-category #products.products-page.products-block .btn-primary {
    width: 100%;
  }

  body.type-category #products.products-page.products-block .btn-cart,
  body.type-category #products.products-page.products-block .btn-primary {
    min-height: 40px;
    padding: 8px 5px;
    font-size: 11px;
  }

  body.type-detail .p-detail-inner-header {
    margin: 12px 0 14px;
    display: block;
  }

  body.type-detail .p-detail-inner-header h1 {
    font-size: 28px;
  }

  body.type-detail .p-detail-inner-header .p-code {
    width: max-content;
    margin-top: 10px;
    display: block;
  }

  body.type-detail .product-top {
    padding: 11px;
    gap: 16px;
    border-radius: 13px;
  }

  body.type-detail .p-detail-info {
    gap: 7px 12px;
  }

  body.type-detail .p-image {
    border-radius: 10px;
  }

  body.type-detail .p-info-wrapper {
    padding: 18px !important;
    border-radius: 10px;
  }

  body.type-detail .p-final-price-wrapper .price-final {
    font-size: 34px;
  }

  body.type-detail .add-to-cart {
    flex-wrap: wrap;
  }

  body.type-detail .add-to-cart .quantity {
    width: 100%;
  }

  body.type-detail .add-to-cart .btn-conversion {
    width: 100%;
    flex-basis: 100%;
  }

  body.type-detail .p-detail-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
  }

  body.type-detail .p-detail-tabs > li {
    flex: 0 0 auto;
  }

  body.type-detail .tab-content {
    padding: 18px;
  }

  body.type-detail .products-related-header {
    margin-top: 30px;
    font-size: 23px;
  }

  body.type-detail .products-related.products-block {
    width: 100%;
    max-width: 100%;
    margin-right: 0;
    margin-left: 0;
    padding: 0 2px 10px;
    display: flex !important;
    flex-wrap: nowrap;
    gap: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    box-sizing: border-box;
    overscroll-behavior-inline: contain;
    scroll-snap-type: inline mandatory;
    scrollbar-width: thin;
  }

  body.type-detail .products-related.products-block > .product {
    width: min(78vw, 280px) !important;
    min-width: min(78vw, 280px);
    flex: 0 0 min(78vw, 280px);
    padding: 0 !important;
    float: none;
    scroll-snap-align: start;
  }

  body.type-detail .products-related .product > .p {
    min-height: 390px;
  }

  body.type-detail .products-related .p-in-in {
    min-height: 72px;
  }
}
