/* ==========================================================================
   Latinea — feuille de styles partagée (base, en-tête, pied de page, motion)
   Reprise à l'identique du rendu produit par le runtime Claude Design.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Jetons
   -------------------------------------------------------------------------- */
:root {
  --charbon: #0C0C0B;
  --creme: #F2EBDD;
  --dore: #C9A84C;

  /* Police des grands titres : Outfit Black, comme le rend le site
     aujourd'hui. Pour basculer en Poppins Black, changer ces deux lignes
     et remplacer Outfit par Poppins dans le <link> Google Fonts des pages. */
  --font-display: 'Outfit', sans-serif;
  --font-display-weight: 900;

  /* Police des intitulés secondaires (h3/h4 sans police explicite).
     Héritée de l'ancien design system, conservée volontairement. */
  --font-heading: 'Archivo', system-ui, sans-serif;
  --font-heading-weight: 800;

  --ease-doux: cubic-bezier(.16, 1, .3, 1);

  /* Fonds des surfaces posées — dégradés complets, un par rôle et par état.
     Valeurs reprises telles quelles d'accueil.css, sans fusion. */
  --fond-carte: linear-gradient(158deg, #1C1A18 0%, #121110 100%);
  --fond-carte-survol: linear-gradient(158deg, #221F1B 0%, #151413 100%);
  --fond-feature: linear-gradient(158deg, #1B1918 0%, #111110 100%);

  /* Durées — trois paliers.
     Court : couleurs et opacité. Moyen : transform, ombre, filtre.
     Long : apparitions au scroll et entrées de page. */
  --t-court: .55s;
  --t-moyen: .7s;
  --t-long: 1.25s;

  /* Espacements — les clamp() répétés du gabarit. */
  --espace-horizontal: clamp(18px, 4vw, 56px);
  --espace-section: clamp(80px, 10vw, 168px);
  --espace-sous-titre: clamp(36px, 5vw, 64px);
  --hauteur-entete: 88px;

  /* Arrondis. */
  --arrondi-pilule: 999px;
  --arrondi-carte: 28px;
  --arrondi-media: 22px;

  /* Dégradés récurrents. */
  --degrade-sombre: linear-gradient(180deg, #0A0A09 0%, #141312 52%, #0B0B0A 100%);

  /* Position par défaut du halo de section. */
  --position-halo: 22% 18%;
}

/* Le halo de section se déplace d'une section à l'autre : redéfinir
   --position-halo sur la section suffit, --degrade-section suit.
   La recette ne peut pas vivre dans :root pour autant : une custom property
   est substituée sur l'élément qui la déclare, donc écrite dans :root elle
   y figerait le halo à sa valeur globale, et les sections hériteraient d'un
   dégradé déjà résolu. Déclarée ici, chaque <section> — et le <header>
   d'en-tête de page — résout sa propre --position-halo. */
section,
header {
  --degrade-section: radial-gradient(115% 78% at var(--position-halo), #171614 0%, #121110 42%, var(--charbon) 100%);
}

/* --------------------------------------------------------------------------
   2. Base
   -------------------------------------------------------------------------- */
/* Socle repris de la feuille du design system supprimé : le site en héritait
   sans que ce soit visible dans le markup (interlignes, box-sizing, marges
   par défaut). Sans ces règles, la mise en page bouge. */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  font-weight: 400;
  background-color: var(--charbon);
  background-image: radial-gradient(120% 60% at 50% -10%, rgba(242, 235, 221, .055) 0%, rgba(12, 12, 11, 0) 60%);
  background-attachment: fixed;
  color: var(--creme);
  font-family: 'Poppins', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  line-height: 1.12;
  letter-spacing: -.015em;
  margin: 0 0 8px;
}

p {
  margin: 0 0 12px;
}

figure {
  margin: 0;
}

:focus {
  outline: none;
}

img,
svg,
video,
table {
  max-width: 100%;
}

img {
  display: block;
}

a {
  color: var(--creme);
  text-decoration: none;
}

a:hover {
  color: var(--dore);
}

::selection {
  background: var(--dore);
  color: #101010;
}

*:focus-visible {
  outline: 2px solid var(--dore);
  outline-offset: 3px;
}

/* Transition commune. Remplace le sélecteur [style*="border-radius"] de
   l'original, qui ne fonctionnait qu'avec des styles en ligne. */
a,
button,
article,
input,
textarea,
select,
.btn,
.card,
.card__media,
.feature,
.phone,
.phone__screen,
.studio__media,
.nav-burger,
.app-btn,
.app-btn__ring,
.app-btn__halo,
.event__media,
.course__media,
.contact-media,
.planning__shell,
.field-input {
  transition:
    background-color .55s var(--ease-doux),
    color .55s var(--ease-doux),
    border-color .55s var(--ease-doux),
    transform .7s var(--ease-doux),
    box-shadow .7s var(--ease-doux),
    filter .7s var(--ease-doux),
    opacity .55s var(--ease-doux);
}

/* --------------------------------------------------------------------------
   3. Éléments de texte récurrents
   -------------------------------------------------------------------------- */
.eyebrow {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--dore);
  margin-bottom: 24px;
}

.eyebrow--hero {
  letter-spacing: .28em;
  margin-bottom: 22px;
}

.eyebrow--tight {
  letter-spacing: .22em;
  margin-bottom: 18px;
}

.section-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: var(--font-display-weight);
  font-size: clamp(28px, 3.5vw, 52px);
  line-height: 1.06;
  letter-spacing: -.01em;
  text-transform: uppercase;
}

/* Un seul titre de l'original portait un interlettrage positif. */
.section-title--wide {
  letter-spacing: .01em;
}

/* --------------------------------------------------------------------------
   4. Boutons
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  border-radius: 999px;
}

.btn--cream {
  padding: 11px 26px;
  background: linear-gradient(180deg, #FBF6EC 0%, #EFE7D8 100%);
  color: #101010;
  box-shadow: 0 16px 44px rgba(242, 235, 221, .16), 0 6px 20px rgba(201, 168, 76, .14);
}

.btn--cream:hover {
  background: #C9A84C;
  color: #101010;
  box-shadow: 0 20px 58px rgba(201, 168, 76, .38);
  transform: translateY(-2px);
}

.btn--outline {
  padding: 11px 26px;
  border: 1px solid rgba(242, 235, 221, .45);
}

.btn--outline:hover {
  background: rgba(242, 235, 221, .1);
  border-color: var(--creme);
  box-shadow: 0 16px 46px rgba(242, 235, 221, .12);
  transform: translateY(-2px);
  color: var(--creme);
}

.btn--dark {
  padding: 12px 30px;
  background: #121110;
  color: var(--creme);
  box-shadow: 0 18px 44px rgba(16, 16, 16, .35);
}

.btn--dark:hover {
  background: var(--dore);
  color: #101010;
  box-shadow: 0 20px 58px rgba(201, 168, 76, .4);
  transform: translateY(-2px);
}

/* --------------------------------------------------------------------------
   5. Emplacements photo
   -------------------------------------------------------------------------- */
.slot {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slot--empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  box-sizing: border-box;
  text-align: center;
  background: rgba(127, 127, 127, .08);
  font: 13px/1.3 system-ui, -apple-system, sans-serif;
  color: inherit;
}

.slot--empty > * {
  opacity: .75;
}

.slot__icon {
  width: 22px;
  height: 22px;
  flex: none;
}

/* Zoom au survol des visuels dans une carte cliquable */
a .slot,
article .slot {
  transition: transform 1.2s var(--ease-doux);
}

a:hover .slot,
article:hover .slot {
  transform: scale(1.06);
}

/* --------------------------------------------------------------------------
   6. En-tête
   -------------------------------------------------------------------------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 16px;
  height: 88px;
  /* Était `hidden` : rien ne dépassait de la barre, la règle ne coupait donc
     rien. Le panneau du menu « Nos cours » s'ouvre sous la barre et doit en
     sortir — il est le premier élément à avoir besoin de ce `visible`. */
  overflow: visible;
  padding: 0 clamp(16px, 3.4vw, 48px);
  background: linear-gradient(180deg, rgba(12, 12, 11, .92) 0%, rgba(12, 12, 11, .72) 100%);
  backdrop-filter: blur(18px) saturate(120%);
  border-bottom: 1px solid rgba(242, 235, 221, .09);
  box-shadow: 0 18px 44px rgba(0, 0, 0, .45);
  box-sizing: border-box;
}

.nav-links-cell {
  display: flex;
  flex: 1 1 0;
  min-width: 0;
  align-items: center;
  justify-content: flex-start;
  gap: clamp(18px, 2.6vw, 36px);
}

.nav-desktop {
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.4vw, 32px);
}

