Is this still active here?
Because I have issues about the transgender and the sex change spell. They don't make a lot of sense to me, as they are now.
The transgender spell basically seems to change the gender identity of the target. In the description it says, that an affected person will "adapt hair styles, clothing, manners, speech, and behaviors appropriate to his newly perceived outlook...".
This is only half of the truth. IRL, transsexual people almost always also try to alter their body (by hormones, surgery etc.).
In a world where magic exists, TS people (either natural or "made" by this spell) will also most likely seek out some kind of polymorph magic to make the body match the soul. The sex change spell can help here, or a well-known belt.
It might be noted that this can become a major goal in a character's life and a great motivator. It is in RL, after all.
It could also be noted that another casting of this spell might "cure" this condition (unless it's a species with more than two genders, then it's still random).
The sex change spell says the following: "Most likely, it will take the victim some time to get used to their new form, the social expectations thereof, etc."
That won't happen. The spell doesn't change the personality of the target (very few polymorphing spells actually do that), so the gender identity remains the same. That means, the character will most likely behave like under the influence of the transgender spell, unless it was TS before (in that case, it should also be immune to the confusion/insanity effect).
I suggest to put it in line with the baleful polymorph spell: If the subject remains in the new form for 24 consecutive hours, it must attempt a Will save. If the save fails, the spell also changes the gender identity of the target and it actually believes it belongs to the new gender. If the target already has the identity of the new form, it can voluntary fail the save. In that case, nothing happens.