Just in case there was any doubt that the Phillies are in an honest-to-goodness playoff race with eight games left in the season, cue up the eighth inning Friday night.

Héctor Neris, the longest consecutively tenured player on a team that hasn’t reached the postseason in nine years, was on the mound. The bases were loaded, a two-run lead hanging in the balance. He had thrown a total of 39 pitches, so manager Joe Girardi went to the mound intending to take him out.

But Neris put out his hand and patted his chest. He told Girardi, “No, give me another chance. I know I can get out this guy.” And then, two pitches later, he stabbed a grounder to the mound, ran to first base, and stomped on the bag with both feet.

Oh, there’s a playoff race in Philadelphia, all right.

“Hey, man, the emotion,” Neris said after the Phillies outlasted the Pittsburgh Pirates, 8-6, and moved within 1½ games of the first-place Atlanta Braves. “When you are in the moment, you don’t care how many pitches you are throwing. Just you need the outs. I wanted that, man.”

Neris threw 41 pitches, his highest total in a game since 2015, and got five outs, including the bases-loaded comebacker from Pirates leadoff man Ke’Bryan Hayes.

It appears Neris will need to get many more out over the next eight games. The Phillies’ bullpen is exhausted. Neither Archie Bradley nor Sam Coonrod pitched against the Pirates for reasons that Girardi didn’t want to get into after the game.

“Let’s just say I used the guys that were available to me tonight,” Girardi said. “We’ll leave it at that and we’ll talk about it tomorrow.”

» READ MORE: Why reliever Connor Brogdon’s imminent return will be welcomed by the Phillies bullpen

Just as Neris came through, so did Didi Gregorius, the embattled shortstop in the midst of a career-worst season. Gregorius, who was hitting .148/.260/.259 against left-handed pitchers, bashed a three-run homer against Pirates lefty Chasen Shreve in the seventh inning to bring the Phillies back from a 6-5 deficit before an announced crowd of 20,548.

One inning earlier, Ronald Torreyes delivered another clutch pinch-hit, an RBI double to give the Phillies a 5-4 lead after they had trailed 4-1. But reliever Cam Bedrosian allowed a two-run homer to Wilmer Difo in the top of the seventh, marking the Phillies’ 34th blown save and tying a major-league record set by the 2004 Colorado Rockies.

It was a game that had to be seen to be believed. If it was a movie, it would’ve been Rocky, hitting the canvas and getting up over and over. Or maybe it would’ve been Bryce Harper, dressed like Russell Crowe in Gladiator, going to the center of the field, holding his bat aloft, and shouting, “Are you not entertained?”

At this point, how can you not be?

It wasn’t unlike Thursday night, when Torreyes’ three-run homer completed a comeback from six runs down. The Phillies have won four games in a row and six of eight, with a three-game showdown in Atlanta looming next week.

No wonder Neris, who lost the closer job in June and has been lights-out as a setup man, wanted the ball in his hands.

“Héctor’s been so clutch for us,” Girardi said. “He’s a guy that is just really tough. He is a tough kid that is durable. You think about where he was 3 1/2 months ago and how he’s bounced back. He’s a warrior to me.”

Didi delivers

Girardi has kept Gregorius in the lineup, even against lefties, because of his track record. But the manager has also made clear that the Phillies need Gregorius to produce down the stretch if they’re going to catch the Braves.

The message seems to have been received. Gregorius has homered in back-to-back games.

“I haven’t been producing the whole year,” he said. “I’ve been working behind the scenes and doing all the things I need to do. I’m just trying to get better. These last couple games are really important, so I’m trying to do the best that I can as I go out there and try to be a big part of the offense.”

» READ MORE: How the deadline deal that proved to be lifeline for Phillies’ playoff hopes went down

Gibson pulls a Blanton

Kyle Gibson’s numbers since being acquired at the trade deadline: 4.87 ERA in 64 2/3 innings over 11 games (10 starts).

Joe Blanton’s numbers after being acquired in July 2008: 4.20 ERA in 70 2/3 innings over 13 starts.

The similarities now extend to their hitting, too. Gibson slugged his first career home run to open a 1-0 lead in the third inning, bringing back memories of Blanton’s big swing in Game 4 of the 2008 World Series. It marked the first homer by a Phillies pitcher since Vince Velasquez on June 28, 2019.

But the lead was short-lived. Gibson loaded the bases in the fourth inning on a single, a walk, and a hit by pitch before allowing a two-run double to Kevin Newman and Michael Perez’s two-run single to put the Phillies down 4-1.

Herrera hurting

Center fielder Odúbel Herrera left before the top of the fifth inning because of what the team described as “soreness” in his left ankle. The injury has dogged him since before the All-Star break, forcing him to miss nine games in July.

Upstart rookie Matt Vierling took over for Herrera and promptly doubled and scored in the fifth inning. Recalled from triple A last month, Vierling has contributed as a right-handed bat and a versatile defender in the outfield and at first base.

Fathers and sons

One batter after Bedrosian allowed the go-ahead homer, he gave up a single to Hayes.

In other words, former Phillies closer Steve Bedrosian’s son gave up a hit to former Phillies third baseman Charlie Hayes’ son 32 years after the fathers were traded for each other. Pretty cool.