:root {
    --rgb-flare-light: rgb(180, 70, 195);
    --rgb-flare-dark: rgb(124, 71, 159);
    --rgba-project-button-shadow-light: rgba(180, 70, 195, 0.2);
    --rgba-project-button-shadow-dark: rgba(124, 71, 159, 0.2);
}

.gradientbackground {
    background-color: rgba(236, 217, 189, 0.911);
    background-image:
        radial-gradient(at 81% 65%, hsla(218, 98%, 94%, 1) 0px, transparent 50%),
        radial-gradient(at 27% 75%, hsla(39, 80%, 94%, 1) 0px, transparent 50%),
        radial-gradient(at 90% 99%, hsla(291, 77%, 94%, 1) 0px, transparent 50%),
        radial-gradient(at 75% 26%, hsla(197, 87%, 94%, 1) 0px, transparent 50%);
    background-size: 500% 500%;
    animation: gradient 9s ease infinite;
    min-height: 100vh;
}

@keyframes gradient {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}


/* GLOBAL */
body {
    font-family: Arial, sans-serif;
    margin: 0px;
    height: 100vh;
}

* {
    box-sizing: border-box;
}

/* COLUMN LAYOUT MOBILE */
.main {
    display: flex;
    flex-direction: column;
}

.main__column {
    display: flex;
    height: 100%;
}

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

.portfolio {
    width: 100%;
    margin-top: 5em;
    margin-bottom: 2em; /* Same height as a project button */
    display: flex;
    flex-direction: column;
    row-gap: 0.5em;
}

.project__container {
    position: fixed;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 100%;
    height: 100%;
    padding: 0px 10vmin;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(15px);
    opacity: 0;
    transition: opacity 0.3s ease-in;
    z-index: 1;
    top: -100vh;
}

.project__container.enter {
    opacity: 1;
    top: 0px;
    transition: opacity 0.3s ease-in;
}

.project__container.exit {
    opacity: 0;
    top: 0px;
    transition: opacity 0.3s ease-out;
}

.portfolio__project {
    display: flex;
    position: relative;
    flex-direction: column;
    align-items: center;
    width: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.portfolio__project.enter {
    opacity: 1;
}

.portfolio__project.exit {
    opacity: 0;
}

.project__content__selected {
    opacity: 0;
    max-height: 0px;
    overflow: hidden;
    transition: opacity 0.3s ease-out, max-height 0.3s ease-out;
}

.project__content__selected.enter {
    opacity: 1;
    max-height: 100%;
    transition: opacity 0.3s ease-out, max-height 0.3s ease-out;
}

.project__content__selected.exit {
    opacity: 0;
    max-height: 0px;
}

#close__project__button {
    position: fixed;
    top: 0%;
    right: 0%;
    left: auto;
    z-index: 100;
    display: block;
    margin: 5vmin;
    height: 10vmin;
    min-height: 48px;
}

/* COLUMN LAYOUT PC */
@media (min-width: 768px) {
    .main {
        flex-direction: row;
        align-items: flex-start;
        justify-content: flex-start;
    }

    #portfolio {
        order: 0;
        min-width: 40%;
        justify-content: center;
    }

    .portfolio {
        align-self: center;
        margin-top: 25vh;
        margin-bottom: 25vh;
        width: auto;
    }

    #biography {
        order: 1;
        position: sticky;
        inset: 0px 0px 0px auto;
        height: 100vh;
        width: 18em;
        min-width: 40%;
        flex-direction: column;
        justify-content: center;
    }

    .project__container {
        position: absolute;
        display: flex;
        flex-direction: column;
        justify-content: center;
        width: 100%;
        padding: 0px;
        background: rgba(255, 255, 255, 0);
        backdrop-filter: blur(0px);
    }

    .biography {
        opacity: 1;
        transition: opacity 0.3s ease;
    }

    .hide {
        opacity: 0;
        transition: opacity 0.3s ease;
    }

    .project__container.hide {
        opacity: 0;
        transition: opacity 0.3s ease;
    }

    #close__project__button {
        display: none;
    }

    .portfolio__project {
        position: fixed;
        padding: 25px;
        overflow-y: scroll;
        max-height: 100vh;
    }
}

/* BIOGRAPHY MOBILE */
#if__biography__about {
    display: none;
}

.biography {
    padding: 30px 15px;
    display: flex;
    flex-direction: column;
    row-gap: 0.7em;
}

.biography__picture {
    opacity: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    max-height: 300px;
}

.biography__picture img {
    max-width: 250px;
    max-height: 250px;
    width: 60vmin;
    height: 60vmin;
    object-fit: cover;
    border-radius: 100%;
    box-shadow: rgba(0, 0, 0, 0.08) 0px 10px 20px 2px;
    margin: 15px 15px 25px;
}

.biography__about {
    opacity: 1;
}

/* BIOGRAPHY PC */
@media (min-width: 768px) {
    .biography__about {
        opacity: 0;
        max-height: 0px;
        overflow: hidden;
        transition: opacity 0.5s ease, max-height 0.5s ease;
    }

    .biography__about--show {
        opacity: 1;
    }

    .biography__picture {
        align-items: flex-start;
        opacity: 0;
        max-height: 0px;
        overflow: hidden;
        margin-left: -15px;
        transition: opacity 0.5s ease, max-height 0.5s ease;
    }

    .biography__picture--show {
        opacity: 1;
    }

    #if__biography__about {
        display: inline-block;
    }
}

/* PROJECT MOBILE */
.project__button {
    padding: 1em;
    margin: 0em 1em;
    display: flex;
    justify-content: space-between;
    align-items: center;
    column-gap: 2em;
    order: 1;
}

