/* ============================================================
   RESET & BASE
   ============================================================ */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

img, svg { display: block; max-width: 100%; }

/* ============================================================
   UTILITAIRES ACCESSIBILITÉ
   ============================================================ */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: #000;
  color: #fff;
  padding: .5rem 1rem;
  z-index: 9999;
  border-radius: 0 0 4px 4px;
  text-decoration: none;
  font-size: .875rem;
}

.skip-link:focus {
  top: 0;
}

/* ============================================================
   HEADER / NAVIGATION
   ============================================================ */

.site-header {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 1rem 2rem;
  background: #fff;
  border-bottom: 1px solid #eee;
}

.site-header__logo {
  text-decoration: none;
  color: inherit;
  flex-shrink: 0;
}

.site-header__logo img {
  height: 48px;
  width: auto;
}

.site-nav {
  flex: 1;
}

.site-nav__list {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.site-nav__link {
  text-decoration: none;
  color: inherit;
  font-size: .9375rem;
}

.site-nav__link:hover,
.site-nav__link.is-active {
  text-decoration: underline;
}

.site-nav__link:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

.site-nav__cta {
  display: flex;
  gap: .75rem;
  list-style: none;
}

/* burger — masqué desktop */
.site-header__burger {
  display: none;
}

/* ============================================================
   BOUTONS
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .625rem 1.5rem;
  border-radius: 4px;
  text-decoration: none;
  font-size: .9375rem;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  transition: background .15s, color .15s, border-color .15s;
}

.btn:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

.btn--outline {
  border-color: currentColor;
  background: transparent;
}

.btn--filled {
  background: #111;
  color: #fff;
  border-color: #111;
}

.btn--filled:hover {
  background: #333;
  border-color: #333;
}

/* ============================================================
   HERO
   ============================================================ */

.block-hero {
  position: relative;
  min-height: 80vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.block-hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.block-hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* overlay contraste */
.block-hero--dark .block-hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .5);
}

.block-hero__content {
  position: relative;
  z-index: 1;
  padding: 4rem 2rem;
  max-width: 800px;
  width: 100%;
}

/* variantes couleur */
.block-hero--dark  { color: #fff; }
.block-hero--light { color: #111; }

/* variantes alignement */
.block-hero--center .block-hero__content {
  margin-inline: auto;
  text-align: center;
}

.block-hero--left .block-hero__content {
  margin-inline: 0;
  text-align: left;
}

.block-hero__title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 1.1;
  margin-bottom: 1rem;
}

.block-hero__subtitle {
  font-size: clamp(1rem, 2vw, 1.25rem);
  margin-bottom: 2rem;
  opacity: .85;
}

.btn--hero {
  background: #fff;
  color: #111;
  border-color: #fff;
}

.btn--hero:hover {
  background: transparent;
  color: #fff;
  border-color: #fff;
}

/* ============================================================
   TIMELINE
   ============================================================ */

.block-timeline {
  padding-block: 4rem;
  padding-inline: 2rem;
}

.block-timeline__header {
  max-width: 700px;
  margin-inline: auto;
  text-align: center;
  margin-bottom: 3rem;
}

.block-timeline__title {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  margin-bottom: .75rem;
}

.block-timeline__intro {
  opacity: .75;
}

/* variante verticale */
.block-timeline--vertical .block-timeline__list {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  list-style: none;
  max-width: 700px;
  margin-inline: auto;
}

.block-timeline--vertical .block-timeline__item {
  display: flex;
  gap: 1.5rem;
  position: relative;
  padding-left: 1rem;
}

.block-timeline--vertical .block-timeline__item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: currentColor;
  opacity: .15;
}

/* variante horizontale */
.block-timeline--horizontal .block-timeline__list {
  display: flex;
  flex-direction: row;
  gap: 2rem;
  list-style: none;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-block: 1rem;
  -webkit-overflow-scrolling: touch;
}

.block-timeline--horizontal .block-timeline__list:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
}

.block-timeline--horizontal .block-timeline__item {
  display: flex;
  flex-direction: column;
  flex: 0 0 280px;
  scroll-snap-align: start;
  gap: .5rem;
}

/* éléments communs */
.block-timeline__year {
  flex-shrink: 0;
  font-weight: 700;
  font-size: 1.125rem;
  min-width: 4rem;
}

.block-timeline__event-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: .25rem;
}

.block-timeline__text {
  font-size: .9375rem;
  opacity: .75;
}

/* ============================================================
   RÉASSURANCE
   ============================================================ */

.block-reassurance {
  padding-block: 4rem;
  padding-inline: 2rem;
}

.block-reassurance__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  max-width: 1100px;
  margin-inline: auto;
}

/* colonne texte */
.block-reassurance__text {
  font-size: 1.125rem;
  line-height: 1.6;
}

.block-reassurance__text p + p {
  margin-top: 1em;
}

