.gpm-body-map {
	--gpm-active: #28b19e;
	--gpm-hover: #28b19e;
	--gpm-text: #1b2926;
	--gpm-surface: transparent;
	--gpm-switch-bg: #eef5f3;
	--gpm-switch-active-bg: #0c5873;
	--gpm-switch-text: #1b2926;
	--gpm-switch-active-text: #ffffff;
	--gpm-offers-bg: #ffffff;
	--gpm-offers-text: #173b47;
	--gpm-offers-accent: #0c5873;
	--gpm-offers-hover-bg: #eef8f5;
	width: 100%;
	color: var(--gpm-text);
}

.gpm-body-map__stage {
	position: relative;
	width: 100%;
	margin: 0 auto;
	padding: 0;
	background: var(--gpm-surface);
}

.gpm-body-map__view[hidden] {
	display: none !important;
}

.gpm-body-map__figure {
	position: relative;
	width: 100%;
	aspect-ratio: 2 / 3;
}

.gpm-body-map__image,
.gpm-body-map__overlay {
	position: absolute;
	inset: 0;
	display: block;
	width: 100%;
	height: 100%;
}

.gpm-body-map__image {
	object-fit: contain;
	pointer-events: none;
	user-select: none;
}

.gpm-body-map__overlay {
	overflow: visible;
}

/*
 * Oba pliki źródłowe mają płótno 1024 × 1536, ale sylwetka z tyłu
 * zajmuje w nim większy obszar. Skalujemy obraz i odpowiadającą mu
 * warstwę SVG tym samym przekształceniem, aby po przełączeniu widoku
 * głowa i stopy pozostały na tej samej wysokości, a hotspoty nie zmieniły
 * położenia względem sylwetki.
 */
.gpm-body-map__view[data-view-panel="back"] .gpm-body-map__image,
.gpm-body-map__view[data-view-panel="back"] .gpm-body-map__overlay {
	transform-origin: 0 0;
	transform: translate(3.29%, 2.09%) scale(.921);
}

.gpm-body-map__region {
	pointer-events: none;
}

.gpm-body-map__region > * {
	fill: transparent;
	fill-opacity: 0;
	stroke: none;
	transition: fill .16s ease, fill-opacity .16s ease, filter .16s ease;
}

.gpm-body-map__region.is-active {
	pointer-events: all;
	cursor: pointer;
}

.gpm-body-map__region.is-active > * {
	fill: var(--gpm-active);
	fill-opacity: .16;
}

.gpm-body-map__link:hover .gpm-body-map__region.is-active > *,
.gpm-body-map__link:focus-visible .gpm-body-map__region.is-active > *,
.gpm-body-map__region.is-active.has-multiple:hover > *,
.gpm-body-map__region.is-active.has-multiple:focus-visible > *,
.gpm-body-map__region.is-active.has-multiple[aria-expanded="true"] > * {
	fill: var(--gpm-hover);
	fill-opacity: .38;
	filter: drop-shadow(0 0 7px color-mix(in srgb, var(--gpm-hover) 32%, transparent));
}


.gpm-body-map__offers-popover[hidden],
.gpm-body-map__offers-backdrop[hidden] {
	display: none !important;
}

.gpm-body-map__offers-popover {
	position: absolute;
	z-index: 20;
	width: 300px;
	max-width: calc(100% - 16px);
	padding: 22px;
	border: 1px solid rgba(13, 79, 105, .10);
	border-radius: 18px;
	background: var(--gpm-offers-bg);
	color: var(--gpm-offers-text);
	box-shadow: 0 18px 50px rgba(20, 55, 66, .18);
}

.gpm-body-map__offers-kicker {
	margin: 0 32px 4px 0;
	color: var(--gpm-offers-accent);
	font-size: 12px;
	font-weight: 800;
	line-height: 1.2;
	letter-spacing: .06em;
	text-transform: uppercase;
}

.gpm-body-map__offers-title {
	margin: 0 34px 14px 0;
	font-size: 19px;
	font-weight: 800;
	line-height: 1.25;
}

.gpm-body-map__offers-close {
	position: absolute;
	top: 10px;
	right: 10px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--gpm-offers-text);
	font: inherit;
	font-size: 25px;
	font-weight: 400;
	line-height: 1;
	cursor: pointer;
}

.gpm-body-map__offers-close:hover,
.gpm-body-map__offers-close:focus-visible {
	background: var(--gpm-offers-hover-bg);
	outline: none;
}

.gpm-body-map__offers-list {
	display: grid;
	gap: 7px;
}

.gpm-body-map__offer-link {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	width: 100%;
	padding: 11px 13px;
	border-radius: 10px;
	background: transparent;
	color: var(--gpm-offers-accent);
	font-size: 15px;
	font-weight: 700;
	line-height: 1.35;
	text-decoration: none;
	transition: background .15s ease, transform .15s ease;
}

