CARACAS - How did Venezuela, once Latin America's richest country, sink into ruin? As the country faces a presidential election Sunday, here are four key elements in the unraveling of its economy.
OIL BOOM BRINGS DOLLARS
The country with the largest oil reserves on the planet enjoyed more than a decade of abundance between 2004 and 2015, pulling in some $750 billion while the price of crude soared.
Heavily dependent on oil, which accounts for 96 percent of its foreign earnings, late president Hugo Chavez took advantage of the oil boom to borrow heavily.
Venezuela issued some $62 billion in sovereign bonds from the state oil company PDVSA, according to the consultants Ecoanalitica, and borrowed also from China and Russia. External debt increased fivefold to $150 billion. Foreign reserves were 42.3 billion in 2008, now reduced to a quarter of that.
Government spending soared, so much that in 2012 the budget deficit rose to 15.6 percent of GDP, while oil was selling at a record $103.42 a barrel.
That deficit "was the equivalent of Greece at its worst," said Oxford University economist Orlando Ochoa.
And the situation has not improved, with the deficit oscillating between 15 and 20 percent of GDP since 2013, according to Humberto Garcia, president of the National Academy of Economics.
The government says it spent $718 billion on social programs between 1999 and 2014.
IRON RULE AND CORRUPTION
The socialist leadership imposed an iron fist on the economy, nationalizing entire sectors such as cement and steel, while expropriating hundreds of companies.
It brought in strict exchange controls in 2003, which allowed it to monopolize the dollar exchange and artificially overvalue the local currency, the bolivar.
It also imposed price controls, which undermined industrial production.
"This promped the private sector to replace production with cheap imports," said Ochoa. Today, production covers only 20 percent of consumption, compared to 70 percent in 2008, according to Fedeagro.
One of the perverse effects of this state control was corruption. Some firms resorted to inventing phantom imports, overcharging for contracts or diverting dollars to the black market, where the greenback is worth 12 times more than the official rate.
Jorge Giordani, Chavez's economic guru, estimates that $300 billion has been lost to corruption over the past decade.
OIL PRICE COLLAPSE
Venezuela's horizon darkened when the price of oil began to fall, from over $98 a barrel in July 2014 to just over $47 by the end of that year. It averaged just over $35 in 2016.
The country's oil-dependent revenues took a massive hit. They melted away from $121 billion to $48 billion between 2014-16.
In the absence of investment in its infrastructure, PDVSA's production collapsed from 3.2 million barrels a day to just 1.5 bpd last March, according to OPEC.
In response, the government cut foreign currency imports and distribution to the private sector, compounding shortages of food and medicine. Inflation meantime soared, reaching 13,800 percent this year, according to the IMF.
Imports, from $66 billion in 2012, will pull in only $9.2 billion in 2018, according to an Ecoanalitica forecast.
The spiraling crisis has nibbled away at wages -- the minimum wage now buys only half a kilo of meat -- and ruined a country whose GDP, the IMF says, has declined by 45 percent since 2013.
These are "indicators of a country at war," said Asdrubal Oliveros of Ecoanalitica.
The final stage of the country's descent into economic hell came when Venezuela and PDVSA were declared in partial default at the end of 2017. The country faces repayments of $10 billion a year.
President Nicolas Maduro, who claims to be the victim of an "economic war" waged by the United States, has announced a debt renegotiation, but is faced by Washington's ban on Americans buying Venezuelan bonds.
The US has also threatened an oil embargo, a catastrophic scenario given that Washington buys a third of local production and provides 75 percent of liquidity.
The Venezuelan crisis is summed up in a recent report by the IMF as "one of the worst in the world" in the last 50 years.
© Agence France-Presse