/* import the base */
@import 'base/_colors';

@import 'base/_sizes';

/* The animation for the spinner */
@keyframes rotate {
	to {
		transform: rotate(360deg);
	}
}

html, body {
	height: 100%;
	font-family: arial, tahoma, helvetica, sans-serif;
	font-size: 13px;
}
body.login,
#loading-mask,
#bg,
body.zarafa-welcome {
	margin: 0;
	padding: 0;
	background: url(../../images/loginbg_daybreak.jpg) no-repeat center center;
	background-size: cover;
}

body.login.theme-basic:after,
body.theme-basic #loading-mask:after,
body.theme-basic #bg:after,
body.theme-basic.zarafa-welcome:after,
body.login.theme-highcontrast:after,
body.theme-highcontrast #loading-mask:after,
body.theme-highcontrast #bg:after,
body.theme-highcontrast.zarafa-welcome:after,
body.login.theme-dark:after,
body.theme-dark #loading-mask:after,
body.theme-dark #bg:after,
body.theme-dark.zarafa-welcome:after {
	content: '';
	position: absolute;
	top: 0;
	bottom: 0;
	left: 0;
	right: 0;
	margin: 0;
	padding: 0;
	background: url(../../images/background.svg);
	background-size: cover;
	z-index: -1;
}

#loading-mask {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	/** ExtJS uses 20001 as z-index for its loading mask, so we need to use values higher then this **/
	z-index: 20002;
}

body.login,
#loading-mask {
	#form-container {
		display: inline-block;
		visibility: hidden;
		top: 0;
		position: relative;
		overflow: hidden;
		z-index: 20010;
		color: $dark-grey2;

		#bg {
			position: absolute;
			left: 0;
			top: 0;
			-webkit-filter: blur(10px);
			filter: blur(10px);
		}

		#content {
			width: 560px;
			padding: 50px 60px 60px;
			background: rgba(255, 255, 255, 0.5);
			position: relative;
		}
		/* clearfix */
		#content:after {
    		content: " ";
    		display: block;
			clear: both;
		}

		.left {
			float: left;
			width: 220px;
			height: 220px;
			padding-right: 60px;
		}
		.right {
			float: left;
			width: 245px;
			padding-left: 35px;
			min-height: 220px;
			position: relative;
		}

		h1 {
			font-size: 36px !important;
			line-height: 36px;
			font-weight: normal;
			margin: 0 0 30px;
		}
		h2 {
			font-size: 13px;
			font-weight: normal;
			text-align: right;
		}

		#logo {
			background: url(../../images/kopano-logo.svg) no-repeat right center;
			background-size: 220px 52px;
			width: 100%;
			height: 61px;
			margin: 71px 0 15px;
		}
	}

	#form-container.loading {
		visibility: visible;
		.right {
			h1, form{
				display: none;
			}

			background: url(../../images/loading_m.png) no-repeat center center;
			animation: rotate 1.3s 0s infinite ease;
		}
	}
}


body.login > #form-container {
	label {
		display: block;
		margin-bottom: 0.5em;
	}
	input[type="text"],
	input[type="password"] {
		display: block;
		width: 245 - 2* $padding-medium - 2;
		background: white !important;
		border: 1px solid $grey;
		padding: 0 $padding-medium;
		margin-bottom: 15px;
		height: 24px;
	}

	input:-webkit-autofill {
		-webkit-box-shadow: 0 0 0px 1000px white inset;
	}

	input:focus {
		outline:0;
		border-color: $sky-blue;
	}

	#password {
		margin-bottom: 8px;
	}

	#error {
		color: #e40023;
	}

	#submitbutton {
		background: $kopano-blue;
		color: white;
		height: 24px;
		line-height: 24px;
		border: 1px solid transparent;
		padding: 0 $padding-large;
		min-width: 84px;
		margin: 12px 0 0;
		box-shadow: 0px 1px 1px 0px rgba(0, 0, 0, 0.35);
	}
	#submitbutton:hover {
		background-color: $kopano-blue-hover;
	}
	#submitbutton:click {
		background-color: $kopano-blue-active;
	}
	#submitbutton:focus {
		box-shadow: 0 0 0 1px $white inset;
	}
}

/* IE10 and IE11 don't support filters, so we load a blurred copy of the background image
 * and use that  */
body.login.MSIE10 #bg,
body.login.MSIE11 #bg{
	background-image: url(../../images/loginbg_daybreak_blurred.jpg);
}
