/**
 * Sermon Auto-Scroll Styles
 *
 * Styling for auto-scroll button and controls.
 *
 * @author Claude Sonnet 4.5
 * @version 1.0.0
 */

/* Auto-scroll toggle button */
#toggle-auto-scroll {
    position: relative;
    transition: all 0.3s ease;
}

#toggle-auto-scroll[data-active="true"] {
    background-color: #198754;
    border-color: #198754;
    color: white;
}

#toggle-auto-scroll[data-active="true"]::after {
    content: '';
    position: absolute;
    top: -2px;
    right: -2px;
    width: 8px;
    height: 8px;
    background-color: #28a745;
    border: 2px solid white;
    border-radius: 50%;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.2);
    }
}

/* Settings dropdown */
#auto-scroll-settings {
    border-left: 1px solid rgba(0, 0, 0, 0.1);
}

/* Speed menu */
#auto-scroll-speed-menu {
    min-width: 180px;
}

#auto-scroll-speed-menu .dropdown-header {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #6c757d;
    padding: 0.5rem 1rem;
}

#auto-scroll-speed-menu .dropdown-item {
    padding: 0.5rem 1rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

#auto-scroll-speed-menu .dropdown-item:hover {
    background-color: rgba(25, 135, 84, 0.1);
}

#auto-scroll-speed-menu .dropdown-item.active {
    background-color: #198754;
    color: white;
}

#auto-scroll-speed-menu .dropdown-item.active:hover {
    background-color: #157347;
}

#auto-scroll-speed-menu .dropdown-item i {
    width: 1.25rem;
    text-align: center;
}

/* Mobile responsive */
@media (max-width: 768px) {
    #toggle-auto-scroll,
    #auto-scroll-settings {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
    }

    #auto-scroll-speed-menu {
        min-width: 150px;
        font-size: 0.875rem;
    }
}

/* Dark theme support */
.dark-theme #toggle-auto-scroll[data-active="true"] {
    background-color: #28a745;
    border-color: #28a745;
}

.dark-theme #auto-scroll-settings {
    border-left-color: rgba(255, 255, 255, 0.2);
}

.dark-theme #auto-scroll-speed-menu {
    background-color: #212529;
    border-color: rgba(255, 255, 255, 0.2);
}

.dark-theme #auto-scroll-speed-menu .dropdown-item {
    color: #f8f9fa;
}

.dark-theme #auto-scroll-speed-menu .dropdown-item:hover {
    background-color: rgba(40, 167, 69, 0.2);
}

.dark-theme #auto-scroll-speed-menu .dropdown-item.active {
    background-color: #28a745;
}

/* Print styles */
@media print {
    #toggle-auto-scroll,
    #auto-scroll-settings,
    #auto-scroll-speed-menu {
        display: none !important;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    #toggle-auto-scroll,
    #toggle-auto-scroll[data-active="true"]::after,
    #auto-scroll-speed-menu .dropdown-item {
        transition: none;
        animation: none;
    }
}

/* Accessibility - Focus states */
#toggle-auto-scroll:focus,
#auto-scroll-settings:focus {
    outline: 2px solid #198754;
    outline-offset: 2px;
}

#auto-scroll-speed-menu .dropdown-item:focus {
    background-color: rgba(25, 135, 84, 0.15);
    outline: none;
}
