Ivan Duque, a law-and-order disciple of a powerful former president, won Sunday's vote with a commanding 12-point lead over rival Gustavo Petro, a former rebel and ex-Bogota mayor.

BOGOTA, Colombia — Uncertainty loomed over Colombia's fragile peace deal on Monday with the victory of one of its most hawkish critics in a bruising presidential runoff that laid bare deep divisions in the South American nation as it emerges from decades of bloody conflict.

Ivan Duque, a law-and-order disciple of a powerful former president, won Sunday's vote with a commanding 12-point lead over rival Gustavo Petro, a former rebel and ex-Bogota mayor.

On the campaign trail, Duque repeatedly vowed to roll back benefits inscribed in the deal, such as demanding that rebel commanders behind scores of atrocities first confess to their war crimes and compensate victims before they are allowed to take up the congressional seats they have been promised in the accord.

But once he takes office in August from the peace deal's architect, President Juan Manuel Santos, Duque is likely to tread softer if he wants to broaden his base of support and unite the country, analysts said.

"Ironically, he has a chance to make the accords stronger by providing something the peace process has lacked from the outset: a national consensus," said Michael Shifter, a longtime observer of Colombia and president of the Inter-American Dialogue in Washington.

This year's elections were the safest in generations, a testament to how far the country has already come in putting Latin America's longest-running conflict behind it. Not a single act of violence affected the campaign.

In the final stretch before the vote, as victory seemed within reach, the pro-business Duque was already moderating some of his proposals, including a call to overturn a negotiated amnesty for rebels involved in drug trafficking. He also stressed that rank-and-file guerrillas of the Revolutionary Armed Forces of Colombia would have his full support in making their transition to civilian life.

While Santos didn't endorse any candidate and has feuded with Duque's mentor, former President Alvaro Uribe, throughout his eight years in office, two of Santos' advisers on the peace process have quietly migrated to the Duque camp in recent months, which is likely to make for a smoother transition.

"This is the opportunity that we have been waiting for," the 41-year-old Duque said in his victory speech, playing up his youth — he is the youngest Colombian president ever elected in a popular vote — and pledging "to turn the page on the politics of polarization, insults and venom."

His biggest challenge will be reining in the pressure from conservative allies. As a senator Duque earned a reputation for being a thoughtful, cordial adversary who frequently stretched his hand across the aisle, but some of his prominent backers are outright hostile to the FARC. Hours after his victory, congresswoman Maria Fernanda Cabal blasted on social media: "The FARC lost. Colombia won!"

One unknown is how much influence Uribe will wield. Duque was elected to Colombia's Senate in 2014 barely two months after returning to Colombia from Washington, where he had worked for more than a decade at a development bank, thanks to Uribe's endorsement. Throughout his presidential campaign, he was dogged by accusations that he would be little more than a puppet for Uribe, who is constitutionally barred from seeking a third term. Though praised for weakening the FARC and drawing record foreign investment, Uribe has also been blamed for the military's killing of thousands of civilians who were falsely accused of being rebels.

"He will have to make some adjustments to the accord, if only to placate Uribe and other hard-liners and avoid being labeled a traitor," Shifter said. "But these could be relatively modest and not put the entire peace effort at risk."

It's also not clear how much leeway there is to make changes to the 310-page accord that put a formal end to a conflict that caused more than 250,000 deaths. Colombia's constitutional court has declared some aspects of the agreement irreversible. For Duque to prevail in his call for substantive "corrections" that deliver "peace with justice," he'll likely need to build political support in Congress that he currently lacks to pass a constitutional reform.

Among the rebels there is concern — and some goodwill.

The FARC has already accepted changes to the accord once before, after the original deal was rejected by voters led by Uribe in a referendum. After Sunday's election victory, ex-guerrilla leader Rodrigo Londono immediately congratulated Duque and said Colombians should work together because "the road of hope is open."

"The truth is we're worried," said Elkin Sepulveda, who joined the FARC at 15 and is now trying to launch an organization to help ex-combatants disabled during the conflict. He's living in a rural camp in northern Colombia where some 200 rebels are catching up on their studies and learning new skills needed to reintegrate into civilian life.

Even before the election, implementation of the accord had been slow going and rebel commanders have complained that the recent arrest of a former rebel peace negotiator on U.S. drug charges could lead some of the 7,000 fighters who've surrendered their weapons to join dissident rebel factions or criminal gangs that have proliferated in former FARC-dominated areas.

"We hope that the next government complies with the peace accords," said Virginia Lobo, a FARC militant living in the same camp. "Nobody wants to return to war."

In addition to dealing with the rebels, Duque will have to contend with a weak economy, a migration crisis spurred by neighboring Venezuela's collapse and a boom in illegal coca crops that has tested traditionally close relations with the U.S.

As part of the peace process, Santos had been betting heavily on a coca crop substitution program that has so far failed to reduce the supply of cocaine, leading the Trump administration to warn last year that it could decertify Colombia as a partner in the war on drugs. Last week, the government said the amount of land dedicated to coca production surged 23 percent last year, to 180,000 hectares, a level unseen in decades.

In March, Duque said he'd bring back a controversial aerial coca eradication program that Santos ended over health concerns. In his victory speech on Sunday, he said the rise in coca production threatens Colombia's national security.

"Duque has the opportunity to be sort of like Nixon going to China," said Bernard Aronson, who was the Obama administration's special envoy to the Colombia peace talks. "I think he's smart enough to know that not to pursue a pragmatic route could start his presidency off with a big crisis."