/**
 * ==================================================
 * BOOKS
 * Francesco Cugini Theme
 * ==================================================
 */

.books{

    background:var(--color-background);

}

.books-grid{

    display:grid;

    grid-template-columns:repeat(auto-fit,minmax(280px,1fr));

    gap:2.5rem;

    margin-top:4rem;

}

.book-card{

    display:flex;

    flex-direction:column;

    background:var(--color-surface);

    border-radius:var(--radius-lg);

    overflow:hidden;

    box-shadow:var(--shadow-md);

    transition:
        transform var(--transition),
        box-shadow var(--transition);

}

.book-card:hover{

    transform:translateY(-8px);

    box-shadow:var(--shadow-xl);

}

.book-cover{

    display:block;

    overflow:hidden;

}

.book-image{

    width:100%;

    aspect-ratio:2/3;

    object-fit:cover;

    transition:transform .6s ease;

}

.book-card:hover .book-image{

    transform:scale(1.04);

}

.book-content{

    display:flex;

    flex-direction:column;

    flex:1;

    padding:2rem;

}

.book-title{

    margin-bottom:1rem;

    font-size:1.5rem;

}

.book-title a{

    color:inherit;

    text-decoration:none;

}

.book-title a:hover{

    color:var(--color-accent);

}

.book-excerpt{

    flex:1;

    margin-bottom:2rem;

    color:var(--color-text-light);

}

.book-excerpt p:last-child{

    margin-bottom:0;

}

.book-content .btn{

    align-self:flex-start;

}

@media (max-width:768px){

    .book-content{

        text-align:center;

    }

    .book-content .btn{

        align-self:center;

    }

}