/* Scroll Zoom Widget — frontend styles */

.szw-wrapper {
	position: relative;
	width: 100%;
	/* Total scrollable height: 1 viewport (during which the box is pinned)
	   + the extra distance the user has to scroll to complete the zoom. */
	height: calc(100vh + var(--szw-scroll-distance, 100vh));
}

.szw-sticky {
	position: -webkit-sticky;
	position: sticky;
	top: 0;
	height: 100vh;
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.szw-media-box {
	position: relative;
	overflow: hidden;
	width: var(--szw-initial-width, 50%);
	height: var(--szw-initial-height, 50vh);
	border-radius: var(--szw-initial-radius, 24px);
	will-change: width, height, border-radius;
	flex-shrink: 0;
}

.szw-wrapper.szw-full-bleed .szw-media-box {
	max-width: 100vw;
}

.szw-media {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
}

.szw-media__el {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* Overlay content */

.szw-overlay__scrim {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.35);
	pointer-events: none;
}

.szw-overlay {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
	gap: 16px;
	padding: 32px;
	box-sizing: border-box;
	transition: opacity 0.05s linear;
}

.szw-overlay--top {
	justify-content: flex-start;
	padding-top: 8%;
}

.szw-overlay--bottom {
	justify-content: flex-end;
	padding-bottom: 8%;
}

.szw-overlay__image {
	max-width: 160px;
	max-height: 160px;
	object-fit: contain;
}

.szw-overlay__heading {
	color: #fff;
	font-size: clamp(22px, 4vw, 44px);
	font-weight: 700;
	margin: 0;
	max-width: 800px;
}

.szw-overlay__description {
	color: #f2f2f2;
	font-size: clamp(14px, 1.6vw, 18px);
	margin: 0;
	max-width: 600px;
}

.szw-overlay__button {
	display: inline-block;
	padding: 12px 28px;
	background: #fff;
	color: #111;
	border-radius: 999px;
	text-decoration: none;
	font-weight: 600;
	transition: transform 0.2s ease;
}

.szw-overlay__button:hover {
	transform: translateY(-2px);
	color: #111;
}

@media (max-width: 767px) {
	.szw-overlay {
		padding: 20px;
		gap: 10px;
	}
}
