@import url('https://fonts.googleapis.com/css?family=Lato');
@import url('https://fonts.googleapis.com/css?family=Raleway');

/* See https://github.com/jonathantneal/MediaClass to apply styles to captions based on their size, for example to
 * reduce the font size in smaller images or increase it in very large ones.
 *
 * Several attributes are given !important to attempt to ensure a consistent display across as many WordPress themes
 * as possible. Theme CSS may reference the content area by '#id p' which will interfere with our styling. This means
 * some attributes may require !important in users custom CSS when attempting to tweak these defaults.
 */

figure.ngg-figure {
    overflow: hidden;
    position: relative;
    margin: 0;
    padding: 0;
    -webkit-transform-style: preserve-3d;
    -moz-transform-style: preserve-3d;
    transform-style: preserve-3d;
}

figure.ngg-figure:hover figcaption.ngg-figcaption {
    -ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=100);
    filter: alpha(opacity=100);
    opacity: 1;
    top: 0;
    left: 0;
}

figcaption.ngg-figcaption {
    -ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=0);
    filter: alpha(opacity=0);
    opacity: 0;
    position: absolute;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, .7);
    color: #fff;
    -webkit-transition-delay: .1s;
    -moz-transition-delay: .1s;
    -o-transition-delay: .1s;
    -ms-transition-delay: .1s;
    transition-delay: .1s;
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
    -webkit-justify-content: center;
    -ms-flex-pack: center;
    justify-content: center;
    -webkit-align-items: center;
    -ms-flex-align: center;
    align-items: center;
    -ms-flex-direction: column;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-backface-visibility: hidden;
    -moz-backface-visibility: hidden;
    backface-visibility: hidden;
}

figcaption.ngg-figcaption h6 {
    margin: 0 !important;
    padding: 10px 16px 10px 16px !important;
    text-align: center;
    color: white;
    line-height: 1em;
    font-family: Lato, sans-serif;
    font-size: 14px;
    max-width: -webkit-calc(100% - 32px);
    max-width: calc(100% - 32px);
    max-height: -webkit-calc(100% - 32px);
    max-height: calc(100% - 32px);
    white-space: normal;
    text-transform: none;
    word-break: break-all;
}

figure.nggc_no_sharing figcaption.ngg-figcaption h6 {
    padding-top: 0 !important;
}

figure.nggc_no_sharing.nggc_no_description.nggc_no_title figcaption.ngg-figcaption h6 {
    margin-top: 0 !important;
}

figure.nggc_no_description figcaption.ngg-figcaption h6 {
    padding: 10px 16px 0 16px !important;
}

figure.ngg-figure .nggc-body p {
    margin: 0 !important;
    padding: 0 !important;
    line-height: 14px !important;
    font-size: 14px !important;
    height: 100% !important;
}

figcaption.ngg-figcaption .nggc-body {
    margin: 0 !important;
    padding: 0 !important;
    line-height: 14px !important;
    font-size: 14px !important;
    overflow: hidden !important;
    text-align: center;
    color: white;
    font-family: Lato, sans-serif;
    max-height: -webkit-calc(100% - 110px);
    max-height: calc(100% - 110px);
    max-width: -webkit-calc(100% - 34px);
    max-width: calc(100% - 34px);
    white-space: normal;
}

figure.nggc-ie9.nggc_no_sharing figcaption.ngg-figcaption h6 {
    padding-top: 16px;
}

figure.nggc-ie9 figcaption.ngg-figcaption .nggc-body {
    margin: 0 auto !important;
}

figure.nggc-ie9.nggc_no_title.nggc_no_sharing .nggc-body {
    margin: 16px auto !important;
}

figure.nggc_no_title .nggc-icon-wrapper {
    margin-bottom: 10px;
}

figure.nggc_no_title figcaption.ngg-figcaption .nggc-body {
    max-height: -webkit-calc(100% - 60px);
    max-height: calc(100% - 60px);
}