.gpm-body-map__offer-link:hover,
.gpm-body-map__offer-link:focus-visible {
	background: var(--gpm-offers-hover-bg);
	color: var(--gpm-offers-accent);
	text-decoration: none;
	outline: none;
	transform: translateX(2px);
}

.gpm-body-map__offer-arrow {
	flex: 0 0 auto;
	font-size: 18px;
	font-weight: 500;
}

.gpm-body-map__offers-backdrop {
	display: none;
}

.gpm-body-map__switcher {
	margin: 16px auto 0;
	padding: 0;
	border: 0;
	text-align: center;
}

.gpm-body-map__switcher-track {
	position: relative;
	display: inline-grid;
	grid-template-columns: repeat(2, minmax(112px, 1fr));
	gap: 4px;
	padding: 4px;
	border-radius: 999px;
	background: var(--gpm-switch-bg);
}

.gpm-body-map__switcher-track::before {
	content: "";
	position: absolute;
	top: 4px;
	left: 4px;
	width: calc(50% - 2px);
	height: calc(100% - 8px);
	border-radius: 999px;
	background: var(--gpm-switch-active-bg);
	transition: transform .2s ease;
}

.gpm-body-map__switcher-track[data-active-view="back"]::before {
	transform: translateX(100%);
}

.gpm-body-map__switch-input {
	position: absolute;
	opacity: 0;
	pointer-events: none;
}

.gpm-body-map__switch {
	position: relative;
	z-index: 1;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 112px;
	padding: 12px 28px;
	border: 0;
	border-radius: 999px;
	background: transparent;
	color: var(--gpm-switch-text);
	font: inherit;
	font-weight: 800;
	line-height: 1;
	cursor: pointer;
	user-select: none;
	transition: color .2s ease, opacity .2s ease;
}

.gpm-body-map__switcher-track[data-active-view="front"] .gpm-body-map__switch[data-view="front"],
.gpm-body-map__switcher-track[data-active-view="back"] .gpm-body-map__switch[data-view="back"] {
	color: var(--gpm-switch-active-text);
}

.gpm-body-map__switch:hover {
	opacity: .92;
}

.gpm-body-map__switch:focus,
.gpm-body-map__switch:focus-visible,
.gpm-body-map__switch-input:focus + .gpm-body-map__switch,
.gpm-body-map__switch-input:focus-visible + .gpm-body-map__switch,
.gpm-body-map__link:focus,
.gpm-body-map__link:focus-visible,
.gpm-body-map__region.has-multiple:focus,
.gpm-body-map__region.has-multiple:focus-visible,
.gpm-body-map__legend-link:focus,
.gpm-body-map__legend-link:focus-visible {
	outline: none;
	box-shadow: none;
}

.gpm-body-map__tooltip {
	position: absolute;
	z-index: 5;
	top: 0;
	left: 0;
	max-width: 240px;
	padding: 9px 12px;
	border-radius: 10px;
	background: #153d49;
	color: #fff;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.3;
	white-space: nowrap;
	pointer-events: none;
	opacity: 0;
	transform: translate(-50%, calc(-100% - 12px)) scale(.96);
	transition: opacity .12s ease, transform .12s ease;
}

.gpm-body-map__tooltip::after {
	content: "";
	position: absolute;
	top: 100%;
	left: 50%;
	width: 9px;
	height: 9px;
	background: #153d49;
	transform: translate(-50%, -50%) rotate(45deg);
}

.gpm-body-map__tooltip.is-visible {
	opacity: 1;
	transform: translate(-50%, calc(-100% - 12px)) scale(1);
}

.gpm-body-map__legend {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 10px 18px;
	margin-top: 24px;
}

.gpm-body-map__legend-link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--gpm-text);
	font-size: 15px;
	font-weight: 500;
	line-height: 1.3;
	text-decoration: none;
}

.gpm-body-map__legend-link span {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: var(--gpm-active);
	flex: 0 0 7px;
}

@media (max-width: 767px) {
	.gpm-body-map__offers-backdrop {
		position: fixed;
		z-index: 99998;
		inset: 0;
		display: block;
		background: rgba(10, 30, 36, .34);
		backdrop-filter: blur(2px);
	}

	.gpm-body-map__offers-popover {
		position: fixed;
		z-index: 99999;
		left: 12px !important;
		right: 12px;
		bottom: 12px;
		top: auto !important;
		width: auto !important;
		max-width: none;
		padding: 22px 18px 18px;
		border-radius: 20px;
		box-shadow: 0 20px 60px rgba(10, 30, 36, .28);
	}

	.gpm-body-map__offers-title {
		font-size: 20px;
	}

	.gpm-body-map__offer-link {
		padding: 13px 12px;
	}
}

@media (max-width: 520px) {
	.gpm-body-map__switcher-track {
		grid-template-columns: repeat(2, minmax(96px, 1fr));
	}

	.gpm-body-map__switch {
		min-width: 96px;
		padding: 11px 20px;
	}

	.gpm-body-map__tooltip {
		max-width: 190px;
		white-space: normal;
	}
}
