/* Palette */
:root {
  --dominante: #16a8c1;
  --sable: #EAC198;
  --ocre: #CC9F72;
  --taupe: #9A7B67;
  --brun: #564949;
  --fond: #f7f7f7;
}

body {
  margin: 0;
  font-family: Marianne, Arial, sans-serif;
  font-size: 1rem;
  background-color: var(--fond);
  color: var(--brun);
  background-color: #99D7F742;
}

header {
  background-color: /*var(--dominante)*/#99D7F7;
  color: white;
  text-align: center;
  padding: 2rem 1rem;
}

h1 {
  margin: 0;
  font-size: 3rem;
  font-weight: 600;
}

h6 {
	margin: 0;
	font-weight: normal;
	font-size: 0.9rem;
}

main {
  padding: 2rem 1rem;
  max-width: 1400px;
  margin: 0 auto;
  margin-bottom: 35px;
}

section {
	scroll-margin-top: 70px;
}

/* Barre de liens ancres (fixe sous le header) */
.nav-ancres {
  position: sticky;
  top: 0; 
  z-index: 1000;
  display: flex;
  justify-content: center;
  gap: 2rem;
  background-color: #0083CB;
  padding: 0.75rem 1rem;
  border-bottom: 3px solid #99D7F7;
  transition: box-shadow 0.3s ease;
}

/* Optionnel : petit effet d’ombre quand on scroll */
.nav-ancres.sticky {
  box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}

.nav-ancres a {
  color: white;
  text-decoration: none;
  font-weight: 500;
  font-size: 1rem;
  position: relative;
  transition: color 0.3s ease;
}

/* Soulignement animé au survol */
.nav-ancres a::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--sable);
  transition: width 0.3s ease;
}

.nav-ancres a:hover {
  color: var(--sable);
}

.nav-ancres a:hover::after {
  width: 100%;
}

/* Responsive */
@media (max-width: 600px) {
  .nav-ancres {
    flex-wrap: wrap;
    gap: 1rem;
  }

  .nav-ancres a {
    font-size: 0.9rem;
  }
}

.categorie {
  margin-top: 2rem;
  margin-bottom: 4rem;
  text-align: center;
}

.categorie h2 {
  display: inline-block;
  margin-bottom: 1rem;
  color: /*var(--dominante)*/ /*#CC9F72*/ white;
  /*border-left: 4px solid var(--dominante);*/
  padding-left: 0.5rem;
  text-align :center;
  background-color: #0083CB;
  border-radius: 25px;
  padding: 5px 20px;
}

/* Conteneur de vignettes */
.vignettes-container {
  position: relative;
  /*overflow: hidden;*/
}

/* Grille horizontale scrollable */
.vignettes {
  display: flex;
  gap: 3rem;
  overflow: hidden;
  scroll-behavior: smooth;
  padding: 1rem;
}

.vignettes::-webkit-scrollbar {
  display: none;
}

.vignettes.center {
  justify-content: center;
}

.vignettes.scrollable {
  justify-content: flex-start;
}

/* Vignette */
.vignette {
  position: relative;
  flex: 0 0 auto;
  width: 450px;
  height: 300px;
  border-radius: 12px;
  overflow: hidden;
  background-color: /*var(--taupe)*/transparent;
  cursor: pointer;
  scroll-snap-align: center;
  transition: transform 0.3s ease;
}

.vignette img {
  width: 100%;
  /*height: 100%;*/
  object-fit: contain;
  object-position: center;
  display: block;
}

.vignette:hover {
  transform: scale(1.05);
}

/* Overlay au survol */
.overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: #0083CB;
  color: white;
  text-align: center;
  padding: 1rem;
  opacity: 0;
  transform: translateY(100%);
  transition: all 0.3s ease;
}

.vignette:hover .overlay {
  opacity: 1;
  transform: translateY(0);
}

/* Boutons de navigation */
.nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: #99D7F7;
  border: none;
  color: white;
  font-size: 2rem;
  padding: 0.5rem;
  cursor: pointer;
  border-radius: 50%;
  z-index: 2;
  display: none; /* caché par défaut */
}

.vignettes-container:hover .nav-btn {
  display: block; /* affiche les boutons au survol */
}

.nav-btn:hover {
  background-color: /*var(--dominante)*/#0083CB;
}

.nav-btn.left {
  left: -3rem;
}

.nav-btn.right {
  right: -3rem;
}


/* === FOOTER FIXE === */
footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: white;
  padding: 1rem 2rem;
  box-shadow: 0 -2px 8px rgba(0,0,0,0.1);
  z-index: 1000;
}

/* Conteneur interne */
.footer-content {
  position: relative;
  max-width: 100%;
  margin: 0 auto;
  height: 75px; /* hauteur fixe pour aligner logos et lien */
}

/* Lien centré */
#mentions-link {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  text-decoration: none;
  color: #0083CB;
  font-weight: 600;
  transition: color 0.3s;
}

#mentions-link:hover {
  color: #0083CBBB;
}

/* Logos à droite */
footer .logos {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  gap: 3rem;
  align-items: center;
}

footer .logos img {
  height: 75px;
  width: auto;
  display: block;
}

/* === MODALE === */
.modal {
  display: none; /* caché par défaut */
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.5);
  align-items: center;
  justify-content: center;
}

.modal-content {
  background-color: white;
  padding: 2rem;
  border-radius: 10px;
  width: 35%;
  max-width: 35%;
  min-width: 15%;
  text-align: left;
  position: relative;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.modal-content h2 {
  margin-top: 0;
  color: #0083CB;
}

.close {
  position: absolute;
  top: 10px;
  right: 15px;
  color: #555;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

.close:hover {
  color: #000;
}



/* Responsive */
@media (max-width: 768px) {
  
  h1 {
	  font-size: 1.6rem;
  }
  
  .vignettes-container {
    overflow: visible; /* plus besoin du scroll horizontal */
  }

  .vignettes {
    flex-direction: column; /* empilement vertical */
    gap: 1rem; /* espace entre les vignettes */
    scroll-snap-type: none; /* désactive le scroll snap */
  }

  .vignette {
    width: 95%; /* prend presque toute la largeur du container */
    max-width: 400px; /* largeur maximale pour ne pas être trop large */
    margin: 0 auto; /* centrer horizontalement */
    aspect-ratio: auto; /* ajuste automatiquement la hauteur */
  }

  .nav-btn {
    display: none; /* on masque les flèches */
  }
  
  .overlay {
	opacity: 1;
  transform: translateY(0%);
  }
  
  
  /*Footer*/
  footer {
	  padding: 1rem 0rem;
  }
  
  .footer-content {
    height: auto;            /* hauteur flexible pour mobile */
    display: flex;
    flex-direction: column;  /* empilement vertical */
    align-items: center;     /* centrer horizontalement le contenu */
    justify-content: center;
  }

  /* Lien toujours centré */
  #mentions-link {
    position: static;       /* annule absolute */
    transform: none;        /* annule translate */
    left: auto;
    top: auto;
  }

  /* Logos sous le lien et centrés */
  footer .logos {
    position: static;       /* annule absolute */
    transform: none;        /* annule translate */
    display: flex;
    justify-content: center;
    gap: 1.5rem;           /* réduire l’espace entre logos */
    margin-top: 0.5rem;
  }

  footer .logos img {
    height: 50px;           /* réduire taille pour mobile */
  }
  
}
