/* ========================================
   The Voice 24 - AI News Portal
   Clean, Text-Centric Design
   Inspired by BBC Bangla & Prothom Alo
   ======================================== */

/* ---------- Root Variables ---------- */
:root {
    --primary: #d32f2f;
    --primary-dark: #b71c1c;
    --secondary: #1a1a2e;
    --text-dark: #1a1a1a;
    --text-body: #333333;
    --text-muted: #6c757d;
    --text-light: #999999;
    --border-color: #e0e0e0;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --bg-dark: #1a1a2e;
    --accent-blue: #1565c0;
    --font-bangla: 'Noto Sans Bengali', 'SolaimanLipi', 'Kalpurush', sans-serif;
    --font-english: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
    --shadow-md: 0 2px 8px rgba(0,0,0,0.1);
    --transition: all 0.2s ease;
}

/* ---------- Base Reset & Typography ---------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-bangla);
    color: var(--text-body);
    background: var(--bg-light);
    line-height: 1.8;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--text-dark);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary);
}

img {
    max-width: 100%;
    height: auto;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.4;
    color: var(--text-dark);
}

/* ---------- Utility Classes ---------- */
.section-divider {
    border: none;
    border-top: 1px solid var(--border-color);
    margin: 0;
}

.text-primary-red {
    color: var(--primary) !important;
}

.bg-primary-red {
    background-color: var(--primary) !important;
}

/* ---------- Breaking News Ticker ---------- */
.breaking-news-bar {
    background: var(--primary);
    color: #fff;
    padding: 8px 0;
    font-size: 14px;
    overflow: hidden;
}

.breaking-news-bar .label {
    background: var(--primary-dark);
    padding: 4px 16px;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.5px;
    display: inline-block;
    white-space: nowrap;
    border-radius: 2px;
}

.breaking-news-bar .ticker-wrap {
    overflow: hidden;
    flex: 1;
    margin-left: 12px;
}

.breaking-news-bar .ticker {
    display: flex;
    animation: ticker 30s linear infinite;
    white-space: nowrap;
}

.breaking-news-bar .ticker a {
    color: #fff;
    margin-right: 60px;
    font-size: 14px;
}

.breaking-news-bar .ticker a:hover {
    text-decoration: underline;
    color: #fff;
}

@keyframes ticker {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ---------- Top Bar ---------- */
.top-bar {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    padding: 6px 0;
    font-size: 13px;
    color: var(--text-muted);
}

.top-bar a {
    color: var(--text-muted);
    font-size: 13px;
}

.top-bar a:hover {
    color: var(--primary);
}

.top-bar .social-links a {
    margin-left: 12px;
    font-size: 15px;
}

/* ---------- Header / Navbar ---------- */
.main-header {
    background: var(--bg-white);
    border-bottom: 3px solid var(--primary);
    position: sticky;
    top: 0;
    z-index: 1050;
    box-shadow: var(--shadow-sm);
}

.main-header .logo-area {
    padding: 12px 0;
}

.main-header .logo-area .site-logo {
    font-size: 32px;
    font-weight: 800;
    color: var(--secondary);
    letter-spacing: -0.5px;
}

.main-header .logo-area .site-logo span {
    color: var(--primary);
}

.main-header .logo-area .tagline {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: -4px;
}

.main-nav {
    background: var(--secondary);
}

.main-nav .navbar-nav .nav-link {
    color: rgba(255,255,255,0.9);
    font-size: 15px;
    font-weight: 500;
    padding: 10px 16px;
    transition: var(--transition);
    white-space: nowrap;
}

.main-nav .navbar-nav .nav-link:hover,
.main-nav .navbar-nav .nav-link.active {
    color: #fff;
    background: var(--primary);
}

.main-nav .navbar-toggler {
    border-color: rgba(255,255,255,0.3);
    padding: 4px 10px;
}

.main-nav .navbar-toggler-icon {
    filter: invert(1);
}

.header-search .form-control {
    border-radius: 20px 0 0 20px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.1);
    color: #fff;
    font-size: 14px;
    padding: 6px 16px;
}

.header-search .form-control::placeholder {
    color: rgba(255,255,255,0.5);
}

.header-search .btn {
    border-radius: 0 20px 20px 0;
    background: var(--primary);
    border: 1px solid var(--primary);
    color: #fff;
    padding: 6px 16px;
}

/* ---------- Section Headers ---------- */
.section-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}

.section-header h2 {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-dark);
    position: relative;
    padding-left: 14px;
}

.section-header h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 2px;
    bottom: 2px;
    width: 4px;
    background: var(--primary);
    border-radius: 2px;
}

.section-header .view-all {
    margin-left: auto;
    font-size: 13px;
    color: var(--primary);
    font-weight: 500;
}

.section-header .view-all:hover {
    text-decoration: underline;
}

/* ---------- News Cards ---------- */
.news-card {
    background: var(--bg-white);
    border-radius: 4px;
    overflow: hidden;
    transition: var(--transition);
    height: 100%;
    border: 1px solid var(--border-color);
}

