/* =========================================
   INDEX.CSS — Styles spécifiques à la page d’accueil
   (Laisse les styles communs dans styles.css)
   ========================================= */


/*============================
======= FICHIERS COMMUNS ========
=============================
   Tout ce qui s’applique à tous les formats,
   hors media queries
=============================*/

/* =======================
   FLASH INFO (bande courte)
======================= */
.flash-info{
  background: #BDBDBD;
  color:#000;
  font-weight:bold;
  padding: 12px 0;
  border-radius: 10px;
  margin: 50px auto;
  display:block;
  width: 80%;
  max-width: 1000px;
  text-align:center;
  box-sizing:border-box;
}

/* (si tu as besoin d’une autre petite boîte flash) */
.flash-box{
  background: #BDBDBD;
  color:#000;
  font-weight:bold;
  padding:20px;
  border-radius:8px;
  max-width:800px;
  margin:0 auto;
}


/* =======================
  LIFTING
======================= */
.lifting{
  background: #BDBDBD;
  color: red;
  font-weight:bold;
  font-size: 20px;
  padding: 20px 0;
  border-radius: 10px;
  margin: 50px auto;
  display:block;
  width: 100%;
  max-width: 1200px;
  text-align:center;
  box-sizing:border-box;
}


/* =======================
   FLASH CONTAINER (bloc de lignes)
======================= */
.FlashContainer{
  width: min(1000px, 80%);
  margin: 40px auto;
  padding: 16px 12px;
  background: #BDBDBD;
  border: 1px solid #000;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  box-sizing: border-box;
  text-align: center;
}

.flash-line{
  font-weight: bold;
  line-height: 1.2;
  font-size: clamp(14px, 2vw + 6px, 20px);
  color: #000;
  margin: 0;
}

.flash-sep{
  font-weight: bold;
  line-height: 1;
  font-size: clamp(14px, 2vw + 6px, 20px);
  margin: 6px 0 2px;
  color: #000;
}

/* petite anim douce */
@keyframes flash-rise {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.flash-line, .flash-sep{ animation: flash-rise .4s ease-out both; }
.flash-line:nth-child(1){ animation-delay: .1s; }
.flash-line:nth-child(2){ animation-delay: .2s; }
.flash-line:nth-child(3){ animation-delay: .3s; }
.flash-sep             { animation-delay: .4s; }
.flash-line:nth-child(5){ animation-delay: .5s; }


/* =======================
   Section MANON (Index)
======================= */

/* Conteneur global : simple grille 2 colonnes (desktop) */
.manon-group {
  display: grid;
  grid-template-columns: 1fr 1fr; /* 2 colonnes équilibrées */
  gap: 60px;                      /* espace entre les colonnes */
  align-items: start;
  justify-content: center;
  margin: 100px 50px auto 80px;   /* centré par rapport à la page */
  max-width: 1400px;
  box-sizing: border-box;
}

/* Colonne gauche */
.manon-left {
  display: flex;
  flex-direction: column;
  gap: 18px; /* espace entre photo & diapo */
  margin-left: 0; /* déplacement spécifique de la colonne gauche */
}

/* Photo responsive */
.manon-photo-box img {
  width: 120%;
  max-width: 600px;
  height: auto;
  display: block;
  border-radius: 10px;
}

/* Colonne droite : texte */
.manon-text-box {
  background: #BDBDBD;
  border: 1px solid #000;
  border-radius: 10px;
  padding: 30px;
  max-width: 700px;
  font-weight: bold;
  font-style: italic;
  line-height: 1.3;
  color: #000;
  margin: 120px auto auto auto; /* déplacement spécifique de la colonne droite */
}

.manon-text-box p {
  text-indent: 25px;
  margin: 0 0 8px;
}


/* ==========================
   ASSOCIATION + GENDARMES 
========================== */

.association-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: stretch;     /* étire les enfants à la même hauteur */
  flex-wrap: wrap;
  gap: 90px;
  max-width: 1400px;
  margin: 80px auto 40px;
  padding: 0 20px;
  box-sizing: border-box;
}

