/* ==========================================================================
   Sunshine UI - Modern Design System
   ========================================================================== */

/* Hide pages while localization is loading */
[v-cloak] {
    display: none;
}

/* ==========================================================================
   CSS Custom Properties - Design Tokens
   ========================================================================== */

:root {
    /* Spacing Scale */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;

    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 200ms ease;
    --transition-slow: 300ms ease;

    /* Shadows - Light theme defaults */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);

    --color-on-primary: #fff;
    --color-on-success: #fff;
    --color-on-danger: #fff;
    --color-on-info: #fff;
    --color-on-warning: #1a1a1a;
}

/* ==========================================================================
   Dark Themes
   ========================================================================== */

/* Dark Theme - Simple clean dark design */
[data-theme="dark"] {
    --color-primary: #0d6efd;
    --color-primary-hover: #3d8bfd;
    --color-primary-light: #031633;
    --color-accent: #fd7e14;
    --color-accent-hover: #fd9843;
    --color-accent-light: #331e08;
    --color-success: #198754;
    --color-success-hover: #20c997;
    --color-success-light: #051b11;
    --color-danger: #dc3545;
    --color-danger-hover: #e35d6a;
    --color-danger-light: #2c0b0e;
    --color-warning: #ffc107;
    --color-warning-hover: #ffcd39;
    --color-warning-light: #332701;
    --color-info: #0dcaf0;
    --color-info-hover: #3dd5f3;
    --color-info-light: #032830;

    --color-on-info: #1a1a1a;

    --color-bg-base: #212529;
    --color-bg-subtle: #2c3034;
    --color-bg-muted: #383d41;
    --color-surface: #2c3034;
    --color-surface-raised: #383d41;

    --color-border: #495057;
    --color-border-strong: #6c757d;

    --color-text-base: #f8f9fa;
    --color-text-muted: #adb5bd;
    --color-text-subtle: #6c757d;

    --navbar-bg: linear-gradient(135deg, #ffc400 0%, #ff9d00 100%);
    --navbar-text: #594400;
    --navbar-text-muted: #7f6100;

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -2px rgba(0, 0, 0, 0.3);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.3);
}

/* Ember Theme - https://github.com/ember-theme/ember */
[data-theme="ember"] {
    --color-primary: #E08060;
    --color-primary-hover: #E7A088;
    --color-primary-light: #452217;
    --color-accent: #C09058;
    --color-accent-hover: #CEA87E;
    --color-accent-light: #392A18;
    --color-success: #8A9868;
    --color-success-hover: #9DAB7C;
    --color-success-light: #292E1F;
    --color-danger: #B07878;
    --color-danger-hover: #C28E8E;
    --color-danger-light: #381E1E;
    --color-warning: #C8B468;
    --color-warning-hover: #D9C98C;
    --color-warning-light: #393318;
    --color-info: #7890A0;
    --color-info-hover: #92AAB9;
    --color-info-light: #1F2B33;

    --color-on-primary: #282418;
    --color-on-success: #282418;
    --color-on-danger: #282418;
    --color-on-info: #282418;

    --color-bg-base: #1C1B19;
    --color-bg-subtle: #242320;
    --color-bg-muted: #33302B;
    --color-surface: #242320;
    --color-surface-raised: #33302B;

    --color-border: #45413B;
    --color-border-strong: #5C574F;

    --color-text-base: #D8D0C0;
    --color-text-muted: #B0A48D;
    --color-text-subtle: #93866C;

    --navbar-bg: linear-gradient(135deg, #D06A4C 0%, #C87D52 50%, #C09058 100%);
    --navbar-text: #282418;
    --navbar-text-muted: rgba(40, 36, 24, 0.72);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.6), 0 2px 4px -1px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.6), 0 4px 6px -2px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6), 0 10px 10px -5px rgba(0, 0, 0, 0.5);
}

/* Midnight Theme - Deep dark blue */
[data-theme="midnight"] {
    --color-primary: #5C6BF5;
    --color-primary-hover: #7C88F8;
    --color-primary-light: #1E1E6E;
    --color-accent: #2FC4DE;
    --color-accent-hover: #5BD4E9;
    --color-accent-light: #0E3C47;
    --color-success: #3FD9A0;
    --color-success-hover: #67E4B6;
    --color-success-light: #0D3D2D;
    --color-danger: #F76C7A;
    --color-danger-hover: #FB8E99;
    --color-danger-light: #41121E;
    --color-warning: #F5C04B;
    --color-warning-hover: #F9D079;
    --color-warning-light: #33270D;
    --color-info: #5BB0F5;
    --color-info-hover: #82C4F8;
    --color-info-light: #102C4F;

    --color-on-primary: #1C1928;
    --color-on-success: #1C1928;
    --color-on-info: #1C1928;
    --color-on-danger: #1C1928;

    --color-bg-base: #0A0A20;
    --color-bg-subtle: #121238;
    --color-bg-muted: #1C1C50;
    --color-surface: #121238;
    --color-surface-raised: #1C1C50;

    --color-border: #242460;
    --color-border-strong: #313188;

    --color-text-base: #E6E8FF;
    --color-text-muted: #C3C7F0;
    --color-text-subtle: #9498D0;

    --navbar-bg: linear-gradient(135deg, #0A0A24 0%, #16165A 50%, #191970 100%);
    --navbar-text: #E6E8FF;
    --navbar-text-muted: rgba(230, 232, 255, 0.8);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.6), 0 2px 4px -1px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.6), 0 4px 6px -2px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6), 0 10px 10px -5px rgba(0, 0, 0, 0.5);
}

/* Moonlight Theme - Cool and serene inspired by moonlight */
[data-theme="moonlight"] {
    --color-primary: #B0BCDF;
    --color-primary-hover: #C8D1EA;
    --color-primary-light: #2A2440;
    --color-accent: #9A7FD1;
    --color-accent-hover: #B49EE0;
    --color-accent-light: #443266;
    --color-success: #5BD6A3;
    --color-success-hover: #7FE3BB;
    --color-success-light: #163A2E;
    --color-danger: #F0738A;
    --color-danger-hover: #F596A8;
    --color-danger-light: #3D1F2A;
    --color-warning: #E5B567;
    --color-warning-hover: #EFC988;
    --color-warning-light: #332918;
    --color-info: #7C9BE0;
    --color-info-hover: #9DB5EA;
    --color-info-light: #232A40;

    --color-on-primary: #1C1928;
    --color-on-success: #1C1928;
    --color-on-info: #1C1928;
    --color-on-danger: #1C1928;

    --color-bg-base: #15131D;
    --color-bg-subtle: #1C1928;
    --color-bg-muted: #2A2540;
    --color-surface: #1C1928;
    --color-surface-raised: #2A2540;

    --color-border: #322C44;
    --color-border-strong: #463A5E;

    --color-text-base: #E6E8F4;
    --color-text-muted: #C0C6DD;
    --color-text-subtle: #B0BCDF;

    --navbar-bg: linear-gradient(135deg, #1B1726 0%, #2E2547 50%, #443266 100%);
    --navbar-text: #E6E8F4;
    --navbar-text-muted: rgba(230, 232, 244, 0.8);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.6), 0 2px 4px -1px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.6), 0 4px 6px -2px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6), 0 10px 10px -5px rgba(0, 0, 0, 0.5);
}

/* Nord Theme - Popular Nordic color palette */
[data-theme="nord"] {
    --color-primary: #5E81AC;
    --color-primary-hover: #81A1C1;
    --color-primary-light: #434C5E;
    --color-accent: #88C0D0;
    --color-accent-hover: #8FBCBB;
    --color-accent-light: #434C5E;
    --color-success: #A3BE8C;
    --color-success-hover: #B8D4A3;
    --color-success-light: #434C5E;
    --color-danger: #BF616A;
    --color-danger-hover: #D08770;
    --color-danger-light: #434C5E;
    --color-warning: #EBCB8B;
    --color-warning-hover: #F0D9A6;
    --color-warning-light: #434C5E;
    --color-info: #5E81AC;
    --color-info-hover: #81A1C1;
    --color-info-light: #434C5E;

    --color-bg-base: #2E3440;
    --color-bg-subtle: #3B4252;
    --color-bg-muted: #434C5E;
    --color-surface: #3B4252;
    --color-surface-raised: #434C5E;

    --color-border: #4C566A;
    --color-border-strong: #5E6B82;

    --color-text-base: #ECEFF4;
    --color-text-muted: #D8DEE9;
    --color-text-subtle: #E5E9F0;

    --navbar-bg: linear-gradient(135deg, #2E3440 0%, #3B4252 100%);
    --navbar-text: #ECEFF4;
    --navbar-text-muted: rgba(236, 239, 244, 0.8);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.5), 0 2px 4px -1px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -2px rgba(0, 0, 0, 0.4);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.5), 0 10px 10px -5px rgba(0, 0, 0, 0.4);
}

