Writing Code That Lasts: Lessons from Maintaining Long-Term Projects