/*
* SFS Gallery Display CSS
*/

.sfs-main-gallery-container {
    position: relative;
}

.sfs-custom-gallery .sfs-category-images .container,
.sfs-custom-gallery .sfs-grid-images .container,
.sfs-custom-gallery .sfs-album-images .container,
.sfs-custom-gallery .sfs-album-category-images .container {
    display: -webkit-flex;
    display: -moz-flex;
    display: -ms-flex;
    display: -o-flex;
    display: -ms-flexbox;
    display: flex;
    -webkit-flex-flow: row wrap;
    -ms-flex-flow: row wrap;
    flex-flow: row wrap;
    -webkit-justify-content: space-between;
    -ms-flex-pack: justify;
    justify-content: normal;
    align-items: normal;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item,
.sfs-custom-gallery .sfs-album-images .sfs-image-item,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item {
    padding: 5px 5px;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item.load_more,
.sfs-custom-gallery .sfs-album-images .sfs-image-item.load_more,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item.load_more,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item {
    display: none;
    padding: 5px 5px;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item .sfs-image-item-container,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item .sfs-image-item-container,
.sfs-custom-gallery .sfs-album-images .sfs-image-item .sfs-image-item-container,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item .sfs-image-item-container {
    height: 100%;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item.col-one,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item.col-one,
.sfs-custom-gallery .sfs-album-images .sfs-image-item.col-one,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item.col-one {
    width: auto;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item.col-two,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item.col-two,
.sfs-custom-gallery .sfs-album-images .sfs-image-item.col-two,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item.col-two {
    width: 50%;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item.col-three,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item.col-three,
.sfs-custom-gallery .sfs-album-images .sfs-image-item.col-three,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item.col-three {
    width: 33.33%;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item.col-four,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item.col-four,
.sfs-custom-gallery .sfs-album-images .sfs-image-item.col-four,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item.col-four {
    width: 25%;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item.col-five,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item.col-five,
.sfs-custom-gallery .sfs-album-images .sfs-image-item.col-five,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item.col-five {
    width: 20%;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item.col-six,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item.col-six,
.sfs-custom-gallery .sfs-album-images .sfs-image-item.col-six,
.sfs-custom-gallery .sfs-album-category-images .sfs-image-item.col-six {
    width: 16.66%;
}

.sfs-custom-gallery .sfs-category-images .sfs-image-item .sfs-image-title,
.sfs-custom-gallery .sfs-grid-images .sfs-image-item .sfs-image-title,
.sfs-custom-gallery .sfs-slide-images .sfs-image-item .sfs-image-title,
.sfs-custom-gallery .sfs-navigation-images .sfs-image-item .sfs-image-title,
.sfs-custom-gallery .sfs-album-images .sfs-album-title,
.sfs-custom-gallery .sfs-album-category-images .sfs-album-title,
.sfs-custom-gallery .sfs-album_slide-images .sfs-album-title {
    text-align: center;
    display: block;
    padding: 5px 5px;
}

.sfs-custom-gallery .sfs-image-item .sfs-image-item-container .sfs-gallery-image img,
.sfs-custom-gallery .sfs-image-item .sfs-image-item-container .sfs-nav-image img {
    display: block;
    margin: 0 auto;
}

.sfs-custom-gallery .gallery-item-container {
    position: relative;
}

.sfs-custom-gallery .sfs-slide-images,
.sfs-main-gallery-preview {
    position: relative;
}

/*
*   Popup Gallery CSS
*/

.sfs-custom-gallery .gallery-image-popup {
    top: 0;
    left: 0;
    position: fixed;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    display: none;
    z-index: 999999;
    overflow: hidden;
}

.sfs-custom-gallery .gallery-image-popup-container {
    padding: 50px 5%;
    height: 100%;
    display: block;
    position: relative;
}

.sfs-custom-gallery .gallery-item-image-popup {
    height: 100%;
    position: relative;
    display: none;
}

.sfs-custom-gallery .gallery-image-popup .sfs-gallery-popup-image {
    display: none;
}

.sfs-custom-gallery .gallery-image-popup .sfs-gallery-popup-image.active {
    display: -webkit-flex;
    display: -moz-flex;
    display: -ms-flex;
    display: -o-flex;
    display: -ms-flexbox;
    display: flex;
    -webkit-flex-flow: row wrap;
    -ms-flex-flow: row wrap;
    flex-flow: row wrap;
    -webkit-justify-content: center;
    -ms-flex-pack: justify;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    height: 100%;
    width: auto;
    position: relative;
}

.sfs-custom-gallery .gallery-image-popup .sfs-gallery-popup-image img {
    display: block;
    margin: 0 auto;
    max-width: 100%;
    max-height: 100%;
}

.gallery-image-popup .sfs-popup-close {
    position: absolute;
    right: 0;
    top: 0;
    font-size: 30px;
    padding: 10px;
    cursor: pointer;
    line-height: 0;
    background-color: #fff;
}

.popup-slide-control .left-slide,
.popup-slide-control .right-slide {
    position: absolute;
    top: 50%;
    -webkit-transform: translateY(-50%);
    -o-transform: translateY(-50%);
    transform: translateY(-50%);
    padding: 10px 5px;
    line-height: 0;
    font-size: 30px;
    background-color: #fff;
    cursor: pointer;
}

.popup-slide-control .left-slide {
    left: 5px;
}

.popup-slide-control .right-slide {
    right: 5px;
}

.sfs-gallery-popup-image .image-title,
.sfs-gallery-popup-image .image-description {
    width: 100%;
    text-align: center;
}

.gallery-image-popup .sfs-image-count {
    position: fixed;
    top: 0;
    left: 0;
    background-color: #fff;
    padding: 10px 10px;
    font-size: 16px;
}

.sfs-category-navigation {
    text-align: center;
}

.sfs-category-navigation .category-item {
    display: inline-block;
    vertical-align: middle;
    background-color: #ccc;
    padding: 5px 20px;
    cursor: pointer;
    margin-bottom: 5px;
}

.sfs-category-navigation .category-item.active,
.sfs-category-navigation .category-item:hover,
.sfs-custom-gallery .sfs-loadmore-btn:hover {
    background-color: #000;
    color: #fff;
}

.sfs-custom-gallery .sfs-loadmore {
    text-align: center;
    display: block;
}

.sfs-custom-gallery .sfs-loadmore-btn {
    display: inline-block;
    background-color: #ccc;
    padding: 5px 20px;
    cursor: pointer;
}

.sfs-main-gallery-container .container,
.sfs-main-gallery-preview .preview-gallery {
    display: none;
}

.sfs-main-gallery-container .container.slick-initialized.slick-slider,
.sfs-main-gallery-preview .preview-gallery.slick-initialized.slick-slider {
    display: block;
}

.sfs-custom-gallery .slide-control > div {
    cursor: pointer;
    padding: 5px;
    background-color: #ccc;
    line-height: 1;
    position: absolute;
    top: 50%;
    -webkit-transform: translateY(-50%);
    -o-transform: translateY(-50%);
    transform: translateY(-50%);
}

.sfs-custom-gallery .slide-control .left-control {
    left: 0;
}

.sfs-custom-gallery .slide-control .right-control {
    right: 0;
}

.sfs-custom-gallery .sfs-gallery-loader {
    text-align: center;
}

.sfs-custom-gallery .sfs-gallery-loader img {
    padding: 60px 0;
}