There are two sexes.
Sex is biological.
Gender, like race, is subjective.
Gender is a grammatical term that refers to nouns and adverbs. People have a sex; they do not have a gender.