/* Animations - @keyframes for all transitions and effects */

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        pointer-events: none;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes markerPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    }
    50% {
        transform: scale(1.15);
        box-shadow: 0 6px 20px rgba(196, 154, 108, 0.5);
    }
}

@keyframes userPulse {
    0%, 100% {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3),
            0 0 0 4px rgba(66, 133, 244, 0.4);
    }
    50% {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3),
            0 0 0 12px rgba(66, 133, 244, 0.2);
    }
}

@keyframes arrowPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* Apply animations */
.location-status {
    animation: slideDown 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.poem-overlay {
    animation: fadeIn 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.poem-card {
    animation: slideUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.marker-current {
    animation: markerPulse 2s infinite;
}

.user-location {
    animation: userPulse 2s infinite;
}

.nav-arrow {
    animation: arrowPulse 1.5s infinite;
}

.loading {
    animation: fadeOut 0.5s 1s forwards;
}

.loading-spinner {
    animation: spin 1s linear infinite;
}

.route-completed {
    animation: fadeIn 0.5s;
}
