MADISON - The state is tightening the rules for conducting election recounts, under legislation signed by Gov. Scott Walker Thursday.

Assembly Bill 153 comes in response to 2016 Green Party presidential candidate Jill Stein's demand for a recount after Donald Trump became the first Republican presidential candidate to win Wisconsin since 1984.

Stein received just 1% of the vote but was able to force a recount here under state law by agreeing to pay $3.5 million to fund it. But the recount didn't change the outcome in Wisconsin — Trump actually padded his victory margin by 163 votes.

The Assembly passed the GOP bill in June on a voice vote and the Senate passed it on a party line vote of 20-13.

Under the bill, candidates could request recounts only if they lost by 1 percentage point or less in an election with at least 4,000 votes total. For elections that don't receive that many votes, the candidate would need to lose by no more than 40 votes for a recall.

The measure also would reimburse the entity that conducts the recount and shorten the deadline to apply for a presidential recount by two days.