/* FB Page Builder – styles publics (aussi utilisés dans l'aperçu de l'éditeur) */

.fbpb-page,
.fbpb-page *,
.fbpb-page *::before,
.fbpb-page *::after { box-sizing: border-box; }

.fbpb-fullwidth { width: 100vw; margin-left: calc(50% - 50vw); }
body.fbpb-has-fullwidth { overflow-x: clip; }

body.fbpb-hide-title .entry-title,
body.fbpb-hide-title .page-title,
body.fbpb-hide-title .post-title,
body.fbpb-hide-title h1.wp-block-post-title { display: none; }

/* Si la page contient le widget « Image mise en avant », on masque celle affichée par le thème (doublon). */
body.fbpb-has-featured .single-thumbnail,
body.fbpb-has-featured .post-thumbnail,
body.fbpb-has-featured .entry-thumbnail,
body.fbpb-has-featured .wp-block-post-featured-image { display: none; }

/* Sections */
.fbpb-section { padding: 0; position: relative; display: flex; flex-direction: column; width: 100%; }
.fbpb-container { position: relative; z-index: 1; width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 max(15px, calc(var(--fbpb-gap, 20px) / 2)); }
.fbpb-section.fbpb-full > .fbpb-container { max-width: none; padding: 0 calc(var(--fbpb-gap, 20px) / 2); }

