/* =======================================================
   RESET GLOBAL (anti scroll parasite)
   ======================================================= */

html, body {
  margin: 0;
  padding: 0;
  overflow: hidden;        /* bloque scroll vertical */
  overflow-x: hidden;      /* sécurité horizontale */
}

/* =======================================================
   FOND GENERAL
   ======================================================= */

.fond-portail-enceinte {
  background-image: url("../images/fonds/fond_portail_enceinte.webp");
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;
  color: #fff;
}

/* Mobile : fond portrait */
@media (max-width: 600px){
  body.fond-portail-enceinte{
    background-image: url("../images/fonds/fond_portail_mobile.webp");
    background-position: center;
  }
}

/* =======================================================
   SCENE PRINCIPALE
   ======================================================= */

.scene {
  position: relative;
  width: 100%;
  height: calc(100vh - 120px); /* ajuste selon header/footer */
}

/* Mobile : un peu plus d’espace */
@media (max-width: 600px){
  .scene {
    height: calc(100vh - 100px);
  }
}

/* Desktop */
.texte-mobile {
  display: none;
}

/* Mobile */
@media (max-width: 600px){

  .texte-desktop {
    display: none;
  }

  .texte-mobile {
    display: block;
  }

}

/* =======================================================
   ZONES CLIQUABLES — DESKTOP
   ======================================================= */

.gargouille {
  position: absolute;
  top: 35%;
  left: 8%;
  width: 30%;
  height: 70%;
  cursor: pointer;
  background: rgba(0, 0, 0, 0);
  transition: transform 0.3s ease;
}

.gargouille:hover {
  transform: scale(1.05);
}

.porte-derobee {
  position: absolute;
  top: 28%;
  right: 20%;
  width: 12%;
  height: 66%;
  cursor: pointer;
  background: rgba(0, 0, 0, 0);
  transition: opacity 0.3s ease;
}

.porte-derobee:hover {
  opacity: 0.7;
}

/* =======================================================
   ZONES CLIQUABLES — MOBILE
   ======================================================= */

@media (max-width: 600px){
  .gargouille {
    top: 0%;
    left: 0%;
    width: 60%;
    height: 30%;
  }

  .porte-derobee {
    top: 43.5%;
    right: 0%;
    width: 45%;
    height: 55%;
  }
}

/* =======================================================
   PARCHEMIN — DESKTOP
   ======================================================= */

.parchemin {
  position: absolute;
  top: 50%;
  left: 48%;
  transform: translate(-50%, -50%);

  width: 240px;
  padding: 2rem 1rem;

  background: url("../images/parchemin_portrait.webp");
  background-size: cover;
  background-repeat: no-repeat;

  text-align: center;
  color: #5c3b0b;

  animation: flotter 6s ease-in-out infinite;
}

@media (max-width: 900px){
.parchemin {
    width: 175px;
    padding: 2rem 1rem;
    font-size: 0.8rem;
  }

.parchemin h2 {
  margin-bottom: 10px;
  font-family: "Cinzel Decorative", serif;
  }
}

/* =======================================================
   PARCHEMIN — MOBILE (horizontal)
   ======================================================= */
@media (max-width: 600px){
  .parchemin {
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);

    width: 300px;
    padding: 2rem 2rem;

    background: url("../images/parchemin_paysage.webp");
    background-size: contain;   /* ✅ IMPORTANT */
    background-position: center; /* ✅ centre propre */
    background-repeat: no-repeat;

    text-align: center;
    color: #5c3b0b;

    animation: flotter 6s ease-in-out infinite;

    font-size: 0.8rem;
  }
  
  .parchemin h2 {
    margin-bottom: 8px;
    font-family: "Cinzel Decorative", serif;
  }
}

/* =======================================================
   ANIMATION PARCHEMIN
   ======================================================= */

@keyframes flotter {
  0%, 100% {
    transform: translate(-50%, -50%) rotate(-0.5deg);
  }
  50% {
    transform: translate(-50%, -52%) rotate(0.5deg);
  }
}

/* =======================================================
   ENVELOPPE
   ======================================================= */

.enveloppe-volante {
  position: absolute;
  top: 30%;
  left: 10%;

  width: 90px;
  height: 60px;

  background: url("../images/icones/enveloppe.webp") no-repeat center;
  background-size: contain;

  cursor: pointer;
  z-index: 20;

  transition: transform 0.2s ease;
}

.enveloppe-volante:hover {
  transform: scale(1.1);
}

/* Mobile */
@media (max-width: 900px){
  .enveloppe-volante {
    top: 30%;
    left: 5%;
    top: auto;

    width: 60px;
    height: 40px;
  }
}