/* Global reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: all 0.2s ease;
}

/* Prevent text cursor on non-input elements */
*:not(input):not(textarea):not([contenteditable="true"]) {
    caret-color: transparent;
}

/* Ensure text cursor only appears on actual text input elements */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="url"],
textarea,
[contenteditable="true"] {
    caret-color: auto;
}

body {
    font-family: 'Inter', 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #e0e0e0;
    background-color: #121212;
    margin: 0;
    padding: 0;
    animation: fadeIn 0.4s ease-in;
    overflow: hidden;
    width: 100vw;
    height: 100vh;
}

header {
    text-align: center;
    margin-bottom: 30px;
}

header h1 {
    font-size: 1.8rem;
    color: #ffffff;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Browser Compatibility Warning */
.browser-warning {
    background-color: rgba(243, 156, 18, 0.15);
    color: #f39c12;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 12px;
    border: 1px solid rgba(243, 156, 18, 0.3);
}

.browser-warning h3 {
    margin-bottom: 10px;
    color: #f39c12;
}

.browser-warning ul {
    margin-left: 20px;
    margin-bottom: 10px;
    color: #e0e0e0;
}

/* Control Panel - MOVED TO control-panel-simplified.css */
/* .control-panel {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 24px;
    padding: 16px;
    background-color: #1e1e1e;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.control-panel button {
    padding: 10px 16px;
    background-color: #2c2c2c;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    order: 0;
}

.control-panel #testFirework {
    order: 3;
}

.control-panel #togglePanels {
    order: 4;
    background-color: #95a5a6 !important;
    color: #ffffff !important;
}

.control-panel button#togglePanels {
    background-color: #95a5a6 !important;
    color: #ffffff !important;
}

#togglePanels {
    background-color: #95a5a6 !important;
    color: #ffffff !important;
}

.control-panel #startMicrophone {
    order: 1;
}

.control-panel #toggleSettings {
    order: 2;
} */

button .icon {
    font-size: 16px;
    line-height: 1;
}

button .text {
    font-size: 12px;
    line-height: 1;
}

button:hover {
    background-color: #3a3a3a;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

button:active {
    transform: translateY(0);
    box-shadow: 0 2px 3px rgba(0, 0, 0, 0.2);
}

button:disabled {
    background-color: #2a2a2a;
    color: #555555;
    cursor: not-allowed;
    box-shadow: none;
}

#startMicrophone {
    background-color: #2ecc71;
    color: #ffffff;
}

#startMicrophone:hover {
    background-color: #27ae60;
}

#startMicrophone.active {
    background-color: #e74c3c;
    color: #ffffff;
    animation: pulse 2s infinite;
}

#startMicrophone.active:hover {
    background-color: #c0392b;
}

#startMicrophone:disabled {
    background-color: #555555 !important;
    color: #888888 !important;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(231, 76, 60, 0); }
    100% { box-shadow: 0 0 0 0 rgba(231, 76, 60, 0); }
}

#stopMicrophone {
    background-color: #e74c3c;
    color: #ffffff;
}

#stopMicrophone:hover {
    background-color: #c0392b;
}

#testFirework {
    background-color: #9b59b6;
    color: #ffffff;
}

#testFirework:hover {
    background-color: #8e44ad;
}

#toggleSettings {
    background-color: #3498db;
    color: #ffffff;
}

#toggleSettings:hover {
    background-color: #2980b9;
}

/* Old mode selector styles removed - now using minimal toggle */

/* Visualization Container */
.visualization-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-bottom: 30px;
}

/* Audio Visualizer - Basic styles only (layout handled in layout.css and audio-visualizer.css) */
.audio-visualizer {
    background-color: #1e1e1e;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border: 1px solid #2c2c2c;
    transition: opacity 0.3s ease, border-color 0.3s ease;
}

.audio-visualizer.active {
    border-color: #2ecc71;
    box-shadow: 0 4px 20px rgba(46, 204, 113, 0.2);
}

.audio-visualizer.inactive {
    border-color: #e74c3c;
    box-shadow: 0 4px 20px rgba(231, 76, 60, 0.2);
}

.audio-visualizer.mic-active {
    border-color: rgba(46, 204, 113, 0.5);
}

.audio-visualizer.mic-inactive {
    border-color: rgba(231, 76, 60, 0.5);
}

