/**
 * Evans Service Area Map — styles (v1.1.0)
 *
 * Two shortcodes, two components:
 *   [evans_service_map]      → .wpc-esm__map  (SVG only)
 *   [evans_service_counties] → .wpc-esm__counties (grid only)
 *
 * Heading, intro copy, and the Request Quote button are built natively
 * in Elementor — this plugin styles only the map and the county grid.
 *
 * Designed to sit inside a DARK Elementor container. The components are
 * transparent; Elementor owns section background, padding, and width.
 *
 * Brand tokens live as CSS variables on .wpc-esm and can be overridden
 * from the child theme.
 */

.wpc-esm {
	--esm-cyan: #2bb8e6;
	--esm-cyan-bright: #8fe3ff;
	--esm-text-muted: #9a9a9a;
	--esm-border: #333333;
	--esm-hover-bg: #1e1e1e;

	font-family: 'Montserrat', sans-serif;
}

/* ---------- County grid ---------- */

.wpc-esm__counties {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 6px 24px;
}

.wpc-esm__counties--cols-1 { grid-template-columns: 1fr; }
.wpc-esm__counties--cols-2 { grid-template-columns: repeat(2, 1fr); }
.wpc-esm__counties--cols-3 { grid-template-columns: repeat(3, 1fr); }
.wpc-esm__counties--cols-4 { grid-template-columns: repeat(4, 1fr); }

.wpc-esm__county {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	padding: 12px 10px;
	border: 1px solid transparent;
	cursor: default;
	transition: border-color .2s, background .2s;
}

.wpc-esm__county:hover,
.wpc-esm__county:focus-visible {
	border-color: var(--esm-border);
	background: var(--esm-hover-bg);
	outline: none;
}

.wpc-esm__check {
	flex-shrink: 0;
	width: 15px;
	height: 15px;
	margin-top: 3px;
}

.wpc-esm__check svg {
	display: block;
	width: 15px;
	height: 15px;
	stroke: var(--esm-cyan);
	fill: none;
	stroke-width: 2.5;
}

.wpc-esm__county-name {
	display: block;
	font-size: 13.5px;
	font-weight: 700;
	color: #fff;
	margin-bottom: 3px;
}

.wpc-esm__county-cities {
	display: block;
	font-size: 11.5px;
	line-height: 1.5;
	color: var(--esm-text-muted);
}

/* ---------- Map / SVG ---------- */

.wpc-esm__svg {
	width: 100%;
	height: auto;
	display: block;
}

.wpc-esm-road {
	fill: none;
	stroke: #3c3c3c;
	stroke-width: 1.4;
}

.wpc-esm-road--major {
	stroke: #555555;
	stroke-width: 2.4;
}

.wpc-esm-river {
	fill: none;
	stroke: #1d5a72;
	stroke-width: 7;
	stroke-linecap: round;
	opacity: .85;
}

.wpc-esm-radius {
	fill: none;
	stroke: #8a8a8a;
	stroke-width: 1.2;
	stroke-dasharray: 5 7;
}

.wpc-esm-radius-label {
	font-family: 'Montserrat', sans-serif;
	font-size: 15px;
	font-weight: 600;
	fill: var(--esm-cyan);
	letter-spacing: .5px;
}

.wpc-esm-shield {
	fill: #181818;
	stroke: #bdbdbd;
	stroke-width: 1.4;
}

.wpc-esm-shield-num {
	font-family: 'Montserrat', sans-serif;
	font-size: 10.5px;
	font-weight: 700;
	fill: #e8e8e8;
	text-anchor: middle;
}

.wpc-esm-pin {
	transition: opacity .25s;
}

.wpc-esm-pin .wpc-esm-marker {
	fill: var(--esm-cyan);
	transition: fill .2s;
}

.wpc-esm-pin .wpc-esm-label {
	font-family: 'Montserrat', sans-serif;
	font-size: 14.5px;
	font-weight: 500;
	fill: #e9e9e9;
	transition: fill .2s;
}

.wpc-esm-pin.is-lit .wpc-esm-marker {
	fill: var(--esm-cyan-bright);
}

.wpc-esm-pin.is-lit .wpc-esm-label {
	fill: #ffffff;
	font-weight: 600;
}

.wpc-esm-pin.is-dim {
	opacity: .22;
}

.wpc-esm-label--hub {
	font-family: 'Anton', sans-serif;
	font-size: 24px;
	font-weight: 400;
	fill: #fff;
	letter-spacing: .5px;
}

/* ---------- Motion & responsive ---------- */

@media (prefers-reduced-motion: reduce) {
	.wpc-esm-pin,
	.wpc-esm-pin .wpc-esm-marker,
	.wpc-esm-pin .wpc-esm-label,
	.wpc-esm__county {
		transition: none;
	}
}

@media (max-width: 980px) {
	.wpc-esm__counties,
	.wpc-esm__counties--cols-3,
	.wpc-esm__counties--cols-4 {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 560px) {
	.wpc-esm__counties,
	.wpc-esm__counties--cols-2,
	.wpc-esm__counties--cols-3,
	.wpc-esm__counties--cols-4 {
		grid-template-columns: 1fr;
		gap: 2px;
	}
}
