@font-face {
    font-family: "Bluunext";
    src: url("/assets/fonts/bluunext-bold-webfont.woff2") format("woff2");
    font-weight: bold;
}

@font-face {
    font-family: "PPMori";
    src: url("/assets/fonts/PPMori-Regular.woff2") format("woff2");
    font-weight: regular;
}

@font-face {
    font-family: "PPMori";
    src: url("/assets/fonts/PPMori-SemiBold.woff2") format("woff2");
    font-weight: bold;
}

/****** CSS RESET ******/

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

h1, h2, h3, h4, h5, h6, p {
    font-size: 16px;
}

ol, ul, li {
    list-style: none;
}

figure {
    font-size: 0;
    line-height: 0;
}

img {
    width: 100%;
}

a {
    color: #000;
    text-decoration: none;
    cursor: pointer;
}

button {
	background: none;
	color: inherit;
	border: none;
	padding: 0;
	font: inherit;
	cursor: pointer;
	outline: inherit;
}


/****** GLOBAL ******/

html {
    font-size: 16px;
}

body {
    padding: 3rem 3rem 2rem;
    position: relative;
    min-height: 100svh;
}

body:has(.play-mode) {
    background-color: #20A3E5;
    transition: background-color 0.4s linear;
}

body:not(:has(.play-mode)){
    background-color: #fff;
    transition: background-color 0.4s linear;
}

header {
    margin-bottom: 4rem;
}


.invisible {
    opacity: 0;
    cursor: initial;
}

h1, h1 span {
    font-family: 'PPMori', serif;
    font-size: 3rem;
    font-weight: bold;
    line-height: 130%;
}

h2 {
    font-family: 'PPMori', serif;
    font-size: 1.75rem;
    font-weight: bold;
    line-height: 120%;
}

h3 {
    font-family: 'PPMori', serif;
    font-size: 1.25rem;
    font-weight: bold;
    line-height: 120%;
}

p,
a {
    font-size: 1rem;
    font-family: 'PPMori', sans-serif;
    line-height: 140%;
}

.text-small {
    font-size: 0.75rem;
}

.button {
    padding: 9px 18px 7px;
    /* border: 1px dashed #000; */
    box-shadow: -0.5px 0.5px 5px rgba(0, 0, 0, 0.1);
    border-radius: 100px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 1.5rem;
    line-height: 120%;
    font-family: 'PPMori', serif;

    transition: box-shadow 0.4s ease-in-out;
}

.button:hover {
    box-shadow: -1px 2px 10px rgba(0, 0, 0, 0.3);
    transition: box-shadow 0.4s ease-in-out;
}

.button p {
    font-family: 'PPMori', serif;
    font-size: 1.5rem;
}

header .button {
    transform: translateY(-20%);
}

.button:has(img) {
    padding: 7px 25px 7px;
}

.button--contact {
    margin-left: 10px;
    background-color: #20A3E5;
    color: #fff;
}

/****** MAIN ******/

/*** SWITCH ***/

.switch {
    z-index: 100;
    border-radius: 100px;
    text-decoration: none;
    display: flex;
    position: fixed;
    bottom: 2rem;
    background-color: #fff;
    box-shadow: -1px 2px 10px rgba(0, 0, 0, 0.2);
}

.home-wrapper:is(.play-mode) .switch .switch-button--bg {
    background-color: #E8201C;
}

.home-wrapper:not(:is(.play-mode)) .switch .switch-button--bg {
    background-color: #000;
}

.switch-button--bg {
    border-radius: 100px;
    width: 50%;
    height: 100%;
    position: absolute;
    z-index: -1;
    
    transform: translate(100%);
    transition: transform 0.2s ease-out;
}

.switch:hover .switch-button--bg {
    transform: translate(90%);
}

.switch p {
    font-family: 'PPMori', serif;
    font-size: 1.25rem;
    font-weight: bold;
    line-height: 100%;
}

.switch-button {
    padding: 1rem 2rem;
}