/* Volume meter basic styles (enhanced in other CSS files) */
.volume-meter {
    height: 12px;
    background-color: rgba(44, 44, 44, 0.5);
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 16px;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.level-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #2ecc71, #3498db);
    position: relative;
    transform-origin: left center;
}

.level-bar::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 2px;
    background-color: rgba(255, 255, 255, 0.8);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.8),
                0 0 5px rgba(255, 255, 255, 0.5);
}

/* Audio status enhanced styling */
#audioStatus {
    font-size: 16px;
    color: #a0a0a0;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

#audioStatus::before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #e74c3c;
    transition: all 0.3s ease;
}

#audioStatus.active::before {
    background-color: #2ecc71;
    box-shadow: 0 0 10px rgba(46, 204, 113, 0.5);
}

#audioStatus.inactive::before {
    background-color: #e74c3c;
    box-shadow: 0 0 10px rgba(231, 76, 60, 0.5);
}

#audioStatus.starting::before {
    background-color: #f39c12;
    box-shadow: 0 0 10px rgba(243, 156, 18, 0.5);
    animation: spin 1s linear infinite;
}

#audioStatus.stopping::before {
    background-color: #f39c12;
    box-shadow: 0 0 10px rgba(243, 156, 18, 0.5);
}

#audioStatus.error::before {
    background-color: #e74c3c;
    box-shadow: 0 0 10px rgba(231, 76, 60, 0.5);
    animation: shake 0.5s ease-in-out;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-2px); }
    75% { transform: translateX(2px); }
}

/* Animation Canvas - both layers */
#animationCanvas, #backgroundCanvas {
    width: 100%;
    height: 500px;
    background-color: #000000;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    display: block;
}

/* Settings Panel */
.settings-panel {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    background-color: #1e1e1e;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    padding: 24px;
    border: 1px solid #2c2c2c;
    max-width: 400px;
    width: 90%;
}

.hidden {
    display: none;
}

.settings-section {
    margin-bottom: 24px;
}

.settings-section h3 {
    font-size: 1.1rem;
    margin-bottom: 16px;
    color: #ffffff;
    border-bottom: 1px solid #2c2c2c;
    padding-bottom: 8px;
}

.setting {
    margin-bottom: 18px;
}

.setting label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #e0e0e0;
}

.setting input[type="range"] {
    width: 100%;
    padding: 5px;
    background-color: #2c2c2c;
    border-radius: 10px;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
}

.setting input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #3498db;
    cursor: pointer;
}

.setting input[type="range"]::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #3498db;
    cursor: pointer;
    border: none;
}

.setting select {
    width: 100%;
    padding: 8px 12px;
    background-color: #2c2c2c;
    color: #e0e0e0;
    border: none;
    border-radius: 8px;
}

/* Settings panel buttons - removed in favor of simplified approach in settings-tabs.css */

/* Footer */
footer {
    margin-top: 40px;
    text-align: center;
}

.reference-guide {
    background-color: #1e1e1e;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    margin-bottom: 20px;
    border: 1px solid #2c2c2c;
}

.reference-guide h3 {
    margin-bottom: 16px;
    color: #ffffff;
}

.reference-guide ul {
    list-style-type: none;
    text-align: left;
    max-width: 600px;
    margin: 0 auto;
}

.reference-guide li {
    padding: 10px 0;
    border-bottom: 1px solid #2c2c2c;
}

.reference-guide li:last-child {
    border-bottom: none;
}

.reference-guide strong {
    color: #3498db;
}

/* Microphone Test */
.mic-test {
    margin: 0;
    padding: 0;
    border-top: none;
}

.mic-test p {
    margin: 0;
    font-size: 0.9rem;
    color: #a0a0a0;
    line-height: 1.5;
}

.mic-detection {
    padding: 10px 16px;
    border-radius: 8px;
    background-color: #2c2c2c;
    display: inline-block;
    font-weight: 500;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    border: 1px solid transparent;
}

.mic-detection.detected-loud {
    background-color: #e74c3c;
    color: white;
    box-shadow: 0 0 15px rgba(231, 76, 60, 0.5);
    border-color: rgba(255, 255, 255, 0.2);
}

.mic-detection.detected-sudden {
    background-color: #f39c12;
    color: white;
    box-shadow: 0 0 15px rgba(243, 156, 18, 0.5);
    border-color: rgba(255, 255, 255, 0.2);
}