.news-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.news-card .card-img-top {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
}

.news-card .card-body {
    padding: 16px;
}

.news-card .card-category {
    font-size: 12px;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
    display: inline-block;
}

.news-card .card-title {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.5;
    margin-bottom: 8px;
    color: var(--text-dark);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card .card-title a {
    color: inherit;
}

.news-card .card-title a:hover {
    color: var(--primary);
}

.news-card .card-text {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card .card-meta {
    font-size: 12px;
    color: var(--text-light);
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.news-card .card-meta i {
    margin-right: 3px;
}

/* ---------- Lead / Hero Story ---------- */
.lead-story {
    position: relative;
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 24px;
}

.lead-story img {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
}

.lead-story .lead-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 40px 30px 30px;
    background: linear-gradient(transparent, rgba(0,0,0,0.85));
    color: #fff;
}

.lead-story .lead-category {
    background: var(--primary);
    padding: 3px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 2px;
    display: inline-block;
    margin-bottom: 10px;
}

.lead-story .lead-title {
    font-size: 28px;
    font-weight: 700;
    line-height: 1.4;
    color: #fff;
    margin-bottom: 8px;
}

.lead-story .lead-title a {
    color: #fff;
}

.lead-story .lead-title a:hover {
    text-decoration: underline;
}

.lead-story .lead-summary {
    font-size: 15px;
    opacity: 0.9;
    line-height: 1.6;
}

.lead-story .lead-meta {
    font-size: 13px;
    opacity: 0.8;
    margin-top: 8px;
}

/* ---------- Horizontal News Item ---------- */
.news-item-horizontal {
    display: flex;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border-color);
}

.news-item-horizontal:last-child {
    border-bottom: none;
}

.news-item-horizontal .news-thumb {
    flex-shrink: 0;
    width: 120px;
    height: 80px;
    border-radius: 4px;
    overflow: hidden;
}

.news-item-horizontal .news-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-item-horizontal .news-info {
    flex: 1;
    min-width: 0;
}

.news-item-horizontal .news-info .category-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    margin-bottom: 4px;
}

.news-item-horizontal .news-info h3 {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.5;
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-item-horizontal .news-info h3 a:hover {
    color: var(--primary);
}

.news-item-horizontal .news-meta {
    font-size: 12px;
    color: var(--text-light);
}

/* ---------- Simple List News ---------- */
.news-list-simple li {
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
    list-style: none;
}

.news-list-simple li:last-child {
    border-bottom: none;
}

.news-list-simple li a {
    font-size: 15px;
    font-weight: 500;
    line-height: 1.6;
    display: block;
}

.news-list-simple li a:hover {
    color: var(--primary);
}

.news-list-simple li .meta-time {
    font-size: 12px;
    color: var(--text-light);
    margin-top: 2px;
}

/* ---------- Most Read / Trending ---------- */
.most-read-list {
    list-style: none;
    padding: 0;
    counter-reset: item;
}

.most-read-list li {
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    counter-increment: item;
}

.most-read-list li:last-child {
    border-bottom: none;
}

.most-read-list li::before {
    content: counter(item);
    font-size: 24px;
    font-weight: 800;
    color: var(--border-color);
    line-height: 1;
    min-width: 30px;
    font-family: var(--font-english);
}

.most-read-list li a {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.5;
}

.most-read-list li a:hover {
    color: var(--primary);
}

/* ---------- Sidebar ---------- */
.sidebar-widget {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 20px;
    margin-bottom: 24px;
}

.sidebar-widget .widget-title {
    font-size: 16px;
    font-weight: 700;
    padding-bottom: 10px;
    margin-bottom: 14px;
    border-bottom: 2px solid var(--primary);
    color: var(--text-dark);
}

/* ---------- Category Tag Pills ---------- */
.category-pills .badge {
    font-size: 12px;
    font-weight: 500;
    padding: 6px 14px;
    margin: 3px;
    border-radius: 20px;
    background: var(--bg-light);
    color: var(--text-body);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.category-pills .badge:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* ---------- Article Page ---------- */
.article-header {
    margin-bottom: 24px;
}

.article-header .article-category {
    font-size: 13px;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
    display: inline-block;
}

.article-header .article-title {
    font-size: 32px;
    font-weight: 800;
    line-height: 1.4;
    color: var(--text-dark);
    margin-bottom: 12px;
}

.article-header .article-subtitle {
    font-size: 18px;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 16px;
    font-weight: 400;
}

.article-meta-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    padding: 12px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 24px;
    font-size: 13px;
    color: var(--text-muted);
}

.article-meta-bar .author-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.article-meta-bar .author-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
}

.article-meta-bar .author-name {
    font-weight: 600;
    color: var(--text-dark);
}

.article-share {
    margin-left: auto;
    display: flex;
    gap: 8px;
}

