@import url("https://fonts.googleapis.com/css2?family=JetBrains+Mono:ital,wght@0,100..800;1,100..800&family=Noto+Sans+JP:wght@100..900&display=swap");

@media (prefers-color-scheme: dark) {
    :root {
        --bg-color: #151515;
        --bg-color-2: #252525;
        --text: gainsboro;
        --text-2: dimgrey;
        --accent: orangered;
        --accent-hover: darkorange;
    }
}

@media (prefers-color-scheme: light) {
    :root {
        --bg-color: whitesmoke;
        --bg-color-2: white;
        --text: black;
        --text-2: grey;
        --accent: orangered;
        --accent-hover: darkorange;
    }
}

@media screen {
    :root {
        --blog-width: 40%;
    }
}

@media screen and (max-width: 1500px) {
    :root {
        --blog-width: 60%;
    }
}

@media screen and (max-width: 1000px) {
    :root {
        --blog-width: 90%;
    }
}

:root {
    background: var(--bg-color);
    font-family: "Noto Sans JP", sans-serif;
}

a {
    text-decoration: none;
    color: var(--accent);
}

a:hover {
    text-decoration: underline;
    color: var(--accent-hover);
}

body {
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text);
    width: 100%;
}

.nav-bar-slash {
    padding-left: 0.2rem;
    padding-right: 0.2rem;
}

main {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 4rem;
    padding-bottom: 2rem;
    padding-top: 2rem;
    background-color: var(--bg-color-2);
    width: 100%;
    font-size: 16px;
}

.blog-width-container {
    width: var(--blog-width);
}

header {
    color: var(--accent);
    font-family: "JetBrains Mono", monospace;
    font-size: 14px;
    padding: 0.5rem 0.5rem 0.5rem 1.5rem;
    width: 100%;
    position: sticky;
    top: 0;
    backdrop-filter: blur(0.5rem);
    background-color: color-mix(in srgb, var(--bg-color), transparent 30%);
}

footer {
    color: var(--text-2);
    margin-top: 2rem;
    margin-bottom: 2rem;
}

footer a {
    color: var(--text-2);
}

.quote {
    background: var(--bg-color);
    padding: 0.5rem;
    margin-left: 1rem;
    margin-right: 2rem;
    border-left: 0.5rem solid
        color-mix(in srgb, var(--text), var(--bg-color) 80%);
}

p {
    padding-bottom: 0.5rem;
    padding-top: 0.5rem;
}

.code {
    font-family: monospace;
    color: orange;
}

.code block {
    background: #fff2;
    font-size: 16px;
    padding: 1rem;
    border-radius: 0.5rem;
}

.separator {
    height: 1px;
    margin-top: 2.5rem;
    margin-bottom: 2.5rem;
    background-color: var(--text);
}
