:root {
    --accent: #1f5f8b;
    --content-width: 960px;
}

/* Base */

body {
    display: block;
    margin: 0;
    background: #fff;
}

/* Header */

body > header {
    background: #fff !important;
    border-bottom: 1px solid #ddd;
    padding: 0.8rem 0;
    text-align: left;
}

.site-header-inner {
    width: min(var(--content-width), calc(100% - 2rem));
    margin: 0 auto;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    box-sizing: border-box;
}

.site-identity {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    margin: 0;
    padding: 0;
}

.site-identity h1,
.site-identity .site-name {
    margin: 0;
    padding: 0;
    font-size: 1.25rem;
    line-height: 1.2;
    font-weight: 600;
}

.site-identity h1 a,
.site-identity .site-name a {
    color: inherit;
    text-decoration: none;
}

.site-role {
    margin: 0;
    padding: 0;
    color: #666;
    font-size: 0.9rem;
    line-height: 1.2;
}

/* Navigation */

.site-header-inner nav {
    flex: 0 0 auto;
    margin: 0 !important;
    padding: 0 !important;
}

.site-header-inner nav ul {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: flex-start;

    width: auto;
    margin: 0 !important;
    padding: 0 !important;

    gap: 1.5rem;
    white-space: nowrap;
}

.site-header-inner nav li {
    margin: 0 !important;
    padding: 0 !important;
    border: 0;
    background: transparent;
}

.site-header-inner nav a {
    display: inline;
    margin: 0;
    border: 0 !important;
    background: transparent !important;
    padding: 0 !important;

    color: #333 !important;
    font-size: 0.9rem;
    font-weight: 400;
    text-decoration: none !important;
}

.site-header-inner nav a:hover {
    color: #333 !important;
    text-decoration: underline !important;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.2em;
}

/* Content */

main {
    width: min(var(--content-width), calc(100% - 2rem));
    max-width: none;
    margin: 4rem auto;
    padding: 0;
    box-sizing: border-box;
}

main h1 {
    font-size: 2.6rem;
    line-height: 1.15;
}

main h2 {
    font-size: 1.7rem;
}

main.article a {
    color: var(--accent) !important;
    text-decoration: underline !important;
    text-underline-offset: 0.15em;
}

main.article a:hover {
    color: #174968 !important;
}

.external-link {
    font-size: 0.8em;
    margin-left: 0.15em;
}

/* Content links */

main a {
    color: inherit !important;
    text-decoration: none !important;
    border: 0 !important;
    background: transparent !important;
}

main a:hover {
    color: #333 !important;
    text-decoration: underline !important;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.2em;
}

/* Footer */

footer {
    width: min(var(--content-width), calc(100% - 2rem));
    max-width: none;
    margin: 5rem auto 2rem;
    border-top: 1px solid #ddd;
    padding-top: 1.5rem;
    box-sizing: border-box;
}

/* Responsive */

@media (max-width: 800px) {
    .site-header-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .site-header-inner nav {
        width: 100%;
        margin: 0 !important;
        padding: 0 !important;
    }

    .site-header-inner nav ul {
        width: 100%;
        flex-wrap: wrap;
        justify-content: flex-start;
        align-items: center;

        margin: 0 !important;
        padding: 0 !important;

        gap: 0.75rem 1.5rem;
        white-space: normal;
    }
}

@media (max-width: 600px) {
    .site-header-inner {
        width: calc(100% - 2rem);
    }

    .site-header-inner nav ul {
        gap: 0.6rem 1.2rem;
    }

    main {
        margin-top: 2.5rem;
    }

    main h1 {
        font-size: 2.2rem;
    }
}