.nav-item {
  position: relative;
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: rgba(242, 235, 221, .62);
  padding: 6px 0;
  border-bottom: 1px solid transparent;
}

.nav-item::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--dore);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .6s var(--ease-doux);
}

.nav-item:hover::after {
  transform: scaleX(1);
}

.nav-item.is-active {
  color: var(--creme);
  border-bottom-color: var(--dore);
}

.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 34px;
  background: none;
  border: 1px solid rgba(242, 235, 221, .22);
  border-radius: 999px;
  cursor: pointer;
  padding: 0 11px;
}

.nav-burger span {
  display: block;
  height: 1.5px;
  background: var(--creme);
  transition: transform .55s var(--ease-doux), opacity .45s var(--ease-doux);
}

.nav-burger[aria-expanded="true"] span:first-child {
  transform: translateY(3.5px) rotate(45deg);
}

.nav-burger[aria-expanded="true"] span:last-child {
  transform: translateY(-3.5px) rotate(-45deg);
}

.nav-logo-cell {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 0;
}

.nav-logo {
  display: block;
  /* Légèrement agrandi (64 → 70). Le logo est une image : seule la taille
     bouge, la drop-shadow garde son rayon d'origine pour que le halo ne
     s'épaississe pas avec lui. */
  height: 70px;
  width: auto;
  max-width: min(40vw, 240px);
  object-fit: contain;
  filter: drop-shadow(0 0 34px rgba(201, 168, 76, .22));
}

