/* =========================================
   1. VARIABLES & RESET
   ========================================= */
:root {
  --eco-blue: #004687;
  --eco-blue-hover: #003366;
  --eco-green: #2ecc71;
  --text-main: #1d1d1f; /* Noir doux façon Apple */
  --text-muted: #86868b;
  --bg-white: #ffffff;
  --bg-light: #f5f5f7;
  --nav-height: 70px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Inter', sans-serif;
  color: var(--text-main);
  background-color: var(--bg-white);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

a { text-decoration: none; color: inherit; }

/* =========================================
   2. BOUTONS GLOBAUX (Version Blindée)
   ========================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-size: 1rem;
  font-weight: 700;
  border-radius: 50px;
  text-decoration: none !important;
  transition: all 0.3s ease;
  cursor: pointer;
  line-height: 1;
  text-align: center;
  /* STYLE PAR DÉFAUT : Bouton blanc avec bordure (règle le problème des boutons invisibles) */
  background: var(--bg-white);
  color: var(--text-main) !important;
  border: 2px solid #e5e5e5;
}

.btn:hover {
  border-color: var(--eco-blue);
  color: var(--eco-blue) !important;
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}

/* Surcharge pour le bouton principal (Bleu) */
.btn.btn-primary {
  background: var(--eco-blue);
  color: #ffffff !important;
  border-color: var(--eco-blue);
}

.btn.btn-primary:hover {
  background: #003060;
  border-color: #003060;
  box-shadow: 0 10px 20px rgba(0, 70, 135, 0.15);
  color: #ffffff !important;
}

/* =========================================
   HEADER & NAVBAR (V8 - Corrections finales)
   ========================================= */

body {
  overflow-x: clip;
}

.site-header {
  background: var(--bg-white);
  height: 90px;
  position: relative;
  z-index: 999;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  width: 100%;
  box-sizing: border-box;
}

.header-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 0 40px;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
  position: relative;
}

/* --- LOGO --- */
.site-header .logo {
  display: flex;
  align-items: center;
  position: relative;
  width: 160px;
  height: 100%;
  flex-shrink: 0;
  z-index: 10;
}

.site-header .logo-img {
  position: absolute;
  top: 5px; /* ✅ Changé de -10px à 5px pour bien descendre le logo */
  left: 0;
  height: 95px; /* Légère réduction pour un équilibre parfait dans les 90px du header */
  width: auto;
  max-width: none;
}

/* --- MENU CENTRÉ (Descente augmentée) --- */
.main-nav {
  position: absolute;
  left: 50%;
  transform: translateX(-50%) translateY(8px); /* ✅ Augmenté de 3px à 8px */
  display: flex;
  align-items: center;
  z-index: 5;
}

.main-nav ul {
  display: flex !important;
  align-items: center !important;
  gap: 40px !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

.main-nav > ul > li {
  display: flex;
  align-items: center;
  margin: 0 !important;
  padding: 0 !important;
  position: relative;
}

.main-nav a {
  color: var(--text-main);
  font-weight: 600;
  text-decoration: none;
  font-size: 0.95rem;
  white-space: nowrap;
  transition: color 0.3s ease;
  display: flex !important;
  align-items: center;
  padding: 8px 0 !important;
  margin: 0 !important;
}

.main-nav a:hover {
  color: var(--eco-blue);
}

/* --- DROPDOWNS --- */
.dropdown {
  position: relative;
  display: flex;
  align-items: center;
  cursor: pointer;
}

.dropdown > a::after {
  content: "▼";
  font-size: 0.6rem;
  margin-left: 6px;
  color: var(--eco-blue);
  transition: transform 0.3s ease;
}

.dropdown:hover > a::after {
  transform: rotate(180deg);
}

.dropdown-content {
  position: absolute;
  top: 100%; /* ✅ On colle au bord pour ne pas perdre le focus */
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-white);
  min-width: 220px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 10px;
  padding: 8px 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
  z-index: 9999;
  list-style: none;
  margin: 0;
}

/* ✅ PONT INVISIBLE : Maintient le menu ouvert lors du passage de la souris */
.dropdown-content::before {
  content: "";
  position: absolute;
  top: -20px;
  left: 0;
  width: 100%;
  height: 20px;
}

