/* Mitat ja tyylit vastaavat sley.fi:n tapahtumakarttaa (tapahtumaupotukset, sley-events.css). */
.sley-mm-shell {
	position: relative;
	max-width: 1200px;
	margin: 0 auto 14px;
	border: 1px solid #d1d5db;
	border-radius: 8px;
	overflow: hidden;
	background: #eef2f0;
}

.sley-mm-map {
	--sley-mm-iw-max-height: 320px;
	width: 100%;
	min-height: 360px;
	background: #eef2f0;
}

@media (max-width: 480px) {
	.sley-mm-map {
		min-height: 300px;
	}
}

.sley-mm-overlay,
.sley-mm-consent {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	padding: 18px;
	background: rgba(248, 250, 252, 0.92);
	color: #1f2937;
	text-align: center;
	z-index: 2;
}

.sley-mm-overlay[hidden],
.sley-mm-consent[hidden] {
	display: none;
}

.sley-mm-consent {
	flex-direction: column;
}

.sley-mm-consent p {
	margin: 4px 0 0;
	font-size: 13px;
}

.sley-mm-consent-button {
	border: 0;
	border-radius: 6px;
	padding: 9px 14px;
	background: #0b6a55;
	color: #fff;
	font: inherit;
	font-weight: 700;
	cursor: pointer;
}

.sley-mm-spinner {
	width: 22px;
	height: 22px;
	border: 3px solid #cbd5e1;
	border-top-color: #0b6a55;
	border-radius: 50%;
	animation: sley-mm-spin 0.8s linear infinite;
}

@keyframes sley-mm-spin {
	to {
		transform: rotate(360deg);
	}
}

/* Tietoikkuna */
.sley-mm-shell .gm-style .gm-style-iw-c {
	max-height: calc(var(--sley-mm-iw-max-height, 320px) + 28px) !important;
	padding-left: 0 !important;
	padding-right: 0 !important;
}

.sley-mm-shell .gm-style .gm-style-iw-chr {
	position: absolute !important;
	top: 10px !important;
	right: 10px !important;
	width: auto !important;
	height: auto !important;
	margin: 0 !important;
	padding: 0 !important;
	z-index: 2;
}

.sley-mm-shell .gm-style .gm-style-iw-c .gm-style-iw-chr button.gm-ui-hover-effect {
	position: static !important;
	width: 22px !important;
	height: 22px !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	border-radius: 999px !important;
	background: transparent !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	opacity: 1 !important;
}

.sley-mm-shell .gm-style .gm-style-iw-c .gm-style-iw-chr button.gm-ui-hover-effect:hover {
	background: rgba(107, 114, 128, 0.14) !important;
}

.sley-mm-shell .gm-style .gm-style-iw-c .gm-style-iw-chr button.gm-ui-hover-effect span {
	display: none !important;
}

.sley-mm-shell .gm-style .gm-style-iw-c .gm-style-iw-chr button.gm-ui-hover-effect::before {
	content: '✕';
	color: #6b7280;
	font-size: 15px;
	line-height: 1;
	font-weight: 700;
}

.sley-mm-shell .gm-style .gm-style-iw-d {
	overflow: auto !important;
	margin-top: 0 !important;
	max-height: var(--sley-mm-iw-max-height, 320px) !important;
	padding-top: 0 !important;
	padding-bottom: 0 !important;
	scrollbar-width: none !important;
}

.sley-mm-shell .gm-style .gm-style-iw-d::-webkit-scrollbar {
	width: 0 !important;
	height: 0 !important;
	display: none !important;
}

.sley-mm-infowindow {
	max-width: 340px;
	overflow-wrap: break-word;
	color: #111827;
	box-sizing: border-box;
	padding: 10px;
}

@media (max-width: 480px) {
	.sley-mm-infowindow {
		max-width: 82vw;
	}
}

.sley-mm-card {
	display: flex;
	flex-direction: column;
	gap: 8px;
	font-size: 14px;
	line-height: 1.35;
}

.sley-mm-card .sley-mm-title {
	margin: 0;
	padding-right: 32px;
	font-family: inherit;
	font-size: 18px;
	font-weight: 700;
	line-height: 1.2;
	letter-spacing: normal;
	text-transform: none;
	color: #111827;
}

.sley-mm-card .sley-mm-desc {
	margin: 0;
	color: #1f2937;
	font-size: 13px;
}

.sley-mm-card .sley-mm-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 2px;
}

.sley-mm-card .sley-mm-actions a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 6px 10px;
	border-radius: 8px;
	text-decoration: none;
	font-size: 12px;
	font-weight: 700;
	background: #0b6a55;
	color: #fff;
	transition: background-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.sley-mm-card .sley-mm-actions a:hover,
.sley-mm-card .sley-mm-actions a:focus-visible {
	transform: translateY(-1px);
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.14);
	background: #095544;
}

.sley-mm-sr {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}
