Updated menu code (to enable multi-level submenus)