/* LeoDynamics – Pop-up Atelier Vision Board */
.ldvbp {
	--ldvbp-accent: #b5523b;
	--ldvbp-ink: #2a1f1c;
	--ldvbp-muted: #6b5d58;
	--ldvbp-bg: #fffaf6;
	position: fixed;
	inset: 0;
	z-index: 999999; /* au-dessus des en-têtes Elementor */
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	font-family: inherit;
	line-height: 1.5;
	box-sizing: border-box;
}
.ldvbp *, .ldvbp *::before, .ldvbp *::after { box-sizing: border-box; }
.ldvbp[hidden] { display: none; }

.ldvbp__overlay {
	position: absolute;
	inset: 0;
	background: rgba(30, 20, 17, .6);
	opacity: 0;
	transition: opacity .25s ease;
}

.ldvbp__dialog {
	position: relative;
	width: 100%;
	max-width: min(460px, 100%);
	max-height: calc(100vh - 32px);
	max-height: calc(100dvh - 32px);
	overflow-y: auto;
	background: var(--ldvbp-bg);
	color: var(--ldvbp-ink);
	border-radius: 16px;
	box-shadow: 0 24px 60px rgba(0, 0, 0, .25);
	opacity: 0;
	transform: translateY(16px) scale(.98);
	transition: opacity .25s ease, transform .25s ease;
	outline: none;
}

.ldvbp.is-visible .ldvbp__overlay { opacity: 1; }
.ldvbp.is-visible .ldvbp__dialog { opacity: 1; transform: none; }

.ldvbp__close {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 2;
	display: grid;
	place-items: center;
	width: 38px;
	height: 38px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, .92);
	color: var(--ldvbp-ink);
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
}
.ldvbp__close:hover { background: #fff; }

.ldvbp__media { aspect-ratio: 12 / 7; overflow: hidden; border-radius: 16px 16px 0 0; }
.ldvbp__img { display: block; width: 100%; height: 100%; object-fit: cover; }

.ldvbp__body { padding: clamp(20px, 4vw, 28px) clamp(18px, 4vw, 28px) 22px; text-align: center; }

.ldvbp__badge {
	display: inline-block;
	margin: 0 0 12px;
	padding: 4px 12px;
	border-radius: 999px;
	background: color-mix(in srgb, var(--ldvbp-accent) 12%, transparent);
	color: var(--ldvbp-accent);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: .06em;
	text-transform: uppercase;
}

.ldvbp .ldvbp__title {
	margin: 0 0 10px;
	color: var(--ldvbp-ink);
	font-size: clamp(24px, 5vw, 30px);
	line-height: 1.15;
}

.ldvbp__desc { margin: 0 0 18px; color: var(--ldvbp-muted); font-size: 16px; }

.ldvbp__meta {
	display: grid;
	gap: 8px;
	margin: 0 0 22px;
	padding: 14px 16px;
	list-style: none;
	border-radius: 12px;
	background: #fff;
	border: 1px solid color-mix(in srgb, var(--ldvbp-accent) 18%, transparent);
	text-align: left;
	font-size: 15px;
}
.ldvbp__meta li { display: flex; align-items: center; gap: 10px; margin: 0; overflow-wrap: anywhere; }
.ldvbp__meta svg { flex: none; color: var(--ldvbp-accent); }

.ldvbp a.ldvbp__cta {
	display: block;
	padding: 14px 20px;
	border-radius: 999px;
	background: var(--ldvbp-accent);
	color: #fff;
	font-weight: 600;
	font-size: 16px;
	text-decoration: none;
	transition: filter .2s ease, transform .2s ease;
}
.ldvbp a.ldvbp__cta:hover { filter: brightness(.92); transform: translateY(-1px); color: #fff; }

.ldvbp__dismiss {
	margin-top: 12px;
	padding: 6px 10px;
	border: 0;
	background: none;
	color: var(--ldvbp-muted);
	font: inherit;
	font-size: 14px;
	text-decoration: underline;
	cursor: pointer;
}

.ldvbp a:focus-visible,
.ldvbp button:focus-visible {
	outline: 3px solid var(--ldvbp-accent);
	outline-offset: 3px;
}

html.ldvbp-lock, html.ldvbp-lock body { overflow: hidden; }

/* ---------- Responsive ---------- */

/* Tablette */
@media (max-width: 782px) {
	.ldvbp__dialog { max-width: min(440px, 100%); }
}

/* Mobile : panneau qui monte du bas de l'écran */
@media (max-width: 560px) {
	.ldvbp { align-items: flex-end; padding: 0; }
	.ldvbp__dialog {
		max-width: none;
		border-radius: 18px 18px 0 0;
		max-height: 90vh;
		max-height: 90dvh;
		transform: translateY(40px);
	}
	.ldvbp__media { border-radius: 18px 18px 0 0; aspect-ratio: 16 / 7; }
	.ldvbp__body { padding: 22px 18px calc(16px + env(safe-area-inset-bottom, 0px)); }
	.ldvbp__desc { font-size: 15px; margin-bottom: 14px; }
	.ldvbp__meta { font-size: 14px; padding: 12px 14px; margin-bottom: 16px; }
	.ldvbp a.ldvbp__cta { padding: 13px 18px; }
}

/* Très petits écrans (iPhone SE, 320 px) */
@media (max-width: 360px) {
	.ldvbp__body { padding-left: 14px; padding-right: 14px; }
	.ldvbp__badge { font-size: 11px; letter-spacing: .04em; }
	.ldvbp .ldvbp__title { font-size: 22px; }
	.ldvbp__meta li { align-items: flex-start; }
}

/* Écrans peu hauts (mobile à l'horizontale) : on retire l'image et on compacte */
@media (max-height: 520px) {
	.ldvbp { align-items: center; padding: 10px; }
	.ldvbp__dialog { max-width: min(560px, 100%); max-height: calc(100vh - 20px); max-height: calc(100dvh - 20px); border-radius: 14px; transform: translateY(16px); }
	.ldvbp__media { display: none; }
	.ldvbp__body { padding: 16px 20px 12px; }
	.ldvbp__badge { margin-bottom: 6px; }
	.ldvbp .ldvbp__title { font-size: 22px; margin-bottom: 6px; }
	.ldvbp__desc { font-size: 14px; margin-bottom: 10px; }
	.ldvbp__meta { grid-template-columns: 1fr 1fr; margin-bottom: 12px; padding: 10px 12px; font-size: 13px; }
	.ldvbp a.ldvbp__cta { padding: 10px 16px; font-size: 15px; }
	.ldvbp__dismiss { margin-top: 6px; }
}

@media (prefers-reduced-motion: reduce) {
	.ldvbp__overlay, .ldvbp__dialog, .ldvbp a.ldvbp__cta { transition: none; }
}
