* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: #fff;
    padding-bottom: 50px;
}

.main-content {
    width: 90%;
    max-width: 1200px;
    margin: 30px auto;
}

.shelf-container h2,
.discovery-section h2 {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: var(--text);
}

.shelf-card {
    background-color: #f6f1ed;
    border-radius: 18px;
    padding: 32px;
    display: flex;
    gap: 32px;
    margin-bottom: 40px;
    align-items: flex-start;
}

.shelf-header {
    flex: 0 0 220px;
}

.shelf-header h3 {
    margin-bottom: 20px;
    font-size: 1rem;
    line-height: 1.4;
    color: var(--text);
}

.shelf-content {
    flex: 1;
    min-width: 0;
}

.book-list {
    display: flex;
    gap: 25px;
    flex-wrap: wrap;
}

.book-item {
    text-align: center;
    width: 120px;
    text-decoration: none;
    color: inherit;
}

.cover-wrap {
    width: 100%;
    margin-bottom: 10px;

    border-radius: 10px;
    overflow: hidden;

    box-shadow:
            0 2px 6px rgba(0,0,0,0.12),
            0 10px 24px rgba(0,0,0,0.18),
            0 0 0 1px rgba(0, 0, 0, 0.05);
}

.cover,
.cover-image {
    width: 100%;
    height: 170px;
    display: block;
    object-fit: cover;
    border-radius: 0;
}

.cover-image {
    object-fit: cover;
    background: #eee;
}

.cover-placeholder {
    background-color: #9e9e9e;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 2rem;
    font-weight: 700;
}

.book-item p {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.35;
    margin-bottom: 4px;
}

.book-item span {
    font-size: 0.75rem;
    color: #666;
    line-height: 1.4;
    display: block;
}

.shelf-empty {
    padding: 18px;
    border: 1px dashed #d7ccc8;
    border-radius: 12px;
    background: #fff;
    color: #666;
    font-size: 0.9rem;
}

.btn-red {
    display: inline-block;
    background-color: #ff4d4d;
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.2s ease;
}

.btn-red:hover {
    background-color: #e43c3c;
}

.discovery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 15px;
}

.disc-card {
    height: 220px;
    padding: 25px;
    border-radius: 12px;
    color: white;
    text-decoration: none;
    display: block;
}

.disc-button {
    border: none;
    text-align: left;
    cursor: pointer;
}

.disc-card h3 {
    font-size: 1.9rem;
    margin-bottom: 10px;
    line-height: 1.15;
}

.disc-card p {
    font-size: 1rem;
    line-height: 1.5;
}

.disc-card.red { background-color: #ff5e5e; }
.disc-card.dark { background-color: #3b110e; }
.disc-card.pink { background-color: #ff7a7a; }

@media (max-width: 980px) {
    .shelf-card {
        flex-direction: column;
    }

    .shelf-header {
        flex: unset;
        width: 100%;
    }

    .discovery-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .main-content {
        width: calc(100% - 28px);
        margin: 20px auto;
    }

    .shelf-card {
        padding: 20px;
    }

    .book-list {
        gap: 18px;
    }

    .book-item {
        width: 110px;
    }

    .cover,
    .cover-image {
        height: 155px;
    }

    .disc-card h3 {
        font-size: 1.5rem;
    }
}