.switch-selected {
    color: #FFFFFF;
    border-radius: 100px;
}

.switch .switch-selected p {
    font-weight: 300;
}

/*** PLAY MODE ***/

.home-wrapper:is(.play-mode) h1,
.home-wrapper:is(.play-mode) h2,
.home-wrapper:is(.play-mode) .button,
.home-wrapper:is(.play-mode) .button p {
    color: #fff;
}

.home-wrapper:is(.play-mode) .button {
    background-color: #fff;
    color: #20A3E5;
    box-shadow: -0.5px 0.5px 5px rgba(232, 38, 154, 0.1);
    box-shadow: -0.5px 0.5px 5px rgba(6, 61, 88, 0.1);
    transition: box-shadow 0.4s ease-in-out;
}

.home-wrapper:is(.play-mode) .button:hover {
    box-shadow: -1px 2px 10px rgba(232, 38, 154, 0.3);
    box-shadow: -0.5px 0.5px 5px rgba(6, 61, 88, 0.3);
    transition: box-shadow 0.4s ease-in-out;
}

.home-wrapper:is(.play-mode) .switch {
    box-shadow: -1px 2px 10px rgba(232, 38, 154, 0.2);
    box-shadow: -0.5px 0.5px 5px rgba(6, 61, 88, 0.2);
}

/* .home-wrapper:is(.play-mode) .switch p {
    color: #E8269A;
} */

.home-wrapper:is(.play-mode) .switch-button--bg {
    /* background-color: #E8269A; */

    transform: translate(0%);
    transition: transform 0.2s ease-out;
}

.home-wrapper:is(.play-mode) .switch:hover .switch-button--bg {
    transform: translate(10%);
}

.home-wrapper:is(.play-mode) .switch-selected p {
    color: #FFFFFF;
}

.home-wrapper:is(.play-mode) .projects {
    display: none;
}

/** GAME **/

