/**
 * WEBPC — mapa.css
 * Style dla map (single, archive split, archive fullwidth, mini)
 */

/* ============================================================
   Custom price markers (Leaflet i Google) — pill z ceną
   ============================================================ */
.webpc-mapa-marker {
	background: var(--c-card);
	color: var(--c-text-primary);
	border: 1.5px solid var(--c-text-primary);
	border-radius: 999px;
	padding: 4px 10px;
	font-family: var(--font-sans);
	font-size: 11px;
	font-weight: 600;
	white-space: nowrap;
	box-shadow: 0 2px 6px rgba(28, 35, 48, 0.15);
	cursor: pointer;
	transition: all 0.15s;
	position: relative;
	transform: translate(-50%, -100%);
}

.webpc-mapa-marker::after {
	content: '';
	position: absolute;
	bottom: -6px;
	left: 50%;
	transform: translateX(-50%);
	border: 5px solid transparent;
	border-top-color: var(--c-text-primary);
	border-bottom: 0;
}

.webpc-mapa-marker:hover,
.webpc-mapa-marker.active {
	background: var(--c-accent);
	color: white;
	border-color: var(--c-accent);
	transform: translate(-50%, -110%);
	z-index: 1000;
}

.webpc-mapa-marker:hover::after,
.webpc-mapa-marker.active::after {
	border-top-color: var(--c-accent);
}

/* Marker dla oferty z badge "Nowość" itp. */
.webpc-mapa-marker.has-status::before {
	content: '';
	position: absolute;
	top: -4px;
	right: -4px;
	width: 8px;
	height: 8px;
	background: var(--c-status-new);
	border: 1.5px solid white;
	border-radius: 50%;
}

/* ============================================================
   Popup oferty
   ============================================================ */
.leaflet-popup-content-wrapper,
.gm-style-iw {
	border-radius: 6px !important;
	padding: 0 !important;
	box-shadow: 0 4px 16px rgba(28, 35, 48, 0.12) !important;
}

.leaflet-popup-content {
	margin: 0 !important;
	font-family: var(--font-sans) !important;
}

.webpc-popup {
	width: 240px;
	font-family: var(--font-sans);
	color: var(--c-text-primary);
}

.webpc-popup-img {
	width: 100%;
	aspect-ratio: 4 / 3;
	background-color: var(--c-cream);
	background-size: cover;
	background-position: center;
}

.webpc-popup-content {
	padding: 12px 14px;
}

.webpc-popup-loc {
	font-family: var(--font-serif);
	font-size: 16px;
	font-weight: 500;
	margin-bottom: 4px;
	line-height: 1.2;
}

.webpc-popup-meta {
	font-size: 11px;
	color: var(--c-text-tertiary);
	margin-bottom: 8px;
}

.webpc-popup-cena {
	font-family: var(--font-serif);
	font-size: 18px;
	font-weight: 500;
	color: var(--c-accent);
	margin-bottom: 8px;
}

.webpc-popup-link {
	display: inline-block;
	background: var(--c-text-primary);
	color: white;
	padding: 6px 12px;
	border-radius: 4px;
	text-decoration: none;
	font-size: 11px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	font-weight: 500;
	transition: background 0.15s;
}

.webpc-popup-link:hover {
	background: var(--c-accent);
	color: white;
}

/* ============================================================
   Klastry (Leaflet)
   ============================================================ */
.marker-cluster-small,
.marker-cluster-medium,
.marker-cluster-large {
	background: rgba(201, 122, 77, 0.4) !important;
}

.marker-cluster-small div,
.marker-cluster-medium div,
.marker-cluster-large div {
	background: var(--c-accent) !important;
	color: white !important;
	font-family: var(--font-sans) !important;
	font-weight: 600 !important;
}

/* ============================================================
   Loading / komunikat błędu
   ============================================================ */
.webpc-mapa-msg {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 100%;
	color: var(--c-text-tertiary);
	font-size: 13px;
	text-align: center;
	padding: 20px;
}

.webpc-mapa-msg svg {
	width: 32px;
	height: 32px;
	stroke: var(--c-gold);
	margin-bottom: 8px;
}
