/* ==================================================================
   FYANARANA — Feuille de style
   ------------------------------------------------------------------
   Site statique HTML/CSS/JS. Aucune dépendance externe.
   Palette issue du logo (img/fyanarana.png) :
     - Bleu ciel  #4cb7eb  (couleur principale)
     - Ardoise    #616d7d  (texte / pictos neutres)
     - Menthe     #aad4c7  (accent doux)
   Organisation :
     1. Variables (thème clair + sombre)
     2. Réinitialisation & bases
     3. Utilitaires (container, boutons, cartes, icônes)
     4. Composants transverses (eyebrow, titres de section, reveal)
     5. Sections, dans l'ordre de la page
     6. Responsive
     7. Accessibilité (focus, reduced-motion)
   ================================================================== */

/* ------------------------------------------------------------------ */
/*  1. Variables de thème                                              */
/* ------------------------------------------------------------------ */
:root {
  /* Palette de marque : bleu ciel #4cb7eb (logo) décliné en nuances */
  --brand-50:  #eff9fe;
  --brand-100: #d8f0fc;
  --brand-200: #b0e2f8;
  --brand-300: #7dd0f2;
  --brand-400: #4cb7eb;  /* bleu du logo */
  --brand-500: #219fd8;  /* couleur principale (contraste texte blanc) */
  --brand-600: #1783b8;  /* survol / états actifs */
  --brand-700: #146a95;
  --brand-800: #14567a;
  --brand-900: #124763;

  /* Couleurs d'appui : menthe (accent du logo) + rouge (alerte) */
  --mint-300: #c6e4da;
  --mint-400: #aad4c7;   /* menthe du logo */
  --mint-500: #7dbcaa;
  --mint-600: #57a08c;
  --red-400:  #f87171;

  /* Neutres (mode clair), teintés gris ardoise #616d7d du logo */
  --bg:            #ffffff;
  --bg-alt:        #f2f7fa;   /* fond de section alternée */
  --surface:       #ffffff;   /* fond des cartes */
  --surface-soft:  #eef7fc;   /* pastilles d'icônes */
  --border:        #dfe8ee;
  --text:          #4b5663;   /* texte courant (ardoise) */
  --text-strong:   #232b35;   /* titres */
  --text-muted:    #77828f;   /* texte secondaire */

  /* Rayons, ombres, transitions */
  --radius:    0.75rem;
  --radius-lg: 1.25rem;
  --radius-xl: 1.75rem;
  --shadow-soft: 0 4px 24px -6px rgb(35 43 53 / 0.08), 0 2px 8px -4px rgb(35 43 53 / 0.05);
  --shadow-lift: 0 16px 48px -12px rgb(33 159 216 / 0.30), 0 4px 16px -8px rgb(35 43 53 / 0.10);
  --header-h: 72px;

  /* Point médian des dégradés de texture QR (clair) */
  --qr-dot: rgb(76 183 235 / 0.18);
}

/* Mode sombre : ardoise profonde avec accents bleu ciel */
:root.dark {
  --bg:            #0a1016;
  --bg-alt:        #080d12;
  --surface:       #101922;
  --surface-soft:  rgb(76 183 235 / 0.12);
  --border:        #223140;
  --text:          #b9c6d1;
  --text-strong:   #eef4f8;
  --text-muted:    #7c8b98;
  --shadow-soft:   0 4px 24px -6px rgb(0 0 0 / 0.5);
  --shadow-lift:   0 16px 48px -12px rgb(0 0 0 / 0.55);
  --qr-dot:        rgb(76 183 235 / 0.10);
}

/* ------------------------------------------------------------------ */
/*  2. Réinitialisation & bases                                        */
/* ------------------------------------------------------------------ */
*,
*::before,
*::after { box-sizing: border-box; }

/* L'attribut [hidden] doit toujours l'emporter sur display:flex/grid. */
[hidden] { display: none !important; }

