Here's an explanation.
Doctors and lawyers make for great television and movies, because of the drama involved and the ease of portraying it.
Pretty girls are also a requirement for entertainment, for <reasons>.
So many doctor and lawyer TV shows were cast with women in them.
And then many girls aspired to be doctors and lawyers, because they saw a viable path that way.
Also, secretaries and nurses worked close to doctors and lawyers and businessmen, tech was more isolated. Again, less bridge, less role model.
Culture > everything.