/*So proud of it I am gonna put my name on it*/
/* Author: Sigurður Birkir Sigurðsson */

#end-screen {
    position: absolute;
    width: 100%;
    height: 100%;
    max-height: 40em;
    min-height: 32em;
    top: 0;
    left: 0;
    z-index: 10;
    font-family: 'Barlow', sans-serif !important;
    transform: translate3d(0px, 92vh, 0px);
    transition: transform 0.8s, opacity 0.4s 0.4s;
    opacity: 0;
    pointer-events: none;
    margin-top: 4em;
}

#end-screen.showing {
    transition: transform 0.8s, opacity 0.4s;
    opacity: 1;
    transform: translate3d(0px, 0, 0px);

}

#end-screen-content {
    height: 100%;
    max-height: 30em;
    background: #01e5ae;
    border-radius: 24px;
    border: 4px solid #fdd619;
    overflow: hidden;
}

#end-screen-overview {
    text-align: center;
    padding-bottom: 0.5em;
    color: #01B0F0;
    /*margin: 1em 3em 0;*/
    font-size: 2em;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 2px;
    display: none;
}

#end-screen-confetti {
    position: absolute;
    z-index: 0;
    width: 100%;
    height: 80%;
    z-index: 9999;
    /*max-width: 100%;*/
    /*max-height: 100%;*/
    display: none;
}

#end-screen-content-left {
    /* height: 100%; */
    /* width: 65%; */
    /* float: left; */
    /* display: flex; */
    /* flex-direction: column; */
    /* justify-content: center; */
    /* align-items: center; */
    /* padding: 1.5em; */
    position: absolute;
    left: 0;
    top: 102px;
    height: 90%;
}

#end-screen-content-right {
    /*position: relative;*/
    /*height: 100%;*/
    /*width: 35%;*/
    /*float: right;*/

    /*display: flex;*/
    /*justify-content: center;*/
    /*align-items: center;*/
    position: absolute;
    right: 0;
    top: 5em;
    left: 0;
    margin: 0 auto;
}

#end-screen-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: -6em;
    padding: 0 2.15rem;
}

#end-screen-buttons button {
    font-size: 1.8em;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 2px;
    width: 10em;
    max-width: 48%;
    border-radius: 10px;
}

#pose-and-background-wrapper {
    position: relative;
    height: 100%;

    display: flex;
    justify-content: center;
    align-items: center;

    /*TODO Enable below with javascript when no background is present to move end-title and prize-pose closer together*/
    margin-left: 12em;
}

#pose-wrapper {
    position: relative;
    /*max-height: 100%;*/
    /*max-width: 14em;*/
}

#pose-wrapper img{
    max-height: 100%;
    width: 14em; /*THIS CONTROLS THE SIZE OF THE PRIZE-POSE*/
}

#end-title {
    z-index: 1;
    border-radius: 8px;
    background: #fdd618;
    padding: 2px 16px;
    display: inline-table;
    height: 50px;
    /*TODO Enable below with javascript when no background is present to move end-title and prize-pose closer together*/
}

#end-title-progress {
    font-size: 1em;
    font-weight: 600;
    letter-spacing: 1px;
}

#end-title-progress strong {
    font-size: 1.5em;
}

#end-title-expression {
    font-size: 1.8em;
    margin-left: 2.5em;
    color: white;
    font-weight: 600;
    letter-spacing: 1px;
}

#end-screen-reward {
    /*TODO Set this depending on every prize with javascript*/
    /*width: 50px !important;*/
    /*top: 0;*/
    /*left: 40px;*/

    width: 80px !important;
    left: 15px;
    bottom: 90px;
}

#end-screen-reward-background {
    height: 90% !important;

    /* This is needed for iOS devices to center a absolute element because flex-box doesn't do the job*/
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 100%;
}

.continue-btn {
    background-color: #01B0F0;
    color: white;
}

