/* ========================================
   ANIMATIONS - All Keyframes & Animation Classes
   ======================================== */

/* ========================================
   RADAR & THREAT ANIMATIONS
   ======================================== */

/* Radar Sweep Animation */
.radar-sweep {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 150%;
    height: 150%;
    transform: translate(-50%, -50%);
    background: conic-gradient(from 0deg,
            transparent 0deg,
            transparent 340deg,
            rgba(239, 68, 68, 0.08) 355deg,
            rgba(239, 68, 68, 0.15) 360deg);
    animation: radarSweep 8s linear infinite;
    mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
}

@keyframes radarSweep {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

/* Bot Node Pulsing Animations */
.bot-pulse-1 {
    animation: botPulse 2s ease-in-out infinite;
}

.bot-pulse-2 {
    animation: botPulse 2s ease-in-out infinite 0.4s;
}

.bot-pulse-3 {
    animation: botPulse 2s ease-in-out infinite 0.8s;
}

@keyframes botPulse {

    0%,
    100% {
        opacity: 0.4;
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
    }

    50% {
        opacity: 1;
        box-shadow: 0 0 12px 2px rgba(239, 68, 68, 0.5);
    }
}

/* Sparkline Crash Animation */
.crash-line {
    stroke-dasharray: 100;
    stroke-dashoffset: 100;
    animation: crashDraw 2s ease-out forwards;
    animation-delay: 0.5s;
}

@keyframes crashDraw {
    to {
        stroke-dashoffset: 0;
    }
}

/* Event Point Pulse */
.event-pulse {
    animation: eventPulse 1.5s ease-in-out infinite;
}

@keyframes eventPulse {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.6);
    }

    50% {
        box-shadow: 0 0 0 8px rgba(239, 68, 68, 0);
    }
}

/* ========================================
   SEMANTIC CLUSTERING ANIMATIONS
   ======================================== */

/* Comment animations - triggered when section enters viewport */
/* Initial state - hidden */
.semantic-comment-1,
.semantic-comment-2,
.semantic-comment-3 {
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}

/* Animated state - when section is in view */
.in-view .semantic-comment-1 {
    animation: commentSlideInVertical 1s cubic-bezier(0.16, 1, 0.3, 1) 0.4s forwards;
}

.in-view .semantic-comment-2 {
    animation: commentSlideInVertical 1s cubic-bezier(0.16, 1, 0.3, 1) 1.4s forwards;
}

.in-view .semantic-comment-3 {
    animation: commentSlideInVertical 1s cubic-bezier(0.16, 1, 0.3, 1) 2.4s forwards;
}

/* Fade out class for smooth reset */
.semantic-comment.fading-out {
    opacity: 0 !important;
    transform: translateY(8px) !important;
    transition: opacity 0.5s ease-in, transform 0.5s ease-in !important;
}

