
/* ---------------------------------------------------- sticky & fix layers */

body > div,
body > footer { position: relative; z-index: 2; }

.sticky-container {
    z-index: 0;
    position: sticky;
    bottom: 0;

    height: 100vh;  /* set to end sticking position  */
}

.sticky-blocker {  /* block container when sticking */
    z-index: 1;
    position: sticky;
    bottom: 0;
    height: 100vh;
    margin-top: -100vh;

    background: #fff;  /* set to upper layer background  */
}

.sticky-blocker {
    box-shadow: 0 50px 80px rgba(0, 0, 0, .4);
}

/* ---------------------------------------------------- fullscreen viewer */

.fullscreen-viewer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    text-align: center;
    background-color: rgba(30,30,30,.8);
    background-position: center;
    background-origin: content-box;
    background-repeat: no-repeat;
    background-size: contain;
    /* padding: 6.6rem 0 3rem 0; */
}

.fullscreen-viewer .info {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 1;
    padding: 2em;
    padding-bottom: 3em;
    background: rgba(0, 0, 0, .5);
    font-size: .8em;
    color: white;
}

.fullscreen-viewer .info .data {
    width: 100%;
    max-width: 40em;
    text-align: left;
    display: inline-block;
}

.fullscreen-viewer .link {
    float: right;
    text-decoration: underline;
}

/* ---------------------------------------------------- fullscreen viewer transitions */

.fullscreen-viewer {
    transition: .4s;

    opacity: 0;
    pointer-events: none;
}

body[data-fs-viewer=true] .fullscreen-viewer {
    opacity: 1;
    pointer-events: all;
}

.fullscreen-viewer .info {
    display: none;
}

.fullscreen-viewer .info:not([data-url=false]) {
    display: block;
}

.fullscreen-viewer .info:not([data-loaded=true]) {
    cursor: wait;
}

/* ---------------------------------------------------- layout */

.layout-container {
    margin: auto .2rem;
    margin-top: -.2rem;
}

.layout-container .item {
    min-width: 10rem;
    width: 100%;
    padding: .2rem;
}

@media (min-width: 600px)  { .layout-container .item { width: 49.95%; }}
@media (min-width: 960px)  { .layout-container .item { width: 33.3%; }}
@media (min-width: 1280px) { .layout-container .item { width: 24.975%; }}

.load-more {
    font-size: 1.8em;
    display: inline-block;
    padding: 2rem;
    width: 100%;
    margin: auto;
    margin-top: 5rem;
}

/* ---------------------------------------------------- layout transitions */

.layout-container ,
.layout-container .item a,
.layout-container .item img { transition: .4s; }

.layout-container {
    filter: blur(0px);
}

body[data-fs-viewer=true] .layout-container {
    filter: blur(5px);
}

.layout-container .item a {
    filter: grayscale(100%) brightness(1.5) contrast(0.9);
}

.layout-container .item a:hover {
    filter: grayscale(0%) brightness(1) contrast(1);
}

.layout-container .item .loading { opacity: 0; }
