/* =====================
   VARIABLES & BASE
===================== */
:root{
  --main-green:#2f7030;
  --dark-green:#245824;
  --muted-gray:#ececec;
  --header-height:64px;
  --cart-badge-bg:#f4c000;
}

/* =====================
   BASE
===================== */
*{box-sizing:border-box; margin:0; padding:0;}
body{
  font-family:"Segoe UI",system-ui,-apple-system,Roboto,Arial,sans-serif;
  background:#f6f7f9;
  color:#222;
}

/* =====================
   HEADER
===================== */
.header-container{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:12px 28px;
  background:var(--main-green);
  color:#fff;
  position:sticky;
  top:0;
  z-index:1000;
}

@media(max-width:768px){
  .header-container{
    padding:12px 10px; /* réduit à 12px à gauche et droite */
  }
}

.logo-img{
  height: 36px;        /* hauteur actuelle */
  width: auto;         /* garde les proportions */
  transform: scale(1.5);
  transform-origin: left center;
}

nav{flex:1; display:flex; justify-content:center;}
nav ul{
  display:flex;
  gap:24px;
  list-style:none;
}
nav a{
  color:#fff;
  font-weight:600;
  font-size:1.3rem;
  text-decoration:none;
  padding:6px 10px;
  border-radius:6px;
  transition:0.2s;
}
nav a:hover{background:var(--dark-green); color:#fff;}

.actions{
  display:flex;
  align-items:center;
  gap:16px;
}

.btn-login{
  padding: 10px 20px;          /* ⬅️ plus gros */
  border-radius: 10px;
  border: none;
  cursor: pointer;
  font-weight: 800;
  font-size: 1rem;             /* ⬅️ texte plus lisible */
  background: #fff;
  color: var(--main-green);
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
  transition: all 0.25s ease;
}

/* Hover élégant */
.btn-login:hover{
  background: var(--muted-gray);
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.2);
}

/* Mobile */
@media(max-width:768px){
  .btn-login{
    padding: 9px 16px;
    font-size: 0.95rem;
  }
}

