/* Style global des scrollbars */
::-webkit-scrollbar {
  width: 10px; /* Largeur de la scrollbar verticale */
  height: 8px; /* Hauteur de la scrollbar horizontale */
}

/* Style de la "tige" (la partie principale de la scrollbar) */
::-webkit-scrollbar-thumb {
  background-color: #a8362d; /* Couleur de fond du "thumb" (partie déplaçable) */
  border-radius: 10px; /* Bordure arrondie */
  border: 2px solid #fff; /* Bordure blanche autour du "thumb" */
}

/* Style de la "tige" au survol */
::-webkit-scrollbar-thumb:hover {
  background-color: #c94339; /* Couleur de fond lorsque l'on survole le "thumb" */
}

/* Style de la "barre" (la zone dans laquelle la scrollbar se déplace) */
::-webkit-scrollbar-track {
  background: #f5c1bd; /* Couleur de fond de la barre de défilement */
  border-radius: 10px; /* Bordure arrondie */
  margin: 0 4px; /* Espacement de la barre de défilement */
}

/* Style de la scrollbar horizontale */
::-webkit-scrollbar-horizontal {
  height: 8px; /* Hauteur de la scrollbar horizontale */
}

/* Scrollbar pour les éléments spécifiques, exemple : .review-body */
.review-body {
  max-height: 20vh; /* Hauteur max avec scroll */
  overflow-y: auto; /* Activation du scroll */
}



* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  background-color: #f4f4f4;
  background-image: url('images/background.jpeg');
  background-size: cover; /* L'image couvre toute la page */
  background-position: center; /* Centrer l'image */
  background-attachment: fixed; /* Fixe l'image en arrière-plan */
}

.navbar {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 10px;
  background-color: transparent;
  width: 100%;
}

.carousel {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2vw; /* Espacement entre les boutons */
  flex-wrap: nowrap; /* Les boutons restent sur une ligne */
}

.nav-button {
  color: #fbe7e5;
  background-color: #dd6056;
  border: 1px solid #3f1310;
  padding: 0; /* Enlever tout padding interne */
  cursor: pointer;
  transition: background-color 0.3s ease;
  text-align: center;
  width: 150px; /* Largeur fixe */
  height: 50px; /* Hauteur fixe */
  display: flex;
  justify-content: center;
  align-items: center; /* Centrer le texte verticalement et horizontalement */
}

.nav-button:hover {
  background-color: #c94339;
}

button.prev, button.next, button.previous {
  color: #fbe7e5;
  background-color: #dd6056;
  border: 1px solid #3f1310;
  padding: 0;
  cursor: pointer;
  width: 50px; /* Largeur fixe pour les flèches */
  height: 50px; /* Hauteur fixe pour les flèches */
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  transition: background-color 0.3s ease;
  margin: 0 2vw;
}

button.prev:hover, button.next:hover, button.previous:hover {
  background-color: #c94339;
}

button.prev {
  font-size: 20px;
}

button.next {
  font-size: 20px;
}

/* Style spécifique pour la galerie avec Flickity */
.gallery {
  margin: 0 auto;
}

.gallery-cell {
  width: 70%;  /* Ajustez la taille des cellules */
  height: 450px;  /* Hauteur des images */
  margin-right: 10px;
  background: #333;
  counter-increment: gallery-cell;
  position: relative;
  cursor: pointer;
}

/* Image de fond */
.gallery-cell img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.5s ease; /* Pour la transition d'opacité */
}

/* Ajout de l'effet de dégradé */
.gallery-cell:before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to left, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0));
  pointer-events: none; /* Pour ne pas interférer avec le clic sur l'image */
  opacity: 0;
  transition: opacity 0.5s ease;
}

.is-prev .gallery-cell:before, .is-next .gallery-cell:before {
  opacity: 1;  /* Applique le dégradé sur les images adjacentes */
}

.gallery-cell.is-selected img {
  opacity: 1; /* Image principale entièrement visible */
}

.mosaic-cell {

  display: flex;
  justify-content: center;
  align-items: center;
}

