@import url('https://fonts.googleapis.com/css2?family=Hind+Siliguri:wght@400;500;600;700&display=swap');

/* ── PDF Viewer Wrapper ───────────────────────────────────────────────────── */
.fas-pdf-viewer-wrap {
    font-family: 'Hind Siliguri', -apple-system, sans-serif;
    margin: 36px 0 20px;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(0,0,0,.10), 0 1px 4px rgba(0,0,0,.06);
    border: 1px solid #e2e6f0;
    background: #fff;
}

/* ── Header ──────────────────────────────────────────────────────────────── */
.fas-fv-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    padding: 14px 20px;
    background: linear-gradient(135deg, #5b4fcf 0%, #7c6ff7 60%, #00b89c 100%);
    color: #fff;
}

.fas-fv-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.fas-fv-icon {
    font-size: 28px;
    flex-shrink: 0;
    filter: drop-shadow(0 1px 2px rgba(0,0,0,.2));
}

.fas-fv-title-group {
    min-width: 0;
}

.fas-fv-title {
    display: block;
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-shadow: 0 1px 2px rgba(0,0,0,.15);
}

.fas-fv-size {
    display: inline-block;
    font-size: 12px;
    color: rgba(255,255,255,.80);
    margin-top: 2px;
}

.fas-fv-header-right {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

/* Toggle button */
.fas-fv-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(255,255,255,.18);
    border: 1px solid rgba(255,255,255,.35);
    color: #fff;
    border-radius: 7px;
    padding: 7px 13px;
    font-size: 13px;
    font-family: 'Hind Siliguri', sans-serif;
    font-weight: 500;
    cursor: pointer;
    transition: background .18s;
    line-height: 1;
}
.fas-fv-toggle-btn:hover {
    background: rgba(255,255,255,.28);
}

/* Download button (header) */
.fas-fv-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    color: #5b4fcf;
    border-radius: 7px;
    padding: 7px 16px;
    font-size: 13px;
    font-family: 'Hind Siliguri', sans-serif;
    font-weight: 600;
    text-decoration: none !important;
    transition: all .18s;
    box-shadow: 0 2px 8px rgba(0,0,0,.12);
    line-height: 1.3;
    border: none;
    white-space: nowrap;
}
.fas-fv-download-btn:hover {
    background: #ede9ff;
    color: #4a3fb8;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,.15);
}

/* ── Reading Streak ব্যাজ ─────────────────────────────────────────────────── */
.fas-streak-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11.5px;
    font-weight: 600;
    color: #9a3412;
    background: linear-gradient(120deg, #fef3c7, #fed7aa);
    border: 1px solid #fdba74;
    padding: 3px 9px 3px 7px;
    border-radius: 20px;
    font-family: 'Hind Siliguri', sans-serif;
    margin-top: 4px;
}
.fas-achievement-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11.5px;
    font-weight: 600;
    color: #4338ca;
    background: linear-gradient(120deg, #e0e7ff, #c7d2fe);
    border: 1px solid #a5b4fc;
    padding: 3px 9px 3px 7px;
    border-radius: 20px;
    font-family: 'Hind Siliguri', sans-serif;
    margin-top: 4px;
    margin-left: 6px;
}

/* ── Continue Reading কার্ড — [fas_continue_reading] শর্টকোড ─────────────────── */
.fas-continue-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-left: 4px solid #5b4fcf;
    border-radius: 10px;
    padding: 14px 18px;
    box-shadow: 0 1px 4px rgba(0,0,0,.04);
    margin: 16px 0;
    flex-wrap: wrap;
}
.fas-continue-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 200px;
}
.fas-continue-icon {
    font-size: 24px;
    flex-shrink: 0;
}
.fas-continue-text {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 0;
}
.fas-continue-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .4px;
    color: #5b4fcf;
    text-transform: uppercase;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-continue-text strong {
    font-size: 14.5px;
    color: #1f2937;
    font-family: 'Hind Siliguri', sans-serif;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 340px;
}
.fas-continue-meta {
    font-size: 12px;
    color: #9ca3af;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-continue-streak {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 12.5px;
    font-weight: 600;
    color: #c2410c;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    padding: 5px 11px;
    border-radius: 20px;
    font-family: 'Hind Siliguri', sans-serif;
    white-space: nowrap;
}
.fas-continue-btn {
    flex-shrink: 0;
    background: #5b4fcf;
    color: #fff !important;
    text-decoration: none !important;
    font-size: 13px;
    font-weight: 700;
    font-family: 'Hind Siliguri', sans-serif;
    padding: 9px 18px;
    border-radius: 8px;
    transition: background .18s;
    white-space: nowrap;
}
.fas-continue-btn:hover {
    background: #4a3fb5;
    color: #fff !important;
}

@media (max-width: 600px) {
    .fas-continue-card {
        flex-direction: column;
        align-items: stretch;
    }
    .fas-continue-btn {
        text-align: center;
    }
    .fas-continue-text strong {
        max-width: none;
    }
}

