/* ═══════════════════════════════════════════════════════════════
   Ikala-Ni | Feuille commune
   Chargée par toutes les pages de la refonte, avant la feuille
   propre à la page (accueil.css, fiche.css).

   Sommaire
     1. Polices
     2. Jetons (couleurs, typos, espacements, courbes)
     3. Base
     4. Utilitaires (or métallisé, repère de section, titre h2)
     5. Boutons
     6. En-tête
     7. Pied de page
     8. Appareils (portable, tablette, téléphone, pliable, moniteur)
     9. Écran qui fait défiler une page entière
    10. Mouvement (apparitions au défilement)
    11. Accessibilité du mouvement
    12. Boutons flottants : WhatsApp et réglages d'accessibilité
    13. Responsive
   ═══════════════════════════════════════════════════════════════ */


/* ═════════ 1. POLICES ═════════
   Auto-hébergées, un seul fichier variable par famille.
   font-display: swap affiche le texte tout de suite avec la police de secours. */
@font-face {
  font-family: 'Playfair Display';
  font-weight: 400 700;
  font-display: swap;
  src: url('../../assets/fonts/playfair-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-weight: 300 700;
  font-display: swap;
  src: url('../../assets/fonts/inter-latin.woff2') format('woff2');
}


/* ═════════ 2. JETONS ═════════
   Toute la charte tient ici : pour changer une couleur sur tout le site,
   on ne la modifie qu'à cet endroit. */
:root {
  /* Couleurs */
  --noir: #000;
  --texte: #efece6;                          /* blanc cassé, moins agressif que #fff */
  --texte-2: #9b978f;                        /* texte secondaire, contraste 7:1 sur noir */
  --or: #c9a84c;
  --filet: rgba(255, 255, 255, 0.08);        /* traits de séparation discrets */
  --filet-or: rgba(201, 168, 76, 0.35);      /* traits et contours dorés */
  --or-metal: linear-gradient(110deg, #a8843a 0%, #e8cf86 38%, #c9a84c 55%, #f3e2b0 72%, #a8843a 100%);

  /* Métaux des appareils : téléphones en bleu métallisé, écrans et tablette en argent.
     Les reflets alternent clair et foncé, comme le bord poli d'un appareil réel. */
  --argent: linear-gradient(135deg, #cfd2d6 0%, #8a8e94 18%, #c4c7cc 36%, #6b6f75 56%, #b9bcc1 76%, #8f9398 100%);
  --argent-vertical: linear-gradient(90deg, #7f8287, #c6c9cd 35%, #a8abb0 65%, #707378);
  --bleu-metal: linear-gradient(135deg, #7fb0f2 0%, #2f63b3 16%, #8dbbf5 32%, #173f80 52%, #6f9fe0 70%, #9cc4f7 82%, #2a5aa3 100%);

  /* Typographie */
  --titre: 'Playfair Display', Georgia, serif;
  --corps: 'Inter', system-ui, sans-serif;

  /* Mise en page : marge latérale fluide (16 px sur mobile, 88 px sur grand écran) */
  --marge: clamp(16px, 5vw, 88px);
  --largeur: 1280px;

  /* Courbes d'animation */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);          /* départ vif, arrivée douce */
  --ease-scroll: cubic-bezier(0.65, 0, 0.35, 1);   /* accélère puis freine, comme un vrai défilement */
}


/* ═════════ 3. BASE ═════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--noir);
  color: var(--texte);
  font-family: var(--corps);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; }

::selection { background: var(--or); color: var(--noir); }
:focus-visible { outline: 2px solid var(--or); outline-offset: 4px; }

/* Lien d'évitement : invisible, il apparaît au premier appui sur Tab */
.lien-evitement {
  position: absolute; left: -9999px; top: 8px; z-index: 100;
  background: var(--or); color: var(--noir); padding: 10px 16px;
}
.lien-evitement:focus { left: 8px; }

/* Conteneur centré, commun à toutes les sections */
.conteneur { max-width: var(--largeur); margin: 0 auto; padding: 0 var(--marge); }

/* Texte lu par les lecteurs d'écran mais invisible à l'écran */
.lecteur-ecran {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}

section { position: relative; }


/* ═════════ 4. UTILITAIRES ═════════ */

/* Or métallisé, réservé aux mots-clés des titres */
.metal {
  background: var(--or-metal);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  /* L'italique dépasse de sa boîte : sans cette marge, la dernière lettre
     sortirait de la zone dorée et serait rognée. La marge négative compense,
     la mise en page ne bouge pas. */
  padding-right: 0.1em;
  margin-right: -0.1em;
}

/* Repère de section : « 01  PROJETS ────── » */
.repere {
  display: flex; align-items: center; gap: 16px;
  font-size: 0.75rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--texte-2);
}
.repere b {
  font-family: var(--titre); font-style: italic; font-weight: 400;
  font-size: 0.9375rem; letter-spacing: 0; text-transform: none; color: var(--or);
  white-space: nowrap;   /* « Ikala-Ni » ne se coupe jamais au tiret */
}
.repere::after { content: ''; flex: 1; max-width: 120px; height: 1px; background: var(--filet-or); }

/* Titre de section : la taille varie selon la page (voir accueil.css et fiche.css) */
h2 {
  font-family: var(--titre); font-weight: 400;
  line-height: 1.05; letter-spacing: -0.015em;
}
h2 em { font-style: italic; }


/* ═════════ 5. BOUTONS ═════════ */
.boutons { display: flex; flex-wrap: wrap; gap: 14px; }

.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 54px; padding: 0 30px; border-radius: 999px; overflow: hidden;
  font-size: 0.9375rem; font-weight: 500; text-decoration: none;
  transition: color 0.4s var(--ease), border-color 0.4s var(--ease);
}

/* Bouton plein : au survol, le dégradé glisse et fait passer un reflet */
.btn-or { background: var(--or-metal); background-size: 200% 100%; color: var(--noir); transition: background-position 0.8s var(--ease); }
.btn-or:hover { background-position: 100% 0; }

/* Bouton contour : au survol, un fond or monte depuis le bas */
.btn-contour { border: 1px solid var(--filet-or); }
.btn-contour::before {
  content: ''; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
  background: var(--or); transform: translateY(101%); transition: transform 0.5s var(--ease);
}
.btn-contour:hover { color: var(--noir); border-color: var(--or); }
.btn-contour:hover::before { transform: none; }

.btn .fleche { transition: transform 0.4s var(--ease); }
.btn:hover .fleche { transform: translateX(4px); }


/* ═════════ 6. EN-TÊTE ═════════
   Transparent en haut de page, il prend un fond flouté dès qu'on défile
   (classe .defile posée par js/ikala/commun.js). */
.entete {
  position: fixed; inset: 0 0 auto; z-index: 50;
  border-bottom: 1px solid transparent;
  transition: background 0.5s var(--ease), border-color 0.5s;
}
.entete.defile { background: rgba(0, 0, 0, 0.82); backdrop-filter: blur(16px) saturate(140%); border-color: var(--filet); }
.entete .conteneur { display: flex; align-items: center; justify-content: space-between; height: 84px; }

.marque { font-family: var(--titre); font-size: 1.625rem; letter-spacing: 0.02em; text-decoration: none; }

.nav { display: flex; align-items: center; gap: 36px; list-style: none; }
.nav a { position: relative; text-decoration: none; font-size: 0.875rem; letter-spacing: 0.04em; color: var(--texte-2); transition: color 0.3s; }
/* Soulignement or qui se trace de gauche à droite au survol */
.nav a::after {
  content: ''; position: absolute; left: 0; bottom: -6px; width: 100%; height: 1px;
  background: var(--or); transform: scaleX(0); transform-origin: right; transition: transform 0.5s var(--ease);
}
.nav a:hover, .nav a[aria-current] { color: var(--texte); }
.nav a:hover::after { transform: scaleX(1); transform-origin: left; }

/* Bouton Menu : visible seulement sur mobile, et seulement si JavaScript tourne
   (classe .js sur <html>). Trois traits or qui deviennent une croix à l'ouverture. */
.menu-btn {
  display: none; align-items: center; gap: 10px; min-height: 44px; padding: 0 16px; cursor: pointer;
  font: inherit; font-size: 0.8125rem; letter-spacing: 0.08em; color: var(--texte);
  background: transparent; border: 1px solid var(--filet-or); border-radius: 999px;
}
.menu-btn:focus-visible { outline: 2px solid var(--or); outline-offset: 3px; }
.menu-traits { position: relative; display: grid; gap: 4px; width: 18px; }
.menu-traits i { display: block; height: 1.5px; background: var(--or); transition: transform 0.35s var(--ease), opacity 0.2s; }
.menu-btn[aria-expanded="true"] .menu-traits i:nth-child(1) { transform: translateY(5.5px) rotate(45deg); }
.menu-btn[aria-expanded="true"] .menu-traits i:nth-child(2) { opacity: 0; }
.menu-btn[aria-expanded="true"] .menu-traits i:nth-child(3) { transform: translateY(-5.5px) rotate(-45deg); }


/* ═════════ 7. PIED DE PAGE ═════════ */
.pied { padding: 32px 0; border-top: 1px solid var(--filet); overflow: hidden; }
.pied-bas { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; font-size: 0.8125rem; color: var(--texte-2); }
.pied-bas ul { display: flex; flex-wrap: wrap; gap: 8px 28px; list-style: none; }
.pied-bas a { text-decoration: none; transition: color 0.3s; }
.pied-bas a:hover { color: var(--or); }


/* ═════════ 8. APPAREILS ═════════
   Cadres dessinés en CSS autour des captures d'écran.
   Astuce du contour métallisé : un fond noir limité à la zone intérieure
   (padding-box) posé sur un dégradé qui remplit tout (border-box).
   La bordure transparente laisse donc voir le dégradé. */

/* Objectif de caméra partagé par tous les appareils : reflet au centre, anneau autour */
.telephone::after, .tablette::before, .portable-ecran::before, .pli-droit::after {
  background: radial-gradient(circle at 50% 50%, rgba(160, 190, 255, 0.85) 0 10%, #2a3550 22%, #0c1018 46%, #030303 72%);
  box-shadow: 0 0 0 1.5px #2b2b2b, 0 0 0 2.5px #0a0a0a;
}

/* Téléphone, bleu métallisé, caméra à poinçon */
.telephone {
  position: relative; padding: 7px; border-radius: 32px; border: 4px solid transparent;
  background: linear-gradient(#000, #000) padding-box, var(--bleu-metal) border-box;
  /* Liseré brillant sur la tranche + halo bleuté discret + ombre portée */
  box-shadow: 0 0 0 1px rgba(110, 160, 235, 0.45), 0 0 30px -6px rgba(61, 114, 196, 0.55), 0 50px 90px -25px rgba(0, 0, 0, 0.8);
}
.telephone::after {
  content: ''; position: absolute; top: 20px; left: 50%; z-index: 2; translate: -50% 0;
  width: 10px; height: 10px; border-radius: 50%;
}
.ecran-tel { aspect-ratio: 390 / 844; border-radius: 22px; }   /* format d'un téléphone actuel */

/* Tablette à l'horizontale, argent, caméra au centre du bord haut */
.tablette {
  position: relative; padding: 15px; border-radius: 26px; border: 3px solid transparent;
  background: linear-gradient(180deg, #111, #050505) padding-box, var(--argent) border-box;
  box-shadow: 0 50px 90px -25px rgba(0, 0, 0, 0.8);
}
.tablette::before, .tablette::after { content: ''; position: absolute; left: 50%; border-radius: 50%; }
.tablette::before { top: 3px; width: 9px; height: 9px; transform: translateX(-50%); }                 /* caméra */
.tablette::after { top: 5.5px; width: 4px; height: 4px; transform: translateX(12px); background: #1c1c1c; } /* capteur de lumière */
.ecran-tab { aspect-ratio: 1194 / 834; border-radius: 10px; }

/* Ordinateur portable vu de face : écran droit, fine base argentée avec encoche */
.portable-ecran {
  position: relative; padding: 11px 9px 13px; border-radius: 16px 16px 4px 4px; border: 3px solid transparent;
  background: linear-gradient(180deg, #111, #050505) padding-box, var(--argent) border-box;
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.9);
}
.portable-ecran::before { content: ''; position: absolute; top: 4px; left: 50%; width: 7px; height: 7px; border-radius: 50%; translate: -50% 0; }
.ecran-portable { aspect-ratio: 16 / 10; border-radius: 4px; }
.portable-base {
  position: relative; height: 16px;
  border-radius: 2px 2px 16px 16px / 2px 2px 12px 12px;
  background: linear-gradient(180deg, #dadde1 0%, #b3b7bc 40%, #858990 100%);
  box-shadow: inset 0 2px 0 rgba(0, 0, 0, 0.35), 0 24px 34px -14px rgba(0, 0, 0, 0.9);
}
/* Encoche qui permet d'ouvrir l'écran avec le doigt */
.portable-base::before {
  content: ''; position: absolute; top: 0; left: 50%; width: 16%; height: 6px; translate: -50% 0;
  border-radius: 0 0 10px 10px; background: linear-gradient(180deg, #7d8187, #a9adb2);
}

/* Pliable ouvert en V, comme un livre posé : chaque volet pivote sur la charnière centrale.
   --ouverture règle l'angle, modifiable au survol par la page qui l'utilise. */
.pliable {
  --ouverture: 14deg;
  display: flex;
  transform: perspective(1800px) rotateX(5deg);
  transform-style: preserve-3d;
}
.pli-volet {
  position: relative; flex: 1; padding: 6px; border: 3px solid transparent;
  background: linear-gradient(#000, #000) padding-box, var(--bleu-metal) border-box;
  box-shadow: 0 0 24px -8px rgba(61, 114, 196, 0.5), 0 40px 70px -30px rgba(0, 0, 0, 0.9);
  transition: transform 0.9s var(--ease);
}
/* Côté charnière : ni tranche ni bord noir, l'écran est continu d'un volet à l'autre */
.pli-gauche { padding-right: 0; border-right-width: 0; border-radius: 30px 4px 4px 30px; transform-origin: right center; transform: rotateY(var(--ouverture)); }
.pli-droit { padding-left: 0; border-left-width: 0; border-radius: 4px 30px 30px 4px; transform-origin: left center; transform: rotateY(calc(-1 * var(--ouverture))); }
.pli-droit::after { content: ''; position: absolute; top: 18px; right: 22px; z-index: 2; width: 8px; height: 8px; border-radius: 50%; }
.ecran-pli { aspect-ratio: 390 / 844; }
.pli-gauche .ecran-pli { border-radius: 22px 0 0 22px; }
.pli-droit .ecran-pli { border-radius: 0 22px 22px 0; }
/* Pliure à peine perceptible, comme sur un vrai écran pliable */
.ecran-pli::after { content: ''; position: absolute; inset: 0; pointer-events: none; }
.pli-gauche .ecran-pli::after { background: linear-gradient(270deg, rgba(0, 0, 0, 0.06), transparent 8%); }
.pli-droit .ecran-pli::after { background: linear-gradient(90deg, rgba(0, 0, 0, 0.06), transparent 8%); }

/* Écran de bureau sur pied, argent */
.moniteur-cadre {
  position: relative; padding: 12px 12px 30px; border-radius: 18px; border: 3px solid transparent;
  background: linear-gradient(180deg, #111, #050505) padding-box, var(--argent) border-box;
  box-shadow: 0 50px 100px -30px rgba(0, 0, 0, 0.9);
}
.moniteur-cadre::after { content: ''; position: absolute; bottom: 11px; left: 50%; width: 9px; height: 9px; translate: -50% 0; border-radius: 50%; background: #1d1d1d; }
.ecran-bureau { aspect-ratio: 16 / 10; border-radius: 6px; }
.moniteur-pied { width: 18%; height: clamp(40px, 6vw, 78px); margin: 0 auto; background: var(--argent-vertical); clip-path: polygon(14% 0, 86% 0, 100% 100%, 0 100%); }
.moniteur-socle { width: 34%; height: 10px; margin: 0 auto; border-radius: 4px 4px 10px 10px; background: linear-gradient(180deg, #c8cbcf, #85888d); box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.9); }


/* ═════════ 9. ÉCRAN QUI FAIT DÉFILER UNE PAGE ENTIÈRE ═════════
   La capture pleine page glisse dans l'écran comme sous un vrai défilement,
   avec des pauses, puis remonte.
   Deux réglages, posés en style sur l'élément .site-defile :
     --h-image : hauteur de l'image exprimée en largeur d'écran
                 (capture de 1000 × 2946 px  =>  2946 / 1000 × 100 = 294.6cqw)
     --duree   : durée d'un tour, plus longue pour les pages longues
   container-type: size permet d'utiliser cqh (hauteur de l'écran) dans l'animation. */
.ecran { position: relative; overflow: hidden; background: #fff; container-type: size; }
.site-defile { position: absolute; inset: 0; overflow: hidden; }
.site-defile img { width: 100%; height: auto; }

/* L'animation ne démarre qu'une fois l'appareil visible (classe .visible) */
.js .visible .site-defile img { animation: defilement var(--duree, 30s) 1.5s infinite; }

@keyframes defilement {
  0%, 8%   { translate: 0 0;                                          animation-timing-function: var(--ease-scroll); }
  20%, 28% { translate: 0 calc((100cqh - var(--h-image)) * 0.27);    animation-timing-function: var(--ease-scroll); }
  40%, 48% { translate: 0 calc((100cqh - var(--h-image)) * 0.52);    animation-timing-function: var(--ease-scroll); }
  60%, 68% { translate: 0 calc((100cqh - var(--h-image)) * 0.78);    animation-timing-function: var(--ease-scroll); }
  78%, 86% { translate: 0 calc(100cqh - var(--h-image));             animation-timing-function: var(--ease-scroll); }
  97%, 100% { translate: 0 0; }
}


/* ═════════ 10. MOUVEMENT ═════════
   Tout ce qui est préfixé .js n'agit que si le JavaScript tourne :
   sans lui, le contenu reste simplement visible. */
.js .apparait { opacity: 0; transform: translateY(36px); transition: opacity 1.1s var(--ease), transform 1.1s var(--ease); }
.js .apparait.visible { opacity: 1; transform: none; }

/* Éléments d'une même rangée : chacun arrive un peu après le précédent */
.js .cascade > .apparait:nth-child(2) { transition-delay: 0.1s; }
.js .cascade > .apparait:nth-child(3) { transition-delay: 0.2s; }
.js .cascade > .apparait:nth-child(4) { transition-delay: 0.3s; }


/* ═════════ 11. ACCESSIBILITÉ DU MOUVEMENT ═════════
   Si le visiteur a demandé moins d'animations dans son système,
   tout s'affiche directement, rien ne bouge ni ne défile. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .apparait { opacity: 1; transform: none; }
}


/* ═════════ 12. BOUTONS FLOTTANTS ═════════
   WhatsApp en bas à droite, réglages d'accessibilité en bas à gauche.
   Le bouton et le panneau d'accessibilité sont construits par
   js/accessibilite.js (script partagé avec les pages pas encore refondues) :
   seule leur apparence est décrite ici. */

/* Contact WhatsApp direct : vert WhatsApp, reconnaissable d'un coup d'œil */
.wa-float {
  position: fixed; right: clamp(16px, 3vw, 28px); bottom: clamp(16px, 3vw, 28px); z-index: 900;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 11px 18px 11px 14px; border-radius: 999px;
  background: #1f8a4c; color: #fff; font-size: 0.875rem; font-weight: 600; text-decoration: none;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.wa-float:hover { transform: translateY(-2px); box-shadow: 0 8px 26px rgba(31, 138, 76, 0.45); }
.wa-float svg { flex: none; width: 22px; height: 22px; }

/* Retour en haut : rond discret, posé au-dessus d'Ikala-bot (lui-même au-dessus de WhatsApp).
   Invisible et inactif tant qu'on n'a pas défilé d'un écran (classe .visible posée par commun.js) */
/* Bulle « Adresse copiée » des liens courriel (commun.js, section 5) */
.bulle-copie {
  position: fixed; left: 50%; bottom: 28px; z-index: 60; translate: -50% 12px;
  padding: 12px 20px; border: 1px solid var(--filet-or); background: #0d0d0d; color: var(--texte);
  font-size: 0.875rem; opacity: 0; pointer-events: none; transition: opacity 0.3s, translate 0.3s var(--ease);
}
.bulle-copie.visible { opacity: 1; translate: -50% 0; }

.retour-haut {
  position: fixed; right: clamp(16px, 3vw, 28px); bottom: calc(clamp(16px, 3vw, 28px) + 122px); z-index: 900;
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; cursor: pointer;
  font-size: 1.125rem; color: var(--or);
  background: rgba(0, 0, 0, 0.75); border: 1px solid var(--filet-or); backdrop-filter: blur(8px);
  opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease), visibility 0.4s, background 0.3s, color 0.3s;
}
.retour-haut.visible { opacity: 1; visibility: visible; transform: none; }
.retour-haut:hover { background: var(--or); color: var(--noir); }

/* Bouton d'accessibilité : rond or métallisé, pictogramme universel */
.a11y-btn {
  position: fixed; left: clamp(16px, 3vw, 28px); bottom: clamp(16px, 3vw, 28px); z-index: 950;
  display: grid; place-items: center; width: 52px; height: 52px; border: 0; border-radius: 50%; cursor: pointer;
  background: var(--or-metal); background-size: 200% 100%; color: var(--noir);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s var(--ease), background-position 0.8s var(--ease);
}
.a11y-btn:hover { transform: translateY(-2px); background-position: 100% 0; }
.a11y-btn svg { width: 28px; height: 28px; }

/* Panneau des réglages, ouvert au-dessus du bouton */
.a11y-panneau {
  position: fixed; left: clamp(16px, 3vw, 28px); bottom: calc(clamp(16px, 3vw, 28px) + 64px); z-index: 951;
  width: min(320px, calc(100vw - 32px)); padding: 22px;
  background: #0a0a0a; border: 1px solid var(--filet-or); border-radius: 14px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6);
}
.a11y-panneau[hidden] { display: none; }
.a11y-panneau h2 { margin: 0 0 16px; font-family: var(--corps); font-size: 0.6875rem; font-weight: 500; letter-spacing: 0.24em; text-transform: uppercase; color: var(--or); }
.a11y-ligne { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 0; border-top: 1px solid var(--filet); }
.a11y-ligne:first-of-type { border-top: 0; }
.a11y-ligne span { font-size: 0.9rem; }

/* Interrupteur oui / non : la pastille glisse à droite quand le réglage est actif */
.a11y-switch {
  position: relative; flex: none; width: 46px; height: 26px; padding: 0; cursor: pointer;
  border: 1px solid var(--filet); border-radius: 999px; background: #1a1a1a;
  transition: background 0.2s, border-color 0.2s;
}
.a11y-switch::after {
  content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%;
  background: var(--texte-2); transition: transform 0.2s, background 0.2s;
}
.a11y-switch[aria-pressed="true"] { background: rgba(201, 168, 76, 0.28); border-color: var(--or); }
.a11y-switch[aria-pressed="true"]::after { transform: translateX(20px); background: var(--or); }

/* Boutons texte du panneau (taille du texte, tout réinitialiser) */
.a11y-reinit {
  display: block; width: 100%; margin-top: 16px; padding: 10px; cursor: pointer;
  font: inherit; font-size: 0.8125rem; color: var(--texte-2);
  background: transparent; border: 1px solid var(--filet); border-radius: 8px;
}
.a11y-reinit:hover { color: var(--texte); border-color: var(--or); }

/* ── Effets des réglages sur la page (classes posées sur <html>) ── */

/* Texte agrandi : les tailles étant en rem, changer la base suffit */
html.a11y-texte-1 { font-size: 112.5%; }
html.a11y-texte-2 { font-size: 125%; }

/* Contraste renforcé : on éclaircit les jetons, toute la page suit */
html.a11y-contraste {
  --texte: #fff;
  --texte-2: #dcd8d0;
  --filet: rgba(255, 255, 255, 0.22);
  --filet-or: rgba(201, 168, 76, 0.7);
}

/* Liens soulignés : repérables sans compter sur la couleur */
html.a11y-liens main a,
html.a11y-liens .pied a,
html.a11y-liens .nav a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Animations coupées : même effet que la préférence système (section 11).
   Le hero passe aussi à son état final, voir mouvementReduit dans commun.js */
html.a11y-anim-off *,
html.a11y-anim-off *::before,
html.a11y-anim-off *::after {
  animation: none !important;
  transition: none !important;
  scroll-behavior: auto !important;
}
html.a11y-anim-off .apparait { opacity: 1; transform: none; }


/* ═════════ 13. RESPONSIVE ═════════ */
@media (max-width: 768px) {
  /* Sans JavaScript, la navigation se réduit au seul lien Contact */
  .nav li:not(:last-child) { display: none; }

  /* Avec JavaScript : bouton Menu, et la liste devient un panneau plein écran.
     Logo et bouton restent au-dessus du panneau pour pouvoir le refermer. */
  .js .menu-btn { display: inline-flex; position: relative; z-index: 2; }
  .js .marque { position: relative; z-index: 2; }
  .js #menu-principal {
    position: fixed; inset: 0; z-index: 1;
    display: flex; align-items: center; justify-content: center;
    padding: 100px var(--marge) 48px; background: var(--noir);
    opacity: 0; visibility: hidden; transition: opacity 0.4s var(--ease), visibility 0.4s;
  }
  .js .nav { flex-direction: column; gap: 30px; text-align: center; }
  .js .nav li:not(:last-child) { display: block; }
  .js .nav li { opacity: 0; transform: translateY(16px); transition: opacity 0.5s var(--ease), transform 0.5s var(--ease); }
  .js .nav a { font-family: var(--titre); font-size: clamp(2rem, 9vw, 2.75rem); letter-spacing: 0; color: var(--texte); }
  .js .nav a[aria-current] { color: var(--or); }
  /* Contact devient le bouton or, comme « Parler d'un projet » ailleurs sur le site */
  .js .nav li:last-child { margin-top: 12px; }
  .js .nav li:last-child a {
    display: inline-flex; padding: 16px 34px; border-radius: 999px;
    font-family: var(--corps); font-size: 1rem; font-weight: 600; letter-spacing: 0.04em;
    color: var(--noir); background: var(--or-metal);
  }
  .js .nav li:last-child a::after { display: none; }

  /* Menu ouvert : panneau visible, liens qui montent l'un après l'autre, page figée.
     Le flou de l'en-tête est coupé : sinon le panneau resterait enfermé dans l'en-tête. */
  html.menu-ouvert { overflow: hidden; }
  html.menu-ouvert .entete { backdrop-filter: none; background: transparent; border-color: transparent; }
  html.menu-ouvert #menu-principal { opacity: 1; visibility: visible; }
  html.menu-ouvert .nav li { opacity: 1; transform: none; }
  html.menu-ouvert .nav li:nth-child(2) { transition-delay: 0.06s; }
  html.menu-ouvert .nav li:nth-child(3) { transition-delay: 0.12s; }
  html.menu-ouvert .nav li:nth-child(4) { transition-delay: 0.18s; }
  html.menu-ouvert .wa-float, html.menu-ouvert .retour-haut, html.menu-ouvert .a11y-btn,
  html.menu-ouvert .ib-btn, html.menu-ouvert .ib-appel { visibility: hidden; }
}
@media (max-width: 560px) {
  .boutons .btn { width: 100%; }

  /* Boutons flottants plus discrets : WhatsApp devient un simple rond */
  .wa-float { gap: 0; padding: 13px; }
  .wa-float .wa-label { display: none; }
  .a11y-btn { width: 48px; height: 48px; }
  .a11y-btn svg { width: 24px; height: 24px; }

  /* Le pied de page laisse la place des boutons flottants sous ses liens */
  .pied { padding-bottom: 96px; }
}