* { margin: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

h1, h2, h3 {
  font-family: "Bricolage Grotesque", system-ui, sans-serif;
  color: var(--text-strong);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

a { color: inherit; text-decoration: none; }
img, svg { display: block; }
ul { list-style: none; padding: 0; }
button { font: inherit; cursor: pointer; }

::selection { background: var(--brand-500); color: #fff; }

/* ------------------------------------------------------------------ */
/*  3. Utilitaires                                                     */
/* ------------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: 80rem;   /* 1280px */
  margin-inline: auto;
  padding-inline: 1rem;
}
.container-narrow { max-width: 48rem; }

@media (min-width: 640px) { .container { padding-inline: 1.5rem; } }
@media (min-width: 1024px) { .container { padding-inline: 2rem; } }

/* Icônes SVG (sprite) — reprennent la couleur du texte via currentColor */
.icon {
  width: 1.25rem;
  height: 1.25rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
.icon-sm { width: 1rem; height: 1rem; }
.icon-xs { width: 0.75rem; height: 0.75rem; }
.text-success { color: var(--brand-600); }
.text-muted { color: var(--text-muted); }

/* Cartes */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  transition: box-shadow 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}
.card-hover:hover {
  box-shadow: var(--shadow-lift);
  border-color: var(--brand-200);
}

/* Boutons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: var(--radius);
  padding: 0.65rem 1.25rem;
  font-weight: 600;
  font-size: 0.875rem;
  border: 1px solid transparent;
  transition: background-color 0.2s ease, transform 0.2s ease,
              border-color 0.2s ease, color 0.2s ease;
  white-space: nowrap;
}
.btn-lg { padding: 0.85rem 1.5rem; font-size: 1rem; }

.btn-primary {
  background: var(--brand-500);
  color: #fff;                /* contraste fort sur le bleu (bouton principal) */
  box-shadow: var(--shadow-lift);
}
.btn-primary:hover { background: var(--brand-600); transform: translateY(-2px); }

.btn-outline {
  background: color-mix(in srgb, var(--surface) 60%, transparent);
  color: var(--text-strong);
  border-color: var(--border);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.btn-outline:hover {
  border-color: var(--brand-400);
  color: var(--brand-700);
  transform: translateY(-2px);
}
:root.dark .btn-outline:hover { color: var(--brand-300); }

/* Lien avec flèche (call-to-action discret) */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--brand-700);
  transition: color 0.2s ease, gap 0.2s ease;
}
.link-arrow:hover { color: var(--brand-600); gap: 0.625rem; }
:root.dark .link-arrow { color: var(--brand-400); }
:root.dark .link-arrow:hover { color: var(--brand-300); }

.link-plain {
  background: none;
  border: none;
  color: var(--brand-700);
  font-weight: 600;
  font-size: 0.875rem;
}
.link-plain:hover { color: var(--brand-600); }
:root.dark .link-plain { color: var(--brand-400); }

/* Texture "pixels QR" — signature graphique de la marque */
.qr-texture {
  background-image: radial-gradient(var(--qr-dot) 1.5px, transparent 1.5px);
  background-size: 14px 14px;
}
.qr-texture-dark {
  background-image: radial-gradient(rgb(255 255 255 / 0.10) 1.5px, transparent 1.5px);
  background-size: 14px 14px;
}

/* ------------------------------------------------------------------ */
/*  4. Composants transverses                                          */
/* ------------------------------------------------------------------ */

/* "Eyebrow" : petite étiquette au-dessus des titres */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid var(--brand-200);
  background: var(--brand-50);
  color: var(--brand-800);
  border-radius: 999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
:root.dark .eyebrow {
  border-color: var(--brand-800);
  background: rgb(76 183 235 / 0.12);
  color: var(--brand-300);
}

/* En-tête de section */
.section { padding-block: 5rem; }
.section-alt { background: var(--bg-alt); }

.section-heading {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1rem;
  margin-inline: auto;
  max-width: 42rem;
}
.section-title { font-size: 1.875rem; font-weight: 700; text-wrap: balance; }
.section-lede { color: var(--text-muted); font-size: 1.0625rem; text-wrap: balance; }

@media (min-width: 640px) {
  .section { padding-block: 7rem; }
  .section-title { font-size: 2.25rem; }
}

/* Animation d'apparition au défilement (JS ajoute .is-visible) */
.reveal, .reveal-scale {
  opacity: 0;
  transition: opacity 0.6s cubic-bezier(0.21, 0.47, 0.32, 0.98),
              transform 0.6s cubic-bezier(0.21, 0.47, 0.32, 0.98);
  will-change: opacity, transform;
}
.reveal { transform: translateY(24px); }
.reveal-scale { transform: scale(0.94); }
.reveal.is-visible, .reveal-scale.is-visible {
  opacity: 1;
  transform: none;
}

/* ------------------------------------------------------------------ */
/*  5. Sections                                                        */
/* ------------------------------------------------------------------ */

/* --- 5.0 Logo & marque ------------------------------------------- */
.brand { display: inline-flex; align-items: center; gap: 0.625rem; }
.brand-logo { width: 2.25rem; height: 2.25rem; }
.logo-bg { fill: var(--brand-500); }
.logo-pixels { fill: #ffffff; }         /* pixels clairs pour contraster sur le bleu */
.logo-accent { fill: var(--mint-500); }
.brand-name {
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-strong);
}

