By Philip Pullella and Yimou Lee
VATICAN CITY/TAIPEI (Reuters) - Five blocks from the Vatican, on the bustling, tourist-packed street leading to St. Peter's Basilica, a Taiwanese flag flutters from the window of a third story suite of offices that house Taipei's embassy to the Holy See.
These days, the staff inside are anxious. They know that one night they may have to lower that flag - red and blue with a white sun - for the last time.
As the Vatican and China move closer to a historic deal on the appointment of bishops, which would signal a warming of once-frigid relations, diplomats and scholars say Taiwan could lose the most from the deal..
Under the deal, the Vatican will have a say in negotiations for the appointment of future bishops in China, whose Catholics are divided between an "underground" Church loyal to the pope and a government-backed Church.
Even a partial resolution of the issue could open the way for eventual diplomatic relations between Beijing and the Vatican. That would give the Church a legal framework to look after all of China's estimated 12 million Catholics.
It would also leave Taiwan in the diplomatic lurch.
The Vatican is one of only 20 states that still recognize Taiwan, officially known as the Republic of China. Beijing insists that if countries want relations with it they must break ties with Taiwan.
The Chinese Foreign Ministry said last month that China had always been sincere in its efforts to improve China-Vatican relations.
A senior Vatican official said however that the accord on bishops "is not a political one," suggesting that it does not include any formal link to diplomatic relations and that the Vatican will not be the next country to switch relations to China from Taiwan.
Catholic leaders in Taipei are also hopeful.
"They (the Vatican and Beijing) won't build diplomatic ties. You need to share common values with each other in order to establish diplomatic ties," Archbishop John Hung of Taipei told Reuters in an interview in Taipei.
"The values the Vatican holds are different from those of the Chinese Communist Party. Building ties with the Vatican requires values including freedom and democracy."
Hung said the Church in Taiwan is "sleeping well at night".
But for how long?
Some experts say diplomatic ties between Beijing and the Vatican are inevitable, even if probably not right around the corner.
"The Church does not have preference among its children and it's clear that the Vatican does not want to do anything to displease Catholics on Taiwan" said Agostino Giovagnoli, a history professor at Milan's Sacred Heart Catholic University and the author of two books on Catholicism in China.
"But strategically the Catholics on the mainland are more important because the future of evangelization of China and all Asia passes through China. It is key for the Catholic Church," he told Reuters.
While Taiwan's embassy to the Vatican proudly flies the flag from its window, hosts cultural events and publishes a newsletter, the Vatican's counterpart in Taipei is a study in low-key diplomacy.
It is located in a quiet residential neighborhood in the city's Daan distinct. The only clue of its function is the papal stem of crossed keys and a tiara, or crown. That symbol is not widely known to the general public.
The Vatican's last diplomat on the mainland was expelled in 1951 and the Holy See mission settled in Taiwan, to where Chiang Kai-shek's Nationalist government fled in 1949 after its defeat by the communist armies of Mao Zedong, founder of the People's Republic of China (PRC).
Since the 1970s, following the United Nations vote to recognize the PRC as the sole legal China, the Vatican has not appointed a nuncio, or ambassador, to Taiwan. It has kept the status of the mission at the lower level of "charge d'affaires ad interim" since.
Diplomats say the Vatican's low profile in Taiwan for four decades has been aimed at placating Beijing, which still sees Taiwan and its sacred territory.
In 1999, Cardinal Angelo Sodano, then Secretary of State under Pope John Paul, sent shockwaves through Taiwan's diplomatic corps.
He said the Vatican was ready to move its embassy from Taipei to China "not tomorrow, but tonight if the Chinese authorities allow it".
In Vatican directories and diplomatic lists, the ambassador from Taiwan, currently Matthew Shieh-Ming Lee, is listed under "China," not "Republic of China," which is Taiwan's official name now, and was China's official name before 1949.
The ambiguity is not accidental, diplomats say. By keeping the listing vague and generic, the Vatican has avoided further irritating Beijing as it has tried to seek an agreement about Catholics on the mainland.
It also would make it easier for the Vatican to move its embassy to Beijing eventually while claiming that it is not really abandoning Taiwan, where it would likely leave an "apostolic" representation to the local Church.
"It is very interesting that both sides are putting the question of diplomatic relations at the very end of the road, on the horizon," Giovagnoli, the history professor, said.
He said that because China's diplomatic and economic strength has grown enormously over the past few decades, it no longer craves the Vatican's diplomatic recognition as it did in the past, making a gradual political rapprochement after a deal on bishops is signed more likely than quick recognition.
"Diplomatic recognition is no longer a quid-pro-quo for a deal on the naming of bishops as it once was," Giovagnoli said.
Those who will likely feel most hurt if the Vatican eventually does realign its political relations with Taiwan are the island's 300,000 Catholics.
While they make up less than 2 percent of the island's population, they are disproportionately influential. Taiwan Vice President Chen Chien-jen is a devout Catholic and visited the Vatican in 2016 for the canonization of Mother Teresa.
The Fu Jen Catholic University is considered highly prestigious. The Taiwan Catholic Regional Seminary trains priests from many parts of Asia, including China.
(Writing by Philip Pullella; Additional reporting by Ben Blanchard in Beijing; Editing by Giles Elgood)