.dropdown:hover .dropdown-content {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.dropdown-content li {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
}

.dropdown-content li a {
  display: block !important;
  padding: 10px 20px !important;
  font-size: 0.9rem !important;
  font-weight: 500 !important;
  color: var(--text-main) !important;
  text-decoration: none !important;
  transition: background 0.2s ease, color 0.2s ease !important;
  height: auto !important;
  border-radius: 6px !important;
  margin: 0 4px !important;
}

.dropdown-content li a:hover {
  background: rgba(0, 70, 135, 0.08) !important;
  color: var(--eco-blue) !important;
}

/* --- ACTIONS (À droite - Descente augmentée) --- */
.header-actions {
  display: flex !important;
  align-items: center !important;
  flex-direction: row !important;
  gap: 25px !important; /* Plus d'espace entre icônes et bouton */
  flex-shrink: 0;
  z-index: 10;
  transform: translateY(0); /* ✅ Aligné parfaitement au centre */
}

.header-social {
  display: flex !important;
  flex-direction: row !important; /* ✅ Icônes côte à côte */
  align-items: center !important;
  gap: 15px !important;
  padding-right: 15px !important;
  border-right: 1px solid #eee; /* Petite séparation élégante */
}

.header-social a {
  color: #b1b1b6 !important;
  transition: all 0.3s ease;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-decoration: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.header-social a:hover {
  color: var(--eco-blue) !important;
  transform: translateY(-2px);
}

.header-social svg {
  width: 20px !important;
  height: 20px !important;
  display: block !important;
}

/* --- BOUTON CTA --- */
.btn.btn-small {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 11px 26px !important;
  font-size: 0.95rem !important;
  font-weight: 700 !important;
  background: var(--eco-blue) !important;
  color: #fff !important;
  border-radius: 50px !important;
  border: 2px solid var(--eco-blue) !important;
  white-space: nowrap !important;
  transition: all 0.3s ease !important;
  text-decoration: none !important;
  margin: 0 !important;
  line-height: 1 !important;
}

.btn.btn-small:hover {
  background: #003060 !important;
  border-color: #003060 !important;
}

/* =========================================
   MENU MOBILE
   ========================================= */

.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  z-index: 1001;
}

.mobile-menu-toggle span {
  width: 25px;
  height: 3px;
  background: var(--text-main);
  border-radius: 2px;
  transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translateY(8px);
}

.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translateY(-8px);
}

.mobile-menu {
  position: fixed;
  top: 90px;
  right: -100%;
  width: 300px;
  height: calc(100vh - 90px);
  background: var(--bg-white);
  box-shadow: -4px 0 20px rgba(0, 0, 0, 0.1);
  transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 998;
  overflow-y: auto;
  padding: 30px 20px;
}

.mobile-menu.active {
  right: 0;
}

.mobile-overlay {
  position: fixed;
  top: 90px;
  left: 0;
  width: 100%;
  height: calc(100vh - 90px);
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 997;
}

.mobile-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.mobile-nav > a,
.mobile-nav .mobile-dropdown > a {
  display: block;
  padding: 16px 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-main);
  text-decoration: none;
  border-bottom: 1px solid #f0f0f0;
  transition: color 0.2s ease;
}

.mobile-nav > a:hover,
.mobile-nav .mobile-dropdown > a:hover {
  color: var(--eco-blue);
}

.mobile-dropdown {
  border-bottom: 1px solid #f0f0f0;
}

.mobile-dropdown > a {
  border: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mobile-dropdown > a::after {
  content: "▼";
  font-size: 0.7rem;
  color: var(--eco-blue);
  transition: transform 0.3s ease;
}

.mobile-dropdown.active > a::after {
  transform: rotate(180deg);
}

.mobile-dropdown-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  padding-left: 15px;
}

.mobile-dropdown.active .mobile-dropdown-content {
  max-height: 300px;
}

.mobile-dropdown-content a {
  display: block;
  padding: 12px 0;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
}

.mobile-dropdown-content a:hover {
  color: var(--eco-blue);
}

.mobile-social {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid #f0f0f0;
}

.mobile-social a {
  color: var(--text-muted);
  transition: color 0.3s ease;
}

.mobile-social a:hover {
  color: var(--eco-blue);
}

.mobile-social svg {
  width: 24px;
  height: 24px;
}

.mobile-cta {
  margin-top: 30px;
}

.mobile-cta .btn {
  width: 100%;
  text-align: center;
  padding: 14px 20px;
}

