CARTAGENA, Colombia (Reuters) - Colombia’s center-right government and the Marxist FARC rebel group signed a peace deal on Monday to end a half-century war that killed a quarter of a million people and once took the Andean country to the brink of collapse.

After four years of peace talks in Cuba, President Juan Manuel Santos, 65, and rebel leader Timochenko - the nom de guerre for 57-year-old Rodrigo Londono - warmly shook hands on Colombian soil for the first time and signed the accord with a pen made from a bullet casing.

A crowd of dignitaries chanted: “Long live Colombia, long live peace” as Santos handed Timochenko a white dove pin. One man waved a large Colombian flag that had an extra white stripe in homage to the peace deal.

“The horrible night of violence that has covered us with its shadow for more than half a century is over,” Santos said through tears. “We open our hearts to a new dawn, to a brilliant sun full of possibilities that has appeared in the Colombian sky.”

Colombians will vote on Sunday on whether to ratify the agreement, but opinion polls show it should pass easily.

Attendees at the event, many of whom also wept, observed a minute of silence in memory of those killed, maimed, raped, kidnapped and displaced during the war.

The end of Latin America’s longest-running war will turn the FARC guerrillas into a political party fighting at the ballot box instead of the battlefield they have occupied since 1964.

“No one should doubt that we will conduct politics without arms,” said Timochenko, who asked for forgiveness from FARC victims. “We are all prepared to disarm in our minds and our hearts.”

Guests at the ceremony in the Caribbean coastal city of Cartagena were asked to wear white and included United Nations Secretary-General Ban Ki-moon, Cuban President Raul Castro and U.S. Secretary of State John Kerry.

Showing its support for the peace deal, the European Union on Monday removed the FARC from its list of terrorist groups.

Kerry said Washington would also review whether to take the FARC off its terrorism list, and has pledged $390 million for Colombia next year to support the peace process.

“Anybody can pick up a gun, blow things up, hurt other people, but it doesn’t take you anywhere. ... Peace is hard work,” he said of a rare diplomatic good news story for the Obama administration as it contends with the seeming intractable war in Syria and other conflicts.

Slideshow ( 9 images )

FIERCE WAR

In the worst days of the war, attacks shook the capital, Bogota, which rebels threatened to overrun, and battles between the guerrillas, paramilitaries, drug gangs and the army raged in the countryside, parts of which remain sown with landmines.

Thousands of civilians were killed in massacres, especially in rural areas, as the warring sides sought to prevent people from collaborating with or supporting enemy forces.

Despite widespread relief at an end to the bloodshed and kidnappings of the past 52 years, the deal has caused divisions within Latin America’s fourth-largest economy.

Slideshow ( 9 images )

Former President Alvaro Uribe and others are angry the accord allows rebels to enter parliament without serving any jail time.

In Cartagena on Monday, huge billboards urged a “yes” vote in the referendum, while Uribe led hundreds of supporters with umbrellas in the colors of the Colombian flag urging voters to back “no.”

The FARC, or Revolutionary Armed Forces of Colombia, which began as a peasant revolt, became a big player in the cocaine trade and at its strongest had 20,000 fighters. Now, its some 7,000 fighters must hand over their weapons to the United Nations within 180 days.

Colombians are nervous over how the rebels will integrate into society, but most are optimistic peace will bring more benefits than problems.

“This is the moment, it’s now or never,” said 50-year-old lawyer Melquis Pulecio, as he watched the ceremony with thousands of others on a big screen in central Bogota. “We are tired of this war - we were born to war.”

Colombia has performed better economically than its neighbors in recent years, and peace should reduce the government’s security spending and open new areas of the country for mining and oil companies.

But criminal gangs may try to fill the void in rebel-held areas, landmines hinder development and rural poverty remains a huge challenge.

With peace achieved, Santos, a member of a wealthy Bogota family, will likely use his political capital to push for tax reforms and other measures to compensate for a drop in oil income caused by a fall in energy prices.

“It’s such an important day,” said Duvier, a nom de guerre for a 25-year-old rebel attending a FARC congress last week in the southern Yari Plains that ratified the peace accord. “Now we can fight politically, without blood, without war.”