@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 300;
  font-stretch: 100%;
  font-display: auto;
  src: url('../fonts/Fraunces-9pt-SuperSoft-Light.otf') format("opentype");
  src: url('../fonts/Fraunces-9pt-SuperSoft-Light.ttf') format("truetype");
  src: url('../fonts/Fraunces-9pt-SuperSoft-Light.woff') format("woff");
  src: url('../fonts/Fraunces-9pt-SuperSoft-Light.woff2') format("woff");
}

@font-face {
  font-family: 'Abordage';
  src: url('../fonts/Abordage-Regular.woff2') format('woff2'),
       url('../fonts/Abordage-Regular.woff') format('woff'),
       url('../fonts/Abordage-Regular.ttf') format('truetype');
}

@font-face {
  font-family: 'Canarina';
  src: url('../fonts/Canarina-Regular.woff2') format('woff2'),
       url('../fonts/Canarina-Regular.woff') format('woff');
}

@font-face {
  font-family: 'Murmure';
  src: url('../fonts/LeMurmure-Regular.woff2') format('woff2'),
       url('../fonts/LeMurmure-Regular.woff') format('woff');
}

html, body {
  margin: 0;
  padding: 0;
  background-color: #EEEEEE;
  color: #000;
  font-family: 'Fraunces', sans-serif;
  line-height: 1.5;
  width: 100%;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-decoration-color: #D0D0D0;
  text-decoration-skip-ink: auto;
  text-underline-offset: 2px;
}

header {
  background: #FFFFFF;
  padding: 3% 2% 0 2%;
  text-align: center;
}

header img {
  width: 100%;
  height: auto;
  margin: 0 auto;
  display: block;
}

/* MENU */

#menu {
  width: 100%;
  margin: 0;
  text-align: center;
}

#menu a {
  text-decoration: none !important;
  color:inherit;
}

#menu ul {
  list-style: none;
  padding: 0;
  margin: 0;
  font-family: 'Abordage';
  font-size: 0.9rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: none;
  flex-direction: column;
  width: 100%;
}

#menu ul.show {
  display: flex;
  font-size: 0.9rem;
}

#menu > ul > li {
  width: 95%;
  margin: 5px auto;
}

#menu a {
  display: block;
  padding: 12px;
  border-radius: 8px;
  transition: background-color 0.3s;
}

.ecole { background: #FFED00; color: #E30613; }
.formation-loisir { background: #ECA1C7; color: #006633; }
.le-coin-des-petits { background: #FF8C00; color: #FFF9C4; }
.formation-pro { background: #009FE3; color: #29235C; }
.repetitions { background: #E52421; color: #FFED00; }
.galerie { background: #006633; color: #ECA1C7; }

/* SOUS-MENUS */
.sub-menu {
  display: none;
  position: relative;
  background-color: inherit;
  padding-left: 0;
  margin: 0;
  border-radius: 5px;
}

.sub-menu.active {
  display: block;
}

.sub-menu a {
  padding: 8px 12px;
  display: block;
  font-size: 0.9rem;
  color: inherit;
  background: rgba(255,255,255,0.1);
  border-bottom: 1px solid rgba(0,0,0,0.1);
}

#menu-toggle {
  display: block;
  margin: 0 auto;
  margin-top: 15px;
  margin-bottom: 15px;
}

li.active > .sub-menu {
  display: block;
}

#menu li:hover > .sub-menu {
  display: none;
}

/* ANCRES */
#header-ecole {
  background: #FFF;
  display: block;
  padding: 0% 5%;
  box-sizing: border-box;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  gap: 10px;
}

.index {
  align-items: left;
  justify-content: left;
}

#header-ecole > div.index > ul {
  display: block;
  font-family: 'Murmure';
  letter-spacing: 1px;
  font-size: 2rem;
  text-transform: uppercase;
  list-style: none;
  padding-left: 0;
}

#header-ecole > div > ul > li {
  display: block;
  width: auto;
  border: 1px dotted black;
  background-color: #CECECE;
  text-align: center;
  transition: 0.2s;
}

.titre #ecole {
  flex: 1;
  color: #FFED00;
  text-align: center;
  font-weight: bold;
  font-size: 3.5rem;
  padding-bottom: 10px;
}

.titre #formation-loisir {
  flex: 1;
  color: #ECA1C7;
  text-align: center;
  font-weight: bold;
  font-size: 3rem;
  padding-bottom: 10px;
  line-height: 1em;
}

