Friedrich Merz’s high-stakes gamble to enlist the far right in pressuring the German government to tighten migration laws has upended the campaign three weeks before general elections.