@import url('https://fonts.googleapis.com/css2?family=Lato:wght@400;700;900&family=Open+Sans:ital,wght@0,400;0,600;0,700;1,400&display=swap');
/* =====================================================================
   FacilityManager (facility-manager.fr) : feuille COMPLÈTE du thème.
   À coller SEULE dans la feuille du thème, en remplaçant tout son contenu.
   L'@import doit rester tout en haut du fichier.

   Charte SMS Management (smsmanagement.fr) : vert #8DBE24 (boutons #6C9C03),
   bleu nuit #303548, orange #D95020 en accent, titres Lato, texte Open Sans.
   Logo FacilityManager : immeubles isométriques, circuits, loupe avec coche (17/11/2026). Accueil « Vitrine » et animations (25/11/2026).

   Règles du CMS AIW (voir GUIDE-INTEGRATION-CMS-AIW.md) :
   la mise en forme repose UNIQUEMENT sur
     1. les classes du BLOC (réglages du bloc, hors éditeur) : fm fm-hero… ;
     2. les grilles de l'éditeur (one-column, two-columns, three-columns…) ;
     3. l'ordre des balises (surtitre = ligne avant le Titre 1, etc.).
   Aucune classe n'est posée à l'intérieur du contenu.
   ===================================================================== */

/* ---------- 1. Jetons ---------- */
:root {
    --fm-nuit: #303548;
    --fm-nuit-fonce: #262A3A;
    --fm-rouge: #6C9C03;          /* bouton principal : vert SMS foncé (contraste du texte blanc) */
    --fm-rouge-survol: #5A8402;
    --fm-vert: #8DBE24;
    --fm-orange: #D95020;
    --fm-bleu: #5E8A00;           /* liens, surtitres */
    --fm-bleu-clair: #B4BBCB;
    --fm-bleu-teinte: #D9DDE6;
    --fm-pale: #F4F6F1;
    --fm-pale-2: #E7EDDA;
    --fm-texte: #3C4152;
    --fm-gris: #72787D;
    --fm-bord: #DDE1E6;
    --fm-blanc: #fff;
    --fm-police: 'Open Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --fm-titres: 'Lato', 'Open Sans', system-ui, sans-serif;
    --fm-largeur: 1240px;
    --fm-rayon: 10px;
    --fm-rayon-photo: 14px;
    --fm-ombre: 0 22px 48px -26px rgba(31, 58, 95, .45);
    --fm-h1: clamp(34px, 4.4vw, 58px);
    --fm-h2: clamp(28px, 2.8vw, 40px);
    --fm-h3: clamp(18px, 1.35vw, 20px);
    --fm-chapeau: clamp(18px, 1.45vw, 21px);
    --fm-corps: clamp(16px, 1.1vw, 17px);
    --fm-petit: 14px;
    --fm-section: clamp(56px, 7vw, 96px);
    --fm-gouttiere: clamp(24px, 3vw, 48px);
    --fm-ecart: 24px;
    --fm-lisere: linear-gradient(90deg, var(--fm-orange) 0 30%, var(--fm-vert) 30% 100%);
}

/* ---------- 2. Base ---------- */
*, *:before, *:after { box-sizing: border-box; }
html, body {
    margin: 0; padding: 0; background: var(--fm-blanc); color: var(--fm-texte);
    font-family: var(--fm-police); font-size: 17px; line-height: 1.6;
    -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
html { scroll-behavior: smooth; }
p { font-family: var(--fm-police); }
a, a:visited { color: var(--fm-bleu); }
a:hover, a:focus { color: var(--fm-nuit); }
img { max-width: 100%; height: auto; }
h1, h2, h3, h4 { font-family: var(--fm-titres); color: var(--fm-nuit); }
footer .wrapper { max-width: var(--fm-largeur); width: auto; margin: 0 auto; padding: 0 24px; }

/* Accessibilité : focus clavier visible, lien d'évitement */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
    outline: 3px solid var(--fm-bleu); outline-offset: 3px; border-radius: 4px; }
footer a:focus-visible, :is(.fm-hero, .fm-appel) a:focus-visible { outline-color: var(--fm-blanc); }
header nav:has(.button + input:focus-visible) .button { outline: 3px solid var(--fm-bleu); outline-offset: -4px; border-radius: 8px; }
.fm-evitement { position: absolute; left: 16px; top: -60px; z-index: 100; background: var(--fm-nuit); color: var(--fm-blanc) !important;
    padding: 10px 16px; border-radius: 0 0 10px 10px; font-weight: 700; text-decoration: none; }
.fm-evitement:focus { top: 0; }

/* ---------- 3. En-tête : logo à gauche, menu à droite, liseré rouge/bleu ---------- */
header { position: relative; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px;
    width: auto; margin: 0; padding: 12px max(24px, calc((100% - var(--fm-largeur)) / 2 + 24px));
    background: var(--fm-blanc); border-bottom: 1px solid var(--fm-bord); }
header:after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 4px; background: var(--fm-lisere); }
header .fm-logo a { display: inline-block; line-height: 0; }
header .fm-logo img { height: 72px; width: auto; }
header nav { position: relative; z-index: 20; }
header nav ul { list-style: none; margin: 0; padding: 0; }
header nav li { list-style: none; position: relative; }
header nav li:before { content: none; }
header nav li a, header nav li a:visited, header nav li .label {
    display: block; color: var(--fm-nuit); text-decoration: none; font-weight: 600; white-space: nowrap; }
