Improve nav behaviour on page resize