/* Phase 2: Watchlist & Watch History Styles */

/* Watchlist Heart Icon */
.watchlist-icon {
    position: absolute;
    top: 0.8rem;
    right: 0.8rem;
    width: 44px;
    height: 44px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    cursor: pointer;
    z-index: 10;
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.3s ease;
}

.content-card:hover .watchlist-icon {
    opacity: 1;
    transform: scale(1);
}

.watchlist-icon:hover {
    background: rgba(0, 0, 0, 0.9);
    transform: scale(1.1);
}

.watchlist-icon.active {
    opacity: 1;
    animation: heartBeat 0.5s ease;
}

@keyframes heartBeat {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.3); }
    50% { transform: scale(1.1); }
}

/* Continue Watching Section */
.continue-watching-section {
    margin-bottom: 4rem;
}

.continue-watching-card {
    position: relative;
}

.continue-watching-card .card-overlay {
    opacity: 1;
    background: linear-gradient(to top, rgba(10, 10, 10, 0.95) 0%, transparent 50%);
}

/* Progress Bar */
.progress-bar-container {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin: 0.8rem 0;
}

.progress-bar {
    height: 100%;
    background: var(--accent-primary);
    border-radius: 2px;
    transition: width 0.3s ease;
    position: relative;
}

.progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.progress-info {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
}

/* Enhanced Card Hover States */
.content-card {
    position: relative;
    overflow: hidden;
}

.content-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(212, 175, 55, 0.1),
        transparent
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 1;
}

.content-card:hover::before {
    opacity: 1;
}

/* Play Button Overlay */
.play-button-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 70px;
    height: 70px;
    background: var(--accent-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 5;
    pointer-events: none;
}

.play-button-overlay::after {
    content: '▶';
    color: var(--bg-dark);
    font-size: 1.5rem;
    margin-left: 4px;
}

.content-card:hover .play-button-overlay {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* Recently Watched Badge */
.recently-watched-badge {
    position: absolute;
    top: 0.8rem;
    left: 0.8rem;
    padding: 0.4rem 0.8rem;
    background: rgba(212, 175, 55, 0.9);
    color: var(--bg-dark);
    font-size: 0.7rem;
    font-weight: 600;
    border-radius: 6px;
    z-index: 10;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Completed Badge */
.completed-badge {
    position: absolute;
    top: 0.8rem;
    left: 0.8rem;
    padding: 0.4rem 0.8rem;
    background: rgba(76, 175, 80, 0.9);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    border-radius: 6px;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.completed-badge::before {
    content: '✓';
}

/* Empty State for Continue Watching */
.empty-continue-watching {
    text-align: center;
    padding: 3rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    border: 1px dashed var(--border-subtle);
}

.empty-continue-watching h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    margin-bottom: 0.8rem;
    color: var(--text-primary);
}

.empty-continue-watching p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Watchlist Page */
.watchlist-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

.watchlist-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.watchlist-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
}

.watchlist-count {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.watchlist-filters {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.filter-btn {
    padding: 0.7rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-subtle);
    border-radius: 50px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    font-weight: 500;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--accent-primary);
    color: var(--bg-dark);
    border-color: var(--accent-primary);
}

.empty-watchlist {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-watchlist h3 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    margin-bottom: 1rem;
}

.empty-watchlist p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.browse-btn {
    padding: 1rem 2rem;
    background: var(--accent-primary);
    color: var(--bg-dark);
    border: none;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.browse-btn:hover {
    background: var(--accent-secondary);
    transform: translateY(-2px);
}

/* Loading States */
.skeleton-card {
    aspect-ratio: 2/3;
    background: linear-gradient(
        90deg,
        var(--bg-card) 0%,
        rgba(255, 255, 255, 0.05) 50%,
        var(--bg-card) 100%
    );
    background-size: 200% 100%;
    animation: skeleton 1.5s infinite;
    border-radius: 12px;
}

@keyframes skeleton {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .watchlist-icon {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }
    
    .play-button-overlay {
        width: 60px;
        height: 60px;
    }
    
    .progress-info {
        font-size: 0.75rem;
    }
    
    .watchlist-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .watchlist-filters {
        overflow-x: auto;
        width: 100%;
        padding-bottom: 0.5rem;
    }
    
    .filter-btn {
        white-space: nowrap;
    }
}
