body {
    position: relative;
    z-index: 1;
    padding: 0;
    margin: 0;
}
.nav-container {
  position: fixed;
  width: 100vw;
  z-index: 1000;
}
.background {
    position: fixed;
    inset: 0;
    z-index: -1; /* placer derrière tout le contenu */
    pointer-events: none; /* laisser les clics passer */
    height: 100%;
    padding: 0;
    margin: 0;
    overflow: hidden;
}
.background-image {
    position: absolute;
    inset: -400px; /* marge pour l'animation */
    background-image: url('../../webassets//backgrounds/background-08.svg');
    background-size:cover;
    background-repeat: repeat;
    background-position: left;
    will-change: transform;
    scale: 1;
    /* Filtre STATIQUE (pas animé en JS = beaucoup plus performant) */
    filter: blur(8px) contrast(1.7) saturate(0.15);
    transform: translate3d(0, 0, 0) scale(1) rotate(0deg);
    /* Améliorer la performance GPU */
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}
/* Désactiver l'animation si préférence utilisateur */
@media (prefers-reduced-motion: reduce) {
    .background-image {
        transform: none !important;
        filter: blur(0) !important;
    }
}
.temporaire {
  position: fixed;
  top: 75px;
  left: 0;
  width: 80vw;
  max-width: 500px;
  background-color: #ffcc00;
  color: #000;
  text-align: center;
  padding: 10px;
  font-size: var(--txt-size-09);
  z-index: 3;
}
.temporaire a {
  color: blue;
  text-decoration: underline;
}










/* =========================
   SECTION INTRODUCTION - PARALLAX
========================= */
#section-introduction {
  height: 100vh;
  width: 100%;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  padding-top: 200px; /* Position initiale du block */
  background-image: linear-gradient(rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.8));
  overflow: hidden;
  /* Isoler le compositing : eviter la création de layer supplémentaire */
  contain: paint;
  /* will-change: transform enlevé car géré sur block-introduction seulement */
}
/* Spacer pour compenser la section fixée */
.parallax-spacer {
  height: 70vh;
  width: 100%;
  pointer-events: none;
}
#block-introduction {
  max-width: 800px;
  align-self: center;
  will-change: transform, opacity;
  width: calc(100% - 8vw);
  color: rgba(0, 0, 0, 0);
  border: 1px solid var(--global-transparent-white-2);
  /* Réduire box-shadow blur : 30 -> 15px = 30-50% perf gain */
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.08);
  background-image: none;
  background-color: rgba(255, 255, 255, 0);
  position: relative;
  margin: 0;
  padding: 20px 40px 20px 20px;
  gap: 15px;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: flex-start;
  overflow: hidden;
  transition: opacity 0.1s ease;
}
.block-introduction-video {
  position: absolute;
  /* Filtres FORTEMENT réduits : 6 filtres -> 2 filtres = 60-70% perf gain */
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
}
#colonne-icone {
  width: auto;
}
#colonne-icone svg {
  width: 1.3rem;
  height: 1.3rem;
  margin-top: 2px;
  color: rgba(0, 102, 255, 0.8);
  /* drop-shadow retiré : trop coûteux, color suffit */
}
#details-nom {
  color: var(--txt-color-whiteop-70);
  display: none;
  margin-left: 0.8rem;
  font-family: Inter-italic;
  font-size: var(--txt-size-08);
  font-weight: 500;
  opacity: 0.8;
}
#description-site {
  margin: 0;
  padding: 0;
}
#description-site-texte {
  margin: 0;
  padding: 0;
  font-family: Inter-italic;
  color: var(--txt-color-whiteop-80);
  font-size: var(--txt-size-10);
  font-weight: 400;
  /* text-shadow retiré : 20-40% perf gain, visuel quasi identique */
}
.typemachine {
  font-size: clamp(1.3rem, 2.4vw, 1.1rem);
  font-weight: 500;
  color: var(--txt-color-black); 
  min-height: 2.3rem;
  display: flex; 
  flex-wrap: nowrap;
  flex-direction: row;
  align-items: flex-start;
  justify-content: flex-start  ;
}
.typemachine-text {
  color: var(--txt-color-whiteop-85);
  text-shadow: 0 0 6px rgba(255, 255, 255, 0.548);
  font-family: Intertight;;
  font-weight: 600;
  border-radius: 6px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.85);
  background-image: linear-gradient(90deg, rgba(0, 102, 255, 0.993), rgba(255, 0, 0, 0.151) 20%, rgb(255, 27, 27) 60%); 
  background-position: 0 100%; 
  background-repeat: no-repeat; 
  background-size: 100% 0.12em; 
  padding-bottom: 0.2em; 
  /* text-shadow retiré : 20-40% perf gain */
}




