nostalgia: 1770, "severe homesickness" (considered as a disease), Mod.L. (cf. Fr. nostalgie, 1802), coined 1668 by Johannes Hofer as a rendering of Ger. heimweh, from Gk. nostos "homecoming" + algos "pain, grief, distress." Transferred sense (the main modern one) of "wistful yearning for the past" first recorded 1920.
Take the modern meaning of yearning for the past. In severe cases, pain felt when remembering that the past is gone and will never come back. Pain felt for that which has been lost.
So in the modern sense, it is
lost + algos
Britannica, are you listening?