What's the big deal about Spain? Last year the country's government debt came to just 68.5% of its gross domestic product. That hardly puts Spain in the same class as Greece, right?

The goal of the Greek rescue package is, after all, to reduce that country's debt to 130% of GDP. Gosh, Spain isn't even in the same debtor class as the United States. The U.S. debt-to-GDP ratio passed 100% in 2011 and is forecast to hit 112% by the end of 2013.

So why have yields on Spanish 10-year bonds -- which rise with the perceived risk of those bonds -- climbed back within spitting distance of 6%? And why has that been enough to send the global financial markets into a bout of panic selling like the one we saw Tuesday?

How about because Spain's debt represents a worse crisis than Greece's and a far worse problem than U.S. debt. (Give us a few years, though.)

The Spanish debt crisis looks as if it has combined the worst of the Irish and Greek debt crises -- and has wrapped the results in an economy too big for existing eurozone funds and mechanisms to rescue. Spain looks as if it's headed down the path that required a bailout in Greece and Ireland -- and everyone knows that Spain is is too big to bail out.

Let me start by laying out the shape of the Spanish crisis, and then suggest the likely outcome. And because I know many of you have questions about the two Spanish stocks you're most likely to own -- Banco Santander (STD) and Banco Bilbao Vizcaya (BBVA) -- I'll post in more detail on those on Friday in the Top Stocks blog (kind of a Spanish theme to end the week).

Image: Jim Jubak

Jim Jubak

Why Spain isn't Greece

The first thing to understand about the Spanish debt crisis is that it doesn't resemble the Greek debt crisis. Or it didn't at the beginning, anyway. The Greek crisis was a crisis in government debt. The Spanish crisis started off as a crisis in private debt. It has only gradually become a crisis in government debt.

Spain's public debt may have ended 2011 at a relatively manageable 68.5% of GDP, but the Spanish private sector is awash in debt -- to the tune of 300% of GDP. And as the Irish debt crisis shows, if a country winds up turning unsustainable private debt into public debt, the deterioration of public finances can be stunningly fast.

In 2007, Irish public debt was a low 25% of GDP. The country finished 2011 with a public debt-to-GDP ratio of 112%. And it's forecast to hit 120% when it peaks in 2013.

What happened? An Irish housing boom turned into a housing bust that turned into a financial crisis at the banks that issued the mortgages. And when the Irish government stepped in to rescue the banks, the private debt became a public burden.

The Irish housing bubble was astonishing, even by U.S. standards. The country started 1997 with a housing stock of 1.2 million homes. By 2008 that was up to 1.9 million homes. Housing prices, meanwhile, quadrupled from 1996 through 2007. That was twice the U.S. appreciation during that period.

Housing prices started to fall in early 2007 -- even before the global financial crisis. But with the financial crisis, the big Irish banks that had borrowed in the global financial markets to fund their mortgage binge couldn't find financing. In 2003, Irish banks issued 15 billion euros ($19.7 billion) worth of debt on international markets to fund their operations. By 2007, that had climbed to 100 billion euros ($131.4 billion). Ireland is a small country; that bank borrowing came to half of GDP.

When international financial markets stopped lending to pretty much everybody in the financial crisis, Ireland's banks couldn't refinance that debt as it matured. And with the value of the mortgages on their books plunging, the banks were in deep trouble. Two weeks after the Lehman Brothers bankruptcy in September 2008, the banks turned to the Irish government for rescue.

The steps that the Irish government took, beginning in 2008 -- a blanket two-year guarantee to the banks, the use of government money to recapitalize the banks, and the use of emergency liquidity from the central bank in 2010 when the Irish banks ran out of collateral for loans from the European Central Bank -- effectively turned the private debt into public debt. In 2010, the government's budget deficit for the year hit 32% of GDP. That locked the Irish government itself out of the financial markets, and the country had to turn to the European Central Bank, the International Monetary Fund and the European Union for a rescue.

How private debt goes public

With the example of Ireland before it, Spain has done everything it can to fix its private debt problem while moving as little of it as possible to the public balance sheet. The country has, so far, used a guarantee fund, underwritten by payments from the country's banks, to help finance the sale of weak or failing banks. For example, the government put 5.25 billion euros ($6.9 billon) from the fund into Caja de Ahorros del Mediterráneo before selling the bank to Banco Sabadell. This arrangement has the advantage that the fund and its disbursements don't count as part of the government's budget or budget deficit.

But the firewall between public and private debt exemplified by that fund is increasingly ineffective. The balance sheets of Spain's banks and Spain's government have become more entwined in recent months. The 1 trillion euros in 3-year loans offered by the European Central Bank to European banks in December and February was supposed to solve the liquidity problem for banks that couldn't access the financial markets to refinance maturing debt. Those banks could borrow at 1% from the central bank. Many banks were able to borrow enough to meet their refinancing needs for 2012 and on into 2013.

But what did those banks do with that money? Well, what would you do if you were a banker borrowing at 1% in an economy sinking into recession -- you don't want to make a business loan in that environment, for sure -- and where Spanish government debt is paying 3.5% or 4% or even 5%, depending on the maturity? You take your European Central Bank money and buy Spanish government bonds, of course. (UBS estimates that only 4% of that 1 trillion euros wound up going into new lending in the real economies of the eurozone.)

From November 2011 to February 2012, the time when the European Central Bank was dishing out that trillion in loan money, Spanish banks increased their holdings of Spanish government debt by 68 billion euros. (By the way, Italian banks have been doing exactly the same thing: They've bought 54 billion euros of Italian government debt in the same period.)

This hasn't turned out to be the smartest play in the past month or so. As banks ran out of borrowed cash to buy government debt, yields started to move up and prices started to move down. (There were other reasons, too, for this price move, such as the attempt by the Spanish government to unilaterally rewrite its budget deficit target.) In the past month, yields on the 10-year Spanish bond have moved up almost a percentage point, sticking the banks that bought Spanish government bonds with big losses.

More from MoneyShow.com: