:root {
    --header-height: 3rem;
}

[data-theme="light"] {
    --main-bg-color: #d5d6db;
    --text-color: #0f0f14;
}

[data-theme="dark"] {
    --main-bg-color: #16161e;
    --text-color: #7aa2f7;
}

* { 
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    font-family: "JetBrains Mono", Arial, Helvetica, sans-serif;
    height: 100%;
    min-height: 100%;
    display: flex;
    flex-direction: column;
    color: var(--text-color);
    background-color: var(--main-bg-color);
}

/* Header & footer elements */
.bar {
    width: 100%;
    background-color: var(--main-bg-color);
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
}

.bar-section {
    display: flex;
    flex-direction: row;
    align-items: center;
    /* justify-content: flex-start; */
    flex-grow: 1;
    margin: 0.5rem;
}

.bar-left {
    justify-content: flex-start;
}

.bar-center {
    justify-content: center;
}

.centered {
    text-align: center;
}

.bar-right {
    justify-content: flex-end;
}

#theme-toggle {
    width: 2rem;
    height: 2rem;
    background-color: var(--text-color);
    border: var(--text-color);
    border-radius: 1rem;
    border-style: solid;
}

.progress-bar-container {
    width: 50%;
    min-width: 0;
    height: 1rem;
    min-height: 1rem;
    border-radius: 1rem;
    background-color: var(--text-color);
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding-right: 0.5rem;
    padding-left: 0.5rem;
}

.progress-bar {
    flex-basis: 0%;
    flex-shrink: 0;
    height: 25%;
    background-color: var(--main-bg-color);
    border-radius: 1rem;
}

/* Header */
header {
    height: var(--header-height);
    min-height: var(--header-height);
}

/* Footer */
footer {
    height: 3rem;
}

/* Content */
#content {
    flex: auto;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    background-color: var(--main-bg-color);
}

/* Main */
main {
    margin-left: 1rem;
    margin-right: 1rem;
    flex-basis: 100%;
}

h1 {
    margin-top: 0.5rem;
    text-align: center;
}

ul {
    list-style-position: inside;
}

a, a:hover, a:active, a:visited, a:focus {
    text-decoration: none;
    color: var(--text-color);
}

.divider {
    border-color: var(--text-color);
    background-color: var(--text-color);
}

.project-gallery {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-evenly;
    width: 100%;
}

.project {
    flex-basis: 30%;
    flex-grow: 1;
    margin-bottom: 0.5rem;
    margin-right: 0.5rem;
    display: flex;
    flex-direction: column;
    border: var(--text-color);
    border-style: solid;
    border-width: 1px;
}

/* Phone screen */
@media screen and (max-width:400px) {
    .project {
        flex-basis: 100%;
    }
}

.project:hover {
    color: var(--main-bg-color);
    background-color: var(--text-color);
}

.project-img {
    width: 100%;
}

.project-thumbnail {
    max-width: 100%;
    object-fit: contain;
}

.project-description {
    flex-grow: 1;
    margin-left: 0.5rem;
    display: flex;
    flex-direction: column;
}

.project-description-paragraph {
    flex-grow: 1;
}

.project-credits {
    font-size: 0.8rem;
}

.blog-entry {
    width: 100%;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
}

.blog-entry:hover {
    color: var(--main-bg-color);
    background-color: var(--text-color);
}