/* ==========================================================================
   Commune de Luant — styles du site
   Couleurs du logo uniquement (vert, bleu, cyan, rouge), sur du noir et blanc.
   Le bleu des textes et boutons est celui du logo, assombri pour rester lisible
   (contraste AA).
   Police : Atkinson Hyperlegible (Braille Institute), dessinée pour les personnes
   qui voient mal : lettres très distinctes (I l 1, O 0). Fichiers dans le thème,
   licence libre OFL (assets/fonts/OFL.txt) : aucune requête vers un service tiers.
   ========================================================================== */

@font-face { font-family: "Atkinson Hyperlegible"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/atkinson-hyperlegible-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/atkinson-hyperlegible-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: italic; font-weight: 400; font-display: swap; src: url("../fonts/atkinson-hyperlegible-400-italic.woff2") format("woff2"); }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: italic; font-weight: 700; font-display: swap; src: url("../fonts/atkinson-hyperlegible-700-italic.woff2") format("woff2"); }

/* 1. Variables ------------------------------------------------------------ */
:root {
	--c-ink: #000;
	--c-muted: #5c5f63;
	--c-line: #dfe1e4;
	--c-grey: #f3f4f5;
	--c-grey-dark: #e6e8ea;
	--c-white: #fff;
	--c-surface: #fff;      /* fond des cartes et des boutons clairs */
	--c-on-ink: #fff;       /* texte posé sur un fond noir (--c-ink) */
	--c-on-blue: #fff;      /* texte posé sur un fond bleu (--c-blue) */
	--c-field-border: #8a8f95;
	--c-placeholder: #85888c;
	--c-hatch: #d9ecf7;
	--c-calls-hover: #fadadf;

	--c-blue-logo: #008ed1;
	--c-blue: #006fa6;
	--c-blue-dark: #00527c;
	--c-blue-tint: #e6f4fb;
	--c-cyan: #00bfd1;
	--c-green: #96b900;
	--c-green-dark: #4f6200;
	--c-green-tint: #f2f7dc;
	--c-red: #ce0014;
	--c-red-dark: #8a000d;
	--c-red-tint: #fdecee;

	--logo-band: linear-gradient(90deg, var(--c-green) 0%, var(--c-cyan) 55%, var(--c-blue-logo) 100%);

	--font: "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

	--radius: 14px;
	--radius-lg: 30px;
	--header-h: 5rem;
	--shadow: 0 1px 2px rgba(0, 0, 0, .05), 0 10px 28px rgba(0, 0, 0, .08);
	--container: 72rem;
	--gutter: clamp(1rem, 4vw, 2rem);
	--gap: clamp(1rem, 2.5vw, 1.5rem);
	--section: clamp(2.5rem, 6vw, 4.5rem);
}

/* 2. Base ----------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 6rem; }

body {
	margin: 0;
	font-family: var(--font);
	font-size: 1.125rem;   /* 18 px : confortable pour un public âgé */
	line-height: 1.6;
	color: var(--c-ink);
	background: var(--c-white);
	-webkit-font-smoothing: antialiased;
}

[hidden] { display: none !important; }

img, svg, video { max-width: 100%; height: auto; }
img { display: block; }
figure { margin: 0; }

h1, h2, h3, h4 {
	margin: 0 0 .6em;
	font-weight: 700;
	line-height: 1.15;
	color: var(--c-ink);
	text-wrap: balance;
}
/* Échelle typographique (rapport ≈ 1,25) : 18 → 22,5 → 28 → 35 → 44 px. */
h1 { font-size: clamp(2.2rem, 4.5vw, 2.75rem); }
h2 { font-size: clamp(1.6rem, 2.6vw, 1.95rem); }
h3 { font-size: 1.4rem; }
h4 { font-size: 1.15rem; }

p { margin: 0 0 1em; }
a { color: var(--c-blue); text-underline-offset: .2em; }
a:hover { color: var(--c-blue-dark); }

:focus-visible { outline: 3px solid var(--c-blue-logo); outline-offset: 3px; border-radius: 4px; }

.icon { width: 1.25rem; height: 1.25rem; flex: none; }

.screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	margin: -1px; padding: 0; border: 0;
	overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.skip-link {
	position: absolute; left: 1rem; top: -4rem; z-index: 2000;
	padding: .75rem 1rem; border-radius: var(--radius);
	background: var(--c-ink); color: var(--c-on-ink); font-weight: 700;
}
.skip-link:focus { top: 1rem; }
/* Connecté : la barre d'administration (46px sur téléphone, 32px au-delà de 782px) ne doit pas cacher le lien. */
.admin-bar .skip-link:focus { top: calc(46px + 1rem); }
@media (min-width: 783px) { .admin-bar .skip-link:focus { top: calc(32px + 1rem); } }

.muted { color: var(--c-muted); }
.empty { padding: 1.25rem; border: 1px dashed var(--c-line); border-radius: var(--radius); color: var(--c-muted); }

/* Consignes de rédaction : invisibles du public, visibles des rédacteurs connectés. */
.luant-todo { display: none; }
body.logged-in .luant-todo {
	display: block; padding: .75rem 1rem; border-left: 4px solid var(--c-green);
	border-radius: 0 var(--radius) var(--radius) 0; background: var(--c-green-tint); color: var(--c-ink); font-size: .95rem;
}

/* 3. Mise en page --------------------------------------------------------- */
.container { width: min(100% - 2 * var(--gutter), var(--container)); margin-inline: auto; }

.section { padding-block: var(--section); }
.section--tight { padding-block: clamp(1.5rem, 4vw, 2.5rem); }
.section--tint { background: var(--c-grey); }

.section__head { margin-bottom: clamp(1.25rem, 3vw, 2rem); }
.section__head h2 { margin: 0; }
.lead { font-size: 1.15rem; color: var(--c-muted); max-width: 40rem; }
.more { display: inline-flex; align-items: center; gap: .4rem; font-weight: 700; text-decoration: none; }
.more:hover .icon { transform: translateX(3px); }
.more .icon { transition: transform .2s; }

.grid { display: grid; gap: var(--gap); }

.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.25rem 0 0; }

/* 4. Boutons -------------------------------------------------------------- */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
	min-height: 2.85rem; padding: .6rem 1.2rem;
	border: 2px solid transparent; border-radius: 999px;
	font: inherit; font-weight: 700; line-height: 1.2; text-decoration: none;
	cursor: pointer; transition: background-color .2s, border-color .2s, color .2s;
}
.btn--primary { background: var(--c-blue); color: var(--c-on-blue); }
.btn--primary:hover { background: var(--c-blue-dark); color: var(--c-on-blue); }
.btn--ghost { background: var(--c-surface); color: var(--c-ink); border-color: var(--c-line); }
.btn--ghost:hover { border-color: var(--c-ink); color: var(--c-ink); }
.btn--light { background: var(--c-surface); color: var(--c-ink); }
.btn--light:hover { background: var(--c-grey); color: var(--c-ink); }
.btn--sm { min-height: 2.6rem; padding: .4rem 1.1rem; font-size: .95rem; }

