The upside to sex (not gender) based attraction is reproduction, the fundamental drive of all life. Some forms of life, such as fungi, have more than two sexes, though they are only compatible with certain other sexes for reproduction. In humans, this becomes a little less relevant, as we are able to overcome the drive to reproduce even while maintaining the drive for sexual activity. There are still people that have a strong reproductive urge, however.
The upside to sex (not gender) based attraction is reproduction, the fundamental drive of all life. Some forms of life, such as fungi, have more than two sexes, though they are only compatible with certain other sexes for reproduction. In humans, this becomes a little less relevant, as we are able to overcome the drive to reproduce even while maintaining the drive for sexual activity. There are still people that have a strong reproductive urge, however.