.article-share a {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--bg-light);
    color: var(--text-muted);
    font-size: 14px;
    transition: var(--transition);
}

.article-share a:hover {
    background: var(--primary);
    color: #fff;
}

.article-featured-img {
    margin-bottom: 24px;
    border-radius: 6px;
    overflow: hidden;
}

.article-featured-img img {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
}

.article-featured-img figcaption {
    font-size: 13px;
    color: var(--text-muted);
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
    font-style: italic;
}

.article-content {
    font-size: 17px;
    line-height: 2;
    color: var(--text-body);
}

.article-content p {
    margin-bottom: 20px;
}

.article-content h2 {
    font-size: 22px;
    margin: 32px 0 16px;
}

.article-content h3 {
    font-size: 19px;
    margin: 28px 0 14px;
}

.article-content blockquote {
    border-left: 4px solid var(--primary);
    padding: 16px 24px;
    margin: 24px 0;
    background: var(--bg-light);
    font-style: italic;
    font-size: 18px;
    color: var(--text-dark);
}

.article-content ul, .article-content ol {
    margin-bottom: 20px;
    padding-left: 24px;
}

.article-content li {
    margin-bottom: 8px;
}

.article-tags {
    margin-top: 32px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.article-tags .tag {
    display: inline-block;
    padding: 4px 14px;
    font-size: 13px;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    margin: 3px;
    color: var(--text-body);
    transition: var(--transition);
}

.article-tags .tag:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* ---------- Breadcrumb ---------- */
.breadcrumb-custom {
    background: transparent;
    padding: 12px 0;
    margin-bottom: 0;
    font-size: 13px;
}

.breadcrumb-custom .breadcrumb-item a {
    color: var(--text-muted);
}

.breadcrumb-custom .breadcrumb-item.active {
    color: var(--text-dark);
}

/* ---------- Pagination ---------- */
.pagination .page-link {
    color: var(--text-dark);
    border-color: var(--border-color);
    padding: 8px 16px;
    font-size: 14px;
}

.pagination .page-item.active .page-link {
    background: var(--primary);
    border-color: var(--primary);
}

/* ---------- Footer ---------- */
.site-footer {
    background: var(--bg-dark);
    color: rgba(255,255,255,0.7);
    padding: 48px 0 0;
    margin-top: 48px;
}

.site-footer h5 {
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
    display: inline-block;
}

.site-footer a {
    color: rgba(255,255,255,0.7);
    font-size: 14px;
}

.site-footer a:hover {
    color: #fff;
}

.site-footer .footer-links li {
    padding: 4px 0;
    list-style: none;
}

.site-footer .footer-about p {
    font-size: 14px;
    line-height: 1.7;
}

.site-footer .footer-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    margin-right: 8px;
    font-size: 16px;
    transition: var(--transition);
}

.site-footer .footer-social a:hover {
    background: var(--primary);
    color: #fff;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 16px 0;
    margin-top: 32px;
    font-size: 13px;
    color: rgba(255,255,255,0.5);
}

.footer-logo {
    font-size: 24px;
    font-weight: 800;
    color: #fff;
    margin-bottom: 12px;
}

.footer-logo span {
    color: var(--primary);
}

/* ---------- Category Page Header ---------- */
.category-page-header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    padding: 24px 0;
    margin-bottom: 32px;
}

.category-page-header h1 {
    font-size: 28px;
    font-weight: 800;
    color: var(--text-dark);
}

