After the Protestant Reformation five centuries ago, Sweden became a grim place for Roman Catholics: Those who rejected the new Lutheran faith were punished with deportation or death.
The circumstances couldn't be more different as Pope Francis arrives in the Scandinavian country next week to commemorate the split in Western Christianity that started with Martin Luther's revolt.
The once-omnipresent Lutheran Church is bleeding members in Sweden, now considered a bastion of tolerance, while the country's small Catholic community is growing, mainly due to immigration.
"Now we have a situation in which the Catholic Church is also an important part in the social life" of the country, said Monsignor Furio Cesare, judicial vicar of the Catholic diocese of Stockholm.
On Monday, Francis will join Lutheran leaders in the southern city of Lund for an ecumenical service marking the start of a jubilee commemorating the 500th anniversary of the Reformation. He will attend another ecumenical event in nearby Malmo, where at the request of Swedish Catholics, he also will preside over a Mass in a football stadium before returning to Rome.
While Swedish media and government officials have given the upcoming visit scant attention, the country's Catholic community is beside itself with excitement. Tickets for the pope's Monday event in Malmo sold out in an hour. More than 15,000 people are expected to attend the Mass on Tuesday.
Francis' trip marks the start of yearlong, 500th anniversary commemorations across the Protestant world of Martin Luther's famous protest of abuses in the Catholic Church.
Vatican officials insist Francis isn't celebrating Luther's 95 theses protesting the sale of indulgences but rather solemnly commemorating the event. In addition, both Catholic and Lutherans say they want to ask forgiveness for their five centuries of division and give thanks for the official Catholic-Lutheran dialogue that began 50 years ago.
The pope's visit comes at a moment when Sweden's Catholic community has grown to about 113,000, a small minority in a country of 10 million people, but the biggest it's been since the Reformation.
Islam and other religions also are growing as migrants from Africa and the Middle East transform the ethnic and religious makeup of Swedish society.
Meanwhile, the Lutheran Church of Sweden is struggling to stay relevant among the majority of secularized ethnic Swedes.
Membership in the church, which was separated from the state in 2000, used to be automatic for all Swedes; now it's reserved for those who have been baptized in the church. Droves of Swedes have revoked their membership to avoid the annual church fee—on average about 1 percent of total income.
The Lutheran church lost 740,000 or 11 percent of its members between 2005 and 2015. The decline has continued despite the church's efforts to adapt to Swedes' liberal views on abortion, gender equality and gay rights. Sister churches in neighboring Norway and Denmark also losing members, but not quite as quickly.
"We are still 6.1 million members. That's one of the three biggest Lutheran churches in the world," Stockholm Bishop Eva Brunne said.
As Sweden's first openly lesbian bishop, the 62-year-old Brunne represents to many the face of a modern church that is adapting to the times.
But the minority of conservative Christians in Sweden says the church is trying too hard to adapt to a secularized society.
"It basically lost its core content," said Sara Skyttedal, the president of the youth wing of the Christian Democrats, a small and—by Swedish standards—conservative party in Parliament.
Skyttedal, who took the rare step in Sweden of converting to Catholicism, said Swedish Lutherans are so eager to adjust to the "zeitgeist" that they're compromising fundamental Christian beliefs. She noted that a Lutheran bishop a few years ago called it "extremist" to believe in an almighty God.
"Even though we need progress in society in many aspects, there is also need for something constant," Skyttedal said. "That is what made me attracted to the Catholic Church."
Cesare said the Catholic Church's relations with the Lutheran Church are complicated by different views on issues such as abortion and same-sex marriage.
"The Swedish Lutheran Church is in a process of renewal," he said. "And personally, I think they need really to find out how to renew their own identity."
Brunne rejects the notion that the Lutheran Church of Sweden has abandoned its core identity, saying the church remains rooted in the Bible and "we talk about Jesus as we have always done."
She doesn't rule out that the Catholic Church could move in the same direction as the Swedish church on issues such as same-sex marriage, which Francis and the Vatican reject.
"Why not?" she says. "It took us 50 years in the Church of Sweden. It hasn't happened from one day to the other."
Winfield reported from Rome. Associated Press journalist Vitnija Saldava contributed to this report.
Copyright 2016 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.