:root {
    color-scheme: dark;

    --main-bg: #171616;
    --alt-bg: #242222;
    --alt-dark-bg: #1B1919;
    --dot-bg: #423F3F5E;
    --main-text: #D6C5C5;
    --alt-text: #A6CDA0;
    --high-text: #D85656;
    --higher-text: #C83131;

    word-break: break-word;

    --light-text: #6E6B6B8C;

    --shadow-color: #03071219;
    --light-color: var(--light-text);
    --box-shadow: 0 0 10px var(--shadow-color),
    0 0 20px var(--shadow-color),
    0 0 30px var(--shadow-color);
    --light-shadow: 0 0 10px var(--light-color),
    0 0 20px var(--light-color),
    0 0 30px var(--light-color);

    --tag: #812020;
}

* {
    transition: all 0.3s ease-in-out;
}

@font-face {
    /*source: https://github.com/IdreesInc/Miracode*/
    font-family: "Miracode";
    src: url("/resources/media/font/Miracode.ttf") format("truetype");
}

@font-face {
    font-family: "mononoki";
    src: url("/resources/media/font/mononoki/mononoki-Regular.ttf") format("truetype");
}

@font-face {
  font-family: "mononoki";
  src: url("/resources/media/font/mononoki/mononoki-Regular.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: "mononoki";
  src: url("/resources/media/font/mononoki/mononoki-Italic.ttf") format("truetype");
  font-weight: normal;
  font-style: italic;
}

@font-face {
  font-family: "mononoki";
  src: url("/resources/media/font/mononoki/mononoki-Bold.ttf") format("truetype");
  font-weight: bold;
  font-style: normal;
}

@font-face {
  font-family: "mononoki";
  src: url("/resources/media/font/mononoki/mononoki-BoldItalic.ttf") format("truetype");
  font-weight: bold;
  font-style: italic;
}

html, body {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
}

html {
    background: var(--alt-dark-bg);
}

body {
    scroll-behavior: smooth;

    background: var(--main-bg);
    color: var(--main-text);

    text-align: left;
    text-shadow: 0 0 0.25rem rgba(66, 66, 66, 0.5);
    font-family: "mononoki", "Miracode", monospace;
    font-style: normal;
    font-weight: normal;
    --text-size: 1rem;
    font-size: var(--text-size);

    /* box-sizing: border-box; */
    /* padding: 0 0.6vh; */
    margin: 2rem;
    padding: 1.5rem;

    border: 2px solid var(--dot-bg);
    width: 80%;

    transition: width 0.5s ease-in-out, height 0.5s ease-in-out;
}

@media only screen and (max-width: 1000px) {
    body {
        width: 95%;
        margin: 0;
        /* border: 0; */
        padding: 1rem;
    }
}

main, header {
    max-width: 1000px;
}

header {
    width: 100%;
    text-align: left;
    /*max-width: 900px;*/

    margin-top: 1rem;
    margin-bottom: 1.5%;
}

h1 {
    /* font-family: "Ubuntu Mono"; */
    margin: 0;
    text-shadow: 0 0 15px var(--light-text);
    animation: text-clip 1.2s linear, bump 1s cubic-bezier(.14, 1, .23, 1.06);

    @media (width <= 500px) {
        font-size: 2.2em;
    }

    & a {
        color: var(--main-text);
        width: 100%;
    }

    & a:hover {
        color: var(--main-text);
        text-decoration: none;
    }
}

h1 a:before {
    transition: all 0.3s ease-in-out;
    content: "✦ ";
    font-family: "Ubuntu Mono", serif;
    font-size: 2rem;
}

h1 a:hover:before {
    color: var(--higher-text);
}

h2, h3, h4, h5 {
    & .title-link {
        opacity: 0;
    }

    display: flex;
    flex-direction: row;
    gap: 0.5rem;
}

h2 {
    font-size: 1.8rem;
}

h3 {
    font-size: 1.2rem;
}

p, li {
    font-size: 1rem;
}

h2:hover, h3:hover, h4:hover, h5:hover {
    & .title-link {
        opacity: 1;
    }
}



nav {
    & li {
        font-size: 1.125em;
    }

    @media (width <= 500px) {
        font-size: 1em;
    }
}


main {
    /*font-size: 1.125rem;*/
    width: 100%;
}

article {
    margin: 40px 0 40px 0;
}

a {
    color: var(--high-text);
    text-decoration: none;
    font-weight: bold;
}

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

li {
    list-style: "✦ "
}

.fancyList li:hover:has(a), .project-link:hover {
    transform: rotate(3deg) scale(125%);
}

.fancyList {
    list-style: none;
    display: flex;
    flex-direction: row;
    gap: 1rem;

    margin: 0;
    padding: 0;

    & li {
        list-style: none;
    }
}

span[title] {
    color: var(--alt-text);
}

span[title]:hover {
    text-decoration: underline dashed;
}

.oldschool-button {
    image-rendering: pixelated !important;
    margin: 0 !important;
    width: 88px !important;
    height: 31px !important;
}

.oldschool-button:hover {
    transform: scale(1.2);
    outline: 1px solid var(--high-text);
}

.media {
    max-width: 70%;

    border-radius: 10px;
}

.shadow {
    box-shadow: var(--box-shadow);
}

.stars {
    background-color: var(--alt-bg);
    background-image: url(/resources/media/star.svg);
    background-size: 45px 45px;
    animation: slide 100s linear infinite;
}

.box-highlight {
    box-shadow: 0 2px 2px 0 var(--dot-bg) inset,
    0 -2px 2px 0 var(--main-bg) inset;
}

.popup {
    --curvey: cubic-bezier(.14, 1, .23, 1.04);
    position: absolute;

    transition-property: transform, opacity;
    transition-duration: 0.3s;
    transition-delay: 0.5s;
    transition-timing-function: var(--curvey);

    z-index: 5;

    padding: 1rem;
    border-radius: 10px;

    max-width: 300px;
}


.hidden {
    display: none;
}

@keyframes text-clip {
    from {
        clip-path: inset(0 100% 0 0);
    }
    to {
        clip-path: inset(0 0 0 0);
    }
}

@keyframes bump {
    from {
        transform: translateX(300px);
    }

    to {
        transform: translateX(0px);
    }
}

@keyframes slight-bump {
    from {
        transform: translateX(20px);
    }

    to {
        transform: translateX(0px);
    }
}

@keyframes transparency-off {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slide {
    to {
        background-position: right bottom;
    }
}