People sell balloons on Valentine’s Day in Karachi, Pakistan, on Feb. 14. Valentine’s Day, celebrated annually around the world, is considered symbolic of Western vulgarity and promiscuity to some in Pakistan. (Shahzaib Akber/European Pressphoto Agency)

Sajjad Ayub knew he was taking a chance. A Pakistani court had just banned public observances of Valentine’s Day in the capital, but he had gone ahead and set

up a roadside display of pink ­rosebud wreaths.

Just before noon, a municipal truck roared up. Several workers got out and swept all his flowers onto the sidewalk. Ayub, 21, waited until they had left, opened a bag hidden under his stand, and pulled out some pink teddy bears.

“I’m a Muslim, and I support the court’s action, but it would be a big business loss for me,” he said with an embarrassed shrug.

At the curb, cars kept pulling up and men in business suits kept jumping out, looking for something to take home to their wives after work. Haroon Khan, 40, a car salesman, picked out a $10 bride-and-groom statuette.

“Life is short,” he said. “If one day a year you give your wife something special to make her smile, what is the harm in that?”

A boy crouches beside a road with wreaths of roses he made to sell for Valentine's Day in Islamabad, Pakistan, on Feb. 14. Such displays were banned as part of a court ruling that the holiday was un-Islamic. (Pam Constable/The Washington Post)

Pakistan, a Muslim democracy of 180 million people, is becoming both more Western and more Islamic at the same time. As it moves into the Internet era and the global economy, the lines are being drawn more sharply. As more professionals in Islamabad, Lahore and Karachi adopt Western dress and tastes, more members of the vast ­religious faithful are hewing to the anti-Western rhetoric of ­radical clerics.

Valentine’s Day is a symbol of that divide, one that is easy to associate with the Western vulgarity and promiscuity that Islamist clerics often rail against.

On Monday, a judge in the federal capital barred all sales, displays, celebrations and media promotion of Valentine’s Day, responding to a petition claiming that the holiday fosters “immorality and indecency” and violates Islamic values and culture, according to news reports.

Like Ayub, many people in Islamabad expressed conflicted feelings or took half-measures to evade but respect the ban. A sidewalk cafe owner covered ­every table with red petals and hung a mobile of paper hearts. A flower vendor said he agreed with “the mullahs” that ­Valentine’s Day was forbidden in Islam, but he just happened to set out all red roses and ­snapdragons.

Elsewhere in Pakistan, though, people expressed opposition to the holiday, and a street protest was staged in Karachi.

But the contradictions go much deeper than a debate over permissible public displays of love and affection, a sensitive topic in many majority-Muslim countries and a source of ­growing conflict in those with both deeply conservative religious traditions and modernizing urban populations.

[In Pakistan, five girls were killed for having fun. Then the story took an even darker twist. ]

Pakistan is a country where love is often punished and hatred allowed to flourish. Its media is brimming with televised hate speech against secular liberals, and its family life is often poisoned by “honor killings” of young women who elope with their sweethearts or try to resist forced marriages.

And although Pakistan was founded in 1947 as a tolerant Muslim democracy where all ­citizens are free to worship as they wish, its citizens are often victimized by violent sectarian groups who torch or lynch ­religious minority members, and by terrorists from radical ­Islamist groups that randomly slaughter fellow Muslims.

Indeed, news of the Islamabad court’s ruling came just hours before a suicide bomber in the eastern city of Lahore — the nation’s leafy cultural capital — detonated explosives amid a peaceful protest rally by pharmacists outside the provincial parliament.

People screamed and tried to flee. Bloody limbs and clothing were strewn across the scene. By evening, 13 people were confirmed dead and more than 80 wounded, almost all probably among the 95 percent of Pakistan’s population that is Muslim. An Islamist militia, allied with the Islamic State, asserted responsibility for the blast and warned that more attacks would follow against “apostate” government agencies, including the police.

In an anguished statement after the attack, Prime Minister Nawaz Sharif declared that the bombing was part of “a fight for the soul of Pakistan.” He was talking specifically about what he called the “cancer” of ­terrorism, but as other Pakistani commentators have pointed out, the real existential conflict in Pakistan has many more ­dimensions and is being fought on multiple fronts.

It is a war between the historical, tolerant South Asian version of Islam and the harsher, Middle Eastern schools that have been imported in recent years. It is a war between modern international norms and rights, and ancient tribal mores of patriarchy, honor and revenge. It is a war between weak political institutions that fail to serve or protect the poor, and strong religious emotions that can easily escalate into violence.

When it comes to love and marriage, mainstream Pakistani society remains deeply traditional. Even among the well-to-do, most marriages are still arranged between families to some degree, and dowry ­demands are often exorbitant. Western-style dating is not common, and young people rarely live alone between leaving home and getting married.

In poorer and more rural regions, especially where tribal custom holds sway, girls and young women who run off with their boyfriends or who resist arranged marriages — some betrothed to much older men, others bartered in compensation for disputes — are often attacked and killed by their own relatives for having dishonored their families.

In comparison, the dispute over Valentine’s Day might seem silly to outsiders, and some secular leaders scoffed at the court ruling. One of Pakistan’s leading human rights activists, Asma Jahangir, commented that the judge who banned the romantic holiday “should be the prayer leader in a mosque.”

But as many Pakistani commentators have said, their society urgently needs to find a middle ground between punitive and permissive versions of Islam, between abusive and licentious notions of romantic relations, between self-defeating hostility toward the Western world and slavish emulation of it. Finding an acceptable way to observe the international day of love might not be a bad place to start, they say.

“Everyone wants to celebrate today,” said Arfan Khan, 21, a college student who was buying a bunch of roses for a friend Tuesday. “Everyone is becoming more aware of American culture, but that’s not the point. With all the problems Pakistan has, why shouldn’t we have one day for happiness?”

Read more:

Did Pakistani security agents kidnap bloggers to make a point?

Pakistani cleric arrested to appease Trump administration, India, supporters say

Iconic ‘Afghan girl’ returns home after 31 years, a symbol of her country’s tensions with Pakistan

Today’s coverage from Post correspondents around the world

Like Washington Post World on Facebook and stay updated on foreign news