/* ==========================================================================
   MARISMA TRANS — feuille de style unique (FR / AR / EN)
   Propriétés logiques partout : une seule feuille sert le RTL. Voir design.md §4.
   ========================================================================== */

:root {
  /* Marque — voir design.md §6. Une seule couleur d'accent. Ne pas en ajouter. */
  --blue:        #3870A4;
  --blue-deep:   #2C5A84;  /* boutons pleins : AA pour texte blanc */
  --blue-dark:   #21445F;
  --blue-wash:   #EDF2F7;
  --blue-line:   #C7D7E6;

  --ink:         #1D1D1B;
  --ink-80:      #3A3A37;
  --ink-60:      #595954;
  --ink-40:      #8A8A83;

  --paper:       #FFFFFF;
  --paper-2:     #F5F7F9;
  --rule:        #DFE4E9;
  --rule-strong: #C3CBD3;

  --wa:          #0F7267;

  --sans: "IBM Plex Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;

  --measure: 68ch;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --shell: 1180px;

  --step--1: clamp(0.8rem, 0.78rem + 0.1vw, 0.85rem);
  --step-0:  clamp(1rem, 0.97rem + 0.15vw, 1.075rem);
  --step-1:  clamp(1.18rem, 1.1rem + 0.35vw, 1.4rem);
  --step-2:  clamp(1.45rem, 1.3rem + 0.7vw, 1.95rem);
  --step-3:  clamp(1.85rem, 1.55rem + 1.4vw, 2.8rem);
  --step-4:  clamp(2.3rem, 1.75rem + 2.6vw, 4rem);
}