@media (max-width: 992px) {
  .desktop-only { display: none !important; }
  .mobile-only { display: block !important; }
  
  /* ✅ HEADER MOBILE : Centrage mathématique parfait */
  .header-flex {
    padding: 0 20px;
    justify-content: flex-end !important; /* Pousse le bouton menu à droite */
    position: relative;
    height: 100%;
  }
  
  .site-header .logo {
    position: absolute !important;
    left: 50% !important;
    top: 50% !important;
    transform: translate(-50%, -50%) !important; /* ✅ Centre le logo par rapport à l'écran */
    width: auto !important;
    margin: 0 !important;
    z-index: 10;
  }

  .site-header .logo-img {
    position: relative !important;
    top: 0 !important; 
    height: 75px !important; /* Taille ajustée pour smartphone */
    display: block !important;
  }

  /* ✅ BOUTON MENU : Calé à droite */
  .mobile-menu-toggle {
    display: flex !important;
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 20;
  }
  
  .header-actions {
    display: flex !important;
    background: transparent;
  }
  .header-actions .header-social,
  .header-actions .btn {
    display: none !important;
  }

  .main-nav {
    position: static;
    transform: none;
  }

  .main-nav {
    position: static;
    transform: none;
  }
}

/* =========================================
   3. HERO SECTION
   ========================================= */
.hero-eco {
  padding: 100px 0 60px;
  text-align: center;
  background: var(--bg-white);
}

/* Nouveau style pour la Hero avec image de fond */
.hero-bg {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  padding: 140px 20px 160px; /* Évite que le texte touche les bords sur mobile */
  position: relative;
  /* L'image et le dégradé sont gérés directement dans le HTML (style inline) */
}

/* On limite la largeur du texte pour la lisibilité */
.hero-wrapper.text-center {
  margin: 0 auto;
  max-width: 800px; 
}

/* Forcer le texte en blanc sur le fond sombre de l'image */
.hero-bg .text-white {
  color: #ffffff;
}

/* Un bleu plus clair pour bien ressortir sur l'overlay marine/noir */
.hero-bg .text-blue-light {
  color: #66b5ff; 
}

.badge-law {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  background: var(--bg-light);
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--eco-blue);
  margin-bottom: 30px;
  border: 1px solid rgba(0, 70, 135, 0.1);
}

.badge-law .dot {
  width: 8px; height: 8px; background: var(--eco-green);
  border-radius: 50%; margin-right: 8px;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.4); }
  70% { box-shadow: 0 0 0 6px rgba(46, 204, 113, 0); }
  100% { box-shadow: 0 0 0 0 rgba(46, 204, 113, 0); }
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 25px;
}

.text-blue { color: var(--eco-blue); }

.hero-subtitle {
  font-size: clamp(1.1rem, 2.5vw, 1.3rem);
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 40px;
}

.hero-cta-group { 
  display: flex; 
  gap: 15px; 
  justify-content: center; /* On recentre les boutons pour le nouveau layout */
  margin-bottom: 60px; 
}

/* Classe utilitaire d'alignement */
.justify-center {
  justify-content: center;
}

/* --- MOBILE --- */
@media (max-width: 992px) {
  .hero-eco {
    padding: 80px 0 40px;
  }
  
  .hero-bg {
    padding: 100px 15px 120px;
  }
  
  .hero-cta-group {
    flex-direction: column;
    align-items: center;
    gap: 15px;
  }
  
  .hero-cta-group .btn {
    width: 100%; /* Les boutons prennent toute la largeur sur smartphone */
  }
}

/* =========================================
   HOMEPAGE : DASHBOARD IMPACT (Correction Padding Gauche)
   ========================================= */

.dashboard-impact {
  padding: 80px 0;
  background: var(--bg-white);
}

.stats-grid {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* --- DESIGN DES CARTES --- */
.stat-card {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important; 
  justify-content: center !important;
  text-align: center !important; 
  transition: transform 0.3s ease;
}

.stat-number-wrap {
  display: flex;
  justify-content: center;
  align-items: baseline;
  margin-bottom: 8px;
}

.stat-number { 
  font-size: 3.5rem; 
  font-weight: 800; 
  color: var(--text-main); 
  letter-spacing: -1px; 
}

.stat-unit { 
  font-size: 1.5rem; 
  font-weight: 800; 
  color: var(--eco-blue); 
  margin-left: 2px; 
}

.stat-label {
  display: block;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  font-weight: 600;
  width: 100%;
  text-align: center !important;
}

/* --- COMPORTEMENT PC (Look d'origine : pas de boîtes) --- */
@media (min-width: 993px) {
  .stats-grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important; 
    gap: 40px;
    max-width: 1100px;
    margin: 0 auto;
  }
  .stat-card {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
  }
}

