The reply "And with your spirit" is a biblical quotation and refers also to the special graces of the Spirit the priest received at ordination.
At Mass, Catholics respond to the priest’s greeting of “The Lord be with you” with “And with your spirit.” This response is another direct bible quote, but also refers to the Holy Spirit and the grace the priest received at ordination.
This again comes from the letters of St. Paul in the New Testament and is often how he ends his letters.
The grace of our Lord Jesus Christ be with your spirit, brothers. Amen (Galatians 6:18)
The response reminds us again that this interchange at Mass is not simply a common meal, but a heavenly banquet with a deep spiritual dimension to it.
It departs from our typical response that we might give to someone on the street and alerts us to something special.
Furthermore, saying “and with your spirit,” recognizes how bishops, priests, and deacons are set apart by their ordination.
Dr. Edward Sri gives a succinct explanation in an article posted on the Catholic Education Resource Center.
By responding, “And with your spirit,” we acknowledge the Spirit’s activity through the priest during the sacred Liturgy. We are referring to the “spirit” of the priest, the very core of his being, where he has been ordained to offer the sacrifice of the Mass. Indeed, we are acknowledging that since God works through the priest who is offering the Mass, ultimately it is Jesus Christ who is the head of the community gathered for the Liturgy, and it is his Spirit who is the primary actor in the Liturgy, regardless who the particular priest celebrating Mass may be.
To be clear, the phrase is not a reference to the priest’s “soul,” but to the Holy Spirit and the special graces that were given to him.
Each word and phrase in the Mass is chosen for a specific purpose and reveals many spiritual meanings that allow us a deeper participation in the sacred mystery.