/* definitions for the entire site */
html {
    -webkit-text-size-adjust: 100%; /* Prevent font scaling in landscape while allowing user zoom */
    background-image: url(image/decoration/warpedforestpainting.png);
    background-size: 100%;
    background-repeat: repeat-y;
    background-attachment: fixed;
}

body {
    --aux-background: #30072B;
    --book-background: #fffaef;
    --itemframe-background: #834829;

    --aux-text: #9ABBC1;
    --book-text: black;
    --itemframe-text: #f0f0ff;

    --aux-anchor: #e9b24c;
    --book-anchor: #501105;
    --itemframe-anchor: #8dd7ff;

    --book-border: #853f2a;
    --itemframe-border: #312c28;

    font-family: Ubuntu, 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
}

/* re-used elements */
a {
    color: var(--book-anchor);
    text-decoration: underline;
}
a:hover {
    text-decoration: none;
}
figure {
    margin: 0;
}
h1, h2, h3, h4, h5, h6 {
    font-family: Minecraft, Impact, Haettenschweiler, 'Arial Narrow Bold', sans-serif;
}
h2 img, h4 img {
    height: 1em;
    width: auto;
}
img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
}
ol li {
    margin-bottom: 1em;
}

/*classes*/
.card {
    background-color: var(--itemframe-background);
    color: var(--itemframe-text);
    padding: .5em;
    margin: .5em;
    display: inline-block;
    border: outset .3em var(--itemframe-border);
}
.card a {
    color: var(--itemframe-anchor);
}
.card h1, .card h2, .card h3, .card h4, .card h5, .card h6 {
    margin-top: 0;
}
.card img {
    height: 20em;
}
.card .top img {
    height: 2em;
    width: auto;
}
.card td {
    text-align: right;
}
.card th {
    text-align: left;
    border-right: solid 1em var(--itemframe-background);
}
.card .top {
    display: grid;
    grid-template-columns: 50% 50%;
}
.card-image-list {
    text-align: right;
}

.columned {
    columns: 2;
}

.credit {
    font-size: small;
    font-style: italic;
}

.image-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    background-color: var(--itemframe-background);
    border: inset .5em var(--itemframe-border);
    border-radius: .5em;
    color: var(--itemframe-text);
    padding: .5em;
}
.image-list a {
    color: var(--itemframe-anchor);
}
.image-list figcaption {
    max-width: 420px;
}
.image-list img, .image-list model-viewer {
    min-height: 15em;
    max-height: 20em;
}

/* page sections */
header, nav, footer, main {
    border-radius: 1em;
}
header, nav, footer {
    background-color: var(--aux-background);
    color: var(--aux-text);
    padding: 0 1em;
}
header a, nav a, footer a {
    color: var(--aux-anchor);
}
header {
    text-align: center;
}
main {
    background-color: var(--book-background);
    background-image: url(image/decoration/binding.svg);
    padding: 1em;
    color: var(--book-text);
    background-size: 1em;
    background-repeat: repeat-y;
    padding-left: 1.5em;
    border: outset .5em var(--book-border);
    border-radius: .5em;
}
/* nav */
nav ul {
    list-style-type: none;
    padding: 0;
}
nav li {
    margin-bottom: .5em;
}

/* medium screens */
@media only screen and (min-width: 600px) {
    .columned {
        columns: 3;
    }
}


/* large screens */
@media only screen and (min-width: 992px) {
    body {
        display: grid;
        grid-template-columns: 15% 5% 5% 5% 40% 5% 5% 20%;
        grid-template-rows: auto auto auto;
    }
    header {
        grid-column: 5;
        grid-row: 1;
    }
    nav {
        grid-column: 1;
        grid-row: 1 / 3;
        height: fit-content;
    }
    nav li {
        margin-bottom: 2em;
    }
    main {
        grid-column: 3 / 8;
        grid-row: 2 / 4;
        margin: 1em;
        border-radius: 1em;
        border-width: 1em;
    }
    footer {
        grid-column: 4 / 7;
        grid-row: 4;
    }

    .columned {
        columns: 4;
    }
}