/* --- COMPORTEMENT MOBILE (Swipe - Fix Premier Élément & Padding) --- */
@media (max-width: 992px) {
  .dashboard-impact { padding: 40px 0; }
  
  .dashboard-impact .container {
    padding: 0 !important;
  }

  .stats-grid {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: flex-start !important; 
    overflow-x: auto !important;
    scroll-snap-type: x mandatory !important;
    /* ✅ FIX : scroll-padding force le respect de la marge de 24px à gauche lors du swipe */
    scroll-padding: 0 24px !important; 
    gap: 15px !important;
    padding: 10px 24px 30px 24px !important; 
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .stats-grid::-webkit-scrollbar { display: none; }

  .stat-card {
    flex: 0 0 85% !important;
    scroll-snap-align: start !important; 
    background: var(--bg-light) !important;
    border-radius: 20px;
    padding: 40px 20px !important;
    border: 1px solid rgba(0,0,0,0.03) !important; /* Ajout de la bordure pour la cohérence visuelle */
  }
}

/* =========================================
   HOMEPAGE : STORYTELLING (Correction Centrage CTA)
   ========================================= */

/* ... (Garder la partie PC intacte) ... */

@media (max-width: 992px) {
  /* ... (Garder le reste du bloc mobile storytelling identique) ... */

  /* ✅ FORCE LE CENTRAGE DU BOUTON CTA SUR MOBILE */
  .story-step div:last-child {
    text-align: center !important;
    width: 100% !important;
  }
  
  .story-step .btn {
    margin: 0 auto !important;
    display: inline-flex !important;
  }
}

/* =========================================
   6. STORYTELLING TUNNEL (Sticky Scroll)
   ========================================= */
.story-tunnel {
  background: var(--bg-light);
  padding: 80px 0;
}

.story-container {
  display: flex;
  gap: 60px;
  position: relative;
  align-items: flex-start;
}

/* Visuels Sticky */
.story-visuals {
  flex: 1;
  position: sticky;
  top: calc(var(--nav-height) + 40px); /* Bloqué juste sous le menu */
  height: 70vh;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

.story-img {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: opacity; /* Optimisation PageSpeed */
}

.story-img.active { opacity: 1; z-index: 2; }

.story-content {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 15px; /* Écart réduit entre les cartes */
    padding: 10px 20px 40px 20px; /* Marges de sécurité à gauche et à droite */
    -ms-overflow-style: none;
    scrollbar-width: none;
  }

  .story-content::-webkit-scrollbar {
    display: none;
  }

  .story-step {
    flex: 0 0 78%; /* <-- LARGEUR RÉDUITE (avant 88%) pour voir la carte suivante */
    scroll-snap-align: center;
    background: var(--bg-white);
    padding: 25px 20px; /* Marges internes légèrement affinées */
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.06);
    min-height: auto; 
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
  }

.step-label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 800;
  color: var(--eco-green);
  margin-bottom: 15px;
}

.story-step h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--eco-blue);
  margin-bottom: 25px;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.story-step p {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.story-step ul {
  list-style: none;
  margin-top: 15px;
}

.story-step ul li {
  font-size: 1.1rem;
  color: var(--text-main);
  margin-bottom: 15px;
  position: relative;
  padding-left: 25px;
}

.story-step ul li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--eco-green);
  font-weight: bold;
}

/* --- MOBILE --- */
@media (max-width: 992px) {
  .story-container { flex-direction: column; gap: 0; }
  
  .story-visuals {
    width: 100vw;
    margin-left: -24px; /* Casse le container pour prendre tout l'écran */
    height: 40vh;
    top: var(--nav-height);
    border-radius: 0;
    z-index: 10;
  }
  
  .story-content { padding-top: 40px; padding-bottom: 10vh; }
  .story-step { min-height: 70vh; padding: 20px 0; }
}

/* =========================================
   7. SECTION MARCHÉS (Bento Grid)
   ========================================= */
.markets-section {
  padding: 100px 0;
  background: var(--bg-white);
}

.section-header {
  margin-bottom: 60px;
}

.section-title {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  color: var(--text-main);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}

.section-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

.text-center { text-align: center; }