/* --- 5.1 En-tête / navigation ------------------------------------ */
.site-header {
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 50;
  transition: background-color 0.3s ease, border-color 0.3s ease,
              backdrop-filter 0.3s ease;
  border-bottom: 1px solid transparent;
}
/* Ajouté par JS après un léger défilement */
.site-header.scrolled {
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  border-bottom-color: var(--border);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}
.nav-desktop { display: none; align-items: center; gap: 1.75rem; }
.nav-desktop a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s ease;
}
.nav-desktop a:hover { color: var(--brand-700); }
:root.dark .nav-desktop a:hover { color: var(--brand-300); }

.header-actions { display: flex; align-items: center; gap: 0.75rem; }

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  transition: color 0.2s ease, border-color 0.2s ease;
}
.icon-btn:hover { color: var(--brand-600); border-color: var(--brand-300); }

/* Icônes de bascule de thème : une seule visible selon le mode */
.theme-icon-sun { display: none; }
:root.dark .theme-icon-moon { display: none; }
:root.dark .theme-icon-sun { display: block; }

.btn-header { display: none; }
.menu-btn { color: var(--text-strong); }
.menu-icon-close { display: none; }
.menu-btn.open .menu-icon-open { display: none; }
.menu-btn.open .menu-icon-close { display: block; }

/* Menu mobile : replié par défaut, déplié via .open */
.mobile-menu {
  overflow: hidden;
  max-height: 0;
  background: var(--bg);
  border-bottom: 1px solid transparent;
  transition: max-height 0.3s ease, border-color 0.3s ease;
}
.mobile-menu.open {
  max-height: 32rem;
  border-bottom-color: var(--border);
}
.mobile-menu-inner { display: flex; flex-direction: column; gap: 0.25rem; padding-block: 1rem; }
.mobile-menu-inner a {
  border-radius: var(--radius);
  padding: 0.65rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text);
  transition: background-color 0.2s ease, color 0.2s ease;
}
.mobile-menu-inner a:hover { background: var(--brand-50); color: var(--brand-800); }
:root.dark .mobile-menu-inner a:hover { background: var(--surface); }
.mobile-cta { margin-top: 0.5rem; color: #ffffff; }

/* --- 5.2 Hero ---------------------------------------------------- */
.hero {
  position: relative;
  overflow: hidden;
  padding-top: 8rem;
  padding-bottom: 6rem;
}
.hero-fade {
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 10rem;
  pointer-events: none;
  background: linear-gradient(to top, var(--bg), transparent);
}
.hero-grid {
  position: relative;
  display: grid;
  gap: 4rem;
  align-items: center;
}
.hero-copy { max-width: 36rem; }

.hero-title {
  margin-top: 1.25rem;
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1.08;
}
.hero-highlight { position: relative; color: var(--brand-600); }
@media (min-width: 480px) { .hero-highlight { white-space: nowrap; } }
:root.dark .hero-highlight { color: var(--brand-400); }
.hero-underline {
  position: absolute;
  left: 0;
  bottom: -0.5rem;
  width: 100%;
  color: var(--mint-500);
}

.hero-lede {
  margin-top: 1.5rem;
  font-size: 1.125rem;
  color: var(--text-muted);
  text-wrap: balance;
}
.hero-actions { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: 1rem; }

.hero-audiences { margin-top: 2.5rem; display: flex; flex-wrap: wrap; gap: 0.5rem; }
.hero-audiences li {
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--surface) 70%, transparent);
  border-radius: 999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

/* Illustration du hero */
.hero-visual { padding: 2rem 1rem; }
.hero-illustration { position: relative; width: 100%; max-width: 36rem; margin-inline: auto; }
.hero-halo {
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: 999px;
  filter: blur(48px);
  background: linear-gradient(120deg,
              rgb(76 183 235 / 0.25),
              rgb(76 183 235 / 0.10) 50%,
              rgb(170 212 199 / 0.35));
}

/* Dashboard central factice */
.dashboard-mock { overflow: hidden; }
.window-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
}
.dot { width: 0.625rem; height: 0.625rem; border-radius: 999px; }
.dot-red { background: var(--red-400); }
.dot-orange { background: #fbbf24; }
.dot-green { background: var(--mint-500); }
.window-title { margin-left: 0.75rem; font-size: 0.75rem; font-weight: 500; color: var(--text-muted); }

.dashboard-body {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  padding: 1rem;
}
.mini-kpi { border-radius: var(--radius); padding: 0.75rem; }
.mini-kpi-primary { background: var(--brand-50); color: var(--brand-700); }
.mini-kpi-green   { background: rgb(76 183 235 / 0.12); color: var(--brand-700); }
.mini-kpi-mint  { background: rgb(170 212 199 / 0.28); color: var(--mint-600); }
:root.dark .mini-kpi-primary { background: rgb(76 183 235 / 0.12); color: var(--brand-300); }
:root.dark .mini-kpi-green   { color: var(--brand-300); }
:root.dark .mini-kpi-mint  { color: var(--mint-400); }
.mini-kpi-value {
  margin-top: 0.5rem;
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-strong);
}
.mini-kpi-label { font-size: 0.6875rem; color: var(--text-muted); }

