It's Schroeder's Law
When can you legally be bothered female and a man? If your father has a title and you are female.
This means that sex ALWAYS remains visible and that gender can not replace sex. Other it would be impossible to make this distinction.
It's a tiny part of the act, but it's also the part that means gender reassignment is not a replacement for sex. It can only be in addition to sex.
Of course there are other practical implications if you replace sex with gender reassignment - which negatively impact multiple groups - INCLUDING trans people.
If legally a trans woman is a female then legally a doctor has to treat you in line with that. Otherwise they put themselves at risk. But if they treat them in line with being female then this could be negligence because you know you are not giving adequate and equal quality of treatment. Thus you could be legally liable.
It's incoherence in putting people into impossible situations is why I firmly believe we will at worst get caveats.