Croatian President Ivo Josipovic, an openly agnostic politician, discussed his efforts to bridge religious divides in a region dominated by Croatian Roman Catholics, Orthodox Serbians and Bosnian Muslims at a talk Monday afternoon.

A legal scholar and musical composer, Josipovic attracted over 100 students and community members at a speech hosted by the Yale Divinity School. During the lecture, Josipovic explained his country’s rise from a war-torn nation to a thriving democracy that joined the European Union this July. Josipovic, who was elected president in 2010, said his first two goals as president were repairing Croatia’s relationship with neighboring countries and joining the European Union.

“These two goals were very connected,” he said. “It was not an easy task.”

Before Croatia could be accepted into the European Union, the nation had to reconcile with its neighbors, Bosnia and Herzegovina and Serbia, with which Croatia has had a history of conflict, Josipovic said. He said the core of the dispute came from the differences in religion among the countries ­— over 86 percent of Croatia is Roman Catholic, Serbia is roughly 85 percent Orthodox and Bosnia is 40 percent Muslim. In the early 1990s, a conflict between the three countries resulted in over 100,000 deaths, 20,000 to 50,000 rapes and a displacement of over 2 million people, marking the worst European conflict since World War II.

After his election, Josipovic said he set out to connect with the leaders of Bosnia and Serbia. He traveled to Bosnia and apologized for the wrongs committed by Croatia, he said, adding that he called for leaders of the three major religions in the region to visit sites of different atrocities with one another. Josipovic said he believed it was crucial to overcome the fear that existed between the groups that had been bred by the violence from two decades before.

“If we fear each other, then we cannot discuss, we cannot resolve problems,” he said.

Josipovic said he rejected the notion that religion naturally pushes people to hatred of other groups. Croatia’s emergence as a democracy demanded a separation of church and state, he added.

“One of the most important human rights is freedom of conscience, including, of course, freedom to believe or not believe.”

Andre Ivankovic ’17, a first-generation American born to parents who immigrated from Croatia, said he was impressed by Josipovic because of his progressive outlook.

“It’s pretty evident that the citizens of Croatia don’t doubt that he can do good for Croatia,” said Ivankovic, who is a dual-citizen.

Jared Gilbert DIV ’12 said he enjoyed Josipovic’s visit because he thinks “it’s important to have world leaders talking about religion.”

Croatia, the 28th and newest member of the EU, was the first nation to join since 2007 when Bulgaria and Romania became members.