/* I like my lake – mappa dei laghi. Colori ereditati dal tema (variabili --ilml-*) con valori di riserva. */
.ilml-map {
	--_blue: var(--ilml-blue, #1997d2);
	--_deep: var(--ilml-deep, #146dab);
	--_ink: var(--ilml-ink, #0e2a3b);
	--_muted: var(--ilml-muted, #5b7183);
	--_line: var(--ilml-line, #dbe6ee);
	--_bg: var(--ilml-surface, #f3f8fb);
	--_radius: var(--ilml-radius, 14px);
	font-family: var(--ilml-font-ui, system-ui, sans-serif);
	color: var(--_ink);
}
.ilml-map__bar {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: center;
	margin-bottom: 12px;
}
.ilml-map__search {
	position: relative;
	flex: 1 1 260px;
	display: flex;
	align-items: center;
}
.ilml-map__search svg {
	position: absolute;
	left: 14px;
	color: var(--_muted);
	pointer-events: none;
}
.ilml-map__search input,
.ilml-map__select select {
	width: 100%;
	height: 48px;
	border: 1px solid var(--_line);
	border-radius: var(--ilml-radius-ctl, 8px);
	background: #fff;
	color: var(--_ink);
	font: inherit;
	font-size: 16px;
	padding: 0 18px 0 42px;
	box-shadow: 0 1px 2px rgba(14, 42, 59, .04);
}
.ilml-map__select { flex: 0 1 240px; }
.ilml-map__select select { padding-left: 18px; cursor: pointer; }
.ilml-map__search input:focus,
.ilml-map__select select:focus {
	outline: 2px solid var(--_blue);
	outline-offset: 1px;
	border-color: transparent;
}
.ilml-map__count {
	font-weight: 600;
	color: var(--_deep);
	white-space: nowrap;
	padding: 0 6px;
}
.ilml-map__body {
	display: grid;
	grid-template-columns: 1fr;
	gap: 12px;
}
.ilml-map.has-list .ilml-map__body { grid-template-columns: minmax(0, 1fr) 300px; }
.ilml-map__canvas {
	height: var(--ilml-map-h, 560px);
	border-radius: var(--_radius);
	overflow: hidden;
	background: #cfe6f3;
	z-index: 0;
}
.ilml-map__list {
	list-style: none;
	margin: 0;
	padding: 6px;
	height: var(--ilml-map-h, 560px);
	overflow-y: auto;
	background: var(--_bg);
	border-radius: var(--_radius);
}
.ilml-map__list a {
	display: flex;
	flex-direction: column;
	padding: 9px 12px;
	border-radius: 10px;
	color: var(--_ink);
	text-decoration: none;
	line-height: 1.25;
}
.ilml-map__list a:hover,
.ilml-map__list a:focus { background: #fff; }
.ilml-map__name { font-weight: 600; }
.ilml-map__region { font-size: 13px; color: var(--_muted); }
.ilml-map__empty { padding: 12px; color: var(--_muted); }

@media (max-width: 860px) {
	.ilml-map.has-list .ilml-map__body { grid-template-columns: 1fr; }
	.ilml-map__canvas { height: min(var(--ilml-map-h, 560px), 70vh); }
	.ilml-map__list { height: auto; max-height: 320px; }
	.ilml-map__select { flex-basis: 100%; }
}

/* Segnaposto a goccia nei colori del logo */
.ilml-pin span {
	display: block;
	width: 100%;
	height: 100%;
	background: var(--_blue, #1997d2);
	border: 3px solid #fff;
	border-radius: 50% 50% 50% 0;
	transform: rotate(-45deg);
	box-shadow: 0 2px 6px rgba(14, 42, 59, .35);
}
.ilml-pin.is-active span { background: var(--_deep, #146dab); }
.ilml-cluster {
	display: flex !important;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	background: rgba(25, 151, 210, .25);
}
.ilml-cluster span {
	display: flex;
	align-items: center;
	justify-content: center;
	width: calc(100% - 8px);
	height: calc(100% - 8px);
	border-radius: 50%;
	background: #146dab;
	color: #fff;
	font: 700 13px/1 var(--ilml-font-ui, system-ui, sans-serif);
}

/* Popup */
.ilml-map .leaflet-popup-content-wrapper { border-radius: 12px; padding: 0; overflow: hidden; }
.ilml-map .leaflet-popup-content { margin: 0; width: auto !important; }
.ilml-pop { display: flex; flex-direction: column; gap: 4px; padding: 0 0 12px; font-family: var(--ilml-font-ui, system-ui, sans-serif); }
.ilml-pop img { width: 100%; height: 110px; object-fit: cover; margin-bottom: 6px; }
.ilml-pop strong { font-size: 16px; padding: 10px 14px 0; color: #0e2a3b; }
.ilml-pop img + strong { padding-top: 0; }
.ilml-pop__region { font-size: 13px; color: #5b7183; padding: 0 14px; }
.ilml-pop__link { padding: 6px 14px 0; font-weight: 600; color: #146dab !important; text-decoration: none; }

/* Elenco testuale per regione */
.ilml-index__region { display: flex; align-items: baseline; gap: 8px; margin: 1.6em 0 .5em; }
.ilml-index__region span { font-size: .7em; color: var(--ilml-muted, #5b7183); font-weight: 500; }
.ilml-index__list { columns: 3 220px; column-gap: 24px; list-style: none; margin: 0; padding: 0; }
.ilml-index__list li { break-inside: avoid; padding: 3px 0; }

.ilml-map .screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px; overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	white-space: nowrap;
}

/* Tinte più morbide per lo sfondo cartografico, così pin e colori del sito risaltano */
.ilml-map__canvas .leaflet-tile-pane { filter: saturate(.55) brightness(1.04) contrast(.95); }

/* Variante "riquadro": mappa a tutta larghezza con riquadro di ricerca sovrapposto */
.ilml-map--panel { position: relative; }
.ilml-map--panel .ilml-map__body { display: block; }
.ilml-map--panel .ilml-map__canvas { height: min(var(--ilml-map-h, 680px), calc(100vh - 60px)); min-height: 480px; border-radius: 0; }
.ilml-map__panel {
	position: absolute;
	z-index: 500;
	top: 32px;
	left: max(var(--gutter, 24px), calc((100% - var(--wrap, 1240px)) / 2 + var(--gutter, 24px)));
	width: 400px;
	max-height: calc(100% - 64px);
	display: flex;
	flex-direction: column;
	background: #fff;
	border-radius: 22px;
	padding: 28px 28px 22px;
	box-shadow: 0 2px 4px rgba(14, 42, 59, .06), 0 18px 50px rgba(14, 42, 59, .18);
}
.ilml-map__eyebrow { margin: 0 0 8px; font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--_blue); }
.ilml-map__title { margin: 0 0 8px; font-size: 30px; line-height: 1.1; color: var(--_ink); }
.ilml-map__text { margin: 0 0 16px; color: var(--_muted); font-size: 16px; line-height: 1.45; }
.ilml-map--panel .ilml-map__bar { flex-direction: column; align-items: stretch; margin: 6px 0 0; }
.ilml-map--panel .ilml-map__search,
.ilml-map--panel .ilml-map__select { flex: 0 0 auto; }
.ilml-map--panel .ilml-map__count { padding: 4px 4px 0; font-size: 15px; }
.ilml-map__hint { margin: 14px 0 0; padding-top: 14px; border-top: 1px solid var(--_line); font-size: 14px; line-height: 1.45; color: var(--_muted); }
.ilml-map--panel .ilml-map__list { display: none; height: auto; min-height: 0; flex: 1 1 auto; margin: 12px -10px 0; padding: 4px; background: none; }
.ilml-map--panel.is-filtered .ilml-map__list { display: block; }
.ilml-map--panel.is-filtered .ilml-map__hint { display: none; }
.ilml-map--panel .ilml-map__list a:hover,
.ilml-map--panel .ilml-map__list a:focus { background: var(--_bg); }

@media (max-width: 860px) {
	.ilml-map__panel { position: static; width: auto; max-height: none; border-radius: 0; box-shadow: none; padding: 24px var(--gutter, 16px) 16px; }
	.ilml-map__title { font-size: 26px; }
	.ilml-map--panel .ilml-map__canvas { height: 62vh; min-height: 360px; }
	.ilml-map--panel .ilml-map__list { max-height: 260px; overflow-y: auto; margin: 10px 0 0; }
}

.ilml-pop { min-width: 190px; }
