﻿@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
    --primary: #3b82f6;
    --secondary: #8b5cf6;
    --dark: #0f172a;
    --light: #f8fafc;
    --gray: #94a3b8;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--dark);
    color: var(--light);
    overflow-x: hidden;
    scroll-behavior: smooth;
}

.perspective-container {
    perspective: 1000px;
}

.card-3d {
    transform-style: preserve-3d;
    transition: transform 250ms ease, box-shadow 0.5s ease;
}

    .card-3d:hover {
        transform: rotateY(0deg) rotateX(5deg);
        box-shadow: 0 25px 70px -12px rgba(59, 130, 246, 0.25);
    }

.floating {
    animation: floating 6s ease-in-out infinite;
}

@keyframes floating {
    0% {
        transform: translateY(0px) rotate(0deg);
    }

    50% {
        transform: translateY(-15px) rotate(2deg);
    }

    100% {
        transform: translateY(0px) rotate(0deg);
    }
}

.skill-bar {
    transition: width 1.5s ease-in-out;
    transform-origin: left;
}

.project-card {
    transform-style: preserve-3d;
    transition: all 0.5s ease;
}

    .project-card:hover {
        transform: translateY(-10px) rotateY(5deg) scale(1.02);
        box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    }

.gradient-text {
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    position: relative;
}

.gradient-bg {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.glow {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.5);
}

.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.nav-link {
    position: relative;
}

    .nav-link::after {
        content: '';
        position: absolute;
        bottom: -5px;
        left: 0;
        width: 0;
        height: 2px;
        background: linear-gradient(90deg, var(--primary), var(--secondary));
        transition: width 0.3s ease;
    }

    .nav-link:hover::after {
        width: 100%;
    }

.typewriter {
    overflow: hidden;
    border-right: .15em solid var(--primary);
    white-space: nowrap;
    animation: typing 3.5s steps(40, end), blink-caret .75s step-end infinite;
}

@keyframes typing {
    from {
        width: 0
    }

    to {
        width: 100%
    }
}

@keyframes blink-caret {
    from, to {
        border-color: transparent
    }

    50% {
        border-color: var(--primary)
    }
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
 }

.animate-scroll {
    animation: scroll 18s linear infinite;
    display: flex;
    width: max-content;
}

/* وقف الحركة عند hover */
.skills-row:hover {
    animation-play-state: paused;
}

#particles-js {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 0;
}

.content-wrapper {
    position: relative;
    z-index: 1;
}

.progress-path {
    position: relative;
}

    .progress-path::before {
        content: '';
        position: absolute;
        top: 0;
        left: 10px;
        height: 100%;
        width: 2px;
        background: linear-gradient(to bottom, var(--primary), var(--secondary));
    }

.progress-dot {
    position: relative;
    z-index: 2;
}

.timeline-item {
    transition: all 0.3s ease;
}

    .timeline-item:hover {
        transform: translateX(10px);
    }

.btn-hover-effect {
    position: relative;
    overflow: hidden;
    z-index: 1;
}

    .btn-hover-effect::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
        transition: all 0.6s ease;
        z-index: -1;
    }

    .btn-hover-effect:hover::before {
        left: 100%;
    }

.testimonial-card {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

    .testimonial-card.active {
        opacity: 1;
        transform: translateY(0);
    }

.loading-bar {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    z-index: 9999;
    width: 0%;
    transition: width 0.4s ease;
}

/* Skills Animation */
@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.animate-scroll {
    animation: scroll 22s linear infinite;
    display: flex;
    width: max-content;
}
 
/* وقف الحركة عند hover */
.skills-row:hover {
    animation-play-state: paused;
}


/*<!-- ✅ Animation CSS -->*/
.skills-row {
    display: flex;
    width: max-content;
    animation: scroll-left 30s linear infinite;
}

@keyframes scroll-left {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}