figure.nggc_no_sharing figcaption.ngg-figcaption .nggc-body {
    max-height: -webkit-calc(100% - 60px);
    max-height: calc(100% - 60px);
}

.nggc-icon-wrapper {
    font-size: 26px !important;
    line-height: 27px !important;
    padding: 0 6px 0 6px;
    text-align: center;
    margin: 4px 0 0 0;
    height: 27px;
}

/* For why .front-page .content .fa is here see: https://imagely.myjetbrains.com/youtrack/issue/NGGPro-471 */
/* NGGPro-471 is also why the following share icon color's are given !important                            */
.front-page .content .nggc-icon-wrapper svg,
.front-page .content .nggc-icon-wrapper i,
.nggc-icon-wrapper svg,
.nggc-icon-wrapper i {
    padding: 0 0 0 6px;
    color: #b5b5b5;
    border-radius: initial;
    display: inline;
    width: inherit;
    background-color: initial;
    margin: 0;
}

.nggc-icon-wrapper svg:first-of-type,
.nggc-icon-wrapper i:first-of-type {
    padding-left: 0;
}

.nggc-icon-wrapper svg.fa-twitter-square,
.nggc-icon-wrapper i.fa-twitter-square {
    color: #4099FF !important;
}

.nggc-icon-wrapper svg.fa-facebook-square,
.nggc-icon-wrapper i.fa-facebook-square {
    color: #3B5998 !important;
}

.nggc-icon-wrapper svg.fa-pinterest-square,
.nggc-icon-wrapper i.fa-pinterest-square {
    color: #cb2027 !important;
}

.nggc-icon-wrapper svg.fa-google-plus-square,
.nggc-icon-wrapper i.fa-google-plus-square {
    color: #dd4b39 !important;
}

.nggc-icon-wrapper svg.fa-shopping-cart,
.nggc-icon-wrapper i.fa-shopping-cart {
}

.nggc-icon-wrapper svg.fa-star,
.nggc-icon-wrapper i.fa-star {
}

.ngg-caption-icon:hover {
    opacity: 0.7;
}

figcaption.ngg-figcaption-plain {
    background: rgba(0, 0, 0, 0);
}

figcaption.ngg-figcaption-fade {
    -webkit-transition: opacity .3s ease-in;
    -moz-transition: opacity .3s ease-in;
    -o-transition: opacity .3s ease-in;
    -ms-transition: opacity .3s ease-in;
    transition: opacity .3s ease-in;
}

figcaption.ngg-figcaption-slideup {
    top: 100%;
    -webkit-transition: all .3s ease;
    -moz-transition: all .3s ease;
    -o-transition: all .3s ease;
    -ms-transition: all .3s ease;
    transition: all .3s ease;
}

figcaption.ngg-figcaption-slideright {
    left: -100%;
    -webkit-transition: all .3s ease;
    -moz-transition: all .3s ease;
    -o-transition: all .3s ease;
    -ms-transition: all .3s ease;
    transition: all .3s ease;
}

figcaption.ngg-figcaption-slidedown {
    top:  -100%;
    -webkit-transition: all .3s ease;
    -moz-transition: all .3s ease;
    -o-transition: all .3s ease;
    -ms-transition: all .3s ease;
    transition: all .3s ease;
}

figcaption.ngg-figcaption-slideleft {
    left:  100%;
    -webkit-transition: all .3s ease;
    -moz-transition: all .3s ease;
    -o-transition: all .3s ease;
    -ms-transition: all .3s ease;
    transition: all .3s ease;
}

/** It's all titlebar from here down */
figure.nggc-ie9 figcaption.ngg-figcaption-titlebar {
    padding: 0;
}

figure.ngg-figure:hover figcaption.ngg-figcaption-titlebar {
    transform: translate3d(0, 0, 0);
    -webkit-transform: translate3d(0, 0, 0);
}

