Different people with different social energy levels and so also different presence intervals, still see each other from time to time. Sprinkle in some nice fun non-obligatory team building activities.. everybody happy and productive.
Pre-pandemic I usually worked in open offices, and always found them horrible.
I found it insane the first job I had that companies preferred me to work in an open plan office, whereas I could do hobby coding without any distractions at home.