Reference: http://mufti.af.org.sa/ar/content/كيفية-قضاء-صلاة-المغرب-أو-الفجر-إذا-فاتت-عند-شروق-الشمس-أو-عند-غروبها
Question: What is the ruling regarding making-up the maghrib or fajr prayer if it has been missed with the passing of sunrise or sunset?
Response: The prayers which have been missed are to be prayed at any time, and there is nothing prohibiting that because the Prophet ﷺ said:
And the Muslims jurists have said with respect to making-up the missed prayers, that they are to be made-up even if it is during the times it is prohibited to do so.