/**
 * Styles de la page Urbanisme.
 *
 * Toutes les règles sont scopées sous .urb-page pour ne jamais entrer
 * en conflit avec le thème (Bridge/qode) ou d'autres plugins.
 *
 * @package Isola_Urbanisme_Page
 */

.urb-page {
	--urb-blue: #008ECF;
	--urb-blue-dark: #006D9E;
	--urb-text: #1a1a1a;
	--urb-muted: #5a5a5a;
	--urb-border: #e5e5e5;
	--urb-bg-soft: #f7f8fa;
	--urb-radius: 10px;
	font-family: inherit;
	color: var(--urb-text);
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px 0 60px;
}

.urb-page * {
	box-sizing: border-box;
}

/* ---------- Sommaire d'ancres ---------- */
.urb-nav {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 36px;
	padding: 14px;
	background: var(--urb-bg-soft);
	border-radius: var(--urb-radius);
	position: sticky;
	top: 0;
	z-index: 20;
}

.urb-nav a {
	display: inline-block;
	padding: 9px 18px;
	background: #fff;
	border: 1px solid var(--urb-border);
	border-radius: 999px;
	color: var(--urb-text);
	text-decoration: none;
	font-size: 14px;
	font-weight: 600;
	white-space: nowrap;
	transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.urb-nav a:hover {
	border-color: var(--urb-blue);
	color: var(--urb-blue);
}

.urb-nav a.is-active {
	background: var(--urb-blue);
	border-color: var(--urb-blue);
	color: #fff;
}

/* ---------- Layout : contenu + colonne latérale ---------- */
.urb-layout {
	display: grid;
	grid-template-columns: 1fr 320px;
	gap: 48px;
	align-items: start;
}

@media (max-width: 900px) {
	.urb-layout {
		grid-template-columns: 1fr;
	}

	.urb-sidebar {
		position: static !important;
		order: -1;
	}
}

/* ---------- Contenu principal ---------- */
.urb-main {
	min-width: 0;
}

.urb-section {
	scroll-margin-top: 90px;
	padding-bottom: 44px;
	margin-bottom: 44px;
	border-bottom: 1px solid var(--urb-border);
	animation: urb-fade-in 0.2s ease;
}

/*
 * Repli des sections (mode "tabs").
 * L'attribut HTML natif [hidden] est ajouté par JavaScript une fois le
 * script chargé : sans JS, [hidden] n'est jamais posé et toutes les
 * sections restent visibles (filet de sécurité SEO/accessibilité).
 */
.urb-section[hidden] {
	display: none !important;
}

@keyframes urb-fade-in {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

.urb-section:last-child {
	border-bottom: none;
	margin-bottom: 0;
}

.urb-section h2 {
	font-size: 26px;
	font-weight: 800;
	margin: 0 0 18px;
	padding-bottom: 10px;
	border-bottom: 3px solid var(--urb-blue);
	display: inline-block;
}

.urb-section h3 {
	font-size: 17px;
	font-weight: 700;
	margin: 24px 0 10px;
}

.urb-section p {
	line-height: 1.65;
	margin: 0 0 14px;
	color: var(--urb-text);
}

.urb-section ul {
	margin: 0 0 16px;
	padding-left: 22px;
	line-height: 1.7;
}

.urb-section ul.urb-files li {
	margin-bottom: 6px;
}

.urb-section a {
	color: var(--urb-blue);
	font-weight: 600;
	text-decoration: none;
}

.urb-section a:hover {
	text-decoration: underline;
}

.urb-card {
	background: var(--urb-bg-soft);
	border-radius: var(--urb-radius);
	padding: 18px 20px;
	margin: 16px 0;
}

.urb-warning {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	background: #fff6e5;
	border: 1px solid #f3c969;
	border-radius: var(--urb-radius);
	padding: 14px 18px;
	margin: 16px 0;
	font-size: 14.5px;
	line-height: 1.55;
}

.urb-warning .urb-warning-icon {
	flex: 0 0 auto;
	font-size: 18px;
	line-height: 1;
}

.urb-steps {
	list-style: none;
	margin: 0;
	padding: 0;
	counter-reset: urb-step;
}

.urb-steps li {
	counter-increment: urb-step;
	position: relative;
	padding: 4px 0 16px 42px;
	line-height: 1.6;
}

.urb-steps li::before {
	content: counter(urb-step);
	position: absolute;
	left: 0;
	top: 2px;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background: var(--urb-blue);
	color: #fff;
	font-weight: 700;
	font-size: 14px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.urb-btn {
	display: inline-block;
	background: var(--urb-blue);
	color: #fff !important;
	font-weight: 700;
	padding: 10px 20px;
	border-radius: 6px;
	text-decoration: none !important;
	font-size: 14px;
}

.urb-btn:hover {
	background: var(--urb-blue-dark);
}

/* ---------- Colonne latérale ---------- */
.urb-sidebar {
	position: sticky;
	top: 90px;
	margin-bottom: 60px;
}

.urb-side-card {
	background: var(--urb-bg-soft);
	border-radius: var(--urb-radius);
	padding: 22px;
	margin-bottom: 18px;
}

.urb-side-card-last {
	margin-bottom: 0;
}

.urb-side-note {
	font-size: 13px;
	color: var(--urb-muted);
	line-height: 1.5;
	margin-top: 10px;
}

.urb-side-card h4 {
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: var(--urb-muted);
	margin: 0 0 12px;
}

.urb-side-card p {
	margin: 0 0 6px;
	font-size: 14.5px;
	line-height: 1.55;
}

.urb-side-card .urb-side-main {
	font-weight: 700;
	font-size: 15.5px;
	margin-bottom: 10px;
}

.urb-side-card a {
	color: var(--urb-blue);
	text-decoration: none;
	font-weight: 600;
}

.urb-side-card a:hover {
	text-decoration: underline;
}

.urb-side-card .urb-btn {
	display: block;
	text-align: center;
	margin-top: 12px;
}

/* ---------- Bloc Actualités ---------- */
.urb-actu {
	margin-top: 50px;
	padding-top: 50px;
	border-top: 1px solid var(--urb-border);
}

.urb-actu h2 {
	font-size: 26px;
	font-weight: 800;
	margin: 0 0 28px;
	padding-bottom: 10px;
	border-bottom: 3px solid var(--urb-blue);
	display: inline-block;
}

.urb-actu-grid {
	display: grid;
	grid-template-columns: 1.3fr 1fr;
	gap: 44px;
}

@media (max-width: 900px) {
	.urb-actu-grid {
		grid-template-columns: 1fr;
		gap: 32px;
	}
}

/* Colonne de gauche : article mis en avant (miniature + contenu) */
.urb-actu-featured {
	display: flex;
	gap: 18px;
	align-items: flex-start;
}

.urb-actu-featured-img {
	flex: 0 0 130px;
	width: 130px;
	display: block;
	border-radius: var(--urb-radius);
	overflow: hidden;
	line-height: 0;
}

.urb-actu-featured-img img {
	width: 100%;
	height: 100px;
	object-fit: cover;
	display: block;
	transition: transform 0.25s ease;
}

.urb-actu-featured-img:hover img {
	transform: scale(1.06);
}

.urb-actu-featured-body {
	flex: 1 1 auto;
	min-width: 0;
}

.urb-actu-featured-body time {
	display: block;
	font-size: 13px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: var(--urb-muted);
	margin-bottom: 6px;
}

.urb-actu-featured-body h3 {
	font-size: 19px;
	font-weight: 800;
	margin: 0 0 8px;
	line-height: 1.3;
}

.urb-actu-featured-body h3 a {
	color: var(--urb-text);
	text-decoration: none;
}

.urb-actu-featured-body h3 a:hover {
	color: var(--urb-blue);
}

.urb-actu-featured-body p {
	line-height: 1.55;
	font-size: 14.5px;
	color: var(--urb-text);
	margin: 0;
}

@media (max-width: 520px) {
	.urb-actu-featured {
		flex-direction: column;
	}

	.urb-actu-featured-img {
		width: 100%;
		flex-basis: auto;
	}

	.urb-actu-featured-img img {
		height: 180px;
	}
}

/* Colonne de droite : liste des autres articles */
.urb-actu-list {
	display: flex;
	flex-direction: column;
}

.urb-actu-list-item {
	padding: 16px 0;
	border-bottom: 1px solid var(--urb-border);
}

.urb-actu-list-item:first-child {
	padding-top: 0;
}

.urb-actu-list-item:last-child {
	border-bottom: none;
	padding-bottom: 0;
}

.urb-actu-list-item time {
	display: block;
	font-size: 12.5px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: var(--urb-muted);
	margin-bottom: 6px;
}

.urb-actu-list-item h4 {
	font-size: 15.5px;
	font-weight: 700;
	margin: 0;
	line-height: 1.4;
}

.urb-actu-list-item h4 a {
	color: var(--urb-text);
	text-decoration: none;
}

.urb-actu-list-item h4 a:hover {
	color: var(--urb-blue);
}
