/* Espace Rédaction — blocs de mise en page (articles + éditeur)
   Couleurs : réglage du plugin, sinon couleurs globales Elementor. */
.er-chapo,
.er-encadre,
.er-citation,
.er-cols,
.er-cta,
.er-sep {
	--er-a: var(--er-accent, var(--e-global-color-primary, #8C1D5B));
	--er-t: var(--e-global-color-text, #2F232A);
}

/* Introduction */
p.er-chapo {
	font-size: 1.22em;
	line-height: 1.55;
	color: var(--er-t);
	margin: 0 0 1.6em;
}

/* Encadré */
.er-encadre {
	background: color-mix(in srgb, var(--er-a) 7%, #fff);
	border-left: 4px solid var(--er-a);
	border-radius: 0 14px 14px 0;
	padding: 1.2em 1.4em;
	margin: 2em 0;
}
.er-encadre > :first-child { margin-top: 0; }
.er-encadre > :last-child { margin-bottom: 0; }

/* Citation */
blockquote.er-citation {
	border: 0;
	margin: 2.2em 0;
	padding: 0 0 0 1.2em;
	border-left: 3px solid var(--er-a);
	font-family: var(--e-global-typography-primary-font-family, inherit);
	font-size: 1.45em;
	line-height: 1.35;
	font-style: italic;
	color: var(--er-t);
	background: none;
	quotes: none;
}
blockquote.er-citation::before,
blockquote.er-citation::after { content: none; }
blockquote.er-citation p { margin: 0; }

/* Colonnes */
.er-cols {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 2em;
	margin: 2em 0;
	align-items: start;
}
.er-cols--media { grid-template-columns: 5fr 6fr; align-items: center; }
.er-col > :first-child { margin-top: 0; }
.er-col > :last-child { margin-bottom: 0; }
.er-col img { width: 100%; height: auto; border-radius: 14px; display: block; }
@media (max-width: 700px) {
	.er-cols, .er-cols--media { grid-template-columns: 1fr; gap: 1.2em; }
}

/* Bouton */
p.er-cta { margin: 2em 0; }
a.er-bouton,
a.er-bouton:visited {
	display: inline-block;
	background: var(--er-a);
	color: #fff !important;
	text-decoration: none !important;
	padding: .8em 1.6em;
	border-radius: 999px;
	font-weight: 600;
	line-height: 1.2;
	transition: transform .15s, box-shadow .15s;
}
a.er-bouton:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 18px color-mix(in srgb, var(--er-a) 30%, transparent);
}

/* Séparateur */
hr.er-sep {
	border: 0;
	height: 1px;
	background: color-mix(in srgb, var(--er-t) 18%, transparent);
	width: 120px;
	margin: 2.6em auto;
}

/* Dans l'éditeur : repères visuels des blocs */
body.er-content .er-cols { outline: 1px dashed color-mix(in srgb, var(--er-t) 20%, transparent); outline-offset: 8px; }
body.er-content .er-col { outline: 1px dashed color-mix(in srgb, var(--er-t) 12%, transparent); outline-offset: 2px; min-height: 2em; }

/* ---------- Sections (constructeur) ---------- */
.er-chapo { font-size: 1.22em; line-height: 1.55; margin: 0 0 1.6em; }
.er-chapo p { margin: 0 0 .6em; }
.er-chapo p:last-child { margin-bottom: 0; }
figure.er-figure { margin: 2em 0; }
figure.er-figure img { width: 100%; height: auto; border-radius: 14px; display: block; }
figure.er-figure--wide { margin-left: -6%; margin-right: -6%; }
figure.er-figure figcaption { font-size: .85em; opacity: .7; margin-top: .6em; text-align: center; }
.er-cols--img-right .er-col--img { order: 2; }
.er-cols--media { grid-template-columns: 5fr 6fr; }
.er-cols--img-right.er-cols--media { grid-template-columns: 6fr 5fr; }
.er-col--img img { width: 100%; height: auto; border-radius: 14px; display: block; }
.er-encadre--fort { background: var(--er-accent, var(--e-global-color-primary, #8C1D5B)); color: #fff; border-left-color: transparent; border-radius: 14px; }
.er-encadre--fort a { color: #fff; }
.er-encadre-titre { margin-top: 0; }
blockquote.er-citation cite { display: block; margin-top: .8em; font-size: .6em; font-style: normal; letter-spacing: .02em; opacity: .75; }
p.er-cta--center { text-align: center; }
.er-audio, .er-video { margin: 2em 0; }
.er-media-titre { margin: 0 0 .6em; }
.er-embed iframe { width: 100% !important; max-width: 100%; border: 0; border-radius: 12px; }
.er-video iframe { aspect-ratio: 16 / 9; height: auto !important; }
.er-space { height: 3em; }
@media (max-width: 700px) {
	figure.er-figure--wide { margin-left: 0; margin-right: 0; }
	.er-cols--img-right .er-col--img { order: 0; }
	.er-cols--media, .er-cols--img-right.er-cols--media { grid-template-columns: 1fr; }
}
/* Lecteur audio : protégé des styles de boutons du thème */
body .er-audio .mejs-container button,
body .er-audio .mejs-container button:hover,
body .er-audio .mejs-container button:focus { background-color: transparent !important; border: 0 !important; padding: 0 !important; margin: 10px 6px !important; box-shadow: none !important; border-radius: 0 !important; min-height: 0 !important; width: 20px !important; height: 20px !important; }
body .er-audio .mejs-container { border-radius: 10px; overflow: hidden; }

/* Titres des articles : police des titres du site (réglage « Police des titres », sinon Titre H1 Elementor),
   tailles des styles globaux Titre H2 / Titre H3 quand ils existent. */
.er-article h2,
.er-article h3,
.er-article h4,
.er-chapo h3 {
	font-family: var(--er-titres, var(--e-global-typography-primary-font-family, inherit)) !important;
	letter-spacing: normal;
	text-transform: none;
}
.er-article h2 {
	font-size: var(--e-global-typography-secondary-font-size, 1.9em);
	font-weight: var(--e-global-typography-secondary-font-weight, 500);
	line-height: var(--e-global-typography-secondary-line-height, 1.2);
	margin: 1.6em 0 .6em;
}
.er-article h3 {
	font-size: var(--e-global-typography-text-font-size, 1.35em);
	font-weight: var(--e-global-typography-text-font-weight, 500);
	line-height: var(--e-global-typography-text-line-height, 1.25);
	margin: 1.4em 0 .5em;
}
.er-article .er-col > h3:first-child { margin-top: 0; }

/* Formats d'image (recadrage sans déformation) */
img.er-ratio { width: 100% !important; height: auto !important; object-fit: cover !important; object-position: var(--er-fx, 50%) var(--er-fy, 50%) !important; }
img.er-ratio--16-9 { aspect-ratio: 16 / 9 !important; }
img.er-ratio--3-2 { aspect-ratio: 3 / 2 !important; }
img.er-ratio--1-1 { aspect-ratio: 1 / 1 !important; }
img.er-ratio--4-5 { aspect-ratio: 4 / 5 !important; }
.er-fx-0 { --er-fx: 0%; } .er-fy-0 { --er-fy: 0%; }
.er-fx-10 { --er-fx: 10%; } .er-fy-10 { --er-fy: 10%; }
.er-fx-20 { --er-fx: 20%; } .er-fy-20 { --er-fy: 20%; }
.er-fx-30 { --er-fx: 30%; } .er-fy-30 { --er-fy: 30%; }
.er-fx-40 { --er-fx: 40%; } .er-fy-40 { --er-fy: 40%; }
.er-fx-50 { --er-fx: 50%; } .er-fy-50 { --er-fy: 50%; }
.er-fx-60 { --er-fx: 60%; } .er-fy-60 { --er-fy: 60%; }
.er-fx-70 { --er-fx: 70%; } .er-fy-70 { --er-fy: 70%; }
.er-fx-80 { --er-fx: 80%; } .er-fy-80 { --er-fy: 80%; }
.er-fx-90 { --er-fx: 90%; } .er-fy-90 { --er-fy: 90%; }
.er-fx-100 { --er-fx: 100%; } .er-fy-100 { --er-fy: 100%; }