@keyframes commentSlideInVertical {
    0% {
        opacity: 0;
        transform: translateY(-8px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Legacy horizontal animation for backwards compatibility */
@keyframes commentSlideIn {
    0% {
        opacity: 0;
        transform: translateX(-20px);
    }

    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Phase transitions - triggered when section is in view */
.semantic-phase-1 {
    opacity: 1;
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.semantic-phase-2,
.semantic-phase-3 {
    opacity: 0;
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.in-view .semantic-phase-1 {
    animation: phaseOut 0.6s cubic-bezier(0.16, 1, 0.3, 1) 2s forwards;
}

.in-view .semantic-phase-2 {
    animation: phaseIn 0.7s cubic-bezier(0.16, 1, 0.3, 1) 2.4s forwards, phaseOut 0.6s cubic-bezier(0.16, 1, 0.3, 1) 3.8s forwards;
}

.in-view .semantic-phase-3 {
    animation: phaseIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) 4.2s forwards;
}

/* Fade out class for smooth phase reset */
.semantic-phase.fading-out {
    opacity: 0 !important;
    transform: translateY(-4px) !important;
    transition: opacity 0.4s ease-in, transform 0.4s ease-in !important;
}

@keyframes phaseIn {
    0% {
        opacity: 0;
        transform: translateY(6px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes phaseOut {
    to {
        opacity: 0;
        transform: translateY(-6px);
    }
}

/* Threat Detection Glow - Subtle breathing effect */
@keyframes threatGlow {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
    }

    50% {
        box-shadow: 0 0 20px -5px rgba(239, 68, 68, 0.2);
    }
}

/* Alert animations DISABLED */
/* Threat badge now static */

/* Scanning Line Effect */
@keyframes scanLine {
    0% {
        top: 0;
        opacity: 0;
    }

    10% {
        opacity: 0.6;
    }

    90% {
        opacity: 0.6;
    }

    100% {
        top: 100%;
        opacity: 0;
    }
}

/* Horizontal Scan Line for Intelligence Bar */
.in-view .semantic-scan-horizontal {
    animation: scanLineHorizontal 3s ease-in-out infinite;
}

@keyframes scanLineHorizontal {

    0%,
    100% {
        opacity: 0.3;
        background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.3), transparent);
    }

    50% {
        opacity: 0.8;
        background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.6), transparent);
    }
}

/* Full Animation Loop Reset - Removed abrupt opacity changes */
.semantic-feed {
    /* Animation loop handled by JS for smoother control */
    opacity: 1;
    transition: opacity 0.5s ease-out;
}

.semantic-feed.fading-out {
    opacity: 0;
    transition: opacity 0.5s ease-in;
}

/* ========================================
   VIRAL VIDEO ANIMATIONS
   ======================================== */

/* Viral Glow Effect - Pulsing ambient light */
.in-view .viral-glow {
    animation: viralGlowPulse 3s ease-in-out infinite;
}

@keyframes viralGlowPulse {

    0%,
    100% {
        opacity: 0.2;
        transform: scale(1);
    }

    50% {
        opacity: 0.4;
        transform: scale(1.1);
    }
}

/* Burning Effect Animation */
.in-view .viral-burn-effect {
    animation: burnEffect 2s ease-in-out infinite;
}

@keyframes burnEffect {

    0%,
    100% {
        background-position: 0% 50%;
        opacity: 0.5;
    }

    50% {
        background-position: 100% 50%;
        opacity: 0.8;
    }
}

/* View Counter Animation */
.in-view .view-counter {
    animation: viewCountGlow 2s ease-in-out infinite;
}

@keyframes viewCountGlow {

    0%,
    100% {
        text-shadow: 0 0 0 transparent;
    }

    50% {
        text-shadow: 0 0 8px rgba(249, 115, 22, 0.5);
    }
}

/* Velocity Flash Animation */
.in-view .velocity-flash {
    animation: velocityFlash 1s ease-in-out 1.5s infinite;
}

@keyframes velocityFlash {

    0%,
    100% {
        color: rgb(251, 146, 60);
        text-shadow: 0 0 0 transparent;
    }

    50% {
        color: rgb(249, 115, 22);
        text-shadow: 0 0 10px rgba(249, 115, 22, 0.6);
    }
}

/* Crash Alert Icon */
.in-view .crash-alert-icon {
    animation: crashAlertFlash 0.5s ease-in-out 1.5s;
}

@keyframes crashAlertFlash {

    0%,
    100% {
        filter: drop-shadow(0 0 0 transparent);
    }

    25%,
    75% {
        filter: drop-shadow(0 0 8px rgba(249, 115, 22, 0.8));
    }

    50% {
        filter: drop-shadow(0 0 12px rgba(249, 115, 22, 1));
    }
}

/* TikTok Clickbait Pulse */
.in-view .tiktok-clickbait-text {
    animation: clickbaitPulse 3s ease-in-out infinite;
}

@keyframes clickbaitPulse {

    0%,
    100% {
        filter: drop-shadow(0 0 4px rgba(239, 68, 68, 0.4));
    }

    50% {
        filter: drop-shadow(0 0 12px rgba(239, 68, 68, 0.7));
    }
}

/* ========================================
   TEXT & BLOCK ANIMATIONS
   ======================================== */

/* Text and block animations DISABLED */
.text-content-block {
    opacity: 1;
    transform: none;
}

.animation-block {
    opacity: 1;
    transform: none;
}

/* ========================================
   KONTROLA SECTION ANIMATIONS
   ======================================== */

/* Dynamic Glow Animations */
.kontrola-glow-1 {
    animation: glowPulse1 8s ease-in-out infinite;
}

.kontrola-glow-2 {
    animation: glowPulse2 10s ease-in-out infinite 2s;
}

.kontrola-glow-3 {
    animation: glowPulse3 9s ease-in-out infinite 4s;
}

.kontrola-glow-4 {
    animation: glowPulse4 7s ease-in-out infinite 1s;
}

@keyframes glowPulse1 {

    0%,
    100% {
        opacity: 0.8;
        transform: translate(-50%, 0) scale(1);
    }

    50% {
        opacity: 1;
        transform: translate(-50%, 0) scale(1.1);
    }
}

@keyframes glowPulse2 {

    0%,
    100% {
        opacity: 0.6;
        transform: scale(1);
    }

    50% {
        opacity: 0.9;
        transform: scale(1.15);
    }
}

@keyframes glowPulse3 {

    0%,
    100% {
        opacity: 0.5;
        transform: scale(1);
    }

    50% {
        opacity: 0.85;
        transform: scale(1.12);
    }
}

@keyframes glowPulse4 {

    0%,
    100% {
        opacity: 0.6;
        transform: scale(1);
    }

    50% {
        opacity: 0.95;
        transform: scale(1.08);
    }
}

/* Kontrola Animation Block Slide In */
@keyframes kontrolaAnimBlockSlideIn {
    from {
        opacity: 0;
        transform: translateX(30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes kontrolaAnimBlockSlideInReverse {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Kontrola Text Fade In */
@keyframes kontrolaTextFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Kontrola Mobile Slide In */
@keyframes kontrolaMobileSlideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Progress Bar Animation on Reveal */
#inteligencija .reveal-on-scroll.visible .bg-red-500,
#inteligencija .reveal-on-scroll.visible .bg-cyan-500,
#inteligencija .reveal-on-scroll.visible .bg-indigo-600 {
    animation: barFillIn 1.5s ease-out forwards;
}

@keyframes barFillIn {
    from {
        transform: scaleX(0);
        transform-origin: left;
    }

    to {
        transform: scaleX(1);
        transform-origin: left;
    }
}

/* Intent Card Pulse Animation */
#inteligencija .animate-pulse {
    animation: intentPulse 2s ease-in-out infinite;
}

@keyframes intentPulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

/* Tab Glow Pulse Animation */
.kontrola-tab.active::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 9999px;
    background: inherit;
    opacity: 0;
    animation: tab-glow-pulse 2s ease-in-out infinite;
    pointer-events: none;
}

@keyframes tab-glow-pulse {

    0%,
    100% {
        opacity: 0;
        transform: scale(1);
    }

    50% {
        opacity: 0.3;
        transform: scale(1.05);
    }
}

/* ========================================
   HERO ANIMATION KEYFRAMES
   ======================================== */

/* Hero section - activated when in-view */
.hero-section.in-view .floating-particles .floating-particle.chaos {
    animation: particleChaos 4s ease-in-out infinite;
}

.hero-section.in-view .progress-stepper {
    animation: fadeInUp 0.4s ease 0.2s forwards;
}

/* Card Reveal from Singularity */
@keyframes cardRevealFromSingularity {
    0% {
        opacity: 0;
        transform: translate(-50%, -55%) scale(0);
        filter: blur(20px);
    }

    40% {
        opacity: 1;
        filter: blur(8px);
    }

    100% {
        opacity: 1;
        transform: translate(-50%, -55%) scale(1);
        filter: blur(0);
    }
}

/* Bloom Flash */
.card-bloom.active {
    animation: bloomFlash 0.6s ease-out forwards;
}

@keyframes bloomFlash {
    0% {
        opacity: 0;
        transform: translate(-50%, -55%) scale(0.5);
    }

    30% {
        opacity: 1;
        transform: translate(-50%, -55%) scale(1);
    }

    100% {
        opacity: 0;
        transform: translate(-50%, -55%) scale(1.2);
    }
}

/* Sheen Sweep */
.summary-card.visible .summary-inner-v2::after {
    animation: sheenSweep 0.7s cubic-bezier(0.4, 0, 0.2, 1) 0.4s forwards;
}

@keyframes sheenSweep {
    0% {
        left: -100%;
        opacity: 1;
    }

    100% {
        left: 200%;
        opacity: 1;
    }
}

/* Singularity Pulse */
@keyframes singularityPulse {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow:
            0 0 8px rgba(99, 102, 241, 0.8),
            0 0 16px rgba(99, 102, 241, 0.5),
            0 0 24px rgba(99, 102, 241, 0.3);
    }

    50% {
        transform: translate(-50%, -50%) scale(1.3);
        box-shadow:
            0 0 12px rgba(99, 102, 241, 1),
            0 0 24px rgba(99, 102, 241, 0.7),
            0 0 36px rgba(99, 102, 241, 0.4);
    }
}

/* Singularity Absorb */
.singularity-dot.absorbing {
    animation: singularityAbsorb 0.4s ease-in-out infinite;
}

@keyframes singularityAbsorb {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow:
            0 0 10px rgba(99, 102, 241, 1),
            0 0 20px rgba(99, 102, 241, 0.8),
            0 0 30px rgba(99, 102, 241, 0.5);
    }

    50% {
        transform: translate(-50%, -50%) scale(1.5);
        box-shadow:
            0 0 15px rgba(99, 102, 241, 1),
            0 0 30px rgba(99, 102, 241, 0.9),
            0 0 45px rgba(99, 102, 241, 0.6);
    }
}

/* Particle Animations */
.floating-particle.chaos {
    animation: particleChaos 4s ease-in-out infinite;
}

.floating-particle.focus {
    animation: particleFocus 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards !important;
}

@keyframes particleChaos {

    0%,
    100% {
        opacity: 0.3;
        transform: translate(0, 0);
    }

    25% {
        opacity: 0.5;
        transform: translate(10px, -15px);
    }

    50% {
        opacity: 0.4;
        transform: translate(-8px, 12px);
    }

    75% {
        opacity: 0.6;
        transform: translate(15px, 8px);
    }
}

@keyframes particleFocus {
    0% {
        opacity: 0.5;
    }

    80% {
        opacity: 0.9;
    }

    100% {
        opacity: 0;
        left: 50% !important;
        top: 50% !important;
        transform: translate(-50%, -50%) scale(0);
    }
}

/* Singularity Burst */
.singularity-flash.active {
    animation: singularityBurst 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes singularityBurst {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
    }

    50% {
        width: 120px;
        height: 120px;
        opacity: 0.8;
    }

    100% {
        width: 200px;
        height: 200px;
        opacity: 0;
    }
}

/* Heartbeat Pulse Ring */
.step-dot.active::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #6366F1;
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.5;
    animation: pulse-ring 1.5s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
    z-index: -1;
}

@keyframes pulse-ring {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.5;
    }

    100% {
        transform: translate(-50%, -50%) scale(3);
        opacity: 0;
    }
}

/* ========================================
   ANIMATION 2 - AMBER PARTICLE VARIANTS
   ======================================== */

