/****************************************************
 * logo_modal.css
 * => Styles pour la fenêtre modale (overlay)
 *    + Polices
 *    + Animation (bond/vibration) 
 *    => Blason + LaCompté
 *    => Logo Edouargot + VILLESEQUELANDE-2017 
 ****************************************************/

/* A) Snailets BRK => Titre h2.snail-title */
@import url('https://fonts.cdnfonts.com/css/snailets-brk');
@import url('https://fonts.cdnfonts.com/css/salterio-gradient');

/* B) Uncial Antiqua => texte “Il était une fois Edouargot…” */
@import url('https://fonts.googleapis.com/css2?family=Uncial+Antiqua&display=swap');


/* ========== OVERLAY (caché par défaut) ========== */
#logoModalOverlay {
  display: none;                /* sera réglé à flex en JS */
  position: fixed;
  top: 0; 
  left: 0; 
  right: 0; 
  bottom: 0;
  background: rgba(0,0,0,0.7);
  z-index: 9999;

  /* Centrage du contenu (modale) */
  justify-content: center;
  align-items: center;
}

/* ========== CONTENU DE LA MODALE ========== */
#logoModalContent {
  background: #3a3a3a;
  border: 2px solid #6C9F42;
  border-radius: 8px;
  color: #fff;
  position: relative;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0,0,0,0.4);

  /* Largeur et hauteur “max” sur écrans plus larges */
  width: 80%;
  max-width: 800px;
  padding: 1rem;
  margin: auto;

  /* Pour le “volet déroulant” : 
     on limite la hauteur et on scrolle à l’intérieur si besoin */
  max-height: 80vh;
  overflow-y: auto;
}

/* ----- Scrollbar design (fonctionne sur WebKit) ----- */
#logoModalContent::-webkit-scrollbar {
  width: 8px;
}
#logoModalContent::-webkit-scrollbar-track {
  background: #2a2a2a;
}
#logoModalContent::-webkit-scrollbar-thumb {
  background-color: #6C9F42;
  border-radius: 4px;
}

/* ========== BOUTON DE FERMETURE (CROIX) ========== */
.close-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  background: transparent;
  border: none;
  color: #6C9F42;
  font-size: 1.2rem;
  cursor: pointer;
}

/* ========== TITRE => Snailets BRK ========== */
.snail-title {
  margin-top: 0;
  font-family: 'Snailets BRK', sans-serif;
  font-size: 48px; /* Ajustez selon vos besoins */
  line-height: 1.2;
  margin-bottom: 1rem;
}

/* ========== BLOC FLEX => Blason & LaCompté ========== */
.blason-comte-container {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  align-items: center;
  margin-bottom: 1.5rem;
}
/* Blason */
.blason-img {
  max-width: 120px;
  height: auto;
  display: block;
  margin: 0 auto;
}
/* LaCompté => ~ 30% bigger => ~195px */
.comte-img {
  max-width: 195px;
  height: auto;
  display: block;
  margin: 0 auto;
}

/* ========== TEXTE => Uncial Antiqua ========== */
.enluminure {
  font-family: 'Uncial Antiqua', cursive;
  font-size: 22px; 
  line-height: 1.4;
  margin-bottom: 1.5rem;
}

/* ========== BLOC FLEX => LOGO Edouargot + VILLESEQUELANDE ========== */
.logo-town-container {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  align-items: center;
  margin-bottom: 1.5rem;
}

/* Logo Edouargot (animé) */
.logo-modal {
  max-width: 150px;
  height: auto;
  display: block;
  margin: 0 auto;
  cursor: pointer;
}

/* VILLESEQUELANDE => ex: 300px max => ajustable */
.villes-2017-img {
  max-width: 300px;
  height: auto;
  display: block;
  margin: 0 auto;
  cursor: pointer;
}

/* ========== ANIMATION => bond/vibration ========== */
@keyframes clickVibe {
  0%   { transform: scale(1) rotate(0deg); }
  30%  { transform: scale(1.2) rotate(1deg); }
  50%  { transform: scale(0.9) rotate(-1deg); }
  70%  { transform: scale(1.1) rotate(1deg); }
  100% { transform: scale(1) rotate(0deg); }
}
.logo-click {
  animation: clickVibe 0.45s ease forwards;
}

/* ========== RESPONSIVE (smartphones / tablettes) ========== */
@media (max-width: 768px) {

  /* On occupe davantage l'écran et on rend le contenu encore plus scrollable */
  #logoModalContent {
    width: 95vw;
    height: 95vh;         /* pour prendre quasi tout l’écran */
    max-width: 95vw;
    max-height: 95vh;
    /* Au besoin, adapter le padding si trop serré */
    padding: 0.8rem;
  }

  .snail-title {
    font-size: 32px;
  }
  .enluminure {
    font-size: 18px;
  }
  .logo-modal {
    max-width: 120px;
  }
  .comte-img {
    max-width: 150px;
  }
  .villes-2017-img {
    max-width: 200px;
  }
}