.game {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.game h2 {
    text-align: center;
    font-weight: normal;
}

.cards {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
}

.home-wrapper:not(.play-mode) .game {
    display: none;
}

.card {
    width: 185px;
    height: 185px;
    position: relative;
    border-radius: 5%;
    perspective: 1000px;
    transition: transform 0.3s ease-in-out;

    transform-style: preserve-3d;
    will-change: transform;
}

.card:not(:has(.card-rotate)):hover .card-inner {
    transform: rotateY(30deg);
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
    -webkit-backface-visibility: hidden; /* Safari */
    backface-visibility: hidden;
    will-change: transform;
}

.card-rotate {
    transform: rotateY(180deg);
}

.card--front,
.card--back {
    -webkit-backface-visibility: hidden; /* Safari */
    backface-visibility: hidden;
    outline: 1px solid transparent;
}

.card--front {
    height: 100%;
    width: 100%;
    position: absolute;
    background-color: #fff;

    border: 6px #fff solid;
    border-radius: 6%;
    transform: rotateY(180deg);
}

.card--front img {
    width: 100%;
    height: 100%;
    border-radius: 5%;
}

.card-button {
    display: none;
    padding: 9px 18px 7px;
    box-shadow: -0.5px 0.5px 5px rgba(0, 0, 0, 0.1);
    border-radius: 100px;
    text-align: center;
    text-decoration: none;
    font-size: 1rem;
    line-height: 120%;
    font-family: 'PPMori', serif;
    color: #E8201C;
    background-color: #FFFFFF;
    
    position: absolute;
    z-index: 1;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: max-content;

    transition: box-shadow 0.4s ease-in-out, opacity 0.4s ease-in-out;
}

.card-button:hover {
    box-shadow: -1px 2px 10px rgba(0, 0, 0, 0.3);
}

.card-turned .card-button {
    display: block;
    opacity: 0;
}

.card-turned:hover .card-button {
    opacity: 1;
    pointer-events: all;
}

.card--back {
    height: 100%;
    width: 100%;
    position: absolute;
    background-image: url("/assets/images/global/Card-Backside-red.png");
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.game-reset {
    color: #fff;
    text-align: center;
    font-size: 2rem;
}

/*** VIEW MODE ***/

.projects {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.project {
    /* border: 1px solid #000; */
    border-radius: 10px;
    width: 49%;
    padding: 15px;
    margin-bottom: 50px;
    height: 100%;

    box-shadow: -1px 2px 10px rgba(0, 0, 0, 0);
    transition: box-shadow 0.4s ease-in-out;
}

.project:first-child {
    width: 100%;
}

.project:hover {
    box-shadow: -1px 2px 10px rgba(0, 0, 0, 0.2);

    transition: box-shadow 0.4s ease-in-out;
}

.project img {
    border-radius: 10px;
    height: 100%;
}

.project:last-child {
    margin-bottom: 0;
}

.project p {
    font-size: 1rem;
}


/****** PROJECT DETAIL ******/

body:has(.project-page--wrapper) {
    padding: 0px;
}

.project-page--wrapper {
    position: relative;
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-gap: 40px;

    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
}

.project-page--wrapper>section::-webkit-scrollbar {
    display: none;
  }

.project-page--wrapper>section {
    height: 100svh;
    overflow: scroll;
}

.project-media-wrapper{
    padding: 3rem 0rem 2rem 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.project-media-wrapper > div {
    padding-bottom: 200px;
}

.project-media-wrapper > div:first-of-type {
    padding-top: 3rem;
}

.project-info-wrapper {
    padding: 3rem 3rem 2rem 0rem;

}

.project-info-wrapper h2 {
    padding-bottom: 20px;
}

.project-info-wrapper p {
    font-size: 1.125rem;
    padding-bottom: 10px;
}

.project-info-wrapper p a {
    font-size: 1.125rem;
}

.project-info-wrapper a:hover {
    text-decoration: underline #20A3E5;
}

.back-button {
    position: absolute;
    top: 2rem;
    left: 3rem;
    background-color: #fff;
}

.project-description {
    padding-top: 10px;
}

.project-details {
    display: flex;
    justify-content: space-between;
    padding: 5px 0 5px;
}

.project-info-wrapper .project-details p {
    padding-bottom: 0px;
}


.project-media-wrapper > div img,
.project-media-wrapper > div video {
    width: auto;
    max-width: 100%;
    max-height: 85vh;
}

.project-media-collection {
    background-color: #FFFFFF;
    border-radius: 0.5rem;
    padding: 1.25rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding-bottom: 0.5rem;
}

.project-media-collection img {
    box-shadow: -1px 2px 10px rgba(0, 0, 0, 0.2);
    width: 49%;
    max-width: 25rem;
}


/****** CONTACT ******/

body:has(.contact-page) {
    padding: 0;
}

.contact-page main {
    position: relative;
    min-height: 100svh;
    padding: 3rem 3rem 2rem;
}

.contact-page main>section {
    padding-top: 4rem;
}

.contact-page .back-button {
    margin-bottom: 1rem;
}

.contact-page--card {
    position: absolute;
    right: 3rem;
    bottom: 2rem;
}

.card--contact {
    transform: rotate(3deg);
}

.card--contact img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/****** FOOTER ******/

footer {
    display: flex;
    justify-content: flex-end;
    height: 8rem;
    gap: 25px;
}

footer p {
    align-self: flex-end;
}


/****** IMPRINT ******/

.imprint-wrapper header {
    margin-bottom: 1rem;
    padding-top: 3rem;
}

.imprint-wrapper h2,
.imprint-wrapper h3,
.imprint-wrapper p {
    margin-bottom: 10px;
}

.imprint-wrapper h2 {
    margin-top: 25px;
}

.imprint-wrapper h3 {
    margin-top: 15px;
}


/****** RESPONSIVE ******/

/* Portrait */

/* @media (orientation: portrait) {
    .game {

        width: 100%;
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translate(-50%, -50%);
    }
} */

/* Big Screens */

@media only screen and (min-width: 1441px) {
    html {
        font-size: 20px;
    }

    body,
    .contact-page main {
        padding: 5rem 5rem 4rem;
    }

    .button {
        padding: 10px 20px 10px;
    } 

    .button:has(img) {
        padding: 10px 25px 10px;
    }

    .button img {
        width: 50px;
    }

    .back-button {
        top: 5rem;
        left: 5rem;
    }

    h1, h1 span {
        font-size: 4rem;
    }

    .play-mode footer {
        margin-top: 500px;
    }

    .game {
        max-width: 1500px;
        margin: 0 auto;
    }
  
    .card {
        width: 250px;
        height: 250px;
    }

    .card--front {    
        border: 9px #fff solid;
    }

    .project:first-child {
        width: 49%;
    }

    .project-media-wrapper {
        padding: 5rem 0rem 2rem 5rem;
    }

    .project-info-wrapper {
        padding: 5rem 5rem 2rem 0rem;
    }

    .project-media-wrapper > div:first-of-type {
        padding-top: 5rem;
    }

}

/* Small Dektop / Big Tablet */

@media only screen and (max-width: 1024px) {

    /****** PROJECT DETAIL ******/

    body:has(.project-page--wrapper) {
        padding: 3rem 3rem 2rem;
    }

    .project-page--wrapper {
        display: flex;
        flex-direction: column-reverse;
        padding-top: 4rem;
        grid-gap: 1rem;
    }

    .project-page--wrapper>section {
        height: auto;
        overflow: auto;
    }

    .project-media-wrapper{
        padding: 0;
    }

    .project-media-wrapper > div {
        padding-bottom: 50px;
    }

    .project-media-wrapper > div:first-of-type {
        padding-top: 0;
    }

    .project-info-wrapper {
        padding: 0;
    }

    .back-button {
        position: fixed;
        top: 2rem;
        left: 2rem;
        background-color: #fff;
    }

    .project-description {
        padding-top: 10px;
    }

    .project-details {
        display: flex;
        justify-content: space-between;
        padding: 5px 0 5px;
    }

    .project-info-wrapper .project-details p {
        padding-bottom: 0px;
    }


    .project-media-wrapper > div img,
    .project-media-wrapper > div video {
        width: auto;
        max-width: 100%;
        max-height: 85vh;
    }

    .project-media-collection {
        background-color: #FFFFFF;
        border-radius: 0.5rem;
        padding: 1.25rem;
        display: flex;
        flex-wrap: wrap;
        gap: 0.75rem;
        padding-bottom: 0.5rem;
    }

    .project-media-collection img {
        box-shadow: -1px 2px 10px rgba(0, 0, 0, 0.2);
        width: 49%;
        max-width: 25rem;
    }

}

/* Tablet */

@media only screen and (max-width: 768px) {
    html {
        font-size: 14px;
    }


    .card {
        width: 170px;
        height: 170px;
    }

    /* .card-button-container {
        opacity: 1;
    }

    .card-button-container .button {
        font-weight: normal;
        font-size: 0.75rem;
    } */

    .project {
        margin-bottom: 10px;
        width: 100%;
        box-shadow: -1px 2px 10px rgba(0, 0, 0, 0.1);
    }
}

/* Smartphone */

@media only screen and (max-width: 480px) {
    html {
        font-size: 12px;
      }

    body {
        padding: 2rem 2rem 1rem;
    }

    h1, h1 span {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }

    .button {
        padding: 7px 14px 5px;
        font-size: 1rem;
        font-weight: bold;
    }

    .button:has(img) {
        padding: 5px 14px 5px;
    }

    .button img {
        width: 80%;
    }

    .cards {
        gap: 5px;
    }

    .card {
        width: 100px;
        height: 100px;
    }

    body:has(.project-page--wrapper) {
        padding: 2rem 2rem 1rem;
    }
      
}
