
@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,600&display=swap');

*{
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    list-style: none;
    text-decoration: none;
}
body,html{
  overflow-x: hidden;
}
body {
  font-family: poppins, sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f4f6f9;
  color: #333;
}
.box-details{
 width: 80%;
 margin:auto  ;
}
.breadcrumb {
  background: #f6f6f6;
  padding: 15px;
  text-align: center;
  margin-top: 100px;
  width: 100%;
}
.breadcrumb h2 {
  margin: 0 0 10px;
}
.breadcrumb a {
  text-decoration: none;
  color: #888;
}

.product-section {
  display: flex;
  gap: 50px;
  padding: 50px;
}

.product-images {
 width: 50%;
}
.main-image {
  width: 100%;
  border: 1px solid #ccc;
  height: 450px;
  object-fit: cover;
}

/* --- Miniatures : 5 visibles + scroll horizontal --- */
.thumbnails {
  display: flex;
  gap: 10px;
  margin-top: 15px;
  width: 100%;
  overflow-x: auto;
  scrollbar-width: none;            /* Firefox */
  scroll-snap-type: x mandatory;    /* snap agréable au défilement */
}

/* Masque la barre de scroll sur WebKit */
.thumbnails::-webkit-scrollbar {
  display: none;
}

/* Chaque miniature occupe exactement 1/5 de la largeur visible
   (on retire 4 gaps*10px de la largeur totale avant de diviser par 5) */
.thumbnails img {
  flex: 0 0 calc((100% - 4 * 10px) / 5);
  height: 90px;
  object-fit: cover;
  cursor: pointer;
  border: 1px solid #ccc;
  border-radius: 8px;
  scroll-snap-align: start;
}

/* État actif (si tu ajoutes la classe .is-active en JS) */
.thumbnails img.is-active {
  border-color: #2c522b;
}

/* --- Mobile --- */
@media (max-width: 600px) {
  /* On garde 5 visibles, mais on rabaisse la hauteur pour mieux rentrer sur petit écran */
  .thumbnails img {
    flex: 0 0 calc((100% - 4 * 10px) / 5);
    height: 70px;
  }
}

.product-info {
  flex: 1;
}
.product-info h3 {
  font-size: 16px;
  margin-bottom: 15px;
}

.product-info #desc{
    font-size: 14px;
}

.price{
 color:#2c522b;
 font-size: 16px;
 font-weight: bold;
 margin-top: 15px;
}
.old-price {
  text-decoration: line-through;
   margin-right: 10px;
}
#saleprice {
  color:#666;
  text-decoration: line-through;
  font-weight: italic;
  margin-left: 10px;

}
.in-stock {
 color:#2c522b;
  font-size:14px;
}
.out-stock {
  color: red;
  font-size: 14px;
}

.volume-buttons {
    margin-top: 20px;
    display: grid;
    grid-template-columns: repeat(6 ,1fr);
}

.volume-buttons button
 {

  padding: 5px 10px;
  margin-right: 10px;
  border: 1px solid #ccc;
  background: #fff;
  cursor: pointer;
  border-radius: 5px;
}
.volume-buttons button:hover{
    background-color: #2c522b ;
    color: #fff;
}
.buttons{
    display: flex;
    margin-top: 20px;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 20px;
    justify-content: space-between;
    /* align-items: center; */
}
 .quantite{
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
 }
.quantite button{
  width: 30px;
  height: 30px;
  background: none;
  padding: 10px;
  background: #ccc;
  cursor: pointer;
  border-radius: 40px;
  display: flex; justify-content: space-between;
  align-items: center;
  border: none;
  gap: 5px;
}

.add-to-cart {
  background: #2c522b;
  color: #fff;
  padding: 10px 25px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}
.social-shares{
  display: flex;
  align-items: center;
  gap: 40px;
}
.social-shares span{
  font-size: 16px;
  font-weight: bold;
}
.social-share {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: center; /* aligne verticalement tous les icônes */
}

.social-share a {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2c522b;
    font-size: 25px; /* taille uniforme pour toutes les icônes */
    text-decoration: none;
      /* hauteur fixe */
}

