/* ============================================================
   VARIABLES + THEME
============================================================ */
:root {
  --primary: #1a73e8;
  --primary-light: #4d97ff;
  --primary-dark: #1558b0;

  --text: #0d1b2a;
  --text-light: #3c4858;

  --background: #ffffff;
  --background-alt: #f5f7fa;

  --radius: 20px;

  --shadow-sm: 0 4px 12px rgba(0,0,0,0.07);
  --shadow-md: 0 12px 35px rgba(0,0,0,0.13);

  --transition: 0.25s ease;
}

/* MODE DARK – conservé */
body.dark {
  --text: #f5f5f5;
  --text-light: #d1d5db;
  --background: #0f172a;
  --background-alt: #1e293b;
}

/* 🔥 FIX ANTI-SCROLL HORIZONTAL GLOBAL */
html, body {
  overflow-x: hidden !important;
  max-width: 100%;
  position: relative;
}

/* ============================================================
   RESET
============================================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;

  /* FIX ANTI-SCROLL 2 : évite les débordements à cause de width:auto */
  max-width: 100%;
}

body {
  font-family: "Inter", sans-serif;
  background: var(--background);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden; /* déjà présent, conservé */
}

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

/* LIENS */
a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}
a:hover {
  color: var(--primary-dark);
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: auto;

  /* FIX ANTI-SCROLL 3 : évite que .container déborde */
  overflow-x: hidden;
}

