/* =================================================================
   AD Énergies — Design System
   Courtage Gaz & Électricité
   ================================================================= */

:root {
  --primary: #1B3A6B;
  --primary-dark: #0F2548;
  --primary-light: #2D5A9A;
  --accent: #FF8A00;
  --accent-dark: #E67700;
  --accent-light: #FFB347;
  --gold: #FFC72C;
  --yellow: #FFE066;
  --green: #7CC04A;
  --green-dark: #5BA82F;
  --leaf: #8FD14F;
  --gaz-blue: #4A90E2;
  --bg: #FAFBFD;
  --surface: #FFFFFF;
  --ink: #0F1B2E;
  --muted: #5A6378;
  --soft: #EEF3FA;
  --line: #DCE3ED;
  --success: #10B981;
  --success-light: #D1FAE5;
  --error: #EF4444;
  --shadow-sm: 0 2px 4px rgba(27,58,107,0.05);
  --shadow-md: 0 8px 20px rgba(27,58,107,0.1);
  --shadow-lg: 0 20px 50px rgba(27,58,107,0.15);
  --shadow-xl: 0 30px 70px rgba(27,58,107,0.2);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  animation: pageFadeIn 0.5s ease-out;
}
@keyframes pageFadeIn { from { opacity: 0; } to { opacity: 1; } }

h1, h2, h3, h4 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: var(--primary);
}
a { color: inherit; }
.container { max-width: 1240px; margin: 0 auto; padding: 0 24px; }

::selection { background: var(--accent); color: white; }
::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-track { background: var(--soft); }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--accent), var(--gold));
  border-radius: 6px;
  border: 3px solid var(--soft);
}

*:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

