WRT the tie-in to the "nerd" phenomenon. Lots of things compete for kids' finite mental resources. It becomes a variation of do I invest in Social Status, or Subject Matter X? Those investments happen in a small way at first, but end up having an outsize impact on the rest of a kid's life.
Such choices are strongly influenced by cultural expectations for gender. Those cultural expectations are, in turn, cartoonishly amplified in the typical lord-of-the-flies high school environment.
Actually all of the above is just me—some random HN puke—speculating and repeating things I've heard elsewhere. But it definitely sounds plausible!