/* MCV Happyness – Actualités & FAQ
   Les couleurs reprennent la palette globale d'Astra (Personnaliser > Global > Couleurs). */
.mcv-actu {
	--mcv-primary: var(--ast-global-color-0, #e4572e);
	--mcv-primary-dark: var(--ast-global-color-1, #b8401d);
	--mcv-heading: var(--ast-global-color-2, #1d1d27);
	--mcv-text: var(--ast-global-color-3, #4a4a57);
	--mcv-bg: #fff;
	--mcv-soft: var(--ast-global-color-5, #f6f4f1);
	--mcv-border: rgba(20, 20, 40, .1);
	--mcv-radius: 18px;
	--mcv-shadow: 0 1px 2px rgba(20, 20, 40, .05), 0 8px 24px rgba(20, 20, 40, .06);
	--mcv-shadow-hover: 0 2px 4px rgba(20, 20, 40, .06), 0 18px 40px rgba(20, 20, 40, .12);
	--mcv-max: 1200px;
	color: var(--mcv-text);
	width: 100%;
	box-sizing: border-box;
}
.mcv-actu *, .mcv-actu *::before, .mcv-actu *::after { box-sizing: border-box; }

/* Astra : le contenu des templates occupe toute la largeur */
.mcv-single, .mcv-archive { flex: 1 1 100%; max-width: 100%; }
.single-post .site-content > .ast-container:has(> .mcv-single) { max-width: 100%; }

/* ---------- Éléments communs ---------- */
.mcv-eyebrow {
	display: inline-block;
	font-size: .78rem;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--mcv-primary);
	margin-bottom: .6rem;
}
.mcv-eyebrow--light { color: rgba(255, 255, 255, .85); }

.mcv-badge {
	display: inline-flex;
	align-items: center;
	padding: .3em .8em;
	border-radius: 999px;
	background: color-mix(in srgb, var(--mcv-primary) 12%, transparent);
	color: var(--mcv-primary-dark);
	font-size: .75rem;
	font-weight: 700;
	line-height: 1.4;
	text-decoration: none;
}
.mcv-badge--light {
	background: rgba(255, 255, 255, .18);
	color: #fff;
	backdrop-filter: blur(6px);
	border: 1px solid rgba(255, 255, 255, .3);
}
a.mcv-badge--light:hover { background: rgba(255, 255, 255, .3); color: #fff; }

.mcv-btn {
	display: inline-flex;
	align-items: center;
	gap: .5em;
	padding: .8em 1.4em;
	border: 0;
	border-radius: 999px;
	background: var(--mcv-primary);
	color: #fff;
	font-weight: 600;
	font-size: .95rem;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: background .2s, transform .2s, box-shadow .2s;
	white-space: nowrap;
}
.mcv-btn:hover, .mcv-btn:focus-visible { background: var(--mcv-primary-dark); color: #fff; transform: translateY(-1px); }
.mcv-btn--ghost {
	background: transparent;
	color: var(--mcv-heading);
	box-shadow: inset 0 0 0 1.5px var(--mcv-border);
}
.mcv-btn--ghost:hover, .mcv-btn--ghost:focus-visible {
	background: var(--mcv-heading);
	color: #fff;
	box-shadow: none;
}
.mcv-arrow { display: inline-block; transition: transform .2s; }
.mcv-btn:hover .mcv-arrow { transform: translateX(3px); }

/* ---------- Hero ---------- */
.mcv-actu .mcv-hero {
	position: relative;
	width: 100vw;
	margin-left: calc(50% - 50vw);
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	color: #fff;
	background-color: var(--mcv-heading);
	background-image:
		radial-gradient(1200px 500px at 85% -10%, color-mix(in srgb, var(--mcv-primary) 55%, transparent), transparent 60%),
		linear-gradient(135deg, var(--mcv-heading), color-mix(in srgb, var(--mcv-heading) 70%, var(--mcv-primary)));
	overflow: hidden;
	isolation: isolate;
}
.mcv-actu .mcv-hero.has-image { background-image: var(--mcv-hero-img); background-size: cover; background-position: center; }
.mcv-actu .mcv-hero.has-image::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: rgba(10, 10, 20, .55);
}
.mcv-actu .mcv-hero__inner {
	width: 100%;
	max-width: var(--mcv-max);
	margin: 0 auto;
	padding: clamp(3.5rem, 8vw, 6rem) 1.25rem;
	text-align: center;
}
.mcv-actu .mcv-hero--single { min-height: clamp(420px, 68vh, 640px); }
.mcv-actu .mcv-hero--single .mcv-hero__inner { max-width: calc(900px + 2.5rem); }
.mcv-actu .mcv-hero--archive { min-height: clamp(360px, 50vh, 480px); text-align: center; }
.mcv-actu .mcv-hero__title {
	color: #fff;
	font-size: clamp(2rem, 4.6vw, 3.4rem);
	line-height: 1.12;
	margin: .9rem 0 .8rem;
	text-wrap: balance;
	text-shadow: 0 2px 20px rgba(0, 0, 0, .2);
}
.mcv-actu .mcv-hero__sep { margin: 0 .5rem; }
.mcv-actu .mcv-hero__meta { margin: 0; opacity: .85; font-size: .95rem; }
.mcv-actu .mcv-hero__intro { max-width: 620px; margin: 0 auto; font-size: 1.1rem; opacity: .88; }

.mcv-breadcrumb { display: flex; justify-content: center; flex-wrap: wrap; gap: .5rem; font-size: .85rem; margin-bottom: 1.25rem; opacity: .85; }
.mcv-breadcrumb a { color: #fff; text-decoration: none; }
.mcv-breadcrumb a:hover { text-decoration: underline; }

/* ---------- Recherche ---------- */
.mcv-search {
	position: relative;
	display: flex;
	align-items: center;
	gap: .5rem;
	max-width: 620px;
	margin: 0 auto;
	padding: .4rem;
	border-radius: 999px;
	background: #fff;
	box-shadow: 0 12px 40px rgba(0, 0, 0, .25);
}
.mcv-search__icon { position: absolute; left: 1.1rem; color: #8a8a97; pointer-events: none; }
.mcv-search input[type=search] {
	flex: 1;
	min-width: 0;
	border: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
	padding: .75rem .75rem .75rem 2.8rem !important;
	font-size: 1rem;
	color: var(--mcv-heading);
	outline: none;
}
.mcv-search input[type=search]::-webkit-search-cancel-button { cursor: pointer; }

/* ---------- Corps de la page Actualités ---------- */
.mcv-archive__body, .mcv-related, .mcv-latest {
	max-width: var(--mcv-max);
	margin: 0 auto;
	padding: 3rem 1.25rem 4rem;
}
.mcv-archive__body { transition: opacity .2s; }
.mcv-archive__body.is-loading { opacity: .45; pointer-events: none; }

.mcv-toolbar {
	position: sticky;
	top: 0;
	z-index: 5;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 1rem 0;
	margin-bottom: .5rem;
	background: color-mix(in srgb, #fff 92%, transparent);
	backdrop-filter: blur(8px);
	border-bottom: 1px solid var(--mcv-border);
}
.admin-bar .mcv-toolbar { top: 32px; }

.mcv-chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.mcv-chip {
	display: inline-flex;
	align-items: center;
	gap: .45em;
	padding: .5em 1em;
	border-radius: 999px;
	background: var(--mcv-soft);
	color: var(--mcv-heading);
	font-size: .9rem;
	font-weight: 600;
	text-decoration: none;
	transition: background .2s, color .2s;
}
.mcv-chip:hover { background: color-mix(in srgb, var(--mcv-primary) 14%, #fff); color: var(--mcv-heading); }
.mcv-chip.is-active { background: var(--mcv-heading); color: #fff; }
.mcv-chip__count {
	min-width: 1.5em;
	padding: 0 .4em;
	border-radius: 999px;
	background: rgba(0, 0, 0, .07);
	font-size: .75rem;
	text-align: center;
}
.mcv-chip.is-active .mcv-chip__count { background: rgba(255, 255, 255, .2); }

.mcv-sort { display: flex; align-items: center; gap: .5rem; font-size: .9rem; margin: 0; }
.mcv-sort label { font-weight: 600; color: var(--mcv-heading); white-space: nowrap; margin: 0; }
.mcv-home-latest { background: var(--ast-global-color-5, #faf8f5); }
.mcv-home-latest .mcv-latest { padding-top: clamp(3rem, 7vw, 5rem); padding-bottom: clamp(3rem, 7vw, 5rem); }
.mcv-sort select {
	padding: .5em 2em .5em .9em;
	border: 1px solid var(--mcv-border);
	border-radius: 10px;
	background-color: #fff;
	font-size: .9rem;
	cursor: pointer;
}

.mcv-count { margin: 1rem 0 1.75rem; font-size: .95rem; color: #6b6b78; }
.mcv-count a { color: var(--mcv-primary); font-weight: 600; }

/* ---------- Cartes ---------- */
.mcv-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
	gap: 1.75rem;
}
.mcv-card {
	position: relative;
	display: flex;
	flex-direction: column;
	border-radius: var(--mcv-radius);
	background: var(--mcv-bg);
	box-shadow: var(--mcv-shadow);
	overflow: hidden;
	transition: transform .25s, box-shadow .25s;
}
.mcv-card:hover, .mcv-card:focus-within { transform: translateY(-4px); box-shadow: var(--mcv-shadow-hover); }
.mcv-card__media { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--mcv-soft); }
.mcv-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s; }
.mcv-card:hover .mcv-card__media img { transform: scale(1.05); }
.mcv-card__placeholder {
	display: block;
	width: 100%;
	height: 100%;
	background: linear-gradient(135deg, color-mix(in srgb, var(--mcv-primary) 25%, #fff), color-mix(in srgb, var(--mcv-primary) 60%, var(--mcv-heading)));
}
.mcv-card__body { display: flex; flex-direction: column; flex: 1; padding: 1.4rem 1.5rem 1.6rem; }
.mcv-card__meta { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; margin-bottom: .8rem; font-size: .8rem; color: #7a7a87; }
.mcv-card__info { display: inline-flex; align-items: center; white-space: nowrap; }
.mcv-card__date { font-weight: 600; color: var(--mcv-heading); }
.mcv-card__date + .mcv-card__read::before { content: "·"; margin: 0 .45rem; }
.mcv-card__title { font-size: 1.2rem; line-height: 1.35; margin: 0 0 .6rem; }
.mcv-card__title a { color: var(--mcv-heading); text-decoration: none; }
/* Toute la carte est cliquable */
.mcv-card__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.mcv-card__title a:focus-visible { outline: none; }
.mcv-card:focus-within { outline: 3px solid color-mix(in srgb, var(--mcv-primary) 50%, transparent); outline-offset: 2px; }
.mcv-card__excerpt { margin: 0 0 1.2rem; font-size: .95rem; line-height: 1.6; flex: 1; }
.mcv-card__more { font-weight: 700; font-size: .9rem; color: var(--mcv-primary); }
.mcv-card:hover .mcv-arrow { transform: translateX(4px); }

/* Article mis en avant */
.mcv-card--featured { margin-bottom: 1.75rem; }
@media (min-width: 860px) {
	.mcv-card--featured { flex-direction: row; min-height: 380px; }
	.mcv-card--featured .mcv-card__media { flex: 0 0 58%; aspect-ratio: auto; }
	.mcv-card--featured .mcv-card__body { justify-content: center; padding: 2.5rem; }
}
.mcv-card--featured .mcv-card__title { font-size: clamp(1.4rem, 2.4vw, 1.9rem); }
.mcv-card--featured .mcv-card__excerpt { flex: 0; font-size: 1.02rem; }

/* ---------- Pagination ---------- */
.mcv-pagination { display: flex; justify-content: center; flex-wrap: wrap; gap: .4rem; margin-top: 3rem; }
.mcv-pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.6rem;
	height: 2.6rem;
	padding: 0 .9rem;
	border-radius: 999px;
	background: var(--mcv-soft);
	color: var(--mcv-heading);
	font-weight: 600;
	text-decoration: none;
}
.mcv-pagination a.page-numbers:hover { background: color-mix(in srgb, var(--mcv-primary) 15%, #fff); }
.mcv-pagination .current { background: var(--mcv-primary); color: #fff; }
.mcv-pagination .dots { background: none; }

.mcv-empty { text-align: center; padding: 4rem 1rem; border-radius: var(--mcv-radius); background: var(--mcv-soft); }
.mcv-empty__title { font-size: 1.25rem; font-weight: 700; color: var(--mcv-heading); margin-bottom: .3rem; }
.mcv-empty .mcv-btn { margin-top: 1rem; }

/* ---------- Section « Dernières actus » (accueil) ---------- */
.mcv-latest__head {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 1rem 2rem;
	margin-bottom: 2.25rem;
}
.mcv-latest__title { margin: 0; font-size: clamp(1.7rem, 3vw, 2.4rem); line-height: 1.15; color: var(--mcv-heading); }
.mcv-latest__subtitle { margin: .6rem 0 0; max-width: 560px; }

/* ---------- Article ---------- */
.mcv-progress { position: fixed; top: 0; left: 0; right: 0; height: 4px; z-index: 9999; pointer-events: none; }
.admin-bar .mcv-progress { top: 32px; }
.mcv-progress span { display: block; height: 100%; background: var(--mcv-primary); transform: scaleX(0); transform-origin: 0 50%; }

.mcv-actu .mcv-article { max-width: calc(900px + 2.5rem); margin: 0 auto; padding: clamp(2.5rem, 6vw, 4rem) 1.25rem 2rem; font-size: 1.08rem; line-height: 1.8; }
.mcv-article__lead { font-size: 1.25rem; line-height: 1.6; color: var(--mcv-heading); font-weight: 500; margin-bottom: 2rem; }
.mcv-article__content h2 { font-size: 1.7rem; margin: 2.5rem 0 1rem; line-height: 1.25; }
.mcv-article__content h3 { font-size: 1.3rem; margin: 2rem 0 .8rem; }
.mcv-article__content img { border-radius: 14px; height: auto; }
.mcv-article__content blockquote {
	margin: 2rem 0;
	padding: 1.2rem 1.5rem;
	border-left: 4px solid var(--mcv-primary);
	border-radius: 0 12px 12px 0;
	background: var(--mcv-soft);
	font-style: italic;
}
.mcv-article__content a { color: var(--mcv-primary); }
.mcv-article__footer {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	margin-top: 3rem;
	padding-top: 2rem;
	border-top: 1px solid var(--mcv-border);
}
.mcv-share { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; font-size: .9rem; }
.mcv-share span { font-weight: 700; color: var(--mcv-heading); margin-right: .25rem; }
.mcv-share a, .mcv-share button {
	padding: .45em .9em;
	border: 0;
	border-radius: 999px;
	background: var(--mcv-soft);
	color: var(--mcv-heading);
	font-size: .85rem;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
	line-height: 1.4;
}
.mcv-share a:hover, .mcv-share button:hover { background: var(--mcv-heading); color: #fff; }
.mcv-related { border-top: 1px solid var(--mcv-border); }

/* Masque les éléments Astra résiduels sur les articles */
.single-post .ast-single-post-order, .single-post .entry-meta, .single-post .post-navigation, .single-post #comments { display: none !important; }

/* ---------- FAQ articles — accordéon (structure Kynova, couleurs MCV) ---------- */
.article-faq {
	--faq-accent: var(--ast-global-color-0, #b08d3c);
	--faq-heading: var(--ast-global-color-2, #3a2a1a);
	--faq-text: var(--ast-global-color-3, #555);
	margin: 3em 0 1.5em;
	padding-top: 2.5em;
	border-top: 1px solid rgba(20, 20, 40, .1);
}
.article-faq > h2 { margin: 0 0 1em; }
.article-faq .faq-item {
	border: 1px solid #e8e2d9;
	border-radius: 12px;
	margin-bottom: 10px;
	background: #fff;
	overflow: hidden;
	transition: border-color .2s ease, box-shadow .2s ease;
}
.article-faq .faq-item:hover { border-color: var(--faq-accent); }
.article-faq .faq-item.is-open {
	border-color: var(--faq-accent);
	box-shadow: 0 4px 14px color-mix(in srgb, var(--faq-accent) 16%, transparent);
}
.article-faq .faq-item > h3 {
	position: relative;
	margin: 0;
	padding: 16px 52px 16px 20px;
	font-size: 1.05em;
	line-height: 1.4;
	color: var(--faq-heading);
	cursor: pointer;
	user-select: none;
	transition: background-color .2s ease, color .2s ease;
}
.article-faq .faq-item > h3:hover,
.article-faq .faq-item.is-open > h3 {
	color: var(--faq-accent);
	background-color: color-mix(in srgb, var(--faq-accent) 7%, #fff);
}
.article-faq .faq-item > h3:focus-visible { outline: 2px solid var(--faq-accent); outline-offset: -2px; }
.article-faq .faq-item > h3::after {
	content: '';
	position: absolute;
	right: 20px;
	top: 50%;
	width: 10px;
	height: 10px;
	border-right: 2px solid var(--faq-accent);
	border-bottom: 2px solid var(--faq-accent);
	transform: translateY(-70%) rotate(45deg);
	transition: transform .25s ease;
}
.article-faq .faq-item.is-open > h3::after { transform: translateY(-20%) rotate(-135deg); }
.article-faq .faq-answer {
	display: none;
	padding: 14px 20px 18px;
	color: var(--faq-text);
	line-height: 1.65;
	border-top: 1px solid #f0ebe3;
}
.article-faq .faq-item.is-open .faq-answer { display: block; }
.article-faq .faq-answer p:first-child { margin-top: 0; }
.article-faq .faq-answer p:last-child { margin-bottom: 0; }

@media (max-width: 600px) {
	.mcv-search .mcv-btn { padding: .8em 1em; }
	.mcv-toolbar { position: static; }
	.mcv-chips { flex-wrap: nowrap; overflow-x: auto; padding-bottom: .25rem; scrollbar-width: none; width: 100%; }
	.mcv-chip { flex: 0 0 auto; }
}
@media (prefers-reduced-motion: reduce) {
	.mcv-actu * { transition: none !important; }
}
