/* ── Галерея [galerey] — сетка ─────────────── */
.pc-galerey {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 12px;
	margin: 1.5em 0;
}

@media (max-width: 768px) {
	.pc-galerey {
		grid-template-columns: repeat(2, 1fr);
		gap: 8px;
	}
}

@media (max-width: 480px) {
	.pc-galerey {
		grid-template-columns: 1fr;
	}
}

.pc-galerey__item {
	position: relative;
	display: block;
	overflow: hidden;
	border-radius: 12px;
	aspect-ratio: 4 / 3;
	background: #f1f5f9;
	cursor: pointer;
	text-decoration: none !important;
	border: 1px solid #e2e8f0;
	transition: box-shadow .25s, transform .25s;
}

.pc-galerey__item:hover {
	box-shadow: 0 8px 24px rgba(0, 0, 0, .12);
	transform: translateY(-2px);
}

.pc-galerey__item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform .35s;
}

.pc-galerey__item:hover img {
	transform: scale(1.05);
}

.pc-galerey__zoom {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(52, 120, 195, .35);
	color: #fff;
	opacity: 0;
	transition: opacity .25s;
	pointer-events: none;
}

.pc-galerey__item:hover .pc-galerey__zoom {
	opacity: 1;
}

/* ── Lightbox overlay ─────────────────────────── */
.pc-lb {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, .92);
	opacity: 0;
	visibility: hidden;
	transition: opacity .3s, visibility .3s;
	-webkit-backdrop-filter: blur(4px);
	backdrop-filter: blur(4px);
}

.pc-lb.is-open {
	opacity: 1;
	visibility: visible;
}

.pc-lb__img-wrap {
	position: relative;
	max-width: 90vw;
	max-height: 85vh;
	display: flex;
	align-items: center;
	justify-content: center;
}

.pc-lb__img {
	max-width: 90vw;
	max-height: 85vh;
	object-fit: contain;
	border-radius: 8px;
	box-shadow: 0 8px 40px rgba(0, 0, 0, .4);
	opacity: 0;
	transition: opacity .3s;
}

.pc-lb__img.is-loaded {
	opacity: 1;
}

.pc-lb__spinner {
	position: absolute;
	width: 36px;
	height: 36px;
	border: 3px solid rgba(255, 255, 255, .2);
	border-top-color: #fff;
	border-radius: 50%;
	animation: pcLbSpin .7s linear infinite;
}

@keyframes pcLbSpin {
	to { transform: rotate(360deg); }
}

/* ── Кнопки навигации ─────────────────────────── */
.pc-lb__close,
.pc-lb__prev,
.pc-lb__next {
	position: absolute;
	background: rgba(255, 255, 255, .1);
	border: 1px solid rgba(255, 255, 255, .15);
	color: #fff;
	cursor: pointer;
	border-radius: 50%;
	width: 44px;
	height: 44px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background .2s, border-color .2s;
	padding: 0;
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
}

.pc-lb__close:hover,
.pc-lb__prev:hover,
.pc-lb__next:hover {
	background: rgba(255, 255, 255, .2);
	border-color: rgba(255, 255, 255, .3);
}

.pc-lb__close {
	top: 16px;
	right: 16px;
	z-index: 3;
}

.pc-lb__prev,
.pc-lb__next {
	top: 50%;
	transform: translateY(-50%);
	z-index: 3;
}

.pc-lb__prev { left: 16px; }
.pc-lb__next { right: 16px; }

/* ── Счётчик ──────────────────────────────────── */
.pc-lb__counter {
	position: absolute;
	bottom: 16px;
	left: 50%;
	transform: translateX(-50%);
	font-size: 13px;
	color: rgba(255, 255, 255, .7);
	background: rgba(0, 0, 0, .4);
	padding: 4px 14px;
	border-radius: 20px;
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
	z-index: 3;
}
