/* ============================================
   ZINABEL - PRODUCT PAGE CUSTOM CSS
   ============================================ */

/* Désactiver la popup image produit (garder le hover zoom) */
#product-modal {
    display: none !important;
}
.images-container .layer[data-target="#product-modal"] {
    display: none !important;
}


/* Product Page Layout */
.product-detail {
  padding: 40px 0;
}
.product-detail > .row {
  position: relative;
}

/* Category Badge */
.product-manufacturer {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #999;
  margin-bottom: 8px;
}

/* Product Title */
.product-title h1 {
  font-size: 1.8rem;
  font-weight: 700;
  color: #FF6B9D;
  margin-bottom: 15px;
  line-height: 1.3;
}

/* Product Rating Stars */
.product-reviews {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.product-reviews .stars {
  display: flex;
  gap: 3px;
  font-size: 1rem;
}

.product-reviews .star {
  color: #FFD700;
}

.product-reviews .star.empty {
  color: #ddd;
}

.product-reviews .reviews-count {
  font-size: 0.9rem;
  color: #999;
}

.product-reviews .reviews-count a {
  color: #999;
  text-decoration: none;
}

.product-reviews .reviews-count a:hover {
  color: #FF6B9D;
  text-decoration: underline;
}

/* Product Price */
.product-prices {
  margin-bottom: 30px;
  padding: 20px 0 0 !important;
}
.product-prices div {
  margin-bottom: 0 !important;
}

.product-price {
  font-size: 2rem;
  font-weight: 700;
  color: #FF6B9D;
  margin-bottom: 5px;
}

.product-price .current-price {
  display: flex;
  align-items: center;
  gap: 12px;
}

.product-price .regular-price {
  font-size: 1.2rem;
  color: #999;
  text-decoration: line-through;
  font-weight: 400;
}

.product-discount-badge {
  background-color: #FF0000;
  color: white;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.product-tax-label {
  font-size: 0.85rem;
  color: #999;
}

/* Product Variants - Color Selector */
.product-variants {
  margin-bottom: 25px;
  padding-top: 10px;
}

.product-variants .variant-label {
  font-weight: 600;
  font-size: 0.95rem;
  color: #333;
  margin-bottom: 12px;
  display: block;
}

.product-variants .color-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.product-variants .color-option {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.product-variants .color-option:hover,
.product-variants .color-option.active {
  border-color: #FF6B9D;
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px #FF6B9D;
}

.product-variants .color-option input {
  display: none;
}

/* Quantity Selector */
.product-quantity {
  margin-bottom: 25px;
}

.product-quantity .quantity-label {
  font-weight: 600;
  font-size: 0.95rem;
  color: #333;
  margin-bottom: 12px;
  display: block;
}

.qty-selector {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 15px;
}

.qty-controls {
  display: flex;
  align-items: center;
  border: 1px solid #ddd;
  border-radius: 4px;
  overflow: hidden;
}

.qty-btn {
  width: 35px;
  height: 40px;
  border: none;
  background-color: #f9f9f9;
  color: #333;
  font-size: 1.2rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

.qty-btn:hover {
  background-color: #FF6B9D;
  color: white;
}

.qty-input {
  width: 60px;
  height: 40px;
  border: none;
  border-left: 1px solid #ddd;
  border-right: 1px solid #ddd;
  text-align: center;
  font-size: 1rem;
  font-weight: 600;
}

.stock-info {
  font-size: 0.85rem;
  color: #28a745;
  margin-left: 10px;
}

/* Add to Cart Button */
.product-add-to-cart {
  display: flex;
  gap: 10px;
  margin-bottom: 25px;
}

.add-to-cart {
  flex: 1;
  background-color: #FF6B9D;
  color: white;
  border: none;
  padding: 15px 30px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.add-to-cart:hover {
  background-color: #e55a8f;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(255, 107, 157, 0.3);
}

.add-to-cart svg {
  width: 20px;
  height: 20px;
}

.wishlist-btn {
  width: 50px;
  height: 50px;
  border: 2px solid #FF6B9D;
  background-color: white;
  color: #FF6B9D;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wishlist-btn:hover {
  background-color: #FF6B9D;
  color: white;
}

.wishlist-btn svg {
  width: 22px;
  height: 22px;
}

/* Product Features */
.product-features {
  background-color: #f9f9f9;
  border-radius: 4px;
  padding: 20px;
  margin-bottom: 25px;
}

.product-features ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.product-features li {
  padding: 8px 0;
  font-size: 0.9rem;
  color: #666;
  position: relative;
  padding-left: 25px;
}

.product-features li::before {
  content: '✓';
  color: #FF6B9D;
  font-weight: 700;
  position: absolute;
  left: 0;
  top: 8px;
}

/* Payment Icons */
.payment-methods {
  display: flex;
  gap: 15px;
  margin-bottom: 25px;
  padding: 15px 0;
  border-top: 1px solid #eee;
  border-bottom: 1px solid #eee;
}

.payment-methods img {
  height: 30px;
  width: auto;
  object-fit: contain;
}

/* Service Icons */
.product-services {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 30px;
}

.service-item {
  text-align: center;
  flex: 1;
}

.service-item svg,
.service-item img {
  width: 40px;
  height: 40px;
  margin-bottom: 10px;
  color: #FF6B9D;
}

.service-item .service-title {
  font-size: 0.75rem;
  color: #FF6B9D;
  font-weight: 600;
  line-height: 1.3;
}

/* Social Share Buttons */
.product-social-sharing {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 20px;
}

.social-share-btn {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.social-share-btn.facebook {
  background-color: #3b5998;
  color: white;
}

.social-share-btn.twitter {
  background-color: #1da1f2;
  color: white;
}

.social-share-btn.pinterest {
  background-color: #bd081c;
  color: white;
}

.social-share-btn.whatsapp {
  background-color: #25d366;
  color: white;
}

.social-share-btn.email {
  background-color: #FF6B9D;
  color: white;
}

.social-share-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Product Tabs */
.product-tabs {
  margin-top: 50px;
}

.product-tabs .nav-tabs {
  border-bottom: 2px solid #eee;
  margin-bottom: 30px;
}

.product-tabs .nav-tabs .nav-link {
  border: none;
  border-bottom: 3px solid transparent;
  color: #666;
  font-weight: 600;
  padding: 15px 25px;
  text-transform: uppercase;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

.product-tabs .nav-tabs .nav-link:hover {
  color: #FF6B9D;
  border-bottom-color: #FF6B9D;
}

.product-tabs .nav-tabs .nav-link.active {
  color: #FF6B9D;
  border-bottom-color: #FF6B9D;
  background-color: transparent;
}

.product-tabs .tab-content {
  padding: 0 0 20px;
}

/* Accordion mobile - Design */
@media (max-width: 1023px) {
  .products-accordion {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #f0f0f0;
  }

  .products-accordion .card {
    border: none;
    border-bottom: 1px solid #f0f0f0;
    margin: 0;
    border-radius: 0;
  }

  .products-accordion .card:last-child {
    border-bottom: none;
  }

  .products-accordion .card-header {
    background: #fff;
    padding: 0;
    border: none;
  }

  .products-accordion .card-header a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    font-size: 14px;
    font-weight: 700;
    color: #333;
    text-decoration: none;
    text-transform: uppercase;
    font-family: 'Montserrat', sans-serif;
    transition: background 0.2s;
  }

  .products-accordion .card-header a::after {
    content: '+';
    font-size: 15px;
    font-weight: 300;
    color: #fe889f;
    transition: transform 0.3s;
    top: 50%;
    transform: translate(-50%, -50%);
    right: 8px;
  }

  .products-accordion .card-header a[aria-expanded="true"]::after {
    content: '−';
  }

  .products-accordion .card-header a[aria-expanded="true"] {
    color: #fe889f;
    background: #fef5f7;
  }

  .products-accordion .card-block {
    padding: 15px 20px;
    font-size: 14px;
    line-height: 1.6;
    color: #555;
  }

  /* Description ouverte par defaut uniquement si classe .in ou .show */
  #collapsedescription.in,
  #collapsedescription.show {
    display: block;
    height: auto;
  }
}

.section-header {
  text-align: center;
  margin-bottom: 30px;
}

.related-products-section {
  margin: 40px 0;
}

/* Related Products */
.vous-aimerez-aussi {
  margin-top: 50px;
  padding-top: 40px;
  border-top: 1px solid #eee;
}

.vous-aimerez-aussi h3 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #FF6B9D;
  margin-bottom: 30px;
  text-align: left;
}

.related-product-item {
  background-color: #fff;
  border: 1px solid #eee;
  border-radius: 4px;
  padding: 15px;
  transition: all 0.3s ease;
  text-align: center;
}

.related-product-item:hover {
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transform: translateY(-5px);
}

.related-product-item img {
  max-width: 100%;
  height: auto;
  margin-bottom: 15px;
}

.related-product-item .product-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: #333;
  margin-bottom: 10px;
}

.related-product-item .product-rating {
  display: flex;
  justify-content: center;
  gap: 3px;
  margin-bottom: 10px;
  font-size: 0.85rem;
  color: #FFD700;
}

.related-product-item .product-price {
  font-size: 1.2rem;
  font-weight: 700;
  color: #FF6B9D;
  margin-bottom: 15px;
}

.related-product-item .btn-add-to-cart {
  background-color: #FF6B9D;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 4px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  transition: all 0.3s ease;
}

.related-product-item .btn-add-to-cart:hover {
  background-color: #e55a8f;
}

/* Product Images Gallery */
.product-images {
  position: relative;
}

.product-images .main-image {
  width: 100%;
  border-radius: 4px;
  margin-bottom: 15px;
}

.product-images .thumbnails {
  display: flex;
  gap: 10px;
  overflow-x: auto;
}

.product-images .thumbnail {
  width: 80px;
  height: 80px;
  border: 2px solid #eee;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  overflow: hidden;
}

.product-images .thumbnail:hover,
.product-images .thumbnail.active {
  border-color: #FF6B9D;
}

.product-images .thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Sticky product image placeholder */
.sticky-img-placeholder {
  pointer-events: none;
}

/* Responsive Design */
@media (max-width: 768px) {
  .product-title h1 {
    font-size: 1.4rem;
  }
  
  .product-price {
    font-size: 1.6rem;
  }
  
  .product-services {
    flex-wrap: wrap;
  }
  
  .service-item {
    flex: 0 0 50%;
    margin-bottom: 15px;
  }
  
  .product-add-to-cart {
    flex-direction: column;
  }
  
  .wishlist-btn {
    width: 100%;
    height: 50px;
  }
}

@media (max-width: 576px) {
  .product-detail {
    padding: 20px 0;
  }
  
  .payment-methods {
    flex-wrap: wrap;
  }
  
  .product-tabs .nav-tabs .nav-link {
    padding: 10px 15px;
    font-size: 0.8rem;
  }
}

/* Masquer référence produit + stock */
.product-reference,
.stock-qty,
.product-out-of-stock,
.leo-cart-item-info .product-discount .discount-percentage {
    display: none !important;
}

/* Readmore - Voir Plus / Voir Moins */
.readmore-wrapper {
  position: relative;
}
.readmore-content--collapsed {
  max-height: 250px;
  overflow: hidden;
  transition: max-height 0.5s ease;
}
.readmore-content--expanded {
  max-height: none !important;
}
.readmore-fade {
  position: absolute;
  bottom: 40px;
  left: 0;
  right: 0;
  height: 100px;
  background: linear-gradient(transparent, #fff);
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.readmore-content--expanded ~ .readmore-fade {
  opacity: 0;
}
.btn-voir-plus {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 15px auto 0;
  padding: 10px 28px;
  background: none;
  border: 1.5px solid #FF6B9D;
  border-radius: 25px;
  color: #FF6B9D;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}
.btn-voir-plus:hover {
  background: #FF6B9D;
  color: #fff;
}
.btn-voir-plus .voir-plus-arrow {
  transition: transform 0.3s ease;
  flex-shrink: 0;
}
.btn-voir-plus.active .voir-plus-arrow {
  transform: rotate(180deg);
}
/* Hide button if content is short enough */
.readmore-wrapper.no-truncate .readmore-fade,
.readmore-wrapper.no-truncate .btn-voir-plus {
  display: none !important;
}

/* Masquer onglets Détails et Livraison (tabs desktop + accordion mobile) */
.product-tabs .nav-item:has(a[href="#product-details"]),
.product-tabs .nav-item:has(a[href="#livraison"]) {
    display: none !important;
}
#tab-content > #product-details,
#tab-content > #livraison {
    display: none !important;
}
#acc-product-detail,
#acc-livraison {
    display: none !important;
}

/* Short description + title - afficher en entier sur page produit */
.product-detail .product-description-short,
#product .product-description-short,
.page-product .product-description-short,
.product-detail .product-title,
#product .product-title,
.page-product .product-title {
    display: block !important;
    -webkit-line-clamp: unset !important;
    -webkit-box-orient: unset !important;
    max-height: none !important;
    height: auto !important;
    overflow: visible !important;
    text-overflow: unset !important;
}

.product-tabs.tabs .tab-pane {
    padding-top: 0;
}

/* Tab Readmore system */
.tab-readmore-wrapper {
    position: relative;
}
.tab-readmore-content {
    overflow: hidden;
    transition: max-height 0.4s ease;
}
.tab-readmore--collapsed {
    max-height: 250px;
}
.tab-readmore-fade {
    position: absolute;
    bottom: 40px;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(to bottom, rgba(255,255,255,0) 0%, rgba(255,255,255,1) 100%);
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.tab-readmore--expanded ~ .tab-readmore-fade {
    opacity: 0;
}
.btn-tab-voir-plus {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 15px auto 0;
    padding: 8px 24px;
    background: none;
    border: 1px solid #e0e0e0;
    border-radius: 25px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: #EA6B8E;
    transition: all 0.3s ease;
}
.btn-tab-voir-plus:hover {
    border-color: #EA6B8E;
    background: #fff0f5;
}
.btn-tab-voir-plus .voir-plus-arrow {
    transition: transform 0.3s ease;
}
.btn-tab-voir-plus.active .voir-plus-arrow {
    transform: rotate(180deg);
}
/* Hide button if content is short */
.tab-readmore-wrapper.no-truncate .tab-readmore-fade,
.tab-readmore-wrapper.no-truncate .btn-tab-voir-plus {
    display: none !important;
}
.tab-readmore-wrapper.no-truncate .tab-readmore-content {
    max-height: none !important;
}
.ets_rv_wrap_content .alert-info {
    display: none;
}

@media (max-width: 768px) {
    body#product .featured-products .products.crossselling-carousel {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        gap: 8px;
        padding-bottom: 10px;
        scrollbar-width: none;
    }
    body#product .featured-products .products.crossselling-carousel::-webkit-scrollbar {
        display: none;
    }
    body#product .featured-products .crossselling-carousel .crossselling-slide {
        flex: 0 0 45% !important;
        min-width: 45% !important;
        max-width: 45% !important;
        scroll-snap-align: start;
    }
    body#product .featured-products .crossselling-carousel .crossselling-slide {
        display: flex;
    }
    body#product .featured-products .crossselling-carousel .crossselling-slide .product,
    body#product .featured-products .crossselling-carousel .crossselling-slide .product-miniature,
    body#product .featured-products .crossselling-carousel .crossselling-slide .thumbnail-container {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        height: 100% !important;
        display: flex;
        flex-direction: column;
    }
    body#product .featured-products .crossselling-carousel .crossselling-slide .product-meta {
        flex: 1;
        display: flex;
        flex-direction: column;
    }
    body#product .featured-products .crossselling-carousel .crossselling-slide .button-container.cart {
        margin-top: auto;
    }
}

@media (max-width: 768px) {
    .product-details {
        padding: 25px 12px !important;
    }
    .slider-nav.prev {
        left: -15px !important;
    }
    .slider-nav.next {
        right: -15px !important;
    }
    h4.title_block {
        margin-bottom: 0;
    }
    .ets_rv_wrap_content .alert-info {
        margin-bottom: 30px;
    }
    section.featured-products {
        margin-top: 15px !important;
    }
    section.featured-products.clearfix.mt-3 > h2 {
        margin-bottom: 30px;
    }
}

@media (max-width: 1024px) {
    #product h1.product-title {
        font-size: 24px !important;
        margin-top: 10px;
    }
}
