.gallery {
	padding-bottom: 10px;
	
	-webkit-column-count: 4;
	-moz-column-count: 4;
	column-count: 4;
	
	-webkit-column-gap: 10px;
	-moz-column-gap: 10px;
	column-gap: 10px;
}
.gallery .thumbnail {
	height: 400px;
	padding: 0;
	margin-bottom: 10px;
	border-radius: 2px !important;
	display: block;
	
	background-size: cover;
	background-position: center;
	
	overflow-y: hidden;
}
.gallery .thumbnail img {
	width: 100%; height: auto;
	opacity: 0;
}

#blend {
	position: fixed;
	top: 0; left: 0;
	width: 100%; height: 100%;
	background: rgba( 0,0,0,0.5 );
}
#image-detail {
	position: fixed;
	top: 50%; left: 50%;
	max-width: 100%;
/*	max-height: 600px; */
	height: auto;
	padding: 10px;
	border-radius: 10px;
	box-shadow: 0px 0px 24px rgba(0, 0, 0, 0.8);
	background: #fff;
}
#image-detail img { 
	border-radius: 10px; 
	max-width: 100%;
	max-height: 100%;
	height: auto;
}

#image-detail span[class^="btn-"] {
	position:absolute;
	min-width: 36px;
	min-height: 36px;
	background-repeat: no-repeat;
	cursor: pointer;
}

#image-detail .btn-close {
	top: -12px; right: -12px;
	width: 36px; height: 36px;
	background-image: url(images/btn-close.png);
}
#image-detail .btn-prev, #image-detail .btn-next { 
	bottom: -15px; 
	width: 50%; 
	height: 100%;
}
#image-detail .btn-prev { left: 0; background: url(images/btn-prev.png) 100% 100% }
#image-detail .btn-next { right: 0; background: url(images/btn-next.png) 0 100% }


@media screen and (max-width: 990px) {
	.gallery {
		padding-left: 15px;
		padding-right: 15px;
	}
}

@media screen and (max-width: 800px) {
	.gallery {
		padding-left: 20px;
		padding-right: 20px;
		
		-webkit-column-count: 2;
		-moz-column-count: 2;
		column-count: 2;
	}
	.gallery .thumbnail {
		max-height: 999px;
	}
}


@media screen and (max-width: 600px) {
	.gallery {
		padding: 0 20px 20px;
	
		-webkit-column-count: 1;
		-moz-column-count: 1;
		column-count: 1;
	}
	.gallery .thumbnail { cursor: default }
}

