:root {
  --dpt-accordion-border-radius: 0;
  --dpt-accordion-BG: #f5f5f5;
  --dpt-accordion-BG-active: #f5f5f5;
  --dpt-accordion-title-color: var(--color-secondary);
  --dpt-accordion-title-color-active: var(--color-secondary);
  --dpt-category: var(--color-secondary);
  --dpt-category-hover: var(--color-secondary-hover);
}

.products-block .p-bottom .prices,
.products-block .p-bottom .p-tools {
  flex-basis: 100%;
}
.products-block .p-bottom .prices {
  position: relative;
}
.products-block .p-bottom .p-tools {
  margin-top: 16px;
}
.products-block .product .availability {
  height: 37px;
  min-height: 37px;
  overflow: hidden;
  display: block;
  margin: 5px 0 10px;
  position: static;
}

/* PageSpeed target-size (>= 24x24px) pre tlačidlá + a - */
.products-block .product .quantity input {
  height: 48px;
}
.products-block .product .quantity .increase,
.products-block .product .quantity .decrease {
  height: 24px;
  min-height: 24px;
  min-width: 28px;
}
.products-block .product .quantity .decrease {
  top: 24px;
}
.products-block .product .quantity .increase:before,
.products-block .product .quantity .decrease:before {
  line-height: 24px;
}
.products-block .product .p-tools > form {
  display: flex;
  flex-wrap: wrap;
}
.products-block .product .p-tools > form .btn {
  width: 70%;
}
.products-block .product .p-tools > form .quantity {
  width: 30%;
}
.products-block .product .p-tools .btn.btn-primary {
  width: 100%;
}
.add-to-cart .quantity {
  position: relative;
}
.add-to-cart .quantity .increase,
.add-to-cart .quantity .decrease {
  pointer-events: auto !important;
  z-index: 5;
}

/* Prevencia CLS (Layout Shift) na Desktop aj Mobile */
.siteCookies,
.siteCookies * {
  transition: none !important;
}
@media (min-width: 992px) {
  .st-cookies-v2.st-cookies-thin .siteCookies {
    height: 87px !important;
    min-height: 87px !important;
    max-height: 87px !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25) !important;
  }
  .st-cookies-v2.st-cookies-thin .siteCookies .siteCookies__links {
    height: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
  }
}
#google-merchantwidget-iframe-wrapper {
  position: fixed !important;
  bottom: 0 !important;
  right: 0 !important;
}
.news-item .image img {
  aspect-ratio: 800 / 533;
  width: 100%;
  height: auto !important;
  object-fit: cover;
  display: block;
}
img[alt="Pavel Tulenko"],
img[src*="Drevospoj_majitel"] {
  aspect-ratio: 1011 / 1242;
  width: 100%;
  max-width: 320px;
  height: auto !important;
  display: block;
}
img[src*="domax-partner-transparentne"] {
  aspect-ratio: 769 / 382;
  height: auto !important;
}

/* Prevencia CLS pre obľúbené kategórie na Homepage */
.fav-cat > ul {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 1rem;
  justify-content: flex-start;
}
.fav-cat > ul > li {
  flex: 0 0 calc(20% - 1rem);
  box-sizing: border-box;
  text-align: center;
  min-height: 170px;
}
.fav-cat > ul > li img {
  aspect-ratio: 1 / 1;
  width: 120px;
  height: 120px;
  object-fit: contain;
  display: block;
  margin: 0 auto 8px;
}
@media (max-width: 768px) {
  .fav-cat > ul > li {
    flex-basis: calc(50% - 1rem);
    min-height: 145px;
  }
  .fav-cat > ul > li img {
    width: 96px;
    height: 96px;
  }
}
@media (max-width: 479px) {
  .products-block .product .p-tools > form .btn {
    width: 60% !important;
    min-width: auto;
  }
  .products-block .product .p-tools > form .quantity {
    width: 40%;
  }
  .products-block .btn.btn-cart:before {
    display: none;
  }
}

/* PageSpeed Accessibility: Dotykové plochy (target-size >= 24x24px) pre šípky carouselu */
.carousel-control,
.carousel-control.left,
.carousel-control.right {
  width: 40px !important;
  min-width: 40px !important;
  height: 48px !important;
  min-height: 48px !important;
  line-height: 48px !important;
}
.carousel-inner .item:not(.active) a,
.carousel-inner .item.left a,
.carousel-inner .item.right a,
.carousel-inner .item.next a,
.carousel-inner .item.prev a {
  pointer-events: none !important;
}

