Professionals who work in front of computer screens are very likely to work overtime without realizing it or being able to help it. The bright screens are said to be able to push back against fatigue which enables users of electronic devices to spend more time (than is advised) in front of their screens. Software engineers spend a lot of time learning in a bid to keep up with the industry as such when they're not working they're studying and time does get away from developers a lot.
Regardless of whether a developer is freelancing or under salaried employment, the consistent theme is that we're paid for results and not for effort. Software engineering is an exact science and doesn't make room for an alternative metric of assessment. A lot of times software engineers will underestimate how much time it'll take them to complete a task, or, something will go wrong that will complicate a rather straightforward process and result in longer production time. Software engineers try to counter the effect of bright screens by using dark mode everywhere but it can only do so much. Software engineers are very likely to work overtime under two conditions:
When the work they're doing is progressing smoothly; software engineering is quite enthralling when everything works well, it's hard to tear yourself away from the keyboard when you get into the deep work state that is responsible for heightened productivity and increased focus.
When the work isn't working as planned; software engineers display some of the toxic traits of gambling addicts when the code isn't producing the result we want. We keep trying other alternatives, believing that we'll get it right with the next iteration. Even when a software engineer decides to call it quits for the day if another untested idea creeps into the mind of the developer, the laptop is powered on again, and the untested idea will be implemented with the hopes that the idea is the final answer (most times it isn't).
Ultimately, it's important for software engineers to work with time in order not to burn out. More often than not, it's the loved ones of developers that help prevent software engineers from burning out. Left alone, most developers will live their lives around code in the quest to get better, chasing the mirage of "I finally know everything there is to know about this programming language". The urge to get so good that one is unfazed by any challenge is so great that most developers forget that some challenges will arise as a result of human error. At the same time, it is important not to rush the process of learning.