But as religion continues it's slow death, it's not been clear what replaces this important role of building community in our society. Hobby groups/clubs is at least one of the answers. My own hobby of mountaineering and climbing is very similar to yours of BJJ. Religion is basically just a glorified shared interest club that you're born into.
Something I haven't seen talked much about is how we financially support these types of groups. A lot of clubs either rely exclusively on volunteer effort and therefore are very fragile or high membership fees (like BJJ studios) that are out of reach for most people.
I didn't really put that together until now, but you're totally right. As a CS student, I've had group projects that involve regular meetings and a large project is developed over the course of a semester. Seeing my team mates constantly helps form bonds, but the wins and triumphs are probably the most influential.
I still remember submitting a project in the library at 2am and cheering that we were finally done. We got together for pizza and video games later that week for a more formal celebration.
On a related note about community it brings to mind Fight Club, Rent, and other "pre-Great Recession" aging very poorly as bitching about your cozy office job which pays the rent handily just came across as a spoiled rich kid to those in the downturn.
One solution to this is to find a deep and meaningful hobby in your area. I have found Brazilian Jiu Jitsu (a grappling martial art) to be one such "real" community. IDK, I still think van life is a legitimate way to live, but without digging into community issues and essentially abandoning all communities there never will be any communities people can adopt.
Here is what works about BJJ and the community it builds:
1.) Doing a physically hard thing together
2.) Broad appeal, very technical if you want it to be
3.) See the same people every week for years
4.) Goal is to improve each others skills in BJJ, but it is a very difficult martial art that builds a mindset of overcoming struggle
5.) My academy we give back to our broader community through charity events, etc.
6.) Community is a mindset. I have found you have to really push and pull the younger generations out of their shell and show them how to socialize to some extent.
--
Of course those qualities above aren't the only qualities that build a community but there are common themes. Working together to pull each other up with a perceivable sense of forward progress is a big element. I am not such a pessimist about communities and the current generation, but I definitely see how digital media and social media have stunted real communities in favor of shallower ones.