/* =========================
   SECTION ESSENTIALS - PARALLAX OVERLAY
========================= */
#section-essentials {
  position: relative;
  z-index: 10;
  width: 100%;
  height: auto;
  padding-bottom: 4rem;
  background-color: var(--global-white-2);
  min-height: 200px;
  display: flex;
  flex-direction: column;
  justify-content: top;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.9);
  border-bottom: 1rem solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 60px rgba(0, 0, 0, 0.);
}

#block-essentials {
  width: 100vw;
  max-width: 1000px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: top;
  gap: 0;
}
#block-essentials h1 {
  font-family: Intertight;
  font-weight: 500;
  font-size: var(--txt-size-20);
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  margin: 3rem 0 0 0;
  padding: 0;
}
#block-essentials h1 b {
  font-weight: 730;
  margin-right: 0.4rem;
  margin-left: 0.4rem;
}
#block-essentials h1 img {
  user-select: none;
  height: 1.45rem;
} 
#block-essentials h2 {
  text-align: center;
  max-width: 400px;
  font-size: var(--txt-size-11);
  font-weight: 500;
  margin: 0;
  padding: 0;
}





/* ACCORDEON */
.answer-image {
  width: 30%;
  border-radius: 12px;
  transition: width 0.3s ease;
}
.answer-image:hover {
  width: 60%;
  transition: width 0.3s ease;
}
#section-essentials-accordion {
  box-sizing: inherit;
  width: calc(100% - 20px);
  margin-top: 2rem;
  margin-bottom: 4rem;

  display: flex;
  align-items: center;
  justify-content: center;
}
.accordion-container{
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1.5rem;
}
.accordion-item{
  border-radius: .4rem;
}
.accordion-item .menu-divider {
  opacity: 0.25;
}
.answer mark {
  opacity: 0.15;
}
.accordion-link{
  margin:0;
  padding: 0;
  box-sizing: inherit;
  font-size: var(--txt-size-13);
  text-decoration: none;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
  cursor: pointer;
}
.accordion-link h3 {
  margin:0;
  padding: 0;
  box-sizing: inherit;
  font-family: Intertight;
  font-size: var(--txt-size-13);
  font-weight: 700;
}
.accordion-link ul {
  display: flex;
  align-items: flex-end;
  list-style-type: none;
  margin-left: 25px;
}
.accordion-link div{
  display: flex;
  align-items: center;
}
/* Icônes accordion — chevron animé (style philo-arrow) */
.accordion-arrow {
  position: relative;
  width: 12px;
  height: 12px;
  margin-right: 10px;
  flex-shrink: 0;
  transform: rotate(180deg);
  transition: transform 0.3s ease;
}
.accordion-arrow::before,
.accordion-arrow::after {
  content: '';
  position: absolute;
  background-color: var(--txt-color-blackop-70);
  border-radius: 2px;
  transition: transform 0.3s ease;
}
.accordion-arrow::before {
  width: 8px;
  height: 2px;
  top: 50%;
  left: 0;
  transform: translateY(-50%) rotate(45deg);
  transform-origin: left center;
}
.accordion-arrow::after {
  width: 8px;
  height: 2px;
  bottom: 50%;
  left: 0;
  transform: translateY(50%) rotate(-45deg);
  transform-origin: left center;
}
.accordion-item.active .accordion-arrow {
  transform: rotate(-90deg);
}
.accordion-link .ion-md-arrow-down{
  display: none;
}
.answer {
  max-height: 0;
  overflow: hidden;
  position: relative;
  transition: max-height 650ms ease, opacity 300ms ease;
  opacity: 0;
  display: flex;
  flex-direction: column;
  align-items: end;
  justify-content: flex-start;
}
.answer-description {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: flex-start;
  flex-wrap: nowrap;
  gap: 0.8rem;
  box-sizing: border-box;
}
.answer p {
  color: var(--txt-color-blackop-90);
  font-size: var(--txt-size-11);
  padding: 0 1rem 0 1rem;  
}
/* Classe active via JS (remplace :target) */
.accordion-item.active .answer{
  opacity: 1;
}
.accordion-item.active .accordion-link .ion-md-arrow-forward{
  display: none
}
.accordion-item.active .accordion-link .ion-md-arrow-down{
  display: block;
}










