/*
 * Obraz z punktami (inc/hotspots.php). Wygląd punktów i dymków jak w Image Map Pro:
 * domyślne style wtyczki plus krycie punktów zapisane w mapie "Cobot".
 */

.hotspots {
	position: relative;
}

.hotspots__image {
	display: block;
	width: 100%;
	height: auto;
}

.hotspots__spot {
	position: absolute;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background-color: rgba(0, 0, 0, 0.545);
	cursor: pointer;
	transition: background-color 0.25s cubic-bezier(0.55, 0, 0.1, 1);
}

/* main.css motywu robi z wciśniętego przycisku "position: relative; top: 1px !important".
   Punkt zostaje na miejscu dzięki position tutaj i top z !important w atrybucie style. */
.hotspots__spot:active {
	position: absolute;
}

.hotspots__spot:hover,
.hotspots__spot[aria-expanded="true"] {
	background-color: rgba(255, 255, 255, 0.4);
}

.hotspots__spot:focus-visible {
	outline: 2px solid #ff6104;
	outline-offset: 2px;
}

.hotspots__tooltip {
	--arrow-x: 50%;
	position: absolute;
	z-index: 10;
	width: 225px;
	padding: 15px;
	border-radius: 10px;
	background-color: #222;
	font-family: sans-serif;
	color: #fff;
	text-align: center;
	pointer-events: none;
}

.hotspots__tooltip[hidden] {
	display: none;
}

/* Strzałka wskazuje punkt także wtedy, gdy dymek jest przesunięty, żeby nie wychodził poza ekran. */
.hotspots__tooltip::after {
	content: "";
	position: absolute;
	top: 100%;
	left: var(--arrow-x);
	margin-left: -8px;
	border: 8px solid transparent;
	border-bottom: 0;
	border-top-color: #222;
}

.hotspots__title,
.hotspots__text {
	margin: 0;
	padding: 10px;
	font-weight: 400;
	line-height: 22px;
	color: #fff;
}

.hotspots__title {
	font-size: 18px;
	/* Image Map Pro wstawiał tytuł jako h3, który dziedziczył z motywu -1px. */
	letter-spacing: -1px;
}

.hotspots__text {
	font-size: 14px;
}

@media (prefers-reduced-motion: reduce) {
	.hotspots__spot {
		transition: none;
	}
}
