/* ===== Custom Styles for Tailwind ===== */

/* Navbar scroll effect */
.navbar.scrolled {
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

/* Nav link active state */
.nav-link.active {
    color: #6366f1;
}

.nav-link.active::after {
    width: 100%;
}

/* Mobile menu */
@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        background: white;
        flex-direction: column;
        padding: 30px;
        gap: 20px;
        box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
        transition: all 0.3s ease;
    }

    .nav-menu.active {
        left: 0;
    }

    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }
}

/* Scroll animations */
.service-card,
.project-card,
.feature-item,
.info-item,
.ai-card {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.service-card.animate-in,
.project-card.animate-in,
.feature-item.animate-in,
.info-item.animate-in,
.ai-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

/* Back to top button */
.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* RotateY animation for service icons */
.service-icon {
    transform-style: preserve-3d;
    transition: transform 0.6s ease;
}

.service-card:hover .service-icon {
    transform: rotateY(360deg);
}

/* Smooth fade-in for code window */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.window-content code {
    opacity: 0;
    animation: fadeIn 1s ease forwards;
    animation-delay: 0.5s;
}

/* Tech icons stagger animation */
.tech-icons span {
    opacity: 0;
    transform: scale(0);
    transition: all 0.3s ease;
}

.tech-icons span.animated {
    opacity: 1;
    transform: scale(1);
}
