Human evolution actually escaped the trap of this short term thinking twice: first some 100k years ago, when altruism bloomed (see E O Wilson), and some 2500 years ago with the universal moralistic religions.
The group that maximizes their long-term reproduction is the one that inherits the earth.