@import "../config/config.scss";
/* SLIDER */

.wk-slider{
	width: 100%;
	height: auto;
	position: relative;
	height: 70vh;

	@include mq($from:desktop){
		margin-bottom: 5px;
	}
	@include mq($from:wide){
		margin-bottom: 10px;
	}


	ul.slides {
		width: 100%;
		padding-top: 0;
		padding-bottom: 0;
		height: auto;

		li {
			width: 100%;
			height: 0;
			padding:0;
			padding-bottom:0%;
			position: relative;
			height: auto;
			background-size: cover;
			background-repeat: no-repeat;
			background-position: center center;

			&:before {
				content: "";
				display: none;
			}

			.slideimg {
				display: block;
				position: relative;
				width: 100%;
				padding-bottom: 100%;
				height: 0;
				
				background-size: cover;
				background-repeat: no-repeat;
				background-position: center center;

				@include mq($from:tablet){
					padding-bottom: 70vh;
				}

			}

			.testo_slide {
				position: relative;
				padding: 10px;
				padding-left:0vw;
				padding-right:0vw;
				color:$nero;
				box-sizing: border-box;
				position: absolute;
			    width: auto;
			    top: 50%;
			    left: 50%;
			    transform: translateX(-50%) translateY(-50%);
			    text-align: center;


				@include mq($to:tablet){
					color: $color_2 !important;
					padding-left: 5vw;
					padding-right: 5vw;
					padding-top: 5vh;
				}

				@include mq($from:tablet){
					position: absolute;
					width: auto;
					max-width: 800px;
					color: $bianco;
				}

				a.pulsante {
					margin-top: 2.5em;
				}

				span {
					font-size: 1.5em;
					line-height: 1.2em;
					font-weight: 300;
					@include mq($from:tablet){
						font-size: 1.7em;
					}
					@include mq($from:desktop){
						font-size: 1.8em;
					}
					@include mq($from:wide){
						font-size: 2em;
					}
				}

				&.top-left {
					text-align: left;

					@include mq($from:tablet){
						text-align: left;
						left: 8vw;
						top: 8vw;
					}
				}
				&.top-center {
					text-align: center;

					@include mq($from:tablet){
						text-align: center;
						left: 50%;
						transform:translateX(-50%);
						top: 8vw;
					}
				}
				&.top-right {
					text-align: right;

					@include mq($from:tablet){
						text-align: right;
						right: 8vw;
						top: 8vw;
					}
				}
				&.center-left {
					text-align: left;

					@include mq($from:tablet){
						text-align: left;
						left: 8vw;
						transform:translateY(-50%);
						top: 50%;
					}
				}
				&.center-center {
					text-align: center;
					@include mq($from:tablet){
						text-align: center;
						left: 50%;
						transform:translateX(-50%) translateY(-50%);
						top: 50%;
					}
				}
				&.center-right {
					text-align: right;
					@include mq($from:tablet){
						text-align: right;
						right: 8vw;
						transform:translateY(-50%);
						top: 50%;
					}
				}
				&.bottom-left {
					text-align: left;
					@include mq($from:tablet){
						text-align: left;
						left: 8vw;
						bottom: 8vw;
					}
				}
				&.bottom-center {
					text-align: center;
					@include mq($from:tablet){
						text-align: center;
						left: 50%;
						transform:translateX(-50%);
						bottom: 8vw;
					}
				}
				&.bottom-right {
					text-align: right;
					@include mq($from:tablet){
						text-align: right;
						bottom: 8vw;
						right: 8vw;
					}
				}
			}

			.caption {
				position: absolute;
				max-width: 30px;
				min-width: 30px;
				min-height: 30px;
				border-radius:15px;
				background: rgba(255,255,255,0);
				border:2px solid $bianco; 
				overflow: hidden;
				bottom:15px;
				left: 15px;
				color: $bianco;
				transition:max-width .3s, background 0.3s, color .3s;
				transition-delay:0.3s;

				@include mq($from:tablet){
					max-width: 48px;
					min-width: 48px;
					min-height: 48px;
					border-radius:24px;
					bottom: 24px;
					left: 24px;
				}

				span {
					display: block;
					margin-left: 30px;
					padding-top: 6px;
					padding-bottom: 6px;
					padding-right: 10px;
					font-size: 11px;
					line-height: 14px;
					max-height: 26px;
					min-width: 100px;
					overflow: hidden;
					transition-property:max-height;
					transition-duration: 0.3s;
					transition-delay:0s;

					&::first-letter {text-transform: uppercase}

					@include mq($from:tablet){
						margin-left: 48px;
						padding-top: 14px;
						padding-bottom: 14px;
						padding-right: 20px;
						font-size: 12px;
						line-height: 16px;
						max-height: 36px;
					}
					@include mq($from:desktop){
						padding-top: 13px;
						padding-bottom: 13px;
						font-size: 13px;
						line-height: 17px;
					}
					@include mq($from:wide){
						padding-top: 12px;
						padding-bottom: 12px;
						font-size: 14px;
						line-height: 18px;
					}
				}

				&:before {
					display: block;
					position: absolute;
					text-align: center;
					content: "i";
					width: 30px;
					height: 30px;
					left: 0;
					line-height: 100%;
					font-size: 25px;
					top: 50%;
					margin-top: -12px;
					left: -2px;
					@include mq($from:tablet){
						content: "i";
						width: 48px;
						height: 48px;
						font-size: 30px;
						top: 50%;
						margin-top: -15px;
					}
				}
			}

			.caption.attivo {
				max-width: calc( 100% - 30px ) !important;
				background: $bianco !important;
				color: $color_2 !important;
				transition:max-width .3s, background 0.3s, color .3s;
				transition-delay:0s !important;

				&:before {
					content: "x" !important;
					font-size: 19px !important;
					margin-top: -11px !important;
					font-weight: 300 !important;
					@include mq($from:tablet){
						font-size: 25px !important;
						margin-top: -15px !important;
					}
				}

				span {
				    max-height:90px !important;
				    max-height:100% !important;
				    transition-property:max-height !important;
				    transition-duration: 0.3s !important;
				    transition-delay:.2s !important;
				  }
			}
		}
	}
}