/* Amber Floating Particles */
.floating-particles-amber .floating-particle {
    background: rgba(245, 158, 11, 0.4);
}

.floating-particles-amber .floating-particle.chaos {
    animation: particleChaosAmber 4s ease-in-out infinite;
}

.floating-particles-amber .floating-particle.focus {
    animation: particleFocusAmber 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards !important;
}

@keyframes particleChaosAmber {

    0%,
    100% {
        opacity: 0.3;
        transform: translate(0, 0);
        background: rgba(245, 158, 11, 0.4);
    }

    25% {
        opacity: 0.5;
        transform: translate(10px, -15px);
        background: rgba(251, 191, 36, 0.5);
    }

    50% {
        opacity: 0.4;
        transform: translate(-8px, 12px);
        background: rgba(245, 158, 11, 0.4);
    }

    75% {
        opacity: 0.6;
        transform: translate(15px, 8px);
        background: rgba(251, 191, 36, 0.6);
    }
}

@keyframes particleFocusAmber {
    0% {
        opacity: 0.5;
        background: rgba(245, 158, 11, 0.5);
    }

    80% {
        opacity: 0.9;
        background: rgba(251, 191, 36, 0.9);
    }

    100% {
        opacity: 0;
        left: 50% !important;
        top: 50% !important;
        transform: translate(-50%, -50%) scale(0);
    }
}

/* Amber Stepper Pulse Ring */
.progress-stepper-amber .step-dot.active::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #F59E0B;
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.5;
    animation: pulse-ring-amber 1.5s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
    z-index: -1;
}

@keyframes pulse-ring-amber {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.5;
    }

    100% {
        transform: translate(-50%, -50%) scale(3);
        opacity: 0;
    }
}

/* Active node subtle pulse */
.precision-timeline .border-indigo-500 {
    animation: subtleNodePulse 3s ease-in-out infinite;
}

@keyframes subtleNodePulse {

    0%,
    100% {
        box-shadow: 0 0 6px rgba(99, 102, 241, 0.5);
    }

    50% {
        box-shadow: 0 0 10px rgba(99, 102, 241, 0.7);
    }
}

/* ========================================
   UTILITY ANIMATIONS
   ======================================== */

@keyframes logo-pulse {

    0%,
    100% {
        transform: scale(1);
        filter: drop-shadow(0 0 15px rgba(99, 102, 241, 0.6));
    }

    50% {
        transform: scale(1.03);
        filter: drop-shadow(0 0 22px rgba(99, 102, 241, 0.9));
    }
}

@keyframes orbit-1 {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@keyframes orbit-2 {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@keyframes orbit-3 {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@keyframes orbit-dot-1 {
    from {
        transform: rotate(0deg) translateX(40px) rotate(0deg);
    }

    to {
        transform: rotate(360deg) translateX(40px) rotate(-360deg);
    }
}

/* ========================================
   BERTIC SECTION STACK LAYER ANIMATIONS
   ======================================== */

/* Initially hidden */
.stack-layer-1,
.stack-layer-2,
.stack-layer-3 {
    opacity: 0;
    transform: translateY(20px);
}

/* Animate when parent section is in view */
.in-view .stack-layer-1 {
    animation: textFadeIn 0.3s ease-out 0.05s forwards;
}

.in-view .stack-layer-2 {
    animation: textFadeIn 0.3s ease-out 0.12s forwards;
}

.in-view .stack-layer-3 {
    animation: textFadeIn 0.3s ease-out 0.2s forwards;
}

@keyframes orbit-dot-2 {
    from {
        transform: rotate(120deg) translateX(55px) rotate(-120deg);
    }

    to {
        transform: rotate(480deg) translateX(55px) rotate(-480deg);
    }
}

@keyframes orbit-dot-3 {
    from {
        transform: rotate(240deg) translateX(75px) rotate(-240deg);
    }

    to {
        transform: rotate(-120deg) translateX(75px) rotate(120deg);
    }
}

@keyframes glow-pulse {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.5;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.15);
        opacity: 0.9;
    }
}

@keyframes stream-down {
    0% {
        opacity: 0;
        transform: translateY(-8px);
    }

    50% {
        opacity: 0.7;
    }

    100% {
        opacity: 0;
        transform: translateY(8px);
    }
}

@keyframes progress-slide {
    0% {
        width: 0%;
        margin-left: 0;
    }

    50% {
        width: 60%;
        margin-left: 20%;
    }

    100% {
        width: 0%;
        margin-left: 100%;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

@keyframes particleFade {
    0% {
        opacity: 1;
        transform: translate(0, 0) scale(1);
    }

    100% {
        opacity: 0;
        transform: translate(var(--tx), var(--ty)) scale(0);
    }
}

/* ========================================
   EARLY WARNING SPECIFIC ANIMATIONS
   ======================================== */

/* Alert Pulse Animation */
.alert-pulse {
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
    0% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(239, 68, 68, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
    }
}

/* Simulation Stage */
#simulation-stage {
    margin-top: 3rem;
    position: relative;
}

/* Floating Comment Animation */
.floating-comment {
    position: absolute;
    opacity: 0;
    transform: scale(0.8) translateY(20px);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    max-width: 340px;
    z-index: 20;
}

.floating-comment.visible {
    opacity: 1;
    transform: scale(1) translateY(0);
}

.floating-comment.exit {
    opacity: 0;
    transform: scale(0.8) translateY(-50px);
}

/* Phone Mockup Animation */
.phone-mockup {
    transform: translateY(120%);
    transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.phone-mockup.active {
    transform: translateY(0);
}

/* Notification Banner Animation */
.notification-banner {
    transform: translateY(-150%);
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.notification-banner.active {
    transform: translateY(0);
}

/* Early Warning Radar Scanner - Override for simulation */
#simulation-stage .radar-sweep {
    width: 150vmax;
    height: 150vmax;
    background: conic-gradient(from 0deg, transparent 0deg, transparent 280deg, rgba(99, 102, 241, 0.1) 360deg);
    animation: radarSpin 8s linear infinite;
    mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
}

@keyframes radarSpin {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

/* Progress Bar for Loop */
.loop-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    background: #4F46E5;
    width: 0%;
    transition: width 0.1s linear;
    z-index: 60;
}

/* Phase Card Styles */
.phase-card {
    background: rgba(11, 13, 23, 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.phase-card:hover {
    transform: translateY(-5px);
    border-color: rgba(239, 68, 68, 0.4);
    box-shadow: 0 10px 40px -10px rgba(239, 68, 68, 0.15);
}

.phase-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(239, 68, 68, 0.5), transparent);
}

/* Viz Icon Wrapper */
.viz-icon-wrapper {
    width: 50px;
    height: 50px;
    background: radial-gradient(circle at center, rgba(239, 68, 68, 0.15), transparent 70%);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ef4444;
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.1);
}

/* ========================================
   OPPORTUNITY DETECTION ANIMATIONS
   ======================================== */

/* Emerald Radar Sweep */
.radar-emerald {
    background: conic-gradient(from 0deg,
            transparent 0deg,
            transparent 340deg,
            rgba(16, 185, 129, 0.08) 355deg,
            rgba(16, 185, 129, 0.15) 360deg) !important;
}

/* Card Glow Emerald */
.card-glow-emerald {
    box-shadow:
        0 0 20px rgba(16, 185, 129, 0.15),
        0 0 40px rgba(16, 185, 129, 0.08),
        0 0 0 1px rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3) !important;
}

.card-glow-emerald:hover {
    box-shadow:
        0 0 30px rgba(16, 185, 129, 0.2),
        0 0 60px rgba(16, 185, 129, 0.12),
        0 0 0 1px rgba(16, 185, 129, 0.2);
}

/* Opportunity Card Animation */
.opportunity-card {
    transition: all 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.opportunity-card.active {
    animation: opportunityPulse 3s ease-in-out infinite;
}

@keyframes opportunityPulse {

    0%,
    100% {
        box-shadow:
            0 0 30px rgba(16, 185, 129, 0.2),
            0 0 60px rgba(16, 185, 129, 0.1);
    }

    50% {
        box-shadow:
            0 0 50px rgba(16, 185, 129, 0.3),
            0 0 100px rgba(16, 185, 129, 0.15);
    }
}

/* Positive Comment Metric Styling */
.card-metrics .value.positive {
    color: #10b981;
}

.card-metrics .value.neutral {
    color: #94a3b8;
}

/* Emerald Alert Pulse */
.alert-pulse-emerald {
    animation: pulse-emerald 2s infinite;
}

@keyframes pulse-emerald {
    0% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}

/* Opportunity Card Inner Glow */
.opportunity-card .card-glow-emerald::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.5), transparent);
}

