/* ══════════════════════════════════════
   RESPONSIVE — breakpoints
   1024px : tablette paysage
    860px : tablette portrait / hamburger
    640px : mobile large
    480px : mobile standard
    360px : petit mobile
══════════════════════════════════════ */


/* ════════════════════════════════
   NAVBAR
════════════════════════════════ */

/* Tablette portrait → hamburger */
@media (max-width: 860px) {
  .nav-links        { display: none; }
  .nav-right        { display: none; }
  .nav-auth-buttons { display: none; }
  .btn-secondary    { display: none; }
  .nav-hamburger    { display: flex; }
  .nav-drawer       { display: flex; }

  /* Pill désactivé sur mobile : navbar pleine largeur */
  nav.scrolled {
    top: 0;
    margin-left: 0;
    margin-right: 0;
    border-radius: 0;
    border: none;
    border-bottom: 0.5px solid rgba(226,232,240,0.8);
    box-shadow: 0 1px 8px rgba(0,0,0,0.06);
    background: rgba(255,255,255,0.97);
  }
}

@media (max-width: 640px) {
  /* Blocage global de l'overflow horizontal */
  html, body {
    overflow-x: hidden;
    max-width: 100vw;
  }

  nav { padding: 0.75rem 1.25rem; }
  body { padding-top: 60px; }
  .nav-brand img { height: 30px; }
}


/* ════════════════════════════════
   HERO
════════════════════════════════ */

/* Tablette paysage : réduire padding */
@media (max-width: 1024px) {
  .hero {
    padding: 3rem 2rem;
    gap: 2rem;
  }
}