/* Slate Theme - Modern slate gray design */
[data-theme="slate"] {
    --color-primary: #6366F1;
    --color-primary-hover: #818CF8;
    --color-primary-light: #312E81;
    --color-accent: #FBBF24;
    --color-accent-hover: #FCD34D;
    --color-accent-light: #78350F;
    --color-success: #34D399;
    --color-success-hover: #6EE7B7;
    --color-success-light: #064E3B;
    --color-danger: #F87171;
    --color-danger-hover: #FCA5A5;
    --color-danger-light: #7F1D1D;
    --color-warning: #FBBF24;
    --color-warning-hover: #FCD34D;
    --color-warning-light: #43300F;
    --color-info: #60A5FA;
    --color-info-hover: #93C5FD;
    --color-info-light: #1E3A8A;

    --color-bg-base: #0F172A;
    --color-bg-subtle: #1E293B;
    --color-bg-muted: #334155;
    --color-surface: #1E293B;
    --color-surface-raised: #334155;

    --color-border: #334155;
    --color-border-strong: #475569;

    --color-text-base: #F1F5F9;
    --color-text-muted: #CBD5E1;
    --color-text-subtle: #94A3B8;

    --navbar-bg: linear-gradient(135deg, #1E293B 0%, #334155 100%);
    --navbar-text: #F1F5F9;
    --navbar-text-muted: rgba(241, 245, 249, 0.8);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -2px rgba(0, 0, 0, 0.3);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.3);
}

/* Dracula Theme - https://draculatheme.com */
[data-theme="dracula"] {
    --color-primary: #BD93F9;
    --color-primary-hover: #CFB0FB;
    --color-primary-light: #3A2D5C;
    --color-accent: #FFB86C;
    --color-accent-hover: #FFCB93;
    --color-accent-light: #43331D;
    --color-success: #50FA7B;
    --color-success-hover: #74FB97;
    --color-success-light: #143D24;
    --color-danger: #FF5555;
    --color-danger-hover: #FF7B7B;
    --color-danger-light: #43201F;
    --color-warning: #F1FA8C;
    --color-warning-hover: #F5FCA8;
    --color-warning-light: #3F421F;
    --color-info: #8BE9FD;
    --color-info-hover: #ABF0FE;
    --color-info-light: #173B43;

    --color-on-primary: #282A36;
    --color-on-success: #282A36;
    --color-on-info: #282A36;

    --color-bg-base: #282A36;
    --color-bg-subtle: #343746;
    --color-bg-muted: #424450;
    --color-surface: #343746;
    --color-surface-raised: #424450;

    --color-border: #44475A;
    --color-border-strong: #6272A4;

    --color-text-base: #F8F8F2;
    --color-text-muted: #6272A4;
    --color-text-subtle: #6272A4;

    --navbar-bg: linear-gradient(135deg, #A98FD8 0%, #C792BB 100%);
    --navbar-text: #282A36;
    --navbar-text-muted: rgba(40, 42, 54, 0.7);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.6), 0 2px 4px -1px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.6), 0 4px 6px -2px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6), 0 10px 10px -5px rgba(0, 0, 0, 0.5);
}

/* Catppuccin Mocha - https://github.com/catppuccin/catppuccin */
[data-theme="mocha"] {
    --color-primary: #cba6f7;
    --color-primary-hover: #d5b8f9;
    --color-primary-light: #3c2e5c;
    --color-accent: #f5c2e7;
    --color-accent-hover: #f7ceec;
    --color-accent-light: #4a2e44;
    --color-success: #a6e3a1;
    --color-success-hover: #b8e9b4;
    --color-success-light: #1e3d24;
    --color-danger: #f38ba8;
    --color-danger-hover: #f5a2b9;
    --color-danger-light: #4a2230;
    --color-warning: #f9e2af;
    --color-warning-hover: #fae8bf;
    --color-warning-light: #41391f;
    --color-info: #89b4fa;
    --color-info-hover: #a1c3fb;
    --color-info-light: #1e2e4a;

    --color-on-primary: #1e1e2e;
    --color-on-success: #1e1e2e;
    --color-on-danger: #1e1e2e;
    --color-on-info: #1e1e2e;

    --color-bg-base: #1e1e2e;
    --color-bg-subtle: #313244;
    --color-bg-muted: #45475a;
    --color-surface: #313244;
    --color-surface-raised: #45475a;

    --color-border: #585b70;
    --color-border-strong: #6c7086;

    --color-text-base: #cdd6f4;
    --color-text-muted: #a6adc8;
    --color-text-subtle: #7f849c;

    --navbar-bg: linear-gradient(135deg, #c9aae8 0%, #e3bdd8 100%);
    --navbar-text: #1e1e2e;
    --navbar-text-muted: rgba(30, 30, 46, 0.75);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.6), 0 2px 4px -1px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.6), 0 4px 6px -2px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6), 0 10px 10px -5px rgba(0, 0, 0, 0.5);
}

/* Rosé Pine Theme - https://rosepinetheme.com */
[data-theme="rose-pine"] {
    --color-primary: #c4a7e7;
    --color-primary-hover: #d0b8ec;
    --color-primary-light: #2e2640;
    --color-accent: #ebbcba;
    --color-accent-hover: #efc9c8;
    --color-accent-light: #3a2b2f;
    --color-success: #31748f;
    --color-success-hover: #3a87a5;
    --color-success-light: #1b2e36;
    --color-danger: #eb6f92;
    --color-danger-hover: #ef85a3;
    --color-danger-light: #3a2530;
    --color-warning: #f6c177;
    --color-warning-hover: #f8cd90;
    --color-warning-light: #3a3020;
    --color-info: #9ccfd8;
    --color-info-hover: #b0d8df;
    --color-info-light: #1f2e30;

    --color-on-primary: #191724;
    --color-on-danger: #191724;
    --color-on-info: #191724;

    --color-bg-base: #191724;
    --color-bg-subtle: #1f1d2e;
    --color-bg-muted: #26233a;
    --color-surface: #1f1d2e;
    --color-surface-raised: #26233a;

    --color-border: #403d52;
    --color-border-strong: #524f67;

    --color-text-base: #e0def4;
    --color-text-muted: #908caa;
    --color-text-subtle: #6e6a86;

    --navbar-bg: linear-gradient(135deg, #c4a7e7 0%, #ebbcba 100%);
    --navbar-text: #191724;
    --navbar-text-muted: rgba(25, 23, 36, 0.75);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.6), 0 2px 4px -1px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.6), 0 4px 6px -2px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6), 0 10px 10px -5px rgba(0, 0, 0, 0.5);
}

/* ==========================================================================
   Light Themes
   ========================================================================== */