header nav li a:hover, header nav li a:focus { color: var(--fm-bleu); text-decoration: none; }
header nav .arrow { display: none; }
@media screen and (min-width: 900px) {
    header nav .button, header nav .button + input { display: none; }
    header nav > ul { display: flex; align-items: center; gap: clamp(16px, 2.2vw, 32px); }
    header nav > ul > li > a, header nav > ul > li > a:visited, header nav > ul > li > .label {
        font-size: 16px; padding: 10px 0 8px; border-bottom: 3px solid transparent; transition: border-color .2s, color .2s; }
    header nav > ul > li > a:hover, header nav > ul > li > a:focus, header nav > ul > li.active > a { border-bottom-color: var(--fm-vert); }
    /* Dernière entrée du menu (« Demander une démo ») en bouton */
    header nav > ul > li:last-child > a, header nav > ul > li:last-child > a:visited {
        background: var(--fm-rouge); color: var(--fm-blanc); border: 0; border-radius: 4px; padding: 10px 18px; transition: background .2s; }
    header nav > ul > li:last-child > a:hover, header nav > ul > li:last-child > a:focus,
    header nav > ul > li.active:last-child > a { background: var(--fm-rouge-survol); color: var(--fm-blanc); }
    header nav ul li ul { display: none; position: absolute; left: -16px; top: 100%; min-width: 250px;
        background: var(--fm-blanc); border: 1px solid var(--fm-bord); border-radius: 0 0 12px 12px; padding: 8px 0; box-shadow: var(--fm-ombre); }
    header nav ul li:hover > ul, header nav ul li:focus-within > ul { display: block; }
    header nav ul li ul a { font-size: 15px; padding: 8px 16px; }
}
@media screen and (max-width: 899px) {
    header nav { flex: 1 1 100%; }
    header nav .button { display: block; padding: 10px 14px; border: 1px solid var(--fm-bord); border-radius: 10px;
        color: var(--fm-nuit); text-align: center; font-weight: 700; cursor: pointer; }
    header nav .button:before { content: "Menu  \2630"; white-space: pre; }
    header nav .button + input { position: absolute; left: 0; top: 0; width: 100%; height: 46px; margin: 0; opacity: 0; cursor: pointer; }
    header nav input + ul { display: none; padding: 8px 0 4px; }
    header nav input:checked + ul { display: block; }
    header nav li a, header nav li a:visited, header nav li .label { font-size: 17px; padding: 12px 8px; text-align: center; }
    header nav li.active > a { color: var(--fm-bleu); }
    header nav ul li ul { display: block; }
    header .fm-logo img { height: 52px; }
}

/* ---------- 4. Pied de page ---------- */
footer { background: var(--fm-nuit-fonce); color: var(--fm-bleu-teinte); padding: 48px 0 18px; margin: 0; font-size: 15px; }
footer .fm-pied { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr); gap: 32px; }
footer .fm-pied strong { display: block; color: var(--fm-blanc); font-family: var(--fm-titres); font-size: 17px; margin-bottom: 10px; }
footer .fm-pied p { margin: 0 0 .6em; }
footer .fm-pied ul { list-style: none; margin: 0; padding: 0; }
footer .fm-pied li { margin: 0 0 .5em; }
footer .fm-pied li:before { content: none; }
footer .legal { border-top: 1px solid #2E4E76; margin-top: 36px; padding-top: 16px; font-size: 13px; color: var(--fm-bleu-clair); }
footer a, footer a:visited { color: var(--fm-blanc); text-decoration: none; }
footer a:hover, footer a:focus { color: var(--fm-blanc); text-decoration: underline; }
/* Liens au fil du texte de la ligne légale : soulignés, pas seulement distingués par la couleur (PageSpeed, 27/11/2026) */
footer .legal a { text-decoration: underline; text-underline-offset: 2px; }
@media (max-width: 760px) { footer .fm-pied { grid-template-columns: minmax(0, 1fr); gap: 24px; } }

/* =====================================================================
   5. LES BLOCS DU CMS ET LES GRILLES DE L'ÉDITEUR
   Rendu du CMS : <div class="item-data … wrapper"><div><div>CONTENU</div></div></div>.
   ===================================================================== */
.item-data, .item-data.wrapper { width: auto !important; max-width: none !important; margin: 0 !important; float: none; }
/* Colonne = la 1re <div> sous le bloc. Sur fm.all-in-web.fr (26/11/2026) ACME n'en ajoute qu'UNE (item-data > div > grilles) ;
   si une 2e <div> existe, elle reste neutre. Ne pas cibler « > div » : ce serait la grille elle-même. */
/* Colonne de lecture et respiration verticale, pour TOUS les blocs (priorité nulle grâce à :where) */
:where(.item-data) > div {
    max-width: var(--fm-largeur); margin-left: auto; margin-right: auto;
    padding: calc(var(--fm-section) * .6) 24px; }
/* Bloc du thème = classe « fm » OU n'importe quelle classe « fm-… » : sur le site (26/11/2026), le dernier bloc
   des 16 pages modules a été réglé « fm-appel fm-carte » sans « fm ». */
:where(.item-data.fm, .item-data[class*=" fm-"]) > div { padding-top: var(--fm-section); padding-bottom: var(--fm-section); }

/* Les grilles */
.one-column, .two-columns, .three-columns, .four-columns, .six-columns, .eight-columns {
    display: grid; gap: var(--fm-gouttiere); align-items: start; }
.one-column { grid-template-columns: minmax(0, 1fr); }
.one-column.centered { text-align: center; }
.two-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.two-columns.third-left { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); }
.two-columns.third-right { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.two-columns.quarter-left { grid-template-columns: minmax(0, 1fr) minmax(0, 3fr); }
.two-columns.quarter-right { grid-template-columns: minmax(0, 3fr) minmax(0, 1fr); }
.three-columns { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.four-columns { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--fm-ecart); }
.six-columns { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--fm-ecart); }
.eight-columns { grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 16px; }
:is(.one-column, .two-columns, .three-columns, .four-columns, .six-columns, .eight-columns)
  + :is(.one-column, .two-columns, .three-columns, .four-columns, .six-columns, .eight-columns) { margin-top: var(--fm-gouttiere); }
/* Neutraliser la mise en page imposée par ui.css (flex à marges négatives, cellules en %).
   width en !important (sélecteurs ui.css plus précis) ; padding SANS !important (garde nos marges voulues). */
.one-column, .two-columns, .three-columns, .four-columns, .six-columns, .eight-columns { margin: 0; flex-wrap: nowrap; }
:is(.one-column, .two-columns, .three-columns, .four-columns, .six-columns, .eight-columns) > * {
    width: auto !important; max-width: 100%; padding: 0; display: block; vertical-align: baseline; }
.one-column.centered > * { max-width: none; margin-left: 0; margin-right: 0; }
.editable { min-width: 0; }
.editable > :first-child { margin-top: 0; }
.editable > :last-child { margin-bottom: 0; }

/* ---------- 6. Typographie du contenu (tous les blocs) ---------- */
main .editable h1 { font-family: var(--fm-titres); font-weight: 900; font-size: var(--fm-h1); letter-spacing: -.025em; line-height: 1.08; margin: 0 0 .35em; }
main .editable h2 { font-family: var(--fm-titres); font-weight: 900; font-size: var(--fm-h2); letter-spacing: -.02em; line-height: 1.15; margin: 0 0 .55em; color: var(--fm-nuit); }
main .editable h3 { font-family: var(--fm-titres); font-weight: 700; font-size: var(--fm-h3); line-height: 1.3; margin: 1.2em 0 .45em; color: var(--fm-nuit); }
main .editable h4 { font-family: var(--fm-titres); font-weight: 600; font-size: 17px; margin: 1em 0 .4em; }
main p, main li { font-size: var(--fm-corps); line-height: 1.65; }
main p { margin: 0 0 1em; }
main ul, main ol { padding-left: 1.3em; margin: 0 0 1.2em; }
main li { margin: .3em 0; }
main li:before { content: none; }
main strong { font-weight: 700; color: var(--fm-nuit); }
main blockquote { margin: 0 0 1em; padding: .2em 0 .2em 1em; border-left: 4px solid var(--fm-rouge); font-style: italic; font-size: var(--fm-chapeau); }
main .editable a:not(:has(img)) { text-underline-offset: 3px; }
/* Titre de section : petit liseré rouge au-dessus des Titre 2 centrés */
main .one-column.centered h2:before { content: ""; display: block; width: 48px; height: 4px; border-radius: 2px;
    background: var(--fm-lisere); margin: 0 auto 18px; }
