/*
 * Photo lightbox opened from a réalisation card's "Voir les photos" button
 * or one of its thumbnails. Appended once to <body> by
 * a2s-realisations-lightbox.js, so it isn't scoped to .a2s-realisations —
 * these rules apply globally to the single shared modal instance.
 */

.a2s-realisations-lightbox-open {
	overflow: hidden;
}

.a2s-realisations-lightbox {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	font-family: var(--a2s-body-font, "Inter"), ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

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

.a2s-realisations-lightbox__backdrop {
	position: absolute;
	inset: 0;
	background-color: rgba(6, 12, 22, 0.92);
}

.a2s-realisations-lightbox__panel {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1rem;
	max-width: min(90vw, 1100px);
	max-height: 90vh;
	padding: 1rem;
}

.a2s-realisations-lightbox__figure {
	margin: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	max-height: 78vh;
}

.a2s-realisations-lightbox__image {
	display: block;
	max-width: 100%;
	max-height: 78vh;
	border-radius: 0.5rem;
	object-fit: contain;
	box-shadow: 0 12px 48px rgba(0, 0, 0, 0.5);
}

.a2s-realisations-lightbox__counter {
	margin: 0;
	color: #f5f6f8;
	font-size: 0.85rem;
	font-weight: 600;
	letter-spacing: 0.03em;
}

.a2s-realisations-lightbox__close {
	position: absolute;
	top: -0.25rem;
	right: -0.25rem;
	z-index: 2;
	width: 42px;
	height: 42px;
	border: none;
	border-radius: 999px;
	background-color: rgba(10, 22, 40, 0.75);
	color: #f5f6f8;
	font-size: 1.5rem;
	line-height: 1;
	cursor: pointer;
	transition: background-color 0.2s ease;
}

.a2s-realisations-lightbox__close:hover {
	background-color: #ff670a;
	color: #1a0f00;
}

.a2s-realisations-lightbox__nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 2;
	width: 52px;
	height: 52px;
	border: none;
	border-radius: 999px;
	background-color: rgba(10, 22, 40, 0.75);
	color: #f5f6f8;
	font-size: 2rem;
	line-height: 1;
	cursor: pointer;
	transition: background-color 0.2s ease;
}

.a2s-realisations-lightbox__nav:hover {
	background-color: #ff670a;
	color: #1a0f00;
}

.a2s-realisations-lightbox__nav[hidden] {
	display: none;
}

.a2s-realisations-lightbox__nav--prev {
	left: 0.5rem;
}

.a2s-realisations-lightbox__nav--next {
	right: 0.5rem;
}

@media (max-width: 640px) {
	.a2s-realisations-lightbox__nav {
		width: 42px;
		height: 42px;
		font-size: 1.6rem;
	}

	.a2s-realisations-lightbox__close {
		top: 0.25rem;
		right: 0.25rem;
	}
}