/* Light Theme - Simple clean light design */
[data-theme="light"] {
    --color-primary: #0d6efd;
    --color-primary-hover: #0b5ed7;
    --color-primary-light: #cfe2ff;
    --color-accent: #fd7e14;
    --color-accent-hover: #e76c0c;
    --color-accent-light: #ffe5d0;
    --color-success: #198754;
    --color-success-hover: #157347;
    --color-success-light: #d1e7dd;
    --color-danger: #dc3545;
    --color-danger-hover: #bb2d3b;
    --color-danger-light: #f8d7da;
    --color-warning: #ffc107;
    --color-warning-hover: #ffca2c;
    --color-warning-light: #fff3cd;
    --color-info: #0dcaf0;
    --color-info-hover: #31d2f2;
    --color-info-light: #cff4fc;

    --color-on-info: #1a1a1a;

    --color-bg-base: #ffffff;
    --color-bg-subtle: #f8f9fa;
    --color-bg-muted: #e9ecef;
    --color-surface: #ffffff;
    --color-surface-raised: #ffffff;

    --color-border: #dee2e6;
    --color-border-strong: #adb5bd;

    --color-text-base: #212529;
    --color-text-muted: #6c757d;
    --color-text-subtle: #adb5bd;

    --navbar-bg: linear-gradient(135deg, #ffc400 0%, #ff9d00 100%);
    --navbar-text: #594400;
    --navbar-text-muted: #7f6100;
}

/* Forest Theme - Green nature tones */
[data-theme="forest"] {
    --color-primary: #10B981;
    --color-primary-hover: #059669;
    --color-primary-light: #D1FAE5;
    --color-accent: #14B8A6;
    --color-accent-hover: #0D9488;
    --color-accent-light: #CCFBF1;
    --color-success: #22C55E;
    --color-success-hover: #16A34A;
    --color-success-light: #DCFCE7;
    --color-danger: #EF4444;
    --color-danger-hover: #DC2626;
    --color-danger-light: #FEE2E2;
    --color-warning: #F59E0B;
    --color-warning-hover: #D97706;
    --color-warning-light: #FEF3C7;
    --color-info: #3B82F6;
    --color-info-hover: #2563EB;
    --color-info-light: #DBEAFE;

    --color-bg-base: #F0FDF4;
    --color-bg-subtle: #DCFCE7;
    --color-bg-muted: #BBF7D0;
    --color-surface: #FFFFFF;
    --color-surface-raised: #F0FDF4;

    --color-border: #86EFAC;
    --color-border-strong: #4ADE80;

    --color-text-base: #14532D;
    --color-text-muted: #166534;
    --color-text-subtle: #15803D;

    --navbar-bg: linear-gradient(135deg, #10B981 0%, #14B8A6 100%);
    --navbar-text: #FFFFFF;
    --navbar-text-muted: rgba(255, 255, 255, 0.9);
}

/* Indigo Theme - Modern indigo/purple design */
[data-theme="indigo"] {
    --color-primary: #4F46E5;
    --color-primary-hover: #4338CA;
    --color-primary-light: #EEF2FF;
    --color-accent: #F59E0B;
    --color-accent-hover: #D97706;
    --color-accent-light: #FEF3C7;
    --color-success: #10B981;
    --color-success-hover: #059669;
    --color-success-light: #D1FAE5;
    --color-danger: #EF4444;
    --color-danger-hover: #DC2626;
    --color-danger-light: #FEE2E2;
    --color-warning: #F59E0B;
    --color-warning-hover: #D97706;
    --color-warning-light: #FEF3C7;
    --color-info: #3B82F6;
    --color-info-hover: #2563EB;
    --color-info-light: #DBEAFE;

    --color-bg-base: #FFFFFF;
    --color-bg-subtle: #F9FAFB;
    --color-bg-muted: #F3F4F6;
    --color-surface: #FFFFFF;
    --color-surface-raised: #FFFFFF;

    --color-border: #E5E7EB;
    --color-border-strong: #D1D5DB;

    --color-text-base: #111827;
    --color-text-muted: #6B7280;
    --color-text-subtle: #9CA3AF;

    --navbar-bg: linear-gradient(135deg, #4F46E5 0%, #6366F1 100%);
    --navbar-text: #FFFFFF;
    --navbar-text-muted: rgba(255, 255, 255, 0.8);
}

/* Lavender Theme - Soft purple tones */
[data-theme="lavender"] {
    --color-primary: #A78BFA;
    --color-primary-hover: #8B5CF6;
    --color-primary-light: #EDE9FE;
    --color-accent: #C4B5FD;
    --color-accent-hover: #A78BFA;
    --color-accent-light: #DDD6FE;
    --color-success: #10B981;
    --color-success-hover: #059669;
    --color-success-light: #D1FAE5;
    --color-danger: #EF4444;
    --color-danger-hover: #DC2626;
    --color-danger-light: #FEE2E2;
    --color-warning: #F59E0B;
    --color-warning-hover: #D97706;
    --color-warning-light: #FEF3C7;
    --color-info: #3B82F6;
    --color-info-hover: #2563EB;
    --color-info-light: #DBEAFE;

    --color-bg-base: #FAF5FF;
    --color-bg-subtle: #F3E8FF;
    --color-bg-muted: #E9D5FF;
    --color-surface: #FFFFFF;
    --color-surface-raised: #FAF5FF;

    --color-border: #D8B4FE;
    --color-border-strong: #C084FC;

    --color-text-base: #4C1D95;
    --color-text-muted: #5B21B6;
    --color-text-subtle: #6D28D9;

    --navbar-bg: linear-gradient(135deg, #8B5CF6 0%, #A78BFA 100%);
    --navbar-text: #FFFFFF;
    --navbar-text-muted: rgba(255, 255, 255, 0.9);
}

/* Monochrome Theme - Pure black and white */
[data-theme="monochrome"] {
    --color-primary: #18181B;
    --color-primary-hover: #3F3F46;
    --color-primary-light: #F4F4F5;
    --color-accent: #52525B;
    --color-accent-hover: #71717A;
    --color-accent-light: #E4E4E7;
    --color-success: #10B981;
    --color-success-hover: #059669;
    --color-success-light: #D1FAE5;
    --color-danger: #EF4444;
    --color-danger-hover: #DC2626;
    --color-danger-light: #FEE2E2;
    --color-warning: #F59E0B;
    --color-warning-hover: #D97706;
    --color-warning-light: #FEF3C7;
    --color-info: #3B82F6;
    --color-info-hover: #2563EB;
    --color-info-light: #DBEAFE;

    --color-bg-base: #FFFFFF;
    --color-bg-subtle: #FAFAFA;
    --color-bg-muted: #F4F4F5;
    --color-surface: #FFFFFF;
    --color-surface-raised: #FAFAFA;

    --color-border: #E4E4E7;
    --color-border-strong: #D4D4D8;

    --color-text-base: #18181B;
    --color-text-muted: #52525B;
    --color-text-subtle: #71717A;

    --navbar-bg: linear-gradient(135deg, #18181B 0%, #27272A 100%);
    --navbar-text: #FFFFFF;
    --navbar-text-muted: rgba(255, 255, 255, 0.9);
}

/* Ocean Theme - Cool blue tones */
[data-theme="ocean"] {
    --color-primary: #0EA5E9;
    --color-primary-hover: #0284C7;
    --color-primary-light: #E0F2FE;
    --color-accent: #06B6D4;
    --color-accent-hover: #0891B2;
    --color-accent-light: #CFFAFE;
    --color-success: #10B981;
    --color-success-hover: #059669;
    --color-success-light: #D1FAE5;
    --color-danger: #EF4444;
    --color-danger-hover: #DC2626;
    --color-danger-light: #FEE2E2;
    --color-warning: #F59E0B;
    --color-warning-hover: #D97706;
    --color-warning-light: #FEF3C7;
    --color-info: #3B82F6;
    --color-info-hover: #2563EB;
    --color-info-light: #DBEAFE;

    --color-bg-base: #F0F9FF;
    --color-bg-subtle: #E0F2FE;
    --color-bg-muted: #BAE6FD;
    --color-surface: #FFFFFF;
    --color-surface-raised: #F0F9FF;

    --color-border: #7DD3FC;
    --color-border-strong: #38BDF8;

    --color-text-base: #0C4A6E;
    --color-text-muted: #075985;
    --color-text-subtle: #0369A1;

    --navbar-bg: linear-gradient(135deg, #0EA5E9 0%, #06B6D4 100%);
    --navbar-text: #FFFFFF;
    --navbar-text-muted: rgba(255, 255, 255, 0.9);
}

/* Rose Theme - Elegant pink tones */
[data-theme="rose"] {
    --color-primary: #EC4899;
    --color-primary-hover: #DB2777;
    --color-primary-light: #FCE7F3;
    --color-accent: #F472B6;
    --color-accent-hover: #EC4899;
    --color-accent-light: #FBCFE8;
    --color-success: #10B981;
    --color-success-hover: #059669;
    --color-success-light: #D1FAE5;
    --color-danger: #EF4444;
    --color-danger-hover: #DC2626;
    --color-danger-light: #FEE2E2;
    --color-warning: #F59E0B;
    --color-warning-hover: #D97706;
    --color-warning-light: #FEF3C7;
    --color-info: #3B82F6;
    --color-info-hover: #2563EB;
    --color-info-light: #DBEAFE;

    --color-bg-base: #FFF1F2;
    --color-bg-subtle: #FFE4E6;
    --color-bg-muted: #FECDD3;
    --color-surface: #FFFFFF;
    --color-surface-raised: #FFF1F2;

    --color-border: #FBCFE8;
    --color-border-strong: #F9A8D4;

    --color-text-base: #881337;
    --color-text-muted: #9F1239;
    --color-text-subtle: #BE123C;

    --navbar-bg: linear-gradient(135deg, #EC4899 0%, #F472B6 100%);
    --navbar-text: #FFFFFF;
    --navbar-text-muted: rgba(255, 255, 255, 0.9);
}

/* Sunshine Theme - Warm and bright inspired by sunlight */
[data-theme="sunshine"] {
    --color-primary: #F59E0B;
    --color-primary-hover: #D97706;
    --color-primary-light: #FEF3C7;
    --color-on-primary: #1a1a1a;
    --color-accent: #FB923C;
    --color-accent-hover: #F97316;
    --color-accent-light: #FFEDD5;
    --color-success: #10B981;
    --color-success-hover: #059669;
    --color-success-light: #D1FAE5;
    --color-danger: #EF4444;
    --color-danger-hover: #DC2626;
    --color-danger-light: #FEE2E2;
    --color-warning: #F59E0B;
    --color-warning-hover: #D97706;
    --color-warning-light: #FEF3C7;
    --color-info: #3B82F6;
    --color-info-hover: #2563EB;
    --color-info-light: #DBEAFE;

    --color-bg-base: #FFFBEB;
    --color-bg-subtle: #FEF3C7;
    --color-bg-muted: #FDE68A;
    --color-surface: #FFFFFF;
    --color-surface-raised: #FFFBEB;

    --color-border: #FDE047;
    --color-border-strong: #FACC15;

    --color-text-base: #78350F;
    --color-text-muted: #92400E;
    --color-text-subtle: #B45309;

    --navbar-bg: linear-gradient(135deg, #F59E0B 0%, #FB923C 50%, #FBBF24 100%);
    --navbar-text: #FFFFFF;
    --navbar-text-muted: rgba(255, 255, 255, 0.9);
}

/* Alucard Theme - https://draculatheme.com */
[data-theme="alucard"] {
    --color-primary: #644AC9;
    --color-primary-hover: #5239B0;
    --color-primary-light: #E0DAF6;
    --color-accent: #A34D14;
    --color-accent-hover: #874010;
    --color-accent-light: #F0E1D4;
    --color-success: #14710A;
    --color-success-hover: #0F5A07;
    --color-success-light: #D5E6D2;
    --color-danger: #CB3A2A;
    --color-danger-hover: #B02E20;
    --color-danger-light: #F4DAD6;
    --color-warning: #846E15;
    --color-warning-hover: #6B5910;
    --color-warning-light: #EAE5CE;
    --color-info: #036A96;
    --color-info-hover: #02597D;
    --color-info-light: #D2E4EC;

    --color-on-warning: #fff;

    --color-bg-base: #FFFBEB;
    --color-bg-subtle: #ECE9DF;
    --color-bg-muted: #DEDCCF;
    --color-surface: #EFEDDC;
    --color-surface-raised: #EFEDDC;

    --color-border: #CFCFDE;
    --color-border-strong: #6C664B;

    --color-text-base: #1F1F1F;
    --color-text-muted: #6C664B;
    --color-text-subtle: #6C664B;

    --navbar-bg: linear-gradient(135deg, #6A5AA8 0%, #8A4F77 100%);
    --navbar-text: #ffffff;
    --navbar-text-muted: rgba(255, 255, 255, 0.85);
}

/* Catppuccin Latte - https://github.com/catppuccin/catppuccin */
[data-theme="latte"] {
    --color-primary: #8839ef;
    --color-primary-hover: #7430cb;
    --color-primary-light: #ede1fd;
    --color-accent: #ea76cb;
    --color-accent-hover: #ce68b3;
    --color-accent-light: #fbe4f5;
    --color-success: #40a02b;
    --color-success-hover: #368825;
    --color-success-light: #dcefd5;
    --color-danger: #d20f39;
    --color-danger-hover: #b30d30;
    --color-danger-light: #f7d6dd;
    --color-warning: #df8e1d;
    --color-warning-hover: #be7919;
    --color-warning-light: #f8ecd3;
    --color-info: #1e66f5;
    --color-info-hover: #1a57d0;
    --color-info-light: #d7e2fd;

    --color-on-success: #1a1a1a;

    --color-bg-base: #e6e9ef;
    --color-bg-subtle: #dce0e8;
    --color-bg-muted: #ccd0da;
    --color-surface: #eff1f5;
    --color-surface-raised: #eff1f5;

    --color-border: #ccd0da;
    --color-border-strong: #acb0be;

    --color-text-base: #4c4f69;
    --color-text-muted: #6c6f85;
    --color-text-subtle: #8c8fa1;

    --navbar-bg: linear-gradient(135deg, #7b47d0 0%, #4257c2 100%);
    --navbar-text: #ffffff;
    --navbar-text-muted: rgba(255, 255, 255, 0.85);
}

/* Ember Light Theme - https://github.com/ember-theme/ember */
[data-theme="ember-light"] {
    --color-primary: #B84C30;
    --color-primary-hover: #993F28;
    --color-primary-light: #F1DDD5;
    --color-accent: #946030;
    --color-accent-hover: #7B5028;
    --color-accent-light: #ECE0D1;
    --color-success: #4A6830;
    --color-success-hover: #3D5628;
    --color-success-light: #DDE5D3;
    --color-danger: #905050;
    --color-danger-hover: #784242;
    --color-danger-light: #ECDCDC;
    --color-warning: #7A6820;
    --color-warning-hover: #65561B;
    --color-warning-light: #EBE5D0;
    --color-info: #3A6080;
    --color-info-hover: #30506A;
    --color-info-light: #D8E0E8;

    --color-on-warning: #fff;

    --color-bg-base: #E6DAC4;
    --color-bg-subtle: #DCCFB6;
    --color-bg-muted: #CEBF9F;
    --color-surface: #F2EAD9;
    --color-surface-raised: #F2EAD9;

    --color-border: #CABD9C;
    --color-border-strong: #A89C7A;

    --color-text-base: #282418;
    --color-text-muted: #6C664B;
    --color-text-subtle: #8A8264;

    --navbar-bg: linear-gradient(135deg, #B84C30 0%, #A5562C 50%, #946030 100%);
    --navbar-text: #FFFFFF;
    --navbar-text-muted: rgba(255, 255, 255, 0.85);
}

/* Rosé Pine Dawn Theme - https://rosepinetheme.com */
[data-theme="rose-pine-dawn"] {
    --color-primary: #907aa9;
    --color-primary-hover: #7d6795;
    --color-primary-light: #ece5f0;
    --color-accent: #d7827e;
    --color-accent-hover: #c66f6b;
    --color-accent-light: #f7e6e4;
    --color-success: #286983;
    --color-success-hover: #20586e;
    --color-success-light: #d6e4e9;
    --color-danger: #b4637a;
    --color-danger-hover: #9d5269;
    --color-danger-light: #f1dde2;
    --color-warning: #ea9d34;
    --color-warning-hover: #d18a26;
    --color-warning-light: #fbedd4;
    --color-info: #56949f;
    --color-info-hover: #487e88;
    --color-info-light: #ddeaec;

    --color-on-primary: #191724;
    --color-on-info: #191724;

    --color-bg-base: #faf4ed;
    --color-bg-subtle: #f2e9e1;
    --color-bg-muted: #e9ded3;
    --color-surface: #fffaf3;
    --color-surface-raised: #fffaf3;

    --color-border: #dfdad9;
    --color-border-strong: #cecacd;

    --color-text-base: #575279;
    --color-text-muted: #797593;
    --color-text-subtle: #9893a5;

    --navbar-bg: linear-gradient(135deg, #907aa9 0%, #d7827e 100%);
    --navbar-text: #ffffff;
    --navbar-text-muted: rgba(255, 255, 255, 0.85);
}

/* ==========================================================================
   Global Styles
   ========================================================================== */

html {
    background-color: var(--color-bg-base);
    min-height: 100%;
}

body {
    background-color: var(--color-bg-base) !important;
    color: var(--color-text-base) !important;
    transition: background-color var(--transition-slow), color var(--transition-slow);
    min-height: 100vh;
}

/* Ensure containers inherit theme background */
.container,
.container-fluid {
    background-color: transparent;
}

/* ==========================================================================
   Bootstrap Component Overrides
   ========================================================================== */

/* Force Bootstrap components to use our theme variables */
.nav-link,
.dropdown-item {
    -webkit-user-select: none;
    user-select: none;
}

.card {
    background-color: var(--color-surface) !important;
    border: 1px solid var(--color-border) !important;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    color: var(--color-text-base) !important;
    transition: all var(--transition-base);
}

.card .card-body {
    padding: var(--spacing-xl);
}

.card-header {
    background-color: var(--color-bg-subtle) !important;
    border-color: var(--color-border) !important;
    color: var(--color-text-base) !important;
}

.card-footer {
    background-color: var(--color-bg-subtle) !important;
    border-color: var(--color-border) !important;
}

.modal-content {
    background-color: var(--color-surface) !important;
    border-color: var(--color-border) !important;
}

.modal-header,
.modal-footer {
    border-color: var(--color-border) !important;
    background-color: var(--color-surface-raised) !important;
}

.list-group-item {
    background-color: var(--color-surface) !important;
    border-color: var(--color-border) !important;
    color: var(--color-text-base) !important;
}

.list-group-item:hover {
    background-color: var(--color-bg-subtle) !important;
}

.accordion-item {
    background-color: var(--color-surface) !important;
    border-color: var(--color-border) !important;
}

.accordion-button {
    background-color: var(--color-bg-subtle) !important;
    color: var(--color-text-base) !important;
}

.accordion-button:not(.collapsed) {
    background-color: var(--color-bg-muted) !important;
    color: var(--color-text-base) !important;
}

.offcanvas {
    background-color: var(--color-surface) !important;
}

.offcanvas-header,
.offcanvas-body {
    color: var(--color-text-base) !important;
}

.toast {
    background-color: var(--color-surface) !important;
    border-color: var(--color-border) !important;
}

.toast-header {
    background-color: var(--color-bg-subtle) !important;
    border-color: var(--color-border) !important;
    color: var(--color-text-base) !important;
}

.toast-body {
    color: var(--color-text-base) !important;
}

.popover {
    background-color: var(--color-surface) !important;
    border-color: var(--color-border) !important;
}

.popover-header {
    background-color: var(--color-bg-subtle) !important;
    border-color: var(--color-border) !important;
    color: var(--color-text-base) !important;
}

.popover-body {
    color: var(--color-text-base) !important;
}

.tooltip-inner {
    background-color: var(--color-bg-muted) !important;
    color: var(--color-text-base) !important;
}

.breadcrumb {
    background-color: var(--color-bg-subtle) !important;
}

.breadcrumb-item a {
    color: var(--color-primary) !important;
}

.breadcrumb-item.active {
    color: var(--color-text-muted) !important;
}

.pagination {
    --bs-pagination-bg: var(--color-surface);
    --bs-pagination-border-color: var(--color-border);
    --bs-pagination-hover-bg: var(--color-bg-subtle);
    --bs-pagination-hover-border-color: var(--color-border);
    --bs-pagination-focus-bg: var(--color-bg-subtle);
    --bs-pagination-disabled-bg: var(--color-bg-muted);
    --bs-pagination-disabled-border-color: var(--color-border);
}

.page-link {
    color: var(--color-text-base) !important;
}

/* ==========================================================================
   Navbar Styles
   ========================================================================== */

.navbar-sunshine {
    background: var(--navbar-bg) !important;
    box-shadow: var(--shadow-md);
    border: none;
    transition: all var(--transition-base);
}

.navbar-sunshine .navbar-brand {
    transition: transform var(--transition-fast);
}

.navbar-sunshine .navbar-brand:hover {
    transform: scale(1.05);
}

.navbar-sunshine .nav-link {
    color: var(--navbar-text-muted) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    min-height: calc(1.5em + 1rem);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navbar-sunshine .nav-link:hover {
    color: var(--navbar-text) !important;
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-1px);
}

.navbar-sunshine .nav-link.active {
    color: var(--navbar-text) !important;
    background-color: rgba(255, 255, 255, 0.15);
    font-weight: 600;
}

.navbar-sunshine .nav-link.dropdown-toggle.show {
    color: var(--navbar-text) !important;
    background-color: rgba(255, 255, 255, 0.15);
}

.navbar-sunshine .navbar-toggler {
    color: var(--navbar-text) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
}

.navbar-sunshine .navbar-toggler:focus {
    box-shadow: 0 0 0 0.25rem rgba(255, 255, 255, 0.15);
}

/* ==========================================================================
   Typography
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    letter-spacing: -0.025em;
    color: var(--color-text-base);
}

h1 {
    font-size: 2.25rem;
    line-height: 2.5rem;
    margin-bottom: var(--spacing-lg);
}

h2 {
    font-size: 1.875rem;
    line-height: 2.25rem;
    margin-bottom: var(--spacing-md);
}

h3 {
    font-size: 1.5rem;
    line-height: 2rem;
    margin-bottom: var(--spacing-md);
}

p {
    line-height: 1.75;
    color: var(--color-text-muted);
}

/* ==========================================================================
   Card Styles
   ========================================================================== */

.card-sunshine {
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-base);
    overflow: hidden;
}

.card-sunshine:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.card-sunshine .card-body {
    padding: var(--spacing-xl);
}

.card-sunshine .card-header {
    background-color: var(--color-bg-subtle);
    border-bottom: 1px solid var(--color-border);
    padding: var(--spacing-lg) var(--spacing-xl);
    font-weight: 600;
}

/* ==========================================================================
   Alert Styles
   ========================================================================== */

.alert {
    border-radius: var(--radius-lg);
    border: 1px solid;
    padding: var(--spacing-lg);
    /* Alerts are containers; keep them as block so their children stack naturally. */
    display: block;
}

/* Use this helper when an alert needs icon + content aligned horizontally. */
.alert-inline {
    display: flex;
    gap: var(--spacing-md);
    align-items: flex-start;
}

.alert-danger {
    background-color: var(--color-danger-light);
    border-color: var(--color-danger);
    color: var(--color-danger);
}

.alert-warning {
    background-color: var(--color-warning-light);
    border-color: var(--color-warning);
    color: var(--color-warning);
}

.alert-success {
    background-color: var(--color-success-light);
    border-color: var(--color-success);
    color: var(--color-success);
}

.alert-info {
    background-color: var(--color-info-light);
    border-color: var(--color-info);
    color: var(--color-info);
}

/* Apply readable alert colors to all dark themes */
[data-bs-theme="dark"] .alert-danger,
[data-bs-theme="dark"] .alert-warning,
[data-bs-theme="dark"] .alert-success,
[data-bs-theme="dark"] .alert-info {
    color: var(--color-text-base);
}

/* ==========================================================================
   Button Styles
   ========================================================================== */

.btn {
    font-weight: 600;
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-md);
    border: none;
    transition: all var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: var(--shadow-sm);
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn:active {
    transform: translateY(0);
    box-shadow: var(--shadow-sm);
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

.btn-primary {
    --bs-btn-active-bg: var(--color-primary-hover);
    --bs-btn-active-border-color: var(--color-primary-hover);
    background-color: var(--color-primary);
    color: var(--color-on-primary);
}

.btn-primary:hover {
    background-color: var(--color-primary-hover);
    color: var(--color-on-primary);
}

.btn-success {
    background-color: var(--color-success);
    color: var(--color-on-success);
}

.btn-success:hover {
    background-color: var(--color-success-hover);
    color: var(--color-on-success);
}

.btn-danger {
    background-color: var(--color-danger);
    color: var(--color-on-danger);
}

.btn-danger:hover {
    background-color: var(--color-danger-hover);
    color: var(--color-on-danger);
}

.btn-warning {
    background-color: var(--color-warning);
    color: var(--color-on-warning);
}

.btn-warning:hover {
    background-color: var(--color-warning-hover);
    color: var(--color-on-warning);
}

.btn-info {
    background-color: var(--color-info);
    color: var(--color-on-info);
}

.btn-info:hover {
    background-color: var(--color-info-hover);
    color: var(--color-on-info);
}

.btn-secondary {
    background-color: var(--color-bg-muted);
    color: var(--color-text-base);
}

.btn-secondary:hover {
    background-color: var(--color-border-strong);
    color: var(--color-text-base);
}

.btn-outline-primary {
    --bs-btn-color: var(--color-primary);
    --bs-btn-border-color: var(--color-primary);
    --bs-btn-hover-color: white;
    --bs-btn-hover-bg: var(--color-primary);
    --bs-btn-hover-border-color: var(--color-primary);
    --bs-btn-active-color: white;
    --bs-btn-active-bg: var(--color-primary);
    --bs-btn-active-border-color: var(--color-primary);
    border: 1px solid var(--color-primary);
}

.btn-outline-secondary {
    --bs-btn-color: var(--color-text-muted);
    --bs-btn-border-color: var(--color-border);
    --bs-btn-hover-color: var(--color-text-base);
    --bs-btn-hover-bg: var(--color-bg-muted);
    --bs-btn-hover-border-color: var(--color-border-strong);
    --bs-btn-active-color: var(--color-text-base);
    --bs-btn-active-bg: var(--color-bg-muted);
    --bs-btn-active-border-color: var(--color-border-strong);
    border: 1px solid var(--color-border);
}

/* Align SVG icons inside buttons. */
.btn .icon,
.btn svg {
    vertical-align: text-bottom;
}

/* ==========================================================================
   Badge Styles
   ========================================================================== */

.badge.bg-primary {
    background-color: var(--color-primary) !important;
    color: var(--color-on-primary) !important;
}

.badge.bg-secondary {
    background-color: var(--color-bg-muted) !important;
    color: var(--color-text-base) !important;
}

/* ==========================================================================
   Toolbar Styles
   ========================================================================== */

.toolbar {
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: var(--spacing-md);
}

.apps-toolbar .input-group {
    width: 14rem;
}

.config-search {
    flex: 0 1 28rem;
}

/* ==========================================================================
   Form Styles
   ========================================================================== */

.form-control,
.form-select {
    background-color: var(--color-bg-base);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 0.625rem 0.875rem;
    color: var(--color-text-base);
    transition: all var(--transition-fast);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-light);
    background-color: var(--color-bg-base);
    color: var(--color-text-base);
}

.form-control::placeholder {
    color: var(--color-text-subtle);
    opacity: 0.7;
}

.input-group-text {
    background-color: var(--color-bg-base);
    border: 1px solid var(--color-border);
    color: var(--color-text-muted);
}

.form-label {
    font-weight: 600;
    color: var(--color-text-base);
    margin-bottom: var(--spacing-sm);
}

.form-check-input {
    border: 2px solid var(--color-border-strong);
    transition: all var(--transition-fast);
}

.form-check-input:checked {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
}

.form-check-input:focus {
    box-shadow: 0 0 0 3px var(--color-primary-light);
}

/* ==========================================================================
   Table Styles
   ========================================================================== */

.table {
    color: var(--color-text-base);
}

.table thead th {
    background-color: var(--color-bg-subtle);
    border-bottom: 2px solid var(--color-border-strong);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    color: var(--color-text-muted);
    padding: var(--spacing-md) var(--spacing-lg);
}

.table tbody tr {
    border-bottom: 1px solid var(--color-border);
    transition: background-color var(--transition-fast);
}

.table tbody tr:hover {
    background-color: var(--color-bg-subtle);
}

.table tbody td {
    padding: var(--spacing-md) var(--spacing-lg);
    vertical-align: middle;
}

/* ==========================================================================
   Virtual Gamepad and Driver License
   ========================================================================== */

.virtual-gamepad-card {
    overflow: hidden;
}

.virtual-gamepad-hero {
    display: flex;
    align-items: flex-start;
    gap: var(--spacing-md);
}

.virtual-gamepad-heading-icon {
    align-items: center;
    background-color: var(--color-primary-light);
    border: 1px solid var(--color-primary);
    border-radius: var(--radius-lg);
    color: var(--color-primary);
    display: flex;
    flex: 0 0 auto;
    height: 3rem;
    justify-content: center;
    width: 3rem;
}

.virtual-gamepad-feature-grid {
    display: grid;
    gap: var(--spacing-md);
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: var(--spacing-xl);
}

.virtual-gamepad-feature {
    align-items: flex-start;
    background-color: var(--color-bg-subtle);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    display: flex;
    gap: var(--spacing-md);
    padding: var(--spacing-lg);
}

.virtual-gamepad-feature-icon {
    align-items: center;
    background-color: var(--color-primary-light);
    border-radius: var(--radius-md);
    color: var(--color-primary);
    display: flex;
    flex: 0 0 auto;
    height: 2.25rem;
    justify-content: center;
    width: 2.25rem;
}

.virtual-gamepad-feature h3 {
    font-size: 1rem;
    letter-spacing: normal;
    line-height: 1.4;
    margin: 0 0 var(--spacing-xs);
}

.virtual-gamepad-feature p {
    font-size: 0.875rem;
    line-height: 1.55;
    margin: 0;
}

.virtual-gamepad-section,
.virtualhid-license-section {
    border-top: 1px solid var(--color-border);
    margin-top: var(--spacing-xl);
    padding-top: var(--spacing-xl);
}

.virtual-gamepad-section-heading,
.virtualhid-license-heading {
    align-items: flex-start;
    display: flex;
    gap: var(--spacing-lg);
    justify-content: space-between;
    margin-bottom: var(--spacing-lg);
}

.driver-refresh-button,
.driver-download-button {
    flex: 0 0 auto;
    font-size: 0.875rem;
    padding: 0.45rem 0.75rem;
    white-space: nowrap;
}

.driver-table-shell {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
}

.driver-table-shell .table thead th:first-child {
    border-top-left-radius: var(--radius-lg);
}

.driver-table-shell .table thead th:last-child {
    border-top-right-radius: var(--radius-lg);
}

.driver-table-shell .table tbody tr:last-child {
    border-bottom: none;
}

.driver-table-shell .table tbody th {
    padding: var(--spacing-md) var(--spacing-lg);
    white-space: nowrap;
}

.driver-release-state {
    align-items: center;
    display: flex;
    font-weight: 600;
    gap: var(--spacing-sm);
    white-space: nowrap;
}

.driver-release-current {
    color: var(--color-success);
}

.driver-release-outdated {
    color: var(--color-warning);
}

.driver-release-neutral {
    color: var(--color-text-muted);
}

.driver-release-detail {
    color: var(--color-text-muted);
    display: block;
    margin-top: 0.15rem;
    white-space: nowrap;
}

.driver-download-column {
    text-align: right;
}

.driver-release-spinning {
    animation: driver-release-spin 0.9s linear infinite;
}

@keyframes driver-release-spin {
    to {
        transform: rotate(360deg);
    }
}

.virtualhid-license-heading .badge {
    flex: 0 0 auto;
    font-size: 0.8rem;
    padding: 0.5rem 0.75rem;
}

.virtualhid-license-stats {
    display: grid;
    gap: var(--spacing-sm);
    grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
    margin: 0;
}

.virtualhid-license-stat {
    background-color: var(--color-bg-subtle);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    margin: 0;
    min-width: 0;
    padding: var(--spacing-md);
}

.virtualhid-license-stat dt {
    color: var(--color-text-muted);
    font-size: 0.75rem;
    letter-spacing: 0.04em;
    margin-bottom: var(--spacing-xs);
    text-transform: uppercase;
}

.virtualhid-license-stat dd {
    color: var(--color-text-base);
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    overflow-wrap: anywhere;
}

.virtualhid-license-message {
    margin: var(--spacing-md) 0 0;
}

.virtualhid-license-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
    justify-content: flex-end;
    margin-top: var(--spacing-lg);
}

.virtualhid-license-activation,
.virtualhid-license-active {
    background-color: var(--color-bg-subtle);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    margin-top: var(--spacing-md);
    padding: var(--spacing-lg);
}

.virtualhid-license-input .form-control {
    border-bottom-right-radius: 0;
    border-top-right-radius: 0;
}

.virtualhid-license-input .btn {
    border-bottom-left-radius: 0;
    border-top-left-radius: 0;
}

.virtualhid-license-active {
    align-items: flex-start;
    border-color: var(--color-success);
    color: var(--color-success);
    display: flex;
    gap: var(--spacing-md);
}

.virtualhid-license-active svg {
    flex: 0 0 auto;
}

.virtualhid-license-active p {
    font-size: 0.875rem;
    line-height: 1.5;
    margin-top: var(--spacing-xs);
}

@media (max-width: 991.98px) {
    .virtual-gamepad-feature-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 575.98px) {
    .virtual-gamepad-section-heading,
    .virtualhid-license-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .driver-refresh-button {
        justify-content: center;
        width: 100%;
    }

    .virtualhid-license-toolbar {
        justify-content: stretch;
    }

    .virtualhid-license-toolbar .btn {
        justify-content: center;
        width: 100%;
    }

    .virtualhid-license-input {
        display: block;
    }

    .virtualhid-license-input .form-control,
    .virtualhid-license-input .btn {
        border-radius: var(--radius-md);
        width: 100%;
    }

    .virtualhid-license-input .btn {
        justify-content: center;
        margin-top: var(--spacing-sm);
    }
}

/* ==========================================================================
   Navigation Tabs
   ========================================================================== */

.nav-tabs {
    border-bottom: 2px solid var(--color-border);
    gap: 0.5rem;
}

.nav-tabs .nav-link {
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--color-text-muted);
    font-weight: 600;
    padding: var(--spacing-md) var(--spacing-lg);
    transition: all var(--transition-fast);
    border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.nav-tabs .nav-link:hover {
    color: var(--color-text-base);
    background-color: var(--color-bg-subtle);
    border-bottom-color: var(--color-border-strong);
}

.nav-tabs .nav-link.active {
    color: var(--color-primary);
    background-color: transparent;
    border-bottom-color: var(--color-primary);
}

/* ==========================================================================
   Container & Layout
   ========================================================================== */

#content {
    padding-top: var(--spacing-xl);
    padding-bottom: var(--spacing-3xl);
}

.config-layout {
    display: flex;
    align-items: flex-start;
    gap: var(--spacing-lg);
}

.config-nav {
    flex: 0 0 15rem;
    position: sticky;
    top: var(--spacing-lg);
}

.config-nav-list {
    flex-direction: column;
    gap: var(--spacing-xs);
}

.config-nav-list .nav-link {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-md);
    color: var(--color-text-muted);
    font-weight: 600;
    transition: all var(--transition-fast);
}

.config-nav-list .nav-link:hover {
    color: var(--color-text-base);
    background-color: var(--color-bg-subtle);
}

.config-nav-list .nav-link.active {
    color: var(--color-on-primary);
    background-color: var(--color-primary);
}

.config-nav-heading {
    margin: var(--spacing-md) var(--spacing-md) var(--spacing-xs);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-subtle);
}

.config-content {
    flex: 1 1 auto;
    min-width: 0;
}

.config-actions {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-lg);
    padding-top: var(--spacing-lg);
    border-top: 1px solid var(--color-border);
}

.config-actions .btn {
    width: 100%;
    justify-content: center;
}

.config-page {
    padding: var(--spacing-xl);
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
}

@media (max-width: 768px) {
    .config-layout {
        flex-direction: column;
    }

    .config-nav {
        position: static;
        flex-basis: auto;
        width: 100%;
    }

    .config-nav-list {
        flex-direction: row;
        flex-wrap: wrap;
    }
}

/* ==========================================================================
   Utility Classes
   ========================================================================== */

.section-spacing {
    margin-top: var(--spacing-xl);
    margin-bottom: var(--spacing-xl);
}

.icon {
    width: 1.25rem;
    height: 1.25rem;
    stroke-width: 2;
}

.icon-lg {
    width: 2rem;
    height: 2rem;
}

/* ==========================================================================
   Specific Component Styles
   ========================================================================== */

/* Troubleshooting Logs */
.troubleshooting-logs {
    white-space: pre;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code', 'Courier New', monospace;
    overflow: auto;
    max-height: 500px;
    min-height: 500px;
    font-size: 0.875rem;
    position: relative;
    background-color: var(--color-bg-muted);
    padding: var(--spacing-lg);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
}

.troubleshooting-logs pre {
    margin: 0;
}

/* Log level highlighting */
.log-line-info {
    color: var(--color-text-base);
}

.log-line-debug {
    color: var(--color-text-muted);
}

.log-line-warning {
    color: #F59E0B;
    font-weight: 500;
}

.log-line-error,
.log-line-fatal {
    color: #EF4444;
    font-weight: 600;
}

/* Log line colors for dark themes */
[data-bs-theme="dark"] .log-line-info {
    color: var(--color-text-base);
}

[data-bs-theme="dark"] .log-line-debug {
    color: var(--color-text-muted);
}

[data-bs-theme="dark"] .log-line-warning {
    color: #FBBF24;
}

[data-bs-theme="dark"] .log-line-error,
[data-bs-theme="dark"] .log-line-fatal {
    color: #F87171;
}

/* Highlight for the currently selected error/warning entry */
/* Warning level - yellow/amber alert style */
.log-line-warning.log-entry-selected {
    background-color: rgba(245, 158, 11, 0.2);
    border-left: 4px solid #F59E0B;
    padding-left: 0.75rem;
    margin-left: -0.75rem;
    box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.3);
}

/* Error/Fatal level - red alert style */
.log-line-error.log-entry-selected,
.log-line-fatal.log-entry-selected {
    background-color: rgba(239, 68, 68, 0.2);
    border-left: 4px solid #EF4444;
    padding-left: 0.75rem;
    margin-left: -0.75rem;
    box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.3);
}

/* Dark theme variants */
[data-bs-theme="dark"] .log-line-warning.log-entry-selected {
    background-color: rgba(251, 191, 36, 0.25);
    border-left-color: #FBBF24;
    box-shadow: 0 0 0 1px rgba(251, 191, 36, 0.4);
}

[data-bs-theme="dark"] .log-line-error.log-entry-selected,
[data-bs-theme="dark"] .log-line-fatal.log-entry-selected {
    background-color: rgba(248, 113, 113, 0.25);
    border-left-color: #F87171;
    box-shadow: 0 0 0 1px rgba(248, 113, 113, 0.4);
}

/* Overlay wrapper keeps controls out of normal flow so log text starts at the top. */
.log-nav-overlay {
    position: sticky;
    top: 0;
    z-index: 10;

    /* Don't push the log text down */
    height: 0;

    /* Let log text remain selectable/clickable under the overlay */
    pointer-events: none;
}

.log-nav-overlay .log-nav-controls {
    pointer-events: auto;

    /* Overlay the buttons in the top-right corner */
    position: absolute;
    top: 0;
    right: 0;

    display: inline-flex;
    gap: var(--spacing-xs);
    background: transparent;
}

.log-nav-btn {
    padding: var(--spacing-sm) var(--spacing-md);
    cursor: pointer;
    color: var(--color-text-muted);
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    font-size: 0.875rem;
    white-space: nowrap;
    font-weight: 500;
}

.log-nav-btn svg {
    flex-shrink: 0;
}

.log-nav-btn:hover:not(:disabled) {
    color: var(--color-text-base);
    background-color: var(--color-bg-subtle);
    transform: scale(1.05);
}

.log-nav-btn:active:not(:disabled) {
    transform: scale(0.95);
}

.log-nav-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.copy-icon {
    position: absolute;
    top: var(--spacing-md);
    right: var(--spacing-md);
    padding: var(--spacing-sm);
    cursor: pointer;
    color: var(--color-text-muted);
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.copy-icon:hover {
    color: var(--color-text-base);
    background-color: var(--color-bg-subtle);
    transform: scale(1.05);
}

.copy-icon:active {
    transform: scale(0.95);
}

/* Cover Finder */
.cover-finder .cover-results {
    max-height: 400px;
    overflow-x: hidden;
    overflow-y: auto;
    padding: var(--spacing-md);
    background-color: var(--color-bg-subtle);
    border-radius: var(--radius-md);
}

.cover-finder .cover-results.busy * {
    cursor: wait !important;
    pointer-events: none;
}

.cover-container {
    padding-top: 133.33%;
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    background-color: var(--color-bg-muted);
}

.cover-container.result {
    cursor: pointer;
    transition: transform var(--transition-fast);
}

.cover-container.result:hover {
    transform: scale(1.02);
}

.cover-container img {
    display: block;
    position: absolute;
    top: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.spinner-border {
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    margin: auto;
}

/* Environment Table */
.env-table td {
    padding: var(--spacing-sm);
    border-bottom: 1px solid var(--color-border);
    vertical-align: top;
}

/* Monospace Text */
.monospace {
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code', 'Courier New', monospace;
    font-size: 0.875rem;
}

/* ==========================================================================
   Markdown Body (for release notes)
   ========================================================================== */

.markdown-body {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--color-text-base);
}

.markdown-body.release-notes {
    width: 100%;
    max-width: 100%;
    column-count: 1 !important;
    display: block !important;
}

.markdown-body h1,
.markdown-body h2,
.markdown-body h3,
.markdown-body h4,
.markdown-body h5,
.markdown-body h6 {
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
    color: var(--color-text-base);
}

.markdown-body h2 {
    font-size: 1.5rem;
    border-bottom: 1px solid var(--color-border);
    padding-bottom: 0.3rem;
}

.markdown-body h3 {
    font-size: 1.25rem;
}

.markdown-body ul,
.markdown-body ol {
    padding-left: 2rem;
    margin-bottom: 1rem;
}

.markdown-body li {
    margin-bottom: 0.25rem;
}

.markdown-body a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.markdown-body a:hover {
    color: var(--color-primary-hover);
    text-decoration: underline;
}

.markdown-body img {
    max-width: 100%;
    height: auto;
    vertical-align: middle;
}

.markdown-body code {
    padding: 0.2em 0.4em;
    margin: 0;
    font-size: 85%;
    background-color: var(--color-bg-muted);
    border-radius: var(--radius-sm);
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code', 'Courier New', monospace;
}

.markdown-body pre {
    padding: var(--spacing-lg);
    overflow: auto;
    font-size: 85%;
    line-height: 1.45;
    background-color: var(--color-bg-muted);
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    border: 1px solid var(--color-border);
}

.markdown-body blockquote {
    padding: 0 var(--spacing-lg);
    color: var(--color-text-muted);
    border-left: 0.25rem solid var(--color-primary);
    margin-bottom: 1rem;
}

.markdown-body table {
    border-spacing: 0;
    border-collapse: collapse;
    margin-bottom: 1rem;
    width: 100%;
}

.markdown-body table th,
.markdown-body table td {
    padding: 6px 13px;
    border: 1px solid var(--color-border);
}

.markdown-body table th {
    background-color: var(--color-bg-subtle);
    font-weight: 600;
}

.markdown-body table tr:nth-child(2n) {
    background-color: rgba(0, 0, 0, 0.02);
}

[data-bs-theme="dark"] .markdown-body table tr:nth-child(2n) {
    background-color: rgba(255, 255, 255, 0.02);
}

.markdown-body hr {
    height: 0.25rem;
    padding: 0;
    margin: 1.5rem 0;
    background-color: var(--color-border);
    border: 0;
}

/* ==========================================================================
   Dropdown Styles
   ========================================================================== */

.dropdown-menu {
    background-color: var(--color-surface) !important;
    border: 1px solid var(--color-border) !important;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: var(--spacing-sm);
}

.dropdown-toggle.show::after {
    transform: rotate(180deg);
}

.dropdown-item {
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-sm);
    color: var(--color-text-base) !important;
    transition: all var(--transition-fast);
}

.dropdown-item:hover {
    background-color: var(--color-bg-muted) !important;
    color: var(--color-text-base) !important;
}

.dropdown-item.active {
    background-color: var(--color-primary-light);
    color: var(--color-primary);
}

[data-bs-theme="dark"] .dropdown-item.active {
    background-color: var(--color-primary);
    color: white;
}

.dropdown-divider {
    border-color: var(--color-border) !important;
}

/* Add spacing between icons and text in dropdown items */
.dropdown-item .icon,
.dropdown-item svg {
    margin-right: 0.5rem;
}

.theme-menu {
    grid-template-columns: 1fr 1fr;
    gap: 0 var(--spacing-sm);
    min-width: 22rem;
}

.dropdown-menu.theme-menu.show {
    display: grid;
}

.theme-menu-full {
    grid-column: 1 / -1;
    display: flex;
    gap: var(--spacing-sm);
}

.theme-menu-full .dropdown-item {
    flex: 1;
}

.theme-menu .dropdown-header {
    color: var(--color-text-muted);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: var(--spacing-sm) var(--spacing-md) var(--spacing-xs);
}

@media (max-width: 480px) {
    .theme-menu {
        grid-template-columns: 1fr;
        min-width: 12rem;
    }
}

/* ==========================================================================
   Responsive Adjustments
   ========================================================================== */

@media (max-width: 768px) {
    h1 {
        font-size: 1.875rem;
        line-height: 2.25rem;
    }

    h2 {
        font-size: 1.5rem;
        line-height: 2rem;
    }

    .card-sunshine .card-body,
    .card .card-body {
        padding: var(--spacing-lg);
    }

    .btn {
        padding: 0.5rem 1rem;
        font-size: 0.875rem;
    }
}

/* ==========================================================================
   Config Search Highlighting
   ========================================================================== */

.config-search-highlight {
    animation: highlightPulse 5s ease-in-out;
    border-radius: var(--radius-md);
}

@keyframes highlightPulse {
    0%, 100% {
        background-color: transparent;
        box-shadow: none;
    }
    20%, 80% {
        background-color: color-mix(in srgb, var(--color-warning) 35%, transparent);
        box-shadow: 0 0 0 4px color-mix(in srgb, var(--color-warning) 55%, transparent);
    }
}

/* ==========================================================================
   App Cards
   ========================================================================== */

.app-card {
    transition: all var(--transition-base);
    overflow: hidden;
}

.app-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.app-card .card-body {
    padding: var(--spacing-md);
}

.app-poster-container {
    position: relative;
    width: 100%;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: var(--color-bg-muted);
}

.app-poster {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.app-poster-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--color-primary-light), var(--color-accent-light));
}

[data-bs-theme="dark"] .app-poster-placeholder {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.2), rgba(245, 158, 11, 0.2));
}

