/* ============================================================
   FIREX Engineering — Feuille de style principale
   Palette et typographie reprises de la brochure 2026
   ============================================================ */

/* ---------- 1. Tokens ---------- */
:root {
  --red: #e7182b;
  --red-dark: #b70f1f;
  --red-light: #ff3546;
  --red-soft: #fff0f1;

  --ink: #0a0a0a;
  --ink-2: #111111;
  --ink-3: #1c1c1c;
  --ink-4: #2a2a2a;

  --white: #ffffff;
  --paper: #f7f7f8;
  --line: #e6e6e8;
  --line-dark: #2e2e2e;

  --text: #17171a;
  --muted: #6a6a72;
  --muted-dark: #a0a0a8;

  --font-head: "Poppins", "Segoe UI", "Trebuchet MS", sans-serif;
  --font-body: "Inter", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --wrap: 1200px;
  --pad: clamp(20px, 5vw, 48px);

  --r-sm: 6px;
  --r: 12px;
  --r-lg: 18px;

  --shadow-sm: 0 2px 10px rgba(10, 10, 10, 0.06);
  --shadow: 0 10px 34px rgba(10, 10, 10, 0.10);
  --shadow-lg: 0 24px 60px rgba(10, 10, 10, 0.16);

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --header-h: 84px;
}

/* ---------- 2. Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

* { margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background: var(--white);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

ul, ol { list-style: none; }

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

h1, h2, h3, h4, h5 {
  font-family: var(--font-head);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.02em;
}

::selection { background: var(--red); color: #fff; }

:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ---------- 3. Utilitaires de mise en page ---------- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--pad);
}

/* Conteneur élargi : utilisé par la rangée de quatre cartes « Nos atouts »,
   pour qu'elles gardent la largeur confortable qu'elles avaient à trois. */
.wrap--wide { max-width: 1560px; }

.section { padding-block: clamp(64px, 9vw, 118px); }
.section--tight { padding-block: clamp(48px, 6vw, 76px); }

.section--dark {
  background: var(--ink);
  color: #fff;
}

.section--paper { background: var(--paper); }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 999;
  background: var(--red);
  color: #fff;
  padding: 12px 20px;
  font-weight: 700;
}
.skip-link:focus { left: 0; }

/* ---------- 4. Étiquette de section (eyebrow) ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-head);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--red);
  background: var(--red-soft);
  border-left: 3px solid var(--red);
  padding: 7px 14px 7px 11px;
  margin-bottom: 22px;
}

.section--dark .eyebrow {
  background: rgba(231, 24, 43, 0.14);
  color: var(--red-light);
}

.eyebrow svg { width: 13px; height: 13px; }

/* ---------- 5. Titres ---------- */
.h-xxl { font-size: clamp(2.3rem, 6.2vw, 4.5rem); }
.h-xl  { font-size: clamp(2rem, 4.6vw, 3.3rem); }
.h-lg  { font-size: clamp(1.6rem, 3vw, 2.3rem); }
.h-md  { font-size: clamp(1.2rem, 2vw, 1.5rem); }

.accent { color: var(--red); }

.lead {
  font-size: clamp(1rem, 1.3vw, 1.13rem);
  color: var(--muted);
  max-width: 68ch;
}

.section--dark .lead { color: var(--muted-dark); }

.rule {
  width: 62px;
  height: 4px;
  background: var(--red);
  border-radius: 2px;
  margin-top: 26px;
}

.rule--center { margin-inline: auto; }

.head-block { max-width: 760px; margin-bottom: clamp(38px, 5vw, 60px); }
.head-block--center { margin-inline: auto; text-align: center; }
.head-block--center .lead { margin-inline: auto; }
.head-block--center .eyebrow { border-left: 0; border-bottom: 2px solid var(--red); }

/* ---------- 6. Boutons ---------- */
.btn {
  --btn-bg: var(--red);
  --btn-fg: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-head);
  font-size: 0.83rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 15px 30px;
  border: 2px solid var(--btn-bg);
  border-radius: var(--r-sm);
  background: var(--btn-bg);
  color: var(--btn-fg);
  cursor: pointer;
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease),
    background 0.22s var(--ease), color 0.22s var(--ease), border-color 0.22s var(--ease);
}

.btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 26px rgba(231, 24, 43, 0.32);
}

.btn svg { width: 16px; height: 16px; flex: none; }

.btn--ghost {
  background: transparent;
  color: var(--text);
  border-color: rgba(0, 0, 0, 0.18);
}
.btn--ghost:hover {
  border-color: var(--red);
  color: var(--red);
  box-shadow: 0 12px 26px rgba(10, 10, 10, 0.12);
}

.btn--ghost-light {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.35);
}
.btn--ghost-light:hover {
  background: #fff;
  color: var(--ink);
  border-color: #fff;
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.3);
}

.btn--dark { --btn-bg: var(--ink); }
.btn--dark:hover { box-shadow: 0 12px 26px rgba(10, 10, 10, 0.3); }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

/* ---------- 7. En-tête / navigation ---------- */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  transform: none !important;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: linear-gradient(to bottom, rgba(8, 8, 8, 0.82), rgba(8, 8, 8, 0));
  transition: background 0.3s var(--ease), height 0.3s var(--ease),
    box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
  border-bottom: 1px solid transparent;
}

.header.is-solid,
.header.is-static {
  background: rgba(9, 9, 9, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: rgba(255, 255, 255, 0.09);
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.35);
}

.header.is-solid { height: 70px; }

.header__inner {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--pad);
  display: flex;
  align-items: center;
  gap: 26px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-right: auto;
  flex: none;
}

