:root {
    --text: #444;
    --muted: #777;
    --rule: #aaa;
}

* {
    box-sizing: border-box;
}

html {
    scrollbar-gutter: stable;
}

body {
    margin: 0;
    height: 100vh;
    color: var(--text);
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.page {
    max-width: 100rem;
    margin: 0 auto;
    padding: 2.5rem 1.5rem;
}

/* Navigation */
nav {

    font-size: 0.9em;

    &.nav-primary {
        display: flex;
        justify-content: space-between;
        gap: 4rem;
        margin-bottom: 1.5rem;
    }

    &.nav-footer ul {
        display: flex;
        justify-content: space-between;
        padding: 0;
        margin: 0;
        list-style: none;

        li {
            margin: 0;
            padding: 0;
        }
    }
}

hr {
    margin: 1rem 0;
}

/* Article list */
ol.article-list {
    list-style: none;
    padding: 0;
    margin: 0;

    li {
        margin: 0.25rem 0;

        article {
            display: flex;
            justify-content: space-between;
            align-items: flex-start;
            gap: 1rem;

            footer {
                margin: 0;

                time {
                    color: var(--muted);
                    font-size: 0.9em;
                    white-space: nowrap;
                }
            }
        }
    }
}

pre {
    overflow-x: auto;
    font-family: monospace;
}

p {
    code {
        display: inline-block;
        font-family: monospace;
    }
}

/* Footer */
.page > footer {
    margin-top: 1.5rem;

    .footer-links {
        display: flex;
        justify-content: space-between;
    }
}

/* Small screens */
@media (max-width: 600px) {
    .article-list article footer {
        display: none;
    }

    nav {
        gap: 24px;
    }
}