/* TEXTE ASSOCIATION (responsive) */

.text-association {
  flex: 1 1 46%;
  max-width: 620px;
  background: #BDBDBD;
  border: 1px solid #000;
  border-radius: 10px;
  color: #000;
  padding: 28px 32px;
  line-height: 1.3;
  font-family: Verdana, Arial, sans-serif;
  font-style: italic;
  font-weight: normal;
  font-size: clamp(14px, 1.4vw, 16px);
  box-sizing: border-box;
  display: flex;            /* ✅ pour que le texte s’étire verticalement */
  flex-direction: column;
  justify-content: center;  /* centre verticalement le texte */
}

.text-association p {
  margin: 0 0 10px;
  text-indent: 25px;
}

/* IMAGE GENDARMES (responsive) */
.gendarmes-image {
  flex: 1 1 46%;
  max-width: 750px;
  border: 1px solid #000;
  border-radius: 10px;
  background: #fff;
  box-sizing: border-box;
  overflow: hidden;

  display: flex;            /* ✅ image occupe toute la hauteur */
  align-items: center;
  justify-content: center;
}

.gendarmes-image img {
  width: 100%;
  height: 100%;             /* ✅ image remplit la hauteur */
  object-fit: cover;        /* garde un cadrage équilibré sans déformation */
  border-radius: 10px;
}


/* =======================
   VIDEO (Index) - Version agrandie et responsive
======================= */

/* Vidéo responsive contrôlée par le conteneur */
.video-space{
  position: relative;
  width: 100%;
  max-width: 800px;     /* plus grand sur desktop */
  margin: 80px auto;
  background: #000;     /* fond propre autour si besoin */
  border: 1px solid #000;
  border-radius: 10px;
  overflow: hidden;

  /* <<< règle le ratio ici : 16/9 pour YouTube standard */
  aspect-ratio: 16 / 9;
}

/* l’iframe remplit ENTIEREMENT la boîte ci-dessus */
.video-space iframe{
  position: absolute;
  inset: 0;              /* top:0; right:0; bottom:0; left:0 */
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}


/* ==========================
   PORTEAU
========================== */

.porteau-image img {
  max-width: 500px;  /* (fusion des deux définitions : 400px retenu) */
  margin: 90px auto 50px 120px;
  width: 100%;
  height: auto;
  display: block;
  border: none;
  border-radius: 10px;
}

/* ==========================
   DIAPO JOUR
========================== */

.diaporama {
  position: relative;
  width: 100%;
  max-width: 500px;     /* largeur max desktop */
  aspect-ratio: 4 / 3;  /* format 4:3 */
  background: #047303;
  border: none;
  border-radius: 10px;
  overflow: hidden;
  transition: max-width 0.3s ease;
}

.diaporama .slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
}

.diaporama .slide.active {
  opacity: 1;
}

/* Les images des diaporamas remplissent la boîte
   sans être coupées */
.diaporama img {
  width: 100%;
  height: 100%;
  object-fit: contain;  /* 👉 montre TOUTE l’image (avec bandes vertes si besoin) */
  display: block;
}

/* ==========================
   DIAPO NUIT
========================== */

.diaporama-nuit {
  position: relative;
  width: 100%;
  max-width: 500px;     /* largeur max desktop */
  aspect-ratio: 4 / 3;  /* format 4:3 */
  background: #047303;
  border: none;
  border-radius: 10px;
  overflow: hidden;
  transition: max-width 0.3s ease;
}

.diaporama-nuit .slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
}

.diaporama-nuit .slide.active {
  opacity: 1;
}

/* Les images des diaporamas remplissent la boîte
   sans être coupées */
.diaporama-nuit img {
  width: 100%;
  height: 100%;
  object-fit: contain;  /* 👉 montre TOUTE l’image (avec bandes vertes si besoin) */
  display: block;
}


/* =============================
====== FICHIERS PETITS FORMATS ======
=============================
   Smartphones portrait
   (≤ 480px et certains blocs ≤ 700px)
==============================*/

