/*
 * 图片灯箱样式（配合 assets/lightbox.js 使用）。
 * 仅在需要「点击放大」的页面加载（当前为「文档页（无侧栏）」模板）。
 */

.cnbcmc-lb {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 99999;
	display: none;
	font-family: "Microsoft YaHei", "Hiragino Sans", "Yu Gothic", Arial, sans-serif;
}

.cnbcmc-lb.is-open {
	display: block;
}

.cnbcmc-lb-backdrop {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(12, 16, 22, .9);
	cursor: zoom-out;
}

/* 顶部工具条 */
.cnbcmc-lb-bar {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 54px;
	padding: 0 18px;
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: space-between;
	background: linear-gradient(to bottom, rgba(0, 0, 0, .55), rgba(0, 0, 0, 0));
	color: #fff;
	z-index: 2;
}

.cnbcmc-lb-hint {
	font-size: 13px;
	color: rgba(255, 255, 255, .72);
	letter-spacing: .5px;
}

.cnbcmc-lb-counter {
	font-size: 14px;
	color: #fff;
	letter-spacing: 1px;
}

.cnbcmc-lb-close {
	width: 38px;
	height: 38px;
	margin-left: 16px;
	padding: 0;
	border: 1px solid rgba(255, 255, 255, .35);
	border-radius: 4px;
	background: rgba(255, 255, 255, .08);
	color: #fff;
	font-size: 17px;
	line-height: 1;
	cursor: pointer;
	transition: background .2s, border-color .2s;
}

.cnbcmc-lb-close:hover {
	background: rgba(255, 255, 255, .2);
	border-color: rgba(255, 255, 255, .6);
}

/* 左右切换 */
.cnbcmc-lb-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 46px;
	height: 66px;
	padding: 0;
	border: none;
	border-radius: 4px;
	background: rgba(255, 255, 255, .1);
	color: #fff;
	font-size: 20px;
	line-height: 1;
	cursor: pointer;
	z-index: 2;
	transition: background .2s, opacity .2s;
}

.cnbcmc-lb-nav:hover {
	background: rgba(255, 255, 255, .24);
}

.cnbcmc-lb-prev {
	left: 16px;
}

.cnbcmc-lb-next {
	right: 16px;
}

.cnbcmc-lb-nav[disabled] {
	opacity: 0;
	pointer-events: none;
}

/* 图片舞台 */
.cnbcmc-lb-stage {
	position: absolute;
	top: 54px;
	left: 74px;
	right: 74px;
	bottom: 74px;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	z-index: 1;
}

.cnbcmc-lb-img {
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	background: #fff;
	border-radius: 3px;
	box-shadow: 0 12px 44px rgba(0, 0, 0, .5);
	cursor: zoom-in;
	-webkit-user-select: none;
	user-select: none;
}

/* 原寸表示模式：允许滚动查看 */
.cnbcmc-lb.is-actual .cnbcmc-lb-stage {
	overflow: auto;
	align-items: flex-start;
	justify-content: flex-start;
}

.cnbcmc-lb.is-actual .cnbcmc-lb-img {
	max-width: none;
	max-height: none;
	cursor: zoom-out;
}

.cnbcmc-lb.is-loading .cnbcmc-lb-img {
	opacity: .35;
}

/* 图注 */
.cnbcmc-lb-caption {
	position: absolute;
	left: 74px;
	right: 74px;
	bottom: 0;
	height: 74px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0 12px;
	box-sizing: border-box;
	color: rgba(255, 255, 255, .82);
	font-size: 13px;
	line-height: 1.6;
	text-align: center;
	z-index: 2;
}

.cnbcmc-lb-caption:empty {
	display: none;
}

/* 页面滚动锁 */
body.cnbcmc-lb-locked {
	overflow: hidden;
}

/* 窄屏 */
@media screen and (max-width: 860px) {
	.cnbcmc-lb-hint {
		display: none;
	}

	.cnbcmc-lb-stage {
		top: 48px;
		left: 10px;
		right: 10px;
		bottom: 62px;
	}

	.cnbcmc-lb-nav {
		width: 38px;
		height: 56px;
	}

	.cnbcmc-lb-prev {
		left: 4px;
	}

	.cnbcmc-lb-next {
		right: 4px;
	}

	.cnbcmc-lb-caption {
		left: 12px;
		right: 12px;
		height: 58px;
		font-size: 12px;
	}
}
