(CNN Money) -- True Religion is hanging on by a thread.
The designer jeans maker filed for bankruptcy protection on Wednesday, asking for a chance to reinvent itself as it grapples with hundreds of millions of dollars worth of debt and declining sales,according to court documents.
According to court documents, the company had $534.7 million worth of liabilities on its books, but only $243.3 million in assets.
There is some good news. True Religion said in a press release that the company has already secured a deal with its creditors to reduce its debt load by $350 million. In exchange, the company's biggest creditors will receive large ownership stakes in the company.
True Religion will stay afloat throughout the Chapter 11 bankruptcy proceedings, the company says, and it expects it will take three or four months for the court to approve its restructuring plan.
In order to improve its outlook, the company plans to "close or consolidate underperforming store locations, and renegotiate lease terms" in order to save money.
Another cornerstone of the restructuring plan is to "invest in growing our digital footprint," CEO John Ermatinger said in a statement.
True Religion is not the first retailer to be upended by the rise of e-commerce.
Traditional department stores and other brick-and-mortar outlets have struggled as digital giants like Amazon have soared.
So far this year, Amazon's stock hit a new record high, while more than 300 other storefront retailers have filed for bankruptcy and the industry has seen tens of thousands of layoffs.
True Religion entered the fashion scene before online apparel sales were common. The company was founded in Los Angeles in 2002 and rose to popularity as designer jeans became a pop culture phenomenon. The True Religion brand was splayed across fashion magazines and sprinkled into the lyrics of hip-hop music.
But today, True Religion's popularity has petered out, and the company's sales have been in decline for years, according to court documents.
True Religion's chief financial officer, Dalibor Snyder, wrote in court papers that the company has worked to "aggressively cut costs," by closing stores and issuing layoffs in an effort to mitigate losses. But those measures weren't enough.
Bankruptcy protection and restructuring was the next step. Snyder says if the plan is successful, True Religion will reduce its debt load by 72%.
™ & © 2017 Cable News Network, Inc., a Time Warner Company. All rights reserved.