INGLEWOOD, Calif. (AP)Through 45 minutes on Sunday, the Los Angeles Rams appeared on the verge of picking up consecutive wins for the first time in nearly 13 months.

Unfortunately for coach Sean McVay and his team, games last 60 minutes.

The Rams had a 17-10 lead going into the fourth quarter but couldn’t make it stand as the Steelers scored two touchdowns to rally for a 24-17 victory.

“There wasn’t really many adjustments that they made other than they ended up just being able to make some plays,” McVay said. “They got some opportunities to be able to convert on some third downs and they ended up getting a couple things going in the run game.”

Los Angeles (3-4) held Pittsburgh to six first downs in the first three quarters but allowed 11 in the fourth. The Steelers also converted three of their five third-down plays and came through on a pivotal fourth-down play before the two-minute warning when quarterback Kenny Pickett got a generous spot on fourth-and-1 sneak at the Rams 39-yard line.

Pickett completed all seven of his passes for 138 yards in the fourth quarter after going 10 of 18 for 92 yards in the first three.

The Steelers scored both of their late touchdowns on the ground. Jaylen Warren’s 13-yard TD and Najee Harris’ run from 3 yards out were both up the middle and through the heart of the Rams’ defense. The plays were set up by the Steelers putting a man in motion.

“I felt like our preparation was right, we’ve just got to finish,” linebacker Byron Young said.

The three longest plays the Rams allowed also came in the fourth, including Pickett connecting with Diontae Johnson for a 39-yard gain on a whip route after Rams cornerback Derion Kendrick went for the interception. Johnson had 31 yards after the catch as before being tackled at the Rams 18.

That wasn’t Kendrick’s first bad play in the quarter. He also was penalized for being one of too many players on the field.

“I think at the end of the day, we have to do a better job of just being able to lock in on the details and one step at a time,” safety Quentin Lake said.

The Rams’ offense had the ball for only 3:05 in the quarter. Matthew Stafford was 0 for 4, marking only the second time in his 15-year career he has failed to complete a pass in the fourth when making at least four attempts.

The other time was also against the Steelers (0 for 10) when was with the Detroit Lions in 2013.

“We felt like we controlled it for a decent amount. We just didn’t finish it,” said Stafford, who was 14 for 29 for 231 yards with a touchdown and an interception. “We have to be more consistent and give ourselves opportunities to close these games out when we do get the chance to do it.”

If the Rams are going to begin stacking wins, it will have to start on the road. Their next home game isn’t until Nov. 19 against Seattle, with trips to Dallas and Green Bay ahead of their bye week.

“I thought we were in a position to be able to do that today and ultimately, we didn’t get that done, ” McVay said. “We’ve got to figure out how to do it at a more consistent clip, because I think we can and I trust that we will.”