/* =========================
   AUTRES CONTENUS
========================= */
#section-autrescontenus {
  position: relative;
  z-index: 10;
  width: 100%;
  top: 0;
  height: auto;
  padding-bottom: 10rem;
  background-color: var(--global-white-2);
  border-top: 1rem solid rgba(255, 255, 255, 0.9);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1rem;
}
#section-autrescontenus h2 {
  margin-top: 6vh;
  margin-bottom: 3vh;
  font-family: "Intertight";
  text-align: center;
  font-weight: 500;
  font-size: var(--txt-size-20);
}

.gallery {
  width: 100%;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}


.gallery-item {
  width: 46vw;
  min-width: 300px;
  height: 40vw;
  min-height: 200px;
  max-height: 550px;
  position: relative;
  border-radius: 3px;
  overflow: hidden;
  text-align: center;
  transition: filter 0.3s ease;
  background-color: var(--gicolor);
}
.gallery-item:hover {
  filter: contrast(1.05) brightness(.92) saturate(1.1);
  transition: filter 0.1s ease;
}
@media (max-width: 600px) {
  .gallery-item {
    width: 90vw;
    height: calc(45px + 80vw);
  }
}

/*@media (max-width: 550px) {
  .gallery-item {
    width: 90vw;
    height: 460px;
  }
}
@media (max-width: 500px) {
  .gallery-item {
    width: 90vw;
    height: 430px;
  }
}
@media (max-width: 450px) {
  .gallery-item {
    width: 90vw;
    height: 400px;
  }
}*/

:root {
  --gicolor: grey;
}
.gi1 {--gicolor : var(--button-color-dark);}
.gi2 {--gicolor : var(--button-color-dark);}


.gallery-item-visual {
  position: relative;
}
.gallery-item-gradient {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10;
  pointer-events: none;
  background-image: radial-gradient(circle, transparent 60%, rgba(0, 0, 10, .8) 100%);
}
.gallery-item-visual-gradient {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  background-image: linear-gradient(to bottom, var(--gicolor) 2%, transparent 30%,transparent 100%);
}

.gallery-item-link {
  position: relative;
  z-index: 20;
  display: inline-block;
}

#gi1-visual,
#gi2-visual  {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: start;
  border-top: 1px solid rgba(0, 0, 0, 0);
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  background-position: top;
  background-repeat: no-repeat;
  background-size: 100%;
}
#gi2-visual  {
  background-image: url(../../webassets/visuels/visuel-accueil-01_brutalisme.jpg);
}
#gi1-visual {
  background-image: url(../../webassets/visuels/visuel-accueil-02_durabilitevetementmedical.jpg);
}

.gallery-item-header {

  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.041), rgba(0, 0, 0, 0));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: start;
  padding-top: 1vh;
  padding-bottom: 1vh;
}
.gallery-item-header h3 {
  z-index: 30;
  color: var(--txt-color-whiteop-90);
  bottom: 0;
  margin: 0;
  padding: 3vh 1vh 0 1vh;
  width: 100%;
  font-size: var(--txt-size-13);
  font-weight: 700;
}
.gallery-item-header p {
  z-index: 30;
  color: var(--txt-color-whiteop-85);
  bottom: 0;
  margin: 0;
  padding: 0 1vh 0.5vh 1vh;
  width: 70%;
  text-align: center;
  font-size: var(--txt-size-10);
  font-weight: 400;
}
.btn-gallery-link {
  margin-top: 1rem;
  text-decoration: none;
  font-size: var(--txt-size-10);
  font-weight: 600;
  transition: background-color 0.2s ease;
}



/* =========================
   SECTION CARROUSEL
========================= */
.section-carrousel {
  position: relative;
  z-index: 10;
  width: 100%;
  height: 90vh;
  overflow: hidden;
  background-color: #111;
}

/* Background color layer */
.carrousel-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  transition: background-color 1s ease;
}

/* Slides container (receives parallax transform) */
.carrousel-slides {
  position: absolute;
  top: -25%;
  left: 0;
  right: 0;
  bottom: -25%;
  z-index: 1;
  will-change: transform;
  /* Isoler le compositing des slides : evite recomposite du background */
  contain: paint;
}

/* Individual slide */
.carrousel-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1s ease, transform 1s ease;
  transform: scale(1.04);
  /* Appliquer will-change seulement aux slides actifs pour eviter overhead */
}
.carrousel-slide.active {
  opacity: 1;
  transform: scale(1);
  will-change: opacity, transform;
}

