[id]{
    scroll-margin-top: 150px;
}

.header{
    width: min(1100px, 85%);
    text-align: center;
    text-wrap: balance;
}

.header>p{
    font-size: 1.2em;
    font-weight: 300;
    font-style: italic;
}

section>h2{
    padding-inline: 5%;
}

/* Book list */
.collections{
    display: flex;
    flex-wrap: wrap;
    gap: 1em;
    margin-inline: 5%;
}

.book{
    flex: 0 0 calc((100% - 1em) / 2);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 1em;
    filter: grayscale(50%);
}

.book:hover{
    filter: grayscale(0);
    background-color: var(--grey);
    cursor: pointer;
}

.book>p{
    text-align: center;
}

.book>img{
    height: auto;
    max-height: 594px;
    width: 80%;
    max-width: 420px;
    pointer-events: none;
}

/* Image collections */
.collections{
    position: relative;
}

.collection-buttons{
    position: absolute;
    top: 50%;
    left: -2.5%;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    height: 20%;
    min-height: 32px;
    width: 105%;
    pointer-events: none;
}

.collection-buttons>button{
    aspect-ratio: 1/1;
    background-color: var(--black);
    border-radius: 50%;
    pointer-events: all;
}

.collection-buttons>button:hover{
    background-color: var(--shadow-2);
}

.collection-buttons>button>img{
    height: 100%;
    width: 60%;
}

.collections div.carousel{
    display: flex;
    gap: 1em;
    width: 100%;
    cursor: grab;
    overflow: hidden;
}

.collections>div.carousel.dragging{
    cursor: grabbing;
    scroll-behavior: auto;
}

.collections>div.carousel.dragging>.cart{
    pointer-events: none;
    cursor: grabbing;
}

div.carousel>.cart{
    position: relative;
    user-select: none;
    -webkit-user-drag: none;
}

div.carousel>.cart>img{
    object-fit: contain;
    pointer-events: none;
}

/* Book window */
.window{
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100lvh;
    z-index: 100;
}

.window iframe{
    width: 100%;
    height: 100lvh;
    background-color: rgba(255, 255, 255, 0.7);
}

.window>.book-close{
    position: absolute;
    top: 10%;
    right: 5%;
    height: 3em;
    aspect-ratio: 1/1;
    transition: 300ms;
    z-index: 1000;
}


.window>.book-close:hover{
    transform: rotate(90deg);
    cursor: pointer;
}

@media (min-width: 761px){
    .book{
        flex: 0 0 calc((100% - 2em) / 3);
        padding-top: 2em;
    }

    .book>img{
        width: 90%;
    }

    .book>.comming-soon>img{
        width: 90%;
    }

    .book>.comming-soon>p{
        top: 22%;
        font-size: 1.8em;
    }
}

@media (min-width: 1166px){
    section>h2{
        max-width: 1250px;
        padding-inline: 1em;
        margin-inline: auto;
    }

    .book{
        flex: 0 0 calc((100% - 3em) / 4);
        padding-top: 2em;
    }

.collection-buttons{
    left: 0%;
    width: 100%;
}
}