/* RESET */
html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font:inherit;vertical-align:baseline}article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{display:block}body{line-height:1}ol,ul{list-style:none}blockquote,q{quotes:none}blockquote:before,blockquote:after,q:before,q:after{content:'';content:none}table{border-collapse:collapse;border-spacing:0}

.clear {
        clear: both;
}

.cover {
	background-size: cover;
	background-position: center center;
}

.transition( @target: all, @duration: 400ms, @type: ease, @delay: 0s ) {
	-webkit-transition: @target @duration @type @delay;
	-moz-transition: @target @duration @type @delay;
	-ms-transition: @target @duration @type @delay;
	-o-transition: @target @duration @type @delay;
	transition: @target @duration @type @delay;
}

.border-radius( @value: 1000px ) {
	-webkit-border-radius: @value;
	border-radius: @value;
	-webkit-background-clip: padding-box; 
	-moz-background-clip: padding; 
	background-clip: padding-box;
}

.contain {
	background-size: contain;
	background-repeat: no-repeat;
	background-position: center center;
}

.rotate( @value: 0deg ) {
	-webkit-transform: rotate( @value );
	-moz-transform: rotate( @value );
	-ms-transform: rotate( @value );
	-o-transform: rotate( @value );
	transform: rotate( @value );
}

.box-sizing {
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
	box-sizing: border-box;
}

html, body {
}

/*================================*/