.project__content__hover {
    display: flex;
    flex-direction: column;
    max-width: 100%;
}

.project__content__selected {
    display: flex;
    flex-direction: column;
    overflow: visible;
}

.portfolio__project {
    overflow: scroll;
    scrollbar-width: none;
}

.video {
    object-fit: contain;
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 70vh;
    border-radius: max(3vmin, 24px);
    box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 15px 2px;
}

.project__video {
    padding: 30px 30px 0px;
}

@media (min-width: 768px) {
    .video {
        box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 20px 2px;
    }

    .project__video {
        padding: 0px;
        display: flex;
        justify-content: center;
    }

    .portfolio__project {
        overflow: scroll;
        scrollbar-width: none;
    }
}

.project__contribution {
    display: inline-flex;
    align-items: center;
    align-self: center;
    background-color: white;
    border-radius: 1em;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 4px 8px;
    padding: 0.5em;
    margin: 20px auto;
    height: 2em;
    white-space: nowrap;
}

.project__contribution img {
    width: 1em;
    height: 1em;
    margin-right: 0.5em;
    object-fit: contain;
    justify-self: center;
}

.project__contribution__collaborators__seperator {
    margin: 0px 0.3em;
}

/* TEXT AND FONTS */
div {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
}

a {
    text-decoration: none;
    color: rgb(0, 0, 0);
    opacity: 0.7;
    font-weight: 500;
}

a:hover {
    color: rgb(0, 0, 0);
    opacity: 0.5;
}

.biography__introduction {
    font-size: 22px;
    line-height: 30px;
    font-weight: 700;
    display: inline-block;
}

.introduction__workplace {
    background: linear-gradient(214deg, var(--rgb-flare-light), var(--rgb-flare-dark)) padding-box text;
    opacity: 1;
    color: transparent;
    font-weight: 700;
}

.introduction__workplace:hover {
    color: transparent;
    opacity: 0.6;
}

.biography__social {
    display: flex;
    gap: 0.7em;
}

.biography__social__link {
    font-size: 18px;
    opacity: 0.7;
    color: black;
    font-weight: 400;
}

.biography__social__link:hover {
    opacity: 0.5;
}

.biography__social__link:visited {
    opacity: 0.6;
}

.biography__about {
    font-size: 16px;
    line-height: 24px;
    font-weight: 400;
    color: rgb(51, 51, 51);
    opacity: 0.9;
}

.project__button__title {
    font-size: 16px;
    font-weight: 400;
    cursor: default;
}

.project__button__year {
    font-size: 16px;
    font-weight: 400;
    cursor: default;
    opacity: 0.5;
}

.project__button {
    border-radius: 1.4em;
    transition: 200ms;
}

.project__button:hover {
    background: rgba(255, 255, 255, 0.4);
    box-shadow: rgba(0, 0, 0, 0.1) 0px 4px 16px 2px;
    transition: 200ms;
}

.project__button.selected {
    background: rgba(255, 255, 255, 0.8);
    box-shadow: var(--rgba-project-button-shadow-light) 4px -2px 16px 2px, var(--rgba-project-button-shadow-dark) -4px 4px 16px 2px;
    transition: 200ms;
}

.project__description__title {
    margin-bottom: 1em;
    margin-top: 1em;
    font-size: 28px;
    line-height: 1.4em;
    font-weight: 700;
    display: inline-block;
}

.project__description__text {
    font-size: 18px;
    line-height: 28px;
    font-weight: 400;
    color: rgb(0, 0, 0);
    opacity: 0.7;
}

.project__redirect__container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 10vw;
    margin-bottom: 5vw;
}

.project__redirect {
    font-size: 20px;
    line-height: 24px;
    font-weight: 600;
    padding: 20px 30px;
    border: medium;
    outline: currentcolor;
    position: relative;
    z-index: 101;
    border-radius: 1000px;
    background: linear-gradient(214deg, var(--rgb-flare-light), var(--rgb-flare-dark));
    cursor: pointer;
    opacity: 1;
}

.project__redirect:hover {
    opacity: 1;
}

.project__redirect::before {
    content: "";
    position: absolute;
    inset: 2px;
    border-radius: 1000px;
    background-color: white;
    z-index: -1;
    transition: 200ms;
}

.project__redirect::after {
    content: attr(data);
    font-size: 20px;
    background: linear-gradient(214deg, var(--rgb-flare-light), var(--rgb-flare-dark)) padding-box text;
    color: transparent;
    transition: 200ms;
}

.project__redirect:hover::before {
    opacity: 0;
    inset: 0px;
    color: white;
}

.project__redirect:hover::after {
    color: white;
}

@media (min-width: 768px) {
    .project__description__title {
        margin-bottom: 1em;
        margin-top: 1em;
        font-size: 22px;
        line-height: 1.4em;
        font-weight: 700;
    }

    .project__description__text {
        font-size: 16px;
        line-height: 24px;
        font-weight: 400;
    }

    .project__redirect {
        font-size: 16px;
        padding: 10px 20px;
    }

    .project__redirect::after {
        font-size: 16px;
    }

    .project__redirect__container {
        display: flex;
        justify-content: center;
        align-items: center;
        margin-top: 1em;
    }
}

.timestamp {
    position: sticky;
    order: 999;
    margin-top: 2em;
    display: flex;
    flex-direction: column;
    align-items: center;
    align-self: center;
}

@media (min-width: 768px) {
    .timestamp {
        position: fixed;
        bottom: 0px;
        right: 0px;
        margin: 1em;
        z-index: 100;
    }
}