/* desktop devices */
@media (min-width: 768px) {
    header {
        margin: 5px;
    }

    aside {
        margin: 5px;

        flex: 15em 0 0;
    }

    article {
        margin: 5px;
    }

    footer {
        margin: 5px;
    }

    #content {
        display: flex;
        flex-direction: row;
    }

    body {
        max-width: 100em;
    }

    .featured-art {
        height: 256px;
        width: auto;
    }

    .grid-sizer, .grid-item {
        /* Almost pixel perfect! */
        width: calc(33.33% - 7.5px);
    }

    .grid-item-wide {
        width: calc(66.667% - 7.5px);
    }

    .page-pic {
        float: right;
        margin-bottom: 10px;
        margin-left: 10px;
    }

    .art-outer {
        display: flex;
        flex-direction: row;
    }

    .art-inner {
        display: flex;
        flex-direction: column;
        flex-grow: 1;
    }

    #nav-menu > summary {
        visibility: hidden;
        height: 0;
    }
}

@media (min-width: 1100px) {
    #detail-pane {
        display: block !important;
    }

    #art-detail-inline {
        display: none;
    }
}

.gutter-sizer {
    width: 10px;
}

#detail-pane {
    display: none;
}

/* mobile devices */
@media (max-width: 768px) {
    aside div {
        padding: 2px;
    }

    aside div a {
        font-size: 135%;
        margin-top: 13px;
        margin-bottom: 13px;
    }

    header {
        margin: 5px;
    }

    aside {
        margin: 5px;
    }

    article {
        margin: 5px;
    }

    footer {
        margin: 5px;
    }

    .featured-art {
        height: auto;
        width: 100%;
    }

    .grid-sizer, .grid-item {
        width: 100%;
        height: auto;
    }

    .page-pic {
        display: none;
    }

    .site-menu > img {
        float: left;
        margin-left: 5px;
        margin-top: 10px;
        width: 25px;
        height: 25px;
    }

    #koring {
        display: none;
    }
}

body {
    background-color: var(--background-primary);
    accent-color: var(--accent-color);

    color: var(--text-color);
    font-family: sans-serif;
}


:root {
    --link: #6a3434;
    --secondary-accent: #c99192;
    --border-color: black;
    --background-primary: #ab4a2f;
    --background-secondary: #fdfdfd;
    --background-tertiary: #f0f0f0;
    --text-color: #363131;
    --link-visited: #460b0b;
    --extra-color: #efe4e4;
    --border: 3px double var(--border-color);
    --shadow: 3px 3px 0px black;
}

@media (prefers-color-scheme: dark) {
    :root {
        --link: #a3c3ff;
        --secondary-accent: #c99192;
        --background-primary: #34313a;
        --background-secondary: #3c3a44;
        --background-tertiary: #2e2c34;
        --border-color: #515860;
        --text-color: #fbeded;
        --link-visited: #75A6FF;
        --extra-color: #504e5a;
    }

    .external-link {
        filter: invert(100%);
    }

    .isso-thread-heading, .isso-author {
        color: #fbeded !important;
    }

    .symbolic-icon {
        filter: invert(100%);
    }
}

/* printers */
@media print {
    :root {
        --link: blue;
        --secondary-accent: #c99192;
        --border-color: black;
        --background-primary: #fff !important;
        --background-secondary: #fdfdfd;
        --background-tertiary: #f0f0f0;
        --text-color: #222;
        --link-visited: #460b0b;
        --extra-color: #efe4e4;
        --border: 0px single transparent;
        --shadow: 0px 0px 0px transparent;
    }

    aside {
        visibility: hidden;
        height: 0 !important;
        padding: 0 !important;
    }

    @page {
        margin: 0.5in;
    }

    h1, h2, h3, h4, h5, h6 {
        page-break-after: avoid !important;
    }

    p, li, blockquote, figure, img {
        page-break-inside: avoid !important;
    }

    #content {
        display: block !important;
    }

    .breadcrumbs {
        visibility: hidden;
        height: 0;
    }

    header {
        visibility: hidden;
        height: 0;
    }

    .external-link {
        visibility: hidden;
        width: 0;
    }

    footer {
        visibility: hidden;
        height: 0;
        padding: 0 !important;
    }

    .header-link {
        visibility: hidden;
        height: 0;
    }

    details {
        visibility: hidden;
        height: 0;
    }

    .voting-container {
        visibility: hidden;
        height: 0;
    }
}

a:link {
    color: var(--link);
}

a:visited {
    color: var(--link-visited);
}

header {
    flex-grow: 1;
    flex-basis: 100%;
    color: var(--background-secondary);
}