/* colonne chiffres */
.block-reassurance__stats {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  list-style: none;
}

.block-reassurance__item {
  display: flex;
  align-items: baseline;
  gap: 1rem;
}

.block-reassurance__figure {
  display: flex;
  align-items: baseline;
  gap: .15rem;
  flex-shrink: 0;
}

.block-reassurance__value {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  line-height: 1;
}

.block-reassurance__unit {
  font-size: 1.5rem;
  font-weight: 700;
}

.block-reassurance__label {
  font-size: 1rem;
  line-height: 1.3;
}

/* variantes */
.block-reassurance--dark {
  background: #111;
  color: #fff;
}

.block-reassurance--accent {
  background: #E63946;
  color: #fff;
}

@media (max-width: 768px) {
  .block-reassurance__inner {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

/* ============================================================
   CAROUSEL
   ============================================================ */

.block-carousel {
  position: relative;
  padding-block: 3rem;
}

.block-carousel__section-title {
  text-align: center;
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  margin-bottom: 2rem;
  padding-inline: 2rem;
}

.block-carousel__track-wrapper {
  position: relative;
  overflow: hidden;
}

.block-carousel__track {
  display: flex;
  list-style: none;
  transition: transform 0.4s ease;
}

@media (prefers-reduced-motion: reduce) {
  .block-carousel__track {
    transition: none;
  }
}

.block-carousel__slide {
  flex: 0 0 100%;
  position: relative;
  min-height: 400px;
}

.block-carousel__image {
  position: absolute;
  inset: 0;
}

.block-carousel__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.block-carousel__content {
  position: relative;
  z-index: 1;
  padding: 3rem 2rem;
  color: #fff;
  background: linear-gradient(to top, rgba(0,0,0,.7) 0%, transparent 100%);
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
}

.block-carousel__title {
  font-size: clamp(1.25rem, 3vw, 2rem);
  margin-bottom: .5rem;
}

.block-carousel__text {
  margin-bottom: 1rem;
  opacity: .85;
}

/* contrôles */
.block-carousel__controls {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  transform: translateY(-50%);
  padding-inline: 1rem;
  pointer-events: none;
  z-index: 2;
}

.block-carousel__prev,
.block-carousel__next,
.block-carousel__pause {
  pointer-events: all;
  background: rgba(0,0,0,.5);
  color: #fff;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.125rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.block-carousel__prev:focus-visible,
.block-carousel__next:focus-visible,
.block-carousel__pause:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.block-carousel__pause {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  top: auto;
}

/* dots */
.block-carousel__dots {
  display: flex;
  justify-content: center;
  gap: .5rem;
  padding: 1rem;
}

.block-carousel__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid currentColor;
  background: transparent;
  cursor: pointer;
  padding: 0;
  opacity: .4;
  transition: opacity .2s;
}

.block-carousel__dot[aria-selected="true"] {
  opacity: 1;
  background: currentColor;
}

.block-carousel__dot:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

/* ============================================================
   CTA
   ============================================================ */

.block-cta {
  position: relative;
  padding-block: 5rem;
  padding-inline: 2rem;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.block-cta__bg-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .45);
}

.block-cta__card {
  position: relative;
  z-index: 1;
  padding: 2.5rem 3rem;
  border-radius: 4px;
  max-width: 560px;
  width: 100%;
}

.block-cta__card--white  { background: #fff; color: #111; }
.block-cta__card--dark   { background: #111; color: #fff; }
.block-cta__card--accent { background: #E63946; color: #fff; }

.block-cta__title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 1rem;
}

.block-cta__text {
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.block-cta__text ul {
  padding-left: 1.25rem;
  margin-top: .5rem;
}

.block-cta__text li + li {
  margin-top: .25rem;
}

.btn--cta {
  display: inline-flex;
  padding: .75rem 2rem;
  font-size: 1rem;
  font-weight: 700;
  border-radius: 4px;
  text-decoration: none;
  background: #111;
  color: #fff;
  border: 2px solid #111;
  transition: background .15s, color .15s;
}

.block-cta__card--dark   .btn--cta,
.block-cta__card--accent .btn--cta {
  background: #fff;
  color: #111;
  border-color: #fff;
}

.btn--cta:hover {
  background: transparent;
  color: #111;
}

.block-cta__card--dark   .btn--cta:hover,
.block-cta__card--accent .btn--cta:hover {
  color: #fff;
  background: transparent;
}

.btn--cta:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

@media (max-width: 768px) {
  .block-cta__card {
    padding: 1.5rem;
  }
}

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

@media (max-width: 768px) {
  .site-header {
    flex-wrap: wrap;
    padding: 1rem;
  }

  .site-nav,
  .site-nav__cta {
    display: none;
  }

  .site-header__burger {
    display: flex;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: .5rem;
    margin-left: auto;
  }

  .site-header__burger span {
    display: block;
    width: 24px;
    height: 2px;
    background: currentColor;
  }
}
