Quality CEO's my ass. Salaries for CEOs are high because they work like the mob's "cleaners" a lot of the time, and because they come from an exclusive club who all hire each other.
You mean like being a code monkey at a web agency, yet they get paid shit all? You mean like hitting rocks in a mine all day until your back gives up on you, yet they get paid shit all? You mean like trying to run a farm and competing against giant corporations who want to take over your business?
People at the top of the corporate and political ladders are excellent at one thing - bullshitting. Their job is the same difficulty as countless jobs which pay a tiny fraction of their salary. They're just good enough liars to convince everyone otherwise.
I think that the trouble is that high school teaches people how to follow, so they are conditioned for that. When people get to university-level education and, even more so, complete a masters degree, they have access to all sorts of information which the average person will find very difficult to obtain. The other aspect of this, which I would argue is far more important, is the social connections which are available at the "upper" end of society. It's all an old boy's club and semi-closed culture which most people simply don't have access to.
Leading is a skill just like mining or programming are skills - they can all be learned. Given the recent evidence of life-long brain plasticity, it's reasonable to assert that this is more a problem of nurture than nature.
In short, we train relatively few people to lead, hence the low supply.
Not to mention SCALE. While it's hard to be sure about cause and effect, a CEO who is 10% more effective than their peers can generate more shareholder value than a developer who is 10% more effective than their peers. A CEO who is 5X better is pretty much priceless.
One reason CEOs are well-paid is so that all of the middle managers will strive harder in hopes of having the job someday. Another is that our corporate governance/capital markets aren't that competitive and lousy managers can insulate themselves from market discipline.
Judging empirically, I'd say most actual CEOs can't handle it. That doesn't mean they don't get their golden parachute!
As I said, most CEOs nowadays seem to behave like mob "cleaners". You want them to come in, do the dirty work that needs doing, and then leave. You don't want them necessarily going somewhere else after leaving you. So you pay them a lot, because you want them to live quiet lives afterward.