/* ============================================
   MARKER ANIMATIONS
   ============================================ */

@keyframes markerPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(228, 0, 43, 0.7),
                    0 0 0 0 rgba(228, 0, 43, 0.4);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(228, 0, 43, 0),
                    0 0 0 16px rgba(228, 0, 43, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(228, 0, 43, 0),
                    0 0 0 0 rgba(228, 0, 43, 0);
    }
}

@keyframes markerHover {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.15);
    }
    100% {
        transform: scale(1.25);
    }
}

@keyframes markerSelect {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.35);
    }
}

/* ============================================
   CARD ANIMATIONS
   ============================================ */

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

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

/* ============================================
   MARKER ELEMENT STYLING & ANIMATION CLASSES
   ============================================ */

.marker {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background-color: var(--color-red);
    border: 3px solid var(--color-white);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transform: scale(1);
    transform-origin: center;
    will-change: auto;
}

.marker.pulse {
    animation: markerPulse 2s infinite;
}

.marker.hover:not(.selected) {
    transform: scale(1.2);
}

.marker.selected {
    transform: scale(1.4);
    animation: none;
    pointer-events: none;
}

.marker::before {
    content: '';
    position: absolute;
    width: 3px;
    height: 3px;
    background-color: var(--color-white);
    border-radius: 50%;
    pointer-events: none;
}

/* ============================================
   CARD CLOSING ANIMATION
   ============================================ */

.project-card.closing {
    animation: fadeOut var(--transition-base) forwards;
}

/* ============================================
   LOADING STATE
   ============================================ */

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

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

/* ============================================
   FADE IN
   ============================================ */

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

.fade-in {
    animation: fadeIn var(--transition-base);
}

/* ============================================
   SMOOTH TRANSITIONS
   ============================================ */

.transition-smooth {
    transition: all var(--transition-base);
}

.transition-fast {
    transition: all var(--transition-fast);
}

/* ============================================
   BOUNCE ANIMATION (for future use)
   ============================================ */

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.bounce {
    animation: bounce 0.6s;
}

/* ============================================
   ZOOM ENTER/EXIT
   ============================================ */

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes zoomOut {
    from {
        opacity: 1;
        transform: scale(1);
    }
    to {
        opacity: 0;
        transform: scale(0.9);
    }
}

.zoom-in {
    animation: zoomIn var(--transition-base);
}

.zoom-out {
    animation: zoomOut var(--transition-base);
}