.app-initial {
    font-size: 3rem;
    font-weight: 700;
    color: var(--color-primary);
    opacity: 0.5;
}

.app-poster-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
    background: linear-gradient(to top,
        color-mix(in srgb, var(--color-primary) 22%, rgba(0, 0, 0, 0.9)) 0%,
        color-mix(in srgb, var(--color-primary) 12%, rgba(0, 0, 0, 0.68)) 55%,
        transparent 100%);
    color: #fff;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-base);
}

.app-card:hover .app-poster-overlay,
.app-card:focus-within .app-poster-overlay {
    opacity: 1;
    pointer-events: auto;
}

.app-overlay-row {
    display: flex;
    align-items: center;
    font-size: 0.8rem;
    line-height: 1.3;
}

.app-poster-overlay .icon {
    flex-shrink: 0;
}

.app-poster-overlay .app-detail-text {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-overlay-badges {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
}

.app-flag-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-xs);
    min-height: 1.5rem;
    font-size: 0.65rem;
    font-weight: 600;
    padding: 0.2em 0.5em;
    border-radius: var(--radius-sm);
    background: var(--color-primary);
    color: var(--color-on-primary);
    text-transform: uppercase;
    letter-spacing: 0.02em;
}


/* ==========================================================================
   Featured Apps Page Styles
   ========================================================================== */