.mini-chart {
  grid-column: span 3;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
}
.mini-chart-title { margin-bottom: 0.75rem; font-size: 0.75rem; font-weight: 600; color: var(--text-muted); }
.mini-bars { display: flex; align-items: flex-end; gap: 0.5rem; height: 6rem; }
.mini-bar {
  flex: 1;
  height: 0;                 /* animé vers --h par JS/CSS */
  border-radius: 0.375rem 0.375rem 0 0;
  background: var(--brand-200);
  transition: height 0.8s cubic-bezier(0.21, 0.47, 0.32, 0.98);
}
:root.dark .mini-bar { background: rgb(76 183 235 / 0.35); }
.mini-bar-last { background: var(--brand-500); }
.mini-bars.animate .mini-bar { height: var(--h); }

/* Cartes flottantes autour du dashboard */
.float-card { position: absolute; padding: 0.75rem; }
.float-card-row { margin-top: 0.5rem; display: flex; align-items: center; gap: 0.375rem; }
.float-card-note { font-size: 0.6875rem; font-weight: 500; line-height: 1.3; color: var(--text-muted); }
.float-card-title { font-size: 0.75rem; font-weight: 700; color: var(--text-strong); }

.float-card-qr {
  left: -1rem;
  top: -2rem;
  width: 10rem;
  animation: float 6s ease-in-out infinite;
}
.qr-wrap { position: relative; width: fit-content; margin-inline: auto; padding: 0.375rem; overflow: hidden; border-radius: 0.5rem; }
.qr-glyph { width: 4rem; height: 4rem; }
.qr-pixels { fill: var(--text-strong); }
.scan-line {
  position: absolute;
  left: 0.375rem;
  right: 0.375rem;
  top: 0.5rem;
  height: 2px;
  border-radius: 999px;
  background: var(--brand-500);
  box-shadow: 0 0 12px 2px rgb(76 183 235 / 0.6);
  animation: scan-line 2.4s ease-in-out infinite;
}

.float-card-report {
  right: -0.75rem;
  top: 2.5rem;
  width: 11rem;
  padding: 1rem;
  animation: float 7s ease-in-out 1.4s infinite;
}
.float-card-head { display: flex; align-items: center; gap: 0.5rem; }
.chip-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 0.5rem;
  background: var(--brand-50);
  color: var(--brand-700);
}
:root.dark .chip-icon { background: rgb(76 183 235 / 0.14); color: var(--brand-300); }
.report-rows { margin-top: 0.75rem; display: flex; flex-direction: column; gap: 0.375rem; }
.report-row { display: flex; justify-content: space-between; font-size: 0.6875rem; }
.report-row span { color: var(--text-muted); }
.report-row strong { color: var(--text-strong); font-weight: 600; }
.report-badge {
  margin-top: 0.75rem;
  border-radius: 0.375rem;
  background: rgb(76 183 235 / 0.14);
  color: var(--brand-700);
  padding: 0.25rem 0.5rem;
  text-align: center;
  font-size: 0.625rem;
  font-weight: 600;
}
:root.dark .report-badge { color: var(--brand-300); }

.float-card-pay {
  bottom: -2rem;
  right: 0.5rem;
  width: 12rem;
  padding: 1rem;
  animation: float 6s ease-in-out 0.7s infinite;
}
.pay-head { display: flex; align-items: center; justify-content: space-between; }
.pay-amount {
  margin-top: 0.5rem;
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-strong);
}
.pay-status { margin-top: 0.5rem; display: flex; align-items: center; gap: 0.375rem; }
.pay-dot { width: 0.5rem; height: 0.5rem; border-radius: 999px; background: var(--brand-500); }
.pay-status p { font-size: 0.6875rem; font-weight: 500; color: var(--brand-700); }
:root.dark .pay-status p { color: var(--brand-300); }

/* --- 5.3 Clients ------------------------------------------------- */
.clients {
  border-block: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg-alt) 60%, var(--bg));
  padding-block: 3rem;
  scroll-margin-top: 6rem;
}
.clients-title {
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
}
.clients-grid {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}
.client-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.625rem;
  padding: 1rem;
  text-align: center;
}
.client-mono {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius);
  background: var(--brand-50);
  color: var(--brand-800);
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 0.875rem;
  font-weight: 700;
}
:root.dark .client-mono { background: rgb(76 183 235 / 0.14); color: var(--brand-300); }
.client-name { font-size: 0.875rem; font-weight: 600; color: var(--text-strong); line-height: 1.2; }
.client-location {
  margin-top: 0.125rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}
