/* Dark Mode Colors */
[data-bs-theme="dark"] {
    --bs-body-bg: #0f172a; /* Deep Dark Background */
    --bs-body-color: #f1f5f9;
    --bs-card-bg: #1e293b; /* Card Background */
    --bs-border-color: rgba(255, 255, 255, 0.1);
}


[data-bs-theme="dark"] .tool-card, 
[data-bs-theme="dark"] .card,
[data-bs-theme="dark"] .qc-stats-card {
    background-color: var(--bs-card-bg) !important;
    border: 1px solid var(--bs-border-color) !important;
    color: #f1f5f9 !important;
}

[data-bs-theme="dark"] .text-muted {
    color: #94a3b8 !important; /* Lighter text for dark bg */
}

/* Dark Mode Global Fix */
[data-bs-theme="dark"] body { background-color: #0f172a !important; color: #e2e8f0 !important; }

[data-bs-theme="dark"] .tool-card, 
[data-bs-theme="dark"] .card, 
[data-bs-theme="dark"] .footer-rating-inner,
[data-bs-theme="dark"] .accordion-item {
    background-color: #1e293b !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
}

[data-bs-theme="dark"] .text-dark, 
[data-bs-theme="dark"] h1, 
[data-bs-theme="dark"] h2, 
[data-bs-theme="dark"] h4, 
[data-bs-theme="dark"] h5, 
[data-bs-theme="dark"] h6 {
    color: #f8fafc !important;
}


/* ===== Hero Section Dark Fix ===== */
[data-bs-theme="dark"] .hero-section,
[data-bs-theme="dark"] .img-hub-header,
[data-bs-theme="dark"] .pdf-header {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}

/* Featured Highlights & FAQ Container Fix */
[data-bs-theme="dark"] .p-4.rounded-4.bg-white.shadow-sm.border,
[data-bs-theme="dark"] .bg-light,
[data-bs-theme="dark"] .card.border-0.shadow-sm.rounded-4 {
    background-color: #1e293b !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

/* Badge & Small Text Visibility */
[data-bs-theme="dark"] .badge.bg-white {
    background-color: #334155 !important;
    color: #f8fafc !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}

/* Hero Title Shadow (Optional - better readability) */
[data-bs-theme="dark"] .display-4, 
[data-bs-theme="dark"] .display-5 {
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

/* Search Bar Transition Fix */
[data-bs-theme="dark"] .header-search input::placeholder {
    color: rgba(255, 255, 255, 0.5) !important;
}
/* ===== Hero Section Seamless Dark Background ===== */
[data-bs-theme="dark"] .hero-section {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}

/* Fix for the 3 Hero Feature Badges/Buttons */
[data-bs-theme="dark"] .hero-section .badge.bg-white,
[data-bs-theme="dark"] .hero-section .bg-white.rounded-3.shadow-sm.border {
    background-color: rgba(255, 255, 255, 0.05) !important;
    color: #f8fafc !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    backdrop-filter: blur(5px);
}

/* Text Visibility inside those 3 Buttons */
[data-bs-theme="dark"] .hero-section .text-dark {
    color: #f8fafc !important;
}

/* Secondary Hero Text (The Lead Paragraph) */
[data-bs-theme="dark"] .hero-section .lead.text-muted {
    color: #94a3b8 !important;
}

* {
    transition: background 0.3s ease, color 0.3s ease, border 0.3s ease;
}
[data-bs-theme="dark"] .btn-primary {
    background-color: #3b82f6;
    border-color: #3b82f6;
}

[data-bs-theme="dark"] .btn-primary:hover {
    background-color: #2563eb;
}
[data-bs-theme="dark"] input,
[data-bs-theme="dark"] textarea {
    background-color: #0f172a !important;
    color: #f8fafc !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
}

[data-bs-theme="dark"] input::placeholder {
    color: rgba(255,255,255,0.5);
}
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-thumb {
    background: #0d6efd;
    border-radius: 10px;
}
[data-bs-theme="dark"] .ads-box {
    background: #1e293b;
    border: 1px dashed rgba(255,255,255,0.1);
}

    /* Smooth Adaptive Background */
    .bg-adaptive-smooth {
        background-color: var(--bs-tertiary-bg) !important;
    }

    /* Custom Border for Dark/Light Mode */
    .border-end-adaptive {
        border-right: 1px solid var(--bs-border-color-translucent);
    }

    /* Text color for Private label in Dark Mode */
    .text-adaptive {
        color: var(--bs-emphasis-color) !important;
    }

    .fw-extrabold { font-weight: 800 !important; }
    .ls-1 { letter-spacing: 1px; font-size: 11px; }

    /* Remove border on Mobile */
    @media (max-width: 768px) {
        .border-end-adaptive {
            border-right: none;
            border-bottom: 1px solid var(--bs-border-color-translucent);
        }
    }

    /* Print Logic */
    @media print {
        .stats-full-wrapper, .no-print {
            display: none !important;
        }
    }
