@font-face {
   font-family: 'Playfair Display SC';
   src: url('./fonts/PlayfairDisplaySC-Regular.ttf')format('truetype');
}

@font-face {
   font-family: 'Playfair Display SC Bold';
   src: url('./fonts/PlayfairDisplaySC-Bold.ttf')format('truetype');
}

@font-face {
   font-family: 'Times New Roman';
   src: url('./fonts/Times_New_Roman.ttf')format('truetype');
}

@font-face {
   font-family: 'Open Sans Regular';
   src: url('./fonts/OpenSans-Regular.ttf')format('truetype');
}

@font-face {
   font-family: 'Open Sans Semibold';
   src: url('./fonts/OpenSans-Semibold.ttf')format('truetype');
}

@font-face {
   font-family: 'GE Inspira';
   src: url('./fonts/GE_Inspira.ttf')format('truetype');
}

@font-face {
  font-family: 'GE Inspira Bold';
  src: url('./fonts/GE_Inspira_Bold.ttf')format('truetype');
}

@font-face {
   font-family: 'Georgia';
   src: url('./fonts/Georgia.ttf')format('truetype');
}

html, body {
   margin: 0;
   padding: 0;
   font-family: 'Open Sans Regular', sans-serif;
   background: url(fond4.jpg);
   background-size: cover;
   background-position: center center; /* Centre l'image */
   background-repeat: repeat;
   font-size: 100%;
}

* {
   box-sizing: border-box;
}


#contact {
   margin-top: 50px; 
   height: 250px; 
   line-height: 250px; 
   background-color: #3a3a3a;
}

h2 {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 1.5em;
    font-weight: normal;
    margin: 0;
    }

h3 {
   font-family: 'Georgia', 'Times New Roman', serif;
   font-size: 1.05em;
   font-weight: bold;
   margin: 0;
}

a:hover {
   color: green;
}

a {
   color: black;
   text-decoration: none;
}

.retour {
  display: block;
  text-align: right;
  color: black;
  text-decoration: none;
}

.espacebas {
   margin-bottom: 2em;
}

.espacehaut {
   margin-top: 2em;
}

.espacebas2 {
   margin-bottom: 4em;
}

.floatL {
   float: left;
}

.center {
   text-align: center;
}

.clear {
   clear: both;
}

.galerie {
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap; /* responsive */
  margin-top: 40px;
}

.item {
  text-align: center;
  max-width: 26%; /* ajuste selon ton besoin */
}

.image-box {
  box-shadow: 6px 6px 12px rgba(0,0,0,0.38);
}

.image-box img {
  display: block;
  height: auto;
  width: 100%;
}

#titre img {
  text-align: left;
  width: 100px; 
  height: 100px;
}

#main {
  height: auto;
  top: 0;
  left: 0;
  width: 100%;
  text-align: center;
  z-index: 10;
}

#main-fancy{
	height:100%;
	margin-left:60px;
	margin-right:60px;
	margin-top:30px;
	margin-bottom:30px
}

#main-fancy h1{
	color:#5b5b5b;
	font-family:'Georgia', sans-serif;
	font-size:1.4em;
	font-weight: normal;
}

.expo-header {
  text-align: center;
  margin: 40px auto 20px;
}

.expo-header h1 {
  font-size: 1.6em;
  font-weight: 500;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.expo-meta {
  font-size: 0.95em;
  color: #777;
  margin-top: 5px;
}

.expo-cartel {
  margin: 10px auto; /*10 au lieu de 20*/
  max-width: 500px;
  font-size: 0.9em;
  color: #666;
  line-height: 1.4;
  border-top: 1px solid #ddd;
/*  padding-top: 10px; */
  opacity: 0.8;
  font-style: italic;
}

#titre {
   position: sticky;
   height: auto;
   margin-left: 10%;
   margin-right: 10%;
   margin-top: 10px;
   z-index: 10;
   display: flex;
   align-items: center;
   flex-wrap: wrap;
   gap: 40px;
   width: 100%;
}

.menu {
	display: flex;
	gap: 20px;
	flex-wrap: wrap;
	justify-content: center;  /* Centrer le contenu pour les petits écrans */
}

.menu a {
	text-decoration: none;
	color: #5f5f5f;
}

.menu a:hover {
	color: #343434;
}

#titre #en-cours a {
	font-size: 1.2em;
	color: black;
	font-family: 'Open Sans Regular', sans-serif;
	font-variant-caps: all-small-caps;
}

#titre img {
	text-align: left;
	width: 100px; 
	height: 100px;
}

