Peter Ling,
The significance of gender to the outcome is uncertain.
Possibly, Hillary Clinton lost because she was an unlikable candidate—the opposite of Bill, who was fantastically likable.
To be voted President, likability is almost essential. Nixon made it.
I invite you to read "Is Kamala Harris More than Cosmetic?"
Many thanks. Best.