/* Correctif mobile définitif — chargé en dernier */
html, body { max-width:100%; overflow-x:hidden; }

@media (max-width: 991px) {
  /* Formulaire mobile stable : aucune translation/animation pendant la saisie */
  body.robba-site .inner-hero-shell.hero-with-form > .hero-form-zone.mobile-detached,
  body.robba-site .hero-form-zone.mobile-detached,
  body.robba-site .hero-form-zone.mobile-detached .modern-form-card,
  body.robba-site .hero-form-zone.mobile-detached form {
    position:relative !important;
    left:auto !important;
    right:auto !important;
    transform:none !important;
    translate:none !important;
    width:100% !important;
    max-width:100% !important;
    margin-left:auto !important;
    margin-right:auto !important;
    box-sizing:border-box !important;
    animation:none !important;
  }
  body.robba-site .hero-form-zone.mobile-detached {
    contain:layout paint !important;
    overflow:hidden !important;
    padding-left:12px !important;
    padding-right:12px !important;
  }
  body.robba-site .hero-form-zone.mobile-detached .modern-form-card {
    overflow:hidden !important;
  }
  body.robba-site .hero-form-zone.mobile-detached .ajax-contact-form {
    width:100% !important;
    margin-left:0 !important;
    margin-right:0 !important;
  }
  body.robba-site .hero-form-zone.mobile-detached .ajax-contact-form > [class*="col-"] {
    width:100% !important;
    max-width:100% !important;
    flex:0 0 100% !important;
    padding-left:0 !important;
    padding-right:0 !important;
  }
  body.robba-site .hero-form-zone.mobile-detached input,
  body.robba-site .hero-form-zone.mobile-detached textarea,
  body.robba-site .hero-form-zone.mobile-detached select,
  body.robba-site .hero-form-zone.mobile-detached .form-control {
    font-size:16px !important; /* évite le zoom iOS qui décadre le formulaire */
    transform:none !important;
    max-width:100% !important;
    min-width:0 !important;
  }
  body.robba-site .hero-form-zone.mobile-detached input:focus,
  body.robba-site .hero-form-zone.mobile-detached textarea:focus,
  body.robba-site .hero-form-zone.mobile-detached select:focus {
    transform:none !important;
  }
  body.robba-site .hero-form-zone.mobile-detached .captcha-col {
    overflow:hidden !important;
    padding:0 !important;
  }
  body.robba-site .hero-form-zone.mobile-detached #js-contact-btn {
    width:100% !important;
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    text-align:center !important;
  }

  /* Menu mobile piloté uniquement par robba-hard-fix.js */
  body.robba-site .vdo-mobile-panel {
    display:block !important;
    position:fixed !important;
    left:10px !important;
    right:10px !important;
    width:auto !important;
    z-index:2147483000 !important;
    opacity:0 !important;
    visibility:hidden !important;
    pointer-events:none !important;
    transform:translateY(-8px) !important;
    max-height:calc(100dvh - var(--robba-menu-top, 88px) - 10px) !important;
    overflow-y:auto !important;
    overscroll-behavior:contain !important;
  }
  body.robba-site .vdo-mobile-panel.robba-menu-open {
    top:var(--robba-menu-top, 88px) !important;
    opacity:1 !important;
    visibility:visible !important;
    pointer-events:auto !important;
    transform:none !important;
  }

  /* Aucun bouton n'est actif par simple présence du lien. */
  body.robba-site .vdo-mobile-panel li:not(.robba-current-page) > a,
  body.robba-site .main-menu.modern-nav nav > ul > li:not(.robba-current-page) > a[href="nos-realisations.html"] {
    background:transparent !important;
    border-color:transparent !important;
    box-shadow:none !important;
    color:inherit !important;
  }
  body.robba-site .vdo-mobile-panel li.robba-current-page > a {
    color:#fff !important;
    background:linear-gradient(180deg,#c3955d 0%,var(--robba-gold,#a6753c) 100%) !important;
    border-color:var(--robba-gold-dark,#70461f) !important;
  }
}