main .one-column.centered h2 + p { font-size: var(--fm-chapeau); color: var(--fm-gris); max-width: 760px; margin-left: auto; margin-right: auto; }
/* Surtitre : la ligne juste avant un Titre 2 */
main .editable > p:has(+ h2) { font-size: var(--fm-petit); font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--fm-bleu); margin: 0 0 .5em; }
/* Images : photo/capture arrondie par défaut */
main .editable img { display: inline-block; vertical-align: middle; }
main .editable p > img:only-child { display: block; width: 100%; border-radius: var(--fm-rayon-photo); }
/* Badges et logos cliquables : rangée de liens-images */
main .editable p:has(> a > img) { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; }
main .one-column.centered p:has(> a > img) { justify-content: center; }
main .editable a:has(> img) { display: inline-block; line-height: 0; transition: transform .2s; }
main .editable a:has(> img):hover { transform: translateY(-3px); }
main .editable a > img { height: 52px; width: auto; border-radius: 0; }

/* Boutons : dans les blocs fm-hero, fm-appel et fm-boutons, un LIEN SEUL DANS SON PARAGRAPHE devient un bouton.
   Deux paragraphes-boutons qui se suivent : le second est un bouton secondaire (contour). */
:is(.fm-hero, .fm-appel, .fm-boutons) .editable p:has(> a:only-child):not(:has(img)) { display: inline-block; margin: 1.2em 6px 0 0; }
:is(.fm-hero, .fm-appel, .fm-boutons) .editable p > a:only-child:not(:has(img)) {
    display: inline-block; background: var(--fm-rouge); color: var(--fm-blanc); text-decoration: none;
    font-weight: 700; font-size: 18px; line-height: 1.2; padding: .8em 1.25em; border-radius: 4px; min-height: 48px;
    border: 2px solid var(--fm-rouge); transition: background .2s, transform .2s, border-color .2s; }
:is(.fm-hero, .fm-appel, .fm-boutons) .editable p > a:only-child:not(:has(img)):hover,
:is(.fm-hero, .fm-appel, .fm-boutons) .editable p > a:only-child:not(:has(img)):focus {
    background: var(--fm-rouge-survol); border-color: var(--fm-rouge-survol); color: var(--fm-blanc); transform: translateY(-2px); }
:is(.fm-hero, .fm-appel, .fm-boutons) .editable p:has(> a:only-child):not(:has(img)) + p:has(> a:only-child):not(:has(img)) > a {
    background: transparent; border-color: currentColor; color: var(--fm-nuit); }
:is(.fm-hero, .fm-appel) .editable p:has(> a:only-child):not(:has(img)) + p:has(> a:only-child):not(:has(img)) > a { color: var(--fm-blanc); }
:is(.fm-hero, .fm-appel, .fm-boutons) .editable p:has(> a:only-child):not(:has(img)) + p:has(> a:only-child):not(:has(img)) > a:hover {
    background: rgba(255, 255, 255, .12); border-color: currentColor; }
.fm-boutons .editable p:has(> a:only-child):not(:has(img)) + p:has(> a:only-child):not(:has(img)) > a:hover { background: var(--fm-pale); color: var(--fm-nuit); }

/* =====================================================================
   7. HAUT DE PAGE  —  bloc « fm fm-hero »
   Dans l'éditeur, deux colonnes (two-columns) :
     colonne 1 : petite ligne (surtitre) · Titre 1 · ligne d'accroche · texte · lien(s) seuls (boutons) ·
                 dernière ligne en petit (réassurance) ;
     colonne 2 : une capture d'écran (image).
   « fm fm-hero fm-hero-court » : même chose, moins haut (pages secondaires, une seule colonne possible).
   ===================================================================== */
.item-data.fm-hero { color: var(--fm-blanc);
    background: radial-gradient(900px 520px at 100% 0%, rgba(141, 190, 36, .28), transparent 70%), var(--fm-nuit); }
:where(.item-data.fm-hero) > div { padding-top: clamp(48px, 6vw, 88px); padding-bottom: clamp(56px, 7vw, 104px); }
.fm-hero .two-columns { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: center; gap: clamp(28px, 4vw, 64px); }
.fm-hero .editable h1 { color: var(--fm-blanc); margin: 0 0 .35em; }
.fm-hero .editable p { color: var(--fm-bleu-teinte); }
.fm-hero .editable > p:has(+ h1) { font-size: var(--fm-petit); font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
    color: var(--fm-vert); margin: 0 0 .9em; padding-left: 12px; border-left: 4px solid var(--fm-orange); }
.fm-hero h1 + p { font-size: var(--fm-chapeau); color: var(--fm-blanc); font-weight: 500; line-height: 1.5; }
/* Dernière ligne de texte après les boutons : réassurance, en petit */
.fm-hero .editable > p:last-child:not(:has(a)) { font-size: var(--fm-petit); color: var(--fm-bleu-clair); margin-top: 1.8em; }
/* Capture d'écran en « fenêtre » */
.fm-hero .two-columns > .editable:last-child p > img:only-child {
    border-radius: 12px; border: 8px solid var(--fm-nuit-fonce); box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .55); }
:where(.item-data.fm-hero.fm-hero-court) > div { padding-top: clamp(40px, 5vw, 64px); padding-bottom: clamp(40px, 5vw, 64px); }

/* ---------- 8. Chiffres clés : bloc « fm fm-chiffres » ---------- */
/* Dans chaque cellule : 1er paragraphe = le chiffre, puis une ligne de texte */
.item-data.fm-chiffres { background: var(--fm-pale); }
:where(.item-data.fm-chiffres) > div { padding-top: clamp(32px, 4vw, 48px); padding-bottom: clamp(32px, 4vw, 48px); }
.fm-chiffres :is(.three-columns, .four-columns) > .editable { text-align: center; padding: 6px 12px; }
.fm-chiffres .editable > p:first-child { font-family: var(--fm-titres); font-weight: 900; color: var(--fm-rouge);
    font-size: clamp(38px, 4.4vw, 60px); line-height: 1; margin: 0 0 .2em; letter-spacing: -.02em; }