/* PageSpeed Accessibility: WCAG AA kontrast pre dostupnosť a inputy (bez zmeny oranžovej farby) */
.availability-value,
.availability-amount,
.availability span[style*="#009901"],
.availability span[style*="0, 153, 1"] {
  color: #007500 !important;
}

input.query-input,
input.search-input,
#newsletterWidget,
#newsletterWidgetCaptcha {
  color: #222222 !important;
  background-color: #ffffff !important;
}

input.query-input::placeholder,
input.search-input::placeholder,
#newsletterWidget::placeholder,
#newsletterWidgetCaptcha::placeholder {
  color: #595959 !important;
  opacity: 1 !important;
}

/* Štítok: Cena pre registrovaných (-6 %) v detaile produktu */
.ds-reg-price-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin: 12px 0 14px;
  padding: 10px 14px;
  background-color: #fff8f3;
  border: 1px solid #ffd5b8;
  border-left: 4px solid #ff7c24;
  border-radius: 6px;
  font-size: 14px;
  line-height: 1.4;
  color: #24242e;
  max-width: 460px;
}
.ds-reg-price-box__left {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.ds-reg-price-box__badge {
  display: inline-block;
  background-color: #ff7c24;
  color: #ffffff;
  font-weight: 700;
  font-size: 12px;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.3px;
  white-space: nowrap;
}
.ds-reg-price-box__text strong {
  color: #c84b00;
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
}
.ds-reg-price-box__link {
  color: #24242e !important;
  font-weight: 700;
  font-size: 13px;
  text-decoration: underline !important;
  white-space: nowrap;
}
.ds-reg-price-box__link:hover {
  color: #ff7c24 !important;
  text-decoration: none !important;
}

/* 1. ZĽAVOVÝ KUPÓN */
.discount-coupon {
  background-color: #fdfaf7 !important;
  border: 2px dashed #c84b00 !important;
  border-radius: 8px !important;
  padding: 15px 20px !important;
  margin-bottom: 20px !important;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05) !important;
  max-width: 450px !important;
  align-self: flex-start !important;
}
.discount-coupon:hover {
  background-color: #fff4ec !important;
  border-color: #a83e00 !important;
}
.discount-coupon .kupon-odkaz {
  font-size: 16px !important;
  font-weight: 700 !important;
  color: #222 !important;
  text-transform: uppercase !important;
}
.discount-coupon form {
  margin: 15px 0 0 0 !important;
  width: 100% !important;
}
.discount-coupon form input,
.discount-coupon form button {
  border-radius: 4px !important;
  box-sizing: border-box !important;
  font-size: 14px !important;
  position: static !important;
  float: none !important;
  transform: none !important;
  inset: auto !important;
}
.discount-coupon form input {
  display: block !important;
  height: 36px !important;
  min-height: 36px !important;
  max-height: 36px !important;
  line-height: 36px !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 12px !important;
  border: 1px solid #767676 !important;
  background: #fff !important;
  color: #222 !important;
}
.discount-coupon form input:focus {
  border-color: #c84b00 !important;
}
.discount-coupon form button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 36px !important;
  min-height: 36px !important;
  max-height: 36px !important;
  width: auto !important;
  min-width: 110px !important;
  padding: 0 15px !important;
  line-height: 1 !important;
  margin: 10px 0 0 0 !important;
  border: 1px solid #c84b00 !important;
  background: #c84b00 !important;
  color: #fff !important;
  font-weight: 700 !important;
  font-size: 13px !important;
  text-transform: uppercase !important;
  cursor: pointer !important;
}
.discount-coupon form button:hover {
  background: #a83e00 !important;
  border-color: #a83e00 !important;
}

