// Simple scroll animation

window.addEventListener("scroll", function() {
    let elements = document.querySelectorAll(".card, .work-item, .service-box");

    elements.forEach(el => {
        let position = el.getBoundingClientRect().top;
        let screenHeight = window.innerHeight;

        if (position < screenHeight - 50) {
            el.style.opacity = "1";
            el.style.transform = "translateY(0)";
        }
    });
});

// Initial hidden state
document.querySelectorAll(".card, .work-item, .service-box").forEach(el => {
    el.style.opacity = "0";
    el.style.transform = "translateY(50px)";
    el.style.transition = "0.5s";
});