.brand img {
  height: 56px;
  width: auto;
  transition: height 0.3s var(--ease);
}

.header.is-solid .brand img { height: 46px; }

.brand__txt {
  display: none;
  font-family: var(--font-head);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.4;
  border-left: 1px solid rgba(255, 255, 255, 0.2);
  padding-left: 11px;
}

@media (min-width: 1080px) { .brand__txt { display: block; } }

.nav { display: flex; align-items: center; gap: 4px; }

.nav a {
  position: relative;
  font-family: var(--font-head);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.82);
  padding: 10px 14px;
  border-radius: var(--r-sm);
  transition: color 0.2s var(--ease), background 0.2s var(--ease);
}

.nav a::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 4px;
  height: 2px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s var(--ease);
}

.nav a:hover { color: #fff; }
.nav a:hover::after,
.nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a[aria-current="page"] { color: #fff; }

.header .btn {
  padding: 12px 22px;
  font-size: 0.74rem;
}

.nav-toggle {
  display: none;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: var(--r-sm);
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
  position: relative;
}

.nav-toggle span {
  position: absolute;
  left: 13px;
  right: 13px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.3s var(--ease), opacity 0.2s var(--ease);
}
.nav-toggle span:nth-child(1) { top: 16px; }
.nav-toggle span:nth-child(2) { top: 22px; }
.nav-toggle span:nth-child(3) { top: 28px; }

.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 980px) {
  .nav-toggle { display: block; }

  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: rgba(9, 9, 9, 0.985);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    border-bottom: 3px solid var(--red);
    padding: 12px var(--pad) 26px;
    transform: translateY(-14px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.26s var(--ease), transform 0.26s var(--ease), visibility 0.26s;
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
  }

  .nav.is-open { opacity: 1; visibility: visible; transform: translateY(0); }

  .nav a {
    padding: 16px 4px;
    font-size: 0.94rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 0;
  }
  .nav a::after { display: none; }
  .nav a[aria-current="page"] { color: var(--red-light); }

  .nav .btn {
    margin-top: 18px;
    width: 100%;
    padding: 16px;
    font-size: 0.82rem;
    border-bottom: 0;
  }
}

/* ---------- 8. Hero (accueil) ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  background: var(--ink);
  color: #fff;
  overflow: hidden;
  padding-top: var(--header-h);
}

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

.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 38%;
  animation: heroZoom 22s var(--ease) forwards;
}

@keyframes heroZoom {
  from { transform: scale(1.14); }
  to { transform: scale(1); }
}

/* Quand GSAP est actif, c'est lui qui pilote l'échelle et la parallaxe du
   hero : on coupe l'animation CSS, sinon elle écraserait ses transformations
   (une animation CSS l'emporte sur un style inline). */
.js .hero__media img { animation: none; }

/* Vidéo de fond, injectée par le JS. Deux lecteurs se relaient en fondu
   enchaîné pour masquer la coupe du bouclage. L'image reste dessous : si la
   vidéo tarde, échoue ou est refusée, le hero garde son visuel. */
.hero__video {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  opacity: 0;
  transition: opacity 0.7s linear;
  pointer-events: none;
}

.hero__video.is-on { opacity: 1; }

.hero__media::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  /* Assez sombre pour que le texte blanc reste lisible, assez transparent
     pour laisser respirer le coucher de soleil de la vidéo. */
  background:
    radial-gradient(120% 92% at 50% 45%, rgba(8, 8, 8, 0.12) 0%, rgba(8, 8, 8, 0.66) 60%, rgba(8, 8, 8, 0.92) 100%),
    linear-gradient(to bottom, rgba(8, 8, 8, 0.70) 0%, rgba(8, 8, 8, 0.22) 32%, rgba(8, 8, 8, 0.86) 100%);
}

.hero__inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding: 60px var(--pad) 150px;
  text-align: center;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--red);
  color: #fff;
  font-family: var(--font-head);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 9px 18px;
  border-radius: 3px;
  margin-bottom: 26px;
}

.hero h1 {
  font-size: clamp(2.35rem, 6.6vw, 5rem);
  margin-inline: auto;
  max-width: 23ch;
  text-shadow: 0 4px 40px rgba(0, 0, 0, 0.55);
}

.hero__sub {
  font-family: var(--font-head);
  font-size: clamp(0.9rem, 1.9vw, 1.3rem);
  font-weight: 400;
  letter-spacing: 0.26em;
  color: rgba(255, 255, 255, 0.72);
  margin-top: 22px;
  text-transform: capitalize;
}

.hero__text {
  max-width: 62ch;
  margin: 30px auto 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(0.95rem, 1.2vw, 1.05rem);
}

.hero__strip {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 3;
  background: var(--red);
}

.hero__strip ul {
  max-width: var(--wrap);
  margin-inline: auto;
  padding: 18px var(--pad);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.hero__strip li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #fff;
  line-height: 1.3;
}

.hero__strip svg { width: 20px; height: 20px; flex: none; opacity: 0.92; }

/* Le bandeau est en position absolue au bas du hero : sa hauteur augmente
   quand il passe sur 2 puis 1 colonne. On creuse le bas du contenu d'autant,
   sinon il recouvrirait les boutons. */
