Having known Castro since the birth of the Cuban revolution in January 1959, I do not remember his ever displaying the kind of deference, if not veneration, that he showed John Paul II on that Roman morning. Watching him on television, as he murmured his greetings to the pope, I had the sensation of a Fidel Castro who, for perhaps the first time in his life, was humble and tender.

I have had the privilege of knowing the pope since 1993. Last week I was struck by the paternal warmth with which John Paul welcomed Castro, putting both his hands on Fidel’s and gently guiding him into his private study for their 35-minute conversation. The pope must have greeted thousands of distinguished visitors at the Apostolic Palace since 1978, but this was something very special. Castro, not prone to such language, called it ““a miracle.''

What is the quasi-mystical bond that seems to exist between these men? First and foremost, they share a profound dedication to what each sees as social justice. Communist dictator and Roman Catholic priest, they have been preaching its virtues continuously in every imaginable context. In their respective speeches at the World Food Summit in Rome last week, both, in effect, denounced the affluent West for letting the developing world starve. In a 1987 book, Castro praised the pope’s support for granting land to landless peasants. And in his Rome speech, Fidel praised John Paul for his defense of women, Latin American Indians and other underprivileged of the globe.

John Paul, for his part, is known to have read at least some of the speeches that Castro had been insistently sending the pope for years. Separately, John Paul has been making quiet inquiries about Castro. In the course of a lunch in his private dining room in February 1994, for example, the pope asked me a few pointed questions about Fidel. Both John Paul and Castro are highly instinctive when it comes to their attraction to others. This has made it possible for both of them to embark on the ostensibly startling exercise of the Vatican handshake and John Paul II’s acceptance of Fidel’s invitation to visit Cuba for the first time.

Both men are also pragmatic risk takers, supremely assured and authoritarian, as well as daring innovators. This is why, I think, they understand each other so well. Both command great intellectual power and a knowledge of history–both are the sons of small, often subjugated nations. Fidel realizes, as does John Paul, that the age of Marxism-Leninism is gone forever, and both have evidently concluded that it is time to concentrate on the future. Both concur in the view that, in the pope’s words, ““savage, unbridled capitalism’’ is a danger to humanity. Small wonder that after the audience Fidel described the pope as ““the most extraordinary person of our time,’’ a remarkable compliment from this Jesuit-educated revolutionary who still insists for the record that he is a Marxist-Leninist.

The pope’s agenda is plain. John Paul began stubbornly working to save Cuba from the dangers of a violent and bloody power transition from communism at least five years ago. Since late 1992 secret papal emissaries have been visiting Fidel. Castro soon saw in the pope his political salvation and a guarantee of the tranquil completion of his lifetime rule.

This is where Castro’s strong sense of affinity with John Paul, and his trust in him, came into play. Castro, his friends tell me, thinks the pope may legitimize him in the eyes of Cuban Catholics through the Vatican meeting and the planned 1997 trip to the island–and hence ensure peace in Cuba as he did in Eastern Europe. Endlessly suspicious, Castro would not have entered into such a compact with anyone but this pope. Both men believe history is defined by the right man at the right place at the right time.

Under the circumstances, Fidel’s willingness to treat the Roman Catholic Church in Cuba decently is no great concession–albeit one that John Paul II had insisted on–so long as the pope and the church become, in effect, his allies. A papal embrace of Castro, magnified by television exposure throughout the island, will defuse much of the internal opposition to him. This was the deal that John Paul had been striving to make Castro accept–and accept it he now has. But all would have failed if, when the men met alone in the pope’s study, there had been no personal chemistry between them.

I have no idea what was actually said. But judging from the broad smiles as they parted, I would imagine that it was the easiest of conversations. Contrary to general belief, Castro–like the pope–can be a very good listener. When he listens, Fidel twirls his beard under his lower lip; John Paul, for his part, rests his knuckle against the corner of his mouth. Because both men know how to put at ease those they like, it must have been an extremely informal exchange. The pope is fluent in Spanish–he taught himself the language as a young man in wartime Cracow to read the works of the great mystic John of the Cross in the original.

For the 76-year-old John Paul, the Cuban enterprise may be the last great work of his life, and he senses it. I believe the surgery he underwent in October led him to receive Fidel, 70, as soon as possible. I suspect that Fidel also felt that time was pressing. For these two unshakable believers in destiny, the sunny Tuesday in the papal apartments must have been a moment of epiphany.