This material was moved from another thread where it was off topic.
The church does not teach that virginity is “better” than a married state. It is different, and the teaching we have from Jesus and the Apostles is that a person who is unmarried is more free to give themselves fully to the kingdom, because they are not immediately responsible for other people, specifically their spouse and children.
Mary is the Ark of the New Covenant. A devout man such as Joseph would be well acquainted with the consequences of putting one’s hand upon the Ark of God.
I think the notion that priestly celibacy is equal to “forbidding marriage” is a protestant misconception. The Catholic Church does not in any way “forbid marriage”. However, she strives to practice what Jesus taught about marriage. Jesus taught that those who could be eunuchs for God are blessed with a special gift, and if they were able to receive it, they should do so. the church recognizes that it is best if the priests should be those who have been blessed with this gift. It has nothing to do with forbidding marriage.