biological sex is a complex, dynamic ,
developmental process with multiple parts. It is not a single , unitary , measure, into which all bodies can be meaningfully categorised into one of two mutually exclusive options.
Yes, there is a powerful binary which underlies sex-development processes , and this can be used as an approximation for classifying the majority of bodies, but this is not an absolute.
Nor would I say that sex is a “spectrum”. Assuming that everything can be classified either as a “binary” or a “spectrum” is another over simplification/ example of binary, black and white thinking.
Biological sex is complex, and just as there is not one single , unitary measure that can defined biological sex, biological sex does not absolutely define gender.
Yes biological sex is an important part of the picture, and for most people gender identity will develop as predicted by biological sex, (just as , for most people , biological sex will develop as predicted by karyotype). For some people, however, this is not the case.
We do not yet understand the aetiology of gender variant development, current science and scientific technologies have not taken us that far. That does not mean that gender is “not real” or a “personal belief” etc. we dont know the aetiology of many many conditions, that we also can’t objective test
for or externally “observe” , that doesn’t mean they aren’t real. ASC for example.