/* 6.2 Backgrounds
----------------------------------------------------------*/

/* Image / Slideshow */

.bg-image-holder,
.bg-slideshow-holder {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-position: center center;
	background-size:  cover;
	background-repeat: no-repeat; 
	z-index: 0;

	&.bottom {
		background-position-y: bottom;
	}
}

.bg-image-holder > img { display: none; }
.bg-image-holder + * { position: relative; }
.bg-image-fixed { 
	background-attachment: fixed; 

	@media #{$screen-sm} {
		background-attachment: scroll;
	}
}

.bg-slideshow-holder {
}

.bg-multiply {
	mix-blend-mode: multiply;
}

.bg-overlay {
	mix-blend-mode: overlay;
}

/* Video */

.bg-video {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}
.bg-video-placeholder { display: none; }

/* Map */

.bg-map {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;

	&.with-joiner:after {
		position: absolute;
		top: 0;
		left: 0;
		right: 0;
		height: 45%;
		content: ' ';
		background-image: linear-gradient(to bottom, #fff, rgba(#fff,0));
	}

	&.light-overlay:after,
	&.dark-overlay:after {
		position: absolute;
		top: 0;
		left: 0;
		width: 100%;
		height: 100%;
		content: ' ';
		@include transition(all 0.3s ease-out);
	}

	&.light-overlay:after {
		background: rgba(255,255,255,0.5);
	}
	&.dark-overlay:after {
		background: rgba(0,0,0,0.5);
	}

	&.light-overlay,
	&.dark-overlay {
		&:hover:after {
			visibility: hidden;
			@include opacity(0);
		}
	}
	
	& + * {
		position: relative;
	}
}

/* Colors */

.bg-white { background-color: #fff; }
.bg-light { background-color: $color-light; }
.bg-black { background-color: #000; }

$k: 1;
@for $i from 1 through length($colorVersions)/2 {
	$type: nth($colorVersions,$k);
	$color: nth($colorVersions,$k+1);

	.bg-#{$type} {
		background-color: $color !important;
	}
	$k: $k+2;
}

.bg-primary-tint {
	background-color: tint($color-primary,10%);
}

.bg-primary-shade {
	background-color: shade($color-primary,10%);
}


$k: 1;
@for $i from 1 through length($socialBrands)/2 {
	$type: nth($socialBrands,$k);
	$color: nth($socialBrands,$k+1);

	.bg-#{$type} {
		background-color: $color;
	}
	$k: $k+2;
}