The financial resurrection of J.C. Penney (OTC:JCPN.Q) has been nothing short of remarkable. As sales went into free fall in 2012, the retailer's demise seemed imminent, but with the departure of CEO Ron Johnson, the company managed to survive.

And though it may not be thriving, the department store chain is certainly much better off today than just a few years ago. However, 2017 is looking to be another difficult year for retail. But as they say, what doesn't kill you makes you stronger, and that could be especially applicable to J.C. Penney.

An empty shopping mall

Image source: Getty Images.

Malls are becoming ghost towns

Like ailing rivals Macy's (NYSE:M) and Sears Holdings (NASDAQ:SHLDQ), which has accelerated its collapse with numerous self-inflicted wounds, J.C. Penney faces major retail headwinds. One one hand, off-price retailers are siphoning customers away, and on the other, e-commerce continues to grab market share.

Many retailers have realized that traditional malls will not be seeing a rebound, thus beginning the process of closing down stores. Macy's, for example, closed 66 locations last year and plans to close 34 more in the future. It currently has 700 stores in operation, down from 840 just five years ago.  

Sears is an even worse position and reduced its store count by 242 last year, bringing the total to 1,430 locations -- five years ago, it had over 4,000 stores. Other retailers such as Wal-Mart and Target have either announced store closings or are reducing their square footage by investing in smaller formats.

Although J.C. Penney resisted calls to follow suit with its own closures, even management realized there were no other options. Last month, the company announced it would close almost 140 stores, or about 14% of its base, by June, giving it about 900 remaining locations.

A Nike store-in-store department inside a JCPenney

Image source: J.C. Penney.

A retail apocalypse

Consumers just aren't shopping at malls the way they used to. According to data compiled by the industry watchers at ShopperTrak, retail store foot traffic has plunged 57% between 2010 and 2015, and real estate research firm CoStar says annual department store retail sales have tumbled 28% since their peak in 1999. It estimates nearly one billion square feet of retail space will need to be "rationalized" over the next few years.

The decline in shopper traffic can be seen in just how many mall-based retailers are downsizing or have declared bankruptcy in the past year alone. The Limited went under this past January, while Aeropostale, American Apparel, Pacific Sunwear, and others failed last year.

According to the The Deal, "The number of large-liability retail Chapter 11 filings (at least $250 million in liabilities) nearly doubled in 2016 and that trend shows no signs of slowing down." Indeed, Moody's has warned that some 19 retailers are at risk of defaulting on their loans, including Sears, True Religion, Nine West, Gymobree, and more. Fashion retailer Bebe just announced it was closing all 170 of its stores, transitioning to an online-only model as a means of staving off bankruptcy.

Giving customers what they want

This is why J.C. Penney's pain might not stop with the store closures it recently announced. The retailer is scrambling to adapt to how consumers now shop and look for products. For example, it found that one of the top things people searched for on its website was appliances, so it is adding them to more of its stores.

A JCPenney showroom with home appliances on display

Image source: J.C. Penney.

The company also announced that it is expanding home services offerings for homeowners looking to remodel and upgrade their homes. It will partner with companies like Trane and Samsung as a middleman for homeowners seeking out heating and cooling systems, bathroom remodeling, whole home water solutions, smart home devices, and more. It used to provide such services to customers, and reentering the market lets it further diversify away from apparel.

And as a smaller retailer focused on the home, it has the potential to come out on top if companies like Sears do go under. The old-line retailer is still a force in the appliance business, for instance, even though it has lost significant ground to competitors. But J.C. Penney could pick up those customers if Sears goes bankrupt as many suspect will happen soon.

J.C. Penney has also shored up its balance sheet, but after a less-than-stellar Christmas shopping season, the business is not where management wants it to be. Still, with the future looking bleak for many of its financially weaker rivals, J.C. Penney may turn out to be one of the last major department stores standing. If that proves to be the case, investors can expect better times ahead.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.