.fm-chiffres .editable > p:first-child + p { color: var(--fm-gris); font-size: 15px; line-height: 1.45; }

/* ---------- 9. Texte et image côte à côte : bloc « fm fm-duo » (+ « fm-pale » pour un fond clair) ---------- */
.item-data.fm-pale { background: var(--fm-pale); }
.fm-duo .two-columns { align-items: center; gap: clamp(28px, 5vw, 80px); }
.fm-duo .editable p > img:only-child { box-shadow: var(--fm-ombre); }
/* Image détourée (PNG transparent, ex. téléphones) : pas d'ombre de cadre */
.fm-duo.fm-detoure .editable p > img:only-child { box-shadow: none; border-radius: 0; max-width: 560px; margin: 0 auto; }
/* Liste à coches */
:is(.fm-duo, .fm-liste) .editable ul { list-style: none; padding: 0; }
:is(.fm-duo, .fm-liste) .editable li { position: relative; padding-left: 34px; margin: .55em 0; }
:is(.fm-duo, .fm-liste) .editable li:before { content: ""; position: absolute; left: 0; top: .2em; width: 22px; height: 22px; border-radius: 50%;
    background: var(--fm-nuit) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center / 14px no-repeat; }

/* ---------- 10. Modules : bloc « fm fm-modules » ---------- */
/* Chaque cellule d'une grille = une tuile : icône (image), Titre 3, texte */
.fm-modules :is(.three-columns, .four-columns) > .editable {
    background: var(--fm-blanc); border: 1px solid var(--fm-bord); border-top: 4px solid var(--fm-nuit); border-radius: var(--fm-rayon);
    padding: 24px 22px 26px; height: 100%; transition: transform .25s, box-shadow .25s, border-color .25s; }
.fm-modules :is(.three-columns, .four-columns) > .editable:hover { transform: translateY(-4px); box-shadow: var(--fm-ombre); border-top-color: var(--fm-vert); }
.fm-modules :is(.three-columns, .four-columns) { align-items: stretch; }
.fm-modules :is(.three-columns, .four-columns) + :is(.three-columns, .four-columns) { margin-top: var(--fm-ecart); }
.fm-modules :is(.three-columns, .four-columns) .editable > p:first-child:has(> img) { margin: 0 0 14px; }
.fm-modules :is(.three-columns, .four-columns) .editable > p:first-child > img:only-child { width: 56px; height: 56px; border-radius: 50%; }
.fm-modules :is(.three-columns, .four-columns) .editable h3 { margin-top: 0; }
.fm-modules :is(.three-columns, .four-columns) .editable p { font-size: 15.5px; color: var(--fm-texte); }
/* Dernière ligne centrée sous les tuiles */
.fm-modules .one-column.centered + :is(.three-columns, .four-columns) ~ .one-column.centered p { color: var(--fm-gris); }

/* ---------- 11. Cartes : bloc « fm fm-cartes » ---------- */
/* Chaque cellule = une carte sur fond clair, liseré rouge à gauche ; Titre 3 puis texte */
.fm-cartes :is(.two-columns, .three-columns, .four-columns) { align-items: stretch; gap: var(--fm-ecart); }
.fm-cartes :is(.two-columns, .three-columns, .four-columns) + :is(.two-columns, .three-columns, .four-columns) { margin-top: var(--fm-ecart); }
.fm-cartes :is(.two-columns, .three-columns, .four-columns) > .editable {
    background: var(--fm-pale); border-left: 4px solid var(--fm-vert); border-radius: 0 var(--fm-rayon) var(--fm-rayon) 0; padding: 22px 24px 24px; }
.fm-cartes :is(.two-columns, .three-columns, .four-columns) > .editable h3 { margin-top: 0; }
.fm-cartes :is(.two-columns, .three-columns, .four-columns) > .editable p { font-size: 15.5px; }
.item-data.fm-pale.fm-cartes :is(.two-columns, .three-columns, .four-columns) > .editable { background: var(--fm-blanc); }

/* ---------- 12. Rangée d'icônes : bloc « fm fm-icones » ---------- */
/* Une liste à puces, chaque ligne commençant par une icône (image) suivie du libellé */
.fm-icones ul { list-style: none; padding: 0; margin: 28px 0 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 20px; text-align: center; }
.fm-icones li { display: flex; flex-direction: column; align-items: center; gap: 12px; margin: 0; font-weight: 600; color: var(--fm-nuit);
    font-size: 15px; line-height: 1.4; }
.fm-icones li img { width: clamp(64px, 5.5vw, 84px); height: auto; border-radius: 50%; transition: transform .25s; }
.fm-icones li:hover img { transform: translateY(-4px); }

/* ---------- 13. Appel à l'action : bloc « fm fm-appel » ---------- */
.item-data.fm-appel { background: var(--fm-nuit); color: var(--fm-blanc); position: relative; }
.item-data.fm-appel:before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--fm-lisere); }
.fm-appel .editable h2 { color: var(--fm-blanc); }
.fm-appel .editable p { color: var(--fm-bleu-teinte); }
.fm-appel .one-column.centered h2:before { display: none; }
.fm-appel .one-column.centered h2 + p { color: var(--fm-bleu-teinte); }

/* =====================================================================
   13 bis. ACCUEIL « VITRINE » (25/11/2026)
   ===================================================================== */

/* ---------- Haut de page centré : bloc « fm fm-vitrine fm-boutons » ----------
   1re grille one-column centered : petite ligne (pastille), Titre 1, accroche, liens seuls (boutons), réassurance ;
   2e grille one-column : une capture, qui déborde sur le bloc suivant (à mettre juste après : fm-secteurs). */
