.news-gallery {
	margin: 32px 0;
}

.news-gallery__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px;
}

.news-gallery__item {
	min-width: 0;
	margin: 0;
}

.news-gallery__button {
	width: 100%;
	padding: 0;
	overflow: hidden;
	display: block;
	border: 0;
	border-radius: var(--news-radius-md);
	background: var(--news-color-soft);
	cursor: zoom-in;
	aspect-ratio: 4 / 3;
}

.news-gallery__button:focus-visible {
	outline: 3px solid var(--news-color-primary);
	outline-offset: 3px;
}

.news-gallery__image {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 240ms ease;
}

.news-gallery__button:hover .news-gallery__image,
.news-gallery__button:focus-visible .news-gallery__image {
	transform: scale(1.025);
}

.news-gallery__caption {
	margin: 8px 2px 0;
	color: var(--news-color-muted);
	font-size: 13px;
	line-height: 1.45;
}

.news-lightbox {
	width: min(1180px, calc(100% - 28px));
	max-width: none;
	height: min(900px, calc(100% - 28px));
	max-height: none;
	padding: 54px 70px 58px;
	overflow: hidden;
	border: 0;
	border-radius: 18px;
	background: #080b12;
	color: #ffffff;
	box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
}

.news-lightbox::backdrop {
	background: rgba(2, 6, 23, 0.88);
	backdrop-filter: blur(4px);
}

.news-lightbox__media {
	width: 100%;
	height: 100%;
	display: grid;
	place-items: center;
}

.news-lightbox__image {
	display: block;
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
}

.news-lightbox__close,
.news-lightbox__nav {
	position: absolute;
	z-index: 2;
	display: grid;
	place-items: center;
	border: 0;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.12);
	color: #ffffff;
	cursor: pointer;
}

.news-lightbox__close:hover,
.news-lightbox__close:focus-visible,
.news-lightbox__nav:hover,
.news-lightbox__nav:focus-visible {
	background: rgba(255, 255, 255, 0.24);
	outline: 2px solid #ffffff;
}

.news-lightbox__close {
	top: 12px;
	right: 12px;
	width: 40px;
	height: 40px;
	font-size: 28px;
	line-height: 1;
}

.news-lightbox__nav {
	top: 50%;
	width: 46px;
	height: 46px;
	font-size: 34px;
	transform: translateY(-50%);
}

.news-lightbox__nav--previous {
	left: 12px;
}

.news-lightbox__nav--next {
	right: 12px;
}

.news-lightbox__caption,
.news-lightbox__counter {
	position: absolute;
	bottom: 16px;
	margin: 0;
	font-size: 13px;
}

.news-lightbox__caption {
	left: 70px;
	right: 130px;
	color: rgba(255, 255, 255, 0.86);
}

.news-lightbox__counter {
	right: 70px;
	font-weight: 800;
}

@media (max-width: 640px) {
	.news-gallery__grid {
		grid-template-columns: 1fr;
	}

	.news-lightbox {
		width: 100%;
		height: 100%;
		padding: 54px 12px 70px;
		border-radius: 0;
	}

	.news-lightbox__nav {
		top: auto;
		bottom: 12px;
		transform: none;
	}

	.news-lightbox__caption {
		left: 66px;
		right: 66px;
		bottom: 22px;
		text-align: center;
	}

	.news-lightbox__counter {
		display: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	.news-gallery__image {
		transition: none;
	}
}