/* La Grille Bento */
.bento-markets {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.market-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-light);
  border-radius: 24px;
  padding: 40px;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid rgba(0,0,0,0.03);
}

/* L'effet Premium au survol */
.market-card:hover {
  transform: translateY(-8px);
  background: #ffffff;
  box-shadow: 0 20px 40px rgba(0, 70, 135, 0.08);
  border-color: rgba(0, 70, 135, 0.1);
}

.market-icon {
  width: 50px;
  height: 50px;
  background: rgba(0, 70, 135, 0.05);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 25px;
  color: var(--eco-blue);
  transition: transform 0.3s;
}

.market-icon svg { width: 24px; height: 24px; }

.market-card:hover .market-icon {
  transform: scale(1.1);
  background: var(--eco-blue);
  color: #fff;
}

.market-content h3 {
  font-size: 1.5rem;
  color: var(--text-main);
  margin-bottom: 15px;
  letter-spacing: -0.01em;
}

.market-content p {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 30px;
  flex-grow: 1; /* Pousse le lien vers le bas */
}

.btn-link {
  font-weight: 600;
  color: var(--eco-blue);
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  transition: color 0.2s;
}

.market-card:hover .btn-link {
  color: var(--eco-green);
}

/* --- MOBILE --- */
@media (max-width: 992px) {
  .bento-markets {
    grid-template-columns: 1fr; /* Une seule colonne sur mobile */
    gap: 20px;
  }
  .market-card { padding: 30px; }
}

/* =========================================
   8. SECTION SERVICES (Déploiement)
   ========================================= */
.services-section {
  padding: 100px 0;
  background: var(--bg-light); /* Fond gris clair pour casser avec le blanc du dessus */
}

.services-grid {
  display: grid;
  grid-template-columns: 1fr 1fr; /* 2 colonnes égales */
  gap: 40px;
}

.service-box {
  background: var(--bg-white);
  border-radius: 24px;
  padding: 50px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.04);
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(0,0,0,0.03);
  transition: transform 0.3s;
}

.service-box:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0, 70, 135, 0.08);
}

.service-box-header {
  margin-bottom: 30px;
  border-bottom: 2px solid var(--bg-light);
  padding-bottom: 20px;
}

.service-box-header h3 {
  font-size: 1.8rem;
  color: var(--text-main);
  margin-bottom: 5px;
  letter-spacing: -0.02em;
}

.service-box-header p {
  color: var(--text-muted);
  font-size: 1.05rem;
}

.service-options {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 40px;
}

.option-item h4 {
  font-size: 1.15rem;
  color: var(--text-main);
  margin-bottom: 8px;
}

.text-green { color: var(--eco-green); margin-right: 5px; }

.option-item p {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.5;
  padding-left: 24px; /* Aligné avec le texte, sous l'icône de validation */
}

.option-divider {
  text-align: center;
  position: relative;
  margin: 10px 0;
}

.option-divider::before {
  content: "";
  position: absolute;
  top: 50%; left: 0; right: 0;
  height: 1px;
  background: #eee;
  z-index: 1;
}

.option-divider span {
  position: relative;
  z-index: 2;
  background: var(--bg-white);
  padding: 0 15px;
  font-size: 0.8rem;
  font-weight: 800;
  color: #ccc;
  letter-spacing: 1px;
}

.btn-full {
  width: 100%;
  text-align: center;
}

/* --- MOBILE --- */
@media (max-width: 992px) {
  .services-grid { grid-template-columns: 1fr; }
  .service-box { padding: 30px; }
}

/* =========================================
   9. PARTENAIRES (Marquee / Défilement infini)
   ========================================= */
.partners-section {
  padding: 60px 0 80px;
  background: var(--bg-white);
  overflow: hidden;
}

.marquee-wrapper {
  display: flex;
  width: 100vw;
  overflow: hidden;
  position: relative;
  margin-top: 30px;
}

/* Fondu sur les bords du carrousel */
.marquee-wrapper::before, .marquee-wrapper::after {
  content: "";
  position: absolute;
  top: 0; width: 100px; height: 100%;
  z-index: 2;
}
.marquee-wrapper::before { left: 0; background: linear-gradient(to right, white, transparent); }
.marquee-wrapper::after { right: 0; background: linear-gradient(to left, white, transparent); }

.marquee-track {
  display: flex;
  align-items: center;
  gap: 60px;
  animation: marquee 30s linear infinite;
  white-space: nowrap;
}

