/*
 * scroll-progress.css
 * Horizontaler Fortschrittsbalken für Beiträge
 */

/* Progress Bar Container */
.scroll-progress-container {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: transparent;
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    border-bottom-left-radius: inherit;
    border-bottom-right-radius: inherit;
    z-index: 15;
    overflow: hidden;
    pointer-events: none; /* Ensure it doesn't block clicks */
    transition: opacity 0.3s var(--transition-smooth);
    opacity: 0;
}

/* Der eigentliche Fortschrittsbalken */
.scroll-progress-bar {
    height: 100%;
    width: 0%; /* Wird durch JS aktualisiert */
    background-color: var(--color-accent-primary);
    border-radius: inherit;
    transition: width 0.1s linear; /* Linear für gleichmäßige Bewegung */
}

/* Nur anzeigen, wenn ein echter Lesefortschritt vorhanden ist */
.scroll-progress-container.active {
    opacity: 1;
}

/* Animationen für das Erscheinen und Verschwinden */
@keyframes fadeInProgress {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

.scroll-progress-container.show {
    animation: fadeInProgress 0.3s forwards;
}

.scroll-progress-container.hide {
    animation: fadeOutProgress 0.3s forwards;
}
