After US president Obama’s call for restrictions on assault weapons on Dec. 6, Americans went gun shopping.

That Monday, The New York Times reports that stock prices for gun makers Smith & Wesson and Ruger soared. Guns sold well on Black Friday, too, the day after three people were shot dead at a Planned Parenthood clinic in Colorado and just two weeks after terrorists killed more than one hundred in coordinated attacks in Paris. In fact, gun sales have been rising steadily all year, as though determined to keep pace with the growing frequency of high-profile shootings.

But who exactly are America’s gun owners?

According to a Pew survey conducted in 2014, Republicans are twice as likely as Democrats to be members of a gun-owning household. Gun owners are also geographically spread out: They’re just as likely to live in the Midwestern US (38%) as they are to live on the West Coast (35%), or the South (34%), debunking the myth that gun ownership is more prevalent in southern states. (In the Northeast, by contrast, gun ownership is lower, at around 27%.)

Above all, though, gun owners are men. It is true that gun sales are rising among women, but a substantial gender gap persists: In 2013, men were around three times as likely as women to own a gun.

“Possessing a gun is considered by many men as a straightforward way of subscribing to dominant masculinity.”

Over the past few years, far more women have favored banning semi-automatic weapons. A full two-thirds of women favor a ban compared to only 48% of men, according to a 2013 Pew study. Indeed, women tend to prioritize gun restrictions over gun rights generally, unlike their male counterparts. Couple this with the fact that the vast majority of mass shooters are also men, and a pattern emerges. America’s gun problem can’t be distilled down to one single issue, of course, but it’s clear that on top of crime and fears of terrorism and insufficient mental health resources and the Second Amendment, America’s gun problem has something to do with America’s masculinity problem.

As Alankaar Sharma, a social worker and researcher, tells Quartz, “Possessing a gun is considered by many men, if not most, as a straightforward way of subscribing to dominant masculinity.” In his view, the patriarchal system, which privileges a certain set of masculine behaviors, values, and practices, provides men with “a clear and justifiable reason to own guns.” It cements their identity as masculine men.

And for many men today, it’s an identity in particular need of cementing. In this May 2015 op-ed for The Los Angeles Times, sociologist Jennifer Carlson argues that men are clinging to guns as a way to address a broad range of social insecurities. Author of a book on the social practice of gun-carrying in America, Carlson found that gun owners often characterized their fathers’ generation as an era when men had important roles to play as providers and breadwinners.

But men’s participation in the labor force has been declining since the 1970s. As The Economist’s cover story, “The Weaker Sex,” explained earlier in 2015, poorly educated men in rich societies aren’t coping well in the 21st century. Changes in the home and the labor force, especially the loss of manufacturing jobs, have created a class of disgruntled, financially insecure men. Meanwhile, women, who now earn more university degrees than men, are surging into the workforce.

This tracks with Carlson’s research as well. “As men doubt their ability to provide,” she argues, “their desire to protect becomes all the more important. They see carrying a gun as a masculine duty and the gun itself as a vehicle for a hardened kind of care-work.” Some envision scenarios where they intervene with their guns to save women and children.

Self-defense is a common rationale for carrying a gun, but studies show that defensive gun use rarely plays out the way people imagine. Shooting someone in the high stress scenario of an attack is extremely difficult, even for well-trained personnel. After the Charlie Hebdo shootings in Paris, a pro-gun group simulated the attack to demonstrate how they would have used guns to save lives. Tellingly, they all still “died” in the exercise.

“As men doubt their ability to provide, their desire to protect becomes all the more important.”

Not only does civilian gun use fail to protect people, there is a direct relationship between gun ownership in America and gun violence. John Cassidy at The New Yorker is right: Americans’ rush to buy more guns is a bit of “collective insanity.” But it’s a mistake to think about the trend in logical terms in the first place. Buying a gun isn’t a rational decision; it’s an emotional one. As Carlson puts it, the gun rights platform is about a “crisis of confidence in the American dream.”

Of course, this is a very specific kind of American dream—one in which men hold a distinct, and presumably dominant, place of power and respect. But trade and technology have displaced the usefulness of brawny, working class men. This in turn has led some men to feel adrift, both emotionally and professionally.

As Harry Brod, a sociologist and a founding figure in the field of men’s studies, explains to Quartz, “We’re talking about masculinity in a period of rising feminism and changing gender roles.” Women are leaning in. Hillary Clinton might be our next president. The patriarchy is far from finished, but men on the lower end of the socioeconomic spectrum especially are feeling threatened.

Idealizing a physical masculinity can help negate this feeling. Gun marketers know this and so they appeal to male self-image to sell their weapons. In ads that ran in 2012, for instance, Bushmaster Firearms promised that if you buy their semi-automatic weapons, you can “consider your man card reissued.” (Guns makers have also started targeting women—as has the National Rifle Association—which doubtless helps explain the increase in female purchasers.)

This might also explain why gun sales spike less after a shooting than after calls for stricter control: For men who look to guns to validate their sense of masculinity, the prospect of restrictions imposed by an external authority is disempowering and emasculating.

Brod insists that we need to think about America’s gun problem as a distinctly gendered problem: “If you don’t understand that connection,” he tells Quartz, “you’re not going to solve the problem.” This, he points out, was the huge gap in Bowling for Columbine, Michael Moore’s 2002 documentary about gun violence in America. Some remedies might lie in addressing boys’ underachievement in school and improving opportunities in the workforce. But helping men dissociate their identities from guns also requires a shift in cultural attitudes. Above all, Brod says, “there needs to be a rethinking of what masculinity means.”