/* ── প্রোগ্রেস স্ট্রিপ ────────────────────────────────────────────────────── */
.fas-progress-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 18px;
    padding: 10px 4px 4px;
    font-size: 12.5px;
    color: #4b5563;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-progress-item strong {
    color: #1f2937;
}

/* ── Mock Test CTA ────────────────────────────────────────────────────────── */
.fas-mocktest-cta {
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(135deg, #ecfdf5 0%, #f0fdfa 100%);
    border: 1px solid #a7f3d0;
    border-radius: 10px;
    padding: 15px 18px;
    margin: 16px 0;
    text-decoration: none !important;
    transition: box-shadow .18s, transform .18s;
}
.fas-mocktest-cta:hover {
    box-shadow: 0 3px 14px rgba(16,185,129,.18);
    transform: translateY(-1px);
}
.fas-mocktest-icon {
    font-size: 24px;
    flex-shrink: 0;
}
.fas-mocktest-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.fas-mocktest-text strong {
    font-size: 14px;
    color: #065f46;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-mocktest-text span:not(.fas-mocktest-icon) {
    font-size: 12.5px;
    color: #047857;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-mocktest-arrow {
    font-size: 18px;
    color: #059669;
    flex-shrink: 0;
}

/* ── লিডারবোর্ড ───────────────────────────────────────────────────────────── */
.fas-leaderboard {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 16px 18px;
    margin: 16px 0;
}
.fas-leaderboard-title {
    margin: 0 0 10px;
    font-size: 14px;
    color: #1f2937;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-leaderboard-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 7px;
}
.fas-leaderboard-list li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-leaderboard-rank {
    flex-shrink: 0;
    width: 26px;
    height: 26px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
    color: #6b7280;
    border-radius: 50%;
    font-size: 11.5px;
    font-weight: 700;
}
.fas-leaderboard-name {
    flex: 1;
    min-width: 0;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.fas-leaderboard-count {
    flex-shrink: 0;
    color: #9ca3af;
    font-size: 12px;
}

/* ── Premium সেল প্যানেল ──────────────────────────────────────────────────── */
.fas-fv-sales-panel {
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 22px;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #1a1a2e 100%);
    overflow: hidden;
    border-bottom: 1px solid #2d2d4a;
}
.fas-fv-sales-glow {
    position: absolute;
    top: -60%;
    right: -8%;
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, rgba(212,175,55,.22) 0%, rgba(212,175,55,0) 70%);
    pointer-events: none;
}
.fas-fv-sales-badge {
    position: relative;
    flex-shrink: 0;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 21px;
    background: linear-gradient(145deg, #f4d47c, #d4af37 55%, #b8860b);
    box-shadow: 0 0 0 1px rgba(212,175,55,.35), 0 4px 14px rgba(212,175,55,.35);
}
.fas-fv-sales-text {
    position: relative;
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.fas-fv-sales-tag {
    align-self: flex-start;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.2px;
    color: #1a1a2e;
    background: linear-gradient(120deg, #f4d47c, #d4af37);
    padding: 2px 9px;
    border-radius: 20px;
    margin-bottom: 2px;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-fv-sales-text strong {
    font-size: 14.5px;
    color: #f5f0e6;
    font-family: 'Hind Siliguri', sans-serif;
    font-weight: 600;
}
.fas-fv-sales-text span:not(.fas-fv-sales-tag) {
    font-size: 12.5px;
    color: #9ca3b8;
    line-height: 1.55;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-fv-sales-cta {
    position: relative;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: linear-gradient(120deg, #f4d47c, #d4af37 55%, #b8860b);
    color: #1a1a2e !important;
    text-decoration: none !important;
    font-size: 13.5px;
    font-weight: 700;
    font-family: 'Hind Siliguri', sans-serif;
    padding: 10px 20px;
    border-radius: 8px;
    box-shadow: 0 3px 12px rgba(212,175,55,.35);
    transition: all .2s ease;
    white-space: nowrap;
}
.fas-fv-sales-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 5px 18px rgba(212,175,55,.5);
    color: #1a1a2e !important;
}

@media (max-width: 600px) {
    .fas-fv-sales-panel {
        flex-wrap: wrap;
    }
    .fas-fv-sales-cta {
        width: 100%;
        justify-content: center;
        order: 3;
    }
}

/* ── Iframe body ─────────────────────────────────────────────────────────── */
.fas-fv-body {
    background: #f5f5f5;
    position: relative;
}

/* ── pdf.js native renderer ──────────────────────────────────────────────── */
.fas-fv-pdfjs-container {
    position: relative;
    width: 100%;
    max-height: 680px;
    overflow-y: auto;
    background: #6e6e6e;
}

.fas-fv-pdfjs-pages {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 14px 0;
}

.fas-fv-pdfjs-page-holder {
    display: flex;
    justify-content: center;
    background: #fff;
    box-shadow: 0 1px 6px rgba(0,0,0,.25);
    max-width: 100%;
}

.fas-fv-pdfjs-page-holder canvas {
    display: block;
    max-width: 100%;
    height: auto;
}

.fas-fv-pdfjs-page-error {
    padding: 40px 20px;
    color: #b91c1c;
    font-size: 13px;
    text-align: center;
}

.fas-fv-pdfjs-error {
    padding: 40px 20px;
    text-align: center;
    color: #6b7280;
    font-family: 'Hind Siliguri', sans-serif;
    font-size: 14px;
}

@media (max-width: 600px) {
    .fas-fv-pdfjs-container {
        max-height: 420px;
    }
}

/* ── Footer ──────────────────────────────────────────────────────────────── */
.fas-fv-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    padding: 14px 20px;
    background: #f8f9fc;
    border-top: 1px solid #e2e6f0;
}

.fas-fv-footer-info {
    font-size: 13px;
    color: #6b7280;
}

/* Large download button (footer) */
.fas-fv-download-lg {
    background: linear-gradient(135deg, #5b4fcf, #00b89c);
    color: #fff !important;
    padding: 10px 22px;
    font-size: 14px;
    border-radius: 9px;
    box-shadow: 0 2px 10px rgba(91,79,207,.30);
}
.fas-fv-download-lg:hover {
    background: linear-gradient(135deg, #4a3fb8, #00a085);
    color: #fff !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(91,79,207,.40);
}

.fas-fv-dl-size {
    font-size: 11px;
    opacity: .85;
    margin-left: 4px;
    font-weight: 400;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 600px) {
    .fas-fv-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .fas-fv-header-right {
        width: 100%;
        justify-content: space-between;
    }
    .fas-fv-iframe {
        height: 420px;
    }
    .fas-fv-footer {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    .fas-fv-download-lg {
        text-align: center;
        justify-content: center;
    }
}

/* ── Loading indicator ───────────────────────────────────────────────────── */
.fas-fv-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: #6b7280;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-fv-body { position: relative; }
.fas-fv-spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 3px solid #e2e6f0;
    border-top-color: #5b4fcf;
    border-radius: 50%;
    animation: fas-spin 0.8s linear infinite;
}
@keyframes fas-spin {
    to { transform: rotate(360deg); }
}

/* ── SEO Intro (above viewer) ────────────────────────────────────────────── */
.fas-seo-intro {
    font-family: 'Hind Siliguri', sans-serif;
    background: #f0eeff;
    border-left: 4px solid #5b4fcf;
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 20px;
}
.fas-seo-intro p {
    font-size: 15px;
    line-height: 1.7;
    color: #374151;
    margin: 0 0 12px;
}
.fas-exam-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.fas-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #fff;
    border: 1px solid #c4b9f7;
    color: #5b4fcf;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 99px;
    font-family: 'Hind Siliguri', sans-serif;
}

/* ── SEO Detail (below viewer) ───────────────────────────────────────────── */
.fas-seo-detail {
    font-family: 'Hind Siliguri', sans-serif;
    margin-top: 24px;
}
.fas-seo-section {
    background: #fff;
    border: 1px solid #e2e6f0;
    border-radius: 12px;
    padding: 20px 24px;
    margin-bottom: 16px;
}
.fas-seo-section.fas-seo-highlight {
    background: #fffbeb;
    border-color: #fcd34d;
}
.fas-seo-heading {
    font-size: 16px;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e2e6f0;
    font-family: 'Hind Siliguri', sans-serif;
}
.fas-topic-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 8px;
}
.fas-topic-list li {
    font-size: 14px;
    color: #374151;
    background: #f8f9fc;
    border-radius: 7px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.fas-tips-list {
    padding-left: 20px;
    margin: 0;
}
.fas-tips-list li {
    font-size: 14px;
    color: #374151;
    line-height: 1.7;
    margin-bottom: 6px;
}
.fas-seo-desc {
    font-size: 14px;
    line-height: 1.8;
    color: #4b5563;
    margin: 0;
}

/* ── FAQ (accordion via native <details>) ────────────────────────────────── */
.fas-faq-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.fas-faq-item {
    border: 1px solid #e2e6f0;
    border-radius: 9px;
    padding: 4px 16px;
    background: #f8f9fc;
}
.fas-faq-item[open] {
    background: #fff;
    border-color: #c4b9f7;
}
.fas-faq-q {
    cursor: pointer;
    list-style: none;
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
    padding: 12px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}
.fas-faq-q::-webkit-details-marker { display: none; }
.fas-faq-q::before {
    content: '+';
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #5b4fcf;
    color: #fff;
    border-radius: 50%;
    font-size: 14px;
    line-height: 1;
}
.fas-faq-item[open] .fas-faq-q::before {
    content: '−';
}
.fas-faq-a {
    font-size: 14px;
    line-height: 1.7;
    color: #4b5563;
    padding: 0 0 14px 28px;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 600px) {
    .fas-topic-list {
        grid-template-columns: 1fr;
    }
    .fas-seo-section {
        padding: 14px 16px;
    }
}
