education is highly funded. teachers are not paid well because there is a perception that "anyone can be a teacher" (which is true in the sense that there is no particular enumerable qualification or credential that makes you a good teacher) so the market is full of people who decide that they should be a teacher (many should not, but there is no a priori way of knowing). supply high. a lot of education funding goes to things that are not teacher pay.