I'm as much of a "try not to kill work morale and culture" guy as the next guy, but I agree. We aren't robots.
I wouldn't personally lead with "pooh-bear" comments. I'll hope to have enough platform to ask: "Hey, from my side here you don't seem OK. You want to talk about it?" Knowing that the professional side of this will likely include, "If it's affecting you or your coworkers' work, let's talk about options here..." when needed.
If someone has an outlook that sees starting with ****-move comments as more acceptable than trying to process <whatever you don't know is going on> may need to reevaluate. In other words, why would you give yourself the right to be an ass in order for someone else to not have the right to a bad day/week/etc? (I'm not saying that the OP was ****-move. They may have enough relationship and platform for that to be the equivalent of "Hey, you OK?". It's hard to judge that kind of thing from outside.)