An implicit flux-corrected transport algorithm