This is the 7633rd most frequent Japanese word.
励まし
Encouragement.
Here, 励まし is used as a noun to denote the act of encouragement received from a friend.
友達の励ましのおかげで、私は試験に合格しました。
Thanks to my friend's encouragement, I passed the exam.
In this sentence, 励ましながら implies the action of encouraging as one continues to support, showing a dynamic use of the word as part of a phrase.
励ましながら子供たちを支援する重要性を感じました。
I recognized the importance of supporting children while encouraging them.
Used as 励ましの言葉, the term describes the specific kind of words intended to encourage someone.