Answer:
Theme.
Step-by-step explanation:
A theme is a literary device that tells the readers about the main idea or underlying meaning of what's been said or referred to in the text. A theme is a central topic that will resonate throughout the whole literary work.
The given definition "the main idea or underlying meaning of a literary work which may be stated directly or indirectly" is about a theme of any literary text. Most literary works will always have an underlying theme in their work, ranging from love, sorrow, poverty, success, or it could be anything.
Thus, the correct answer is a theme.