.page {
	font-family: 'trivia-grotesk';
	
	.start, .action, .finish {
		position: relative;
		display: none;
		padding: 50px 0;
		.box-sizing;
		
		&.shown {
			display: block;
		}
	}

	.start {
		background-image: url(../images/bg1.jpg);
		color: #ffffff;
		.cover;
		
		.container {
			width: 600px;
			margin: 0 auto;
			background-image: url(../images/bomb.png);
			background-repeat: no-repeat;
			background-position: center 180px;
			background-size: 600px auto;
		}
		
		.title {
			text-align: center;
			font-size: 43px;
			line-height: 51px;
			margin-bottom: 30px;
		}
		
		.subtitle {
			text-align: center;
			font-size: 22px;
			line-height: 30px;
			text-decoration: underline;
		}
		
		.authors {
			position: relative;
			left: -20px;
			margin-top: 250px;
			margin-bottom: 10px;
		}
		
		.rubrics {
			margin-bottom: 30px;
		}
		
		.description {
			font-size: 16px;
			line-height: 22px;
			margin-bottom: 30px;
		}
		
		.about {
			font-size: 22px;
			line-height: 30px;
			margin-bottom: 60px;
		}
		
		.button {
			width: 272px;
			height: 112px;
			background-image: url(../images/btn1.png);
			cursor: pointer;
			background-position: 0px 0px;
			margin: 0 auto;
			
			&:hover {
				background-position: 0px -113px;
			}
		}
		
		a {
			text-decoration: underline;
			color: #ffffff;
		}
	}
	
	.action {
		@width: 1000px;
		@height: 500px;
	
		height: @height;
			
		.background {
			position: absolute;
			z-index: 1;
			width: 100%;
			height: 100%;
			left: 0;
			top: 0;
			background-image: url(../images/bg1.jpg);
			.cover;
		
			.bar {
				position: absolute;
				z-index: 1;
				width: 0%;
				height: 100%;
				left: 0;
				top: 0;
				background-image: url(../images/bg2.jpg);
				.cover;
			}
		}
		
		.info {
			position: absolute;
			z-index: 2;
			width: 100%;
			height: 100%;
			left: 0;
			top: 0;
			
			.sh-hidden {
				opacity: 0;
				.transition(@duration: 400ms, @target: opacity);
			}
			
			.sh-shown {
				opacity: 1;
			}
		
			.container {
				position: absolute;
				width: @width;
				height: @height;
				left: 50%;
				top: 50%;
				margin-left: -@width / 2;
				margin-top: -@height / 2;
			}
			
			.question {
				position: absolute;
				width: 200px;
				color: #000000;
				font-size: 30px;
				line-height: 38px;
				left: 0;
				top: 190px;
			}
			
			.hint {
				position: absolute;
				width: 200px;
				color: #000000;
				font-size: 30px;
				line-height: 38px;
				right: 0;
				top: 190px;
				.sh-hidden;
				
				&.shown {
					.sh-shown;
				}
			}
			
			.counter {
				position: absolute;
				width: 100px;
				text-align: center;
				font-size: 16px;
				line-height: 16px;
				left: 50%;
				top: 20px;
				margin-left: -50px;
				color: #ffffff;
			}
			
			.image {
				position: absolute;
				z-index: 1;
				width: 400px;
				height: 400px;
				left: 50%;
				top: 50%;
				margin-left: -200px;
				margin-top: -200px;
				.cover;
			}
			
			.percent {
				position: absolute;
				z-index: 2;
				width: 170px;
				text-align: center;
				font-size: 20px;
				line-height: 20px;
				left: 0%;
				top: 50%;
				margin-top: 80px;
				color: #ffffff;
				
				span {
					display: block;
					font-size: 60px;
					line-height: 60px;
				}
			}
			
			.range, .ok {
				display: none;
			}
			
			.counter, .image, .label, .percent {
				.sh-hidden;
			}
			
			&.shown {
				.counter, .image, .label, .percent {
					.sh-shown !important;
				}
			}
		}
		
		.layer {
			position: absolute;
			z-index: 3;
			width: 100%;
			height: 100%;
			left: 0;
			top: 0;
			cursor: ew-resize;
		}
	}
	
	.finish {
		background-image: url(../images/bg1.jpg);
		.cover;
	
		.container {
			width: 600px;
			margin: 0 auto;
		}
		
		.label, .you, .percent, .result {
			text-align: center;
			font-size: 20px;
			line-height: 26px;
			color: #ffffff;
		}
		
		.label {
			color: #000000;
		}
		
		.you {
			margin-top: 30px;
		}
		
		.percent {
			font-size: 72px;
			line-height: 72px;
			margin: 30px 0;
		}
		
		.result {
			
		}
		
		.shares {
			margin-top: 60px;
			padding: 0 30px;
		
			.share {
				float: left;
				width: 150px;
				height: 45px;
				background-image: url(../images/btnShare.png);
				cursor: pointer;
				margin-right: 30px;
				
				&.fb {
					background-position: 0px 0px;
					
					&:hover {
						background-position: 0px -46px;
					}
				}
				
				&.vk {
					background-position: 150px 0px;
					
					&:hover {
						background-position: 150px -46px;
					}
				}
				
				&.tw {
					margin-right: 0px;
					background-position: -165px 0px;
					
					&:hover {
						background-position: -165px -46px;
					}
				}
			}
		}
		
		.more {
			display: block;
			width: 154px;
			height: 154px;
			margin: 30px auto;
			margin-top: 30px;
			background-image: url(../images/btnMore.png);
			background-position: 0px 0px;
			
			&:hover {
				background-position: 0px -155px;
			}
		}
	}
	
	&.mobile {
		.container {
			width: 100%;
			padding: 0 20px;
			height: auto;
			.box-sizing;
		}
		
		.start {
			.container {
				background-size: 100% auto;
				background-position: center 280px;
			}
		
			.title {
				font-size: 33px;
				line-height: 41px;
			}
			
			.subtitle {
				font-size: 18px;
				line-height: 26px;
			}
			
			.authors {
				left: 0;
				margin-top: 195px;
			}
			
			.description, .about {
				font-size: 14px;
				line-height: 20px;
			}
		}
		
		.action {
			background-image: url(../images/bg1.jpg);
			height: auto;
			.cover;
		
			.container {
				position: relative;
				left: auto;
				margin-left: auto;
				top: auto;
				margin-top: auto;
				height: auto;
				width: 100%;
			}
			
			.info {
				position: relative;
				left: auto;
				margin-left: auto;
				top: auto;
				margin-top: auto;
				height: auto;
			}
			
			.background {
				display: none;
			}
			
			.layer {
				display: none;
			}
			
			.counter, .image, .question, .percent {
				position: relative;
				left: auto;
				top: auto;
				margin: auto;
				width: auto;
			}
			
			.question {
				text-align: center;
				color: #ffffff;
				font-size: 18px;
				line-height: 24px;
				margin-top: 20px;
			}
			
			.hint {
				display: none;
			}
			
			.range, .ok {
				display: block;
			}
			
			.ok {
				width: auto;
				height: 100px;
				line-height: 100px;
				text-align: center;
				color: #ffffff;
				background-color: #FF6568;
				font-size: 72px;
				
				&:hover {
					background-color: #FFE565;
				}
			}
			
			.rangeslider {
				position: relative;
				height: 50px;
				margin-top: 20px;
				
				.rangeslider__fill {
					position: relative;
					z-index: 2;
					height: 30px;
					top: 10px;
					background-image: url(../images/sliderMobile.png);
					.cover;
				}
				
				.rangeslider__handle {
					position: absolute;
					z-index: 3;
					height: 100%;
					width: 20px;
					top: 0;
					background-color: black;
				}
			}
			
			.counter {
				font-size: 18px;
				line-height: 24px;
				margin: 10px 0;
			}
			
			.image {
				height: 280px;
			}
			
			.percent {
				font-size: 14px;
			
				span {
					display: inline;
					font-size: 18px;
				}
			}
		}
		
		.finish {
			.share {
				float: none;
				margin-right: auto !important;
				margin: 0 auto !important;
				margin-bottom: 10px !important;
			}
		}
	}
}