/* --- Responsive (smartphone portrait ≤480px) --- */
@media (max-width: 480px) {
  .flash-info{
    width: 92%;
    margin: 24px auto;
    padding: 10px 0;
    border-radius: 8px;
  }
}

/* --- Responsive --- */
@media (max-width: 480px) {
  .flash-box{
    width: 92%;
    padding: 14px;
  }
}

/* --- Responsive --- */
@media (max-width: 480px) {
  .lifting{
    font-size: 18px;
    width: 92%;
    margin: 28px auto;
    padding: 14px 0;
    border-radius: 8px;
  }
}

/* --- Responsive --- */
@media (max-width: 700px) {
  .FlashContainer{
    width: 92%;
    margin: 24px auto;
    padding: 12px 10px;
    border-radius: 8px;
    gap: 6px;
  }
}

/* --- Responsive (smartphone portrait ≤700px) --- */
@media (max-width: 700px) {
  .manon-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 10px auto;
    max-width: 95%;
  }

  .manon-left { order: 1; }

  .manon-photo-box,
  .manon-photo-box img {
    width: 100% !important;
    max-width: 100% !important;
  }

  .manon-photo-box img {
    margin: 0 auto 15px !important;
  }

  .manon-text-box {
    order: 2;
    margin: 0 !important;
    padding: 14px;
    max-width: 100%;
    font-size: 14px;
    line-height: 1.35;
  }
}

/* --- Responsive (smartphone portrait ≤480px) --- */
@media (max-width: 480px) {
  .association-wrapper {
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin: 40px auto 20px;
    padding: 0 12px;
  }

  .text-association,
  .gendarmes-image {
    flex: 1 1 100%;
    max-width: 95%;
    height: auto;           /* sur mobile, on enlève la hauteur forcée */
  }

  .gendarmes-image img {
    height: auto;           /* pour éviter l’écrasement sur petit écran */
    object-fit: contain;
  }
}

/* --- Responsive (smartphone portrait ≤700px) --- */
@media (max-width: 700px) {
  .zone-photos {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
    margin: 20px auto;
  }

  .diaporama,
  .diaporama-nuit {
    width: 100%;
    max-width: 100%;
    height: auto;
  }

  .porteau-image img {
    width: 100%;
    max-width: 100%;
    height: auto;
    margin: 30px auto;
  }
}

/* --- Responsive (smartphone portrait ≤480px) --- */
@media (max-width: 480px) {
  .video-space {
    width: 100%;
    max-width: 100%;
    margin: 80px auto 20px auto;
  }
}


/*============================
====== FICHIERS MOYENS FORMATS =====
=============================
   Smartphones paysage + tablettes portrait
==============================*/

/* ==================================================
   TABLETTES (701px à 1100px)
   Version commune iPad + autres tablettes
================================================== */

@media (min-width: 701px) and (max-width: 1100px){

  /* Flashs un peu plus compacts */
  .flash-info,
  .flash-box,
  .lifting,
  .FlashContainer,
  .video-space {
    width: 90%;
    margin: 30px auto;
  }

  /* Bloc MANON : moins de marge, colonnes un peu resserrées */
  .manon-group {
    margin: 60px auto 30px auto;
    max-width: 1100px;
    gap: 30px;
  }

  .manon-left{
    position: relative;
    top: 0;        /* tu peux ajuster si tu veux */
    left: 0;
  }

  .manon-photo-box img {
    width: 100%;
    max-width: 550px;
    height: auto;
  }

  .manon-text-box {
    margin: 60px auto auto auto;
    padding: 24px;
    max-width: 650px;
  }

  /* Association + gendarmes : un peu moins large */
  .association-wrapper {
    gap: 40px;
    margin: 60px auto 30px;
    padding: 0 16px;
  }

  /* Zone 3 photos : on garde la grille en 3 colonnes, mais plus "resserrée" */

  .zone-photos {
    max-width: 1200px;
    gap: 28px;
    margin: 30px auto;
    padding: 0 16px;
  }

  .diaporama {
    max-width: 550px;   /* diapos un peu plus grandes que la base (500px) */
}
  .diaporama-nuit {
    max-width: 550px;   /* diapos un peu plus grandes que la base (500px) */
  }

  .porteau-image img {
    max-width: 380px;
    margin: 60px auto auto 0px;
  }
}