/* ============ ICÔNES 3D ============ */
.icon-3d {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  border-radius: 22px;
  color: white;
  flex-shrink: 0;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.icon-3d::after {
  content: '';
  position: absolute;
  top: 8%; left: 12%; right: 12%;
  height: 35%;
  background: linear-gradient(180deg, rgba(255,255,255,0.5) 0%, rgba(255,255,255,0) 100%);
  border-radius: 50% / 100%;
  pointer-events: none;
}
.icon-3d svg { position: relative; z-index: 1; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.15)); }
.icon-3d-yellow {
  background: linear-gradient(145deg, #FFE066 0%, #FFC72C 60%, #FFA800 100%);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.7), inset 0 -3px 0 rgba(0,0,0,0.1), 0 10px 25px rgba(255,199,44,0.5);
}
.icon-3d-orange {
  background: linear-gradient(145deg, #FFB347 0%, #FF8A00 60%, #E67000 100%);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.6), inset 0 -3px 0 rgba(0,0,0,0.15), 0 10px 25px rgba(255,138,0,0.5);
}
.icon-3d-blue {
  background: linear-gradient(145deg, #4A90E2 0%, #1B3A6B 60%, #0F2548 100%);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.4), inset 0 -3px 0 rgba(0,0,0,0.2), 0 10px 25px rgba(27,58,107,0.5);
}
.icon-3d-green {
  background: linear-gradient(145deg, #8FD14F 0%, #7CC04A 60%, #5BA82F 100%);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.5), inset 0 -3px 0 rgba(0,0,0,0.15), 0 10px 25px rgba(124,192,74,0.5);
}
.icon-3d-purple {
  background: linear-gradient(145deg, #A78BFA 0%, #8B5CF6 60%, #7C3AED 100%);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.4), inset 0 -3px 0 rgba(0,0,0,0.15), 0 10px 25px rgba(139,92,246,0.5);
}
.icon-3d-teal {
  background: linear-gradient(145deg, #5EEAD4 0%, #14B8A6 60%, #0F766E 100%);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.4), inset 0 -3px 0 rgba(0,0,0,0.15), 0 10px 25px rgba(20,184,166,0.5);
}
.icon-3d:hover { transform: translateY(-4px) rotate(-3deg) scale(1.05); }
.icon-3d-sm { width: 56px; height: 56px; border-radius: 16px; }
.icon-3d-sm svg { width: 24px; height: 24px; }
.icon-3d-lg { width: 110px; height: 110px; border-radius: 28px; }
.icon-3d-lg svg { width: 50px; height: 50px; }

/* ============ HEADER ============ */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid rgba(220,227,237,0.5);
  z-index: 100;
  transition: all 0.3s;
}
header.scrolled { box-shadow: var(--shadow-sm); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--primary); }
.logo-img {
  height: 52px;
  width: auto;
  transition: transform 0.3s;
}
.logo:hover .logo-img { transform: scale(1.05); }
.nav-links { display: none; gap: 32px; list-style: none; }
@media (min-width: 1024px) { .nav-links { display: flex; } }
.nav-links a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  position: relative;
  transition: color 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: var(--accent); }
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 2px;
  background: var(--accent);
  transition: width 0.3s;
}
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-cta { display: none; align-items: center; gap: 14px; }
@media (min-width: 768px) { .nav-cta { display: flex; } }
.phone-link {
  color: var(--primary);
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s;
}
.phone-link:hover { color: var(--accent); }

/* ============ BUTTONS ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 12px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}
.btn-primary {
  background: linear-gradient(135deg, #FF8A00 0%, #FFC72C 100%);
  color: white;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), inset 0 -2px 0 rgba(0,0,0,0.1), 0 8px 20px rgba(255,138,0,0.4);
}
.btn-primary::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.35), transparent);
  transition: left 0.6s;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), inset 0 -2px 0 rgba(0,0,0,0.1), 0 12px 28px rgba(255,138,0,0.55);
}
.btn-primary:hover::before { left: 100%; }
.btn-secondary {
  background: white;
  color: var(--primary);
  border: 2px solid var(--line);
}
.btn-secondary:hover { border-color: var(--primary); background: var(--soft); transform: translateY(-2px); }
.btn-large { padding: 18px 36px; font-size: 16px; }
.btn-xl { padding: 22px 44px; font-size: 17px; border-radius: 14px; }
.btn-block { width: 100%; }
.btn:active { transform: translateY(0) scale(0.98); transition-duration: 0.1s; }
button:disabled, .btn:disabled { opacity: 0.7; cursor: not-allowed; pointer-events: none; }

.btn-pulse { animation: pulse-shadow 2s ease-in-out infinite; }
@keyframes pulse-shadow {
  0%, 100% { box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), inset 0 -2px 0 rgba(0,0,0,0.1), 0 8px 20px rgba(255,138,0,0.4); }
  50% { box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), inset 0 -2px 0 rgba(0,0,0,0.1), 0 8px 28px rgba(255,138,0,0.7), 0 0 0 8px rgba(255,138,0,0.1); }
}

/* ============ FLOATING WA & STICKY MOBILE ============ */
.float-wa {
  position: fixed;
  bottom: 90px; right: 20px;
  width: 64px; height: 64px;
  background: linear-gradient(145deg, #34D399 0%, #25D366 60%, #128C7E 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  text-decoration: none;
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.4), inset 0 -3px 0 rgba(0,0,0,0.15), 0 10px 25px rgba(37,211,102,0.5);
  z-index: 80;
  animation: wa-pulse 2.5s ease-in-out infinite;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@media (max-width: 768px) { .float-wa { display: none; } }
.float-wa:hover { transform: scale(1.1) rotate(-5deg); }
@keyframes wa-pulse {
  0%, 100% { box-shadow: inset 0 2px 0 rgba(255,255,255,0.4), inset 0 -3px 0 rgba(0,0,0,0.15), 0 10px 25px rgba(37,211,102,0.5), 0 0 0 0 rgba(37,211,102,0.7); }
  50% { box-shadow: inset 0 2px 0 rgba(255,255,255,0.4), inset 0 -3px 0 rgba(0,0,0,0.15), 0 10px 25px rgba(37,211,102,0.5), 0 0 0 14px rgba(37,211,102,0); }
}

.sticky-mobile-cta {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: white;
  border-top: 1px solid var(--line);
  padding: 12px 16px;
  display: none;
  gap: 8px;
  z-index: 90;
  box-shadow: 0 -8px 24px rgba(0,0,0,0.1);
}
@media (max-width: 768px) {
  .sticky-mobile-cta { display: flex; }
  body { padding-bottom: 76px; }
}
.sticky-mobile-cta a {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  color: white;
  transition: transform 0.2s;
}
.sticky-mobile-cta a:active { transform: scale(0.96); }
.sticky-form { background: linear-gradient(145deg, #FFB347 0%, #FF8A00 60%, #E67000 100%); }
.sticky-call { background: linear-gradient(145deg, #4A90E2 0%, #1B3A6B 60%, #0F2548 100%); }
.sticky-wa { background: linear-gradient(145deg, #34D399 0%, #25D366 60%, #128C7E 100%); }

/* ============ SECTIONS ============ */
section { padding: 80px 0; }
@media (min-width: 1024px) { section { padding: 100px 0; } }
.section-header { text-align: center; max-width: 720px; margin: 0 auto 60px; }
.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--soft);
  color: var(--accent);
  padding: 8px 16px;
  border-radius: 100px;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.section-eyebrow .dot {
  width: 6px; height: 6px;
  background: var(--accent);
  border-radius: 50%;
  animation: dot-pulse 1.5s ease-in-out infinite;
}
@keyframes dot-pulse { 0%, 100% { opacity: 0.4; transform: scale(1); } 50% { opacity: 1; transform: scale(1.5); } }
.section-header h2 { font-size: clamp(32px, 4.5vw, 48px); margin-bottom: 16px; }
.section-header p { color: var(--muted); font-size: 18px; line-height: 1.6; }

/* ============ MOBILE MENU ============ */
.menu-btn { display: flex; background: none; border: none; cursor: pointer; padding: 8px; color: var(--primary); }
@media (min-width: 1024px) { .menu-btn { display: none; } }
.mobile-menu {
  position: fixed;
  inset: 0;
  background: white;
  z-index: 200;
  padding: 24px;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.4,0,0.2,1);
}
.mobile-menu.open { transform: translateX(0); }
.mobile-menu-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 40px; }
.mobile-menu nav ul { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.mobile-menu nav a {
  display: block; padding: 16px; border-radius: 12px;
  color: var(--primary); text-decoration: none;
  font-weight: 700; font-size: 18px;
  transition: background 0.2s;
}
.mobile-menu nav a:hover { background: var(--soft); }

/* ============ FOOTER ============ */
footer {
  background: var(--primary-dark);
  color: rgba(255,255,255,0.7);
  padding: 60px 0 24px;
  position: relative;
  overflow: hidden;
}
footer::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--gold), var(--green), var(--primary-light));
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
@media (min-width: 768px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.footer-brand .logo { margin-bottom: 16px; }
.footer-brand .logo-img { filter: brightness(0) invert(1); height: 48px; }
.footer-brand p { font-size: 14px; line-height: 1.65; max-width: 320px; margin-bottom: 16px; }
.footer-brand .phone-link { color: white; }
.footer-brand .phone-link:hover { color: var(--accent); }
footer h4 { color: white; font-size: 14px; margin-bottom: 20px; text-transform: uppercase; letter-spacing: 0.08em; }
footer ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
footer ul a { color: rgba(255,255,255,0.7); text-decoration: none; font-size: 14px; transition: color 0.2s; }
footer ul a:hover { color: var(--accent); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
}
.footer-bottom a { color: rgba(255,255,255,0.5); text-decoration: none; }
.footer-bottom a:hover { color: white; }

/* ============ REVEAL ANIMATIONS ============ */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.4,0,0.2,1), transform 0.8s cubic-bezier(0.4,0,0.2,1);
}
.reveal.visible { opacity: 1; transform: none; }
.reveal-scale {
  opacity: 0;
  transform: scale(0.92);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.reveal-scale.visible { opacity: 1; transform: scale(1); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

/* ============ FORMS ============ */
.form-input, .form-select, .form-textarea {
  padding: 14px 16px;
  border: 2px solid var(--line);
  border-radius: 12px;
  font-family: inherit;
  font-size: 15px;
  background: white;
  color: var(--ink);
  transition: all 0.25s;
  width: 100%;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(255,138,0,0.12);
}
.form-textarea { resize: vertical; min-height: 100px; }
.form-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.form-label .required { color: var(--accent); }

/* ============ PAGE HERO ============ */
.page-hero {
  padding: 140px 0 60px;
  background: linear-gradient(135deg, #1B3A6B 0%, #0F2548 100%);
  color: white;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(255,138,0,0.2) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(124,192,74,0.15) 0%, transparent 50%);
}
.page-hero-inner { position: relative; z-index: 1; }
.page-hero .breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(255,255,255,0.6);
  font-size: 13px;
  margin-bottom: 16px;
}
.page-hero .breadcrumb a { color: rgba(255,255,255,0.6); text-decoration: none; }
.page-hero .breadcrumb a:hover { color: white; }
.page-hero h1 { color: white; font-size: clamp(36px, 5vw, 56px); margin-bottom: 16px; }
.page-hero h1 .highlight {
  background: linear-gradient(120deg, #FF8A00 0%, #FFC72C 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.page-hero p { color: rgba(255,255,255,0.85); font-size: 18px; max-width: 640px; margin: 0 auto; }

@keyframes spin { to { transform: rotate(360deg); } }

/* ============ SPECIFIC: AD ENERGIE PILLARS ============ */
.pillars-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
@media (min-width: 768px) { .pillars-grid { grid-template-columns: repeat(3, 1fr); } }
.pillar-card {
  background: white;
  border-radius: 24px;
  padding: 36px 28px;
  border: 2px solid var(--line);
  transition: all 0.4s cubic-bezier(0.4,0,0.2,1);
  position: relative;
  overflow: hidden;
}
.pillar-card:hover {
  transform: translateY(-10px);
  border-color: var(--accent);
  box-shadow: var(--shadow-xl);
}
.pillar-card .icon-3d { margin-bottom: 20px; }
.pillar-card h3 { font-size: 22px; margin-bottom: 12px; }
.pillar-card > p { color: var(--muted); font-size: 15px; margin-bottom: 20px; }
.pillar-card ul { list-style: none; padding: 0; margin: 0 0 16px 0; }
.pillar-card ul li {
  position: relative;
  padding-left: 28px;
  margin-bottom: 8px;
  font-size: 14px;
  color: var(--ink);
  font-weight: 500;
}
.pillar-card ul li::before {
  content: '';
  position: absolute;
  left: 0; top: 6px;
  width: 16px; height: 16px;
  background: linear-gradient(145deg, #FFE066, #FFC72C, #FFA800);
  border-radius: 5px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.6), 0 2px 4px rgba(255,199,44,0.4);
}
.pillar-card ul li::after {
  content: '✓';
  position: absolute;
  left: 1.5px; top: 2.5px;
  font-size: 11px;
  color: white;
  font-weight: 800;
  width: 16px;
  text-align: center;
}

/* ============ PROCESS STEPS ============ */
.process-section { background: linear-gradient(135deg, #FFF8E7 0%, #FFE7CC 100%); position: relative; overflow: hidden; }
.process-steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  position: relative;
}
@media (min-width: 768px) { .process-steps { grid-template-columns: repeat(4, 1fr); gap: 16px; } }
.process-step {
  background: white;
  border-radius: 20px;
  padding: 24px 20px;
  text-align: center;
  border: 2px solid white;
  box-shadow: var(--shadow-md);
  position: relative;
  transition: transform 0.3s;
}
.process-step:hover { transform: translateY(-6px); }
.process-step-num {
  width: 44px; height: 44px;
  background: linear-gradient(145deg, #FFB347 0%, #FF8A00 60%, #E67000 100%);
  color: white;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  font-size: 20px;
  margin: 0 auto 16px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), inset 0 -2px 0 rgba(0,0,0,0.15), 0 6px 14px rgba(255,138,0,0.4);
  position: relative;
}
.process-step h4 { font-size: 16px; margin-bottom: 8px; }
.process-step p { color: var(--muted); font-size: 13px; line-height: 1.5; }

/* ============ LOGO SPECIFIC ============ */
.logo-text {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.02em;
  display: none;
}

/* ================================================================
   📱 OPTIMISATIONS MOBILE — Ajoutées pour smartphones & tablettes
   ================================================================ */

/* --- 1. CORRECTION ZOOM iOS sur formulaires --- */
/* iOS zoome automatiquement sur les inputs avec font-size < 16px.
   On force 16px en mobile pour éviter ce comportement gênant. */
@media (max-width: 768px) {
  .form-input, .form-select, .form-textarea,
  input[type="text"], input[type="email"], input[type="tel"],
  input[type="number"], input[type="url"], input[type="search"],
  input[type="password"], select, textarea {
    font-size: 16px !important;
  }
}

/* --- 2. SAFE AREA pour iPhones avec encoche (X et plus récents) --- */
body {
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
}
.sticky-mobile-cta {
  padding-bottom: max(12px, env(safe-area-inset-bottom));
}
#header {
  padding-top: env(safe-area-inset-top);
}

/* --- 3. LOGO RESPONSIVE (taille adaptée à chaque écran) --- */
@media (max-width: 768px) {
  .logo-img { height: 40px; }
  .footer-brand .logo-img { height: 40px; }
}
@media (max-width: 380px) {
  .logo-img { height: 34px; }
}

/* --- 4. HEADER mobile compact --- */
@media (max-width: 768px) {
  #header { padding: 10px 0; }
  #header.scrolled { padding: 8px 0; }
  .nav { gap: 8px; }
  .nav-cta .phone-link span,
  .nav-cta .phone-link {
    font-size: 13px;
  }
  /* Cache le numéro affiché sur très petits écrans, garde l'icône cliquable */
  .nav-cta { display: none; }
}
@media (max-width: 768px) {
  .menu-btn {
    width: 44px; height: 44px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 10px;
  }
  .menu-btn:active { background: rgba(255,138,0,0.1); }
}

/* --- 5. HERO mobile : padding et tailles ajustés --- */
@media (max-width: 768px) {
  .hero {
    padding: 100px 0 60px !important;
    min-height: auto;
  }
  .hero h1 {
    font-size: clamp(28px, 7vw, 40px) !important;
    line-height: 1.1 !important;
    margin-bottom: 16px;
  }
  .hero-subtitle {
    font-size: 15px !important;
    line-height: 1.55;
  }
  .hero-eyebrow {
    font-size: 11px !important;
    padding: 6px 12px;
  }
  .hero-grid {
    gap: 32px !important;
  }
  .hero-ctas {
    flex-direction: column;
    gap: 10px;
    width: 100%;
  }
  .hero-ctas .btn { width: 100%; justify-content: center; }
  .hero-trust {
    flex-wrap: wrap;
    gap: 8px;
  }
  .hero-trust-item { font-size: 13px; }
}

/* --- 6. PAGE HERO (pages secondaires) --- */
@media (max-width: 768px) {
  .page-hero { padding: 100px 0 50px !important; }
  .page-hero h1 {
    font-size: clamp(28px, 7vw, 38px) !important;
    line-height: 1.15;
  }
  .page-hero p { font-size: 15px; }
}

/* --- 7. SECTIONS : padding mobile réduit --- */
@media (max-width: 768px) {
  section { padding: 60px 0 !important; }
  .container { padding: 0 20px; }
  .section-header h2 {
    font-size: clamp(26px, 6vw, 34px) !important;
    line-height: 1.15;
  }
  .section-header p { font-size: 15px !important; }
  .section-eyebrow { font-size: 11px; }
}

/* --- 8. BOUTONS : touch targets >= 44px (norme accessibilité) --- */
@media (max-width: 768px) {
  .btn {
    min-height: 48px;
    padding: 14px 24px;
    font-size: 15px;
  }
  .btn-large {
    min-height: 52px;
    padding: 16px 28px;
    font-size: 15px;
  }
  .btn-xl {
    min-height: 56px;
    padding: 18px 28px;
    font-size: 16px;
  }
  /* Pleine largeur par défaut sur mobile pour faciliter le tap */
  .hero-ctas .btn, .thanks-actions .btn {
    width: 100%;
  }
}

/* --- 9. STICKY MOBILE CTA : encore plus visible --- */
@media (max-width: 1023px) {
  .sticky-mobile-cta {
    display: grid !important;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    padding: 10px 12px;
    background: white;
    border-top: 1px solid #DCE3ED;
    box-shadow: 0 -8px 20px rgba(0,0,0,0.08);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
  }
  .sticky-mobile-cta a {
    min-height: 46px;
    font-size: 13px;
    font-weight: 700;
    border-radius: 10px;
  }
  /* Espace en bas pour ne pas masquer le contenu */
  body { padding-bottom: 80px; }
  footer { padding-bottom: 90px !important; }
}
@media (min-width: 1024px) {
  .sticky-mobile-cta { display: none !important; }
  body { padding-bottom: 0; }
}

/* --- 10. FORMULAIRES mobile : meilleur espacement --- */
@media (max-width: 768px) {
  .form-shell, .form-shell-contact {
    padding: 24px 16px !important;
    border-radius: 16px !important;
  }
  .form-row.cols-2, .form-row.cols-3 {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }
  .form-input, .form-select, .form-textarea {
    padding: 14px 14px;
    border-radius: 10px;
  }
  .form-label { font-size: 13px; }
  .form-step-title h3 { font-size: 18px !important; }
  .form-step-sub {
    margin-left: 0 !important;
    font-size: 14px;
  }
  .form-step-title { gap: 10px; }
  .form-progress-step span:last-child {
    display: none;
  }
  .form-progress-step.active span:last-child {
    display: inline;
  }
}

/* --- 11. UPLOAD ZONES mobile : empilées en plus grand --- */
@media (max-width: 640px) {
  .upload-grid {
    grid-template-columns: 1fr !important;
    gap: 10px;
  }
  .upload-zone {
    min-height: 100px !important;
    flex-direction: row !important;
    text-align: left !important;
    padding: 14px 16px !important;
    gap: 12px;
    align-items: center;
  }
  .upload-zone .upload-zone-icon { margin: 0 !important; }
  .upload-zone-title,
  .upload-zone-hint,
  .upload-zone-filename {
    flex: 1;
  }
}

/* --- 12. CONTACT CARDS : grille 2 colonnes au lieu de 4 --- */
@media (max-width: 768px) {
  .contact-cards-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 12px;
  }
  .contact-card-direct {
    padding: 18px 12px !important;
  }
  .contact-card-direct strong { font-size: 14px !important; }
  .contact-card-direct span { font-size: 12px !important; }
  .contact-card-value { font-size: 13px !important; }
}
@media (max-width: 400px) {
  .contact-cards-grid {
    grid-template-columns: 1fr !important;
  }
}

/* --- 13. ANIMATION FACTURES (5 scènes) mobile --- */
@media (max-width: 768px) {
  .video-wrapper {
    padding: 32px 16px !important;
    border-radius: 16px !important;
  }
  .video-stage { height: 480px !important; }
  .scene h3 { font-size: 22px !important; line-height: 1.2; }
  .scene p { font-size: 13px !important; padding: 0 12px; }
  .bills-floating { gap: 10px !important; }
  .bill-doc { width: 70px !important; height: 95px !important; }
  .analyzer { width: 110px !important; height: 110px !important; }
  .partners-network { width: 260px !important; height: 180px !important; }
  .partner-dot { width: 36px !important; height: 36px !important; font-size: 9px !important; }
  .partner-dot.center { width: 56px !important; height: 56px !important; font-size: 11px !important; }
  .best-offer-card { width: 240px !important; padding: 18px !important; }
  .best-offer-card .price { font-size: 26px !important; }
}

/* --- 14. PILLARS GRID mobile : empilées --- */
@media (max-width: 768px) {
  .pillars-grid {
    grid-template-columns: 1fr !important;
    gap: 16px;
  }
  .pillar-card {
    padding: 24px 20px !important;
  }
  .pillar-card h3 { font-size: 19px; }
}

/* --- 15. PAGES LÉGALES (CGV, mentions, RGPD) mobile --- */
@media (max-width: 1023px) {
  .legal-wrapper { grid-template-columns: 1fr !important; gap: 24px !important; }
  .legal-toc {
    position: relative !important;
    background: #FAFBFD;
    padding: 16px;
    border-radius: 12px;
    border: 1.5px solid #DCE3ED;
  }
  .legal-toc-title { margin-bottom: 10px; }
  .legal-toc ul {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
  }
  .legal-toc a {
    padding: 8px 10px !important;
    font-size: 12px !important;
  }
}
@media (max-width: 640px) {
  .legal-toc ul { grid-template-columns: 1fr; }
  .legal-block h2 {
    font-size: 20px !important;
    flex-wrap: wrap;
    gap: 10px;
  }
  .legal-block h2 .num {
    width: 32px !important;
    height: 32px !important;
    font-size: 14px !important;
  }
  .legal-block h3 { font-size: 16px !important; }
  .legal-block p, .legal-block ul li { font-size: 14px !important; }
  .info-card-grid { grid-template-columns: 1fr !important; gap: 10px; }
  .rights-grid { grid-template-columns: 1fr !important; }
}

/* --- 16. FOOTER mobile : empilé proprement --- */
@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 28px !important;
    text-align: left;
  }
  .footer-brand p { max-width: 100% !important; }
  .footer-bottom {
    flex-direction: column !important;
    gap: 14px;
    text-align: center;
    padding-bottom: 100px;
  }
  .footer-bottom > div { justify-content: center; flex-wrap: wrap; }
}

/* --- 17. MOBILE MENU plein écran amélioré --- */
@media (max-width: 1023px) {
  .mobile-menu {
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
  }
  .mobile-menu nav ul li a {
    padding: 16px 20px;
    font-size: 18px;
    display: block;
    border-radius: 12px;
    transition: background 0.2s;
  }
  .mobile-menu nav ul li a:active {
    background: rgba(255,138,0,0.1);
  }
}

/* --- 18. HORAIRES mobile (page contact) --- */
@media (max-width: 768px) {
  .hours-card { padding: 24px 18px !important; }
  .hours-row { padding: 8px 12px !important; font-size: 14px !important; }
}

/* --- 19. PAGE MERCI mobile --- */
@media (max-width: 768px) {
  .thanks-section { padding: 90px 16px 100px !important; }
  .thanks-card {
    padding: 32px 20px !important;
    border-radius: 24px !important;
  }
  .thanks-icon {
    width: 90px !important;
    height: 90px !important;
    border-radius: 28px !important;
  }
  .thanks-icon svg { width: 42px !important; height: 42px !important; }
  .thanks-card h1 { font-size: clamp(26px, 7vw, 36px) !important; }
  .thanks-card .lead { font-size: 15px !important; }
  .thanks-steps { gap: 10px !important; }
  .thanks-step { padding: 14px 12px !important; }
  .thanks-actions { flex-direction: column !important; gap: 10px !important; }
  .thanks-actions .btn { width: 100%; }
}

/* --- 20. PERFORMANCE : désactive animations lourdes sur mobile --- */
@media (max-width: 768px) {
  /* Réduit la profondeur des box-shadows lourdes */
  .icon-3d {
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,0.4),
      inset 0 -2px 0 rgba(0,0,0,0.12),
      0 4px 8px rgba(0,0,0,0.1) !important;
  }
  /* Désactive les transformations 3D inutiles (hover sans souris) */
  .icon-3d:hover {
    transform: none !important;
  }
  /* Simplifie les parallax */
  .hero-illustration {
    transform: none !important;
  }
  /* Désactive le tilt 3D sur mobile (pas de souris) */
  .pillar-card:hover, .why-card:hover, .step-card:hover {
    transform: translateY(-2px) !important;
  }
}

/* --- 21. ICÔNES TACTILES : pas de hover sur écrans tactiles --- */
@media (hover: none) and (pointer: coarse) {
  /* Désactive tous les effets de hover sur écrans tactiles */
  .icon-3d:hover { transform: none !important; }
  .btn:hover { transform: none !important; }
  *:hover { transition-duration: 0s !important; }
}

/* --- 22. AMÉLIORATION TAP DELAY (iOS / Android) --- */
a, button, input, select, textarea {
  -webkit-tap-highlight-color: rgba(255,138,0,0.15);
  touch-action: manipulation;
}

/* --- 23. SCROLLBAR cachée sur mobile (gain de place) --- */
@media (max-width: 768px) {
  ::-webkit-scrollbar { width: 0; height: 0; }
}

/* --- 24. ORIENTATION PAYSAGE sur petits écrans --- */
@media (max-width: 900px) and (orientation: landscape) {
  .hero, .page-hero {
    padding: 80px 0 40px !important;
  }
  .thanks-section { min-height: auto !important; padding: 80px 16px !important; }
}

/* --- 25. CHARGEMENT D'IMAGES différé en standard --- */
img { content-visibility: auto; }

/* ================================================================
   🌙 MODE SOMBRE — Activation automatique selon les préférences OS
   ================================================================
   Sur iOS : Réglages → Affichage → Sombre
   Sur Android : Paramètres → Affichage → Thème sombre
   Sur Mac/Windows : préférences système d'apparence
   ================================================================ */

@media (prefers-color-scheme: dark) {
  /* Variables de couleur en mode sombre */
  :root {
    --primary: #4A7AC7;       /* Bleu plus clair pour bon contraste */
    --primary-dark: #1B3A6B;
    --primary-deep: #0A1628;
    --accent: #FF9E2C;        /* Orange légèrement adouci */
    --accent-dark: #FF8A00;
    --gold: #FFC72C;
    --green: #34D399;
    --ink: #F1F5F9;           /* Texte principal (presque blanc) */
    --muted: #94A3B8;         /* Texte secondaire */
    --bg: #0A1628;            /* Fond global */
    --surface: #15243D;       /* Fond des cartes */
    --soft: #1F3052;          /* Fonds soft (sections alternées) */
    --line: #2A3A56;          /* Bordures */
  }

  /* Fond global */
  body { background: #0A1628 !important; color: #F1F5F9 !important; }

  /* Sections de contenu blanches → fond sombre */
  .about-section, .why-section, .contact-cards-section,
  .legal-section, .hours-section, .testimonials-section,
  .partners-section, .video-section, .form-section-contact {
    background: #0A1628 !important;
  }

  /* Sections "alt" : surface légèrement plus claire */
  .subservice-section, .subservice-section.alt,
  .process-section, .trust-bar, .services-intro {
    background: #15243D !important;
  }

  /* TITRES — clairs sur fond sombre */
  h1, h2, h3, h4, h5 { color: #F1F5F9 !important; }
  .section-header h2 { color: #F1F5F9 !important; }
  .section-header p { color: #94A3B8 !important; }

  /* HIGHLIGHTS — restent en dégradé orange/or */
  .highlight {
    background: linear-gradient(120deg, #FF9E2C 0%, #FFC72C 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent;
  }

  /* PARAGRAPHES sur sections claires en light → texte clair en dark */
  .about-section p, .why-section p, .why-card p,
  .pillar-card p, .pillar-card li, .step-card p,
  .testimonial-quote, .contact-card-direct span,
  .legal-block p, .legal-block ul li, .legal-block h3,
  .form-step-sub, .form-label {
    color: #CBD5E1 !important;
  }

  .pillar-card h3, .step-card h3, .why-card h3,
  .legal-block h2, .legal-block strong,
  .contact-card-direct strong, .form-step-title h3 {
    color: #F1F5F9 !important;
  }

  /* CARTES — fond plus clair que le fond global pour ressortir */
  .pillar-card, .why-card, .step-card,
  .testimonial, .partner-card, .contact-card-direct,
  .form-shell, .form-shell-contact, .upload-zone,
  .legal-toc, .hours-card, .info-card, .right-card,
  .thanks-card, .thanks-step, .form-progress-bar {
    background: #15243D !important;
    border-color: #2A3A56 !important;
    color: #F1F5F9 !important;
  }

  /* INPUTS / FORMULAIRES — fond sombre */
  .form-input, .form-select, .form-textarea,
  input[type="text"], input[type="email"], input[type="tel"],
  input[type="url"], input[type="number"], select, textarea {
    background: #0F1B2E !important;
    border-color: #2A3A56 !important;
    color: #F1F5F9 !important;
  }
  .form-input::placeholder, .form-textarea::placeholder { color: #64748B !important; }
  .form-input:focus, .form-select:focus, .form-textarea:focus {
    background: #15243D !important;
    border-color: #FF8A00 !important;
  }

  /* HEADER — fond translucide sombre */
  #header {
    background: rgba(10, 22, 40, 0.92) !important;
    backdrop-filter: blur(12px);
    border-bottom-color: #2A3A56 !important;
  }
  .nav-links a { color: #CBD5E1 !important; }
  .nav-links a:hover, .nav-links a.active { color: #FF9E2C !important; }
  .phone-link { color: #F1F5F9 !important; }

  /* MOBILE MENU — fond sombre */
  .mobile-menu { background: #0A1628 !important; }
  .mobile-menu nav ul li a { color: #F1F5F9 !important; }
  .mobile-menu nav ul li a:active { background: rgba(255,138,0,0.15) !important; }

  /* STICKY MOBILE CTA — fond sombre */
  .sticky-mobile-cta {
    background: rgba(15, 27, 46, 0.95) !important;
    border-top-color: #2A3A56 !important;
  }

  /* FOOTER — déjà sombre, on l'unifie */
  footer {
    background: #050C18 !important;
    border-top: 1px solid #2A3A56;
  }
  .footer-grid h4, .footer-grid li, .footer-grid a,
  .footer-brand p, .footer-bottom p, .footer-bottom a {
    color: #94A3B8 !important;
  }
  .footer-grid a:hover, .footer-bottom a:hover { color: #FF9E2C !important; }

  /* CARDS SPÉCIALES (encadrés colorés) — gardent leurs couleurs */
  .legal-intro, .thanks-tip, .upload-help,
  .legal-callout, .legal-highlight {
    background: linear-gradient(135deg, rgba(255,138,0,0.15) 0%, rgba(255,199,44,0.08) 100%) !important;
    border-color: rgba(255,138,0,0.3) !important;
  }
  .legal-intro-text strong, .legal-callout strong, .legal-highlight strong { color: #F1F5F9 !important; }
  .legal-intro-text p, .legal-callout p { color: #CBD5E1 !important; }

  /* LIENS dans le texte */
  .legal-block a, .form-consent a, .upload-help a,
  .footer-bottom a, p a { color: #FF9E2C !important; }
  .legal-block a:hover { color: #FFC72C !important; }

  /* CONSENT BOX */
  .form-consent { background: #0F1B2E !important; color: #94A3B8 !important; }
  .form-consent strong { color: #F1F5F9 !important; }

  /* PROGRESS BAR / STEP — base sombre */
  .form-progress-bar { background: #0F1B2E !important; }
  .form-progress-step { color: #64748B !important; }
  .form-progress-step.active { color: #FF9E2C !important; }
  .form-progress-step.done { color: #34D399 !important; }
  .form-progress-step-num { background: #1F3052 !important; color: #94A3B8; }
  .form-progress-step.active .form-progress-step-num { background: #FF8A00 !important; color: white !important; }

  /* TOC pages légales */
  .legal-toc a { color: #94A3B8 !important; }
  .legal-toc a:hover { background: #1F3052 !important; color: #F1F5F9 !important; }

  /* SCROLLBAR sombre (desktop) */
  ::-webkit-scrollbar-track { background: #15243D; }
  ::-webkit-scrollbar-thumb { border-color: #15243D; }

  /* LOGO — un léger glow autour pour ressortir sur fond sombre */
  .logo-img {
    filter: drop-shadow(0 0 8px rgba(74, 122, 199, 0.3));
  }
  .footer-brand .logo-img {
    filter: brightness(0) invert(1) !important;
  }

  /* SELECTION DE TEXTE */
  ::selection { background: #FF9E2C; color: #0A1628; }

  /* IMAGES — légère atténuation pour ne pas éblouir en mode sombre */
  img:not(.logo-img):not(.no-dim) { filter: brightness(0.92); }

  /* ZONES D'UPLOAD avec fichier */
  .upload-zone.has-file {
    background: rgba(52, 211, 153, 0.15) !important;
    border-color: #34D399 !important;
  }

  /* TEXTES en majuscules / labels */
  .form-progress-step span { color: inherit; }
}

/* ----- TOGGLE manuel (au cas où l'utilisateur veut forcer un mode) ----- */
[data-theme="dark"] { color-scheme: dark; }
[data-theme="light"] { color-scheme: light; }

/* ================================================================
   ✨ AMÉLIORATIONS 2026 — 3D, ACCESSIBILITÉ, PERFORMANCE
   ================================================================
   Inspiré des tendances web 2026 :
   • Profondeur spatiale et ombres réalistes
   • Glassmorphism évolué (depth hierarchy)
   • Boutons 3D avec rebond physique
   • Mesh gradients subtils
   • Focus rings accessibilité WCAG 2.2
   ================================================================ */

/* --- A. SKIP-LINK (accessibilité clavier WCAG 2.4.1) --- */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: #FF8A00;
  color: white;
  padding: 14px 24px;
  z-index: 9999;
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  border-radius: 0 0 12px 0;
  box-shadow: 0 8px 24px rgba(255,138,0,0.4);
  transition: top 0.2s ease;
}
.skip-link:focus {
  top: 0;
  outline: 3px solid #1B3A6B;
  outline-offset: 2px;
}

/* --- B. FOCUS RINGS PREMIUM (WCAG 2.4.7 + 2.4.11) --- */
*:focus { outline: none; }
*:focus-visible {
  outline: 3px solid #FF8A00;
  outline-offset: 3px;
  border-radius: 6px;
  transition: outline-offset 0.15s ease;
}
button:focus-visible, a:focus-visible, .btn:focus-visible {
  outline-offset: 4px;
  box-shadow: 0 0 0 6px rgba(255, 138, 0, 0.15);
}
input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: none;
  border-color: #FF8A00 !important;
  box-shadow: 0 0 0 4px rgba(255, 138, 0, 0.2),
              inset 0 1px 2px rgba(0, 0, 0, 0.05) !important;
}

/* --- C. BOUTON 3D PREMIUM (depth + bounce physique) --- */
.btn-primary {
  position: relative;
  background: linear-gradient(145deg, #FFB347 0%, #FF8A00 50%, #E67000 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.4),
    inset 0 -2px 0 rgba(0,0,0,0.15),
    0 4px 0 #C25E00,
    0 8px 20px rgba(255,138,0,0.35);
  transform: translateZ(0);
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.btn-primary::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.3) 0%, transparent 50%);
  border-radius: inherit;
  pointer-events: none;
  opacity: 0.6;
  transition: opacity 0.2s;
}
.btn-primary:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.5),
    inset 0 -2px 0 rgba(0,0,0,0.15),
    0 7px 0 #C25E00,
    0 12px 30px rgba(255,138,0,0.45);
}
.btn-primary:hover::after { opacity: 1; }
.btn-primary:active {
  transform: translateY(2px);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.4),
    inset 0 -2px 0 rgba(0,0,0,0.15),
    0 2px 0 #C25E00,
    0 4px 10px rgba(255,138,0,0.35);
  transition-duration: 0.08s;
}

/* --- D. ICÔNES 3D AVEC PROFONDEUR RÉALISTE --- */
.icon-3d {
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.icon-3d::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(255,255,255,0.4) 0%, transparent 50%, transparent 100%);
  pointer-events: none;
  z-index: 1;
}
.icon-3d svg { position: relative; z-index: 2; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.15)); }

/* --- E. GLASSMORPHISM HEADER (depth hierarchy) --- */
#header {
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(220, 227, 237, 0.5);
}
#header.scrolled {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(24px) saturate(200%);
  box-shadow: 0 4px 24px rgba(27, 58, 107, 0.08);
}

/* --- F. MESH GRADIENT BACKGROUNDS (tendance 2026) --- */
.hero, .page-hero {
  background:
    radial-gradient(at 20% 0%, rgba(255, 138, 0, 0.25) 0px, transparent 50%),
    radial-gradient(at 80% 0%, rgba(255, 199, 44, 0.2) 0px, transparent 50%),
    radial-gradient(at 0% 50%, rgba(74, 122, 199, 0.3) 0px, transparent 50%),
    radial-gradient(at 100% 100%, rgba(16, 185, 129, 0.2) 0px, transparent 50%),
    linear-gradient(135deg, #1B3A6B 0%, #0F2548 50%, #1B3A6B 100%) !important;
}

/* --- G. CARTES LEVITATING (depth réaliste) --- */
.pillar-card, .why-card, .testimonial, .step-card, .contact-card-direct {
  position: relative;
  background: white;
  box-shadow:
    0 1px 2px rgba(15, 27, 46, 0.04),
    0 4px 12px rgba(15, 27, 46, 0.06),
    0 16px 32px rgba(15, 27, 46, 0.04);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.4s ease;
}
.pillar-card::before, .why-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.5) 0%, transparent 30%);
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s;
}
.pillar-card:hover, .why-card:hover, .testimonial:hover {
  transform: translateY(-8px) scale(1.01);
  box-shadow:
    0 2px 4px rgba(15, 27, 46, 0.06),
    0 12px 24px rgba(15, 27, 46, 0.1),
    0 32px 64px rgba(15, 27, 46, 0.12);
}
.pillar-card:hover::before, .why-card:hover::before { opacity: 1; }

/* --- H. TEXTE GRADIENT ANIMÉ (highlight amélioré) --- */
.highlight {
  background: linear-gradient(120deg,
    #FF8A00 0%, #FFC72C 25%, #FFE066 50%, #FFC72C 75%, #FF8A00 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: gradient-shimmer 6s linear infinite;
}
@keyframes gradient-shimmer {
  to { background-position: 200% center; }
}

/* --- I. BOUTONS PULSE AMÉLIORÉS (halo lumineux) --- */
.btn-pulse {
  position: relative;
}
.btn-pulse::before {
  content: '';
  position: absolute;
  inset: -4px;
  background: linear-gradient(135deg, #FF8A00, #FFC72C, #FF8A00);
  border-radius: inherit;
  z-index: -1;
  opacity: 0;
  filter: blur(12px);
  animation: pulse-halo 2.5s ease-in-out infinite;
}
@keyframes pulse-halo {
  0%, 100% { opacity: 0.4; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(1.05); }
}

/* --- J. PARALLAX ÉLÉMENTS FLOTTANTS (depth perception) --- */
.bolt-bg {
  animation: bolt-drift 8s ease-in-out infinite;
  filter: drop-shadow(0 8px 16px rgba(255, 199, 44, 0.3));
}

/* --- K. SECTIONS AVEC SÉPARATEURS ORGANIQUES (blob) --- */
.about-section, .why-section, .partners-section {
  position: relative;
}

/* --- L. SCROLLBAR PREMIUM --- */
@media (min-width: 1024px) {
  ::-webkit-scrollbar { width: 14px; }
  ::-webkit-scrollbar-track { background: #FAFBFD; }
  ::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #FFB347, #FF8A00, #FFC72C);
    border-radius: 7px;
    border: 3px solid #FAFBFD;
  }
  ::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #FF8A00, #FFB347);
  }
}

/* --- M. LIENS AVEC SOULIGNEMENT ANIMÉ --- */
.legal-block a:not(.btn), .legal-content a:not(.btn) {
  position: relative;
  text-decoration: none;
  background-image: linear-gradient(currentColor, currentColor);
  background-size: 0% 2px;
  background-repeat: no-repeat;
  background-position: 0 100%;
  transition: background-size 0.3s ease;
}
.legal-block a:hover, .legal-content a:hover {
  background-size: 100% 2px;
}

/* --- N. CONTRAST ENHANCEMENT (WCAG 2.2 AA — 4.5:1 minimum) --- */
.section-header p, .hero-subtitle {
  color: rgba(255,255,255,0.9);
}
:root {
  --muted: #4F5C73; /* assombri pour meilleur contraste sur fond blanc */
}

/* --- O. ANIMATION D'APPARITION PROGRESSIVE (smooth) --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
  will-change: auto;
}
.reveal-scale {
  opacity: 0;
  transform: scale(0.92);
  transition:
    opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.reveal-scale.visible {
  opacity: 1;
  transform: scale(1);
}

/* --- P. SECTION DIVIDERS ORGANIQUES (SVG wave) --- */
.section-divider {
  display: block;
  width: 100%;
  height: 60px;
  margin-top: -1px;
}

/* --- Q. SR-ONLY (texte pour lecteurs d'écran uniquement) --- */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* --- R. ARIA LIVE REGION (annonces dynamiques aux lecteurs d'écran) --- */
.live-region {
  position: absolute;
  left: -10000px;
  width: 1px; height: 1px;
  overflow: hidden;
}

/* --- S. RESPECT MOTION PREFERENCES (WCAG 2.3.3) --- */
@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 !important;
    transform: none !important;
  }
  .btn-pulse::before { animation: none !important; opacity: 0; }
  .highlight { animation: none !important; }
  .bolt-bg { animation: none !important; }
  body { animation: none !important; }
}

/* --- T. HIGH CONTRAST MODE (WCAG 1.4.6) --- */
@media (prefers-contrast: more) {
  .btn { border: 2px solid currentColor; }
  .form-input, .form-select, .form-textarea { border-width: 3px; }
  .pillar-card, .why-card, .testimonial { border: 2px solid #1B3A6B; }
}

/* --- U. PRINT STYLES (UX qualité) --- */
@media print {
  header, footer, .sticky-mobile-cta, .float-wa, .skip-link { display: none !important; }
  body { background: white !important; color: black !important; }
  a { color: inherit !important; text-decoration: underline; }
  .hero, .page-hero { background: white !important; color: black !important; }
  .hero *, .page-hero * { color: black !important; }
}

/* --- V. PERFORMANCE : containment pour éviter les recalculs --- */
.pillar-card, .why-card, .testimonial, .partner-card,
.contact-card-direct, .step-card, .thanks-step {
  contain: layout style;
}

/* --- W. FONT FACE LOADING (perf + smooth) --- */
@font-face {
  font-family: 'Plus Jakarta Sans Local';
  font-display: swap;
  font-weight: 400 800;
}

/* --- X. STICKY HEADER AVEC SCROLL DETECTION --- */
@supports (animation-timeline: scroll()) {
  #header {
    animation: header-shrink linear;
    animation-timeline: scroll();
    animation-range: 0 200px;
  }
  @keyframes header-shrink {
    to {
      background: rgba(255, 255, 255, 0.95);
      box-shadow: 0 4px 24px rgba(27, 58, 107, 0.1);
    }
  }
}

/* --- Y. CARDS QUI BRILLENT AU SURVOL --- */
.pillar-card, .why-card {
  --shine-x: 50%;
  --shine-y: 50%;
}
.pillar-card::after, .why-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    circle 200px at var(--shine-x) var(--shine-y),
    rgba(255, 138, 0, 0.1) 0%,
    transparent 70%
  );
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.pillar-card:hover::after, .why-card:hover::after { opacity: 1; }

/* --- Z. ARIA-EXPANDED visual state --- */
[aria-expanded="true"] .menu-icon { transform: rotate(90deg); }

/* ================================================================
   ⚡ SECTION "NOTRE UNIVERS ÉNERGIE" — Animations originales
   ================================================================ */
.energy-showcase {
  background: linear-gradient(180deg, #FAFBFD 0%, #FFFFFF 100%);
  padding: 100px 0;
  position: relative;
  overflow: hidden;
}
.energy-showcase::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(at 10% 20%, rgba(255, 138, 0, 0.06) 0px, transparent 50%),
    radial-gradient(at 90% 80%, rgba(16, 185, 129, 0.05) 0px, transparent 50%);
  pointer-events: none;
}
.energy-grid {
  display: grid; grid-template-columns: 1fr; gap: 24px;
  margin-top: 50px; position: relative; z-index: 1;
}
@media (min-width: 768px) { .energy-grid { grid-template-columns: repeat(3, 1fr); } }

.energy-card {
  position: relative;
  border-radius: 24px;
  padding: 36px 28px;
  overflow: hidden;
  min-height: 460px;
  display: flex; flex-direction: column;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.4s ease;
}
.energy-card:hover { transform: translateY(-10px); }
.energy-card-visual {
  height: 220px; margin: -36px -28px 24px;
  position: relative; overflow: hidden;
}

/* ===== CARTE 1 — ÉLECTRICITÉ ===== */
.energy-elec {
  background: linear-gradient(160deg, #1B3A6B 0%, #0F2548 100%);
  color: white;
  box-shadow: 0 20px 50px rgba(27,58,107,0.3);
}
.energy-elec:hover { box-shadow: 0 30px 70px rgba(27,58,107,0.4); }
.energy-elec .energy-card-visual {
  background:
    radial-gradient(at 30% 50%, rgba(255,199,44,0.3) 0%, transparent 50%),
    linear-gradient(180deg, #0F2548 0%, #1B3A6B 100%);
}
.lightning-svg { width: 100%; height: 100%; position: absolute; top: 0; left: 0; }
.lightning-bolt {
  fill: url(#elecGrad);
  filter: drop-shadow(0 0 12px rgba(255,199,44,0.8))
          drop-shadow(0 0 24px rgba(255,138,0,0.5));
  animation: lightning-flash 2.5s ease-in-out infinite;
  transform-origin: center;
}
@keyframes lightning-flash {
  0%, 100% { opacity: 0.4; transform: scale(0.95); }
  20%, 22% { opacity: 1; transform: scale(1.05); }
  40% { opacity: 0.6; transform: scale(1); }
}
.electron {
  fill: #FFC72C;
  filter: drop-shadow(0 0 6px #FFC72C);
}
.electron-1 { animation: electron-flow 3s linear infinite; }
.electron-2 { animation: electron-flow 3s linear 1s infinite; }
.electron-3 { animation: electron-flow 3s linear 2s infinite; }
@keyframes electron-flow {
  0% { transform: translate(-20px, 110px); opacity: 0; }
  10% { opacity: 1; }
  50% { transform: translate(150px, 80px); }
  90% { opacity: 1; }
  100% { transform: translate(320px, 110px); opacity: 0; }
}

/* ===== CARTE 2 — GAZ ===== */
.energy-gaz {
  background: linear-gradient(160deg, #4A7AC7 0%, #1B3A6B 100%);
  color: white;
  box-shadow: 0 20px 50px rgba(74,122,199,0.3);
}
.energy-gaz:hover { box-shadow: 0 30px 70px rgba(74,122,199,0.4); }
.energy-gaz .energy-card-visual {
  background: radial-gradient(at 50% 80%, rgba(74,122,199,0.4) 0%, transparent 60%),
              linear-gradient(180deg, #1B3A6B 0%, #0F2548 100%);
}
.flame-svg { width: 100%; height: 100%; position: absolute; top: 0; left: 0; }
.flame-outer {
  fill: url(#flameOuterGrad);
  filter: drop-shadow(0 -8px 24px rgba(74,122,199,0.8));
  transform-origin: center bottom;
  animation: flame-flicker-out 1.5s ease-in-out infinite;
}
.flame-inner {
  fill: url(#flameInnerGrad);
  filter: drop-shadow(0 -4px 12px rgba(180,220,255,0.9));
  transform-origin: center bottom;
  animation: flame-flicker-in 1.2s ease-in-out infinite 0.2s;
}
@keyframes flame-flicker-out {
  0%, 100% { transform: scaleY(1) scaleX(1); }
  25% { transform: scaleY(1.1) scaleX(0.95); }
  50% { transform: scaleY(0.95) scaleX(1.05); }
  75% { transform: scaleY(1.08) scaleX(0.98); }
}
@keyframes flame-flicker-in {
  0%, 100% { transform: scaleY(1); opacity: 1; }
  50% { transform: scaleY(1.15); opacity: 0.85; }
}
.heat-wave {
  stroke: rgba(74,122,199,0.4);
  stroke-width: 1.5;
  fill: none;
  stroke-linecap: round;
  animation: heat-rise 3s ease-out infinite;
  opacity: 0;
}
.heat-wave-2 { animation-delay: 1s; }
.heat-wave-3 { animation-delay: 2s; }
@keyframes heat-rise {
  0% { transform: translateY(20px); opacity: 0; }
  20% { opacity: 0.6; }
  100% { transform: translateY(-40px); opacity: 0; }
}

/* ===== CARTE 3 — ÉNERGIES VERTES ===== */
.energy-eco {
  background: linear-gradient(160deg, #10B981 0%, #047857 100%);
  color: white;
  box-shadow: 0 20px 50px rgba(16,185,129,0.3);
}
.energy-eco:hover { box-shadow: 0 30px 70px rgba(16,185,129,0.4); }
.energy-eco .energy-card-visual {
  background: radial-gradient(at 30% 30%, rgba(255,199,44,0.3) 0%, transparent 50%),
              linear-gradient(180deg, #047857 0%, #065F46 100%);
}
.turbine-svg { width: 100%; height: 100%; position: absolute; top: 0; left: 0; }
.turbine-mast { fill: #FAFBFD; opacity: 0.9; }
.turbine-blades {
  fill: #FAFBFD;
  transform-origin: 50% 38%;
  animation: turbine-spin 4s linear infinite;
  filter: drop-shadow(0 4px 12px rgba(0,0,0,0.15));
}
@keyframes turbine-spin {
  to { transform: rotate(360deg); }
}
.sun-circle {
  fill: url(#sunGrad);
  animation: sun-pulse 3s ease-in-out infinite;
  filter: drop-shadow(0 0 20px rgba(255,199,44,0.6));
}
@keyframes sun-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}
.sun-ray {
  stroke: #FFC72C;
  stroke-width: 2.5;
  stroke-linecap: round;
  animation: ray-twinkle 2s ease-in-out infinite;
}
.sun-ray:nth-child(odd) { animation-delay: 0.5s; }
@keyframes ray-twinkle {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}
.leaf-float {
  fill: #A7F3D0;
  animation: leaf-drift 6s ease-in-out infinite;
  transform-origin: center;
}
.leaf-float-2 { animation-delay: 2s; }
.leaf-float-3 { animation-delay: 4s; }
@keyframes leaf-drift {
  0% { transform: translate(0, -10px) rotate(0); opacity: 0; }
  20% { opacity: 0.8; }
  80% { opacity: 0.8; }
  100% { transform: translate(40px, 120px) rotate(180deg); opacity: 0; }
}

/* Contenu textuel des cartes */
.energy-card h3 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 24px;
  font-weight: 800;
  color: white;
  margin: 0 0 12px;
}
.energy-card p {
  color: rgba(255,255,255,0.9);
  font-size: 15px;
  line-height: 1.6;
  margin: 0 0 20px;
  flex-grow: 1;
}
.energy-card-cta {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,0.15);
  border: 1.5px solid rgba(255,255,255,0.3);
  color: white;
  padding: 10px 18px;
  border-radius: 100px;
  text-decoration: none;
  font-weight: 700; font-size: 13px;
  backdrop-filter: blur(10px);
  transition: all 0.25s;
  align-self: flex-start;
}
.energy-card-cta:hover {
  background: rgba(255,255,255,0.25);
  transform: translateX(4px);
}

/* Désactivation animations sur reduced-motion */
@media (prefers-reduced-motion: reduce) {
  .lightning-bolt, .electron, .flame-outer, .flame-inner,
  .heat-wave, .turbine-blades, .sun-circle, .sun-ray, .leaf-float,
  .spark-burst {
    animation: none !important;
  }
}