.social-share a i {
    font-size: 25px;  /* taille de l’icône */
    line-height: 1;
}




.tabs {
  margin: 40px 50px;
  display: flex;
  border-bottom: 2px solid #eee;
}
.tabs div {
  margin-right: 30px;
  padding: 10px;
  cursor: pointer;
  font-weight: bold;
}
.tabs .active {
  border-bottom: 3px solid #f9b234;
}

.review-summary {
  display: flex;
  align-items: center;
  padding: 20px 50px;
}
.review-summary h3 {
  font-size: 24px;
  margin-right: 20px;
}

.review-list {
  padding: 20px 50px;
}
.review-item {
  margin-bottom: 30px;
  border-bottom: 1px solid #eee;
  padding-bottom: 20px;
}
.review-item h4 {
  margin: 0 0 5px;
}
.review-item p {
  margin: 10px 0;
}
.review-images {
  display: flex;
  gap: 10px;
}
.review-images img {
  width: 60px;
  height: 60px;
  border-radius: 8px;
}

  

/* Responsive tablette */
@media (max-width: 992px) {
  .product-section {
    flex-direction: column;
    padding: 30px 20px;
  }

  .volume-buttons {
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }

  .buy-buttons {
    /* flex-direction: column; */
    align-items: stretch;
  }

  .review-summary,
  .review-list,
  .tabs {
    padding: 20px;
    margin: 20px 0;
  }

  .tabs {
    flex-wrap: wrap;
  }
   #product-name{
    font-size: 14px;
  }
 
}

/* Responsive mobile */
@media (max-width: 600px) {
  .box-details {
    width: 95%;
  }

  .breadcrumb {
    font-size: 14px;
    padding: 10px;
    margin-top: 80px;
  }
  .product-images{
    width: 100%;
  }
  .product-section {
    padding: 20px 10px;
    gap: 30px;
  }

  .main-image {
    height:500px;
    object-fit: cover;
    /* max-height: 300px; */
  }

 #product-name{
    font-size: 14px;
  }
  .thumbnails img {
    width: 70px;
    height: 70px;
  }

  .volume-buttons {
    grid-template-columns: repeat(3, 1fr);
  }

  .buy-buttons {
    flex-direction: column;
    gap: 10px;
  }

  .tabs div {
    margin: 5px 10px;
    padding: 8px;
    font-size: 14px;
  }

  .review-summary h3 {
    font-size: 20px;
  }

  .review-images img {
    width: 50px;
    height: 50px;
  }

  /* .social-shares {
    align-items: flex-start;
    gap: 5px;
  } */
}
.simil h2 {
    font-size: 2rem;
    margin-bottom: 30px;
    color:#2c522b;
    text-align: center;
}
/* =============================
Panneau Description (après le border-bottom des .tabs)

* Aucun style inline via JS
* Ouverture/fermeture en togglant la classe .is-open
* Ne modifie pas la disposition .product-section (reste en lignes)
  \============================= \*/

/* Grille 2 colonnes stable (facultatif si déjà présent dans ton HTML) \*/
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
.info-grid >{ min-width: 0; }
@media (max-width: 992px) { .info-grid { grid-template-columns: 1fr; } }

.desc-panel {              
overflow: hidden;
opacity: 0;
background: #fff;
border: 1px solid #e5e7eb;
border-radius: 12px;
box-shadow: 0 8px 20px rgba(0,0,0,.06);
margin-top: 14px;           
}
.desc-panel.is-open {    
opacity: 1;
padding: 20px;       
}
.desc-header { position: relative; padding-right: 34px; }
.desc-header strong { font-size: 16px; }
.desc-close {
position: absolute; right: 0; top: -2px;
background: none; border: 0; cursor: pointer; font-size: 22px; 
 color: #333;
}



.desc-panel .desc-body {
  padding: 0.5rem 0;    /* padding interne pour le texte */
  word-wrap: break-word; /* permet au texte long de se casser */
  overflow-wrap: break-word; 
  white-space: normal;   /* empêche le texte de rester sur une seule ligne */
  line-height: 1.5;
   color: #333;
   font-size: 14px; 
}
