In the US, it applies across the board, where US rankings keep falling.
Canada has rankings in math and science that are not too bad, and Canada has been doing better recently.  For all the criticism of the Ontario government, Ontario has actually been doing quite well.
.
Still, though, this is a topic with which I have first hand knowledge, and it is not a lack of math and science that is killing our democratic institutions, it is a lack of knowledge of history and civics.
.
Further, the well-spring of our prosperity is not the teaching of math or science.
.
The well-spring of our prosperity is our democratic institutions.
.
Take a look around the world.  Prosperity is very nearly perfectly correlated to the relative health of a country's democratic institutions.  The stronger the democracy, the richer the country.
.
Democracy is a treasure beyond value.