@media (max-width: 900px) {
  .hero__strip ul { grid-template-columns: repeat(2, 1fr); gap: 14px 18px; }
  .hero__strip li:last-child { grid-column: 1 / -1; }
  .hero__inner { padding-bottom: 190px; }
}
@media (max-width: 420px) {
  .hero__strip ul { grid-template-columns: 1fr; }
  .hero__strip li:last-child { grid-column: auto; }
  .hero__inner { padding-bottom: 275px; }
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 132px;
  z-index: 3;
  transform: translateX(-50%);
  width: 26px;
  height: 42px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 14px;
}
.scroll-cue::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 8px;
  width: 3px;
  height: 8px;
  border-radius: 2px;
  background: #fff;
  transform: translateX(-50%);
  animation: cue 1.9s var(--ease) infinite;
}
@keyframes cue {
  0% { opacity: 0; transform: translate(-50%, 0); }
  35% { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, 15px); }
}

@media (max-width: 700px) { .scroll-cue { display: none; } }

/* ---------- 9. Bannière de page intérieure ---------- */
.pagehead {
  position: relative;
  background: var(--ink);
  color: #fff;
  padding: calc(var(--header-h) + clamp(56px, 8vw, 92px)) 0 clamp(56px, 8vw, 92px);
  overflow: hidden;
}

.pagehead::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--bg, none);
  background-size: cover;
  background-position: center;
  opacity: 0.26;
}

.pagehead::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, rgba(8, 8, 8, 0.96) 20%, rgba(8, 8, 8, 0.62) 100%);
}

.pagehead > * { position: relative; z-index: 2; }

.pagehead .lead { color: rgba(255, 255, 255, 0.78); }

.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  font-size: 0.76rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 26px;
}
.crumbs a:hover { color: var(--red-light); }
.crumbs span[aria-current] { color: #fff; }

/* ---------- 10. Grilles génériques ---------- */
.grid { display: grid; gap: clamp(18px, 2.4vw, 28px); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(285px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(228px, 1fr)); }

/* Quatre cartes tenues sur une seule rangée. En « auto-fit » elles
   tombaient en 3+1, ce qui laissait une carte orpheline.
   Gouttières resserrées : chaque pixel gagné va à la largeur des cartes. */
.grid--4up {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(14px, 1.5vw, 22px);
}

/* En dessous de 1300 px, quatre colonnes deviendraient trop étroites :
   on passe à 2+2, qui reste équilibré et laisse les cartes respirer. */
@media (max-width: 1300px) { .grid--4up { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px)  { .grid--4up { grid-template-columns: 1fr; } }

/* ---------- 11. Section « à propos » (split) ---------- */
.split {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}

@media (max-width: 940px) { .split { grid-template-columns: 1fr; } }

.split__media {
  position: relative;
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4 / 5;
}

.split__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.9s var(--ease);
}
.split__media:hover img { transform: scale(1.05); }

.split__quote {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 30px 26px 26px;
  background: linear-gradient(to top, rgba(8, 8, 8, 0.94), rgba(8, 8, 8, 0));
  color: #fff;
}

.split__quote p {
  font-style: italic;
  font-size: 0.94rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.92);
}

.split__quote cite {
  display: block;
  margin-top: 12px;
  font-family: var(--font-head);
  font-size: 0.66rem;
  font-weight: 700;
  font-style: normal;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--red-light);
}

.prose p + p { margin-top: 16px; }
.prose p { color: var(--muted); }

.mission {
  margin-top: 28px;
  padding: 22px 24px;
  background: var(--paper);
  border-left: 4px solid var(--red);
  border-radius: 0 var(--r) var(--r) 0;
}

.mission h3 {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 0.95rem;
  margin-bottom: 9px;
}
.mission h3 svg { width: 17px; height: 17px; color: var(--red); }
.mission p { font-size: 0.92rem; color: var(--muted); }

/* ---------- 12. Cartes valeurs ---------- */
.vcard {
  background: var(--paper);
  border-top: 3px solid var(--red);
  border-radius: 0 0 var(--r) var(--r);
  padding: 28px 22px;
  text-align: center;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background 0.3s var(--ease);
}
.vcard:hover { transform: translateY(-6px); box-shadow: var(--shadow); background: #fff; }

.vcard__icon {
  width: 46px;
  height: 46px;
  margin: 0 auto 16px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
}
.vcard__icon svg { width: 21px; height: 21px; }

.vcard h3 {
  font-size: 0.86rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 9px;
}
.vcard p { font-size: 0.85rem; color: var(--muted); line-height: 1.6; }

/* ---------- 13. Bandeau de statistiques ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  background: var(--ink);
  border-radius: var(--r);
  overflow: hidden;
}

.stats--flat { border-radius: 0; }

.stat {
  padding: 30px 22px;
  border-right: 1px solid rgba(255, 255, 255, 0.09);
  text-align: center;
}
.stat:last-child { border-right: 0; }

.stat__num {
  font-family: var(--font-head);
  font-size: clamp(1.9rem, 3.4vw, 2.7rem);
  font-weight: 800;
  color: var(--red);
  line-height: 1;
  letter-spacing: -0.03em;
}

.stat__label {
  margin-top: 10px;
  font-family: var(--font-head);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.62);
  line-height: 1.5;
}

.section--paper .stats { box-shadow: var(--shadow); }

/* ---------- 14. Cartes domaines (5 pôles) ---------- */
.dcard {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-left: 4px solid var(--red);
  border-radius: var(--r);
  padding: 28px 26px 24px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.32s var(--ease), box-shadow 0.32s var(--ease), border-color 0.32s var(--ease);
}

.dcard:hover { transform: translateY(-7px); box-shadow: var(--shadow-lg); }

.dcard__no {
  position: absolute;
  top: 12px;
  right: 20px;
  font-family: var(--font-head);
  font-size: 3.4rem;
  font-weight: 800;
  color: rgba(231, 24, 43, 0.10);
  line-height: 1;
  pointer-events: none;
}

.dcard__top {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 15px;
}

.dcard__icon {
  width: 46px;
  height: 46px;
  flex: none;
  display: grid;
  place-items: center;
  background: var(--red);
  color: #fff;
  border-radius: var(--r-sm);
  transition: transform 0.32s var(--ease);
}
.dcard:hover .dcard__icon { transform: rotate(-6deg) scale(1.06); }
.dcard__icon svg { width: 23px; height: 23px; }

.dcard h3 {
  font-size: 0.98rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding-right: 46px;
}

.dcard p { font-size: 0.9rem; color: var(--muted); flex: 1; }

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 20px;
}