.logo-item {
  font-size: 1.5rem;
  font-weight: 800;
  color: #d1d1d6; /* Gris clair neutre */
  text-transform: uppercase;
  letter-spacing: 1px;
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); } /* Doit défiler exactement de la moitié car contenu dupliqué */
}

/* =========================================
   10. CONFIGURATEUR D'IMPACT
   ========================================= */
.configurator-section {
  padding: 100px 0;
  background: var(--eco-blue);
  color: #fff;
}

.config-card {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  padding: 60px;
  max-width: 900px;
  margin: 0 auto;
}

.config-header h2 { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 15px; }
.config-header p { color: #ccc; font-size: 1.1rem; margin-bottom: 40px; }

/* Styling du Slider (Range Input) */
.eco-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 8px;
  border-radius: 4px;
  background: #e5e5e5;
  outline: none;
  margin: 20px 0;
}

.eco-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--eco-green);
  cursor: pointer;
  box-shadow: 0 0 15px rgba(46, 204, 113, 0.5);
  border: 4px solid #fff;
}

.slider-group { text-align: center; margin-bottom: 50px; }
.slider-group label { display: block; font-size: 1.2rem; font-weight: 600; margin-bottom: 15px; }
.slider-value { font-size: 1.1rem; color: #ccc; }
.slider-value span { font-size: 2rem; font-weight: 800; color: #fff; margin-right: 5px; }

.config-results { display: flex; justify-content: center; gap: 40px; }
.result-box { text-align: center; }
.result-number { font-size: 3.5rem; font-weight: 800; color: var(--eco-green); line-height: 1; }
.result-unit { font-size: 1.5rem; color: #fff; margin-left: 5px; }
.result-label { display: block; text-transform: uppercase; font-size: 0.8rem; letter-spacing: 1px; color: #ccc; margin-top: 10px; }

/* =========================================
   11. CONTACT
   ========================================= */
.contact-section { padding: 100px 0; background: var(--bg-light); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.contact-info h2 { font-size: clamp(2.5rem, 5vw, 3.5rem); color: var(--eco-blue); line-height: 1.1; margin-bottom: 20px; letter-spacing: -0.02em; }
.contact-info p { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 30px; }
.contact-list { list-style: none; }
.contact-list li { margin-bottom: 15px; color: var(--text-main); font-size: 1.05rem; }
.contact-list strong { color: var(--eco-blue); }

.eco-form { background: var(--bg-white); padding: 40px; border-radius: 20px; box-shadow: 0 15px 40px rgba(0,0,0,0.05); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: 0.9rem; font-weight: 600; margin-bottom: 8px; color: var(--text-main); }
.form-group input, .form-group textarea {
  width: 100%; padding: 15px; border: 1px solid #e5e5e5; border-radius: 8px; font-family: inherit; font-size: 1rem; transition: border-color 0.3s;
}
.form-group input:focus, .form-group textarea:focus { border-color: var(--eco-blue); outline: none; }

/* --- MOBILE --- */
@media (max-width: 992px) {
  .config-card { padding: 40px 20px; border-radius: 0; border-left: none; border-right: none; }
  .config-results { flex-direction: column; gap: 30px; }
  .contact-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .eco-form { padding: 30px 20px; }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 20px;
}

.header-social {
  display: flex;
  align-items: center;
  gap: 12px;
  border-right: 1px solid #e5e5e5;
  padding-right: 20px;
}

.header-social a {
  color: var(--text-muted);
  transition: all 0.2s ease;
  display: flex;
}

.header-social a svg {
  width: 20px;
  height: 20px;
}

.header-social a:hover {
  color: var(--eco-blue);
  transform: translateY(-2px);
}

/* =========================================
   12. PAGE TECHNOLOGIE / PRODUIT
   ========================================= */
.tech-hero {
  padding-bottom: 40px;
}

/* Espacement de la section (Règle le problème de la bordure collée en bas) */
.variants-section {
  padding-bottom: 100px;
}

/* Grille des Variantes */
.variants-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin-top: 50px;
}

.variant-card {
  background: var(--bg-white);
  /* Bordure neutre de 2px pour toutes les cartes (évite le saut d'épaisseur au survol) */
  border: 2px solid rgba(0,0,0,0.04);
  border-radius: 20px;
  padding: 40px 30px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.02);
  transition: all 0.3s ease; /* "all" permet d'animer aussi la couleur de la bordure */
  display: flex;
  flex-direction: column;
}

/* Au survol : la bordure devient verte et la carte se soulève (identique pour les 3) */
.variant-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 40px rgba(46, 204, 113, 0.12);
  border-color: var(--eco-green);
}

/* On neutralise l'ancien comportement "bizarre" de la carte centrale pour l'aligner parfaitement */
.featured-variant {
  /* On laisse cette classe vide, elle hérite du style parfait de .variant-card */
}

.variant-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-bottom: 20px;
  border-bottom: 1px solid #eee;
  padding-bottom: 20px;
}

.variant-header h3 {
  font-size: 1.6rem;
  color: var(--eco-blue);
  margin-bottom: 10px;
}

.badge-variant {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 800;
  background: var(--bg-light);
  color: var(--text-muted);
  padding: 5px 12px;
  border-radius: 50px;
}
.badge-variant.highlight { background: rgba(46, 204, 113, 0.1); color: var(--eco-green); }

.variant-desc {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 25px;
  line-height: 1.6;
  flex-grow: 1;
}

.variant-specs { list-style: none; padding: 0; }
.variant-specs li {
  font-size: 0.95rem;
  margin-bottom: 10px;
  padding-left: 20px;
  position: relative;
  color: var(--text-main);
}
.variant-specs li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--eco-green);
  font-weight: bold;
}

