Source: GT Advanced.

Investors have long known that being an Apple (AAPL -0.81%) supplier cuts both ways. Having a relationship with the Mac maker can simultaneously be a boon and a curse. There's a long history of stocks that soar while in Apple's favor, only to be utterly crushed when things go the wrong way or when Apple begins to squeeze too hard. Just ask OmniVision in 2011, or Cirrus Logic in 2013, among many others.

With GT Advanced Technology's (NASDAQ: GTAT) surprise announcement on Monday that it is filing for Chapter 11 bankruptcy protection, the company becomes the latest textbook example of what can go wrong, underscoring the incredible risks associated with getting in bed with Apple.

Where it all began
Back in November, GT Advanced announced the deal with Apple alongside third-quarter earnings. Apple would prepay GT $578 million in four installments to help fund the Arizona facility's capital expenditure requirements, and GT would begin reimbursing Apple over five years starting in 2015.

Source: Apple.

The company then guided 2014 revenue to a range of $600 million to $800 million, with the sapphire business comprising 80% of sales. Note that the sapphire business also includes furnace and equipment sales, but GT was also transitioning its business model to selling sapphire material itself.

GT initially declined to add color on the revenue mix, but it was safe to assume that Apple was expected to be a big part of 2014 revenue. Indeed, a subsequent 10-Q noted that "it is remote that any entity other than Apple will take more than a minor amount of sapphire material output from the ASF systems and related equipment in the Arizona facility." Translation: Apple is buying the bulk of sapphire output.

When announced, GT CEO Tom Gutierrez called the deal "a significant milestone in GT's long-term diversification strategy." I'm not so sure that relying on one customer for a huge chunk of sales fits the bill for a "diversification strategy." To be fair, GT is still looking to expand its reach in the photovoltaic and polysilicon markets, but the opportunities there still pale in comparison with the Apple deal, especially in the near term.

This all triggered the past year's speculation that sapphire would be included on the iPhone 6, which it was not.

How the deal was structured
Naturally, many aspects of this deal are shrouded in secrecy, with portions of the Master Development and Supply Agreement, or MDSA, redacted for confidentiality. But the corresponding 10-Q provides a brief overview:

On October 31, 2013, GTAT Corporation ("GTAT"), a wholly owned subsidiary of GT Advanced Technologies Inc, and Apple ("Apple") entered into a Master Development and Supply Agreement and related Statement of Work (the "MDSA"), pursuant to which GTAT will supply sapphire material exclusively to Apple for consumer electronics. GTAT has granted Apple certain intellectual property rights in connection with its sapphire growth technologies.

On October 31, 2013, GTAT also entered into a Prepayment Agreement with Apple pursuant to which GTAT will receive approximately $578 million (the "Prepayment Amount"), in four separate installments, as payment in advance for the purchase of sapphire goods. GTAT is required to repay this amount ratably over a five year period ending in January 2020, either as a credit against Apple purchases of sapphire goods under the MDSA or as a direct cash payment. GTAT's obligation to repay the Prepayment Amount may be accelerated under certain circumstances. GTAT's obligations under the Prepayment Agreement are secured by certain of its assets. While the MDSA specifies GTAT's minimum and maximum supply commitments, there are no minimum purchase requirements under the terms of the MDSA.

Per the Prepayment Agreement, GT would repay $28.9 million per quarter for five years starting in January 2015, paying off the balance by January 2020. As noted, this could come in the form of delivering sapphire materials to Apple as opposed to cold, hard cash. Apple has no obligation to actually purchase sapphire from GT, but it clearly has some interest in doing so.

Reading through the MDSA, it's quite clear that the deal was structured dramatically in Apple's favor. That's par for the Apple supplier course.

Which B of A do you prefer? 
One reason Apple was prepaying GT to help build the Arizona facility was the simple fact that GT was strapped for cash in the first place, which should have been the first red flag for investors. The Arizona facility was expected to cost approximately $550 million, which the Apple prepayments would cover.

Specialty sapphire products. Source: GT Advanced.

Here's another red flag. In the most recent annual report, where the company details its liquidity and capital position, it notes: "We fund our operations generally through cash generated by operations, prepayments made to us by Apple Inc., proceeds from our debt and stock offerings, and proceeds from exercises of stock awards."

It's not a good sign when the company is relying on irregular events like deals with Apple and capital offerings to fund operations. Last year's operating cash flow was negative $159 million. The company raised $290 million in capital by selling stock and debt in December 2013. Proceeds from exercises of stock awards were negligible.

In fact, there were already yellow flags predating the Apple deal, hinting that GT was struggling financially. In 2012, GT entered into a credit facility agreement with Bank of America, imposing various financial covenants. GT would have to maintain certain liquidity ratios of adjusted EBITDA to interest charges. In February 2013, the company amended this credit facility, waiving the covenants for a limited period of time. GT negotiated the amendments because it didn't think it could comply for much longer with the covenants related to its interest coverage ratios.

That bought the company some time, but people never like having creditors looking over their shoulder. GT paid off the final $96 million it owed under this facility the day before it officially inked the Apple deal. It's kind of like GT refinanced its debt with the Bank of Apple, which comes with a whole new set of iStrings attached.

iStrings
Over the past year or so, GT has been plunging hundreds of millions of dollars into capital expenditures related to the Arizona facility, mostly offset by Apple's prepayments. However, those prepayments are effectively secured debt with obligations, and GT was hoping to begin sapphire deliveries to repay what it owes.

Source: SEC filings.
*Disclosed in press release without additional data on prepayment obligation.

At the beginning of this year, management expected the company to end the year with $400 million to $500 million in cash. That's obviously not happening, and GT says it had $85 million in cash at the end of September.

The same should be true for sales. In August, GT guided 2014 revenue to a range of $600 million to $700 million, lowering the high end by $100 million. The company generated just $80.5 million in revenue for the first half of the year, meaning it still needs nearly $520 million in sales this year to hit the low end of its outlook. That's a tall order to fill.

A swing and a miss
After Apple's September event, analyst and vocal GT Advanced bull Matt Margolis issued a research report claiming that GT missed the iPhone 6 by mere "weeks." GT was shipping quite a bit of the material to sapphire finishers in China, but yields were low and couldn't meet Apple's volume requirements.

The "acceptance" section of the MDSA specifies that any sapphire goods "that do not comply with the requirements of the applicable Specifications, Purchase Order or this Agreement may be rejected," and GT had to cover any costs associated with returning defective goods. It's unclear if the sapphire was considered "defective," as Margolis believes the problems were with the finishers and not GT itself.

The company was expecting to receive the fourth and final $139 million prepayment from Apple by the end of this month, but only if it met "certain operational targets" that aren't publicly specified. Whatever these targets were, it seems that GT missed them, and shareholders are the ones paying the ultimate price for it.

Lessons learned
There's been a lot of debate about the merit of sapphire in smartphones. The material is highly scratch-resistant, more so than Corning Gorilla Glass, but its brittleness makes it more susceptible to breaking. By the looks of it, it seems that GT was expecting to win the iPhone, and it guided 2014 revenue as such.

It's not a stretch to say that GT management was betting the company on the Apple deal. Not necessarily operationally, since the company will continue to operate in bankruptcy as it restructures, but financially, as its capital structure was becoming increasingly reliant on the Apple deal.

The company has now buckled under the weight of its financial obligations. With Apple prepaying nearly $600 million that can be repaid in the form of sapphire goods, it still seems that the Mac maker has broader plans for the material, but that could be a longer-term product pipeline. As GT's short-term sapphire prospects hit a wall, its balance sheet lacked the financial fortitude to weather the storm. So much for the diversification strategy.