Detect navbar position upon resize