:root {
    --site-bg: url("/images/back.jpg");
    --accent-color: #f55cc0;
    --select-color: #ffc1e9;
    --link-color: #5083C1;
    --bg-color: #CEEAFF;
    --text-color: #191919;
    --bg-color2: white;
    --border-color: #215697;
    --special-text-color: #215697;
    --post-header-color: white;
    --post-shadow-color: #21569760;
    --outline-color: #6EAAD6;
    --outline-color2: #CEEAFF;
}

* {
    box-sizing: border-box;
    font-family: 'Space Mono', 'Courier New', monospace;
}

@-moz-document url-prefix() {
    * {
        scrollbar-width: thin;
        scrollbar-color: var(--accent-color) #00000000;
    }
}

::-webkit-scrollbar {
    height: 8px;
    width: 8px;
    background: #00000000;
}

::-webkit-scrollbar-thumb {
    background: var(--accent-color);
    -webkit-border-radius: .3rem;
    -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.75);
}

::-webkit-scrollbar-corner {
    background: #000;
}

::selection {
    background: var(--select-color);
    color: var(--border-color);
}

body {
    background-color: var(--bg-color);
    background-image: var(--site-bg);
    margin: 0;
    font-size: 14px;
    color: var(--text-color);
}

p { line-height: 1.5em; }

h1 {
    font-family: 'Orbitron', 'Arial Black', sans-serif;
    font-size: 1.5em;
    color: var(--post-header-color);
    filter: drop-shadow(2px 0 0 var(--outline-color)) drop-shadow(0 2px 0 var(--outline-color)) drop-shadow(-2px 0 0 var(--outline-color)) drop-shadow(0 -2px 0 var(--outline-color)) drop-shadow(0 1px 1px var(--outline-color2)) drop-shadow(1px 0 1px var(--outline-color2));
}

h2, h3 {
    font-family: 'Orbitron', 'Arial Black', sans-serif;
}

h4, h5, h6 {
    color: var(--special-text-color);
    font-family: 'Righteous', 'Arial Black', sans-serif;
}

header {
    background-size: 100%;
    background-position: center;
    min-height: 80px;
    margin: 0 0 1.5em;
    padding: 1em;
    display: flex;
    align-items: center;
    justify-content: center;
}

header > h1 {
    background-color: var(--bg-color2);
    color: var(--special-text-color);
    margin: 0 auto;
    font-size: 2.5em;
    font-family: 'UnifrakturMaguntia', 'Cinzel', serif;
    font-weight: 400;
    letter-spacing: 0.1em;
    max-width: 48rem;
    padding: 8px 16px;
    border-radius: 1em;
    border: 4px double var(--outline-color);
    filter: none;
    text-align: center;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

header h1 a {
    cursor: pointer;
    color: var(--special-text-color);
    text-decoration: none;
}

header h1 a:hover { color: var(--accent-color); }
header h1 a:visited { color: var(--special-text-color); }

/* pagination */
ul.pagination {
    display: flex;
    justify-content: center;
    padding: 0;
    flex-wrap: wrap;
}

li.page-item { list-style: none; }

li.page-item a {
    display: inline-flex;
    font-size: 1rem;
    padding: .5rem 1rem;
    background-color: var(--bg-color2);
    border: 2px solid var(--border-color);
    border-radius: .5rem;
    color: var(--link-color);
    text-decoration: none;
    margin: .2rem;
}

li.page-item a:visited { color: var(--link-color); }
li.page-item a:hover {
    color: var(--accent-color);
    background-color: var(--select-color);
}

/* lists */
ul { list-style: none; padding-left: 1.2em; }
ul li::marker { content: "✦ "; color: var(--accent-color); }
ul li {
    margin: .3em 0;
    line-height: 1.5em;
}

/* tags */
div.tags {
    display: block;
    width: 100%;
    text-align: center;
    margin: .5rem 0;
}

div.tags > p.tags {
    text-align: center;
    margin-bottom: 0;
}

ul.tags {
    margin: 0;
    padding: 0;
    text-align: center;
    justify-content: center;
}

ul.tags li {
    display: inline-block;
    margin: 0 .2rem;
}
ul.tags li::marker { content: ""; }

/* nav */
nav { margin: 1em; }

nav.links > ul {
    max-width: 960px;
    margin: auto;
    line-height: 3rem;
    list-style-type: none;
    padding-left: 0;
    display: flex;
    justify-content: space-evenly;
    flex-wrap: wrap;
}

nav.links li {
    text-align: center;
    list-style: none;
}
nav.links li::marker { content: ""; }

nav.links li > a {
    font-weight: bold;
    background-color: var(--bg-color);
    border: 4px double var(--outline-color);
    padding: .5em 3em;
    text-decoration: none;
}

nav.links li > a:visited { color: var(--link-color); }
nav.links li > a:hover {
    color: var(--accent-color);
    background-color: var(--select-color);
}

nav.languages {
    margin: .3em;
    text-align: center;
}
nav.languages ul { display: inline-block; padding-left: 0; }
nav.languages ul li { display: inline-block; }
nav.languages ul li::marker { content: ""; }
nav.languages a { padding: .2em .6em; text-decoration: none; }
nav.languages a.active { color: var(--accent-color); font-weight: bold; }

a {
    color: var(--link-color);
    border-radius: .3em;
    transition: .2s ease-out;
}
a:visited { color: var(--text-color); }
a:hover {
    color: var(--accent-color);
    border-color: var(--accent-color);
    transition: .2s ease;
}

/* sidebar */
#sidebar {
    background-color: var(--bg-color2);
    color: var(--special-text-color);
    height: fit-content;
    width: 260px;
    flex-shrink: 0;
    border-radius: .5em;
    padding-bottom: 1em;
}

