Add check to prevent infobox from overlapping nav