@import '../../variables';

.loading-overlay {
	width:100%;
	height:100%;
	position:absolute;
	background: $green;
	@include themify() {
		background: $theme-background; /* Old browsers */
		/* IE9 SVG, needs conditional override of 'filter' to 'none' */
		background: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIxMDAlIiB5Mj0iMTAwJSI+CiAgICA8c3RvcCBvZmZzZXQ9IjAlIiBzdG9wLWNvbG9yPSIjNDllNGE5IiBzdG9wLW9wYWNpdHk9IjEiLz4KICAgIDxzdG9wIG9mZnNldD0iMTAwJSIgc3RvcC1jb2xvcj0iIzAwZTI4YiIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgPC9saW5lYXJHcmFkaWVudD4KICA8cmVjdCB4PSIwIiB5PSIwIiB3aWR0aD0iMSIgaGVpZ2h0PSIxIiBmaWxsPSJ1cmwoI2dyYWQtdWNnZy1nZW5lcmF0ZWQpIiAvPgo8L3N2Zz4=);
		background: -moz-linear-gradient(-45deg, $theme-background 0%, saturate($theme-background, 5%) 70%); /* FF3.6+ */
		background: -webkit-gradient(linear, left top, right bottom, color-stop(0%,$theme-background), color-stop(70%,saturate($theme-background, 5%))); /* Chrome,Safari4+ */
		background: -webkit-linear-gradient(-45deg, $theme-background 0%,saturate($theme-background, 5%) 70%); /* Chrome10+,Safari5.1+ */
		background: -o-linear-gradient(-45deg, $theme-background 0%,saturate($theme-background, 5%) 70%); /* Opera 11.10+ */
		background: -ms-linear-gradient(-45deg, $theme-background 0%,saturate($theme-background, 5%) 70%); /* IE10+ */
		background: linear-gradient(135deg, $theme-background 0%,saturate($theme-background, 5%) 70%); /* W3C */
		filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='$theme-background', endColorstr='saturate($theme-background, 5%)',GradientType=1 ); /* IE6-8 fallback on horizontal gradient */
	}
	opacity: 0.9;
	color: $white;
	z-index: 6;
	display: flex;
	justify-content: center;
	align-items: center;
	font-size: 2em;
	left: 0;
	transition: left .2s ease-in;

	img {
		clear: both;
		display: block;
	}

	& .prototypo-loading {
		background: url('../../../images/prototypo-loading.svg') no-repeat center;
		height: 50px;
		width: 50px;
	}
}

.loading-overlay-enter {
	left: -100%;
}

.loading-overlay-leave {
	left:100%;
}
