nav state now falls back to cookies if localstorage is unavailable