﻿
.referenzEntry {
	width: 45%;
	display:inline-block;
	margin-right: 8%;
	margin-bottom: 3em;
	cursor:pointer;
	vertical-align: top;
}

.referenzEntry img {
	margin: 0;
}

.referenzEntry:nth-child(2n) {
	margin-right: 0;
}


.referenzenOverlayContainer {
	opacity: 0;
	transition: opacity 0.5s ease;
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	width: 100vw;
	height: 100vh;
	z-index: 100;
	background-color: rgba(0,0,0,0.7);
	overflow:hidden;
}

.referenzenOverlayContainer.open {
	opacity: 1;
}

.referenzSlides {
	min-height: 100vh;
	height: auto;
	width: 100vw;
}

.referenzenSlidesWrapper {
	background-color: white;
}

.overlayCloser {
	position: fixed;
	top: 10px;
	right: 10px;
	display:block;
	width: 32px;
	height: 32px;
	z-index: 120;
	cursor:pointer;
}

.prevButton,
.nextButton {
	position: fixed;
	width: 32px;
	height: auto;
	z-index: 120;
	top: calc(50vh - 15px);
	cursor: pointer;
}

.prevButton svg,
.nextButton svg {
	height: 32px;
	width: auto;
}

.prevButton {
	left: 5px;
}

.nextButton {
	right: 5px;
}

.overlayCloser svg {
	width: 100%;
	height: auto;
}

.referenzSlides {
	width: 90%;
	height: auto;
}


.referenzSlide {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	margin: auto;
	height: 85vh;
	width: 80vw;
	opacity: 0;
	transition: opacity 0.5s ease;
}

.referenzSlide.active {
	opacity: 1;
}

.referenzSlide > img {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	margin: 0 auto;
	max-width: 100%;
	max-height: 60vh;
	height: auto;
	width: auto;
}

.referenzText {
	position: absolute;
	bottom: -2em;
	padding-top: 1em;
	background-color: rgba(255,255,255, 0.7);
	font-size: 0.8em;
	line-height: 1.2;
	z-index: 102;
	width: 100%;
}

.referenzDetails {
	color: #888;
}

.referenzText h4 {
	margin: 1em 0;
	font-weight: bold;
}

.slidesCounter {
	position: absolute;
	top: 0.6em;
	width: 100%;
	text-align: center;
	color: #888;
	font-size: 0.9em;
}


@media (min-width: 950px) { /* desktop */
	.referenzenVorschauContainer {
		margin-top: 4em;
	}

	.referenzEntry {
		width: 30%;
		margin-right: 4%;
		margin-bottom: 4em;
	}

	.referenzEntry:hover {
		font-weight: bold;
		letter-spacing: 0.02em;
	}

	.referenzEntry:nth-child(2n) {
		margin-right: 4%;
	}

	.referenzEntry:nth-child(3n) {
		margin-right: 0;
	}

	.referenzenSlidesWrapper {
		position: absolute;
		top: 0;
		left: 0;
		right: 0;
		bottom: 0;
		margin: auto;
		overflow:hidden;
		width: 900px;
		max-height: 900px;
		box-shadow: rgba(0,0,0,0.3) 10px 10px 30px;
	}
	
	.referenzSlides {
		min-height: 0;
		width: 100%;
	}

	.referenzSlide {
		height: 100%;
		width: 100%;
	}

	.referenzSlide>img {
		left: auto;
		right: 35%;
		top: auto;
		bottom: 4em;
		max-height: calc(94vh - 8em);
		max-width: 58%;
	}

	.referenzText {
		right: 2.5em;
		bottom: 2.7em;
		width: 26%;
		font-size: 1em;
		line-height: inherit;
	}

	.overlayCloser {
		position: absolute;
		top: 20px;
		right: 20px;
		transform: scale(1,1);
	}

		
	.overlayCloser:hover {
		transform: scale(1.06,1.06);
	}

	.nextButton,
	.prevButton {
		position: absolute;
		transform: scale(1,1);
		top: calc(50% - 15px);
	}

	.nextButton:hover,
	.prevButton:hover {
		transform: scale(1.1,1.1);
	}

	.nextButton {
		right: 15px;
	}

	.prevButton {
		left: 15px;
	}

	.slidesCounter {
		position: absolute;
		top: 1em;
		font-size: 1em;
	}

}