.p-gallery,
.p-gallery * {
    position: relative;
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
}

.p-gallery {
    z-index: 9999;
    color: white;
    display: none;
}

.p-gallery,
.p-gallery-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.p-gallery-backdrop {
    z-index: 9999;
    background: rgba(0, 0, 0, 0.7);
}

.p-gallery-container {
    position: absolute;
    top: 0;
    left: 0;
    width: calc(100% - 60px);
    z-index: 10000;
    height: calc(100vh - 40px);
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-flow: column;
    flex-flow: column;
    margin: 10px 0 0 30px;
}

.p-gallery-info,
.p-gallery-content {
    -webkit-box-flex: 1;
    -ms-flex-positive: 1;
    flex-grow: 1;
}

.p-gallery-content {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
    -ms-flex-flow: row;
    flex-flow: row;
    border-radius: 3px;
    overflow: hidden;
}

.p-gallery-info {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
    -ms-flex-flow: row;
    flex-flow: row;
    -webkit-box-pack: justify;
    -ms-flex-pack: justify;
    justify-content: space-between;
    min-height: 40px;
    max-height: 40px;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
}

.p-gallery-title,
.p-gallery-close {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
}

.p-gallery-close {
    cursor: pointer;
}

.p-gallery-title {
    display: inline-block;
    white-space: nowrap;
    -o-text-overflow: ellipsis;
    text-overflow: ellipsis;
    overflow: hidden;
    margin-right: 10px;
}

.p-gallery-images-container {
    -webkit-box-flex: 1;
    -ms-flex: 1;
    flex: 1;
    overflow: hidden;
}

.p-gallery-images-container.showing-video .move {
    width: 100px;
    color: #e4e4e4;
}

.p-gallery-images {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    white-space: nowrap;
    -webkit-transform: translate3d(0, 0px, 0px);
    transform: translate3d(0, 0px, 0px);
    -webkit-transition: -webkit-transform 400ms ease;
    transition: -webkit-transform 400ms ease;
    -o-transition: transform 400ms ease;
    transition: transform 400ms ease;
    transition: transform 400ms ease, -webkit-transform 400ms ease;
    z-index: 1;
}

.p-gallery-image {
    width: 100%;
    padding: 20px;
    height: calc(100vh - 80px);
    display: -webkit-inline-box;
    display: -ms-inline-flexbox;
    display: inline-flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    vertical-align: middle;
}

.p-gallery-image img {
    pointer-events: none;
}

.p-gallery-video iframe {
    width: calc(100% - 200px);
    height: calc(100vh - 200px);
}

.p-gallery-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    background: black;
    margin: -20px 0 0 -20px;
}

.p-gallery-thumbnails-container {
    overflow: hidden;
    overflow-y: scroll;
    display: flex;
    flex-flow: column;
    background: #f2f2f1;
 }

.p-gallery-thumbnails,
.p-gallery-videos {
    padding: 20px 4px 20px 20px;
    min-width: 150px;
    display: none;
}

.p-gallery-thumbnails.active,
.p-gallery-videos.active {
    display: block;
}

.p-gallery-thumbnails-mover {
    display: flex;
    flex-flow: row;
    flex-grow: 1;
}

.p-gallery-images-container,
.p-gallery-thumb {
    background: white;
}

.p-gallery-thumb iframe {
    pointer-events: none;
}

.p-gallery-images-container .move {
    position: absolute;
    top: 0;
    width: 50%;
    height: 100%;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    z-index: 2;
    -webkit-box-pack: start;
    -ms-flex-pack: start;
    justify-content: flex-start;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    font-size: 50px;
    padding: 40px;
    color: rgba(255,255,255,0.5);
}

.p-gallery-images-container .move:hover {
    color: black;
}

.p-gallery-images-container .prev {
    left: 0;
}

.p-gallery-images-container .next {
    right: 0;
    -webkit-box-pack: end;
    -ms-flex-pack: end;
    justify-content: flex-end;
}

.p-gallery-thumb {
    width: 100px;
    height: 100px;
    margin: 0 auto 15px auto;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    border: 2px solid #d0d0d0;
    overflow: hidden;
}

.p-gallery-thumb.active {
    border-color: #D00070;
}

.p-gallery-thumb:last-child {
    margin-bottom: 0;
}

.p-gallery img {
    max-width: 100%;
    max-height: 100%;
}

.pg-initialized {
    overflow: hidden;
}

.p-gallery-tabs {
    display: flex;
    flex-flow: row;
    align-items: center;
    background-color: #d2d2d2;
    min-height: 40px;
}

.p-gallery-tab {
    flex: 1;
    text-align: center;
    padding: 10px 0;
    color: black;
    cursor: pointer;
}

.p-gallery-tab.active,
.p-gallery-tab:hover {
    background-color: #f2f2f1;
}