.tag {
  font-family: var(--font-head);
  font-size: 0.63rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--red);
  background: var(--red-soft);
  padding: 6px 11px;
  border-radius: 40px;
}

.section--dark .tag {
  background: rgba(231, 24, 43, 0.16);
  color: var(--red-light);
}

.dcard--wide { grid-column: 1 / -1; }

@media (min-width: 860px) {
  .dcard--wide { flex-direction: row; align-items: center; gap: 30px; }
  .dcard--wide .dcard__body { flex: 1; }
  .dcard--wide .dcard__top { margin-bottom: 0; min-width: 330px; }
  .dcard--wide .tags { margin-top: 14px; }
}

/* ---------- 15. Bloc de service détaillé ---------- */
.svc {
  scroll-margin-top: calc(var(--header-h) + 24px);
  border-top: 1px solid var(--line);
  padding-block: clamp(52px, 7vw, 88px);
}
.svc:first-of-type { border-top: 0; }

.svc__banner {
  position: relative;
  border-radius: var(--r-lg);
  overflow: hidden;
  margin-bottom: 40px;
  background: var(--ink);
  aspect-ratio: 1600 / 428;
}

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

/* Variante sans photo : dégradé + trame technique */
.svc__banner--plain {
  background:
    linear-gradient(115deg, var(--ink) 0%, #1a1013 46%, var(--red-dark) 100%);
}

.svc__banner--plain::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(100deg, transparent 30%, #000 100%);
  -webkit-mask-image: linear-gradient(100deg, transparent 30%, #000 100%);
}

.svc__banner--plain .svc__banner-txt {
  background: linear-gradient(100deg, rgba(8, 8, 8, 0.85) 20%, rgba(8, 8, 8, 0.1) 90%);
}

.svc__banner-txt {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(20px, 4vw, 48px);
  background: linear-gradient(100deg, rgba(8, 8, 8, 0.93) 25%, rgba(8, 8, 8, 0.45) 75%, rgba(8, 8, 8, 0.15));
  color: #fff;
}

.svc__banner-txt h2 { font-size: clamp(1.4rem, 3.4vw, 2.5rem); }

.svc__banner-txt p {
  margin-top: 8px;
  font-size: clamp(0.7rem, 1.3vw, 0.88rem);
  letter-spacing: 0.05em;
  color: rgba(255, 255, 255, 0.78);
}

.svc__grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: clamp(30px, 4vw, 54px);
  align-items: start;
}

@media (max-width: 940px) { .svc__grid { grid-template-columns: 1fr; } }

.subhead {
  font-family: var(--font-head);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text);
  padding-bottom: 12px;
  margin-bottom: 24px;
  border-bottom: 2px solid var(--red);
  display: inline-block;
}

.feature-list { display: grid; gap: 20px; }

.feature {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 15px;
  align-items: start;
}

.feature__dot {
  width: 30px;
  height: 30px;
  margin-top: 2px;
  display: grid;
  place-items: center;
  background: var(--red-soft);
  color: var(--red);
  border-radius: 50%;
  flex: none;
  transition: background 0.25s var(--ease), color 0.25s var(--ease);
}
.feature__dot svg { width: 15px; height: 15px; }
.feature:hover .feature__dot { background: var(--red); color: #fff; }

.feature h4 { font-size: 0.94rem; font-weight: 700; margin-bottom: 4px; }
.feature p { font-size: 0.86rem; color: var(--muted); line-height: 1.62; }

/* ---------- 16. Normes / standards ---------- */
.norms { display: grid; gap: 12px; }

.norm {
  padding: 15px 18px;
  background: var(--paper);
  border-left: 3px solid var(--red);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
  transition: transform 0.25s var(--ease), background 0.25s var(--ease);
}
.norm:hover { transform: translateX(5px); background: var(--red-soft); }

.norm strong {
  display: block;
  font-family: var(--font-head);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  color: var(--text);
}
.norm span { font-size: 0.79rem; color: var(--muted); }

/* ---------- 17. Puces de secteurs ---------- */
.sectors { display: flex; flex-wrap: wrap; gap: 9px; }

.sector {
  font-family: var(--font-head);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: 40px;
  color: var(--muted);
  transition: all 0.25s var(--ease);
}
.sector:hover,
.section--dark .sector:hover {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
  transform: translateY(-2px);
}

.section--dark .sector {
  border-color: rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.72);
}

/* ---------- 18. Bandeau KPI d'un service ---------- */
.kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  margin-top: 40px;
}

