body {
    margin: 0;
    padding: 0;
    font-family: sans-serif;
    background-color: indianred;
}

.box {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);    
    width: 1000px;
    height: 150px;
}

.box .face {
    position: absolute;
    width: 500px;
    height: 150px;
    font-size: 6em;
    text-align: center;
    line-height: 150px;
    overflow: hidden;
}

.box .face span {
    width: 100%;
    height: 100%;
    display: block;
    transition: .5s;
}

.box .face.face1 {
    background-color: green;
    color: white;
    transform-origin: left;
    left: 0;
    transform: perspective(800px) rotateY(-64.02deg);
}

.box .face.face2 {
    background-color: lime;
    color: red;
    transform-origin: right;
    right: 0;
    transform: perspective(800px) rotateY(64.02deg);
}

.box .face.face1 span {
    position: absolute;
    animation: animation1 10s linear infinite;
}

@keyframes animation1 {
    0% {
        left: 200%;
    }
    100% {
        left: -100%;
    }
}

.box .face.face2 span {
    position: absolute;
    animation: animation2 10s linear infinite;
}

@keyframes animation2 {
    0% {
        left: 100%;
    }
    100% {
        left: -200%;
    }
}













