refactored main navbar