.kpi { background: #fff; padding: 26px 18px; text-align: center; }
.kpi b {
  display: block;
  font-family: var(--font-head);
  font-size: clamp(1.5rem, 2.6vw, 2.1rem);
  font-weight: 800;
  color: var(--red);
  line-height: 1.1;
}
.kpi span {
  display: block;
  margin-top: 8px;
  font-family: var(--font-head);
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.5;
}

/* ---------- 19. Processus ---------- */
.steps { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.step {
  position: relative;
  background: var(--ink-2);
  border: 1px solid var(--line-dark);
  border-radius: var(--r);
  padding: 30px 24px 26px;
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease);
}
.step:hover { transform: translateY(-6px); border-color: var(--red); }

.step__no {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  background: var(--red);
  color: #fff;
  border-radius: 50%;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1rem;
  margin-bottom: 16px;
}

.step h4 { font-size: 0.98rem; color: #fff; margin-bottom: 8px; }
.step p { font-size: 0.85rem; color: var(--muted-dark); line-height: 1.62; }

/* ---------- 20. Partenaires ---------- */
.pcard {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 168px;
  padding: 26px 18px;
  background: var(--ink-2);
  border: 1px solid var(--line-dark);
  border-radius: var(--r);
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease), background 0.3s var(--ease);
}

.pcard:hover { transform: translateY(-6px); border-color: var(--red); background: #161616; }

.pcard b {
  font-family: var(--font-head);
  font-size: 0.98rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
}

.pcard b em {
  display: block;
  font-style: normal;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  color: var(--red);
  margin-top: 2px;
}

.pcard i {
  display: block;
  width: 26px;
  height: 3px;
  background: var(--red);
  border-radius: 2px;
  margin: 11px 0 10px;
}

.pcard span {
  font-size: 0.66rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted-dark);
  line-height: 1.55;
}

.pcard img { max-height: 66px; max-width: 76%; width: auto; object-fit: contain; }

/* Logos fournis en image : fond clair, comme dans la brochure */
.pcard--light { background: #f2f2f2; border-color: #f2f2f2; }
.pcard--light:hover { background: #fff; }

/* ---------- 21. Références projets ---------- */
.ref {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 28px 26px;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
  overflow: hidden;
}

.ref::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--red);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.35s var(--ease);
}
.ref:hover::before { transform: scaleY(1); }
.ref:hover { transform: translateY(-6px); box-shadow: var(--shadow); }

.ref h3 { font-size: 1.02rem; margin-bottom: 10px; }
.ref p { font-size: 0.88rem; color: var(--muted); }

/* ---------- 22. Atouts ---------- */
.adv {
  background: var(--ink-2);
  border: 1px solid var(--line-dark);
  border-radius: var(--r);
  padding: 30px 26px;
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease);
}
.adv:hover { transform: translateY(-6px); border-color: var(--red); }

.adv__icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  background: rgba(231, 24, 43, 0.14);
  color: var(--red-light);
  border-radius: var(--r-sm);
  margin-bottom: 18px;
}
.adv__icon svg { width: 23px; height: 23px; }

.adv h3 {
  font-size: 0.94rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 11px;
}
.adv p { font-size: 0.87rem; color: var(--muted-dark); line-height: 1.68; }


/* ---------- 23. Appel à l'action ---------- */
.cta {
  position: relative;
  background: var(--red);
  color: #fff;
  padding-block: clamp(52px, 7vw, 86px);
  overflow: hidden;
  text-align: center;
}

.cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(60% 120% at 12% 0%, rgba(255, 255, 255, 0.16), transparent 60%),
    radial-gradient(50% 110% at 88% 100%, rgba(0, 0, 0, 0.22), transparent 60%);
}

.cta > * { position: relative; z-index: 2; }
.cta h2 { font-size: clamp(1.7rem, 3.8vw, 2.8rem); }
.cta p {
  max-width: 64ch;
  margin: 16px auto 0;
  color: rgba(255, 255, 255, 0.92);
  font-size: clamp(0.94rem, 1.2vw, 1.05rem);
}
.cta .btn-row { justify-content: center; }

/* ---------- 24. Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}
@media (max-width: 940px) { .contact-grid { grid-template-columns: 1fr; } }

.info-card {
  background: var(--ink);
  color: #fff;
  border-radius: var(--r-lg);
  padding: clamp(26px, 3.4vw, 40px);
  border-top: 4px solid var(--red);
}

.info-list { display: grid; gap: 24px; margin-top: 26px; }

.info {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 15px;
  align-items: start;
}

.info__icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: rgba(231, 24, 43, 0.16);
  color: var(--red-light);
  border-radius: 50%;
  flex: none;
}
.info__icon svg { width: 17px; height: 17px; }

.info b {
  display: block;
  font-family: var(--font-head);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red-light);
  margin-bottom: 5px;
}
.info a,
.info p { font-size: 0.92rem; color: rgba(255, 255, 255, 0.85); line-height: 1.6; }
.info a { display: block; transition: color 0.2s var(--ease); }
.info a:hover { color: #fff; text-decoration: underline; }

.socials { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }

.social {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 17px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--r-sm);
  font-size: 0.8rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  transition: all 0.25s var(--ease);
}
.social svg { width: 16px; height: 16px; }
.social:hover { background: var(--red); border-color: var(--red); color: #fff; transform: translateY(-2px); }

/* Formulaire */
.form-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: clamp(26px, 3.4vw, 40px);
  box-shadow: var(--shadow-sm);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 18px;
  margin-top: 26px;
}

.field { display: flex; flex-direction: column; gap: 7px; }
.field--full { grid-column: 1 / -1; }

.field label {
  font-family: var(--font-head);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text);
}
.field label span { color: var(--red); }

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--paper);
  font-size: 0.93rem;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.field textarea { resize: vertical; min-height: 132px; line-height: 1.6; }

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--red);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(231, 24, 43, 0.12);
}

.field input:user-invalid,
.field textarea:user-invalid { border-color: var(--red); }

.field small { font-size: 0.74rem; color: var(--muted); }

.form-note {
  margin-top: 18px;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.6;
}