header img {
    height: 3em;
    width: auto;
    vertical-align: middle;
    box-shadow: var(--shadow);
    border: var(--border);
    background-color: var(--background-secondary);
}

header h1 {
    display: inline;
    vertical-align: middle;
    margin-left: 0.25em;
}

@media (prefers-color-scheme: dark) {
    header h1 {
        color: white;
    }
}

aside {
    background-color: var(--background-secondary);

    text-align: center;

    border: var(--border);
    box-shadow: var(--shadow);
    border-radius: 3px;
    padding: 15px;
}

article {
    background-color: var(--background-secondary);

    border: var(--border);
    border-radius: 3px;
    box-shadow: var(--shadow);

    padding: 15px;

    min-width: 0;
    flex: 1 1 auto;
}

footer {
    background-color: var(--background-secondary);

    flex-grow: 1;
    flex-basis: 100%;

    border: var(--border);
    border-radius: 3px;
    box-shadow: var(--shadow);

    padding: 15px;
}

.site-menu {
    width: 100%;
    border: 1px solid gray;
    border-radius: 5px;
    margin-top: 5px;
    margin-bottom: 5px;
}

.gallery-img {
    border: 1px inset black;
    border-radius: 5px;
}

.article-img {
    max-width: 100%;
    max-height: 100%;
    height: auto;
}

.actual-article-img {
    max-width: 50%;
    max-height: 100%;
    height: auto;
}

figure {
    flex-grow: 1;
    text-align: center;
    margin: 25px;
}

figure figcaption {
    text-align: center;
}

.gallery-con {
    border: 1px dashed gray;
    border-radius: 5px;
    background-color: var(--background-tertiary);
    padding: 20px;
}

.generic-con {
    border: 1px dashed gray;
    border-radius: 5px;
    background-color: var(--background-tertiary);

    padding: 20px;
}

.year-con {
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
}

.year-con > a:last-child {
    margin-right: 20px;
}

.year-con > a:not(:last-child) {
    margin-right: 5px;
}

.grid-container {
    background-color: var(--background-tertiary);
    margin: -15px;
    margin-top: 20px;
    margin-bottom: 20px;
    padding: 15px;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.grid-item {
    border: 1px solid var(--border-color);
    border-radius: 3px;
    background-color: var(--background-secondary);
    margin-bottom: 8px;
    padding-bottom: 5px;
}

.grid-item > picture > img {
    border-bottom: 1px solid var(--border-color);
}

.grid-item span {
    padding: 10px;
    color: var(--text-color);
}

.grid {
    padding: 0;
    margin: 0;
}

td {
    text-align: center;
}

tr:nth-child(even) {
    background-color: var(--extra-color) !important;
}

tbody > tr {
    background-color: var(--background-secondary);
}

table {
    width: 100%;
    border: 1px solid black;
    border-radius: 3px;
    background-color: var(--background-tertiary);
}

td {
    border: 1px inset black;
}

#f-badges {
    text-align: center;
}

#f-badges * {
    display: inline;
    margin-left: 0.2em;
    margin-right: 0.2em;
}

.f-list {
    text-align: center;
}

h2 {
    margin-top: 0.2em;
    margin-bottom: 0.2em;
}

iframe {
    border: 1px solid gray;
}

hr {
    background-color: var(--border-color);
    height: 1px;
    border: 0;
}

:not(pre) > code {
    white-space: pre-wrap;
    background-color: var(--background-tertiary);
    border-radius: 5px;
    padding: 3px;
}

pre {
    padding: 5px;
    border-radius: 5px;
}

.buttons {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    margin: auto;
}

.blurb {
    border: 1px solid gray;
    border-radius: 3px;

    margin: .5em;

    box-shadow: var(--shadow);

    display: flex;
    flex-direction: column;
}

.blurb-button {
    padding: 1em;
    border-radius: 7px;
    margin: 0.5em;
    text-decoration: none;
}

.blurb-button:hover {
    background-color: #eaeaea;
}

.blurb-button h4, .blurb h4 {
    margin: 0 0 3px;
}


.buttons {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    margin: auto;
}

.nice-list {
    display: inline;
    list-style: none;
    margin-bottom: 0;
    margin-top: 0;
    padding: 0.5em;
}

.nice-list li {
    display: inline-block;
    margin-right: 5px;
}

.toot-header .toot-profile img {
    border-radius: 9999px;
    width: 48px;
    height: auto;
}

.toot-blockquote {
    line-height: 1.35em;
    margin: 1.5rem auto;
    padding: 1rem;
    border: 2px solid gray;
    border-radius: 12px;
}

.toot-header .toot-author {
    display: flex;
    flex-direction: column;
    flex-grow: 1;

    margin-left: 10px;
    margin-top: 3px;
}

