


* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

main {
    width: 60vw;
    height: 60vh;
}

.book-container {
    width: 100%;
    height: 100%;
    padding: 20px;
    background-color: #ff000020;

    display: grid;
    grid-template-columns: 35px 1fr 35px;
    grid-template-rows: 1fr;
   
}

.book-container[data-pos="first"] #book-btn-previous,
.book-container[data-pos="last"] #book-btn-next {
    display: none;
}

.book-btn-container {
    display: flex;
    justify-content: center;
    align-items: center;
    align-self: center;
}

.book-btn {
    width: 30px;
    height: 30px;
    border: 1px solid tomato;
    background-color: tomato;
    border-radius: 200px;
    /*margin: 10px;*/
    display: flex;
    justify-content: center;
    align-items: center;
    align-self: center;
    user-select: none;
    cursor: pointer;
}

.book {
    position: relative;
    width: 100%;
    height: 100%;
    background-color: #0000ff20;
    transform-style: preserve-3d;
    perspective: 1000;
}

.page {
    position: absolute;
    left: 50%;
    width: 50%;
    height: 100%;
    transform-origin: left;
    transition: all 1000ms linear;
}

.page-front,
.page-back {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 1px solid black;
    background-color: #00ff00;
    z-index: 1;
    transition: 1000ms linear;
}

.page-front {
    z-index: 2;
}

.page-back {
    transform: rotateY(-180deg);
    background-color: yellow;
}

.flipped {
    transform: rotateY(-180deg);
}

.flipped .page-front {
    z-index: 1;
}

.book-page-sideinfo {
    position: absolute;
    bottom: 0;
    font-size: 12px;
    padding: 3px;
}

.page-front .book-page-sideinfo {
    right: 0;
}


