:root {
    --nav-bar-bg-color: #455a64;
    --nav-bar-text-color: white;
    --primary-bg-color: #1976d2;
    --primary-bg-text-color: white;
    --secondary-bg-color: white;
    --secondary-bg-text-color: #455a64;
    --tertiary-bg-color: #c56000;
    --tertiary-bg-text-color: #000000;


    --nav-bar-height: 80px;
    --content-width: 1024px;


    --project-box-size: 300px;
    --project-box-margin: 32px;
}

html {
    scroll-behavior: smooth;
}

body {
    display: flex;
    margin: 0;
    flex-direction: column;
    font-family: 'Roboto', sans-serif;
    background-color: var(--primary-bg-color);
}


/* Header */

.nav-bar {
    background-color: var(--nav-bar-bg-color);
    color: var(--nav-bar-text-color);
    height: var(--nav-bar-height);
    box-sizing: border-box;
    display: flex;
    align-items: stretch;
    box-shadow: 0 1px 5px black;
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-item {
    color: inherit;
    padding: 16px;
}

a.header-item {
    text-decoration: none;
}

a.header-item:hover {
    background-color: #E68E0D;
}

a.header-item:active {
    background-color: #CC7400;
}

.header-filler {
    flex-grow: 1;
}

.logo-text {
    font-size: 1.3em;
}


/* -Header */


/* Main Content */

main {
    flex-grow: 1;
}
.text-content{
    max-width: var(--content-width);
    text-align: justify;
}

#section1 {
    height: calc(100vh - var(--nav-bar-height)) ;
}

.background-box {
    background-color: var(--bb-background-color);
    color: var(--bb-text-color);
}

.background-box hr {
    background-color: var(--bb-text-color)
}

.background-box .cycle-img-wrapper {
    filter: var(--bb-text-color-filter);
}

.primary-background-box {
    --bb-background-color: var(--primary-bg-color);
    --bb-text-color: var(--primary-bg-text-color);
    --bb-text-color-filter: invert(100%) sepia(0%) saturate(7500%) hue-rotate(344deg) brightness(111%) contrast(100%);
}

.secondary-background-box {
    --bb-background-color: var(--secondary-bg-color);
    --bb-text-color: var(--secondary-bg-text-color);
    --bb-text-color-filter: invert(31%) sepia(16%) saturate(683%) hue-rotate(155deg) brightness(96%) contrast(85%);
}

.tertiary-background-box {
    --bb-background-color: var(--tertiary-bg-color);
    --bb-text-color: var(--tertiary-bg-text-color);
    --bb-text-color-filter: invert(31%) sepia(16%) saturate(683%) hue-rotate(155deg) brightness(96%) contrast(85%);
}

.person-photo {
    transition: 1s ease-in-out;
    cursor: pointer;
}

.person-photo:active {
    transition: 2s ease-in-out;
    transform: rotate(1turn);
}

.person-photo-wrapper,
.person-photo {
    border-radius: 50%;
}

.person-photo-wrapper {
    justify-content: space-evenly;
    align-items: center;
}

.person-photo-wrapper:active::after {
    content: "Do a barrel roll!";
    font-style: italic;
    font-family: "Comic Sans MS", "Comic Sans", cursive;
}


/* Generic sections */

.content-section {
    flex-direction: column;
    box-sizing: border-box;
    padding: 32px;
}


/* -Generic sections */


/* Cycle img */

.hidden {
    display: none;
}

.cycle-img {
    opacity: 0;
    pointer-events: none;
    position: absolute;
    height: inherit;
    width: inherit;
}

.cycle-img > img {
    height: inherit;
    width: inherit;
}

.cycle-img-radio:checked + .cycle-img,
.placeholder {
    /* display: block; */
    cursor: pointer;
    opacity: 1;
    transition: opacity .4s ease;
    pointer-events: all;
}

.cycle-img-wrapper {
    width: 48px;
    height: 48px;
    margin-left: 16px;
    margin-right: 16px;
}


