/*
 * sigurba2 : styles écran.
 *
 * Les couleurs viennent des variables --c-* : valeurs par défaut du schéma Blue
 * ci-dessous, remplacées par celles choisies dans Apparence > Options sigurba2
 * (feuille en ligne générée par inc/colors.php).
 */

/* ==========================================================================
   Variables
   ========================================================================== */

:root {
	/* Schéma de couleurs (Blue par défaut, clés de l'option painter_color_scheme) */
	--c-general-border: #3f6e9d;
	--c-general-background: #ffffff;
	--c-general-navigation-link: #3f6e9d;
	--c-header-background: #27537e;
	--c-header-title: #ffffff;
	--c-header-description: #d1ebfa;
	--c-menu-border: #416991;
	--c-menu-background: #14212e;
	--c-menu-background-active: #1a344d;
	--c-menu-link: #ffffff;
	--c-menu-link-active: #d1ebfa;
	--c-submenu-border: #bed1e4;
	--c-submenu-background: #496991;
	--c-submenu-background-active: #27537e;
	--c-submenu-link: #ffffff;
	--c-submenu-link-active: #e0e9fc;
	--c-breadcrumb-text: #416991;
	--c-breadcrumb-link: #27537e;
	--c-content-background: #eff7ff;
	--c-content-background-odd: #dfedfb;
	--c-content-session-background: #416991;
	--c-content-session-title: #ffffff;
	--c-content-slide: #6499ce;
	--c-content-slide-active: #cedff8;
	--c-content-title: #416991;
	--c-content-text: #4e8cb1;
	--c-content-link: #3f6e9d;
	--c-content-info: #3f6e9d;
	--c-content-box-border: #7298bd;
	--c-content-box-background: #7298bd;
	--c-content-box-text: #ffffff;
	--c-content-box-link: #cedff8;
	--c-content-input-border: #f2f2f2;
	--c-content-input-background: #ffffff;
	--c-content-input-text: #4e8cb1;
	--c-content-button-border: #f2f2f2;
	--c-content-button-background: #ffffff;
	--c-content-button-text: #416991;
	--c-sidebar-border: #cadbed;
	--c-sidebar-background: #eff7ff;
	--c-sidebar-background-odd: #e2ecf7;
	--c-sidebar-session-background: #496991;
	--c-sidebar-session-title: #ffffff;
	--c-sidebar-text: #355b82;
	--c-sidebar-link: #355b82;
	--c-sidebar-input-border: #3f6e9d;
	--c-sidebar-input-background: #ffffff;
	--c-sidebar-input-text: #114973;
	--c-sidebar-button-border: #f2f2f2;
	--c-sidebar-button-background: #4e8cb1;
	--c-sidebar-button-text: #114973;
	--c-footer-background: #416991;
	--c-footer-text: #b3ceea;
	--c-footer-link: #ffffff;

	/* Texte courant : couleur du schéma assombrie pour rester lisible */
	--text: color-mix(in srgb, var(--c-content-text) 68%, #0d1b2a);
	--text-soft: color-mix(in srgb, var(--c-content-info) 80%, #0d1b2a);
	--border: color-mix(in srgb, var(--c-content-background-odd) 70%, var(--c-content-title));

	/* Couleurs du portail GeoRezo */
	--grz-orange: #ef7103;
	--grz-orange-dark: #c25a00;
	--grz-blue: #456baa;
	--grz-blue-dark: #2c4a7e;

	--page-bg: #e9edf2;
	--radius: 12px;
	--radius-sm: 7px;
	--shadow: 0 1px 2px rgba(13, 27, 42, .06), 0 6px 22px rgba(13, 27, 42, .08);
	--gap: clamp(1rem, 2.5vw, 1.75rem);
	--site-w: 1180px;

	--font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
	--font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

/* ==========================================================================
   Base
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
	margin: 0;
	background: var(--page-bg);
	color: var(--text);
	font: 1.0625rem/1.65 var(--font-sans);
	-webkit-font-smoothing: antialiased;
}

img, svg, video, iframe { max-width: 100%; }
img { height: auto; }

a { color: var(--c-content-link); text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { color: var(--c-content-title); }
:focus-visible {
	outline: 3px solid var(--grz-orange);
	outline-offset: 2px;
	border-radius: 3px;
}

h1, h2, h3, h4, h5, h6 {
	color: var(--c-content-title);
	line-height: 1.25;
	margin: 1.6em 0 .6em;
	font-weight: 700;
	letter-spacing: -.01em;
}
h1 { font-size: clamp(1.55rem, 1.2rem + 1.4vw, 2.1rem); }
h2 { font-size: clamp(1.3rem, 1.1rem + .7vw, 1.6rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.1rem; }
h5, h6 { font-size: 1rem; }

p, ul, ol, dl, blockquote, pre, figure, table { margin: 0 0 1.1em; }

input, select, textarea, button { font: inherit; color: inherit; }

input[type="text"], input[type="email"], input[type="url"], input[type="search"], input[type="password"],
input[type="number"], input[type="tel"], select, textarea {
	width: 100%;
	max-width: 100%;
	padding: .5em .7em;
	border: 1px solid color-mix(in srgb, var(--c-content-input-border) 40%, var(--border));
	border-radius: var(--radius-sm);
	background: var(--c-content-input-background);
	color: color-mix(in srgb, var(--c-content-input-text) 65%, #0d1b2a);
	transition: border-color .15s ease, box-shadow .15s ease;
}
input:focus, select:focus, textarea:focus {
	border-color: var(--c-content-title);
	box-shadow: 0 0 0 3px color-mix(in srgb, var(--c-content-title) 22%, transparent);
	outline: none;
}
label { display: block; margin-bottom: .25em; font-weight: 600; font-size: .92rem; }

button, .button, input[type="submit"] {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: .45em;
	padding: .55em 1.15em;
	border: 2px solid var(--c-content-title);
	border-radius: 999px;
	background: var(--c-content-title);
	color: #fff;
	font-weight: 700;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
button:hover, .button:hover, input[type="submit"]:hover {
	background: color-mix(in srgb, var(--c-content-title) 80%, #000);
	border-color: color-mix(in srgb, var(--c-content-title) 80%, #000);
	color: #fff;
}

.screen-reader-text {
	border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%);
	height: 1px; width: 1px; margin: -1px; overflow: hidden; padding: 0;
	position: absolute !important; word-wrap: normal !important;
}
.skip-link:focus {
	clip: auto; clip-path: none; height: auto; width: auto; margin: 0;
	position: fixed !important; top: .5rem; left: .5rem; z-index: 1000;
	padding: .6em 1em; background: #fff; color: var(--c-content-title); font-weight: 700;
	border-radius: var(--radius-sm); box-shadow: var(--shadow);
}

.container {
	width: min(100% - 2 * var(--gap), var(--site-w));
	margin-inline: auto;
}

.icon { flex: none; vertical-align: -.15em; }

/* ==========================================================================
   Page
   ========================================================================== */

.site {
	width: min(100% - 2 * var(--gap), var(--site-w));
	margin: 1.5rem auto 2rem;
	background: var(--c-general-background);
	border-top: 4px solid var(--c-general-border);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
	overflow: clip;
}

@media (max-width: 700px) {
	.site { width: 100%; margin: 0; border-radius: 0; border-top: 0; }
}

/* ==========================================================================
   En-tête : bandeau et menu
   ========================================================================== */

.site-header { background: var(--c-header-background); }
.site-header .site-title { margin: 0; line-height: 0; }
.site-banner {
	display: block;
	width: 100%;
	height: auto;
	min-height: 64px;
	object-fit: cover;
	object-position: right center;
}

/* Nom et description du blog sur la couleur d'en-tête et la trame de parcelles */
.site-branding {
	display: flex;
	flex-direction: column;
	justify-content: center;
	min-height: clamp(6.5rem, 12vw, 9rem);
	padding: clamp(1.2rem, 3.5vw, 2.2rem) var(--gap);
	background-color: var(--c-header-background);
}
.site-branding--image {
	background-image:
		linear-gradient(90deg, color-mix(in srgb, var(--c-header-background) 55%, transparent) 0%, transparent 65%),
		var(--header-image);
	background-repeat: no-repeat;
	background-position: center, right center;
	background-size: cover, cover;
}
.site-title--text { line-height: 1.1 !important; font-size: clamp(1.8rem, 1.2rem + 2.6vw, 3rem); font-weight: 800; letter-spacing: -.02em; }
.site-title--text a { color: var(--header-text, var(--c-header-title)); text-decoration: none; text-shadow: 0 1px 12px color-mix(in srgb, var(--c-header-background) 70%, transparent); }
.site-title--text a:hover { text-decoration: underline; text-decoration-thickness: 2px; }
.site-description { margin: .4em 0 0; color: var(--header-text, var(--c-header-description)); font-size: clamp(.95rem, .9rem + .3vw, 1.1rem); }

/* Lien vers le flux RSS, à droite du menu (remplace l'ancienne barre de date) */
.main-nav { display: flex; align-items: center; }
.main-nav .menu { flex: 1; }
.main-nav .main-nav__feed {
	display: inline-flex;
	align-self: stretch;
	align-items: center;
	padding: 0 var(--gap) !important;
	color: var(--c-menu-link) !important;
}
.main-nav .main-nav__feed:hover { background: var(--c-menu-background-active); color: var(--grz-orange) !important; }
.main-nav__feed .icon { width: 18px; height: 18px; }

.main-nav {
	position: relative;
	background: var(--c-menu-background);
	border-top: 1px solid var(--c-menu-border);
	font-size: .95rem;
}
.main-nav ul { list-style: none; margin: 0; padding: 0; }
.main-nav .menu { display: flex; flex-wrap: wrap; padding-inline: calc(var(--gap) - .8em); }
.main-nav li { position: relative; display: flex; align-items: center; }
.main-nav a {
	display: block;
	padding: .8em .8em;
	color: var(--c-menu-link);
	font-weight: 600;
	text-decoration: none;
	transition: background-color .15s ease, color .15s ease;
}
.main-nav .menu > li > a { box-shadow: inset 0 -3px 0 transparent; }
.main-nav .menu > li > a:hover,
.main-nav .menu > li:focus-within > a {
	background: var(--c-menu-background-active);
	color: var(--c-menu-link-active);
}
.main-nav .menu > .current_page_item > a,
.main-nav .menu > .current-menu-item > a,
.main-nav .menu > .current_page_ancestor > a,
.main-nav .menu > .current-menu-ancestor > a {
	color: var(--c-menu-link-active);
	box-shadow: inset 0 -3px 0 var(--grz-orange);
}

/* Bouton d'ouverture des sous-menus (ajouté par script.js) */
.submenu-toggle {
	width: 1.8em;
	height: 1.8em;
	margin-left: -.55em;
	margin-right: .2em;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--c-menu-link);
}
.submenu-toggle::before {
	content: "";
	display: block;
	width: .45em;
	height: .45em;
	margin: -.2em auto 0;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	transition: transform .15s ease;
}
.submenu-toggle:hover { background: var(--c-menu-background-active); border: 0; color: var(--c-menu-link-active); }
.is-open > .submenu-toggle::before { margin-top: .15em; transform: rotate(-135deg); }

.main-nav .sub-menu, .main-nav .children {
	position: absolute;
	top: 100%;
	left: 0;
	z-index: 100;
	min-width: 14rem;
	padding: .35rem 0;
	background: var(--c-submenu-background);
	border-radius: 0 0 var(--radius-sm) var(--radius-sm);
	box-shadow: 0 12px 24px rgba(13, 27, 42, .25);
	visibility: hidden;
	opacity: 0;
	transform: translateY(-4px);
	transition: opacity .15s ease, transform .15s ease, visibility 0s .15s;
}
.main-nav li:hover > .sub-menu, .main-nav li:hover > .children,
.main-nav li:focus-within > .sub-menu, .main-nav li:focus-within > .children,
.main-nav li.is-open > .sub-menu, .main-nav li.is-open > .children {
	visibility: visible;
	opacity: 1;
	transform: none;
	transition-delay: 0s;
}
.main-nav .sub-menu li, .main-nav .children li { display: block; }
.main-nav .sub-menu li + li, .main-nav .children li + li {
	border-top: 1px solid color-mix(in srgb, var(--c-submenu-border) 35%, transparent);
}
.main-nav .sub-menu a, .main-nav .children a { padding: .55em 1.1em; color: var(--c-submenu-link); font-weight: 500; }
.main-nav .sub-menu a:hover, .main-nav .children a:hover {
	background: var(--c-submenu-background-active);
	color: var(--c-submenu-link-active);
}

.menu-toggle { display: none; }

@media (max-width: 760px) {
	.menu-toggle {
		display: flex;
		width: 100%;
		justify-content: flex-start;
		padding: .8em var(--gap);
		border: 0;
		border-radius: 0;
		background: transparent;
		color: var(--c-menu-link);
	}
	.menu-toggle:hover { background: var(--c-menu-background-active); border: 0; }
	.menu-toggle__icon, .menu-toggle__icon::before, .menu-toggle__icon::after {
		display: block;
		width: 1.15em;
		height: 2px;
		border-radius: 2px;
		background: currentColor;
		transition: transform .2s ease, background-color .2s ease;
	}
	.menu-toggle__icon { position: relative; }
	.menu-toggle__icon::before, .menu-toggle__icon::after { content: ""; position: absolute; left: 0; }
	.menu-toggle__icon::before { top: -6px; }
	.menu-toggle__icon::after { top: 6px; }
	.main-nav.is-open .menu-toggle__icon { background: transparent; }
	.main-nav.is-open .menu-toggle__icon::before { transform: translateY(6px) rotate(45deg); }
	.main-nav.is-open .menu-toggle__icon::after { transform: translateY(-6px) rotate(-45deg); }

	.main-nav { flex-wrap: wrap; }
	.menu-toggle { flex: 1; width: auto; }
	.main-nav .main-nav__feed { order: 2; padding-block: .8em !important; }
	.main-nav .menu { order: 3; flex-basis: 100%; display: none; padding: 0 0 .5rem; }
	.main-nav.is-open .menu { display: block; }
	.main-nav li { flex-wrap: wrap; }
	.main-nav li > a { flex: 1; padding-inline: var(--gap); }
	.main-nav .menu > li + li { border-top: 1px solid color-mix(in srgb, var(--c-menu-border) 50%, transparent); }
	.main-nav .menu > li > a { box-shadow: none !important; }
	.submenu-toggle { width: 2.6em; height: 2.6em; margin: 0 calc(var(--gap) - .6em) 0 0; }

	.main-nav .sub-menu, .main-nav .children {
		position: static;
		display: none;
		flex-basis: 100%;
		min-width: 0;
		padding: 0;
		border-radius: 0;
		box-shadow: none;
		visibility: visible;
		opacity: 1;
		transform: none;
		transition: none;
	}
	.main-nav li.is-open > .sub-menu, .main-nav li.is-open > .children { display: block; }
	.main-nav .sub-menu a, .main-nav .children a { padding-left: calc(var(--gap) + 1em); }
}

/* Fil d'Ariane (extension Breadcrumb Navigation XT) */
.breadcrumb {
	padding: .6rem var(--gap);
	border-bottom: 1px solid var(--border);
	color: var(--c-breadcrumb-text);
	font-size: .88rem;
}
.breadcrumb p { margin: 0; }
.breadcrumb a { color: var(--c-breadcrumb-link); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* ==========================================================================
   Mise en page : contenu + colonne
   ========================================================================== */

.site-content {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: var(--gap);
	padding: var(--gap);
}
@media (min-width: 960px) {
	.site-content { grid-template-columns: minmax(0, 1fr) 18.5rem; align-items: start; }
}

.content > :first-child { margin-top: 0; }

/* Titres de section (« Nouveautés », archives, commentaires) */
.content-title {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: .2em .6em;
	margin: 2rem 0 1rem;
	padding: .55em 1em;
	background: var(--c-content-session-background);
	border-radius: var(--radius-sm);
	color: var(--c-content-session-title);
	font-size: 1.15rem;
	letter-spacing: 0;
}
.content-title a { color: inherit; }
.content-title__kicker {
	font-size: .72rem;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
	opacity: .8;
}
.archive-description { margin: -.3rem 0 1.2rem; color: var(--text-soft); }

/* ==========================================================================
   Articles
   ========================================================================== */

.post-list { display: grid; gap: 1rem; }

.post {
	position: relative;
	padding: clamp(1rem, 2.5vw, 1.6rem);
	background: var(--c-content-background);
	border: 1px solid var(--c-content-background-odd);
	border-radius: var(--radius);
}
.post-list > .post:nth-child(even) { background: color-mix(in srgb, var(--c-content-background-odd) 55%, var(--c-content-background)); }
.post--single { padding: clamp(1.1rem, 3vw, 2.2rem); }
.post--empty { text-align: center; }
.post--empty form { max-width: 28rem; margin: 0 auto 1rem; }
.error-code { margin: 0; color: var(--c-content-title); font-size: 4rem; font-weight: 800; line-height: 1; opacity: .35; }

.post-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.post-title { margin: 0 0 .4rem; color: var(--c-content-title); font-size: clamp(1.25rem, 1.1rem + .6vw, 1.55rem); }
.post--single .post-title { font-size: clamp(1.55rem, 1.2rem + 1.4vw, 2.1rem); }
.post-title a { color: inherit; text-decoration: none; }
.post-title a:hover { text-decoration: underline; text-decoration-thickness: 2px; }

.post-edit {
	display: inline-flex;
	padding: .35rem;
	border-radius: 50%;
	color: var(--c-content-info);
}
.post-edit:hover { background: var(--c-content-background-odd); }

.post-actions { display: flex; flex: none; gap: .4rem; margin-top: .3rem; }
.post-action, .post-actions .post-action {
	display: inline-flex;
	align-items: center;
	gap: .35em;
	padding: .3em .75em;
	border: 1px solid var(--border);
	border-radius: 999px;
	background: transparent;
	color: var(--c-content-info);
	font-size: .82rem;
	font-weight: 600;
	text-decoration: none;
}
.post-action:hover, .post-actions .post-action:hover {
	background: var(--c-content-background-odd);
	border-color: var(--border);
	color: var(--c-content-title);
}

.post-lead { margin: .3rem 0 1rem; color: var(--text-soft); font-size: 1.08rem; font-weight: 500; }
.post-lead p:last-child { margin-bottom: 0; }

.post-info {
	display: flex;
	flex-wrap: wrap;
	gap: .3rem 1.1rem;
	margin: 0 0 .8rem;
	color: var(--c-content-info);
	font-size: .88rem;
}
.post-info > span { display: inline-flex; align-items: center; gap: .35em; }
.post-info a { color: inherit; font-weight: 600; text-decoration: none; }
.post-info a:hover { text-decoration: underline; }

.post-footer:empty { display: none; }
.post-footer { margin-top: 1rem; padding-top: .8rem; border-top: 1px solid var(--border); }
.post-footer .post-info { margin: 0; }
.post-footer > :last-child { margin-bottom: 0; }

.tags { display: flex; flex-wrap: wrap; gap: .35rem; margin: .7rem 0 0; padding: 0; list-style: none; }
.post-footer .post-info + .tags { margin-top: .7rem; }
.post-footer > .tags:first-child { margin-top: 0; }
.tags a {
	display: inline-block;
	padding: .15em .7em;
	background: var(--c-general-background);
	border: 1px solid var(--border);
	border-radius: 999px;
	color: var(--c-content-info);
	font-size: .82rem;
	text-decoration: none;
}
.tags a::before { content: "#"; opacity: .55; }
.tags a:hover { background: var(--c-content-title); border-color: var(--c-content-title); color: #fff; }

/* Contenu rédigé */
.entry { overflow-wrap: break-word; }
.entry::after { content: ""; display: table; clear: both; }
.entry > :last-child { margin-bottom: 0; }
.post--single .entry { font-size: 1.07rem; }
.entry h2, .entry h3, .entry h4 { margin-top: 1.5em; }
.entry ul, .entry ol { padding-left: 1.4em; }
.entry li { margin: .25em 0; }
.entry li::marker { color: var(--c-content-title); }
.entry a { color: var(--c-content-link); }
.entry hr { border: 0; border-top: 2px solid var(--c-content-box-border); margin: 2em 0; opacity: .5; }

.entry blockquote {
	margin-left: 0;
	padding: .7em 1.2em;
	border-left: 4px solid var(--c-content-box-border);
	background: color-mix(in srgb, var(--c-content-box-background) 12%, #fff);
	border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
	color: var(--text);
	font-style: italic;
}
.entry blockquote p:last-child { margin-bottom: 0; }
.entry blockquote cite { display: block; margin-top: .4em; font-size: .9em; font-style: normal; }

code, kbd, pre { font-family: var(--font-mono); font-size: .9em; }
.entry code { padding: .1em .35em; background: color-mix(in srgb, var(--c-content-box-background) 14%, #fff); border-radius: 4px; }
.entry pre {
	overflow-x: auto;
	padding: 1em 1.2em;
	background: var(--c-content-box-background);
	color: var(--c-content-box-text);
	border-radius: var(--radius-sm);
	line-height: 1.5;
}
.entry pre code { padding: 0; background: none; color: inherit; }
.entry pre a { color: var(--c-content-box-link); }

.entry table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.entry th, .entry td { padding: .5em .7em; border-bottom: 1px solid var(--border); text-align: left; }
.entry th { color: var(--c-content-title); }

.entry img { border-radius: 4px; }
.alignleft { float: left; margin: .3em 1.4em 1em 0; }
.alignright { float: right; margin: .3em 0 1em 1.4em; }
.aligncenter { display: block; margin-inline: auto; }
@media (max-width: 600px) {
	.entry .alignleft, .entry .alignright { float: none; margin: 0 auto 1em; display: block; }
}
.wp-caption { max-width: 100%; }
.wp-caption-text, .wp-element-caption, figcaption {
	margin-top: .4em;
	color: var(--c-content-info);
	font-size: .85rem;
	text-align: center;
}
.gallery { display: grid; gap: .6rem; grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr)); }
.gallery-item { margin: 0; }

.more-link { display: inline-block; margin-top: .3em; font-weight: 700; text-decoration: none; }
.more-link:hover { text-decoration: underline; }

.page-links { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin-top: 1.5rem; }
.page-links a, .page-links > .post-page-numbers {
	display: inline-block;
	min-width: 2em;
	padding: .2em .5em;
	border: 1px solid var(--border);
	border-radius: var(--radius-sm);
	text-align: center;
	text-decoration: none;
}
.page-links .current { background: var(--c-content-title); border-color: var(--c-content-title); color: #fff; }

/* Pagination et navigation entre articles */
.pagination, .post-navigation .nav-links {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: .8rem;
	margin: 1.5rem 0 0;
}
.pagination a {
	display: inline-block;
	padding: .5em 1.1em;
	border: 2px solid var(--c-general-navigation-link);
	border-radius: 999px;
	color: var(--c-general-navigation-link);
	font-weight: 700;
	text-decoration: none;
}
.pagination a:hover { background: var(--c-general-navigation-link); color: #fff; }
.pagination__next { margin-left: auto; }

.post-navigation .nav-links > div { flex: 1 1 15rem; }
.post-navigation .nav-next { text-align: right; }
.post-navigation a {
	display: block;
	height: 100%;
	padding: .8rem 1rem;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	text-decoration: none;
}
.post-navigation a:hover { background: var(--c-content-background); border-color: var(--c-general-navigation-link); }
.post-navigation__label { display: block; color: var(--c-general-navigation-link); font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.post-navigation__title { color: var(--c-content-title); font-weight: 600; }

/* ==========================================================================
   Diaporama « À la une » (catégorie highlights)
   ========================================================================== */

.highlight { margin-bottom: 1.5rem; }
.highlight__head { display: flex; align-items: center; gap: .8rem; margin-bottom: 1rem; }
.highlight__head .content-title { flex: 1; margin: 0; }
.highlight__controls { display: flex; align-items: center; gap: .5rem; }
.highlight__controls[hidden] { display: none; }
.highlight__pager { display: flex; gap: .4rem; }

.highlight__dot {
	width: .85rem;
	height: .85rem;
	padding: 0;
	border: 2px solid var(--c-content-slide);
	border-radius: 50%;
	background: transparent;
}
.highlight__dot:hover { background: var(--c-content-slide); border-color: var(--c-content-slide); }
.highlight__dot.is-active { background: var(--c-content-slide); border-color: var(--c-content-slide); transform: scale(1.15); }

.highlight__pause {
	width: 2rem;
	height: 2rem;
	padding: 0;
	border: 2px solid var(--c-content-slide);
	border-radius: 50%;
	background: transparent;
	color: var(--c-content-slide);
}
.highlight__pause::before {
	content: "";
	width: .55rem;
	height: .7rem;
	border-inline: 3px solid currentColor;
}
.highlight.is-paused .highlight__pause::before {
	width: 0;
	height: 0;
	margin-left: .2rem;
	border-style: solid;
	border-width: .38rem 0 .38rem .6rem;
	border-color: transparent transparent transparent currentColor;
}
.highlight__pause:hover { background: var(--c-content-slide); border-color: var(--c-content-slide); color: #fff; }

.highlight__slides {
	display: grid;
	gap: 1rem;
	padding: clamp(1rem, 2.5vw, 1.5rem);
	background: var(--c-content-background);
	border: 1px solid var(--c-content-background-odd);
	border-bottom: 3px solid var(--c-content-slide);
	border-radius: var(--radius);
}
.highlight__slide { display: grid; gap: 1.2rem; grid-template-columns: minmax(0, 1fr); align-items: start; }
@media (min-width: 560px) {
	.highlight__slide:has(.highlight__image) { grid-template-columns: minmax(0, 13rem) minmax(0, 1fr); }
}
.highlight__image img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius-sm); }
.highlight .post-title { font-size: 1.3rem; }
.highlight .entry p { margin-bottom: .6em; }

/* Une diapositive à la fois, empilées dans la même cellule : la hauteur suit la plus haute. */
.highlight.is-enhanced .highlight__slide {
	grid-area: 1 / 1;
	visibility: hidden;
	opacity: 0;
	transition: opacity .7s ease, visibility 0s .7s;
}
.highlight.is-enhanced .highlight__slide.is-active {
	visibility: visible;
	opacity: 1;
	transition-delay: 0s;
}
.highlight:not(.is-enhanced) .highlight__slide + .highlight__slide { padding-top: 1rem; border-top: 1px solid var(--border); }

/* ==========================================================================
   Commentaires
   ========================================================================== */

.comments { margin-top: 1.5rem; }
.comments-title { justify-content: space-between; }
.comments-feed { font-size: .8rem; font-weight: 600; opacity: .85; }
.comment-list, .ping-list, .comment-list .children { list-style: none; margin: 0 0 1.5rem; padding: 0; }
.comment-list .children { margin: 0 0 0 clamp(.8rem, 4vw, 2.5rem); }
.comment-body {
	margin-top: .8rem;
	padding: 1rem 1.2rem;
	background: var(--c-content-background);
	border: 1px solid var(--c-content-background-odd);
	border-radius: var(--radius);
}
.comment-list > li:nth-child(even) > .comment-body { background: color-mix(in srgb, var(--c-content-background-odd) 55%, var(--c-content-background)); }
.comment-header { display: flex; align-items: center; gap: .8rem; margin-bottom: .5rem; }
.comment-avatar { flex: none; border-radius: 50%; }
.comment-author, .comment-date { margin: 0; }
.comment-author { font-weight: 700; color: var(--c-content-title); }
.comment-author a { color: inherit; }
.comment-date { color: var(--c-content-info); font-size: .85rem; }
.comment-date a { color: inherit; text-decoration: none; }
.author-comment > .comment-body { border-left: 4px solid var(--c-content-title); }
.author-comment > .comment-body .comment-author::after {
	content: "auteur";
	margin-left: .5em;
	padding: .05em .55em;
	background: var(--c-content-title);
	border-radius: 999px;
	color: #fff;
	font-size: .72rem;
	font-weight: 600;
	vertical-align: .1em;
}
.comment-content { overflow-wrap: break-word; }
.comment-content p:last-child { margin-bottom: 0; }
.comment-awaiting-moderation { padding: .3em .7em; background: #fff4e5; border-radius: var(--radius-sm); font-size: .9rem; }
.comment-reply { margin: .5rem 0 0; font-size: .88rem; text-align: right; }
.comment-reply a { font-weight: 700; text-decoration: none; }
.ping-list li { padding: .5em 0; border-top: 1px solid var(--border); }
.ping-list .comment-date { margin-left: .5em; }

.comment-respond {
	margin-top: 1.5rem;
}
.comment-reply-title small { margin-left: auto; font-size: .8rem; font-weight: 500; }
.comment-reply-title small a { color: inherit; }
.comment-notes, .logged-in-as, .must-log-in { color: var(--text-soft); font-size: .9rem; }
.comment-form {
	display: grid;
	gap: 0 1rem;
	grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
	padding: clamp(1rem, 2.5vw, 1.5rem);
	background: var(--c-content-background);
	border: 1px solid var(--c-content-background-odd);
	border-radius: var(--radius);
}
.comment-form > p { margin-bottom: .9rem; }
.comment-form .comment-notes, .comment-form .logged-in-as, .comment-form .comment-form-comment,
.comment-form .comment-form-cookies-consent, .comment-form .form-submit { grid-column: 1 / -1; }
.comment-form .form-submit { margin-bottom: 0; }
.comment-form .required { color: var(--text-soft); font-weight: 400; }
.comment-form-cookies-consent { display: flex; gap: .5rem; align-items: flex-start; font-size: .9rem; }
.comment-form-cookies-consent input { margin-top: .3em; }
.comment-form-cookies-consent label { font-weight: 400; }
.comment-form .button {
	border-color: var(--c-content-button-border);
	background: var(--c-content-button-background);
	color: var(--c-content-button-text);
	box-shadow: inset 0 0 0 2px var(--c-content-title);
}
.comment-form .button:hover { background: var(--c-content-title); color: #fff; }
.comments-closed, .nocomments { color: var(--text-soft); font-style: italic; }

/* ==========================================================================
   Colonne et widgets
   ========================================================================== */

.sidebar { display: grid; gap: 1.1rem; min-width: 0; font-size: .95rem; }
@media (min-width: 700px) and (max-width: 959px) {
	.sidebar { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
}

.sidebar .widget {
	min-width: 0;
	padding: 0 1rem 1rem;
	background: var(--c-sidebar-background);
	border: 1px solid var(--c-sidebar-border);
	border-radius: var(--radius);
	color: var(--c-sidebar-text);
	overflow-wrap: anywhere;
}
.sidebar .widget-title, .sidebar .widget .wp-block-heading {
	margin: 0 -1rem .8rem;
	padding: .6em 1rem;
	background: var(--c-sidebar-session-background);
	border-radius: calc(var(--radius) - 1px) calc(var(--radius) - 1px) 0 0;
	color: var(--c-sidebar-session-title);
	font-size: 1rem;
}
.sidebar .widget-title a { color: inherit; text-decoration: none; }
.sidebar .widget > :first-child:not(.widget-title):not(.wp-block-heading) { margin-top: 1rem; }
.sidebar .widget > :last-child { margin-bottom: 0; }
.sidebar .widget a { color: var(--c-sidebar-link); text-decoration: none; }
.sidebar .widget a:hover { text-decoration: underline; }
.sidebar .widget p { margin: 0 0 .7em; }

.sidebar .widget ul { list-style: none; margin: 0; padding: 0; }
.sidebar .widget li { padding: .45em 0; }
.sidebar .widget li + li { border-top: 1px solid var(--c-sidebar-border); }
.sidebar .widget li ul { margin: .35em 0 -.45em; padding-left: 1em; }
.sidebar .widget li li { border-top: 1px dashed var(--c-sidebar-border); }

/* Listes de liens : la ligne entière est cliquable */
.sidebar .widget_categories li a, .sidebar .widget_pages li a, .sidebar .widget_archive li a,
.sidebar .widget_recent_entries li a, .sidebar .widget_links li a, .sidebar .widget_meta li a,
.sidebar .widget_nav_menu li a {
	display: block;
	margin: -.45em -.5rem;
	padding: .45em .5rem;
	border-radius: var(--radius-sm);
}
.sidebar .widget_categories li a:hover, .sidebar .widget_pages li a:hover, .sidebar .widget_archive li a:hover,
.sidebar .widget_recent_entries li a:hover, .sidebar .widget_links li a:hover, .sidebar .widget_meta li a:hover,
.sidebar .widget_nav_menu li a:hover {
	background: var(--c-sidebar-background-odd);
	text-decoration: none;
}
.sidebar .widget_categories li, .sidebar .widget_archive li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 .3em; }
.sidebar .widget_categories li > a, .sidebar .widget_archive li > a { flex: 1; }
.sidebar .widget_categories li > ul { flex-basis: 100%; }

.sidebar .widget .post-date, .sidebar .widget .rss-date, .sidebar .widget .comment-author-link { font-size: .85em; opacity: .85; }
.sidebar .widget_rss .rsswidget { font-weight: 700; }
.sidebar .widget_rss .rssSummary { margin-top: .2em; font-size: .9em; }
.sidebar .widget_recent_comments li { padding-left: 0; }

.sidebar .widget input[type="text"], .sidebar .widget input[type="search"], .sidebar .widget input[type="email"], .sidebar .widget select {
	border-color: var(--c-sidebar-input-border);
	background: var(--c-sidebar-input-background);
	color: var(--c-sidebar-input-text);
}
.sidebar .widget button, .sidebar .widget input[type="submit"], .sidebar .widget .wp-block-search__button {
	border-color: var(--c-sidebar-session-background);
	background: var(--c-sidebar-session-background);
	color: var(--c-sidebar-session-title);
}

/* Formulaire de recherche */
.search-form, .wp-block-search__inside-wrapper { display: flex; gap: .4rem; }
.wp-block-search__inside-wrapper { padding: 0 !important; border: 0 !important; }
.wp-block-search__input { flex: 1; min-width: 0; }
.search-form .search-submit, .wp-block-search__button { flex: none; margin: 0 !important; padding-inline: 1em; white-space: nowrap; }
.wp-block-search__label { margin-bottom: .3em; font-weight: 700; }
.search-form label { flex: 1; margin: 0; }
.search-form .search-field { min-width: 0; }

.sidebar .tagcloud, .sidebar .wp-block-tag-cloud { display: flex; flex-wrap: wrap; gap: .3rem; line-height: 1.3; }
.sidebar .tag-cloud-link {
	display: inline-block;
	padding: .15em .6em;
	background: var(--c-sidebar-background-odd);
	border-radius: 999px;
}

/* Calendrier */
.sidebar .wp-calendar-table { width: 100%; border-collapse: collapse; font-size: .85rem; text-align: center; table-layout: fixed; }
.sidebar .wp-calendar-table caption { margin-bottom: .4em; font-weight: 700; }
.sidebar .wp-calendar-table th, .sidebar .wp-calendar-table td { padding: .25em 0; }
.sidebar .wp-calendar-table a { display: block; border-radius: 4px; background: var(--c-sidebar-background-odd); font-weight: 700; }
.sidebar .wp-calendar-nav { display: flex; justify-content: space-between; margin-top: .4em; font-size: .85rem; }

/* ==========================================================================
   Identité GeoRezo
   ========================================================================== */

.georezo-logo { display: block; height: auto; }

.button--georezo { background: var(--grz-orange); border-color: var(--grz-orange); color: #fff; }
.button--georezo:hover { background: var(--grz-orange-dark); border-color: var(--grz-orange-dark); color: #fff; }
.button--ghost { background: transparent; border-color: rgba(255, 255, 255, .55); color: #fff; }
.button--ghost:hover { background: rgba(255, 255, 255, .12); border-color: #fff; }

/* Encadré « Un blog GeoRezo » (en tête de la colonne) */
.sidebar .georezo-card {
	padding-top: 1rem;
	background: linear-gradient(180deg, #fff 0%, #fff7ef 100%);
	border-color: #f3d9c0;
	border-top: 4px solid var(--grz-orange);
	color: #4a5562;
	text-align: center;
}
.georezo-card__logo { display: inline-block; margin-bottom: .4rem; }
.georezo-card__kicker {
	margin: 0 0 .3rem !important;
	color: var(--grz-orange-dark);
	font-size: .78rem;
	font-weight: 800;
	letter-spacing: .08em;
	text-transform: uppercase;
}
.georezo-card__text { margin: 0 0 .7rem; font-size: .9rem; }
.sidebar .georezo-card__text a { color: var(--grz-blue-dark); text-decoration: underline; }
.sidebar .georezo-card .georezo-card__links { display: flex; flex-wrap: wrap; justify-content: center; gap: .3rem; margin-bottom: .9rem; }
.sidebar .georezo-card .georezo-card__links li { padding: 0; border: 0; }
.sidebar .georezo-card .georezo-card__links a {
	display: inline-block;
	padding: .15em .7em;
	background: #eef2f9;
	border-radius: 999px;
	color: var(--grz-blue-dark);
	font-size: .82rem;
	font-weight: 600;
}
.sidebar .georezo-card .georezo-card__links a:hover { background: var(--grz-blue); color: #fff; text-decoration: none; }
.sidebar .georezo-card .button { color: #fff; text-decoration: none; }

/* Pied de page aux couleurs du portail */
.georezo-footer { background: var(--grz-blue-dark); color: rgba(255, 255, 255, .85); font-size: .92rem; }
.georezo-footer__inner {
	display: grid;
	gap: 2rem;
	grid-template-columns: minmax(0, 1fr);
	padding-block: 2.2rem;
}
@media (min-width: 900px) {
	.georezo-footer__inner { grid-template-columns: minmax(16rem, 22rem) minmax(0, 1fr); }
}
.georezo-footer__logo {
	display: inline-block;
	margin-bottom: .9rem;
	padding: .5rem .8rem;
	background: #fff;
	border-radius: var(--radius-sm);
}
.georezo-footer p { margin: 0 0 .8em; }
.georezo-footer strong { color: #fff; }
.georezo-footer a { color: #fff; }
.georezo-footer a:hover { color: #ffd2a8; }
.georezo-footer__actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.georezo-footer__sections {
	display: grid;
	gap: 1.2rem 1.5rem;
	grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
}
.georezo-footer__title {
	margin-bottom: .5em !important;
	padding-bottom: .35em;
	border-bottom: 2px solid var(--grz-orange);
	color: #fff;
	font-weight: 700;
}
.georezo-footer__section ul { margin: 0; padding: 0; list-style: none; }
.georezo-footer__section li { margin: .25em 0; }
.georezo-footer__section a { color: rgba(255, 255, 255, .85); text-decoration: none; }
.georezo-footer__section a:hover { color: #fff; text-decoration: underline; }

/* Bandeau légal (couleurs « pied de page » du schéma) */
.site-footer { background: var(--c-footer-background); color: var(--c-footer-text); font-size: .88rem; }
.site-footer__inner {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: center;
	gap: .5rem 2rem;
	padding-block: 1rem;
}
.site-footer__about { margin: 0; }
.site-footer a { color: var(--c-footer-link); }
.site-footer__links { display: flex; flex-wrap: wrap; gap: .3rem 1.3rem; margin: 0; padding: 0; list-style: none; }

.logo-print { display: none; }

/* ==========================================================================
   Préférences d'accessibilité
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { transition: none !important; animation: none !important; }
}