.category-page-header p {
    font-size: 15px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* ---------- Contact / About Page ---------- */
.page-header-banner {
    background: linear-gradient(135deg, var(--secondary) 0%, #2d2d5e 100%);
    color: #fff;
    padding: 48px 0;
    margin-bottom: 40px;
}

.page-header-banner h1 {
    color: #fff;
    font-size: 32px;
    font-weight: 800;
}

.page-header-banner p {
    opacity: 0.8;
    font-size: 16px;
    margin-top: 8px;
}

.contact-form .form-control,
.contact-form .form-select {
    border-radius: 4px;
    padding: 10px 16px;
    border: 1px solid var(--border-color);
    font-size: 15px;
}

.contact-form .form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(211,47,47,0.1);
}

.contact-info-card {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 24px;
    text-align: center;
    transition: var(--transition);
    height: 100%;
}

.contact-info-card:hover {
    box-shadow: var(--shadow-md);
}

.contact-info-card i {
    font-size: 28px;
    color: var(--primary);
    margin-bottom: 12px;
}

.contact-info-card h5 {
    font-size: 16px;
    margin-bottom: 6px;
}

.contact-info-card p {
    font-size: 14px;
    color: var(--text-muted);
    margin: 0;
}

/* ---------- Highlights / Special News Badge ---------- */
.badge-highlight {
    background: #ff9800;
    color: #fff;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 2px;
    font-weight: 600;
}

.badge-special {
    background: var(--primary);
    color: #fff;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 2px;
    font-weight: 600;
}

.badge-breaking {
    background: var(--primary);
    color: #fff;
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 2px;
    font-weight: 700;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* ---------- Datetime Display ---------- */
.datetime-display {
    font-family: var(--font-english);
    font-size: 13px;
}

/* ---------- Video Overlay ---------- */
.video-overlay {
    position: relative;
}

.video-overlay::after {
    content: '\f04b';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.6);
    color: #fff;
    border-radius: 50%;
    font-size: 18px;
}

/* ---------- Related News ---------- */
.related-news {
    margin-top: 40px;
    padding-top: 24px;
    border-top: 2px solid var(--border-color);
}

/* ---------- Responsive ---------- */
@media (max-width: 991.98px) {
    .lead-story .lead-title {
        font-size: 22px;
    }

    .article-header .article-title {
        font-size: 26px;
    }

    .main-nav .navbar-nav .nav-link {
        padding: 8px 16px;
        border-bottom: 1px solid rgba(255,255,255,0.05);
    }
}

@media (max-width: 767.98px) {
    .lead-story .lead-title {
        font-size: 18px;
    }

    .lead-story .lead-overlay {
        padding: 24px 16px 16px;
    }

    .lead-story .lead-summary {
        display: none;
    }

    .article-header .article-title {
        font-size: 22px;
    }

    .article-content {
        font-size: 16px;
    }

    .news-item-horizontal .news-thumb {
        width: 100px;
        height: 68px;
    }

    .section-header h2 {
        font-size: 18px;
    }

    .top-bar {
        display: none;
    }

    .breaking-news-bar .label {
        font-size: 11px;
        padding: 3px 10px;
    }

    .news-card .card-title {
        font-size: 15px;
    }

    .article-share {
        margin-left: 0;
        margin-top: 8px;
        width: 100%;
    }

    .article-meta-bar {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 575.98px) {
    .main-header .logo-area .site-logo {
        font-size: 24px;
    }

    .page-header-banner h1 {
        font-size: 24px;
    }

    .category-page-header h1 {
        font-size: 22px;
    }
}

/* ---------- Spacing Helper ---------- */
.section-gap {
    padding-top: 32px;
    padding-bottom: 32px;
}

/* ---------- Content Area Background ---------- */
.content-area {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 24px;
    margin-bottom: 24px;
}

/* ---------- Skeleton / Placeholder ---------- */
.placeholder-img {
    background: linear-gradient(135deg, #e0e0e0 0%, #f5f5f5 50%, #e0e0e0 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #bbb;
    font-size: 14px;
}

/* ---------- Latest News Sidebar Flash ---------- */
.latest-news-flash {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 24px;
}

.latest-news-flash .flash-header {
    background: var(--primary);
    color: #fff;
    padding: 10px 16px;
    font-size: 15px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.latest-news-flash .flash-header .live-dot {
    width: 8px;
    height: 8px;
    background: #fff;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

.latest-news-flash .flash-list {
    list-style: none;
    padding: 0;
    margin: 0;
    max-height: 400px;
    overflow-y: auto;
}

.latest-news-flash .flash-list li {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    font-size: 14px;
    line-height: 1.6;
    position: relative;
    padding-left: 28px;
}

.latest-news-flash .flash-list li::before {
    content: '';
    position: absolute;
    left: 16px;
    top: 18px;
    width: 6px;
    height: 6px;
    background: var(--primary);
    border-radius: 50%;
}

.latest-news-flash .flash-list li:last-child {
    border-bottom: none;
}

.latest-news-flash .flash-list li a {
    font-weight: 500;
    display: block;
}

.latest-news-flash .flash-list li .flash-time {
    font-size: 11px;
    color: var(--text-light);
    margin-top: 3px;
}

/* ---------- Article Navigation ---------- */
.article-nav {
    display: flex;
    gap: 16px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 2px solid var(--border-color);
}

.article-nav .nav-item-prev,
.article-nav .nav-item-next {
    flex: 1;
    padding: 16px;
    background: var(--bg-light);
    border-radius: 6px;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.article-nav .nav-item-prev:hover,
.article-nav .nav-item-next:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.article-nav .nav-label {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 4px;
    display: block;
}

.article-nav .nav-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-nav .nav-item-next {
    text-align: right;
}

/* ---------- Category Lead Enhanced ---------- */
.category-lead-enhanced {
    position: relative;
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 24px;
}

.category-lead-enhanced img {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.category-lead-enhanced:hover img {
    transform: scale(1.02);
}

.category-lead-enhanced .lead-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 32px 24px 24px;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: #fff;
}

.category-lead-enhanced .lead-content .badge-cat {
    background: var(--primary);
    padding: 3px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 2px;
    display: inline-block;
    margin-bottom: 8px;
}

.category-lead-enhanced .lead-content h2 {
    font-size: 24px;
    color: #fff;
    margin-bottom: 8px;
    line-height: 1.4;
}

.category-lead-enhanced .lead-content h2 a {
    color: #fff;
}

.category-lead-enhanced .lead-content h2 a:hover {
    text-decoration: underline;
}

.category-lead-enhanced .lead-content p {
    font-size: 14px;
    opacity: 0.9;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.category-lead-enhanced .lead-meta {
    font-size: 12px;
    opacity: 0.8;
}

/* ---------- Reading Progress Bar ---------- */
.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--primary);
    z-index: 9999;
    transition: width 0.1s linear;
}

/* ---------- User Reviews / Comments ---------- */
.reviews-section .review-count {
    background: var(--primary);
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    padding: 2px 10px;
    border-radius: 20px;
    vertical-align: middle;
    margin-left: 6px;
}

/* Rating Summary */
.rating-summary {
    display: flex;
    gap: 32px;
    align-items: center;
    background: var(--bg-light);
    border-radius: 8px;
    padding: 20px 24px;
    margin-bottom: 20px;
    border: 1px solid var(--border-color);
    flex-wrap: wrap;
}

.rating-average {
    text-align: center;
    flex-shrink: 0;
}

.rating-average .rating-number {
    font-size: 52px;
    font-weight: 800;
    color: var(--text-dark);
    line-height: 1;
    font-family: var(--font-english);
}

.rating-average .rating-stars {
    color: #f59e0b;
    font-size: 20px;
    margin: 6px 0 4px;
    letter-spacing: 2px;
}

.rating-average .rating-total {
    font-size: 12px;
    color: var(--text-muted);
}

.rating-bars {
    flex: 1;
    min-width: 200px;
}

.rating-bar-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.rating-bar-row .bar-label {
    font-size: 12px;
    color: var(--text-muted);
    min-width: 32px;
    font-family: var(--font-english);
    text-align: right;
}

.rating-bar-row .bar-track {
    flex: 1;
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.rating-bar-row .bar-fill {
    height: 100%;
    background: #f59e0b;
    border-radius: 4px;
    transition: width 0.4s ease;
}

.rating-bar-row .bar-count {
    font-size: 12px;
    color: var(--text-muted);
    min-width: 20px;
    font-family: var(--font-english);
}

/* Sort Controls */
.review-sort {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.review-sort .sort-label {
    font-size: 13px;
    color: var(--text-muted);
}

.sort-btn {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 5px 16px;
    font-size: 13px;
    color: var(--text-body);
    cursor: pointer;
    font-family: var(--font-bangla);
    transition: var(--transition);
}

.sort-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.sort-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* Comment Items */
.comment-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.comment-item {
    display: flex;
    gap: 14px;
    padding: 20px 0;
    border-bottom: 1px solid var(--border-color);
}

.comment-item:last-child {
    border-bottom: none;
}

.comment-avatar {
    flex-shrink: 0;
}

.comment-avatar img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border-color);
}

.comment-body {
    flex: 1;
    min-width: 0;
}

.comment-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 4px;
}

.commenter-name {
    font-weight: 700;
    font-size: 15px;
    color: var(--text-dark);
}

.commenter-badge {
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 20px;
    margin-left: 6px;
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.commenter-badge.verified {
    background: #e8f5e9;
    color: #2e7d32;
}

.commenter-badge.expert {
    background: #e3f2fd;
    color: #1565c0;
}

.comment-stars {
    color: #f59e0b;
    font-size: 13px;
    letter-spacing: 1px;
}

.comment-date {
    font-size: 12px;
    color: var(--text-light);
    margin-bottom: 8px;
}

.comment-text {
    font-size: 15px;
    line-height: 1.8;
    color: var(--text-body);
    margin-bottom: 10px;
}

.comment-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.comment-like,
.comment-dislike,
.comment-reply-btn {
    background: none;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 13px;
    color: var(--text-muted);
    cursor: pointer;
    font-family: var(--font-bangla);
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.comment-like:hover,
.comment-like.active {
    border-color: #2e7d32;
    color: #2e7d32;
    background: #e8f5e9;
}

.comment-dislike:hover,
.comment-dislike.active {
    border-color: var(--primary);
    color: var(--primary);
    background: #ffebee;
}

.comment-reply-btn:hover {
    border-color: var(--accent-blue);
    color: var(--accent-blue);
    background: #e3f2fd;
}

/* Nested Replies */
.reply-list {
    margin-top: 12px;
    padding-left: 20px;
    border-left: 3px solid var(--border-color);
}

.reply-item {
    padding: 12px 0;
}

.reply-item .comment-avatar img {
    width: 40px;
    height: 40px;
}

/* Load More Button */
.btn-load-more {
    border: 2px solid var(--primary);
    color: var(--primary);
    background: transparent;
    border-radius: 4px;
    padding: 8px 28px;
    font-size: 14px;
    font-weight: 600;
    font-family: var(--font-bangla);
    transition: var(--transition);
}

.btn-load-more:hover {
    background: var(--primary);
    color: #fff;
}

.btn-load-more:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Review Form */
.review-form-wrap {
    background: var(--bg-light);
    border-radius: 8px;
    padding: 24px;
    border: 1px solid var(--border-color);
}

.review-form-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary);
    display: inline-block;
}

.star-rating-picker label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
}

.star-picker {
    display: flex;
    gap: 6px;
    margin: 8px 0 4px;
}

.star-picker i {
    font-size: 28px;
    color: #f59e0b;
    cursor: pointer;
    transition: transform 0.15s ease;
}

.star-picker i:hover {
    transform: scale(1.15);
}

.rating-hint {
    font-size: 13px;
    color: var(--text-muted);
    font-style: italic;
}

.review-form .form-control {
    border-radius: 4px;
    border: 1px solid var(--border-color);
    font-size: 15px;
    font-family: var(--font-bangla);
    padding: 10px 14px;
    transition: var(--transition);
}

.review-form .form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(211,47,47,0.1);
}

.review-form .form-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 6px;
}

.char-counter {
    font-size: 12px;
    color: var(--text-light);
    text-align: right;
    margin-top: 4px;
}

.btn-review-submit {
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 10px 28px;
    font-size: 15px;
    font-weight: 600;
    font-family: var(--font-bangla);
    transition: var(--transition);
}

.btn-review-submit:hover {
    background: var(--primary-dark);
    color: #fff;
}

.btn-primary-red {
    background: var(--primary);
    color: #fff;
    border: none;
    font-family: var(--font-bangla);
    transition: var(--transition);
}

.btn-primary-red:hover {
    background: var(--primary-dark);
    color: #fff;
}

/* Review Success Message */
.review-success {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: #e8f5e9;
    border: 1px solid #a5d6a7;
    border-radius: 6px;
    padding: 20px;
    color: #2e7d32;
}

.review-success i {
    font-size: 28px;
    flex-shrink: 0;
    margin-top: 2px;
}

.review-success strong {
    font-size: 16px;
    display: block;
    margin-bottom: 4px;
}

.review-success p {
    font-size: 14px;
    margin: 0;
    color: #388e3c;
}

/* Responsive */
@media (max-width: 575.98px) {
    .rating-summary {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    .rating-average {
        display: flex;
        align-items: center;
        gap: 12px;
        text-align: left;
    }
    .rating-average .rating-number {
        font-size: 40px;
    }
    .comment-header {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ========================================
   FILTER BAR (Blogs & Books)
   ======================================== */
.filter-bar {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.filter-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.filter-pills {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.filter-pill {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 5px 16px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-body);
    cursor: pointer;
    white-space: nowrap;
    transition: var(--transition);
    font-family: var(--font-bangla);
}

.filter-pill:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.filter-pill.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

.filter-sort .form-select {
    font-size: 13px;
    min-width: 160px;
    font-family: var(--font-bangla);
}

/* ========================================
   BLOG PAGES
   ======================================== */

/* --- Featured Blog --- */
.blog-featured {
    background: var(--bg-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.blog-featured:hover {
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}

.blog-featured-img {
    position: relative;
    height: 100%;
    min-height: 320px;
}

.blog-featured-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.blog-category-badge {
    display: inline-block;
    background: var(--primary);
    color: #fff;
    padding: 3px 12px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 600;
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 2;
}

.blog-featured-body {
    padding: 28px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
}

.blog-meta-top {
    display: flex;
    gap: 12px;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.blog-featured-title {
    font-size: 22px;
    font-weight: 800;
    line-height: 1.4;
    margin-bottom: 10px;
}

.blog-featured-title a:hover {
    color: var(--primary);
}

.blog-featured-excerpt {
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-stats {
    display: flex;
    gap: 14px;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.btn-read-more {
    display: inline-flex;
    align-items: center;
    background: var(--primary);
    color: #fff;
    padding: 8px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    width: fit-content;
    transition: var(--transition);
}

.btn-read-more:hover {
    background: var(--primary-dark);
    color: #fff;
}

/* --- Blog Card --- */
.blog-card {
    background: var(--bg-white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
}

.blog-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.blog-card-img {
    position: relative;
    overflow: hidden;
}

.blog-card-img img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.blog-card:hover .blog-card-img img {
    transform: scale(1.05);
}

.blog-card-body {
    padding: 16px;
}

.blog-card-title {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-card-title a:hover { color: var(--primary); }

.blog-card-excerpt {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-card-footer {
    display: flex;
    gap: 12px;
    font-size: 12px;
    color: var(--text-light);
    border-top: 1px solid var(--border-color);
    padding-top: 10px;
}

/* --- Blog Single Author Card --- */
.blog-author-card {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 20px;
    background: var(--bg-light);
    border-radius: 10px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.blog-author-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary);
}

.blog-author-info {
    flex: 1;
    min-width: 200px;
}

.blog-author-name-large {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
}

.blog-author-bio {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 2px;
}

.blog-author-meta {
    display: flex;
    gap: 14px;
    font-size: 12px;
    color: var(--text-light);
    margin-top: 6px;
    flex-wrap: wrap;
}

.blog-sidebar-author {
    text-align: center;
}

/* ========================================
   BOOK LIBRARY PAGES
   ======================================== */

/* --- Library Stats Bar --- */
.library-stats-bar {
    background: var(--secondary);
    color: #fff;
    padding: 16px 0;
}

.library-stats-inner {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.stat-item i {
    font-size: 24px;
    opacity: 0.8;
}

.stat-item strong {
    display: block;
    font-size: 18px;
    font-weight: 800;
}

.stat-item span {
    font-size: 12px;
    opacity: 0.7;
}

/* --- Book Card (Library Grid) --- */
.book-card {
    background: var(--bg-white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
}

.book-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.book-card-inner {
    height: 100%;
}

.book-cover {
    position: relative;
    overflow: hidden;
    background: #f0ebe3;
    text-align: center;
}

.book-cover img {
    width: 100%;
    height: auto;
    aspect-ratio: 2/3;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.book-card:hover .book-cover img {
    transform: scale(1.04);
}

.book-cover-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.book-card:hover .book-cover-overlay {
    opacity: 1;
}

.btn-book-read {
    background: var(--primary);
    color: #fff;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    transition: var(--transition);
}

.btn-book-read:hover {
    background: var(--primary-dark);
    color: #fff;
}

.book-badge-featured {
    position: absolute;
    top: 8px;
    right: 8px;
    background: #f59e0b;
    color: #fff;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    z-index: 2;
}

.book-info {
    padding: 12px;
}

.book-category {
    display: inline-block;
    font-size: 11px;
    color: var(--primary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.book-title {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.book-title a:hover { color: var(--primary); }

.book-author {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.book-rating {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-muted);
}

.book-rating .stars {
    color: #f59e0b;
    font-size: 11px;
}

.book-meta-row {
    display: flex;
    gap: 10px;
    font-size: 11px;
    color: var(--text-light);
    margin-top: 6px;
    flex-wrap: wrap;
}

/* --- Featured Book Card (larger) --- */
.book-card-featured .book-cover img {
    height: auto;
    max-height: 320px;
}

.book-card-featured .book-info {
    padding: 16px;
}

.book-card-featured .book-title {
    font-size: 17px;
}

/* ========================================
   SINGLE BOOK PAGE
   ======================================== */

/* --- Book Detail Hero --- */
.book-detail-hero {
    background: var(--bg-white);
    border-radius: 12px;
    padding: 28px;
    box-shadow: var(--shadow-md);
    margin-bottom: 28px;
}

.book-detail-cover {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.book-detail-cover img {
    width: 100%;
    height: auto;
}

.book-format-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--primary);
    color: #fff;
    padding: 3px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
}

.book-action-buttons .btn {
    font-size: 14px;
    padding: 10px;
    font-weight: 600;
    border-radius: 8px;
}

.btn-book-primary {
    background: var(--primary);
    color: #fff;
    border: none;
}

.btn-book-primary:hover {
    background: var(--primary-dark);
    color: #fff;
}

.btn-book-download {
    background: var(--secondary);
    color: #fff;
    border: none;
}

.btn-book-download:hover {
    background: #141426;
    color: #fff;
}

/* --- Book Detail Info --- */
.book-category-label {
    display: inline-block;
    background: var(--bg-light);
    color: var(--primary);
    padding: 3px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 8px;
}

.book-detail-title {
    font-size: 28px;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 8px;
}

.book-detail-subtitle {
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 16px;
}

.book-detail-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}

.book-detail-rating .stars {
    color: #f59e0b;
    font-size: 16px;
}

.book-detail-rating .rating-text {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
}

.book-detail-rating .rating-count {
    font-size: 13px;
    color: var(--text-muted);
}

.book-detail-meta-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.meta-item {
    background: var(--bg-light);
    padding: 10px 14px;
    border-radius: 8px;
}

.meta-item .meta-label {
    display: block;
    font-size: 11px;
    color: var(--text-light);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.meta-item .meta-value {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark);
}

.meta-item .meta-value a {
    color: var(--primary);
}

.book-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.book-share .share-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: var(--bg-light);
    border-radius: 50%;
    color: var(--text-muted);
    font-size: 13px;
    transition: var(--transition);
}

.book-share .share-icon:hover {
    background: var(--primary);
    color: #fff;
}

/* --- Quick Stats Sidebar --- */
.book-quick-stats {
    background: var(--bg-light);
    border-radius: 10px;
    padding: 20px;
}

.book-quick-stats h5 {
    font-size: 16px;
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
}

.book-quick-stats ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.book-quick-stats li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 14px;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-color);
}

.book-quick-stats li:last-child { border-bottom: none; }

.book-quick-stats li strong {
    color: var(--text-dark);
}

/* --- Book Preview Section --- */
.book-preview-section {
    margin-bottom: 28px;
}

.preview-page {
    background: #fffef8;
    border: 1px solid #e8e0ca;
    border-radius: 8px;
    margin-bottom: 16px;
    overflow: hidden;
}

.preview-page-header {
    background: #f5f0e3;
    padding: 8px 20px;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-muted);
    border-bottom: 1px solid #e8e0ca;
}

.preview-page-content {
    padding: 28px;
    font-size: 16px;
    line-height: 2;
    color: var(--text-body);
}

.preview-page-content h4, .preview-page-content h5 {
    color: var(--text-dark);
}

.preview-lock-overlay {
    position: relative;
    width: 100%;
    padding: 60px 20px;
    background: linear-gradient(to bottom, rgba(255,254,248,0.3), rgba(255,255,255,0.95) 40%, #fff);
    text-align: center;
    margin-top: -80px;
}

.preview-lock-content i {
    font-size: 40px;
    color: var(--text-light);
    margin-bottom: 12px;
    display: block;
}

.preview-lock-content h4 {
    font-size: 18px;
    margin-bottom: 8px;
    color: var(--text-dark);
}

/* --- Author Detail Card --- */
.author-detail-card {
    background: var(--bg-light);
    border-radius: 12px;
    padding: 24px;
}

.author-detail-header {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-bottom: 16px;
}

.author-detail-photo {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary);
}

.author-detail-info h3 {
    font-size: 20px;
    margin-bottom: 2px;
}

.author-designation {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.author-detail-stats {
    display: flex;
    gap: 16px;
    font-size: 13px;
    color: var(--text-light);
    flex-wrap: wrap;
}

.author-detail-bio {
    font-size: 15px;
    line-height: 1.8;
    color: var(--text-body);
    margin-bottom: 16px;
}

.author-other-books h5 {
    font-size: 15px;
    margin-bottom: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
}

.author-book-thumb {
    display: block;
    text-align: center;
}

.author-book-thumb img {
    width: 100%;
    border-radius: 6px;
    box-shadow: var(--shadow-sm);
    margin-bottom: 6px;
    aspect-ratio: 2/3;
    object-fit: cover;
}

.author-book-thumb span {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-body);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.author-book-thumb:hover span {
    color: var(--primary);
}

/* --- Sidebar Book List --- */
.sidebar-book-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.sidebar-book-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 10px;
    border-radius: 8px;
    transition: var(--transition);
}

.sidebar-book-item:hover {
    background: var(--bg-light);
    color: var(--text-dark);
}

.sidebar-book-item img {
    width: 50px;
    height: 70px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
}

.sidebar-book-item h5 {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 2px;
    line-height: 1.3;
}

.sidebar-book-item span {
    font-size: 12px;
    color: var(--text-muted);
}

.sidebar-book-item .stars {
    font-size: 10px;
    color: #f59e0b;
    margin-top: 2px;
}

/* ========================================
   RESPONSIVE (Blog & Book Pages)
   ======================================== */
@media (max-width: 991px) {
    .blog-featured-img {
        min-height: 260px;
    }

    .blog-featured-body {
        padding: 20px;
    }

    .book-detail-hero {
        padding: 20px;
    }

    .book-detail-title {
        font-size: 22px;
    }

    .book-detail-meta-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .library-stats-inner {
        gap: 20px;
    }

    .filter-pills {
        padding-bottom: 4px;
    }

    .author-detail-header {
        flex-direction: column;
        text-align: center;
    }

    .author-detail-stats {
        justify-content: center;
    }
}

@media (max-width: 767px) {
    .blog-featured-img {
        min-height: 220px;
    }

    .blog-featured-title {
        font-size: 18px;
    }

    .filter-bar-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .book-detail-title {
        font-size: 20px;
    }

    .book-detail-meta-grid {
        grid-template-columns: 1fr 1fr;
    }

    .library-stats-inner {
        gap: 16px;
        justify-content: space-between;
    }

    .stat-item i { font-size: 18px; }
    .stat-item strong { font-size: 15px; }

    .preview-page-content {
        padding: 16px;
        font-size: 15px;
        line-height: 1.8;
    }

    .blog-author-card {
        flex-direction: column;
        text-align: center;
    }

    .blog-author-card .article-share {
        justify-content: center;
        width: 100%;
    }
}

@media (max-width: 575px) {
    .book-detail-meta-grid {
        grid-template-columns: 1fr;
    }

    .library-stats-inner {
        flex-wrap: wrap;
        gap: 12px;
    }

    .stat-item {
        flex: 0 0 calc(50% - 6px);
        justify-content: center;
    }
}

/* ---------- Print Styles ---------- */
@media print {
    .main-header, .main-nav, .breaking-news-bar, .site-footer,
    .article-share, .sidebar-widget, .filter-bar, .library-stats-bar {
        display: none !important;
    }

    .article-content {
        font-size: 14px;
        line-height: 1.6;
    }
}
