/* === APEXDERM CAROUSELS === */

/* Sekce nadpis */
.homepage-group-title {
  position: relative;
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #1a1a1a;
  margin: 48px 0 28px;
  padding-bottom: 14px;
}
.homepage-group-title::after {
  content: "";
  position: absolute; left: 0; bottom: 0;
  width: 44px; height: 3px;
  background: #a8324a; border-radius: 2px;
}

/* Wrapper */
.products-wrapper.product-slider-holder {
  position: relative;
  padding: 8px 0 56px;
  overflow: visible !important;
}
.product-slider { overflow: hidden; }
.products-block { display: flex; }

/* Karta */
.product-slider .product { padding: 8px; box-sizing: border-box; }

.product-slider .p {
  position: relative;
  background: #fff;
  border: 1px solid #f0e8ea;
  border-radius: 14px;
  overflow: hidden;
  height: 100%;
  display: flex; flex-direction: column;
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.product-slider .p:hover {
  transform: translateY(-3px);
  border-color: #e8dde0;
  box-shadow: 0 12px 28px rgba(168,50,74,.10), 0 2px 8px rgba(0,0,0,.04);
}

/* Schovat zbytečnosti */
.product-slider .p-code,
.product-slider .p-desc,
.product-slider .stars-placeholder,
.product-slider .quantity,
.product-slider .increase-tooltip,
.product-slider .decrease-tooltip { display: none !important; }

/* Obrázek */
.product-slider .p > a.image {
  display: block; position: relative;
  aspect-ratio: 4 / 3;
  background: #fafafa;
  overflow: hidden;
}
.product-slider .p > a.image img {
  width: 100%; height: 100%;
  object-fit: contain; padding: 16px;
  transition: transform .5s ease;
}
.product-slider .p:hover > a.image img { transform: scale(1.06); }

/* Flagy */
.product-slider .flags-extra {
  position: absolute; top: 12px; left: 12px;
  display: flex; flex-direction: column; gap: 6px; z-index: 2;
}
.product-slider .flag {
  display: inline-block;
  padding: 4px 10px;
  background: #a8324a; color: #fff;
  font-size: 10px; font-weight: 600;
  letter-spacing: .05em; text-transform: uppercase;
  border-radius: 999px;
}
.product-slider .flag-freeshipping { background: #2a7a4a; }

/* Vnitřek */
.product-slider .p-in {
  padding: 16px;
  display: flex; flex-direction: column;
  flex: 1; gap: 10px;
}
.product-slider .p-in-in { display: flex; flex-direction: column; gap: 8px; }

/* Název */
.product-slider .name {
  display: -webkit-box;
  -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
  text-decoration: none;
  color: #1a1a1a;
  font-size: 15px; font-weight: 600; line-height: 1.4;
  min-height: 42px;
  text-align: left;
}
.product-slider .p:hover .name { color: #a8324a; }

/* Dostupnost */
.product-slider .ratings-wrapper { font-size: 13px; }
.product-slider .availability { display: flex; align-items: center; gap: 6px; }
.product-slider .availability span:first-child {
  position: relative; padding-left: 14px; font-weight: 500;
}
.product-slider .availability span:first-child::before {
  content: ""; position: absolute; left: 0; top: 50%;
  width: 7px; height: 7px; border-radius: 50%;
  background: currentColor; transform: translateY(-50%);
}
.product-slider .availability-amount { color: #999; font-size: 12px; }

/* Spodní část — cena + tlačítko */
.product-slider .p-bottom {
  margin-top: auto;
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
}
.product-slider .p-bottom > div { display: contents; }
.product-slider .prices { margin: 0; }
.product-slider .price-final strong {
  font-size: 21px; font-weight: 700; color: #1a1a1a;
  letter-spacing: -0.02em; white-space: nowrap;
}

/* Tools */
.product-slider .p-tools { margin: 0; }
.product-slider .pr-action { margin: 0; }

.product-slider .btn-cart,
.product-slider .btn-primary {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 6px;
  height: 40px; padding: 0 18px;
  background: #1a1a1a; color: #fff;
  border: none; border-radius: 10px;
  font-size: 12px; font-weight: 600;
  letter-spacing: .04em; text-transform: uppercase;
  cursor: pointer; text-decoration: none;
  transition: background .2s ease, transform .15s ease;
  white-space: nowrap;
  font-size: 13px;

}
.product-slider .btn-cart::before {
  content: ""; width: 14px; height: 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='21' r='1'/%3E%3Ccircle cx='20' cy='21' r='1'/%3E%3Cpath d='M1 1h4l2.7 13.4a2 2 0 0 0 2 1.6h9.7a2 2 0 0 0 2-1.6L23 6H6'/%3E%3C/svg%3E");
  background-size: contain; background-repeat: no-repeat;
}
.product-slider .btn-cart:hover,
.product-slider .btn-primary:hover { background: #a8324a; }
.product-slider .btn-cart:active { transform: scale(.97); }

.product-slider .p-bottom.single-button .btn-primary {
  width: 100%; flex: 1;
}

/* === NAVIGACE === */
.product-slider-navigation {
  position: absolute; top: 50%;
  transform: translateY(-50%);
  width: 40px; height: 40px;
  background: #fff;
  border: none;
  border-radius: 50%;
  cursor: pointer; z-index: 10;
  font-size: 0; color: transparent;
  padding: 0;
  opacity: 0;
  box-shadow:
    0 2px 6px rgba(0,0,0,.06),
    0 10px 24px rgba(0,0,0,.08);
  transition: opacity .3s ease, transform .25s cubic-bezier(.4,0,.2,1), box-shadow .25s ease;
}

/* Šipka jako čisté SVG na pozadí */
.product-slider-navigation.navigation-prev {
  left: 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231a1a1a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 18l-6-6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 18px 18px;
}
.product-slider-navigation.navigation-next {
  right: 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231a1a1a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18l6-6-6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 18px 18px;
}

/* Zbav se starých pseudo-elementů z předchozí verze */
.product-slider-navigation::before,
.product-slider-navigation::after { display: none !important; }

/* Zobrazit na hover slideru */
.products-wrapper.product-slider-holder:hover .product-slider-navigation {
  opacity: 1;
}

/* Hover — tmavá s bílou šipkou */
.product-slider-navigation:hover {
  box-shadow:
    0 4px 12px rgba(0,0,0,.12),
    0 16px 32px rgba(168,50,74,.20);
  transform: translateY(-50%) scale(1.1);
}
.product-slider-navigation.navigation-prev:hover {
  background-color: #1a1a1a;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 18l-6-6 6-6'/%3E%3C/svg%3E");
}
.product-slider-navigation.navigation-next:hover {
  background-color: #1a1a1a;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18l6-6-6-6'/%3E%3C/svg%3E");
}

.product-slider-navigation:active { transform: translateY(-50%) scale(1.02); }

@media (max-width: 767px) {
  .product-slider-navigation { display: none !important; }
}

/* === PAGINATION === */
.product-slider-pagination {
  display: flex; justify-content: center; gap: 8px;
  margin-top: 24px;
}
.pagination-button {
  width: 8px; height: 8px;
  padding: 0; border: none;
  background: #d8cfd2;
  border-radius: 50%;
  font-size: 0; color: transparent;
  cursor: pointer;
  transition: all .25s ease;
}
.pagination-button:hover { background: #a8324a; opacity: .6; }
.pagination-button.active {
  background: #a8324a;
  width: 24px; border-radius: 4px;
}

/* === Desktop tlačítka — sjednocený plný styl === */
.product-slider .p-tools .btn-cart,
.product-slider .p-tools .btn-primary {
  background: #1a1a1a !important;
  color: #fff !important;
  border: none !important;
  outline: none !important;
  border-radius: 10px !important;
  height: 40px !important;
  padding: 0 18px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  letter-spacing: .04em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  white-space: nowrap !important;
  box-sizing: border-box !important;
  cursor: pointer;
  transition: background .2s ease, transform .15s ease !important;
}

.product-slider .p-tools .btn-cart:hover,
.product-slider .p-tools .btn-primary:hover {
  background: #a8324a !important;
  color: #fff !important;
}

.product-slider .p-tools .btn-cart:active,
.product-slider .p-tools .btn-primary:active {
  transform: scale(.97);
}

/* Pokud je karta single-button (jen Detail), tlačítko kompaktní + vycentrované */
.product-slider .p-bottom.single-button {
  display: flex !important;
  justify-content: center !important;
}
.product-slider .p-bottom.single-button > div[data-micro="offer"] {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 12px !important;
  width: 100% !important;
}
.product-slider .p-bottom.single-button .prices {
  text-align: center !important;
  margin: 0 !important;
}
.product-slider .p-bottom.single-button .p-tools {
  margin: 0 !important;
  display: flex !important;
  justify-content: center !important;
}
.product-slider .p-bottom.single-button .btn-primary {
  width: auto !important;
  min-width: 140px !important;
  flex: 0 0 auto !important;
  padding: 0 32px !important;
}
/* === MOBILE === */
@media (max-width: 767px) {
 /* === LAYOUT — cena nad tlačítkem === */
.product-slider .p-bottom,
.product-slider .p-bottom > div[data-micro="offer"] {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  justify-content: flex-start !important;
  gap: 10px !important;
  width: 100% !important;
}

.product-slider .prices {
  margin: 0 !important;
  text-align: center !important;
}

.product-slider .price-final strong {
  font-size: 18px !important;
  white-space: nowrap;
}

.product-slider .p-tools {
  margin: 0 !important;
  width: 100% !important;
  display: block !important;
}

.product-slider .pr-action {
  margin: 0 !important;
  width: 100% !important;
  display: block !important;
}

/* === Tlačítka — full-width pill, sjednocená === */
.product-slider .p-tools .btn-cart,
.product-slider .p-tools .btn-primary {
  width: 100% !important;
  height: 40px !important;
  padding: 0 12px !important;
  border-radius: 10px !important;
  border: none !important;
  background: #1a1a1a !important;
  color: #fff !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  letter-spacing: .05em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
  transition: background .2s ease !important;
}

.product-slider .p-tools .btn-cart:hover,
.product-slider .p-tools .btn-primary:hover {
  background: #a8324a !important;
}
.product-slider .p-tools .btn-cart:active,
.product-slider .p-tools .btn-primary:active {
  transform: scale(.98);
}

/* Text košíku ponechat, přidat ikonu vlevo */
.product-slider .p-tools .btn-cart span {
  display: inline !important;
  font-size: 12px !important;
  color: #fff !important;
}

.product-slider .p-tools .btn-cart::before {
  content: "" !important;
  display: inline-block !important;
  width: 15px !important;
  height: 15px !important;
  flex-shrink: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='21' r='1'/%3E%3Ccircle cx='20' cy='21' r='1'/%3E%3Cpath d='M1 1h4l2.7 13.4a2 2 0 0 0 2 1.6h9.7a2 2 0 0 0 2-1.6L23 6H6'/%3E%3C/svg%3E") center/contain no-repeat !important;
}

.product-slider .p-tools .btn-primary::before { display: none !important; }

.product-slider .quantity { display: none !important; }
}
