/* MonBesoin.fr — V5.2.1 | Correctifs d'affichage sur le portail uniquement.
   Anti-interferences : styles de thème/extension et conflits de tailles/line-height.
   Aucun changement des comptes, formulaires, pages ni données. */
body.monbesoin-site-page {
  --mb-text: #27213f;
  --mb-muted: #605976;
  --mb-accent: #7651df;
  font-size: 16px;
  line-height: 1.6;
  color: var(--mb-text);
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body.monbesoin-site-page *,
body.monbesoin-site-page *::before,
body.monbesoin-site-page *::after { box-sizing: border-box; }
body.monbesoin-site-page .wrap {
  width: 100%;
  max-width: 1240px;
  margin-inline: auto;
  padding-inline: clamp(20px, 3.1vw, 48px);
}
body.monbesoin-site-page main,
body.monbesoin-site-page main section,
body.monbesoin-site-page .hero-copy,
body.monbesoin-site-page .section-heading > div,
body.monbesoin-site-page .center-heading,
body.monbesoin-site-page .pro-banner-copy { min-width: 0; }
body.monbesoin-site-page button,
body.monbesoin-site-page input,
body.monbesoin-site-page textarea,
body.monbesoin-site-page select { max-width: 100%; }

/* Remise à l'échelle des titres : le précédent letter-spacing en pixels
   rapprochait excessivement les lettres quand un thème réduisait le h2. */
body.monbesoin-site-page .hero h1 {
  font-size: clamp(39px, 4.25vw, 64px) !important;
  font-weight: 800 !important;
  line-height: 1.13 !important;
  letter-spacing: -.045em !important;
  margin: 24px 0 22px !important;
  text-wrap: balance;
  overflow-wrap: normal;
  color: #252039 !important;
}
body.monbesoin-site-page .section h2,
body.monbesoin-site-page .mbv4-orientation h2 {
  font-size: clamp(32px, 3.1vw, 47px) !important;
  line-height: 1.2 !important;
  letter-spacing: -.035em !important;
  font-weight: 800 !important;
  margin: 18px 0 18px !important;
  text-wrap: balance;
  overflow-wrap: normal;
  color: #29223e !important;
}
body.monbesoin-site-page .section h2 span,
body.monbesoin-site-page .center-heading h2 span,
body.monbesoin-site-page .section-heading h2 span { color: #7954df !important; }
body.monbesoin-site-page .section .kicker,
body.monbesoin-site-page .section .pro-kicker,
body.monbesoin-site-page .mbv4-orientation .kicker {
  font-size: 14px !important;
  line-height: 1.55 !important;
  font-weight: 800 !important;
  letter-spacing: .11em !important;
  text-transform: uppercase;
}
body.monbesoin-site-page .section p,
body.monbesoin-site-page .section-heading p,
body.monbesoin-site-page .center-heading p,
body.monbesoin-site-page .mbv4-orientation-head p {
  line-height: 1.72 !important;
}
body.monbesoin-site-page .section-heading p,
body.monbesoin-site-page .center-heading p,
body.monbesoin-site-page .mbv4-orientation-head p {
  color: var(--mb-muted) !important;
  font-size: clamp(14px, 1.18vw, 16px) !important;
  max-width: 600px;
  margin: 0;
}
body.monbesoin-site-page .center-heading p { margin-inline: auto; }
body.monbesoin-site-page .section { padding-block: clamp(64px, 6.4vw, 104px); }
body.monbesoin-site-page .section-heading { margin-bottom: clamp(28px, 3.5vw, 46px); }
body.monbesoin-site-page .center-heading { max-width: 790px; margin: 0 auto clamp(34px, 4.4vw, 60px); }
body.monbesoin-site-page .section-heading h2 br,
body.monbesoin-site-page .center-heading h2 br { display: block; content: ''; }
body.monbesoin-site-page .split-heading { align-items: flex-end; gap: 30px; }
body.monbesoin-site-page .split-heading > div { max-width: 820px; }

/* Accueil et zone de recherche. */
body.monbesoin-site-page .hero {
  padding-top: clamp(58px, 6vw, 90px);
  padding-bottom: clamp(30px, 4vw, 54px);
}
body.monbesoin-site-page .hero-grid {
  grid-template-columns: minmax(0, 1.06fr) minmax(0, .94fr);
  gap: clamp(26px, 3.5vw, 56px);
  min-height: 0;
}
body.monbesoin-site-page .hero-copy { padding-bottom: 0; }
body.monbesoin-site-page .hero-lead {
  font-size: clamp(15px, 1.2vw, 17px) !important;
  line-height: 1.75 !important;
  color: #625b74 !important;
}
body.monbesoin-site-page .hero-buttons {
  gap: 12px;
  margin: 26px 0 28px;
  align-items: stretch;
}
body.monbesoin-site-page .hero-buttons .btn { min-height: 54px; font-size: 14px; }
body.monbesoin-site-page .hero-social-proof { flex-wrap: wrap; gap: 14px; }
body.monbesoin-site-page .hero-metric {
  min-width: 118px;
  height: 58px;
  gap: 9px;
  padding: 9px 14px;
  flex-shrink: 0;
}
body.monbesoin-site-page .hero-metric strong { font-size: 27px !important; line-height: 1 !important; letter-spacing: -.025em !important; }
body.monbesoin-site-page .hero-metric span {
  font-size: 14px !important;
  line-height: 1.2 !important;
  max-width: none;
  white-space: nowrap;
}
body.monbesoin-site-page .hero-social-proof > div:not(.hero-metric) strong {
  font-size: 14px !important;
  line-height: 1.4 !important;
}
body.monbesoin-site-page .hero-social-proof > div:not(.hero-metric) small {
  font-size: 14px !important;
  line-height: 1.5 !important;
}
body.monbesoin-site-page .hero-search-wrap { margin-top: 20px; }
body.monbesoin-site-page .hero-search { width: min(100%, 900px); }
body.monbesoin-site-page .hero-search input {
  min-width: 0;
  width: 100%;
  font-size: 15px;
  line-height: 1.5;
}

/* Cartes, parcours et univers : espacements stables et textes lisibles. */
body.monbesoin-site-page .mbv4-orientation-grid,
body.monbesoin-site-page .steps-grid,
body.monbesoin-site-page .worlds-grid { gap: clamp(16px, 2vw, 26px); }
body.monbesoin-site-page .mbv4-path { min-width: 0; }
body.monbesoin-site-page .mbv4-path strong { line-height: 1.3 !important; letter-spacing: -.02em !important; }
body.monbesoin-site-page .mbv4-path em { font-size: 14px !important; line-height: 1.5 !important; }
body.monbesoin-site-page .service-card h3,
body.monbesoin-site-page .photo-service-card h3,
body.monbesoin-site-page .step-card h3 {
  font-size: clamp(16px, 1.35vw, 19px) !important;
  line-height: 1.35 !important;
  letter-spacing: -.018em !important;
  overflow-wrap: break-word;
}
body.monbesoin-site-page .photo-service-card p,
body.monbesoin-site-page .step-card p {
  font-size: 14px !important;
  line-height: 1.6 !important;
  color: #665d78 !important;
}
body.monbesoin-site-page .service-card-cta { font-size: 14px !important; }
body.monbesoin-site-page .service-card-copy { min-width: 0; }
body.monbesoin-site-page .services-grid { gap: clamp(15px, 1.7vw, 23px); }
body.monbesoin-site-page .photo-service-card { min-height: 330px; }
body.monbesoin-site-page .services-grid .service-more { min-height: 330px; }

/* Bandeau partenaires : imposer le texte blanc sur le fond violet. */
body.monbesoin-site-page .pros-section .pro-banner {
  height: auto;
  min-height: 400px;
  padding: clamp(32px, 5vw, 68px);
  border-radius: 28px;
  align-items: center;
  overflow: hidden;
}
body.monbesoin-site-page .pros-section .pro-banner::after {
  background: linear-gradient(90deg, rgba(43,28,93,.98) 0%, rgba(54,35,113,.96) 43%, rgba(56,38,111,.68) 75%, rgba(50,34,102,.47) 100%);
}
body.monbesoin-site-page .pros-section .pro-banner-copy { z-index: 3; max-width: min(100%, 650px); }
body.monbesoin-site-page .pros-section .pro-banner h2,
body.monbesoin-site-page .pros-section .pro-banner h2 span {
  color: #fff !important;
  font-size: clamp(32px, 3.3vw, 47px) !important;
  line-height: 1.21 !important;
  letter-spacing: -.035em !important;
  font-weight: 800 !important;
  max-width: 620px;
  text-wrap: balance;
  margin: 22px 0 24px !important;
}
body.monbesoin-site-page .pros-section .pro-banner .pro-kicker { color: #e8dcff !important; }
body.monbesoin-site-page .pros-section .pro-banner p {
  color: #f2eaff !important;
  font-size: 15px !important;
  line-height: 1.7 !important;
  max-width: 570px;
  margin-bottom: 26px;
}
body.monbesoin-site-page .pros-section .pro-banner .btn-white {
  background: #fff !important;
  color: #6943cf !important;
  font-weight: 800;
}

/* Pied de page : contraste des titres, liens et marque. */
body.monbesoin-site-page .footer { color: #eeeaf8 !important; background: #25213f; }
body.monbesoin-site-page .footer-main { gap: clamp(24px, 3vw, 44px); }
body.monbesoin-site-page .footer .brand-word,
body.monbesoin-site-page .footer .footer-col h4 {
  color: #f8f6ff !important;
}
body.monbesoin-site-page .footer .brand-word { font-size: 21px !important; letter-spacing: -.045em !important; }
body.monbesoin-site-page .footer .brand-word span { color: #c9b1ff !important; }
body.monbesoin-site-page .footer .footer-col h4 {
  font-size: 14px !important;
  font-weight: 800 !important;
  line-height: 1.45 !important;
  margin: 4px 0 20px !important;
}
body.monbesoin-site-page .footer .footer-col a,
body.monbesoin-site-page .footer .footer-col button {
  color: #dcd5ef !important;
  font-size: 14px !important;
  line-height: 1.45 !important;
  text-decoration: none;
  border: 0;
  outline-offset: 4px;
}
body.monbesoin-site-page .footer .footer-col a:hover,
body.monbesoin-site-page .footer .footer-col button:hover { color: #fff !important; text-decoration: underline; }
body.monbesoin-site-page .footer .footer-brand p,
body.monbesoin-site-page .footer .footer-brand small { color: #d3cce3 !important; font-size: 14px !important; }
body.monbesoin-site-page .footer .footer-bottom { color: #c6bbd9 !important; font-size: 14px !important; }
body.monbesoin-site-page .footer .footer-bottom button {
  color: #e3d7f3 !important;
  font-size: 14px !important;
  padding: 4px 0;
  border: 0;
}
body.monbesoin-site-page .footer .footer-bottom>div { flex-wrap: wrap; gap: 12px 22px; }

/* Les différents formats d'écran doivent rester lisibles sans zoom. */
@media (max-width: 1100px) {
  body.monbesoin-site-page .hero-grid { gap: 20px; }
  body.monbesoin-site-page .services-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  body.monbesoin-site-page .footer-main { grid-template-columns: 1.4fr 1fr 1fr; }
  body.monbesoin-site-page .footer-brand { grid-column: 1; }
  body.monbesoin-site-page .footer-col:last-child { grid-column: 2 / 4; }
}
@media (max-width: 850px) {
  body.monbesoin-site-page .hero-grid { grid-template-columns: minmax(0,1fr); }
  body.monbesoin-site-page .hero-copy { max-width: 700px; }
  body.monbesoin-site-page .hero-art-photos { margin: 4px auto 0 !important; }
  body.monbesoin-site-page .services-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  body.monbesoin-site-page .mbv4-orientation-grid { grid-template-columns: 1fr; }
  body.monbesoin-site-page .split-heading { flex-direction: column; align-items: flex-start; }
  body.monbesoin-site-page .steps-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  body.monbesoin-site-page .worlds-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  body.monbesoin-site-page .pros-section .pro-banner-photo { width: 100%; opacity: .24; }
  body.monbesoin-site-page .pros-section .pro-banner::after { background: rgba(46,29,100,.85); }
  body.monbesoin-site-page .footer-main { grid-template-columns: 1fr 1fr; }
  body.monbesoin-site-page .footer-brand { grid-column: span 2; }
  body.monbesoin-site-page .footer-col:last-child { grid-column: auto; }
}
@media (max-width: 600px) {
  body.monbesoin-site-page .wrap { padding-inline: 20px; }
  body.monbesoin-site-page .hero h1 {
    font-size: clamp(34px, 8.9vw, 42px) !important;
    line-height: 1.18 !important;
    letter-spacing: -.035em !important;
    margin: 20px 0 16px !important;
  }
  body.monbesoin-site-page .section h2,
  body.monbesoin-site-page .mbv4-orientation h2 {
    font-size: clamp(28px, 7.2vw, 35px) !important;
    line-height: 1.22 !important;
    letter-spacing: -.032em !important;
    margin: 15px 0 !important;
  }
  body.monbesoin-site-page .section-heading h2 br,
  body.monbesoin-site-page .center-heading h2 br { display: block; content: ""; }
  body.monbesoin-site-page .section .kicker { font-size: 14px !important; letter-spacing: .09em !important; }
  body.monbesoin-site-page .section-heading p,
  body.monbesoin-site-page .center-heading p { font-size: 14px !important; }
  body.monbesoin-site-page .section { padding-block: 58px; }
  body.monbesoin-site-page .section-heading { margin-bottom: 27px; }
  body.monbesoin-site-page .hero { padding-top: 45px; padding-bottom: 35px; }
  body.monbesoin-site-page .hero-buttons { flex-direction: column; align-items: stretch; gap: 11px; margin: 23px 0; }
  body.monbesoin-site-page .hero-buttons .btn { width: 100%; white-space: normal; text-align: center; }
  body.monbesoin-site-page .hero-metric { min-width: 116px; }
  body.monbesoin-site-page .hero-search { gap: 9px; padding: 9px 10px 9px 14px; }
  body.monbesoin-site-page .hero-search input { font-size: 14px; }
  body.monbesoin-site-page .hero-social-proof { gap: 12px; }
  body.monbesoin-site-page .services-grid,
  body.monbesoin-site-page .steps-grid,
  body.monbesoin-site-page .worlds-grid { grid-template-columns: minmax(0,1fr); }
  body.monbesoin-site-page .photo-service-card,
  body.monbesoin-site-page .services-grid .service-more { min-height: 0; }
  body.monbesoin-site-page .service-photo-wrap { height: 192px; flex-basis: 192px; }
  body.monbesoin-site-page .service-tile > .service-card .service-card-copy { min-height: 150px; }
  body.monbesoin-site-page .photo-service-card p { min-height: 0; }
  body.monbesoin-site-page .pros-section .pro-banner { padding: 32px 25px; min-height: 0; border-radius: 22px; }
  body.monbesoin-site-page .pros-section .pro-banner h2 { font-size: clamp(28px, 7.2vw, 35px) !important; margin: 18px 0 !important; }
  body.monbesoin-site-page .pros-section .pro-banner p { font-size: 14px !important; }
  body.monbesoin-site-page .footer-main { grid-template-columns: minmax(0,1fr); padding: 48px 0 34px; gap: 30px; }
  body.monbesoin-site-page .footer-brand,
  body.monbesoin-site-page .footer-col:last-child { grid-column: auto; }
  body.monbesoin-site-page .footer .footer-col h4 { margin-bottom: 12px !important; }
  body.monbesoin-site-page .footer .footer-col a { margin-bottom: 12px; }
  body.monbesoin-site-page .footer-bottom { flex-direction: column; align-items: flex-start; gap: 13px; }
}
@media (max-width: 380px) {
  body.monbesoin-site-page .hero h1 { font-size: 32px !important; }
  body.monbesoin-site-page .section h2 { font-size: 27px !important; }
  body.monbesoin-site-page .hero-social-proof { align-items: flex-start; }
  body.monbesoin-site-page .hero-metric { height: 55px; }
  body.monbesoin-site-page .btn { white-space: normal; }
}
@media (prefers-reduced-motion: reduce) {
  body.monbesoin-site-page .hero-art-photos *,
  body.monbesoin-site-page .btn { animation: none !important; transition: none !important; }
}


/* V5.2.3 — Affichage du déclencheur Charlotte en présence d'une autre
   bulle de messagerie flottante en bas à droite (module tiers).
   On réserve un couloir à droite sans modifier ni masquer ce module. */
body.monbesoin-site-page .charlotte-launch {
  position: fixed !important;
  left: auto !important;
  right: calc(104px + env(safe-area-inset-right, 0px)) !important;
  bottom: calc(24px + env(safe-area-inset-bottom, 0px)) !important;
  box-sizing: border-box;
  width: 252px;
  max-width: min(252px, calc(100vw - 132px));
  min-height: 64px;
  padding: 10px 13px !important;
  display: grid !important;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 11px !important;
  background: #fff !important;
  border: 1px solid #e6def7 !important;
  border-radius: 17px !important;
  text-align: left;
  line-height: normal;
  box-shadow: 0 10px 30px rgba(42, 24, 78, .16);
  isolation: isolate;
}
body.monbesoin-site-page .charlotte-launch > .charlotte-avatar {
  width: 42px !important;
  height: 42px !important;
  min-width: 42px;
  display: grid !important;
  place-items: center;
  margin: 0;
  border-radius: 13px !important;
}
body.monbesoin-site-page .charlotte-launch > span:nth-child(2) {
  display: block !important;
  min-width: 0;
  width: 100%;
  margin: 0;
  text-align: left;
}
body.monbesoin-site-page .charlotte-launch b {
  display: block;
  color: #392e59 !important;
  font-size: 14px !important;
  font-weight: 750 !important;
  line-height: 1.35 !important;
  letter-spacing: 0 !important;
  white-space: normal !important;
  overflow-wrap: normal;
  margin: 0 0 3px !important;
}
body.monbesoin-site-page .charlotte-launch small {
  display: block;
  color: #76678d !important;
  font-size: 14px !important;
  line-height: 1.35 !important;
  letter-spacing: 0 !important;
  white-space: normal !important;
  margin: 0 !important;
}
body.monbesoin-site-page .charlotte-launch > .charlotte-arrow {
  display: none !important;
}
@media (max-width: 600px) {
  body.monbesoin-site-page .charlotte-launch {
    right: calc(92px + env(safe-area-inset-right, 0px)) !important;
    bottom: calc(15px + env(safe-area-inset-bottom, 0px)) !important;
    width: 56px !important;
    max-width: 56px !important;
    height: 56px !important;
    min-height: 56px !important;
    padding: 6px !important;
    border-radius: 50% !important;
    grid-template-columns: 1fr;
    gap: 0 !important;
    place-items: center;
  }
  body.monbesoin-site-page .charlotte-launch > .charlotte-avatar {
    width: 42px !important;
    height: 42px !important;
    min-width: 42px;
    border-radius: 50% !important;
  }
  body.monbesoin-site-page .charlotte-launch > span:nth-child(2),
  body.monbesoin-site-page .charlotte-launch > .charlotte-arrow {
    display: none !important;
  }
}
@media (max-width: 320px) {
  body.monbesoin-site-page .charlotte-launch {
    right: calc(84px + env(safe-area-inset-right, 0px)) !important;
  }
}

/* V5.2.4 — FAQ du site en production : liens directs vers espace et inscription. */
.mbsite-faq-actions{display:flex;flex-wrap:wrap;gap:10px;margin:16px 0 4px;align-items:center}
.mbsite-faq-actions .btn{min-height:42px;white-space:normal;text-align:center;line-height:1.35;font-size:14px;padding:11px 15px}
.faq-items details p strong{color:#4c4263;font-weight:800}
@media(max-width:420px){.mbsite-faq-actions{flex-direction:column;align-items:stretch}.mbsite-faq-actions .btn{width:100%}}

/* V5.2.9 — Charlotte et navigation mobile.
   Le menu de navigation reste prioritaire et aucun lien n'est recouvert.
   Hors ouverture du menu, placer Charlotte au-dessus de la zone de commandes
   flottantes en bas de l'ecran (autre module de chat / navigation mobile).
   La version de bureau n'est pas modifiee. */
@media (max-width: 850px) {
  body.monbesoin-site-page .site-header {
    z-index: 90;
  }
  body.monbesoin-site-page .mobile-nav.open {
    position: absolute;
    z-index: 2;
    max-height: calc(100dvh - 78px - env(safe-area-inset-bottom, 0px));
    overflow-y: auto;
    overscroll-behavior: contain;
    padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  }
  body.monbesoin-site-page .charlotte-launch {
    z-index: 35 !important;
  }
  /* JS garde la classe en synchronisation avec aria-expanded.
     :has() protege aussi l'affichage si un script tiers ouvre le menu. */
  body.monbesoin-site-page.mbsite-mobile-menu-open .charlotte-launch,
  body.monbesoin-site-page:has(#mobile-nav.open) .charlotte-launch {
    display: none !important;
    pointer-events: none !important;
  }
}
@media (max-width: 600px) {
  body.monbesoin-site-page .mobile-nav.open {
    max-height: calc(100dvh - 67px - env(safe-area-inset-bottom, 0px));
  }
  body.monbesoin-site-page .charlotte-launch {
    /* Au-dessus des boutons flottants / barre mobile (sans chevauchement). */
    right: calc(14px + env(safe-area-inset-right, 0px)) !important;
    bottom: calc(92px + env(safe-area-inset-bottom, 0px)) !important;
  }
}

/* V5.2.10 — espace membre mobile / chatbot independant.
 * La bulle de l'autre module de conversation ne doit pas passer par-dessus
 * la barre de navigation de l'espace membre. Ne rien modifier sur la vitrine. */
@media (max-width: 850px) {
  body.monbesoin-site-page.app-visible #app-shell {
    position: fixed !important;
    z-index: 2147483000 !important;
    isolation: isolate;
  }
  /* Les dialogues du portail doivent rester accessibles au-dessus de l'espace. */
  body.monbesoin-site-page.app-visible .modal-backdrop {
    z-index: 2147483001 !important;
  }
  body.monbesoin-site-page.app-visible .charlotte-launch {
    display: none !important;
    pointer-events: none !important;
  }
  body.monbesoin-site-page.app-visible #app-mobile-tabbar {
    z-index: 10 !important;
    padding-bottom: max(8px, env(safe-area-inset-bottom, 0px));
    touch-action: manipulation;
  }
  /* Repli si un widget tiers impose lui-meme le z-index maximal. La logique
     de masquage ne s'active que lorsque ce widget chevauche 'Profil'. */
  body.monbesoin-site-page.app-visible [data-mbsite-suppressed-floating="1"] {
    visibility: hidden !important;
    pointer-events: none !important;
  }
}
