In this July 13, 2020, file photo, Warsaw Mayor Rafal Trzaskowski concedes defeat in Poland's tight presidential election runoff and congratulates President Andrzej Duda for winning a second term in Warsaw, Poland. Credit: Czarek Sokolowski / AP

Few people outside of Poland care about the outcome of last week’s presidential election there, but maybe they should. Andrzej Duda is practically a Polish clone of Donald Trump, who will also be seeking re-election less than four months from now — and Duda squeaked out a victory.

Duda only got 51.2 percent of the vote against 48.8 percent for his liberal opponent, but Trump doesn’t even need that many votes. The Poles vote for their president directly, but gerrymandered electoral districts and the Electoral College in the United States let Trump win last time with only 46.1 percent of the popular vote. He could do it again.

It’s not a perfect comparison, of course. Duda is more intelligent than Trump, and the coronavirus death toll is only 40 per million people in Poland, compared to 420 per million in the United States. Moreover the Law and Justice Party he is linked to is generally seen as competent and honest.

So what relevance could Polish politics have for the forthcoming election in the United States? Quite a lot, actually, starting with the very similar ways in which the two countries are polarized politically.

The Law and Justice Party, in power since 2015, draws its support from exactly the same social groups as Trump’s base: older, small-town or rural, lower-middle or working class, poorly educated and significantly more male than female. Also more religious (which in Poland usually means a conservative brand of Catholicism) and much more nationalist.

The Law and Justice Party makes a great song-and-dance about hordes of Muslim immigrants threatening Polish national identity (although no sane Muslim would ever choose to move to Poland). But the best targets in the culture wars are people who really live in the country, and since Poland doesn’t have minorities of different colors, that mainly means gays and Jews.

Duda made homophobic rhetoric the centrepiece of his re-election campaign, promising to “defend children from LGBT ideology” and comparing the LGBT rights agenda to communism. He promised a new constitutional amendment to ban same-sex adoption, which he described as the “enslavement” of children.

Since the government has already turned the once impartial state-owned media into the Law and Justice Party’s propaganda arm, it now concentrates its fire on the private media, much of it owned by U.S. and German companies, which still try to offer independent analysis. Duda’s line was therefore to attack the evil foreign-owned media — and, of course, to suggest that they are really serving “Jewish interests.”

It’s not pretty, but Trump recognizes a kindred spirit in Duda, whom he has met 11 times since 2017, including an invitation to the White House last month to give the Polish president a last-minute electoral boost. Duda attacks the media, his party is busily packing the judiciary with reliable conservative judges — and he won re-election. It’s enough to give The Donald hope.

But maybe not enough hope, because there is one big practical difference. However much Trump may claim to love the poor and “the poorly educated,” he hasn’t done much to help them, whereas the Law and Justice Party puts its money where its mouth is.

Trump has “signed” a check for $1,200 for each American once during the pandemic, and wants to sign one more if Congress approves. The Law and Justice Party gives every Pole $125 a month for each child every month, pandemic or not. It doesn’t make much difference to the average urban middle-class Polish family, but it has transformed the lives of millions of families who live in the small towns and the countryside.

The party’s base is also invested in the culture wars, but there’s little doubt that this subsidy, running around $3,000 a year for the average family, gave Duda a vital extra push in the election. If Trump promised a thinly disguised basic income like that for the United States, he could probably win, too.

He wouldn’t have any serious ideological objection to that, because he actually doesn’t have any coherent ideology. However, the Republican Party’s loyalty to its traditional conservative beliefs, though heavily eroded, is probably still strong enough to make that impossible.

Gwynne Dyer’s new book is “Growing Pains: The Future of Democracy (and Work).”