/* 5. En-tête -------------------------------------------------------------- */
.alert-bar { background: var(--c-red); color: #fff; font-weight: 600; }
.alert-bar .container { display: flex; align-items: center; gap: .75rem; padding-block: .6rem; }
.alert-bar p { margin: 0; }
.alert-bar a { color: #fff; }

/* L'en-tête se cache en descendant et revient en remontant (assets/js/main.js). */
.site-header { position: sticky; top: 0; z-index: 900; background: var(--c-surface); transition: transform .3s ease, box-shadow .3s; }
/* Liseré aux couleurs du logo sous l'en-tête. */
.site-header::after { content: ""; display: block; height: 4px; background: var(--logo-band); }
.site-header.is-stuck { box-shadow: 0 4px 18px rgba(0, 0, 0, .08); }
.site-header.is-hidden { transform: translateY(-100%); box-shadow: none; }

.header__bar { position: relative; display: flex; align-items: center; gap: 1rem; min-height: var(--header-h); }
/* En-tête un peu plus large que le contenu : place pour les 5 rubriques, dont « Démarches administratives ». */
.site-header .container { --container: 80rem; }

.brand { display: inline-flex; flex: none; align-items: center; text-decoration: none; }
.brand__logo, .custom-logo { width: auto; height: 3.6rem; }


.header__actions { display: flex; align-items: center; gap: .5rem; margin-left: auto; }
.icon-btn {
	display: inline-grid; place-items: center; width: 2.75rem; height: 2.75rem; padding: 0;
	border: 2px solid var(--c-line); border-radius: 50%; background: var(--c-surface); color: var(--c-ink); cursor: pointer;
}
.icon-btn:hover, .icon-btn[aria-expanded="true"] { border-color: var(--c-ink); }
/* Raccourcis « appeler » et « écrire » : mêmes ronds que la loupe, l'icône aux couleurs du logo. */
a.icon-btn { text-decoration: none; }
.icon-btn--tel .icon { color: var(--c-green-dark); }
.icon-btn--write .icon { color: var(--c-blue); }
.icon-btn--write[aria-current="page"] { border-color: var(--c-blue); background: var(--c-blue-tint); }
/* Très petits écrans : on garde « appeler », « écrire » est dans le menu. */
@media (max-width: 30rem) { .icon-btn--write { display: none; } }
.nav-toggle {
	display: inline-flex; align-items: center; gap: .4rem; min-height: 2.75rem; padding: .4rem 1rem;
	border: 2px solid var(--c-line); border-radius: 999px; background: var(--c-surface); color: var(--c-ink);
	font: inherit; font-weight: 700; cursor: pointer;
}
.nav-toggle[aria-expanded="true"] { background: var(--c-ink); border-color: var(--c-ink); color: var(--c-on-ink); }

/* Recherche par mot-clé : un bandeau qui s'ouvre sous l'en-tête. */
.search-panel { border-top: 1px solid var(--c-line); background: var(--c-grey); }
/* « search-form » et non « search » : WordPress met la classe « search » sur le <body> des résultats. */
.search-form { display: flex; gap: .6rem; padding-block: 1rem; }
.search-form input {
	flex: 1; min-width: 0; height: 3rem; padding: 0 1.25rem; border: 2px solid var(--c-line); border-radius: 999px;
	font: inherit; color: var(--c-ink); background: var(--c-surface);
}
.search-form input:focus { border-color: var(--c-blue-logo); outline: 3px solid var(--c-blue-dark); outline-offset: 2px; }
.search-form--page { max-width: 40rem; padding-block: 0 2rem; }
@media (max-width: 30rem) { .search-form .btn { width: 3rem; padding: 0; font-size: 0; } .search-form .btn .icon { margin: 0; } }
/* Suggestions pendant la saisie : une liste de pages sous le champ, titre en gras puis la rubrique. */
.suggest__list { display: grid; margin: 0; padding: 0 0 1rem; list-style: none; }
.search-form--page + .suggest .suggest__list { max-width: 40rem; margin-top: -1.25rem; padding-bottom: 2rem; }
.suggest__list[hidden] { display: none; }
.suggest__list li + li { border-top: 1px solid var(--c-line); }
.suggest__link { display: grid; gap: .15rem; padding: .7rem 1rem; border-radius: 12px; color: var(--c-ink); text-decoration: none; }
.suggest__link:hover, .suggest__link:focus-visible { background: var(--c-surface); }
.suggest__link:focus-visible { outline: 3px solid var(--c-blue-dark); outline-offset: -3px; }
.suggest__title { font-weight: 700; text-decoration: underline; text-decoration-color: var(--c-line); text-underline-offset: .2em; }
.suggest__link:hover .suggest__title { text-decoration-color: currentColor; }
.suggest__meta { overflow: hidden; color: var(--c-muted); font-size: .95rem; text-overflow: ellipsis; white-space: nowrap; }
.suggest__empty { padding: .7rem 1rem; color: var(--c-muted); }
/* Petits écrans : le mot « Menu » reste écrit (les trois traits seuls ne parlent pas à tout le monde). */
@media (max-width: 30rem) {
	:root { --header-h: 4.25rem; }
	.header__bar { gap: .5rem; }
	.brand__logo, .custom-logo { height: 2.9rem; }
	.header__actions { gap: .4rem; }
	.nav-toggle { padding: .4rem .8rem; }
}
/* 360 px et moins : boutons et logo un peu plus petits pour que tout tienne sur une ligne. */
@media (max-width: 24rem) {
	.header__bar { gap: .35rem; }
	.header__actions { gap: .3rem; }
	.brand__logo, .custom-logo { height: 2.5rem; }
	.site-header .icon-btn { width: 2.5rem; height: 2.5rem; }
	.nav-toggle { min-height: 2.5rem; padding: .3rem .65rem; gap: .3rem; }
}

/* Navigation mobile : panneau sous l'en-tête */
.nav { display: none; }
.nav.is-open {
	display: block; position: absolute; left: 0; right: 0; top: 100%;
	max-height: calc(100vh - 7.5rem); overflow-y: auto; padding: .75rem var(--gutter) 1.5rem;
	background: var(--c-surface); border-bottom: 1px solid var(--c-line); box-shadow: 0 18px 30px rgba(0, 0, 0, .12);
	border-radius: 0 0 24px 24px;
}
.nav__list, .nav .sub-menu { margin: 0; padding: 0; list-style: none; }
.nav__list > li { border-bottom: 1px solid var(--c-line); }
.nav__list a { display: block; padding: .85rem .25rem; color: var(--c-ink); font-weight: 600; text-decoration: none; }
.nav__list a:hover, .nav__list .current-menu-item > a, .nav__list .current-menu-ancestor > a { color: var(--c-blue); }
.nav .menu-item-has-children { display: flex; flex-wrap: wrap; align-items: center; }
.nav .menu-item-has-children > a { flex: 1; }
.nav .sub-menu { display: none; flex-basis: 100%; padding: 0 0 .75rem 1rem; }
.nav .is-open > .sub-menu { display: block; }
.nav .sub-menu a { padding: .55rem .25rem; font-weight: 500; }
.nav__contact { width: 100%; margin-top: 1rem; }
/* Effet verre : le menu laisse deviner la page derrière, floutée. Sans flou (vieux navigateurs), il reste opaque. */
/* Même verre sombre que la pastille des horaires de l'accueil. Limité au panneau mobile (et au menu compact) : sur grand écran, le menu est dans l'en-tête blanc. */
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
	@media (max-width: 74.99rem) {
		.nav.is-open {
			background: rgba(10, 20, 30, .62); border-bottom-color: rgba(255, 255, 255, .35); box-shadow: 0 18px 40px -12px rgba(0, 0, 0, .5);
			-webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4);
		}
		.nav.is-open .nav__list > li { border-bottom-color: rgba(255, 255, 255, .22); }
		.nav.is-open .nav__list a, .nav.is-open .sub-toggle { color: #fff; }
		.nav.is-open .nav__list a:hover, .nav.is-open .nav__list .current-menu-item > a, .nav.is-open .nav__list .current-menu-ancestor > a { color: #cfe6ff; }
		.nav.is-open .sub-menu .menu-item-overview { border-bottom-color: rgba(255, 255, 255, .25); }
		.nav.is-open .menu-item-overview__hint { color: rgba(255, 255, 255, .78); }
		.nav.is-open :focus-visible { outline-color: #fff; }
	}
	html.nav-compact .nav.is-open {
		background: rgba(10, 20, 30, .62); border-bottom-color: rgba(255, 255, 255, .35); box-shadow: 0 18px 40px -12px rgba(0, 0, 0, .5);
		-webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4);
	}
	html.nav-compact .nav.is-open .nav__list > li { border-bottom-color: rgba(255, 255, 255, .22); }
	html.nav-compact .nav.is-open .nav__list a, html.nav-compact .nav.is-open .sub-toggle { color: #fff; }
	html.nav-compact .nav.is-open .nav__list a:hover, html.nav-compact .nav.is-open .nav__list .current-menu-item > a, html.nav-compact .nav.is-open .nav__list .current-menu-ancestor > a { color: #cfe6ff; }
	html.nav-compact .nav.is-open .sub-menu .menu-item-overview { border-bottom-color: rgba(255, 255, 255, .25); }
	html.nav-compact .nav.is-open .menu-item-overview__hint { color: rgba(255, 255, 255, .78); }
	html.nav-compact .nav.is-open :focus-visible { outline-color: #fff; }
}
/* Première ligne du menu déroulant : la page de la rubrique elle-même. */
.nav .sub-menu .menu-item-overview { margin-bottom: .35rem; padding-bottom: .35rem; border-bottom: 1px solid var(--c-line); }
.nav .sub-menu .menu-item-overview > a { font-weight: 700; }
.menu-item-overview__title, .menu-item-overview__hint { display: block; }
.menu-item-overview__hint { margin-top: .1rem; color: var(--c-muted); font-size: .85rem; font-weight: 500; }

.sub-toggle {
	display: grid; place-items: center; width: 2.75rem; height: 2.75rem; padding: 0;
	border: 0; background: transparent; color: var(--c-ink); cursor: pointer;
}
.sub-toggle::after {
	content: ""; width: .55rem; height: .55rem; margin-top: -.25rem;
	border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg); transition: transform .2s;
}
.sub-toggle[aria-expanded="true"]::after { margin-top: .2rem; transform: rotate(-135deg); }

/* Menu complet à partir de 1200 px : en dessous, les 5 rubriques et les boutons « appeler », « écrire », « rechercher » ne tiennent pas sur une ligne. */
@media (min-width: 75rem) {
	:where(html:not(.nav-compact)) .nav-toggle, :where(html:not(.nav-compact)) .nav__contact { display: none; }
	:where(html:not(.nav-compact)) .nav, :where(html:not(.nav-compact)) .nav.is-open { display: block; position: static; flex: 1; max-height: none; overflow: visible; padding: 0; background: none; border: 0; box-shadow: none; }
	/* Rubriques : soulignement aux couleurs du logo qui s'étire au survol et reste sous la rubrique en cours. */
	:where(html:not(.nav-compact)) .nav__list { display: flex; justify-content: center; gap: 0; }
	:where(html:not(.nav-compact)) .nav__list > li { position: relative; border: 0; }
	:where(html:not(.nav-compact)) .nav__list > li > a { position: relative; padding: .7rem .6rem; font-weight: 700; white-space: nowrap; }
	:where(html:not(.nav-compact)) .nav__list > li > a::after {
		content: ""; position: absolute; left: .6rem; right: .6rem; bottom: .25rem; height: 3px; border-radius: 3px;
		background: var(--logo-band); transform: scaleX(0); transition: transform .25s ease;
	}
	:where(html:not(.nav-compact)) .nav__list > li:hover > a, :where(html:not(.nav-compact)) .nav__list > li:focus-within > a { color: var(--c-ink); }
	:where(html:not(.nav-compact)) .nav__list > li:hover > a::after, :where(html:not(.nav-compact)) .nav__list > li:focus-within > a::after, :where(html:not(.nav-compact)) .nav__list > .current-menu-item > a::after, :where(html:not(.nav-compact)) .nav__list > .current-menu-ancestor > a::after, :where(html:not(.nav-compact)) .nav__list > .current-page-ancestor > a::after { transform: scaleX(1); }
	:where(html:not(.nav-compact)) .nav .menu-item-has-children { display: block; }
	/* Petit chevron pour les rubriques qui ont des pages. */
	:where(html:not(.nav-compact)) .nav__list > .menu-item-has-children > a { padding-right: 1.45rem; }
	:where(html:not(.nav-compact)) .nav__list > .menu-item-has-children > a::before {
		content: ""; position: absolute; right: .55rem; top: 50%; width: .4rem; height: .4rem;
		border: solid currentColor; border-width: 0 2px 2px 0; transform: translateY(-75%) rotate(45deg); transition: transform .25s;
	}
	:where(html:not(.nav-compact)) .nav__list > .menu-item-has-children:hover > a::before, :where(html:not(.nav-compact)) .nav__list > .menu-item-has-children:focus-within > a::before { transform: translateY(-25%) rotate(-135deg); }
	:where(html:not(.nav-compact)) .sub-toggle { display: none; }
	/* Menu déroulant : une carte qui glisse doucement, avec une pointe vers la rubrique. */
	:where(html:not(.nav-compact)) .nav .sub-menu {
		display: block; position: absolute; left: 50%; top: calc(100% + .6rem); z-index: 10; min-width: 17rem; padding: .6rem;
		background: var(--c-surface); border: 1px solid var(--c-line); border-radius: 22px; box-shadow: 0 24px 48px -16px rgba(0, 0, 0, .22);
		opacity: 0; visibility: hidden; transform: translate(-50%, 8px);
		transition: opacity .2s ease, transform .2s ease, visibility 0s linear .2s;
	}
	:where(html:not(.nav-compact)) .nav .sub-menu::before {
		content: ""; position: absolute; top: -8px; left: 50%; width: 14px; height: 14px;
		background: var(--c-surface); border: solid var(--c-line); border-width: 1px 0 0 1px; transform: translateX(-50%) rotate(45deg);
	}
	/* Pont invisible : la souris peut descendre vers le menu sans qu'il se referme. */
	:where(html:not(.nav-compact)) .nav__list > .menu-item-has-children::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: .8rem; }
	@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
		/* Même verre sombre que la pastille des horaires de l'accueil. */
		:where(html:not(.nav-compact)) .nav .sub-menu {
			background: rgba(10, 20, 30, .62); border-color: rgba(255, 255, 255, .35); border-radius: 24px;
			box-shadow: 0 18px 40px -12px rgba(0, 0, 0, .5);
			-webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4);
		}
		/* « .sub-menu li > a » : plus précis que les règles du menu clair écrites plus bas. */
		:where(html:not(.nav-compact)) .nav .sub-menu li > a { color: #fff; }
		:where(html:not(.nav-compact)) .nav .sub-menu li > a:hover, :where(html:not(.nav-compact)) .nav .sub-menu li > a:focus-visible,
		:where(html:not(.nav-compact)) .nav .sub-menu li.current-menu-item > a { background: rgba(255, 255, 255, .16); color: #fff; }
		:where(html:not(.nav-compact)) .nav .sub-menu li.current-menu-item > a { box-shadow: inset 3px 0 0 #fff; }
		:where(html:not(.nav-compact)) .nav .sub-menu li > a:focus-visible { outline-color: #fff; }
		:where(html:not(.nav-compact)) .nav .sub-menu .menu-item-overview { border-bottom-color: rgba(255, 255, 255, .25); }
		:where(html:not(.nav-compact)) .nav .sub-menu .menu-item-overview__hint { color: rgba(255, 255, 255, .78); }
		/* La pointe est cachée : un petit carré flouté à part ne se raccorde pas proprement à la carte. */
		:where(html:not(.nav-compact)) .nav .sub-menu::before { display: none; }
	}
	:where(html:not(.nav-compact)) .nav .menu-item-has-children:hover > .sub-menu, :where(html:not(.nav-compact)) .nav .menu-item-has-children:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: translate(-50%, 0); transition-delay: 0s; }
	:where(html:not(.nav-compact)) .nav .sub-menu a { display: block; padding: .6rem .85rem; border-radius: 14px; font-weight: 600; white-space: nowrap; }
	:where(html:not(.nav-compact)) .nav .sub-menu a:hover, :where(html:not(.nav-compact)) .nav .sub-menu a:focus-visible { background: var(--c-blue-tint); color: var(--c-blue); }
	:where(html:not(.nav-compact)) .nav .sub-menu .current-menu-item > a { background: var(--c-blue-tint); color: var(--c-blue); box-shadow: inset 3px 0 0 var(--c-blue-logo); }
}

/* 6. Accueil -------------------------------------------------------------- */
/* Le seul moment « spectaculaire » du site : les photos du village en fondu enchaîné,
   qui défilent un peu plus lentement que la page (main.js), et la vague du logo.
   Tout le reste de la page reste calme. */
.home-hero {
	position: relative; display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden;
	min-height: clamp(28rem, 82vh, 50rem); background: #000; color: #fff;
}
.home-hero__media { position: absolute; inset: -6% 0 0; will-change: transform; }
.slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.4s ease; }
.slide.is-active { opacity: 1; }
.slide img { width: 100%; height: 100%; object-fit: cover; object-position: center 60%; }
.home-hero__media::after {
	content: ""; position: absolute; inset: 0;
	/* Voile mesuré (RGAA 3.2) : texte blanc ≥ 4,5:1 sur toutes les photos, même claires (ciel, façade). */
	background: linear-gradient(to top, rgba(0, 0, 0, .82) 0%, rgba(0, 0, 0, .55) 45%, rgba(0, 0, 0, .12) 80%), linear-gradient(to right, rgba(0, 0, 0, .5), rgba(0, 0, 0, 0) 65%);
}
.home-hero__text { position: relative; z-index: 1; padding-bottom: clamp(1.5rem, 4vw, 2.5rem); will-change: transform, opacity; }
/* Météo : pastille en verre (flou, reflet clair sur le bord haut), icône en couleur. Teinte sombre pour rester lisible sur un ciel clair. */
.weather-glass {
	position: relative; display: inline-flex; align-items: center; gap: .55rem; margin: 0 0 1rem; padding: .4rem 1.1rem .4rem .55rem;
	border-radius: 999px; color: #fff; font-weight: 700; line-height: 1.2; text-shadow: 0 1px 6px rgba(0, 0, 0, .35);
	background: linear-gradient(135deg, rgba(255, 255, 255, .26), rgba(255, 255, 255, .06) 55%), rgba(12, 22, 32, .42);
	-webkit-backdrop-filter: blur(14px) saturate(1.6); backdrop-filter: blur(14px) saturate(1.6);
	border: 1px solid rgba(255, 255, 255, .42);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55), inset 0 -1px 0 rgba(255, 255, 255, .12), 0 10px 30px -10px rgba(0, 0, 0, .45);
}
.weather-glass__icon { flex: none; width: 2rem; height: 2rem; filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .25)); }
.weather-glass__temp { font-size: 1.15rem; }
.weather-glass__label { padding-left: .55rem; border-left: 1px solid rgba(255, 255, 255, .45); font-weight: 600; }
@media (max-width: 48rem) { .weather-glass { margin-top: 1.1rem; } }
.home-hero__text h1 { margin-bottom: .3em; color: #fff; font-size: clamp(2.6rem, 6.5vw, 4.4rem); line-height: 1.02; text-shadow: 0 2px 24px rgba(0, 0, 0, .25); }
.home-hero__text .lead { max-width: 34rem; margin: 0; color: rgba(255, 255, 255, .92); font-size: clamp(1.05rem, 1.6vw, 1.25rem); }
.home-hero__bar {
	position: relative; z-index: 1; display: flex; align-items: center; gap: .5rem 1rem;
	padding-block: .5rem clamp(4.5rem, 10vw, 9rem);
}

/* La vague du logo : transition douce vers la suite de la page. */
.hero-wave {
	position: absolute; left: 0; bottom: -2px; z-index: 2; width: 100%; max-width: none; height: clamp(60px, 10vw, 150px);
	pointer-events: none;
}

/* Pastille en verre fumé : ouvert / fermé en direct, téléphone, lien vers les horaires. */
.hero-status {
	position: absolute; z-index: 3; top: clamp(1rem, 3vw, 2.25rem); right: max(1rem, calc((100vw - var(--container)) / 2));
	display: grid; gap: .5rem; width: min(22rem, calc(100% - 2rem)); padding: 1.1rem 1.35rem;
	border: 1px solid rgba(255, 255, 255, .35); border-radius: 24px;
	background: rgba(10, 20, 30, .62); -webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4);
	box-shadow: 0 18px 40px -12px rgba(0, 0, 0, .5); color: #fff;
}
/* Le nom au-dessus, l'état en dessous : les deux lignes se lisent de la même façon. */
.hero-status__row { display: grid; gap: .1rem; margin: 0; }
.hero-status__row + .hero-status__row { margin-top: .35rem; }
.hero-status__state { display: inline-flex; align-items: center; gap: .45rem; opacity: .92; }
.hero-status__state::before { content: ""; width: .65rem; height: .65rem; border-radius: 50%; background: rgba(255, 255, 255, .6); box-shadow: 0 0 0 4px rgba(255, 255, 255, .15); }
.hero-status__state.status--open, .hero-status__state.status--closed { background: none; color: #fff; }
.hero-status__state.status--open::before { background: var(--c-green); }
.hero-status__state.status--closed::before { background: #ff5a68; }
.hero-status__tel {
	display: flex; align-items: center; gap: .5rem; margin-top: .2rem; padding-top: .6rem;
	border-top: 1px solid rgba(255, 255, 255, .28); color: #fff; font-size: 1.3rem; font-weight: 700; text-decoration: none;
}
.hero-status__tel .icon { color: var(--c-green); }
.hero-status__more { color: #fff; font-size: 1rem; font-weight: 700; text-underline-offset: .25em; }
.hero-status a:hover { color: #fff; }
/* Sur téléphone, la pastille prend sa place sous le texte d'accueil, sans rien recouvrir. */
@media (max-width: 47.99rem) {
	/* Compacte : deux lignes « ● Mairie  Fermé, ouvre demain à 9h00 », pour laisser voir la photo.
	   Le téléphone est déjà dans l'en-tête et les horaires juste en dessous. */
	.hero-status {
		position: relative; top: auto; right: auto; z-index: 1; align-self: flex-start; width: auto; max-width: calc(100% - 2 * var(--gutter));
		margin: 0 var(--gutter) .25rem; padding: .5rem .85rem; gap: .2rem; border-radius: 14px; background: rgba(10, 20, 30, .55); font-size: .95rem; line-height: 1.3;
	}
	.hero-status__row { display: flex; flex-wrap: wrap; align-items: center; gap: 0 .5rem; }
	.hero-status__row + .hero-status__row { margin-top: 0; }
	.hero-status__state::before { width: .55rem; height: .55rem; box-shadow: 0 0 0 3px rgba(255, 255, 255, .15); }
	.hero-status__tel, .hero-status__more { display: none; }
	.home-hero__text .lead { font-size: 1rem; }
}
.slide-caption { display: flex; flex: 1; align-items: center; gap: .45rem; min-width: 0; margin: 0; font-size: .95rem; font-weight: 600; color: rgba(255, 255, 255, .9); }
/* Sur téléphone, une légende longue passe sur deux lignes au lieu d'être coupée par « … ». */
.slide-caption span { line-height: 1.25; overflow-wrap: anywhere; }
.slide-caption .icon { width: 1.05rem; height: 1.05rem; color: var(--c-green); }
.slide-dots { display: flex; flex: none; }
.slide-dots button { display: grid; place-items: center; width: 2.4rem; height: 2.4rem; padding: 0; border: 0; background: none; cursor: pointer; }
.slide-dots button::before { content: ""; width: .7rem; height: .7rem; border-radius: 999px; background: rgba(255, 255, 255, .5); transition: width .4s, background-color .4s; }
.slide-dots button[aria-current="true"]::before { width: 1.9rem; background: #fff; }
@media (max-width: 30rem) { .slide-dots button { width: 1.6rem; } .slide-dots button[aria-current="true"]::before { width: 1.2rem; } }
.slide-pause {
	display: grid; flex: none; place-items: center; width: 2.6rem; height: 2.6rem; padding: 0;
	border: 2px solid rgba(255, 255, 255, .6); border-radius: 50%; background: rgba(0, 0, 0, .25); cursor: pointer;
}
.slide-pause:hover { border-color: #fff; }
.slide-pause__icon { display: block; width: .7rem; height: .8rem; border: solid #fff; border-width: 0 3px; }
.slide-pause.is-paused .slide-pause__icon { width: 0; height: 0; margin-left: .2rem; border-width: .42rem 0 .42rem .7rem; border-color: transparent transparent transparent #fff; }

/* Mairie et agence postale : un seul bloc en deux colonnes, la semaine visible d'emblée.
   L'état ouvert / fermé est déjà dans la pastille du haut : ici, la ligne du jour est surlignée. */
.offices {
	display: grid; background: var(--c-surface); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden;
}
@media (min-width: 52rem) { .offices { grid-template-columns: 1fr 1fr; } }
.office { display: flex; flex-direction: column; padding: clamp(1.5rem, 3.5vw, 2.5rem); }
.office + .office { border-top: 1px solid var(--c-line); }
@media (min-width: 52rem) { .office + .office { border-top: 0; border-left: 1px solid var(--c-line); } }
.office__name { margin-bottom: 1rem; }
.office .contact-card { margin: 0 0 1.5rem; }
.office .contact-list { gap: .6rem; }
.office .contact-list a[href^="tel:"] { font-size: 1.35rem; font-weight: 700; }
.office__hours-title { margin: 0 0 .5rem; font-size: 1.15rem; }
/* Téléphone : le bouton « Voir les horaires » remplace le titre à l'écran (le titre reste pour la lecture vocale). */
.office__hours-title:has(+ .reveal-btn:not([hidden])) {
	position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.office .reveal-btn { align-self: flex-start; margin: 0; }
.office .reveal-btn[aria-expanded="true"] { margin-bottom: 1rem; }
.know__mail { overflow-wrap: anywhere; }
.office .hours .status { display: none !important; }   /* déjà affiché dans la pastille du haut */
.office .hours-table { margin-bottom: 0; }
.offices__write { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.25rem; margin: 1.5rem 0 0; }

/* La dernière section grise touche directement le pied de page (gris lui aussi) : pas de bande blanche entre les deux. */
main:has(> .section--tint:last-child) + .site-footer { margin-top: 0; }

.tiles { display: grid; gap: .75rem; margin: 0; padding: 0; list-style: none; }
@media (min-width: 36rem) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 56rem) { .tiles { grid-template-columns: repeat(3, 1fr); } }
.tile {
	display: flex; align-items: center; gap: .9rem; height: 100%; padding: .9rem 1rem;
	background: var(--c-surface); border: 1px solid var(--c-line); border-radius: var(--radius-lg);
	color: var(--c-ink); text-decoration: none; transition: border-color .2s, background-color .2s;
}
.tile:hover { border-color: var(--c-blue-logo); background: var(--c-blue-tint); color: var(--c-ink); }
.tile__icon {
	display: grid; flex: none; place-items: center; width: 2.75rem; height: 2.75rem;
	border-radius: var(--radius); background: var(--c-blue-tint); color: var(--c-blue);
}
.tile:hover .tile__icon { background: var(--c-surface); }
.tile__icon .icon { width: 1.45rem; height: 1.45rem; }
.tile__label { flex: 1; font-weight: 700; line-height: 1.25; }
.tile > .icon { color: var(--c-muted); transition: transform .2s; }
.tile:hover > .icon { color: var(--c-blue); transform: translateX(3px); }

/* 7. Panneaux, horaires, coordonnées -------------------------------------- */
.panel { padding: clamp(1.25rem, 3vw, 1.75rem); background: var(--c-surface); border: 1px solid var(--c-line); border-radius: var(--radius-lg); }
.panel h3, .entry .panel__title { display: flex; align-items: center; gap: .6rem; margin: 0 0 1rem; font-size: 1.3rem; }
.panel h3 .icon, .panel__title .icon { color: var(--c-blue); width: 1.5rem; height: 1.5rem; }
/* Bloc « Quand venir / Où » (Luanthèque, marché, santé) : un seul bloc à filets, deux parties (côte à côte dès 40rem). */
.entry .place { display: grid; align-items: stretch; gap: 1px; margin: 1.5rem 0 2.5rem; overflow: hidden; background: var(--c-line); border: 1px solid var(--c-line); border-radius: var(--radius-lg); }
.entry .place__part { margin: 0; padding: clamp(1.25rem, 3vw, 1.75rem); background: var(--c-surface); }
.place__part > :last-child, .place__part .hours-table { margin-bottom: 0; }
.entry .place__part p { margin: 0 0 .75rem; }
.place__addr { font-weight: 700; }
.hours__closed { margin: .75rem 0 0; color: var(--c-muted); }
/* Numéros à appeler : le numéro en grand, le libellé dessous. */
.place__calls { display: grid; gap: .5rem; margin: 0; padding: 0; list-style: none; }
.entry .place__calls li { margin: 0; }
.place__calls a { display: grid; gap: .1rem; padding: .7rem 1rem; border-radius: var(--radius); background: var(--c-red-tint); color: var(--c-ink); font-weight: 600; line-height: 1.3; text-decoration: none; }
.place__calls a:hover { background: var(--c-calls-hover); }
.place__num { color: var(--c-red-dark); font-size: 1.45rem; font-weight: 700; }
/* École, centre de loisirs : téléphone, e-mail, grandes heures, liste des périodes. */
.place__tel, .place__mail { display: inline-flex; align-items: center; gap: .55rem; font-weight: 700; overflow-wrap: anywhere; }
.place__tel { font-size: 1.35rem; }
.place__tel .icon, .place__mail .icon { flex: none; width: 1.25rem; height: 1.25rem; color: var(--c-blue); }
.entry .place__big { margin-bottom: .5rem; font-size: 1.35rem; font-weight: 700; }
.entry .place__list { margin: 0; padding-left: 1.2rem; }
.entry .place__list li { margin: 0 0 .3rem; }
@media (min-width: 40rem) { .entry .place { grid-template-columns: 1fr 1fr; } }
/* Deux photos de même hauteur : colonnes proportionnelles aux formats (3:4 et 4:3). */
.luantheque-photos { display: grid; grid-template-columns: 9fr 16fr; gap: .75rem; margin: 0 0 2.5rem; }
.luantheque-photos img { display: block; width: 100%; height: auto; border-radius: var(--radius-lg); }
.luantheque-photos figcaption { grid-column: 1 / -1; color: var(--c-muted); font-size: .95rem; }
/* Rangée de photos dans le texte d'une page ([luant_photos]) : cases de même format, recadrées. */
.photo-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: .75rem; margin: 1.5rem 0 2.5rem; }
.photo-row img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--radius-lg); }

.hours-table { width: 100%; margin: 0 0 1rem; border-collapse: collapse; font-size: .97rem; }
.hours-table th, .hours-table td { padding: .45rem .6rem; border-bottom: 1px solid var(--c-line); text-align: left; vertical-align: top; }
.hours-table th { width: 7.5rem; font-weight: 600; }
@media (max-width: 30rem) { .hours-table th { width: 6rem; } }
.hours-table tr:last-child th, .hours-table tr:last-child td { border-bottom: 0; }
.hours-range { white-space: nowrap; }
.hours-table .is-today th, .hours-table .is-today td { background: var(--c-blue-tint); font-weight: 700; }
.hours-table .is-today th { box-shadow: inset 4px 0 0 var(--c-blue-logo); }

.status {
	display: inline-flex; align-items: center; gap: .5rem; margin: 0 0 .85rem; padding: .3rem .85rem;
	border-radius: 999px; background: var(--c-grey-dark); color: var(--c-ink); font-size: .9rem; font-weight: 600;
}
.status::before { content: ""; width: .55rem; height: .55rem; border-radius: 50%; background: var(--c-muted); }
.status--open { background: var(--c-green-tint); color: var(--c-green-dark); }
.status--open::before { background: var(--c-green); }
.status--closed { background: var(--c-red-tint); color: var(--c-red-dark); }
.status--closed::before { background: var(--c-red); }

.contact-card { margin: 0 0 1.25rem; }
.contact-card__name { margin: 0 0 .5rem; font-size: 1.1rem; font-weight: 700; line-height: 1.25; }
.contact-card__note { margin: .75rem 0 0; padding: .75rem 1rem; border-radius: var(--radius); background: var(--c-grey); font-size: .95rem; }
.contact-list { display: grid; gap: .45rem; margin: 0 0 1rem; padding: 0; list-style: none; }
.contact-list li { display: flex; align-items: flex-start; gap: .6rem; }
.contact-list .icon { margin-top: .2rem; color: var(--c-blue); width: 1.1rem; height: 1.1rem; }
.contact-list a { font-weight: 600; word-break: break-word; }

/* Lien « Y aller » : ouvre l'itinéraire dans Google Maps (ou Plans sur appareil Apple). */
/* Juste la flèche verte du logo et le texte, sans fond ; au survol, seule la flèche avance. */
.go-btn {
	display: inline-flex; align-items: center; gap: .55rem;
	min-height: 2.75rem; padding: 0; border: 0; background: none;
	font: inherit; font-size: 1.0625rem; font-weight: 700; line-height: 1.2;
	text-decoration: none; white-space: nowrap; cursor: pointer;
}
.go-btn.go-btn, .go-btn.go-btn:visited, .go-btn.go-btn:hover { color: inherit; text-decoration: none; }
.go-btn__icon { display: inline-flex; flex: none; transition: transform .25s cubic-bezier(.2, .8, .2, 1); }
.go-btn .icon { width: 1.6rem; height: 1.6rem; margin: 0 !important; color: var(--c-green-dark) !important; fill: var(--c-green); stroke-width: 1.6; }
.go-btn:hover .go-btn__icon, .go-btn:focus-visible .go-btn__icon { transform: translate(3px, -3px); }
@media (prefers-reduced-motion: reduce) { .go-btn__icon { transition: none; } .go-btn:hover .go-btn__icon, .go-btn:focus-visible .go-btn__icon { transform: none; } }
.contact-list a.go-btn { word-break: normal; font-weight: 700; }
/* Dans les listes de coordonnées, le lien passe sous l'adresse. */
.contact-list__addr .go-btn { display: flex; width: max-content; margin-top: .25rem; }

/* 8. Cartes --------------------------------------------------------------- */
.cards { display: grid; gap: var(--gap); }
@media (min-width: 40rem) { .cards--2, .cards--3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 64rem) { .cards--3 { grid-template-columns: repeat(3, 1fr); } }
/* Cartes avec icône : un seul bloc blanc à filets, comme « Vous cherchez » sur l'accueil.
   2 cases par ligne (la dernière prend toute la ligne si elle est seule), puis toutes sur une ligne
   quand il y a la place (cards--n3, n4, n5 = nombre de cases). Toute la case est cliquable. */
.cards--icons {
	gap: 1px; background: var(--c-line); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden;
}
@media (min-width: 40rem) {
	.cards--icons { grid-template-columns: repeat(2, 1fr); }
	.cards--icons .card:last-child:nth-child(odd) { grid-column: 1 / -1; }
}
@media (min-width: 52rem) { .cards--n3 { grid-template-columns: repeat(3, 1fr); } .cards--n3 .card:last-child:nth-child(odd) { grid-column: auto; } }
@media (min-width: 64rem) { .cards--n4 { grid-template-columns: repeat(4, 1fr); } }
/* 7 cases (Démarches) : 4 par ligne, la dernière prend 2 places pour ne pas laisser de case vide. */
@media (min-width: 64rem) { .cards--n7 { grid-template-columns: repeat(4, 1fr); } .cards--n7 .card:last-child:nth-child(odd) { grid-column: span 2; } }
@media (min-width: 72rem) { .cards--n5 { grid-template-columns: repeat(5, 1fr); } .cards--n5 .card:last-child:nth-child(odd) { grid-column: auto; } }
.cards--icons .card { border: 0; border-radius: 0; transition: background-color .2s; }
.cards--icons .card:hover { background: var(--c-blue-tint); box-shadow: none; }
.cards--icons .card:focus-within { outline-offset: -3px; }
.cards--icons .card__body { gap: .45rem; padding: clamp(1.25rem, 2.5vw, 1.6rem); }
/* Même rond bleu que les autres blocs du site. */
.cards--icons .card__icon { width: 3rem; height: 3rem; margin-bottom: .5rem; border-radius: 50%; }
.cards--icons .card__icon .icon { width: 1.4rem; height: 1.4rem; }
.cards--icons .card__title { font-size: clamp(1.15rem, 1.6vw, 1.25rem); }
/* Téléphone : l'icône à gauche du texte, pour une liste plus courte. */
@media (max-width: 39.99rem) {
	.cards--icons .card__body { display: grid; grid-template-columns: 3rem minmax(0, 1fr); align-content: start; column-gap: 1rem; row-gap: .35rem; }
	.cards--icons .card__icon { grid-row: 1 / span 4; margin: 0; }
	.cards--icons .card__body > :not(.card__icon) { grid-column: 2; }
	.cards--icons .card__more { padding-top: .2rem; }
}

/* Haut des rubriques avec photo : une phrase d'accueil un peu plus grande, puis les cases. */
.rubrique__intro { max-width: 40rem; margin-bottom: clamp(1.5rem, 3vw, 2rem); }
.rubrique__intro p { font-size: clamp(1.15rem, 1.8vw, 1.35rem); font-weight: 500; line-height: 1.55; }

/* L'essentiel dans la case (Vivre à Luant) : téléphones et horaires, séparés du résumé par un filet.
   Les numéros restent cliquables au-dessus du lien qui couvre toute la case. */
.card__facts { display: grid; gap: .5rem; margin: .4rem 0 0; padding: .75rem 0 0; border-top: 1px solid var(--c-line); list-style: none; font-size: 1rem; }
.card__fact-label { display: block; color: var(--c-muted); font-size: .88rem; }
.card__facts a { position: relative; z-index: 1; font-weight: 700; }
.card__fact-note { color: var(--c-muted); font-size: .9rem; }
/* Carte Associations : une rangée de logos qui se chevauchent, le dernier rond donne le nombre restant. */
.card__facts--assos p { margin: 0; }
.card__faces { display: flex; padding-left: .1rem; }
.card__face {
	display: grid; flex: none; place-items: center; width: 2.4rem; height: 2.4rem; overflow: hidden;
	border: 2px solid var(--c-surface); border-radius: 50%; background: var(--c-surface); box-shadow: 0 0 0 1px var(--c-line);
}
.card__face + .card__face { margin-left: -.55rem; }
.card__face img { width: 100%; height: 100%; border-radius: 0; object-fit: contain; }
.card__face--icon { background: var(--c-blue-tint); color: var(--c-blue); }
.card__face--icon .icon { width: 1.2rem; height: 1.2rem; }
.card__face--more { background: var(--c-blue); color: var(--c-on-blue); font-size: .85rem; font-weight: 700; }

.card {
	position: relative; display: flex; flex-direction: column; overflow: hidden;
	background: var(--c-surface); border: 1px solid var(--c-line); border-radius: var(--radius-lg);
	transition: box-shadow .2s, border-color .2s;
}
.card:hover { box-shadow: var(--shadow); border-color: var(--c-blue-logo); }
.card:focus-within { outline: 3px solid var(--c-blue-logo); outline-offset: 3px; }
.card__media { aspect-ratio: 3 / 2; overflow: hidden; background: var(--c-grey-dark); }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.card:hover .card__media img { transform: scale(1.03); }
.card__body { display: flex; flex: 1; flex-direction: column; gap: .5rem; padding: 1.2rem 1.3rem 1.3rem; }
.card__title { margin: 0; font-size: 1.15rem; }
.card__link { color: inherit; text-decoration: none; }
.card__link::after { content: ""; position: absolute; inset: 0; }   /* lien étendu à toute la carte */
.card__link:focus-visible { outline: none; }
.card__text { margin: 0; color: var(--c-muted); font-size: .97rem; }
/* Cartes 2 par ligne : photo à gauche, texte à droite, pour prendre moins de hauteur. */
.cards--2 .card--photo { flex-direction: row; }
.cards--2 .card--photo .card__media { flex: 0 0 clamp(6.5rem, 36%, 13rem); aspect-ratio: auto; min-height: 8.5rem; position: relative; }
.cards--2 .card--photo .card__media img { position: absolute; inset: 0; }   /* la photo suit la hauteur du texte, pas l'inverse */
.cards--2 .card--photo .card__body { padding: 1rem 1.1rem 1.1rem; }
.cards--2 .card__title { font-size: clamp(1.1rem, 1.6vw, 1.3rem); }
.cards--2 .card__text { font-size: 1rem; }
.card__more { display: inline-flex; align-items: center; gap: .4rem; margin-top: auto; padding-top: .5rem; color: var(--c-blue); font-weight: 700; font-size: .95rem; }
.card__icon {
	display: grid; place-items: center; width: 2.9rem; height: 2.9rem; border-radius: var(--radius);
	background: var(--c-blue-tint); color: var(--c-blue);
}
.card__icon .icon { width: 1.5rem; height: 1.5rem; }

/* 9. Pages intérieures ---------------------------------------------------- */
.page-hero { padding-block: clamp(1.5rem, 4vw, 2.75rem) clamp(1.25rem, 3vw, 2rem); background: var(--c-grey); }
.page-hero h1 { margin-bottom: .3em; }
.page-hero .lead { margin: 0; }

/* Ma mairie : la photo de la façade à côté du titre, et l'ouverture du jour juste dessous. */
/* Ma mairie : le haut de page de l'accueil (photo, vague, même hauteur), avec une seule photo et sans pastille. */
.home-hero--page .home-hero__media img { width: 100%; height: 100%; object-fit: cover; object-position: center 55%; }
.home-hero--page .home-hero__text { padding-bottom: clamp(4.5rem, 10vw, 9rem); }
.home-hero--page .breadcrumbs { color: #fff; }
.home-hero--page .breadcrumbs a, .home-hero--page .breadcrumbs li + li::before { color: rgba(255, 255, 255, .9); }
.home-hero--page .breadcrumbs a:hover { color: #fff; }
.home-hero--page + .section { padding-top: clamp(1rem, 2.5vw, 1.75rem); }   /* la vague fait déjà l'espace */
@media (max-width: 47.99rem) {
	/* Sur téléphone : une photo moins haute (seul le titre est dessus), assombrie pour que le texte reste lisible sur la façade claire. */
	.home-hero--page { min-height: clamp(22rem, 64vh, 30rem); }
}
/* Sur téléphone, le texte couvre presque toute la photo : voile plus régulier, du bas jusqu'en haut (RGAA 3.2). */
@media (max-width: 47.99rem) {
	:is(.home-hero--page, .home-hero--sub) .home-hero__media::after { background: linear-gradient(to top, rgba(0, 0, 0, .82) 0%, rgba(0, 0, 0, .6) 55%, rgba(0, 0, 0, .4) 100%); }
}
/* Sous-pages avec photo : un bandeau moins haut que les rubriques, la vague se fond dans le blanc de la page. */
.home-hero--sub { min-height: clamp(24rem, 64vh, 38rem); }
.home-hero--sub .home-hero__text h1 { font-size: clamp(2.1rem, 4.6vw, 3.3rem); }
.home-hero--sub .home-hero__text { padding-bottom: clamp(4rem, 8vw, 7.5rem); }
.home-hero--sub + .layout { padding-top: clamp(1rem, 2.5vw, 1.75rem); }
@media (max-width: 47.99rem) { .home-hero--sub { min-height: clamp(18rem, 54vh, 24rem); } }

.section__title { margin: 0 0 clamp(1.25rem, 3vw, 1.75rem); }

/* Liens vers les sous-pages : une ligne entière cliquable, deux par ligne sur grand écran. */
.link-rows { display: grid; gap: 1rem; margin: 0; padding: 0; list-style: none; }
@media (min-width: 48rem) { .link-rows { grid-template-columns: repeat(2, 1fr); } }
.link-row {
	position: relative; display: flex; align-items: flex-start; gap: 1rem; padding: 1.25rem 1.4rem;
	border: 1px solid var(--c-line); border-radius: 22px; background: var(--c-surface); transition: border-color .2s, background-color .2s;
}
.link-row:hover { border-color: var(--c-blue-logo); background: var(--c-blue-tint); }
.link-row:focus-within { outline: 3px solid var(--c-blue-logo); outline-offset: 3px; }
.link-row__icon, .know__icon {
	display: grid; flex: none; place-items: center; width: 3rem; height: 3rem; border-radius: 50%;
	background: var(--c-blue-tint); color: var(--c-blue);
}
.link-row:hover .link-row__icon { background: var(--c-surface); }
.link-row__icon .icon, .know__icon .icon { width: 1.4rem; height: 1.4rem; }
.link-row__text { display: grid; gap: .25rem; padding-top: .2rem; }
.link-row__link { color: var(--c-ink); font-size: 1.25rem; font-weight: 700; line-height: 1.25; text-decoration: none; }
.link-row__link::after { content: ""; position: absolute; inset: 0; }   /* toute la ligne est cliquable */
.link-row__link:focus-visible { outline: none; }
.link-row__desc { color: var(--c-muted); }

/* Ma mairie : le maire et l'accès à la mairie, dans le même bloc en deux colonnes que « Mairie et agence postale » sur l'accueil. */
.know {
	display: grid; grid-template-columns: minmax(0, 1fr); background: var(--c-surface); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden;
}
@media (min-width: 52rem) { .know { grid-template-columns: 1fr 1fr; } }
.know__item { overflow-wrap: break-word; display: flex; flex-direction: column; padding: clamp(1.5rem, 3.5vw, 2.5rem); }
.know__item + .know__item { border-top: 1px solid var(--c-line); }
@media (min-width: 52rem) { .know__item + .know__item { border-top: 0; border-left: 1px solid var(--c-line); } }
/* Trois blocs : empilés jusqu'à ce qu'ils tiennent sur une ligne. */
@media (min-width: 52rem) and (max-width: 63.99rem) {
	.know--3 { grid-template-columns: minmax(0, 1fr); }
	.know--3 .know__item + .know__item { border-left: 0; border-top: 1px solid var(--c-line); }
}
@media (min-width: 64rem) { .know--3 { grid-template-columns: repeat(3, 1fr); } }
.know__title { display: flex; align-items: center; gap: .85rem; margin: 0 0 1.1rem; font-size: clamp(1.35rem, 2.4vw, 1.6rem); }
.know__item p { margin: 0 0 .75rem; }
.know__name { font-size: 1.1rem; font-weight: 700; }
/* Les boutons restent en bas de chaque colonne, alignés d'une colonne à l'autre. */
.know__actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.25rem; margin: auto 0 0 !important; padding-top: .75rem; }
.know__more { max-width: 46rem; margin-block: 2.5rem 0; }
.know__more > :first-child { margin-top: 0; }

/* Portraits du maire et des adjoints, en une rangée régulière. */
.faces { display: grid; grid-template-columns: repeat(6, 1fr); gap: .5rem; max-width: 24rem; margin: 0 0 1rem; padding: 0; list-style: none; }
.faces__item { aspect-ratio: 4 / 5; overflow: hidden; border-radius: 12px; background: var(--c-grey); }
.faces__item img { width: 100%; height: 100%; object-fit: cover; }

/* Venir à la mairie : l'adresse et le bouton à gauche, l'accès coché à droite. */
.visit { display: grid; gap: 1.5rem 3rem; align-items: start; }
@media (min-width: 52rem) { .visit { grid-template-columns: 1fr 1fr; } }
.visit__main { display: flex; flex-direction: column; }
.visit__address { margin: 0 0 .5rem; font-size: clamp(1.25rem, 2.4vw, 1.5rem); font-weight: 700; line-height: 1.35; }
.visit__main .know__actions { margin-top: .75rem !important; }
.visit__access { padding: clamp(1.25rem, 3vw, 1.75rem); border-radius: 22px; background: var(--c-grey); }
.visit__title { margin: 0 0 .85rem; font-size: 1.15rem; }
.checks { display: grid; gap: .65rem; margin: 0; padding: 0; list-style: none; }
.checks li { display: flex; align-items: flex-start; gap: .65rem; }
.checks .icon { flex: none; width: 1.4rem; height: 1.4rem; margin-top: .1rem; padding: .15rem; border-radius: 50%; background: var(--c-green); color: #fff; stroke-width: 3; }

.breadcrumbs { margin-bottom: 1rem; font-size: .88rem; }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: .25rem .5rem; margin: 0; padding: 0; list-style: none; }
.breadcrumbs li + li::before { content: "›"; margin-right: .5rem; color: var(--c-muted); }
.breadcrumbs a { color: var(--c-muted); }
.breadcrumbs [aria-current] { font-weight: 600; }

.layout { padding-block: clamp(2rem, 5vw, 3.5rem); }
.layout--aside { display: grid; gap: 2.5rem; }
@media (min-width: 62rem) { .layout--aside { grid-template-columns: minmax(0, 1fr) 21rem; gap: 3.5rem; align-items: start; } }
.layout__aside { display: grid; gap: 1.25rem; }
.layout--aside > * { min-width: 0; }   /* un tableau large défile dans son cadre au lieu d'élargir la colonne */
@media (min-width: 62rem) {
	.layout__aside { position: sticky; top: 8.5rem; }
	.layout__aside.is-tall { position: static; }   /* plus haute que l'écran : elle défile avec la page (main.js) */
}

.entry { max-width: 46rem; }
.entry > * + * { margin-top: 1.1rem; }
.entry h2 { margin-top: 2.25rem; }
.entry h3 { margin-top: 1.75rem; }
.entry--intro { margin-bottom: 2rem; }
/* Texte courant seulement : les listes et tableaux « composants » (élus, planning, horaires…) portent une classe et gardent leur style. */
.entry :where(ul, ol):where(:not([class]), .wp-block-list) { padding-left: 1.3rem; }
.entry :where(ul, ol):where(:not([class]), .wp-block-list) > li + li { margin-top: .35rem; }
.entry table:not([class]) { width: 100%; border-collapse: collapse; }
.entry table:not([class]) :is(th, td) { padding: .6rem .75rem; border: 1px solid var(--c-line); text-align: left; }
.entry table:not([class]) th { background: var(--c-grey); }
.entry blockquote { margin-inline: 0; padding: .5rem 1.25rem; border-left: 4px solid var(--c-green); background: var(--c-grey); }
.entry img { border-radius: var(--radius); }
.entry .alignwide { max-width: var(--container); }
.wp-block-button__link { border-radius: var(--radius); font-weight: 700; }

.subnav, .aside-card { padding: 1.25rem; background: var(--c-grey); border-radius: var(--radius-lg); }
.subnav__title, .aside-card__title { margin: 0 0 .75rem; font-size: 1.1rem; }
.subnav__title a { color: inherit; text-decoration: none; }
.subnav ul { margin: 0; padding: 0; list-style: none; }
.subnav a { display: block; padding: .45rem .6rem; border-radius: 6px; color: var(--c-ink); text-decoration: none; }
.subnav a:hover { background: var(--c-surface); }
.subnav [aria-current="page"] { background: var(--c-surface); color: var(--c-blue); font-weight: 700; box-shadow: inset 4px 0 0 var(--c-blue-logo); }
.aside-card { background: var(--c-surface); border: 1px solid var(--c-line); }
.aside-card__sub { margin: 1rem 0 .5rem; font-size: 1rem; }

/* Téléphone et tablette (colonne sous le texte) : pas de doublon avec le pied de page, rubrique en pastilles. */
@media (max-width: 61.99rem) {
	.aside-card--question { display: none; }
	.subnav { padding: 1rem 1.1rem 1.1rem; }
	.subnav ul { display: flex; flex-wrap: wrap; gap: .5rem; }
	.subnav li a { padding: .5rem .9rem; border: 1px solid var(--c-line); border-radius: 999px; background: var(--c-surface); }
	.subnav [aria-current="page"] { border-color: var(--c-blue); box-shadow: none; }
}

/* Bloc « Détails » replié sur téléphone (cantine…) ; sur grand écran, main.js l'ouvre et le titre cliquable disparaît. */
.replie-mobile > summary { display: inline-flex; align-items: center; gap: .6rem; min-height: 2.75rem; padding: .55rem 1.1rem; border: 2px solid var(--c-line); border-radius: 999px; background: var(--c-surface); font-weight: 700; cursor: pointer; list-style: none; }
.replie-mobile > summary::-webkit-details-marker { display: none; }
.replie-mobile > summary::after { content: ""; width: .55rem; height: .55rem; border: solid currentColor; border-width: 0 2px 2px 0; transform: translateY(-2px) rotate(45deg); }
.replie-mobile[open] > summary::after { transform: translateY(2px) rotate(-135deg); }
.replie-mobile > summary:hover { border-color: var(--c-blue); }
.replie-mobile > summary:focus-visible { outline: 3px solid var(--c-blue); outline-offset: 2px; }
.replie-mobile[open] > summary { margin-bottom: 1.1rem; }
.replie-mobile > * + *:not(summary) { margin-top: 1.1rem; }
@media (min-width: 62rem) { .js .replie-mobile > summary { display: none; } }

.facts { display: grid; gap: .6rem; margin: 0; }
.facts div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .1rem 1rem; padding-bottom: .6rem; border-bottom: 1px solid var(--c-line); }
.facts dt { color: var(--c-muted); }
.facts dd { margin: 0; font-weight: 700; }
.ticks { margin: 0; padding: 0; list-style: none; }
.ticks li { position: relative; padding-left: 1.5rem; }
.ticks li + li { margin-top: .3rem; }
.ticks li::before { content: ""; position: absolute; left: .2rem; top: .45rem; width: .4rem; height: .75rem; border: solid var(--c-green-dark); border-width: 0 2px 2px 0; transform: rotate(45deg); }

/* 10. Listes alimentées par les fiches ------------------------------------ */
.group { margin-top: 2.5rem; }
.group:first-child { margin-top: 0; }
.group__title { padding-bottom: .5rem; border-bottom: 2px solid var(--c-line); }
.entries { display: grid; gap: var(--gap); margin: 0; padding: 0; list-style: none; }
@media (min-width: 40rem) { .entries { grid-template-columns: repeat(2, 1fr); } }
.entry-card { padding: 1.25rem; background: var(--c-surface); border: 1px solid var(--c-line); border-radius: var(--radius-lg); }
.entry-card h3 { margin-bottom: .35rem; }
.entry-card p { margin-bottom: .6rem; }
.entry-card__hours { display: flex; gap: .6rem; color: var(--c-muted); font-size: .95rem; }
.entry-card__hours .icon { width: 1.1rem; height: 1.1rem; margin-top: .2rem; color: var(--c-blue); }
.entry-card .contact-list { margin-bottom: 0; }
.entry-card__hours { display: flex; align-items: flex-start; gap: .6rem; margin: .6rem 0 0; font-size: .95rem; }
.entry-card__hours .icon { flex: none; width: 1.1rem; height: 1.1rem; margin-top: .2rem; color: var(--c-blue); }
/* Tableaux de tarifs : la durée (« 30 ans ») ne se coupe pas sur téléphone. */
.wp-block-table td:first-child { white-space: nowrap; }
.wp-block-table caption { margin-bottom: .5rem; font-weight: 700; text-align: left; caption-side: top; }
/* Petits téléphones : les tarifs tiennent dans la largeur ; sinon, le tableau défile seul (pas toute la page). */
.wp-block-table { max-width: 100%; overflow-x: auto; }
@media (max-width: 30rem) { .entry table:not([class]) :is(th, td) { padding: .5rem .45rem; } }
.table-scroll { max-width: 100%; margin-bottom: 1.5rem; overflow-x: auto; }
.table-scroll table { margin-bottom: 0; }
.table-scroll:focus-visible { outline-offset: 2px; }
/* Tarifs des salles : prix centrés sous leur colonne (réunion du 27/11/2026). */
.table-scroll--tarifs :is(thead th:not(:first-child), td) { text-align: center; }
/* Tous les tableaux du texte : même titre que les blocs Tableau (gras, à gauche), au lieu du centré du navigateur. */
.entry table:not([class]) caption { margin-bottom: .5rem; font-weight: 700; text-align: left; caption-side: top; }
/* Tarifs des salles sur téléphone : une petite fiche par ligne (« Samedi ou dimanche » puis les 3 prix), plus de défilement.
   Le titre des colonnes reste lu par les lecteurs d'écran ; le libellé visible vient de data-label et n'est pas relu. */
@media (max-width: 35.99rem) {
	.table-scroll--stack { overflow: visible; }
	.table-scroll--stack :is(table, caption, tbody, tr, th, td) { display: block; }
	.table-scroll--stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
	.table-scroll--stack tbody tr { margin-bottom: .75rem; overflow: hidden; border: 1px solid var(--c-line); border-radius: 14px; }
	.entry .table-scroll--stack table :is(th, td) { padding: .6rem .9rem; border: 0; }
	.entry .table-scroll--stack tbody th { background: var(--c-grey); }
	.table-scroll--stack td { display: flex; justify-content: space-between; gap: 1rem; border-top: 1px solid var(--c-line) !important; }
	.table-scroll--stack td::before { content: attr(data-label); content: attr(data-label) / ""; color: var(--c-muted); }
}
/* Commerces et artisans : boutons de filtre de la page Associations ; l'espace va sous chaque groupe,
   pour que le premier groupe affiché après un filtre reste collé au compteur. */
.commerces .group { margin: 0 0 2.5rem; }
/* Commerces (16/11/2026, page trop longue) : un annuaire en lignes dans un bloc blanc à filets, comme « Liens utiles ».
   Nom et activité à gauche, téléphone à droite dès 40rem ; sur téléphone, tout l'un sous l'autre. */
.commerces .entries { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1px; margin-top: 1rem; background: var(--c-line); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden; }
.commerces .entry-card { padding: .9rem 1.25rem; background: var(--c-surface); border: 0; border-radius: 0; }
.commerces .entry-card h3 { margin: 0 0 .15rem; font-size: 1.05rem; }
.commerces .entry-card p { margin-bottom: 0; color: var(--c-muted); }
.commerces .entry-card .contact-list { margin-top: .4rem; }
.commerces .entry-card .contact-list li { margin: 0; }
@media (min-width: 40rem) {
	.commerces .entry-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 1.5rem; align-items: center; }
	.commerces .entry-card > :not(.contact-list) { grid-column: 1; }
	.commerces .entry-card > .contact-list { grid-column: 2; grid-row: 1 / span 3; max-width: 17rem; margin-top: 0; }
}

/* Associations : boutons de filtre par domaine, puis un seul bloc blanc partagé par des filets.
   Les filets sont des ombres de 1px à droite et en bas de chaque fiche (le bloc les coupe sur ses bords),
   ce qui reste juste quel que soit le nombre de fiches affichées après un filtre. */
.asso-filter { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: .9rem; }
.asso-filter__btn {
	display: inline-flex; align-items: center; gap: .4rem; min-height: 2.75rem; padding: .4rem 1.05rem;
	border: 1px solid var(--c-line); border-radius: 999px; background: var(--c-surface); color: var(--c-ink);
	font: inherit; font-weight: 700; cursor: pointer; transition: background-color .2s, border-color .2s;
}
.asso-filter__btn:hover { border-color: var(--c-blue-logo); background: var(--c-blue-tint); }
.asso-filter__btn[aria-pressed="true"] { border-color: var(--c-blue); background: var(--c-blue); color: var(--c-on-blue); }
.asso-filter__n { color: var(--c-muted); font-weight: 400; }
.asso-filter__btn[aria-pressed="true"] .asso-filter__n { color: var(--c-on-blue); }
.assos__count { margin: 0 0 1rem; color: var(--c-muted); font-size: .95rem; }
.assos__list {
	display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr)); margin: 0; padding: 0; list-style: none;
	background: var(--c-surface); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden;
}
.asso { display: flex; flex-direction: column; gap: .8rem; padding: clamp(1.25rem, 2.5vw, 1.6rem); box-shadow: 1px 0 0 var(--c-line), 0 1px 0 var(--c-line); }
.asso[hidden] { display: none; }
.asso__head { display: flex; align-items: center; gap: .9rem; }
.asso__logo { display: grid; flex: none; place-items: center; width: 3.5rem; height: 3.5rem; overflow: hidden; border: 1px solid var(--c-line); border-radius: 50%; background: var(--c-surface); }
.asso__logo img { width: 100%; height: 100%; border-radius: 0; object-fit: contain; }
.asso__logo--icon { border: 0; background: var(--c-blue-tint); color: var(--c-blue); }
.asso__logo--icon .icon { width: 1.6rem; height: 1.6rem; }
.asso .asso__name { margin: 0; font-size: 1.15rem; line-height: 1.25; }
.asso__domain { margin: .15rem 0 0; color: var(--c-blue); font-size: .9rem; font-weight: 600; }
.asso__text { margin: 0; }
.asso .asso__contact { margin: auto 0 0; }

/* Bus : les deux sens dans un bloc blanc à filets. La première colonne dessine la ligne :
   un trait bleu continu et un rond par arrêt, plein pour les arrêts de la commune. */
.bus__dirs {
	display: grid; background: var(--c-surface); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden;
}   /* un sens sous l'autre : côte à côte, la colonne de texte est trop étroite pour 4 horaires */
.bus-dir { overflow-x: auto; padding: clamp(.85rem, 2.5vw, 1.4rem) clamp(.6rem, 2vw, 1.25rem); box-shadow: 1px 0 0 var(--c-line), 0 1px 0 var(--c-line); }
.bus-dir:focus-visible { outline-offset: -3px; border-radius: 22px; }
.bus-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.bus-table caption { padding: 0 0 .6rem .35rem; font-size: 1.2rem; font-weight: 700; text-align: left; }
.bus-table thead th { padding: .3rem .35rem; border-bottom: 1px solid var(--c-line); color: var(--c-muted); font-size: .85rem; font-weight: 600; line-height: 1.25; text-align: right; vertical-align: bottom; }
.bus-table thead th:first-child { padding-left: .35rem; text-align: left; }
.bus-table__resa { display: block; font-size: .75rem; font-weight: 400; }
.bus-table tbody th { position: relative; padding: .5rem .35rem .5rem 1.7rem; font-weight: 600; text-align: left; }
.bus-table td { padding: .5rem .35rem; text-align: right; white-space: nowrap; }
.bus-table td.is-empty { color: var(--c-muted); }
.bus-table tbody th::before { content: ""; position: absolute; top: 0; bottom: 0; left: .6rem; width: 3px; background: var(--c-blue-logo); }
.bus-table tbody tr:first-child th::before { top: 1.3rem; }
.bus-table tbody tr:last-child th::before { bottom: auto; height: 1.3rem; }
.bus-table tbody th::after {
	content: ""; position: absolute; top: .92rem; left: .33rem; box-sizing: border-box; width: .78rem; height: .78rem;
	border: 3px solid var(--c-blue-logo); border-radius: 50%; background: var(--c-surface);
}
.bus-table__stop { display: block; }
.bus-table__note { display: block; color: var(--c-muted); font-size: .82rem; font-weight: 400; line-height: 1.3; }
.bus-table tr.is-local { background: var(--c-blue-tint); }
.bus-table tr.is-local td, .bus-table tr.is-local .bus-table__stop { font-weight: 700; }
.bus-table tr.is-local th::after { border-color: var(--c-blue); background: var(--c-blue); }
/* Téléphone : le nom de l'arrêt sur sa ligne, les horaires en dessous ; le trait bleu passe en fond de ligne pour rester continu. */
@media (max-width: 35.99rem) {
	.bus-table, .bus-table thead, .bus-table tbody { display: block; }
	.bus-table tr { display: grid; grid-template-columns: repeat(var(--cols, 3), minmax(0, 1fr)); padding-left: 1.7rem; }
	.bus-table thead th:first-child { display: none; }
	.bus-table thead th, .bus-table td { text-align: left; }
	.bus-table tbody th { grid-column: 1 / -1; padding: .55rem 0 0; }
	.bus-table td { padding: .1rem .3rem .55rem 0; }
	.bus-table tbody th::before { display: none; }
	.bus-table tbody th::after { top: .97rem; left: -1.37rem; }
	.bus-table caption { display: block; }
	.bus-table tbody tr { background: linear-gradient(var(--c-blue-logo), var(--c-blue-logo)) no-repeat .6rem 0 / 3px 100%; }
	.bus-table tbody tr.is-local { background: linear-gradient(var(--c-blue-logo), var(--c-blue-logo)) no-repeat .6rem 0 / 3px 100%, var(--c-blue-tint); }
	.bus-table tbody tr:first-child { background-position: .6rem 1.35rem; }
	.bus-table tbody tr:last-child { background-size: 3px 1.35rem; }
}
.bus__infos { margin-top: .9rem; }
.bus__docs { margin-top: 1.25rem; }

/* Bouton « Afficher les horaires » : le bloc replié apparaît juste dessous. */
.reveal-btn { margin: 0 0 1rem; }
.reveal-btn::after {
	content: ""; width: .5rem; height: .5rem; margin: -.2rem 0 0 .15rem;
	border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.reveal-btn[aria-expanded="true"] { border-color: var(--c-ink); }
.reveal-btn[aria-expanded="true"]::after { margin-top: .25rem; transform: rotate(-135deg); }
.reveal-panel[hidden] { display: none; }

/* « En savoir plus » des pages longues (téléphone) : bouton, puis les titres de ce qui est replié. */
.more { display: grid; justify-items: start; margin: 1.75rem 0 0; padding-top: 1.25rem; border-top: 1px solid var(--c-line); }
.more[hidden], .more-panel[hidden] { display: none; }
.more .more__btn { margin: 0; white-space: nowrap; }
.more .more__hint { margin: .6rem 0 0; color: var(--c-muted); font-size: 1rem; font-weight: 400; }
.planning > .more { grid-column: 1 / -1; margin-top: 0; padding-top: 0; border-top: 0; }
.planning > .more-panel { display: contents; }
.planning > .more-panel[hidden] { display: none; }
/* Élus. Sur téléphone : une liste, petite photo à gauche (pas de photo seule sur sa ligne, texte lisible).
   Dès 48rem : une grille de portraits ; colonnes choisies pour qu'aucun élu ne reste seul sur une ligne. */
.people { display: grid; margin: 0; padding: 0; list-style: none; }
.person { display: grid; grid-template-columns: 5.5rem minmax(0, 1fr); gap: 1rem; align-items: start; }
.person + .person { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--c-line); }
.person__photo { aspect-ratio: 4 / 5; overflow: hidden; border-radius: 14px; background: var(--c-grey); }
.person__photo img { width: 100%; height: 100%; object-fit: cover; }
.person__text { padding-top: .2rem; }
@media (min-width: 48rem) {
	.people { grid-template-columns: repeat(5, 1fr); gap: 2rem 1.25rem; }
	.person { display: block; }
	.person + .person { margin-top: 0; padding-top: 0; border-top: 0; }
	.person__photo { margin-bottom: .85rem; border-radius: var(--radius-lg); }
	.person__text { padding-top: 0; }
	.people--bureau { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 64rem) { .people--bureau { grid-template-columns: repeat(5, 1fr); } }
@media (min-width: 75rem) { .people--conseil { grid-template-columns: repeat(7, 1fr); } }
/* CCAS : 9 membres dans la colonne de texte, 3 par ligne (personne seul sur une ligne). */
@media (min-width: 48rem) { .people--ccas { grid-template-columns: repeat(3, 1fr); margin-top: 1.5rem; } }
.avatar { display: grid; place-items: center; width: 100%; height: 100%; font-size: 2.4rem; font-weight: 800; color: var(--c-blue); }
.person__name { margin: 0; font-size: 1.1rem; }
.person__role { margin: .15rem 0 .4rem; color: var(--c-blue); font-weight: 700; font-size: 1rem; line-height: 1.4; }
.person__deleg { margin: 0; font-size: .95rem; line-height: 1.5; color: var(--c-muted); }
.person__sector { display: flex; gap: .4rem; margin: .4rem 0 0; font-size: .95rem; color: var(--c-muted); }
.person__sector .icon { width: 1rem; height: 1rem; margin-top: .2rem; }

/* Page « L'équipe municipale » : un groupe par rubrique, le maire en grand. */
.team-group + .team-group { margin-top: clamp(2.75rem, 6vw, 4rem); }
.team-group__title { margin: 0 0 1.5rem; padding-bottom: .6rem; border-bottom: 2px solid var(--c-line); }
.team-lead {
	display: grid; grid-template-columns: 6.5rem minmax(0, 1fr); grid-template-areas: "photo head" "text text";
	gap: 1.25rem; align-items: center; margin-bottom: 2rem;
	padding: clamp(1.25rem, 3vw, 2rem); border-radius: 22px; background: var(--c-grey);
}
@media (min-width: 40rem) {
	.team-lead { grid-template-columns: 13rem minmax(0, 1fr); grid-template-rows: 1fr auto auto 1fr; grid-template-areas: "photo ." "photo head" "photo text" "photo ."; column-gap: 2.5rem; row-gap: .9rem; }
	.team-lead__text { align-self: start; }
}
.team-lead__photo { grid-area: photo; aspect-ratio: 4 / 5; overflow: hidden; border-radius: 14px; background: var(--c-surface); }
@media (min-width: 40rem) { .team-lead__photo { border-radius: 18px; } }
.team-lead__photo img { width: 100%; height: 100%; object-fit: cover; }
.team-lead__head { grid-area: head; }
.team-lead__text { grid-area: text; }
.team-lead__name { margin: 0; font-size: clamp(1.4rem, 3vw, 2rem); }
.team-lead__head .person__role { margin: .2rem 0 0; font-size: 1.1rem; }
.team-lead__text p { margin: 0 0 .9rem; }
.team-lead__text p:last-child { margin-bottom: 0; }
/* Le déontologue : une seule carte, la photo à gauche, à toutes les tailles. */
.people--deontologue { grid-template-columns: 1fr; max-width: 32rem; }
.people--deontologue .person { display: grid; grid-template-columns: 6.5rem minmax(0, 1fr); gap: 1.25rem; }
.people--deontologue .person__photo { margin: 0; }
.people--deontologue .person__text { padding-top: .35rem; }
.team__write { margin-top: clamp(2.5rem, 6vw, 3.5rem); padding-top: 1.5rem; border-top: 1px solid var(--c-line); }

/* Page Contact : le formulaire à côté de son titre, puis trois autres façons de joindre la commune. */
.write + .reach { margin-top: var(--section); }
.reach .status { align-self: flex-start; }
.reach__tel { margin-bottom: .6rem !important; }
.reach__tel a { color: var(--c-ink); font-size: clamp(1.45rem, 2.4vw, 1.7rem); font-weight: 700; text-decoration-thickness: 2px; }
.reach__tel a:hover { color: var(--c-blue); }
/* « (choix 3) » : à côté du numéro, en petit, pour que le numéro ne se coupe pas. */
.reach__tel-note { color: var(--c-muted); font-size: 1rem; font-weight: 600; white-space: nowrap; }
.reach__addr { font-size: 1.1rem; }
.write { display: grid; gap: 1.5rem 3.5rem; }
@media (min-width: 62rem) { .write { grid-template-columns: minmax(0, 19rem) minmax(0, 1fr); align-items: start; } }
.write__title { margin: 0 0 1rem; font-size: clamp(1.6rem, 3vw, 2rem); }
.write__intro .entry p { margin: 0 0 1rem; }
.write__mail { margin: 0; color: var(--c-muted); }
.write .form-wrap { margin-top: 0; }

/* Accueil, « Vous cherchez » : un seul bloc blanc (comme « Liens utiles »), des cases séparées par un filet.
   Toute la case est cliquable. 2 colonnes, 4 à partir de 64rem. */
.needs-section { padding-top: clamp(1rem, 3vw, 2rem); }
.needs {
	display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin: 0; padding: 0; list-style: none;
	background: var(--c-line); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden;
}
@media (min-width: 64rem) { .needs { grid-template-columns: repeat(4, 1fr); } }
.needs__item { display: flex; background: var(--c-surface); }
.needs__link {
	display: flex; flex: 1; align-items: center; gap: .85rem; min-height: 5.5rem; padding: 1rem clamp(1rem, 2.5vw, 1.5rem);
	color: var(--c-ink); font-weight: 700; line-height: 1.3; text-decoration: none;
}
.needs__link .know__icon { flex: none; }
.needs__link:hover { background: var(--c-blue-tint); color: var(--c-blue); }
.needs__link:focus-visible { outline-offset: -4px; }
/* Téléphone : l'icône au-dessus du texte, pour garder des cases lisibles sur 2 colonnes. */
@media (max-width: 30rem) {
	.needs__link { flex-direction: column; align-items: flex-start; gap: .6rem; }
}
/* Rubrique (Démarches) : « Je veux… » puis les cartes. 6 raccourcis = 3 par ligne sur grand écran. */
.rubrique__needs { margin-bottom: clamp(2rem, 4vw, 3rem); }
.rubrique__needs-title { margin: 0 0 1rem; font-size: clamp(1.35rem, 2.4vw, 1.6rem); }
@media (min-width: 64rem) { .rubrique__needs .needs { grid-template-columns: repeat(3, 1fr); } }

/* Liens utiles : un bloc blanc par groupe (comme « Rencontrer le maire »), une ligne cliquable par site,
   l'adresse du site écrite en clair. */
.useful { display: grid; gap: clamp(2rem, 5vw, 2.75rem); }
.useful .useful__title { display: flex; align-items: center; gap: .85rem; margin: 0 0 1rem; font-size: clamp(1.3rem, 2.4vw, 1.5rem); }
.useful__list { margin: 0; padding: 0; list-style: none; background: var(--c-surface); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden; }
.useful__item { position: relative; display: flex; align-items: flex-start; gap: 1rem; padding: 1.1rem clamp(1.1rem, 3vw, 1.5rem); transition: background-color .2s; }
.useful__item + .useful__item { border-top: 1px solid var(--c-line); }
.useful__item:hover { background: var(--c-blue-tint); }
.useful__item:focus-within { outline: 3px solid var(--c-blue-logo); outline-offset: -3px; }
.useful__text { display: grid; flex: 1; gap: .1rem; min-width: 0; }
.useful__link { color: var(--c-ink); font-size: 1.2rem; font-weight: 700; line-height: 1.3; text-decoration: none; }
.useful__link::after { content: ""; position: absolute; inset: 0; }   /* toute la ligne est cliquable */
.useful__link:focus-visible { outline: none; }
.useful__site { color: var(--c-blue); font-size: .95rem; font-weight: 600; overflow-wrap: anywhere; }
.useful .useful__desc { margin: .3rem 0 0; color: var(--c-muted); }
.useful__tel {
	position: relative; z-index: 1; justify-self: start; display: inline-flex; align-items: center; gap: .5rem; margin-top: .7rem;
	padding: .45rem 1rem; border: 2px solid var(--c-line); border-radius: 999px; background: var(--c-surface); color: var(--c-ink); font-weight: 700; text-decoration: none;
}
.useful__tel:hover { border-color: var(--c-blue-logo); }
.useful__tel .icon { width: 1.1rem; height: 1.1rem; color: var(--c-blue); }
.useful__go { flex: none; margin-top: .25rem; color: var(--c-blue); }
.useful__go .icon { width: 1.25rem; height: 1.25rem; }

/* Santé et marché : listes « nom, détail, bouton pour appeler » (même bloc à filets que « Liens utiles »). */
.dir { display: grid; gap: clamp(2rem, 5vw, 2.75rem); margin: 0 0 2rem; }
.entry .dir__title { display: flex; align-items: center; gap: .85rem; margin: 0 0 1rem; font-size: clamp(1.3rem, 2.4vw, 1.5rem); }
.dir__list { margin: 0; padding: 0; list-style: none; background: var(--c-surface); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden; }
.entry .dir__item { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .6rem 1.25rem; margin: 0; padding: 1rem clamp(1.1rem, 3vw, 1.5rem); }
.dir__item + .dir__item { border-top: 1px solid var(--c-line); }
.dir__text { display: grid; flex: 1 1 16rem; gap: .1rem; min-width: 0; }
.dir__name { font-size: 1.15rem; font-weight: 700; line-height: 1.3; }
.dir__desc { color: var(--c-muted); }
.dir__link { display: inline-flex; align-items: center; justify-self: start; gap: .4rem; margin-top: .3rem; font-weight: 700; }
.dir__link .icon { width: 1.05rem; height: 1.05rem; color: var(--c-blue); }
.dir__tel {
	display: inline-flex; flex: none; align-items: center; gap: .5rem; min-height: 2.6rem; padding: .35rem 1rem;
	border: 2px solid var(--c-line); border-radius: 999px; background: var(--c-surface); color: var(--c-ink); font-weight: 700; white-space: nowrap; text-decoration: none;
}
.dir__tel:hover { border-color: var(--c-blue-logo); color: var(--c-ink); }
.dir__tel .icon { width: 1.1rem; height: 1.1rem; color: var(--c-blue); }

/* Conseil municipal : délibérations par année (même bloc à filets que « Liens utiles »). */
.files { display: grid; gap: 1.75rem; }
.entry .files__year { margin: 0 0 .75rem; font-size: 1.2rem; }
.files__list { margin: 0; padding: 0; list-style: none; background: var(--c-surface); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden; }
.files__item { position: relative; display: flex; align-items: center; gap: 1rem; margin: 0; padding: 1rem clamp(1.1rem, 3vw, 1.5rem); transition: background-color .2s; }
.files__item + .files__item { border-top: 1px solid var(--c-line); }
.files__item:hover { background: var(--c-blue-tint); }
.files__item:focus-within { outline: 3px solid var(--c-blue-logo); outline-offset: -3px; }
.files__text { display: grid; flex: 1; gap: .1rem; min-width: 0; }
.files__link { color: var(--c-ink); font-weight: 700; line-height: 1.3; text-decoration: none; }
.files__link::after { content: ""; position: absolute; inset: 0; }   /* toute la ligne est cliquable */
.files__link:focus-visible { outline: none; }
.files__meta { color: var(--c-muted); font-size: .95rem; }
.files__icon, .files__go { display: flex; flex: none; color: var(--c-blue); }

.docs { margin: 0; padding: 0; list-style: none; }
.doc { display: flex; flex-wrap: wrap; align-items: baseline; gap: .1rem .6rem; padding: .7rem 0; border-bottom: 1px solid var(--c-line); }
.doc .icon { align-self: center; color: var(--c-blue); }
.doc a { font-weight: 600; }
/* Bas de page « Documents à télécharger » (template-parts/page-documents.php). */
.page-docs__title { margin-top: 0; }
.page-docs .docs { max-width: 50rem; }
.doc__meta { color: var(--c-muted); font-size: .88rem; }

/* Numéros d'urgence : un bloc blanc à filets comme les autres, le numéro en rouge à gauche, ce qu'il appelle à droite.
   1 colonne, 3 à partir de 52rem (9 numéros = 3 lignes pleines). */
.urgences {
	display: grid; gap: 1px; margin: 0; padding: 0; list-style: none;
	background: var(--c-line); border: 1px solid var(--c-line); border-radius: 22px; overflow: hidden;
}
@media (min-width: 52rem) { .urgences { grid-template-columns: repeat(3, 1fr); } }
.urgences li { display: flex; background: var(--c-surface); }
.urgence { display: flex; flex: 1; flex-wrap: wrap; align-items: center; gap: .25rem 1rem; padding: 1rem clamp(1rem, 2.5vw, 1.4rem); color: var(--c-ink); text-decoration: none; transition: background-color .2s; }
.urgence:hover { background: var(--c-blue-tint); color: var(--c-ink); }
.urgence:focus-visible { outline-offset: -4px; }
.urgence__num { min-width: 4.25rem; font-size: 1.8rem; font-weight: 800; line-height: 1.1; color: var(--c-red); }
.urgence__num--long { font-size: 1.2rem; line-height: 1.5; white-space: nowrap; }
.urgence__label { flex: 1 1 8rem; font-size: 1rem; line-height: 1.35; }

.links { padding-left: 1.3rem; }

/* Prochaines ouvertures du dépôt de déchets verts ([luant_depot_dates]) */
.depot-dates { display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: .5rem; margin: .75rem 0 1.25rem; padding: 0; list-style: none; }
.depot-dates li { padding: .55rem .8rem; border-radius: var(--radius); background: var(--c-grey); font-variant-numeric: tabular-nums; }
.depot-dates__month { display: block; font-weight: 700; }
.depot-dates__month::first-letter { text-transform: uppercase; }

/* Planning des salles (tenu par le secrétariat dans Salles › Planning des réservations) */
.planning { display: grid; grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); gap: 1.25rem; }
.planning__month { padding: 1rem 1rem 1.1rem; border: 1px solid var(--c-line); border-radius: var(--radius); background: var(--c-surface); }
.planning__month h3 { margin: 0 0 .6rem; font-size: 1.05rem; }
.planning__month h3::first-letter { text-transform: uppercase; }
.planning table { width: 100%; margin: 0; border-collapse: separate; border-spacing: 3px; text-align: center; font-size: .92rem; table-layout: fixed; }
.planning th { padding: .2rem 0; border: 0; background: none; color: var(--c-muted); font-weight: 700; font-size: .78rem; }
.planning abbr { text-decoration: none; }
.planning td { padding: .4rem 0; border: 0; border-radius: 6px; background: var(--c-grey); font-variant-numeric: tabular-nums; }
.planning td:empty { background: none; }
.planning .is-past { background: none; color: var(--c-muted); }
.planning .is-booked { background: var(--c-blue); color: var(--c-on-blue); font-weight: 700; }
.planning .is-option { background: repeating-linear-gradient(135deg, var(--c-hatch) 0 5px, var(--c-surface) 5px 10px); box-shadow: inset 0 0 0 1.5px var(--c-blue); color: var(--c-blue-dark); font-weight: 700; }
.planning .is-today { box-shadow: inset 0 0 0 2px var(--c-ink); }
.planning__legend { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; margin: 1.1rem 0 0; padding: 0; list-style: none; font-size: .95rem; }
.planning__legend li { display: flex; align-items: center; gap: .5rem; margin: 0; }
.planning__dot { flex: none; width: 1.1rem; height: 1.1rem; border-radius: 4px; background: var(--c-blue); }
.planning__dot--option { background: repeating-linear-gradient(135deg, var(--c-hatch) 0 3px, var(--c-surface) 3px 6px); box-shadow: inset 0 0 0 1.5px var(--c-blue); }
.planning__dot--free { background: var(--c-grey); box-shadow: inset 0 0 0 1px var(--c-line); }
.planning__note { margin-top: .75rem; color: var(--c-muted); font-size: .95rem; }

/* 11. Formulaires --------------------------------------------------------- */
.form-wrap { margin-top: 2rem; }
.entry + .form-wrap { margin-top: 2.5rem; }
.form { display: grid; gap: 1.25rem; padding: clamp(1.25rem, 3vw, 2rem); background: var(--c-grey); border-radius: var(--radius-lg); }
.form__legend { margin: 0; color: var(--c-muted); font-size: .92rem; }
.form__row { display: grid; gap: 1.25rem; }
@media (min-width: 40rem) { .form__row { grid-template-columns: 1fr 1fr; } }
.form__field label { display: block; margin-bottom: .35rem; font-weight: 700; }
/* Bord des champs assez foncé pour bien voir où écrire (contraste 3:1 au moins sur le blanc). */
.form input[type="text"], .form input[type="email"], .form input[type="tel"], .form select, .form textarea {
	width: 100%; padding: .75rem .9rem; border: 2px solid var(--c-field-border); border-radius: var(--radius);
	font: inherit; color: var(--c-ink); background: var(--c-surface);
}
.form select {
	appearance: none; padding-right: 2.75rem; cursor: pointer;
	background: var(--c-surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23006fa6' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right .85rem center / 1.25rem;
}
.form textarea { min-height: 9rem; resize: vertical; }
.form input:focus, .form select:focus, .form textarea:focus { border-color: var(--c-blue-logo); outline: 3px solid rgba(0, 142, 209, .25); outline-offset: 0; }
.form__hint { margin: .35rem 0 0; color: var(--c-muted); font-size: .9rem; }
/* Plus précis que « .form input[type=…] » : sinon le bord rouge du champ en erreur ne s'affiche pas. */
.form .form__field [aria-invalid="true"] { border-color: var(--c-red); }
.form__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form__legal { margin: 0; color: var(--c-muted); font-size: .88rem; }
.form .btn { justify-self: start; }

.notice { display: flex; gap: 1rem; padding: 1.1rem 1.25rem; border-radius: var(--radius); }
.notice .icon { width: 1.6rem; height: 1.6rem; margin-top: .15rem; }
.notice p, .notice ul { margin: .25rem 0 0; }
.notice ul { padding-left: 1.2rem; }
.notice--ok { margin-bottom: 1.25rem; background: var(--c-green-tint); color: var(--c-green-dark); }
.notice--error { margin-bottom: 1.25rem; background: var(--c-red-tint); color: var(--c-red-dark); }

/* 12. Pied de page -------------------------------------------------------- */
/* Pied de page court et clair : logo, mairie, quelques liens. Texte assez grand pour tous. */
.site-footer { margin-top: var(--section); background: var(--c-grey); color: var(--c-ink); }
.site-footer::before { content: ""; display: block; height: 4px; background: var(--logo-band); }
.site-footer a { color: var(--c-ink); font-weight: 600; }
.site-footer a:hover { color: var(--c-blue); }
.footer__grid { display: grid; gap: 2rem; padding-block: clamp(2rem, 5vw, 3rem); }
@media (min-width: 48rem) { .footer__grid { grid-template-columns: 1fr 1.3fr 1fr; gap: 2.5rem; } }
.footer__brand p { margin: .75rem 0 0; color: var(--c-muted); font-weight: 600; line-height: 1.4; }
.footer__title { margin-bottom: .75rem; font-size: 1.15rem; }
.site-footer .contact-card { margin: 0 0 .75rem; }
.site-footer .contact-list { margin: 0; }
.site-footer .status { margin: 0; background: var(--c-surface); }
.footer__links, .footer__legal-links { margin: 0; padding: 0; list-style: none; }
.footer__links li + li { margin-top: .3rem; }
/* Liens du pied de page : une zone cliquable d'au moins 24 px de haut (plus facile au doigt). */
.footer__links a, .footer__legal a { display: inline-block; padding-block: .2rem; }
.footer__social { margin: 1rem 0 0; }
.footer__social a { display: inline-flex; align-items: center; gap: .5rem; }
.footer__social .icon { color: var(--c-blue); }
/* Téléphone : pied de page plus court (logo et nom côte à côte, liens sur 2 colonnes) ;
   sur l'accueil, pas de bloc « Mairie » : la section « Mairie et agence postale » est juste au-dessus. */
@media (max-width: 47.99rem) {
	.footer__grid { gap: 1.5rem; }
	.footer__brand { display: flex; align-items: center; gap: 1rem; }
	.footer__brand p { margin: 0; }
	.footer__links { display: grid; grid-template-columns: 1fr 1fr; gap: .2rem 1rem; }
	.footer__links li + li { margin-top: 0; }
	.home .footer__mairie { display: none; }
}
.footer__legal { border-top: 1px solid var(--c-line); font-size: .9rem; }
.footer__legal a { font-weight: 400; color: var(--c-muted); }
.footer__legal-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 1.5rem; padding-block: 1.1rem; }
.footer__legal-inner p { margin: 0; }
.footer__legal-links { display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; }

/* 13. Éléments flottants : accès rapides, actualités (lien Facebook), bouton haut / bas */
.side-tab {
	position: fixed; z-index: 800; display: inline-flex; align-items: center; gap: .5rem;
	padding: .7rem 1.1rem; border: 0; border-radius: 999px; box-shadow: 0 6px 20px rgba(0, 0, 0, .18);
	font: inherit; font-size: .92rem; font-weight: 700; text-decoration: none; cursor: pointer;
}
.side-tab .icon { width: 1.15rem; height: 1.15rem; }
.side-tab--left { left: 1rem; bottom: 1rem; background: var(--c-ink); color: var(--c-on-ink); }
.side-tab--right { right: 5rem; bottom: 1rem; background: var(--c-blue); color: var(--c-on-blue); }
.side-tab:hover { filter: brightness(1.15); }
/* Sur téléphone : une barre fixe en bas, deux boutons écrits en toutes lettres.
   La page garde une marge en bas pour que rien ne soit jamais caché derrière. */
@media (max-width: 77.99rem) {
	html { scroll-padding-bottom: 5rem; }   /* au clavier, l'élément actif s'arrête au-dessus de la barre */
	body { padding-bottom: 3.9rem; }
	.side-tab {
		bottom: 0; width: 50%; height: 3.9rem; justify-content: center; padding: 0 .5rem;
		border-top: 1px solid var(--c-line); border-radius: 0; box-shadow: none; font-size: 1rem;
		background: var(--c-surface); color: var(--c-ink);
	}
	.side-tab--left { left: 0; border-right: 1px solid var(--c-line); }
	.side-tab--right { right: 0; }
	.side-tab .icon { width: 1.3rem; height: 1.3rem; color: var(--c-blue); }
	.side-tab:hover { filter: none; background: var(--c-blue-tint); }
}

/* Sur grand écran : deux boutons horizontaux en bas de l'écran, écrits dans le sens de lecture
   (les anciens onglets verticaux dans la marge passaient inaperçus, retour de la relecture du 20/11). */
@media (min-width: 78rem) {
	/* Alignés sur le bouton haut / bas (3,25rem, à 1,5rem du bord). */
	.side-tab { bottom: 1.5rem; min-height: 3.25rem; padding: 0 1.4rem; font-size: 1rem; }
	.side-tab .icon { width: 1.3rem; height: 1.3rem; }
	.side-tab--left { left: 1.5rem; }
	.side-tab--right { right: 5.5rem; }
	/* Les liens du bas de page s'arrêtent au-dessus des boutons flottants (1,5rem + 3,25rem). */
	html { scroll-padding-bottom: 5.5rem; }
	.footer__legal-inner { padding-bottom: 5.75rem; }
}

/* Message après un clic sur un e-mail (main.js) : au-dessus des boutons flottants. */
.mail-note {
	position: fixed; z-index: 860; left: 50%; bottom: 5rem; transform: translateX(-50%);
	width: max-content; max-width: min(34rem, calc(100% - 2rem)); margin: 0; padding: .8rem 1.1rem;
	background: var(--c-ink); color: var(--c-on-ink); border-radius: var(--radius); box-shadow: 0 6px 20px rgba(0, 0, 0, .18);
	font-size: .95rem; overflow-wrap: anywhere;
}
@media (min-width: 78rem) { .mail-note { bottom: 5.75rem; } }

.quick-panel {
	position: fixed; z-index: 850; left: .75rem; right: .75rem; bottom: 4.65rem;
	max-height: 75vh; overflow-y: auto; padding: 1.1rem;
	background: var(--c-surface); border: 1px solid var(--c-line); border-radius: var(--radius-lg); box-shadow: 0 18px 50px rgba(0, 0, 0, .22);
}
@media (min-width: 78rem) {
	/* Le volet s'ouvre à la place du bouton « Je cherche » (masqué pendant ce temps), sans passer sous l'en-tête. */
	.quick-panel { left: 1.5rem; right: auto; bottom: 1.5rem; width: 18.5rem; max-height: calc(100vh - 8rem); }
}
.quick-panel__head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: .5rem; padding-left: .4rem; }
.quick-panel__head h2 { margin: 0; font-size: 1.15rem; }
.quick-panel .icon-btn { width: 2.4rem; height: 2.4rem; }
.quick-list { display: grid; gap: .15rem; margin: 0; padding: 0; list-style: none; }
.quick-list a { display: flex; align-items: center; gap: .75rem; padding: .45rem .5rem; border-radius: var(--radius); color: var(--c-ink); font-weight: 600; text-decoration: none; }
.quick-list a:hover { background: var(--c-blue-tint); color: var(--c-ink); }
.quick-list__icon { display: grid; flex: none; place-items: center; width: 2.3rem; height: 2.3rem; border-radius: 50%; background: var(--c-blue-tint); color: var(--c-blue); }
.quick-list__icon .icon { width: 1.15rem; height: 1.15rem; }
.quick-list a:hover .quick-list__icon { background: var(--c-surface); }

.scroll-btn {
	position: fixed; z-index: 800; right: 1rem; bottom: 1rem; display: grid; place-items: center;
	width: 3.25rem; height: 3.25rem; padding: 0; border: 2px solid var(--c-surface); border-radius: 50%;
	background: var(--c-ink); color: var(--c-on-ink); box-shadow: 0 6px 20px rgba(0, 0, 0, .2); cursor: pointer;
}
.scroll-btn .icon { transform: rotate(-90deg); transition: transform .3s; }
.scroll-btn.is-down .icon { transform: rotate(90deg); }
.scroll-btn:hover { background: var(--c-blue); }
@media (min-width: 78rem) { .scroll-btn { right: 1.5rem; bottom: 1.5rem; } }
/* Sur téléphone, on fait défiler avec le doigt : le bouton haut / bas n'apporte rien et encombrerait la barre. */
@media (max-width: 77.99rem) { .scroll-btn { display: none !important; } }

/* 13 bis. Accessibilité : taille du texte, couleurs, écouter la page --------
   Bouton de l'en-tête → bandeau (template-parts/a11y-panel.php). Choix retenus par main.js (partie 4)
   et posés sur <html> avant l'affichage (inc/enqueue.php). Tout le site est en rem : agrandir la
   taille de base agrandit tout, sans rien casser. */
html[data-texte="grand"] { font-size: 112.5%; }
html[data-texte="tres-grand"] { font-size: 125%; }

/* Rond « accessibilité » : même rond que la loupe, l'icône en bleu. */
.icon-btn--a11y .icon { width: 1.45rem; height: 1.45rem; color: var(--c-blue); }
/* Sous-menu refermé avec Échap (main.js) : caché tant qu'on ne quitte pas la rubrique. */
@media (min-width: 75rem) {
	:where(html:not(.nav-compact)) .nav .menu-item-has-children.is-dismissed > .sub-menu { opacity: 0; visibility: hidden; transform: translate(-50%, 8px); }
}

/* Téléphone : ronds et logo un peu plus petits pour que tout tienne sur une ligne avec le bouton « Accessibilité ». */
@media (max-width: 30rem) {
	.site-header .icon-btn { width: 2.5rem; height: 2.5rem; }
	.brand__logo, .custom-logo { height: 2.6rem; }
}
@media (max-width: 24rem) { .brand__logo, .custom-logo { height: 2.5rem; } }
/* Texte agrandi sur petit écran : les boutons passent sous le logo plutôt que de déborder (classe posée par main.js). */
html.header-wrap .header__bar { flex-wrap: wrap; row-gap: .5rem; padding-block: .6rem; }
html.header-wrap .header__actions { flex-wrap: wrap; margin-left: 0; }
/* Très petits écrans (320 px, ou zoom à 400 %) : le téléphone de la mairie reste dans le menu et le pied de page. */
@media (max-width: 22rem) { .icon-btn--tel { display: none; } }

.a11y-panel { border-top: 1px solid var(--c-line); background: var(--c-grey); }
.a11y-panel__inner { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 1rem 2rem; padding-block: 1rem 1.15rem; }
.a11y-group__label { margin: 0 0 .4rem; font-weight: 700; }
.a11y-choices { display: flex; flex-wrap: wrap; gap: .5rem; }
.a11y-choice {
	display: inline-flex; align-items: center; gap: .45rem; min-height: 2.75rem; padding: .35rem 1.05rem;
	border: 2px solid var(--c-line); border-radius: 999px; background: var(--c-surface); color: var(--c-ink);
	font: inherit; font-weight: 700; line-height: 1.2; cursor: pointer;
}
.a11y-choice:hover { border-color: var(--c-ink); }
.a11y-choice[aria-pressed="true"] { border-color: var(--c-blue); background: var(--c-blue); color: var(--c-on-blue); }
.a11y-choice .icon { width: 1.2rem; height: 1.2rem; }
.a11y-choice__a { font-weight: 700; line-height: 1; }
.a11y-choice--normal .a11y-choice__a { font-size: 1rem; }
.a11y-choice--grand .a11y-choice__a { font-size: 1.25rem; }
.a11y-choice--tres-grand .a11y-choice__a { font-size: 1.5rem; }
.a11y-panel__more { margin: 0 0 .6rem auto; }
@media (max-width: 47.99rem) { .a11y-panel__more { margin-left: 0; } }

/* Écouter la page : le passage lu est surligné, une barre permet de faire une pause ou d'arrêter. */
.is-read { background: var(--c-read); box-shadow: 0 0 0 .3rem var(--c-read); border-radius: 4px; color: var(--c-ink); }
:root { --c-read: #dcf0fa; }
html[data-couleurs="sombre"] { --c-read: #1b4a61; }
.reader-bar {
	position: fixed; z-index: 950; left: 50%; bottom: 1.25rem; transform: translateX(-50%);
	display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .5rem .75rem;
	width: max-content; max-width: calc(100% - 1.5rem); padding: .6rem .7rem .6rem 1.25rem;
	border-radius: var(--radius-lg); background: var(--c-ink); color: var(--c-on-ink); box-shadow: 0 10px 30px rgba(0, 0, 0, .3);
}
.reader-bar__text { margin: 0; font-weight: 700; }
.reader-bar__btn {
	min-height: 2.75rem; padding: .35rem 1.05rem; border: 2px solid var(--c-on-ink); border-radius: 999px;
	background: transparent; color: var(--c-on-ink); font: inherit; font-weight: 700; cursor: pointer;
}
.reader-bar__btn:hover { background: var(--c-on-ink); color: var(--c-ink); }
.reader-bar__btn:focus-visible { outline-color: var(--c-blue-logo); }
@media (max-width: 77.99rem) { .reader-bar { bottom: 4.65rem; } }

/* Mode sombre : on change seulement les jetons de couleur. Le bleu devient clair, le texte posé
   dessus devient foncé (contraste ≥ 4,5:1 partout). Les photos ne changent pas. */
html[data-couleurs="sombre"] {
	color-scheme: dark;
	--c-ink: #eef0f2;
	--c-muted: #b4b9bf;
	--c-line: #3c4249;
	--c-grey: #1a1d21;
	--c-grey-dark: #272b30;
	--c-white: #111316;
	--c-surface: #1e2226;
	--c-on-ink: #111316;
	--c-on-blue: #0b1014;
	--c-blue-logo: #3aaee6;
	--c-blue: #6cc4f0;
	--c-blue-dark: #a6dcf7;
	--c-blue-tint: #0f2f3e;
	--c-cyan: #2fd3e3;
	--c-green: #a9cc12;
	--c-green-dark: #bcdc4c;
	--c-green-tint: #232a0e;
	--c-red-dark: #ff8d97;
	--c-red-tint: #3b1519;
	--c-field-border: #8f969d;
	--c-placeholder: #9ba1a7;
	--c-hatch: #1f4559;
	--c-calls-hover: #4a1d22;
	--shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 28px rgba(0, 0, 0, .5);
}
/* Le logo (fond transparent) se lit tel quel sur fond sombre : bleus, vert et gris clair, un peu éclaircis.
   Les logos d'associations, eux, ont un fond blanc : on garde leur rond blanc. */
html[data-couleurs="sombre"] :is(.brand__logo, .custom-logo) { filter: brightness(1.18) saturate(1.05); }
html[data-couleurs="sombre"] .asso__logo { background: #fff; }
html[data-couleurs="sombre"] .urgence__num { color: var(--c-red-dark); }
html[data-couleurs="sombre"] img:not(.brand__logo, .custom-logo) { filter: brightness(.92); }

/* 14. Emplacements de photos à venir -------------------------------------- */
.ph {
	display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .4rem;
	width: 100%; height: 100%; min-height: 10rem; padding: 1rem; text-align: center; color: var(--c-placeholder);
	background: repeating-linear-gradient(135deg, var(--c-grey) 0 14px, var(--c-grey-dark) 14px 15px);
}
.ph .icon { width: 2.4rem; height: 2.4rem; opacity: .7; }
.ph__label { font-weight: 700; color: var(--c-muted); }
.ph__brief { max-width: 28ch; font-size: .85rem; line-height: 1.35; color: var(--c-muted); }

/* 15. Mouvements réduits, impression -------------------------------------- */
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

@media print {
	.alert-bar, .site-header, .site-footer .footer__grid > nav, .btn, .side-tab, .quick-panel, .scroll-btn, .reader-bar, .mail-note { display: none !important; }
	body { font-size: 11pt; color: #000; }
	html[data-couleurs="sombre"] :is(body, body *) { color: #000 !important; background-color: transparent !important; }
	.site-footer { margin: 0; background: none; color: #000; }
	.site-footer::before { display: none; }
	a { color: #000; text-decoration: none; }
	.layout--aside { display: block; }
}
/* Fiche ouverte depuis la recherche : un contour bleu du logo qui s'efface doucement. */
.asso, .entry-card { scroll-margin-block: 7rem; }
.asso.is-found, .entry-card.is-found { animation: luant-found 2.6s ease-out; }
@keyframes luant-found { 0%, 55% { box-shadow: 0 0 0 4px var(--c-blue-logo); } 100% { box-shadow: 0 0 0 4px transparent; } }