.nav-app-cell {
  position: relative;
  display: flex;
  flex: 1 1 0;
  min-width: 0;
  align-items: center;
  justify-content: flex-end;
}

/* --------------------------------------------------------------------------
   6bis. Menu déroulant « Nos cours » — sans JavaScript

   Bureau : le panneau s'ouvre au survol du bloc, et reste ouvert tant qu'un
   de ses éléments a le focus. Le clic sur le bouton donne ce focus, un clic
   ailleurs le retire : on obtient l'ouverture au clic et la fermeture au
   clic extérieur sans une ligne de script.
   Mobile : c'est le <details> du menu burger (chapitre 8) qui prend le relais.
   -------------------------------------------------------------------------- */
.nav-dd {
  position: relative;
  display: flex;
  align-items: center;
}

/* Le bouton porte aussi .nav-item : seules les valeurs propres au <button>
   sont remises à zéro ici, le dessin vient de .nav-item. */
.nav-dd__toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: 0;
  border-bottom: 1px solid transparent;
  padding: 6px 0;
  font-family: inherit;
  cursor: pointer;
}

.nav-dd__chev,
.nav-sub__chev {
  display: block;
  flex: none;
  transition: transform var(--t-moyen) var(--ease-doux);
}

.nav-dd:hover .nav-dd__chev,
.nav-dd:focus-within .nav-dd__chev {
  transform: rotate(180deg);
}

.nav-dd__panel {
  position: absolute;
  top: calc(100% + 18px);
  left: 50%;
  translate: -50% 0;
  z-index: 210;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 236px;
  padding: 10px;
  background: var(--fond-carte);
  border: 1px solid rgba(242, 235, 221, .12);
  border-radius: var(--arrondi-carte);
  box-shadow:
    0 30px 64px rgba(0, 0, 0, .55),
    inset 0 1px 0 rgba(242, 235, 221, .07);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition:
    opacity var(--t-court) var(--ease-doux),
    transform var(--t-moyen) var(--ease-doux),
    visibility var(--t-court) var(--ease-doux);
}

