I have the same problem with YouTube! Between work + school I don’t have free time until 930/10, so I unwind watching documentaries on YouTube and it’s 2-3am before I know it :(
I recently ordered an EReader and if books can’t replace that YouTube urge I might have to go the same route as you and redirect myself after midnight.
I give myself a pass for Lemmy though. It’s not sucking me in, rather I open the site specifically for news for sites that don’t offer RSS feeds. (RSS helps a lot with eliminating the news -> distraction scenario)