.form-status {
  margin-top: 16px;
  padding: 13px 16px;
  border-radius: var(--r-sm);
  font-size: 0.87rem;
  display: none;
}
.form-status.is-ok { display: block; background: #eaf7ee; border: 1px solid #b6e0c2; color: #1d6b34; }
.form-status.is-err { display: block; background: var(--red-soft); border: 1px solid #f4b8be; color: var(--red-dark); }

.hp { position: absolute; left: -9999px; opacity: 0; }

/* Carte */
.map-wrap {
  margin-top: clamp(38px, 5vw, 60px);
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  background: var(--paper);
}
.map-wrap iframe { display: block; width: 100%; height: 420px; border: 0; }

/* ---------- 25. Pied de page ---------- */
.footer {
  background: var(--ink);
  color: rgba(255, 255, 255, 0.72);
  padding-top: clamp(52px, 6vw, 78px);
  font-size: 0.89rem;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: clamp(28px, 3.4vw, 48px);
  padding-bottom: 48px;
}

@media (max-width: 900px) { .footer__grid { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); } }

.footer img.f-logo { height: 68px; width: auto; margin-bottom: 18px; }

.footer p { line-height: 1.75; color: rgba(255, 255, 255, 0.62); font-size: 0.87rem; }

.footer h4 {
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 11px;
}
.footer h4::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 28px;
  height: 2px;
  background: var(--red);
}

.footer li { margin-bottom: 11px; }
.footer li a { color: rgba(255, 255, 255, 0.62); transition: color 0.2s var(--ease), padding-left 0.2s var(--ease); }
.footer li a:hover { color: var(--red-light); padding-left: 5px; }

.footer__contact li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 11px;
  align-items: start;
  color: rgba(255, 255, 255, 0.62);
}
.footer__contact svg { width: 15px; height: 15px; color: var(--red); margin-top: 5px; }
.footer__contact a { display: block; }

.footer__bar {
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  padding-block: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.45);
}

.footer__bar nav { display: flex; flex-wrap: wrap; gap: 18px; }
.footer__bar a:hover { color: var(--red-light); }

