html {
    scroll-behavior: smooth;
}

body {
    font-family: Vazirmatn, sans-serif;
    background-color: #e6f9f0;
    background-image: linear-gradient(to right, #a7f3d0 1px, transparent 1px), linear-gradient(to bottom, #a7f3d0 1px, transparent 1px);
    background-size: 20px 20px;
    background-attachment: local; /* Fix for pattern visibility on mobile */
    animation: moveGrid 2s linear infinite;
    padding-top: 120px;
}

.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.03);
}

.gradient-text {
    background: linear-gradient(45deg, #10b981, #059669);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.btn-hover {
    transition: all 0.3s ease;
}

.btn-hover:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.glassmorphism {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.dynamic-island {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 600px;
    border-radius: 50px;
    padding: 10px 20px;
    z-index: 1000;
}

.dynamic-island-stats {
    width: 90%;
    max-width: 900px;
    margin: 0 auto;
    border-radius: 50px;
    padding: 20px;
    background-color: #059669;
    color: white;
}

.timeline-item {
    position: absolute;
    width: 150px;
}

.timeline-content {
    position: relative;
}


@keyframes moveGrid {
    from {
        background-position: 0 0;
    }
    to {
        background-position: 20px -20px;
    }
}

#mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease-in-out;
}

#mobile-menu.open {
  max-height: 250px; /* A height large enough to contain the menu items */
}

/* --- Responsive Adjustments for Mobile --- */

@media (max-width: 480px) {
    /* Adjust hero section text for smaller screens */
    h1.text-4xl {
        font-size: 2.5rem; /* 40px */
        line-height: 1.2;
    }

    /* Reduce padding on the navigation island */
    .dynamic-island {
        padding: 8px 12px;
    }

    /* Make timeline more compact on mobile */
    .timeline-item {
        width: 130px;
    }

    .timeline-content {
        padding: 0.75rem; /* 12px */
    }
}