It was caesaropapism, the form invented by Constantine and perpetuated in Byzantium and in Moscovy.
And perpetuated in Rome until their loss of the Papal States.
The claim of the papacy was universal jurisdiction over the Church. Boniface VIII made an absurd claim to secular authority and was soon humbled by it. In their struggle against the Emperors, the popes had depended on the French kings, and now it was the French king who slapped him down and removed the popes from Rome into captivity in Avignon. The importance of the papal states was that it gave the popes a certain independence, which is why Pius IX refused to accept the authority of the Italian king after he seized control of the papal states but especially Rome. If you look at the part of Rome that existed in 1870, when it was seized by Savoy, you see not a political capital but a religious center like Mecca. The king wanted Rome as a capital because it was situated between North and South but more because its ancient prestige was supposed to give luster to the new kingdom of Italy. But of course, it prompted Pio Nono to hole up in the Vatican and try to shame the Italians.