/* Hide the legacy text-block sources (helab-popup-1..N and wrapper section). */
[class^="helab-popup-"]:not(.helab-popup-card):not(.helab-popup-card-trigger),
[class*=" helab-popup-"]:not(.helab-popup-card):not(.helab-popup-card-trigger) {
	display: none !important;
}

/* Popup Card element: the trigger is visible, the content stays hidden. */
.helab-popup-card {
	display: inline-block;
}

.helab-popup-card-trigger {
	display: inline-block;
	cursor: pointer;
}

.helab-popup-card-trigger img {
	display: block;
	max-width: 100%;
	height: auto;
	transition: transform 0.2s ease;
}

.helab-popup-card-trigger:hover img,
.helab-popup-card-trigger:focus img {
	transform: scale(1.05);
}

.helab-popup-card-content {
	display: none !important;
}

.section-popup {
	position: absolute;
	top: 0;
	left: 0;
	z-index: 9999;
	width: 360px;
	max-width: calc(100vw - 24px);
	background: #fff;
	color: #333;
	border-radius: 6px;
	box-shadow: 0 12px 32px rgba(0, 0, 0, 0.22), 0 2px 6px rgba(0, 0, 0, 0.08);
	opacity: 1;
	transform: translateY(0);
	transition: opacity 0.14s ease, transform 0.14s ease;
}

.section-popup.is-hidden {
	opacity: 0;
	pointer-events: none;
	visibility: hidden;
	transform: translateY(-6px);
}

.section-popup__arrow {
	position: absolute;
	top: -8px;
	left: 24px;
	width: 16px;
	height: 16px;
	background: #fff;
	transform: translateX(-50%) rotate(45deg);
	box-shadow: -2px -2px 4px rgba(0, 0, 0, 0.05);
	pointer-events: none;
}

.section-popup__dialog {
	position: relative;
	max-height: 70vh;
	overflow-y: auto;
	padding: 22px 20px 20px;
	border-radius: 6px;
	outline: none;
}

.section-popup__close {
	position: absolute;
	top: 4px;
	right: 6px;
	background: transparent;
	border: 0;
	font-size: 26px;
	line-height: 1;
	color: #777;
	cursor: pointer;
	padding: 4px 8px;
	border-radius: 4px;
}

.section-popup__close:hover,
.section-popup__close:focus {
	color: #000;
	background: rgba(0, 0, 0, 0.06);
	outline: none;
}

.section-popup__title {
	margin: 0 28px 10px 0;
	font-size: 20px;
	line-height: 1.25;
	color: #004f83;
}

.section-popup__body {
	font-size: 15px;
	line-height: 1.55;
}

.section-popup__body p {
	margin: 0 0 10px;
}

.section-popup__body p:last-child {
	margin-bottom: 0;
}

.section-popup__body img {
	max-width: 100%;
	height: auto;
}

.section-popup__body img.alignleft {
	float: left;
	margin: 0 12px 8px 0;
	max-width: 45%;
}

.section-popup__body a {
	color: #004f83;
	text-decoration: underline;
}

.section-popup__loading {
	margin: 0;
	color: #666;
	font-style: italic;
}

@media (max-width: 480px) {
	.section-popup__title {
		font-size: 18px;
	}

	.section-popup__body img.alignleft {
		float: none;
		display: block;
		margin: 0 0 10px;
		max-width: 100%;
	}
}