.client-note {
  margin-top: 0.25rem;
  display: inline-block;
  border-radius: 999px;
  background: var(--bg-alt);
  color: var(--text-muted);
  padding: 0.1rem 0.5rem;
  font-size: 0.625rem;
  font-weight: 500;
}
:root.dark .client-note { background: var(--surface); }

/* --- 5.4 Avantages ----------------------------------------------- */
.advantages-grid {
  margin-top: 3.5rem;
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}
.advantage { padding: 1.5rem; height: 100%; }
.advantage-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius);
  background: var(--brand-50);
  color: var(--brand-600);
  transition: background-color 0.25s ease, color 0.25s ease;
}
:root.dark .advantage-icon { background: rgb(76 183 235 / 0.14); color: var(--brand-300); }
.advantage:hover .advantage-icon { background: var(--brand-500); color: #ffffff; }
.advantage h3 { margin-top: 1rem; font-size: 1.125rem; font-weight: 700; }
.advantage p { margin-top: 0.5rem; font-size: 0.875rem; color: var(--text-muted); }

/* --- 5.5 Produits ------------------------------------------------ */
.products-grid {
  margin-top: 3.5rem;
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}
.product { position: relative; display: flex; flex-direction: column; padding: 1.75rem; height: 100%; }
.product-featured {
  border-color: var(--brand-300);
  box-shadow: 0 0 0 1px var(--brand-200), var(--shadow-soft);
}
:root.dark .product-featured {
  border-color: var(--brand-700);
  box-shadow: 0 0 0 1px var(--brand-800), var(--shadow-soft);
}
.product-badge {
  position: absolute;
  top: -0.75rem;
  left: 1.5rem;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  border-radius: 999px;
  background: var(--mint-500);
  color: #fff;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  box-shadow: var(--shadow-soft);
}
.product-badge .icon { fill: currentColor; }
.product-audience {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--brand-700);
}
:root.dark .product-audience { color: var(--brand-400); }
.product-name { margin-top: 0.5rem; font-size: 1.25rem; font-weight: 700; }
.product-tagline { margin-top: 0.5rem; font-size: 0.875rem; color: var(--text-muted); }

.feature-list { margin-top: 1.25rem; display: flex; flex-direction: column; gap: 0.625rem; }
.feature-list li { display: flex; align-items: flex-start; gap: 0.625rem; font-size: 0.875rem; color: var(--text); }
.feature-list .icon { margin-top: 0.15rem; color: var(--brand-600); }

.feature-group { margin-top: 1.25rem; }
.feature-group-title {
  display: inline-block;
  margin-bottom: 0.5rem;
  border-radius: 0.375rem;
  background: var(--brand-50);
  color: var(--brand-800);
  padding: 0.25rem 0.625rem;
  font-size: 0.75rem;
  font-weight: 700;
}
:root.dark .feature-group-title { background: rgb(76 183 235 / 0.14); color: var(--brand-300); }
.feature-group .feature-list { margin-top: 0; }

.product-cta { margin-top: auto; padding-top: 1.5rem; }

/* --- 5.6 Gamme FY (écosystème de produits) ----------------------- */
.suite-grid {
  margin-top: 3.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
.suite-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
  height: 100%;
  color: inherit;
}
.suite-card-current { border-style: dashed; border-color: var(--brand-300); }
:root.dark .suite-card-current { border-color: var(--brand-700); }
.suite-badge {
  position: absolute;
  top: -0.75rem;
  left: 1.25rem;
  border-radius: 999px;
  background: var(--brand-500);
  color: #fff;
  padding: 0.2rem 0.75rem;
  font-size: 0.7rem;
  font-weight: 700;
  box-shadow: var(--shadow-soft);
}
.suite-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius);
  background: var(--brand-50);
  color: var(--brand-600);
  transition: background-color 0.25s ease, color 0.25s ease;
}
:root.dark .suite-icon { background: rgb(76 183 235 / 0.14); color: var(--brand-300); }
.suite-card:hover .suite-icon { background: var(--brand-500); color: #ffffff; }
.suite-name {
  margin-top: 1rem;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.suite-desc { margin-top: 0.5rem; font-size: 0.875rem; color: var(--text-muted); flex-grow: 1; }
.suite-link { margin-top: 1rem; font-size: 0.85rem; }

/* --- 5.6bis Pages produit de la gamme ----------------------------- */
.product-hero { padding-top: calc(var(--header-h) + 3.5rem); padding-bottom: 3.5rem; }
.product-hero-inner { max-width: 46rem; }
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}
.breadcrumb a { color: var(--brand-700); font-weight: 600; }
.breadcrumb a:hover { color: var(--brand-600); }
:root.dark .breadcrumb a { color: var(--brand-400); }
.product-hero-icon {
  margin-top: 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: var(--radius-lg);
  background: var(--brand-50);
  color: var(--brand-600);
}
:root.dark .product-hero-icon { background: rgb(76 183 235 / 0.14); color: var(--brand-300); }
.product-hero-icon .icon { width: 1.75rem; height: 1.75rem; }
.product-hero-title { margin-top: 1rem; font-size: clamp(2rem, 5vw, 2.75rem); font-weight: 800; }
.product-hero-tagline { margin-top: 0.75rem; font-size: 1.125rem; color: var(--text-muted); }
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  margin-top: 1.25rem;
  border-radius: 999px;
  border: 1px solid var(--mint-400);
  background: rgb(170 212 199 / 0.22);
  color: var(--mint-600);
  padding: 0.3rem 0.85rem;
  font-size: 0.75rem;
  font-weight: 700;
}
:root.dark .status-badge { color: var(--mint-400); background: rgb(170 212 199 / 0.10); }


