* {
    box-sizing: border-box;
}

:root {
    --black: #1e1e1e;
    --sand: #FFECC5;
    --rose: #E77658;
    --light-rose: #F1C1B4;
    --yellow: #F2BC41;
    --green: #009D5C;
    --light-green: #9CD9BA;
    --blue: #6BA6D6;
    --light-blue: #C2D2DF;
}

/* stock styling */

body {
    max-width: 540px;
    margin: 0 auto;
    background-color: var(--sand);
    font-family: "baloo-2", sans-serif;
    font-weight: 700;
    font-style: normal;
    overflow: hidden;
}

@keyframes bob {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

#splash-screen {
    background-image: url(img/splash-mobile.png);
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    position: absolute;
    z-index: 999;
    width: 100vw;
    height: 100%;
    overflow-x: hidden;
    transition: 1s ease;
    display: flex;
    justify-content: center;
    align-items: flex-end;
}

#splash-title {
    width: 80%;
    max-width: 400px;
    margin-bottom: 20%;
    animation: bob 3s ease-in-out infinite;

    h1 {
        color: var(--sand);
        font-size: 4rem;
        margin: 0;
        text-align: center;
        line-height: 4rem;
    }
}

#skip-btn {
    width: 150px;
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 10;
    border-radius: 15px;
    padding: 15px 30px;
    color: var(--black);
    background-color: var(--light-blue);
    border: 3px solid var(--blue);
    text-decoration: none;
    white-space: nowrap;
    margin: 15px;
}

/* videos */

#cutscene-container {
    position: absolute;
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: var(--black);
    z-index: 998;
    transition: 1s;
    max-width: 540px;

    video {
        width: 100%;
    }
}

#main-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;

}

#games-container {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    gap: 5vw;
    padding: 0 10vw;
    scroll-behavior: smooth;
}


#games-container>.game-container,
#games-container>.cutscene {
    scroll-snap-align: center;
    flex: 0 0 100%;
    width: 80%;
    max-width: 300px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
}

.cutscene {
    flex-direction: column !important;
    justify-content: center !important;
}

.game-container video,
.cutscene img {
    flex: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

#games-container::-webkit-scrollbar {
    display: none;
}

#main-logo {
    width: 30%;
    max-width: 200px;
    margin: 0 auto;
    padding: 15px 0;
}

/* game containers */

.game-container,
.cutscene {
    border-radius: 25px;
    overflow: hidden;

    opacity: 80%;
    transform: scale(80%);
}

.level-title {
    text-align: center;
    color: var(--black);

    h1 {
        margin: 0;
        font-size: clamp(0.5rem, 8vw, 2rem);
    }

    h4 {
        margin: 0;
        font-weight: 300;

    }
}

.score-display {
    color: var(--black);
    border-radius: 15px;
    position: absolute;
    top: 81%;
    left: 50%;
    transform: translateX(-50%);

    p {
        margin: 5px;
        font-size: clamp(0.5rem, 5vw, 1rem);
        white-space: nowrap;
    }
}

#volcano-climb {
    background-color: var(--light-rose);
    border: 3px solid var(--rose);
    border-radius: 25px;

    video {
        border-top: 3px solid var(--rose);
    }

    .score-display {
        background-color: var(--light-rose);
        border: 3px solid var(--rose);
    }
}

#wispy-forest {
    background-color: var(--light-green);
    border: 3px solid var(--green);
    border-radius: 25px;


    video {
        border-top: 3px solid var(--green);
        border-bottom: 3px solid var(--green);
    }

    .score-display {
        background-color: var(--light-green);
        border: 3px solid var(--green);
    }
}

#ocean-run {
    height: 100%;
    background-color: var(--light-blue);
    border: 3px solid var(--blue);
    border-radius: 25px;

    .score-display {
        background-color: var(--light-blue);
        border: 3px solid var(--blue);
    }
}

#lower-content {
    display: flex;
    justify-content: center;
    width: 100%;
    height: 100%;

    h4 {
        margin: 5px;
        color: var(--black);
    }
}

#takahe-container {
    position: relative;
    width: 100%;
    border-top: 3px solid var(--blue);
}

#takahe {
    position: absolute;
    width: 35%;
    top: 20%;
    right: 5%;
    cursor: pointer;
    pointer-events: all;
    z-index: 99;
}

#cliff-video {
    object-fit: cover;
    width: 100%;
}

#speach-bubble {
    position: absolute;
    top: 10%;
    left: 5%;
    width: 50%;
    border-radius: 25px;
    border: 3px solid var(--yellow);
    background-color: var(--sand);

    p {
        padding: 5px;
        font-weight: 100;
        line-height: 18px;
        color: var(--black);
    }
}

#speach-bubble-triangle {
    position: absolute;
    right: -25px;
    bottom: 10%;
    width: 0;
    height: 0;
    border-top: 25px solid transparent;
    border-bottom: 25px solid transparent;
    border-left: 50px solid var(--sand);
}

.focused-game {
    opacity: 100%;
    transform: scale(100%);
    transition: 0.3s;
}

/* level progression */

.kite-piece-pos {
    position: absolute;
    width: 15%;
    left: 10%;
    top: 25%;
}

#kite-head {
    display: none;
}

#kite-body {
    transform: rotate(20deg);
    display: none;
}

#kite-back {
    width: 25% !important;
    transform: rotate(-10deg);
    display: none;
}

#final-cutscene-select {
    pointer-events: none;
}

@media screen and (min-width: 769px) {
    #splash-screen {
        left: 0;
        background-image: url(img/splash-screen-desktop.png);
    }
}