/* 2. DOPRAVA A PLATBY V KOŠÍKU */
.extras-wrap .extra:not(.step),
.extras-wrap .delivery-time {
  margin-bottom: 12px !important;
  background-color: #f9f9f9 !important;
  border-radius: 6px !important;
  border: 1px solid #eee !important;
  font-size: 15px !important;
  line-height: 1.5 !important;
  color: #222 !important;
}
.extras-wrap .extra:not(.step) {
  padding: 12px 15px 12px 42px !important;
  position: relative !important;
}
.extras-wrap .delivery-time {
  margin-top: -10px !important;
  background-color: transparent !important;
  border: 0 !important;
  padding: 0 15px 12px 42px !important;
  font-size: 14px !important;
}
.extras-wrap .extra strong,
.extras-wrap .delivery-time strong,
.extras-wrap a:not(.btn) {
  color: #c84b00 !important;
  font-weight: 700 !important;
}
.extras-wrap .extra strong,
.extras-wrap .delivery-time strong {
  font-size: 16px !important;
}
.extras-wrap a:not(.btn) {
  text-decoration: underline !important;
}
.extras-wrap .price-range {
  margin-top: 10px !important;
  height: 8px !important;
  border-radius: 999px !important;
  background-color: #e5e5e5 !important;
  overflow: hidden !important;
}
.extras-wrap .price-range div {
  height: 100% !important;
  border-radius: 999px !important;
  background-color: #c84b00 !important;
}

/* ==========================================================================
   VLASTNÉ PREPOJENIE ROZMEROV (NÁHRADA WEBOTVŮRCI) + PONUKA TORX BITOV
   ========================================================================== */

/* Skrytie pôvodnej neprehľadnej roletky Webotvůrci (ak je doplnok ešte zapnutý) */
#c-product-interconnection-wrapper {
  display: none !important;
}

/* Kontajner prepínača rozmerov priamo nad cenou (odľahčený, kompaktný dizajn bez ťažkého rámiku) */
.ds-dim-switcher {
  padding: 8px 0 10px 0;
  margin-bottom: 12px;
  border-top: 1px solid #f1f5f9;
  border-bottom: 1px solid #f1f5f9;
  box-sizing: border-box;
}

.ds-dim-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 7px;
}

.ds-dim-row:last-child {
  margin-bottom: 0;
}

.ds-dim-label {
  flex: 0 0 82px;
  font-size: 12px;
  font-weight: 600;
  color: #64748b;
  line-height: 27px;
  white-space: nowrap;
}

.ds-dim-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  flex: 1;
}

/* Tlačidlá pre Balenie, Priemer a Dĺžku */
.ds-dim-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 27px;
  padding: 2px 8px;
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.2;
  color: #1e293b !important;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 5px;
  text-decoration: none !important;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease;
  user-select: none;
}

.ds-dim-pill:hover,
.ds-dim-pill:focus {
  border-color: #FF7C24;
  background: #fff7ed;
  color: #c2410c !important;
  text-decoration: none !important;
}

.ds-dim-pill.is-active {
  background: #FF7C24 !important;
  border-color: #FF7C24 !important;
  color: #ffffff !important;
  font-weight: 700;
}

/* Odlišný, jemný štýl pre prepínač Balenie (Po kusoch / Celé balenie) */
.ds-dim-pill--variant {
  font-size: 12px;
  min-height: 26px;
  padding: 2px 9px;
  background: #f8fafc;
  border-color: #cbd5e1;
  color: #475569 !important;
}

.ds-dim-pill--variant.is-active {
  background: #334155 !important;
  border-color: #334155 !important;
  color: #ffffff !important;
}

/* Oprava mobilného zobrazenia na detaile produktu (aby políčko množstva neprekrývalo box "Cena pre registrovaných") */
@media (max-width: 767px) {
  .ds-reg-price-box {
    max-width: 100% !important;
    width: 100% !important;
    margin: 8px 0 12px 0 !important;
  }

  .p-detail .add-to-cart,
  .p-info-wrapper .add-to-cart {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: stretch !important;
    gap: 10px !important;
    position: relative !important;
    margin-top: 4px !important;
  }

  .p-detail .add-to-cart .quantity,
  .p-info-wrapper .add-to-cart .quantity {
    position: relative !important;
    bottom: auto !important;
    right: auto !important;
    top: auto !important;
    left: auto !important;
    margin: 0 !important;
    flex: 0 0 103px !important;
    height: 54px !important;
  }

  .p-detail .add-to-cart .btn.add-to-cart-button,
  .p-detail .add-to-cart .btn.btn-cart,
  .p-info-wrapper .add-to-cart .btn.add-to-cart-button,
  .p-info-wrapper .add-to-cart .btn.btn-cart {
    margin-top: 0 !important;
    flex: 1 1 auto !important;
    width: auto !important;
    height: 54px !important;
  }

  .ds-dim-label {
    flex: 0 0 70px;
    font-size: 11.5px;
  }
}