h1 {
	font-family: 'Georgia', 'Times New Roman', serif;
	font-weight: normal;
	margin: 0;
}

hr{
	/* The horizontal ruler */
	background-color:#696969;
	border:none;
	color:#696969;
	margin-top:10px;
	margin-bottom:0px;
	height:1px;
	width:100%;
}

#page {
	text-align:justify;
	margin-left: 5%; 
	margin-right: 5%; 
	padding-top: 30px; 
	font-size: 1.1em;
}

#page p {
	font-family: 'Open Sans Regular', sans-serif;
}

article {
	display: grid;
	place-items: center;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.legende {
	margin-top: 8px;
	font-size: 0.9rem;
	font-style: italic;
	text-align: left;
}

/*apparition et mouvement du titre sur les images*/
.thumb {
	position: relative;
	display: inline-block;
	width: 250px;
	height: 250px;
	overflow: hidden;   /* très important */
}

/* état par défaut : mobile / tactile */
div.index figcaption {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	font-family: "Georgia";
	font-size: 0.9em;
	line-height: 1.3em;
	padding: 0;
	background-color: rgba(0,0,0,0.4);
	color: #e6e6e6;
	text-align: center;
	transform: translateY(150px);
	opacity: 1;
	transition: transform 2s ease, opacity 0.25s ease;
}

#conteneur-titre {
  margin: 20px 0.5% 0 0.5%;
}

/* Conteneur flexible */
.titres {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  width: 100%;
  padding: 0.5rem 0;

  /* Active les container queries */
  container-type: inline-size;
}

/* Cartes responsive */
.carte {
  flex: 1 1 160px;      /* largeur minimum */
  max-width: 200px;     /* largeur maximum */
  aspect-ratio: 4 / 3;  /* garde une belle proportion */
  
  border: 1px solid black;
  border-radius: 12px;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;

  padding: 10px;
  box-sizing: border-box;
}

.carte2 {
  flex: 1 1 160px;      /* largeur minimum */
  max-width: 400px;     /* largeur maximum */
  aspect-ratio: 16 / 9;
  
  border: 1px solid black;
  border-radius: 12px;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;

  padding: 10px;
  box-sizing: border-box;
}

/* Images adaptatives */
.carte img {
  width: clamp(40px, 30%, 60px);
  height: auto;
  margin-bottom: 8px;
}

/* Texte responsive lié à la taille du conteneur */
.text {
  font-size: clamp(0.8rem, 0.8vw + 0.3rem, 1.1rem);
  color: black;
  line-height: 1.2;
  word-break: break-word;
}

/*VIDÉO*/
.video-container {
  max-width: 100%;
  margin: 0 10%;
}

.video-container video {
  width: 100%;
  height: auto;
  display: block;
}

:root {
  --plyr-color-main: #ffffff;

  /* Barre très fine */
  --plyr-range-track-height: 2px;

  /* Curseur discret */
  --plyr-range-thumb-height: 10px;
  --plyr-range-thumb-width: 10px;
}

/* Fond presque transparent */
.plyr--video .plyr__controls {
  padding: 8px 12px;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.15),
    rgba(0, 0, 0, 0.0)
  );
}

/* Boutons compacts */
.plyr__control {
  padding: 4px;
}

/* Texte temps discret */
.plyr__time {
  font-size: 13px;
  letter-spacing: 0.5px;
}

/* Volume un peu plus court (plus élégant) */
.plyr__volume {
  max-width: 90px;
}

/* Curseur invisible par défaut sur desktop uniquement */
@media (hover: hover) {

  .plyr input[type=range]::-webkit-slider-thumb,
  .plyr input[type=range]::-moz-range-thumb {
    opacity: 0;
    transition: opacity 0.2s ease;
  }

  .plyr:hover input[type=range]::-webkit-slider-thumb,
  .plyr:hover input[type=range]::-moz-range-thumb {
    opacity: 1;
  }

  .plyr--video .plyr__controls {
    opacity: 0;
    transition: opacity 0.3s ease;
  }

  .plyr--video:hover .plyr__controls {
    opacity: 1;
  }
}

/*
* 
*
*
*
*/
@media screen and (max-width: 980px) {
	
#page {
    padding-left: 10px; 
    padding-right: 10px; 
    padding-top: 5px; 
    text-align: justify;
    font-size: 0.8em;
    }

 #page p {
    font-family: 'Open Sans Regular', sans-serif;
    }

h2 {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 1.3em;
    font-weight: normal;
    margin: 0;
    }

