/* SPDX-FileCopyrightText: 2020 Grzegorz Szymaszek */
@font-face {
    font-display: swap;
    font-family: 'Go';
    font-style: normal;
    font-weight: normal;
    src: url('font_go_r.woff') format('woff');
}
@font-face {
    font-display: swap;
    font-family: 'Go';
    font-style: normal;
    font-weight: bold;
    src: url('font_go_b.woff') format('woff');
}

body {
    background: white;
    color: black;
    font-family: 'Go', sans-serif;
    line-height: 1.4142;
    margin: 0;
}
@media (prefers-color-scheme: dark) {
    body {
        background: #333333;
        color: white;
    }
}

@supports (hyphens: auto) {
    figcaption, p, ul, ol {
        hyphens: auto;
        margin: 1em 0;
        text-align: justify;
    }
}

h1 {
    border-bottom: 2px solid #afafaf;
    font-size: 2em;
}
h2 {
    font-size: 1.5em;
}
@media (prefers-color-scheme: dark) {
    h1 {border-color: #505050}
}

a {
    color: #2c575d;
    text-decoration-color: #2c575d7f;
    text-decoration-thickness: 2px;
}
a:focus, a:hover {
    color: #2a555b;
    text-decoration-color: #2a555b;
}
a:focus {
    outline: dashed;
}
@media (prefers-color-scheme: dark) {
    a {
        color: #acd7dd;
        text-decoration-color: #acd7dd7f;
    }
    a:focus, a:hover {
        color: #aad5db;
        text-decoration-color: #aad5db;
    }
}

abbr {
    text-decoration-color: #0000007f;
}
@media (prefers-color-scheme: dark) {
    abbr {
        text-decoration-color: #ffffff7f;
    }
}

address {
    font-style: normal;
}

code, pre {
    font-family: 'Go Mono', monospace;
}

.compound p {
    margin-bottom: 0;
}

.compound ul {
    margin-top: 0;
}

ul {
    list-style: url('hexagon.svg');
    padding-left: 24px;
}

header, main, section, footer {
    margin: 0 auto;
    max-width: 640px;
    min-width: 200px;
    width: 90%;
}

main.wide, section.wide {
    max-width: inherit;
    width: 100%;
}

main.wide .fill, section.wide .fill, main.wide .narrow, section.wide .narrow {
    margin: 0 auto;
    width: 90%;
}

main.wide .fill, section.wide .fill {
    max-width: 1280px;
}

main.wide .narrow, section.wide .narrow {
    max-width: 640px;
}

header img {
    display: block;
    margin: 1em auto;
}

header nav ul {
    line-height: 1em;
    padding: 0;
    text-align: center;
}

header nav ul li {
    display: inline-block;
}

@supports (display: flex) {
    body>header nav ul {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
    }

    body>header nav ul li {
        display: block;
    }
}

header nav ul li a {
    display: block;
    padding: 0.5em;
}

header nav ul li a.active {
    padding: 0.5em 0.75em;
}

a.active {
    background: #2c575d;
    background: linear-gradient(#2c575d, #2a555b);
    clip-path: polygon(95% 0%, 100% 50%, 95% 100%, 5% 100%, 0% 50%, 5% 0%);
    color: white;
    text-decoration-color: white;
}
a.active:focus {
    clip-path: none;
    outline-color: #2c575d;
}
a.active:not(:focus, :hover) {
    text-decoration: none;
}

section, footer {
    margin-top: 3em;
}

.heroes li {
    margin: 1em 0;
}

.float-right {
    float: right;
    margin-left: 1em;
}

table.horizontal tbody th {
    text-align: left;
}

.tiles-outer {
    /*background: #2c575d20;*/
}

.tiles {
    list-style: none;
    padding: 0;
    text-align: center;
}

.tiles li {
    display: block;
    margin: 2em 0;
}
.tiles li:first-child {margin-top: 0}
.tiles li:last-child {margin-bottom: 0}

.tiles figure {
    margin: 0;
}

.tiles figcaption {
    background: #d4d4d4;
    hyphens: manual;
    padding: 0.5em;
    text-align: center;
}
@media (prefers-color-scheme: dark) {
    .tiles figcaption {background: #2b2b2b}
}

.tiles img {
    height: auto;
    margin-top: 1em;
    max-height: 160px;
    max-width: 100%;
    max-width: min(100%, 320px);
}
@media (prefers-color-scheme: dark) {
    .tiles img.needs-white-bg {background: white}
}

@supports (display: grid) {
    @media (min-width: 640px) {
        .tiles {
            align-items: baseline;
            display: grid;
            grid-gap: 2em 1em;
            grid-template-columns: 1fr 1fr;
        }

        .tiles li {
            margin: 0;
        }
    }

    @media (min-width: 880px) {
        .tiles {
            grid-template-columns: 1fr 1fr 1fr;
        }
    }

    @media (min-width: 1120px) {
        .tiles {
            grid-template-columns: 1fr 1fr 1fr 1fr;
        }
    }
}

footer {
    color: #505050;
    font-size: small;
}
@media (prefers-color-scheme: dark) {
    footer {color: #afafaf}
}

footer p {
    text-align: center;
}