.nav-dd:hover .nav-dd__panel,
.nav-dd:focus-within .nav-dd__panel {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.nav-dd__link {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px 14px;
  border-radius: var(--arrondi-media);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(242, 235, 221, .78);
}

a.nav-dd__link:hover {
  background: rgba(242, 235, 221, .07);
  color: var(--dore);
}

/* --------------------------------------------------------------------------
   7. Bouton « app » — coque fixe, bille de lumière qui tourne, lueur statique
   -------------------------------------------------------------------------- */
.app-btn-wrap {
  position: relative;
  display: inline-flex;
}

.app-btn {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 20px;
  color: var(--creme);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  border-radius: 999px;
  white-space: nowrap;
  background-color: #161611C4;
  isolation: isolate;
  border: 1px solid rgba(242, 235, 221, .30);
}

.app-btn:hover {
  color: var(--creme);
  border-color: rgba(242, 235, 221, .62);
}

.app-btn__label {
  position: relative;
  z-index: 2;
}

.app-btn__ring {
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: 999px;
  overflow: hidden;
  pointer-events: none;
  -webkit-mask: linear-gradient(#000, #000) content-box, linear-gradient(#000, #000);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000, #000) content-box, linear-gradient(#000, #000);
  mask-composite: exclude;
  padding: 1.5px;
}

.app-btn__ring::before {
  content: "";
  position: absolute;
  z-index: 0;
  left: 50%;
  top: 50%;
  width: 260%;
  aspect-ratio: 1;
  translate: -50% -50%;
  border-radius: 999px;
  background: conic-gradient(from 0deg,
      rgba(242, 235, 221, 0) 0deg,
      rgba(242, 235, 221, 0) 262deg,
      rgba(201, 168, 76, .85) 316deg,
      #F2EBDD 344deg,
      rgba(237, 228, 211, .9) 352deg,
      rgba(242, 235, 221, 0) 360deg);
  animation: latBeam 3.6s linear infinite;
}

.app-btn-wrap:hover .app-btn__ring::before {
  animation-duration: 2.1s;
}

.app-btn__halo {
  position: absolute;
  z-index: 0;
  inset: -10px;
  border-radius: 999px;
  pointer-events: none;
  background: radial-gradient(62% 62% at 50% 50%, rgba(242, 235, 221, .14) 0%, rgba(201, 168, 76, .1) 48%, rgba(201, 168, 76, 0) 78%);
  filter: blur(13px);
}

@keyframes latBeam {
  to { transform: rotate(1turn); }
}

/* Le libellé se raccourcit sous 620px (comportement JS d'origine) */
.app-btn__label--short { display: none; }

@media (max-width: 619.98px) {
  .app-btn__label--full { display: none; }
  .app-btn__label--short { display: inline; }
}

/* --------------------------------------------------------------------------
   8. Menu mobile
   -------------------------------------------------------------------------- */
.nav-menu {
  position: fixed;
  inset: 88px 0 auto 0;
  z-index: 190;
  background: #0E0E0E;
  border-bottom: 1px solid rgba(242, 235, 221, .14);
  padding: 12px clamp(18px, 4vw, 56px) 28px;
  display: none;
  flex-direction: column;
  box-sizing: border-box;
  animation: latMenuIn .6s var(--ease-doux) both;
}

.nav-menu.is-open {
  display: flex;
}

/* Les entrées ne sont plus toutes des liens : « Nos cours » est un <details>.
   Le dessin et la cascade portent donc sur tous les enfants directs. */
.nav-menu > a,
.nav-menu > .nav-sub > .nav-sub__toggle {
  padding: 16px 0;
  font-family: var(--font-display);
  font-weight: var(--font-display-weight);
  font-size: 24px;
  letter-spacing: 0;
  text-transform: uppercase;
}

.nav-menu > * {
  border-bottom: 1px solid rgba(242, 235, 221, .1);
  animation: latFadeUp .8s var(--ease-doux) both;
}

.nav-menu > *:last-child {
  border-bottom: 0;
}

.nav-menu > *:nth-child(1) { animation-delay: .05s; }
.nav-menu > *:nth-child(2) { animation-delay: .13s; }
.nav-menu > *:nth-child(3) { animation-delay: .21s; }
.nav-menu > *:nth-child(4) { animation-delay: .29s; }
.nav-menu > *:nth-child(5) { animation-delay: .37s; }
/* Sixième entrée (Contact) : la cascade continue au même pas de .08s. */
.nav-menu > *:nth-child(6) { animation-delay: .45s; }

/* Sous-liste dépliable « Nos cours » — <details> natif, sans JavaScript. */
.nav-sub__toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
  list-style: none;
}

.nav-sub__toggle::-webkit-details-marker {
  display: none;
}

.nav-sub[open] .nav-sub__chev {
  transform: rotate(180deg);
}

.nav-sub__list {
  display: flex;
  flex-direction: column;
  padding: 0 0 16px 16px;
  border-left: 1px solid rgba(242, 235, 221, .14);
  margin-left: 2px;
  animation: latFadeUp .8s var(--ease-doux) both;
}

.nav-sub__link {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 11px 0;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: rgba(242, 235, 221, .72);
}

@keyframes latMenuIn {
  from { opacity: 0; transform: translateY(-14px); }
  to   { opacity: 1; transform: none; }
}

/* --------------------------------------------------------------------------
   9. Apparitions au scroll, parallaxe, entrée du hero
   -------------------------------------------------------------------------- */
.js-reveal [data-reveal] {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity 1.25s var(--ease-doux), transform 1.25s var(--ease-doux);
  transition-delay: var(--rd, 0ms);
  will-change: opacity, transform;
}

[data-reveal].is-in {
  opacity: 1;
  transform: none;
}

[data-reveal] svg {
  transition: transform .6s var(--ease-doux);
}

[data-reveal]:hover svg {
  transform: translateY(-3px) scale(1.08);
}

@keyframes latFadeUp {
  from { opacity: 0; transform: translateY(36px); }
  to   { opacity: 1; transform: none; }
}

[data-hero-copy] > * {
  animation: latFadeUp 1.35s var(--ease-doux) both;
}

[data-hero-copy] > *:nth-child(1) { animation-delay: .15s; }
[data-hero-copy] > *:nth-child(2) { animation-delay: .34s; }
[data-hero-copy] > *:nth-child(3) { animation-delay: .53s; }
[data-hero-copy] > *:nth-child(4) { animation-delay: .72s; }

@keyframes latKenBurns {
  from { transform: scale(1); }
  to   { transform: scale(1.05); }
}

[data-parallax] .slot {
  display: block;
  width: 100%;
  height: 100%;
  animation: latKenBurns 18s cubic-bezier(.37, 0, .63, 1) infinite alternate;
}

/* --------------------------------------------------------------------------
   10. Pied de page
   -------------------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid rgba(242, 235, 221, .08);
  background: linear-gradient(180deg, #0A0A09 0%, #141312 52%, #0B0B0A 100%);
  padding: clamp(48px, 6vw, 88px) clamp(18px, 4vw, 56px) 32px;
}

.footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: clamp(32px, 4vw, 64px);
  align-items: start;
}

.footer__col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer__col--brand {
  gap: 16px;
}

.footer__col--app {
  gap: 16px;
  align-items: flex-start;
}

.footer__logo {
  display: block;
  height: 61px;
  width: 158px;
  max-width: 112%;
  object-fit: contain;
}

.footer__tagline {
  margin: 0;
  max-width: 26ch;
  font-size: 14px;
  line-height: 1.7;
  color: rgba(242, 235, 221, .55);
}

.footer__tagline--app {
  max-width: 24ch;
}

.footer__heading {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--dore);
}

.footer__link,
.footer__text {
  font-size: 14px;
  color: rgba(242, 235, 221, .7);
}

.footer__bottom {
  margin-top: clamp(36px, 5vw, 64px);
  padding-top: 22px;
  border-top: 1px solid rgba(242, 235, 221, .12);
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  font-size: 12px;
  letter-spacing: .06em;
  color: rgba(242, 235, 221, .42);
}

.footer__legal {
  display: flex;
  gap: 22px;
}

.footer__legal a {
  color: rgba(242, 235, 221, .42);
}

/* --------------------------------------------------------------------------
   11. Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 620px) {
  .nav-logo { height: 38px; }
}

/* Bascule bureau / burger (seuil JS d'origine : innerWidth < 1080) */
@media (max-width: 1079.98px) {
  .nav-desktop { display: none; }
  .nav-burger { display: flex; }
}

@media (min-width: 1081px) {
  .nav-logo-cell {
    order: -1;
    flex: 1 1 0;
    justify-content: flex-start;
  }
  .nav-links-cell {
    flex: 0 1 auto;
    justify-content: center;
  }
}

/* Les classes sont doublées (.grid-3.grid-3) pour que ces surcharges
   l'emportent sur les feuilles de page chargées après celle-ci — l'équivalent
   du !important qu'utilisait l'original, sans en abuser. */
@media (max-width: 1080px) {
  .grid-3.grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-studio.grid-studio,
  .grid-app.grid-app { grid-template-columns: minmax(0, 1fr); }
  .grid-studio.grid-studio > *:last-child {
    justify-self: start;
    margin-top: 0;
  }

  /* KPI : 2 par ligne dès la tablette, et jusqu'au mobile (aucun palier
     intermédiaire ne les remet sur une ligne). Gap repris de celui déjà
     utilisé par les grilles de ce fichier. */
  .stats.stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(20px, 2.8vw, 32px);
  }
}