/* Grille d'Installation (4 étapes) */
.install-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

.install-step { text-align: center; }

.install-img-wrapper {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 20px;
  box-shadow: 0 10px 20px rgba(0,0,0,0.05);
  aspect-ratio: 4/3; /* Force un format uniforme pour les photos */
}

.install-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.install-step:hover .install-img-wrapper img { transform: scale(1.05); }

.step-number {
  position: absolute;
  top: 15px; left: 15px;
  width: 35px; height: 35px;
  background: var(--eco-blue);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center; justify-content: center;
  font-weight: 800; font-size: 1.2rem;
  box-shadow: 0 4px 10px rgba(0, 70, 135, 0.3);
}

.install-step h4 { font-size: 1.2rem; color: var(--text-main); margin-bottom: 10px; }
.install-step p { font-size: 0.95rem; color: var(--text-muted); line-height: 1.5; }

/* --- MOBILE --- */
@media (max-width: 992px) {
  .variants-grid { grid-template-columns: 1fr; }
  
  .install-grid { grid-template-columns: 1fr 1fr; gap: 20px; } /* 2 colonnes sur tablette */
}

@media (max-width: 600px) {
  .install-grid { grid-template-columns: 1fr; } /* 1 colonne sur smartphone */
}

/* =========================================
   13. PAGE CONTACT & REVENDEURS
   ========================================= */

/* Carte Google Maps */
.map-wrapper {
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08);
  border: 4px solid var(--bg-white);
}

/* Section Revendeurs */
.resellers-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin-top: 40px;
}

.reseller-card {
  background: var(--bg-white);
  border-radius: 16px;
  padding: 35px 30px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(0,0,0,0.04);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.reseller-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0, 70, 135, 0.08);
}

.reseller-card h3 {
  font-size: 1.4rem;
  color: var(--text-main);
  margin-bottom: 5px;
}

.reseller-company {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--eco-blue);
  display: block;
  margin-bottom: 10px;
}

.reseller-region {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 25px;
  flex-grow: 1; /* Pousse les contacts vers le bas */
}

.reseller-region strong {
  color: var(--text-main);
}

.reseller-contact {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-top: 1px solid #eee;
  padding-top: 20px;
}

.reseller-email, .reseller-phone {
  font-size: 1rem;
  font-weight: 600;
  color: var(--eco-green);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(46, 204, 113, 0.3);
  transition: all 0.2s ease;
}

.reseller-email:hover, .reseller-phone:hover {
  color: var(--eco-blue);
  text-decoration-color: var(--eco-blue);
}

/* --- MOBILE --- */
@media (max-width: 992px) {
  .resellers-grid {
    grid-template-columns: 1fr;
  }
}

.justify-center {
  justify-content: center;
}

@media (max-width: 992px) {
  .layout-50-50 {
    flex-direction: column;
  }
}

/* =========================================
   HOMEPAGE : STORYTELLING (Correction Finale)
   ========================================= */

/* --- RESET SECURITÉ --- */
.mobile-story-img { display: none; }