.features-grid {
  margin-top: 3.5rem;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}
.feature-chip {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-strong);
  height: 100%;
}
.feature-chip-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  flex-shrink: 0;
  border-radius: 0.625rem;
  background: var(--brand-50);
  color: var(--brand-600);
}
:root.dark .feature-chip-icon { background: rgb(76 183 235 / 0.14); color: var(--brand-300); }

/* --- 5.7 Tableaux de bord ---------------------------------------- */
.kpi-grid {
  margin-top: 3.5rem;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}
.kpi { padding: 1.25rem; }
.kpi-label { font-size: 0.75rem; font-weight: 500; color: var(--text-muted); }
.kpi-value {
  margin-top: 0.25rem;
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-strong);
}
.kpi-delta { margin-top: 0.25rem; font-size: 0.75rem; font-weight: 600; color: var(--brand-700); }
:root.dark .kpi-delta { color: var(--brand-400); }

.charts-grid {
  margin-top: 1.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}
.chart-card { padding: 1.5rem; }
.chart-card h3 { font-size: 1rem; font-weight: 700; }
.chart-subtitle { margin-top: 0.25rem; font-size: 0.75rem; color: var(--text-muted); }
.chart { margin-top: 1.25rem; height: 16rem; }

/* Styles internes des graphiques SVG (dessinés par js/charts.js) */
.chart svg { width: 100%; height: 100%; overflow: visible; }
.chart .axis-line { stroke: var(--border); stroke-width: 1; }
.chart .grid-line { stroke: var(--border); stroke-dasharray: 3 3; }
.chart .axis-label { fill: var(--text-muted); font-size: 11px; font-family: "Inter", sans-serif; }
.chart .bar { transition: opacity 0.2s ease; }
.chart .bar:hover { opacity: 0.8; }
.chart-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin-top: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}
.chart-legend span { display: inline-flex; align-items: center; gap: 0.375rem; }
.legend-swatch { width: 0.75rem; height: 0.75rem; border-radius: 0.25rem; }

/* Infobulle partagée des graphiques */
.chart-tooltip {
  position: fixed;
  z-index: 60;
  pointer-events: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.75rem;
  color: var(--text-strong);
  box-shadow: var(--shadow-lift);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  white-space: nowrap;
}
.chart-tooltip.visible { opacity: 1; transform: translateY(0); }

