A theme would often be the summary of the plot of the story, so the title of the story, but you can use “live your life with meaning” as a theme. And yes, a main idea can be “Live everyday as if it were your last” because the main idea is the lesson you get from the story, and you are giving a message with this sentence.