* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    min-height: 100vh;
    overflow-x: hidden;
    color: #fff;
}

/* Animated background particles */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 3px;
    height: 3px;
    background: rgba(139, 92, 246, 0.5);
    border-radius: 50%;
    animation: float 20s infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    90% {
        opacity: 1;
    }

    50% {
        transform: translate(var(--tx), var(--ty)) scale(1.5);
    }
}

/* Gradient orbs */
.orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    animation: pulse 8s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

.orb1 {
    width: 400px;
    height: 400px;
    background: linear-gradient(45deg, #8b5cf6, #ec4899);
    top: -200px;
    left: -200px;
    animation-delay: 0s;
}

.orb2 {
    width: 500px;
    height: 500px;
    background: linear-gradient(45deg, #3b82f6, #8b5cf6);
    bottom: -250px;
    right: -250px;
    animation-delay: 4s;
}

.orb3 {
    width: 350px;
    height: 350px;
    background: linear-gradient(45deg, #ec4899, #f59e0b);
    top: 50%;
    left: 50%;
    animation-delay: 2s;
}

@keyframes pulse {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    50% {
        transform: translate(50px, -50px) scale(1.2);
    }
}

.container {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* Header with glitch effect */
.header {
    text-align: center;
    margin-bottom: 80px;
    padding-top: 60px;
}

.logo-wrapper {
    position: relative;
    display: inline-block;
    margin-bottom: 20px;
}

.logo {
    font-size: 5rem;
    font-weight: 900;
    background: linear-gradient(45deg, #8b5cf6, #ec4899, #3b82f6, #8b5cf6);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 5s ease infinite, scaleIn 0.8s ease-out;
    letter-spacing: -2px;
    position: relative;
    cursor: default;
}

.logo:hover {
    animation: gradientShift 5s ease infinite, glitch 0.5s infinite;
}

@keyframes gradientShift {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

@keyframes glitch {

    0%,
    100% {
        transform: translate(0);
    }

    20% {
        transform: translate(-2px, 2px);
    }

    40% {
        transform: translate(-2px, -2px);
    }

    60% {
        transform: translate(2px, 2px);
    }

    80% {
        transform: translate(2px, -2px);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.5);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.tagline {
    font-size: 1.4rem;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.3s forwards;
    font-weight: 300;
    letter-spacing: 1px;
}

.typing-container {
    display: inline-block;
    margin-top: 10px;
}

.typing {
    color: #8b5cf6;
    font-family: 'Courier New', monospace;
    font-size: 1rem;
    opacity: 0;
    animation: fadeIn 1s ease-out 0.6s forwards;
}

.cursor {
    display: inline-block;
    width: 2px;
    height: 1em;
    background: #8b5cf6;
    margin-left: 2px;
    animation: blink 1s step-end infinite;
}

@keyframes blink {

    0%,
    50% {
        opacity: 1;
    }

    51%,
    100% {
        opacity: 0;
    }
}

/* Projects grid */
.projects {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin-bottom: 80px;
    perspective: 1000px;
}

.card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 40px;
    border: 1px solid rgba(139, 92, 246, 0.2);
    text-decoration: none;
    color: #fff;
    display: block;
    position: relative;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    opacity: 0;
    animation: fadeInUp 0.8s ease-out forwards;
    transform-style: preserve-3d;
}

.card:nth-child(1) {
    animation-delay: 0.2s;
}

.card:nth-child(2) {
    animation-delay: 0.4s;
}

.card:nth-child(3) {
    animation-delay: 0.6s;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, rgba(139, 92, 246, 0.1), rgba(236, 72, 153, 0.1));
    opacity: 0;
    transition: opacity 0.5s;
}

.card:hover::before {
    opacity: 1;
}

.card:hover {
    transform: translateY(-15px) rotateX(5deg);
    border-color: rgba(139, 92, 246, 0.6);
    box-shadow: 0 30px 60px rgba(139, 92, 246, 0.3),
        0 0 50px rgba(139, 92, 246, 0.2);
}

.card-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.5s;
    pointer-events: none;
}

.card:hover .card-glow {
    opacity: 1;
}

.card-icon {
    font-size: 3.5rem;
    margin-bottom: 20px;
    display: inline-block;
    transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    filter: drop-shadow(0 0 10px rgba(139, 92, 246, 0.5));
}

.card:hover .card-icon {
    transform: scale(1.2) rotate(5deg);
    filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.8));
}

.card-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 15px;
    background: linear-gradient(45deg, #fff, #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.card-description {
    opacity: 0.8;
    line-height: 1.7;
    font-size: 1rem;
    margin-bottom: 20px;
}

.card-url {
    font-size: 0.9rem;
    opacity: 0.6;
    font-family: 'Courier New', monospace;
    padding: 8px 16px;
    background: rgba(139, 92, 246, 0.1);
    border-radius: 8px;
    display: inline-block;
    transition: all 0.3s;
}

.card:hover .card-url {
    opacity: 1;
    background: rgba(139, 92, 246, 0.2);
}

.card-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(139, 92, 246, 0.2);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: 1px solid rgba(139, 92, 246, 0.3);
}

/* Footer */
.footer {
    text-align: center;
    opacity: 0;
    animation: fadeIn 1s ease-out 1s forwards;
    padding-bottom: 40px;
}

.social-links {
    display: flex;
    gap: 25px;
    justify-content: center;
    margin-bottom: 30px;
}

.social-link {
    width: 50px;
    height: 50px;
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #8b5cf6;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    position: relative;
    overflow: hidden;
}

.social-link::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #8b5cf6, #ec4899);
    opacity: 0;
    transition: opacity 0.3s;
}

