.zh-lightbox {
	position: fixed;
	left: 0; top: 0; right: 0; bottom: 0;
	z-index: 200000;
	background: rgba(0, 0, 0, .92);
	display: flex;
	flex-direction: column;
	opacity: 0;
	transition: opacity .22s ease;
}
.zh-lightbox.show { opacity: 1; }

.zh-lb-stage {
	flex: 1;
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 0;
	overflow: hidden;
	transform-origin: var(--zh-origin-x, 50%) var(--zh-origin-y, 50%);
}
.zh-lb-stage.enter { animation: zhLbIn .28s cubic-bezier(.2, .7, .3, 1); }
@keyframes zhLbIn {
	from { transform: scale(.55); opacity: .4; }
	to   { transform: scale(1);   opacity: 1; }
}
.zh-lb-view {
	position: absolute;
	left: 0; top: 0; right: 0; bottom: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	touch-action: none;
}
.zh-lb-img {
	display: block;
	width: calc(100% - 10px);
	height: calc(100% - 10px);
	object-fit: contain;
	cursor: zoom-in;
	-webkit-user-drag: none;
	user-select: none;
	transition: transform .3s ease;
}

.zh-lb-toolbar {
	position: absolute;
	top: 0; right: 0;
	z-index: 3;
	display: flex;
	gap: 6px;
	padding: 14px;
}
.zh-lb-tool {
	width: 38px; height: 38px;
	border-radius: 50%;
	background: rgba(41, 41, 41, .7);
	border: 1px solid rgba(255, 255, 255, .35);
	box-shadow: 0 1px 4px rgba(0, 0, 0, .4);
	color: #fff;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 15px;
	cursor: pointer;
	text-decoration: none;
	transition: background .2s, border-color .2s;
}
.zh-lb-tool i { color: #fff; }
.zh-lb-tool:hover { background: rgba(70, 70, 70, .7); border-color: rgba(255, 255, 255, .6); color: #fff; text-decoration: none; }
.zh-lb-tool:hover i { color: #fff; }
.zh-lb-tool.on { background: rgba(41, 41, 41, .9); border-color: #fff; box-shadow: 0 0 0 2px rgba(255, 255, 255, .25); }

.zh-lb-counter {
	position: absolute;
	left: 14px; top: 14px;
	z-index: 2;
}
.zh-lb-counter badge {
	background: rgba(0, 0, 0, .5);
	color: #fff;
	font-size: 13px;
	padding: 3px 12px;
	border-radius: 14px;
	font-weight: normal;
	letter-spacing: .5px;
}

.zh-lb-thumbs {
	position: relative;
	height: 96px;
	flex: 0 0 auto;
	background: rgba(0, 0, 0, .45);
	display: flex;
	align-items: center;
}
.zh-lb-thumbs-inner {
	display: flex;
	align-items: center;
	gap: 8px;
	overflow-x: auto;
	padding: 8px 64px;
	width: 100%;
}
.zh-lb-thumb {
	height: 80px;
	max-width: 130px;
	width: auto;
	object-fit: cover;
	border: 2px solid transparent;
	border-radius: 4px;
	opacity: .65;
	cursor: pointer;
	flex: 0 0 auto;
	transition: opacity .2s, border-color .2s;
}
.zh-lb-thumb:hover { opacity: 1; }
.zh-lb-thumb.active { border-color: #fff; opacity: 1; }
.zh-lb-thumbs-toggle {
	position: absolute;
	right: 12px; top: 50%;
	transform: translateY(-50%);
	width: 30px; height: 30px;
	border-radius: 50%;
	background: rgba(41, 41, 41, .7);
	border: 1px solid rgba(255, 255, 255, .3);
	color: #fff;
	display: flex; align-items: center; justify-content: center;
	cursor: pointer;
	z-index: 2;
	transition: background .2s, border-color .2s;
}
.zh-lb-thumbs-toggle i { color: #fff; }
.zh-lb-thumbs-toggle:hover { background: rgba(70, 70, 70, .7); border-color: rgba(255, 255, 255, .55); }
.zh-lb-thumbs-toggle:hover i { color: #fff; }
.zh-lb-thumbs.collapsed { display: none; }

body.zh-lb-open { overflow: hidden; }

@media (max-width: 767px) {
	.zh-lb-toolbar { gap: 4px; padding: 10px; }
	.zh-lb-tool { width: 34px; height: 34px; font-size: 14px; }
	.zh-lb-prev { left: 8px; }
	.zh-lb-next { right: 8px; }
	.zh-lb-thumbs { height: 76px; }
	.zh-lb-thumb { height: 62px; }
}
