A man strides past the elaborate gilt portal of the Islamic seminary, wearing a white turban and the long cloak of a Muslim cleric. With his thick black beard - in the shadow of exquisite gold and turquoise minarets that mark Iran's spiritual center in Qom - he looks like a Persian character portrayed in "The Thousand and One Nights," from centuries ago.
But he is in a rush, on a mission as modern as any in the Western world. Clutched close to his belly is a computer disk: Software problems are hampering his research, so he is headed to the seminary computer experts for help.
Najah Taee is a religious writer, combing Islamic canon for facts about how jewels were smuggled to Syria 1,400 years ago.
He has come to the right place. Such details - along with the collected theological wealth and history of more than 2,000 Muslim texts - are now available on CD-ROM as part of a project to make significant Islamic works available on computer. Eventually, they'll put these volumes on the Internet for worldwide use.
A string of clerics tap at their computers, debunking the myth that fundamentalist clergy of all faiths - especially Iran's mullahs - are caught in a time warp.
"I can't say how much time it saves me," says Mr. Taee. "This machine can find every subject very quickly. It is such a big change; it can give me everything."
Two hours' drive south of the capital, Tehran, Qom is where Iran's late Shiite Muslim leader Ayatollah Ruhollah Khomeini taught for decades before leading an Islamic revolution in 1979 and where computers have become crucial tools for scholarship.
An entourage from the Vatican visited recently to examine references to Christianity in Islamic texts. They were impressed, clerics here say, and said this project is well ahead of Rome's work with sacred Christian texts.
Cleric Ali Kurani is the gregarious man whose idea sparked the program seven years ago, with an aim of creating a database for the 5,000 most important Shia and Sunna Islamic texts. Each volume takes some 500 hours to input and edit. The bulk of them are hadithi, or interpretations of the Koran and its laws analyzed and passed down by Muslim scholars since the dawn of Islam in the 7th century.
Mr. Kurani - a smile always on his face - says these days it is natural for his battalion of 130 clerics to be inputting the Persian language of Farsi and Arabic texts into computers at the Center for the Encyclopedia of Islamic Laws.
"We see this new technology as distinct from the culture that also comes from the West," he says over tea in his simple office. Shelves are lined with disks and English-language manuals for the latest software. "Computers can be used in a bad way, say for pornography, but they can also be used in a very good way."
Kurani plans to put the research on the Internet and to open an Islamic Web site. Using programs for Farsi, the center has produced a CD-ROM with 1,300 volumes of text.
There was initial resistance, until Kurani persuaded the theological seminary's aging Grand Ayatollah Mohammed-Reza Golpaygani to decree that computers were not against Islam and could be used.
"At first the old clergy thought they were being replaced," Kurani says. "'You want a computer to issue fatwas [Islamic decrees] instead of us?' they asked. But when they saw the result they were happy. Now they come to do research. They don't know about computers, but they know how to press buttons."
Accessing the material is as simple as playing a child's computer game. Kurani demonstrates by looking up references to "Jesus." First he must choose between the Arabic or Farsi language, then whether he wants to search the Shia or Sunna canon.
A long list of references pops up on the screen; text can be downloaded into the computer's memory or easily printed. For scholars who once spent "much of their lives" tracking down disparate lines, such immediate access is a godsend.
Kurani, however, views his mission in broader terms, as a student of Islam trying to improve what he considers to be wayward societies. Issues such as disintegrating family values, use of drugs, and other problems, which he sees as most prevalent in America and the West, should be dealt with jointly by Islamic and Christian leaders.
Here, making the Islamic canon more available to the West is part of that mission. Translations into English are currently being produced.
"I think [the West] needs a revival of human and religious values - such as family, which is in danger in the US - because they are agreed by all men in the world," Kurani says. "We can coordinate with Christian centers for these values. Although we may differ politically, we are ready to help in this field."
Then, using an analogy - just as the Islamic texts teach by parable - Kurani concludes: "If a wave comes, we can't stop it with a single hand. We should research its source, so we can stop it there."