/**
 * SleekLine Lightbox — Styles
 */

/* ============================================================
   BODY SCROLL LOCK
   ============================================================ */
body.slps-lightbox-lock {
	overflow: hidden;
}

/* ============================================================
   OVERLAY
   ============================================================ */
.slps-lightbox {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	width: 100vw;
	height: 100vh;
	height: 100dvh; /* Dynamic viewport for mobile browsers */
	z-index: 999999;
	background: rgba(0, 0, 0, 0.92);
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.25s ease, visibility 0.25s ease;
	-webkit-tap-highlight-color: transparent;
}

.slps-lightbox[hidden] {
	display: none;
}

.slps-lightbox.is-open {
	opacity: 1;
	visibility: visible;
}

.slps-lightbox *,
.slps-lightbox *::before,
.slps-lightbox *::after {
	box-sizing: border-box;
}

/* ============================================================
   STAGE (image container)
   ============================================================ */
.slps-lightbox__stage {
	position: relative;
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 60px 70px;
}

@media (max-width: 768px) {
	.slps-lightbox__stage {
		padding: 50px 15px;
	}
}

/* ============================================================
   IMAGE
   ============================================================ */
.slps-lightbox__img {
	display: block;
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	opacity: 0;
	transition: opacity 0.25s ease;
	cursor: pointer;
	user-select: none;
	-webkit-user-drag: none;
}

.slps-lightbox__img.is-loaded {
	opacity: 1;
}

/* ============================================================
   LOADER SPINNER
   ============================================================ */
.slps-lightbox__loader {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 40px;
	height: 40px;
	border: 3px solid rgba(255, 255, 255, 0.15);
	border-top-color: rgba(255, 255, 255, 0.85);
	border-radius: 50%;
	opacity: 0;
	pointer-events: none;
	animation: slps-spin 0.8s linear infinite;
	transition: opacity 0.2s ease;
}

.slps-lightbox__loader.is-visible {
	opacity: 1;
}

@keyframes slps-spin {
	to {
		transform: translate(-50%, -50%) rotate(360deg);
	}
}

/* ============================================================
   CLOSE BUTTON
   ============================================================ */
.slps-lightbox__close {
	position: absolute;
	top: 15px;
	right: 15px;
	z-index: 10;
	width: 44px;
	height: 44px;
	padding: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
	border: none;
	border-radius: 50%;
	cursor: pointer;
	transition: background 0.2s ease, transform 0.2s ease;
	-webkit-appearance: none;
	appearance: none;
}

.slps-lightbox__close:hover,
.slps-lightbox__close:focus-visible {
	background: rgba(255, 255, 255, 0.2);
	transform: scale(1.05);
	outline: none;
}

.slps-lightbox__close svg {
	width: 22px;
	height: 22px;
}

/* ============================================================
   NAVIGATION BUTTONS
   ============================================================ */
.slps-lightbox__nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 10;
	width: 50px;
	height: 50px;
	padding: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
	border: none;
	border-radius: 50%;
	cursor: pointer;
	transition: background 0.2s ease, transform 0.2s ease;
	-webkit-appearance: none;
	appearance: none;
}

.slps-lightbox__nav:hover,
.slps-lightbox__nav:focus-visible {
	background: rgba(255, 255, 255, 0.2);
	outline: none;
}

.slps-lightbox__nav--prev {
	left: 15px;
}

.slps-lightbox__nav--next {
	right: 15px;
}

.slps-lightbox__nav svg {
	width: 28px;
	height: 28px;
}

@media (max-width: 768px) {
	.slps-lightbox__nav {
		width: 42px;
		height: 42px;
	}
	.slps-lightbox__nav svg {
		width: 22px;
		height: 22px;
	}
	.slps-lightbox__nav--prev {
		left: 5px;
	}
	.slps-lightbox__nav--next {
		right: 5px;
	}
}

/* ============================================================
   COUNTER (1 / 5)
   ============================================================ */
.slps-lightbox__counter {
	position: absolute;
	bottom: 20px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 10;
	color: rgba(255, 255, 255, 0.85);
	font-size: 14px;
	font-family: system-ui, -apple-system, sans-serif;
	font-variant-numeric: tabular-nums;
	background: rgba(0, 0, 0, 0.4);
	padding: 6px 14px;
	border-radius: 20px;
	pointer-events: none;
}

@media (max-width: 768px) {
	.slps-lightbox__counter {
		bottom: 12px;
		font-size: 13px;
	}
}
