/*
 * Home page slider. Replaces Master Slider 3.7.8 (slider #1, "Home Page Slider")
 * with the same look: fullwidth 1800x688 fade slider, caption layers,
 * light-skin-1 arrows and bullets, 4px time bar along the bottom.
 * Behaviour lives in js/home-slider.js. Caption layout comes from style.css
 * (#slider-home .home-slider__anim and the .slider-home-* classes).
 *
 * The rules below are Master Slider's own (masterslider.main.css, ms-skin-default)
 * under new class names, so sizes and stacking match.
 */

/* .master-slider-parent * — also makes the caption .btn content-box sized */
.home-slider,
.home-slider * {
	box-sizing: content-box;
}

.home-slider {
	position: relative;
	margin-left: auto;
	margin-right: auto;
	visibility: hidden; /* shown by JS once laid out, like Master Slider */
}
.home-slider.is-ready {
	visibility: visible;
}
.home-slider a,
.home-slider a:hover {
	-webkit-transition: none;
	transition: none;
}
.home-slider img {
	max-width: none;
}

.home-slider__container,
.home-slider__controls {
	position: relative;
	margin: 0 auto;
	-webkit-user-select: none;
	user-select: none;
}
.home-slider__controls {
	max-width: 1800px; /* centerControls: controls stay inside the 1800px box */
}

.home-slider__view {
	position: relative;
	overflow: hidden;
	margin: 0 auto;
	-webkit-perspective: 2000px;
	perspective: 2000px;
	/* before JS runs: reserve the slider's box (width x 688/1800, max 688px) */
	aspect-ratio: 1800 / 688;
	max-height: 688px;
	cursor: url(../img/slider/grab.png), move;
	touch-action: pan-y;
}
.home-slider__view.is-grabbing {
	cursor: url(../img/slider/grabbing.png), move;
}
.home-slider__slides {
	position: relative;
}

.home-slider__slide {
	position: absolute;
	top: 0;
	left: 0;
	height: 100%;
	-webkit-transform: translateZ(0px);
	transform: translateZ(0px);
}
.home-slider.is-wk .home-slider__slide {
	-webkit-transform-style: preserve-3d;
	transform-style: preserve-3d;
}

/* whole-slide link, above the caption layers (110 vs 109) as in Master Slider */
.home-slider__link {
	display: block;
	position: absolute;
	top: 0;
	width: 100%;
	height: 100%;
	z-index: 110;
}

.home-slider__bg {
	position: absolute;
	overflow: hidden;
	width: 100%;
	height: 100%;
}
.home-slider__bg img {
	display: block;
	-webkit-user-select: none;
	user-select: none;
	-webkit-user-drag: none;
}
.home-slider.is-moz .home-slider__bg > img {
	transform: translateX(0px);
}

/* per-slide spinner until its image loads */
.home-slider__loading {
	position: absolute;
	left: 50%;
	top: 50%;
	width: 36px;
	height: 36px;
	margin: -18px;
	border-radius: 60px;
	background: url(../img/slider/loading-2.gif) no-repeat center white;
	box-shadow: 0 0 3px rgba(0, 0, 0, 0.2);
	opacity: 0.9;
}

.home-slider__layers {
	position: absolute;
	top: 0;
	overflow: hidden;
	width: 100%;
	height: 100%;
	max-width: 1800px;
	z-index: 109;
	pointer-events: none;
}
.home-slider.is-wk .home-slider__layers,
.home-slider.is-wk .home-slider__link {
	-webkit-transform: translateZ(0.44px);
	transform: translateZ(0.44px);
}
.home-slider__layer {
	position: absolute;
	pointer-events: auto;
}

/* Arrows: ms-skin-default, light-skin-1 sprite */
.home-slider__nav {
	position: absolute;
	top: 50%;
	left: 30px;
	z-index: 110;
	width: 30px;
	height: 40px;
	margin: -20px 0 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: url(../img/slider/light-skin-1.png) -89px -26px;
	cursor: pointer;
	/* hidden/shown inline by JS (autohide, hideUnder 768) */
}
.home-slider__nav--next {
	left: auto;
	right: 30px;
	background-position: -89px -103px;
}

/* Bullets: centred, 10px up from the bottom, no gap between (space: 0) */
.home-slider__bullets {
	position: absolute;
	bottom: 10px;
	right: 50%;
	width: 40px; /* JS sets bullet width x count */
}
.home-slider__bullets-count {
	position: relative;
	right: -50%;
}
.home-slider__bullet {
	float: left;
	width: 10px;
	height: 10px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: url(../img/slider/light-skin-1.png) no-repeat -34px -117px;
	cursor: pointer;
}
.home-slider__bullet.is-selected {
	background-position: -34px -84px;
}

.home-slider__nav:focus-visible,
.home-slider__bullet:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 2px;
}

@media only screen and (-webkit-min-device-pixel-ratio: 2),
	only screen and (min-resolution: 192dpi),
	only screen and (min-resolution: 2dppx) {
	.home-slider__nav,
	.home-slider__bullet {
		background-image: url(../img/slider/light-skin-1-retina.png);
		background-size: 152px 225px;
	}
}

/* Time bar: full slider width, 4px, rgba(255,255,255,.65) */
.home-slider__timerbar {
	position: absolute;
	bottom: 0;
	width: 100%;
	height: 4px;
}
.home-slider__timebar {
	width: 0;
	height: 4px;
	background-color: rgba(255, 255, 255, 0.65);
	-webkit-transition: width 120ms linear;
	transition: width 120ms linear;
}
