OMAHA, Neb. (AP) — Three of the 12 unions negotiating with the nation’s biggest freight railroads have reached a tentative deal which will deliver 24% pay raises, in line with what a special presidential panel of arbitrators recommended earlier this month to resolve the stalemate before a strike could happen.

The tentative five-year deal announced Monday covers more than 15,000 members of the International Association of Machinists, the Transportation Communications Union and the Brotherhood of Railway Carmen unions.

But the two biggest rail unions that represent engineers and conductors said over the weekend they still haven’t been able to reach a deal their members would accept.

The railroads have until mid-September to reach agreements with all their unions before federal law would allow them to go on strike. If it gets to that point, however, Congress is expected to step in to keep the trains moving because a rail strike could be devastating to the economy. Lawmakers could impose terms on both sides or order arbitration.

Roughly 115,000 workers are represented by all the railroad unions. Even though they have been negotiating jointly as a coalition, each individual union now has to reach its own agreement with the railroads that its members will vote on. CSX, Union Pacific, BNSF, Norfolk Southern and a number of other railroads are represented by the National Carriers Conference Committee in the talks.

“It is critical for all stakeholders — including customers, employees, and the public — that all parties promptly resolve the negotiations and prevent service disruptions,” the railroads said in a statement.

The deal announced Monday closely follows the recommendations of an emergency board that President Joe Biden appointed last month. The board heard from both sides before issuing a 124-page report with recommendations. The railroads said they want to work out contracts based on those recommendations.

“This comes after a long, tough process that began almost three years ago and led us through every step of the Railway Labor Act, including a Presidential Emergency Board,” said Josh Hartford with the Machinists Union’s Rail Division.

The tentative deal includes one additional paid leave day a year. The raises in the deal are bigger than the 17% ones railroads were offering but not as generous as the 31% raises the unions sought.

In addition to the 24% pay boost, the board also recommended five $1,000 bonuses in the five-year deal which is retroactive to 2020. Rail workers will see increases in their health insurance premiums each year as part of the deal, but their cost will be capped at 15% of the total cost of their health plans.

The railroads have said the recommendations that the three unions associated with the Machinists agreed to Monday will deliver the biggest raises in decades and increase average railroad salaries up to $110,000 a year by the time the deal expires in 2025.

The heads of the Sheet Metal, Air, Rail and Transportation Workers — Transportation Division union that represents conductors and the Brotherhood of Locomotive Engineers and Trainmen union that represents engineers said in a joint statement Saturday that the railroads still hadn’t done enough to address their quality-of-life concerns. The unions have complained about strict attendance policies that railroads have imposed that make it hard to take any time off and about the increase in workload they have seen in recent years after freight railroads cut nearly one third of their workforces.

In their recommendations, the presidential panel of arbitrators said the unions’ concerns about working conditions should be resolved through arbitration instead of being addressed in the new contract.