.flex-direction-nav {
	@include mq($to:tablet){display: none !important;}
}

.notouch .wk-slider {
	@include mq($from:tablet){
		a.flex-prev, a.flex-next {
			display:block;
		}

		.flex-direction-nav {
			padding-top: 0;
			padding-bottom: 0;

			li {
				&:before {
					content: "";
					display: none;
				}
			}
		}

		.flex-direction-nav li a {
			
			position: absolute;
			width: 10%;
			height: 80%;
			top: 10%;
			z-index: 9;
			cursor: pointer;
			color: transparent;
			opacity: 0;
			left: 2%;

			&.flex-prev::before {
				content: " ";
				@include arrow("left", $bianco);
				transform: translateX(-50%) translateY(-50%) rotate(90deg);
				width: 50px;
				height: 50px;
				top: 50%;
				left: 50%;
				position: absolute;
			}


			&.flex-next {
				left: inherit;
				right: 2%;
			}

			&.flex-next::before {
				content: " ";
				@include arrow("right", $bianco);
				transform: translateX(-50%) translateY(-50%) rotate(270deg);
				width: 50px;
				height: 50px;
				top: 50%;
				left: 50%;
				position: absolute;
			}
		}
	}
}

.notouch .wk-slider:hover {
	@include mq($from:tablet){
		.flex-direction-nav li a { opacity: 0.3; }
		.flex-direction-nav li a.flex-next { left:inherit;}
		.flex-direction-nav li a:hover { opacity: 1; }
		.flex-direction-nav li a.flex-next:hover { left: inherit;}
	}
}