.social-link:hover::before {
    opacity: 1;
}

.social-link svg {
    position: relative;
    z-index: 1;
    transition: all 0.3s;
}

.social-link:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 10px 25px rgba(139, 92, 246, 0.5);
    border-color: transparent;
}

.social-link:hover svg {
    fill: #fff;
}

.copyright {
    opacity: 0.5;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    opacity: 0;
    animation: fadeIn 1s ease-out 1.2s forwards;
}

.footer-link {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s;
    position: relative;
}

.footer-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: #8b5cf6;
    transition: width 0.3s;
}

.footer-link:hover {
    color: #8b5cf6;
}

.footer-link:hover::after {
    width: 100%;
}

.footer-separator {
    color: rgba(255, 255, 255, 0.3);
    font-size: 0.8rem;
}

/* Scroll indicator */
.scroll-indicator {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    animation: fadeIn 1s ease-out 1.5s forwards, bounce 2s infinite 2s, fadeOut 1s ease-out 5s forwards;
    z-index: 10;
}

.scroll-indicator::before {
    content: '';
    display: block;
    width: 30px;
    height: 50px;
    border: 2px solid rgba(139, 92, 246, 0.5);
    border-radius: 20px;
    position: relative;
}

.scroll-indicator::after {
    content: '';
    position: absolute;
    width: 6px;
    height: 10px;
    background: #8b5cf6;
    border-radius: 3px;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scrollDot 2s infinite;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateX(-50%) translateY(0);
    }

    50% {
        transform: translateX(-50%) translateY(10px);
    }
}

@keyframes scrollDot {
    0% {
        top: 8px;
        opacity: 1;
    }

    100% {
        top: 28px;
        opacity: 0;
    }
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

@media (max-width: 768px) {
    .logo {
        font-size: 3.5rem;
    }

    .tagline {
        font-size: 1.1rem;
    }

    .projects {
        grid-template-columns: 1fr;
    }

    .card {
        padding: 30px;
    }

    .orb1,
    .orb2,
    .orb3 {
        width: 300px;
        height: 300px;
    }

    .footer-links {
        flex-direction: column;
        gap: 10px;
    }

    .footer-separator {
        display: none;
    }
}