.mic-detection.detected-sustained {
    background-color: #2ecc71;
    color: white;
    box-shadow: 0 0 15px rgba(46, 204, 113, 0.5);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Responsive Design */
@media (min-width: 768px) {
    .visualization-container {
        flex-direction: row;
    }
    
    /* Remove conflicting audio-visualizer flex style for desktop */
    /* .audio-visualizer {
        flex: 1;
    } */
    
    #animationCanvas, #backgroundCanvas {
        flex: 2;
        height: 500px;
    }
    
    /* Control panel styles moved to control-panel-simplified.css
    .control-panel {
        justify-content: space-evenly;
    }

    .control-panel:has(#startMicrophone.is-hidden):has(#toggleSettings.is-hidden):not(:has(#togglePanels.is-hidden)):not(:has(#testFirework.is-hidden)) {
    }

    .control-panel:has(#startMicrophone.is-hidden):has(#toggleSettings.is-hidden):not(:has(#togglePanels.is-hidden)):not(:has(#testFirework.is-hidden)) #testFirework {
        order: 1;
    }

    .control-panel:has(#startMicrophone.is-hidden):has(#toggleSettings.is-hidden):not(:has(#togglePanels.is-hidden)):not(:has(#testFirework.is-hidden)) #togglePanels {
        order: 2;
    } */
}

/* Mobile Mode Toggle - Above control panel */
.mobile-mode-toggle {
    display: none; /* Hidden on desktop */
    text-align: center;
    margin: 8px 0 12px 0; /* Reduced margins, especially top */
    padding: 5px; /* Reduced padding */
    position: relative;
    z-index: 10;
    pointer-events: auto;
}

@media (max-width: 767px) {
    .mobile-mode-toggle {
        display: block;
        /* Ensure it's not cut off by viewport */
        min-height: 60px; /* Minimum height to contain the toggle */
        overflow: visible; /* Ensure toggle is fully visible */
    }
    
    /* Ensure app container has enough top padding for mobile toggle */
    .app-container {
        padding-top: 16px !important;
    }
    
    /* Mobile toggle styling - larger than desktop */
    .mode-toggle.mobile-toggle {
        /* Positioning */
        position: relative;
        margin: 0 auto;
        z-index: 11;
        
        /* Larger sizing for mobile */
        width: 80px;
        height: 40px;
        
        /* Visual styling */
        background: rgba(0, 0, 0, 0.6);
        border: 1px solid rgba(255, 255, 255, 0.3);
        border-radius: 20px;
        
        /* Enhanced styling for mobile */
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
        
        /* Touch-friendly */
        -webkit-tap-highlight-color: rgba(255, 255, 255, 0.2);
        touch-action: manipulation;
        
        /* Interaction */
        cursor: pointer;
        user-select: none;
        -webkit-user-select: none;
        -moz-user-select: none;
        pointer-events: auto;
        
        /* Flexbox layout */
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0 8px;
        
        /* Smooth transitions */
        transition: all 0.25s ease;
    }
    
    .mode-toggle.mobile-toggle:hover {
        background: rgba(0, 0, 0, 0.8);
        border-color: rgba(255, 255, 255, 0.5);
        box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
        transform: translateY(-2px);
    }
    
    .mode-toggle.mobile-toggle:active {
        background: rgba(0, 0, 0, 0.9);
        transform: translateY(0);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    }
    
    /* Mobile toggle mode options */
    .mode-toggle.mobile-toggle .mode-option {
        /* Sizing for mobile */
        width: 24px;
        height: 24px;
        
        /* Typography */
        font-size: 16px;
        font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
        
        /* Centering */
        display: flex;
        align-items: center;
        justify-content: center;
        
        /* Visual state */
        opacity: 0.6;
        transition: all 0.25s ease;
        
        /* Interaction */
        cursor: pointer;
        pointer-events: auto;
        
        /* Layering - above slider */
        position: relative;
        z-index: 12;
        
        /* Accessibility */
        border-radius: 12px;
    }
    
    .mode-toggle.mobile-toggle .mode-option:hover {
        opacity: 0.8;
    }
    
    .mode-toggle.mobile-toggle .mode-option.active {
        opacity: 1;
        text-shadow: 0 0 8px rgba(255, 255, 255, 0.6);
    }
    
    /* Mobile toggle slider */
    .mode-toggle.mobile-toggle .mode-slider {
        /* Positioning */
        position: absolute;
        top: 2px;
        left: 2px;
        
        /* Sizing for mobile - smaller to fit within frame */
        width: 36px;
        height: 36px;
        border-radius: 18px;
        
        /* Visual styling */
        background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
        box-shadow: 
            0 3px 6px rgba(0, 0, 0, 0.3),
            0 2px 4px rgba(0, 0, 0, 0.2);
        
        /* Animation */
        transition: all 0.3s ease;
        
        /* Layering - behind emojis */
        z-index: 1;
    }
    
    /* Mobile bubble mode state */
    .mode-toggle.mobile-toggle.bubble-mode .mode-slider {
        /* Move to right side - adjusted for smaller slider */
        transform: translateX(42px);
        
        /* Change color */
        background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    }
}

