[data-bs-theme="dark"] {
    /* Background Layers - Purple-tinted Dark */
    --crypto-bg-base: #0c0b12;
    --crypto-bg-primary: #0c0b12;
    --crypto-bg-secondary: #14131c;
    --crypto-bg-elevated: #14131c;
    --crypto-bg-elevated-hover: #18171f;
    --crypto-bg-hover: #1c1b24;
    --crypto-bg-active: #201f28;
    --crypto-bg-input: #1c1b26;
    --crypto-bg-input-focus: #201f2a;

    /* Glass/Overlay Layers */
    --crypto-glass-subtle: rgba(28, 24, 52, 0.4);
    --crypto-glass-light: rgba(28, 24, 52, 0.6);
    --crypto-glass-medium: rgba(28, 24, 52, 0.75);
    --crypto-glass-heavy: rgba(28, 24, 52, 0.9);
    --crypto-glass-navbar: rgba(28, 24, 52, 0.85);
    --crypto-glass-dropdown: rgba(28, 24, 52, 0.95);

    /* Legacy (for backwards compatibility) */
    --crypto-bg-glass: var(--crypto-glass-light);
    --crypto-bg-glass-scrolled: var(--crypto-glass-navbar);
    --crypto-bg-dropdown: var(--crypto-glass-dropdown);

    /* Overlay Variants */
    --crypto-overlay-light: rgba(12, 11, 18, 0.6);
    --crypto-overlay-medium: rgba(12, 11, 18, 0.8);
    --crypto-overlay-heavy: rgba(12, 11, 18, 0.95);

    /* Text Colors - Enhanced Contrast (WCAG AA) */
    --crypto-text-primary: #ffffff;
    --crypto-text-primary-emphasis: #f8f9fa;
    --crypto-text-secondary: #a0a7c9;
    --crypto-text-tertiary: #8891b8;
    --crypto-text-muted: #7a82a8;
    --crypto-text-disabled: #4a5273;

    /* Monospace/Technical Text */
    --crypto-text-mono: #b4b5fb;
    --crypto-text-mono-highlight: #c8c9ff;

    /* Border Colors */
    --crypto-border-subtle: rgba(139, 146, 183, 0.08);
    --crypto-border-default: rgba(139, 146, 183, 0.12);
    --crypto-border-emphasis: rgba(139, 146, 183, 0.2);
    --crypto-border-strong: rgba(139, 146, 183, 0.3);
    --crypto-border-glass: rgba(255, 255, 255, 0.1);
    --crypto-border-glass-strong: rgba(255, 255, 255, 0.15);

    /* Legacy (for backwards compatibility) */
    --crypto-border: var(--crypto-border-default);
    --crypto-border-hover: var(--crypto-border-emphasis);

    /* Shadows */
    --crypto-shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
    --crypto-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.35);
    --crypto-shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --crypto-shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --crypto-shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.6);
    --crypto-shadow-2xl: 0 24px 64px rgba(0, 0, 0, 0.7);
    --crypto-shadow-header: 0 4px 24px rgba(0, 0, 0, 0.5);

    /* Glow Effects */
    --crypto-glow-accent-sm: 0 0 16px rgba(120, 121, 246, 0.3);
    --crypto-glow-accent-md: 0 0 24px rgba(120, 121, 246, 0.4);
    --crypto-glow-accent-lg: 0 0 32px rgba(120, 121, 246, 0.5);
    --crypto-glow-success: 0 0 20px rgba(34, 197, 94, 0.3);
    --crypto-glow-warning: 0 0 20px rgba(245, 158, 11, 0.3);
    --crypto-glow-danger: 0 0 20px rgba(239, 68, 68, 0.3);
    --crypto-glow-cyan: 0 0 24px rgba(6, 182, 212, 0.4);

    /* Legacy (for backwards compatibility) */
    --crypto-shadow-glow: var(--crypto-glow-accent-md);

    /* Combined Shadow + Glow */
    --crypto-shadow-glow-accent: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 24px rgba(120, 121, 246, 0.3);

    /* Inner Shadows (Depth) */
    --crypto-shadow-inset-sm: inset 0 1px 3px rgba(0, 0, 0, 0.3);
    --crypto-shadow-inset-md: inset 0 2px 6px rgba(0, 0, 0, 0.4);

    /* Semantic Colors - Success (Green) */
    --crypto-success-400: #4ade80;
    --crypto-success-500: #22c55e;
    --crypto-success-600: #16a34a;
    --crypto-success-alpha-10: rgba(34, 197, 94, 0.1);
    --crypto-success-alpha-15: rgba(34, 197, 94, 0.15);
    --crypto-success-alpha-20: rgba(34, 197, 94, 0.2);
    --crypto-success-bg: rgba(34, 197, 94, 0.12);
    --crypto-success-border: rgba(34, 197, 94, 0.3);

    /* Semantic Colors - Warning (Amber/Orange) */
    --crypto-warning-400: #fbbf24;
    --crypto-warning-500: #f59e0b;
    --crypto-warning-600: #d97706;
    --crypto-warning-alpha-10: rgba(245, 158, 11, 0.1);
    --crypto-warning-alpha-15: rgba(245, 158, 11, 0.15);
    --crypto-warning-alpha-20: rgba(245, 158, 11, 0.2);
    --crypto-warning-bg: rgba(245, 158, 11, 0.12);
    --crypto-warning-border: rgba(245, 158, 11, 0.3);

    /* Semantic Colors - Danger (Red) */
    --crypto-danger-400: #f87171;
    --crypto-danger-500: #ef4444;
    --crypto-danger-600: #dc2626;
    --crypto-danger-alpha-10: rgba(239, 68, 68, 0.1);
    --crypto-danger-alpha-15: rgba(239, 68, 68, 0.15);
    --crypto-danger-alpha-20: rgba(239, 68, 68, 0.2);
    --crypto-danger-bg: rgba(239, 68, 68, 0.12);
    --crypto-danger-border: rgba(239, 68, 68, 0.3);

    /* Semantic Colors - Info (Blue) */
    --crypto-info-400: #60a5fa;
    --crypto-info-500: #3b82f6;
    --crypto-info-600: #2563eb;
    --crypto-info-alpha-10: rgba(59, 130, 246, 0.1);
    --crypto-info-alpha-15: rgba(59, 130, 246, 0.15);
    --crypto-info-alpha-20: rgba(59, 130, 246, 0.2);
    --crypto-info-bg: rgba(59, 130, 246, 0.12);
    --crypto-info-border: rgba(59, 130, 246, 0.3);

    /* Accent Colors - Primary (Indigo/Purple) */
    --crypto-accent-300: #b4b5fb;
    --crypto-accent-400: #9899f9;
    --crypto-accent-500: #7879F6;
    --crypto-accent-600: #5c5de6;
    --crypto-accent-alpha-10: rgba(120, 121, 246, 0.1);
    --crypto-accent-alpha-20: rgba(120, 121, 246, 0.2);
    --crypto-accent-alpha-30: rgba(120, 121, 246, 0.3);

    /* Accent Colors - Secondary (Violet) */
    --crypto-violet-400: #a78bfa;
    --crypto-violet-500: #8b5cf6;
    --crypto-violet-600: #7c3aed;

    /* Accent Colors - Tertiary (Cyan/Teal) */
    --crypto-cyan-400: #22d3ee;
    --crypto-cyan-500: #06b6d4;
    --crypto-cyan-600: #0891b2;
    --crypto-cyan-alpha-10: rgba(6, 182, 212, 0.1);
    --crypto-cyan-alpha-20: rgba(6, 182, 212, 0.2);
}

/* Override Tabler body background */
[data-bs-theme="dark"] {
    --tblr-body-bg: #0c0b12;
    --tblr-body-color: #ffffff;
}