@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');

*{
    box-sizing: border-box;
}

body{
    font-family: 'Roboto', sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0;
    width: 100%;
    background-color: #efedd6;
    overflow-x: hidden;
}

h1{
    margin: 10px;
}

.box{
    background-color: slategray;
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 400px;
    height: 200px;
    margin: 10px;
    border-radius: 10px;
    box-shadow: 2px 4px 5px rgba(0, 0, 0, 0.27);
    transform: translateX(400%);
    transition: transform 0.4s ease;
}

.box:nth-of-type(even){
    transform: translateX(-400%);
}

.box.show{
    transform: translateX(0);
}

.box h2 {
    font-size: 45px;
}