.featured-app-card {
    transition: transform var(--transition-base), box-shadow var(--transition-base);
    overflow: hidden;
}

.featured-app-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.featured-app-card .card-body {
    overflow: hidden;
}

.featured-app-icon {
    width: 64px;
    height: 64px;
    min-width: 64px;
    min-height: 64px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: var(--radius-md);
}

.featured-app-icon img {
    max-width: 64px !important;
    max-height: 64px !important;
    width: auto;
    height: auto;
    object-fit: contain;
}

.featured-app-icon-placeholder {
    width: 64px;
    height: 64px;
    background: var(--color-bg-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
}

.featured-app-card .card-title {
    font-weight: 600;
    color: var(--color-text-base);
}

.featured-app-card .text-muted.small {
    line-height: 1.4;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.min-w-0 {
    min-width: 0;
}

/* GitHub stats */
.github-stats {
    font-size: 0.875rem;
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-md);
}

.github-stats span {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    white-space: nowrap;
}

.github-stats svg {
    flex-shrink: 0;
}

/* Screenshot gallery */
.screenshots-container {
    overflow: hidden;
    width: 100%;
}

.screenshots-scroll {
    display: flex;
    gap: var(--spacing-sm);
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
    padding-bottom: var(--spacing-xs);
}

.screenshots-scroll::-webkit-scrollbar {
    height: 6px;
}

.screenshots-scroll::-webkit-scrollbar-track {
    background: var(--color-bg-muted);
    border-radius: 3px;
}

.screenshots-scroll::-webkit-scrollbar-thumb {
    background: var(--color-border-strong);
    border-radius: 3px;
}

.screenshots-scroll::-webkit-scrollbar-thumb:hover {
    background: var(--color-text-subtle);
}

.screenshot-thumbnail {
    height: 120px !important;
    width: auto;
    max-width: 200px !important;
    min-width: 100px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: transform var(--transition-base), box-shadow var(--transition-base);
    flex-shrink: 0;
    object-fit: cover;
    border: 1px solid var(--color-border);
}

.screenshot-thumbnail:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-md);
}