/* ---------- 26. Boutons flottants ---------- */
.floaters {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.float {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
  border: 0;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.float:hover { transform: translateY(-4px) scale(1.06); }
.float svg { width: 24px; height: 24px; }

.float--wa { background: #25d366; }
.float--tel { background: var(--red); }

.float--top {
  background: var(--ink-3);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
}
.float--top.is-on { opacity: 1; visibility: visible; transform: translateY(0); }
.float--top svg { width: 20px; height: 20px; }

/* ---------- 27. Animations d'apparition ----------
   Les états masqués ne s'appliquent QUE si le JS a pu démarrer (classe .js
   posée en <head>). Sans JS — ou si GSAP ne charge pas — tout reste visible. */
.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  will-change: opacity, transform;
}
.reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------- 28. Impression ---------- */
@media print {
  .header, .floaters, .cta, .footer__bar nav, .scroll-cue,
  .preloader, .grain, .cursor, .scroll-progress, .page-curtain { display: none !important; }
  body { color: #000; }
  .section--dark, .info-card, .footer { background: #fff !important; color: #000 !important; }
}


/* ════════════════════════════════════════════════════════════
   29. COUCHE CINÉMATIQUE
   Défilement inertiel (Lenis) + animations pilotées au scroll (GSAP).
   Tous les états masqués sont préfixés par .js : sans JavaScript,
   ou si GSAP ne se charge pas, la page reste entièrement lisible.
   ════════════════════════════════════════════════════════════ */

/* ---------- 29.1 Défilement inertiel ---------- */
html.lenis,
html.lenis body { height: auto; }

.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

/* ---------- 29.2 Écran de chargement ---------- */
/* Masqué par défaut : n'apparaît que si la couche d'animation est active,
   pour ne jamais bloquer la page si le JavaScript ne démarre pas. */
.preloader { display: none; }

.js .preloader {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.preloader__panel {
  position: absolute;
  left: 0;
  right: 0;
  height: 50.5%;
  background: var(--ink);
}
.preloader__panel--t { top: 0; }
.preloader__panel--b { bottom: 0; }

.preloader__inner {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
}

.preloader__logo {
  height: 84px;
  width: auto;
  opacity: 0;
}

.preloader__bar {
  position: relative;
  width: min(300px, 58vw);
  height: 2px;
  background: rgba(255, 255, 255, 0.14);
  overflow: hidden;
}

.preloader__bar i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: var(--red);
  box-shadow: 0 0 16px rgba(231, 24, 43, 0.8);
}

.preloader__meta {
  display: flex;
  justify-content: space-between;
  width: min(300px, 58vw);
  font-family: var(--font-head);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.42);
}

.preloader__pct { color: var(--red); }

body.is-loading { overflow: hidden; }

/* ---------- 29.3 Grain de pellicule ---------- */
.grain {
  position: fixed;
  top: -60%;
  left: -60%;
  width: 220%;
  height: 220%;
  z-index: 94;
  pointer-events: none;
  opacity: 0.032;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/></filter><rect width='240' height='240' filter='url(%23n)'/></svg>");
  animation: grainShift 6s steps(8) infinite;
}

@keyframes grainShift {
  0%   { transform: translate(0, 0); }
  12%  { transform: translate(-4%, -3%); }
  25%  { transform: translate(-8%, 4%); }
  37%  { transform: translate(3%, -6%); }
  50%  { transform: translate(-2%, 7%); }
  62%  { transform: translate(-7%, 2%); }
  75%  { transform: translate(5%, 5%); }
  87%  { transform: translate(-3%, -5%); }
  100% { transform: translate(0, 0); }
}

/* ---------- 29.4 Barre de progression de lecture ---------- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 101;
  pointer-events: none;
  background: rgba(255, 255, 255, 0.07);
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}
.scroll-progress.is-on { opacity: 1; }

.scroll-progress i {
  display: block;
  height: 100%;
  width: 100%;
  transform: scaleX(0);
  transform-origin: left;
  background: linear-gradient(90deg, var(--red-dark), var(--red), var(--red-light));
  box-shadow: 0 0 12px rgba(231, 24, 43, 0.7);
}

/* ---------- 29.5 Rideau de transition entre pages ---------- */
.page-curtain {
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  background: var(--red);
  transform: scaleY(0);
  transform-origin: bottom;
}

.page-curtain::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(60% 100% at 50% 50%, rgba(0, 0, 0, 0.28), transparent 70%);
}

/* ---------- 29.6 Curseur personnalisé (pointeur fin uniquement) ---------- */
.cursor { display: none; }

@media (pointer: fine) {
  .js .cursor {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 998;
    pointer-events: none;
    mix-blend-mode: difference;
  }

  .cursor__dot,
  .cursor__ring {
    position: absolute;
    top: 0;
    left: 0;
    border-radius: 50%;
    transform: translate(-50%, -50%);
  }

  .cursor__dot {
    width: 7px;
    height: 7px;
    background: #fff;
  }

  .cursor__ring {
    width: 38px;
    height: 38px;
    border: 1px solid rgba(255, 255, 255, 0.55);
    transition: width 0.28s var(--ease), height 0.28s var(--ease),
      border-color 0.28s var(--ease), background 0.28s var(--ease);
  }

  .cursor.is-hot .cursor__ring {
    width: 64px;
    height: 64px;
    border-color: transparent;
    background: rgba(255, 255, 255, 0.22);
  }

  .cursor.is-hot .cursor__dot { opacity: 0; }
}

/* ---------- 29.7 Révélation de texte ligne par ligne ---------- */
.line-mask {
  display: block;
  overflow: hidden;
  padding-bottom: 0.08em;
  margin-bottom: -0.08em;
}

.js .line-in {
  display: block;
  transform: translateY(105%);
  will-change: transform;
}

/* Découpage par mot (titres) */
.w-mask {
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
  padding-bottom: 0.06em;
  margin-bottom: -0.06em;
}

.js .w-in {
  display: inline-block;
  transform: translateY(104%);
  will-change: transform;
}

/* ---------- 29.8 Révélation d'image par volet ---------- */
.img-reveal {
  position: relative;
  overflow: hidden;
}

.js .img-reveal > img,
.js .img-reveal > picture > img { transform: scale(1.18); will-change: transform; }

/* Volet rouge injecté par le JS (absent si le JS ne tourne pas) */
.img-reveal__veil {
  position: absolute;
  inset: 0;
  z-index: 3;
  background: var(--red);
  transform: scaleX(1);
  transform-origin: left;
  pointer-events: none;
}

/* ---------- 29.9 Parallaxe ---------- */
[data-parallax] { will-change: transform; }

.parallax-wrap {
  overflow: hidden;
  position: relative;
}

.parallax-wrap > img {
  width: 100%;
  height: 118%;
  object-fit: cover;
  position: absolute;
  top: -9%;
  left: 0;
}

/* ---------- 29.10 Hero cinématique ---------- */
.hero__media img { will-change: transform; }

/* Halo lumineux qui pulse derrière le titre */
.hero__glow {
  position: absolute;
  left: 50%;
  top: 52%;
  width: min(1100px, 92vw);
  height: min(560px, 60vh);
  transform: translate(-50%, -50%);
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(50% 50% at 50% 50%, rgba(231, 24, 43, 0.20), transparent 72%);
  filter: blur(30px);
  animation: glowPulse 7s ease-in-out infinite;
}

@keyframes glowPulse {
  0%, 100% { opacity: 0.55; transform: translate(-50%, -50%) scale(1); }
  50%      { opacity: 1;    transform: translate(-50%, -50%) scale(1.12); }
}

/* Barres lumineuses qui balaient le bandeau rouge */
.hero__strip { overflow: hidden; }

.hero__strip::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 45%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.16), transparent);
  animation: sweep 6s var(--ease) infinite;
}

@keyframes sweep {
  0%   { left: -50%; }
  60%  { left: 110%; }
  100% { left: 110%; }
}

/* ---------- 29.11 Vitrine horizontale épinglée (5 domaines) ---------- */
.showcase { position: relative; background: var(--ink); color: #fff; overflow: hidden; }

.showcase__head {
  padding-top: clamp(64px, 9vw, 118px);
  padding-bottom: clamp(30px, 4vw, 48px);
}

.showcase__viewport { position: relative; padding-bottom: clamp(64px, 9vw, 110px); }

/* Sans JavaScript, la piste ne peut pas défiler horizontalement : elle passe
   à la ligne pour que les 5 domaines restent tous accessibles. Le mode
   horizontal épinglé n'est activé que lorsque l'animation tourne. */
.showcase__track {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(18px, 2.2vw, 30px);
  padding-inline: var(--pad);
}

.js .showcase__track {
  flex-wrap: nowrap;
  justify-content: flex-start;
}

/* Repères décoratifs propres au défilement horizontal */
.showcase__rail,
.showcase__hint { display: none; }

.js .showcase__rail { display: block; }
.js .showcase__hint { display: flex; }

.panel {
  position: relative;
  flex: 0 0 clamp(280px, 30vw, 430px);
  aspect-ratio: 3 / 4;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--ink-2);
  border: 1px solid var(--line-dark);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  isolation: isolate;
  transition: border-color 0.4s var(--ease);
}