/* --- TABLETTE (768–1024px) --- */
@media (min-width: 768px) and (max-width: 1024px) {
  .grid-studio.grid-studio,
  .grid-app.grid-app {
    grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr);
    gap: clamp(28px, 4vw, 48px);
    align-items: center;
    max-width: 900px;
    margin: 0 auto;
  }
  .grid-studio.grid-studio > *:last-child,
  .grid-app.grid-app > *:last-child {
    justify-self: stretch;
    margin-top: 0;
  }
  .grid-3.grid-3:not(.grid-3--tablet),
  .grid-2.grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(20px, 2.8vw, 32px);
    max-width: 860px;
    margin-left: auto;
    margin-right: auto;
  }
  .grid-3--tablet.grid-3--tablet {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(18px, 2.4vw, 28px);
    max-width: 900px;
  }
}

@media (max-width: 860px) {
  .hero.hero {
    height: 62svh;
    min-height: 400px;
  }
  .hero__copy.hero__copy {
    padding-top: calc(88px + clamp(28px, 8vw, 44px));
    padding-bottom: clamp(28px, 8vw, 44px);
  }
}

/* L'original pilotait ce palier avec des sélecteurs d'éléments en
   !important, pour passer par-dessus les styles en ligne. On garde la même
   mécanique : ces règles doivent gagner sur les classes de page.

   CAUSE DU BUG MOBILE : ce palier s'arrêtait à 720px alors que le palier
   tablette démarre à 768px. Entre 721 et 767px, aucune des deux séries ne
   s'appliquait : les grilles retombaient sur le palier 1080 (2 colonnes) ou
   sur le desktop. Le plafond passe donc à 767.98px, soit le complément exact
   du seuil 768 déjà en place — aucun nouveau seuil n'est introduit et la
   tablette (768–1024) ne bouge pas. */