/* Mobile Control Panel - MOVED TO control-panel-simplified.css */
/* @media (max-width: 767px) {
    .control-panel {
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-template-rows: 1fr 1fr;
        gap: 12px;
        max-width: 400px;
        margin: 0 auto;
        margin-top: 0;
    }
    
    .control-panel button {
        min-width: unset;
        width: 100%;
        min-height: 60px;
    }
    
    #animationCanvas, #backgroundCanvas {
        height: 350px;
    }
} */



/* Add a subtle animation to the entire app */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* General utility classes */
.is-hidden {
    display: none !important;
}

/* Desktop layout for buttons */
@media (min-width: 769px) {
    button {
        flex-direction: row;
        gap: 8px;
    }
    
    button .icon {
        font-size: 14px;
    }
    
    button .text {
        font-size: 14px;
    }
}

/* .control-panel #togglePanels:hover,
.control-panel button#togglePanels:hover,
#togglePanels:hover {
    background-color: #7f8c8d !important;
    color: #ffffff !important;
} */

/* Desktop Toggle - Integrated into tab navigation */
.mode-toggle.desktop-toggle {
    /* Positioning within tab navigation */
    position: relative;
    margin-left: auto;
    z-index: 1;
    
    /* Compact sizing for tab header */
    width: 60px;
    height: 30px;
    
    /* Visual styling */
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 15px;
    
    /* Subtle styling to blend with tabs */
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    
    /* Interaction */
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    
    /* Simple flexbox layout */
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 6px;
    
    /* Smooth transitions */
    transition: all 0.25s ease;
}

/* Hide desktop toggle on mobile */
@media (max-width: 768px) {
    .mode-toggle.desktop-toggle {
        display: none;
    }
}

/* Hide mobile mode toggle on desktop */
@media (min-width: 769px) {
    .mobile-mode-toggle {
        display: none;
    }
}

/* Tab navigation integration */
.uploader-tab-navigation {
    display: flex;
    align-items: center;
    gap: 8px;
}

.uploader-tab-navigation .mode-toggle.desktop-toggle {
    flex-shrink: 0;
    margin-left: 16px;
}

.mode-toggle.desktop-toggle:hover {
    background: rgba(0, 0, 0, 0.8);
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.4);
}

.mode-toggle.desktop-toggle:active {
    background: rgba(0, 0, 0, 0.9);
}

/* Desktop toggle mode options */
.mode-toggle.desktop-toggle .mode-option {
    /* Sizing for desktop */
    width: 18px;
    height: 18px;
    
    /* Typography */
    font-size: 12px;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
    
    /* Centering */
    display: flex;
    align-items: center;
    justify-content: center;
    
    /* Visual state */
    opacity: 0.6;
    transition: all 0.25s ease;
    
    /* Interaction */
    cursor: pointer;
    
    /* Layering - above slider */
    position: relative;
    z-index: 3;
    
    /* Accessibility */
    border-radius: 9px;
}

.mode-toggle.desktop-toggle .mode-option:hover {
    opacity: 0.8;
}

.mode-toggle.desktop-toggle .mode-option.active {
    opacity: 1;
    text-shadow: 0 0 6px rgba(255, 255, 255, 0.6);
}

