There is a “substantial risk” that SunEdison may file for bankruptcy, the world’s largest renewable energy developer said in a regulatory filing on Tuesday. The company’s fall isn’t a referendum on the solar industry as a whole, as much as it is on SunEdison’s aggressive growth strategy fueled by excessive debt and financial engineering, analysts say.

SunEdison “just thought they were smarter than everyone else,” said David Levine, the founder and CEO of Geostellar, a solar energy marketplace that has done deals with the company.

The company's shares have fallen steeply since they hit a high of $30 in July. They were at just $1.26 before the filing. The stock immediately dropped another 40 percent when the market opened after the filing, and the company was trading at just $0.59 by Tuesday lunchtime.

SunEdison shares plummet 40 percent after bankruptcy concerns surfacehttps://t.co/i337x7fv2x pic.twitter.com/PdQZj0ijf7 — Bloomberg Markets (@markets) March 29, 2016

“What happened from late-2014 to the middle of 2015, the company began embarking on a hyper-growth strategy,” S&P analyst Angelo Zino told The Huffington Post.

SunEdison loaded up a total of $11 billion in debt to develop or acquire renewable energy projects. Once projects were complete, they sold them to one of two separate, public companies, called yieldcos, which SunEdison controlled. The company also created two internal financing entities, called warehouses, that raised a total of $2.5 billion to build renewable energy projects, which would be sold to the yieldcos once they were complete.

The theory was that the risk of building and managing renewable energy projects could be split into its various components and investors could buy exactly the slice they wanted. To work, SunEdison needed to keep raising more money to build new projects, and its yieldcos needed to keep raising money to keep buying those projects so that the company could pay down its debt in order to borrow more to build new projects.

“That is way too complicated, way too smart I would say... There’s only so much you should do because you are super smart,” said an industry observer, who is familiar with SunEdison’s business. “It’s a great company with great assets. It’s the finance department that’s the problem...They over-engineered it to death.”

Levine told HuffPost that a deal to buy the residential solar company Vivint for $2.2 billion in July of 2015 started the cratering. He pointed out that there’s nothing inherently wrong with yieldcos. Other solar companies and other utilities have them, but what set SunEdison apart was what it tried to stuff into the yieldcos. Rather than sticking to utility scale projects, SunEdison included residential solar that was tied long-term contracts. Investors didn’t trust these contracts, called purchase power agreements, because they locked in rates at current prices, which wouldn’t make financial sense if solar costs keep falling, as they are predicted to. “[Investors] considered purchase power agreements for consumers to be the equivalent of subprime loans,” Levine said. “I think it was a totally stupid deal to do Vivint and it made everyone question SunEdison.”

As a result of the Vivint deal, investors soured on the company's yieldcos and their stock prices, along with SunEdison's, started dropping. That meant that the yieldcos couldn’t raise more money to buy more assets from SunEdison. Worse, SunEdison had to delay its financial report because of accounting questions, so the company, already deeply in debt, couldn’t borrow more money. The carefully laid financial structure lacked what was necessary for it to work: new cash flowing in.

When financing dried up, SunEdison’s only option was to sell its assets to other companies, like utilities. But Zino said there had been limited asset sales since the company last reported in November. “We’re at a point now where if they haven’t been able to generate cash via those assets sales, and you can’t tap the equity markets and you can’t tap the debt markets, there’s really no other means to generate cash,” the S&P analyst said. Zino thinks that could be because SunEdison's projects aren’t as good as the company says or because buyers know they are in trouble and is negotiating to get lower prices.

Now the company, by their own admission, may file for bankruptcy protection. Zino, noting that strong growth in renewable energy last year, sees a bright spot for other big solar companies: They now have a chance to buy up projects from a competitor at a discount.

SunEdison did not immediately respond to a request for comment.