/* Melon's Gallery Maker! - Mega Grid v0.2 */

a,
a:visited {
    color: #be4eff;
    text-decoration: underline;
}

a:hover {
    color: #dda3ff;
    text-decoration: none;
}

h1,
h2 {

    font-size: 0.8rem;
}

nav {
    clear: both;
}

nav ul,
nav li {
    padding: 0px 15px;
}

footer {
    clear: both;
    margin-top: 20px;
    font-size: 0.7em;
}

/* Gallery Pages */

#photos {
    display: flex;
    flex-wrap: wrap;
}

#photos a {
    display: flex;
    flex-flow: column;
}

#photos figure {
    margin: 10px;
    max-width: min-content;
}

#photos img {
    object-fit: cover;
    width: 100px;
    height: 100px;
    /* Enable this for pixel art!! */
    /* image-rendering: pixelated; */
}

#photos img:hover {
    opacity: 0.5;
}

#photos span,
#photos figcaption {
    font-size: 0.5em;
    word-break: break-all;
    max-width: 95%;
}

#photos span {
    display: block;
}

#photos figcaption {
    padding: 6px 0px;
}

.page-links ul {
    padding: 5px 5px;
    margin: 0px;
    display: inline-block;
}
.page-links li {
    list-style: none;
    display: inline;
    margin: 0px 1px;
    padding: 0px;
}

/* Mobile Styling */

@media (max-width: 800px) {
    #photos img {
        width: 100px;
        height: 100px;
    }

    #photos span,
    #photos figcaption {
        font-size: 0.8em;
    }
}

/* Styling for JavaScript viewer (if enabled) */

#js-viewer {
    position: fixed;
    top: 0px;
    left: 0px;
    width: 100%;
    height: 100%;
    background-color: #e0b1ffa0;
    display: flex;
    flex-flow: column;
    justify-content: center;
    align-items: center;
}

#js-viewer img {
    max-width: 95%;
    max-height: 80%;
    height: auto;
    width: auto;
}

#js-viewer span {
    margin-top: 10px;
}

#js-viewer span button {
    border-radius: 0px;
    border: 5px outset #520081;
    background-color: #dbcbff;
    cursor: pointer;
}

#js-viewer span button:hover {
    border: 5px inset #520081;
    background-color: #bca0ff;
}