“It was only Catholicism until then. In fact, Luther had been educated as a Catholic.”
It was not. I’ve given you links before that demonstrate your claim is false.
“But then he fell into disobedience and apostasy.”
Following God’s specific Word isn’t apostasy except to those who have strayed far from what God declared as true.
According to Catholic doctrine, the proximate criterion of the Biblical canon is the infallible decision of the Church. This decision was not given until rather late in the history of the Church (at the Council of Trent). Before that time there was some doubt about the canonicity of certain Biblical books, i.e., about their belonging to the canon. (The New Catholic Encyclopedia, McGraw Hill, Copyright 1967, Volume 3, Canon, Biblical, p. 29)