/* --- 5.8 Pourquoi nous choisir ----------------------------------- */
.whyus {
  overflow: hidden;
  background: var(--brand-600);
  border-color: var(--brand-500);
}
:root.dark .whyus { background: var(--brand-700); border-color: var(--brand-600); }
.whyus-grid {
  display: grid;
  gap: 2.5rem;
  padding: 2rem;
}
.whyus-eyebrow {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgb(255 255 255 / 0.25);
  background: rgb(255 255 255 / 0.10);
  color: #fff;
  border-radius: 999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.whyus-intro { display: flex; flex-direction: column; align-items: flex-start; gap: 1rem; }
.whyus-title { font-size: 1.875rem; font-weight: 700; color: #fff; }
.whyus-lede { font-size: 1.0625rem; color: rgb(255 255 255 / 0.85); text-wrap: balance; }
.whyus-list { display: grid; gap: 1.5rem 2rem; grid-template-columns: 1fr; }
.whyus-list li { display: flex; gap: 0.875rem; }
.whyus-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  flex-shrink: 0;
  border-radius: var(--radius);
  background: rgb(255 255 255 / 0.15);
  color: #fff;
}
.whyus-list h3 { font-size: 1rem; font-weight: 700; color: #fff; }
.whyus-list p { margin-top: 0.25rem; font-size: 0.875rem; color: rgb(255 255 255 / 0.85); }

/* --- 5.9 Témoignages --------------------------------------------- */
.testimonials-grid {
  margin-top: 3.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}
.testimonial { display: flex; flex-direction: column; padding: 1.75rem; height: 100%; }
.quote-icon { width: 1.5rem; height: 1.5rem; color: var(--brand-300); fill: none; }
:root.dark .quote-icon { color: var(--brand-700); }
.testimonial blockquote { margin-top: 1rem; flex: 1; font-size: 0.875rem; color: var(--text); }
.testimonial figcaption {
  margin-top: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-top: 1px solid var(--border);
  padding-top: 1.25rem;
}
.testimonial-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  flex-shrink: 0;
  border-radius: 999px;
  background: var(--brand-500);
  color: #ffffff;
  font-size: 0.875rem;
  font-weight: 700;
}
.testimonial-name { font-size: 0.875rem; font-weight: 600; color: var(--text-strong); }
.testimonial-role { font-size: 0.75rem; color: var(--text-muted); }

/* --- 5.10 FAQ ---------------------------------------------------- */
.faq-list { margin-top: 3rem; display: flex; flex-direction: column; gap: 1rem; }
.faq-item { overflow: hidden; }
.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  padding: 1.25rem 1.5rem;
  text-align: left;
  background: none;
  border: none;
  color: var(--text-strong);
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 1rem;
  font-weight: 700;
}
.faq-chevron { color: var(--brand-600); transition: transform 0.3s ease; }
:root.dark .faq-chevron { color: var(--brand-400); }
.faq-question[aria-expanded="true"] .faq-chevron { transform: rotate(180deg); }
.faq-answer {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.3s ease;
}
.faq-answer p {
  padding: 0 1.5rem 1.5rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* --- 5.11 Contact ------------------------------------------------ */
.contact-grid {
  margin-top: 3.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}
/* Autorise les colonnes à rétrécir sous la largeur de leur contenu
   (évite un débordement horizontal sur mobile). */
.contact-grid > * { min-width: 0; }
.contact-info p { min-width: 0; word-break: break-word; }
.contact-card { padding: 1.75rem; }
.contact-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
.form-field { display: flex; flex-direction: column; }
.form-field label {
  margin-bottom: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text);
}
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  color: var(--text-strong);
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.form-field textarea { resize: vertical; min-height: 6rem; }
.form-field input::placeholder,
.form-field textarea::placeholder { color: var(--text-muted); opacity: 0.7; }
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--brand-500);
  box-shadow: 0 0 0 3px rgb(76 183 235 / 0.18);
}
/* Champ en erreur (ajouté par la validation JS) */
.form-field input.invalid,
.form-field select.invalid,
.form-field textarea.invalid {
  border-color: var(--red-400);
  box-shadow: 0 0 0 3px rgb(248 113 113 / 0.15);
}
.field-error { margin-top: 0.25rem; font-size: 0.75rem; color: #dc2626; }
:root.dark .field-error { color: #f87171; }

/* Erreur globale du formulaire (échec d'envoi côté serveur) */
.form-error-banner {
  margin-bottom: 1rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--red-400);
  background: rgb(248 113 113 / 0.1);
  color: #dc2626;
  font-size: 0.875rem;
}
:root.dark .form-error-banner { color: #f87171; }

.btn-submit { width: 100%; }
.btn-submit:disabled { opacity: 0.7; cursor: not-allowed; }

/* Message de confirmation après envoi */
.contact-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 20rem;
  gap: 0.25rem;
}
.success-icon { width: 3.5rem; height: 3.5rem; color: var(--brand-600); }
.contact-success h3 { margin-top: 1rem; font-size: 1.25rem; font-weight: 700; }
.contact-success p { margin-top: 0.5rem; max-width: 24rem; font-size: 0.875rem; color: var(--text-muted); }
.contact-success button { margin-top: 1.5rem; }

.contact-aside { display: flex; flex-direction: column; gap: 1.5rem; }
.contact-info { display: flex; flex-direction: column; gap: 1rem; padding: 1.75rem; }
.contact-info p { display: flex; align-items: center; gap: 0.75rem; font-size: 0.875rem; color: var(--text); }
.contact-info .icon { color: var(--brand-600); }
:root.dark .contact-info .icon { color: var(--brand-400); }

/* Carte fictive */
.fake-map { position: relative; height: 16rem; overflow: hidden; flex: 1; }
.fake-map svg { width: 100%; height: 100%; }
.map-bg { fill: var(--bg-alt); }
.map-park { fill: rgb(76 183 235 / 0.20); }
.map-road { stroke: var(--surface); }
:root.dark .map-road { stroke: var(--border); }
.map-lake { fill: rgb(76 183 235 / 0.30); }
.map-marker {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -100%);
}
.map-ping {
  position: absolute;
  inset: -0.75rem;
  border-radius: 999px;
  background: rgb(76 183 235 / 0.30);
  animation: ping 1.5s cubic-bezier(0, 0, 0.2, 1) infinite;
}
.map-pin-icon { width: 2.25rem; height: 2.25rem; fill: var(--brand-600); stroke: #fff; filter: drop-shadow(0 4px 6px rgb(0 0 0 / 0.3)); }
.map-label {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--surface) 90%, transparent);
  padding: 0.75rem 1rem;
  box-shadow: var(--shadow-soft);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  max-width: 15rem;
}
.map-label-title { font-size: 0.875rem; font-weight: 600; color: var(--text-strong); }
.map-label-address { font-size: 0.75rem; color: var(--text-muted); }

