Having survived Republican opposition in Congress, President Obama's nuclear deal with Iran will soon go into effect. Here, a brief rundown of the deal and its effects:

What does the deal do?
It significantly inhibits Iran's ability to develop nuclear weapons, in exchange for relief from crippling economic sanctions. Forged over 20 months of intense negotiations among Iran, the U.S., and five other world powers, the Joint Comprehensive Plan of Action is designed to block four possible pathways to the bomb for 10 to 15 years. Iran must relinquish 97 percent of its enriched uranium stockpiles; remove two-thirds of its 20,000 uranium-enriching centrifuges; rebuild its heavy-water reactor so that it cannot produce weapons-grade plutonium; and submit to ongoing, intrusive inspections. These measures are designed to increase Iran's "breakout time" to developing nuclear weapons from the current three months to at least a year. Republicans and Israel strongly opposed the deal, saying it does not guarantee that Iran won't cheat, and may only postpone the Islamic Republic's development of a nuclear weapon. But President Obama insisted that the choice was between a negotiated deal and war. "How can we in good conscience justify war," he asked, "before we've tested a diplomatic agreement?"

When does the deal go into effect?
It will formally be adopted on Oct. 19, but "implementation day" won't be until the United Nations' International Atomic Energy Agency (IAEA) confirms that Iran has complied with all its obligations. Every stage of Iran's nuclear-fuel supply chain — uranium mines and mills, enrichment plants, centrifuge factories — will be monitored by up to 150 IAEA inspectors, 24/7 video surveillance, and high-tech sensors. If Iran does cheat, said Aaron Stein, a nuclear nonproliferation expert, "the likelihood of getting caught is near 100 percent."

Can the inspectors go wherever they want?
No — and that's the key objection of the deal's critics. While inspectors will have unrestricted access to specified, existing nuclear facilities, they'll require Iranian permission to visit any other site — military or otherwise — they deem "suspicious." If Iran refuses, it will have 24 days to convince first the IAEA and then a special Western-majority U.N. panel — comprising the U.S., the U.K., France, Germany, the EU, Russia, China, and Iran itself — that its objections are valid. If five of the eight countries on that panel do not vote to support Iran, the U.N.'s sanctions will automatically "snap back" into place. Critics say this 24-day period gives the regime ample time to cover up evidence of any illicit activity. The deal's defenders argue that no nation would agree to "anytime, anywhere" inspections throughout its territory unless it had been conquered militarily.

Will the sanctions snap back?
The U.S. has majority support on the special panel, so Iran cannot be bailed out by its traditional backers, China and Russia. It is therefore likely that cheating will result in the reimposition of sanctions. But Mark Dubowitz of the Foundation for Defense of Democracies, a conservative think tank, argues that the Obama administration, and perhaps following administrations, will only take that step if "massive" Iranian violations are discovered. "You're certainly not going to risk engaging in nuclear escalation over smaller violations," Dubowitz says.

Is Iran likely to violate the deal?
The Islamic Republic does have a long history of deception and obfuscation. U.S. intelligence believes the regime was secretly pursuing the development of a nuclear weapon until 2003. In 2006, sanctions were imposed amid reports the country wasn't complying with the Nuclear Non-Proliferation Treaty. Iran has also refused to allow the IAEA to inspect the Parchin military facility for evidence of past nuclear activity — instead, in what critics called a "selfie inspection," Iranian officials collected dirt and air samples themselves under IAEA observation. But now that Iran has gotten sanctions relief, cheating would be a high-risk gamble that could cost Iran hundreds of billions of dollars a year in revenues. The dropping of sanctions should double Iran's oil exports, and provide an immediate windfall of up to $150 billion.

What happens when the deal expires?
That's unknown. Iran could race to build a bomb within months and dare the West and Israel to respond, or a new deal could be negotiated. Obama's hope is that over 15 years, the fundamentalist Islamic hard-liners' grip on Iran will loosen, and that the country will come to see that global integration is preferable to isolation. In the short term, defenders argue, half a loaf is better than none. "If I knew for certain that in five years they would cheat or renege, I'd still take the deal," says Gary Samore, the former president of the group United Against Nuclear Iran, who became a supporter of the accord when he saw its details. "We will have bought a couple of years, and if Iran cheats or reneges we will be in an even better position to double down on sanctions or, if necessary, use military force."

Some very personal diplomacy
The long negotiations in Austria and Switzerland that led to the deal were a roller-coaster ride of conflicting agendas, growing personal friendship, and explosions of anger. On one occasion, recounts Robin Wright in The New Yorker, Iranian Foreign Minister Mohammad Javad Zarif announced he was leaving, then "sat on a chair against a wall and put his head in his hands." Later that day, U.S. Secretary of State John Kerry slammed his hand on the table so hard it sent a pen flying into the air, and it hit one of the Iranians. During another impasse, a Kerry staffer had to warn the two men that their shouting could be heard from down the hotel corridor. But the two men also developed a rapport. When Kerry broke his leg cycling, Zarif was among the first to contact him to express his sympathy. The two teams ate together — Persian food — for the first time shortly before the deal was struck; both Kerry and Zarif commiserated about the pressures they were receiving from home. In their final meeting, the diplomats sent their aides out of the room, and hammered out the final details alone. "All of the mistrust that has been there for these decades remains," said a State Department official. "But it fights against the fact that we've spent two years getting to know each other."