
.gallery-items {
	margin: 0;
	padding: 0;
	list-style: none;
	text-align: center;
	display: flex;
    flex-wrap: wrap;
    margin: -10px;
 }

.gallery-item {
	display: inline-block;
	vertical-align: top;
	-webkit-transition: height 500ms ease;
	-o-transition: height 500ms ease;
	transition: height 500ms ease;
	margin: 10px;
}

.gallery-expander {
	position: absolute;
	left: 0;
	right: 0;
	overflow: hidden;
	max-height: 0;
	-webkit-transition: max-height 500ms ease;
	-o-transition: max-height 500ms ease;
	transition: max-height 500ms ease;
}

.gallery-contents { position: relative; }

.gallery-contents:after {
	display: block;
	position: absolute;
	bottom: -30px;
	left: 50%;
	margin-left: -30px;
	width: 0;
	height: 0;
	content: '';
	border-left: 30px solid transparent;
	border-right: 30px solid transparent;
	border-bottom-style: solid;
	border-bottom-width: 0px;
	-webkit-transition: border-bottom-width 500ms ease;
	-o-transition: border-bottom-width 500ms ease;
	transition: border-bottom-width 500ms ease;
}
.gallery-item.active .gallery-expander {
	margin-top: 30px;
}
.gallery-item.active .gallery-contents:after { border-bottom-width: 30px; }

.gallery-item {
	max-width: calc( 100% / 3 - 20px );
	flex-grow: 1;
	flex-shrink: 1;
	flex-basis: 1;
}

.gallery-item .the-thumbnail {
	position: relative;
	overflow: hidden;
	cursor: pointer;
	box-shadow: 0 2px 4px 0 rgba(0,0,0,0.2);
}

.gallery-item .title {
	text-align: center;
	margin-top: 20px;
	padding-bottom: 20px;
}

.gallery-contents:after { border-bottom-color: #EEEEEE; }

.gallery-expander { 
	background: #EEEEEE; 
	margin-bottom: 30px;
}

.gallery-expander-contents {
	margin: 0 auto;
	padding: 40px;
}
@media (min-width: 640px) and (max-width: 999px) {

.gallery-expander-contents { width: 640px; }
}
@media (max-width: 639px) {

.gallery-expander-contents { width: 100%; }
}

.gallery-expander-contents:after {
	clear: both;
	display: table;
	content: '';
}

.gallery-expander-contents > div.col {
	float: left;
	width: 480px;
}
@media (min-width: 640px) and (max-width: 999px) {

.gallery-expander-contents > div.col { width: 310px; }
}
@media (max-width: 639px) {

.gallery-expander-contents > div.col {
	float: none;
	padding: 25px 20px 0;
	width: auto;
}
}

.gallery-expander-contents > div.col + div.col { margin-left: 40px; }
@media (min-width: 640px) and (max-width: 999px) {

.gallery-expander-contents > div.col + div.col { margin-left: 20px; }
}
@media (max-width: 639px) {

.gallery-expander-contents > div.col + div.col { margin-left: 0px; }
}

.gallery-expander-contents div.close {
	position: absolute;
	top: 10px;
	right: 20px;
}

.gallery-expander-contents div.title {
	font-weight: 500;
	color: #D28A3C;
}

.gallery-expander-contents div.contents {
	margin-top: 10px;
	font-size: 23px;
	line-height: 28px;
	color: #494949;
	text-align: left;
}

.gallery-expander-contents div.image > img {
	width: 100%;
	display: block;

}
li.gallery-item.active {
    margin-bottom: 50px;
}
.the-image-overlay {
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,.3);
    position: absolute;
    border-radius: 8px 8px 0 0;
}

.the-title {
    font-size: 20px;
    font-weight: bold;
    color: #fff;
    position: absolute;
    line-height: 23px;
    top: 44%;
    width: 100%;
    padding: 0 40px;
}
.content-title {
    font-size: 28px;
    text-align: left;
    color: #494949;
    font-weight: 600;
}
