/* ANIMATIONS ----------------------------------------- */
@-webkit-keyframes play {
    0% {
        background-position: 0 0;
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    100% {
        background-position: -22308px 0;
        opacity: 1;
    }
}
@keyframes play {
    0% {
        background-position: 0 0;
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    100% {
        background-position: -22308px 0;
        opacity: 1;
    }
}
@-webkit-keyframes fall-n-swing {
    0% {
        transform: rotateZ(7deg) translate(-2px, -9px);
    }
    25% {
        transform: rotateZ(-7deg);
    }
    50% {
        transform: rotateZ(2deg);
    }
    75% {
        transform: rotateZ(-.3deg);
    }
    100% {
        transform: rotateZ(0deg);
    }
}
@keyframes fall-n-swing {
    0% {
        transform: rotateZ(7deg) translate(-2px, -9px);
    }
    25% {
        transform: rotateZ(-7deg);
    }
    50% {
        transform: rotateZ(2deg);
    }
    75% {
        transform: rotateZ(-.3deg);
    }
    100% {
        transform: rotateZ(0deg);
    }
}
@-webkit-keyframes remove-rope {
    0% {
        top: 5vh;
    }
    100% {
        top: 0vh;
    }
}
@-moz-keyframes remove-rope {
    0% {
        top: 5vh;
    }
    100% {
        top: 0vh;
    }
}
@-o-keyframes remove-rope {
    0% {
        top: 5vh;
    }
    100% {
        top: 0vh;
    }
}
@keyframes remove-rope {
    0% {
        top: 5vh;
    }
    100% {
        top: 0vh;
    }
}



@-webkit-keyframes fall {
    0% {
        background-image: url('/assets/images/rico-animation/rico-01.png');
        opacity: 1;
        top: -200px;
        left: -160px;
    }
    44% {
        background-image: url('/assets/images/rico-animation/rico-01.png');
        opacity: 1;
        top: -200px;
        left: -160px;
    }
    45% {
        background-image: url('/assets/images/rico-animation/rico-02.png');
        opacity: 1;
        top: -100px;
        left: -90px;
    }
    69% {
        opacity: 1;
        top: -100px;
        left: -90px;
    }
    70% {
        opacity: 0;
        top: -100px;
        left: -90px;
    }
}
@keyframes fall {
    0% {
        background-image: url('/assets/images/rico-animation/rico-01.png');
        opacity: 1;
        top: -300px;
        left: -160px;
    }
    32% {
        background-image: url('/assets/images/rico-animation/rico-01.png');
        opacity: 1;
        top: -300px;
        left: -160px;
    }
    33% {
        background-image: url('/assets/images/rico-animation/rico-02.png');
        opacity: 1;
        top: -300px;
        left: -90px;
    }
    42% {
        opacity: 1;
        top: -300px;
        left: -90px;
    }
    43% {
        opacity: 0;
        top: -300px;
        left: -90px;
    }
}


#rico-animation {
    height: 100vh;
    width: 100%;
    position: absolute;
    top: 0;
    left: 0;
    text-align: right;
    z-index: 3;
    overflow: hidden;
    display: none;
}
#rico-animation .holder {
    position: absolute;
    height: calc(100vh + 200px);
    width: 100%;
    margin: 0 auto;
    overflow: hidden;
}
#rico-animation .wrapper {
    position: relative;
    height: 100%;
    height: calc(100% + 200px);
    margin-top: -200px;
}
#rico-animation .segment {
    position: absolute;
    z-index: 1;
    left: 0;
    top: 7vh;
    height: 10vh;
    width: 6px;
    background: #A3793F;
    transform-origin: top center;
    border-radius: 100%;
    backface-visibility: hidden;
    display: none;
    -webkit-box-shadow: -20px 15px 10px 0px rgba(0,0,0,.3);
    box-shadow: -20px 15px 10px 0px rgba(0,0,0,.3);
}

#rico-animation .first-segment {
    left: 60%;
}

#rico-animation .rico {
    top: -200px;
    left: -270px;
    background-repeat: no-repeat;
    background-color: transparent;
    background-image: url('/assets/images/rico-animation/rico-02.png');
    border-radius: 0;
    width: 295px;
    height: 332px;
    display: block;
    opacity: 0;
    -webkit-box-shadow: none;
    box-shadow: none;
}
#rico-animation #static-ani {
    position: absolute;
    bottom: 0;
    right: 230px;
    width:676px;
    height: 339px;
    background: url('/assets/images/rico-animation/sprite.png') no-repeat 0 0;
    z-index: 2;
    opacity: 1;
}
#figure-ani {
    width:676px;
    height: 339px;
    background: url('/assets/images/rico-animation/sprite.png') no-repeat 0 0;
    z-index: 2;
    opacity: 1;
    position: absolute;
    left: -310px;
    top: -250px;
}
#figure-ani .txt {
    position:absolute;
    right:40px !important;
    bottom:100px !important;
    font-family: var(--secondary-font);
    color:#fff;
    font-size:36px;
    line-height:36px
}

.animate-rico #rico-animation {
    display: block;
}
.animate-rico #rico-animation .segment {
    animation-timing-function: ease-in-out;
    animation: fall-n-swing 4s 1, remove-rope 1s 3s 1;
    animation-fill-mode: forwards;
    display: block;
}
.animate-rico #rico-animation .rico {
    animation: fall 3s 1;
    animation-fill-mode: forwards;
}
.animate-rico #rico-animation #static-ani,
.animate-rico #figure-ani {
    animation: play 2s steps(33) 1.15s 1;
    animation-fill-mode: forwards;
}

