/* ── PSP Map — scoped to .psp-map-wrap ─────────────────────────────────── */
:root {
	--psp-map-teal:   #118a80;
	--psp-map-tealbg: #2FB8AC;
	--psp-map-gold:   #b3853e;
	--psp-map-goldbg: #C9A15C;
	--psp-map-ink:    #182225;
	--psp-map-muted:  #5c6d72;
	--psp-map-line:   #e3e9ea;
}

.psp-map-wrap {
	position: relative;
	font-family: 'Segoe UI', Arial, sans-serif;
	overflow: hidden;
}

/* ── Canvas ──────────────────────────────────────────────────────────────── */
.psp-map-canvas {
	width: 100%;
	min-height: 300px;
	background: #dfe8e8;
}

/* ── Topbar ──────────────────────────────────────────────────────────────── */
.psp-map-topbar {
	position: absolute;
	z-index: 1000;
	top: 14px;
	left: 14px;
	right: 14px;
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: flex-start;
	pointer-events: none;
}

.psp-map-brand-filters {
	background: #fff;
	border: 1px solid var(--psp-map-line);
	border-radius: 14px;
	box-shadow: 0 6px 24px rgba(20,40,45,.12);
	padding: 10px 12px;
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: center;
	pointer-events: auto;
}

.psp-map-search {
	border: 1px solid var(--psp-map-line);
	border-radius: 20px;
	box-shadow: 0 6px 24px rgba(20,40,45,.12);
	background: #fff;
	padding: 8px 14px;
	font-size: 12px;
	outline: none;
	min-width: 180px;
	pointer-events: auto;
}

/* ── Chips ───────────────────────────────────────────────────────────────── */
.psp-map-chip {
	border: 1.5px solid var(--psp-map-line);
	background: #fff;
	border-radius: 20px;
	padding: 6px 12px;
	font-size: 11.5px;
	font-weight: 600;
	color: var(--psp-map-muted);
	cursor: pointer;
	transition: background .15s, border-color .15s, color .15s;
}