/* ============================================================
   HEADER
============================================================ */
.header {
  position: sticky;
  top: 0;
  background: var(--background);
  box-shadow: var(--shadow-sm);
  z-index: 1000;
  padding: 15px 0;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo img {
  height: 42px;
}

.nav {
  display: flex;
  gap: 25px;
}
.nav a {
  font-weight: 500;
  color: var(--text-light);
  padding: 6px 8px;
}
.nav a:hover {
  background: var(--background-alt);
  border-radius: 8px;
  color: var(--primary);
}

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

.lang-switch,
.dark-toggle {
  padding: 6px 12px;
  border-radius: 10px;
  border: 1px solid var(--background-alt);
  background: var(--background-alt);
  cursor: pointer;
}

/* ============================================================
   HERO — GLASSMORPHISM
============================================================ */
.glass-hero {
  padding: 100px 0;
  background: linear-gradient(135deg, #e8f0ff, #ffffff);
  position: relative;

  /* FIX ANTI-SCROLL 4 */
  overflow-x: hidden;
}

.glass-hero::before,
.glass-hero::after {
  content: "";
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  filter: blur(120px);
  background: rgba(26,115,232,0.22);
}
.glass-hero::before { top: -80px; left: -80px; }
.glass-hero::after { bottom: -80px; right: -80px; }

.hero-content {
  display: flex;
  gap: 50px;
  align-items: center;
  justify-content: space-between;
  backdrop-filter: blur(18px);
  background: rgba(255,255,255,0.26);
  border-radius: 32px;
  border: 1px solid rgba(255,255,255,0.4);
  padding: 60px 50px;
  box-shadow: var(--shadow-md);

  /* empêche les débordements internes */
  overflow-x: hidden;
}

.hero-text {
  flex: 1;
  max-width: 520px;
}
.hero-text h1 {
  font-size: 38px;
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 18px;
  color: var(--text);
}
.hero-text p {
  font-size: 18px;
  color: var(--text-light);
  margin-bottom: 26px;
}

.hero-image {
  flex: 1;
  display: flex;
  justify-content: center;
}
.hero-image img {
  max-height: 420px;
  object-fit: contain;
  filter: drop-shadow(0 6px 18px rgba(0,0,0,0.15));
}

/* ============================================================
   HOW IT WORKS
============================================================ */
.glass-section-super {
  padding: 120px 0;
  background: linear-gradient(135deg, #e8f0ff, #ffffff);
  position: relative;
}
.glass-title {
  text-align: center;
  font-size: 40px;
  font-weight: 800;
}

.glass-subtitle {
  text-align: center;
  margin-top: 12px;
  color: var(--text-light);
}

.how-super-grid {
  margin-top: 70px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;

  /* important pour éviter overflow */
  width: 100%;
}

.glass-card-super {
  position: relative;
  padding: 45px 35px;
  backdrop-filter: blur(22px);
  background: rgba(255,255,255,0.22);
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 26px;
  box-shadow: var(--shadow-md);
  transition: 0.35s ease;
}
.glass-card-super:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 18px 40px rgba(0,0,0,0.22);
}

.super-icon {
  height: 110px;
  margin: auto;
  filter: drop-shadow(0 10px 20px rgba(0,0,0,0.1));
}

.glass-card-super h3 {
  text-align: center;
  font-size: 24px;
  margin: 16px 0;
}

.super-list {
  list-style: none;
  color: var(--text-light);
  font-size: 16px;
  line-height: 1.7;
}
.super-list li {
  display: flex;
  gap: 10px;
  margin-bottom: 8px;
}

/* ============================================================
   CTA DOWNLOAD
============================================================ */
.cta-glass {
  padding: 120px 0;
  text-align: center;
  background: linear-gradient(135deg, #e8f0ff, #ffffff);
  position: relative;
}

.cta-glass-content {
  backdrop-filter: blur(20px);
  background: rgba(255,255,255,0.28);
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 28px;
  padding: 60px 40px;
  box-shadow: var(--shadow-md);

  overflow-x: hidden;
}

.cta-glass h2 {
  font-size: 38px;
  font-weight: 800;
}
.cta-glass p {
  margin: 14px 0 40px;
  color: var(--text-light);
}

.cta-store-row {
  display: flex;
  justify-content: center;
  gap: 35px;
  margin-bottom: 40px;

  /* évite débordement sur mobile */
  flex-wrap: wrap;
}

.cta-store-box {
  width: auto;
  height: 95px;
  padding: 0 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 22px;
  background: rgba(255,255,255,0.28);
  backdrop-filter: blur(22px);
  border: 1px solid rgba(255,255,255,0.45);
  box-shadow: var(--shadow-sm);
  transition: 0.3s ease;
  overflow: hidden;
}

.cta-store-box img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.cta-store-box:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: var(--shadow-md);
}

/* ============================================================
   FOOTER
============================================================ */
.footer-glass {
  padding: 80px 0 40px;
  background: rgba(255,255,255,0.6);
  backdrop-filter: blur(18px);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 35px;

  width: 100%;
  overflow-x: hidden;
}

.footer-logo {
  height: 45px;
  margin-bottom: 10px;
}

.footer-glass a {
  display: block;
  margin-bottom: 6px;
  color: var(--text-light);
}

.footer-bottom {
  text-align: center;
  margin-top: 30px;
  font-size: 14px;
  color: var(--text-light);
}

/* ============================================================
   RESPONSIVE
============================================================ */
@media (max-width: 900px) {
  .nav { display: none; }
  .hero-content { flex-direction: column; padding: 40px 20px; text-align: center; }
  .hero-image img { max-height: 260px; }
  .how-super-grid { grid-template-columns: 1fr; }
  .cta-store-row { flex-direction: column; }
}

/* ============================================================
   IPHONE MOCKUP
============================================================ */

.hero-phone-wrapper {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;

  /* Évite le débordement sur petits écrans */
  overflow-x: hidden;
}

.iphone-frame {
  position: relative;
  width: 280px;
  height: 560px;
  border-radius: 42px;
  padding: 10px;
  background: radial-gradient(circle at top, #d8dde8 0%, #aeb4c4 40%, #9096a8 100%);
  box-shadow:
    inset 0 0 8px rgba(255,255,255,0.05),
    inset 0 0 20px rgba(255,255,255,0.03),
    0 12px 30px rgba(0,0,0,0.45);
  border: 2px solid rgba(255,255,255,0.9);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;

  max-width: 100%; /* important */
  overflow: hidden; /* anti-scroll */
}

.iphone-inner {
  position: relative;
  flex: 1;
  margin-top: 18px;
  border-radius: 32px;
  overflow: hidden;
  overscroll-behavior: contain;
  background: #f7f8fc;
  display: flex;
  flex-direction: column;
}

.iphone-app-header {
  padding: 6px 14px 8px 14px;
  border-bottom: 1px solid rgba(148,163,184,0.3);
}

.iphone-app-title {
  font-size: 15px;
  font-weight: 700;
  color: #111827;
}

.iphone-content {
  flex: 1;
  padding: 10px 10px 12px 10px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  background: #f7f8fc;
}

.iphone-loading {
  text-align: center;
  font-size: 14px;
  color: #6b7280;
}

.phone-trip-item {
  padding: 10px 10px;
  margin-bottom: 8px;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 4px 10px rgba(15,23,42,0.08);
  border: 1px solid rgba(148,163,184,0.35);
}

.phone-trip-route {
  font-size: 14px;
  font-weight: 700;
  color: #111827;
  margin-bottom: 4px;
}

.phone-trip-meta {
  font-size: 12px;
  color: #6b7280;
  margin-bottom: 6px;
}

.phone-trip-btn {
  display: inline-block;
  padding: 5px 9px;
  border-radius: 999px;
  background: #1a73e8;
  color: #ffffff;
  font-size: 11px;
  font-weight: 600;
  text-decoration: none;
}

@media (max-width: 900px) {
  .hero-content {
    flex-direction: column;
    gap: 32px;
  }

  .hero-phone-wrapper {
    order: 2;
  }

  .iphone-frame {
    width: 260px;
    height: 520px;
  }
}

/* ============================
   🔥 ANTI-SCROLL GLOBAL
============================ */
html, body {
  overflow-x: hidden !important;
  width: 100%;
  max-width: 100%;
  position: relative;
}

/* Force tous les layouts à ne jamais dépasser l'écran */
* {
  max-width: 100vw;
}

/* Empêche les sections avec effets glass/blur de dépasser */
.glass-hero,
.hero-content,
.glass-section-super,
.cta-glass,
.footer-glass {
  overflow-x: hidden !important;
}

/* Le cercle flou géant overridait l’écran → on limite */
.glass-hero::before,
.glass-hero::after {
  left: auto !important;
  right: auto !important;
  max-width: 100vw !important;
  overflow: hidden !important;
}

/* iPhone mockup ne doit JAMAIS dépasser */
.hero-phone-wrapper,
.iphone-frame {
  max-width: 100% !important;
  overflow-x: hidden !important;
}

/* Sur mobile, on réduit encore pour être sûr */
@media (max-width: 480px) {
  .iphone-frame {
    transform: scale(0.92); /* 8% de réduction invisible mais efficace */
    margin: 0 auto;
  }

  .hero-content {
    padding-left: 0 !important;
    padding-right: 0 !important;
    width: 100% !important;
  }
}
