/* ============================================
   📺 TV NEWS - ANIMATIONS
   ============================================ */

@keyframes flicker {

    0%,
    100% {
        opacity: 0.02;
    }

    50% {
        opacity: 0.04;
    }
}

@keyframes static {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: 100% 100%;
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.3);
        opacity: 0.7;
    }
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes glowPulse {

    0%,
    100% {
        box-shadow: 0 0 20px rgba(0, 255, 136, 0.2);
    }

    50% {
        box-shadow: 0 0 40px rgba(0, 255, 136, 0.4);
    }
}

@keyframes breakingFlash {

    0%,
    100% {
        background-color: rgba(255, 45, 85, 0.8);
    }

    50% {
        background-color: rgba(255, 45, 85, 1);
    }
}

@keyframes cardEnter {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes shimmer {
    0% {
        background-position: -200% center;
    }

    100% {
        background-position: 200% center;
    }
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes channelChange {
    0% {
        transform: scale(1);
        filter: brightness(1);
    }

    25% {
        transform: scale(0.98);
        filter: brightness(1.5) saturate(0);
    }

    50% {
        transform: scale(1.02);
        filter: brightness(0.5);
    }

    100% {
        transform: scale(1);
        filter: brightness(1);
    }
}

@keyframes rgbSplit {

    0%,
    100% {
        text-shadow: -2px 0 rgba(255, 0, 0, 0.5), 2px 0 rgba(0, 255, 255, 0.5);
    }

    50% {
        text-shadow: 2px 0 rgba(255, 0, 0, 0.5), -2px 0 rgba(0, 255, 255, 0.5);
    }
}

/* Card animations */
.news-card {
    animation: cardEnter 0.5s ease-out;
    animation-fill-mode: both;
}

.news-card:nth-child(1) {
    animation-delay: 0.05s;
}

.news-card:nth-child(2) {
    animation-delay: 0.1s;
}

.news-card:nth-child(3) {
    animation-delay: 0.15s;
}

.news-card:nth-child(4) {
    animation-delay: 0.2s;
}

.news-card:nth-child(5) {
    animation-delay: 0.25s;
}

.news-card:nth-child(6) {
    animation-delay: 0.3s;
}

.news-card.featured.main {
    animation: cardEnter 0.5s ease-out, glowPulse 3s infinite;
}

.refresh-btn.loading {
    animation: spin 1s linear infinite;
}

.tv-screen.changing {
    animation: channelChange 0.3s ease-out;
}

.ticker-label {
    animation: breakingFlash 1s infinite;
}

.logo-text:hover {
    animation: rgbSplit 0.3s ease;
}

/* Skeleton loading */
.skeleton {
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.05) 25%, rgba(255, 255, 255, 0.1) 50%, rgba(255, 255, 255, 0.05) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
}

.skeleton-image {
    width: 100%;
    aspect-ratio: 16/9;
}

.skeleton-title {
    height: 20px;
    width: 80%;
    margin-bottom: 8px;
}

.skeleton-text {
    height: 14px;
    width: 60%;
}

.card-image {
    opacity: 0;
    transition: opacity 0.5s ease;
}

.card-image.loaded {
    opacity: 1;
}

.neon-text {
    text-shadow: 0 0 5px var(--accent-primary), 0 0 10px var(--accent-primary), 0 0 20px var(--accent-primary);
}