/* ==================================================
====================================================
====================================================
   SMARTPHONE PAYSAGE (≤ 700px + orientation: landscape)
   On se rapproche du layout "colonne" du portrait
==================================================
==================================================
================================================== */

@media (max-width: 700px) and (orientation: landscape) {

  /* Flashs plus compacts, comme sur mobile portrait */
  .flash-info,
  .flash-box,
  .lifting,
  .FlashContainer {
    width: 92%;
    margin: 20px auto;
    border-radius: 8px;
  }

  /* MANON : colonne, comme en portrait mais un peu plus aéré */
  .manon-group {
    margin: 20px auto;
    max-width: 95%;
    gap: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .manon-left{
    position: relative;
    top: 0;
    left: 0;
    width: 100%;
    text-align: center;
  }

  .manon-photo-box img {
    width: 90%;
    max-width: 380px;
    height: auto;
    margin: 0 auto 10px;
  }

  .manon-text-box {
    margin: 0 auto;
    padding: 14px;
    max-width: 95%;
    font-size: 14px;
    line-height: 1.35;
  }

  /* ASSOCIATION + GENDARMES : en colonne */
  .association-wrapper {
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin: 40px auto 20px;
    padding: 0 12px;
  }

  .text-association,
  .gendarmes-image {
    flex: 1 1 100%;
    max-width: 95%;
    height: auto;
  }

  .gendarmes-image img {
    height: auto;
    object-fit: contain;
  }

  /* ZONE 3 BLOCS : on empile tout en colonne */

  .zone-photos {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
    margin: 20px auto;
    max-width: 95%;
    padding: 0;
  }

  .diaporama,
  .diaporama-nuit {
    width: 100%;
    max-width: 100%;
    height: auto;
  }

  .porteau-image{
    position: relative;
    left: -35px;   /* décale vers la gauche → ajuste à ton goût */
    top: -20px;    /* remonte un peu → ajuste aussi si besoin */
    margin-bottom: 20px;
    width: 100%;   /* sécurité */
  }

  .porteau-image img{
    width: 90%;    /* optionnel → réduit légèrement l’image */
    max-width: 90%;
  }

  /* Vidéo : pleine largeur en paysage */
  .video-space {
    width: 100%;
    max-width: 100%;
    margin: 40px auto 20px auto;
  }
}


/*============================
===== FICHIERS GRANDS FORMATS ======
=============================
   Tablettes paysage + petits ordinateurs portables
   (actuellement pas de règles spécifiques ici,
    mais section prête pour plus tard)
==============================*/


/*============================
======= FICHIERS ORDINATEURS =======
=============================
   Ordinateurs (≥ 1025px)
==============================*/

@media (min-width:1025px) {

  .manon-photo-box img {
    position: relative;
    left: -30px;
    top: 50px;    
    margin: 0;           
}


 .porteau-image img {
    margin-left: 100px;
    margin-top: 130px;
  }

  .diaporama {
    width: 100%;
    max-width: 50%;
    margin-left: 720px;
    margin-top: -850px;
  }

  .diaporama-nuit {
    width: 100%;
    max-width: 50%;
    margin-left: 720px;
    margin-top: 50px;
  }
 
  .text-association {
    width: 100%;
    max-width: 100%;
    font-size: 16px;
    position: relative;
    left: -50px;
    top: -350px;
  }

  .gendarmes-image {
    border: 1px solid #000;
    border-radius: 10px;
    background: #fff;
    overflow: hidden;
    box-sizing: border-box;
    position: relative;      
    left: -775px;         
    top: 100px; 
  }

  .gendarmes-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 10px;
  }

  .video-space {
    position: relative; 
    margin: 0;  
    left: 720px;         
    top: -320px; 
    margin-bottom: 0px;
  }

}  /* ✅ une seule accolade pour fermer la media query */
