    megaMenuTrigger.addEventListener('mouseleave', function () {
        timeout = setTimeout(() => {
          // Additional cleanup if needed
        }, 300);
      });
    }
  });

  // Initialize Lucide icons after content loads
  document.addEventListener('DOMContentLoaded', function() {
    if (typeof lucide !== 'undefined') {
        lucide.createIcons();
    }
});
</script>
{% endblock %}

{% block extra_js %}
{{ block.super }}
{% endblock %}