.titre #le-coin-des-petits {
  flex: 1;
  color: #FF8C00;
  text-align: center;
  font-size: 3rem;
  font-weight: bold;
  padding-bottom: 10px;
  line-height: 1em;
}

.titre #repetitions {
  flex: 1;
  color: #E30613;
  text-align: center;
  font-weight: bold;
  font-size: 2.5rem;
  padding-bottom: 10px;
  line-height: 1em;
}

.titre #galerie {
  flex: 1;
  color: #006633;
  margin: auto;
  font-weight: bold;
  font-size: 3rem;
  padding-bottom: 10px;
}


main {
  background: #EEE;
  margin-top: 1em;
}

h1 {
  font-family: 'Abordage';
  text-transform: uppercase;
  font-size:4rem;
  letter-spacing: 1.5px;
  text-align: center;
}

h2 {
  font-size: 2rem;
  font-family: 'Murmure';
  text-align: center;
}

#h2-margin-mobile {
  margin-top: 0;
}

h3, h4, h5 {
  color: #000000;
  font-family: 'Fraunces', sans-serif;
  font-weight: 600;
}

hr {
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
  border-top: 1.5px solid black;
  color: black;
  overflow: hidden;
  text-align: center;
}

/*SECTIONS PAGES*/

section {
  box-sizing: border-box;
  padding: 0 5% 0 5%;
}

#blocs {
  display: inline-block;
  width: 100%;
}

.illustration {
  box-sizing: border-box;
  margin-top: 0 !important;
}

.text {
  box-sizing: border-box;
  margin-top: 0 !important;
}

.text p {
  font-size: 0.9rem;
}

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

#blocs > div.text > h4 {
  font-size: 0.9rem;
}

#blocs > div.text > li {
  font-size: 0.9rem;
  margin-left: 20px;
}

/* CV PROFS */

#profs {
  padding-top: 0;
  margin-top: 0;
}

section #professeurs {
  padding: 0 5% 0 5% !important;
  margin: 0 !important;
}

.prof-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}

.prof-card {
  position: relative;
  perspective: 1000px;
  width: 100%;
  height: 100px;
}

.prof-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.3s ease-in-out;
  transform-style: preserve-3d;
  display: flex;
  flex-direction: column;
}

.prof-card:hover .prof-inner {
  transform: rotateX(180deg);
}

.prof-front, .prof-back {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
  backface-visibility: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  background: white;
}

.prof-front img {
  height: 100%;
  float: left;
  object-fit: contain;
}

.prof-front .info {
  text-align: right;
  padding: 0.5rem;
}

.prof-front .info h3 {
  font-size: 0.9rem;
  font-family: Abordage;
  text-transform: uppercase;
  margin: 0.1rem 0;
}

.prof-front .info p {
  font-size: 0.8rem;
  font-family: Fraunces;
  line-height: 1em;
  padding: 0 10px 0 10px;
  margin: 0.2rem 0;
}

.prof-back {
  background: #2b2b2b;
  color: white;
  transform: rotateX(180deg);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 0 15px 0 15px;
  text-align: left;
  overflow-y: auto;
  flex: 1;
  -webkit-overflow-scrolling: touch;
  white-space: pre-line;
}

.prof-back p {
  font-size: 0.8rem;
  text-align: left;
  line-height: 1.5em;
}

.equipe-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}

.equipe-card {
  position: relative;
  perspective: 1000px;
  width: 100%;
  height: 100px;
}

.equipe-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.3s ease-in-out;
  transform-style: preserve-3d;
  display: flex;
  flex-direction: column;
}

.equipe-card:hover .equipe-inner {
  transform: rotateX(180deg);
}

.equipe-front, .equipe-back {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
  backface-visibility: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  background: white;
}

.equipe-front img {
  height: 100%;
  float: left;
  object-fit: contain;
}

.equipe-front .info {
  text-align: right;
  padding: 0.5rem;
}

.equipe-front .info h3 {
  font-size: 0.9rem;
  font-family: Abordage;
  text-transform: uppercase;
  margin: 0.1rem 0;
}

.equipe-front .info p {
  font-size: 0.8rem;
  font-family: Fraunces;
  line-height: 1em;
  padding: 0 10px 0 10px;
  margin: 0.2rem 0;
}

