:root {
    --bb-bg: #fff5f8;
    /* light pink */
    --bb-card: #ffffff;
    --bb-accent: #ff7aa2;
    /* warm pink accent */
    --bb-accent-2: #ffd2e1;
    /* softer pink */
    --bb-text: #2b2b2b;
}

body {
    background: var(--bb-bg);
    color: var(--bb-text);
}

.bb-hero {
    background: linear-gradient(135deg, var(--bb-accent-2), #fff);
    border-radius: 1.25rem;
    padding: 2rem 1.25rem;
}

.bb-search {
    background: #fff;
    border-radius: 999px;
    padding: .35rem .5rem .35rem .75rem;
    box-shadow: 0 4px 16px rgba(255, 122, 162, .15);
}

.bb-btn {
    background: var(--bb-accent);
    border: none;
    color: #fff;
    font-weight: 600;
    width: 100%;
}

.bb-btn:hover {
    filter: brightness(0.95);
}

.bb-card {
    background: var(--bb-card);
    border: 1px solid #f8c9d7;
    border-radius: 1rem;
    box-shadow: 0 6px 20px rgba(255, 122, 162, .12);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.bb-card .p-3 {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.action-btn {
    margin-top: auto;
}


.bb-cover {
    width: 100%;
    aspect-ratio: 3/4;
    object-fit: cover;
    border-top-left-radius: 1rem;
    border-top-right-radius: 1rem;
    background: #fde7ef;
}

.bb-rating {
    font-weight: 600;
}

footer {
    border-top: 1px solid #f3b9cb;
    color: #6b6b6b;
}

.bb-pagination .page-link {
    border-radius: .75rem;
}

.bb-badge {
    background: #fff;
    border: 1px dashed var(--bb-accent);
    color: var(--bb-accent);
    padding: .35rem .6rem;
    border-radius: .75rem;
    font-weight: 600;
}

.bb-desc {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2em;
    max-height: calc(1.2em * 3);
    min-height: unset;
}

.bb-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.6em;
}

.text-decoration-line-through {
    opacity: 0.7;
}

.fw-bold.text-success {
    font-size: 1.1rem;
}

.related-book-card {
    max-width: 200px;
    margin: auto;
}

.related-book-img {
    height: 220px;
    object-fit: contain;
    background: #f8f9fa;
    padding: 8px;
}

h1.display-6 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

.faq-item {
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    margin-bottom: 0.75rem;
    background: #fff;
    transition: box-shadow 0.2s ease;
}

.faq-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.faq-question {
    padding: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-answer {
    padding: 0 1rem 1rem;
    display: none;
    color: #555;
    line-height: 1.5;
}

.faq-item.active .faq-answer {
    display: block;
}

.faq-icon {
    font-size: 1.2rem;
    transition: transform 0.2s ease;
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
}

.cover-wrapper {
    position: relative;
    overflow: hidden;
}

.best-seller-ribbon {
    position: absolute;
    top: 10px;
    left: -42px;
    width: 120px;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: #000;
    font-weight: bold;
    font-size: 11px;
    text-align: center;
    line-height: 20px;
    transform: rotate(-45deg);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

#hero-posters .carousel-item {
    height: 220px;
}

@media (min-width: 768px) {
    #hero-posters .carousel-item {
        height: 55vh;
    }
}

@media (min-width: 1200px) {
    #hero-posters .carousel-item {
        height: 90vh;
    }
}

#hero-posters .carousel-item img {
    height: 100% !important;
    width: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

#hero-posters .carousel-item::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.12));
    pointer-events: none;
}

#hero-posters .carousel-caption {
    bottom: 0.75rem;
}

/* Statistics */
.stats-banner h2 {
    font-size: 2rem;
    font-weight: bold;
}

.stats-banner .lead {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.stats-row h3 {
    font-size: 1.75rem;
    color: var(--bb-accent);
    margin-bottom: 0.25rem;
}

.stats-row p {
    margin: 0;
    font-size: 1rem;
    color: #555;
}

#categories-carousel {
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}