/* =====================
   BOUTON PANIER
===================== */
.btn-cart-icon{
  position: relative;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Image panier */
.cart-icon-img{
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 10px; /* 🔥 bords arrondis */
  background: transparent;
  transition: transform 0.25s ease, filter 0.25s ease;
}

/* Glow au hover */
.btn-cart-icon:hover .cart-icon-img{
  filter: drop-shadow(0 0 6px rgba(255, 200, 0, 0.8))
          drop-shadow(0 0 12px rgba(255, 200, 0, 0.4));
  transform: scale(1.08);
}

@keyframes cart-shake {
  0%   { transform: translateX(0) rotate(0); }
  15%  { transform: translateX(-2px) rotate(-3deg); }
  30%  { transform: translateX(2px) rotate(3deg); }
  45%  { transform: translateX(-2px) rotate(-3deg); }
  60%  { transform: translateX(2px) rotate(3deg); }
  75%  { transform: translateX(-1px) rotate(-2deg); }
  100% { transform: translateX(0) rotate(0); }
}

.cart-shake{
  animation: cart-shake 0.45s ease;
}



/* =====================
   BADGE PANIER
===================== */
.cart-count{
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  font-size: 0.75rem;
  font-weight: 800;
  color: #fff;
  background: #e63946;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  transform: scale(0);
  transition: transform 0.25s ease;
}

.cart-count.show{
  transform: scale(1);
  animation: bounce 0.3s;
}

/* animation badge */
@keyframes bounce{
  0%{transform:scale(0.3);}
  50%{transform:scale(1.2);}
  70%{transform:scale(0.95);}
  100%{transform:scale(1);}
}


/* =====================
   MENU HAMBURGER
===================== */
.menu-toggle{
  font-size:28px;
  background:none;
  border:none;
  color:#fff;
  cursor:pointer;
  position:relative;
  top:2px;
  display:none;
}

/* Responsive */
@media(max-width: 992px) {
  nav {
    position: absolute;
    top: 60px;
    left: 0;
    width: 100%;
    background: var(--main-green);
    flex-direction: column;
    align-items: center;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
  }

  nav.open {
    max-height: 500px;
  }

  nav ul {
    flex-direction: column;
    gap: 12px;
    padding: 16px 0;
  }

  .menu-toggle {
    display: block;
  }

  .actions {
    gap: 8px;
  }
}



/* ===================== RESPONSIVE ===================== */
@media (max-width: 992px) {
  nav {
    position: absolute;
    top: var(--header-height);
    left: 0;
    width: 100%;
    background: var(--main-green);
    overflow: hidden;
    max-height: 0;
    flex-direction: column;
    align-items: center;
    transition: max-height 0.3s ease;
  }

  nav.open { max-height: 500px; } /* ajuste selon nb liens */
  nav ul { flex-direction: column; gap: 12px; padding: 16px 0; }

  .menu-toggle { display: block; }

  nav a { font-size: 1.2rem; }
}

/* Mobile align actions right */
@media (max-width: 768px) {
  .actions { gap: 8px; }
}


/* Hamburger & mobile nav */
@media(max-width:768px){
  nav{display:none; position:absolute; top:64px; left:0; right:0; background:var(--main-green);}
  nav.open{display:flex; flex-direction:column; padding:16px 0;}
  nav ul{flex-direction:column; gap:14px;}
  .menu-toggle{display:block;}
}

/* =====================
   PAGINATION
===================== */
.pagination{
  display:flex;
  justify-content:center;
  gap:8px;
  margin:30px 0;
  flex-wrap:wrap;
}

.pagination a{
  display:inline-block;
  padding:8px 12px;
  background:#f0f0f0;
  color:#222;
  border-radius:6px;
  text-decoration:none;
  font-weight:600;
  transition: background 0.2s, color 0.2s;
}

.pagination a:hover,
.pagination a.active{
  background: var(--main-green);
  color:#fff;
}

.pagination a.active{
  pointer-events:none;
}

/* =====================
   PRODUITS
===================== */
.products-wrap{
  max-width:1560px;
  margin:auto;
  padding:10px 16px;
}

.products{
  display:grid;
  gap:20px;
  grid-template-columns:repeat(6,1fr);
}

/* Product card */
.product{
  background:#fff;
  border-radius:12px;
  padding:16px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  box-shadow:0 6px 20px rgba(0,0,0,0.08);
  transition:transform 0.2s, box-shadow 0.2s;
  position:relative;
  min-height:380px;
}

.product:hover{
  transform:translateY(-4px);
  box-shadow:0 10px 25px rgba(0,0,0,0.12);
}

.product-img{
  width:100%;
  height:180px;
  object-fit:contain;
  background:#fafafa;
  border-radius:10px;
}

.product h3{
  margin:12px 0 6px;
  font-size:1.05rem;
  line-height:1.3;
  min-height:2.6em;
}

.product-desc{
  font-size:0.85rem;
  color:#666;
  flex-grow:1;
  margin-bottom:12px;
}

/* Price & promo */
.price, .product .old{
  font-size:1.1rem;
  font-weight:800;
}

.price{ color:var(--main-green); }

.price{ font-size:1.3rem; font-weight:800; }

.product .old{
  color:#999;
  text-decoration:line-through;
  margin-left:8px;
}

.old{
  text-decoration:line-through;
  font-weight: bold;
  font-size:1.1rem;
}

.product .promo-badge{
  position:absolute;
  top:10px;
  left:10px;
  background:var(--main-green);
  color:#fff;
  padding:5px 8px;
  font-weight:700;
  border-radius:5px;
  font-size:0.85rem;
  z-index:10;
}




/* Actions */
.product-actions{
  display:flex;
  gap:10px;
  margin-top:auto;
}

.product-actions .btn{
  flex:1;
  padding:10px 8px;
  border-radius:8px;
  font-weight:700;
  cursor:pointer;
  text-align:center;
}

.btn-details{ 
  background:var(--muted-gray); 
  color:#222; 
  align-items: center;
}




/* =====================
   GRID RESPONSIVE
===================== */
@media(max-width:1600px){ .products{ grid-template-columns:repeat(5,1fr); } }
@media(max-width:1350px){ .products{ grid-template-columns:repeat(4,1fr); } }
@media(max-width:1100px){ .products{ grid-template-columns:repeat(3,1fr); } }
@media(max-width:800px){  .products{ grid-template-columns:repeat(2,1fr); gap: 14px 14px; } }
@media(max-width:500px){  .products{ grid-template-columns:repeat(2,1fr); gap: 14px 14px; } }
@media(max-width:360px){  .products{ grid-template-columns:1fr; gap: 14px 14px; } }

@media(max-width:768px){
  .product{
    padding: 12px 10px;
  }
}





.add-to-cart-wrapper {
  display: flex;
  justify-content: flex-start;
  width: 100%;
}





/* =====================
   BOUTON PANIER GÉNÉRAL
===================== */
.btn-cart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 16px;
  font-size: 16px;
  font-weight: 700;
  border-radius: 8px;
  background-color: var(--main-green, #28a745);
  color: #fff;
  border: none;
  cursor: pointer;
  transition: background-color 0.3s, transform 0.2s;
}

.btn-cart:hover {
  background-color: #218838;
  transform: translateY(-2px);
}

.btn-cart:active {
  transform: translateY(0);
}

.btn-cart-text {
  display: inline-block;
}

/* =====================
   MOBILE
===================== */
@media (max-width: 768px) {

  /* Liste produits : bouton carré, texte caché */
  .products .btn-cart {
    width: 44px;
    height: 44px;
    padding: 0;
    justify-content: center;
    font-size: 18px;
  }

  .products .btn-cart-text {
    display: none;  /* texte caché en mobile liste produits */
  }

  /* Page détail : bouton garde texte, s’adapte */
  .detail.btn-cart {
    width: auto;
    height: auto;
    padding: 10px 16px;
    font-size: 16px;
    justify-content: center;
  }

  .detail.btn-cart .btn-cart-text {
    display: inline-block; /* texte visible */
  }
}



.btn-cart .cart-icon {
  font-size: 18px;
}






/* =====================
   FICHE PRODUIT
===================== */
.container{
  max-width:1200px;
  margin:40px auto;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:40px;
  padding:0 20px;
}

@media(max-width:900px){ .container{ grid-template-columns:1fr; } }

.main-img{
  width:100%;
  max-height:420px;
  object-fit:contain;
  background:#fff;
  border-radius:12px;
}

.thumbs{
  display:flex;
  gap:10px;
  margin-top:12px;
  flex-wrap:wrap;
}

.thumbs img{
  width:70px;
  height:70px;
  object-fit:cover;
  border-radius:8px;
  cursor:pointer;
}



/* =====================
   QUANTITÉ
===================== */
.qty{
  display:flex;
  gap:10px;
  margin:20px 0;
}
.qty button{
  width:36px;
  height:36px;
  font-weight:800;
}

/* =====================
   PANIER LATÉRAL
===================== */
.cart-sidebar{
  position:fixed;
  top:0;
  right:-420px;
  width:380px;
  height:100%;
  background:#fff;
  transition:right .35s ease;
  z-index:10000;
  display:flex;
  flex-direction:column;
}

.cart-header{
  background:var(--main-green);
  color:#fff;
  padding:16px;
  display:flex;
  justify-content:space-between;
}










.cart-footer{
  padding:16px;
  border-top:1px solid #eee;
  background:#fafafa;
}

/* =====================
   NEWSLETTER / FOOTER
===================== */
.newsletter {
  background: #f8fdf8;
  text-align: center;
  padding: 24px 16px;
  border-top: 1px solid #e0e0e0;
}
.newsletter h3 { color: var(--main-green); font-size: 1.2rem; margin-bottom: 6px; }
.newsletter-form { display: flex; justify-content: center; gap: 8px; }
.newsletter-form input { padding:8px 12px; border-radius:8px; border:2px solid var(--main-green); width:260px; }
.newsletter-form button { padding:8px 14px; border-radius:8px; background:var(--main-green); color:#fff; border:0; font-weight:700; cursor:pointer; }


footer{
  background:var(--main-green);
  color:#fff;
  text-align:center;
  padding:40px 20px;
  font-size:0.95rem;
}
.footer-content{
  max-width:1200px;
  margin:auto;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:16px;
}
.footer-links{
  list-style:none;
  display:flex;
  flex-wrap:wrap;
  gap:20px;
  justify-content:center;
  padding:0;
}
.footer-links li a{
  color:#fff;
  text-decoration:none;
  font-weight:600;
  font-size:1rem;
  padding:4px 8px;
  border-radius:6px;
  transition:0.2s;
}
.footer-links li a:hover{
  background:var(--dark-green);
  color:#fff;
}
footer p{margin:0; font-size:0.9rem; color:#ececec;}

/* Responsive footer */
@media(max-width:600px){
  .footer-links{flex-direction:column; gap:12px;}
}




/* =====================
   IMAGE PRODUIT (SANS ZOOM)
===================== */
.image-viewer {
  width: 100%;
  height: 420px;              /* hauteur fixe */
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.image-viewer .promo-badge {
  position: absolute;
  top: 12px;
  right: 12px;           /* au lieu de left:12px */
  background-color: var(--main-green);
  color: #fff;
  padding: 6px 10px;
  font-weight: 800;
  border-radius: 6px;
  font-size: 0.9rem;
  z-index: 20;
  box-shadow: 0 4px 10px rgba(0,0,0,0.25);
}

/* Image principale */
.image-viewer img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.4s ease;
  transform-origin: center center;
}

/* 🔽 Mobile : zone image plus petite */
@media(max-width:768px){
  .image-viewer{
    height:320px;      /* ⬅️ réduit encore */
  }
}


.back-link {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--muted-gray);
  color: #222;
  padding: 6px 10px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  z-index: 30; /* au-dessus du badge */
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
  transition: background 0.2s ease;
}

.back-link:hover {
  background: #e0e0e0;
}


.search-bar {
  background: #f8fdf8;
  text-align: center;
  padding: 24px 16px;
  border-bottom: 1px solid #e0e0e0;
  border-top: 1px solid #e0e0e0;
  margin-bottom: 30px;
}

.search-bar h3 { color: var(--main-green); font-size: 1.2rem; margin-bottom: 6px; }


/* Formulaire de recherche - Disposition par défaut */
.search-form {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
  flex-wrap: wrap; /* Permet au contenu de s'ajuster sur des écrans plus petits */
  width: 100%;
  max-width: 900px; /* Largeur maximale sur grands écrans */
  margin: 0 auto;
}

/* Champ de recherche */
.search-input {
  padding: 8px 12px;
  width: 200px; /* Limite la largeur sur grands écrans */
  border-radius: 6px;
  border: 1px solid #ccc;
  font-size: 16px;
}

/* Sélecteur de catégorie */
.search-select {
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px solid #ccc;
  width: 200px; /* Limite la largeur sur grands écrans */
  font-size: 16px;
}

/* Bouton de recherche */
.search-button {
  padding: 8px 12px;
  border: none;
  border-radius: 6px;
  background: var(--main-green);
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  width: 150px; /* Largeur du bouton */
}

/* Lorsque l'écran est inférieur à 768px (mobile/tablette) */
@media (max-width: 768px) {
  .search-form {
    flex-direction: column; /* Passage en colonne sur mobile */
    gap: 10px;
  }

  .search-input,
  .search-select,
  .search-button {
    width: 100%; /* Les champs prennent 100% de la largeur sur mobile */
    max-width: 100%; /* Enlever la largeur maximale pour les petits écrans */
  }
}

.user-info{
  text-decoration: none;
  color: inherit;
  font-weight: 600;
  cursor: pointer;
  font-size: 1.2rem;
}

.user-info:hover{
  text-decoration: underline;
}

.user-info:hover span{
  color: #f4c000;
}

/* =====================
   PAGE CONNEXION / INSCRIPTION
===================== */
.auth-page{
  max-width: 1100px;
  margin: 40px auto 80px;
  padding: 0 20px;
}

.auth-title{
  text-align: center;
  color: var(--main-green);
  margin-bottom: 40px;
  font-size: 2rem;
  font-weight: 800;
}

/* Conteneur des 2 blocs */
.auth-container{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

/* Carte */
.auth-card{
  background: #fff;
  border-radius: 14px;
  padding: 30px 26px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
}

.auth-card h2{
  color: var(--main-green);
  margin-bottom: 20px;
  text-align: center;
}

/* Formulaire */
.auth-form{
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-form input{
  padding: 12px 14px;
  border-radius: 8px;
  border: 1px solid #ccc;
  font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.auth-form input:focus{
  outline: none;
  border-color: var(--main-green);
  box-shadow: 0 0 0 2px rgba(47,112,48,0.15);
}

/* Bouton */
.btn-auth{
  margin-top: 10px;
  padding: 12px;
  border-radius: 10px;
  border: none;
  background: var(--main-green);
  color: #fff;
  font-weight: 800;
  font-size: 1rem;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}

.btn-auth:hover{
  background: var(--dark-green);
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.2);
}

/* =====================
   RESPONSIVE
===================== */
@media(max-width: 900px){
  .auth-container{
    grid-template-columns: 1fr;
  }
}



/* === Conteneur général === */
.account-section {
  max-width: 650px;
  margin: 40px auto;
  background: #ffffff;
  padding: 32px 28px;
  border-radius: 16px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.account-section:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.15);
}

/* Titres */
.account-section h1 {
  text-align: center;
  color: var(--main-green);
  margin-bottom: 28px;
  font-size: 1.8rem;
  font-weight: 700;
}
.account-section h2 {
  color: var(--main-green);
  margin-top: 28px;
  font-size: 1.3rem;
  font-weight: 700;
  border-bottom: 2px solid #e0e0e0;
  padding-bottom: 6px;
}

/* Labels et inputs */
.account-form label {
  display: block;
  font-weight: 600;
  margin-top: 16px;
  font-size: 0.95rem;
  color: #333;
}
.account-form input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1.5px solid #ccc;
  margin-top: 6px;
  font-size: 1rem;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  outline: none;
}
.account-form input:focus {
  border-color: var(--main-green);
  box-shadow: 0 0 8px rgba(47,112,48,0.2);
}

/* Bouton */
.btn-update {
  width: 100%;
  padding: 14px;
  background: var(--main-green);
  color: #fff;
  border: none;
  border-radius: 10px;
  margin-top: 24px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.3s, transform 0.2s, box-shadow 0.2s;
}
.btn-update:hover {
  background: var(--dark-green);
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.2);
}

/* Messages */
.success, .error {
  text-align: center;
  padding: 12px 16px;
  border-radius: 12px;
  margin-bottom: 20px;
  font-weight: 600;
  font-size: 0.95rem;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}
.success { background: #e6f9e6; color: #1b5e20; }
.error { background: #fdecea; color: #b71c1c; }

/* Responsive */
@media(max-width:768px){
  .account-section { padding: 24px 18px; }
  .account-section h2 { font-size: 1.15rem; }
  .account-form input { font-size: 0.95rem; padding: 10px 12px; }
  .btn-update { font-size: 0.95rem; padding: 12px; }
}

.account-form input[readonly] {
  background: #f6f6f6;
  color: #555;
  cursor: not-allowed;
}




/* 🧾 Grid des commandes avec marges latérales et espacement bas */
.orders-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* max 3 par ligne */
  gap: 24px; /* espace entre les cartes */
  margin: 40px auto 60px auto; /* top 40px, bottom 60px, centré */
  max-width: 1200px; /* limite la largeur pour laisser des marges */
  padding: 0 20px; /* un peu de padding à gauche/droite */
  box-sizing: border-box;
}

/* 🟢 Carte commande */
.order-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.order-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

/* 🟢 Header carte */
.order-header {
  background: var(--main-green, #2f7030);
  color: #fff;
  padding: 14px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.order-id {
  font-weight: 700;
  font-size: 1rem;
}
.order-status {
  font-size: 0.85rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 12px;
  text-transform: capitalize;
}
.order-status.pending { background: #fff4e5; color: #f39c12; }
.order-status.paid { background: #eafaf1; color: #27ae60; }
.order-status.shipped { background: #e8f1fa; color: #2980b9; }
.order-status.delivered { background: #e6f8f3; color: #16a085; }
.order-status.cancelled { background: #fdebea; color: #e74c3c; }

/* 🟢 Body carte */
.order-body {
  padding: 16px 20px;
  flex-grow: 1;
}
.order-body p {
  margin: 6px 0;
  font-size: 0.95rem;
  color: #444;
}
.order-body .total {
  color: var(--main-green);
  font-weight: 700;
  font-size: 1.1rem;
}

/* 🟢 Footer carte */
.order-footer {
  padding: 12px 20px;
  text-align: right;
  background: #f9f9f9;
}
.btn-detail {
  background: var(--main-green);
  color: #fff;
  padding: 8px 14px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  transition: background 0.25s ease, transform 0.25s ease;
}
.btn-detail:hover {
  background: var(--dark-green);
  transform: translateY(-2px);
}

/* 🔹 Responsive */
@media screen and (max-width: 1024px) {
  .orders-grid { grid-template-columns: repeat(2, 1fr); }
}
@media screen and (max-width: 768px) {
  .orders-grid { grid-template-columns: 1fr; }
}



/* FORMULAIRE CONTACT*/
.contact-wrapper {
  max-width: 700px;
  margin: 50px auto;
  background: #fff;
  border-radius: 14px;
  box-shadow: var(--shadow-light);
  padding: 40px 32px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.input-group {
  display: flex;
  flex-direction: column;
}

.input-group label {
  font-weight: 600;
  margin-bottom: 6px;
  color: #334155;
}

.input-group input,
.input-group textarea {
  padding: 12px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.input-group input:focus,
.input-group textarea:focus {
  border-color: var(--emerald);
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.15);
  outline: none;
}



/* ✅ BOUTON EN VERT FORCÉ */
.send-btn {
  background-color: #15803d !important;   /* Vert principal */
  color: #fff !important;                 /* Texte blanc */
  font-weight: 700;
  font-size: 1rem;
  border: none;
  border-radius: 8px;
  padding: 14px;
  cursor: pointer;
  transition: background-color .2s ease, transform .1s ease;
  display: inline-block;
  text-align: center;
}

.send-btn:hover {
  background-color: #16a34a !important;   /* Vert plus foncé au survol */
  transform: translateY(-2px);
}



/* ALERTES */
.alert {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-weight: 600;
  text-align: center;
}
.alert.success { background: #dcfce7; color: #166534; }
.alert.error { background: #fee2e2; color: #991b1b; }



/* VALIDATION PANIER */
#cartContainer {
  max-width: 900px;
  margin: 30px auto 60px auto; /* marge haut/bas */
  padding: 0 15px;
  box-sizing: border-box;
}

.empty {
  font-size: 1.1rem;
  color: #555;
  margin-top: 30px;
}

/* === Table du panier === */
table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-bottom: 30px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 18px rgba(0,0,0,0.05);
}

th, td {
  padding: 14px 8px;
  text-align: center;
  vertical-align: middle;
  font-size: 0.95rem;
}

/* Header vert arrondi */
thead tr th {
  background: var(--main-green);
  color: #fff;
  text-transform: uppercase;
  font-size: 1.05rem;
  font-weight: 700;
  border: none;
}

thead tr th:first-child { border-top-left-radius: 12px; }
thead tr th:last-child { border-top-right-radius: 12px; }

/* Lignes produits */
tbody tr {
  background: #fafafa;
  transition: background 0.25s ease, transform 0.2s ease;
}
tbody tr:hover {
  background: #f1f1f1;
  transform: translateY(-1px);
}

/* Image produit */
td img {
  width: 75px;
  height: 75px;
  object-fit: cover;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #eee;
}

/* Info produit */
.product-info {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: flex-start;
  text-align: left;
}
.product-title {
  font-weight: 600;
  color: #333;
  display: flex;
  align-items: center;
  height: 80px;
}

/* Prix */
.price {
  font-weight: 700;
  color: var(--main-green);
}
.old-price {
  text-decoration: line-through;
  color: #e60023;
  margin-right: 6px;
  font-size: 1.2rem;
}

.price.promo {
  
  color: var(--main-green);
  font-weight: bold;
  font-size: 1.2rem;
}


.total {
  font-weight: bold;
  color: var(--main-green);
  font-size: 1.05rem;
}

/* Bouton supprimer */
.trash-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: #8a8a8a;
  transition: color 0.2s ease, transform 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}
.trash-btn:hover {
  color: #e74c3c;
  transform: scale(1.2);
}
.trash-btn svg {
  width: 22px;
  height: 22px;
}

/* Total général */
h2.total-general {
  text-align: right;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--main-green);
  margin-top: 20px;
}

/* === Sections Livraison, Coupon, Total === */
.cart-container,
.coupo-section,
.total-section {
  max-width: 900px;
  margin: 30px auto;
  background: #fff;
  border-radius: 15px;
  box-shadow: 0 5px 18px rgba(0,0,0,0.08);
  padding: 25px;
  transition: transform 0.2s ease, box-shadow 0.25s ease;
}
.cart-container:hover,
.coupo-section:hover,
.total-section:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

.cart-container h2,
.coupo-section h2,
.total-section h2 {
  color: var(--main-green);
  text-align: center;
  font-size: 1.4rem;
  margin-bottom: 20px;
}

/* Livraison */
.delivery-details .delivery-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid #eee;
  font-size: 0.95rem;
}
.delivery-methods {
  margin-top: 25px;
}
.delivery-option {
  display: block;
  background: #f8f8f8;
  padding: 12px 15px;
  border-radius: 12px;
  margin-bottom: 12px;
  cursor: pointer;
  transition: background 0.25s ease;
  font-size: 0.95rem;
}
.delivery-option:hover {
  background: #e8f5e9;
}
.delivery-option input {
  margin-right: 10px;
}
.delivery-option.disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Champ Mondial Relay */
#mondialRelayField textarea {
  width: 100%;
  padding: 10px;
  border-radius: 10px;
  border: 1px solid #ccc;
  font-size: 0.95rem;
  resize: none;
}

/* Coupon */
.coupo-section input {
  padding: 12px;
  border-radius: 10px;
  border: 1px solid #ccc;
  font-size: 1rem;
  flex-grow: 1;
}
.coupo-section button {
  padding: 12px 20px;
  border-radius: 10px;
  background: var(--main-green);
  color: #fff;
  border: none;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.2s ease, transform 0.2s ease;
}
.coupo-section button:hover {
  background: var(--dark-green);
  transform: translateY(-2px);
}

/* Total Section */
.total-section .total-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  font-size: 1rem;
}
.total-section .total-row strong {
  font-weight: 700;
}
.total-section hr {
  border: 0;
  border-top: 1px solid #eee;
  margin: 10px 0;
}

/* Bouton valider la commande */
#validateOrderContainer {
  text-align: center;
  margin: 40px auto 80px auto;
}
#validateOrderBtn {
  padding: 14px 28px;
  background: var(--main-green);
  color: #fff;
  font-size: 1.15rem;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}
#validateOrderBtn:hover {
  background: var(--dark-green);
  transform: translateY(-2px);
}

/* Mobile friendly */
@media screen and (max-width: 768px) {
  table th, table td { font-size: 0.90rem; padding: 12px 1px; }
  td.price, td.total { font-size: 0.90rem; }
  td.total { white-space: nowrap; }
  thead tr th { font-size: 0.7rem; }
  th, td { padding: 14px 1px; font-size: 0.90rem; }
  .trash-btn svg { width: 16px; height: 16px; }
  .total { font-size: 0.90rem; }
  .product-info { gap: 1px; }
  .old-price { font-size: 0.9rem; }
  .price.promo { font-size: 0.9rem; margin-right: 2px; }
  .price { font-size: 0.9rem; }
  .delivery-details .delivery-row { flex-direction: column; align-items: flex-start; gap: 4px; }
  .delivery-option { font-size: 0.9rem; padding: 10px 12px; }
  #validateOrderBtn { width: 90%; font-size: 1.05rem; }
}



.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 30000;
}

.modal-box {
  background: #fff;
  border-radius: 12px;
  padding: 20px 25px;
  max-width: 420px;
  width: 90%;
  box-shadow: 0 8px 25px rgba(0,0,0,0.25);
  animation: fadeUp .2s ease;
}

.modal-box h3 {
  margin-top: 0;
  color: var(--main-green);
}

.modal-box p {
  margin: 15px 0;
  line-height: 1.5;
}

.close-modal {
  background: var(--main-green);
  color: #fff;
  border: none;
  padding: 8px 14px;
  border-radius: 8px;
  cursor: pointer;
}

@keyframes fadeUp {
  from { transform: translateY(10px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}


.cart-box {
  max-width: 900px;          /* même largeur */
  margin: 30px auto;         /* espace gauche/droite + bas */
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  padding: 20px 24px;
}


.cart-login {
  max-width: 900px; /* 🔹 avant : souvent 1000 ou 1200px */
  margin: 30px auto 60px auto; /* marge haut/bas */
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  padding: 15px 20px; /* 🔹 avant : souvent 30px ou plus */
}

.coupo-section {
  max-width: 900px; /* 🔹 avant : souvent 1000 ou 1200px */
  margin: 30px auto 60px auto; /* marge haut/bas */
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  padding: 15px 20px; /* 🔹 avant : souvent 30px ou plus */
}

.total-section {
  max-width: 900px; /* 🔹 avant : souvent 1000 ou 1200px */
  margin: 30px auto 60px auto; /* marge haut/bas */
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  padding: 15px 20px; /* 🔹 avant : souvent 30px ou plus */
  text-align: center;
}

.total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-width: 320px;
  margin-bottom: 4px; /* 👈 avant 10px → plus serré */
}

.total-row:last-of-type {
  margin-bottom: 0;
}

.total-section hr {
  margin: 6px 0; /* 👈 avant souvent 15–20px */
}




/* PAGE PANIER */
.cart-items {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.cart-item {
    display: flex;
    align-items: center;
    padding: 12px 0;
    gap: 15px;
    border: none; /* supprime le cadre */
    border-bottom: 1px solid #eee; /* un seul trait dessous */
}

.cart-item img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
}

.cart-item-details {
    flex: 1;
}

.cart-item-details h3 {
    margin: 0 0 5px 0;
    font-size: 1.1rem;
}

.cart-item-details .price {
    font-weight: bold;
}

.cart-item-details .old-price {
    text-decoration: line-through;
    color: #999;
    margin-left: 5px;
}

.cart-item-qty {
    width: 60px;
    text-align: center;
}

.cart-item-total {
    font-weight: bold;
    min-width: 60px;
    text-align: right;
}



/* =====================
   POLITIQUE DE CONFIDENTIALITÉ
===================== */
.legal-wrapper{
  max-width: 900px;
  margin: 40px auto 80px;
  background: #fff;
  padding: 35px 30px;
  border-radius: 16px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
}

.legal-wrapper h1{
  text-align:center;
  color: var(--main-green);
  margin-bottom: 30px;
  font-size: 2rem;
  font-weight: 800;
}

.legal-wrapper h2{
  color: var(--main-green);
  margin-top: 28px;
  margin-bottom: 10px;
  font-size: 1.2rem;
  font-weight: 700;
}

.legal-wrapper p{
  margin-bottom: 14px;
  line-height: 1.6;
  color:#444;
  font-size: 0.95rem;
}

.legal-wrapper ul{
  margin: 10px 0 15px 18px;
  color:#444;
  font-size: 0.95rem;
}

@media(max-width:768px){
  .legal-wrapper{
    margin: 40px 10px 80px;
    padding: 25px 18px;
  }
}




.order-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 15px;
}

.btn-cancel {
  background: #fff;
  color: #d93025;
  border: 1px solid #d93025;
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  transition: 0.2s ease;
}

.btn-cancel:hover {
  background: #d93025;
  color: #fff;
}



/* === LIGHTBOX PRO === */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 20px;
  animation: fadeIn 0.3s ease;
}