header { z-index: 30; }   /* le liseré de l'en-tête reste au-dessus du haut de page */
.item-data.fm-vitrine { position: relative; z-index: 1; background: linear-gradient(180deg, #F3F8E8 0%, #fff 78%); overflow: visible; overflow-x: clip; }
:where(.item-data.fm-vitrine) > div { padding-top: clamp(56px, 7vw, 104px); padding-bottom: 0; }
.fm-vitrine .one-column.centered .editable { max-width: 900px; margin: 0 auto; }
.fm-vitrine .editable > p:has(+ h1) { display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
    color: var(--fm-bleu); background: var(--fm-blanc); border: 1px solid #D6E6B5; border-radius: 999px; padding: 6px 16px; margin-bottom: 22px; }
.fm-vitrine .editable h1 { font-size: clamp(38px, 5.4vw, 72px); line-height: 1.04; }
.fm-vitrine h1 + p { font-size: var(--fm-chapeau); color: var(--fm-gris); max-width: 720px; margin: 0 auto 8px; }
.fm-vitrine .editable p:has(> a:only-child):not(:has(img)) { margin: 1.2em 3px 0; }
.fm-vitrine .editable p > a:only-child:not(:has(img)) { border-radius: 999px; padding: .8em 1.6em; }
.fm-vitrine .editable > p:last-child:not(:has(a)) { font-size: var(--fm-petit); color: var(--fm-gris); margin-top: 1.6em; }
.fm-vitrine .one-column + .one-column { margin-top: clamp(40px, 5vw, 64px); }
.fm-vitrine .one-column:last-child .editable { position: relative; z-index: 2; margin-bottom: -140px; }
.fm-vitrine .one-column:last-child p > img:only-child { border-radius: 16px; border: 10px solid var(--fm-nuit);
    box-shadow: 0 50px 90px -40px rgba(48, 53, 72, .6); }

/* ---------- Bandeau des secteurs sous la capture : bloc « fm fm-secteurs » ----------
   one-column centered : une ligne de texte, puis une liste à puces (icône + libellé). */
.item-data.fm-secteurs { background: var(--fm-nuit); }
:where(.item-data.fm-secteurs) > div { padding-top: 56px; padding-bottom: 56px; }
.fm-vitrine + .fm-secteurs > div { padding-top: 196px; }
.fm-secteurs .editable > p:first-child { color: var(--fm-bleu-clair); font-size: 15px; letter-spacing: .03em; }
.fm-secteurs ul { list-style: none; padding: 0; margin: 20px 0 0; display: flex; justify-content: center; flex-wrap: wrap; gap: 14px 40px; }
.fm-secteurs li { display: flex; align-items: center; gap: 10px; margin: 0; color: var(--fm-blanc); font-weight: 600; font-size: 15px; }
.fm-secteurs li img { width: 36px; height: 36px; border-radius: 50%; background: var(--fm-blanc); }

/* ---------- Texte et image en zigzag : bloc « fm fm-zigzag » (+ « fm-inverse » : image à gauche ; + « fm-detoure ») ----------
   two-columns : colonne 1 = surtitre, Titre 2, texte, liste (coches) ; colonne 2 = l'image.
   Avec fm-inverse, on écrit toujours le texte en 1re colonne : c'est l'affichage qui inverse. */
.fm-zigzag .two-columns { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: center; gap: clamp(32px, 6vw, 96px); }
.fm-zigzag.fm-inverse .two-columns { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.fm-zigzag.fm-inverse .two-columns > .editable:first-child { order: 2; }
.fm-zigzag .editable p > img:only-child { box-shadow: var(--fm-ombre); border: 1px solid var(--fm-bord); }
.fm-zigzag.fm-detoure .editable p > img:only-child { box-shadow: none; border: 0; border-radius: 0; max-width: 520px; margin: 0 auto; }
.fm-zigzag .editable ul { list-style: none; padding: 0; }
.fm-zigzag .editable li { position: relative; padding-left: 32px; margin: .5em 0; }
.fm-zigzag .editable li:before { content: ""; position: absolute; left: 0; top: .2em; width: 22px; height: 22px; border-radius: 50%;
    background: var(--fm-rouge) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center / 14px no-repeat; }

/* ---------- Modules en pastilles : bloc « fm fm-pastilles » ----------
   Titre centré, puis six-columns : chaque cellule = icône (image) + Titre 3. */
.fm-pastilles .six-columns { gap: 16px; align-items: stretch; }
.fm-pastilles .six-columns + .six-columns { margin-top: 16px; }
.fm-pastilles .six-columns > .editable { text-align: center; background: var(--fm-blanc); border: 1px solid var(--fm-bord); border-radius: 14px; padding: 22px 10px 18px;
    transition: border-color .25s, transform .3s cubic-bezier(.2, .8, .2, 1), box-shadow .3s; }
.fm-pastilles .six-columns > .editable:hover { border-color: var(--fm-vert); transform: translateY(-4px); box-shadow: var(--fm-ombre); }
.fm-pastilles .six-columns .editable p > img:only-child { width: 56px; margin: 0 auto 12px; border-radius: 50%; transition: transform .4s cubic-bezier(.3, 1.4, .5, 1); }
.fm-pastilles .six-columns > .editable:hover p > img:only-child { transform: rotate(-8deg) scale(1.1); }
.fm-pastilles .six-columns .editable h3 { font-size: 15.5px; line-height: 1.3; margin: 0; }
.fm-pastilles .six-columns ~ .one-column.centered p { color: var(--fm-gris); font-size: 15.5px; max-width: 820px; margin: 0 auto; }

/* ---------- Encart centré à bord pointillé : bloc « fm fm-encart » (+ fm-boutons) ---------- */
.fm-encart .one-column.centered > .editable { max-width: 880px; margin: 0 auto; border: 2px dashed #CFE0A8; border-radius: 24px; padding: clamp(32px, 4vw, 48px) clamp(20px, 4vw, 48px); }
.fm-encart .one-column.centered h2:before { display: none; }
.fm-encart .editable > p:has(+ h2) { color: var(--fm-bleu); }

/* ---------- Appel à l'action en carte verte : « fm fm-appel fm-carte » ---------- */
.item-data.fm-appel.fm-carte { background: var(--fm-blanc); }
.item-data.fm-appel.fm-carte:before { display: none; }
:where(.item-data.fm-appel.fm-carte) > div { padding-top: 0; }
.fm-appel.fm-carte .one-column.centered > .editable { background: linear-gradient(120deg, var(--fm-rouge), var(--fm-vert)); border-radius: 28px; padding: clamp(40px, 5vw, 64px) clamp(20px, 4vw, 40px); }
.fm-appel.fm-carte .editable p, .fm-appel.fm-carte .one-column.centered h2 + p { color: var(--fm-blanc); }
.fm-appel.fm-carte .editable p > a:only-child:not(:has(img)) { background: var(--fm-nuit); border-color: var(--fm-nuit); border-radius: 999px; }
.fm-appel.fm-carte .editable p > a:only-child:not(:has(img)):hover { background: var(--fm-nuit-fonce); border-color: var(--fm-nuit-fonce); }
.fm-appel.fm-carte .editable p:has(> a:only-child):not(:has(img)) + p:has(> a:only-child):not(:has(img)) > a { background: transparent; border-color: var(--fm-blanc); }

@media (max-width: 1000px) {
    .fm-pastilles .six-columns { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
    .fm-zigzag .two-columns, .fm-zigzag.fm-inverse .two-columns { grid-template-columns: minmax(0, 1fr); }
    .fm-zigzag.fm-inverse .two-columns > .editable:first-child { order: 0; }
    .fm-vitrine .one-column:last-child .editable { margin-bottom: -60px; }
    .fm-vitrine + .fm-secteurs > div { padding-top: 100px; }
    .fm-secteurs ul { gap: 12px 24px; }
}
@media (max-width: 620px) {
    .fm-pastilles .six-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .fm-pastilles .six-columns + .six-columns { margin-top: 10px; }
    .fm-pastilles .six-columns > .editable { padding: 16px 8px 14px; }
    .fm-pastilles .six-columns .editable p > img:only-child { width: 44px; margin-bottom: 8px; }
    .fm-vitrine .one-column:last-child p > img:only-child { border-width: 5px; border-radius: 10px; }
    .fm-vitrine .one-column:last-child .editable { margin-bottom: -40px; }
    .fm-vitrine + .fm-secteurs > div { padding-top: 72px; }
    .fm-secteurs ul { justify-content: flex-start; flex-direction: column; align-items: flex-start; max-width: 300px; margin-left: auto; margin-right: auto; }
}

/* =====================================================================
   13 ter. PAGES MODULES ET PAGE FONCTIONNALITÉS (26/11/2026)
   ===================================================================== */
/* Points clés sans icône (pages modules) : une coche verte avant le libellé */
.fm-secteurs li:not(:has(img)):before { content: ""; width: 20px; height: 20px; border-radius: 50%; flex: none;
    background: var(--fm-vert) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center / 13px no-repeat; }
/* Pastilles et tuiles cliquables : un lien dans le Titre 3 rend toute la tuile cliquable */
:is(.fm-pastilles .six-columns, .fm-modules :is(.three-columns, .four-columns)) > .editable { position: relative; }
:is(.fm-pastilles, .fm-modules) .editable h3 a, :is(.fm-pastilles, .fm-modules) .editable h3 a:visited { color: inherit; text-decoration: none; }
:is(.fm-pastilles, .fm-modules) .editable h3 a:after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
:is(.fm-pastilles, .fm-modules) .editable:has(h3 a):hover h3 a { color: var(--fm-bleu); }
:is(.fm-pastilles, .fm-modules) .editable h3 a:focus-visible { outline: none; }
:is(.fm-pastilles, .fm-modules) .editable:has(h3 a:focus-visible) { outline: 3px solid var(--fm-bleu); outline-offset: 3px; }
/* Page Fonctionnalités : tuiles de modules un peu plus compactes */
.fm-modules.fm-liens .four-columns .editable p:not(:first-child) { font-size: 14.5px; color: var(--fm-gris); }
/* Haut de page sans capture : « fm fm-vitrine fm-entete » */
:where(.item-data.fm-vitrine.fm-entete) > div { padding-bottom: clamp(48px, 6vw, 80px); }
.fm-vitrine.fm-entete .one-column:last-child .editable { margin-bottom: 0; }
.fm-vitrine.fm-entete .editable h1 { font-size: clamp(34px, 4.4vw, 58px); }
.fm-vitrine.fm-entete + .item-data > div { padding-top: clamp(16px, 2vw, 32px); }

/* ---------- 14. Formulaire de contact (CMS, Semantic UI) : bloc « fm fm-contact » ---------- */
.fm-contact > div { max-width: 760px; }
.fm-contact .ui.form .name, .fm-contact label { color: var(--fm-nuit); font-weight: 600; font-size: 15px; border: 0 !important; }
.fm-contact .ui.form .row .column { width: 100% !important; text-align: left !important; }
.fm-contact .ui.form input:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=button]):not(.search),
.fm-contact .ui.form textarea,
.fm-contact .ui.selection.dropdown {
    border: 1px solid var(--fm-bord) !important; border-radius: 10px !important; box-shadow: none !important;
    padding: 12px 14px !important; min-height: 48px; font-family: var(--fm-police) !important; font-size: 16px !important;
    color: var(--fm-texte) !important; background: var(--fm-blanc) !important; }
.fm-contact .ui.form input:focus, .fm-contact .ui.form textarea:focus,
.fm-contact .ui.selection.dropdown:focus, .fm-contact .ui.selection.active.dropdown {
    border-color: var(--fm-bleu) !important; box-shadow: 0 0 0 4px var(--fm-pale-2) !important; outline: none; }
/* Champ de recherche invisible des listes déroulantes : sans cadre, sinon double bordure */
.fm-contact .ui.form .ui.search.selection.dropdown > input.search.search {
    border: 0 !important; background: transparent !important; box-shadow: none !important;
    padding: 12px 34px 12px 14px !important; min-height: 0; height: 100%; font-size: 16px !important; }
.fm-contact .ui.selection.dropdown > .dropdown.icon { top: 50% !important; right: 14px !important; margin: 0 !important; padding: 0 !important;
    height: auto !important; line-height: 1 !important; transform: translateY(-50%) !important; }
.fm-contact .ui.form .required:after { color: var(--fm-rouge); }
.fm-contact .buttons { text-align: center; margin-top: 24px; }
.fm-contact .ui.primary.button, .fm-contact .ui.button, .fm-contact button[type=submit] {
    background: var(--fm-rouge) !important; background-image: none !important; color: var(--fm-blanc) !important;
    border: 0 !important; border-radius: 12px !important; box-shadow: none !important;
    font-family: var(--fm-police) !important; font-weight: 700 !important; font-size: 17px !important;
    text-transform: none !important; padding: .85em 1.6em !important; min-height: 48px; cursor: pointer; }
.fm-contact .ui.primary.button:hover, .fm-contact .ui.primary.button:focus { background: var(--fm-rouge-survol) !important; }
/* Bande grise au survol d'une ligne (style d'administration du composant ui-form, relevé le 26/11/2026 :
   « ui-form .ui.form:not(.live):not(.flat) > .row:hover > .name.column { background:#e0e0e0 !important } », 8 classes).
   Classes répétées pour l'emporter sur cette priorité. */
.item-data.fm-contact ui-form .ui.form.form.form > .row.row > .column.column.column,
.item-data.fm-contact ui-form .ui.form.form.form > .row.row:is(:hover, .active) > .column.column.column {
    background: transparent !important; border-radius: 0 !important; box-shadow: none !important; }

/* ---------- 15. Mentions légales : colonne de lecture étroite (« fm fm-legal ») ---------- */
.fm-legal > div { max-width: 820px; }
.fm-legal .editable h2 { font-size: clamp(22px, 2vw, 28px); margin: 1.8em 0 .5em; }
.fm-legal .editable h2:first-of-type { margin-top: .4em; }

/* ---------- 15 bis. Guide et questions (26/11/2026) ----------
   « fm fm-article » (+ « fm-liste » pour les coches) : un long texte en colonne de lecture, Titres 2 et paragraphes.
   « fm fm-faq » : un Titre 2, puis une question en Titre 3 suivie de sa réponse, autant de fois que voulu. */
:is(.fm-article, .fm-faq) > div { max-width: 820px; }
.fm-article .editable h2 { font-size: clamp(24px, 2.2vw, 30px); margin: 1.9em 0 .55em; }
.fm-article .editable h2:first-child { margin-top: 0; }
.fm-faq .editable h2 { text-align: center; margin-bottom: .9em; }
.fm-faq .editable h2:before { content: ""; display: block; width: 48px; height: 4px; border-radius: 2px; background: var(--fm-lisere); margin: 0 auto 18px; }
.fm-faq .editable h3 { margin: 0; padding: 22px 0 8px; border-top: 1px solid var(--fm-bord); font-size: clamp(18px, 1.4vw, 20px); }
.fm-faq .editable h3 + p { color: var(--fm-texte); margin-bottom: 0; padding-bottom: 6px; }
.fm-faq .editable > :last-child { padding-bottom: 22px; border-bottom: 1px solid var(--fm-bord); }
/* Étapes numérotées : une liste numérotée dans un bloc zigzag ou article */
:is(.fm-zigzag, .fm-article) .editable ol { list-style: none; padding: 0; counter-reset: fm-etape; }
:is(.fm-zigzag, .fm-article) .editable ol li { position: relative; padding-left: 46px; margin: .9em 0; counter-increment: fm-etape; }
:is(.fm-zigzag, .fm-article) .editable ol li:before { content: counter(fm-etape); position: absolute; left: 0; top: .05em;
    width: 30px; height: 30px; border-radius: 50%; background: var(--fm-nuit); color: var(--fm-blanc);
    font: 700 15px/30px var(--fm-titres); text-align: center; }

[id] { scroll-margin-top: 24px; }

/* ---------- 15 ter. Bandeau cookies (tarteaucitron, composant fm-site, 27/11/2026) ----------
   Couleurs du site. « Tout accepter » et « Tout refuser » ont exactement le même style : la CNIL exige
   que refuser soit aussi simple et aussi visible qu'accepter. !important : la feuille de tarteaucitron
   est chargée après celle du thème. */
#tarteaucitronRoot #tarteaucitronAlertBig { background: var(--fm-nuit) !important; color: var(--fm-blanc) !important;
    font-family: var(--fm-police) !important; font-size: 14px !important; line-height: 1.3 !important; padding: 8px 20px !important;
    border-top: 3px solid var(--fm-vert) !important; box-shadow: 0 -12px 30px -12px rgba(0, 0, 0, .35) !important; }
#tarteaucitronRoot #tarteaucitronAlertBig #tarteaucitronDisclaimerAlert { font-family: var(--fm-police) !important; font-size: 14px !important;
    color: var(--fm-blanc) !important; margin: 0 8px 0 0 !important; }
/* Boutons compacts (27/11/2026 : le bandeau faisait 116 px de haut, il en fait 60) */
#tarteaucitronRoot #tarteaucitronAlertBig :is(#tarteaucitronPersonalize2, #tarteaucitronAllDenied2, #tarteaucitronCloseAlert, #tarteaucitronPrivacyUrl) {
    font: 700 14px/1.2 var(--fm-police) !important; padding: 7px 14px !important; margin: 4px !important; min-height: 0 !important; height: auto !important; }
#tarteaucitronRoot #tarteaucitronAlertBig :is(#tarteaucitronPersonalize2, #tarteaucitronAllDenied2) {
    background: #557A02 !important; color: var(--fm-blanc) !important; border: 0 !important; border-radius: 4px !important; }   /* vert plus foncé : texte blanc 14 px à 5:1 (PageSpeed, 27/11/2026) */
#tarteaucitronRoot #tarteaucitronAlertBig :is(#tarteaucitronPersonalize2, #tarteaucitronAllDenied2):hover { background: #466502 !important; }
#tarteaucitronRoot #tarteaucitronAlertBig #tarteaucitronCloseAlert { background: transparent !important; color: var(--fm-blanc) !important;
    border: 1px solid var(--fm-blanc) !important; border-radius: 4px !important; font-weight: 600 !important; }
