My experience as well, in a hospital a doc left me with sa fully logged in console, to feed my kid in his office (which is incredibly kind of course). I for one got that "walk afk = alt-f4" rammed into me at my work place at that time. Makes me think that there might be a face-id like unlock (and immediately lock) market out there for PCs...
I expanded on this in an adjacent comment: smartcards might be a cheap and easy solve here. Insert the card to log in, pull the card and you get logged out. Bonus points if the smartcard is also your access card for e.g. the break room.