/* -Cycle img */


/* Tags */
.tag {
    padding: 8px;
    line-height: 48px;
    margin-right: 8px;
    border-radius: 20px;
    white-space: nowrap;
    background-color: var(--primary-bg-color);
    color: var(--primary-bg-text-color);
}

.tag-filter-label {
    cursor: pointer;
    pointer-events: all;
}

.tag-filter-btn:checked + .tag-filter-label {
    background-color: var(--tertiary-bg-color);
    color: var(--tertiary-bg-text-color);
}

#portfolio-items > input[value="All"]:checked ~ [data-category] {
    display: inherit;
}

.tag-filter {
    width: 100%;
    text-align: center;
    padding-top: 24px;
}

.tag-filter > input[value="CSS"]:checked ~ #portfolio-items > [data-category]:not([data-category~="CSS"]),
.tag-filter > input[value="JavaScript"]:checked ~ #portfolio-items > [data-category]:not([data-category~="JavaScript"]),
.tag-filter > input[value="Kotlin"]:checked ~ #portfolio-items > [data-category]:not([data-category~="Kotlin"]),
.tag-filter > input[value="HTML"]:checked ~ #portfolio-items > [data-category]:not([data-category~="HTML"]),
.tag-filter > input[value="CSS"]:checked ~ #portfolio-items > [data-category]:not([data-category~="CSS"]) {
    /* display: none; */
    width: 0;
    height: 0;
    padding: 0;
    margin: 0;
    opacity: 0;
}


/* -Tags */


/* Modal */

#portfolio-items {
    flex-wrap: wrap;
}

.project {
    position: relative;
    width: var(--project-box-size);
    height: var(--project-box-size);
    margin: var(--project-box-margin);
    transition: all 1s;
    transition-timing-function: ease-in-out;

}
.project > * {
    transition: none;
}

.modal-btn {
    width: 100%;
    height: 100%;
}

.modal-btn-img {
    max-height: 100%;
    max-width: 100%;
}

.modal-btn::before {
    content: '';
    position: absolute;
    background-color: #0086c3;
    width: 100%;
    height: 100%;
    opacity: 0;
    /*filter: invert(58%) sepia(76%) saturate(444%) hue-rotate(344deg) brightness(99%) contrast(97%);*/
    transition: all .5s;
}
.modal-btn:hover::before {
    opacity: .3;
}
.project[open] > .modal-btn::before {
    transition: all 0s;
    opacity: 1;
}

.modal-btn-icon {
    position: relative;
    user-select: none;
    opacity: 0;
    width: auto;
    height: 50%;
    /* #f9973b: */
    filter: invert(58%) sepia(76%) saturate(444%) hue-rotate(344deg) brightness(99%) contrast(97%);
}

.images-first-time-right{
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
}


/* -Modal */

.about-me-text {
    text-align: justify;
    flex-wrap: wrap;
    justify-content: center;
}

.about-me-text > p {
    max-width: 320px;
    padding-right: 16px;
    padding-left: 16px;
}

footer {
    text-align: justify;
    flex-wrap: wrap;
    justify-content: center;
}

footer > div {
    align-items: center;;
    max-width: 320px;
    flex-grow: 1;
    padding-right: 16px;
    padding-left: 16px;
}

/* -Main Content */


/* Generic */

hr {
    width: 150px;
    height: 3px;
    border: 0px;
}

.header-item,
.modal-btn,
.text-center {
    display: flex;
    justify-content: center;
    align-items: center;
}

.flex-row {
    display: flex;
    flex-direction: row;
}

.flex-column {
    display: flex;
    flex-direction: column
}

.social-link {
    min-width: 48px;
    min-height: 48px;
    box-sizing: border-box;
    padding: 8px;
}


@media screen and (max-width: 772px) {
    .about-me-text > p {
        max-width: inherit;
    }
    .footer > div {
        max-width: inherit;
    }

    #portfolio-items{
        flex-direction: column;
    }
}