Is the opposite explained? I haven't read literature on the topic, and I'm by the way also somewhat of a sceptic of science on such topics, as a layman. But it seems super obvious that girls/women on average are not wanting to spend their teenage years in the basement programming geek stuff, like many boys/men do. In my experience, here in Germany, and you can probably extrapolate to the West in general, it's not like girls aren't encouraged to pursue programming or science. Men are, on average, just more willing to put in the hours of social neglect in order to become good at such things as programming, or also gaming, or whatever other fringe unsocial hobby. A big part of that is probably competitiveness, but also I believe there are more loners among men. Again, this is not scientific, just personal observations, also ideas I've picked up that I can agree with. I'm not even saying that it must be mostly for biological reasons (though I assume it is), just that there is a deeper reason for fewer girls to exist in tech than just "there is patriarchy and power structures and misogynist gatekeeping and shit".
Never forget that the social neglect is not exactly healthy, and programming isn't actually that prestigious and externally rewarding, except for maybe the compensation that you can currently earn in some places.
Adding that for example in math or other sciences, we are much closer to gender parity.