Iran may be about to emerge from decades of economic isolation -- at an absolutely terrible time for an oil-producing country.
Years of painful economic sanctions by the West have ravaged Iran's economy, sending unemployment and inflation soaring.
Now there's a glimmer of hope for Iran. The historic nuclear deal with the U.S. and its allies paves the way for sanctions relief. If the agreement is ratified, Iran will be able to export oil to Western nations and generate badly-needed revenue.
Here's the catch: Oil prices are tanking and may stay depressed for some time.
U.S. crude oil prices touched $41.21 a barrel on Thursday. That's the lowest price since early 2009 and down 60% from June of last year.
The price crash is hurting oil-exporting countries of all stripes.
But Iran's economy is coming off an extremely low base, after years of sitting in the penalty box. New oil exports won't bring in as much money as it would like, but it would still be more than where it is currently.
Still, Iran is expected to pump oil ferociously in an effort to make up for lost revenue.
"Iran has been talking a big game. They will try to look like they are coming back to oil markets with a vengeance," said Helima Croft, global head of commodity strategy at RBC Capital and a former analyst at the CIA.
Related: Iran is hiding more oil at sea than we realized
Iran needs higher oil prices
One problem for Iran is budgetary. To balance its budget, Iran needs oil prices to be at least $130 a barrel, or more, according to a Deutsche Bank analysis from 2014.
That's far higher than the prices listed in the budgets of Russia, Saudi Arabia and smaller countries like Kuwait and the United Arab Emirates.
One major reason Iran needs higher prices is because it has the second-highest population in the region and large social spending programs.
Iran deal could worsen the oil glut
But adding a ton of new Iranian crude to the global oil market at a time when prices are at 6-year lows would only worsen the situation.
Already, there's a huge supply glut, which helped cause the price meltdown in the first place. Iran will only add to the excess supply.
"We think it could be a bad couple of weeks for the oil market," said Croft.
Of course, the overall future is looking brighter in Iran. It's obvious that Iran is better off without sanctions than with them -- no matter where oil is trading. Sanctions relief will undoubtedly help its struggling economy.
It's also important to remember Iran is more than just oil and gas. The country has a much more diversified economy than many of its rivals. Sectors such as healthcare, finance and manufacturing stand to gain from sanctions relief.
Related: Why oil prices could sink to $15 a barrel
Cheap oil could slow investments in oil field upgrades
But cheap oil creates other serious headaches for Iran.
More than half of Iran's oil fields are over 70 years old, according to Phillipp Chladek, an oil analyst at Bloomberg Intelligence. These mature fields need serious upgrades in order to operate. That's one reason why analysts are very skeptical of Iran's claims that within months of sanctions relief it can ramp up production by one million barrels per day.
"They will need investment in new fields. Right now they're strapped for cash -- just like everybody else," said Matt Bey, an analyst at geopolitical intelligence firm Stratfor.
But Iran may not be able to count on large Western companies for these much-needed updates. These companies are already dialing back spending due to the crash in oil prices. It's possible that Big Oil may decide it's not worth it to bet on a risky country like Iran in today's depressed oil price environment.
"That's going to hurt Iran the most," said Bey.
Other analysts believe energy companies will not be able to resist the lure of Iran, which has 9% of the Middle East's proven global oil reserves and 18% of its gas reserves. Major European oil companies such as Royal Dutch Shell (RDSA) and Eni (E) met with Iranian officials in Tehran earlier this year to discuss business plans.
Related: Obama, Kerry exaggerate U.S. dollar risk if Iran deal killed
Some believe Saudi Arabia too will turn the screws on Iran -- its longtime regional rival -- by trying to keep prices very low.
"The Saudis' best weapon is the lowest oil price at maximum volume. They have enough financial reserves to have staying power for years," said David Kotok, chief investment officer at Cumberland Advisors.