@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

* {
    font-family: 'Inter', sans-serif;
}

/* Radar Animation */
@keyframes radar {
    0% {
        transform: scale(0.8);
        opacity: 1;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

.glass-effect {
    background: rgba(255, 255, 255, 0.01);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.dark .glass-effect {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

html.light .glass-effect {
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.radar-circle {
    animation: radar 3s infinite ease-out;
    pointer-events: none;
}

/* Progress Bar Animation */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

#progressBar {
    background-size: 200% 200%;
    animation: gradientShift 2s ease infinite;
    transition: width 0.5s ease-out;
}

/* Pulse Animation */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.6;
    }
}

.animate-pulse {
    animation: pulse 2s infinite;
}

/* Fade In Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

/* Detected Items Animation */
@keyframes detectedItem {
    0% {
        background-color: rgba(239, 68, 68, 0.2);
    }
    50% {
        background-color: rgba(239, 68, 68, 0.1);
    }
    100% {
        background-color: rgba(239, 68, 68, 0.2);
    }
}

.detected-item {
    animation: detectedItem 2s infinite;
}

/* Video Placeholder Animation */
@keyframes videoPlaceholderGlow {
    0%, 100% {
        box-shadow: 0 0 15px rgba(239, 68, 68, 0.3);
    }
    50% {
        box-shadow: 0 0 25px rgba(239, 68, 68, 0.5);
    }
}

#videoPlaceholder {
    animation: videoPlaceholderGlow 2s infinite;
}

/* Dark Mode Styles */
.dark .bg-gray-900 {
    background-color: rgba(17, 24, 39, 0.8);
}

.dark #progressBar {
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
}

/* Light Mode Styles */
.light #progressBar {
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.3);
}

/* Typewriter Animation */
@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

.typewriter {
    overflow: hidden;
    white-space: nowrap;
    animation: typing 1s steps(40, end);
}

/* Detected Text Animation */
.detected-text {
    position: relative;
    display: inline-block;
}

.detected-text::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, rgba(239, 68, 68, 0.7), rgba(139, 92, 246, 0.7));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.detected-text.active::after {
    transform: scaleX(1);
}
