* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

* {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.3) rgba(255, 255, 255, 0.1);
}

*::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

*::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

*::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    transition: background-color 0.2s;
}

*::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

*::-webkit-scrollbar-corner {
    background: rgba(255, 255, 255, 0.05);
}

/* Universal custom checkbox styles - applies to all checkboxes */
input[type="checkbox"] {
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    width: 16px !important;
    height: 16px !important;
    border: 2px solid rgba(255, 255, 255, 0.3) !important;
    border-radius: 3px !important;
    background: rgba(255, 255, 255, 0.05) !important;
    cursor: pointer !important;
    position: relative !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    margin: 0 !important;
    flex-shrink: 0 !important;
    outline: none !important;
    vertical-align: middle !important;
}

input[type="checkbox"]:hover {
    border-color: rgba(255, 255, 255, 0.5) !important;
    background: rgba(255, 255, 255, 0.08) !important;
    transform: scale(1.05) !important;
}

input[type="checkbox"]:checked {
    background: rgba(59, 130, 246, 0.3) !important;
    border-color: #3b82f6 !important;
    background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='%233b82f6' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='m13.854 3.646-1.415-1.414L6.5 8.171 3.561 5.232 2.147 6.646l4.353 4.354 7.354-7.354Z'/%3e%3c/svg%3e") !important;
    background-size: 10px !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

input[type="checkbox"]:checked:hover {
    background-color: rgba(59, 130, 246, 0.4) !important;
    border-color: #2563eb !important;
}

input[type="checkbox"]:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2) !important;
}

input[type="checkbox"]:active {
    transform: scale(0.95) !important;
}

input[type="checkbox"]:disabled {
    opacity: 0.5 !important;
    cursor: not-allowed !important;
    transform: none !important;
}

input[type="checkbox"]:disabled:hover {
    transform: none !important;
    border-color: rgba(255, 255, 255, 0.3) !important;
    background: rgba(255, 255, 255, 0.05) !important;
}

