ISTANBUL (Reuters) - Any Turkish hopes that a crisis with the United States might be eased by personal chemistry between their two leaders hit the rocks this week when President Donald Trump directly warned Turkey of possible sanctions over a detained U.S. pastor.

With hostility to Ankara growing in Congress over disputes ranging from the fate of Christian pastor Andrew Brunson, Iran sanctions and Turkey’s plans to buy a Russian missile defense system, Turkish officials have seen Trump as a possible shield against the worst fallout from the collapse in ties.

But in a relationship plagued by recrimination, mutual misunderstanding and apparently irreconcilable Middle East policies, pinning hopes on Trump may turn out to be a miscalculation.

Turkish hopes that Trump may steer the relationship to calmer waters foundered when the president himself, and his Vice President Mike Pence, delivered Thursday’s direct warning to President Tayyip Erdogan of looming sanctions.

“Trump’s tweet on Brunson shows that there are weaknesses in this strategy,” said Sinan Ulgen, a former Turkish diplomat and analyst at Carnegie Europe.

Trump did not spell out what form the sanctions might take, but a U.S. Senate bill to restrict loans to Turkey from international financial institutions passed through a committee late on Thursday, an important early step for the legislation.

Brunson has become the most public and recent focus of U.S. anger with Turkey, once one of its closest Middle East allies, but trust between the NATO partners has been eroding for years.

A low point for Turkey came when Washington decided in 2017 to arm the Kurdish YPG militia - seen as terrorists by Ankara - to lead the fight against Islamic State in northern Syria.

NATO SECURITY

Turkey then said it was finalizing the purchase of a Russian air defense system, a move Washington said would hurt NATO security and risk Turkish plans to buy U.S. F-35 fighter jets.

The crisis was aggravated when Turkish authorities detained U.S. consular staff over their alleged links to a failed coup in July 2016, which Turkey said had been masterminded by an Islamic preacher living in Pennsylvania for nearly two decades.

FILE PHOTO: U.S. President Donald Trump and Turkish President Tayyip Erdogan gesture as they talk at the start of the NATO summit in Brussels, Belgium July 11, 2018. REUTERS/Kevin Lamarque/File Photo

Throughout the rolling stand-offs, both sides have described themselves as the wronged party, betrayed by a long-standing partner who wilfully ignores their point of view.

“This was a cascade of misunderstandings that has damaged the trust to breaking point,” said Howard Eissenstaat, associate professor in Middle East history at St. Lawrence University.

“This is like a really ugly divorce where the two sides have simply lost trust in each other. They feel abused, and because they feel abused they feel legitimate in trampling on the rights of the others.”

Turkey insists that the trial of Brunson on terrorism charges, which he denies, is a matter for the courts to decide. Washington has described him as a hostage and demanded the immediate release of the pastor and two detained U.S. consular staff and a third consular staffer under house arrest.

Brunson's detention was one reason the U.S. Senate last week demanded a block on sales to Turkey of F-35 jets unless Trump certifies Turkey is not threatening NATO, purchasing defense equipment from Russia or detaining U.S. citizens. nL1N1TK1VB

FIST-BUMP TO FALLING OUT

Turkey has played down any threat from Congress, saying Trump will ultimately decide matters. “This is something completely at the discretion of the American president,” Erdogan told Turkey’s parliament this week, referring to the F-35 sales.

“We do not have the slightest concern on this point.”

A Turkish official spoke about a better understanding emerging. He linked the perceived improvement to what he said was Trump’s increased command of U.S. policy, in contrast to the “mentality of certain members of Congress”.

But focusing on Trump, with whom Erdogan was reported to have shared a fist-bump at a NATO summit in early July, has been a major Turkish misjudgment, U.S. officials and analysts say.

“The issue with Turkish government thinking is that they still think this is up to the executive. Congress is setting the agenda now - that should be a red flag,” said Aaron Stein, resident fellow at the Washington-based Atlantic Council.

FRESH DISPUTES

With the second largest standing army in NATO, troops in Syria and Iraq, and a NATO air base in the south of the country, Turkey has clout in the Middle East and beyond.

For years, especially early in Erdogan’s 15-year-old rule, it was also seen as a model blend of Islam and democracy.

But Washington has criticized a crackdown following the failed bid by rogue military officers to oust Erdogan, and Western critics say he is pushing Turkey toward one-man rule.

Erdogan, re-elected last month with new powers, dismisses the criticism and says Turkey must be strong to handle threats from regional conflict and supporters of cleric Fethullah Gulen, whom it blames for the failed coup. Gulen denies involvement.

Turkey has made repeated failed requests for Gulen’s extradition: Washington says courts require sufficient evidence before they can extradite the influential cleric.

In Turkey, hostility to the United States is on the rise, and while popular sentiment drifts apart, so too do Ankara and Washington’s regional policies, particularly on Syria and Iran.

With U.S. forces stationed alongside Kurdish YPG fighters in northern Syria, Erdogan warned earlier this year that U.S. soldiers could be caught in the cross-fire of Turkish military action against the Kurdish militia near the town of Manbij.

Fresh disputes loom over Iran. Trump has pulled the United States out of an international nuclear accord with Tehran and called for sanctions against the Islamic Republic.

Turkey, which buys much of its oil from neighboring Iran, says Washington cannot dictate the trade of other countries.

“One thing has always been a sticking point in this relationship,” the Turkish official said. “When the Americans decide on something, they want everyone to obey them. They think their decision is internationally binding - and it isn’t.”