/* Theme Switcher Styles */
.theme-switcher {
    position: relative;
    display: inline-block;
    margin-left: 12px;
}

.theme-btn {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 10px;
    padding: 8px 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    color: inherit;
    transition: all 0.2s ease;
}

.theme-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

.theme-icon {
    font-size: 1rem;
}

.theme-dropdown {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    background: rgba(30, 30, 46, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    min-width: 140px;
    padding: 6px;
    z-index: 1001;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.theme-dropdown.show {
    display: block;
    animation: fadeIn 0.15s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.theme-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 8px;
    cursor: pointer;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.15s ease;
}

.theme-option:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.theme-option.active {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.theme-option-icon {
    font-size: 1rem;
    width: 20px;
    text-align: center;
}

/* Light Theme Variables */
[data-theme="light"] {
    --bg-color: #f8fafc;
    --text-primary: #1e293b;
    --text-secondary: #475569;
    --glass-bg: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(0, 0, 0, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.08);
    --accent-gradient: linear-gradient(135deg, #2563eb 0%, #9333ea 100%);
    --card-bg: #ffffff;
    --card-border: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] body {
    background-color: var(--bg-color) !important;
    color: var(--text-primary) !important;
}

/* Background mesh - lighter version */
[data-theme="light"] .ambient-mesh {
    background: linear-gradient(180deg,
            #f8fafc 0%,
            #e2e8f0 50%,
            #f8fafc 100%) !important;
}

[data-theme="light"] .ambient-mesh::before {
    background: radial-gradient(circle,
            rgba(37, 99, 235, 0.1) 0%,
            rgba(37, 99, 235, 0.03) 30%,
            transparent 60%) !important;
}

[data-theme="light"] .ambient-mesh::after {
    background: radial-gradient(circle,
            rgba(147, 51, 234, 0.08) 0%,
            rgba(147, 51, 234, 0.02) 30%,
            transparent 60%) !important;
}

/* Header */
[data-theme="light"] header {
    background: rgba(255, 255, 255, 0.9) !important;
    border-bottom-color: rgba(0, 0, 0, 0.08) !important;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
}

[data-theme="light"] .logo {
    color: #1e293b !important;
}

[data-theme="light"] nav a {
    color: #64748b !important;
}

[data-theme="light"] nav a:hover {
    color: #1e293b !important;
    background: rgba(0, 0, 0, 0.05) !important;
}

/* CRITICAL: Hero heading gradient - must override inline styles */
[data-theme="light"] .hero h1 {
    background: linear-gradient(135deg, #1e40af 0%, #7c3aed 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    text-shadow: none !important;
}

[data-theme="light"] .hero p {
    color: #475569 !important;
}

/* Apps section */
[data-theme="light"] .apps h2 {
    background: linear-gradient(135deg, #1e40af 0%, #7c3aed 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    color: transparent !important;
}

/* App cards */
[data-theme="light"] .app-card {
    background: rgba(255, 255, 255, 0.95) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06) !important;
}

[data-theme="light"] .app-card:hover {
    background: #ffffff !important;
    border-color: rgba(37, 99, 235, 0.2) !important;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.1) !important;
}

[data-theme="light"] .app-card h3 {
    color: #1e293b !important;
}

[data-theme="light"] .app-card p {
    color: #64748b !important;
}

[data-theme="light"] .app-card .tagline {
    color: #2563eb !important;
}

/* Category sections */
[data-theme="light"] .category-header h2 {
    color: #1e293b !important;
}

[data-theme="light"] .category-count {
    background: rgba(37, 99, 235, 0.12) !important;
    color: #1e40af !important;
}

[data-theme="light"] .category-icon {
    color: #1e293b !important;
}

/* Tool cards */
[data-theme="light"] .tool-card {
    background: #ffffff !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04) !important;
}

[data-theme="light"] .tool-card:hover {
    border-color: rgba(37, 99, 235, 0.25) !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1) !important;
}

[data-theme="light"] .tool-card h3 {
    color: #1e293b !important;
}

[data-theme="light"] .tool-card p {
    color: #64748b !important;
}

/* Features section */
[data-theme="light"] .features h2 {
    background: linear-gradient(135deg, #1e40af 0%, #7c3aed 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
}

[data-theme="light"] .feature-item {
    background: rgba(255, 255, 255, 0.9) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04) !important;
}

[data-theme="light"] .feature-item:hover {
    background: #ffffff !important;
    border-color: rgba(37, 99, 235, 0.15) !important;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08) !important;
}

[data-theme="light"] .feature-item h3 {
    color: #1e293b !important;
}

[data-theme="light"] .feature-item p {
    color: #64748b !important;
}

/* Footer */
[data-theme="light"] footer {
    background: rgba(255, 255, 255, 0.9) !important;
    border-top: 1px solid rgba(0, 0, 0, 0.08) !important;
}

[data-theme="light"] footer p,
[data-theme="light"] footer a {
    color: #64748b !important;
}

[data-theme="light"] footer a:hover {
    color: #2563eb !important;
}

/* Theme dropdown for light mode */
[data-theme="light"] .theme-dropdown {
    background: #ffffff !important;
    border-color: rgba(0, 0, 0, 0.1) !important;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15) !important;
}

[data-theme="light"] .theme-option {
    color: #475569 !important;
}

[data-theme="light"] .theme-option:hover {
    background: rgba(0, 0, 0, 0.05) !important;
    color: #1e293b !important;
}

[data-theme="light"] .theme-option.active {
    background: rgba(37, 99, 235, 0.1) !important;
    color: #2563eb !important;
}

[data-theme="light"] .theme-btn {
    background: rgba(0, 0, 0, 0.06) !important;
    border-color: rgba(0, 0, 0, 0.12) !important;
    color: #475569 !important;
}

[data-theme="light"] .theme-btn:hover {
    background: rgba(0, 0, 0, 0.1) !important;
}

/* Lang dropdown for light mode */
[data-theme="light"] .lang-dropdown {
    background: #ffffff !important;
    border-color: rgba(0, 0, 0, 0.1) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15) !important;
}

[data-theme="light"] .lang-dropdown a {
    color: #475569 !important;
}

[data-theme="light"] .lang-dropdown a:hover {
    background: rgba(0, 0, 0, 0.05) !important;
    color: #1e293b !important;
}

[data-theme="light"] .lang-btn {
    color: #64748b !important;
}

/* Store badges stay dark */
[data-theme="light"] .store-badge {
    background: rgba(0, 0, 0, 0.85) !important;
    color: white !important;
}

/* Tool link buttons */
[data-theme="light"] .tool-link {
    color: #2563eb !important;
}

/* Generic text overrides for all pages */
[data-theme="light"] h1,
[data-theme="light"] h2,
[data-theme="light"] h3,
[data-theme="light"] h4 {
    color: #1e293b;
}

[data-theme="light"] p {
    color: #475569;
}

[data-theme="light"] strong,
[data-theme="light"] b {
    color: #1e293b;
}

[data-theme="light"] li {
    color: #475569;
}

[data-theme="light"] a {
    color: #2563eb;
}

/* Highlight/quote boxes */
[data-theme="light"] .highlight {
    background: rgba(37, 99, 235, 0.08) !important;
    border-left-color: #2563eb !important;
}

/* Value cards (about page) */
[data-theme="light"] .value-card {
    background: rgba(255, 255, 255, 0.9) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
}

[data-theme="light"] .value-card:hover {
    background: #ffffff !important;
    border-color: rgba(37, 99, 235, 0.2) !important;
}

/* Stat cards */
[data-theme="light"] .stat-card {
    background: rgba(37, 99, 235, 0.08) !important;
    border-color: rgba(37, 99, 235, 0.15) !important;
}

[data-theme="light"] .stat-label {
    color: #64748b !important;
}

/* Contact box */
[data-theme="light"] .contact-box {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1) 0%, rgba(147, 51, 234, 0.1) 100%) !important;
    border-color: rgba(37, 99, 235, 0.2) !important;
}

