Pain at the pump. Soaring food prices. Plummeting stock markets and housing prices.

Add 'em all up, and it sure seems as if the sky is falling. But you can't respond to gloom and doom by giving up on your retirement investments. Instead, your ultimate investing success depends on your confidence that people will adapt in the face of new challenges -- and find ways to prosper.

The end is near?
In a recent update on The Motley Fool's Rule Your Retirement service, retirement expert Robert Brokamp noticed that extremely pessimistic predictions are appearing in greater numbers. Books such as Michael Panzner's Financial Armageddon point to huge personal-debt levels, government budget deficits, broken promises from corporate retirement plans, and the overwhelming size of the derivatives market in predicting a breakdown of the financial system.

Yet as Robert points out, we've been through all of this before. In the 1970s, double-digit inflation joined hands with a slowing economy to knock stocks for a loop. Before the crisis was done, mortgage rates rose above 18% -- bond investors suffered as well -- and oil prices climbed from single digits to around $40 per barrel.

The problem with doomsday predictions is that in the end, no one profits from them. After all, if financial systems do completely collapse, then paper profits on gold stocks or stock-index put options won't really be worth anything -- and you'll have a lot more pressing concerns than trying to collect a bunch of worthless greenbacks from your broker.

In contrast, investors who profited most from the difficulties of the 1970s didn't focus solely on the crisis itself. They also believed that people would find solutions to the problems the world faced -- and invested their money in those solutions. That turned out to be a far better long-term strategy. As the overall market did well in the subsequent years, oil stocks such as BP (NYSE:BP) stayed in the doldrums for years to come.

A grain of salt
You need to be aware of changing conditions so you can figure out which of your investments are most vulnerable and take appropriate action.

Hard times don't always mean bad news for business, after all. Shifting economic trends present opportunities you should take advantage of in your investing strategy. For example, cheaper labor in emerging-market countries such as India led many U.S. companies, including Honeywell (NYSE:HON), Cisco Systems (NASDAQ:CSCO), and Oracle (NASDAQ:ORCL), to cut costs by working with Indian businesses and outsourcing some of their operations in recent years. Rather than simply accept higher labor costs at home, these companies jumped at the chance to become more competitive.

Similarly, you can take advantage of trend shifts in your portfolio. In the current energy crisis, for instance, oil and gas stocks have performed spectacularly. Figuring out how to profit going forward, though, requires thinking about how the industry will respond. If more areas are opened to drilling, then seismic-data providers such as Dawson Geophysical (NASDAQ:DWSN) should see continued growth. On the other hand, if a new energy policy favors sources other than fossil fuels, then solar stocks such as First Solar (NASDAQ:FSLR) and Evergreen Solar (NASDAQ:ESLR) will have a chance to justify their high current valuations.

Don't bet on doomsday
As you can see, the exact steps you should take to profit from hard times aren't perfectly clear. But the general philosophy of looking at how companies will solve problems is a valuable one for investors to keep in mind. By investing in stocks that you think will find the solutions to the challenges we face, you'll get the most from the happy days that are yet to come.

For more on investing in tough times, read about: