Turkey looked set to return to single-party rule after the Islamist-rooted AK Party swept to an unexpected victory in elections on Sunday, an outcome that will boost the power of President Tayyip Erdogan but may sharpen deep social divisions.
With almost all ballots counted, the AKP had taken just shy of 50 percent of the votes, comfortably enough to control a majority in the 550-seat parliament and a far higher margin of victory than even party insiders had expected.
Prime Minister and AKP leader Ahmet Davutoglu tweeted simply "Elhamdulillah" (Thanks be to god), before emerging from his family home in the central Anatolian city of Konya to briefly address crowds of cheering supporters.
"Today is a victory for our democracy and our people ... Hopefully we will serve you well for the next four years and stand in front of you once again in 2019," he said.
A senior official from the main CHP opposition, which had calculated on 'reining in' Erdogan's influence with a coalition government, described the result as "simply a disaster".
The result could aggravate deep splits in Turkey between pious conservatives who champion Erdogan as a hero of the working class, and Western-facing secularists suspicious of his authoritarianism and Islamist ideals.
In the mainly Kurdish southeastern city of Diyarbakir, security forces fired tear gas at stone-throwing protesters after support for the pro-Kurdish opposition fell perilously close to the 10 percent threshold needed to enter parliament.
In June, the AKP lost the overall majority it had enjoyed since 2002. Erdogan had presented Sunday's polls as a chance to restore stability at a time of tension over Kurdish insurrection and after two bombings, attributed to Islamic State, while critics fear a drift to authoritarianism under the president.
With 97.5 percent of votes counted, the AKP was on 49.4 percent, according to state-run broadcaster TRT. The main opposition CHP was at 25.4 percent and a senior official said any hopes of a coalition now looked all but impossible.
"This is a success exceeding our expectations," one senior AKP officials told Reuters, acknowledging surprise over the scale of the victory.
Since June's poll, a ceasefire with Kurdish militants has collapsed, the war in neighbouring Syria has worsened and Turkey - a NATO member state - has been buffeted by two Islamic State-linked suicide bomb attacks that killed more than 130 people.
Investors and Western allies hoped the vote would help restore stability and confidence in an $800 billion economy, allowing Ankara to play a more effective role in stemming a flood of refugees from neighbouring wars via Turkey into Europe and helping in the battle against Islamic State militants.
WAITING FOR SIGNS
The lira currency firmed to its strongest in 2-1/2 months on the results. Investors had been pricing in a coalition, but the prospect of a strong stable government - even a polarising one - appeared to offer relief after months of uncertainty.
Erdogan's crackdowns on media freedoms and tightening grip on the judiciary, following a corruption investigation that was shut down as an attempt to overthrow him, have alarmed European leaders. A large number of journalists and others have faced court proceedings for "insulting the president".
Foreign capitals as well as Turkish media and other organisations will be watching closely for signs as to whether a harsh climate will continue or government relaxes its grip.
Erdogan and the AKP have been a fierce critics, for example, of U.S. support for Kurdish militia fighters battling Islamic State (IS) across Turkey's border in neighbouring Syria.
"This (result) makes more difficult a strategy of using the Kurds against IS because AKP appeals to anti-Kurd sentiments," said Bruce Riedel, a former CIA analyst and sometime policy advisor to U.S. President Barack Obama.
The pro-Kurdish HDP, which scaled back its election campaign after its supporters were targeted in the Ankara suicide bomb attack that killed more than 100 people on Oct. 10, was on 10.6 percent, according to TRT. It won 13 percent in June.
The nationalist MHP, which was another casualty of the rise in AKP support, saw its share of the vote drop to 12 percent from 16.5 percent in June.
This time, there were few of the flags, posters and campaign buses that thronged the streets in the build-up to June's vote.
The election was prompted by the AKP's inability to find a junior coalition partner after the June outcome. Erdogan's critics said it represented a gamble by the combative leader to win back enough support so the party can eventually change the constitution and give him greater presidential powers.
Erdogan, Turkey's most powerful leader in generations, resigned as prime minister last year and became Turkey's first directly elected president - with the aim of transforming it from a largely ceremonial position to a strong executive post.
The AK Party still seems unlikely to get a majority big enough to change the constitution; but with AK the sole party in power, he will be able to reassert his influence over government from the grandeur of his newly built presidential palace.
"Turkey lost considerable ground in economy, politics and terror during this period, and gains were lost. Voters appeared to want to bring back stability once again," a third AKP official said.
Some Western allies, foreign investors and Turks had seen an AKP coalition with the CHP as the best hope of easing sharp divisions in the EU-candidate nation, hoping it might keep Erdogan's authoritarian instincts in check.
Voters appeared sharply divided in their views on a return to single-party rule or the prospect of a coalition.
"The little welfare, better living conditions, bigger house and fancier appliances we have, we all owe it to AK Party and Erdogan," said Nurcan Gunduz, 24, at the airport in Ankara.
"Look at the state of the country after the June 7 election results and we didn't even have a coalition government. I can't imagine how much worse it would be if we did have it."
But Yasar, a 62-year-old retired labourer now working as a shoeshine man outside a mosque in the conservative Istanbul district of Uskudar, said he switched his vote to the main opposition CHP in hopes of a coalition.
"I've given up on the AKP. The honest party is the CHP. The country needs to heal its wounds and a coalition is the best way."