.equipe-back {
  background: #2b2b2b;
  color: white;
  transform: rotateX(180deg);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 0 15px 0 15px;
  text-align: left;
  overflow-y: auto;
  flex: 1;
  -webkit-overflow-scrolling: touch;
  white-space: pre-line;
}

.equipe-back p {
  font-size: 0.8rem;
  text-align: left;
  line-height: 1.5em;
}

/* FORMULAIRE */
form {
  margin: 1em auto;
  width: 80%;
  max-width: 80%;
  padding: 2em;
  border: 1px solid #ccc;
  border-radius: 10px;
  background-color: #fafafa;
}
.form-grid {
  display: inline-block;
  gap: 1.5em;
}

.full-width {
  grid-column: 1 / -1;
}

#nom, #prenom, #email, #telephone {
  width: 100%;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.4em;
  color: #222;
}

input,
textarea {
  font: 0.9em;
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
  box-sizing: border-box;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
textarea:focus {
  outline: none;
}

#message {
  width: 100%;
  height: 10em;
}

.demande-select {
  display: inline-block;
  justify-content: left;
  gap: 10px;
}

.demande-select label {
  display: inline-block;
  align-items: center;
  gap: 1rem;
  font-weight: 500;
  color: #333;
}

.form-buttons {
  display: flex;
  justify-content: center;
  gap: 0.5em;
  margin-top: 2em;
}

button {
  font-family: Fraunces;
  padding: 0.7em 1.5em;
  font-size: 0.9em;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  background-color: #CECECE;
  color: black;
  transition: background-color 0.2s ease;
}

/* PAGE FORMATION LOISIR */
#blocs > div.text > h3 {
  font-size: 1rem;
}

#grid-ateliers-1, #grid-ateliers-2, #grid-ateliers-3{
  font-size: 0.9rem;
  margin: 0;
  padding-left: 20px;
}

.tarifs-loisir thead {
  display: none; /* cache l'en-tête */
}

.tarifs-loisir,
.tarifs-loisir tbody,
.tarifs-loisir tr,
.tarifs-loisir td {
  display: block;
  font-size: 0.9rem;
}

.tarifs-loisir tr td[colspan] {
  display: block;
  text-align: left;
  font-weight: 700;
  color: white;
  text-transform: uppercase;
  text-wrap: wrap;
}

.tarifs-loisir tr:not(:has(td[colspan])) {
  background: #fff;
  border: 1px solid #ddd;
  margin-bottom: 1rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  padding: 0.5rem;
}

.tarifs-loisir tr {
  margin-bottom: 1rem;
  background-color: black;
  border: none;
  padding: 0.5rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.tarifs-loisir td {
  display: block;
  text-align: left;
  border: none;
  border-bottom: 1px solid #eee;
  position: relative;
  font-size: 0.9rem !important;
  padding: 0.5rem 0.5rem 0.5rem 80%;
}

.tarifs-loisir td:first-child {
  padding-left: 0.75rem;
  font-weight: bold;
}

.tarifs-loisir td:not(:first-child)::before {
  content: attr(data-label);
  position: absolute;
  left: 0.75rem;
  top: 0;
  bottom: 0;
  padding: 0.5rem 0;
  font-weight: bold;
  white-space: normal;
}

.tarifs-loisir td:last-child {
  border-bottom: none;
}

.note-tarifs {
  font-size: 0.8rem;
  margin: 15px;
}

/* PAGE EVEIL */
#blocs > div.text > h4 {
  font-size: 1em;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-decoration-color: #555555;
  text-decoration-skip-ink: auto;
  text-underline-offset: 2px;
}

/* PAGE REPETITIONS */

.colonne-salle {
  display: block;
  width: 100%;
  gap: 10px;
  margin-bottom: 3%;
}

.grid-salle {
  margin: auto;
  width: 100%;
}

.grid-salle h4 {
  font-weight: 600;
  text-align: center;
  margin-bottom: 0;
}

.photo-salle {
  display: inline-block;
  width: 100%;
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.photo-salle img {
  display: block;
  width: 100%;
  transition: opacity 0.3s ease;
}

.description-salle {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.6);
  color: #fff;
  opacity: 0;
  transition: opacity 0.3s ease;
  text-align: left;
  overflow-y: auto;
  width: 100%;
  font-size: 0.8rem;
  list-style-type: disc;
}

#equipements > div > div > div > div > div > ul {
  margin: auto;
}

