body{
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    height: 100vh;
    justify-content: center;
    background-color: black;
}

.images{
    width: 200px;
    height: 200px;
    transform-style: preserve-3d;
    transform: perspective(1000px) rotateY(0deg);
    transition: 1s transform;
}

.images span{
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    transform: rotateY(calc(var(--i)*45deg)) translateZ(400px);

}

.images span img{
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    background: white;
    border-radius: 5px;
}

.buttons{
    position: relative;
    width: 80%;
    /* justify-content: space-between; */
}

.btn{
    position: absolute;
    bottom: -80px;
    background-color: slateblue;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
}

.btn:hover{
    filter: brightness(1.5);
}

#prev{
    left: 20%;
}

#next{
    right: 20%;
}

#rot{
    transform: translateX(-50%);
}

.btnDir{
    color: white;
    font-size: 20px;
    text-align: center;
    position: absolute;
    bottom: -83px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    box-shadow: 2px 2px 3px rgba(255, 255, 255, .4), -2px -2px 3px rgba(255, 255, 255, .4), 2px -2px 3px rgba(255, 255, 255, .4), -2px 2px 3px rgba(255, 255, 255, .4);
    background-color: black;
    border: none;
    cursor: pointer;
}

#right{
    right: 34%;
}

#left{
    left: 34%;
}

.btnDir:hover{
    background: #1f1f1f;
}