/* Simple Reading Progress Styles */

/* Progress Bar at Top */
.simple-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: rgba(0, 0, 0, 0.1);
    z-index: 10001;
    pointer-events: none;
}

.simple-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-color, #2c5aa0), var(--gold-color, #d4af37));
    width: 0%;
    transition: width 0.2s ease;
}

/* Reading Time Widget - Arc Shape at Top Center */
.reading-time-widget {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%) translateY(-100%);
    background: rgba(231, 76, 60, 0.75);
    padding: 10px 24px;
    box-shadow: 0 2px 16px rgba(231, 76, 60, 0.4);
    z-index: 100;
    transition: transform 0.3s ease;
    pointer-events: none;
    font-family: var(--font-content, 'Noto Kufi Arabic', 'Traditional Arabic', serif);
    direction: rtl;
    display: flex;
    align-items: center;
    gap: 16px;
    white-space: nowrap;
    max-width: 90%;
    border-radius: 0 0 50px 50px;
    backdrop-filter: blur(10px);
}

.reading-time-widget.visible {
    transform: translateX(-50%) translateY(0);
}

.widget-section {
    font-size: 15px;
    font-weight: 600;
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 300px;
}

.widget-separator {
    color: rgba(255, 255, 255, 0.5);
    font-weight: 300;
}

.widget-progress {
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    display: none;
}

.widget-time {
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.95);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Dark Theme Support */
[data-theme="dark"] .simple-progress-bar {
    background: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .reading-time-widget {
    background: rgba(231, 76, 60, 0.75);
    box-shadow: 0 2px 16px rgba(231, 76, 60, 0.5);
}

[data-theme="dark"] .widget-section,
[data-theme="dark"] .widget-progress,
[data-theme="dark"] .widget-time {
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .widget-separator {
    color: rgba(255, 255, 255, 0.5);
}

/* Sepia Theme Support */
[data-theme="sepia"] .simple-progress-bar {
    background: #d4c8b4;
}

[data-theme="sepia"] .reading-time-widget {
    background: rgba(139, 105, 20, 0.85);
    box-shadow: 0 2px 16px rgba(139, 105, 20, 0.4);
}

[data-theme="sepia"] .widget-section,
[data-theme="sepia"] .widget-progress,
[data-theme="sepia"] .widget-time {
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

[data-theme="sepia"] .widget-separator {
    color: rgba(255, 255, 255, 0.5);
}

/* High Contrast Theme Support */
[data-theme="high-contrast"] .simple-progress-bar {
    background: #333333;
}

[data-theme="high-contrast"] .reading-time-widget {
    background: #000000;
    border: 2px solid #00ff00;
    box-shadow: 0 2px 16px rgba(0, 255, 0, 0.4);
}

[data-theme="high-contrast"] .widget-section,
[data-theme="high-contrast"] .widget-progress,
[data-theme="high-contrast"] .widget-time {
    color: #00ff00;
    text-shadow: none;
}

[data-theme="high-contrast"] .widget-separator {
    color: #00ff00;
}

/* Mobile Reading Time Indicator - Semi-circle at top */
.mobile-time-indicator {
    position: fixed;
    top: -50px;
    left: 50%;
    transform: translateX(-50%);
    background: #e74c3c;
    color: white;
    padding: 8px 20px 12px;
    border-radius: 0 0 50px 50px;
    font-family: var(--font-headings, 'Cairo', sans-serif);
    font-size: 14px;
    font-weight: 600;
    z-index: 999;
    transition: top 0.3s ease;
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4);
    text-align: center;
    min-width: 100px;
}

.mobile-time-indicator.visible {
    top: 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .reading-time-widget {
        padding: 8px 20px;
        gap: 12px;
    }
    
    .widget-section {
        font-size: 14px;
        max-width: 200px;
    }
    
    .widget-progress {
        font-size: 15px;
    }
    
    .widget-time {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .reading-time-widget {
        padding: 5px 16px;
        gap: 10px;
        max-width: 100%;
        font-size: 13px;
    }
    
    .widget-section {
        font-size: 13px;
        max-width: 150px;
    }
    
    .widget-progress {
        font-size: 14px;
    }
    
    .widget-time {
        font-size: 12px;
    }
}

/* Print - Hide Progress Elements */
@media print {
    .simple-progress-bar,
    .reading-time-widget {
        display: none !important;
    }
}
