/* Fade In Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.8s ease forwards;
}

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

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

/* Floating Animation */
@keyframes floating {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-15px);
    }
}

.floating {
    animation: floating 6s ease-in-out infinite;
}

/* Gradient Background Animation */
@keyframes gradientBG {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

.gradient-bg {
    background: linear-gradient(-45deg, var(--primary), var(--secondary), var(--accent));
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
}

/* Bounce Animation */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* Skill Card Hover Animation */
.skill-card:hover .skill-icon {
    animation: bounce 0.5s ease;
    color: var(--accent);
}

/* Project Card Hover Effects */
.project-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px var(--shadow);
}

.project-image {
    position: relative;
    overflow: hidden;
}

.project-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-card:hover .project-image::after {
    opacity: 1;
}

.project-image img {
    transition: transform 0.5s ease;
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

/* Button Hover Effects */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, 
        transparent, 
        rgba(255, 255, 255, 0.2), 
        transparent);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.btn:hover::after {
    transform: translateX(100%);
}

/* Section Title Underline Animation */
.section-title {
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 80px;
    height: 4px;
    background: linear-gradient(to right, var(--primary), var(--secondary));
    border-radius: 2px;
    transform-origin: center;
    transition: transform 0.5s ease;
}

.section-header:hover .section-title::after {
    transform: translateX(-50%) scaleX(1);
}

/* Theme Toggle Animation */
.theme-toggle i {
    transition: all 0.3s ease;
}

/* Scroll To Top Button Animation */
.scroll-top {
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
}

.scroll-top.active {
    opacity: 1;
    visibility: visible;
}

.scroll-top:hover {
    transform: translateY(-5px) scale(1.1);
}

/* Social Link Hover Animation */
.social-link {
    transition: all 0.3s ease;
}

.social-link:hover {
    transform: translateY(-3px) scale(1.1);
}

/* Image Border Animation */
.image-border-animation {
    animation: rotateBorder 4s linear infinite;
}

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