In the book "On Caring", philosopher Milton Mayeroff wrote: "Through caring for certain others, by serving them through caring, a man lives the meaning of his own life. In the sense in which a man can ever be said to be at home in the world, he is at home not through dominating, or explaining, or appreciating, but through caring and being cared for."

Given you acted to write something, what does it show you care about?

In "thinking about thinking", it is very easy to drift from observations to speculations and from insights to overgeneralizations. A variation on that is something Bertrand Russel suggested, that every philosopher at some point makes an (usually unacknowledged) assumption and then proceeds from there.

Your observation (generalized) that a person's feelings about other people's feelings affect our behavior seems true (especially for parents and children). That is perhaps a variation of the theme in "Descartes' Error: Emotion, Reason, and the Human Brain" by Antonio Damasio that all reason rests on emotion (with emotion giving us a reason to reason)?

Albert Einstein says something similar in "Religion and Science": https://sacred-texts.com/aor/einstein/einsci.htm
"For the scientific method can teach us nothing else beyond how facts are related to, and conditioned by, each other. The aspiration toward such objective knowledge belongs to the highest of which man is capable, and you will certainly not suspect me of wishing to belittle the achievements and the heroic efforts of man in this sphere. Yet it is equally clear that knowledge of what is does not open the door directly to what should be. One can have the clearest and most complete knowledge of what is, and yet not be able to deduct from that what should be the goal of our human aspirations. Objective knowledge provides us with powerful instruments for the achievements of certain ends, but the ultimate goal itself and the longing to reach it must come from another source. And it is hardly necessary to argue for the view that our existence and our activity acquire meaning only by the setting up of such a goal and of corresponding values. The knowledge of truth as such is wonderful, but it is so little capable of acting as a guide that it cannot prove even the justification and the value of the aspiration toward that very knowledge of truth. Here we face, therefore, the limits of the purely rational conception of our existence. But it must not be assumed that intelligent thinking can play no part in the formation of the goal and of ethical judgments. When someone realizes that for the achievement of an end certain means would be useful, the means itself becomes thereby an end. Intelligence makes clear to us the interrelation of means and ends. But mere thinking cannot give us a sense of the ultimate and fundamental ends. To make clear these fundamental ends and valuations, and to set them fast in the emotional life of the individual, seems to me precisely the most important function which religion has to perform in the social life of man. And if one asks whence derives the authority of such fundamental ends, since they cannot be stated and justified merely by reason, one can only answer: they exist in a healthy society as powerful traditions, which act upon the conduct and aspirations and judgments of the individuals; they are there, that is, as something living, without its being necessary to find justification for their existence. They come into being not through demonstration but through revelation, through the medium of powerful personalities. One must not attempt to justify them, but rather to sense their nature simply and clearly."

Depending on feelings and assumptions about the possibility of moral progress and the nature of the universe, were the human race to vanish, perhaps a long process of growth would just begin all over again for it or something like it eventually? And would such a possibility change the presumed optimum you outline?

Also, on reducing suffering as an optimization criterion, always remember the motivation triad (as explained well by Douglas J. Lisle such as in "The Pleasure Trap") of maximizing pleasure, minimizing pain, and minimizing effort -- where our brains try to optimize all three simultaneously (along with other objectives).

On the general topic of suicide prevention, you may find of interest some resources I collected here:
https://github.com/pdfernhout/High-Performance-Organizations...

Especially the point here from David Conroy: "Suicide is not chosen; it happens when pain exceeds resources for coping with pain. That's all it's about. You are not a bad person, or crazy, or weak, or flawed, because you feel suicidal. It doesn't even mean that you really want to die - it only means that you have more pain than you can cope with right now. If I start piling weights on your shoulders, you will eventually collapse if I add enough weights... no matter how much you want to remain standing. Willpower has nothing to do with it. Of course you would cheer yourself up, if you could. Don't accept it if someone tells you, "That's not enough to be suicidal about." There are many kinds of pain that may lead to suicide. Whether or not the pain is bearable may differ from person to person. What might be bearable to someone else, may not be bearable to you. The point at which the pain becomes unbearable depends on what kinds of coping resources you have. Individuals vary greatly in their capacity to withstand pain. When pain exceeds pain-coping resources, suicidal feelings are the result. Suicide is neither wrong nor right; it is not a defect of character; it is morally neutral. It is simply an imbalance of pain versus coping resources. You can survive suicidal feelings if you do either of two things: (1) find a way to reduce your pain, or (2) find a way to increase your coping resources. Both are possible."

Here is a summary of key ideas from Mayeroff's book in more blunt language: https://thoughtcatalog.com/kyle-eschenroeder/2016/11/this-is...
"In 1971 a philosopher named Milton Mayeroff wrote the manifesto on giving a shit. It’s titled On Caring (for us, On Giving a Shit) and we’ll pull from it to help understand how giving a shit can change our lives and how we might learn to give higher quality shits."

As mentioned there, Mayeroff also wrote: "No one else can give me the meaning of my life; it is something I alone can make. The meaning is not something predetermined which simply unfolds; I help both to create it and to discover it, and this is a continuing process, not a once-and-for-all. "

Also related: https://www.wikihow.com/Find-Meaning-in-Life

Or, as Richard P. Feynman said: "Fall in love with some activity, and do it! Nobody ever figures out what life is all about, and it doesn't matter. Explore the world. Nearly everything is really interesting if you go into it deeply enough. Work as hard and as much as you want to on the things you like to do the best. Don't think about what you want to be, but what you want to do. Keep up some kind of a minimum with other things so that society doesn't stop you from doing anything at all."

For example, your post shows you care about philosophy as well as reducing suffering -- and there are a lot more ideas and actions you can explore starting from those two areas. If you do so, please keep in mind the extra complexity of the motivational triad and other possible human objectives. And along with "The Pleasure Trap", please also perhaps reflect on the book "Supernormal Stimuli: How Primal Urges Overran Their Evolutionary Purpose" by Deirdre Barrett and the essay "The Acceleration of Addictiveness" by Paul Graham as they explore the dark side of modern society and technology relative to human inclinations adapted for a more tribal culture within an environment with different abundances and scarcities. As Stephen Ilardi writes about in "The Depression Cure: The 6-Step Program to Beat Depression without Drugs": "We were never designed for the sedentary, indoor, sleep-deprived, socially-isolated, fast-food-laden, frenetic pace of modern life."

All the best in discovering and/or making meanings in your life -- including from loving caring.