/* ===========================================================
   Books page (books.html) — light source of truth.
   Dark overrides live in css/theme.css, loaded after this.
   =========================================================== */

body {
    line-height: 1.6;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

h1 {
    text-align: center;
    margin-bottom: 40px;
    color: #2c3e50;
    font-size: 2rem;
}

.intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.1em;
    color: #555;
}

.book-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 30px;
}

.book-card {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.book-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.book-cover {
    height: 240px;
    background-color: #eee;
    display: flex;
    align-items: center;
    justify-content: center;
}

.book-cover img {
    max-height: 100%;
    max-width: 100%;
    object-fit: cover;
}

.book-info {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.book-title {
    font-size: 1em;
    font-weight: 600;
    margin: 0 0 5px;
    color: #2c3e50;
}

.book-author {
    font-size: 0.9em;
    color: #7f8c8d;
    margin: 0 0 10px;
}

.book-note {
    font-size: 0.85em;
    color: #555;
    margin-top: auto;
    font-style: italic;
}

@media (max-width: 768px) {
    .book-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 20px;
    }

    .book-cover {
        height: 200px;
    }
}