.mosaic-cell img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mosaic-cell.add-image {
  background-color: #fbe7e5; /* Couleur de fond pour la carte avec le plus */
  color: #8c2f28; /* Couleur de l'icône */
  font-size: 3rem; /* Taille de l'icône */
}

.mosaic-cell.add-image i {
  font-size: 4rem; /* Taille de l'icône plus */
  text-align: center;
  vertical-align: middle;
  display: inline-block;
}

/* Modale */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6); /* Assurez-vous que le fond sombre est moins opaque */
  justify-content: center;
  align-items: center;
  z-index: 1050; /* Augmenter le z-index pour éviter qu'un autre élément bloque la modale */
}

/* Style du contenu du modal */
.modal-content {
  width: auto;
  max-width: 100%;  /* Largeur de l'image + 1vw de chaque côté */
  max-height: 100%;
  background-color: #f8d3d0;
  padding: 10px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  text-align: center;
  overflow: hidden; /* Empêche l'overflow du contenu */
}


/* Image dans le modal */
.modal img {
  width: 100%;
  height: auto;
  max-height: 90vh; /* Limite la hauteur à 70% de la fenêtre */
  object-fit: contain; /* Garder l'image proportionnelle */
  margin-bottom: 10px; /* Espacement entre l'image et les infos */
}

/* Informations au-dessus de l'image */
.modal-info {
  position: absolute;
  bottom: 0; /* Place les informations en bas de l'image */
  left: 0;
  right: 0;
  padding: 20px;
  background: rgba(0, 0, 0, 0.7); /* Fond semi-transparent */
  color: white;
  opacity: 0; /* Masque les informations par défaut */
  transform: translateY(50px); /* Positionne les informations sous l'image */
  transition: opacity 0.5s ease, transform 0.5s ease; /* Transition fluide */
  max-height: 50%; /* Limite la hauteur pour garder les infos visibles sans encombrer l'image */
  overflow: auto; /* Si le texte dépasse, il sera défilable */
}

/* Effet lors du survol de l'image */
.modal-content:hover .modal-info {
  opacity: 1; /* Rendre les informations visibles */
  transform: translateY(0); /* Déplace les informations vers le haut */
}

.modal-info .left-info {
  flex: 1;
  margin-right: 10px;
}

.modal-info .right-info {
  text-align: right;
  font-weight: bold;
  color: #e53e3e; /* Couleur pour le statut (ex: vendu) */
}

.modal-info p {
  margin: 5px 0;
  font-size: 16px;
}

/* Le bouton de fermeture du modal */
.close {
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 30px;
  color: #333;
  cursor: pointer;
}


/* Section galerie mosaïque sous la barre de navigation */
.mosaic-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); /* Crée des colonnes auto-ajustables */
  gap: 15px; /* Espacement entre les images */
  padding: 20px;
}