/* --- 5.12 Pied de page ------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg);
  padding-block: 3.5rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
}
.footer-tagline { margin-top: 1rem; max-width: 20rem; font-size: 0.875rem; color: var(--text-muted); }
.footer-socials { margin-top: 1.25rem; display: flex; gap: 0.75rem; }
.footer-socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.625rem;
  border: 1px solid var(--border);
  color: var(--text-muted);
  transition: color 0.2s ease, border-color 0.2s ease;
}
.footer-socials a:hover { color: var(--brand-600); border-color: var(--brand-400); }
.footer-socials .icon { fill: none; }
.footer-heading {
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-strong);
}
.site-footer nav ul { margin-top: 1rem; display: flex; flex-direction: column; gap: 0.625rem; }
.site-footer nav a { font-size: 0.875rem; color: var(--text-muted); transition: color 0.2s ease; }
.site-footer nav a:hover { color: var(--brand-600); }
.footer-bottom {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ------------------------------------------------------------------ */
/*  6. Responsive                                                      */
/* ------------------------------------------------------------------ */
@media (min-width: 640px) {
  .clients-grid { grid-template-columns: repeat(3, 1fr); }
  .advantages-grid { grid-template-columns: repeat(2, 1fr); }
  .features-grid { grid-template-columns: repeat(3, 1fr); }
  .products-grid { grid-template-columns: repeat(2, 1fr); }
  .suite-grid { grid-template-columns: repeat(2, 1fr); }
  .testimonials-grid { grid-template-columns: repeat(2, 1fr); }
  .whyus-list { grid-template-columns: repeat(2, 1fr); }
  .contact-form { grid-template-columns: repeat(2, 1fr); }
  .form-field-full { grid-column: span 2; }
  .btn-submit { width: auto; }
  .btn-header { display: inline-flex; }
  .footer-bottom { flex-direction: row; justify-content: space-between; }
  .whyus-grid { padding: 3rem; }
}

@media (min-width: 768px) {
  .charts-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1.2fr 1fr; }
}

@media (min-width: 1024px) {
  .nav-desktop { display: flex; }
  .menu-btn { display: none; }
  .hero-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-title { font-size: 3.75rem; }
  .advantages-grid { grid-template-columns: repeat(3, 1fr); }
  .features-grid { grid-template-columns: repeat(4, 1fr); }
  .suite-grid { grid-template-columns: repeat(3, 1fr); }
  .kpi-grid { grid-template-columns: repeat(4, 1fr); }
  .clients-grid { grid-template-columns: repeat(5, 1fr); }
  .footer-grid { grid-template-columns: 1.4fr repeat(4, 1fr); }
  .whyus-grid { grid-template-columns: 1fr 1.4fr; gap: 3.5rem; }
}

@media (min-width: 1280px) {
  .products-grid { grid-template-columns: repeat(3, 1fr); }
  .suite-grid { grid-template-columns: repeat(4, 1fr); }
  .testimonials-grid { grid-template-columns: repeat(3, 1fr); }
  .features-grid { grid-template-columns: repeat(5, 1fr); }
  /* La version phare occupe deux rangées comme dans la maquette d'origine */
  .product-featured { grid-row: span 2; }
}

/* ------------------------------------------------------------------ */
/*  7. Accessibilité                                                   */
/* ------------------------------------------------------------------ */
/* Focus clavier visible partout */
:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--brand-500);
  border-radius: 0.375rem;
}

/* Respect de la préférence "réduire les animations" */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal, .reveal-scale { opacity: 1; transform: none; }
}

/* ------------------------------------------------------------------ */
/*  Keyframes                                                          */
/* ------------------------------------------------------------------ */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
@keyframes scan-line {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(46px); }
}
@keyframes ping {
  75%, 100% { transform: scale(2); opacity: 0; }
}