/* Amber Highlight for Stats */
.text-amber-400 {
    text-shadow: 0 0 8px rgba(251, 191, 36, 0.3);
}

/* Viz Icon Wrapper Emerald Variant */
.viz-icon-emerald {
    background: radial-gradient(circle at center, rgba(16, 185, 129, 0.15), transparent 70%) !important;
    border: 1px solid rgba(16, 185, 129, 0.2) !important;
    color: #10b981 !important;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.1) !important;
}

/* Phase Card Emerald Border Hover */
.phase-card.border-emerald-500\/20:hover {
    border-color: rgba(16, 185, 129, 0.4) !important;
    box-shadow: 0 10px 40px -10px rgba(16, 185, 129, 0.15) !important;
}

.phase-card.border-emerald-500\/20::before {
    background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.5), transparent) !important;
}

/* ========================================
   AMBER/GOLD OPPORTUNITY ANIMATIONS
   ======================================== */

/* Amber Alert Pulse */
.alert-pulse-amber {
    animation: pulse-amber 2s infinite;
}

@keyframes pulse-amber {
    0% {
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.4);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(245, 158, 11, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0);
    }
}

/* Card Glow Amber - Subtle Version */
.card-glow-amber-subtle {
    box-shadow:
        0 0 0 1px rgba(245, 158, 11, 0.05),
        0 10px 30px -10px rgba(245, 158, 11, 0.1);
    transition: box-shadow 0.5s ease, transform 0.3s ease;
}

.card-glow-amber-subtle:hover {
    box-shadow:
        0 0 0 1px rgba(245, 158, 11, 0.1),
        0 15px 40px -10px rgba(245, 158, 11, 0.15);
}

/* Viz Icon Wrapper Amber Variant */
.viz-icon-amber {
    background: radial-gradient(circle at center, rgba(245, 158, 11, 0.15), transparent 70%) !important;
    border: 1px solid rgba(245, 158, 11, 0.2) !important;
    color: #F59E0B !important;
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.1) !important;
}

/* Phase Card Amber Border Hover */
.phase-card.border-amber-500\/20:hover {
    border-color: rgba(245, 158, 11, 0.4) !important;
    box-shadow: 0 10px 40px -10px rgba(245, 158, 11, 0.15) !important;
}

.phase-card.border-amber-500\/20::before {
    background: linear-gradient(90deg, transparent, rgba(245, 158, 11, 0.5), transparent) !important;
}

/* Singularity Amber Variant */
.singularity-amber {
    background: radial-gradient(circle, #F59E0B 0%, #D97706 100%);
    box-shadow:
        0 0 8px rgba(245, 158, 11, 0.8),
        0 0 16px rgba(245, 158, 11, 0.5),
        0 0 24px rgba(245, 158, 11, 0.3);
    animation: singularityPulseAmber 2s ease-in-out infinite;
}

@keyframes singularityPulseAmber {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow:
            0 0 8px rgba(245, 158, 11, 0.8),
            0 0 16px rgba(245, 158, 11, 0.5),
            0 0 24px rgba(245, 158, 11, 0.3);
    }

    50% {
        transform: translate(-50%, -50%) scale(1.3);
        box-shadow:
            0 0 12px rgba(245, 158, 11, 1),
            0 0 24px rgba(245, 158, 11, 0.7),
            0 0 36px rgba(245, 158, 11, 0.4);
    }
}

.singularity-amber.absorbing {
    animation: singularityAbsorbAmber 0.4s ease-in-out infinite;
}

@keyframes singularityAbsorbAmber {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow:
            0 0 10px rgba(245, 158, 11, 1),
            0 0 20px rgba(245, 158, 11, 0.8),
            0 0 30px rgba(245, 158, 11, 0.5);
    }

    50% {
        transform: translate(-50%, -50%) scale(1.5);
        box-shadow:
            0 0 15px rgba(245, 158, 11, 1),
            0 0 30px rgba(245, 158, 11, 0.9),
            0 0 45px rgba(245, 158, 11, 0.6);
    }
}

/* Singularity Flash Amber */
.singularity-flash-amber.active {
    background: radial-gradient(circle, rgba(245, 158, 11, 0.8) 0%, rgba(245, 158, 11, 0) 70%);
    animation: singularityBurstAmber 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes singularityBurstAmber {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
    }

    50% {
        width: 120px;
        height: 120px;
        opacity: 0.8;
    }

    100% {
        width: 200px;
        height: 200px;
        opacity: 0;
    }
}

/* Card Bloom Amber */
.card-bloom-amber {
    background: radial-gradient(circle, rgba(245, 158, 11, 0.4) 0%, rgba(245, 158, 11, 0) 70%);
}

.card-bloom-amber.active {
    animation: bloomFlashAmber 0.6s ease-out forwards;
}

@keyframes bloomFlashAmber {
    0% {
        opacity: 0;
        transform: translate(-50%, -55%) scale(0.5);
    }

    30% {
        opacity: 1;
        transform: translate(-50%, -55%) scale(1);
    }

    100% {
        opacity: 0;
        transform: translate(-50%, -55%) scale(1.2);
    }
}

/* Step Dot Amber Variant */
.step-dot-amber {
    background: #1E1B4B;
    border: 2px solid #374151;
    transition: all 0.3s ease;
}

.step-dot-amber.active {
    background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
    border-color: #F59E0B;
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.5);
}

.step-dot-amber.active::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #F59E0B;
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.5;
    animation: pulse-ring-amber 1.5s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
    z-index: -1;
}

@keyframes pulse-ring-amber {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.5;
    }

    100% {
        transform: translate(-50%, -50%) scale(3);
        opacity: 0;
    }
}

.step-dot-amber.completed {
    background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
    border-color: #F59E0B;
}

