Some of my best times were working in a university department. We did all this, though the talking to people outside your team was at proscribed coffee times in the staff lounge and sometimes over lunch.
But they remained colleagues not friends. Outside the few parties a year we didn't go round people's houses. We collaborated and fought over work, as that was what brought us together.
I make the distinction between colleagues and other employees as not all employees are colleagues. Colleagues help each other out of tight spots and talk beyond "Nice weather". Friends could be either, but in my experience once everyone is married and has kids, the closest will be "friendly" rather than "friends".