Two or three decades ago, it was fashionable to say that Japan was the future. And now it seems that we were right: Japan does look like the future. Just not in the way we expected.

Back in the 1970s, Japan was the rising economic powerhouse that was set to shift the balance of power from West to East, rather like China is supposed to be today.

Then look what happened. It suffered not one lost decade but two of them, and is heading for a hat-trick. And as far as I can see, this is only the beginning of its woes.

Dead country
I spent a couple of months in Japan 20 years ago, and I loved the place and the people. But it pains me to say that unless the country goes through a radical (and unlikely) transformation, it will be no more. It will cease to be. It will shuffle off its mortal coil, run down the curtain and join the bleedin' choir invisible.

It will be an ex-country. Do you want to invest in that?

How much debt?
Japan has problems. It has public sector debts of nearly 250% of GDP, compared to 59% in the U.K. Its budget deficit is 8.7% and no plan to shrink it for at least five years. And this week, ratings agency Standard & Poor's downgraded Japanese debt from AA to -AA, claiming it lacks a "coherent strategy" to control this massive deficit.

So far, Japan has been able to service its borrowings by turning to its own people, who buy 94% of its government debt, even at rubbish yields of around 1.21%. But this can't go on forever, and for a very worrying reason.

The future is grey
Japan is aging. It has the oldest population in the world, with an average age of just over 44 years. And it's getting older.

I like old people, but you can have too many of them. In Japan, there are just three workers for every pensioner. In a decade, that will fall to just two workers, and continue to shrink. Japanese pensions have been notably generous. That will have to change.

Just as people shrink with age, so do countries. By 2055, the Japanese population will have shed a massive 38 million people, falling from 128 million to around 90 million.

The Japanese have stopped replacing themselves. The average woman has just 1.27 babies, and the number is falling. It ranks 184 out of 195 countries in the UN fertility ranking table.

The country seems to be going off sexual reproduction altogether. In a recent government survey, an incredible one in three Japanese males aged between 16 and 19 said they weren't interested in sex, or were actively averse.

If demographics are destiny, Japan is doomed. Once a population starts declining, it is very hard to reverse, except perhaps by immigration, which all those conservative, elderly Japanese people will resist.

1.21% anyone?
So what will happen to all those people? They will stop working, claim pensions, and die. They will also do a rather surprising thing. They will stop saving, and start spending. After all, who would they be saving for? Not their grandchildren, because they might not have any.

And when the Japanese stop saving, who will buy the country's bonds?

Not me, not you. Or at least, not until they yield rather more than 1.21%. Which the heavily indebted Japanese government will be completely unable to afford.

Ouch.

Yer old!
Japan has been living on borrowed time since the late 1980s. As the economic miracle ground to a halt, the country's bankers and politicians refused to restructure or write down bad loans, but borrowed heavily instead in a bid to keep the party going.

When that failed to revive the economy, they borrowed some more money. Deficit spending became the norm, it was funded by the Japanese, and we all pretended this made it sustainable.

Japan has been able to generate so much debt without sparking a major calamity because its borrowing costs have so far been low. When that changes, it could go into shock.

Setting sun
Japan is still the world's fourth biggest exporter, and its exports have been surging lately. It is currently bailing out the euro zone, by pledging to buy more than 20% of AAA-rated bonds issued by the euro zone's new bailout fund.

We need Japan.

But I'm racking my brains to think of another country in history that has willingly let itself die out. Some were destroyed by conquest, others by changing climate, or depleting their resources. But has any country let itself wither and die? Let alone one with such a proud history as Japan?

The lost country
As Japan enters its death spiral, it will hurt the global economy. As the nation's bond yields start rising, Japanese banks, pension funds, and life insurers will send money home to cover their losses, sucking billions out of the global economy.

Asset prices will plunge, and so will stock markets. And I can't see a way out of this.

Here's another worrying thought. China is regularly called "the country that is going to grow old before it grows rich." At some point, it could find itself in the same position as Japan.

But let's just worry about one country at a time. Now, how much have you got invested in Japan?

More from Harvey Jones:

This article has been adapted from our sister site across the pond, Fool U.K. The Motley Fool has a disclosure policy.