/* Colonnes : empilées sur mobile, côte à côte dès 768px */
.fbpb-row { display: flex; flex-wrap: wrap; margin: 0 calc(var(--fbpb-gap, 20px) / -2); }
.fbpb-column { display: flex; width: 100%; padding: 0 calc(var(--fbpb-gap, 20px) / 2); }
.fbpb-column-inner { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
@media (min-width: 768px) {
	.fbpb-column { flex: 1 1 0%; min-width: 0; width: auto; }
}

.fbpb-widget { width: 100%; }
.fbpb-widget:not(:last-child) { margin-bottom: 20px; }

/* Titre / texte */
.fbpb-heading { margin: 0; }
.fbpb-heading a { color: inherit; text-decoration: none; }
.fbpb-text > :first-child { margin-top: 0; }
.fbpb-text > :last-child { margin-bottom: 0; }

/* Image */
.fbpb-image img { max-width: 100%; height: auto; display: inline-block; vertical-align: top; }

/* Bouton */
.fbpb-button {
	display: inline-block; text-decoration: none; font-weight: 600; line-height: 1.2; text-align: center; cursor: pointer;
	border: 2px solid var(--fbpb-btn, #2563eb); background: var(--fbpb-btn, #2563eb); color: var(--fbpb-btn-text, #fff);
	border-radius: 6px; transition: filter .15s, background .15s, color .15s;
}
.fbpb-btn-sm { padding: 8px 16px; font-size: 14px; }
.fbpb-btn-md { padding: 12px 24px; font-size: 16px; }
.fbpb-btn-lg { padding: 16px 32px; font-size: 18px; }
.fbpb-button:hover { filter: brightness(.92); color: var(--fbpb-btn-text, #fff); }
.fbpb-btn-outline { background: transparent; color: var(--fbpb-btn, #2563eb); }
.fbpb-btn-outline:hover { background: var(--fbpb-btn, #2563eb); color: var(--fbpb-btn-text, #fff); filter: none; }

/* Séparateur / espace */
.fbpb-spacer { height: 40px; }
.fbpb-divider-wrap { display: flex; }
.fbpb-divider {
	width: 100%; margin: 0; height: 0; border: 0;
	border-top: var(--fbpb-div-weight, 1px) var(--fbpb-div-style, solid) var(--fbpb-div-color, #d1d5db);
}

/* Vidéo / carte */
.fbpb-video { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #000; }
.fbpb-video iframe, .fbpb-video video { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }
.fbpb-map iframe { display: block; width: 100%; height: 350px; border: 0; }

/* Boîte à icône */
.fbpb-iconbox { text-align: center; }
.fbpb-icon {
	display: inline-flex; align-items: center; justify-content: center; margin-bottom: 14px;
	font-size: var(--fbpb-icon-size, 32px); width: 2em; height: 2em; line-height: 1;
	border-radius: 50%; background: var(--fbpb-icon-bg, #eff6ff);
}
.fbpb-icon-title { margin: 0 0 8px; font-size: 1.25rem; }
.fbpb-icon-desc { margin: 0; }

/* Témoignage */
.fbpb-testimonial { text-align: center; }
.fbpb-quote { margin: 0 0 16px; padding: 0; border: 0; font-size: 1.15rem; font-style: italic; line-height: 1.6; }
.fbpb-quote::before { content: "\201C"; }
.fbpb-quote::after { content: "\201D"; }
.fbpb-person { display: inline-flex; align-items: center; gap: 12px; text-align: left; }
.fbpb-avatar { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; }
.fbpb-name, .fbpb-role { display: block; }
.fbpb-role { font-size: .875em; opacity: .7; }

/* Logo du site */
.fbpb-logo-wrap { display: flex; align-items: center; }
.fbpb-logo { display: inline-flex; align-items: center; text-decoration: none; color: inherit; }
.fbpb-logo img { max-height: 48px; width: auto; display: block; }
.fbpb-logo-text { font-size: 1.5rem; font-weight: 700; line-height: 1.1; }

/* Menu de navigation */
.fbpb-nav { display: flex; align-items: center; }
.fbpb-menu { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; list-style: none; margin: 0; padding: 0; }
.fbpb-menu li { position: relative; margin: 0; }
.fbpb-menu a { color: inherit; text-decoration: none; }
.fbpb-menu a:hover { text-decoration: underline; }
.fbpb-menu .sub-menu {
	display: none; position: absolute; left: 0; top: 100%; z-index: 60; min-width: 190px; margin: 0; padding: 8px 0;
	list-style: none; background: #fff; border-radius: 6px; box-shadow: 0 8px 24px rgba(0, 0, 0, .15);
}
.fbpb-menu li:hover > .sub-menu, .fbpb-menu li:focus-within > .sub-menu { display: block; }
.fbpb-menu .sub-menu a { display: block; padding: 8px 16px; color: #111827; white-space: nowrap; }
.fbpb-menu .sub-menu a:hover { background: #f3f4f6; text-decoration: none; }
.fbpb-nav-toggle {
	display: none; align-items: center; justify-content: center; flex-direction: column; gap: 5px; width: 42px; height: 42px;
	padding: 0; background: transparent; border: 0; cursor: pointer; color: inherit;
}
.fbpb-nav-toggle span { display: block; width: 24px; height: 2px; background: currentColor; border-radius: 2px; }
@media (max-width: 767px) {
	.fbpb-nav--collapse { flex-wrap: wrap; justify-content: flex-end !important; }
	.fbpb-nav--collapse .fbpb-nav-toggle { display: inline-flex; }
	/* Le menu ouvert se déploie sous l'en-tête, sur toute sa largeur */
	.fbpb-nav--collapse .fbpb-menu {
		display: none; flex-direction: column !important; align-items: stretch; gap: 0 !important;
		position: absolute; left: 0; right: 0; top: 100%; z-index: 60; padding: 6px 20px 10px;
		background: var(--fbpb-nav-bg, #fff); box-shadow: 0 14px 24px rgba(0, 0, 0, .14);
	}
	.fbpb-nav--collapse.is-open .fbpb-menu { display: flex; }
	.fbpb-nav--collapse .fbpb-menu > li { width: 100%; padding: 10px 0; border-bottom: 1px solid rgba(128, 128, 128, .2); }
	.fbpb-nav--collapse .fbpb-menu .sub-menu { display: block; position: static; box-shadow: none; background: transparent; padding: 4px 0 0 14px; }
	.fbpb-nav--collapse .fbpb-menu .sub-menu a { color: inherit; padding: 6px 0; }
}

/* Visibilité selon l'appareil */
@media (min-width: 1025px) { .fbpb-hide-d { display: none !important; } }
@media (min-width: 768px) and (max-width: 1024px) { .fbpb-hide-t { display: none !important; } }
@media (max-width: 767px) { .fbpb-hide-m { display: none !important; } }
