JEZOWE, a five-hour bus ride from Warsaw, is officially designated an agricultural village. But it is one where the agriculture now tends to take place elsewhere. Jezowe’s fields lie mostly fallow; its workers now seek higher-paid jobs in wealthier European Union countries, harvesting grapes in France and cabbages in Germany. Among the village’s weathered wooden houses stand gaudy villas, paid for with euros earned abroad. “Disneyland,” says one resident, pointing to the turrets and gilded fences. The town’s public buildings, too, have been spruced up, mainly with injections of EU cash. A grant of 525,000 zloty ($140,000) paid for the renovation of the old parsonage, which now houses a museum devoted to carved figurines of Christ.

In short, Jezowe has done well by the EU. Yet the village has long backed the right-wing Law and Justice party (PiS), a mildly Eurosceptic and socially conservative party that has been in opposition since 2007. The PiS candidate for president, Andrzej Duda, took a startling 92% of the vote here in an election in May; nationwide, he won with a more modest 52%.

The rest of Poland is moving in Jezowe’s direction. With a parliamentary election due on October 25th, one poll puts PiS support at 36%, far ahead of the 22% for the ruling centrist Civic Platform (PO) party. Ewa Kopacz, who succeeded Donald Tusk as prime minister and PO party leader when he became president of the European Council last year, has failed to give her party a new sense of momentum.

Poland’s economy has grown by a third since 2007, when PO came to power. But the country’s rural, conservative east feels neglected. Easterners have the sense that the government is punishing them for voting for the opposition, says Gabriela Maslowska, a PiS member of parliament. What do they lack? “Everything,” says a trade-union activist in the eastern city of Lublin. “This is the backwater of Europe. If it could, Warsaw would fill it with forest.” Only PiS cares, he says.

Unemployment is higher in the east; in the area around Jezowe it stood at 20% in August, double the national average. But much of the resentment is cultural, not economic. The government, says Ms Maslowska, promotes “pseudo-equality” and “gender ideology”—euphemisms Polish conservatives use to describe feminism and gay rights. In the south-east, patriotism and religion have always been inter-twined, says Marek Stepak, the PiS mayor of Jezowe. On the wall behind his desk hangs a trinity of symbols: the village’s coat of arms, the Polish eagle and a crucifix.

PO’s only hope of staying in power hinges on a motley anti-PiS coalition of agrarians, social democrats and liberals—smaller parties which might not win enough votes to enter parliament. PiS, by contrast, is intent on winning enough seats to govern alone. Jaroslaw Kaczynski, the party’s veteran leader, urges voters to opt for rule by a single party (his) over a multiparty government mired in “chaos and perpetual war”.

Popular exhaustion with eight years of PO rule helps the right. In 2014 tapes secretly recorded by a conspiracy of waiters at posh Warsaw restaurants revealed senior PO politicians making embarrassingly candid remarks. (The former foreign minister, Radek Sikorski, disparaged David Cameron’s EU renegotiation stance as “stupid propaganda”; a central bank governor discussed altering monetary policy to help PO.) The tapes cemented an image of PO as self-satisfied and elitist.

That has helped neutralise the memory of PiS’s chaotic stint in power in 2005-07, when Mr Kaczynski picked needless fights with Germany and embraced the less realistic variety of anti-Russian conspiracy theories. PiS has courted young urban voters with an upbeat social-media campaign run by a zealous team of activists in their 20s. In rural areas, PiS has challenged the agrarian Polish People’s Party, PO’s junior coalition partner, for farmers’ votes. It has made lavish promises of spending on social benefits: a monthly 500-zloty-per-child subsidy, and jobs programmes for depressed regions. “We have something for everyone,” says Stanislaw Karczewski, head of PiS’s campaign.

The divisive Mr Kaczynski wisely spent the summer behind the scenes, naming his deputy, Beata Szydlo, as the party’s candidate for prime minister. But he attracts fervent loyalty from supporters who say the mainstream media is biased against him. (“You should watch TV Trwam,” suggests a pensioner in Lublin, referring to an ultraconservative television channel run by a Catholic priest with links to PiS.) And as the country erupted in debate over the EU’s plans to resettle tens of thousands of asylum applicants, Mr Kaczynski resurfaced with characteristic frenzy. The migrants carry “various types of parasites” which “could be dangerous here,” he said last week.

Jezowe, like other communities in the area, has refused to take in migrants. Mr Stepak says the village lacks suitable housing. He frets about the “Islamisation” of Europe, and is unconvinced by offers of EU subsidies to accommodate refugees. Rather than taking in Middle Eastern asylum-seekers, PiS wants to “repatriate” people with Polish roots from the former Soviet Union. Jezowe already has one family of ethnic Poles from Kazakhstan.

As Poles prepare to vote, centrists and liberals have been issuing somewhat exaggerated predictions of doom. Ms Kopacz’s 31-year-old daughter, a gynaecologist, says she may emigrate if PiS wins. In Jezowe, many people have left already—to earn more money elsewhere in Europe. They will continue to do so, even if their favoured party wins. They are glad of the freedom of movement the EU affords them. But accepting that this freedom of movement means they might have to take in some of the refugees who reach Europe’s shores appears to be a step too far.