Stock markets are performing terribly. The U.S., by most common measures, appears to be in the midst of a recession. The credit markets are crumbling, and liquidity is scarce. The situation has gotten so bad that one of the country's most respected financial institutions, Bear Stearns (NYSE: BSC), recently came close to a collapse reminiscent of Long-Term Capital Management's death spiral. Bear found salvation only in an amusingly cutthroat $2-a-share buyout offer from JPMorgan Chase (NYSE: JPM).

But in spite of all this turmoil, investors should be rejoicing.

Buy stocks like you'd buy milk and eggs
Investing should be no different than the weekly visit to your grocery store. At the grocery store, most shoppers are quite astute. They scrutinize the aisles, armed with years of collective information on prices, brands, and quality. Grocery shoppers save money by taking advantage of store sales and loading up on their favorite items when they're offered at a cheaper price than normal.

Investors of all shapes and sizes would benefit tremendously from mimicking the buying habits of regular grocery shoppers. Instead of scrutinizing stuff like detergent, eggs, and milk, investors need to scrutinize companies in all areas. Just as a grocery shopper knows to take advantage of a sale when he or she sees one, so should the investor when the stock market offers up underpriced bargains. Like a grocery shopper who loads up the pantry with her favorite goods, when Mr. Market announces a blue-light special, buy the strong companies you know well -- and buy them in bulk.

One investor's panic is another's profit
Unlike the stock market, grocery stores usually advertise sales and promotions to entice more shoppers to buy. The stock market, on the other hand, doesn't go out of its way to tell you about stocks on sale. And unlike groceries, when stocks are on sale, most investors do the exact opposite of what they should be doing: They avoid the market out of fear.

This fear is understandable, but you have to overcome it. Understand that the serious money to be made in markets comes from making big buys during continued market declines. Have we hit the bottom? I have no clue. Things could very easily get worse. Timing markets is not the name of the game; all that matters is buying great businesses at low prices. But bear-market investing isn't about buying indiscriminately; certainly, not every stock is a great buy right now. Along with the opportunities come the traps -- and the only way to avoid them is by performing your own due diligence.

A little push
If nothing else, the current market offers a bounty of investment ideas that are worth a second look. At best, you'll find a great investment; at worst, you'll increase your overall knowledge. And you might come across some real bargain stocks. For example, take a look at electronics retailer Circuit City (NYSE: CC). While the near-term outlook might look bleak, with consumers cutting back on discretionary electronic purchases, the company has a very attractive balance sheet. The company's current market valuation stands at just more than $750 million, yet it has almost $500 million in cash and marketable securities, and tangible equity of almost $1.3 billion. The retailing business is a tough one, and competition from companies like Best Buy (NYSE: BBY) is cutthroat. But the cash-rich balance sheet offers plenty of levers of upside at today's prices.

Another potential candidate worth a look is FreightCar America (Nasdaq: RAIL). This railcar manufacturer currently sells for $35 a share, but has more than $16 a share in net cash. So you are essentially paying $19 for a business that had per-share earnings of $4 in 2005, $10 in 2006, and $2 in 2007. Last year was a weak year for the industry, so if the picture improves in 2008, this little business could prove to be very valuable today. The company recently announced a joint venture in India that should help push it in the right direction.

Fertile hunting grounds
The fear and panic overwhelming today's market means happy hunting for investors. Tomorrow's big gains will be made from today's panic. But, as always, be careful: The market is littered with businesses posing as bargain stocks. Avoid the ones you don't understand, focus on quality companies with solid balance sheets, and you won't be afraid to act.

Further Foolishness: