/* Masquer header et footer */
.site-header, .site-footer {
  display: none !important;
}

.fond-chemin {
  background: url("../images/fonds/fond_chemin.webp") no-repeat center center fixed;
  background-size: cover;
  color: #ffffff;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  font-family: 'Libre Baskerville', serif;
  text-align: center;
}

/* Texte brumeux mais lisible */
.chemin-texte {
  position: absolute;
  top: 42%;
  left: 55%;
  transform: translate(-50%, -50%);
  font-size: 1.5vw; /* taille relative à la largeur de l'écran */
  line-height: 1.4;
  color: rgba(180, 200, 245, 0.5);
  text-shadow:
    0 0 6px rgba(180,200,255,0.5),
    0 0 14px rgba(120,160,255,0.3);
  opacity: 0;
  filter: blur(0.5px);
  transition: opacity 4s ease-in-out;
  text-align: center;
  max-width: 40%;
}

@media (max-width: 768px) {
  .chemin-texte {
    font-size: 3vw; /* texte plus petit sur tablette/mobile */
    max-width: 60%;
  }
}

@media (max-width: 480px) {
  .chemin-texte {
    font-size: 4vw;
    max-width: 80%;
  }
}

.chemin-doyen {
  position: absolute;
  top: 65%;
  left: 85%;
  transform: translate(-50%, -50%);
  font-size: 1.1rem;
  font-style: italic;
  color: rgba(180, 200, 245, 0.5);
  text-shadow:0 0 10px rgba(140,160,220,0.4);
  opacity: 0;
  pointer-events: none;
  white-space: nowrap;

  /* Défloutage : animation en pause */
  animation: flouTexte 4.5s ease-out forwards;
  animation-play-state: paused;
}

@keyframes flouTexte {
  from { filter: blur(4px); }
  to { filter: blur(1px); }
}


/* Lumières / feux follets */
.feu-follet {
  position: absolute;
  width: 88px;          /* taille de base */
  height: auto;
  opacity: 0;
  pointer-events: none;
  transition: opacity 2s ease-in-out;
  filter:
    drop-shadow(0 0 6px rgba(120,180,255,0.6))
    drop-shadow(0 0 14px rgba(80,140,255,0.4))
	blur(1.05px);

  animation: oscillationFlamme 4.5s ease-in-out infinite;
  transform-origin: center bottom;
}

.feu-follet:nth-child(odd) {
  animation-duration: 4.7s;
}

.feu-follet:nth-child(even) {
  animation-duration: 4.3s;
}

/* Oscillation des flammes */
@keyframes oscillationFlamme {
  0% { transform: rotate(-1deg) scale(1); }
  25% { transform: rotate(1deg) scale(1.03); }
  50% { transform: rotate(-0.5deg) scale(0.98); }
  75% { transform: rotate(0.8deg) scale(1.02); }
  100% { transform: rotate(-1deg) scale(1); }
}

/* Assurer que les flammes restent au-dessus du fond mais sous header/footer */
body {
  position: relative;
  overflow-x: hidden;
}

.chemin-texte {
  z-index: 10; /* texte au-dessus des flammes */
}


@media (max-width: 768px) {
  .fond-chemin {
    height: 100vh;
    height: 100dvh;
    align-items: flex-start;
    padding-top: 10vh;
  }
  
  .chemin-texte {
    position: relative;
    top: auto;
    left: auto;
    transform: none;

    font-size: 1.1rem;
    max-width: 90%;
    margin: 0 auto;

    text-align: center;
  }
  
  .feu-follet {
    width: 50px;
    opacity: 0.7;
  }  
}

@media (max-width: 400px) {
  .chemin-texte {
    font-size: 0.95rem;
    max-width: 95%;
  }

  .chemin-doyen {
    font-size: 0.9rem;
  }
}

@media (orientation: portrait) {
  .chemin-texte {
  top: 42%;
  left: 33%;
  }
  
  .chemin-doyen {
    position: absolute;
    top: 45%;
    left: 40%;
  }
}