figcaption.ngg-figcaption-titlebar .nggc-icon-wrapper {
    background-color: rgba(0, 0, 0, 0.9);
    color: white;
    float: right;
    padding: 6px 16px 7px 5px;
    line-height: 0.44em;
    margin: 0;
}

figcaption.ngg-figcaption-titlebar .nggc-body {
    margin: 0 auto !important;
    color: white;
    text-shadow: 1px 1px 2px #000;
    height: -webkit-calc(100% - 59px);
    height: calc(100% - 59px);
    max-height: -webkit-calc(100% - 59px);
    max-height: calc(100% - 59px);
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
    -webkit-justify-content: center;
    -ms-flex-pack: center;
    justify-content: center;
    -webkit-align-items: center;
    -ms-flex-align: center;
    align-items: center;
}

figure.nggc-ie10 figcaption.ngg-figcaption-titlebar .nggc-body {
    display: inline-block !important;
}

figcaption.ngg-figcaption-titlebar h6 {
    background-color: rgba(0, 0, 0, 0.9) !important;
    height: 39px !important;
    min-height: 39px !important;
    max-height: 39px !important;
    padding-top: 11px !important;
    padding-left: 16px !important;
    text-align: left;
    clear: none;
    box-sizing: border-box;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
    max-width: -webkit-calc(100% - 128px);
    max-width: calc(100% - 128px);
}

figure.nggc_no_sharing figcaption.ngg-figcaption-titlebar h6 {
    padding-top: 11px !important;
    max-width: 100%;
}

figure.nggc_no_description figcaption.ngg-figcaption-titlebar h6 {
    padding-bottom: 11px !important;
}

figure.ngg-figure.nggc_no_title.ngg-figure-titlebar .nggc-icon-wrapper {
    float: none;
    text-align: right;
}

figcaption.ngg-figcaption-titlebar {
    transform: translate3d(0, -125%, 0);
    -webkit-transform: translate3d(0, 100%, 0);
    -webkit-transition: -webkit-transform .35s linear;
    -moz-transition: transform .3s linear;
    -o-transition: transform .3s linear;
    -ms-transition: transform .3s linear;
    transition: all .3s linear;
    top: -125%;
    -ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=100);
    filter: alpha(opacity=100);
    background: rgba(0, 0, 0, 0);
    display: block;
    justify-content: center;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.6);
}

figure.ngg-figure figcaption.ngg-figcaption-titlebar .nggc-body p {
    height: auto !important;
}

figure.ngg-figure:hover figcaption.ngg-figcaption-titlebar .nggc-icon-wrapper i:nth-child(2) {
    transition: transform 0.35s;
    transition-delay: 0.1s;
    -webkit-transition-delay: 0.1s;
}
figure.ngg-figure:hover figcaption.ngg-figcaption-titlebar .nggc-icon-wrapper i:nth-child(3) {
    transition-delay: 0.3s;
    -webkit-transition-delay: 0.3s;
}
figure.ngg-figure:hover figcaption.ngg-figcaption-titlebar .nggc-icon-wrapper i:nth-child(4) {
    transition-delay: 0.5s;
    -webkit-transition-delay: 0.5s;
}

/* A few NextGen Pro display type specific overrides */
div.nextgen_pro_blog_gallery figure.ngg-figure {
    text-align: center;
    margin: 0 auto;
}
div.ngg-pro-album.nextgen_pro_list_album figure.ngg-figure {
    float: left;
    margin-right: 20px;
}

div.nextgen_pro_blog_gallery figure.ngg-figure img {
    margin: 0 !important;
}

div.nextgen_pro_film figure.ngg-figure {
    margin: 0 auto;
}

div.nextgen_pro_blog_gallery figure.ngg-figure img,
div.nextgen_pro_thumbnail_grid figure.ngg-figure img {
    box-sizing: border-box !important;
}