[data-theme="light"] .contact-box h2 {
    color: #1e293b !important;
    -webkit-text-fill-color: #1e293b !important;
}

/* Content sections */
[data-theme="light"] .content {
    color: #334155 !important;
}

[data-theme="light"] .subtitle {
    color: #64748b !important;
}

/* =================================================
   HOMEPAGE ABOUT SECTION - Light mode overrides
   ================================================= */
/* More specific selector to ensure override */
[data-theme="light"] h2.about-title,
[data-theme="light"] .about-section h2.about-title,
[data-theme="light"] .about-section .about-title,
[data-theme="light"] .about-title {
    background: linear-gradient(135deg, #1e40af 0%, #7c3aed 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    color: transparent !important;
}

[data-theme="light"] .about-content-box {
    background: rgba(255, 255, 255, 0.9) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
}

[data-theme="light"] .about-text {
    color: #475569 !important;
}

[data-theme="light"] .about-text strong {
    color: #1e293b !important;
}

[data-theme="light"] .about-feature-card {
    background: rgba(37, 99, 235, 0.08) !important;
    border: 1px solid rgba(37, 99, 235, 0.15) !important;
}

[data-theme="light"] .about-feature-title {
    color: #1e293b !important;
}

[data-theme="light"] .about-feature-text {
    color: #64748b !important;
}

[data-theme="light"] .about-cta-btn {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.12) 0%, rgba(147, 51, 234, 0.12) 100%) !important;
    color: #1e40af !important;
    border-color: rgba(37, 99, 235, 0.25) !important;
}