/* Indeterminate state (for select all functionality) */
input[type="checkbox"]:indeterminate {
    background: rgba(59, 130, 246, 0.3) !important;
    border-color: #3b82f6 !important;
    background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='%233b82f6' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M4 8h8v1H4z'/%3e%3c/svg%3e") !important;
    background-size: 10px !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

/* Dark theme variant for better contrast */
input[type="checkbox"].dark-theme {
    border-color: rgba(255, 255, 255, 0.4) !important;
    background: rgba(255, 255, 255, 0.08) !important;
}

input[type="checkbox"].dark-theme:hover {
    border-color: rgba(255, 255, 255, 0.6) !important;
    background: rgba(255, 255, 255, 0.12) !important;
}

/* Animation for check state change */
input[type="checkbox"] {
    transition: all 0.15s ease-in-out !important;
}

@keyframes checkboxCheck {
    0% {
        transform: scale(0.8);
        opacity: 0;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

input[type="checkbox"]:checked {
    animation: checkboxCheck 0.2s ease-in-out !important;
}

/* Ensure consistent sizing in different containers */
.file-manager-list input[type="checkbox"],
.window-content input[type="checkbox"],
table input[type="checkbox"],
form input[type="checkbox"] {
    width: 16px !important;
    height: 16px !important;
    min-width: 16px !important;
    min-height: 16px !important;
}

/* Focus ring for accessibility */
input[type="checkbox"]:focus-visible {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3) !important;
    outline: none !important;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    input[type="checkbox"] {
        border-color: rgba(255, 255, 255, 0.8) !important;
    }
    
    input[type="checkbox"]:checked {
        border-color: #ffffff !important;
        background-color: rgba(59, 130, 246, 0.8) !important;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    input[type="checkbox"] {
        transition: none !important;
        animation: none !important;
    }
    
    input[type="checkbox"]:hover {
        transform: none !important;
    }
    
    input[type="checkbox"]:active {
        transform: none !important;
    }
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    overflow: hidden;
    user-select: none;
}

.desktop {
    height: 100vh;
    width: 100vw;
    background: linear-gradient(135deg, #1e293b 0%, #7c3aed 50%, #1e293b 100%);
    position: relative;
    overflow: hidden;
}

.desktop::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle at 1px 1px, rgba(255,255,255,0.05) 1px, transparent 0);
    background-size: 20px 20px;
    pointer-events: none;
}

.topbar {
    height: 48px;
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    position: relative;
    z-index: 1000;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.menu-btn, .settings-btn {
    padding: 8px;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    transition: background-color 0.2s;
}

.menu-btn:hover, .settings-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.logo {
    color: white;
    font-weight: 600;
    font-size: 14px;
}

.time {
    color: rgba(255, 255, 255, 0.7);
    font-size: 12px;
}

.desktop-area {
    height: calc(100vh - 96px);
    position: relative;
}

.app-grid {
    position: absolute;
    top: 24px;
    left: 24px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    z-index: 10;
}

.app-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    color: white;
    text-decoration: none;
}

.app-icon:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.app-icon-bg {
    padding: 12px;
    border-radius: 8px;
    transition: transform 0.2s;
}

.app-icon:hover .app-icon-bg {
    transform: scale(1.1);
}

.app-icon-bg.files { background: #3b82f6; }
.app-icon-bg.images { background: #8b5cf6; }

.app-name {
    font-size: 12px;
    font-weight: 500;
}

.window {
    position: absolute;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
    transition: transform 0.2s, opacity 0.2s;
    min-width: 400px;
    min-height: 300px;
    transition: all 0.2s ease;
}

.window.minimized {
    transform: scale(0);
    opacity: 0;
}

.window-titlebar {
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    cursor: move;
    border-radius: 8px 8px 0 0;
    user-select: none;
}

.window-title {
    color: white;
    font-size: 14px;
    font-weight: 500;
}

.window-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.window-control-btn {
    padding: 4px;
    background: transparent;
    border: none;
    border-radius: 4px;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: all 0.2s;
}

.window-control-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.window-control-btn.close:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.custom-scrollbar {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.3) rgba(255, 255, 255, 0.1);
}

.custom-scrollbar::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.custom-scrollbar::-webkit-scrollbar-corner {
    background: rgba(255, 255, 255, 0.05);
}



.window-content {
    height: calc(100% - 40px);
    overflow: hidden;
    border-radius: 0 0 8px 8px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.3) rgba(255, 255, 255, 0.1);
}

.window-content::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.window-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.window-content::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    transition: background-color 0.2s;
}

.window-content::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* File list specific scrollbar */
.file-list::-webkit-scrollbar {
    width: 6px;
}

.file-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

.file-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

.file-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.window.fullscreen {
    position: fixed !important;
    top: 48px !important;
    left: 0 !important;
    width: 100vw !important;
    height: calc(100vh - 96px) !important;
    z-index: 10000 !important;
    border-radius: 0 !important;
}

.window.fullscreen .window-titlebar {
    border-radius: 0 !important;
}

.window.halfscreen {
    position: fixed !important;
    top: 48px !important;
    width: 50vw !important;
    height: calc(100vh - 96px) !important;
    z-index: 10000 !important;
}

.window.halfscreen.left {
    left: 0 !important;
}

.window.halfscreen.right {
    left: 50vw !important;
}

.sidebar {
    position: fixed;
    top: 48px;
    right: 0;
    width: 320px;
    height: calc(100vh - 96px);
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
    border-left: 1px solid rgba(255, 255, 255, 0.2);
    transform: translateX(100%);
    transition: transform 0.3s ease;
    z-index: 2000;
}

.sidebar.open {
    transform: translateX(0);
}

.sidebar-header {
    height: 48px;
    padding: 0 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-title {
    color: white;
    font-weight: 600;
    font-size: 14px;
}

.sidebar-close {
    padding: 4px;
    background: transparent;
    border: none;
    border-radius: 4px;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: all 0.2s;
}

.sidebar-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.sidebar-content {
    height: calc(100% - 48px);
    padding: 16px;
    display: flex;
    flex-direction: column;
}

.ai-chat {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 16px;
    overflow-y: auto;
}

.ai-welcome {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    line-height: 1.5;
}

.ai-input-form {
    display: flex;
    gap: 8px;
}

.ai-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 8px 12px;
    color: white;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.ai-input:focus {
    border-color: rgba(59, 130, 246, 0.5);
}

.ai-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.mic-btn {
    padding: 8px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    transition: all 0.2s;
}

.mic-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.mic-btn.listening {
    background: #ef4444;
}

.taskbar {
    height: 48px;
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 16px;
    position: relative;
    z-index: 1000;
}

.taskbar-items {
    display: flex;
    gap: 8px;
}

.taskbar-item {
    padding: 4px 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    color: white;
    font-size: 12px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.taskbar-item:hover {
    background: rgba(255, 255, 255, 0.2);
}

.ai-toggle {
    position: fixed;
    top: 50%;
    right: 0;
    width: 24px;
    height: 80px;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-right: none;
    border-radius: 12px 0 0 12px;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: all 0.2s;
    z-index: 1500;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
}

.ai-toggle:hover {
    background: rgba(0, 0, 0, 0.6);
    color: white;
    width: 28px;
}

.ai-toggle.hidden {
    opacity: 0;
    pointer-events: none;
}

.ai-toggle::before {
    content: '';
    width: 3px;
    height: 20px;
    background: currentColor;
    border-radius: 2px;
    opacity: 0.5;
}

.ai-toggle::after {
    content: '';
    width: 3px;
    height: 20px;
    background: currentColor;
    border-radius: 2px;
    opacity: 0.5;
}

/* Add drag handle dots */
.drag-dots {
    display: flex;
    flex-direction: column;
    gap: 2px;
    align-items: center;
}

.drag-dot {
    width: 3px;
    height: 3px;
    background: currentColor;
    border-radius: 50%;
    opacity: 0.6;
}

/* Icons using CSS */
.icon {
    width: 20px;
    height: 20px;
    display: inline-block;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.icon-menu { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='white'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 6h16M4 12h16M4 18h16'/%3E%3C/svg%3E"); }
.icon-settings { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='white'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M10.325 4.317c.426-1.756 2.924-1.756 3.35 0a1.724 1.724 0 002.573 1.066c1.543-.94 3.31.826 2.37 2.37a1.724 1.724 0 001.065 2.572c1.756.426 1.756 2.924 0 3.35a1.724 1.724 0 00-1.066 2.573c.94 1.543-.826 3.31-2.37 2.37a1.724 1.724 0 00-2.572 1.065c-.426 1.756-2.924 1.756-3.35 0a1.724 1.724 0 00-2.573-1.066c-1.543.94-3.31-.826-2.37-2.37a1.724 1.724 0 00-1.065-2.572c-1.756-.426-1.756-2.924 0-3.35a1.724 1.724 0 001.066-2.573c-.94-1.543.826-3.31 2.37-2.37.996.608 2.296.07 2.572-1.065z'/%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M15 12a3 3 0 11-6 0 3 3 0 016 0z'/%3E%3C/svg%3E"); }
.icon-folder { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='white'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M3 7v10a2 2 0 002 2h14a2 2 0 002-2V9a2 2 0 00-2-2h-6l-2-2H5a2 2 0 00-2 2z'/%3E%3C/svg%3E"); }
.icon-image { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='white'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z'/%3E%3C/svg%3E"); }
.icon-minimize { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='rgba(255,255,255,0.7)'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M20 12H4'/%3E%3C/svg%3E"); }
.icon-close { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='rgba(255,255,255,0.7)'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M6 18L18 6M6 6l12 12'/%3E%3C/svg%3E"); }
.icon-mic { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='white'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 11a7 7 0 01-7 7m0 0a7 7 0 01-7-7m7 7v4m0 0H8m4 0h4m-4-8a3 3 0 01-3-3V5a3 3 0 116 0v6a3 3 0 01-3 3z'/%3E%3C/svg%3E"); }
.icon-message { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='white'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M8 12h.01M12 12h.01M16 12h.01M21 12c0 4.418-4.03 8-9 8a9.863 9.863 0 01-4.255-.949L3 20l1.395-3.72C3.512 15.042 3 13.574 3 12c0-4.418 4.03-8 9-8s9 3.582 9 8z'/%3E%3C/svg%3E"); }

.app-icon-bg.editor { background: #10b981; }

.app-icon-bg.assistant {
    background: linear-gradient(135deg, #8b5cf6, #a78bfa);
}

.icon-edit { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='white'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z'/%3E%3C/svg%3E"); }

/* Responsive Design */
@media (max-width: 768px) {
    .ai-toggle {
        width: 20px;
        height: 60px;
    }
    
    .ai-toggle:hover {
        width: 24px;
    }
    .app-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 12px;
        top: 16px;
        left: 16px;
        right: 16px;
    }
    
    .window {
        min-width: 300px;
        width: calc(100vw - 32px) !important;
        height: calc(100vh - 160px) !important;
        left: 16px !important;
        top: 64px !important;
    }
    
    .sidebar {
        width: 100vw;
    }
}

/* Slider/Range Input Styles */
input[type="range"] {
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    width: 100% !important;
    height: 6px !important;
    border-radius: 3px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    outline: none !important;
    cursor: pointer !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    margin: 8px 0 !important;
}

input[type="range"]:hover {
    background: rgba(255, 255, 255, 0.15) !important;
}

/* Webkit slider thumb */
input[type="range"]::-webkit-slider-thumb {
    appearance: none !important;
    -webkit-appearance: none !important;
    width: 18px !important;
    height: 18px !important;
    border-radius: 50% !important;
    background: rgba(0, 0, 0, 0.3) !important;
    border: 2px solid rgba(255, 255, 255, 0.2) !important;
    cursor: pointer !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2) !important;
}

input[type="range"]::-webkit-slider-thumb:hover {
    background: rgba(0, 0, 0, 0.3) !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
    transform: scale(1.1) !important;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3) !important;
}

input[type="range"]::-webkit-slider-thumb:active {
    transform: scale(1.05) !important;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2) !important;
}

/* Firefox slider thumb */
input[type="range"]::-moz-range-thumb {
    width: 18px !important;
    height: 18px !important;
    border-radius: 50% !important;
    background: rgba(0, 0, 0, 0.3) !important;
    border: 2px solid rgba(255, 255, 255, 0.2) !important;
    cursor: pointer !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2) !important;
}

input[type="range"]::-moz-range-thumb:hover {
    background: rgba(0, 0, 0, 0.8) !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
    transform: scale(1.1) !important;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3) !important;
}

/* Firefox slider track */
input[type="range"]::-moz-range-track {
    height: 6px !important;
    border-radius: 3px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    border: none !important;
}

input[type="range"]:hover::-moz-range-track {
    background: rgba(255, 255, 255, 0.15) !important;
}

/* Focus styles for accessibility */
input[type="range"]:focus {
    background: rgba(255, 255, 255, 0.15) !important;
}

input[type="range"]:focus::-webkit-slider-thumb {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3) !important;
}

input[type="range"]:focus::-moz-range-thumb {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3) !important;
}

/* Disabled state */
input[type="range"]:disabled {
    opacity: 0.5 !important;
    cursor: not-allowed !important;
    background: rgba(255, 255, 255, 0.05) !important;
}

input[type="range"]:disabled::-webkit-slider-thumb {
    background: rgba(255, 255, 255, 0.3) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    cursor: not-allowed !important;
    transform: none !important;
}

input[type="range"]:disabled::-moz-range-thumb {
    background: rgba(255, 255, 255, 0.3) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    cursor: not-allowed !important;
    transform: none !important;
}

/* Dark theme variant */
input[type="range"].dark-theme {
    background: rgba(255, 255, 255, 0.12) !important;
}

input[type="range"].dark-theme:hover {
    background: rgba(255, 255, 255, 0.18) !important;
}

/* Animation for value change */
@keyframes sliderMove {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.15);
    }
    100% {
        transform: scale(1);
    }
}

input[type="range"]::-webkit-slider-thumb:active {
    animation: sliderMove 0.15s ease-in-out !important;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    input[type="range"] {
        background: rgba(255, 255, 255, 0.3) !important;
    }
    
    input[type="range"]::-webkit-slider-thumb {
        border-color: rgba(255, 255, 255, 0.8) !important;
        background: #ffffff !important;
    }
    
    input[type="range"]::-moz-range-thumb {
        border-color: rgba(255, 255, 255, 0.8) !important;
        background: #ffffff !important;
    }
}

.icon-music::before {
    content: '♪';
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    input[type="range"],
    input[type="range"]::-webkit-slider-thumb,
    input[type="range"]::-moz-range-thumb {
        transition: none !important;
        animation: none !important;
    }

    input[type="range"]::-webkit-slider-thumb:hover,
    input[type="range"]::-webkit-slider-thumb:active {
        transform: none !important;
    }
    
    input[type="range"]::-moz-range-thumb:hover {
        transform: none !important;
    }
}

/* Ensure consistent sizing in different containers */
.window-content input[type="range"],
.sidebar-content input[type="range"],
form input[type="range"] {
    width: 100% !important;
    height: 6px !important;
}

/* Slider with labels/values */
.slider-container {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin: 8px 0;
}

.slider-label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 12px;
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.slider-value {
    color: rgba(0, 0, 0, 0.2);
    font-weight: 600;
}

/* Vertical slider support */
input[type="range"].vertical {
    writing-mode: bt-lr;
    -webkit-appearance: slider-vertical !important;
    width: 6px !important;
    height: 100px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    outline: none !important;
}