
/* =====================================================
   DPEP Mobile V1 — Menu profil mobile
===================================================== */

@media (max-width: 991px) {
    body.dpep-mobile-v1 .offcanvas-login-register,
    body.dpep-mobile-v1 #hz-offcanvas-login-register {
        max-width: 88vw !important;
        width: 340px !important;
    }

    body.dpep-mobile-v1 .dpep-mobile-profile-actions-v1 {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        padding: 14px 16px 12px !important;
        border-bottom: 1px solid rgba(0, 0, 0, .08) !important;
        background: #fff !important;
    }

    body.dpep-mobile-v1 .dpep-mobile-profile-actions-v1 a,
    body.dpep-mobile-v1 .dpep-mobile-profile-actions-v1 button {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-height: 42px !important;
        width: 100% !important;
        border-radius: 10px !important;
        font-size: 14px !important;
        font-weight: 800 !important;
        text-decoration: none !important;
        border: 1px solid rgba(103, 78, 52, .35) !important;
        cursor: pointer !important;
    }

    body.dpep-mobile-v1 .dpep-mobile-profile-home-v1 {
        background: #6b4d34 !important;
        color: #fff !important;
        border-color: #6b4d34 !important;
    }

    body.dpep-mobile-v1 .dpep-mobile-profile-close-v1 {
        background: #fff !important;
        color: #6b4d34 !important;
    }

    body.dpep-mobile-v1 .dpep-mobile-profile-actions-v1 a:before {
        content: "←" !important;
        margin-right: 8px !important;
        font-weight: 900 !important;
    }

    body.dpep-mobile-v1 .dpep-mobile-profile-close-v1:before {
        content: "×" !important;
        margin-right: 8px !important;
        font-size: 18px !important;
        line-height: 1 !important;
        font-weight: 900 !important;
    }

    /* Rend le menu plus lisible dans l'offcanvas */
    body.dpep-mobile-v1 #hz-offcanvas-login-register .logged-in-nav,
    body.dpep-mobile-v1 .offcanvas-login-register .logged-in-nav {
        padding-top: 4px !important;
    }

    body.dpep-mobile-v1 #hz-offcanvas-login-register .logged-in-nav li a,
    body.dpep-mobile-v1 .offcanvas-login-register .logged-in-nav li a {
        min-height: 44px !important;
        display: flex !important;
        align-items: center !important;
        padding: 12px 18px !important;
        font-size: 14px !important;
    }
}

/* =====================================================
   DPEP Mobile V2 — Connexion / Inscription mobile
===================================================== */

@media (max-width: 991px) {
    body.dpep-mobile-v2 .dpep-mobile-login-link-v2,
    body.dpep-mobile-v2 .dpep-mobile-register-link-v2 {
        cursor: pointer !important;
    }

    body.dpep-mobile-v2 #hz-offcanvas-login-register .login-link a,
    body.dpep-mobile-v2 #hz-offcanvas-login-register .register-link a,
    body.dpep-mobile-v2 .offcanvas-login-register .login-link a,
    body.dpep-mobile-v2 .offcanvas-login-register .register-link a {
        min-height: 42px !important;
        display: flex !important;
        align-items: center !important;
    }
}

/* =====================================================
   DPEP Mobile V3 — Connexion responsive
===================================================== */