.small-box {
    max-width: 240px;
    margin: auto;
    border: 2px solid var(--bg-color);
    font-size: 11px;
    line-height: 1.5rem;
}

#avatar {
    margin: .5em;
    max-width: 280px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.flower {
    width: 200px;
    height: 200px;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid var(--outline-color);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

#bio {
    margin: 20px;
    padding: .2em;
    background: var(--bg-color);
    border: 4px double var(--bg-color2);
    border-radius: 2em;
    font-size: small;
}
#bio p { margin: 1em; }

/* bitcoin widget */
.bitcoin-wallet { margin: 1em .5em; }
.wallet-info { display: flex; flex-direction: column; align-items: center; }
.wallet-qr {
    background: white;
    padding: 0.5em;
    border-radius: 0.5em;
    margin-bottom: 0.5em;
    border: 2px solid var(--border-color);
}
.wallet-qr img { width: 120px; height: 120px; display: block; }
.wallet-address {
    font-family: 'Space Mono', monospace;
    font-size: 9px;
    word-break: break-all;
    padding: 0.5em;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 0.3em;
    margin: 0.5em;
    text-align: center;
    max-width: 200px;
}
.wallet-note { color: var(--special-text-color); text-align: center; }

/* layout */
#content {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 1.5em;
    width: min(1100px, 90vw);
    margin: 0 auto 2em;
    padding: 0;
}

#content > main { flex: 1; min-width: 0; }

main { padding: 0; }

#top { background-color: var(--bg-color); }

#top section {
    background-color: var(--bg-color2);
    border-radius: .5em;
    margin-bottom: 10px;
    padding: .5em 1em;
    width: 100%;
}

article {
    background-color: var(--bg-color2);
    padding: 1em;
    border: 2px solid var(--border-color);
    border-radius: .3em;
    margin-bottom: 1em;
    box-shadow: var(--post-shadow-color) 5px 5px;
}
article img { max-width: 100%; }

.post-meta {
    font-size: 11px;
    color: var(--special-text-color);
    margin-bottom: 1em;
}

.readmore summary {
    font-weight: bold;
    color: var(--special-text-color);
    list-style: none;
    cursor: pointer;
}

/* table of contents */
.table-of-contents {
    background-color: var(--bg-color2);
    border: 2px solid var(--border-color);
    border-radius: .3em;
    padding: 1em;
    margin-bottom: 1em;
    position: sticky;
    top: 1em;
    max-height: 90vh;
    overflow-y: auto;
    width: 180px;
    flex-shrink: 0;
    height: fit-content;
}
.table-of-contents.sidebar { margin-left: 0; }
.table-of-contents h4 { margin-top: 0; text-align: center; }
.table-of-contents ul { list-style-type: none; padding-left: 1em; }
.table-of-contents ul li::marker { content: ""; }
.table-of-contents li { margin: .3em 0; }
.table-of-contents a { text-decoration: none; color: var(--link-color); }
.table-of-contents a:hover { color: var(--accent-color); }

/* single post */
#single-post { display: flex; align-items: flex-start; gap: 1.5em; }
#single-post > article { flex: 1; min-width: 0; }
#single-post > article > #post-toc-mobile { display: none; }

/* code */
pre {
    border: 1px solid var(--outline-color);
    border-radius: 6px;
    padding: 0.75rem 1rem;
    margin: 1.2rem 0;
    overflow-x: auto;
}
code { font-family: 'Space Mono', monospace; }

/* responsive */
@media only screen and (max-width: 800px) {
    #content { flex-wrap: wrap; }
    #sidebar {
        width: 100%;
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        align-items: center;
        border: none;
        margin-right: 0;
        margin-bottom: 1em;
        border-radius: .3em;
    }
    header { min-height: 110px; }
    header > h1 { width: fit-content; padding: .3em 1em; }
    nav.links > ul { display: flex; flex-wrap: wrap; flex-direction: row; }
    #bio { width: 50%; }
    #sidebar ul { line-height: 2em; display: flex; flex-wrap: wrap; gap: 1em; }
    #sidebar > .small-box li { margin: .3em 1em; }
    #single-post > .table-of-contents.sidebar { display: none; }
    #single-post > article > #post-toc-mobile { display: inline; }
}