.lightbox img {
  max-width: 95%;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.6);
  transition: transform 0.3s ease;
}

/* Boutons */
.lb-close,
.lb-prev,
.lb-next {
  position: absolute;
  background: rgba(255,255,255,0.1);
  border: none;
  color: #fff;
  font-size: 30px;
  cursor: pointer;
  padding: 12px 18px;
  border-radius: 50%;
  transition: 0.2s ease;
}

.lb-close:hover,
.lb-prev:hover,
.lb-next:hover {
  background: rgba(255,255,255,0.25);
}

.lb-close {
  top: 20px;
  right: 25px;
  font-size: 36px;
}

.lb-prev {
  left: 25px;
  top: 50%;
  transform: translateY(-50%);
}

.lb-next {
  right: 25px;
  top: 50%;
  transform: translateY(-50%);
}

/* Responsive mobile */
@media (max-width: 768px) {
  .lb-prev,
  .lb-next {
    font-size: 24px;
    padding: 10px 14px;
  }

  .lightbox img {
    max-height: 75vh;
  }
}

/* Animation */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}


/* oeil password */
.input-password{
  position: relative;
  width: 100%;
}

.input-password input{
  width: 100%;
  padding-right: 40px; /* espace pour l'oeil */
  box-sizing: border-box;
}

.toggle-password{
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  font-size: 18px;
}

