There's a good evolutionary argument for this. In many pre-modern societies, men coming back from a successful hunt all get laid the night after the feast. Even if the guy didn't catch anything, he gets a sexual reward for trying.

This is probably why young men associate being nice with pleasant sexual outcomes: because for several million years, doing a service that benefits the entire group of men who perform the service absolutely was rewarded with sex, even if the guy was the ugliest person in the tribe.

Human males are an incredibly simple mechanism. They will joyously risk their lives and health for the tribe, and in return for this huge sacrifice, the tribe just has to ensure that a part of his groin gets massaged by another tribe member (usually of the opposite sex) a couple times a month.

Men who exist under this simple deal are always happy. Modern society violates this deal. A small proportion of men get all the sex they can handle, yet are not required to perform any service for anybody but themselves.

This basic "hunt for the tribe in the morning, get your sexual reward in the evening" dynamic is replicated across the globe in hunter gatherer communities, from tundra to prairie to jungle to river delta. It's almost certainly how all of our male ancestors lived from around 2000BC TO 1,000,000BC.

The most egregious example of the misery caused by modenity's betrayal of that basic sexual social contract is, of course, the Islamic world. See how the young men of Islam happily volunteer to annihilate themselves in horrifying numbers.

But it's still visible here in the West, and these subreddits are a great demonstration of it.