The quake struck near Mazar-e Sharif, one of Afghanistan's largest cities, in the early hours of Monday.