/* ============================================================
   SOS TSAF — Feuille de style unique
   Aucune ressource externe : polices système, images locales.
   ============================================================ */




/* ---------- Variables & base ---------- */

:root {
  --bleu: #014b88;
  --bleu-fonce: #003366;
  --bleu-pale: #d7ecf7;
  --encre: #0a2342;
  --crete-eau: 90px;
  --marge-bonhomme: 45px;
}

:root, html, body {
  min-height: 100vh;
  min-height: 100dvh;
}

body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  margin: 0;
  max-width: 100vw;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  color: var(--encre);
  background: #eaf4fa;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.25;
  margin: 1rem 0 0.5rem;
}

a { color: var(--bleu); text-decoration: none; }
a:hover { text-decoration: underline; }

.clear { clear: both; }

/* Accueil : page figée à un écran, eau débordero sur la vidéo */
body.accueil {
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  --crete-eau: -50px;
  --marge-bonhomme: 35px;
}

/* ---------- Ascenseur ---------- */

::-webkit-scrollbar { width: 14px; }
::-webkit-scrollbar-track { box-shadow: inset 0 0 5px grey; border-radius: 8px; }
::-webkit-scrollbar-thumb { background: var(--bleu-fonce); border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: #00509e; }

/* ============================================================
   NAVBAR, SOUS-MENUS & BURGER (toutes les pages)
   ============================================================ */


/* --- Barre de navigation : liens à gauche, logo à droite --- */
.navbar {
  position: relative;
  max-width: 100%;
  height: 70px;
  background-color: #014b88;
  letter-spacing: 2px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  flex-shrink: 0;
  z-index: 200;
}

.brand {
  order: 3;
}

.brand img {
  height: 55px;
  display: block;
}

.nav-links {
  display: flex;
  align-items: center;
  order: 1;
}

.nav-links a,
.dropbtn {
  display: block;
  color: #ffffff;
  text-align: center;
  padding: 14px 16px;
  text-decoration: none;
  font-size: 17px;
  background: none;
  border: none;
  font-family: inherit;
  letter-spacing: inherit;
  cursor: pointer;
}

.nav-links a:hover,
.dropbtn:hover,
.dropdown.open .dropbtn {
  background-color: #003366;
  color: #ffffff;
}

.nav-links a.active {
  background-color: #014b88;
  color: #ffffff;
}

.dropdown {
  position: relative;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background-color: #014b88;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
  border-top: 3px solid #003366;
}

.dropdown.open .dropdown-content {
  display: block;
}

.dropdown-content a {
  padding: 12px 16px;
  text-align: left;
  font-size: 15px;
}

.burger {
  display: none;
  order: 4;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
}

.burger span {
  width: 26px;
  height: 3px;
  background: #ffffff;
  border-radius: 2px;
}


/* ============================================================
   ACCUEIL : VIDÉO + IMAGE
   ============================================================ */

.hero {
  flex: 1;
  position: relative;
  overflow: hidden;
  min-height: 0;
  background: #002b4a;
}

.hero video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-image {
  position: absolute;
  right: 6%;
  top: 10px;
  max-width: 20%;
  max-height: 38%;
  cursor: pointer;
  transition: opacity 0.5s;
}

.hero-image.cachee {
  opacity: 0;
  pointer-events: none;
}

/* ============================================================
   FOOTER : SCÈNE D'EAU + 3 BLOCS (toutes les pages)
   ============================================================ */

.footer {
  position: relative;
  height: 220px;
  width: 100%;
  background: linear-gradient(to bottom, rgba(0, 51, 102, 0), #003366);
  flex-shrink: 0;
  overflow: hidden;        /* contenu : l'eau reste dans le footer */
  z-index: 2;
}

body.accueil .footer {
  overflow: visible;       /* accueil : l'eau chevauche le bas de la vidéo */
}

.eau {
  position: absolute;
  left: 0;
  top: var(--crete-eau);
  width: 100%;
  height: 190px;
  object-fit: fit;
  object-position: top center;
  will-change: transform;
}

body.accueil .eau { height: 190px; }

.eau-avant2 {
  z-index: 1;
  animation: eau2 6s ease-in-out infinite alternate;
}

.eau-avant {
  z-index: 4;
  animation: eau1 4s ease-in-out infinite alternate;
}

@keyframes eau1 {
  0%   { transform: translateY(0); }
  50%  { transform: translateY(16px); }
  100% { transform: translateY(0); }
}

@keyframes eau2 {
  0%   { transform: scaleX(-1) translateY(6px); }
  50%  { transform: scaleX(-1) translateY(30px); }
  100% { transform: scaleX(-1) translateY(6px); }
}

.flottant {
  position: absolute;
  left: 6%;
  top: calc(var(--crete-eau) - var(--marge-bonhomme));
  width: 110px;
  z-index: 2;
  cursor: pointer;
}

body.accueil .flottant { width: 150px; }

.flottant:focus-visible {
  outline: 3px solid #ffffff;
  border-radius: 8px;
}

.antoninflotte {
  width: 100%;
  height: auto;
  display: block;
  animation: flotte 6s ease-in-out infinite alternate;
  will-change: transform;
}

@keyframes flotte {
  0%   { transform: translateY(0)   rotate(0deg); }
  50%  { transform: translateY(6px) rotate(4deg); }
  100% { transform: translateY(0)   rotate(0deg); }
}

.footer-content {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: flex-start;
  gap: 2rem;
  margin-top: 130px;
  padding: 0 2rem 0.5rem;
}

body.accueil .footer-content { margin-top: 140px; }

.footer-tel {
  flex: 1;
  text-align: center;
  color: #ffffff;
  font-size: clamp(1.6rem, 4vw, 2.6rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: 2px;
  text-decoration: none;
}

body.accueil .footer-tel { font-size: clamp(2.4rem, 6vw, 4rem); }

.btn-info {
  flex-shrink: 0;
  align-self: center;
  background: var(--bleu);
  color: #ffffff;
  border: none;
  padding: 10px 26px;
  font-size: 1rem;
  font-family: inherit;
  letter-spacing: 2px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s;
}

.btn-info:hover { background: var(--bleu-fonce); }

.footer-maison { flex-shrink: 0; }
.footer-maison img { height: 55px; }

/* ============================================================
   POP-UPS (Info & Recherche) — toutes les pages
   ============================================================ */

.overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 20, 40, 0.6);
  padding: 1rem;
}

.overlay.open { display: flex; }

.modal {
  position: relative;
  background: #f4fafd;
  color: var(--encre);
  width: min(640px, 94%);
  max-height: 80vh;
  overflow-y: auto;
  padding: 2.5rem 2rem 2rem;
  border-radius: 12px;
  border-top: 6px solid var(--bleu);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.modal h2 {
  color: var(--bleu);
  letter-spacing: 2px;
  font-size: 1.3rem;
  margin-bottom: 1.25rem;
  padding-right: 2.5rem;
}

.modal-close {
  position: absolute;
  top: 10px;
  right: 14px;
  background: none;
  border: none;
  font-size: 2rem;
  line-height: 1;
  color: var(--bleu);
  cursor: pointer;
}

.form-recherche {
  display: flex;
  gap: 0.5rem;
  margin: 0.5rem 0 1rem;
}

.form-recherche input {
  flex: 1;
  padding: 12px 16px;
  font-size: 1.05rem;
  border: 2px solid var(--bleu);
  border-radius: 8px;
  font-family: inherit;
  color: var(--encre);
}

.form-recherche input:focus {
  outline: 3px solid rgba(1, 75, 136, 0.3);
}

.form-recherche button {
  background: var(--bleu);
  color: #ffffff;
  border: none;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
  cursor: pointer;
}

.form-recherche button:hover { background: var(--bleu-fonce); }

.indice-recherche {
  font-size: 0.9rem;
  color: #5a6b7b;
}

/* Texte du pop-up Info */
.modal .footer-info p {
  margin-bottom: 0.9rem;
  font-size: 14px;
  line-height: 1.6;
}

.modal .footer-info a { color: var(--bleu); }

.modal .footer-info svg {
  width: 20px;
  height: 20px;
  fill: var(--bleu);
  vertical-align: middle;
  margin: 0 4px;
}

.modal .footer-info svg.stroke {
  fill: none;
  stroke: var(--bleu);
  stroke-width: 2;
}

.modal .footer-info svg .fill { fill: var(--bleu); }

/* ============================================================
   PAGES DE CONTENU (blogue, static, articles)
   ============================================================ */

main.contenu {
  flex: 1;
  width: min(900px, 92%);
  margin: 2.5rem auto;
  background: #ffffff;
  border-radius: 12px;
  padding: 2.5rem 3rem;
  box-shadow: 0 4px 20px rgba(0, 20, 40, 0.08);
  font-size: 1.1rem;
  line-height: 1.7;
}

.article.art_thumbnail {
  display: block;
  width: 50%;
  height: 100%;
float:left;
padding:2%;
}


main.contenu h1 {
  color: var(--bleu);
  font-size: 2rem;
  letter-spacing: 1px;
}

main.contenu h2 {
  color: var(--bleu);
  font-size: 1.4rem;
  margin-top: 2rem;
}

main.contenu p { margin-bottom: 1rem; }

main.contenu ul,
main.contenu ol { margin: 0 0 1rem 1.5rem; }

main.contenu img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  display: block;
  margin: 1.5rem auto;
}

main.contenu figure { margin: 1.5rem 0; text-align: center; }

main.contenu figcaption {
  font-size: 0.85rem;
  color: #5a6b7b;
  margin-top: 0.4rem;
}

main.contenu blockquote {
  border-left: 4px solid var(--bleu);
  background: #eaf4fa;
  padding: 0.75rem 1.25rem;
  border-radius: 0 8px 8px 0;
  margin: 1.5rem 0;
  font-style: italic;
}

/* ============================================================
   PAGES DE CATÉGORIE : grille de vignettes d'articles
   Structure : article > .column3 > .gallery-item.container3
   ============================================================ */

.page-categories .article { font-size: inherit; }

.column3 {
  float: left;
  width: 30.33%;
  padding: 8px;
}

.gallery-item {
  box-shadow: 0.3rem 0.4rem 0.4rem rgba(0, 0, 0, 0.4);
  overflow: hidden;
  border-radius: 8px;
  background: #ffffff;
}

.container3 { position: relative; display: block; height: 170px; }

.overlayb {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: 0.3s ease;
  background: rgba(1, 75, 136, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
}

.container3:hover .overlayb,
.container3:focus-within .overlayb {
  opacity: 1;
}

.art_thumbnail {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease-out;
}

.container3:hover .art_thumbnail { transform: scale(1.08); }

.text {
  position: absolute;
  text-align: center;
  color: #ffffff;
  font-size: 15px;
}

.text h4 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.3;
}

.text a {
  color: #ffffff;
  text-decoration: none;
}

/* Détail d'article */
.art-date { font-size: 1rem; color: #9EABB3; }
.written-by:after, .classified-in:after { content: "|"; }

.classified-in .active,
.cat-list .active {
  background-color: #6aa6ce;
  color: #fff;
}

/* ---------- Pagination ---------- */

.pagination { margin: 2rem 0; }

.pagination a {
  background-color: var(--bleu);
  border-radius: 0.3rem;
  color: #fff;
  padding: 0.6rem 0.8rem;
  transition-duration: 0.2s;
  text-decoration: none;
}

.pagination a:hover { background-color: #3a6c96; text-decoration: none; }

.p_first, .p_prev, .p_current, .p_next, .p_last { display: inline-block; }

/* ============================================================
   PAGE ÉQUIPE : CARTES QUI FLIPPENT
   ============================================================ */

.galerie-equipe {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  justify-content: center;
  padding: 2rem 1rem;
}

.carte-equipe {
  perspective: 1000px;
  width: 220px;
}

.carte-interieur {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 4;
  transform-style: preserve-3d;
  transition: transform 0.8s;
}

.carte-equipe:hover .carte-interieur,
.carte-equipe:focus-within .carte-interieur {
  transform: rotateY(180deg);
}

.carte-recto,
.carte-verso {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0.3rem 0.4rem 0.4rem rgba(0, 0, 0, 0.4);
}

.carte-recto img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.carte-nom {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(1, 75, 136, 0.85);
  color: #ffffff;
  text-align: center;
  padding: 0.5rem;
  font-weight: 600;
}

.carte-verso {
  transform: rotateY(180deg);
  background: var(--bleu);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1rem;
}

.carte-verso h3 {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
}

.carte-verso p {
  font-size: 0.85rem;
  margin: 0;
}

/* ============================================================
   UTILITAIRES divers (conservés de l'ancien site au besoin)
   ============================================================ */

.img-comp-container { position: relative; height: 200px; }
.img-comp-img { position: absolute; width: auto; height: auto; overflow: hidden; }
.img-comp-img img { display: block; vertical-align: middle; }
.img-comp-slider {
  position: absolute;
  z-index: 9;
  cursor: ew-resize;
  width: 40px;
  height: 40px;
  background-color: #2196F3;
  opacity: 0.7;
  border-radius: 50%;
}

.tooltip { position: relative; display: inline-block; }
.tooltip .tooltiptext {
  visibility: hidden;
  width: 120px;
  background-color: #cccccc;
  color: var(--bleu-fonce);
  text-align: center;
  padding: 5px 0;
  border-radius: 6px;
  font-size: 100%;
  position: absolute;
  z-index: 100;
  top: 100%;
  left: 50%;
  margin-left: -60px;
}
.tooltip:hover .tooltiptext { visibility: visible; }

.tab {
  overflow: hidden;
  border: 1px solid #ccc;
  background-color: #f1f1f1;
}

.tab button {
  background-color: inherit;
  float: left;
  border: none;
  outline: none;
  cursor: pointer;
  padding: 14px 16px;
  transition: 0.3s;
}

.tab button:hover { background-color: #ddd; }
.tab button.active { background-color: #ccc; }

.tabcontent {
  display: none;
  padding: 6px 12px;
  border: 1px solid #ccc;
  border-top: none;
}

.button {
  border: none;
  background-color: var(--bleu-fonce);
  color: #ffffff;
  padding: 15px;
  display: inline-block;
  border-radius: 20px;
  font-size: 1.1rem;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  margin: 5px;
}

.footer2 {
  color: #99ccff;
  background-color: var(--bleu);
  padding: 5%;
}

.footer2 a { color: #ffffff; }

/* Commentaires d'article */
.comment { margin-bottom: 2.5rem; }
.comment blockquote { margin: 0; }
.type-admin { background-color: #F0F8FF; padding: 0.2rem 0.5rem; }

.level-1 { margin-left: 1rem; }
.level-2 { margin-left: 2rem; }
.level-3 { margin-left: 3rem; }
.level-4 { margin-left: 4rem; }
.level-5, .level-max { margin-left: 5rem; }

/* Tags du blogue */
.tag-size-1  a { font-size: 1.0rem; color: #4C6A92; }
.tag-size-2  a { font-size: 1.2rem; color: #92B6D5; }
.tag-size-3  a { font-size: 1.4rem; color: #838487; }
.tag-size-4  a { font-size: 1.6rem; color: #B76BA3; }
.tag-size-5  a { font-size: 1.8rem; color: #AF9483; }
.tag-size-6  a { font-size: 2.0rem; color: #AD5D5D; }
.tag-size-7  a { font-size: 2.2rem; color: #006E51; }
.tag-size-8  a { font-size: 2.4rem; color: #D8AE47; }
.tag-size-9  a { font-size: 2.6rem; color: #9E4624; }
.tag-size-10 a { font-size: 2.8rem; color: #B93A32; }
.tag-size-11 a { font-size: 3.0rem; color: #034F84; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 992px) {
  .column3 { width: 47%; }
}

@media (max-width: 785px) {
 

 .burger {
    display: flex;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 70px;
    left: 0;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    background-color: #014b88;
    border-top: 1px solid #003366;
  }

  .nav-links.open {
    display: flex;
  }

  .dropdown-content {
    position: static;
    width: 100%;
    box-shadow: none;
  }


  .body-accueil { }
  
  body.accueil .hero { min-height: 55vh; }

  .footer { height: auto; }

  .eau { height: 120px; }

  body.accueil .eau { height: 140px; }

  .flottant { width: 80px; }

  .footer-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
    margin-top: 100px;
  }

  main.contenu {
    width: 94%;
    margin: 1.25rem auto;
    padding: 1.5rem 1.25rem;
  }
}

@media (max-width: 600px) {
  .column3 { width: 100%; }
}

/* ============================================================
   IMPRESSION
   ============================================================ */

@media print {
  .navbar,
  .footer,
  .overlay,
  .pasimpression,
  #pasimpression {
    display: none !important;
  }

  main.contenu {
    width: 100%;
    box-shadow: none;
    background: #fff;
  }
}