body,
html {
  margin: 0;
  padding: 0;
  font-family: Arial, sans-serif;
  overflow-x: hidden;
}

nav {
  color: black;
  box-shadow: 9px 20px 50px hsl(0, 68%, 17%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(to right, #312ba4, #2649bb);
  position: fixed;
  top: 0;
  padding: 5px;
  width: 100%;
  z-index: 2;
  max-width: 100vw;
}

.nav-left,
.nav-right {
  margin: 1vh 10vh 0 10vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-left img {
  height: 40px;
  margin-right: 1px;
}

.nav-left h4 {
  margin: 0;
  font-size: 24px;
  font-weight: bold;
}

.nav-right a {
  text-decoration: none;
  color: white;
  font-size: 18px;
  padding: 0 50px;
}
.nav-right a:hover {
  color: rgb(229, 255, 0);
  text-decoration: underline;
}

nav::before {
  content: "";
  position: absolute;
  top: -1px;
  left: -20px;
  right: -10px;
  bottom: -40px;
  z-index: -1;
  background: linear-gradient(to right, #ccc5fb, #0d03d1);
  filter: blur(15px);
}

.mainUp,
.mainUp2 {
  z-index: 1;
  position: absolute;
  display: flex;
  width: 80%;
}
.mainUp img {
  top: 50vh;
  width: 50%;
  position: relative;
  left: 20%;
}
.mainUp2 img {
  top: 2vh;
  width: 10%;
  position: absolute;
  border-radius: 50%;
}
.mainUp img,
.mainUp2 img {
  border-radius: 50%;
  animation: rotation 15s linear infinite;
}

@keyframes bounce {
  0%,
  100% {
    bottom: 0;
  }
  50% {
    bottom: 550px;
  }
}

@keyframes rotation {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@keyframes reverseRotation {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(-360deg); /* Sens inverse */
  }
}

.mainUp2 img {
  animation: rotation 12s linear infinite;
}
.mainUp img {
  animation: reverseRotation 8s linear infinite;
}

.mainUp {
  max-width: 500px;
  animation: rotation 15s linear infinite;
}

.bodystory {
  position: relative;
  z-index: 1;
  color: white;
  padding: 10%;
}

#background-video {
  top: 5vh;
  position: fixed;
  right: 0;
  bottom: 0;
  min-width: 100%;
  min-height: 100%;
  z-index: -1;
}

.music-box {
  border: 2px solid #ddd;
  border-radius: 10px;
  padding: 20px;
  width: 300px;
  text-align: center;
  background: linear-gradient(
      rgba(255, 255, 255, 0.5),
      rgba(255, 255, 255, 0.5)
    ),
    url(../assets/lecteurk7.jpeg) no-repeat center / cover;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  margin: 200px auto 0;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.music-box:hover {
  transform: scale(1.2); /* Augmente la taille */
  box-shadow: 0 8px 12px rgba(0, 0, 0, 0.2); /* Accentue l'ombre */
}

.music-box h4 {
  color: #e9fb43;
  margin-bottom: 10px;
  font-size: 2em;
  text-shadow: 2px 4px 6px rgba(0, 0, 0, 1);
}

.controls button {
  background-color: #3ac333ac;
  color: white;
  border: none;
  padding: 10px;
  margin: 5px;
  border-radius: 50%;
  font-size: 1.2em;
  cursor: pointer;
}

.controls button:hover {
  background-color: #c159cab6;
}

.controls button:disabled {
  background-color: #ccc;
  cursor: not-allowed;
}

/* Style pour le bouton actif */
.controls button.active {
  background-color: #1bb2e0; /* Vert pour indiquer que la boucle est active */
  color: white;
}

#intro,
#fin,
.lutin-card {
  position: relative;
  z-index: 2;
  color: rgb(48, 27, 81);
  margin-top: 100px;
  font-weight: bold;
  box-shadow: 1px 1px 20px 20px rgba(26, 26, 255, 0.871);
  background: #bebbffc9;
  padding: 10px;
  border: 1px solid rgb(0, 0, 255);
  border-radius: 10px;
}

#fin .gras {
  color: yellow;
  font-size: larger;
}

#secret {
  font-style: italic;
  color: #ffffff;
  animation: clignoter-shadow 0.8s infinite alternate-reverse;
}

.marque {
  animation: clignoter-shadow 0.8s infinite alternate;
  font-size: 20px;
  font-weight: bold;
  z-index: 999;
  text-shadow: 5px 5px 5px #ffffff;
  color: rgb(66, 3, 255);
}

@keyframes clignoter-shadow {
  0% {
    text-shadow: 2px 2px 10px rgb(0, 4, 255), -2px -2px 5px rgb(174, 187, 255);
  }
  100% {
    text-shadow: 2px 2px 20px rgb(255, 255, 255), -2px -2px 5px rgb(4, 12, 255);
  }
}

p {
  text-align: center;
  font-size: 1.2rem;
  color: yellow;
}

h1,
h3 {
  z-index: 999;
  font-family: fantasy;
  text-shadow: 1px 2px 5px rgb(255, 0, 0);
  font-size: 8rem;
  text-align: center;
  margin-top: 0;
  color: rgb(200, 255, 0);
}

.lutin-grid {
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin-top: 100px;
}

.lutin-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  position: relative;
}

.lutin-card {
  font-weight: bold;
  font-size: 5rem;
  padding: 50px;
  flex: 1;
  max-width: 30%;
  transition: transform 0.2s;
}

.lutin-card:hover {
  transform: translateY(-10px);
}

.lutin-card h4 {
  text-shadow: 1px 2px 3px #3925b7;
  text-transform: uppercase;
  margin: 0 0 10px 0;
  font-size: 2rem;
}

.lutin-card p {
  text-align: justify;
  margin: 0;
  font-size: 1.5rem;
}

.lutin-image {
  margin-top: 15%;
  box-shadow: 1px 1px 20px 20px rgb(169, 224, 253);
  border: none;
  border-radius: 50%;
  max-width: 40%;
  position: relative;
  align-items: center;
  justify-content: center;
}

.lutin-row:nth-child(even) .lutin-card {
  order: 1;
}

.lutin-row:nth-child(even) .lutin-image {
  order: 2;
}

.lutin-row:nth-child(odd) .lutin-card {
  order: 2;
}

.lutin-row:nth-child(odd) .lutin-image {
  order: 1;
}

#fin {
  text-align: center;
}

