When is maghrib considered as qaza? Till what time can i offer it?

Until shari midnight (half way between sunset and Fajr).