/* Sub-images within a slide */
.carrousel-slide-img {
  position: absolute;
  inset: 0;
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0;
  transition: opacity 0.8s ease;
}
.carrousel-slide-img.active {
  opacity: 1;
}

/* Gradient overlay for text readability */
.carrousel-slide::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.55) 0%,
    rgba(0, 0, 0, 0.06) 35%,
    rgba(0, 0, 0, 0.02) 55%,
    rgba(0, 0, 0, 0.5) 100%
  );
  z-index: 1;
  pointer-events: none;
}

/* ---- OVERLAY (non-parallax layer) ---- */
.carrousel-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}

/* Header zone (top) */
.carrousel-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  padding: 45px 70px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 30px;
  pointer-events: auto;
}
.carrousel-info {
  flex: 1;
  min-width: 0;
}
.carrousel-title {
  color: white;
  font-family: 'Intertight', sans-serif;
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  font-weight: 700;
  margin: 0;
  line-height: 1.15;
  text-shadow: 0 2px 25px rgba(0, 0, 0, 0.35);
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.5s ease 0.15s, transform 0.5s ease 0.15s;
}
.carrousel-description {
  color: var(--txt-color-whiteop-85);
  font-size: clamp(0.9rem, 1.2vw, 1.15rem);
  font-weight: 400;
  max-width: 520px;
  margin: 10px 0 0 0;
  line-height: 1.5;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.25);
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.5s ease 0.3s, transform 0.5s ease 0.3s;
}
.carrousel-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-shrink: 0;
  padding-top: 5px;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.5s ease 0.4s, transform 0.5s ease 0.4s;
  pointer-events: auto;
}
/* Animated entrance */
.carrousel-header.visible .carrousel-title,
.carrousel-header.visible .carrousel-description,
.carrousel-header.visible .carrousel-actions {
  opacity: 1;
  transform: translateY(0);
}

/* ---- ARROWS ---- */
.carrousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 4;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);  /* Augmenter opacité au lieu de blur */
  /* backdrop-filter retiré : 80-90% GPU perf gain */
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
  pointer-events: auto;
}
.carrousel-arrow:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-50%) scale(1.06);
}
.carrousel-arrow:active {
  transform: translateY(-50%) scale(0.95);
}
.carrousel-arrow svg {
  width: 22px;
  height: 22px;
  stroke: white;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}
.carrousel-prev { left: 22px; }
.carrousel-next { right: 22px; }

/* ---- DOTS ---- */
.carrousel-dots {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  align-items: center;
  pointer-events: auto;
}
.carrousel-dot {
  height: 8px;
  width: 8px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.35);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: width 0.4s ease, background 0.4s ease;
  position: relative;
  overflow: hidden;
}
.carrousel-dot:hover {
  background: rgba(255, 255, 255, 0.55);
}
.carrousel-dot.active {
  width: 44px;
  background: rgba(255, 255, 255, 0.2);
}
.carrousel-dot.active::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 0%;
  background: rgba(255, 255, 255, 0.85);
  border-radius: 4px;
  animation: carrousel-dot-fill var(--carrousel-duration, 15s) linear forwards;
}
.carrousel-dot.paused.active::after {
  animation-play-state: paused;
}
@keyframes carrousel-dot-fill {
  from { width: 0%; }
  to { width: 100%; }
}

/* ---- IMAGE SUB-INDICATORS ---- */
.carrousel-img-indicators {
  position: absolute;
  bottom: 60px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  align-items: center;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}
.carrousel-img-indicators.visible {
  opacity: 1;
}
.carrousel-img-indicator {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
  transition: background 0.3s ease, transform 0.3s ease;
}
.carrousel-img-indicator.active {
  background: rgba(255, 255, 255, 0.9);
  transform: scale(1.4);
}



/* =========================
   MOBILE
========================= */
@media (max-width: 800px) {
  /* Carrousel mobile (animation du background désactivée via JS mobile detection) */
  .carrousel-header {
    padding: 30px 20px;
    flex-direction: column;
    gap: 15px;
  }
  .carrousel-actions {
    padding-top: 0;
    flex-direction: column;
    align-items: flex-start;
  }
  .carrousel-arrow {
    width: 40px;
    height: 40px;
  }
  .carrousel-arrow svg {
    width: 18px;
    height: 18px;
  }
  .carrousel-prev { left: 12px; }
  .carrousel-next { right: 12px; }
  .carrousel-dots {
    bottom: 20px;
  }
  .carrousel-img-indicators {
    bottom: 48px;
  }
}