/* Connector Fill Amber */
.connector-fill-amber {
    background: linear-gradient(90deg, #F59E0B 0%, #FBBF24 100%);
}

.connector-fill-amber.active {
    width: 100%;
}

/* Summary Inner Amber */
.summary-inner-amber {
    border-color: rgba(245, 158, 11, 0.2) !important;
    box-shadow:
        0 25px 80px -20px rgba(245, 158, 11, 0.25),
        0 0 0 1px rgba(245, 158, 11, 0.1);
}

.summary-inner-amber::after {
    background: linear-gradient(90deg, transparent, rgba(245, 158, 11, 0.4), transparent);
}

/* Highlight Amber for text */
.highlight-amber {
    color: #FBBF24;
    font-weight: 600;
}

/* ========================================
   SIMPLE PROGRESS BAR
   ======================================== */

.simple-progress-bar {
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 88%;
    max-width: 300px;
    z-index: 100;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.5s forwards;
    background: rgba(10, 10, 15, 0.95);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 8px 12px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 640px) {
    .simple-progress-bar {
        bottom: 16px;
        width: 320px;
        padding: 12px 20px;
    }
}

.progress-labels {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.progress-label {
    font-size: 10px;
    font-weight: 600;
    color: rgba(148, 163, 184, 0.4);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.4s ease;
}

@media (min-width: 640px) {
    .progress-label {
        font-size: 9px;
    }
}

.progress-label.active {
    color: #FBBF24;
    text-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
}

.progress-label.completed {
    color: rgba(245, 158, 11, 0.7);
}

.progress-track {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #F59E0B 0%, #FBBF24 100%);
    border-radius: 2px;
    transition: width 0.6s ease-in-out;
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.5);
}

/* Progress states */
.progress-fill.step-1 {
    width: 16.66%;
}

.progress-fill.step-2 {
    width: 50%;
}

.progress-fill.step-3 {
    width: 100%;
}

/* ========================================
   COMMENT STORM ANIMATIONS
   ======================================== */

/* Storm Comments Container */
.storm-comments-container {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

/* ========================================
   MOBILE: Single Card Carousel (default)
   ======================================== */

/* Individual Storm Comment - Mobile First */
.storm-comment {
    position: absolute;
    width: 92%;
    max-width: 340px;
    left: 50%;
    top: 45%;
    transform: translate(-50%, -50%) scale(0.9);
    opacity: 0;
    transition: all 0.4s ease-out;
    z-index: 10;
}

/* Mobile: All comments stack in center, only visible ones show */
.storm-comment:nth-child(1) {
    z-index: 20;
}

.storm-comment:nth-child(2) {
    z-index: 19;
}

.storm-comment:nth-child(3) {
    z-index: 18;
}

.storm-comment:nth-child(4) {
    z-index: 17;
}

.storm-comment:nth-child(5) {
    z-index: 16;
}

.storm-comment:nth-child(6) {
    z-index: 15;
}

.storm-comment:nth-child(7) {
    z-index: 14;
}

.storm-comment:nth-child(8) {
    z-index: 13;
}

.storm-comment:nth-child(9) {
    z-index: 12;
}

.storm-comment:nth-child(10) {
    z-index: 11;
}

/* Mobile Storm In - Card slides in from bottom with clear visibility */
.storm-comment.storm-in {
    animation: mobileStormIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes mobileStormIn {
    0% {
        opacity: 0;
        transform: translate(-50%, 40%) scale(0.85);
    }

    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

/* Mobile: Previous cards fade out and move up */
.storm-comment.mobile-fade-out {
    animation: mobileFadeOut 0.2s ease-out forwards;
}

@keyframes mobileFadeOut {
    0% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }

    100% {
        opacity: 0;
        transform: translate(-50%, -90%) scale(0.7);
    }
}

/* Mobile Gather */
.storm-comment.gather {
    animation: mobileGather 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes mobileGather {
    0% {
        opacity: 1;
    }

    100% {
        opacity: 0.3;
        transform: translate(-50%, -50%) scale(0.15) !important;
        filter: blur(4px);
    }
}

/* Mobile Storm Out */
.storm-comment.storm-out {
    animation: mobileStormOut 0.2s ease-in forwards;
}

@keyframes mobileStormOut {
    0% {
        opacity: 0.3;
        filter: blur(4px);
    }

    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0) !important;
        filter: blur(10px);
    }
}

/* ========================================
   DESKTOP: Circular/Scattered Layout
   ======================================== */

@media (min-width: 768px) {
    .storm-comment {
        width: 260px;
        max-width: none;
        left: auto;
        transform: scale(0.7);
    }

    /* Desktop: Circular/scattered positions around center */
    /* Using polar coordinates converted to percentages */
    .storm-comment:nth-child(1) {
        top: 5%;
        left: 8%;
        transform: rotate(-8deg) scale(0.65);
    }

    .storm-comment:nth-child(2) {
        top: 3%;
        left: 38%;
        transform: rotate(3deg) scale(0.7);
    }

    .storm-comment:nth-child(3) {
        top: 8%;
        right: 5%;
        left: auto;
        transform: rotate(6deg) scale(0.68);
    }

    .storm-comment:nth-child(4) {
        top: 35%;
        left: 2%;
        transform: rotate(-5deg) scale(0.72);
    }

    .storm-comment:nth-child(5) {
        top: 30%;
        right: 2%;
        left: auto;
        transform: rotate(4deg) scale(0.7);
    }

    .storm-comment:nth-child(6) {
        top: 55%;
        left: 5%;
        transform: rotate(-3deg) scale(0.68);
    }

    .storm-comment:nth-child(7) {
        top: 50%;
        right: 8%;
        left: auto;
        transform: rotate(7deg) scale(0.65);
    }

    .storm-comment:nth-child(8) {
        bottom: 18%;
        left: 15%;
        top: auto;
        transform: rotate(-6deg) scale(0.7);
    }

    .storm-comment:nth-child(9) {
        bottom: 12%;
        left: 42%;
        top: auto;
        transform: rotate(2deg) scale(0.72);
    }

    .storm-comment:nth-child(10) {
        bottom: 20%;
        right: 10%;
        left: auto;
        top: auto;
        transform: rotate(-4deg) scale(0.68);
    }

    /* Desktop Storm In - Swirling/circular motion */
    .storm-comment.storm-in {
        animation: none;
    }

    .storm-comment:nth-child(1).storm-in {
        animation: desktopStormIn1 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    .storm-comment:nth-child(2).storm-in {
        animation: desktopStormIn2 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    .storm-comment:nth-child(3).storm-in {
        animation: desktopStormIn3 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    .storm-comment:nth-child(4).storm-in {
        animation: desktopStormIn4 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    .storm-comment:nth-child(5).storm-in {
        animation: desktopStormIn5 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    .storm-comment:nth-child(6).storm-in {
        animation: desktopStormIn6 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    .storm-comment:nth-child(7).storm-in {
        animation: desktopStormIn7 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    .storm-comment:nth-child(8).storm-in {
        animation: desktopStormIn8 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    .storm-comment:nth-child(9).storm-in {
        animation: desktopStormIn9 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    .storm-comment:nth-child(10).storm-in {
        animation: desktopStormIn10 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

    /* Swirling animations - coming from outside with rotation */
    @keyframes desktopStormIn1 {
        0% {
            opacity: 0;
            transform: translate(-150%, -50%) rotate(-25deg) scale(0.3);
        }

        60% {
            transform: translate(10%, 10%) rotate(5deg) scale(0.7);
        }

        100% {
            opacity: 1;
            transform: rotate(-8deg) scale(0.65);
            left: 8%;
            top: 5%;
        }
    }

    @keyframes desktopStormIn2 {
        0% {
            opacity: 0;
            transform: translate(0, -150%) rotate(15deg) scale(0.3);
        }

        60% {
            transform: translate(-5%, 15%) rotate(-3deg) scale(0.75);
        }

        100% {
            opacity: 1;
            transform: rotate(3deg) scale(0.7);
            left: 38%;
            top: 3%;
        }
    }

    @keyframes desktopStormIn3 {
        0% {
            opacity: 0;
            transform: translate(150%, -30%) rotate(20deg) scale(0.3);
        }

        60% {
            transform: translate(-15%, 5%) rotate(-5deg) scale(0.72);
        }

        100% {
            opacity: 1;
            transform: rotate(6deg) scale(0.68);
            right: 5%;
            top: 8%;
        }
    }

    @keyframes desktopStormIn4 {
        0% {
            opacity: 0;
            transform: translate(-150%, 20%) rotate(-18deg) scale(0.3);
        }

        60% {
            transform: translate(20%, -10%) rotate(8deg) scale(0.76);
        }

        100% {
            opacity: 1;
            transform: rotate(-5deg) scale(0.72);
            left: 2%;
            top: 35%;
        }
    }

    @keyframes desktopStormIn5 {
        0% {
            opacity: 0;
            transform: translate(150%, 10%) rotate(22deg) scale(0.3);
        }

        60% {
            transform: translate(-20%, 5%) rotate(-6deg) scale(0.74);
        }

        100% {
            opacity: 1;
            transform: rotate(4deg) scale(0.7);
            right: 2%;
            top: 30%;
        }
    }

    @keyframes desktopStormIn6 {
        0% {
            opacity: 0;
            transform: translate(-150%, 40%) rotate(-15deg) scale(0.3);
        }

        60% {
            transform: translate(15%, -15%) rotate(5deg) scale(0.72);
        }

        100% {
            opacity: 1;
            transform: rotate(-3deg) scale(0.68);
            left: 5%;
            top: 55%;
        }
    }

    @keyframes desktopStormIn7 {
        0% {
            opacity: 0;
            transform: translate(150%, 30%) rotate(18deg) scale(0.3);
        }

        60% {
            transform: translate(-10%, -5%) rotate(-8deg) scale(0.68);
        }

        100% {
            opacity: 1;
            transform: rotate(7deg) scale(0.65);
            right: 8%;
            top: 50%;
        }
    }

    @keyframes desktopStormIn8 {
        0% {
            opacity: 0;
            transform: translate(-120%, 100%) rotate(-20deg) scale(0.3);
        }

        60% {
            transform: translate(10%, -20%) rotate(6deg) scale(0.74);
        }

        100% {
            opacity: 1;
            transform: rotate(-6deg) scale(0.7);
            left: 15%;
            bottom: 18%;
        }
    }

    @keyframes desktopStormIn9 {
        0% {
            opacity: 0;
            transform: translate(0, 150%) rotate(12deg) scale(0.3);
        }

        60% {
            transform: translate(5%, -25%) rotate(-4deg) scale(0.76);
        }

        100% {
            opacity: 1;
            transform: rotate(2deg) scale(0.72);
            left: 42%;
            bottom: 12%;
        }
    }

    @keyframes desktopStormIn10 {
        0% {
            opacity: 0;
            transform: translate(120%, 100%) rotate(16deg) scale(0.3);
        }

        60% {
            transform: translate(-15%, -15%) rotate(-7deg) scale(0.72);
        }

        100% {
            opacity: 1;
            transform: rotate(-4deg) scale(0.68);
            right: 10%;
            bottom: 20%;
        }
    }

    /* Desktop Gather - Spiral into center */
    .storm-comment.gather {
        animation: desktopGather 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    }

    @keyframes desktopGather {
        0% {
            opacity: 1;
        }

        50% {
            opacity: 0.8;
            transform: translate(-50%, -50%) rotate(180deg) scale(0.4) !important;
        }

        100% {
            opacity: 0.5;
            transform: translate(-50%, -50%) rotate(360deg) scale(0.2) !important;
            left: 50% !important;
            top: 50% !important;
            right: auto !important;
            bottom: auto !important;
            filter: blur(3px);
        }
    }

    /* Desktop Storm Out */
    .storm-comment.storm-out {
        animation: desktopStormOut 0.25s ease-in forwards;
    }

    @keyframes desktopStormOut {
        0% {
            opacity: 0.5;
            filter: blur(3px);
        }

        100% {
            opacity: 0;
            transform: translate(-50%, -50%) rotate(540deg) scale(0) !important;
            filter: blur(10px);
        }
    }
}

/* ========================================
   LARGE DESKTOP: Even more spread out
   ======================================== */

@media (min-width: 1024px) {
    .storm-comment {
        width: 260px;
    }

    .storm-comment:nth-child(1) {
        top: 3%;
        left: 5%;
    }

    .storm-comment:nth-child(2) {
        top: 2%;
        left: 35%;
    }

    .storm-comment:nth-child(3) {
        top: 5%;
        right: 3%;
    }

    .storm-comment:nth-child(4) {
        top: 32%;
        left: 0%;
    }

    .storm-comment:nth-child(5) {
        top: 28%;
        right: 0%;
    }

    .storm-comment:nth-child(6) {
        top: 58%;
        left: 3%;
    }

    .storm-comment:nth-child(7) {
        top: 52%;
        right: 5%;
    }

    .storm-comment:nth-child(8) {
        bottom: 15%;
        left: 12%;
    }

    .storm-comment:nth-child(9) {
        bottom: 8%;
        left: 40%;
    }

    .storm-comment:nth-child(10) {
        bottom: 18%;
        right: 8%;
    }
}

/* ========================================
   CARD STYLING (All Sizes)
   ======================================== */

/* Make cards inside storm comments smaller */
.storm-comment .post-card-v2 {
    padding: 10px;
    font-size: 0.9em;
}

.storm-comment .card-header {
    margin-bottom: 6px;
    gap: 8px;
}

.storm-comment .card-icon {
    width: 24px;
    height: 24px;
}

.storm-comment .card-title {
    font-size: 11px;
}

.storm-comment .card-meta {
    font-size: 9px;
}

.storm-comment .card-text {
    font-size: 11px;
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
    -webkit-line-clamp: 2;
}

.storm-comment .card-footer {
    display: none;
}

@media (min-width: 768px) {
    .storm-comment .post-card-v2 {
        padding: 10px;
        font-size: 0.85em;
    }

    .storm-comment .card-header {
        margin-bottom: 8px;
        gap: 10px;
    }

    .storm-comment .card-icon {
        width: 28px;
        height: 28px;
    }

    .storm-comment .card-title {
        font-size: 11px;
    }

    .storm-comment .card-meta {
        font-size: 9px;
    }

    .storm-comment .card-text {
        font-size: 10px;
        margin-bottom: 6px;
        padding-bottom: 6px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }
}

@media (min-width: 1024px) {
    .storm-comment .post-card-v2 {
        padding: 12px;
    }

    .storm-comment .card-icon {
        width: 28px;
        height: 28px;
    }

    .storm-comment .card-title {
        font-size: 12px;
    }

    .storm-comment .card-meta {
        font-size: 10px;
    }

    .storm-comment .card-text {
        font-size: 12px;
    }
}

/* ========================================
   PURPLE/VIOLET NARRATIVE ANALYSIS ANIMATIONS
   ======================================== */

/* Purple Floating Particles */
.floating-particles-purple .floating-particle {
    background: rgba(139, 92, 246, 0.4);
}

.floating-particles-purple .floating-particle.chaos {
    animation: particleChaosPurple 4s ease-in-out infinite;
}

.floating-particles-purple .floating-particle.focus {
    animation: particleFocusPurple 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards !important;
}

@keyframes particleChaosPurple {

    0%,
    100% {
        opacity: 0.3;
        transform: translate(0, 0);
        background: rgba(139, 92, 246, 0.4);
    }

    25% {
        opacity: 0.5;
        transform: translate(10px, -15px);
        background: rgba(167, 139, 250, 0.5);
    }

    50% {
        opacity: 0.4;
        transform: translate(-8px, 12px);
        background: rgba(139, 92, 246, 0.4);
    }

    75% {
        opacity: 0.6;
        transform: translate(15px, 8px);
        background: rgba(167, 139, 250, 0.6);
    }
}

@keyframes particleFocusPurple {
    0% {
        opacity: 0.5;
        background: rgba(139, 92, 246, 0.5);
    }

    80% {
        opacity: 0.9;
        background: rgba(167, 139, 250, 0.9);
    }

    100% {
        opacity: 0;
        left: 50% !important;
        top: 50% !important;
        transform: translate(-50%, -50%) scale(0);
    }
}

/* Purple Stepper Pulse Ring */
.progress-stepper-purple .step-dot.active::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #8B5CF6;
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.5;
    animation: pulse-ring-purple 1.5s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
    z-index: -1;
}

@keyframes pulse-ring-purple {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.5;
    }

    100% {
        transform: translate(-50%, -50%) scale(3);
        opacity: 0;
    }
}

/* Card Glow Purple - Subtle Version */
.card-glow-purple-subtle {
    box-shadow:
        0 0 0 1px rgba(139, 92, 246, 0.05),
        0 10px 30px -10px rgba(139, 92, 246, 0.1);
    transition: box-shadow 0.5s ease, transform 0.3s ease;
}

.card-glow-purple-subtle:hover {
    box-shadow:
        0 0 0 1px rgba(139, 92, 246, 0.1),
        0 15px 40px -10px rgba(139, 92, 246, 0.15);
}

/* Singularity Purple Variant */
.singularity-purple {
    background: radial-gradient(circle, #8B5CF6 0%, #7C3AED 100%);
    box-shadow:
        0 0 8px rgba(139, 92, 246, 0.8),
        0 0 16px rgba(139, 92, 246, 0.5),
        0 0 24px rgba(139, 92, 246, 0.3);
    animation: singularityPulsePurple 2s ease-in-out infinite;
}

@keyframes singularityPulsePurple {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow:
            0 0 8px rgba(139, 92, 246, 0.8),
            0 0 16px rgba(139, 92, 246, 0.5),
            0 0 24px rgba(139, 92, 246, 0.3);
    }

    50% {
        transform: translate(-50%, -50%) scale(1.3);
        box-shadow:
            0 0 12px rgba(139, 92, 246, 1),
            0 0 24px rgba(139, 92, 246, 0.7),
            0 0 36px rgba(139, 92, 246, 0.4);
    }
}

.singularity-purple.absorbing {
    animation: singularityAbsorbPurple 0.4s ease-in-out infinite;
}

@keyframes singularityAbsorbPurple {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow:
            0 0 10px rgba(139, 92, 246, 1),
            0 0 20px rgba(139, 92, 246, 0.8),
            0 0 30px rgba(139, 92, 246, 0.5);
    }

    50% {
        transform: translate(-50%, -50%) scale(1.5);
        box-shadow:
            0 0 15px rgba(139, 92, 246, 1),
            0 0 30px rgba(139, 92, 246, 0.9),
            0 0 45px rgba(139, 92, 246, 0.6);
    }
}

/* Singularity Flash Purple */
.singularity-flash-purple.active {
    background: radial-gradient(circle, rgba(139, 92, 246, 0.8) 0%, rgba(139, 92, 246, 0) 70%);
    animation: singularityBurstPurple 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes singularityBurstPurple {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
    }

    50% {
        width: 120px;
        height: 120px;
        opacity: 0.8;
    }

    100% {
        width: 200px;
        height: 200px;
        opacity: 0;
    }
}

/* Card Bloom Purple */
.card-bloom-purple {
    background: radial-gradient(circle, rgba(139, 92, 246, 0.4) 0%, rgba(139, 92, 246, 0) 70%);
}

.card-bloom-purple.active {
    animation: bloomFlashPurple 0.6s ease-out forwards;
}

@keyframes bloomFlashPurple {
    0% {
        opacity: 0;
        transform: translate(-50%, -55%) scale(0.5);
    }

    30% {
        opacity: 1;
        transform: translate(-50%, -55%) scale(1);
    }

    100% {
        opacity: 0;
        transform: translate(-50%, -55%) scale(1.2);
    }
}

/* Summary Inner Purple */
.summary-inner-purple {
    border-color: rgba(139, 92, 246, 0.2) !important;
    box-shadow:
        0 25px 80px -20px rgba(139, 92, 246, 0.25),
        0 0 0 1px rgba(139, 92, 246, 0.1);
}

.summary-inner-purple::after {
    background: linear-gradient(90deg, transparent, rgba(139, 92, 246, 0.4), transparent);
}

/* Highlight Purple for text */
.highlight-purple {
    color: #A78BFA;
    font-weight: 600;
}

/* Progress Stepper Purple Theme */
.progress-stepper-purple .step-dot {
    background: #1E1B4B;
    border: 2px solid #374151;
    transition: all 0.3s ease;
}

.progress-stepper-purple .step-dot.active {
    background: linear-gradient(135deg, #8B5CF6 0%, #7C3AED 100%);
    border-color: #8B5CF6;
    box-shadow: 0 0 12px rgba(139, 92, 246, 0.5);
}

.progress-stepper-purple .step-dot.completed {
    background: linear-gradient(135deg, #8B5CF6 0%, #7C3AED 100%);
    border-color: #8B5CF6;
}

.progress-stepper-purple .step-label.active {
    color: #A78BFA;
}

.progress-stepper-purple .step-label.completed {
    color: rgba(139, 92, 246, 0.7);
}

.progress-stepper-purple .connector-fill.active {
    background: linear-gradient(90deg, #8B5CF6 0%, #A78BFA 100%);
    width: 100%;
}

/* Mobile: Ensure progress stepper stays visible below summary card */
@media (max-width: 767px) {
    .progress-stepper-purple {
        z-index: 60 !important;
        bottom: 12px;
        background: rgba(10, 10, 12, 0.95);
        border: 1px solid rgba(139, 92, 246, 0.25);
    }
}

/* ========================================
   NARRATIVE CONFLICT SUMMARY CARD STYLES
   Professional Design with Sheen Effect
   ======================================== */

.narrative-summary-card {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -55%) scale(0);
    opacity: 0;
    width: 92%;
    max-width: 850px;
    z-index: 50;
    pointer-events: none;
    will-change: transform, opacity, filter;
    transform-origin: center center;
}

.narrative-summary-card.visible {
    opacity: 1;
    pointer-events: auto;
    animation: cardRevealFromSingularity 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

/* Mobile positioning */
@media (max-width: 767px) {
    .narrative-summary-card {
        top: 46%;
        transform: translate(-50%, -50%) scale(0);
        width: 92%;
        max-width: 360px;
    }
}

@media (max-width: 400px) {
    .narrative-summary-card {
        top: 44%;
        width: 96%;
        max-width: none;
    }
}

.narrative-summary-inner {
    position: relative;
    z-index: 50;
    background: rgba(13, 13, 15, 0.98);
    border: 1px solid rgba(139, 92, 246, 0.25);
    border-radius: 16px;
    overflow: hidden;
    box-shadow:
        0 25px 60px -15px rgba(139, 92, 246, 0.35),
        0 15px 35px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(139, 92, 246, 0.1) inset,
        0 0 80px -20px rgba(139, 92, 246, 0.2);
    transition: all 0.3s ease;
}

/* Top accent line - purple gradient */
.narrative-summary-inner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg,
            #8B5CF6 0%,
            #A78BFA 50%,
            rgba(139, 92, 246, 0.3) 100%);
    z-index: 5;
}

/* THE SHEEN EFFECT - Diagonal light sweep */
.narrative-summary-inner::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(105deg,
            transparent 0%,
            transparent 40%,
            rgba(255, 255, 255, 0.04) 45%,
            rgba(255, 255, 255, 0.08) 50%,
            rgba(255, 255, 255, 0.04) 55%,
            transparent 60%,
            transparent 100%);
    pointer-events: none;
    z-index: 10;
    opacity: 0;
    border-radius: 16px;
}

/* Sheen animation on visible */
.narrative-summary-card.visible .narrative-summary-inner::after {
    animation: sheenSweep 0.7s cubic-bezier(0.4, 0, 0.2, 1) 0.4s forwards;
}

/* Hover state */
.narrative-summary-inner:hover {
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow:
        0 30px 70px -15px rgba(139, 92, 246, 0.45),
        0 18px 40px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(139, 92, 246, 0.15) inset,
        0 0 100px -20px rgba(139, 92, 246, 0.3);
    transform: translateY(-3px);
}

/* Header Section */
.narrative-summary-header {
    padding: 8px 12px 6px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    background: linear-gradient(180deg, rgba(139, 92, 246, 0.05) 0%, transparent 100%);
}

.narrative-summary-title {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    margin: 0 0 4px 0;
    letter-spacing: -0.01em;
}

.narrative-summary-subtitle {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    margin: 0;
    line-height: 1.4;
}

/* Content Grid - Vertical layout (stacked) */
.narrative-summary-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0;
    align-items: stretch;
}

@media (max-width: 640px) {
    .narrative-summary-content {
        grid-template-columns: 1fr;
        gap: 0;
        padding: 0;
    }

    .narrative-summary-header {
        padding: 18px 20px 16px;
    }

    .narrative-summary-title {
        font-size: 15px;
        letter-spacing: 0.02em;
    }

    .narrative-summary-subtitle {
        font-size: 11px;
        line-height: 1.4;
    }
}

/* Columns - Equal height with stretch */
.narrative-column-left,
.narrative-column-right {
    padding: 8px 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-radius: 0;
    position: relative;
    min-height: auto;
    border: none;
}

/* Left Column - Original message (purple accent) */
.narrative-column-left {
    background: rgba(139, 92, 246, 0.03);
    border-left: 3px solid transparent;
    border-image: linear-gradient(180deg, rgba(139, 92, 246, 0.7), rgba(139, 92, 246, 0.25)) 1;
}

/* Right Column - Public perception (red accent) */
.narrative-column-right {
    background: rgba(239, 68, 68, 0.04);
    border-left: 3px solid transparent;
    border-image: linear-gradient(180deg, rgba(239, 68, 68, 0.8), rgba(239, 68, 68, 0.3)) 1;
}

/* No badge on desktop - clean design */
.narrative-column-right::before {
    display: none;
}

@media (max-width: 640px) {

    .narrative-column-left,
    .narrative-column-right {
        padding: 18px 20px;
        min-height: auto;
        border-image: none;
        border-left: none;
    }

    .narrative-column-left {
        margin-bottom: 0;
    }

    /* Remove accent bars on mobile for cleaner look */
    .narrative-column-left::after,
    .narrative-column-right::after {
        display: none;
    }
}

/* Column Headers - Small labels, not the focus */
.narrative-column-header {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 6px;
    margin-bottom: 6px;
    font-size: 9px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255, 255, 255, 0.35);
    text-align: left;
}

/* Left header - purple tint for brand/company messages */
.narrative-column-header.purple {
    color: rgba(167, 139, 250, 0.7);
}

/* Right header - subtle red/warning tint for public reaction */
.narrative-column-right .narrative-column-header {
    color: rgba(248, 113, 113, 0.8);
}

/* Column Text - Left side (Original message) - More muted, it's the "input" */
.narrative-column-left .narrative-column-text {
    font-size: 14px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.6);
    margin: 0;
    font-weight: 400;
    text-align: left;
}

/* Column Text - Right side (Public reaction) - HIGHLIGHTED, this is the key insight */
.narrative-column-right .narrative-column-text {
    font-size: 16px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.95);
    margin: 0;
    font-weight: 500;
    text-align: left;
}

@media (max-width: 640px) {
    .narrative-column-header {
        margin-bottom: 8px;
        font-size: 9px;
        letter-spacing: 0.12em;
        font-weight: 600;
    }

    .narrative-column-left .narrative-column-text {
        font-size: 12px;
        line-height: 1.55;
    }

    .narrative-column-right .narrative-column-text {
        font-size: 12.5px;
        line-height: 1.55;
    }
}

/* Center Icon - Vertically centered with columns */

.narrative-center-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 10px 0;
    position: relative;
    align-self: center;
}

@media (max-width: 640px) {
    .narrative-center-icon {
        flex-direction: column;
        padding: 10px 0;
    }
}

/* Transform label - Merged Badge Style */
/* Icon is now inside this label */
.narrative-transform-label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 8px;
    font-weight: 600;
    letter-spacing: 0.1em;
    color: rgba(167, 139, 250, 0.85);
    text-transform: uppercase;
    white-space: nowrap;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.12) 0%, rgba(139, 92, 246, 0.06) 100%);
    border: 1px solid rgba(139, 92, 246, 0.2);
    padding: 5px 10px;
    border-radius: 16px;
    backdrop-filter: blur(4px);
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.1);
    position: relative;
    transition: all 0.3s ease;
}

