/* Video Fade In/Out Tool Styles */

/* Fade slider with striped background (similar to volume slider) */
.fade-slider {
    --fade-value: 20%;
    height: 8px;
    background: repeating-linear-gradient(
        45deg,
        #e9ecef,
        #e9ecef 5px,
        #d3d6d9 5px,
        #d3d6d9 10px
    );
    border-radius: 4px;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

.fade-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: #052c65;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.fade-slider::-webkit-slider-thumb:hover {
    background: #041f4a;
    transform: scale(1.1);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
}

.fade-slider::-webkit-slider-runnable-track {
    height: 8px;
    background: linear-gradient(to right,
        #052c65 0%,
        #052c65 var(--fade-value, 0%),
        transparent var(--fade-value, 0%)),
        repeating-linear-gradient(
            45deg,
            #e9ecef,
            #e9ecef 5px,
            #d3d6d9 5px,
            #d3d6d9 10px
        );
    border-radius: 4px;
}

.fade-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: #052c65;
    border-radius: 50%;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.fade-slider::-moz-range-thumb:hover {
    background: #041f4a;
    transform: scale(1.1);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
}

.fade-slider::-moz-range-track {
    height: 8px;
    background: repeating-linear-gradient(
        45deg,
        #e9ecef,
        #e9ecef 5px,
        #d3d6d9 5px,
        #d3d6d9 10px
    );
    border-radius: 4px;
}

.fade-slider::-moz-range-progress {
    height: 8px;
    background: #052c65;
    border-radius: 4px;
}

/* Dark mode slider */
[data-bs-theme="dark"] .fade-slider {
    background: repeating-linear-gradient(
        45deg,
        #343a40,
        #343a40 5px,
        #495057 5px,
        #495057 10px
    );
}

[data-bs-theme="dark"] .fade-slider::-webkit-slider-thumb {
    background: #6ea8fe;
}

[data-bs-theme="dark"] .fade-slider::-webkit-slider-thumb:hover {
    background: #9ec5fe;
}

[data-bs-theme="dark"] .fade-slider::-moz-range-thumb {
    background: #6ea8fe;
}

[data-bs-theme="dark"] .fade-slider::-moz-range-thumb:hover {
    background: #9ec5fe;
}

[data-bs-theme="dark"] .fade-slider::-webkit-slider-runnable-track {
    background: linear-gradient(to right,
        #6ea8fe 0%,
        #6ea8fe var(--fade-value, 0%),
        transparent var(--fade-value, 0%)),
        repeating-linear-gradient(
            45deg,
            #343a40,
            #343a40 5px,
            #495057 5px,
            #495057 10px
        );
}

[data-bs-theme="dark"] .fade-slider::-moz-range-track {
    background: repeating-linear-gradient(
        45deg,
        #343a40,
        #343a40 5px,
        #495057 5px,
        #495057 10px
    );
}

[data-bs-theme="dark"] .fade-slider::-moz-range-progress {
    background: #6ea8fe;
}

/* Video preview wrapper */
.video-preview-wrapper {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    border-radius: 8px;
    overflow: hidden;
    background-color: #000;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.video-preview {
    width: 100%;
    height: auto;
    display: block;
}

/* Fade settings card */
.fade-settings-card .card-header {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
}

[data-bs-theme="dark"] .fade-settings-card .card-header {
    background-color: #343a40;
    border-bottom-color: #495057;
}

/* Form switch styling */
.form-check-input:checked {
    background-color: #052c65;
    border-color: #052c65;
}

[data-bs-theme="dark"] .form-check-input:checked {
    background-color: #6ea8fe;
    border-color: #6ea8fe;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .fade-slider::-webkit-slider-thumb {
        width: 24px;
        height: 24px;
    }

    .fade-slider::-moz-range-thumb {
        width: 24px;
        height: 24px;
    }
}
