/* Progress Tracker and Bookmarks Styles */

/* Streak Display */
.streak-container {
    position: fixed;
    top: 100px;
    right: 20px;
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 50px;
    padding: 0.75rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    z-index: 100;
    animation: fadeInRight 0.5s ease;
}

.streak-icon {
    font-size: 1.5rem;
    animation: flicker 2s infinite;
}

@keyframes flicker {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

.streak-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

.streak-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Mark Complete Button */
.mark-complete-btn {
    padding: 0.5rem 1rem;
    background: var(--success-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mark-complete-btn:hover {
    background: var(--success-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.mark-complete-btn.completed {
    background: var(--bg-secondary);
    color: var(--text-muted);
    cursor: default;
}

/* Bookmark Button */
.bookmarkable {
    position: relative;
}

.bookmark-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.5rem;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
}

.bookmark-btn:hover {
    background: var(--bg-secondary);
    transform: scale(1.1);
}

.bookmark-btn.bookmarked {
    background: var(--warning-color);
    border-color: var(--warning-color);
}

/* Bookmarks Menu */
.bookmarks-menu {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
}

.bookmarks-toggle {
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
    transition: all 0.3s ease;
    position: relative;
}

.bookmarks-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.bookmark-icon {
    font-size: 1.5rem;
}

.bookmark-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--danger-color);
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
}

.bookmarks-dropdown {
    position: absolute;
    bottom: 70px;
    right: 0;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    min-width: 300px;
    max-height: 400px;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.bookmarks-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.bookmarks-dropdown h3 {
    margin: 0 0 1rem 0;
    color: var(--text-primary);
    font-size: 1.1rem;
}

.bookmarks-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.bookmark-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: var(--bg-secondary);
    border-radius: 8px;
    transition: all 0.3s ease;
}

.bookmark-item:hover {
    background: var(--bg-tertiary);
}

.bookmark-item a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.95rem;
    flex: 1;
}

.remove-bookmark {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0 0.5rem;
    transition: color 0.3s ease;
}

.remove-bookmark:hover {
    color: var(--danger-color);
}

.no-bookmarks {
    text-align: center;
    color: var(--text-muted);
    padding: 2rem;
}

/* Achievement Notification */
.achievement-notification {
    position: fixed;
    top: 20px;
    right: -400px;
    background: linear-gradient(135deg, var(--success-color), #059669);
    color: white;
    border-radius: var(--border-radius);
    padding: 1rem 1.5rem;
    box-shadow: 0 10px 30px rgba(16, 185, 129, 0.3);
    transition: right 0.3s ease;
    z-index: 2000;
}

.achievement-notification.show {
    right: 20px;
}

.achievement-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.achievement-icon {
    font-size: 2rem;
}

.achievement-text h4 {
    margin: 0 0 0.25rem 0;
    font-size: 1.1rem;
}

.achievement-text p {
    margin: 0;
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Progress Stats Display */
.progress-stats {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 2rem;
    margin: 2rem 0;
}

.progress-stats h2 {
    margin: 0 0 1.5rem 0;
    color: var(--text-primary);
    font-size: 1.5rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.stat-card {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    display: block;
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Progress Bar */
.progress-bar-container {
    background: var(--bg-tertiary);
    border-radius: 50px;
    height: 30px;
    overflow: hidden;
    margin: 1rem 0;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 50px;
    transition: width 0.5s ease;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 1rem;
}

.progress-bar-text {
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .streak-container {
        top: auto;
        bottom: 100px;
        right: 10px;
    }
    
    .bookmarks-menu {
        bottom: 20px;
        right: 20px;
    }
    
    .bookmarks-dropdown {
        right: -10px;
        left: -10px;
        min-width: auto;
        width: calc(100vw - 40px);
    }
    
    .achievement-notification {
        right: 10px;
        left: 10px;
    }
}

/* Animations */
@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
