/* Enhanced Map Styles for Guachincheando */

/* Google Maps optimizations */
.gm-style {
	font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
}

.gm-style .gm-style-iw-c {
	border-radius: 8px;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.gm-style .gm-style-iw-d {
	overflow: hidden !important;
}

/* Leaflet Maps optimizations */
.leaflet-container {
	font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	border-radius: 8px;
	overflow: hidden;
}

.leaflet-popup-content-wrapper {
	border-radius: 8px;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.leaflet-popup-content {
	margin: 0;
	padding: 0;
	overflow: hidden;
	border-radius: 8px;
}

.custom-popup .leaflet-popup-content {
	width: 300px !important;
}

.custom-popup .leaflet-popup-tip {
	background: white;
}

/* Map container improvements */
#mapa,
#mapCanvasTwo {
	height: 400px;
	width: 100%;
	border-radius: 0px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
	overflow: hidden;
}

@media (max-width: 768px) {
	#mapa,
	#mapCanvasTwo {
		height: 300px;
	}
}

/* Loading state for maps */
.map-loading {
	display: flex;
	align-items: center;
	justify-content: center;
	background: #f8f9fa;
	color: #6c757d;
	font-size: 14px;
}

.map-loading::before {
	content: "";
	width: 20px;
	height: 20px;
	border: 2px solid #dee2e6;
	border-top-color: #007bff;
	border-radius: 50%;
	animation: spin 1s linear infinite;
	margin-right: 8px;
}

@keyframes spin {
	to {
		transform: rotate(360deg);
	}
}

/* Enhanced marker clustering styles for Leaflet */
.marker-cluster-small {
	background-color: rgba(181, 226, 140, 0.8);
	border: 2px solid rgba(110, 204, 57, 0.8);
}

.marker-cluster-small div {
	background-color: rgba(110, 204, 57, 0.8);
	border-radius: 50%;
}

.marker-cluster-medium {
	background-color: rgba(241, 211, 87, 0.8);
	border: 2px solid rgba(240, 194, 12, 0.8);
}

.marker-cluster-medium div {
	background-color: rgba(240, 194, 12, 0.8);
	border-radius: 50%;
}

.marker-cluster-large {
	background-color: rgba(253, 156, 115, 0.8);
	border: 2px solid rgba(241, 128, 23, 0.8);
}

.marker-cluster-large div {
	background-color: rgba(241, 128, 23, 0.8);
	border-radius: 50%;
}

/* Performance improvements */
.leaflet-fade-anim .leaflet-tile,
.leaflet-fade-anim .leaflet-popup {
	transition: opacity 0.2s linear;
}

/* Accessibility improvements */
.leaflet-control-zoom a {
	color: #333;
	font-weight: bold;
}

.leaflet-control-zoom a:hover {
	background-color: #f4f4f4;
}

/* Custom popup styles */
.leaflet-popup-content .position-relative {
	background: linear-gradient(45deg, rgba(0, 0, 0, 0.6) 0%, transparent 100%);
}

.leaflet-popup-content .text-white {
	text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.7);
}

/* Responsive map controls */
@media (max-width: 480px) {
	.leaflet-control-zoom {
		transform: scale(0.9);
	}

	.leaflet-popup-content-wrapper {
		max-width: 250px;
	}
}

/* Map fullscreen mode */
.map-fullscreen {
	position: fixed !important;
	top: 0 !important;
	left: 0 !important;
	width: 100vw !important;
	height: 100vh !important;
	z-index: 9999 !important;
	border-radius: 0 !important;
}

.map-fullscreen-toggle {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 1000;
	background: white;
	border: 1px solid #ccc;
	border-radius: 4px;
	padding: 5px;
	cursor: pointer;
	box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.map-fullscreen-toggle:hover {
	background: #f0f0f0;
}
