/* Animation Classes */
.fade-in {
    animation: fadeIn 1s ease forwards;
}

.slide-up {
    animation: slideUp 0.8s ease forwards;
}

.slide-down {
    animation: slideDown 0.8s ease forwards;
}

.slide-left {
    animation: slideLeft 0.8s ease forwards;
}

.slide-right {
    animation: slideRight 0.8s ease forwards;
}

.zoom-in {
    animation: zoomIn 0.8s ease forwards;
}

.pulse {
    animation: pulse 2s infinite;
}

.delay-1 {
    animation-delay: 0.2s;
}

.delay-2 {
    animation-delay: 0.4s;
}

.delay-3 {
    animation-delay: 0.6s;
}

.delay-4 {
    animation-delay: 0.8s;
}

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

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

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

@keyframes slideLeft {
    from { 
        opacity: 0;
        transform: translateX(50px);
    }
    to { 
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideRight {
    from { 
        opacity: 0;
        transform: translateX(-50px);
    }
    to { 
        opacity: 1;
        transform: translateX(0);
    }
}

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

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

/* Hero Section Animations */
.hero-title {
    animation: slideDown 1s ease forwards;
}

.hero-subtitle {
    animation: slideDown 1s ease forwards 0.3s;
    opacity: 0;
}

.hero-buttons {
    animation: fadeIn 1s ease forwards 0.6s;
    opacity: 0;
}

/* Service Card Hover Animations */
.service-card:hover .service-icon {
    animation: pulse 1s ease;
}

/* Button Hover Animations */
.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.btn:active {
    transform: translateY(-1px);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
}

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

.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

/* Form Field Focus Animations */
.form-group input:focus, 
.form-group textarea:focus {
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(0, 86, 179, 0.1);
}

/* Page Transition Animations */
.page-transition {
    animation: fadeIn 0.5s ease forwards;
}

/* Special Elements */
.highlight-box {
    position: relative;
}

.highlight-box::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    animation: highlightPulse 3s infinite;
    opacity: 0;
}

@keyframes highlightPulse {
    0% { opacity: 0; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(1.02); }
    100% { opacity: 0; transform: scale(1); }
}

/* Responsive Animations */
@media (max-width: 768px) {
    .slide-left, .slide-right {
        animation-name: slideUp;
    }
}