/* ══════════════════════════════════════════════════════════════════
   RESPONSIVE FIX — filet de sécurité mobile (à charger en dernier)
   ══════════════════════════════════════════════════════════════════ */
html, body { max-width: 100%; overflow-x: hidden; }
*, *::before, *::after { min-width: 0; }

img, video, canvas, svg, iframe { max-width: 100%; height: auto; }
iframe { width: 100%; }

h1, h2, h3, h4, p, li, a, span, td, th, label, button {
  overflow-wrap: break-word;
  word-break: normal;
  hyphens: none;
}
pre, code { white-space: pre-wrap; overflow-wrap: anywhere; }

/* Tableaux : défilement horizontal plutôt que débordement */
table { max-width: 100%; }
.compare-wrap, .table-wrap, .guide-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 768px) {
  /* Titres fluides */
  h1 { font-size: clamp(1.7rem, 7vw, 2.6rem) !important; line-height: 1.15 !important; }
  h2 { font-size: clamp(1.35rem, 5.4vw, 2rem) !important; line-height: 1.2 !important; }
  h3 { font-size: clamp(1.05rem, 4.4vw, 1.4rem) !important; }

  /* Grilles génériques en une colonne */
  .reviews-grid, .faq-grid, .features-grid, .specs-grid,
  .guides-grid, .footer-grid, .steps-grid, .usecase-grid, .stats-grid {
    grid-template-columns: 1fr !important;
  }

  /* Espacements et rayons plus doux */
  section { padding-left: 16px !important; padding-right: 16px !important; }

  /* Cibles tactiles confortables */
  a.btn, button, .pricing-btn, .cmp-btn, .cta-btn {
    min-height: 44px;
  }
}

@media (max-width: 420px) {
  .stats-grid, .reviews-grid { gap: 12px !important; }
}

/* Respect des préférences de mouvement */
@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;
  }
}
