/* Advanced Animations */

/* Floating Animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* Pulse Animation */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
}

.animate-pulse {
    animation: pulse 2s ease-in-out infinite;
}

/* Gradient Text Animation */
@keyframes gradient-shift {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

.gradient-text {
    background: linear-gradient(-45deg, #2cb67d, #239a69, #2cb67d, #1a1a2e);
    background-size: 400% 400%;
    animation: gradient-shift 3s ease infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Slide In Animations */
@keyframes slideInLeft {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.slide-in-left {
    animation: slideInLeft 0.8s ease forwards;
}

.slide-in-right {
    animation: slideInRight 0.8s ease forwards;
}

.slide-in-up {
    animation: slideInUp 0.8s ease forwards;
}

/* Hover Effects */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(44, 182, 125, 0.2);
}

.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

/* Glow Effects */
.glow-on-hover {
    transition: all 0.3s ease;
}

.glow-on-hover:hover {
    box-shadow: 0 0 20px rgba(44, 182, 125, 0.5);
}

/* Loading Spinner */
@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top: 2px solid #2cb67d;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Typewriter Cursor */
@keyframes blink {
    0%, 50% {
        opacity: 1;
    }
    51%, 100% {
        opacity: 0;
    }
}

.typewriter-cursor::after {
    content: '|';
    animation: blink 1s infinite;
}

/* Parallax Effect */
.parallax {
    transform: translateZ(0);
    will-change: transform;
}

/* Stagger Animation for Lists */
.stagger-item {
    opacity: 0;
    transform: translateY(20px);
    animation: staggerFadeIn 0.6s ease forwards;
}

.stagger-item:nth-child(1) { animation-delay: 0.1s; }
.stagger-item:nth-child(2) { animation-delay: 0.2s; }
.stagger-item:nth-child(3) { animation-delay: 0.3s; }
.stagger-item:nth-child(4) { animation-delay: 0.4s; }
.stagger-item:nth-child(5) { animation-delay: 0.5s; }

@keyframes staggerFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Morphing Background */
@keyframes morph {
    0%, 100% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    }
    50% {
        border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
    }
}

.morphing-bg {
    background: linear-gradient(45deg, #2cb67d, #239a69);
    animation: morph 8s ease-in-out infinite;
}

/* Text Reveal Animation */
.text-reveal {
    overflow: hidden;
    position: relative;
}

.text-reveal::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #0f0f23;
    animation: textReveal 1.5s ease forwards;
}

@keyframes textReveal {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(100%);
    }
}

/* Bounce Animation */
@keyframes bounce {
    0%, 20%, 53%, 80%, 100% {
        transform: translate3d(0, 0, 0);
    }
    40%, 43% {
        transform: translate3d(0, -30px, 0);
    }
    70% {
        transform: translate3d(0, -15px, 0);
    }
    90% {
        transform: translate3d(0, -4px, 0);
    }
}

.animate-bounce {
    animation: bounce 1s ease;
}

/* Shake Animation */
@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-10px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(10px);
    }
}

.animate-shake {
    animation: shake 0.8s ease;
}

/* Fade In with Scale */
@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.fade-in-scale {
    animation: fadeInScale 0.6s ease forwards;
}

/* Rotate Animation */
@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.animate-rotate {
    animation: rotate 2s linear infinite;
}

/* Wave Animation */
@keyframes wave {
    0%, 100% {
        transform: translateY(0);
    }
    25% {
        transform: translateY(-5px);
    }
    75% {
        transform: translateY(5px);
    }
}

.animate-wave {
    animation: wave 2s ease-in-out infinite;
}

/* Responsive Animations */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Print Styles for Animations */
@media print {
    .animate-float,
    .animate-pulse,
    .animate-bounce,
    .animate-shake,
    .animate-rotate,
    .animate-wave {
        animation: none !important;
    }
}

/* Enhanced About Stats Design */
.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(44, 182, 125, 0.2);
}

.stat-item {
    background: linear-gradient(135deg, rgba(44, 182, 125, 0.1), rgba(255, 107, 107, 0.1));
    border: 2px solid rgba(44, 182, 125, 0.3);
    border-radius: 1.5rem;
    padding: 2rem 1.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    backdrop-filter: blur(10px);
}

.stat-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.6s ease;
}

.stat-item:hover::before {
    left: 100%;
}

.stat-item:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: var(--primary-color);
    box-shadow: 0 15px 30px rgba(44, 182, 125, 0.3);
    background: linear-gradient(135deg, rgba(44, 182, 125, 0.15), rgba(255, 107, 107, 0.15));
}

.stat-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.05) 50%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stat-item:hover::after {
    opacity: 1;
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
    display: block;
    position: relative;
    z-index: 2;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.stat-label {
    color: var(--text-primary);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    z-index: 2;
    opacity: 0.9;
}

/* Stats Icons */
.stat-item:nth-child(1)::before {
    background: linear-gradient(90deg, transparent, rgba(44, 182, 125, 0.2), transparent);
}

.stat-item:nth-child(2)::before {
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.2), transparent);
}

.stat-item:nth-child(3)::before {
    background: linear-gradient(90deg, transparent, rgba(255, 107, 107, 0.2), transparent);
}

/* Responsive Stats */
@media (max-width: 768px) {
    .about-stats {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .stat-item {
        padding: 1.5rem 1rem;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
    .stat-item {
        padding: 1rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
}

/* Additional Animations */
@keyframes glow {
    0%, 100% {
        box-shadow: 0 0 5px rgba(44, 182, 125, 0.3);
    }
    50% {
        box-shadow: 0 0 20px rgba(44, 182, 125, 0.6);
    }
}

.stat-item {
    animation: float 6s ease-in-out infinite;
}

.stat-item:hover {
    animation: glow 2s ease-in-out infinite;
}

/* Gradient Backgrounds for Stats */
.stat-item:nth-child(1) {
    background: linear-gradient(135deg, rgba(44, 182, 125, 0.1), rgba(34, 197, 94, 0.1));
}

.stat-item:nth-child(2) {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(99, 102, 241, 0.1));
}

.stat-item:nth-child(3) {
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.1), rgba(236, 72, 153, 0.1));
}