.notouch .wk_caption_inside .caption:hover {
	max-width: calc( 100% - 30px ) !important;
	background: $bianco !important;
	color: $color_2 !important;
	transition:max-width .3s, background 0.3s, color .3s;
	transition-delay:0s !important;

	span {
	    max-height:90px !important;
	    max-height:100% !important;
	    transition-property:max-height !important;
	    transition-duration: 0.3s !important;
	    transition-delay:.2s !important;
	  }
}

.notouch a.slidelink {
	text-shadow:0px 0px 0px rgba(0,0,0,0);
	transition: text-shadow .5s;

	&:hover {
		text-shadow:0px 0px 15px rgba(0,0,0,0.4);
	}
}


.wk-slider.wk_vertical {
	width: 100%;
	height: auto;
	position: relative;

	ul.slides {
		width: 100%;
		height: auto;

		li {
			width: 100%;
			height: auto;

			.slideimg {
				display: block;
				position: relative;
				width: 100%;
				padding-bottom: 132%;

				@include mq($from:tablet){
					padding-bottom: 132%;
				}
				@include mq($from:desktop){
					padding-bottom: 132%;
				}
				@include mq($from:wide){
					padding-bottom: 132%;
				}
			}

		}
	}
}


.wk-slider.wk_horizontal {
	width: 100%;
	height: auto;
	position: relative;

	ul.slides {
		width: 100%;
		height: auto;

		li {
			width: 100%;
			height: auto;

			.slideimg {
				display: block;
				position: relative;
				width: 100%;
				padding-bottom: 60%;

				@include mq($from:tablet){
					padding-bottom: 60%;
				}
				@include mq($from:desktop){
					padding-bottom: 60%;
				}
				@include mq($from:wide){
					padding-bottom: 60%;
				}
			}

		}
	}
}

.wk-slider.wk_squared {
	width: 100%;
	height: auto;
	position: relative;

	ul.slides {
		width: 100%;
		height: auto;

		li {
			width: 100%;
			height: auto;

			.slideimg {
				display: block;
				position: relative;
				width: 100%;
				padding-bottom: 100%;

				@include mq($from:tablet){
					padding-bottom: 100%;
				}
				@include mq($from:desktop){
					padding-bottom: 100%;
				}
				@include mq($from:wide){
					padding-bottom: 100%;
				}
			}

		}
	}
}


.wk-slider.wk_horizontal, .wk-slider.wk_vertical, .wk-slider.wk_squared {

	.flex-control-nav {
		width: 100%; 
		position: absolute;  
		text-align: right; 
		display: block !important; 
		z-index: 999; 
		top: calc( 100% + 7px ); 
		overflow: hidden;
		text-align: center;

		@include mq($from:tablet){
			top: calc( 100% + 12px );  
		}
	}
	.flex-control-nav li {
		padding: 0;

		margin: 0 3px; 
		display: inline-block; 
		zoom: 1; 
		*display: inline;
		@include mq($from:tablet){
			margin: 0 5px; 
		}

		&:last-child {
			margin-right: 0;
		}

		&:before {
			display: none !important;
		}
	}
	.flex-control-paging li a {
		display: block; 
		width: 7px; 
		height: 7px; 
		background: none; 
		border:1px solid $color_2; 
		cursor: pointer; 
		text-indent: 9999px; 
		-webkit-border-radius: 20px; 
		-moz-border-radius: 20px; 
		-o-border-radius: 20px; 
		border-radius: 20px; 
		@include mq($from:tablet){
			width: 11px; 
			height: 11px; 
		}
	}
	.flex-control-paging li a:hover { background: $color_2; }
	.flex-control-paging li a.flex-active { background: $color_2; cursor: default; }	
}


.wk-slider.wk_contain ul li {
	
	background-color: darken($color_2, 30%)!important;

	.slideimg{

		background-size: contain !important;

	}
}