.mosaic-cell {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  background: #333;
  border-radius: 8px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.mosaic-cell img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.mosaic-cell:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.mosaic-cell:hover img {
  transform: scale(1.1);
}

@media (max-width: 768px) {
  .carousel {
    flex-direction: column;
    align-items: center;
    gap: 10px; /* Espacement réduit en colonne */
  }

  .nav-button {
    width: 80%; /* Réduit la largeur des boutons sur petits écrans */
    height: 50px; /* Assure la même hauteur pour les petits écrans */
  }

  button.prev, button.next {
    width: 40px;
    height: 40px;
  }
}

@media (max-width: 480px) {
  button.prev, button.next {
    width: 35px;
    height: 35px;
  }

  .nav-button {
    width: 100%; /* Les boutons prennent toute la largeur sur petits écrans */
    height: 50px; /* Assure une hauteur uniforme */
  }
}

/* Page avis clients */

.review-container {
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  margin-bottom: 20px;
  padding: 20px;
  width: 100%;
  min-height: 150px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.review-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.review-header .name {
  font-weight: bold;
  color: #dd6056;
}

.review-header .date {
  font-size: 12px;
  color: #888;
}

.review-header .rating {
  font-size: 20px;
  color: #f39c12;
}

.profil {
  color: white;
}

.profil:hover {
  color: white;
}

.review-body {
  margin-top: 10px;
  color: #333;
  flex-grow: 1;
  overflow-wrap: break-word;
  word-wrap: break-word;
  max-height: 20vh;
  overflow-y: auto;
}

.review-form {
  background-color: rgba(255, 255, 255, 0.8);
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.star-rating {
  display: inline-block;
  font-size: 30px;
  color: #ccc;
  cursor: pointer;
}

.star-rating input {
  display: none;
}

.star-rating label {
  color: #ccc;
  transition: color 0.3s ease;
}

.star-rating input:checked ~ label {
  color: #f39c12; /* Color gold for selected stars */
}

.submit-btn {
  background-color: #dd6056;
  color: #fbe7e5;
  padding: 10px 20px;
  border-radius: 50px;
  width: 100%;
  font-weight: bold;
}

.submit-btn:hover {
  background-color: #c94339;
  color: #fbe7e5;
}

.toasts {
  position: fixed;
  top: 20px;
  right: 20px;
  min-width: 250px;
  background-color: #6a885a;
  color: white;
  padding: 15px;
  border-radius: 5px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transition: opacity 0.5s;
}

.review-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 20px;
}

.review-columns .review-container {
  display: flex;
  flex-direction: column;
  height: 100%;
}

@media (max-width: 768px) {
  .review-columns {
      grid-template-columns: 1fr;
  }
}

/* Style pour le champ de texte */
textarea#descArtiste {
  width: 100%;
  height: 150px;
  padding: 15px;
  font-size: 1rem;
  font-family: 'Arial', sans-serif;
  border: 2px solid #ccc;
  border-radius: 10px;
  background-color: #f9f9f9;
  color: #333;
  resize: none;
  box-sizing: border-box;
  transition: border-color 0.3s ease, background-color 0.3s ease;
}

textarea#descArtiste:focus {
  outline: none;
  border-color: #6a885a; /* Couleur de la bordure lors du focus */
  background-color: #eaf3e0; /* Légère teinte verte lors du focus */
}

textarea#descArtiste::placeholder {
  color: #aaa; /* Couleur du texte de placeholder */
  font-style: italic;
}

/* Bouton Modifier */
#editBtn {
  background-color: #6a885a;
  color: white;
  padding: 5px 10px;
  border-radius: 25px;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
  transition: background-color 0.3s ease;
}

#editBtn:hover {
  background-color: #49603e; /* Teinte plus foncée lors du survol */
}

/* Bouton Enregistrer */
#saveBtn {
  background-color: #28a745;
  color: white;
  padding: 5px 10px;
  border-radius: 25px;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
  transition: background-color 0.3s ease;
  display: none;
}

#saveBtn:hover {
  background-color: #218838; /* Teinte plus foncée lors du survol */
}

.form-container {
  background-color: rgba(255, 255, 255, 0.8);
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  max-width: 800px;
  margin: 0 auto;
}

.form-container h2 {
  margin-bottom: 20px;
  text-align: center;
  color: #6a885a;
}

.form-container input,
.form-container textarea,
.form-container select {
  width: 100%;
  padding: 10px;
  margin-bottom: 15px;
  border: 1px solid #ccc;
  border-radius: 5px;
  background-color: #f9f9f9;
  font-size: 14px;
}

.form-container select {
  -webkit-appearance: none; /* Supprimer le style par défaut sur Chrome et Safari */
  -moz-appearance: none; /* Supprimer le style par défaut sur Firefox */
  appearance: none; /* Applique le style personnalisé sur tous les navigateurs */
  background-color: #fff;
  background-image: url('data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 16 16%22%3E%3Cpath fill=%22none%22 d=%22M1 4l7 7 7-7%22/%3E%3C/svg%3E');
  background-position: right 10px center;
  background-repeat: no-repeat;
}

.form-container select:focus {
  border-color: #6a885a;
  outline: none;
}

.form-container button {
  width: 100%;
  padding: 12px;
  background-color: #dd6056;
  color: white;
  border: none;
  border-radius: 50px;
  font-weight: bold;
  cursor: pointer;
}

