The victory of South Korea’s main opposition party in parliamentary elections has made its leader a top contender for president in 2027, as long as he can manage a fickle public and stay ahead of a legal battle that could land him in prison before then.

Lee Jae-myung emerged from the election with a strong enough majority for the progressive bloc led by his Democratic Party to dictate the course of legislation and pressure the conservative ruling People Power Party to make concessions if it wants to get anything done.

An advocate of a universal basic income, Lee had proposed while he was on the campaign trail a total 13 trillion won ($9.5 billion) in cash handouts to citizens as a way to revive the economy. His Democratic Party has been looking to increase taxes on wealthy individuals and the chaebol conglomerates that dominate the corporate landscape.