Add mouse-leave event to close the dropdown