.form-container button:hover {
  background-color: #c94339;
}

.toasts {
  position: fixed;
  top: 20px;
  right: 20px;
  min-width: 250px;
  background-color: #6a885a;
  color: white;
  padding: 15px;
  border-radius: 5px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transition: opacity 0.5s;
}

.radio-container {
  display: flex;
  justify-content: space-between;
  margin-bottom: 15px;
}

.radio-container input {
  display: none;
}

.radio-container label {
  cursor: pointer;
  padding: 8px 16px;
  background-color: #ccc;
  border-radius: 50px;
  transition: background-color 0.3s ease, color 0.3s ease;
  width: 45%;
  text-align: center;
  font-size: 14px;
}

.radio-container input:checked + label {
  background-color: #6a885a;
  color: white;
}

.radio-container label:hover {
  background-color: #49603e;
  color: white;
}

.radio-container input:checked + label:hover {
  background-color: #49603e;
  color: white;
}

.option-group {
  display: flex;
  justify-content: space-between;
  margin-bottom: 15px;
}

/* Style pour le switch radio */
.toggle {
  position: relative;
  border: solid 3px #ea877f;
  border-radius: 55px;
  width: 95%;
  margin: auto;
  height: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 5px;
  cursor: pointer;
}

.toggle input {
  display: none;
}

.toggle label {
  font-size: 0.85rem;
  font-weight: bold;
  text-transform: capitalize;
  color: #3f1310;
  width: 50%;
  height: 100%;
  text-align: center;
  line-height: 30px;
  z-index: 9999;
}

.toggle input:checked + label {
  color: #8c2f28;
}

.toggle .flap {
  position: absolute;
  background-color: #ea877f;
  width: 50%;
  height: 100%;
  border-radius: 55px;
  top: 0;
  left: 0;
  transition: all 0.4s ease;
}

.toggle input:checked + label + .flap {
  transform: translateX(100%);
}

.toggle-color {
  position: relative;
  border: solid 3px #ea877f;
  border-radius: 55px;
  width: 95%;
  margin: auto;
  height: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 5px;
  cursor: pointer;
}

.toggle-color input {
  display: none;
}

.toggle-color label {
  font-size: 0.85rem;
  font-weight: bold;
  text-transform: capitalize;
  color: #3f1310;
  width: 100%;
  height: 100%;
  text-align: center;
  line-height: 30px;
  z-index: 9999;
}

.toggle-color input:checked + label {
  color: #8c2f28;
}

.toggle-color .flap {
  position: absolute;
  background-color: #ea877f;
  width: 33.3%;
  height: 100%;
  border-radius: 55px;
  top: 0;
  left: 0;
  transition: all 0.4s ease;
}

/* Position de la flèche pour chaque option sélectionnée */
#choice1:checked ~ .flap {
  transform: translateX(0%);
}

#choice2:checked ~ .flap {
  transform: translateX(100%);
}

#choice3:checked ~ .flap {
  transform: translateX(200%);
}

select {
  background-color: #fff;
  color: #333;
}

select:focus {
  border-color: #6a885a;
  outline: none;
}

/* Style pour le bouton de sélection de fichier */
input[type="file"] {
  width: 100%;
  padding: 10px;
  background-color: #fff;
  color: #333;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 14px;
  cursor: pointer;
}

input[type="file"]:hover {
  background-color: #f2f2f2;
}

input[type="file"]:focus {
  border-color: #6a885a;
  outline: none;
}

input[type="file"]::-webkit-file-upload-button {
  background-color: #dd6056;
  color: white;
  border: none;
  padding: 10px;
  border-radius: 5px;
  cursor: pointer;
}

input[type="file"]::-webkit-file-upload-button:hover {
  background-color: #c94339;
}

@media (max-width: 768px) {
  .form-container {
      padding: 15px;
  }

  .radio-container {
      flex-direction: column;
      align-items: center;
  }

  .radio-container label {
      width: 100%;
      margin-bottom: 10px;
  }
}