Updated

Protesters lit buses on fire, blocked roads and clashed with police on Friday during a general strike that brought transportation to a halt in many cities across Latin America's largest nation.

The strike was to protest major changes to labor law and the pension system being considered by Congress, but it was also a raw display of anger by many Brazilians fed up with corruption and worried about the future amid a deep recession and rising unemployment.

In Rio de Janeiro, after hours of clashes with police in front of the legislative building, several buses were torched. In Sao Paulo, thousands marched toward the home of President Michel Temer, throwing rocks at police who shot stun grenades when protesters tried to go beyond barriers set up.

Millions stayed home, either in support of the strike or simply because they were unable to get to work. The tens of thousands who took to the street raised questions about whether Temer will be able to push his proposals through Congress, where they had previously looked likely to pass.

Temer's administration argues that more flexible labor rules will revive a moribund economy and warns the pension system will go bankrupt without changes. Unions and other groups called for the strike, saying the changes before Congress will make workers too vulnerable and strip away too many benefits.

In a statement Friday night, Temer characterized the protesters as "small groups" that blocked the roads and streets. He said his administration was working to help Brazilians workers overcome the country's economic malaise.

Earlier in the day, most commuter trains and metro lines were stopped in Sao Paulo during the height of morning commute, and all buses stayed off the roads. Buses ran partial service during the morning in Rio but later began returning to normal. The metro was closed for the day in the capital of Brasilia.

Some protesters also set up barricades and started fires in the streets, including on roads heading to the main airports in Sao Paulo. In Rio, protesters created confusion by running through Santos Dumont Airport, and others blocked a major road.

Some plane mechanics joined the strike, according to the National Aeronautic Union, but the impact was minimal, with only a handful of flights canceled or delayed at the two cities' airports.

"We are demanding our rights, as workers, because the president of the country proposed a law for people to work more and live less, so you will only receive your pension when you die," said Edgar Fernandes, a dock worker who was protesting in Rio.

The CUT union said around 35 million Brazilians didn't show up for work on Friday, more than one-third of the working population. But government officials downplayed the strike, insisting that many Brazilians were still at work.

"We don't have a strike, we have widespread riots," Justice Minister Osmar Serraglio said on Joven Pam radio.

Brazil's economy is in a deep recession, and many Brazilians are frustrated with Temer's government. Temer, whose approval ratings are hovering around 10 percent, has argued the proposed changes will benefit Brazilians in the long run. But with so many out of work, many feel they can ill afford any cuts to their benefits.

Meanwhile, the country is mired in a colossal scandal involving billions of dollars in kickbacks to politicians and other public officials. Over the last three years, dozens of top politicians and businessmen have been jailed in the so-called Car Wash investigation that has produced near daily revelations of wrongdoing.

Scores of sitting politicians, including Temer himself and several of his ministers, have been implicated. Temer denies wrongdoing.

In one the largest demonstrations Friday, thousands of protesters gathered in front Rio de Janeiro's state assembly in the afternoon and were fighting pitched battles with police who tried to remove them. Police fired tear gas while protesters threw stones and lit small fires in the middle of streets.

In Sao Paulo, police told downtown shopkeepers to close early, apparently out of concern that protesters might head there. Throughout the day, 21 people were arrested in Sao Paulo, according to military police.

Underscoring the economic malaise, the IBGE statistics agency announced on Friday that unemployment had jumped to 13.7 percent in the first quarter of the year, up from 12 percent.

The anger over the proposed changes to benefits shows that Temer's government has failed to convince the people that the moves are necessary, said Oliver Stuenkel, who teaches international relations at the Fundacao Getulio Vargas university in Sao Paulo. And yet, the proposed laws have been moving fairly easily through Congress, and had been expected to eventually pass.

"This is a peculiar government that has low approval and still gets work done in Congress," he said. "But lawmakers also think of their re-elections next year. After today, there could be a bigger risk for Temer in getting any meaningful bills passed."