:root {
    /* --background-image: url("images/stars3.gif"); */
    --background-image: url("images/stars-light.gif");
    --text-color: #ffffff;
    --background-color: rgba(0, 0, 0, 1.0);
    /* --nav-background: rgba(0, 0, 0, 0.3);
    --content-background: rgba(0, 0, 0, 0.3); */
    --link-color: coral;
    --link-hover-color: rgb(255, 68, 0);
    --border-color: #ffcc00;
    --heading-color: #7700ff;
    --marquee-color: #ffcc00;
}

[data-theme="light"] {
    --background-image: url("images/stars-light.gif");
    --text-color: #1a1d2b;
    --background-color: rgba(255, 255, 255);
    /* --nav-background: rgba(223, 223, 223, 0.6);
    --content-background: rgba(223, 223, 223, 0.6); */
    --link-color: #ff6b35;
    --link-hover-color: #e63946;
    --border-color: #4361ee;
    --heading-color: #3a0ca3;
    --marquee-color: #3a0ca3;
}

html {
    height: 100%;
}

body {
    background: var(--background-image) repeat;
    background-color: var(--background-color);
    margin: 0;
    color: var(--text-color);
    font-family: 'Press Start 2P', cursive;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-y: scroll;
    overflow-x: hidden;
    -ms-overflow-style: none;
    scrollbar-width: none;
    transition: color 1s ease;
}

body::-webkit-scrollbar { 
    display: none;
}

.main-container {
    display: flex;
    flex-direction: column;
}

header {
    display: flex;
    text-align: center;
}

#datetime {
    flex: 1;
    text-align: center; /* Center text within its flexible space */
  }

nav {
    background-color: var(--nav-background);
    padding: 10px;
    border-top: 12px outset var(--border-color);
    transition: background-color 0.3s ease;
    max-height: 78px;
}

nav a {
    color: var(--text-color);
    text-decoration: none;
    display: inline-block;
    margin: 5px 10px;
    transition: color 0.3s ease;
}

.content {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 0px 20px;
    background-color: var(--content-background);
    /* border-left: 4px solid var(--border-color); */
    /* border-right: 4px solid var(--border-color); */
    transition: background-color 0.3s ease;
}

fieldset {
    border-width: 6px;
    border-image: repeating-radial-gradient(circle at 10px,
            var(--border-color),
            var(--heading-color) 2px,
            var(--border-color) 4px,
            var(--heading-color) 2px) 1;
    margin-bottom: 20px;
    box-shadow: 0 0 5px var(--border-color);
    transition: box-shadow 0.3s ease, border-image 0.3s ease;
}

legend {
    font-family: 'Press Start 2P', cursive;
    padding: 0 10px;
    color: var(--text-color);
}

.project-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.project-list p {
    flex: 0 0 100%;
    margin: 0;
}

.marquee {
    font-size: 1.2em;
    color: var(--marquee-color);
    overflow: hidden;
}

a {
    color: var(--link-color);
    transition: color 0.3s ease;
}

a:hover {
    color: var(--link-hover-color);
}

footer {
    text-align: center;
    padding: 20px;
}

img {
    max-width: 100%;
    height: auto;
}

.yellow {
    color: var(--heading-color);
}

.theme-toggle {
    position: absolute;
    right: 10px;
    top: 10px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.8em;
    background: var(--content-background);
    border: 4px outset var(--border-color);
    color: var(--text-color);
    cursor: pointer;
    padding: 4px;
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    border-style: inset;
    transform: scale(0.98);
}

.theme-toggle:active {
    transform: scale(0.95);
}

@media (min-width: 768px) {

    .main-container {
        flex-direction: row;
        justify-content: center;
    }

    .content-wrapper {
        /* border: 4px outset var(--border-color); */
        display: flex;
        width: 80%;
        max-width: 900px;
        transition: border-color 0.3s ease;
    }

    .buttons {
        width: 80%;
        max-width: 900px;
        margin-left: auto;
        margin-right: auto;
    }

    .buttons > button {
        border: var(--border-color) solid 4px;
    }

    nav {
        width: 15%;
        /* padding: 0; */
        border-right: 4px solid var(--border-color);
    }

    nav a {
        display: block;
        /* margin: 10px 0; */
    }

    .project-list p {
        flex: 0 0 calc(50% - 7.5px);
    }
}

@media (max-width: 767px) {

    .content-wrapper {
        width: 100%;
        /* border: 4px outset var(--border-color); */
        /* border-top: 12px outset var(--border-color); */
        box-sizing: border-box;
    }

    .buttons {
        width: 100%;
        margin-left: auto;
        margin-right: auto;
    }

    nav {
        border-bottom: 4px outset var(--border-color);
    }

    .project-list > div {
        margin-bottom: 0px;
    }
}

* {
    transition: background-color 0.3s ease,
                color 0.3s ease,
                border-color 0.3s ease,
                box-shadow 0.3s ease;
}