.panel:hover { border-color: var(--red); }

.panel__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.panel__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.9s var(--ease);
  filter: saturate(0.85);
}

.panel:hover .panel__bg img { transform: scale(1.07); }

.panel__bg--plain {
  background: linear-gradient(160deg, #1b1114 0%, var(--ink) 55%, var(--red-dark) 145%);
}

.panel__bg--plain::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(80% 70% at 70% 20%, #000, transparent 75%);
  -webkit-mask-image: radial-gradient(80% 70% at 70% 20%, #000, transparent 75%);
}

.panel__scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(to top, rgba(8, 8, 8, 0.96) 6%, rgba(8, 8, 8, 0.72) 42%, rgba(8, 8, 8, 0.18) 100%);
}

.panel__no {
  position: absolute;
  top: 18px;
  right: 22px;
  font-family: var(--font-head);
  font-size: 3.2rem;
  font-weight: 800;
  line-height: 1;
  color: rgba(255, 255, 255, 0.14);
  letter-spacing: -0.04em;
}

.panel__body { padding: 26px 24px 26px; }

.panel__icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  background: var(--red);
  color: #fff;
  border-radius: var(--r-sm);
  margin-bottom: 16px;
  transition: transform 0.4s var(--ease);
}
.panel:hover .panel__icon { transform: rotate(-8deg) scale(1.08); }
.panel__icon svg { width: 22px; height: 22px; }

.panel h3 {
  font-size: 1.02rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 10px;
}

.panel p {
  font-size: 0.85rem;
  line-height: 1.62;
  color: rgba(255, 255, 255, 0.72);
}

.panel .tags { margin-top: 16px; }

.panel__link {
  position: absolute;
  inset: 0;
  z-index: 4;
}

/* Indicateur de progression de la vitrine */
.showcase__rail {
  position: relative;
  height: 2px;
  margin: 30px var(--pad) 0;
  background: rgba(255, 255, 255, 0.12);
}

.showcase__rail i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 22%;
  background: var(--red);
  transform-origin: left;
}

.showcase__hint {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px var(--pad) 0;
  font-family: var(--font-head);
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
}

.showcase__hint svg { width: 22px; height: 12px; }

/* Repli vertical : mobile / tablette / mouvement réduit */
@media (max-width: 900px) {
  .showcase__track,
  .js .showcase__track {
    flex-direction: column;
    flex-wrap: nowrap;
    gap: 20px;
  }
  .panel { flex: none; width: 100%; aspect-ratio: 4 / 5; }
  .showcase__rail,
  .showcase__hint,
  .js .showcase__rail,
  .js .showcase__hint { display: none; }
}

/* ---------- 29.12 Bandeau défilant (ticker) ---------- */
.ticker {
  position: relative;
  overflow: hidden;
  background: var(--ink-2);
  border-block: 1px solid var(--line-dark);
  padding-block: 20px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.ticker--light {
  background: var(--paper);
  border-color: var(--line);
}

.ticker__track {
  display: flex;
  width: max-content;
  will-change: transform;
}

.ticker__group {
  display: flex;
  align-items: center;
  flex: none;
}

.ticker__item {
  display: inline-flex;
  align-items: center;
  gap: 22px;
  padding-inline: 22px;
  font-family: var(--font-head);
  font-size: clamp(0.82rem, 1.5vw, 1.05rem);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.58);
  white-space: nowrap;
}

.ticker--light .ticker__item { color: var(--muted); }

.ticker__item::after {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--red);
  flex: none;
}

/* ---------- 29.13 Boutons magnétiques ---------- */
@media (pointer: fine) {
  .btn { will-change: transform; }
}

/* ---------- 29.14 Compteurs ---------- */
.stat__num span[data-count] { font-variant-numeric: tabular-nums; }

/* ---------- 29.15 Entrée d'en-tête ---------- */
.js .header { will-change: transform; }

/* ---------- 29.16 Bandeau citation cinématique ---------- */
.filmquote {
  position: relative;
  background: var(--ink);
  color: #fff;
  overflow: hidden;
  padding-block: clamp(72px, 11vw, 150px);
}

.filmquote__bg {
  position: absolute;
  inset: -12% 0;
  z-index: 0;
}

.filmquote__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.28;
  filter: grayscale(0.35);
}

.filmquote::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(70% 90% at 50% 50%, transparent 10%, rgba(8, 8, 8, 0.86) 78%),
    linear-gradient(to bottom, var(--ink), transparent 22%, transparent 78%, var(--ink));
}

.filmquote > .wrap { position: relative; z-index: 2; text-align: center; }

.filmquote blockquote {
  font-family: var(--font-head);
  font-size: clamp(1.3rem, 3.2vw, 2.5rem);
  font-weight: 700;
  line-height: 1.32;
  letter-spacing: -0.02em;
  max-width: 26ch;
  margin-inline: auto;
}

.filmquote cite {
  display: block;
  margin-top: 26px;
  font-family: var(--font-head);
  font-size: 0.68rem;
  font-style: normal;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--red-light);
}

.filmquote__mark {
  font-size: clamp(3rem, 8vw, 6rem);
  line-height: 0.6;
  color: var(--red);
  display: block;
  margin-bottom: 18px;
}

/* ---------- 29.17 Accessibilité : mouvement réduit ---------- */
@media (prefers-reduced-motion: reduce) {
  .grain,
  .hero__glow,
  .hero__strip::after { animation: none; }

  .js .line-in,
  .js .w-in { transform: none; }

  .js .img-reveal::after { transform: scaleX(0); }
  .js .img-reveal > img { transform: none; }

  .cursor { display: none !important; }
}
