had been mastering
-había estado dominando
Past perfect progressive conjugation of master. There are other translations for this conjugation.

master

Word of the Day
to stay up late