.psp-map-chip--360.is-on  { background: var(--psp-map-tealbg); border-color: var(--psp-map-tealbg); color: #fff; }
.psp-map-chip--lux.is-on  { background: var(--psp-map-goldbg); border-color: var(--psp-map-goldbg); color: #fff; }
.psp-map-chip--view.is-on,
.psp-map-chip--list.is-on { background: var(--psp-map-ink);    border-color: var(--psp-map-ink);    color: #fff; }

/* ── Stats bar ───────────────────────────────────────────────────────────── */
.psp-map-stats {
	position: absolute;
	z-index: 1000;
	bottom: 14px;
	left: 14px;
	background: #fff;
	border: 1px solid var(--psp-map-line);
	border-radius: 12px;
	box-shadow: 0 4px 16px rgba(20,40,45,.10);
	padding: 8px 14px;
	display: flex;
	gap: 16px;
	pointer-events: none;
}

.psp-map-stat {
	font-size: 10px;
	color: var(--psp-map-muted);
	letter-spacing: .4px;
	text-transform: uppercase;
}

.psp-map-stat strong {
	display: block;
	font-size: 16px;
	color: var(--psp-map-teal);
	letter-spacing: 0;
	text-transform: none;
}

/* ── List view sidebar ───────────────────────────────────────────────────── */
.psp-map-list {
	position: absolute;
	z-index: 1001;
	top: 100px;
	bottom: 14px;
	left: 14px;
	width: 320px;
	background: #fff;
	border: 1px solid var(--psp-map-line);
	border-radius: 14px;
	box-shadow: 0 6px 24px rgba(20,40,45,.12);
	overflow-y: auto;
}

.psp-map-grp {
	padding: 10px 14px;
	border-bottom: 1px solid var(--psp-map-line);
	cursor: pointer;
}

.psp-map-grp:hover { background: #f4f8f8; }

.psp-map-grp b {
	font-size: 12.5px;
	color: var(--psp-map-ink);
	display: block;
}

.psp-map-grp span {
	font-size: 10.5px;
	color: var(--psp-map-muted);
}

/* ── Side panel ──────────────────────────────────────────────────────────── */
.psp-map-panel {
	position: absolute;
	z-index: 1001;
	top: 0;
	right: -400px;
	width: 360px;
	max-width: 90vw;
	height: 100%;
	background: #fff;
	box-shadow: -8px 0 30px rgba(20,40,45,.18);
	transition: right .25s ease;
	overflow-y: auto;
}

.psp-map-panel.is-open { right: 0; }

.psp-map-panel__head {
	position: sticky;
	top: 0;
	background: #fff;
	padding: 16px 18px 10px;
	border-bottom: 1px solid var(--psp-map-line);
}

.psp-map-panel__title {
	margin: 0 32px 0 0;
	font-size: 16px;
	color: var(--psp-map-ink);
}

.psp-map-panel__sub {
	font-size: 11px;
	color: var(--psp-map-muted);
	margin: 2px 0 0;
}

.psp-map-panel__close {
	position: absolute;
	top: 12px;
	right: 12px;
	border: none;
	background: #f0f4f4;
	border-radius: 50%;
	width: 28px;
	height: 28px;
	font-size: 14px;
	cursor: pointer;
	color: var(--psp-map-ink);
	display: flex;
	align-items: center;
	justify-content: center;
}

/* ── Property unit cards in panel ───────────────────────────────────────── */
.psp-map-unit {
	margin: 12px 14px;
	padding: 13px 14px;
	border: 1px solid var(--psp-map-line);
	border-radius: 12px;
}

.psp-map-bch {
	font-size: 8.5px;
	font-weight: 800;
	letter-spacing: 1.4px;
	padding: 3px 8px;
	border-radius: 10px;
	color: #fff;
	display: inline-block;
}

.psp-map-unit__title {
	font-size: 13px;
	color: var(--psp-map-ink);
	margin: 7px 0 3px;
	line-height: 1.3;
}

.psp-map-unit__addr {
	font-size: 10.5px;
	color: var(--psp-map-muted);
	line-height: 1.35;
	margin: 0;
}

.psp-map-unit__meta {
	font-size: 10.5px;
	color: var(--psp-map-teal);
	font-weight: 700;
	margin: 5px 0 0;
}

.psp-map-btns {
	display: flex;
	gap: 6px;
	margin-top: 9px;
	flex-wrap: wrap;
}

.psp-map-btn {
	font-size: 10.5px;
	font-weight: 700;
	text-decoration: none;
	padding: 6px 11px;
	border-radius: 8px;
	border: 1.5px solid var(--psp-map-line);
	color: var(--psp-map-ink);
	transition: background .15s;
}

.psp-map-btn--primary {
	background: var(--psp-map-tealbg);
	border-color: var(--psp-map-tealbg);
	color: #fff;
}

.psp-map-btn--enquire {
	background: var(--psp-map-teal);
	border-color: var(--psp-map-teal);
	color: #fff;
	cursor: pointer;
}

/* ── Custom Leaflet marker ───────────────────────────────────────────────── */
.psp-mk {
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	color: #fff;
	font-weight: 800;
	font-family: Arial, sans-serif;
	box-shadow: 0 3px 10px rgba(20,40,45,.35);
	border: 2.5px solid #fff;
}

/* ── Loader ──────────────────────────────────────────────────────────────── */
.psp-map-loader {
	position: absolute;
	z-index: 1002;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	background: #fff;
	border: 1px solid var(--psp-map-line);
	border-radius: 10px;
	padding: 10px 20px;
	font-size: 13px;
	color: var(--psp-map-muted);
	pointer-events: none;
}

/* ── Mobile ──────────────────────────────────────────────────────────────── */
@media (max-width: 600px) {
	.psp-map-topbar {
		top: 8px;
		left: 8px;
		right: 8px;
		gap: 6px;
	}

	.psp-map-panel {
		width: 100%;
		max-width: 100%;
		right: -100%;
	}

	.psp-map-list {
		left: 8px;
		right: 8px;
		width: auto;
	}

	.psp-map-stats {
		left: 8px;
		right: 8px;
		bottom: 8px;
		gap: 10px;
	}
}