/* Tablette portrait : colonne unique */
@media (max-width: 860px) {
  .hero {
    grid-template-columns: 1fr;
    padding: 2.5rem 2rem 3.5rem;
    gap: 2.5rem;
    text-align: center;
  }
  .hero-left {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .title-row {
    justify-content: center;
    padding-left: 0;
  }
  /* Logo icône repositionné : plus de débordement gauche */
  .logo-wrap {
    position: static;
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    margin-right: 10px;
  }
  .hero-sub {
    max-width: 100%;
    text-align: center;
  }
  .hero-auth-buttons {
    justify-content: center;
  }
  /* Annuler le translateX qui cause l'overflow */
  .carousel-outer {
    transform: none;
    max-width: 480px;
    margin: 0 auto;
  }
  .hero-dots {
    bottom: -28px;
  }
}

/* Mobile */
@media (max-width: 640px) {
  .hero {
    padding: 2rem 1.25rem 3rem;
    gap: 2rem;
  }
  .hero-title {
    font-size: clamp(1.6rem, 6vw, 2rem);
    min-height: unset;
  }
  .hero-sub {
    font-size: 0.95rem;
    min-height: unset;
  }
  .hero-auth-buttons {
    flex-direction: column;
    gap: 10px;
    width: 100%;
    max-width: 280px;
  }
  .btn-login,
  .btn-signup {
    width: 100%;
    justify-content: center;
  }
  .carousel-outer {
    transform: none;
    max-width: 100%;
  }
  /* Logo icône encore plus compact */
  .logo-wrap {
    width: 36px;
    height: 36px;
  }
}


/* ════════════════════════════════
   PARTNERS
════════════════════════════════ */

@media (max-width: 640px) {
  .partners-section {
    padding: 24px 0 32px;
  }
  .partners-track {
    gap: 32px;
    animation-duration: 18s;
  }
  .partner-logo img {
    height: 38px;
    max-width: 100px;
  }
}

@media (max-width: 480px) {
  .partners-track {
    gap: 24px;
    animation-duration: 15s;
  }
  .partner-logo img {
    height: 30px;
    max-width: 80px;
  }
}


/* ════════════════════════════════
   ADVANTAGES
════════════════════════════════ */

@media (max-width: 1024px) {
  .adv-container { padding: 0 24px; }
  .mockup-shell  { width: 360px; }
  .mockup-screen { height: 500px; }
  .adv-slide     { height: 500px; }
  .mockup-container { height: 540px; }
}

@media (max-width: 860px) {
  .advantages-section { padding: 72px 0 88px; }
  .advantages-layout {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .mockup-container {
    height: 480px;
    order: -1; /* Mockup en haut sur tablette */
  }
  .mockup-shell {
    width: 340px;
  }
  .mockup-screen { height: 460px; }
  .adv-slide     { height: 460px; }
  .adv-dots {
    right: unset;
    bottom: -24px;
    top: unset;
    flex-direction: row;
    transform: translateX(-50%);
    left: 50%;
  }
  .adv-dot { width: 6px; height: 6px; }
  .adv-dot.active { width: 24px; height: 6px; }
  .section-title-adv { font-size: clamp(1.6rem, 5vw, 2.2rem); }
  .section-subtitle-adv { font-size: 15px; margin-bottom: 48px; }
}

@media (max-width: 640px) {
  .advantages-section { padding: 56px 0 72px; }
  .adv-container { padding: 0 16px; }
  .mockup-shell { width: 300px; }
  .mockup-screen { height: 400px; }
  .adv-slide     { height: 400px; }
  .mockup-container { height: 420px; }
  .feature-item { padding: 20px 20px; }
  .feature-title-adv { font-size: 17px; }
}

@media (max-width: 480px) {
  .mockup-shell { width: 270px; border-radius: 28px; }
  .mockup-screen { height: 360px; border-radius: 20px; }
  .adv-slide     { height: 360px; }
  .mockup-container { height: 380px; }
}


/* ════════════════════════════════
   FEATURES
════════════════════════════════ */

@media (max-width: 1024px) {
  .features-container { padding: 0 24px; }
  .feature-row { gap: 48px; }
}

@media (max-width: 860px) {
  .features-section { padding: 72px 0 88px; }
  .features-header  { margin-bottom: 56px; }
  .feature-row {
    grid-template-columns: 1fr;
    gap: 36px;
    margin-bottom: 56px;
  }
  .feature-row--reverse { direction: ltr; }
  .feature-row--reverse .feature-text,
  .feature-row--reverse .feature-img { direction: ltr; }
  .feature-title    { font-size: 24px; }
  .features-title   { font-size: clamp(24px, 5vw, 36px); }
  .feature-divider  { margin: 48px 0; }
}

@media (max-width: 640px) {
  .features-section  { padding: 56px 0 72px; }
  .features-container { padding: 0 16px; }
  .features-title    { font-size: 22px; }
  .features-subtitle { font-size: 14px; }
  .feature-title     { font-size: 20px; }
  .feature-desc      { font-size: 14px; }
  .feature-pills     { gap: 8px; }
  .feature-pill      { font-size: 12px; padding: 6px 12px; }
  .features-header   { margin-bottom: 40px; }
}


/* ════════════════════════════════
   FAQ
════════════════════════════════ */

@media (max-width: 860px) {
  .faq-section  { padding: 72px 0 88px; }
  .faq-header   { margin-bottom: 40px; }
  .faq-title    { font-size: clamp(22px, 5vw, 32px); }
}

@media (max-width: 640px) {
  .faq-section   { padding: 56px 0 72px; }
  .faq-container { padding: 0 16px; }
  .faq-toggle    { padding: 18px 16px; font-size: 14px; }
  .faq-answer    { padding: 0 16px 18px; font-size: 14px; }
}


/* ════════════════════════════════
   FOOTER
════════════════════════════════ */

@media (max-width: 1024px) {
  .footer-container { padding: 0 24px; }
  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 40px 32px;
  }
  .footer-brand { grid-column: span 2; }
}

@media (max-width: 640px) {
  .footer-section   { padding: 56px 0 40px; }
  .footer-container { padding: 0 20px; }
  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 32px 20px;
  }
  .footer-brand { grid-column: span 2; }
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 18px 0;
  }
  .footer-watermark {
    font-size: clamp(48px, 18vw, 88px);
  }
}

@media (max-width: 480px) {
  .footer-top {
    grid-template-columns: 1fr;
  }
  .footer-brand { grid-column: span 1; }
  .footer-watermark {
    font-size: clamp(40px, 20vw, 72px);
  }
}
