/* Centre Sahélien pour la Biodiversité : page « Agenda » v3 (13 nov. 2026), grille de sessions filtrable, préfixe .csb-ag-
   Chargé après csb.css et csb-hero-photo.css. Les apparitions (data-rv) viennent de assets/js/csb-anime.js ; filtres, panneau, statuts : assets/js/csb-agenda.js.
   Version précédente : csb-docs/sauvegarde-2026-11-13-agenda/css/csb-evenements-v2.css. */

.csb-ag3 {
	--ag-foret: #004540; --ag-vegetal: #23734A; --ag-mil: #FFE175; --ag-encre: #16231A;
	--ag-texte: rgba(22, 35, 26, .78); --ag-doux: rgba(22, 35, 26, .64); --ag-trait: rgba(0, 69, 64, .14); --ag-pale: #F5F8F4;
	--ag-titre: var(--csb-font-titre, Georgia, serif); --ag-sans: var(--csb-font-texte, system-ui, sans-serif);
	--ag-rayon: 12px; --ag-courbe: cubic-bezier(.2, .7, .2, 1); --ag-haut: 0px;
	font-family: var(--ag-sans); color: var(--ag-encre);
}
.csb-ag3 *, .csb-ag3 *::before, .csb-ag3 *::after { box-sizing: border-box; }
body .csb-ag3 :is(h2, h3):not(#csb) { margin: 0; font-family: var(--ag-titre); font-weight: 700; color: var(--ag-encre); text-transform: none; letter-spacing: -.01em; text-wrap: balance; }
/* Remises à zéro de faible spécificité (:where) : les règles des composants ci-dessous l'emportent */
body .csb-ag3 :where(.csb-ag-sessions, .csb-ag-suivre, .csb-ag-fiche) :where(p) { margin: 0; text-align: left; hyphens: none; }
body .csb-ag3 :where(.csb-ag-sessions, .csb-ag-fiche) :where(ul) { margin: 0; padding: 0; list-style: none; }
.csb-ag3 :focus-visible { outline: 3px solid var(--ag-foret); outline-offset: 3px; border-radius: 6px; }
.csb-ag-a-preciser { font-style: italic; color: var(--ag-doux); }

/* --- Bandeau : résumé chiffré sous l'accroche, séparé par des filets verticaux --- */
body .csb-ag3 ul.csb-ag-chiffres:not(#csb) { display: flex; flex-wrap: wrap; margin: 24px 0 0; padding: 0; list-style: none; }
.csb-ag-chiffres li { display: flex; align-items: baseline; gap: 8px; padding: 0 24px; border-left: 1px solid rgba(255, 255, 255, .35); color: #fff; }
.csb-ag-chiffres li:first-child { padding-left: 0; border-left: 0; }
.csb-ag-chiffres b { font: 700 28px/1 var(--ag-titre); font-variant-numeric: tabular-nums; }
.csb-ag-chiffres span { font-size: 15px; font-weight: 500; color: rgba(255, 255, 255, .86); }

/* --- Barre de filtres, collante sous l'en-tête --- */
.csb-ag-barre { position: sticky; top: var(--ag-haut); z-index: 20; background: rgba(255, 255, 255, .96); border-bottom: 1px solid var(--ag-trait); }
.csb-ag-barre-int { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 72px; }
.csb-ag-filtres { position: relative; display: flex; gap: 4px; padding: 4px; border-radius: 100px; background: var(--ag-pale); box-shadow: inset 0 0 0 1px var(--ag-trait); }
body .csb-ag3 .csb-ag-filtre:not(#csb) { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 18px; border: 0; border-radius: 100px; background: none; font: 600 15px/1 var(--ag-sans); color: var(--ag-texte); white-space: nowrap; cursor: pointer; transition: color .25s ease; }
body .csb-ag3 .csb-ag-filtre[aria-pressed="true"]:not(#csb) { color: var(--ag-foret); }
body .csb-ag3 .csb-ag-filtre:disabled:not(#csb) { opacity: .45; cursor: default; }
@media (hover: hover) { body .csb-ag3 .csb-ag-filtre:hover:not(:disabled):not([aria-pressed="true"]):not(#csb) { color: var(--ag-foret); } }
.csb-ag-n { min-width: 24px; padding: 3px 7px; border-radius: 100px; background: rgba(0, 69, 64, .08); font-size: 13px; font-weight: 600; text-align: center; font-variant-numeric: tabular-nums; }
.csb-ag-filtre[aria-pressed="true"] .csb-ag-n { background: rgba(0, 69, 64, .12); }
/* Indicateur jaune mil qui glisse sous le filtre actif (position posée par csb-agenda.js) */
.csb-ag-indic { position: absolute; top: 4px; left: 0; height: calc(100% - 8px); width: 0; border-radius: 100px; background: var(--ag-mil); transform: translateX(var(--x, 0)); width: var(--l, 0); transition: transform .35s var(--ag-courbe), width .35s var(--ag-courbe); }
html:not(.csb-ag-pret) .csb-ag-indic { transition: none; }
.csb-ag-resultat { margin: 0; font-size: 15px; font-weight: 500; color: var(--ag-doux); white-space: nowrap; font-variant-numeric: tabular-nums; }
/* Sans JavaScript : pas de filtre, toutes les cartes groupées par statut */
html:not(.csb-js) .csb-ag-barre { display: none; }

/* --- Grille unique des sessions (en cours, à venir, passés) --- */
.csb-ag-sessions { padding: 48px 0 96px; background: #fff; scroll-margin-top: 72px; }
.csb-ag-grille { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 24px; align-items: stretch; }   /* cartes d'une même rangée à la même hauteur ; l'action reste en bas (margin-top: auto) */
@media (max-width: 1199px) { .csb-ag-grille { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767px) { .csb-ag-grille { grid-template-columns: minmax(0, 1fr); gap: 24px; } }
/* Filtre actif (avec JavaScript) : seules les cartes du statut choisi */
.csb-js [data-vue="en-cours"] .csb-ag-carte:not([data-statut="en-cours"]),
.csb-js [data-vue="a-venir"] .csb-ag-carte:not([data-statut="a-venir"]),
.csb-js [data-vue="passe"] .csb-ag-carte:not([data-statut="passe"]) { display: none; }

/* --- Carte --- */
.csb-ag-carte { position: relative; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--ag-trait); border-radius: var(--ag-rayon); background: #fff; transition: transform .3s var(--ag-courbe), border-color .3s ease; }
.csb-ag-media { position: relative; aspect-ratio: 3 / 2; overflow: hidden; background: var(--ag-pale); }
.csb-ag-media img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ag-courbe), filter .3s ease; }
.csb-ag-carte.is-passe .csb-ag-media img { filter: saturate(.55); }
/* Bloc date en surimpression */
body .csb-ag3 .csb-ag-date:not(#csb) { position: absolute; left: 16px; bottom: 16px; display: flex; flex-direction: column; min-width: 72px; padding: 10px 14px; border-radius: 10px; background: #fff; color: var(--ag-foret); }
.csb-ag-date b { font: 700 24px/1.05 var(--ag-titre); white-space: nowrap; font-variant-numeric: lining-nums; }
.csb-ag-date span { margin-top: 4px; font-size: 13px; font-weight: 600; line-height: 1.2; color: var(--ag-texte); }
body .csb-ag3 .csb-ag-credit:not(#csb) { padding: 8px 20px 0; font-size: 12.5px; line-height: 1.4; color: var(--ag-doux); }
.csb-ag-corps { display: flex; flex-direction: column; flex: 1; padding: 16px 20px 20px; }
/* Métadonnées : statut, catégorie, filière, séparées par des filets verticaux */
body .csb-ag3 .csb-ag-meta:not(#csb) { display: flex; flex-wrap: wrap; align-items: center; row-gap: 6px; font-size: 13.5px; font-weight: 500; line-height: 1.3; color: var(--ag-doux); }
.csb-ag-meta > span + span { margin-left: 10px; padding-left: 10px; border-left: 1px solid var(--ag-trait); }
.csb-ag-meta > span.is-debut:not(.csb-ag-statut) { margin-left: 0; padding-left: 0; border-left: 0; }   /* élément renvoyé en début de ligne : pas de filet (csb-agenda.js) */
.csb-ag-statut { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 100px; font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.csb-ag-meta > .csb-ag-statut + span { border-left: 0; padding-left: 0; }
.csb-ag-statut.is-a-venir { background: var(--ag-mil); color: var(--ag-foret); }
.csb-ag-statut.is-en-cours { background: #E3F0E7; color: var(--ag-foret); }
.csb-ag-statut.is-en-cours::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--ag-vegetal); animation: csbAgPouls 1.4s ease .4s 3; }
.csb-ag-statut.is-passe { box-shadow: inset 0 0 0 1px rgba(22, 35, 26, .25); color: var(--ag-doux); }
@keyframes csbAgPouls { 0% { box-shadow: 0 0 0 0 rgba(35, 115, 74, .55); } 100% { box-shadow: 0 0 0 7px rgba(35, 115, 74, 0); } }
body .csb-ag3 .csb-ag-titre:not(#csb) { margin-top: 12px; font-size: 20px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.csb-ag-titre a { color: inherit; text-decoration: none; transition: color .25s ease; }
.csb-ag-titre a::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: var(--ag-rayon); }
.csb-ag-titre a:focus-visible { outline: none; }
.csb-ag-carte:has(.csb-ag-titre a:focus-visible) { outline: 3px solid var(--ag-foret); outline-offset: 3px; }
/* Informations à icônes */
.csb-ag-infos, .csb-ag-fiche-infos { display: grid; gap: 8px; }
body .csb-ag3 .csb-ag-infos:not(#csb) { margin-top: 14px; }
.csb-ag-infos li, .csb-ag-fiche-infos li { display: grid; grid-template-columns: 16px minmax(0, 1fr); gap: 10px; align-items: baseline; font-size: 14.5px; line-height: 1.5; color: var(--ag-texte); }
.csb-ag-infos i, .csb-ag-fiche-infos i { font-size: 14px; color: var(--ag-vegetal); text-align: center; }
body .csb-ag3 .csb-ag-rebours:not(#csb) { margin-top: 12px; font-size: 14px; font-weight: 600; color: var(--ag-foret); }
body .csb-ag3 .csb-ag-resume:not(#csb) { margin-top: 12px; font-size: 15px; line-height: 1.6; color: var(--ag-texte); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }   /* résumé : 2 lignes sur la carte, texte complet dans la fiche */
/* Pied de carte : une seule action */
.csb-ag-pied { display: flex; align-items: center; gap: 16px; margin-top: auto; padding-top: 18px; }
.csb-ag-pied:empty { display: none; }
.csb-ag-btn { position: relative; z-index: 2; display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 20px; border-radius: 100px; background: var(--ag-mil); font-size: 15px; font-weight: 600; color: var(--ag-foret); text-decoration: none; transition: background-color .25s ease; }
.csb-ag-btn:hover { background: #FFD84A; color: var(--ag-foret); }
/* Bouton principal du panneau : page de l'événement (vert forêt) ; l'inscription reste en jaune mil */
.csb-ag-btn.is-foret { background: var(--ag-foret); color: #fff; }
.csb-ag-btn.is-foret:hover { background: #00302c; color: #fff; }
.csb-ag-action { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 15px; font-weight: 600; color: var(--ag-foret); text-decoration: none; }
.csb-ag-action.is-lien { position: relative; z-index: 2; text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 5px; }
:is(.csb-ag-btn, .csb-ag-action) i { font-size: 13px; transition: transform .3s var(--ag-courbe); }
@media (hover: hover) {
	.csb-ag-carte:hover { transform: translateY(-2px); border-color: rgba(0, 69, 64, .3); }
	.csb-ag-carte:hover .csb-ag-media img { transform: scale(1.04); }
	.csb-ag-carte:hover .csb-ag-titre a { color: var(--ag-foret); }
	.csb-ag-carte:hover :is(.csb-ag-btn, .csb-ag-action) i { transform: translateX(3px); }
	.csb-ag-carte:hover .csb-ag-action.is-lien i { transform: translate(2px, -2px); }
}
/* Carte ciblée par un lien evenements.php#id : mise en évidence brève */
.csb-ag-carte.is-repere { animation: csbAgRepere 2.2s ease 1; }
@keyframes csbAgRepere { 0%, 60% { box-shadow: 0 0 0 4px var(--ag-mil); border-color: var(--ag-foret); } 100% { box-shadow: 0 0 0 0 rgba(255, 225, 117, 0); } }

/* État vide d'un filtre */
.csb-ag-vide { max-width: 560px; padding: 40px 0 8px; }
body .csb-ag3 .csb-ag-vide p:not(#csb) { font-size: 17px; line-height: 1.6; color: var(--ag-texte); }
body .csb-ag3 .csb-ag-vide p:first-child:not(#csb), body .csb-ag3 .csb-ag-vide p[data-ag-vide-texte]:not([hidden]):not(#csb) { font: 700 22px/1.3 var(--ag-titre); color: var(--ag-encre); margin-bottom: 8px; }
.csb-ag-vide-liens { display: flex; flex-wrap: wrap; gap: 24px; margin-top: 16px; }
.csb-ag-lien { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; color: var(--ag-foret); text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 5px; }
.csb-ag-lien:hover { color: var(--ag-vegetal); }

/* --- Bas de page : fond très clair, plus de bande vert foncé avant le pied de page --- */
.csb-ag-suivre { padding: 64px 0; background: var(--ag-pale); border-top: 1px solid var(--ag-trait); }
.csb-ag-suivre-grille { display: flex; align-items: center; justify-content: space-between; gap: 32px 64px; flex-wrap: wrap; }
body .csb-ag3 .csb-ag-suivre h2:not(#csb) { font-size: clamp(24px, 20px + 1vw, 32px); line-height: 1.2; }
body .csb-ag3 .csb-ag-suivre p:not(#csb) { margin-top: 12px; max-width: 58ch; font-size: 16px; line-height: 1.6; color: var(--ag-texte); }
.csb-ag-suivre-actions { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }

/* --- Fiche détaillée : panneau latéral à droite (plein écran sur mobile) --- */
.csb-ag-fiche { position: fixed; inset: 0 0 0 auto; width: min(560px, 100%); max-width: 100%; height: 100%; max-height: 100%; margin: 0; padding: 0; border: 0; background: #fff; color: var(--ag-encre); overflow: hidden; }
.csb-ag-fiche::backdrop { background: rgba(10, 30, 26, .45); }
.csb-ag-fiche[open] { animation: csbAgFicheEntre .35s var(--ag-courbe); }
.csb-ag-fiche[open]::backdrop { animation: csbAgFond .3s ease; }
@keyframes csbAgFicheEntre { from { transform: translateX(32px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes csbAgFond { from { opacity: 0; } to { opacity: 1; } }
.csb-ag-fiche-int { height: 100%; overflow-y: auto; overscroll-behavior: contain; padding: 0 32px 40px; }
.csb-ag-fiche-barre { position: sticky; top: 0; z-index: 2; display: flex; justify-content: flex-end; margin: 0 -32px; padding: 12px 16px; background: rgba(255, 255, 255, .96); }
body .csb-ag-fiche .csb-ag-fermer:not(#csb) { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: var(--ag-pale); color: var(--ag-foret); cursor: pointer; transition: background-color .25s ease, color .25s ease; }
body .csb-ag-fiche .csb-ag-fermer:hover:not(#csb) { background: var(--ag-foret); color: #fff; }
.csb-ag-fermer svg { width: 20px; height: 20px; }
.csb-ag-fiche-photo { margin: 0 0 20px; }
.csb-ag-fiche-photo img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--ag-rayon); }
.csb-ag-fiche-photo figcaption { margin-top: 8px; font-size: 12.5px; color: var(--ag-doux); }
body .csb-ag3 .csb-ag-fiche-titre:not(#csb) { margin-top: 12px; font-size: clamp(24px, 20px + 1vw, 30px); line-height: 1.2; }
body .csb-ag3 .csb-ag-fiche-infos:not(#csb) { margin-top: 20px; padding: 16px 0; border-top: 1px solid var(--ag-trait); border-bottom: 1px solid var(--ag-trait); }
.csb-ag-fiche-infos li { font-size: 15px; }
.csb-ag-cle { display: block; font-size: 12.5px; font-weight: 600; color: var(--ag-doux); }
.csb-ag-fiche-texte { margin-top: 20px; }
body .csb-ag3 .csb-ag-fiche-texte p:not(#csb) { font-size: 16px; line-height: 1.65; color: var(--ag-texte); }
body .csb-ag3 .csb-ag-fiche-texte p + p:not(#csb) { margin-top: 12px; }
.csb-ag-fiche-liens { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 24px; }
.csb-ag-fiche-liens:empty { display: none; }
html.csb-ag-fiche-ouverte { overflow: hidden; }

/* --- Tablette et mobile --- */
@media (max-width: 991px) {
	.csb-ag-barre-int { min-height: 64px; }
	.csb-ag-resultat { display: none; }
}
@media (max-width: 767px) {
	.csb-ag-chiffres li { padding: 0 16px; }
	.csb-ag-chiffres b { font-size: 24px; }
	.csb-ag-barre-int { gap: 12px; }
	/* La barre de filtres défile horizontalement */
	.csb-ag-filtres { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
	.csb-ag-filtres::-webkit-scrollbar { display: none; }
	body .csb-ag3 .csb-ag-filtre:not(#csb) { padding: 0 14px; font-size: 14.5px; }
	.csb-ag-sessions { padding: 40px 0 72px; }
	.csb-ag-fiche { width: 100%; }
	.csb-ag-fiche-int { padding: 0 20px 32px; }
	.csb-ag-fiche-barre { margin: 0 -20px; padding: 8px 12px; }
	.csb-ag-suivre { padding: 48px 0; }
}

/* Mouvement réduit : aucun mouvement, filtres instantanés */
@media (prefers-reduced-motion: reduce) {
	.csb-ag3 *, .csb-ag3 *::before, .csb-ag3 *::after, .csb-ag-fiche, .csb-ag-fiche::backdrop { animation: none !important; transition: none !important; }
}

/* --- Cartes d'une même rangée : mêmes hauteurs de bloc (photo, métadonnées, titre, infos, résumé, action) sans blanc, 13 nov. 2026 ---
   Chaque carte reprend les lignes de la grille (subgrid) : le titre, les infos, le résumé et l'action sont alignés d'une carte à l'autre. */
.csb-ag-infos li > span:last-child { display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.csb-ag-infos li.is-lieu > span:last-child { -webkit-line-clamp: 2; }   /* titre : 2 lignes, lieu : 2 lignes, programme et public : 1 ligne sur la carte ; texte complet dans la fiche */
.csb-ag-meta { flex-wrap: nowrap; overflow: hidden; }
.csb-ag-meta > span { flex: none; white-space: nowrap; }
.csb-ag-meta > span:last-child:not(.csb-ag-statut) { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.csb-ag-credit.is-vide { min-height: 0; }
@supports (grid-template-rows: subgrid) {
	@media (min-width: 768px) {
		.csb-ag-grille { row-gap: 0; }
		.csb-ag-carte { display: grid; grid-row: span 8; grid-template-rows: subgrid; row-gap: 0; margin-bottom: 32px; align-self: stretch; }
		.csb-ag-corps { display: contents; }
		.csb-ag-media { grid-row: 1; }
		.csb-ag-credit { grid-row: 2; }
		.csb-ag-meta { grid-row: 3; }
		.csb-ag-titre { grid-row: 4; }
		.csb-ag-infos { grid-row: 5; }
		.csb-ag-rebours { grid-row: 6; }
		.csb-ag-resume { grid-row: 7; }
		.csb-ag-pied { grid-row: 8; align-self: end; }
		body .csb-ag3 :is(.csb-ag-meta, .csb-ag-titre, .csb-ag-infos, .csb-ag-rebours, .csb-ag-resume):not(#csb) { margin-inline: 20px; }
		.csb-ag-pied { margin: 0 20px 20px; }
		.csb-ag-carte > .csb-ag-credit { padding-bottom: 0; }
		.csb-ag-titre { margin-top: 12px; }
	}
}

/* Filtres compacts sur mobile (13 nov. 2026) : les quatre filtres tiennent sur une ligne sans défilement jusqu'à 360 px */
@media (max-width: 767px) {
	.csb-ag-barre-int { min-height: 52px; }
	.csb-ag-filtres { gap: 2px; padding: 3px; max-width: 100%; }
	body .csb-ag3 .csb-ag-filtre:not(#csb) { gap: 5px; min-height: 40px; padding: 0 10px; font-size: 13px; }
	.csb-ag-n { min-width: 20px; padding: 2px 5px; font-size: 11.5px; }
	.csb-ag-indic { top: 3px; height: calc(100% - 6px); }
	.csb-ag-sessions { padding-top: 32px; }
}
@media (max-width: 380px) {
	body .csb-ag3 .csb-ag-filtre:not(#csb) { gap: 4px; padding: 0 7px; font-size: 12.5px; }
	.csb-ag-n { min-width: 18px; padding: 2px 4px; font-size: 11px; }
}

/* --- Thématiques (13 nov. 2026) : 2e rangée de la barre collante, cumulable avec le statut --- */
.csb-ag-themes-ligne { padding-top: 0; padding-bottom: 12px; }
.csb-ag-themes { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 4px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.csb-ag-themes::-webkit-scrollbar { display: none; }
body .csb-ag3 .csb-ag-theme:not(#csb) { flex: none; display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 14px; border: 1px solid var(--ag-trait); border-radius: 8px; background: #fff; font: 500 14px/1 var(--ag-sans); color: var(--ag-texte); white-space: nowrap; cursor: pointer; transition: border-color .2s ease, color .2s ease, box-shadow .2s ease; }
body .csb-ag3 .csb-ag-theme .csb-ag-n:not(#csb) { min-width: 0; padding: 0; background: none; font-size: 13px; font-weight: 400; color: var(--ag-doux); }
body .csb-ag3 .csb-ag-theme[aria-pressed="true"]:not(#csb) { border-color: var(--ag-foret); box-shadow: inset 0 -3px 0 var(--ag-mil); color: var(--ag-foret); font-weight: 600; }
body .csb-ag3 .csb-ag-theme:disabled:not(#csb) { opacity: .45; cursor: default; }
@media (hover: hover) { body .csb-ag3 .csb-ag-theme:hover:not(:disabled):not([aria-pressed="true"]):not(#csb) { border-color: var(--ag-foret); color: var(--ag-foret); } }
body .csb-ag3 .csb-ag-theme:focus-visible:not(#csb) { outline: 2px solid var(--ag-foret); outline-offset: 2px; }
.csb-ag-carte.is-hors-theme { display: none; }
body .csb-ag3 .csb-ag-reinit:not(#csb) { min-height: 44px; margin: 8px 0 16px; padding: 0 18px; border: 1px solid var(--ag-foret); border-radius: 8px; background: #fff; font: 600 15px/1 var(--ag-sans); color: var(--ag-foret); cursor: pointer; }
body .csb-ag3 .csb-ag-reinit:hover:not(#csb) { background: var(--ag-foret); color: #fff; }
@media (max-width: 767px) { .csb-ag-themes-ligne { padding-bottom: 8px; } body .csb-ag3 .csb-ag-theme:not(#csb) { min-height: 36px; padding: 0 12px; font-size: 13px; } }
html:not(.csb-js) .csb-ag-themes-ligne { display: none; }

/* Largeur figée sur mobile et tablette : aucun balayage horizontal */
@media (max-width: 991px) {
	html, body { max-width: 100%; overflow-x: clip; }
}

/* Icônes des métadonnées (catégorie, filière) : même jeu, 14 px, couleur du texte */
.csb-ag-meta > span > i { margin-right: 6px; font-size: 14px; line-height: 1; vertical-align: -1px; }

/* Métadonnées au style de la page Actualités (15 nov. 2026) : statut en pastille, catégorie en étiquette teintée, filière en texte gris avec icône ;
   plus de filets verticaux, un simple espacement de 10 px (étiquettes et dates : csb-sidebar-publications.css) */
body .csb-ag3 .csb-ag-meta:not(#csb) { gap: 6px 10px; }
body .csb-ag3 .csb-ag-meta > span:not(#csb) { margin-left: 0; padding-left: 0; border-left: 0; }
body .csb-ag3 .csb-ag-meta > .csb-post-category-label:not(#csb) { display: inline-flex; align-items: center; gap: 5px; padding: 3px 7px; }
body .csb-ag3 .csb-ag-meta > .csb-post-category-label i { margin: 0; font-size: 11px; vertical-align: 0; }
body .csb-ag3 .csb-ag-meta > .csb-post-date:not(#csb) i { margin: 0; font-size: 11px; vertical-align: 0; }
body .csb-ag3 .csb-ag-meta:not(#csb) { margin-top: 6px; }

/* Méta des cartes (15 nov. 2026) : statut, catégorie, dates (ex-pavé sur la photo) puis filière ; la ligne passe à la ligne au lieu d'être coupée */
body .csb-ag3 .csb-ag-meta:not(#csb) { flex-wrap: wrap; overflow: visible; }
body .csb-ag3 .csb-ag-meta > span:not(#csb) { white-space: nowrap; }
body .csb-ag3 .csb-ag-meta > span:last-child:not(.csb-ag-statut):not(#csb) { overflow: visible; text-overflow: clip; }
body .csb-ag3 .csb-ag-meta > .csb-post-date:not(#csb) { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 400; color: #555; }

/* Filière (Maraîchage, Aviculture…) : étiquette minimaliste en haut à gauche de la photo (15 nov. 2026) */
body .csb-ag3 .csb-ag-media:not(#csb) { position: relative; }
body .csb-ag3 p.csb-ag-filiere:not(#csb) { position: absolute; top: 12px; left: 12px; z-index: 1; margin: 0; padding: 3px 8px; border-radius: 4px; background: rgba(255, 255, 255, .92); font-size: 11px; font-weight: 600; line-height: 1.2; color: var(--ag-foret, #004540); }

/* Pagination des sessions passées (15 nov. 2026) : 9 par page, minimaliste, texte noir, fond blanc, filets fins, page active soulignée de jaune */
.csb-ag-carte.is-hors-page { display: none; }
.csb-ag-pagination { margin-top: 48px; }
.csb-ag-pagination[hidden] { display: none; }
.csb-ag-pagination ul { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; margin: 0; padding: 0; list-style: none; }
.csb-ag-pagination li { margin: 0; padding: 0; }
body .csb-ag-pagination button:not(#csb) { min-width: 44px; min-height: 44px; padding: 0 14px; border: 1px solid rgba(0, 0, 0, .16); border-radius: 8px; background: #fff; color: #111; font: inherit; font-weight: 500; line-height: 1; cursor: pointer; transition: border-color .15s ease, background-color .15s ease; }
body .csb-ag-pagination button:not(#csb):hover:not(:disabled) { border-color: #111; }
body .csb-ag-pagination button:not(#csb)[aria-current="page"] { border-color: #111; background: #fff; box-shadow: inset 0 -3px 0 #FFE175; font-weight: 700; }
body .csb-ag-pagination button:not(#csb):disabled { color: rgba(0, 0, 0, .35); border-color: rgba(0, 0, 0, .08); cursor: default; }
.csb-ag-pagination button:focus-visible { outline: 3px solid #004540; outline-offset: 2px; }
@media (max-width: 480px) { body .csb-ag-pagination button:not(#csb) { min-width: 40px; padding: 0 10px; } .csb-ag-pagination ul { gap: 6px; } }
@media (prefers-reduced-motion: reduce) { body .csb-ag-pagination button:not(#csb) { transition: none; } }

/* Agenda : texte noir, justifié, textes complets, espacements resserrés (unslop, 15 nov. 2026). Sauvegarde : csb-docs/sauvegarde-2026-11-15-agenda-unslop/. */
.csb-ag3 { --ag-texte: #111; --ag-doux: #333; }
body .csb-ag3 .csb-ag-titre:not(#csb) { margin-top: 10px; color: #111; -webkit-line-clamp: unset; display: block; overflow: visible; text-wrap: pretty; }
body .csb-ag3 .csb-ag-meta:not(#csb) { font-size: 13px; color: #111; }
body .csb-ag3 .csb-ag-infos:not(#csb) { margin-top: 12px; gap: 6px; }
.csb-ag-infos li, .csb-ag-fiche-infos li { font-size: 15px; line-height: 1.45; color: #111; }
.csb-ag-infos i, .csb-ag-fiche-infos i { color: #333; }
.csb-ag-infos li > span:last-child, .csb-ag-infos li.is-lieu > span:last-child { display: block; -webkit-line-clamp: unset; overflow: visible; }
body .csb-ag3 .csb-ag-resume:not(#csb) { margin-top: 10px; font-size: 16px; line-height: 1.55; color: #111; display: block; -webkit-line-clamp: unset; overflow: visible; text-align: justify; text-justify: inter-word; -webkit-hyphens: auto; hyphens: auto; overflow-wrap: break-word; }
.csb-ag-action { color: #111; }
.csb-ag-carte:hover .csb-ag-titre a { color: #111; }
.csb-ag-carte:hover .csb-ag-action.is-lien, .csb-ag-action.is-lien { color: #111; }
.csb-ag-corps { padding: 14px 18px 16px; }
.csb-ag-grille { gap: 28px 22px; }
@supports (grid-template-rows: subgrid) {
	@media (min-width: 768px) {
		.csb-ag-grille { row-gap: 0; }
		body .csb-ag3 :is(.csb-ag-meta, .csb-ag-titre, .csb-ag-infos, .csb-ag-rebours, .csb-ag-resume):not(#csb) { margin-inline: 18px; }
		.csb-ag-pied { margin: 0 18px 16px; }
	}
}
@media (max-width: 420px) { body .csb-ag3 .csb-ag-resume:not(#csb) { text-align: left; } }

/* Carte : le statut (En cours, À venir, Terminé) est un badge sur l'image ; la filière passe dans les métadonnées */
body .csb-ag3 p.csb-ag-badge-img:not(#csb) { position: absolute; top: 12px; left: 12px; z-index: 1; margin: 0; line-height: 1; }
.csb-ag-badge-img .csb-ag-statut { box-shadow: 0 1px 4px rgba(0, 0, 0, .18); }
.csb-ag-badge-img .csb-ag-statut.is-passe { background: #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, .18); color: #111; }
.csb-ag-badge-img .csb-ag-statut.is-en-cours { background: #E3F0E7; }

/* Cartes à hauteur naturelle : plus de lignes alignées entre cartes (subgrid), donc plus de vides entre les informations et le lien (15 nov. 2026) */
@supports (grid-template-rows: subgrid) {
	@media (min-width: 768px) {
		.csb-ag-grille { row-gap: 28px; align-items: start; }
		.csb-ag-carte { display: flex; grid-row: auto; grid-template-rows: none; align-self: start; margin-bottom: 0; }
		.csb-ag-corps { display: flex; padding: 14px 18px 16px; }
		body .csb-ag3 :is(.csb-ag-meta, .csb-ag-titre, .csb-ag-infos, .csb-ag-rebours, .csb-ag-resume):not(#csb) { margin-inline: 0; }
		.csb-ag-pied { margin: 4px 0 0; align-self: stretch; }
	}
}

/* Cartes de même hauteur dans une rangée ; le résumé remplit l'éventuel espace libre (csb-agenda.js, remplir()) */
@media (min-width: 768px) {
	.csb-ag-grille { align-items: stretch; }
	.csb-ag-carte { align-self: stretch; }
	.csb-ag-grille.is-mesure .csb-ag-carte { align-self: start; }
	.csb-ag-pied { margin-top: auto; padding-top: 4px; }
}
body .csb-ag3 .csb-ag-resume[data-ag-remplir]:not([hidden]):not(#csb) { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: var(--ag-lignes, 3); overflow: hidden; margin-top: 12px; margin-bottom: 8px; }
.csb-ag-resume[data-ag-remplir][hidden] { display: none !important; }

/* Agenda : « Voir le détail » / « Voir le compte rendu » est un vrai lien d'action sur chaque carte (16 nov. 2026) : texte noir, flèche, filet jaune */
.csb-ag-action.is-cta { position: relative; z-index: 2; min-height: 0; padding: 0 0 4px; border-bottom: 2px solid #FFE06A; font-size: 14.5px; font-weight: 600; color: #171717; text-decoration: none; transition: color .2s ease, border-color .2s ease; }
.csb-ag-action.is-cta:hover, .csb-ag-action.is-cta:focus-visible { color: #004540; border-color: #004540; }
.csb-ag-pied { flex-wrap: wrap; gap: 12px 20px; }