[data-theme="light"] .about-cta-btn:hover {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.2) 0%, rgba(147, 51, 234, 0.2) 100%) !important;
    border-color: rgba(37, 99, 235, 0.4) !important;
}

/* =================================================
   ABOUT PAGE (about.html) - Light mode overrides
   ================================================= */
/* Body and background */
[data-theme="light"] body {
    background: #f8fafc !important;
    color: #1e293b !important;
}

/* Header */
[data-theme="light"] header {
    border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important;
}

/* Navigation links */
[data-theme="light"] nav a {
    color: #475569 !important;
}

[data-theme="light"] nav a:hover {
    color: #1e293b !important;
}

/* Page heading h1 - gradient text */
[data-theme="light"] .content h1 {
    background: linear-gradient(135deg, #1e40af 0%, #7c3aed 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
}

/* Subtitle */
[data-theme="light"] .subtitle {
    color: #64748b !important;
}

/* Section headings h2 */
[data-theme="light"] .content h2 {
    color: #1e40af !important;
}

/* Section headings h3 */
[data-theme="light"] .content h3 {
    color: #6366f1 !important;
}

/* Paragraph text */
[data-theme="light"] .content p {
    color: #475569 !important;
}

/* List items */
[data-theme="light"] .content ul,
[data-theme="light"] .content li {
    color: #475569 !important;
}

/* Strong/bold text */
[data-theme="light"] .content strong {
    color: #1e293b !important;
}

/* Highlight box */
[data-theme="light"] .highlight {
    background: rgba(37, 99, 235, 0.08) !important;
    border-left-color: #2563eb !important;
}

/* Value cards */
[data-theme="light"] .value-card {
    background: rgba(255, 255, 255, 0.9) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
}

[data-theme="light"] .value-card:hover {
    background: rgba(255, 255, 255, 1) !important;
    border-color: rgba(37, 99, 235, 0.3) !important;
}

[data-theme="light"] .value-card h3 {
    color: #6366f1 !important;
}

[data-theme="light"] .value-card p {
    color: #475569 !important;
}

/* Stat cards */
[data-theme="light"] .stat-card {
    background: rgba(37, 99, 235, 0.08) !important;
    border: 1px solid rgba(37, 99, 235, 0.15) !important;
}

[data-theme="light"] .stat-label {
    color: #64748b !important;
}

/* Contact box */
[data-theme="light"] .contact-box {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.08) 0%, rgba(147, 51, 234, 0.08) 100%) !important;
    border: 1px solid rgba(37, 99, 235, 0.2) !important;
}

[data-theme="light"] .contact-box h2 {
    color: #1e293b !important;
}

[data-theme="light"] .contact-box p {
    color: #475569 !important;
}

/* Footer */
[data-theme="light"] footer {
    border-top: 1px solid rgba(0, 0, 0, 0.08) !important;
    background: rgba(248, 250, 252, 0.8) !important;
}

[data-theme="light"] .footer-links a {
    color: #64748b !important;
}

[data-theme="light"] .footer-links a:hover {
    color: #1e293b !important;
}

[data-theme="light"] .copyright {
    color: #94a3b8 !important;
}