.description-salle > ul {
  list-style-type: disc;
}

.photo-salle:hover img {
  opacity: 0.4;
}

.photo-salle:hover .description-salle {
  opacity: 1;
  width: 100%;
}

.colonne-studio {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: space-between;
  width: 100%;
  gap: 20px;
  margin-bottom: 3%;
}

.grid-studio {
  width: 100%;
}

.grid-studio h4 {
  font-weight: 600;
  text-align: center;
  margin-bottom: 0;
}

.photo-studio {
  display: block;
  width: 100%;
}

.photo-studio img {
  display: block;
  width: 100%;
  margin: auto;
}

.description-studio {
  width: 80%;
  margin: auto;
}

.description-studio li {
  text-align: left;
  font-size: 0.9rem;
  line-height: 1.5em;
}

#equipement-studio {
  display: block;
  padding: 0;
}

#equipement-studio h5 {
  margin: 15px 0 0 0;
  text-align: center;
}

#equipement-studio li {
  text-align: center;
  list-style: none;
}

.tarifs {
  display: block;
}

.grid-tarifs > .left > .tarifs > table {
  background-color: white;
  border-collapse: collapse;
  padding: 1%;
  border: 1px solid;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.grid-tarifs > .left > .tarifs > table > thead > tr {
  background-color:black;
  color:white;
}

.grid-tarifs > .left > .tarifs > table > thead > tr > th {
  border: 1px solid white;
  font-weight: 600;
  padding: 0.5rem;
}

.grid-tarifs > .left > .tarifs > table > thead {
  border: 1px solid black;
  padding: 1%;
  margin: 1%;
  border-collapse: collapse;
}

.grid-tarifs > .left > .tarifs > table > tbody > tr > th {
  padding: 5px 15px 5px 15px;
  border: 1px solid;
} 

#tarifs > div > div > th,td,tr {
  border: 1px solid;
  padding: 10px;
  text-align: center;
}



.right p {
  font-size: 0.9rem;
}

#references > div {
  text-align: center;
}

#references > div > h3 {
  font-size: 1rem;
}

#references > div > p {
  font-size: 0.9rem;
}

/* GALERIE */
/* Conteneur principal */
.gallery {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin: 10px;
}

/* Titre de l'album */
.album-title {
  font-size: 1.1em;
  font-weight: 500;
  background-color: #006633;
  color: #fff;
  padding: 8px 12px;
  border-radius: 5px;
  user-select: none;
  font-family: Fraunces;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

/* Conteneur des images dans l’album */
.album-images {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: all 0.4s ease;
}

.album-images.open {
  max-height: 3000px;
  opacity: 1;
  margin-top: 10px;
}

.album {
  transition: opacity 0.3s ease;
  font-size: 0.9rem;
  font-weight: 500;
}

.album[style*="display: none"] {
  opacity: 0;
  transform: scale(0.98);
}

/* Lightbox individuelle */
.lightbox {
  width: 48%; /* deux images par ligne sur mobile */
  cursor: pointer;
  transition: transform 0.2s;
}

.lightbox img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  object-fit: cover;
}

.lightbox:hover {
  transform: scale(1.03);
}

/* Lightbox masquée par filtrage */
.hidden {
  display: none !important;
}

/* Overlay pour zoom */
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.85);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.overlay img.zoomed {
  max-width: 90%;
  max-height: 90%;
  border-radius: 10px;
  box-shadow: 0 0 15px #fff;
}

/* Responsive : écran très petit */
@media (max-width: 480px) {
  .lightbox {
    width: 100%; /* une image par ligne */
  }

  .album-title {
    font-size: 1em;
    padding: 6px 10px;
  }
}

#filtre-annee,
#filtre-evenement,
#filtre-lieu {
  background-color: #fff;
  border: 2px solid #006633;
  color: #006633;
  padding: 8px 16px;
  margin: 5px;
  border-radius: 5px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s ease;
}

/* RETOUR EN HAUT */
#back-to-top {
  display: none;
}

/* SCREEN READER ONLY*/
.sr-only:not(:focus):not(:active) {
  clip: rect(0 0 0 0); 
  clip-path: inset(50%);
  height: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap; 
  width: 1px;
}

/*FOOTER*/
footer {
  background-color: white; 
  width: 100%;
  padding: 1px 1px;
  box-sizing: border-box;
}

footer p {
  font-size: 0.8rem;
}