@media (max-width: 991px) {
    body.dpep-mobile-auth-v3 {
        overflow-x: hidden !important;
    }

    body.dpep-mobile-auth-v3 section.blog-wrap,
    body.dpep-mobile-auth-v3 .blog-wrap,
    body.dpep-mobile-auth-v3 .main-wrap,
    body.dpep-mobile-auth-v3 main,
    body.dpep-mobile-auth-v3 .container,
    body.dpep-mobile-auth-v3 .row,
    body.dpep-mobile-auth-v3 .col-lg-12,
    body.dpep-mobile-auth-v3 .col-md-12,
    body.dpep-mobile-auth-v3 .col-sm-12 {
        max-width: 100vw !important;
        overflow-x: hidden !important;
    }

    body.dpep-mobile-auth-v3 section.blog-wrap,
    body.dpep-mobile-auth-v3 .blog-wrap {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    body.dpep-mobile-auth-v3 section.blog-wrap .container,
    body.dpep-mobile-auth-v3 .blog-wrap .container {
        width: 100% !important;
        max-width: 100% !important;
        padding-left: 14px !important;
        padding-right: 14px !important;
    }

    body.dpep-mobile-auth-v3 section.blog-wrap .row,
    body.dpep-mobile-auth-v3 .blog-wrap .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    body.dpep-mobile-auth-v3 section.blog-wrap [class*="col-"],
    body.dpep-mobile-auth-v3 .blog-wrap [class*="col-"] {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* Carte auth */
    body.dpep-mobile-auth-v3 .dpep-auth-card,
    body.dpep-mobile-auth-v3 .login-register-form,
    body.dpep-mobile-auth-v3 .login-register-form-wrap,
    body.dpep-mobile-auth-v3 .login-register-wrap,
    body.dpep-mobile-auth-v3 .houzez-login-form-js,
    body.dpep-mobile-auth-v3 .houzez-register-form-js,
    body.dpep-mobile-auth-v3 .tab-content,
    body.dpep-mobile-auth-v3 .login-form-tab,
    body.dpep-mobile-auth-v3 .register-form-tab {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    body.dpep-mobile-auth-v3 .dpep-auth-card,
    body.dpep-mobile-auth-v3 .login-register-form-wrap,
    body.dpep-mobile-auth-v3 .login-register-wrap {
        margin-left: auto !important;
        margin-right: auto !important;
        border-radius: 20px !important;
    }

    body.dpep-mobile-auth-v3 .tab-content,
    body.dpep-mobile-auth-v3 .tab-pane {
        overflow: visible !important;
    }

    body.dpep-mobile-auth-v3 form,
    body.dpep-mobile-auth-v3 .form-group,
    body.dpep-mobile-auth-v3 .form-group-field,
    body.dpep-mobile-auth-v3 .bootstrap-select,
    body.dpep-mobile-auth-v3 .dropdown,
    body.dpep-mobile-auth-v3 input,
    body.dpep-mobile-auth-v3 select,
    body.dpep-mobile-auth-v3 textarea,
    body.dpep-mobile-auth-v3 button,
    body.dpep-mobile-auth-v3 .btn {
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    body.dpep-mobile-auth-v3 input.form-control,
    body.dpep-mobile-auth-v3 .form-control,
    body.dpep-mobile-auth-v3 .bootstrap-select > .dropdown-toggle {
        width: 100% !important;
        min-width: 0 !important;
    }

    body.dpep-mobile-auth-v3 .houzez-grecaptcha-v2,
    body.dpep-mobile-auth-v3 .captcha_wrapper,
    body.dpep-mobile-auth-v3 .houzez_google_reCaptcha {
        max-width: 100% !important;
        overflow: hidden !important;
    }

    body.dpep-mobile-auth-v3 .houzez_google_reCaptcha > div,
    body.dpep-mobile-auth-v3 .g-recaptcha,
    body.dpep-mobile-auth-v3 iframe[title="reCAPTCHA"] {
        max-width: 100% !important;
    }

    /* Onglets connexion / inscription */
    body.dpep-mobile-auth-v3 .login-register-tabs,
    body.dpep-mobile-auth-v3 .nav-tabs,
    body.dpep-mobile-auth-v3 .dpep-auth-tabs {
        max-width: 100% !important;
        overflow: hidden !important;
    }

    body.dpep-mobile-auth-v3 .login-register-tabs a,
    body.dpep-mobile-auth-v3 .nav-tabs a,
    body.dpep-mobile-auth-v3 .login-register-tabs button,
    body.dpep-mobile-auth-v3 .nav-tabs button {
        white-space: nowrap !important;
    }

    /* Quand l’onglet inscription est demandé, éviter l’écran blanc */
    body.dpep-mobile-auth-v3 .tab-pane.active,
    body.dpep-mobile-auth-v3 .tab-pane.show.active {
        display: block !important;
        opacity: 1 !important;
        visibility: visible !important;
    }

    body.dpep-mobile-auth-v3 #login-form-tab.active,
    body.dpep-mobile-auth-v3 #register-form-tab.active,
    body.dpep-mobile-auth-v3 .login-form-tab.active,
    body.dpep-mobile-auth-v3 .register-form-tab.active {
        display: block !important;
        opacity: 1 !important;
        visibility: visible !important;
    }

    /* Bouton bas */
    body.dpep-mobile-auth-v3 .btn-register,
    body.dpep-mobile-auth-v3 .btn-login,
    body.dpep-mobile-auth-v3 input[type="submit"],
    body.dpep-mobile-auth-v3 button[type="submit"] {
        width: 100% !important;
    }
}

@media (max-width: 420px) {
    body.dpep-mobile-auth-v3 section.blog-wrap .container,
    body.dpep-mobile-auth-v3 .blog-wrap .container {
        padding-left: 10px !important;
        padding-right: 10px !important;
    }

    body.dpep-mobile-auth-v3 .dpep-auth-card,
    body.dpep-mobile-auth-v3 .login-register-form-wrap,
    body.dpep-mobile-auth-v3 .login-register-wrap {
        border-radius: 16px !important;
    }
}

/* =====================================================
   DPEP Mobile V4 — Auth mobile simplifiée
===================================================== */

@media (max-width: 991px) {
    body.dpep-mobile-auth-v4 {
        overflow-x: hidden !important;
    }

    body.dpep-mobile-auth-v4 .login-register-tabs,
    body.dpep-mobile-auth-v4 .nav-tabs,
    body.dpep-mobile-auth-v4 .dpep-auth-tabs {
        justify-content: center !important;
        max-width: 100% !important;
    }

    /* Mode connexion : on cache l'onglet inscription pour éviter le bug d'onglet mobile */
    body.dpep-mobile-auth-v4.dpep-auth-mode-login-v4 .register-link,
    body.dpep-mobile-auth-v4.dpep-auth-mode-login-v4 a[href*="register-form-tab"],
    body.dpep-mobile-auth-v4.dpep-auth-mode-login-v4 button[data-bs-target*="register"],
    body.dpep-mobile-auth-v4.dpep-auth-mode-login-v4 [aria-controls*="register"] {
        display: none !important;
    }

    /* Mode inscription : on cache l'onglet connexion */
    body.dpep-mobile-auth-v4.dpep-auth-mode-register-v4 .login-link,
    body.dpep-mobile-auth-v4.dpep-auth-mode-register-v4 a[href*="login-form-tab"],
    body.dpep-mobile-auth-v4.dpep-auth-mode-register-v4 button[data-bs-target*="login"],
    body.dpep-mobile-auth-v4.dpep-auth-mode-register-v4 [aria-controls*="login"] {
        display: none !important;
    }

    body.dpep-mobile-auth-v4.dpep-auth-mode-login-v4 #register-form-tab,
    body.dpep-mobile-auth-v4.dpep-auth-mode-login-v4 .register-form-tab {
        display: none !important;
    }

    body.dpep-mobile-auth-v4.dpep-auth-mode-register-v4 #login-form-tab,
    body.dpep-mobile-auth-v4.dpep-auth-mode-register-v4 .login-form-tab {
        display: none !important;
    }

    body.dpep-mobile-auth-v4 .dpep-auth-switch-link-v4 {
        display: block !important;
        margin: 12px auto 0 !important;
        text-align: center !important;
        color: #6b4d34 !important;
        font-size: 12px !important;
        line-height: 1.4 !important;
        font-weight: 800 !important;
        text-decoration: none !important;
    }

    body.dpep-mobile-auth-v4 .dpep-auth-switch-link-v4 span {
        text-decoration: underline !important;
        text-underline-offset: 3px !important;
    }

    /* Le sélecteur de type de compte repasse en natif sur mobile */
    body.dpep-mobile-auth-v4 .dpep-native-role-select-v4 {
        display: block !important;
        width: 100% !important;
        height: 46px !important;
        min-height: 46px !important;
        padding: 0 14px !important;
        border-radius: 12px !important;
        border: 1px solid rgba(64, 48, 35, .16) !important;
        background: #6b4d34 !important;
        color: #fff !important;
        font-size: 13px !important;
        font-weight: 800 !important;
        box-sizing: border-box !important;
        appearance: auto !important;
        -webkit-appearance: menulist !important;
    }

    body.dpep-mobile-auth-v4 .dpep-native-role-select-v4 option {
        color: #222 !important;
        background: #fff !important;
    }

    body.dpep-mobile-auth-v4 .dpep-role-native-wrap-v4 .bootstrap-select,
    body.dpep-mobile-auth-v4 .dpep-role-native-wrap-v4 .dropdown.bootstrap-select,
    body.dpep-mobile-auth-v4 .dpep-role-native-wrap-v4 > .dropdown,
    body.dpep-mobile-auth-v4 .dpep-role-native-wrap-v4 button.dropdown-toggle {
        display: none !important;
    }

    body.dpep-mobile-auth-v4 .dpep-role-native-wrap-v4 select[name="role"] {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: static !important;
    }

    /* reCAPTCHA responsive */
    body.dpep-mobile-auth-v4 .captcha_wrapper,
    body.dpep-mobile-auth-v4 .houzez-grecaptcha-v2,
    body.dpep-mobile-auth-v4 .houzez_google_reCaptcha {
        width: 100% !important;
        max-width: 100% !important;
        overflow: visible !important;
        display: flex !important;
        justify-content: center !important;
    }

    body.dpep-mobile-auth-v4 .houzez_google_reCaptcha > div {
        transform: scale(.86) !important;
        transform-origin: top center !important;
        margin-left: auto !important;
        margin-right: auto !important;
        max-width: 304px !important;
    }

    body.dpep-mobile-auth-v4 .captcha_wrapper {
        min-height: 76px !important;
        margin-bottom: 8px !important;
    }

    body.dpep-mobile-auth-v4 iframe[title="reCAPTCHA"] {
        max-width: 304px !important;
    }

    /* évite les découpes des menus/formulaires */
    body.dpep-mobile-auth-v4 .tab-content,
    body.dpep-mobile-auth-v4 .tab-pane,
    body.dpep-mobile-auth-v4 .login-register-form-wrap,
    body.dpep-mobile-auth-v4 .login-register-wrap,
    body.dpep-mobile-auth-v4 .dpep-auth-card {
        overflow: visible !important;
    }

    body.dpep-mobile-auth-v4 form,
    body.dpep-mobile-auth-v4 .form-group,
    body.dpep-mobile-auth-v4 .form-group-field,
    body.dpep-mobile-auth-v4 input,
    body.dpep-mobile-auth-v4 select,
    body.dpep-mobile-auth-v4 button,
    body.dpep-mobile-auth-v4 .btn {
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
}

@media (max-width: 380px) {
    body.dpep-mobile-auth-v4 .houzez_google_reCaptcha > div {
        transform: scale(.80) !important;
    }

    body.dpep-mobile-auth-v4 .captcha_wrapper {
        min-height: 70px !important;
    }
}

/* =====================================================
   DPEP Mobile V5 — Auth mobile propre
===================================================== */

@media (max-width: 991px) {
    /*
      Connexion : on supprime visuellement l'onglet Inscription du haut.
      L'utilisateur passe par le lien clair en bas.
    */
    body.dpep-mobile-auth-v5.dpep-auth-mode-login-v4 .dpep-auth-tab-register-v5,
    body.dpep-mobile-auth-v5.dpep-auth-mode-login-v4 .register-link,
    body.dpep-mobile-auth-v5.dpep-auth-mode-login-v4 .login-register-tabs .register-link,
    body.dpep-mobile-auth-v5.dpep-auth-mode-login-v4 .login-register-tabs a.dpep-register-tab-v5,
    body.dpep-mobile-auth-v5.dpep-auth-mode-login-v4 .login-register-tabs button.dpep-register-tab-v5 {
        display: none !important;
    }

    /*
      Inscription : on supprime visuellement l'onglet Connexion du haut.
      L'utilisateur repasse par le lien clair en bas.
    */
    body.dpep-mobile-auth-v5.dpep-auth-mode-register-v4 .dpep-auth-tab-login-v5,
    body.dpep-mobile-auth-v5.dpep-auth-mode-register-v4 .login-link,
    body.dpep-mobile-auth-v5.dpep-auth-mode-register-v4 .login-register-tabs .login-link,
    body.dpep-mobile-auth-v5.dpep-auth-mode-register-v4 .login-register-tabs a.dpep-login-tab-v5,
    body.dpep-mobile-auth-v5.dpep-auth-mode-register-v4 .login-register-tabs button.dpep-login-tab-v5 {
        display: none !important;
    }

    body.dpep-mobile-auth-v5 .login-register-tabs,
    body.dpep-mobile-auth-v5 .nav-tabs {
        display: flex !important;
        justify-content: center !important;
        width: 100% !important;
    }

    body.dpep-mobile-auth-v5 .login-register-tabs li,
    body.dpep-mobile-auth-v5 .nav-tabs li {
        flex: 0 0 auto !important;
    }

    body.dpep-mobile-auth-v5.dpep-auth-mode-login-v4 .login-register-tabs li:not(.register-link),
    body.dpep-mobile-auth-v5.dpep-auth-mode-register-v4 .login-register-tabs li:not(.login-link) {
        margin-left: auto !important;
        margin-right: auto !important;
    }

    /* Sélecteur de type de compte : texte visible et style propre */
    body.dpep-mobile-auth-v5 .dpep-native-role-select-v4,
    body.dpep-mobile-auth-v5 select[name="role"].dpep-native-role-select-v4 {
        display: block !important;
        width: 100% !important;
        height: 48px !important;
        min-height: 48px !important;
        padding: 0 38px 0 14px !important;
        border-radius: 14px !important;
        border: 1px solid rgba(107, 77, 52, .22) !important;
        background-color: #6b4d34 !important;
        color: #ffffff !important;
        font-size: 12px !important;
        font-weight: 900 !important;
        line-height: 48px !important;
        text-indent: 0 !important;
        text-align: left !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        appearance: auto !important;
        -webkit-appearance: menulist !important;
        opacity: 1 !important;
        visibility: visible !important;
    }

    body.dpep-mobile-auth-v5 .dpep-native-role-select-v4 option {
        color: #222 !important;
        background: #fff !important;
        font-size: 13px !important;
    }

    body.dpep-mobile-auth-v5 .dpep-role-native-wrap-v4::before {
        content: "Type de compte" !important;
        display: block !important;
        margin: 0 0 6px 2px !important;
        color: rgba(47, 37, 29, .65) !important;
        font-size: 11px !important;
        font-weight: 800 !important;
    }

    /* reCAPTCHA : largeur Google native 304px, donc réduction plus forte */
    body.dpep-mobile-auth-v5 .captcha_wrapper,
    body.dpep-mobile-auth-v5 .houzez-grecaptcha-v2 {
        width: 238px !important;
        max-width: 238px !important;
        min-height: 66px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        overflow: visible !important;
        display: block !important;
    }

    body.dpep-mobile-auth-v5 .houzez_google_reCaptcha {
        width: 304px !important;
        max-width: 304px !important;
        transform: scale(.78) !important;
        transform-origin: top left !important;
        margin: 0 !important;
        display: block !important;
    }

    body.dpep-mobile-auth-v5 .houzez_google_reCaptcha > div {
        transform: none !important;
        width: 304px !important;
        max-width: 304px !important;
        margin: 0 !important;
    }

    body.dpep-mobile-auth-v5 iframe[title="reCAPTCHA"] {
        width: 304px !important;
        max-width: 304px !important;
    }

    body.dpep-mobile-auth-v5 .btn-login,
    body.dpep-mobile-auth-v5 .btn-register,
    body.dpep-mobile-auth-v5 button[type="submit"],
    body.dpep-mobile-auth-v5 input[type="submit"] {
        margin-top: 4px !important;
    }
}

@media (max-width: 380px) {
    body.dpep-mobile-auth-v5 .captcha_wrapper,
    body.dpep-mobile-auth-v5 .houzez-grecaptcha-v2 {
        width: 219px !important;
        max-width: 219px !important;
        min-height: 61px !important;
    }

    body.dpep-mobile-auth-v5 .houzez_google_reCaptcha {
        transform: scale(.72) !important;
    }
}

/* =====================================================
   DPEP Mobile V6 — Auth remember/select fixes
===================================================== */

@media (max-width: 991px) {
    /*
      Connexion : évite le chevauchement entre "Se souvenir de moi"
      et "Mot de passe oublié ?" sur les petits écrans.
    */
    body.dpep-mobile-auth-v6.dpep-auth-mode-login-v4 .form-tools {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 8px !important;
        align-items: start !important;
        justify-items: stretch !important;
        width: 100% !important;
        margin: 12px 0 12px !important;
    }

    body.dpep-mobile-auth-v6.dpep-auth-mode-login-v4 .form-tools .control,
    body.dpep-mobile-auth-v6.dpep-auth-mode-login-v4 .form-tools label,
    body.dpep-mobile-auth-v6.dpep-auth-mode-login-v4 .form-tools a,
    body.dpep-mobile-auth-v6.dpep-auth-mode-login-v4 .form-tools .forgot-password,
    body.dpep-mobile-auth-v6.dpep-auth-mode-login-v4 .form-tools .forgot-password-text {
        position: static !important;
        float: none !important;
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        text-align: left !important;
        white-space: normal !important;
        line-height: 1.35 !important;
    }

    body.dpep-mobile-auth-v6.dpep-auth-mode-login-v4 .form-tools .control {
        display: flex !important;
        align-items: flex-start !important;
        min-height: 22px !important;
        padding-left: 26px !important;
    }

    body.dpep-mobile-auth-v6.dpep-auth-mode-login-v4 .form-tools .control__indicator {
        top: 1px !important;
        left: 0 !important;
    }

    body.dpep-mobile-auth-v6.dpep-auth-mode-login-v4 .form-tools a {
        color: #6b4d34 !important;
        font-weight: 800 !important;
        text-align: center !important;
    }

    /*
      Inscription : nouveau select natif V6 cliquable.
      Il est créé par JS hors du wrapper bootstrap-select pour éviter l'overlay.
    */
    body.dpep-mobile-auth-v6 .dpep-role-native-wrapper-v6 {
        width: 100% !important;
        margin: 0 0 12px !important;
        display: block !important;
        position: relative !important;
        z-index: 5 !important;
    }

    body.dpep-mobile-auth-v6 .dpep-role-native-label-v6 {
        display: block !important;
        margin: 0 0 6px 2px !important;
        color: rgba(47, 37, 29, .65) !important;
        font-size: 11px !important;
        font-weight: 800 !important;
        line-height: 1.2 !important;
    }

    body.dpep-mobile-auth-v6 .dpep-role-native-select-v6 {
        display: block !important;
        width: 100% !important;
        height: 48px !important;
        min-height: 48px !important;
        padding: 0 38px 0 14px !important;
        border-radius: 14px !important;
        border: 1px solid rgba(107, 77, 52, .22) !important;
        background-color: #6b4d34 !important;
        color: #ffffff !important;
        font-size: 12px !important;
        font-weight: 900 !important;
        line-height: 48px !important;
        appearance: menulist !important;
        -webkit-appearance: menulist !important;
        box-sizing: border-box !important;
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
        position: relative !important;
        z-index: 10 !important;
    }

    body.dpep-mobile-auth-v6 .dpep-role-native-select-v6 option {
        color: #222 !important;
        background: #fff !important;
        font-size: 14px !important;
        font-weight: 500 !important;
    }

    body.dpep-mobile-auth-v6 .dpep-role-original-hidden-v6 {
        position: absolute !important;
        left: -9999px !important;
        width: 1px !important;
        height: 1px !important;
        overflow: hidden !important;
        opacity: 0 !important;
        pointer-events: none !important;
    }

    body.dpep-mobile-auth-v6 .dpep-role-original-hidden-v6 + .dropdown.bootstrap-select,
    body.dpep-mobile-auth-v6 .dpep-role-original-hidden-v6 ~ .dropdown.bootstrap-select {
        display: none !important;
        pointer-events: none !important;
    }

    /*
      Annule les règles trop agressives V4/V5 qui pouvaient rendre le select non cliquable.
    */
    body.dpep-mobile-auth-v6 .dpep-role-native-wrap-v4 .bootstrap-select,
    body.dpep-mobile-auth-v6 .dpep-role-native-wrap-v4 .dropdown.bootstrap-select,
    body.dpep-mobile-auth-v6 .dpep-role-native-wrap-v4 > .dropdown,
    body.dpep-mobile-auth-v6 .dpep-role-native-wrap-v4 button.dropdown-toggle {
        pointer-events: none !important;
    }

    /*
      reCAPTCHA : un peu plus compact et centré pour éviter le dépassement bas/droite.
    */
    body.dpep-mobile-auth-v6 .captcha_wrapper,
    body.dpep-mobile-auth-v6 .houzez-grecaptcha-v2 {
        width: 224px !important;
        max-width: 224px !important;
        min-height: 62px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        overflow: visible !important;
    }

    body.dpep-mobile-auth-v6 .houzez_google_reCaptcha {
        width: 304px !important;
        max-width: 304px !important;
        transform: scale(.735) !important;
        transform-origin: top left !important;
        margin: 0 !important;
    }

    body.dpep-mobile-auth-v6 .houzez_google_reCaptcha > div {
        transform: none !important;
        width: 304px !important;
        max-width: 304px !important;
    }
}

@media (max-width: 380px) {
    body.dpep-mobile-auth-v6 .captcha_wrapper,
    body.dpep-mobile-auth-v6 .houzez-grecaptcha-v2 {
        width: 210px !important;
        max-width: 210px !important;
        min-height: 58px !important;
    }

    body.dpep-mobile-auth-v6 .houzez_google_reCaptcha {
        transform: scale(.69) !important;
    }
}

/* =====================================================
   DPEP Mobile V7 — Auth select clean
===================================================== */

@media (max-width: 991px) {
    /*
      Inscription : on garde uniquement le nouveau select natif V7.
      L'ancien select Bootstrap et les wrappers résiduels sont totalement masqués.
    */
    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-role-native-wrapper-v6 {
        display: none !important;
    }

    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-role-native-wrap-v4::before {
        content: none !important;
        display: none !important;
    }

    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-role-native-wrapper-v7 {
        display: block !important;
        width: 100% !important;
        margin: 0 0 14px !important;
        position: relative !important;
        z-index: 50 !important;
    }

    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-role-native-label-v7 {
        display: block !important;
        margin: 0 0 7px 2px !important;
        color: rgba(47, 37, 29, .72) !important;
        font-size: 11px !important;
        line-height: 1.2 !important;
        font-weight: 900 !important;
    }

    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-role-native-select-v7 {
        display: block !important;
        width: 100% !important;
        height: 48px !important;
        min-height: 48px !important;
        padding: 0 38px 0 14px !important;
        border-radius: 14px !important;
        border: 1px solid rgba(107, 77, 52, .22) !important;
        background-color: #6b4d34 !important;
        color: #fff !important;
        font-size: 12px !important;
        font-weight: 900 !important;
        line-height: 48px !important;
        appearance: menulist !important;
        -webkit-appearance: menulist !important;
        box-sizing: border-box !important;
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
        position: relative !important;
        z-index: 60 !important;
    }

    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-role-native-select-v7 option {
        color: #222 !important;
        background: #fff !important;
        font-size: 14px !important;
        font-weight: 500 !important;
    }

    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 select[name="role"]:not(.dpep-role-native-select-v7),
    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-role-original-hidden-v7 {
        position: absolute !important;
        left: -99999px !important;
        top: auto !important;
        width: 1px !important;
        height: 1px !important;
        min-height: 1px !important;
        opacity: 0 !important;
        visibility: hidden !important;
        overflow: hidden !important;
        pointer-events: none !important;
        display: block !important;
    }

    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dropdown.bootstrap-select:has(select[name="role"]),
    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .bootstrap-select:has(select[name="role"]) {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        min-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        pointer-events: none !important;
    }

    /*
      Fallback pour navigateurs sans :has().
      Les classes sont ajoutées par JS.
    */
    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-hide-bootstrap-role-v7,
    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-hide-bootstrap-role-v7.dropdown,
    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-hide-bootstrap-role-v7.bootstrap-select {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        min-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        pointer-events: none !important;
    }

    body.dpep-mobile-auth-v7.dpep-auth-mode-register-v4 .dpep-role-form-group-v7 {
        position: relative !important;
        z-index: 40 !important;
    }
}

/* =====================================================
   DPEP Mobile V8 — Auth select stable
===================================================== */

@media (max-width: 991px) {
    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-native-wrapper-v6,
    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-native-wrapper-v7,
    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-native-wrap-v4::before {
        display: none !important;
        content: none !important;
    }

    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-stable-wrapper-v8 {
        display: block !important;
        width: 100% !important;
        margin: 0 0 14px !important;
        position: relative !important;
        z-index: 80 !important;
    }

    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-stable-label-v8 {
        display: block !important;
        margin: 0 0 7px 2px !important;
        color: rgba(47, 37, 29, .72) !important;
        font-size: 11px !important;
        line-height: 1.2 !important;
        font-weight: 900 !important;
    }

    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-stable-select-v8 {
        display: block !important;
        width: 100% !important;
        height: 48px !important;
        min-height: 48px !important;
        padding: 0 38px 0 14px !important;
        border-radius: 14px !important;
        border: 1px solid rgba(107, 77, 52, .22) !important;
        background-color: #6b4d34 !important;
        color: #fff !important;
        font-size: 12px !important;
        font-weight: 900 !important;
        line-height: 48px !important;
        appearance: menulist !important;
        -webkit-appearance: menulist !important;
        box-sizing: border-box !important;
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
        position: relative !important;
        z-index: 90 !important;
    }

    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-stable-select-v8 option {
        color: #222 !important;
        background: #fff !important;
        font-size: 14px !important;
        font-weight: 500 !important;
    }

    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-hidden-v8,
    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 select[name="role"]:not(.dpep-role-stable-select-v8) {
        position: absolute !important;
        left: -99999px !important;
        top: auto !important;
        width: 1px !important;
        height: 1px !important;
        min-height: 1px !important;
        opacity: 0 !important;
        visibility: hidden !important;
        overflow: hidden !important;
        pointer-events: none !important;
        display: block !important;
    }

    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-bootstrap-hidden-v8,
    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dropdown.bootstrap-select.dpep-role-bootstrap-hidden-v8,
    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .bootstrap-select.dpep-role-bootstrap-hidden-v8 {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        min-height: 0 !important;
        max-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        pointer-events: none !important;
    }

    body.dpep-mobile-auth-v8.dpep-auth-mode-register-v4 .dpep-role-form-group-v8 {
        position: relative !important;
        z-index: 70 !important;
    }
}

/* =====================================================
   DPEP Mobile V9 — Auth select final
   Important : règles volontairement indépendantes de body.dpep-mobile-auth-v8,
   car le cache peut charger le JS V8 sans la classe body V8.
===================================================== */

@media (max-width: 991px) {
    /*
      Masque le doublon Bootstrap directement par classe.
      Cette classe existe bien dans ton HTML :
      .dpep-role-bootstrap-hidden-v8
    */
    .dpep-role-bootstrap-hidden-v8,
    .dropdown.bootstrap-select.form-control.dpep-role-bootstrap-hidden-v8,
    .bootstrap-select.dpep-role-bootstrap-hidden-v8,
    .form-group .dpep-role-bootstrap-hidden-v8,
    .form-group.mt-2 .dpep-role-bootstrap-hidden-v8 {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        min-height: 0 !important;
        max-height: 0 !important;
        width: 0 !important;
        max-width: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        border: 0 !important;
        overflow: hidden !important;
        pointer-events: none !important;
        position: absolute !important;
        left: -99999px !important;
        top: auto !important;
    }

    /*
      Masque aussi le vrai select Houzez original, mais le laisse présent
      pour que l'inscription fonctionne côté Houzez.
    */
    select[name="role"].dpep-role-hidden-v8,
    select[name="role"].dpep-role-hidden-v7,
    select[name="role"].dpep-role-original-hidden-v7,
    select[name="role"].dpep-role-original-hidden-v6 {
        position: absolute !important;
        left: -99999px !important;
        top: auto !important;
        width: 1px !important;
        height: 1px !important;
        min-height: 1px !important;
        max-height: 1px !important;
        opacity: 0 !important;
        visibility: hidden !important;
        overflow: hidden !important;
        pointer-events: none !important;
        display: block !important;
    }

    /*
      Un seul champ visible : le select natif V8.
    */
    .dpep-role-stable-wrapper-v8 {
        display: block !important;
        width: 100% !important;
        margin: 0 0 14px !important;
        position: relative !important;
        z-index: 80 !important;
    }

    .dpep-role-stable-label-v8 {
        display: block !important;
        margin: 0 0 7px 2px !important;
        color: rgba(47, 37, 29, .72) !important;
        font-size: 11px !important;
        line-height: 1.2 !important;
        font-weight: 900 !important;
    }

    .dpep-role-stable-select-v8 {
        display: block !important;
        width: 100% !important;
        height: 48px !important;
        min-height: 48px !important;
        padding: 0 38px 0 14px !important;
        border-radius: 14px !important;
        border: 1px solid rgba(107, 77, 52, .22) !important;
        background-color: #6b4d34 !important;
        color: #fff !important;
        font-size: 12px !important;
        font-weight: 900 !important;
        line-height: 48px !important;
        appearance: menulist !important;
        -webkit-appearance: menulist !important;
        box-sizing: border-box !important;
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
        position: relative !important;
        z-index: 90 !important;
    }

    .dpep-role-stable-select-v8 option {
        color: #222 !important;
        background: #fff !important;
        font-size: 14px !important;
        font-weight: 500 !important;
    }

    /*
      Nettoyage des anciens champs générés par V6/V7 si le cache les laisse.
    */
    .dpep-role-native-wrapper-v6,
    .dpep-role-native-wrapper-v7 {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        max-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        pointer-events: none !important;
    }

    .dpep-role-native-wrap-v4::before {
        content: none !important;
        display: none !important;
    }
}