/* Hover Effects */
.stat-item:hover:nth-child(1) {
    background: linear-gradient(135deg, rgba(44, 182, 125, 0.2), rgba(34, 197, 94, 0.2));
    border-color: #22c55e;
}

.stat-item:hover:nth-child(2) {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(99, 102, 241, 0.2));
    border-color: #3b82f6;
}

.stat-item:hover:nth-child(3) {
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.2), rgba(236, 72, 153, 0.2));
    border-color: #ff6b6b;
}

/* Additional Animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes glow {
    0%, 100% {
        box-shadow: 0 0 5px rgba(44, 182, 125, 0.3);
    }
    50% {
        box-shadow: 0 0 20px rgba(44, 182, 125, 0.6);
    }
}

/* Additional hover effects for cards */
.project-card:hover {
    animation: glow 2s ease-in-out infinite;
}

/* Smooth transitions for all interactive elements */
.btn, .nav-link, .social-link, .project-link {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Enhanced button hover effects */
.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* Card hover animations */
.skill-item:hover {
    animation: float 3s ease-in-out infinite;
}

/* Text gradient animations */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.hero-title {
    background-size: 200% 200%;
    animation: gradientShift 3s ease infinite;
}

/* Loading animations */
@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

.loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shimmer 1.5s infinite;
}

/* Pulse animation for interactive elements */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.btn:active {
    animation: pulse 0.3s ease-in-out;
}

/* Fade in animations */
@keyframes fadeInUp {
    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);
    }
}

/* Apply animations to elements */
.fade-in-up {
    animation: fadeInUp 0.8s ease-out;
}

.fade-in-left {
    animation: fadeInLeft 0.8s ease-out;
}

.fade-in-right {
    animation: fadeInRight 0.8s ease-out;
}

/* Hover effects for social links */
.social-link:hover {
    animation: pulse 0.6s ease-in-out;
}

/* Project card hover effects */
.project-card {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-card:hover {
    transform: translateY(-10px) scale(1.02);
}

/* Skill bar animations */
.skill-bar-fill {
    position: relative;
    overflow: hidden;
}

.skill-bar-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: shimmer 2s infinite;
}

/* Cursor animations */
.cursor-dot {
    transition: transform 0.1s ease;
}

.cursor-outline {
    transition: all 0.3s ease;
}

/* Scroll progress animation */
.scroll-progress {
    transition: width 0.1s ease;
}

/* Form input focus animations */
.form-group input:focus,
.form-group textarea:focus {
    animation: pulse 0.3s ease-in-out;
}

/* Navigation link hover effects */
.nav-link::after {
    transition: width 0.3s ease;
}

/* Button loading state */
.btn.loading {
    position: relative;
    overflow: hidden;
}

.btn.loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 1s infinite;
}

/* Responsive animations */
@media (max-width: 768px) {
    .project-card:hover {
        transform: translateY(-5px) scale(1.01);
    }
    
    .skill-item:hover {
        animation: none;
    }
    
    .btn:hover {
        transform: translateY(-1px);
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Project Card Animations - Simplified */
.project-card {
    transition: all 0.3s ease;
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.project-card .project-overlay {
    transition: opacity 0.3s ease;
}

.project-card .project-content {
    transition: all 0.3s ease;
}

/* Simple transitions for all interactive elements */
.btn, .nav-link, .social-link, .project-link {
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(44, 182, 125, 0.3);
}

.skill-item:hover {
    transform: translateX(5px);
}

/* Gradient Animation for Hero Title */
@keyframes gradientShift {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

.hero-title {
    background: linear-gradient(-45deg, #2cb67d, #239a69, #2cb67d, #1a1a2e);
    background-size: 400% 400%;
    animation: gradientShift 3s ease infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Simple Shimmer Effect for Loading States */
@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

.loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    animation: shimmer 1.5s infinite;
}

/* Simple Pulse Animation */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.btn:active {
    animation: pulse 0.2s ease-in-out;
}

/* Simple Fade In Animations */
@keyframes fadeInUp {
    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);
    }
}

.fade-in-up {
    animation: fadeInUp 0.8s ease forwards;
}

.fade-in-left {
    animation: fadeInLeft 0.8s ease forwards;
}

.fade-in-right {
    animation: fadeInRight 0.8s ease forwards;
}

/* Simple Hover Effects */
.social-link:hover {
    transform: translateY(-3px);
}

.skill-bar-fill {
    transition: width 2s ease;
}

.skill-bar-fill::after {
    animation: shimmer 2s infinite;
}

/* Custom Cursor Animations */
.cursor-dot {
    transition: transform 0.1s ease;
}

.cursor-outline {
    transition: all 0.3s ease;
}

/* Scroll Progress Bar */
.scroll-progress {
    transition: width 0.1s ease;
}

/* Form Input Focus Effects */
.form-group input:focus,
.form-group textarea:focus {
    transform: scale(1.02);
}

/* Navigation Link Hover Effect */
.nav-link::after {
    transition: width 0.3s ease;
}

/* Button Loading State */
.btn.loading {
    position: relative;
    overflow: hidden;
}

.btn.loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    animation: shimmer 1.5s infinite;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .project-card:hover {
        transform: translateY(-5px);
    }
    
    .skill-item:hover {
        transform: none;
    }
    
    .btn:hover {
        transform: none;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
} 