#main {
    height: auto;
    top: 0;
    left: 0;
    max-width: 100%;
    text-align: center;
    z-index: 10;
    }

#main img {
   width: 300px;
   height: auto;
}

#titre {
    margin-left: 5px;
    margin-right: 5px;
    padding-top: 10px;
    max-width: 100%;
    flex-direction: column;
    gap: 10px;
    justify-content: flex-start; /*aligne le contenu verticalement*/
    }

.menu {
	display: flex;
	flex-wrap: wrap;
        gap: 6px;
        justify-content: center;  /* Centre les éléments du menu */
}

.menu a {
    text-decoration: none;
    font-size: 0.80em;
    color: #5f5f5f;
    }

.menu a:hover {
    color: #343434;
    }

#titre #en-cours a {
    font-size: 0.9em;
    color: black;
    font-family: 'Open Sans Regular', sans-serif;
    font-variant-caps: all-small-caps;
    }

figcaption {
    font-family: 'Times New Roman', serif; 
    font-size: 0.8em; 
    font-style: italic;
    }

.legende {
    margin-top: 8px;
    font-size: 0.6em;
    font-style: italic;
    text-align: left;
    }

}

/* ===== MOBILE ===== */
@media screen and (max-width: 600px) {
    #titre {
        padding-top: 5px;
        gap: 4px;
    }
}

/* ===== MOUVEMENT DU TITRE SUR IMAGES ===== */
@media (hover: hover) and (pointer: fine) {

  div.index figcaption {
    transform: translateY(-100%);
    opacity: 0;
  }

  .thumb:hover figcaption {
    transform: translateY(135px);
    opacity: 1;
  }
}


@media (hover: none) and (pointer: coarse) { 
  /* titre toujours visible */
  div.index div {
    transform: translateY(150px);   /* même valeur que desktop */
    opacity: 1;
  }

  /* on désactive l’animation */
  .thumb:hover div {
    transform: translateY(150px);
  }
  h1 {
    font-size: clamp(2em, 5vw, 3em);
  }

  div.index div {
    font-size: clamp(14px, 2.5vw, 20px);
  }
}

/*
* 
*
*
*
POUR FANCYBOX */


.gallery {
    display: grid;
    grid-template-columns: repeat(7, minmax(100px, 1fr));
    gap: clamp(10px, 2vw, 20px);
    justify-content: center;
    align-items: center; 
}

.gallery figcaption {
  display: none;
}

.pic {
    width: 100%;
    text-align: center; /* centrer l'image et le texte */
    margin-bottom: 20px; /* espace entre miniatures */
}

.pic a {
    display: block;
}

.pic img {
    width: 100%;
    height: auto;
    display: block;
}

.pic .caption-mini {
    font-size: 0.7em;
    color: #333;
    margin-top: 4px;
}

.bordure_ombre {
    border: 3px solid #eeeeee;
    box-shadow: 8px 8px 10px #807a7a;
}

/* Flèches discrètes */

.fancybox-nav span {
    opacity: 0;
    transition: opacity 0.2s;
}

/* apparition au survol */

.fancybox-wrap:hover .fancybox-nav span {
    opacity: 0.5;
}

/* plus visible si on vise la flèche */

.fancybox-nav span:hover {
    opacity: 1;
}

/* supprimer l'image sprite utilisée par fancybox */

.fancybox-prev span,
.fancybox-next span {
    background: none !important;
}

/* style commun aux flèches */

.fancybox-nav span::before {
    font-size: 56px;
    color: rgba(255,255,255,0.9);
    text-shadow: 0 0 6px rgba(0,0,0,0.6);
}

/* flèche gauche */

.fancybox-prev span::before {
    content: "❮";
}

/* flèche droite */

.fancybox-next span::before {
    content: "❯";
}

/* position */

.fancybox-prev span {
    left: 15px;
}

.fancybox-next span {
    right: 15px;
}

/* curseur normal sur les zones de navigation */

.fancybox-prev,
.fancybox-next {
    cursor: default;
}

/* curseur pointeur uniquement au centre */

.fancybox-inner {
    cursor: pointer;
}

/* ===== TABLETTE et MOBILE (moins de 800px) ===== */
@media (max-width: 800px) {
    .gallery {
        grid-template-columns: repeat(3, minmax(120px, 1fr)); /* 3 images par ligne sur tablette et mobile */
        gap: clamp(10px, 2vw, 20px);
    }
div.index figcaption {
    transform: translateY(150px);
    }
}
