/* ARPOZ Selecta — wallpictures. Chargé uniquement pour les articles activés. */
.arpoz-photo-gallery {
	width: 100%;
	box-sizing: border-box;
	margin: 24px 0;
}

.arpoz-photo-gallery-page {
	width: 100%;
	box-sizing: border-box;
}

.arpoz-photo-gallery-page__inner {
	width: 100%;
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 20px 36px;
	box-sizing: border-box;
}

.arpoz-photo-gallery-page__title {
	margin: 0 0 22px;
}

.arpoz-photo-gallery-page__intro {
	margin-bottom: 24px;
}

.arpoz-photo-gallery__layout {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 8px;
	width: 100%;
}

.arpoz-photo-gallery__row {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	width: 100%;
}

.arpoz-photo-gallery__item {
	position: relative;
	flex: 0 0 auto;
	min-width: 0;
	margin: 0;
	overflow: hidden;
	background: #f1f1f1;
	border-radius: 3px;
}

.arpoz-photo-gallery__open {
	display: block;
	width: 100%;
	height: 100%;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	line-height: 0;
	cursor: zoom-in;
}

.arpoz-photo-gallery__open:focus-visible {
	outline: 3px solid #f08a24;
	outline-offset: -3px;
}

.arpoz-photo-gallery__item img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	margin: 0;
	object-fit: contain;
	transition: filter .18s ease;
}

.arpoz-photo-gallery__open:hover img {
	filter: brightness(.92);
}

.arpoz-photo-gallery__caption {
	position: absolute;
	right: 0;
	bottom: 0;
	left: 0;
	padding: 7px 9px;
	background: rgba(0, 0, 0, .68);
	color: #fff;
	font-size: 13px;
	line-height: 1.4;
}

.arpoz-photo-gallery__empty {
	padding: 16px;
	border: 1px dashed #aaa;
	color: #555;
}

/* Visionneuse */
.arpoz-gallery-lightbox[hidden] {
	display: none !important;
}

.arpoz-gallery-lightbox {
	position: fixed;
	z-index: 999999;
	inset: 0;
	display: grid;
	grid-template-rows: auto minmax(0, 1fr) auto;
	gap: 12px;
	padding: 16px;
	background: rgba(0, 0, 0, .96);
	color: #fff;
}

.arpoz-gallery-lightbox__top,
.arpoz-gallery-lightbox__bottom {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	min-height: 40px;
}

.arpoz-gallery-lightbox__counter,
.arpoz-gallery-lightbox__caption {
	color: #fff;
	font-size: 14px;
	line-height: 1.4;
}

.arpoz-gallery-lightbox__stage {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 0;
}

.arpoz-gallery-lightbox__image {
	display: block;
	width: auto;
	height: auto;
	max-width: calc(100vw - 120px);
	max-height: calc(100vh - 150px);
	object-fit: contain;
}

.arpoz-gallery-lightbox__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 42px;
	min-height: 42px;
	padding: 8px 12px;
	border: 1px solid rgba(255, 255, 255, .45);
	border-radius: 4px;
	background: rgba(30, 30, 30, .8);
	color: #fff;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
}

.arpoz-gallery-lightbox__button:hover,
.arpoz-gallery-lightbox__button:focus-visible {
	background: #fff;
	color: #111;
}

.arpoz-gallery-lightbox__caption {
	flex: 1;
	text-align: center;
}

body.arpoz-gallery-lightbox-open {
	overflow: hidden;
}

@media (max-width: 767px) {
	.arpoz-photo-gallery-page__inner {
		padding-right: 10px;
		padding-left: 10px;
	}

	.arpoz-photo-gallery__layout,
	.arpoz-photo-gallery__row {
		gap: 4px;
	}

	.arpoz-photo-gallery__item {
		border-radius: 2px;
	}

	.arpoz-gallery-lightbox {
		gap: 8px;
		padding: 8px;
	}

	.arpoz-gallery-lightbox__image {
		max-width: calc(100vw - 24px);
		max-height: calc(100vh - 150px);
	}

	.arpoz-gallery-lightbox__button {
		min-width: 38px;
		min-height: 38px;
		padding: 6px 9px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.arpoz-photo-gallery__item img {
		transition: none;
	}
}