.tryagain-btn {
    border-radius: 10px;
    padding: 8px 12px;
    background-color: #ba9bc9;
    color: white;
}

.endscreen-signup-btn {
    font-size: 2em;
    margin: 0 0.2em;
    color: white;
    background: rgb(63, 197, 255);
    border-radius: 2em;
    box-shadow: 0px 0px 12px white;
}

.nav-chapter {
    text-align: center;
    font-size: 2em;
    position: absolute;
    top: 21.3rem;
    right: 2rem;
    color: white;
    /*text-transform: uppercase;*/
    letter-spacing: 0.5px;
    font-weight: 700;
    text-shadow: -1px -1px 3px #40525a1f;
    pointer-events: none;
    z-index: 1;
}

#next-chapter {

}

#prev-chapter {
    left: 2rem;
    right: auto;
}

#prizeImg {
    width: 40px;
    float: left;
    margin: 12px 0px 0px 10px;
    display: block;
}

.bubble {
    position: relative;
    font-size: 22px;
    line-height: 26px;
    width: 13em;
    background: #fdd619;
    border-radius: 8px;
    padding: 20px;
    margin-left: 4em;
    text-align: center;
    color: #333;
    font-weight: 600;
    box-shadow: -1px -1px 12px #40525a1f;
    /*text-transform: uppercase;*/
}

.bubble-bottom-left:after {
    content: "";
    width: 0px;
    height: 0px;
    position: absolute;
    border-left: 8px solid #fdd619;
    border-right: 15px solid transparent;
    border-top: 7px solid transparent;
    border-bottom: 15px solid #fdd619;
    right: -20px;
    top: 28px;
}

/************ TABLET *************/
@media (max-width: 1024px) {
    #previous-next.hide-up {
        transform: translate3d(0, 0, 0);
    }
    #end-screen.showing {
        transform: translate3d(0px, 70px, 0px);
    }
}

/************ MOBILE *************/
@media (max-width: 767px) {

    #end-screen.showing {
        transform: translate3d(0px, 0, 0px);
        height: calc(100vh - 130px);
        margin: 0;
    }


    #end-screen-content {
        height: 96%;
        margin: 10px;
        max-height: none;
    }


    #end-screen-buttons {
        margin: -9rem 0 0;
        width: auto;
    }

    #end-screen-overview {
        margin: 8px 0 0;
        padding: 0;
    }

    #end-screen-confetti {
        height: 95%;
        width: 90%;
        margin: 2em 0 0 2em;
    }


    #end-title {
        width: auto;
    }

    #end-title-progress {
        margin-right: 0.5em;
    }

    #end-title-expression {
        margin: 0;
    }

    #end-screen-buttons button {
        width: 12em;
        font-size: 1.2em;
    }

    #end-screen-content-right {
        width: 40%;
        top: 170px;
    }


    #end-screen-content-left {
        top: -20px;
        left: 20px;
    }

    .back-stars {
        width: auto;
        height: 100%;
    }

    .nav-chapter {
        top: 37vh;
        font-size: 7vw;
    }

    .bubble-bottom-left:after {
        border-right: 8px solid #FDD619;
        border-left: 15px solid transparent;
        border-bottom: 7px solid transparent;
        border-top: 15px solid #FDD619;
        left: auto;
        top: auto;
        right: 15vw;
        bottom: -20px;
    }
    .bubble {
        margin: 3em 7em 0 0;
        width: 60%;
        padding: 15px;
    }


    #prizeImg {
        margin: 1.25em 0 0 2px;
        width: 2em;
    }

    #pose-and-background-wrapper {
        margin: 0 auto;
    }

    #pose-wrapper img{
        width: 13em; /*THIS CONTROLS THE SIZE OF THE PRIZE-POSE*/
    }

    #pose-wrapper {
        scale: 90%;
        margin-bottom: 0em;
    }

    .tryagain-btn-btn {
        margin: 5px 0;
    }

}