.toot-header .toot-author .toot-author-name {
    font-weight: 700;
}

.toot-header .toot-author .toot-author-handle {
    line-height: 1;
}

.toot-header {
    display: flex;
}

.nice-list li:not(:last-child):not(:only-child)::after {
    content: "·";
    margin-left: 5px;
}

#about-pic {
    float: left;
    margin: 10px;
    border: 1px inset black;
}

.external-link {
    vertical-align: sub;
    margin-left: 2px;
}

.art-button-container {
    display: flex;
    flex-flow: row;
    gap: 10px;
    margin-bottom: 10px;
}

.art-button {
    width: 100%;
    height: 50px;
    line-height: 50px;
    text-align: center;
    border: 1px outset black;
    border-radius: 5px;
    margin-top: 10px;
    background-color: var(--extra-color);
    color: var(--text-color) !important;
    text-decoration: none;
}

.new-banner {
    border: 1px outset black;
    border-radius: 5px;
    padding: 5px;
    text-align: center;
    margin: 10px;
}

.no-decoration {
    text-decoration: none;
}

.banner-alert-icon {
    vertical-align: middle;
    margin-left: 5px;
    margin-right: 5px;
}

model-viewer {
    height: 600px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
}

.page-pic {
    width: 200px;
    height: 200px;
}

.project-header {
    margin: 0;
    padding: 0.5em;
    background-color: var(--background-tertiary);
    background-image: repeating-linear-gradient(-45deg, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.1) 25%, transparent 25%, transparent 25%, rgba(0, 0, 0, 0.01) 50%);
    background-size: 24px 24px;
    border-bottom: 1px solid var(--border-color);
    font-weight: bold;
    color: white;
}

.project-desc {
    padding-left: 0.5em;
    padding-right: 0.5em;
    flex-grow: 1;
}

.threejs-canvas canvas {
    width: 50%;
    margin-left: auto;
    margin-right: auto;
}

.voting-container {
    width: 100px;
    margin-top: 20px;
    margin-bottom: 20px;
    margin-left: auto;
    margin-right: auto;
}

.voting-button {
    display: block;
    margin-left: auto;
    margin-right: auto;
    font-size: 20pt;
}

.add {
    padding: 0.2em;
    border-radius: 7px;
    display: inline-block;
}

.add-bugfix {
    background-color: #e16060;
}

.add-feature {
    background-color: #45a83d;
    color: black;
}

.add-testing {
    background-color: #3d99a8;
    color: black;
}

.add-release {
    background-color: #65bbdd;
}

.add-nlnet {
    background-color: #8dce19;
}

.toot-card-image-image {
    width: 50%;
}

.page-item {
     display: inline-block;
     padding: 5px;
}

.active {
    background-color: var(--background-tertiary);
    border-radius: 2px;
}

.disabled {
    background-color: var(--background-tertiary);
    border-radius: 2px;
}

.page-item:not(.disabled):not(.active) {
    background-color: var(--extra-color);
    border: 1px solid gray;
    border-radius: 2px;

    a {
        color: var(--text-color);
        text-decoration: none;
    }
}

.pagination {
    text-align: center;
    padding-left: 0;
}

.character {
    display: inline-block;
    text-align: center;
}

.character span {
    display: block;
}

.gallery-type-icon-hidden {
    visibility: hidden;
}

#koring {
        table {
            width: 500px;
            margin: auto;
        }
}

.site-menu > img {
    float: left;
    margin-left: 5px;
    margin-top: 2px;
}

.pagination > .page-item {
    margin-left: 5px;
}

.pagination > .page-item:nth-child(-n+1) {
    float: left;
}

.pagination > .page-item:nth-last-child(-n+1) {
    float: right;
}

.art-fancy-button {
    margin: 5px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    display: inline-grid;
    text-decoration: none;
    background-color: var(--background-tertiary);
    box-shadow: var(--shadow);

    p {
        margin: 0;
        color: var(--text-color);
        padding: 5px;
    }

    img {
        border: 1px solid var(--border-color);
        width: 100%;
        margin: -1px;
        height: auto;
    }
}

.art-sidebar-button {
    display: block;
    width: 240px;
    height: 50px;
    line-height: 50px;
    text-align: center;
    border: 1px outset black;
    border-radius: 5px;
    background-color: var(--extra-color);
    text-decoration: none;
    color: var(--text-color) !important;
    margin-bottom: 10px;
}

#art-button-main-container {
    display: grid;
    justify-items: center;
}

@media (min-width: 1200px) {
    #art-button-main-container {
        grid-template-columns: 50% 50%;
    }
}

.project-maintainer {
    background-color: #844e4e;
}

.project-contribution {
    background-color: #586449;
}