footer {
  z-index: 1000;
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 20px;
  background: linear-gradient(to left, #ffffff, #bb2649);
  width: 100%;
  color: white;

  position: relative;
  bottom: 0;
}

.footer-left,
.footer-center,
.footer-right {
  text-align: center;
}

.footer-center {
  display: flex;
  justify-content: center;
  /* gap: 20px; */
  color: white;
}

.footer-center a {
  color: white;
  text-decoration: none;
}

.footer-right a {
  color: black;
  padding: 10px;
  font-size: 14px;
  text-decoration: none;
}

.footer-right a:hover {
  text-decoration: underline;
}

footer::before {
  content: "";
  position: absolute;
  top: -35px;
  left: -10px;
  right: -10px;
  bottom: -50px;
  z-index: -1;
  background: linear-gradient(to right, #0d03d1, #ccc5fb);
  filter: blur(15px);
}

/* Media Queries */
@media (max-width: 1024px) {
  h1 {
    font-size: 4rem;
  }

  #nblut {
    font-size: 4rem;
  }
  .mainUp img {
    width: 25%;
    position: absolute;
    left: 1vw;
    top: 30vh;
  }

  .mainUp2 img {
    width: 20%;
    position: absolute;
    left: 80%;
    top: 20vh;
  }
}

/* ********************************768*********************** */
@media (max-width: 768px) {
  .lutin-row {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .lutin-image {
    order: 1 !important;
    max-width: 80%;
    margin-bottom: 20px;
  }
  .lutin-card {
    order: 2 !important;
    font-size: 2.5rem;
    max-width: 100%;
    margin: 10px auto;
    max-width: 90%;
  }

  nav {
    flex-direction: column;
    padding: 10px;
  }

  .nav-right a {
    font-size: 16px;
    padding: 0 20px;
  }

  footer {
    flex-direction: column;
    padding: 10px;
    text-align: center;
  }

  /* Ajustement de mainUp et mainUp2 pour mobile */
  .mainUp img {
    width: 25%;
    position: absolute;
    left: 10vw;
    top: 8vh;
  }

  .mainUp2 img {
    width: 25%;
    position: absolute;
    top: 30vh;
  }
}

@media (max-width: 480px) {
  body {
    margin-top: 100px;
  }
  h1 {
    font-size: 2rem;
  }

  p,
  .lutin-card p {
    font-size: 1rem;
  }

  .lutin-card {
    font-size: 2rem;
    padding: 20px;
    max-width: 100%;
    margin: 5px auto;
  }

  .lutin-image {
    max-width: 80%;
  }

  nav {
    flex-direction: column;
    padding: 5px;
  }

  .nav-left h4 {
    font-size: 18px;
  }

  .nav-right a {
    font-size: 14px;
    padding: 5px 10px;
  }

  footer .footer-left {
    font-size: 12px;
  }

  .footer-right a {
    font-size: 12px;
    padding: 5px;
  }
  .footer-center {
    margin: 20px;
  }

  /* Ajustement pour les très petits écrans */
  .mainUp img {
    width: 30%;
    position: absolute;
    left: 5vw;
    top: 28vh;
  }

  .mainUp2 img {
    width: 20%;
    position: absolute;
    left: 5vw;
    top: 10vh;
  }
}
