It was June, and Aegean Marine was tapped out.

The bunker and tanker company was practically cut off from borrowing money, and thus unable to buy enough fuel to keep up with customer demand. By mid-2018, several critical hubs had run dry.

Aegean Marine was caught in a tailspin that, as laid out in court papers, began the year prior and ended with the former fueling giant landing in chapter 11 bankruptcy Tuesday.

"The need to commence these Chapter 11 cases was a perfect storm of circumstances that nearly forced Aegean to liquidate in during the summer of 2018," director Tyler Baron wrote in a declaration included in the company's bankruptcy filing.

Aegean's business began to slow in the second half of 2017 in the face of what Baron, put on the board by dissident shareholders in May, called a "hyper saturated market."

The company's volume remained depressed into 2018, but a February proposal to buy HEC Europe — a company owned by departed founder Dimitris Melisanidis — for $367m spooked lenders. So did a lack of audited financial statements to date in 2018 and concerns over $200m in uncollected accounts receivable.

Lenders cut the company's line of credit from $1bn in March to $600m in May. Some asked Aegean Marine to prepay or sign a letter of credit before borrowing.

Without money to buy fuel, "Aegean's volumes (dropped) to levels well below break-even," Baron wrote.

And without fuel, customers fled.

Aegean Marine's ability to borrow continued to dwindle. In June, it announced it would have to write off the $200m as the business was done with shell companies controlled by an unnamed "former affiliate" and had no economic substance. On the day of the announcement Aegean Marine stock cratered 75%.

"In fact, on multiple business days during June 2018, the company had zero borrowing base availability and thus no liquidity, causing fuel inventories in certain critical supply hubs to virtually run dry," Baron said.

"These events, coupled with a reduced borrowing base and available liquidity, forced (Aegean Marine) into a negative feedback loop that proved insurmountable," Baron added.

In July, the company cut a deal with Swiss commodities trader Mercuria Energy to become its sole lender.

Mercuria continues to provide Aegean Marine backing, offering $532m in post-petition financing, and intends to serve as a stalking-horse bidder in a sale process that would offer Aegean as a continuing business.