/* ==========================================================================
   BERAFO BTP — Feuille de style principale
   Emplacement : frontend/assets/css/berafo.css
   Direction artistique « plan & chantier » : bleu marine du bureau d'études,
   rouge des panneaux de chantier, vert de la grue du logo ; trames de plan,
   lignes de cote, coupes biseautées inspirées du flyer.
   Organisation en couches (@layer) : l'ordre des couches décide des priorités.
   ========================================================================== */

@layer reset, jetons, base, mise-en-page, composants, sections, utilitaires;

/* --------------------------------------------------------------- RESET --- */
@layer reset {
  *, *::before, *::after { box-sizing: border-box; }
  * { margin: 0; }
  html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
  img, svg, video { display: block; max-width: 100%; }
  input, button, select, textarea { font: inherit; color: inherit; }
  button { cursor: pointer; background: none; border: 0; }
  a { color: inherit; text-decoration: none; }
  ul, ol { list-style: none; padding: 0; }
  :where(h1, h2, h3, h4) { text-wrap: balance; }
  p { text-wrap: pretty; }
}

/* -------------------------------------------------------------- JETONS --- */
@layer jetons {
  @property --angle { syntax: "<angle>"; inherits: false; initial-value: 0deg; }

  :root {
    /* Couleurs de marque : --principale et --accent sont réécrites depuis le
       tableau de bord (Entreprise & logo → couleurs). */
    --principale: #0e367e;
    --accent: #e3141b;
    --marine: color-mix(in oklab, var(--principale) 62%, #020a1f);
    --nuit: color-mix(in oklab, var(--principale) 40%, #01040c);
    --vert: #12a82a;
    --ambre: #f4a300;
    --principale-voile: color-mix(in oklab, var(--principale) 9%, white);
    --accent-fonce: color-mix(in oklab, var(--accent) 82%, black);
    --accent-voile: color-mix(in oklab, var(--accent) 10%, white);
    --whatsapp: #25d366;

    --papier: #ffffff;
    --beton: #f3f6fb;
    --beton-2: #e9eef6;
    --ligne: #dce3ee;
    --texte: #0b1b3a;
    --texte-doux: #56617a;

    /* Typographie : titres condensés « chantier », texte très lisible */
    --police-titre: "Barlow Condensed", "Arial Narrow", "Segoe UI", system-ui, sans-serif;
    --police-texte: "Barlow", "Segoe UI", system-ui, sans-serif;

    --t-xs: clamp(0.74rem, 0.72rem + 0.1vw, 0.8rem);
    --t-s: clamp(0.86rem, 0.84rem + 0.12vw, 0.94rem);
    --t-m: clamp(0.98rem, 0.94rem + 0.2vw, 1.06rem);
    --t-l: clamp(1.18rem, 1.06rem + 0.5vw, 1.4rem);
    --t-xl: clamp(1.6rem, 1.3rem + 1.2vw, 2.25rem);
    --t-2xl: clamp(2.3rem, 1.5rem + 3.4vw, 4.2rem);

    --e-1: 0.25rem; --e-2: 0.5rem; --e-3: 0.75rem; --e-4: 1rem;
    --e-5: 1.5rem;  --e-6: 2rem;   --e-7: 3.25rem; --e-8: 5rem;

    --r-puce: 4px;
    --r-bouton: 8px;
    --r-carte: 12px;
    --r-panneau: 18px;
    --r-plein: 999px;

    --ombre-1: 0 1px 2px rgb(10 36 85 / 0.06), 0 2px 8px rgb(10 36 85 / 0.06);
    --ombre-2: 0 2px 6px rgb(10 36 85 / 0.07), 0 18px 40px -14px rgb(10 36 85 / 0.28);
    --ombre-3: 0 30px 80px -20px rgb(2 8 24 / 0.6);

    --largeur-max: 1320px;
    --gouttiere: clamp(1rem, 3.2vw, 2.5rem);
    --hauteur-entete: 74px;
    --transition: 200ms cubic-bezier(0.2, 0.7, 0.2, 1);
    --trame: linear-gradient(rgb(255 255 255 / 0.07) 1px, transparent 1px) 0 0 / 32px 32px,
             linear-gradient(90deg, rgb(255 255 255 / 0.07) 1px, transparent 1px) 0 0 / 32px 32px;
    --trame-claire: linear-gradient(rgb(14 54 126 / 0.05) 1px, transparent 1px) 0 0 / 28px 28px,
                    linear-gradient(90deg, rgb(14 54 126 / 0.05) 1px, transparent 1px) 0 0 / 28px 28px;
    color-scheme: light;
  }
}

/* ---------------------------------------------------------------- BASE --- */
@layer base {
  html { scroll-behavior: smooth; scroll-padding-top: calc(var(--hauteur-entete) + 12px + env(safe-area-inset-top, 0px)); }
  body {
    font-family: var(--police-texte); font-size: var(--t-m); line-height: 1.6; color: var(--texte);
    background: var(--beton); min-height: 100dvh;
    padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px);
    -webkit-font-smoothing: antialiased;
  }
  h1, h2, h3, h4 { font-family: var(--police-titre); line-height: 1.04; letter-spacing: 0.005em; font-weight: 800; }
  :focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
  ::selection { background: var(--principale); color: #fff; }
  body:has(dialog[open]) { overflow: hidden; }
  @media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
  }
}

/* -------------------------------------------------------- MISE EN PAGE --- */
@layer mise-en-page {
  .conteneur { width: min(100% - 2 * var(--gouttiere), var(--largeur-max)); margin-inline: auto; }
  .section { padding-block: var(--e-8); }
  .section--blanche { background: var(--papier); }
  .section--trame { background: var(--trame-claire), var(--beton); }
  .tete-section { display: grid; gap: var(--e-3); margin-bottom: var(--e-6); max-width: 760px; }
  .tete-section--centre { text-align: center; justify-items: center; margin-inline: auto; }
  .tete-section--ligne { max-width: none; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: var(--e-4); }
  .tete-section--ligne > div { display: grid; gap: var(--e-3); max-width: 720px; }
}

/* ---------------------------------------------------------- COMPOSANTS --- */
@layer composants {
  .icone { width: 1.25em; height: 1.25em; flex: none; }

  /* Sur-titre : petit trait rouge + capitales espacées */
  .surtitre {
    display: inline-flex; align-items: center; gap: 0.6rem;
    font-size: var(--t-xs); font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent);
  }
  .surtitre::before { content: ""; width: 28px; height: 2px; background: currentColor; }
  .titre { font-size: var(--t-xl); text-transform: uppercase; color: var(--marine); }
  .titre em { font-style: normal; color: var(--accent); }
  .chapo { color: var(--texte-doux); font-size: var(--t-m); }
  /* Ligne de cote : signature visuelle (trait fin + deux traits d'extrémité) */
  .cote { position: relative; height: 12px; width: 120px; }
  .cote::before { content: ""; position: absolute; left: 0; right: 0; top: 5px; height: 1.5px; background: var(--principale); }
  .cote::after { content: ""; position: absolute; inset: 0; border-inline: 1.5px solid var(--principale); }
  .tricolore { height: 4px; background: linear-gradient(90deg, var(--principale) 0 40%, var(--accent) 40% 70%, var(--vert) 70%); }

  /* Boutons */
  .bouton {
    --fond: var(--accent); --couleur: #fff;
    display: inline-flex; align-items: center; justify-content: center; gap: 0.6em;
    min-height: 48px; padding: 0 1.5em; border-radius: var(--r-bouton);
    background: var(--fond); color: var(--couleur); border: 1.5px solid transparent;
    font-weight: 700; font-size: var(--t-s); letter-spacing: 0.02em; white-space: nowrap;
    transition: background var(--transition), transform var(--transition), box-shadow var(--transition), border-color var(--transition), color var(--transition);
  }
  .bouton:hover { --fond: var(--accent-fonce); box-shadow: 0 10px 22px -10px color-mix(in oklab, var(--fond) 80%, transparent); }
  .bouton:active { transform: translateY(1px) scale(0.99); }
  .bouton--bleu { --fond: var(--principale); }
  .bouton--bleu:hover { --fond: var(--marine); }
  .bouton--contour { --fond: transparent; --couleur: currentColor; border-color: currentColor; }
  .bouton--contour:hover { --fond: color-mix(in oklab, currentColor 10%, transparent); box-shadow: none; }
  .bouton--clair { --fond: #fff; --couleur: var(--marine); border-color: var(--ligne); }
  .bouton--clair:hover { --fond: var(--beton); border-color: var(--principale); box-shadow: none; }
  .bouton--whatsapp { --fond: var(--whatsapp); }
  .bouton--whatsapp:hover { --fond: color-mix(in oklab, var(--whatsapp) 85%, black); }
  .bouton--sombre { --fond: var(--marine); }
  .bouton--sombre:hover { --fond: var(--nuit); }
  .bouton--danger { --fond: #c81e3c; }
  .bouton--danger:hover { --fond: #a3132d; }
  .bouton--plein { width: 100%; white-space: normal; text-align: center; }
  .bouton--petit { min-height: 38px; padding: 0 1em; font-size: var(--t-xs); }
  .bouton--grand { min-height: 56px; font-size: var(--t-m); }
  .bouton-icone {
    position: relative; display: grid; place-items: center; width: 42px; height: 42px; border-radius: var(--r-bouton);
    color: inherit; transition: background var(--transition), color var(--transition);
  }
  .bouton-icone:hover { background: color-mix(in oklab, currentColor 9%, transparent); }
  .lien { color: var(--principale); font-weight: 700; font-size: var(--t-s); text-decoration: underline; text-underline-offset: 3px; justify-self: center; padding: 0.2rem; }
  .lien:hover { color: var(--accent); }
  .pastille {
    position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px; border-radius: var(--r-plein);
    background: var(--accent); color: #fff; font-size: 11px; font-weight: 800; line-height: 18px; text-align: center;
    transform: scale(var(--echelle, 1)); transition: transform var(--transition);
  }
  .pastille:empty, .pastille[data-valeur="0"] { --echelle: 0; }

  /* Puces / étiquettes */
  .puce { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.22rem 0.6rem; border-radius: var(--r-puce); font-size: 11px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; background: var(--principale-voile); color: var(--principale); }
  .puce .icone { width: 13px; height: 13px; }
  .puce--rouge { background: var(--accent); color: #fff; }
  .puce--vert { background: color-mix(in oklab, var(--vert) 14%, white); color: #0c7a1f; }
  .puce--ambre { background: #fff4d6; color: #9a6400; }
  .puce--sombre { background: rgb(10 36 85 / 0.82); color: #fff; backdrop-filter: blur(6px); }
  .puce--exemple { background: #fff; color: var(--texte-doux); border: 1px dashed var(--ligne); }

  .etoiles { display: inline-flex; gap: 2px; color: var(--ambre); }
  .etoiles .icone { width: 15px; height: 15px; }
  .etoiles .vide { color: var(--ligne); }

  /* Segments (filtres) */
  .segments { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; background: var(--papier); border: 1px solid var(--ligne); border-radius: var(--r-carte); }
  .segments button { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.5rem 0.95rem; border-radius: var(--r-bouton); font-size: var(--t-s); font-weight: 700; color: var(--texte-doux); transition: background var(--transition), color var(--transition); }
  .segments button:hover { color: var(--marine); background: var(--beton); }
  .segments button[aria-pressed="true"] { background: var(--marine); color: #fff; }
  .segments .compte { font-size: 11px; opacity: 0.7; font-variant-numeric: tabular-nums; }

  /* Champs */
  .champ { display: grid; gap: 0.35rem; font-size: var(--t-xs); font-weight: 700; color: var(--marine); }
  .champ small { font-weight: 600; color: var(--texte-doux); }
  .champ input, .champ textarea, .champ select {
    width: 100%; min-height: 48px; padding: 0.65rem 0.9rem; font-size: var(--t-s); font-weight: 600; color: var(--texte);
    border: 1.5px solid var(--ligne); border-radius: var(--r-bouton); background: var(--papier);
    transition: border-color var(--transition), box-shadow var(--transition);
  }
  .champ select {
    appearance: none; padding-right: 2.4rem;
    background: var(--papier) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%230a2455' stroke-width='2'%3E%3Cpath d='m2 4 4 4 4-4'/%3E%3C/svg%3E") no-repeat right 0.9rem center;
  }
  .champ textarea { resize: vertical; min-height: 96px; line-height: 1.45; }
  .champ input:focus, .champ textarea:focus, .champ select:focus { border-color: var(--principale); outline: 0; box-shadow: 0 0 0 4px var(--principale-voile); }
  .champ [aria-invalid="true"] { border-color: #c81e3c; box-shadow: 0 0 0 4px rgb(200 30 60 / 0.12); }
  .champ-unite { position: relative; display: block; }
  .champ-unite input { padding-right: 3.2rem; }
  .champ-unite::after { content: attr(data-unite); position: absolute; right: 0.9rem; top: 50%; translate: 0 -50%; font-size: var(--t-xs); color: var(--texte-doux); font-weight: 700; }
  .champ-mdp { position: relative; display: block; }
  .champ-mdp input { padding-right: 3rem; }
  .voir-mdp { position: absolute; right: 4px; top: 50%; translate: 0 -50%; width: 40px; height: 40px; display: grid; place-items: center; color: var(--texte-doux); border-radius: var(--r-bouton); }
  .voir-mdp:hover { color: var(--marine); background: var(--beton); }
  .case { display: flex; gap: 0.6rem; align-items: flex-start; font-size: var(--t-s); line-height: 1.4; cursor: pointer; }
  .case input { width: 20px; height: 20px; margin-top: 1px; accent-color: var(--principale); flex: none; }
  .case a { color: var(--principale); text-decoration: underline; }
  .formulaire { display: grid; gap: var(--e-3); }
  .formulaire__intro { color: var(--texte-doux); font-size: var(--t-s); }
  .formulaire__aide { color: var(--texte-doux); font-size: var(--t-xs); text-align: center; }
  .formulaire__ligne { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: var(--e-3); }
  .form-erreur { color: #c81e3c; font-size: var(--t-s); font-weight: 600; }
  .form-erreur:empty, .form-info:empty { display: none; }
  .form-info { color: #137a3a; font-size: var(--t-s); font-weight: 600; background: #e9f8ef; padding: 0.7rem 0.9rem; border-radius: var(--r-bouton); }
  .separateur { display: flex; align-items: center; gap: var(--e-3); color: var(--texte-doux); font-size: var(--t-xs); margin-top: var(--e-2); }
  .separateur::before, .separateur::after { content: ""; flex: 1; height: 1px; background: var(--ligne); }
  .piege { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
  .chargement { color: var(--texte-doux); font-size: var(--t-s); padding: var(--e-5) 0; text-align: center; }
  .roue { width: 16px; height: 16px; border-radius: 50%; border: 2.5px solid rgb(255 255 255 / 0.4); border-top-color: #fff; animation: tourne-roue 700ms linear infinite; }
  .roue--sombre { border-color: var(--ligne); border-top-color: var(--accent); width: 28px; height: 28px; border-width: 3px; }
  @keyframes tourne-roue { to { rotate: 360deg; } }

  /* Choix en tuiles (formulaire de demande) */
  .choix { border: 0; padding: 0; display: grid; gap: 0.5rem; min-width: 0; }
  .choix legend { font-size: var(--t-xs); font-weight: 700; color: var(--marine); margin-bottom: 0.45rem; }
  .choix__grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); gap: 0.5rem; }
  .tuile-choix { position: relative; cursor: pointer; }
  .tuile-choix input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
  .tuile-choix span {
    display: flex; align-items: center; gap: 0.55rem; height: 100%; padding: 0.7rem 0.8rem; border-radius: var(--r-bouton);
    border: 1.5px solid var(--ligne); background: var(--papier); font-size: var(--t-s); font-weight: 600; line-height: 1.25;
    transition: border-color var(--transition), background var(--transition), box-shadow var(--transition);
  }
  .tuile-choix .icone { width: 22px; height: 22px; color: var(--principale); }
  .tuile-choix:hover span { border-color: color-mix(in oklab, var(--principale) 45%, var(--ligne)); }
  .tuile-choix input:checked + span { border-color: var(--principale); background: var(--principale-voile); box-shadow: inset 0 0 0 1px var(--principale); color: var(--marine); }
  .tuile-choix input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 2px; }

  /* Toast */
  .toasts { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); translate: -50% 0; z-index: 95; display: grid; gap: 8px; justify-items: center; width: min(520px, calc(100vw - 24px)); pointer-events: none; }
  .toast {
    max-width: 100%; background: var(--marine); color: #fff; padding: 0.8em 1.2em; border-radius: var(--r-bouton); border-left: 4px solid var(--accent);
    font-size: var(--t-s); font-weight: 600; box-shadow: var(--ombre-2); display: flex; align-items: center; gap: 0.6em;
    animation: toast-entre 260ms cubic-bezier(0.2, 0.9, 0.3, 1.2) both;
  }
  .toast .icone { color: #8fb3ff; }
  .toast.sort { animation: toast-sort 200ms ease-in both; }
  .toast--action { pointer-events: auto; }
  .toast--action button { margin-left: 0.4rem; background: var(--accent); color: #fff; font-weight: 800; padding: 0.35rem 0.7rem; border-radius: 6px; font-size: var(--t-xs); }
  @keyframes toast-entre { from { opacity: 0; transform: translateY(12px) scale(0.96); } }
  @keyframes toast-sort { to { opacity: 0; transform: translateY(8px); } }

  .vide { display: grid; justify-items: center; gap: var(--e-3); padding: var(--e-6) var(--e-4); text-align: center; color: var(--texte-doux); font-size: var(--t-s); }
  .vide > .icone { width: 44px; height: 44px; color: color-mix(in oklab, var(--principale) 45%, white); }
  .avatar { width: 42px; height: 42px; border-radius: 50%; flex: none; display: grid; place-items: center; background: var(--principale); color: #fff; font-weight: 800; font-size: 14px; }
  .statut { font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: var(--r-plein); background: var(--beton-2); color: var(--texte); white-space: nowrap; }
  .statut--nouvelle { background: #fff3e6; color: #b45309; }
  .statut--contactee { background: #e8f0ff; color: #1d4ed8; }
  .statut--visite { background: #f3e8ff; color: #7e22ce; }
  .statut--devis_envoye { background: #e0f7fa; color: #0e7490; }
  .statut--acceptee { background: #e9f8ef; color: #15803d; }
  .statut--en_cours { background: #fff4d6; color: #9a6400; }
  .statut--terminee { background: #dcfce7; color: #166534; }
  .statut--refusee, .statut--annulee { background: #f1f1f3; color: #6b6b75; }
  .statut--annulee { text-decoration: line-through; }
}

/* ------------------------------------------------------------ SECTIONS --- */
@layer sections {
  /* ===== BARRE D'INFORMATIONS (ordinateur) ===== */
  .barre-info { background: var(--nuit); color: #c8d4ee; font-size: var(--t-xs); }
  .barre-info__rangee { display: flex; align-items: center; gap: var(--e-5); min-height: 38px; }
  .barre-info a, .barre-info span { display: inline-flex; align-items: center; gap: 0.4rem; }
  .barre-info a:hover { color: #fff; }
  .barre-info .icone { width: 15px; height: 15px; color: #8fb3ff; }
  .barre-info__reseaux { margin-left: auto; display: flex; gap: 0.3rem; }
  .barre-info__reseaux a { width: 28px; height: 28px; justify-content: center; border-radius: 6px; }
  .barre-info__reseaux a:hover { background: rgb(255 255 255 / 0.1); }
  @media (max-width: 900px) { .barre-info { display: none; } }

  /* ===== EN-TÊTE ===== */
  .entete { position: sticky; top: 0; z-index: 60; background: rgb(255 255 255 / 0.94); backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid transparent; transition: border-color var(--transition), box-shadow var(--transition); }
  .entete.defile { border-bottom-color: var(--ligne); box-shadow: 0 8px 26px -18px rgb(10 36 85 / 0.45); }
  .entete__rangee { display: flex; align-items: center; gap: var(--e-4); min-height: var(--hauteur-entete); }
  .marque { display: flex; align-items: center; gap: 0.7rem; min-width: 0; }
  .marque__logo { height: 52px; width: auto; max-width: 150px; object-fit: contain; }
  .marque__texte { display: grid; line-height: 1.05; min-width: 0; }
  .marque__nom { font-family: var(--police-titre); font-weight: 800; font-size: 1.32rem; color: var(--marine); text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .marque__slogan { font-size: 11.5px; color: var(--texte-doux); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; }
  .nav { display: flex; gap: 0.15rem; margin-inline: auto; }
  .nav a { position: relative; padding: 0.55rem 0.8rem; font-weight: 700; font-size: var(--t-s); color: var(--marine); border-radius: var(--r-bouton); transition: color var(--transition), background var(--transition); }
  .nav a::after { content: ""; position: absolute; left: 0.8rem; right: 0.8rem; bottom: 0.25rem; height: 2px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform var(--transition); }
  .nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
  .nav a[aria-current="page"] { color: var(--principale); }
  .entete__actions { display: flex; align-items: center; gap: 0.25rem; margin-left: auto; color: var(--marine); }
  .nav ~ .entete__actions { margin-left: 0; }
  .entete__cta { margin-left: 0.4rem; }
  .entete__menu { display: none; }
  .bouton-installer {
    display: inline-flex; align-items: center; gap: 0.45rem; height: 40px; padding: 0 0.95rem; border-radius: var(--r-plein);
    background: var(--marine); color: #fff; font-size: var(--t-xs); font-weight: 800; white-space: nowrap;
    transition: background var(--transition); animation: apparait 400ms ease both;
  }
  .bouton-installer:hover { background: var(--accent); }
  .bouton-installer .icone { width: 18px; height: 18px; }
  .pastille-compte { position: absolute; top: 7px; right: 7px; width: 10px; height: 10px; border-radius: 50%; background: var(--vert); box-shadow: 0 0 0 2px var(--papier); }
  .progression { position: absolute; left: 0; bottom: -1px; height: 3px; width: 100%; background: linear-gradient(90deg, var(--principale), var(--accent)); transform-origin: left; transform: scaleX(0); }
  @supports (animation-timeline: scroll()) {
    .progression { animation: progression linear both; animation-timeline: scroll(root); }
    @keyframes progression { to { transform: scaleX(1); } }
  }
  @keyframes apparait { from { opacity: 0; transform: scale(0.94); } }

  @media (max-width: 1180px) { .entete__cta { display: none; } }
  @media (max-width: 1020px) {
    .entete__menu { display: grid; }
    .nav {
      position: fixed; inset: calc(var(--hauteur-entete) + env(safe-area-inset-top, 0px)) 0 auto 0; z-index: 59; margin: 0;
      flex-direction: column; gap: 0; padding: var(--e-3) var(--gouttiere) var(--e-5); background: var(--papier);
      border-bottom: 1px solid var(--ligne); box-shadow: var(--ombre-2);
      transform: translateY(-12px); opacity: 0; visibility: hidden; transition: transform var(--transition), opacity var(--transition), visibility var(--transition);
    }
    .entete.menu-ouvert .nav { transform: none; opacity: 1; visibility: visible; }
    .nav a { padding: 0.9rem 0.4rem; border-bottom: 1px solid var(--beton-2); border-radius: 0; font-size: var(--t-m); }
    .nav a::after { display: none; }
    .nav .nav__cta { display: flex; margin-top: var(--e-3); border: 0; justify-content: center; color: #fff; }
  }
  .nav__cta { display: none; }
  @media (max-width: 560px) {
    .marque__slogan { display: none; }
    .marque__logo { height: 44px; }
    .marque__nom { font-size: 1.05rem; line-height: 0.95; white-space: normal; overflow: visible; max-width: 7.2em; }
    .bouton-installer span { display: none; }
    .bouton-installer { padding: 0; width: 40px; justify-content: center; }
  }
  @media (max-width: 380px) { .marque__nom { display: none; } }

  /* ===== HÉROS ===== */
  .heros { position: relative; isolation: isolate; color: #fff; background: var(--trame), radial-gradient(90% 70% at 85% 30%, color-mix(in oklab, var(--principale) 70%, transparent), transparent 70%), var(--nuit); overflow: hidden; }
  .heros::after { content: ""; position: absolute; inset: auto 0 0; height: 90px; background: var(--beton); clip-path: polygon(0 100%, 100% 30%, 100% 100%); z-index: -1; }
  .heros__grille { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: var(--e-6); align-items: center; padding-block: clamp(2.5rem, 6vw, 5rem) clamp(6rem, 9vw, 8rem); }
  .heros__texte { display: grid; gap: var(--e-4); align-content: center; }
  .heros .surtitre { color: #ff8a8e; }
  .heros h1 { font-size: var(--t-2xl); text-transform: uppercase; line-height: 0.98; }
  .heros h1 em { font-style: normal; color: var(--accent); text-shadow: 0 2px 30px color-mix(in oklab, var(--accent) 45%, transparent); }
  .heros__slogan { font-family: var(--police-titre); font-style: italic; font-weight: 600; font-size: var(--t-l); color: #dbe6ff; display: flex; gap: 0.6rem; align-items: center; }
  .heros__slogan::before { content: ""; width: 34px; height: 3px; background: var(--accent); }
  .heros__chapo { color: #c7d5f2; max-width: 56ch; }
  .heros__actions { display: flex; flex-wrap: wrap; gap: var(--e-3); margin-top: var(--e-2); }
  .heros__actions .bouton--contour { color: #fff; }
  .heros__engagements { display: flex; flex-wrap: wrap; gap: 0.4rem 1.1rem; font-size: var(--t-s); font-weight: 700; color: #e6edfb; margin-top: var(--e-2); }
  .heros__engagements li { display: inline-flex; align-items: center; gap: 0.4rem; }
  .heros__engagements .icone { color: var(--vert); width: 20px; height: 20px; }
  .heros__visuel { position: relative; aspect-ratio: 9 / 8; border-radius: var(--r-panneau); }
  .heros__visuel > svg { width: 100%; height: 100%; }
  .heros__photo { position: relative; aspect-ratio: 4 / 3.4; border-radius: var(--r-panneau); overflow: hidden; clip-path: polygon(8% 0, 100% 0, 100% 100%, 0 100%, 0 12%); box-shadow: var(--ombre-3); }
  .heros__photo img { width: 100%; height: 100%; object-fit: cover; }
  .heros__photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgb(2 8 24 / 0.55)); }
  .heros__badge { position: absolute; left: -14px; bottom: 26px; z-index: 2; display: flex; align-items: center; gap: 0.6rem; padding: 0.75rem 1rem; background: #fff; color: var(--marine); border-radius: var(--r-carte); box-shadow: var(--ombre-2); font-weight: 700; font-size: var(--t-s); }
  .heros__badge .icone { width: 30px; height: 30px; color: var(--accent); }
  .heros__badge small { display: block; font-weight: 600; color: var(--texte-doux); font-size: var(--t-xs); }
  /* Dessin du bâtiment : les traits se tracent à l'ouverture */
  .visuel--heros .trace { stroke-dasharray: 1400; stroke-dashoffset: 1400; animation: trace 2.2s cubic-bezier(0.4, 0, 0.2, 1) forwards; }
  .visuel--heros .trace--2 { animation-delay: 0.6s; }
  .visuel--heros .trace--3 { animation-delay: 1.4s; }
  .visuel--heros .apparait { opacity: 0; animation: fondu 0.9s ease forwards 1.6s; }
  .visuel--heros .apparait--2 { animation-delay: 2.1s; }
  .visuel--heros .apparait--3 { animation-delay: 2.5s; }
  .visuel--heros .grue-anim { transform-origin: 170px 560px; animation: grue 1.4s cubic-bezier(0.2, 0.9, 0.2, 1) both 0.2s; }
  @keyframes trace { to { stroke-dashoffset: 0; } }
  @keyframes fondu { to { opacity: 1; } }
  @keyframes grue { from { opacity: 0; transform: translateY(40px); } }
  @media (max-width: 900px) {
    .heros__grille { grid-template-columns: minmax(0, 1fr); padding-bottom: 5.5rem; }
    .heros__visuel { max-width: 520px; width: 100%; justify-self: center; aspect-ratio: 9 / 7; }
    .heros__photo { max-width: 620px; width: 100%; justify-self: center; }
  }

  /* Bandeau des expertises sous le héros (comme le flyer) */
  .bandeau-expertises { position: relative; z-index: 2; margin-top: -4.4rem; }
  .bandeau-expertises__grille { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); background: var(--papier); border-radius: var(--r-panneau); box-shadow: var(--ombre-2); overflow: hidden; }
  .raccourci { display: flex; gap: 0.8rem; align-items: center; padding: 1.1rem 1.2rem; border-right: 1px solid var(--beton-2); transition: background var(--transition); }
  .raccourci:last-child { border-right: 0; }
  .raccourci:hover { background: var(--beton); }
  .raccourci__icone { flex: none; width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; background: var(--principale); color: #fff; box-shadow: 0 0 0 5px var(--principale-voile); }
  .raccourci__icone .icone { width: 24px; height: 24px; }
  .raccourci strong { display: block; font-family: var(--police-titre); text-transform: uppercase; font-size: 1.08rem; color: var(--marine); line-height: 1.1; }
  .raccourci small { display: block; font-size: var(--t-xs); color: var(--texte-doux); line-height: 1.3; }
  @media (max-width: 640px) { .raccourci { border-right: 0; border-bottom: 1px solid var(--beton-2); } }

  /* ===== CHIFFRES CLÉS ===== */
  .chiffres { padding-top: var(--e-6); }
  .chiffres__grille { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: var(--e-4); }
  .chiffre { text-align: center; padding: var(--e-4); }
  .chiffre strong { display: block; font-family: var(--police-titre); font-size: clamp(2.4rem, 2rem + 2vw, 3.4rem); font-weight: 800; color: var(--principale); line-height: 1; }
  .chiffre span { font-weight: 700; color: var(--texte-doux); font-size: var(--t-s); text-transform: uppercase; letter-spacing: 0.06em; }

  /* ===== EXPERTISES ===== */
  .expertises { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr)); gap: var(--e-5); }
  .expertise { display: grid; grid-template-rows: auto 1fr; background: var(--papier); border: 1px solid var(--ligne); border-radius: var(--r-panneau); overflow: hidden; transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition); }
  .expertise:hover { transform: translateY(-4px); box-shadow: var(--ombre-2); border-color: color-mix(in oklab, var(--principale) 25%, var(--ligne)); }
  .expertise[data-expertise] { cursor: pointer; }
  .expertise:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
  .expertise__voir { position: absolute; top: 10px; right: 10px; z-index: 2; opacity: 0.92; transition: opacity var(--transition), transform var(--transition); }
  .expertise:hover .expertise__voir { opacity: 1; transform: translateY(-1px); }
  .expertise__media { position: relative; aspect-ratio: 16 / 10; background: var(--beton-2); overflow: hidden; }
  .expertise__media > svg, .expertise__media > img { width: 100%; height: 100%; object-fit: cover; transition: transform 600ms cubic-bezier(0.2, 0.7, 0.2, 1); }
  .expertise:hover .expertise__media > * { transform: scale(1.04); }
  .expertise__icone { position: absolute; left: 1rem; bottom: -24px; z-index: 2; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: var(--principale); color: #fff; border: 4px solid var(--papier); box-shadow: var(--ombre-1); }
  .expertise__icone .icone { width: 26px; height: 26px; }
  .expertise__corps { display: flex; flex-direction: column; gap: var(--e-3); padding: 2.1rem 1.3rem 1.3rem; }
  .expertise h3 { font-size: 1.55rem; text-transform: uppercase; color: var(--marine); }
  .expertise__resume { color: var(--principale); font-weight: 700; font-size: var(--t-s); margin-top: -0.5rem; }
  .expertise p { color: var(--texte-doux); font-size: var(--t-s); }
  .points { display: grid; gap: 0.35rem; font-size: var(--t-s); }
  .points li { display: flex; gap: 0.5rem; align-items: flex-start; }
  .points .icone { width: 18px; height: 18px; color: var(--vert); margin-top: 2px; }
  .expertise .bouton { align-self: flex-start; margin-top: auto; }
  /* 6 expertises : 3 + 3 sur grand écran, 2 + 2 + 2 sur tablette */
  @media (min-width: 1000px) { .expertises:has(> .expertise:nth-child(6):last-child) { grid-template-columns: repeat(3, 1fr); } }
  @media (min-width: 640px) and (max-width: 999px) { .expertises:has(> .expertise:nth-child(6):last-child) { grid-template-columns: repeat(2, 1fr); } }
  /* 5 expertises sur grand écran : 3 cartes puis 2 cartes larges (jamais de carte orpheline) */
  @media (min-width: 1100px) {
    .expertises:has(> .expertise:nth-child(5):last-child) { grid-template-columns: repeat(6, 1fr); }
    .expertises:has(> .expertise:nth-child(5):last-child) > .expertise { grid-column: span 2; }
    .expertises:has(> .expertise:nth-child(5):last-child) > .expertise:nth-child(n+4) { grid-column: span 3; grid-template-columns: 46% 1fr; grid-template-rows: none; }
    .expertises:has(> .expertise:nth-child(5):last-child) > .expertise:nth-child(n+4) .expertise__media { aspect-ratio: auto; min-height: 100%; }
    .expertises:has(> .expertise:nth-child(5):last-child) > .expertise:nth-child(n+4) .expertise__icone { bottom: 1rem; left: auto; right: 1rem; }
    .expertises:has(> .expertise:nth-child(5):last-child) > .expertise:nth-child(n+4) .expertise__corps { padding-top: 1.5rem; }
  }

  /* ===== PLANS ===== */
  .outils-plans { display: flex; flex-wrap: wrap; gap: var(--e-3); align-items: center; margin-bottom: var(--e-5); }
  .outils-plans .segments { flex: 1 1 auto; }
  .outils-plans select { min-height: 46px; padding: 0 2.4rem 0 0.9rem; border: 1px solid var(--ligne); border-radius: var(--r-carte); font-weight: 700; font-size: var(--t-s); color: var(--marine); appearance: none;
    background: var(--papier) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%230a2455' stroke-width='2'%3E%3Cpath d='m2 4 4 4 4-4'/%3E%3C/svg%3E") no-repeat right 0.9rem center; }
  .recherche { display: flex; align-items: center; gap: 0.5rem; padding: 0 0.9rem; min-height: 46px; flex: 0 1 280px; background: var(--papier); border: 1px solid var(--ligne); border-radius: var(--r-carte); }
  .recherche:focus-within { border-color: var(--principale); box-shadow: 0 0 0 4px var(--principale-voile); }
  .recherche input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: var(--t-s); }
  .recherche .icone { color: var(--texte-doux); width: 18px; height: 18px; }
  .resume-liste { font-size: var(--t-s); color: var(--texte-doux); margin-bottom: var(--e-3); }

  .grille-plans { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: var(--e-5); }
  .carte-plan { position: relative; display: grid; grid-template-rows: auto 1fr; background: var(--papier); border: 1px solid var(--ligne); border-radius: var(--r-panneau); overflow: hidden; cursor: pointer; transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition); }
  .carte-plan:hover, .carte-plan:focus-visible { transform: translateY(-4px); box-shadow: var(--ombre-2); border-color: color-mix(in oklab, var(--principale) 30%, var(--ligne)); }
  .carte-plan__media { position: relative; aspect-ratio: 4 / 3; background: #fbfcfe; border-bottom: 1px solid var(--beton-2); overflow: hidden; }
  .carte-plan__media > svg, .carte-plan__media > img { width: 100%; height: 100%; object-fit: cover; }
  .carte-plan__media > .visuel--plan { object-fit: contain; padding: 0.2rem; }
  .carte-plan__puces { position: absolute; top: 10px; left: 10px; z-index: 2; display: flex; flex-wrap: wrap; gap: 0.35rem; }
  .carte-plan__nombre { position: absolute; bottom: 10px; left: 10px; z-index: 2; }
  .signet { position: absolute; top: 8px; right: 8px; z-index: 3; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: rgb(255 255 255 / 0.95); color: var(--marine); box-shadow: var(--ombre-1); transition: transform var(--transition), background var(--transition), color var(--transition); }
  .signet:hover { transform: scale(1.08); }
  .signet[aria-pressed="true"] { background: var(--accent); color: #fff; }
  .signet .icone { width: 20px; height: 20px; }
  .carte-plan__corps { display: grid; gap: 0.6rem; align-content: start; padding: 1rem 1.15rem 1.15rem; }
  .carte-plan__type { font-size: 11px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); }
  .carte-plan h3 { font-size: 1.45rem; text-transform: uppercase; color: var(--marine); }
  .carte-plan__resume { font-size: var(--t-s); color: var(--texte-doux); }
  .specs { display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; font-size: var(--t-s); font-weight: 700; color: var(--marine); }
  .specs li { display: inline-flex; align-items: center; gap: 0.35rem; }
  .specs .icone { width: 18px; height: 18px; color: var(--principale); }
  .carte-plan__pied { display: flex; justify-content: space-between; align-items: center; gap: var(--e-3); padding-top: 0.75rem; margin-top: 0.2rem; border-top: 1px dashed var(--ligne); }
  .budget { display: grid; line-height: 1.15; }
  .budget small { font-size: 11px; color: var(--texte-doux); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }
  .budget strong { font-family: var(--police-titre); font-size: 1.25rem; color: var(--principale); font-variant-numeric: tabular-nums; }
  .carte-plan__voir { display: inline-flex; align-items: center; gap: 0.3rem; font-weight: 800; font-size: var(--t-s); color: var(--accent); }

  /* ===== RÉALISATIONS ===== */
  .grille-realisations { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); grid-auto-rows: 260px; grid-auto-flow: dense; gap: var(--e-4); }
  .realisation { position: relative; border-radius: var(--r-panneau); overflow: hidden; background: var(--marine); color: #fff; cursor: pointer; isolation: isolate; text-align: left; }
  .realisation--grande { grid-row: span 2; }
  .realisation > svg, .realisation > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform 700ms cubic-bezier(0.2, 0.7, 0.2, 1); }
  .realisation::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, transparent 40%, rgb(2 8 24 / 0.86)); }
  .realisation:hover > svg, .realisation:hover > img { transform: scale(1.05); }
  .realisation__haut { position: absolute; top: 12px; left: 12px; right: 12px; display: flex; flex-wrap: wrap; gap: 0.35rem; }
  .realisation__bas { position: absolute; left: 0; right: 0; bottom: 0; padding: 1rem 1.1rem; display: grid; gap: 0.2rem; }
  .realisation h3 { font-size: 1.35rem; text-transform: uppercase; }
  .realisation small { color: #c8d4ee; font-size: var(--t-xs); font-weight: 600; display: inline-flex; gap: 0.35rem; align-items: center; }
  .realisation small .icone { width: 14px; height: 14px; }
  .vide-realisations { background: var(--papier); border: 1px dashed var(--ligne); border-radius: var(--r-panneau); }

  /* ===== DÉMARCHE ===== */
  .demarche { counter-reset: etape; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); gap: var(--e-4); }
  .etape { position: relative; display: grid; gap: 0.5rem; padding: 1.3rem 1.1rem; background: var(--papier); border: 1px solid var(--ligne); border-radius: var(--r-carte); }
  .etape::before { counter-increment: etape; content: "0" counter(etape); font-family: var(--police-titre); font-size: 2.6rem; font-weight: 800; line-height: 1; color: transparent; -webkit-text-stroke: 1.5px var(--principale); }
  .etape h3 { font-size: 1.2rem; text-transform: uppercase; color: var(--marine); }
  .etape p { font-size: var(--t-s); color: var(--texte-doux); }
  .etape .icone { position: absolute; top: 1.2rem; right: 1.1rem; width: 28px; height: 28px; color: var(--accent); }

  /* ===== POURQUOI NOUS ===== */
  .pourquoi { background: var(--trame), var(--marine); color: #fff; }
  .pourquoi__grille { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
  .valeur { display: flex; gap: 1rem; align-items: flex-start; padding: var(--e-5) var(--e-4); border-left: 1px solid rgb(255 255 255 / 0.12); }
  .valeur:first-child { border-left: 0; }
  .valeur__icone { flex: none; width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; border: 2px solid rgb(255 255 255 / 0.7); }
  .valeur__icone .icone { width: 28px; height: 28px; }
  .valeur h3 { font-size: 1.2rem; text-transform: uppercase; }
  .valeur p { font-size: var(--t-s); color: #c8d4ee; }
  @media (max-width: 760px) { .valeur { border-left: 0; border-top: 1px solid rgb(255 255 255 / 0.12); } .valeur:first-child { border-top: 0; } }

  /* ===== AVIS ===== */
  .temoignages { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: var(--e-4); }
  .temoignage { display: grid; gap: var(--e-3); align-content: start; padding: var(--e-5); background: var(--papier); border: 1px solid var(--ligne); border-radius: var(--r-panneau); }
  .temoignage blockquote { font-size: var(--t-m); color: var(--texte); }
  .temoignage__auteur { display: flex; gap: 0.7rem; align-items: center; }
  .temoignage__auteur strong { display: block; font-size: var(--t-s); }
  .temoignage__auteur span { font-size: var(--t-xs); color: var(--texte-doux); }

  /* ===== DEMANDE DE TRAVAUX ===== */
  .zone-devis { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: var(--e-5); align-items: start; }
  @media (max-width: 960px) { .zone-devis { grid-template-columns: minmax(0, 1fr); } }
  .carte-devis { background: var(--papier); border: 1px solid var(--ligne); border-radius: var(--r-panneau); box-shadow: var(--ombre-1); overflow: hidden; }
  .etapes-devis { display: grid; grid-template-columns: repeat(4, 1fr); background: var(--beton); border-bottom: 1px solid var(--ligne); }
  .etapes-devis button { display: flex; gap: 0.5rem; align-items: center; justify-content: center; padding: 0.9rem 0.4rem; font-size: var(--t-xs); font-weight: 700; color: var(--texte-doux); border-bottom: 3px solid transparent; }
  .etapes-devis button span { width: 26px; height: 26px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--papier); border: 1.5px solid var(--ligne); font-size: 12px; color: var(--texte-doux); }
  .etapes-devis button[aria-current="step"] { color: var(--marine); border-bottom-color: var(--accent); }
  .etapes-devis button[aria-current="step"] span { background: var(--accent); border-color: var(--accent); color: #fff; }
  .etapes-devis button.fait span { background: var(--vert); border-color: var(--vert); color: #fff; }
  @media (max-width: 620px) { .etapes-devis button em { display: none; } }
  .etapes-devis em { font-style: normal; }
  .form-devis { padding: var(--e-5); }
  .pas { display: grid; gap: var(--e-4); animation: apparait 260ms ease both; }
  .pas h3 { font-size: 1.5rem; text-transform: uppercase; color: var(--marine); }
  .pas__intro { font-size: var(--t-s); color: var(--texte-doux); margin-top: -0.6rem; }
  .selection-devis { display: flex; flex-wrap: wrap; gap: 0.5rem; }
  .selection-devis:empty { display: none; }
  .jeton-plan { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.35rem 0.4rem 0.35rem 0.7rem; background: var(--principale-voile); border: 1px solid color-mix(in oklab, var(--principale) 30%, white); border-radius: var(--r-plein); font-size: var(--t-xs); font-weight: 700; color: var(--marine); }
  .jeton-plan button { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: var(--texte-doux); }
  .jeton-plan button:hover { background: #fff; color: var(--accent); }
  .jeton-plan .icone { width: 14px; height: 14px; }
  .ajout-plan { display: inline-flex; align-items: center; gap: 0.35rem; font-size: var(--t-xs); font-weight: 800; color: var(--principale); }
  .pied-devis { display: flex; justify-content: space-between; gap: var(--e-3); padding: var(--e-4) var(--e-5); border-top: 1px solid var(--ligne); background: var(--beton); }
  .pied-devis .bouton { min-width: 140px; }
  .pied-devis__note { font-size: var(--t-xs); color: var(--texte-doux); padding: 0 var(--e-5) var(--e-4); background: var(--beton); }
  .canaux { border: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: var(--e-2); }
  .canaux legend { font-size: var(--t-xs); font-weight: 700; margin-bottom: 0.45rem; color: var(--marine); }
  .canal { position: relative; cursor: pointer; }
  .canal input { position: absolute; opacity: 0; inset: 0; }
  .canal__carte { display: flex; gap: 0.6rem; align-items: center; height: 100%; padding: 0.85rem; border-radius: var(--r-carte); border: 1.5px solid var(--ligne); background: var(--papier); transition: border-color var(--transition), background var(--transition), box-shadow var(--transition); }
  .canal__carte strong { display: block; font-size: var(--t-s); }
  .canal__carte small { display: block; font-size: var(--t-xs); color: var(--texte-doux); line-height: 1.25; }
  .canal__icone { width: 28px; height: 28px; color: var(--marine); }
  .canal__icone--wa { color: var(--whatsapp); }
  .canal input:checked + .canal__carte { border-color: var(--principale); background: var(--principale-voile); box-shadow: 0 0 0 3px var(--principale-voile); }
  .canal input:focus-visible + .canal__carte { outline: 3px solid var(--accent); outline-offset: 2px; }
  .canaux--seul { grid-template-columns: 1fr; }
  @media (max-width: 400px) { .canaux { grid-template-columns: 1fr; } }
  .info-compte { display: flex; gap: 0.5rem; align-items: flex-start; font-size: var(--t-xs); color: var(--texte-doux); }
  .info-compte:empty { display: none; }
  .info-compte .icone { width: 18px; height: 18px; color: var(--principale); }
  .info-compte .lien { font-size: var(--t-xs); padding: 0; }
  .secours { display: grid; gap: var(--e-2); padding: var(--e-4); border-radius: var(--r-carte); background: #fff7ed; border: 1.5px solid #fdba74; font-size: var(--t-s); }
  .succes { display: grid; gap: var(--e-3); justify-items: center; text-align: center; padding: var(--e-6) var(--e-5); outline: 0; }
  .succes > .bouton { width: min(100%, 420px); }
  .succes__icone { width: 80px; height: 80px; border-radius: 50%; display: grid; place-items: center; background: #e9f8ef; color: #16a34a; animation: pop 520ms cubic-bezier(0.2, 0.9, 0.3, 1.4) both; }
  .succes__icone .icone { width: 42px; height: 42px; stroke-width: 2.6; animation: pop 420ms 160ms cubic-bezier(0.2, 0.9, 0.3, 1.5) both; }
  @keyframes pop { from { transform: scale(0.4); opacity: 0; } }
  .succes h3 { font-size: var(--t-xl); text-transform: uppercase; color: var(--marine); }
  .succes__ref strong { font-family: var(--police-titre); font-size: 1.3em; letter-spacing: 0.04em; background: var(--beton); padding: 0.15rem 0.6rem; border-radius: var(--r-puce); }
  .succes__etape { max-width: 520px; background: var(--beton); border-radius: var(--r-carte); padding: var(--e-3) var(--e-4); font-size: var(--t-s); text-align: left; }
  .succes__compte { font-size: var(--t-s); color: var(--texte-doux); }

  .contact-direct { position: sticky; top: calc(var(--hauteur-entete) + 16px); display: grid; gap: var(--e-4); padding: var(--e-5); border-radius: var(--r-panneau); color: #fff; background: var(--trame), var(--marine); overflow: hidden; }
  .contact-direct h3 { font-size: 1.6rem; text-transform: uppercase; }
  .contact-direct p { color: #c8d4ee; font-size: var(--t-s); }
  .contact-direct__liste { display: grid; gap: 0.6rem; }
  .contact-direct__liste a, .contact-direct__liste span { display: flex; gap: 0.7rem; align-items: center; font-weight: 700; }
  .contact-direct__liste .icone { width: 38px; height: 38px; padding: 9px; border-radius: 50%; background: rgb(255 255 255 / 0.1); color: #fff; }
  .contact-direct__liste a:hover .icone { background: var(--accent); }
  .contact-direct .tricolore { margin: calc(-1 * var(--e-5)) calc(-1 * var(--e-5)) 0; }

  /* ===== PIED DE PAGE ===== */
  .pied { background: var(--nuit); color: #c8d4ee; }
  .pied__grille { display: grid; grid-template-columns: 1.3fr 1fr 1.2fr 1.2fr; gap: var(--e-6); padding-block: var(--e-7) var(--e-6); }
  .pied h3 { color: #fff; font-size: 1.15rem; text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: var(--e-3); }
  .pied a:hover { color: #fff; }
  .pied__plaque { display: inline-flex; background: #fff; padding: 10px 14px; border-radius: var(--r-carte); }
  .pied__logo { height: 70px; width: auto; max-width: 200px; object-fit: contain; }
  .pied__nom { font-family: var(--police-titre); font-size: 1.6rem; font-weight: 800; color: #fff; text-transform: uppercase; }
  .pied__slogan { margin-top: var(--e-3); font-size: var(--t-s); font-style: italic; }
  .pied__liens { display: grid; gap: 0.45rem; font-size: var(--t-s); }
  .pied__coord { display: grid; gap: 0.6rem; font-size: var(--t-s); }
  .pied__coord li { display: flex; gap: 0.6rem; align-items: start; }
  .pied__coord .icone { color: var(--accent); width: 18px; height: 18px; margin-top: 3px; }
  .reseaux { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-top: var(--e-3); }
  .reseaux a { width: 40px; height: 40px; border-radius: var(--r-bouton); display: grid; place-items: center; background: rgb(255 255 255 / 0.08); color: #fff; transition: background var(--transition); }
  .reseaux a:hover { background: var(--accent); }
  .reseaux .icone { width: 19px; height: 19px; }
  .newsletter { display: flex; margin-top: var(--e-2); border-radius: var(--r-bouton); overflow: hidden; background: rgb(255 255 255 / 0.08); }
  .newsletter input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; padding: 0.8em 1em; font-size: var(--t-s); color: #fff; }
  .newsletter input::placeholder { color: #8b97b3; }
  .newsletter button { width: 50px; display: grid; place-items: center; background: var(--accent); color: #fff; }
  .pied__bas { border-top: 1px solid rgb(255 255 255 / 0.1); padding-block: var(--e-4); display: flex; justify-content: space-between; flex-wrap: wrap; gap: var(--e-3); font-size: var(--t-xs); }
  .pied__bas nav { display: flex; gap: var(--e-4); flex-wrap: wrap; }
  /* Téléphone : le bas de page n'est jamais caché sous le bouton WhatsApp flottant ni sous la bannière d'installation */
  @media (max-width: 760px) {
    .pied__bas { padding-bottom: calc(var(--e-4) + 84px + env(safe-area-inset-bottom, 0px)); }
    body:has(.banniere-app:not([hidden])) .pied__bas { padding-bottom: calc(var(--e-4) + 160px + env(safe-area-inset-bottom, 0px)); }
  }
  @media (max-width: 1000px) { .pied__grille { grid-template-columns: 1fr 1fr; } }
  @media (max-width: 560px) { .pied__grille { grid-template-columns: 1fr; } }

  /* ===== BOUTON WHATSAPP FLOTTANT ===== */
  .wa-flottant { position: fixed; z-index: 80; right: calc(20px + env(safe-area-inset-right, 0px)); bottom: calc(20px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; gap: 0.7rem; }
  .wa-flottant__etiquette { display: grid; line-height: 1.2; background: var(--papier); color: var(--marine); font-weight: 700; font-size: var(--t-xs); padding: 0.55em 0.95em; border-radius: var(--r-carte); box-shadow: var(--ombre-2); border: 1.5px solid var(--whatsapp); transition: opacity var(--transition), transform var(--transition); }
  .wa-flottant__etiquette small { font-weight: 600; color: var(--texte-doux); }
  .wa-flottant__bouton { position: relative; width: 62px; height: 62px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--whatsapp); box-shadow: 0 10px 28px -6px color-mix(in oklab, var(--whatsapp) 70%, transparent); transition: transform var(--transition); }
  .wa-flottant__bouton .icone { width: 32px; height: 32px; }
  .wa-flottant:hover .wa-flottant__bouton { transform: scale(1.08) rotate(-6deg); }
  .wa-flottant__bouton::before { content: ""; position: absolute; inset: -5px; border-radius: 50%; z-index: -1; background: conic-gradient(from var(--angle), var(--whatsapp), transparent 40%, var(--whatsapp) 70%, transparent); animation: tourne 3.2s linear infinite; }
  .wa-flottant__bouton::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--whatsapp); animation: onde 2.4s ease-out infinite; }
  @keyframes tourne { to { --angle: 360deg; } }
  @keyframes onde { from { opacity: 0.8; transform: scale(1); } to { opacity: 0; transform: scale(1.7); } }
  .wa-flottant.discret .wa-flottant__etiquette { opacity: 0; transform: translateX(10px); pointer-events: none; }
  @media (max-width: 640px) { .wa-flottant__etiquette { display: none; } .wa-flottant__bouton { width: 58px; height: 58px; } }
  @media (hover: hover) { .wa-flottant.discret:hover .wa-flottant__etiquette { opacity: 1; transform: none; } }

  /* ===== FICHES (plan, réalisation) ===== */
  .fiche { width: min(1180px, 100% - 24px); max-width: none; max-height: min(94dvh, 920px); margin: auto; padding: 0; border: 0; border-radius: var(--r-panneau); background: var(--papier); color: var(--texte); box-shadow: var(--ombre-3); overflow: hidden; }
  .fiche::backdrop { background: rgb(2 8 24 / 0.66); backdrop-filter: blur(6px); }
  .fiche[open] { animation: fiche-ouvre 320ms cubic-bezier(0.2, 0.9, 0.25, 1) both; }
  .fiche[open]::backdrop { animation: fondu-fond 320ms ease both; }
  @keyframes fiche-ouvre { from { opacity: 0; transform: translateY(24px) scale(0.97); } }
  @keyframes fondu-fond { from { opacity: 0; } }
  .fiche__cadre { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); max-height: inherit; overflow: auto; overscroll-behavior: contain; }
  .fiche__fermer { position: absolute; top: 12px; right: 12px; z-index: 6; background: var(--papier); box-shadow: var(--ombre-1); border-radius: 50%; }
  .galerie { display: grid; grid-template-rows: minmax(0, 1fr) auto; gap: var(--e-3); padding: var(--e-4); background: var(--beton); min-width: 0; }
  .galerie__scene { position: relative; aspect-ratio: 4 / 3; border-radius: var(--r-carte); overflow: hidden; background: #fff; touch-action: pan-y; cursor: zoom-in; border: 1px solid var(--ligne); }
  .galerie__image { position: absolute; inset: 0; transition: transform 180ms ease-out, opacity 220ms ease; }
  .galerie__image > * { width: 100%; height: 100%; object-fit: contain; }
  .galerie__image > img.couvre { object-fit: cover; }
  .galerie__scene.zoom .galerie__image { transform: scale(2.1); }
  .galerie__scene.change .galerie__image { opacity: 0; }
  .galerie__fleche { position: absolute; top: 50%; translate: 0 -50%; z-index: 4; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: rgb(255 255 255 / 0.95); color: var(--marine); box-shadow: var(--ombre-1); opacity: 0; transition: opacity var(--transition); }
  .galerie__scene:hover .galerie__fleche, .galerie__fleche:focus-visible { opacity: 1; }
  .galerie__fleche--prec { left: 10px; }
  .galerie__fleche--suiv { right: 10px; }
  .galerie__compteur { position: absolute; bottom: 10px; left: 10px; z-index: 4; background: rgb(10 36 85 / 0.82); color: #fff; font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: var(--r-plein); font-variant-numeric: tabular-nums; }
  .galerie__vignettes { display: flex; gap: var(--e-2); overflow-x: auto; padding: 2px; scrollbar-width: thin; }
  .galerie__vignette { flex: none; width: 74px; aspect-ratio: 4 / 3; border-radius: var(--r-bouton); overflow: hidden; background: #fff; border: 2px solid var(--ligne); opacity: 0.75; transition: opacity var(--transition), border-color var(--transition); }
  .galerie__vignette > * { width: 100%; height: 100%; object-fit: cover; }
  .galerie__vignette:hover { opacity: 1; }
  .galerie__vignette[aria-current="true"] { border-color: var(--accent); opacity: 1; }
  /* Filigrane : nom + logo répétés en diagonale sur les images agrandies */
  .filigrane { position: absolute; inset: -50%; z-index: 3; pointer-events: none; display: flex; flex-wrap: wrap; align-content: center; justify-content: center; gap: 70px 90px; rotate: -24deg; opacity: 0.1; font-family: var(--police-titre); font-weight: 800; font-size: 22px; color: var(--marine); user-select: none; }
  .filigrane span { white-space: nowrap; }
  .filigrane-coin { position: absolute; right: 12px; bottom: 12px; z-index: 4; height: 34px; width: auto; opacity: 0.85; pointer-events: none; }
  /* Avant / après (réalisations) */
  .avant-apres { position: absolute; inset: 0; z-index: 2; --pos: 50%; }
  .avant-apres img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
  .avant-apres__avant { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
  .avant-apres input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: ew-resize; margin: 0; z-index: 3; }
  .avant-apres__poignee { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 3px; background: #fff; translate: -50% 0; pointer-events: none; box-shadow: 0 0 0 1px rgb(0 0 0 / 0.2); }
  .avant-apres__poignee::after { content: "⇆"; position: absolute; top: 50%; left: 50%; translate: -50% -50%; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: #fff; color: var(--marine); font-weight: 800; box-shadow: var(--ombre-1); }
  .avant-apres__libelle { position: absolute; top: 10px; z-index: 2; pointer-events: none; }
  .avant-apres__libelle--avant { left: 10px; }
  .avant-apres__libelle--apres { right: 10px; }

  .fiche__infos { padding: var(--e-6) var(--e-6) var(--e-5); display: grid; grid-template-columns: minmax(0, 1fr); align-content: start; gap: var(--e-4); }
  .fiche__entete { display: flex; justify-content: space-between; align-items: start; gap: var(--e-3); padding-right: 46px; }
  .fiche__type { font-size: var(--t-xs); font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); }
  .fiche__titre { font-size: var(--t-xl); text-transform: uppercase; color: var(--marine); }
  .fiche__specs { display: flex; flex-wrap: wrap; gap: 1px; background: var(--ligne); border: 1px solid var(--ligne); border-radius: var(--r-carte); overflow: hidden; }
  .fiche__specs div { flex: 1 1 118px; background: var(--papier); padding: 0.7rem 0.8rem; display: grid; gap: 0.1rem; align-content: start; }
  .fiche__specs span { font-size: 11px; font-weight: 700; color: var(--texte-doux); text-transform: uppercase; letter-spacing: 0.05em; display: flex; align-items: center; gap: 0.3rem; }
  .fiche__specs span .icone { width: 14px; height: 14px; color: var(--principale); }
  .fiche__specs strong { font-family: var(--police-titre); font-size: 1.3rem; color: var(--marine); white-space: nowrap; }
  .fiche__budget { display: flex; align-items: baseline; gap: 0.5rem; flex-wrap: wrap; font-size: var(--t-s); color: var(--texte-doux); }
  .fiche__budget strong { font-family: var(--police-titre); font-size: var(--t-xl); color: var(--principale); }
  .fiche__description { color: #36405a; }
  .fiche__note { font-size: var(--t-xs); color: var(--texte-doux); background: var(--beton); border-left: 3px solid var(--ambre); padding: 0.6rem 0.8rem; border-radius: 0 var(--r-bouton) var(--r-bouton) 0; }
  .fiche__boutons { display: grid; gap: var(--e-2); }
  .fiche__boutons--2 { grid-template-columns: 1fr 1fr; }
  @media (max-width: 920px) {
    .fiche { width: 100%; max-width: 100%; max-height: 100dvh; height: 100dvh; border-radius: 0; }
    .fiche__cadre { grid-template-columns: minmax(0, 1fr); }
    .galerie { padding-top: calc(var(--e-4) + env(safe-area-inset-top, 0px)); }
    .galerie__fleche { opacity: 1; }
    .fiche__infos { padding: var(--e-5) var(--e-4) calc(var(--e-6) + env(safe-area-inset-bottom, 0px)); }
    .fiche__fermer { top: calc(12px + env(safe-area-inset-top, 0px)); }
  }
  @media (max-width: 420px) { .fiche__boutons--2 { grid-template-columns: 1fr; } }
  .fiche__resume { color: var(--principale); font-weight: 700; }
  .fiche__galerie-info { display: flex; align-items: center; gap: 0.45rem; font-size: var(--t-xs); font-weight: 700; color: var(--texte-doux); }
  .fiche__galerie-info .icone { color: var(--principale); }

  /* ===== DEMANDE DE DEVIS : WhatsApp ou e-mail au choix (fiches + fenêtre de choix) ===== */
  .contact-bloc { display: grid; gap: var(--e-3); padding: var(--e-4); border-radius: var(--r-carte); background: var(--beton); border: 1px solid var(--ligne); }
  .contact-bloc__titre { display: flex; align-items: center; gap: 0.5rem; font-family: var(--police-titre); font-size: 1.25rem; font-weight: 700; text-transform: uppercase; color: var(--marine); }
  .contact-bloc__titre .icone { color: var(--accent); }
  .contact-duo { display: grid; grid-template-columns: 1fr 1fr; gap: var(--e-2); width: 100%; }
  .contact-duo--seul { grid-template-columns: 1fr; }
  @media (max-width: 420px) { .contact-duo { grid-template-columns: 1fr; } }
  .bouton--canal { justify-content: flex-start; min-height: 58px; padding: 0.55rem 0.95rem; white-space: normal; text-align: left; line-height: 1.2; }
  .bouton--canal .icone { width: 26px; height: 26px; }
  .bouton--canal span { display: grid; min-width: 0; }
  .bouton--canal strong { font-size: var(--t-m); }
  .bouton--canal small { font-size: 11.5px; font-weight: 600; opacity: 0.88; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .bouton--canal.bouton--grand { min-height: 66px; }
  .contact-bloc__formulaire { display: flex; align-items: center; gap: 0.7rem; width: 100%; padding: 0.7rem 0.85rem; border-radius: var(--r-bouton); border: 1.5px dashed color-mix(in oklab, var(--principale) 35%, var(--ligne)); background: var(--papier); color: var(--marine); text-align: left; transition: border-color var(--transition), background var(--transition); }
  .contact-bloc__formulaire:hover { border-color: var(--principale); background: var(--principale-voile); }
  .contact-bloc__formulaire span { flex: 1; display: grid; gap: 0.1rem; min-width: 0; }
  .contact-bloc__formulaire strong { font-size: var(--t-s); }
  .contact-bloc__formulaire small { font-size: var(--t-xs); color: var(--texte-doux); }
  .contact-bloc__formulaire > .icone:first-child { color: var(--principale); width: 22px; height: 22px; }
  .feuille--contact .feuille__cadre { position: relative; gap: var(--e-3); }
  .feuille__fermer { position: absolute; top: 10px; right: 10px; }
  .feuille__pictogramme { width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; background: var(--principale); color: #fff; box-shadow: 0 0 0 6px var(--principale-voile); }
  .feuille__pictogramme .icone { width: 28px; height: 28px; }
  .feuille--contact .surtitre { margin-bottom: -0.4rem; }
  .choix-contact__objet { max-width: 100%; padding: 0.35rem 0.8rem; border-radius: var(--r-plein); background: var(--accent-voile); color: var(--accent-fonce); font-weight: 700; font-size: var(--t-s); overflow-wrap: anywhere; }
  .choix-contact__boutons { width: 100%; }
  .choix-contact__note { font-size: var(--t-xs); color: #7a5200; background: #fff4d6; padding: 0.45rem 0.7rem; border-radius: var(--r-bouton); }

  /* ===== TIROIRS (sélection, compte) ===== */
  .tiroir { margin: 0 0 0 auto; height: 100dvh; max-height: 100dvh; width: min(460px, 100%); max-width: 100%; border: 0; padding: 0; background: var(--papier); box-shadow: var(--ombre-3); }
  .tiroir::backdrop { background: rgb(2 8 24 / 0.55); backdrop-filter: blur(4px); }
  .tiroir[open] { animation: tiroir-entre 300ms cubic-bezier(0.2, 0.9, 0.25, 1) both; }
  @keyframes tiroir-entre { from { transform: translateX(100%); } }
  .tiroir__cadre { display: grid; grid-template-rows: auto 1fr auto; height: 100%; padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px); }
  .tiroir__tete { display: flex; align-items: center; justify-content: space-between; padding: var(--e-4) var(--e-5); border-bottom: 1px solid var(--ligne); }
  .tiroir__tete h2 { font-size: 1.5rem; text-transform: uppercase; color: var(--marine); }
  .tiroir__corps { overflow-y: auto; overscroll-behavior: contain; padding: var(--e-4) var(--e-5) var(--e-5); }
  .tiroir__pied { padding: var(--e-4) var(--e-5) var(--e-5); border-top: 1px solid var(--ligne); display: grid; gap: var(--e-2); }
  .tiroir__note { font-size: var(--t-xs); color: var(--texte-doux); }
  @media (max-width: 520px) { .tiroir__corps { padding-inline: var(--e-4); } }
  .ligne-selection { display: grid; grid-template-columns: 84px 1fr auto; gap: var(--e-3); align-items: center; padding-block: var(--e-3); border-bottom: 1px solid var(--beton-2); }
  .ligne-selection__visuel { width: 84px; aspect-ratio: 4 / 3; border-radius: var(--r-bouton); overflow: hidden; background: #fbfcfe; border: 1px solid var(--ligne); }
  .ligne-selection__visuel > * { width: 100%; height: 100%; object-fit: cover; }
  .ligne-selection h3 { font-family: var(--police-titre); font-size: 1.1rem; text-transform: uppercase; color: var(--marine); }
  .ligne-selection p { font-size: var(--t-xs); color: var(--texte-doux); }
  .ligne-selection .bouton-icone { color: var(--texte-doux); }
  .ligne-selection .bouton-icone:hover { color: #c81e3c; }

  /* Mon compte */
  .compte-entete { display: flex; align-items: center; gap: var(--e-3); padding-bottom: var(--e-3); border-bottom: 1px solid var(--ligne); }
  .compte-entete strong { display: block; font-size: var(--t-m); }
  .compte-entete span:not(.avatar) { display: block; font-size: var(--t-xs); color: var(--texte-doux); word-break: break-all; }
  .onglets { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: var(--beton); border-radius: var(--r-bouton); margin: var(--e-3) 0; }
  .onglets button { padding: 0.6rem; border-radius: 6px; font-size: var(--t-s); font-weight: 700; color: var(--texte-doux); }
  .onglets button[aria-selected="true"] { background: var(--papier); color: var(--marine); box-shadow: var(--ombre-1); }
  .liste-demandes { display: grid; gap: var(--e-3); }
  .dem { border: 1px solid var(--ligne); border-radius: var(--r-carte); padding: var(--e-3) var(--e-4); display: grid; gap: 0.45rem; animation: apparait 300ms ease both; }
  .dem header { display: flex; justify-content: space-between; align-items: center; gap: var(--e-2); }
  .dem header strong { font-family: var(--police-titre); font-size: 1.1rem; letter-spacing: 0.02em; color: var(--marine); }
  .dem__date { font-size: var(--t-xs); color: var(--texte-doux); }
  .dem__objet { font-size: var(--t-s); font-weight: 600; }
  .dem__objet small { display: block; font-weight: 500; color: var(--texte-doux); }
  .dem__message { font-size: var(--t-s); background: var(--principale-voile); border-left: 3px solid var(--principale); padding: 0.55rem 0.75rem; border-radius: 0 var(--r-bouton) var(--r-bouton) 0; }
  .dem__message strong { display: block; font-size: var(--t-xs); color: var(--principale); }
  .dem__infos { display: flex; flex-wrap: wrap; gap: 0.3rem 1rem; font-size: var(--t-xs); color: var(--texte-doux); }
  .dem__infos b { color: var(--marine); }
  .dem__suivi { display: grid; grid-template-columns: repeat(5, 1fr); gap: 3px; }
  .dem__suivi i { height: 5px; border-radius: 3px; background: var(--beton-2); }
  .dem__suivi i.atteint { background: var(--vert); }
  .dem__actions { display: flex; gap: var(--e-2); flex-wrap: wrap; }
  .compte-pied { display: grid; gap: var(--e-3); margin-top: var(--e-5); padding-top: var(--e-4); border-top: 1px solid var(--ligne); }
  .zone-danger, .zone-mdp { border: 1px solid var(--ligne); border-radius: var(--r-carte); padding: var(--e-3) var(--e-4); }
  .zone-danger summary, .zone-mdp summary { cursor: pointer; font-weight: 700; font-size: var(--t-s); }
  .zone-danger summary { color: #c81e3c; }
  .zone-danger[open], .zone-mdp[open] { display: grid; gap: var(--e-3); }
  .zone-danger p { font-size: var(--t-xs); color: var(--texte-doux); }

  /* ===== INSTALLATION DE L'APPLICATION ===== */
  .feuille { margin: auto auto 0; width: min(520px, 100%); max-width: 100%; max-height: 94dvh; overflow-y: auto; border: 0; padding: 0; border-radius: var(--r-panneau) var(--r-panneau) 0 0; background: var(--papier); box-shadow: var(--ombre-3); }
  .feuille::backdrop { background: rgb(2 8 24 / 0.55); backdrop-filter: blur(4px); }
  .feuille[open] { animation: feuille-monte 320ms cubic-bezier(0.2, 0.9, 0.25, 1) both; }
  @keyframes feuille-monte { from { transform: translateY(100%); } }
  .feuille__cadre { display: grid; gap: var(--e-3); justify-items: center; text-align: center; padding: var(--e-5) var(--e-5) calc(var(--e-5) + env(safe-area-inset-bottom, 0px)); }
  .feuille__icone { width: 68px; height: 68px; border-radius: 16px; box-shadow: var(--ombre-2); }
  .feuille h2 { font-size: 1.6rem; text-transform: uppercase; color: var(--marine); }
  .feuille__texte { font-size: var(--t-s); color: var(--texte-doux); }
  .etapes { display: grid; gap: var(--e-2); text-align: left; width: 100%; }
  .etapes li { display: flex; gap: var(--e-3); align-items: flex-start; background: var(--beton); padding: 0.75rem 0.9rem; border-radius: var(--r-carte); font-size: var(--t-s); }
  .etapes__num { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: #fff; font-weight: 800; font-size: 13px; }
  .etapes .icone { display: inline-block; vertical-align: -4px; width: 20px; height: 20px; color: #0a84ff; }
  .etapes__note { font-size: var(--t-xs); color: var(--texte-doux); }
  @media (min-width: 700px) { .feuille { margin: auto; border-radius: var(--r-panneau); } }
  @media (max-height: 760px) { .feuille__cadre { gap: var(--e-2); padding-top: var(--e-4); } .feuille__icone { width: 48px; height: 48px; } .etapes li { padding: 0.55rem 0.75rem; } }
  .banniere-app { position: fixed; z-index: 85; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; gap: 0.7rem; padding: 0.7rem 0.6rem 0.7rem 0.8rem; background: var(--marine); color: #fff; border-radius: var(--r-carte); box-shadow: var(--ombre-3); border-top: 3px solid var(--accent); animation: feuille-monte 420ms cubic-bezier(0.2, 0.9, 0.25, 1) both; }
  .banniere-app img { border-radius: 10px; flex: none; background: #fff; }
  .banniere-app__texte { flex: 1; min-width: 0; display: grid; line-height: 1.25; }
  .banniere-app__texte strong { font-size: var(--t-s); }
  .banniere-app__texte span { font-size: var(--t-xs); color: #c8d4ee; }
  .banniere-app .bouton-icone { color: #c8d4ee; width: 34px; height: 34px; }
  body:has(.banniere-app:not([hidden])) .wa-flottant { bottom: calc(100px + env(safe-area-inset-bottom, 0px)); }

  /* ===== PAGES LÉGALES ===== */
  .legale { max-width: 800px; padding-block: var(--e-6) var(--e-7); display: grid; gap: var(--e-5); }
  .legale h1 { font-size: var(--t-2xl); text-transform: uppercase; color: var(--marine); }
  .legale__maj { color: var(--texte-doux); font-size: var(--t-s); margin-top: calc(-1 * var(--e-4)); }
  .legale section { background: var(--papier); border: 1px solid var(--ligne); border-radius: var(--r-panneau); padding: var(--e-5); display: grid; gap: var(--e-3); }
  .legale h2 { font-size: 1.4rem; text-transform: uppercase; color: var(--marine); padding-left: 0.7rem; border-left: 4px solid var(--accent); }
  .legale ul { display: grid; gap: var(--e-2); padding-left: 1.1rem; list-style: disc; }
  .legale a { color: var(--principale); text-decoration: underline; }
  .pied--simple .pied__bas { border-top: 0; }
}

/* ---------------------------------------------------------- UTILITAIRES --- */
/* Aperçu local (VISUALISER_SITE.bat) : badge discret en bas à gauche */
@layer sections {
  .badge-apercu { position: fixed; z-index: 70; left: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); display: grid; gap: 0.1rem;
    padding: 0.5rem 0.75rem; border-radius: var(--r-bouton); background: var(--ambre); color: #3a2600; font-size: 11.5px; line-height: 1.3; box-shadow: var(--ombre-2); max-width: min(300px, calc(100vw - 110px)); }
  .badge-apercu strong { text-transform: uppercase; letter-spacing: 0.06em; font-size: 11px; }
  .badge-apercu a { text-decoration: underline; font-weight: 700; }
}

@layer utilitaires {
  .visuellement-cache { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
  [hidden] { display: none !important; }
  .revele { opacity: 0; transform: translateY(18px); transition: opacity 600ms ease, transform 600ms cubic-bezier(0.2, 0.7, 0.2, 1); }
  .revele.visible { opacity: 1; transform: none; }
  @media (prefers-reduced-motion: reduce) { .revele { opacity: 1; transform: none; } }
}