/* Desktop toggle slider */
.mode-toggle.desktop-toggle .mode-slider {
    /* Positioning */
    position: absolute;
    top: 1px;
    left: 1px;
    
    /* Sizing for desktop */
    width: 28px;
    height: 28px;
    border-radius: 14px;
    
    /* Visual styling */
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    box-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.2),
        0 1px 2px rgba(0, 0, 0, 0.1);
    
    /* Animation */
    transition: all 0.3s ease;
    
    /* Layering - behind emojis */
    z-index: 1;
}

/* Desktop bubble mode state */
.mode-toggle.desktop-toggle.bubble-mode .mode-slider {
    /* Move to right side */
    transform: translateX(30px);
    
    /* Change color */
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
}

/* Mobile responsive design - CHOOSE YOUR PREFERRED OPTION */

/* OPTION 1: Top Center (Current) */
@media (max-width: 768px) {
    .mode-toggle {
        top: 10px;
        left: 50%;
        transform: translateX(-50%);
        right: auto;
        
        /* Smaller sizing */
        width: 60px;
        height: 32px;
        border-radius: 16px;
        padding: 0 5px;
    }
}

/* OPTION 2: Top Left Corner - Uncomment to use */
/*
@media (max-width: 768px) {
    .mode-toggle {
        top: 10px;
        left: 10px;
        right: auto;
        transform: none;
        
        width: 60px;
        height: 32px;
        border-radius: 16px;
        padding: 0 5px;
    }
}
*/

/* OPTION 3: Top Right Corner (same as desktop) - Uncomment to use */
/*
@media (max-width: 768px) {
    .mode-toggle {
        top: 10px;
        right: 10px;
        left: auto;
        transform: none;
        
        width: 60px;
        height: 32px;
        border-radius: 16px;
        padding: 0 5px;
    }
}
*/

/* OPTION 4: Bottom Center (floating) - Uncomment to use */
/*
@media (max-width: 768px) {
    .mode-toggle {
        top: auto;
        bottom: 20px;
        left: 50%;
        transform: translateX(-50%);
        right: auto;
        
        width: 60px;
        height: 32px;
        border-radius: 16px;
        padding: 0 5px;
    }
}
*/

/* OPTION 5: Bottom Right Corner - Uncomment to use */
/*
@media (max-width: 768px) {
    .mode-toggle {
        top: auto;
        bottom: 20px;
        right: 15px;
        left: auto;
        transform: none;
        
        width: 60px;
        height: 32px;
        border-radius: 16px;
        padding: 0 5px;
    }
}
*/

/* Small screens - applies to whichever option you choose above */
@media (max-width: 480px) {
    .mode-toggle {
        width: 55px;
        height: 28px;
        border-radius: 14px;
        padding: 0 4px;
    }
    
    .mode-option {
        width: 16px;
        height: 16px;
        font-size: 11px;
    }
    
    .mode-slider {
        width: 25px;
        height: 25px;
        border-radius: 12px;
    }
    
    .mode-toggle.bubble-mode .mode-slider {
        transform: translateX(26px);
    }
}

/* Accessibility enhancements */
.mode-toggle:focus-visible {
    outline: 3px solid #60a5fa;
    outline-offset: 2px;
}

.mode-option:focus-visible {
    outline: 2px solid #60a5fa;
    outline-offset: 1px;
}

/* Prevent text cursor on focusable non-input elements */
.mode-toggle,
.mode-option,
div[tabindex],
button,
[role="switch"],
[role="button"] {
    caret-color: transparent;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Ensure proper cursor for interactive elements */
.mode-toggle,
.mode-option,
div[tabindex]:not([tabindex="-1"]),
[role="switch"],
[role="button"] {
    cursor: pointer;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .mode-toggle {
        background: #000000;
        border: 3px solid #ffffff;
    }
    
    .mode-slider {
        box-shadow: 0 0 0 2px #ffffff;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .mode-toggle,
    .mode-option,
    .mode-slider {
        transition: none;
    }
    
    .mode-option:hover,
    .mode-option.active {
        transform: none;
    }
}

/* Dark mode adjustments */
@media (prefers-color-scheme: light) {
    .mode-toggle {
        background: rgba(255, 255, 255, 0.9);
        border-color: rgba(0, 0, 0, 0.2);
        color: #000000;
    }
    
    .mode-option.active {
        text-shadow: 0 0 8px rgba(0, 0, 0, 0.5);
    }
}