/* Lesson image enlarge / lightbox */
.sjl-lesson-image-wrap {
	position: relative;
	display: block;
	max-width: 100%;
}

.sjl-lesson-image-wrap img {
	display: block;
	max-width: 100%;
	height: auto;
}

.sjl-lesson-image-enlarge {
	position: absolute;
	right: 8px;
	bottom: 8px;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 0;
	border: none;
	border-radius: 999px;
	background: rgba(0, 0, 0, 0.62);
	color: #fff;
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
	transition: background-color 0.15s ease, transform 0.15s ease;
}

.sjl-lesson-image-enlarge:hover,
.sjl-lesson-image-enlarge:focus-visible {
	background: rgba(0, 115, 170, 0.92);
	transform: scale(1.04);
	outline: 2px solid #fff;
	outline-offset: 2px;
}

.sjl-lesson-image-enlarge svg {
	width: 18px;
	height: 18px;
	fill: currentColor;
}

.sjl-image-lightbox {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}

.sjl-image-lightbox[hidden] {
	display: none !important;
}

.sjl-image-lightbox__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.82);
}

.sjl-image-lightbox__panel {
	position: relative;
	z-index: 1;
	max-width: min(96vw, 1400px);
	max-height: 92vh;
	display: flex;
	align-items: center;
	justify-content: center;
}

.sjl-image-lightbox__figure {
	margin: 0;
	max-width: 100%;
	max-height: 92vh;
}

.sjl-image-lightbox__img {
	display: block;
	max-width: 100%;
	max-height: 92vh;
	width: auto;
	height: auto;
	object-fit: contain;
	background: #111;
	border-radius: 4px;
}

.sjl-image-lightbox__close {
	position: absolute;
	top: -12px;
	right: -12px;
	z-index: 2;
	width: 40px;
	height: 40px;
	border: none;
	border-radius: 999px;
	background: #0073aa;
	color: #fff;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
}

.sjl-image-lightbox__close:hover,
.sjl-image-lightbox__close:focus-visible {
	background: #005a87;
	outline: 2px solid #fff;
	outline-offset: 2px;
}

@media (max-width: 640px) {
	.sjl-image-lightbox {
		padding: 8px;
	}

	.sjl-lesson-image-enlarge {
		width: 40px;
		height: 40px;
	}

	.sjl-image-lightbox__close {
		top: 8px;
		right: 8px;
	}
}
