refactored the navbar