/* animations.css */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

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

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

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

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

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

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

@keyframes slideIn {
    from { transform: translateX(-100%); }
    to { transform: translateX(0); }
}

@keyframes slideOut {
    from { transform: translateX(0); }
    to { transform: translateX(100%); }
}

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

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes shimmer {
    0% { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
}

/* فئات الأنيميشن */
.fade-in { animation: fadeIn 0.6s ease; }
.fade-in-up { animation: fadeInUp 0.8s ease; }
.fade-in-down { animation: fadeInDown 0.8s ease; }
.fade-in-left { animation: fadeInLeft 0.8s ease; }
.fade-in-right { animation: fadeInRight 0.8s ease; }

.pulse { animation: pulse 2s infinite; }
.bounce { animation: bounce 2s infinite; }
.float { animation: float 3s ease-in-out infinite; }

.slide-in { animation: slideIn 0.5s ease; }
.slide-out { animation: slideOut 0.5s ease; }

.rotate { animation: rotate 20s linear infinite; }

.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }

.duration-500 { animation-duration: 0.5s; }
.duration-1000 { animation-duration: 1s; }
.duration-1500 { animation-duration: 1.5s; }
.duration-2000 { animation-duration: 2s; }

/* أنيميشن للعناصر */
.hero-title { animation: fadeInUp 1s ease; }
.hero-description { animation: fadeInUp 1s ease 0.2s forwards; opacity: 0; }
.hero-actions { animation: fadeInUp 1s ease 0.4s forwards; opacity: 0; }

.service-card { transition: all 0.3s ease; }
.service-card:hover { transform: translateY(-10px); }

.project-card { transition: all 0.3s ease; }
.project-card:hover { transform: scale(1.05); }

/* أنيميشن للتأكيد */
.highlight { 
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.1), transparent);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

/* أنيميشن للتحميل */
.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* أنيميشن للتنبيه */
.alert-pulse {
    animation: pulse 0.5s ease-in-out;
}

/* أنيميشن للظهور التدريجي */
.stagger-children > * {
    opacity: 0;
    animation: fadeInUp 0.6s ease forwards;
}

.stagger-children > *:nth-child(1) { animation-delay: 0.1s; }
.stagger-children > *:nth-child(2) { animation-delay: 0.2s; }
.stagger-children > *:nth-child(3) { animation-delay: 0.3s; }
.stagger-children > *:nth-child(4) { animation-delay: 0.4s; }
.stagger-children > *:nth-child(5) { animation-delay: 0.5s; }

/* أنيميشن للخطوط */
.typing {
    overflow: hidden;
    white-space: nowrap;
    border-right: 3px solid;
    animation: typing 3.5s steps(40, end), blink-caret 0.75s step-end infinite;
}

@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes blink-caret {
    from, to { border-color: transparent; }
    50% { border-color: #502b78; }
}

/* أنيميشن للخلفيات */
.animated-bg {
    background: linear-gradient(-45deg, #502b78, #8b5cf6, #ec4899, #f59e0b);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
}

/* أنيميشن للشرائح */
.slide-item {
    animation: slideIn 0.5s ease;
}

/* أنيميشن للأيقونات */
.icon-spin {
    animation: rotate 2s linear infinite;
}

.icon-bounce {
    animation: bounce 2s infinite;
}

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

/* أنيميشن للإشعارات */
.notification-in {
    animation: slideIn 0.3s ease;
}

.notification-out {
    animation: slideOut 0.3s ease;
}