NEW YORK (AP) - Sometimes, pain hits nearly everywhere.

NEW YORK (AP) — Sometimes, pain hits nearly everywhere.

The vast majority of mutual funds skidded to losses last quarter as worries worsened about global economic growth. Uncertainty about interest rates made markets even shakier.

Only 17 percent of the mutual funds tracked by Morningstar were able to scrounge out positive returns in the three months through September. That's down from 41 percent in the second quarter, and it's the reverse of the first quarter, when 87 percent of funds made money.

The biggest losses last quarter came from funds that invest in stocks, which is typical when fear is high. Bond funds offered some protection, fulfilling their traditional role of stabilizers for a portfolio, but not as much as they have in prior downturns.

Here's a look at how mutual funds performed during the third quarter:

— Stock funds struggled.

All but three of the 2,255 mutual funds that focus on U.S. stocks had losses.

They couldn't overcome worries that a slowing global economy will hurt profits for U.S. companies, which are increasingly reliant on customers abroad. The Federal Reserve's decision to hold off on raising rates at its last meeting also shook markets.

Consider the largest mutual fund by assets, Vanguard's Total Stock Market Index fund, which helps make up the core of many 401(k) accounts and IRAs. It lost 7.3 percent over the three months. That's its biggest quarterly loss in four years. If it doesn't rebound in the next three months, the fund will have its first down year since the financial crisis in 2008.

The best-performing U.S. stock fund last quarter was the Polen Growth fund. It returned less than 1 percent.

— Popularity doesn't always translate into returns.

One of the hottest areas for investors has been foreign stock markets.

Europe and Japan are earlier in their economic recoveries than the United States, which means their central banks are pushing stimulus while the Federal Reserve moves in the opposite direction. That, plus cheaper valuations abroad, led investors to pour nearly $210 billion into foreign stock mutual funds and exchange-traded funds in the 12 months through August. They pulled more than $7 billion out of U.S. stock funds over the same time.

After plowing that much in, investors were rewarded with losses from nearly all foreign stock funds last quarter. All but four of the 1,154 dropped last quarter.

The sharpest losses came from funds that focus on stocks from emerging markets, which have a long history of big swings. Latin American stock funds tumbled an average of 21.4 percent, while Chinese stock funds lost 20.1 percent.

China's economic growth is in the midst of a sharp slowdown, which is pulling down prices for the commodities that Latin American companies produce.

— Bond funds offered (some) protection.

Many bond funds held their own, as they're expected to during down markets for stocks. Interestingly, the funds investors had been most fearful of did best: longer-term bond funds.

When interest rates rise, bond prices fall because their yields look less attractive. Longer-term bond prices are particularly sensitive to rate changes because they lock investors into fixed rates of return for longer.

That's why many investors have been shifting in recent years from long- and intermediate-term bond funds to short-term options.

Last quarter, short-term bond funds had modest losses, while longer-term funds had modest returns. Short-term bond funds lost an average of 0.2 percent, intermediate-term bond funds returned 0.3 percent and long-term bond funds gained 1.7 percent.

That's in part because the yield for the one-year Treasury bill rose last quarter, while yields for 10- and 30-year Treasurys fell. It's a phenomenon that bond traders call a "flattening yield curve," and it's one that some expect to continue.

Just don't expect bond funds to offer as much protection as they did in prior downturns. Because yields are lower, bond funds are producing less income than in years past.

—Health care stock funds flatlined.

For years, health care stock funds were some of the top-performing investments. That's because biotechnology and other health care stocks were offering prospects for strong revenue growth in a global economy that was notably short of it.

That run ended last quarter, and a single tweet had a lot do with it. Presidential candidate Hillary Rodham Clinton went on Twitter last month to criticize "price gouging" by drugmakers, which raised worries that increased regulation could pull down profits for the industry.

Health care stock funds lost an average of 13.7 percent last quarter. They have returned between 21 percent and 48 percent annually over the last three years.