.narrative-transform-label:hover {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.18) 0%, rgba(139, 92, 246, 0.1) 100%);
    border-color: rgba(139, 92, 246, 0.3);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.15);
}

/* Icon inside the label - always vertical (pointing down) */
.narrative-transform-label svg {
    transition: transform 0.3s ease;
    transform: rotate(90deg);
}

.narrative-transform-label:hover svg {
    transform: rotate(90deg) translateY(2px);
}

/* Mobile transform icon */
@media (max-width: 640px) {
    .narrative-transform-label svg {
        transform: rotate(90deg);
    }

    .narrative-transform-label:hover svg {
        transform: rotate(90deg) translateY(2px);
    }
}



/* ========================================
   NARRATIVE ANALYSIS HERO - MOBILE HEIGHT FIX
   Use flexbox for content-aware height on mobile
   ======================================== */

@media (max-width: 767px) {
    #na-hero-container {
        aspect-ratio: unset !important;
        height: auto !important;
        min-height: 480px;
        display: flex;
        flex-direction: column;
        justify-content: flex-end;
        align-items: center;
        padding-bottom: 16px;
        padding-top: 120px;
    }

    /* Adjust storm comment positioning for flex container */
    #na-hero-container .storm-comment {
        top: 35%;
    }

    /* Summary card uses static positioning within flex container */
    #na-hero-container .narrative-summary-card {
        left: auto;
        transform: scale(0);
        width: 92%;
        max-width: 360px;
        margin: 0 auto 16px auto;
        flex-shrink: 0;
    }

    #na-hero-container .narrative-summary-card.visible {
        animation: mobileNaCardRevealFlex 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
        height: 470px;
        margin-top: -70px !important;
    }

    /* Progress stepper uses static position within flex container, always visible below card */
    #na-hero-container .progress-stepper {
        transform: none;
        margin: 0 auto;
        flex-shrink: 0;
    }
}

@keyframes mobileNaCardRevealFlex {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@media (max-width: 480px) {
    #na-hero-container {
        min-height: 460px;
        padding-top: 100px;
    }

    #na-hero-container .narrative-summary-card {
        width: 94%;
        max-width: none;
        top: 0;
        position: relative;
        top: auto;
    }
}

@media (max-width: 380px) {
    #na-hero-container {
        min-height: 480px;
        padding-top: 90px;
    }

    #na-hero-container .narrative-summary-card {
        width: 96%;
    }
}


/* ========================================
   TRANSFORMATION BADGE LAYOUT OVERRIDE
   Fixing mobile layout to be vertical and icon rotation
   ======================================== */

@media (max-width: 640px) {
    .narrative-transform-label {
        flex-direction: column;
        padding: 10px 8px;
        gap: 6px;
        border-radius: 12px;
    }

    .narrative-transform-label svg {
        margin-left: 0 !important;
        transform: rotate(90deg);
    }

    .narrative-transform-label:hover svg {
        transform: rotate(90deg) translateY(2px);
    }
}