/*
	项目自定义样式（Forty 模板增量调整）
	- 实习 / 项目行加高：图片按封面填充整个图片框，便于后续替换真实照片
*/

.spotlights > section {
	min-height: 26em;
}

.spotlights > section > .image {
	overflow: hidden;
}

.spotlights > section > .image img {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

@media screen and (max-width: 980px) {

	.spotlights > section > .image {
		height: 17em;
	}

}

/*
	顶部导航：宽屏直接平铺显示各栏目链接，窄屏退回「菜单」按钮 + 遮罩菜单
*/

#header nav ul.links {
	display: -moz-flex;
	display: -webkit-flex;
	display: -ms-flex;
	display: flex;
	height: inherit;
	list-style: none;
	margin: 0;
	padding: 0;
}

#header nav ul.links a {
	white-space: nowrap;
	color: rgba(255, 255, 255, 0.82);
	-moz-transition: color 0.2s ease-in-out;
	-webkit-transition: color 0.2s ease-in-out;
	-ms-transition: color 0.2s ease-in-out;
	transition: color 0.2s ease-in-out;
}

#header nav ul.links a:hover,
#header nav ul.links a:active {
	color: #9bf1ff;
}

#header nav > a[href="#menu"] {
	display: none;
}

@media screen and (max-width: 980px) {

	#header nav ul.links {
		display: none;
	}

	#header nav > a[href="#menu"] {
		display: block;
	}

}

/*
	动画：首屏入场、滚动进入揭示、图片悬停轻微放大
*/

/* 首屏内容：淡入上移 */
@keyframes banner-in {
	from {
		opacity: 0;
		-moz-transform: translateY(24px);
		-webkit-transform: translateY(24px);
		-ms-transform: translateY(24px);
		transform: translateY(24px);
	}

	to {
		opacity: 1;
		-moz-transform: none;
		-webkit-transform: none;
		-ms-transform: none;
		transform: none;
	}
}

body:not(.is-preload) #banner > .inner {
	-moz-animation: banner-in 0.9s ease 0.15s both;
	-webkit-animation: banner-in 0.9s ease 0.15s both;
	-ms-animation: banner-in 0.9s ease 0.15s both;
	animation: banner-in 0.9s ease 0.15s both;
}

/* 滚动进入揭示 */
.reveal-on-scroll {
	opacity: 0;
	-moz-transform: translateY(24px);
	-webkit-transform: translateY(24px);
	-ms-transform: translateY(24px);
	transform: translateY(24px);
	-moz-transition: opacity 0.7s ease, -moz-transform 0.7s ease;
	-webkit-transition: opacity 0.7s ease, -webkit-transform 0.7s ease;
	-ms-transition: opacity 0.7s ease, -ms-transform 0.7s ease;
	transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-on-scroll.is-visible {
	opacity: 1;
	-moz-transform: none;
	-webkit-transform: none;
	-ms-transform: none;
	transform: none;
}

/* 图片框只淡入，不位移；描述框稍作延迟形成层次 */
.spotlights > section > .image.reveal-on-scroll {
	-moz-transform: none;
	-webkit-transform: none;
	-ms-transform: none;
	transform: none;
}

.spotlights > section > .content > .inner.reveal-on-scroll {
	-moz-transition-delay: 0.12s;
	-webkit-transition-delay: 0.12s;
	-ms-transition-delay: 0.12s;
	transition-delay: 0.12s;
}

/* 图片悬停轻微放大 */
.spotlights > section > .image img {
	-moz-transition: -moz-transform 0.6s ease;
	-webkit-transition: -webkit-transform 0.6s ease;
	-ms-transition: -ms-transform 0.6s ease;
	transition: transform 0.6s ease;
}

.spotlights > section > .image:hover img {
	-moz-transform: scale(1.04);
	-webkit-transform: scale(1.04);
	-ms-transform: scale(1.04);
	transform: scale(1.04);
}

/* 减弱动效 */
@media (prefers-reduced-motion: reduce) {

	body:not(.is-preload) #banner > .inner {
		-moz-animation: none;
		-webkit-animation: none;
		-ms-animation: none;
		animation: none;
	}

	.reveal-on-scroll {
		opacity: 1 !important;
		-moz-transform: none !important;
		-webkit-transform: none !important;
		-ms-transform: none !important;
		transform: none !important;
		-moz-transition: none !important;
		-webkit-transition: none !important;
		-ms-transition: none !important;
		transition: none !important;
	}

	.spotlights > section > .image img,
	.spotlights > section > .image:hover img {
		-moz-transition: none;
		-webkit-transition: none;
		-ms-transition: none;
		transition: none;
		-moz-transform: none;
		-webkit-transform: none;
		-ms-transform: none;
		transform: none;
	}

}