/* Lien « Politique de confidentialité » : noir par défaut, illisible sur le fond nuit */
#tarteaucitronRoot #tarteaucitronAlertBig #tarteaucitronPrivacyUrl { background: transparent !important; color: var(--fm-blanc) !important;
    border: 0 !important; font-weight: 400 !important; text-decoration: underline !important; }
#tarteaucitronRoot :is(button, a):focus-visible { outline: 3px solid var(--fm-vert) !important; outline-offset: 2px !important; }

/* ---------- 16. Tablette et téléphone ---------- */
@media (max-width: 1000px) {
    .four-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .six-columns { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .eight-columns { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .fm-icones ul { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 28px; }
}
@media (max-width: 860px) {
    .two-columns, .two-columns.third-left, .two-columns.third-right, .two-columns.quarter-left, .two-columns.quarter-right,
    .three-columns, .fm-hero .two-columns { grid-template-columns: minmax(0, 1fr); }
    .fm-hero .two-columns > .editable:last-child { max-width: 560px; }
}
@media (max-width: 620px) {
    .four-columns { grid-template-columns: minmax(0, 1fr); }
    .six-columns, .eight-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    :where(.item-data) > div { padding-left: 16px; padding-right: 16px; }
    .fm-chiffres .four-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .fm-icones ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    :is(.fm-hero, .fm-appel, .fm-boutons) .editable p:has(> a:only-child):not(:has(img)) { display: block; margin-right: 0; }
    :is(.fm-hero, .fm-appel, .fm-boutons) .editable p > a:only-child:not(:has(img)) { display: block; text-align: center; }
    main .editable a > img { height: 44px; }
}

/* ---------- 17. Mouvement réduit ---------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *:before, *:after { transition: none !important; }
    .editable:hover, .editable:hover img, main .editable a:hover, .fm-icones li:hover img { transform: none !important; }
}

/* =====================================================================
   18. ANIMATIONS (CSS pur, aucun script)
   - au chargement : en-tête, haut de page (lignes en cascade, halos qui dérivent, capture qui flotte) ;
   - au défilement : animation-timeline: view() (Chrome, Edge, Safari 26+) ; ailleurs le contenu s'affiche simplement ;
   - coupées si le visiteur a demandé à réduire les animations (section 17).
   ===================================================================== */
main { overflow-x: clip; }   /* les éléments qui arrivent de côté ne créent pas de défilement horizontal */
@keyframes fm-entre   { from { opacity: 0; transform: translateY(26px) scale(.98); } to { opacity: 1; transform: none; } }   /* sans flou : filter n'est pas composé (PageSpeed, 27/11/2026) */
@keyframes fm-monte   { from { opacity: 0; transform: translateY(48px); } to { opacity: 1; transform: none; } }
@keyframes fm-gauche  { from { opacity: 0; transform: translateX(-70px); } to { opacity: 1; transform: none; } }
@keyframes fm-droite  { from { opacity: 0; transform: translateX(70px) rotate(1.5deg); } to { opacity: 1; transform: none; } }
@keyframes fm-zoom    { from { opacity: .3; transform: scale(.88); } to { opacity: 1; transform: none; } }
@keyframes fm-trait   { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes fm-descend { from { transform: translateY(-100%); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes fm-flotte  { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }
@keyframes fm-aurore  { 0% { transform: translate(0, 0) scale(1); } 50% { transform: translate(8%, 6%) scale(1.15); } 100% { transform: translate(-6%, -4%) scale(.95); } }
@keyframes fm-reflet  { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@keyframes fm-pop     { 0% { opacity: 0; transform: scale(.6); } 70% { transform: scale(1.06); } 100% { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: no-preference) {
    /* En-tête */
    header { animation: fm-descend .7s cubic-bezier(.2, .8, .2, 1) both; }
    header:after { transform-origin: left; animation: fm-trait 1.2s .4s cubic-bezier(.6, 0, .2, 1) both; }

    /* Haut de page : les lignes arrivent en cascade, le titre monte en fondu */
    :is(.fm-vitrine, .fm-hero) .one-column.centered .editable > *,
    .fm-hero .two-columns > .editable:first-child > * { animation: fm-entre .9s cubic-bezier(.2, .8, .2, 1) both; }
    :is(.fm-vitrine, .fm-hero) :is(.one-column, .two-columns) .editable > :nth-child(2) { animation-delay: .1s; }
    :is(.fm-vitrine, .fm-hero) :is(.one-column, .two-columns) .editable > :nth-child(3) { animation-delay: .25s; }
    :is(.fm-vitrine, .fm-hero) :is(.one-column, .two-columns) .editable > :nth-child(4) { animation-delay: .4s; }
    :is(.fm-vitrine, .fm-hero) :is(.one-column, .two-columns) .editable > :nth-child(5) { animation-delay: .5s; }
    :is(.fm-vitrine, .fm-hero) :is(.one-column, .two-columns) .editable > :nth-child(n+6) { animation-delay: .6s; }
    /* Halos vert et orange qui dérivent lentement */
    .fm-vitrine, .fm-hero { isolation: isolate; }
    .fm-hero { position: relative; overflow: hidden; }
    :is(.fm-vitrine, .fm-hero):before, :is(.fm-vitrine, .fm-hero):after {
        content: ""; position: absolute; z-index: -1; width: 46vw; height: 46vw; max-width: 720px; max-height: 720px; border-radius: 50%;
        filter: blur(70px); opacity: .55; pointer-events: none; animation: fm-aurore 16s ease-in-out infinite alternate; }
    :is(.fm-vitrine, .fm-hero):before { left: -12%; top: -30%; background: radial-gradient(circle, rgba(141, 190, 36, .55), transparent 65%); }
    :is(.fm-vitrine, .fm-hero):after { right: -14%; top: 10%; background: radial-gradient(circle, rgba(217, 80, 32, .28), transparent 65%);
        animation-duration: 20s; animation-direction: alternate-reverse; }
    .fm-hero:before { opacity: .35; }
    /* Capture : arrive, puis flotte doucement */
    .fm-vitrine .one-column:last-child .editable { animation: fm-zoom 1.2s .5s cubic-bezier(.2, .8, .2, 1) both; }
    .fm-vitrine .one-column:last-child .editable > p { animation: fm-flotte 7s 2s ease-in-out infinite; }
    .fm-hero .two-columns > .editable:last-child p > img:only-child { animation: fm-droite 1.1s .45s cubic-bezier(.2, .8, .2, 1) both, fm-flotte 7s 2s ease-in-out infinite; }

    /* Boutons : un reflet passe au survol */
    :is(.fm-hero, .fm-appel, .fm-boutons) .editable p > a:only-child:not(:has(img)) { position: relative; overflow: hidden; isolation: isolate; }
    :is(.fm-hero, .fm-appel, .fm-boutons) .editable p > a:only-child:not(:has(img)):after {
        content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
        background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, .35) 50%, transparent 65%) 200% 0 / 250% 100% no-repeat; }
    :is(.fm-hero, .fm-appel, .fm-boutons) .editable p > a:only-child:not(:has(img)):hover:after { animation: fm-reflet .9s ease; }

    /* Au défilement */
    @supports (animation-timeline: view()) {
        main .item-data:not(.fm-vitrine):not(.fm-hero) .editable { animation: fm-monte linear both; animation-timeline: view(); animation-range: entry 0% cover 25%; }
        /* zigzag et duo : le texte arrive d'un côté, l'image de l'autre */
        :is(.fm-zigzag, .fm-duo) .two-columns > .editable:first-child { animation-name: fm-gauche; }
        :is(.fm-zigzag, .fm-duo) .two-columns > .editable:last-child { animation-name: fm-droite; animation-range: entry 10% cover 35%; }
        .fm-zigzag.fm-inverse .two-columns > .editable:first-child { animation-name: fm-droite; }
        .fm-zigzag.fm-inverse .two-columns > .editable:last-child { animation-name: fm-gauche; }
        /* tuiles en cascade */
        :is(.fm-pastilles .six-columns, .fm-modules .four-columns, .fm-cartes .three-columns, .fm-chiffres .four-columns) > .editable:nth-child(2) { animation-range: entry 5% cover 30%; }
        :is(.fm-pastilles .six-columns, .fm-modules .four-columns, .fm-cartes .three-columns, .fm-chiffres .four-columns) > .editable:nth-child(3) { animation-range: entry 10% cover 35%; }
        :is(.fm-pastilles .six-columns, .fm-modules .four-columns, .fm-chiffres .four-columns) > .editable:nth-child(4) { animation-range: entry 15% cover 40%; }
        .fm-pastilles .six-columns > .editable:nth-child(5) { animation-range: entry 20% cover 45%; }
        .fm-pastilles .six-columns > .editable:nth-child(6) { animation-range: entry 25% cover 50%; }
        /* chiffres : « pop » */
        .fm-chiffres .editable > p:first-child { animation: fm-pop linear both; animation-timeline: view(); animation-range: entry 20% cover 40%; }
        /* liseré des titres centrés qui se dessine */
        main .one-column.centered h2:before { transform-origin: center; animation: fm-trait linear both; animation-timeline: view(); animation-range: entry 0% cover 30%; }
    }
}
