maybe because "impact on society" is a totally delusional way to make pay scales. Pay is almost entirely based on talent scarcity. Thats why low skill jobs are lower pay, and highly skilled professions pay more accordingly. It doesn't matter at all what your impact is, think of people who work(ed) in mines or in the fields.
I'd argue it's not just talent scarcity it's measurable talent scarcity. There are really great teachers out there that do a fantastic job there are terrible teachers that suck, they are mostly paid the same because it's hard to differentiate between a good teacher and a bad teacher.
Whereas with a software developer especially at small orgs their ability is easier to measure and evaluate.