DETROIT (Reuters) - General Motors Co and the United Auto Workers union reached a tentative agreement on Wednesday for a new four-year labor deal, moving closer to ending a costly month-long strike that shut down GM’s most profitable factories in a test of wills over the future of U.S. auto industry jobs.

Neither the UAW nor GM released details of the deal, which is subject to ratification by UAW members, a process that could last up to two weeks. A new contract is expected to include commitments by the automaker to invest billions in U.S. vehicle factories to build new generations of electric vehicles, as well as U.S. electric vehicle battery plants. Union leaders worry that a shift to electric vehicles could cost thousands of jobs at engine and transmission factories.

The longest nationwide strike against a Detroit automaker since 1970 became a political event. Democratic presidential candidates joined UAW picket lines, eager to win union votes in Midwest swing states. For his part, U.S. President Donald Trump put pressure on GM Chief Executive Mary Barra before the strike to preserve jobs at a car plant in Lordstown, Ohio, that she had targeted for closure.

Trump spoke individually with Barra and UAW President Gary Jones on Wednesday, spokesmen for GM and the union confirmed. The White House declined to comment on the discussions.

Details of GM’s last offer emerged over the weekend and Reuters had reported that the company boosted the amount it plans to invest in the United States to about $9 billion from its previous offer of $7 billion. That figure is unchanged in the final agreement, a person briefed on the matter said.

The deal also would create or retain 9,000 UAW jobs, a “substantial” number of which will be new, the source said. GM in September said its initial offer would support 5,400 jobs - and a majority of those would be new jobs.

If the contract is ratified, UAW workers who have been living on $250 a week in strike pay are expected to get one-time signing bonuses, as well as increases to base pay. The union had also pushed for temporary workers at GM plants who earned less than permanent UAW employees to get an easier path to full-time wages and benefits.

GM shares closed 1.1% higher at $36.65 on Wednesday after rising as much as 2.6% during the day. Shares of some auto parts suppliers also rose after the UAW announced the tentative deal. The cost of the strike - and how quickly those costs can be recovered - will be a focus for investors as the automaker and its major suppliers report quarterly results over the next several days.

Analysts have estimated the strike cost GM more than $2 billion in lost production, though some of that could be made up through overtime work. The strike halted production of GM’s large pickup trucks and sport utility vehicles - key drivers of the company’s global profit.

POLITICAL EVENT

The deal is not done yet. The union’s national GM council will decide whether to accept the agreement during a meeting on Thursday. Then UAW members at GM will vote on the agreement. The strike continues at least until Thursday’s meeting, the UAW said in a statement.

The strike began on Sept. 16, with about 48,000 hourly workers of the UAW union at GM seeking higher pay, greater job security, a bigger share of profit and protection of healthcare benefits. Other issues included the fate of plants GM has indicated it may close, and the use of temporary workers.

GM’s revised offer that emerged over the weekend also included an increase of its proposed ratification bonus by $1,000 to $9,000. GM also proposed 3% pay raises in the second and fourth year of the four-year-contract and 3% and 4% lump sum payments in the first and fourth year respectively. It agreed to make temporary workers with three years of service permanent and give those workers a $3,000 ratification bonus.

FILE PHOTO: A union strike sign is stuck in the fence outside the General Motors Flint Truck Assembly in Flint, Michigan, U.S., October 9, 2019. REUTERS/Brian Snyder/File Photo

The final agreement is similar to that offer on pay and bonuses, but includes some enhancements, the person briefed on the matter said.

The automaker said during the talks that it had offered “solutions” for the Lordstown assembly plant and a large assembly plant in Detroit-Hamtramck that were targeted for closure. A group affiliated with electric truck maker Workhorse Group had proposed acquiring the Lordstown plant. GM also said it had proposed a “union represented battery cell manufacturing site in the U.S.”

GM was considering using the Detroit-Hamtramck factory to build a new line of electric trucks, sources said.

These proposals could have changed or been dropped in the final days of the talks.

If the deal is approved by the workers, the union will next begin negotiations with Ford Motor Co or Fiat Chrysler Automobiles NV (FCA), covering many of the same issues. The UAW previously agreed to temporary contract extensions with both automakers while it focused on GM.

A successful ratification is not a sure thing as workers during the 2015 talks initially rejected a deal with FCA before eventually approving a revised offer.

SHARING THE REWARDS

This year’s talks have been overshadowed by a widening federal investigation into corruption at the union.

For GM and the UAW, the bargaining came at a time of industry uncertainty following nine years of strong sales and robust profit, fueled by the trucks and SUVs built by UAW workers. GM’s Barra and President Mark Reuss joined the bargaining on Tuesday, indicating a deal was close.

Union leaders said the rewards of GM’s recovery from its 2009 bankruptcy had not been shared fairly. Inflation-adjusted wages for all U.S. auto workers have fallen 16% since 2010, and UAW workers at the Detroit Three have received only two base wage increases of 3% in the past nine years, according to CAR.

GM management, on the other hand, sees UAW wages as 26% higher than the average for non-union auto factories in the Southern United States. High absenteeism and rich health benefits add to the cost burdens at a time when U.S. vehicle sales are projected to decline and automakers are funding investments in electric vehicles.