/* -----------------------------------------
   A. VERSION PC (Écrans > 992px)
   ----------------------------------------- */
@media (min-width: 993px) {
  .story-tunnel { background: var(--bg-light); padding: 100px 0; }
  
  .story-container { 
    display: flex !important; 
    gap: 80px !important; 
    align-items: flex-start !important; 
    max-width: 1200px;
    margin: 0 auto;
  }

  .story-visuals {
    display: block !important;
    flex: 1 !important; 
    position: sticky !important; 
    top: 120px !important; 
    height: 60vh !important;
    border-radius: 24px; 
    overflow: hidden; 
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
  }

  .story-img {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover;
    opacity: 0; transition: opacity 0.6s ease-in-out;
  }
  .story-img.active { opacity: 1; z-index: 2; }

  .story-content-wrapper { flex: 1 !important; }
  
  .story-content { 
    display: block !important; 
    padding-bottom: 20vh !important; 
  }

  .story-step {
    min-height: 70vh !important; 
    display: flex !important; 
    flex-direction: column !important; 
    justify-content: center !important;
    background: transparent !important; 
    box-shadow: none !important; 
    padding: 0 !important;
  }
}

/* -----------------------------------------
   B. VERSION MOBILE (Écrans <= 992px)
   ----------------------------------------- */
@media (max-width: 992px) {
  .story-tunnel { padding: 50px 0 !important; overflow: hidden; }
  .story-container { padding: 0 !important; width: 100% !important; max-width: 100% !important; }
  .story-visuals { display: none !important; }

  .story-content-wrapper { position: relative; width: 100%; }

  .story-content {
    display: flex !important;
    overflow-x: auto !important;
    scroll-snap-type: x mandatory !important;
    gap: 0px !important; /* On colle les cartes */
    padding: 0 !important;
    scrollbar-width: none;
    overscroll-behavior-x: contain;
  }
  .story-content::-webkit-scrollbar { display: none; }

  .story-step {
    flex: 0 0 100% !important; /* Largeur totale */
    scroll-snap-align: center;
    padding: 30px 25px !important;
    background: var(--bg-white) !important;
    box-sizing: border-box;
    min-height: auto !important;
  }

  .mobile-story-img {
    display: block !important;
    width: 100%; height: 220px; object-fit: cover;
    border-radius: 16px; margin-bottom: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
  }

  /* FLÈCHES AVEC ICÔNES FORCÉES */
  .carousel-arrows {
    display: flex !important;
    justify-content: space-between !important;
    position: absolute !important;
    top: 50%; width: 100%; left: 0;
    padding: 0 10px;
    pointer-events: none; z-index: 100;
    box-sizing: border-box;
  }

  .carousel-arrow {
    pointer-events: auto;
    background: var(--eco-blue) !important;
    border: none; border-radius: 50%;
    width: 46px; height: 46px;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  }

  .carousel-arrow svg {
    width: 24px !important;
    height: 24px !important;
    stroke: #ffffff !important; /* Force la couleur blanche de l'icône */
    display: block !important;
  }
}

/* Taille du logo footer sur PC */
.footer-logo-img {
  height: 90px; /* Plus gros que la version précédente */
  width: auto;
  display: block;
}

/* Taille du logo footer sur Mobile */
@media (max-width: 992px) {
  .footer-logo-img {
    height: 80px; /* Équilibré pour smartphone */
  }
  
  .footer-brand {
    margin-bottom: 40px; /* Espace supplémentaire entre le logo et les colonnes suivantes */
  }
}

/* BANDEAU COOKIES */
.cookie-notice {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: var(--bg-white);
  box-shadow: 0 -10px 30px rgba(0,0,0,0.1);
  padding: 20px 0;
  z-index: 10000;
  border-top: 2px solid var(--eco-green);
  animation: slideUp 0.5s ease-out;
}

.cookie-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

.cookie-content p {
  font-size: 0.9rem;
  color: var(--text-main);
  margin: 0;
  line-height: 1.5;
}

.cookie-content a {
  color: var(--eco-blue);
  text-decoration: underline;
  font-weight: 600;
}

.cookie-actions {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-shrink: 0;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

/* Version Mobile */
@media (max-width: 768px) {
  .cookie-flex {
    flex-direction: column;
    text-align: center;
    gap: 20px;
  }
  .cookie-actions {
    width: 100%;
    justify-content: center;
    flex-direction: column;
    gap: 15px;
  }
}
