html {
    font-family: "Funnel Display", sans-serif;
    background-color: #282a36;
    color: #f8f8f2;
    display: flex;
    align-items: center;
    justify-content: center;
    scrollbar-gutter: stable;
}

body {
    margin: 0;
    padding: 0;
}

h3.year-divider {
    border-bottom: 2px dashed #516087;
    margin-top: 0px;
}

/* Links */

div.header-home {
    display: flex;
    align-items: baseline;
    gap: 1.5em;
    padding: 0;
}

div.header-home a {
    color: #f8f8f2;
    text-decoration: none;
}

div.header-home a:hover {
    text-decoration: underline;
}

div.header-home a:first-child {
    margin-right: auto;
}

a.header-home h2 {
    margin-top: 1em;
}

div.header-home h1,
div.header-home h2 {
    margin-top: 1em;
}

a {
    color: #ff79c6;
}

/* Article metadata */
.article-metadata {
    color: #bcbcb8;
    font-size: 0.8em;
}

.article-metadata p {
    margin: 0;
    padding: 0;
}

section.article-metadata a {
    color: #bcbcb8;
    text-decoration: underline;
}

article {
    display: flex;
    flex-direction: column;
    max-width: 48em;
    width: 48em;
}

article.blog-body {
    border: 2px solid #44475a;
    background: #44475a;
    border-radius: 10px;
    padding: 0.4em;
}

article.article-references {
    border: 2px dashed #6272a4;
    border-radius: 4px;
    margin-top: 1em;
    width: 100%;
    padding: 0.4em;
}

article.article-references ol {
    margin-top: 0.5em;
}

/* Article headers */

article.article-references h3 {
    margin-bottom: 0;
    padding: 0.4em;
    margin-top: 0.2em;
    margin-top: 0;
    padding-top: 0;
}

article h2.article-title {
    margin-top: 0;
    color: #f8f8f2;
}

article h2 {
    margin-top: 0.5em;
    margin-bottom: 0.5em;
    color: #a983de;
}

article h3 {
    font-size: 1.2em;
}

article section div.article-summary {
    background-color: #44475a;
    border-radius: 10px;
    padding: 0.5em;
    padding-bottom: 0;
    padding-top: 0;
}

article section div p.article-summary-title {
    padding: 0;
    margin: 0;
    margin-bottom: 0.2em;
}

article section div p.article-category-url {
    padding-bottom: 1em;
}

article section div p.article-summary-text {
    margin-top: 0;
}

/* Table styiling */
/*table {
    border-collapse: collapse;
    border: 2px solid rgb(140 140 140);
    font-family: sans-serif;
    font-size: 0.8rem;
    letter-spacing: 1px;
}*/
table {
    overflow: auto;
    width: 100%;
    max-width: 400px;
    display: block;
    margin: 0 auto;
    border-spacing: 0;
    font-size: 0.8rem;
}

table caption {
    caption-side: bottom;
    padding: 10px;
    font-weight: bold;
}

thead,
tfoot {
    background-color: #6272a4;
}

th,
td {
    border: 1px solid rgb(160 160 160);
    padding: 8px 10px;
}

td:last-of-type {
    text-align: center;
}

tbody > tr:nth-of-type(even) {
    background-color: #696d8d;
}

tfoot th {
    text-align: right;
}

tfoot td {
    font-weight: bold;
}

/* Footer styling */

footer {
    justify-self: center;
    width: 48em;
    max-width: 48em;
    display: flex;
    flex-direction: row;
    margin-top: 1.5em;
    border-top: 2px solid #6272a4;
}

footer.blog-footer {
    position: absolute;
    left: 0;
    right: 0;
    /*bottom: 0;*/
    z-index: 2;
}

span.footer-row {
    display: flex;
}

span.footer-row p {
    padding: 10px;
}

/*Blog article image styling*/
figure {
    width: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

figure img {
    margin: 1em;
    margin-top: 0;
    margin-bottom: 0;
    max-width: 90%;
    max-height: 40em;
    border: 3px dashed #6272a4;
    border-radius: 4px;
}

figure video {
    margin: 1em;
    max-width: 90%;
    max-height: 40em;
    border: 3px dashed #6272a4;
    border-radius: 4px;
}

/* Quote styling */

blockquote {
    border-left: 2px solid #f8f8f2;
    padding-left: 0.6em;
}

/* Code styling */

pre {
    margin: 0;
}

code.multi-line-code {
    tab-size: 4;
    -moz-tab-size: 4;
    margin-top: 15px;
    margin-bottom: 15px;
    padding: 10px;
    background-color: #282a36;
    color: #f8f8f2;
    display: block;
    border-radius: 10px;
    overflow-x: auto;
    white-space: pre-wrap;
}

code.inline-code {
    padding: 4px;
    background-color: #282a36;
    color: #f8f8f2;
    border-radius: 6px;
}

/* Admonitions */
div.admonition-tip {
    margin: 3em;
    margin-top: 0;
    margin-bottom: 0;
}

div.admonition-tip h3 {
    margin: 0;
    display: block;
    background-color: #bd93f9;
    padding: 0.5em;
    border-top-left-radius: 6px;
    border-top-right-radius: 6px;
}

div.admonition-tip section {
    padding: 0.5em;
    border: 2px dashed #bd93f9;
    border-top: none;
    border-radius: 6px;
    border-top-left-radius: unset;
    border-top-right-radius: unset;
}

@media screen and (max-width: 820px) {
    body {
        padding: 1em;
    }

    article,
    article.blog-body {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    div.admonition-tip {
        margin: 1.5em 0;
    }

    figure img,
    figure video {
        max-width: 100%;
        margin: 1em 0;
        box-sizing: border-box;
    }

    code.multi-line-code {
        white-space: pre-wrap !important;
        word-break: break-all !important;
        overflow-wrap: anywhere !important;
    }

    article,
    article *,
    div,
    pre {
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
    }
}

@media screen and (max-width: 520px) {
    div.header-home {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5em;
    }

    div.header-home h1 {
        margin-bottom: 0.2em;
    }

    div.header-home h2 {
        margin-bottom: 0.2em;
        margin-top: 0.2em;
    }

    article.blog-body {
        margin-top: 1em;
    }

    footer {
        font-size: 0.8em;
    }
}