@media (max-width: 767.98px) {
  .grid-3.grid-3,
  .grid-2.grid-2,
  .grid-3--tablet.grid-3--tablet { grid-template-columns: minmax(0, 1fr); }

  header,
  section {
    padding-left: 20px !important;
    padding-right: 20px !important;
  }

  section {
    padding-top: clamp(48px, 12vw, 72px) !important;
    padding-bottom: clamp(48px, 12vw, 72px) !important;
  }

  h1 {
    font-size: clamp(30px, 9.4vw, 44px) !important;
    line-height: 1.08 !important;
  }

  h2 {
    font-size: clamp(24px, 7.4vw, 34px) !important;
    line-height: 1.12 !important;
  }

  h3 { font-size: 20px !important; }

  p, li, td { text-wrap: pretty; }

  /* L'original neutralisait toutes les largeurs en ligne (son sélecteur
     [style*="width:"] attrapait aussi les max-width exprimées en ch). */
  .u-measure.u-measure {
    width: auto;
    max-width: 100%;
    height: auto;
    min-height: 0;
  }

  /* Le bloc photo garde sa largeur : il est en justify-self:start, un
     width:auto le ferait collapser (son seul enfant est en absolute). */
  .studio__media.studio__media {
    max-width: 100%;
  }

  /* Les deux grands coins (120px) valent la moitié de la largeur du bloc sur
     écran étroit : le cadre devient un demi-cercle. On les ramène au double
     de l'arrondi de carte, la découpe asymétrique reste lisible. */
  .studio__media.studio__media {
    border-radius: calc(var(--arrondi-carte) * 2) var(--arrondi-carte);
  }

  /* Intitulé de section : le lien passe sous le titre, calé à gauche. */
  .section-head.section-head {
    flex-direction: column;
    align-items: flex-start;
  }

  /* 1 — HERO : la photo imposait une hauteur en svh (62svh ici) sans rapport
     avec le texte — bande d'image vide en haut, et boutons qui débordaient
     sous le cadre. Sur mobile le cadre suit exactement son contenu : plus de
     hauteur imposée, plus de débordement. Le rythme vertical se resserre au
     passage, notamment entre le titre et le texte. */
  .hero.hero {
    height: auto;
    min-height: 0;
    /* .hero est un <section> : il récupérait les 48px de padding vertical
       !important du palier, soit 96px de photo en plus. Le bloc de texte
       porte déjà ses propres marges, y compris le décalage d'en-tête. */
    padding-top: 0 !important;
    padding-bottom: 0 !important;
  }

  .hero__copy.hero__copy {
    /* Un peu d'air au-dessus du titre pour dégager la photo. Le bas reste
       serré : le hero ne doit pas regagner la hauteur qu'il a perdue. */
    padding-top: calc(var(--hauteur-entete) + clamp(40px, 11vw, 64px));
    padding-bottom: clamp(14px, 4vw, 22px);
  }

  .hero__lead.hero__lead { margin-top: 12px; }
  .hero__actions.hero__actions { margin-top: 20px; }

  /* 2 — STUDIO : le texte passe en premier (ordre du DOM, la grille est déjà
     en une colonne), centré, et la photo se centre en dessous au lieu de
     rester calée à gauche par le palier 1080. */
  .grid-studio.grid-studio { text-align: center; }

  .grid-studio.grid-studio > *:last-child { justify-self: center; }

  /* Section app : le bouton se centre sous la liste. .btn est en inline-flex,
     on garde ce mode d'affichage et on centre par les marges automatiques. */
  .app__cta.app__cta {
    display: flex;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
  }

  /* 3 — KPI : les trois sur une seule ligne, centrés. Le palier 1080 les
     laisse à 2 par ligne pour la tablette, ce mobile-ci les remet à 3. */
  .stats.stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(18px, 2.4vw, 28px);
    justify-items: center;
  }

  .cta__title.cta__title { white-space: normal; }
}

/* --------------------------------------------------------------------------
   12. Accessibilité — mouvement réduit
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .app-btn__ring::before {
    animation: none !important;
    background: rgba(242, 235, 221, .5) !important;
  }

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }

  .js-reveal [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }

  html { scroll-behavior: auto; }
}
