Havana (CNN) Less than a month after seizing power in 1959, Fidel Castro embarked on his first trip as leader to seek support for his revolution. The young rebel leader's destination wasn't Moscow or Washington, it was Caracas.

Venezuela's government had secretly supported Castro and his rebels with funds and weapons during their fight to oust US-backed dictator Fulgencio Batista. Now a victorious Castro had a new request: Loan Cuba $300 million dollars worth of oil.

The oil shipments would be "a master trick on the gringos," Castro told then-Venezuelan president Rómulo Betancourt, breaking Cuba's economic dependence on the US. Not wanting to upset Washington, Betancourt frostily replied that if Castro wanted Venezuelan oil, he should buy it on the open market.

But Castro got what he wanted, in the end. Today, Venezuelan oil is the lifeblood of Cuban economy, under a barter system where Cuba receives billions of dollars of crude in exchange for Cuban doctors, teachers, sports trainers, and military and intelligence advisers. And now, as political unrest threatens the Maduro régime in Caracas , it also threatens to put the lights out in Havana.

Maduro's rival, Juan Guaidó, has vowed to end Cuban influence in Venezuela , and any change in government could upset the special relationship between the two countries. Shipments from Venezuela have become less frequent, and Cuba is hurrying to expand how much oil it can store. "Our calculation is Cuba has 5 million barrels of total primary storage," says Jorge Piñón, a Cuba energy expert at the University of Texas in Austin. "I am saying if Cuba has a crisis, Cuba has enough oil to last them 35 to 45 days."

So far Cubans have not experienced a shortage. But many still remember the painful end of another special relationship, which led to widespread blackouts and drove Cuban refugees toward the United States: the so-called "Special Period" in the 1990s, when the USSR collapsed.

Cuba, the Soviet Union, and a painful "Special Period"

When Castro first approached Venezuela in 1959, he envisioned a leftist government in control of its massive oil riches, which could support like minded regimes across the region and finally challenge Washington's control of the hemisphere.

Instead of Venezuela, it was the Soviet Union that ultimately provided crucial support to the Cuban revolution, becoming the island's main trading partner and sending thousands of military and intelligence advisers to island. But Castro never forgot Venezuela's potential, and backed several failed attempts at revolution beginning in the 1960s.

Mikhail Gorbachev with Fidel Castro in 1989.

After the dissolution of the Soviet Union in 1991, Cuba found itself in dire need of new friends. The economy on the communist-run island had all but collapsed without Soviet support. Called " the Special Period " in Cuba, Cubans endured wartime food rations, daily blackouts of electricity while thousands of citizens fled the island on rafts.

In 1998, the stars seemed to align for the Cuba-Venezuela alliance that Castro had dreamed of: Hugo Chavez, a charismatic former Army paratrooper, was elected to the Venezuela's presidency. Like Castro, Chavez had led a thwarted uprising but used that failure to raise his profile.

Young Hugo Chavez as a presidential candidate.

After time in jail, Chavez came back to win an upset victory. Both men could speak for hours, casting a spell over their supporters, and both swore to erase the gap between rich and poor in their countries.

Castro would eventually take the role of the elder statesmen, and Chavez his heir to the mantle of the leader of the Latin American left.

Access to "the largest oil reserves on the planet"

In the early 2000s, Castro and Chavez struck a barter deal that pulled Cuba from the depths of its economic crisis with generous dose of petroleum. "Cuba got access to the largest oil reserves on the planet, in exchange for sending doctors and coaches and intelligence advisers and military advisers," Geoff Ramsey of the Washington Office on Latin America tells CNN.

Soon Venezuela was sending the island roughly 100,000 barrels of oil a day to the island. In exchange, Cuban doctors set up clinics for the poor — Chavez's political base — in Venezuela's most downtrodden neighborhoods, and thousands of Venezuelans traveled free of charge to Havana for medical treatment of everything from cataracts to gunshot wounds.

With oil flowing in from Venezuela, Cuba was able to pay off longstanding debts and revamp the island's faded tourism industry. The workers-for-oil deal generated more income than rum, cigars or anything else Cuba produced. The island's citizens became its main export. Cuban workers returned from postings in oil-rich Venezuela carting flat-screen TVs, bottles of whiskey and other hard-to-find items back home.

Chavez took to proclaiming that Cuba and Venezuela were not two countries, but a single one: La Gran Patria, or "the Big Homeland." He frequently popped over to Havana for strategy sessions and to play late night baseball games with Castro.

Castro talks with Chavez before a friendly baseball game between the Cuban and Venezuelan teams, in Venezuela in 2000.

Castro gave Chavez a sprawling mansion next to the North Korean ambassador's residence. The Cuban government had originally spent a small fortune restoring the house's frescoed ceilings and yards of marble from every region in Italy for Pope John Paul II's 1998 visit. But the pontiff preferred simpler lodging, and the house became Chavez's.

"Desenchúfalos!": Calls to disconnect "Cuba-zuela"

Venezuela's political opposition criticized the two leaders' tight friendship, saying Castro had all but taken over their country and accusing Cuba's intelligence services of monitoring Chavez's own military for loyalty. Desenchúfalos or "disconnect them" became a rallying cry of the Venezuelan opposition, referring to the Cubans.

When Chavez was briefly ousted by the Venezuelan military, Fidel Castro called him by phone and urged him to take power back. "Are you president still or not?" Castro told him, according to Cuba's state-run press. Chavez regained control of the country.

When Chavez announced he had pelvic cancer in 2011, he flew to Havana for treatment. Venezuelan officials in the city attended a public ceremony of the Afro-Caribbean Santería religion meant to safeguard Chavez. When his death was announced in March 2013, Havana officials announced three days of official mourning and banned live music from being played in public.

The alliance continued with Chavez's handpicked successor Nicolas Maduro, a former bus driver who had studied in Cuba in his youth. But Venezuela's oil production plummeted, as Chavez stacked the country's oil industry with loyalists who mismanaged the country's principal export.

A downturn for Venezuela

As Venezuela's economy tanked, soon it was the Venezuelans working in Cuba who returned home with bags packed with toilet paper, toothpaste, soap and other items that had disappeared from store shelves back home.

Supporters of Chavez light candles in front of the Venezuelan Embassy in Santiago, Chile, in 2013.

Cuba now receives about 50,000 barrels of oil a day from Venezuela, about half of what it did during its neighbor's boom years, estimates Piñón, the energy expert. Although analysts believe that Cuba has also recently imported oil from Russia and Algeria, it is unlikely that the island enjoys the same favorable terms that it receives from its socialist ally and neighbor.

As Guaidó demands new elections in Venezuela and heads of state around the world weigh in on the country's future, it's not just the local opposition calling to disconnect the bond between Caracas and Havana.

On Monday, US National Security Adviser John Bolton blamed Chavez and Maduro for allowing Venezuela's "penetration by adversaries of the United States, not least of which is Cuba. "Some call the country 'Cuba-zuela', reflecting the grip that Cuba's military and security forces have on the Maduro regime," he said. "We think that is a strategic significant threat to the United States."

Bolton also announced new sanctions on Venezuelan oil , which could cripple the tottering Venezuelan oil industry, and further shrink its supply to Havana.

Cuban officials have said they will not abandon their Venezuelan comrades. But US officials are eyeing Cuba as the key to forcing embattled president Nicolas Maduro's resignation.

Pressure Cuba, their reasoning goes, and Cuba will pressure Venezuela.