The yellow horse-drawn gasoline tank is out in the open, on a busy highway that snakes along a poor slum in eastern Cairo. Trucks and cars stop to fill up. Pedestrians come by, too, with plastic containers to fill.

The yellow tank isn’t alone. Mini-tankers and canisters of illegal diesel fuel have become ubiquitous in Egypt. Vendors hawk the fuel in crowded neighborhoods, next to shops and idle police officers who do little to stop the sales.

Egypt’s rapidly expanding black market for fuel — and for foodstuffs, other commodities and U.S. dollars — may be the most tangible illustration of just how badly the economy of this vast Arab nation is failing, two years after the fall of Hosni Mubarak.

The prices of most basic goods, like fuel and flour, have been fixed for decades, with Egypt pouring roughly a quarter of its GDP into a bloated and deeply inefficient national subsidy system each year.

But after two years of political turmoil, weak governance, a devastated tourism industry and sapped investments, the government is quickly running out of money to foot the bill.

Egyptian economists say the government, confronted with reduced purchasing power, is buying less wheat and diesel from abroad. But they said it is unclear whether that is the main cause of the shortages, or whether the scarcity is driven mostly by the growing black market and the hoarding of goods by ordinary Egyptians who are anxious about the unstable economy.

One way or another, the supply of subsidized goods is drying up, breaking down the long-standing subsidy system and pushing those who can afford it to the black market.

Egypt is in negotiations for a $4.8 billion International Monetary Fund loan that financial experts say would alleviate some of the pressure and improve investor confidence enough to facilitate more badly needed loans and grants from abroad. But those talks have been stalled for months amid a volatile political crisis in Egypt that has delayed implementation of economic reforms needed to complete the deal.

In the meantime, Cairo drivers say they spend up to four hours waiting in line at state-subsidized gas stations that are almost sure to go dry by the afternoon.

“Sometimes they will only sell half of what they have, and then they’ll take the other half and sell it on the black market,” said Rafaat Mahmoud, 53, a taxi driver.

But waiting in line also means losing money in an increasingly desperate economy, so Mahmoud does what many other Egyptians do: He pays 22 percent more to buy the diesel on the black market, without having to queue up.

Before the revolution, there weren’t lines like these, many Egyptians say, viewing the Mubarak-era poverty as a sort of golden age compared with today’s reality.

Many accuse government workers of exploiting the shortages to pad their own pockets. Karim al-Nahas, a hotel worker, described waiting in line for subsidized butane cooking gas, which is officially sold for eight pounds, or $1.17, per canister. But “by the time you get inside the government store, it’s 12 pounds,” he said, because the worker manning the door demands a bribe.

Drop in reserves, currency

Officials play down the extent of the black market, but they acknowledge that they have limited control in a country marred by declining security and a culture of corruption inherited from Hosni Mubarak’s time.

Without the usual tourism revenue, and with limited foreign investment, Egypt has rapidly eaten through its foreign currency reserves, more than halving its $36 billion supply in just two years.

The value of the pound also has fallen sharply, and economists say Egyptians, anticipating a steeper drop, are increasingly converting their money to dollars.

“I just withdrew all my Egyptian money, and I’m spending it because I know its value next month will be half its value,” said Amirah el-Haddad, an associate professor of economics at Cairo University. “I’m trying to get rid of those pounds as much as possible. I’m sure every rational person will do that. They’ll buy gold, they’ll buy other currencies.”

On the street, it seems as if almost everyone is an amateur dollar dealer these days: convenience-store clerks, cellphone retailers, construction contractors, cigarette vendors — even employees at foreign embassies.

But the gold souk in eastern Cairo is where the business gets serious.

“I know what you want,” one shopkeeper, Amin Wassef, quickly greeted a visitor this month. “You want to know how much.”

The Egyptian Central Bank has frantically tried to limit the fluctuation of the pound, officially valued at 6.90 to the dollar. But in the souk — where the black-market dollar exchanges happen daily in front of swarms of police officers — the rate has climbed over the past few months to more than eight pounds to the dollar.

Subsidy systems and fixed currency rates work only if a government has the cash and the “iron fist” to regulate them, Haddad said. Egypt is short on both, she said.

Instead, a defective legal system and entrenched corruption, as well as poor government handling of the economy, have facilitated the black market’s rise and heightened public anger and anxiety.

Economists say the embattled government of Islamist President Mohamed Morsi, which has faced growing opposition in recent months, has only enough cash to fund the subsidies for a few months. But it lacks the political support needed to carry out the massive spending cuts that economists say are necessary to keep Egypt afloat and secure the IMF loan.

Christine Lagarde, the IMF’s managing director, said last week after meetings with Egyptian opposition leaders that politics in Egypt had forced the fund “back to the drawing board,” suggesting that a loan is unlikely to come anytime soon.

Austerity measures

That reality has sent government officials scrambling to secure small grants and loans from elsewhere — including a recent pledge from Qatar to buy $3 billion in Egyptian government bonds — to avert price increases that could spark riots.

Rolling government-sanctioned blackouts have begun to ripple through the country. But the cut that many Egyptians say they fear the most is bread, the sustenance of the 85 million population.

The government imports nearly half its wheat from abroad and subsidizes it so heavily that Egyptians can still buy 20 flat, round loaves for less than 15 cents.

But many subsidized bakeries have been running out of bread as quickly as gas stations run out of diesel. The reason, many here say, is that some of the flour is being sold for higher prices on the black market.

This month the state shifted its subsidy from the flour to the bread itself, hoping to stifle illegal sales and keep cheap loaves coming. But bakers say they know the end is near.

“At the end of each month, we clasp our hearts because we never know if that will be the month that the government has no money to pay us,” said bread-seller Mohamed Fathallah.

The arrival of flour has slowed, he said. On other days, the diesel to fuel the ovens never shows up. Last month, bakers twice stormed the Ministry of Supply and Internal Trade to protest proposed subsidy changes and steeper fees.

Any further government cuts will probably face the fiercest backlash from the middle class and from the business community, which has benefitted from years of subsidized energy. But it is the millions of poor in this country, where about 40 percent live on less than $2 a day, who would be hit the hardest.

In the neighborhood known to many as the City of the Dead, a sprawling district of ancient tombs and mausoleums that has transformed into a slum over the decades, bakers say they can feel the country’s slow demise between the tips of their fingers.

In the stifling heat of a bakery, Ahmed Mohamed reached for a sack and scooped out a handful of the high-quality flour that he said keeps getting rarer.

Taken from another sack, the bad stuff, which includes more local wheat, slides between his fingers like sand.

“We take ants, cockroaches and worms out of it every morning before we bake it,” he said.

Outside the bakery, Nahas, the hotel worker, laughed at what he deemed the sad predictability of it all.

“We have two to six months before the whole thing collapses. It’s going to happen. There is no way out of it.”

Sharaf al-Hourani and Lara El Gibaly contributed to this report.