Refactor navigation bar