Well, where are you getting the text of the encyclical from?
What I’ve learned is that you need to use the style of formatting that corresponds to the medium from which you got your information.
For example, if you got the text of the encyclical from a website then you would cite it in your bibliography in a web format. Or if you got it from a pamphlet then you would look for all the publishng information that you can find and fill in the blanks as best as you can.
Same goes with the Catechism and any other published work including the Bible.
I cited the Bible once and then revealed to my prof that it was from the online edition and he wanted me to cite that rather than the printed version.