/* Carousel Slide Projector 24 – Frontend Styles */

.csp24-wrapper {
	position: relative;
	width: 100%;
	overflow: hidden;
	background-color: #080604;
	font-family: 'Helvetica Neue', Arial, sans-serif;
}

.csp24-container {
	position: relative;
	width: 100%;
	height: 580px;
	cursor: grab;
	user-select: none;
	-webkit-user-select: none;
}

.csp24-container:active {
	cursor: grabbing;
}

.csp24-container canvas {
	display: block;
	width: 100% !important;
	height: 100% !important;
	opacity: 0;
	transition: opacity 1s ease;
}

.csp24-container canvas.csp24-ready {
	opacity: 1;
}

/* Loading */
.csp24-loading {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	color: rgba(255, 248, 210, 0.4);
	font-size: 13px;
	letter-spacing: 0.15em;
	text-transform: uppercase;
	pointer-events: none;
}

.csp24-loading.csp24-hidden {
	display: none;
}

/* Navigation buttons */
.csp24-nav-btn {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 10;
	background: rgba(8, 6, 4, 0.6);
	border: 1px solid #c0392b;
	color: #c0392b;
	width: 42px;
	height: 42px;
	border-radius: 50%;
	font-size: 14px;
	cursor: pointer;
	transition: background 0.2s, transform 0.1s;
	display: flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
}

.csp24-nav-btn:hover {
	background: rgba(192, 57, 43, 0.2);
}

.csp24-nav-btn:active {
	transform: translateY(-50%) scale(0.92);
}

.csp24-nav-prev { left: 14px; }
.csp24-nav-next { right: 14px; }

/* Slide counter */
.csp24-counter {
	position: absolute;
	bottom: 48px;
	right: 16px;
	z-index: 10;
	color: #c0392b;
	font-size: 11px;
	letter-spacing: 0.12em;
	font-variant-numeric: tabular-nums;
	opacity: 0.85;
}

/* Caption bar */
.csp24-caption-bar {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	z-index: 10;
	min-height: 34px;
	padding: 8px 60px;
	background: rgba(8, 6, 4, 0.75);
	border-top: 1px solid rgba(192, 57, 43, 0.3);
	color: rgba(255, 248, 210, 0.8);
	font-size: 12px;
	letter-spacing: 0.08em;
	text-align: center;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	transition: opacity 0.3s;
}

.csp24-caption-bar:empty {
	opacity: 0;
}

.csp24-caption-date {
	opacity: 0.5;
	font-size: 11px;
}

/* Transition overlay (black flash on advance) */
.csp24-transition-overlay {
	position: absolute;
	inset: 0;
	z-index: 8;
	background: #000;
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.12s;
}

.csp24-transition-overlay.csp24-flash {
	opacity: 1;
	transition: none;
}

/* Lightbox */
.csp24-lightbox {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
}

.csp24-lightbox-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.9);
	backdrop-filter: blur(14px);
	-webkit-backdrop-filter: blur(14px);
}

.csp24-lightbox-content {
	position: relative;
	z-index: 1;
	max-width: 90vw;
	max-height: 92vh;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
}

.csp24-lightbox-media {
	max-width: 100%;
	max-height: 78vh;
	overflow: hidden;
	border: 2px solid rgba(224, 224, 204, 0.4);
	box-shadow:
		0 0 0 8px rgba(8, 6, 4, 0.8),
		0 0 80px rgba(255, 248, 210, 0.1);
}

.csp24-lightbox-media img {
	display: block;
	max-width: 100%;
	max-height: 78vh;
	object-fit: contain;
}

.csp24-lightbox-meta {
	text-align: center;
}

.csp24-lightbox-caption {
	color: rgba(255, 248, 210, 0.9);
	font-size: 14px;
	letter-spacing: 0.06em;
	margin: 0 0 4px;
}

.csp24-lightbox-date {
	color: rgba(255, 248, 210, 0.45);
	font-size: 11px;
	letter-spacing: 0.1em;
	margin: 0;
}

.csp24-lightbox-close {
	position: absolute;
	top: -44px;
	right: 0;
	background: transparent;
	border: none;
	color: rgba(255, 248, 210, 0.6);
	font-size: 36px;
	cursor: pointer;
	line-height: 1;
	padding: 0;
	transition: color 0.2s;
}

.csp24-lightbox-close:hover {
	color: #fff;
}

/* Responsive */
@media (max-width: 768px) {
	.csp24-container {
		height: 460px;
		cursor: default;
	}

	.csp24-nav-btn {
		width: 36px;
		height: 36px;
		font-size: 12px;
	}

	.csp24-caption-bar {
		padding: 6px 48px;
		font-size: 11px;
	}
}

@media (max-width: 480px) {
	.csp24-container {
		height: 360px;
	}

	.csp24-nav-prev { left: 8px; }
	.csp24-nav-next { right: 8px; }

	.csp24-lightbox-media {
		max-height: 65vh;
	}

	.csp24-lightbox-caption {
		font-size: 12px;
	}
}