/* Screenshot modal */
.screenshot-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1060;
    cursor: pointer;
    animation: fadeIn var(--transition-fast);
    user-select: none;
    -webkit-user-select: none;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.screenshot-modal-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: zoomIn var(--transition-base);
}

@keyframes zoomIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.screenshot-modal-content img {
    max-width: calc(100vw - 160px);
    max-height: calc(100vh - 100px);
    width: auto;
    height: auto;
    object-fit: contain;
    cursor: default;
    border-radius: var(--radius-md);
}

.screenshot-close {
    position: fixed;
    top: var(--spacing-lg);
    right: var(--spacing-lg);
    z-index: 3;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    padding: var(--spacing-sm);
    transition: background var(--transition-fast), transform var(--transition-fast);
}

.screenshot-close:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: scale(1.1);
}

/* Screenshot navigation buttons */
.screenshot-nav {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: white;
    padding: var(--spacing-lg);
    cursor: pointer;
    border-radius: var(--radius-md);
    transition: background var(--transition-fast), transform var(--transition-fast);
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
}

.screenshot-nav:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: translateY(-50%) scale(1.1);
}

.screenshot-nav:active {
    transform: translateY(-50%) scale(0.95);
}

.screenshot-nav-prev {
    left: var(--spacing-xl);
}

.screenshot-nav-next {
    right: var(--spacing-xl);
}

/* Screenshot counter */
.screenshot-counter {
    position: fixed;
    bottom: var(--spacing-xl);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: var(--spacing-sm) var(--spacing-lg);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    white-space: nowrap;
    z-index: 3;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .screenshot-modal-content img {
        max-width: calc(100vw - 80px);
        max-height: calc(100vh - 80px);
    }

    .screenshot-nav {
        padding: var(--spacing-sm);
    }

    .screenshot-nav-prev {
        left: var(--spacing-sm);
    }

    .screenshot-nav-next {
        right: var(--spacing-sm);
    }

    .screenshot-close {
        top: var(--spacing-sm);
        right: var(--spacing-sm);
    }

    .screenshot-counter {
        bottom: var(--spacing-sm);
    }
}
