Are you asking what atheists replace those two things with if they don't believe in a God?
— Philosophim
Yes. — Brett
A fantastic question then. Some atheists don't understand why people stay religious, even though "rationality" reveals the lack of evidence for the truth of the religious tenants. I do not view people who hold religion as lacking rationality, as many are good people who want to hold onto morals and a purpose in life. Good people will often hold onto morals and purpose in life, even if there are some underlying rational questions they have not answered.
And on the flip side, I hope you don't view atheists as "rational" but bad people who reject purpose and morality. The reason I started philosophy many years ago was to answer the questions of God, knowledge, and morality. Why are we here? What's it all for?
My conclusion after all these years is that we are a part of the existence all around us. Instead of a void, there are things. Life and non life are all jumbled together into this beautiful set of physical and chemical interactions that make something, over there being nothing.
We are parts of existence that have gained the gift or curse of realizing what we are. Of getting to see reality in a way beyond ourselves. Of being able to imagine a reality of what the world can be, and shape it. In this journey, you either come to appreciate it and love it, or resent it and reject it. The path to heaven or hell. Some people resent other existence. Try to tear it down if its beautiful. Some resent themselves. Some hate it all. They have seen the world, they see it as an abyss, and wish all of it would end.
Others, like myself, see the beauty of it all. We are amazed by the complexity. We love seeing other people live out their passions and dreams. We love the struggle of being able to live out our own passions and dreams. We go along our way, understanding we're all in this existence together, working, laughing, dreaming, and one day dying. So we make the best of the time we have. We help others have an easier and happier day. We do pursue our own dreams, but we try to elevate others along the way, not crush them.
When there is a God, you realize you have a choice. But your purpose is made for you, and you are set to follow that, or reject that. When there is no God, you realize you have a choice. But you make your own purpose. You are truly free, and you realize the ramifications of what you do are immediate, and not in the future. If I make fun of of a person I don't like so that they feel hurt, there will be no consequence in the afterlife. No reward or punishment. I will have to live with the fact I made another human being like me suffer for my own selfishness. Do I want to live like that? No.
The consequences of life become clear. There is no reward or punishment waiting on the other side. But was that why you wanted to be a moral person originally? Or did you want to be a moral person because it was right? That it made the world a better place? So instead of paving the way for the afterlife, you pave the way for today and tomorrow. Suffering needs to be ended now, as there may not be a later. There is no God who will come along and save people, so you need to do it yourself. It puts moral decisions in very real and stark terms. You understand there is a time limit, so you get things done.
Can a religious person arrive at these conclusions and do these things too? Yes. Some people cannot live in a positive way without the idea of a God or afterlife existing. They need a structure, and people telling them what to do. There is no shame in this, as we are a social race that also craves unity, family, and belongingness. Some people live their life better with atheism, but I also believe some people live their life better with religion.
So in the end, if you do not have the existence of another being dictating your purpose, then you dictate your own purpose. You obtain pure freedom, and the responsibility that goes along with that freedom. I hope that answers your question.