/* --- Styles généraux --- */
/* --- Ajouter un effet de grain à l'ensemble du site --- */
body {
  margin: 0;
  padding: 0;
  font-family: "Montserrat", sans-serif;
  background-color: #f9f9f9;
  overflow: hidden;
  width: 100%;
  height: auto;

  background-color: #2a3037;
  display: flex;
  flex-direction: column;
}

/* --- En-tête (header) --- */
header {
  color: white;
  padding: 1rem;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 30px;
  width: 100%;
  height: 200px;
  position: absolute;
  z-index: 999;
}

.wrapper {
  display: flex;
  flex-direction: column;
  padding-top: 15rem;
  padding-bottom: 2rem;
  margin-left: 3rem;
  margin-right: 3rem;
  color: white;
}

header img {
  width: 200px;
  margin: 0;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 1s;
}

header img:hover {
  opacity: 80%;
}

.nav ul {
  gap: 5rem;
  padding-right: 5rem;
}

.nav a {
  font-size: 24px;
  color: white;
  transition: 1s;
  text-transform: uppercase;
  font-weight: 400;
}

.nav a:hover {
  color: #ed2a1d;
  font-size: 26px;
}

nav ul {
  list-style: none;
  padding: 0;
  display: flex;
  justify-content: center;
  gap: 1rem;
}

nav ul li a {
  text-decoration: none;
  color: white;
  font-weight: bold;
}

/* --- Écran de transition --- */
.transition {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #333;
  z-index: 9999;
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.6s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

/* Texte dans la transition */
.transition-text {
  font-size: 2rem;
  font-weight: bold;
  opacity: 0;
  transform: scale(0.8);
}

.transition.active .transition-text {
  opacity: 1;
  transform: scale(1) ease;
}

/* Classe active pour démarrer la transition */
.transition.active {
  transform: scaleY(1);
}

/* --- Section principale (main) --- */

.top-video {
  margin: 0;
  width: 100%;
  height: 100vh;
}

.roll {
  width: 100%;
  height: 100%;
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  z-index: 997;
}

.overlay {
  content: "";
  margin: 0;
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 100vh;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.374) 10%,
    rgba(0, 0, 0, 0.87) 70%
  );
}

.video {
  overflow: hidden;
  background-size: cover;
}

#video {
  width: 100%;
  min-height: 100vh;
  background-size: cover;
  object-fit: cover;
}

main {
  min-height: 100vh;
}

/* --- Pied de page (footer) --- */
footer {
  color: white;
  text-align: center;
  position: absolute;
  bottom: 0;
  width: 100%;
  font-size: 3rem;
  z-index: 998;
  height: 150px;
}

footer ul {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3rem;
  margin: 0;
  padding: 0;
}

footer a {
  color: white;
  text-decoration: none;
  transition: 1s;
}

footer a:hover {
  color: #ed2a1d;
  font-size: 2.5rem;
}

/* --- Responsive --- */

/* Pour les écrans plus petits que 1200px (Tablettes et petits ordinateurs) */
@media (max-width: 1200px) {
  header {
    font-size: 12px;
    height: 150px;
  }

  .nav ul {
    gap: 3rem;
  }

  .nav a {
    font-size: 24px;
  }

  footer {
    font-size: 2.5rem;
    gap: 2rem;
    height: 80px;
  }
}

/* Pour les écrans plus petits que 768px (Tablettes portrait et grands téléphones) */
@media (max-width: 768px) {
  header {
    height: auto;
    font-size: 10px;
  }

  header img {
    width: 150px;
  }

  .nav ul {
    gap: 2rem;
  }

  .nav a {
    font-size: 10px;
  }

  footer {
    font-size: 2rem;
    gap: 1.5rem;
    height: 70px;
  }

  .overlay {
    height: 80vh; /* Ajuster la taille de l'overlay pour les écrans plus petits */
  }

  .video {
    height: 80vh; /* Ajuster la vidéo */
  }
}

/* Pour les écrans plus petits que 480px (Téléphones mobiles) */
@media (max-width: 480px) {
  header {
    width: 100%;
  }

  header img {
    width: 100px;
  }

  .nav ul {
    gap: 1rem;
  }

  .nav a {
    font-size: 8px;
  }

  footer {
    font-size: 1.8rem;
    gap: 1rem;
    height: 60px;
  }

  .overlay {
    height: 60vh; /* Ajuster l'overlay pour les petits écrans */
  }

  .video {
    height: 60vh; /* Ajuster la vidéo */
  }
}
