/* News Detail Gallery (Google News 16:9 Standard) */
.news-gallery {
	margin: 16px 0 24px;
	border: 1px solid var(--news-detail-border, #e5e7eb);
	border-radius: 8px;
	overflow: hidden;
	background: #111315;
}

.news-gallery .gallery-stage {
	position: relative;
	aspect-ratio: 16 / 9;
	background: #0b0c0e;
	display: flex;
	align-items: center;
	justify-content: center;
}

.news-gallery .gallery-figure {
	width: 100%;
	height: 100%;
	margin: 0;
	position: relative;
}

.news-gallery .gallery-main-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	cursor: zoom-in;
	transition: opacity 0.2s ease;
}

.news-gallery .gallery-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 2;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	border: none;
	background: rgba(0, 0, 0, 0.55);
	color: #ffffff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: background 0.2s ease;
}

.news-gallery .gallery-nav:hover {
	background: rgba(0, 0, 0, 0.85);
}

.news-gallery .gallery-prev {
	left: 12px;
}

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

.news-gallery .gallery-zoom-btn {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 2;
	width: 36px;
	height: 36px;
	border-radius: 4px;
	border: none;
	background: rgba(0, 0, 0, 0.55);
	color: #ffffff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}

.news-gallery .gallery-zoom-btn:hover {
	background: rgba(0, 0, 0, 0.85);
}

.news-gallery .gallery-counter {
	position: absolute;
	bottom: 12px;
	right: 12px;
	background: rgba(0, 0, 0, 0.65);
	color: #ffffff;
	font-size: 12px;
	font-weight: 600;
	padding: 4px 10px;
	border-radius: 999px;
}

.news-gallery .gallery-caption-bar {
	background: #181a1d;
	color: #e5e7eb;
	padding: 12px 16px;
	font-size: 14px;
	border-top: 1px solid #2a2e33;
}

.news-gallery .gallery-caption-text {
	margin: 0;
}

.news-gallery .gallery-thumbs {
	display: flex;
	gap: 8px;
	padding: 10px 12px;
	background: #111315;
	overflow-x: auto;
	scrollbar-width: thin;
}

.news-gallery .thumb-item {
	flex: 0 0 96px;
	height: 54px;
	border: 2px solid transparent;
	border-radius: 4px;
	overflow: hidden;
	cursor: pointer;
	opacity: 0.55;
	background: none;
	padding: 0;
	transition: opacity 0.2s ease, border-color 0.2s ease;
}

.news-gallery .thumb-item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.news-gallery .thumb-item:hover {
	opacity: 0.85;
}

.news-gallery .thumb-item.is-active {
	opacity: 1;
	border-color: #b91c1c;
}

/* News Gallery Lightbox */
.news-gallery-lightbox {
	position: fixed;
	inset: 0;
	z-index: 1060;
	background: rgba(0, 0, 0, 0.92);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px;
}

.news-gallery-lightbox[hidden] {
	display: none;
}

.news-gallery-lightbox .lightbox-content {
	max-width: 90vw;
	max-height: 85vh;
	text-align: center;
}

.news-gallery-lightbox .lightbox-content img {
	max-width: 100%;
	max-height: 75vh;
	object-fit: contain;
	border-radius: 4px;
}

.news-gallery-lightbox .lightbox-caption {
	color: #e5e7eb;
	font-size: 14px;
	margin-top: 12px;
}

.news-gallery-lightbox .lightbox-close {
	position: absolute;
	top: 16px;
	right: 24px;
	background: none;
	border: none;
	color: #ffffff;
	font-size: 36px;
	line-height: 1;
	cursor: pointer;
}

.news-gallery-lightbox .lightbox-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	background: rgba(255, 255, 255, 0.12);
	border: none;
	color: #ffffff;
	font-size: 24px;
	width: 48px;
	height: 48px;
	border-radius: 50%;
	cursor: pointer;
}

.news-gallery-lightbox .lightbox-prev {
	left: 20px;
}

.news-gallery-lightbox .lightbox-next {
	right: 20px;
}

@media (max-width: 640px) {
	.news-gallery .gallery-nav {
		width: 34px;
		height: 34px;
	}

	.news-gallery .thumb-item {
		flex: 0 0 80px;
		height: 45px;
	}
}