/* L'arabe demande plus d'interligne et un corps légèrement supérieur. §5 */
:root:lang(ar), [dir="rtl"] {
  --sans: "IBM Plex Sans Arabic", "IBM Plex Sans", system-ui, sans-serif;
  --step-0: clamp(1.07rem, 1.04rem + 0.15vw, 1.15rem);
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
/* Mouvement réduit : on ne coupe pas tout. On garde les transitions de
   couleur et d'opacité, qui aident à comprendre un changement d'état, et on
   supprime tout déplacement. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-property: color, background-color, border-color, outline-color,
                         text-decoration-color, opacity !important;
    transition-duration: 160ms !important;
  }
  *:hover, *:focus, *:active { transform: none !important; }
}

body {
  margin: 0;
  font-family: var(--sans);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
[dir="rtl"] body { line-height: 1.9; }

h1, h2, h3, h4 { margin: 0; font-weight: 600; line-height: 1.15; letter-spacing: -0.015em; }
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3 { letter-spacing: 0; line-height: 1.35; }
p { margin: 0 0 1em; max-width: var(--measure); }
a { color: var(--blue-deep); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--blue-dark); }
img, svg { max-width: 100%; }

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

/* Chiffres, références, identifiants : chasse fixe, jamais de mirroring. §4 */
.num, bdi.num, .ref { font-family: var(--mono); font-variant-numeric: tabular-nums; }

.shell { max-width: var(--shell); margin-inline: auto; padding-inline: var(--gutter); }

.skip {
  position: absolute; inset-block-start: -100%; inset-inline-start: 0.5rem;
  z-index: 100; background: var(--ink); color: #fff;
  padding: 0.7rem 1.1rem; border-radius: 0 0 4px 4px; font-weight: 500;
}
.skip:focus { inset-block-start: 0; }

/* --------------------------------------------------------------- en-tête -- */

.masthead {
  position: sticky; inset-block-start: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: saturate(1.6) blur(10px);
  border-block-end: 1px solid var(--rule);
}
.masthead__inner {
  display: flex; align-items: center; gap: 1.25rem;
  min-height: 74px;
}
.lockup { display: inline-flex; align-items: center; gap: 0.75rem; text-decoration: none; color: var(--ink); }
.lockup__mark { width: 46px; color: var(--blue); flex: none; }
/* Le wordmark est du texte vivant, pas une image : corriger l'orthographe
   est une modification de texte. Montserrat = la police du fichier logo. */
.lockup__type { display: block; font-family: "Montserrat", var(--sans); line-height: 1; }
.lockup__name { display: block; font-weight: 700; font-size: 1.02rem; letter-spacing: 0.012em; }
.lockup__sub {
  display: block; margin-block-start: 0.18rem; text-align: center;
  font-weight: 400; font-size: 0.565rem; letter-spacing: 0.34em;
  text-indent: 0.34em; color: var(--ink-80);
}
@media (max-width: 400px) { .lockup__mark { width: 38px; } .lockup__name { font-size: 0.9rem; } }

.nav { margin-inline-start: auto; display: flex; align-items: center; gap: clamp(1rem, 2.2vw, 1.9rem); }
.nav a {
  font-size: 0.775rem; font-weight: 500; letter-spacing: 0.085em; text-transform: uppercase;
  text-decoration: none; color: var(--ink-80); padding-block: 0.4rem;
  border-block-end: 2px solid transparent;
}
[dir="rtl"] .nav a { letter-spacing: 0; }
.nav a:hover { color: var(--ink); border-block-end-color: var(--blue-line); }
.nav a[aria-current="page"] { color: var(--ink); border-block-end-color: var(--blue); }

.langs { display: flex; align-items: center; gap: 0.5rem; padding-inline-start: 1rem; border-inline-start: 1px solid var(--rule); }
.langs a, .langs span {
  font-size: 0.73rem; font-weight: 500; text-decoration: none; padding: 0.2rem 0.32rem; border-radius: 3px;
  border-block-end: none; color: var(--ink-80);
}
.langs a:hover { background: var(--blue-wash); color: var(--ink); border-block-end-color: transparent; }
.langs [aria-current="true"] { background: var(--ink); color: #fff; cursor: default; }
.langs [aria-current="true"]:hover { background: var(--ink); color: #fff; border-block-end-color: transparent; }
.langs [aria-disabled="true"] { color: #6B6B64; cursor: not-allowed; }

.burger {
  display: none; margin-inline-start: auto; background: none; border: 1px solid var(--rule-strong);
  border-radius: 4px; padding: 0.55rem 0.7rem; cursor: pointer; color: var(--ink);
}
.burger span { display: block; width: 19px; height: 1.5px; background: currentColor; }
.burger span + span { margin-block-start: 4.5px; }

@media (max-width: 880px) {
  .burger { display: block; }
  .nav {
    position: fixed; inset-block-start: 74px; inset-inline: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); border-block-end: 1px solid var(--rule);
    padding: 0.5rem var(--gutter) 1.25rem; margin: 0;
    box-shadow: 0 18px 40px -24px rgb(29 29 27 / 0.35);
  }
  .nav:not(.is-open) { display: none; }
  .nav a { padding-block: 0.85rem; border-block-end: 1px solid var(--rule); }
  .nav a[aria-current="page"] { border-block-end-color: var(--blue); }
  .langs { border-inline-start: 0; padding-inline-start: 0; padding-block-start: 1rem; }
  .langs a { border-block-end: none; padding-block: 0.32rem; }
}

/* ------------------------------------------------------------------ bouts -- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55rem;
  font: inherit; font-size: 0.925rem; font-weight: 500; line-height: 1;
  padding: 0.95rem 1.5rem; border-radius: 3px; border: 1px solid transparent;
  text-decoration: none; cursor: pointer;
  transition: background-color .16s ease, border-color .16s ease, color .16s ease, transform .16s ease;
}
.btn:active { transform: translateY(1px); }
.btn--solid { background: var(--blue-deep); color: #fff; }
.btn--solid:hover { background: var(--blue-dark); color: #fff; }
.btn--line { border-color: var(--rule-strong); color: var(--ink); background: var(--paper); }
.btn--line:hover { border-color: var(--blue); color: var(--blue-deep); }
.btn--ghost { color: var(--ink); background: transparent; padding-inline: 0; }
/* Sur fond encre, le bleu de marque avec du blanc plafonne à 3.04:1.
   On inverse : fond clair, texte encre. Voir design.md §6. */
.btn--invert { background: #fff; color: var(--ink); }
.btn--invert:hover { background: #E7EDF3; color: var(--ink); }
.btn--outline-dark { background: transparent; color: #fff; border-color: rgba(255,255,255,.45); }
.btn--outline-dark:hover { background: rgba(255,255,255,.14); color: #fff; border-color: #fff; }
.btn svg { width: 17px; height: 17px; flex: none; }

.btn-row { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* ----------------------------------------------------------------- bandes -- */

.band { padding-block: clamp(3.5rem, 7vw, 6rem); }
.band--tint { background: var(--paper-2); border-block: 1px solid var(--rule); }
.band--ink { background: var(--blue-dark); color: #fff; }
.band--ink p { color: #C9C9C4; }
.band--tight { padding-block: clamp(2.5rem, 5vw, 4rem); }

.eyebrow {
  display: flex; align-items: center; gap: 0.7rem;
  font-family: var(--mono); font-size: 0.7rem; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--blue-deep);
  margin-block-end: 1.1rem;
}
.eyebrow::after { content: ""; flex: 1; height: 1px; background: var(--rule); max-width: 120px; }
.band--ink .eyebrow { color: #8FB4D4; }
.band--ink .eyebrow::after { background: rgba(255,255,255,.18); }

.h-sec { font-size: var(--step-3); max-width: 20ch; }
.lede { font-size: var(--step-1); color: var(--ink-80); max-width: 56ch; line-height: 1.5; }
[dir="rtl"] .lede { line-height: 1.8; }
.band--ink .lede { color: #D6D6D1; }

/* -------------------------------------------------------------------- une -- */

.hero { position: relative; overflow: hidden; padding-block: clamp(3rem, 7vw, 6rem) clamp(3rem, 6vw, 5rem); }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.85fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: start; }
@media (max-width: 900px) { .hero__grid { grid-template-columns: 1fr; } }

.hero h1 { font-size: var(--step-4); max-width: 17ch; letter-spacing: -0.028em; }
[dir="rtl"] .hero h1 { letter-spacing: 0; }
.hero__lede { margin-block-start: 1.5rem; }

/* Motif de la marque, en fond. Identité seulement — jamais réutilisé en icône. §6 */
.hero__motif {
  position: absolute; inset-block-start: -8%; inset-inline-end: -14%;
  width: min(760px, 66vw); color: var(--blue);
  opacity: 0.055; pointer-events: none; z-index: 0;
}
/* Le motif est la marque, pas un élément d'interface : il ne se reflète jamais,
   même en RTL. Seule sa position change, via inset-inline. Voir design.md §6. */
.hero > .shell { position: relative; z-index: 1; }

/* Même traitement pour la bande FAQ, décalé plus bas. */
#faq { position: relative; overflow: hidden; }
#faq > .shell { position: relative; z-index: 1; }
#faq .hero__motif { inset-block-start: calc(-8% + 400px); }

/* fiche contact — l'appel est l'objectif du site. §9 */
.dossier { background: var(--paper); border: 1px solid var(--rule); border-radius: 4px; box-shadow: 0 24px 50px -38px rgb(29 29 27 / 0.45); }
.dossier__head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 1rem;
  padding: 0.85rem 1.25rem; background: var(--ink); color: #fff; border-radius: 3px 3px 0 0;
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase;
}
.dossier__body { padding: 1.25rem; }
.dossier dl { margin: 0; display: grid; gap: 0.9rem; }
.dossier dt {
  font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.13em;
  text-transform: uppercase; color: var(--ink-60); margin-block-end: 0.2rem;
}
.dossier dd { margin: 0; font-size: 1.02rem; }
.dossier dd a { text-decoration: none; font-weight: 500; }
.dossier dd a:hover { text-decoration: underline; }
.dossier__foot { padding: 1rem 1.25rem; border-block-start: 1px solid var(--rule); background: var(--paper-2); border-radius: 0 0 3px 3px; }

/* Barre latérale du devis (contact.html) : suit le défilement jusqu'au bas
   du formulaire. Grâce à align-items:start sur la grille parente, la zone
   de grille conserve la hauteur de la colonne la plus haute (le formulaire) :
   c'est cet espace que la barre latérale parcourt avant de se détacher.
   74px = hauteur de l'en-tête sticky (.masthead). */
@media (min-width: 881px) {
  .dossier-aside { position: sticky; inset-block-start: calc(74px + 1.5rem); }
}

/* ---------------------------------------------------------------- réglure -- */

.strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); border-block-start: 1px solid var(--rule); }
.strip > div { padding: 1.4rem 1.25rem; border-inline-end: 1px solid var(--rule); border-block-end: 1px solid var(--rule); }
.strip > div:last-child { border-inline-end: 0; }
.strip dt { font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.13em; text-transform: uppercase; color: var(--ink-60); }
.strip dd { margin: 0.35rem 0 0; font-size: var(--step-2); font-weight: 600; letter-spacing: -0.02em; }

/* ---------------------------------------------------------------- cartes -- */

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(255px, 1fr)); gap: 1px; background: var(--rule); border: 1px solid var(--rule); }

/* services.html "What we offer" — fixed 3x2 instead of the auto-fit above,
   which produced an uneven 4-then-2 split for six cards. */
.cards--3x2 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 820px) { .cards--3x2 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .cards--3x2 { grid-template-columns: 1fr; } }
.card { background: var(--paper); padding: clamp(1.4rem, 2.6vw, 2rem); display: flex; flex-direction: column; gap: 0.6rem; }
.card__no { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.12em; color: var(--blue); }
.card h3 { font-size: var(--step-1); overflow-wrap: break-word; }
.card p { color: var(--ink-80); margin: 0; font-size: 0.96rem; }
.card--link { text-decoration: none; color: inherit; transition: background-color .16s ease; }
.card--link:hover { background: var(--blue-wash); color: inherit; }

/* Même effet au survol pour une carte qui n'est pas un lien. */
.card--hover { transition: background-color .16s ease; }
.card--hover:hover { background: var(--paper-2); }

/* Cas d'une carte-lien qui doit tout de même utiliser paper-2. */
.card--link.card--hover:hover { background: var(--paper-2); }

.prose { max-width: var(--measure); }
.prose h3 { font-size: var(--step-1); margin-block: 2rem 0.6rem; }
.prose ul { padding-inline-start: 1.15rem; }
.prose li { margin-block-end: 0.45rem; }

/* liste à puces carrées — le chevron de la marque ne sert pas d'icône. §6 */
.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.7rem; }
.ticks li { position: relative; padding-inline-start: 1.5rem; }
.ticks li::before {
  content: ""; position: absolute; inset-inline-start: 0; inset-block-start: 0.58em;
  width: 7px; height: 7px; background: var(--blue);
}

/* ---------------------------------------------------------------- tableau -- */

.tbl { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.tbl th, .tbl td { text-align: start; padding: 0.8rem 1rem; border-block-end: 1px solid var(--rule); vertical-align: top; }
.tbl th { font-weight: 500; color: var(--ink-60); white-space: nowrap; width: 1%; }
.tbl tr:first-child th, .tbl tr:first-child td { border-block-start: 1px solid var(--rule); }

/* ---------------------------------------------------------- à confirmer --- */

.todo {
  border: 1px dashed #B8860B; background: #FFFBEF; color: #6B5300;
  padding: 0.12em 0.45em; border-radius: 3px; font-size: 0.85em;
  font-family: var(--mono);
}
.note {
  border-inline-start: 3px solid var(--blue); background: var(--blue-wash);
  padding: 1rem 1.25rem; margin-block: 1.5rem; max-width: var(--measure);
}
.note p:last-child { margin-block-end: 0; }

/* ------------------------------------------------------------------- faq -- */

.faq-list { border-block-start: 1px solid var(--rule); max-width: var(--measure); }
.faq-item { border-block-end: 1px solid var(--rule); }
.faq-item > summary {
  list-style: none; cursor: pointer; padding-block: 1.1rem;
  display: flex; align-items: center; gap: 1rem;
  font-weight: 500; font-size: var(--step-0);
}
.faq-item > summary::-webkit-details-marker { display: none; }
.faq-item > summary::marker { content: ""; }
.faq-item[open] > summary { color: var(--blue-deep); }
.faq-item__icon { margin-inline-start: auto; flex: none; width: 20px; height: 20px; position: relative; }
.faq-item__icon::before, .faq-item__icon::after {
  content: ""; position: absolute; background: var(--ink-60); transition: opacity .16s ease, transform .16s ease;
}
.faq-item[open] > summary .faq-item__icon::before { background: var(--blue-deep); }
.faq-item__icon::before { inset-inline-start: 0; inset-block-start: 9px; width: 20px; height: 1.5px; }
.faq-item__icon::after { inset-inline-start: 9px; inset-block-start: 0; width: 1.5px; height: 20px; }
.faq-item[open] > summary .faq-item__icon::after { transform: rotate(90deg); opacity: 0; }
.faq-item > p { margin: 0 0 1.15rem; color: var(--ink-80); max-width: 68ch; }

/* ------------------------------------------------------------ formulaire -- */

.form { display: grid; gap: 1.15rem; max-width: 620px; }
.field { display: grid; gap: 0.4rem; }
.field label { font-size: 0.8rem; font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-80); }
.field .req { color: var(--blue-deep); }
.field input, .field select, .field textarea {
  font: inherit; font-size: 1rem; color: var(--ink); background: var(--paper);
  border: 1px solid var(--rule-strong); border-radius: 3px; padding: 0.75rem 0.85rem;
  width: 100%; transition: border-color .15s ease, box-shadow .15s ease;
}
.field textarea { min-height: 140px; resize: vertical; line-height: 1.55; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgb(56 112 164 / 0.16);
}
.field__hint { font-size: 0.82rem; color: var(--ink-60); }
.field--2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.15rem; }
@media (max-width: 620px) { .field--2 { grid-template-columns: 1fr; } }
.hp { position: absolute; inset-inline-start: -9999px; width: 1px; height: 1px; overflow: hidden; }

.alert { padding: 1rem 1.25rem; border-radius: 3px; margin-block-end: 1.75rem; max-width: 620px; }
.alert--ok { background: #EAF5EC; border-inline-start: 3px solid #2E7D3A; color: #1E5426; }
.alert--bad { background: #FCECEC; border-inline-start: 3px solid #B3261E; color: #8A1C16; }
.alert p:last-child { margin-block-end: 0; }

/* ------------------------------------------------------------- WhatsApp --- */

.wa-fab {
  position: fixed; inset-block-end: 1.25rem; inset-inline-end: 1.25rem; z-index: 60;
  display: inline-flex; align-items: center; gap: 0.6rem;
  background: var(--wa); color: #fff; text-decoration: none;
  padding: 0.85rem 1rem; border-radius: 999px; font-weight: 500; font-size: 0.92rem;
  box-shadow: 0 10px 28px -8px rgb(37 211 102 / 0.55), 0 2px 8px rgb(29 29 27 / 0.18);
  transition: transform .18s ease, box-shadow .18s ease;
}
.wa-fab:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 16px 34px -8px rgb(37 211 102 / 0.6); }
.wa-fab svg { width: 24px; height: 24px; flex: none; }
.wa-fab__txt { white-space: nowrap; }
@media (max-width: 700px) {
  .wa-fab { padding: 0.9rem; inset-block-end: 1rem; inset-inline-end: 1rem; }
  .wa-fab__txt { display: none; }
}

/* ------------------------------------------------------------------ pied -- */

.foot { background: var(--ink); color: #B9B9B4; font-size: 0.9rem; padding-block: clamp(2.5rem, 5vw, 4rem) 2rem; }
.foot a { color: #E8E8E4; }
.foot__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 2.25rem; }
.foot h2 { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase; color: #9A9A92; margin-block-end: 0.9rem; font-weight: 500; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.5rem; }
.foot ul.foot__pages-cols { grid-template-columns: repeat(2, auto); grid-template-rows: repeat(3, auto); grid-auto-flow: column; column-gap: 1.5rem; }
.foot p { max-width: 40ch; }
.foot__legal {
  margin-block-start: 2.75rem; padding-block-start: 1.5rem; border-block-start: 1px solid #343431;
  font-size: 0.79rem; color: #9A9A92; line-height: 1.75;
}
.foot__legal .num { color: #B5B5AE; }
.foot__legal p { max-width: 90ch; }

/* --------------------------------------------------------- ajustements --- */

/* Les ancres ne doivent pas passer sous l'en-tête collant. */
[id] { scroll-margin-block-start: 90px; }

/* Une mention « à fournir » ne doit pas hériter du corps d'affichage. */
.strip dd .todo,
.card h3 .todo { font-size: 0.82rem; font-weight: 400; letter-spacing: 0; }

/* Un numéro de téléphone ne se coupe jamais en fin de ligne. */
.card h3 .num, .dossier dd .num { white-space: nowrap; }
.card h3 .num { font-size: 0.92em; }

/* Titre de structure nécessaire à la hiérarchie, masqué visuellement. */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* ------------------------------------------------------------ photos ----- */

figure { margin: 0; }
.shot {
  display: block; width: 100%; height: 100%; object-fit: cover;
  background: var(--paper-2);
}
.figure { border: 1px solid var(--rule); background: var(--paper); }
.figure figcaption {
  padding: 0.85rem 1.1rem; font-size: 0.88rem; color: var(--ink-60);
  border-block-start: 1px solid var(--rule);
}
.figure figcaption strong { color: var(--ink); font-weight: 500; }

/* Bande de photos. Trois colonnes au large : six photos font deux rangées
   pleines. `height: auto` laisse l'aspect-ratio gouverner — sans quoi les
   figures de hauteurs inégales étirent les images. */
.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.25rem; }
.gallery .figure { display: flex; flex-direction: column; }
.gallery .shot { aspect-ratio: 4 / 3; height: auto; }
/* Les légendes s'alignent en bas, quel que soit leur nombre de lignes. */
.gallery figcaption { margin-block-start: auto; }

/* Une grande photo, deux plus petites empilées à côté. La hauteur du bloc
   vient de l'aspect-ratio du conteneur, pas des images : les figures
   remplissent leur cellule de grille, donc l'écart vertical entre les deux
   petites égale l'écart horizontal avec la grande. */
.egallery {
  display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; gap: 1.25rem;
  aspect-ratio: 16 / 8.2;
}
.egallery .figure { display: flex; flex-direction: column; height: 100%; min-height: 0; }
.egallery .shot { flex: 1 1 auto; min-height: 0; height: auto; }
.egallery figcaption { flex: none; margin-block-start: 0; }
.egallery__feature { grid-column: 1; grid-row: 1 / 3; }
.egallery__side { grid-column: 2; }
.egallery__side--a { grid-row: 1; }
.egallery__side--b { grid-row: 2; }

@media (max-width: 820px) {
  .egallery { grid-template-columns: repeat(2, 1fr); aspect-ratio: auto; }
  .egallery .figure { height: auto; }
  .egallery .shot { flex: none; aspect-ratio: 4 / 3; height: auto; }
  .egallery__feature { grid-column: 1 / 3; grid-row: auto; }
  .egallery__feature .shot { aspect-ratio: 16 / 10; }
  .egallery__side { grid-column: span 1; grid-row: auto; }
}
@media (max-width: 520px) {
  .egallery { grid-template-columns: 1fr; }
  .egallery__feature, .egallery__side { grid-column: 1; }
}

.trust-line {
  margin-block-start: 1.75rem; font-size: 0.86rem; color: var(--ink-60);
  padding-inline-start: 0.9rem; border-inline-start: 2px solid var(--rule);
}

/* Photo large, jumelée à du texte. */
.split {
  display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr);
  gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center;
}
@media (max-width: 820px) { .split { grid-template-columns: 1fr; } }
.split .figure .shot { aspect-ratio: 5 / 4; }

/* Vignette dans une carte de service. */
.card .shot { aspect-ratio: 16 / 10; margin-block-end: 0.9rem; }
.foot__legal p { margin-block-end: 0.6rem; }
.foot__legal .foot__copy { margin-block-end: 0; }
.foot__legal strong { color: #C9C9C4; font-weight: 600; }

/* --------------------------------------------------------------- étapes -- */

.steps { list-style: none; margin: 0; padding: 0; counter-reset: etape; }
.steps li {
  position: relative; counter-increment: etape;
  padding-inline-start: 3.25rem; padding-block-end: 1.6rem;
}
.steps li::before {
  content: counter(etape, decimal-leading-zero);
  position: absolute; inset-inline-start: 0; inset-block-start: 0.1rem;
  font-family: var(--mono); font-size: 0.72rem; font-weight: 500;
  color: var(--blue-deep); background: var(--blue-wash);
  width: 2.1rem; height: 2.1rem; border-radius: 50%;
  display: grid; place-items: center;
}
/* filet reliant les étapes */
.steps li::after {
  content: ""; position: absolute; inset-inline-start: 1.05rem; inset-block: 2.35rem 0;
  width: 1px; background: var(--rule);
}
.steps li:last-child { padding-block-end: 0; }
.steps li:last-child::after { display: none; }
.steps h3 { font-size: 1.02rem; margin-block-end: 0.3rem; }
.steps p { margin: 0; color: var(--ink-80); font-size: 0.96rem; }
abbr[title] { text-decoration: underline dotted; text-underline-offset: 0.2em; cursor: help; }

/* ------------------------------------------------------------------ RTL -- */

/* Les flèches de navigation se reflètent en RTL ; le logo et les photos
   ne se reflètent jamais. Voir design.md §4 et §6. */
[dir="rtl"] .mirror { transform: scaleX(-1); }

/* L'arabe demande plus d'air entre les lignes et un peu moins de chasse. */
[dir="rtl"] .lede { line-height: 1.85; }
[dir="rtl"] .ticks li,
[dir="rtl"] .card p,
[dir="rtl"] .steps p { line-height: 1.85; }
[dir="rtl"] .eyebrow,
[dir="rtl"] .lockup__sub,
[dir="rtl"] .nav a,
[dir="rtl"] .dossier__head,
[dir="rtl"] .foot h2,
[dir="rtl"] .card__no,
[dir="rtl"] .strip dt,
[dir="rtl"] .dossier dt { letter-spacing: 0; }

/* Le wordmark reste latin : il garde sa direction quel que soit le sens. */
.lockup__type { direction: ltr; }

/* Les numéros de téléphone, e-mails et identifiants ne se retournent pas. */
[dir="rtl"] bdi.num, [dir="rtl"] .num { direction: ltr; unicode-bidi: isolate; }

/* Les champs qui reçoivent du latin ou des chiffres restent en LTR. */
[dir="rtl"] input[type="tel"],
[dir="rtl"] input[type="email"],
[dir="rtl"] input[type="date"] { text-align: start; }

/* ------------------------------------------------- conformité de base --- */
/* Corrections issues de l'audit Web Interface Guidelines. Elles valent pour
   les deux versions du design et ne relèvent pas de l'itération visuelle. */

:root { color-scheme: light; }

/* Pas de délai de 300 ms au tap, et pas de flash gris sur mobile. */
a, button, label, summary, [role="button"] {
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgb(56 112 164 / 0.12);
}

/* Les titres ne doivent pas laisser un mot orphelin sur la dernière ligne. */
h1, h2, h3, .h-sec, .lede { text-wrap: pretty; }
h1, h2 { text-wrap: balance; }

/* Le menu mobile ne doit pas entraîner le défilement de la page derrière lui. */
.nav.is-open { overscroll-behavior: contain; }

/* Un select natif hérite sinon des couleurs du système, pas des nôtres. */
.field select { background-color: var(--paper); color: var(--ink); }

/* Le focus clavier reste visible même quand on retire le contour par défaut. */
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible {
  outline: 2px solid var(--blue-deep); outline-offset: 1px;
}

/* ------------------------------------------------- fiche technique ------ */

.spec-sheet { display: grid; gap: clamp(2rem, 4vw, 3.25rem); }
.vehicle {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(1.25rem, 3vw, 2.5rem); align-items: start;
}
@media (max-width: 760px) { .vehicle { grid-template-columns: 1fr; } }
.vehicle__shot .shot { aspect-ratio: 1 / 1; height: auto; }
.vehicle__data h3 { font-size: var(--step-2); letter-spacing: -0.02em; }
[dir="rtl"] .vehicle__data h3 { letter-spacing: 0; }
.vehicle__use { color: var(--ink-60); margin-block: 0.5rem 1.25rem; font-size: 0.96rem; }

.spec { width: 100%; border-collapse: collapse; }
.spec th, .spec td { text-align: start; padding: 0.7rem 0; border-block-end: 1px solid var(--rule); vertical-align: baseline; }
.spec th { font-weight: 400; color: var(--ink-60); font-size: 0.9rem; white-space: nowrap; padding-inline-end: 1.5rem; }
.spec td { font-family: var(--mono); font-size: 0.98rem; font-variant-numeric: tabular-nums; }

/* Bandeau photographique pleine largeur (utilisé par la version 2). */
.hero-band img { display: block; width: 100%; height: clamp(180px, 26vw, 330px); object-fit: cover; object-position: center 46%; }

/* Un numéro de téléphone ne se scinde jamais sur deux lignes. */
a[href^="tel:"], a[href^="tel:"] .num, a[href^="tel:"] bdi,
.ticks a[href^="tel:"] { white-space: nowrap; }

/* Le sélecteur de langue garde son nom complet dans sa propre écriture, mais
   sans capitales : « Français · العربية · English ». Voir design.md §8. */
.langs a, .langs span { text-transform: none; letter-spacing: 0; font-size: .82rem; }
