You're looking for balance of "saving the world" (i.e. our responsibility with civilization and all lifeforms) and "enjoy your life". Clearly if everyone is concerned exclusively with enjoying their lives (i.e. hyper-hedonism), society collapses; that's deeply irresponsible. If everyone is also hyper-focused on self-propagation of our species with zero regard to our actual experience as conscious beings with rich inner lives, then clearly there's the risk of indeed making our inner lives much worse than they could be.
A system I've seen recommended here to think about it is (I've seen it related to Ikigai, a Japanese concept): you need to find a balance between your needs and experience, your skills and potential, and what's good for society at large (in a soft max-min).
I think overall, however, if we give it a little thought it's easy to find something aligned with our interests and potential that can really make a good impact. If you're interested I recommend the Effective Altruism community for a take on this (they're largely focused on more tangible things like Earning to Give) and 80000 hours. In all likelihood, just by being a functional member of our society (and giving what you can), if you don't work for some obviously evil enterprise (idk, making hyper-addictive things, oil field discovery, or something like that), you're probably helping society.
I encourage a different path as well: if you can program (or develop technology) and you're entrepreneurial (many people around here?) you can most likely make something that will make a good impact on society and even civilization at large. Furthering education with online tools, making educational games (or otherwise that promote growth and reflection), making tools more accessible, ... , improving the robustness and reliability of our systems, ..., the list goes on -- why not fulfill your potential to the best you can? Invent the future, Hack the planet.