NEW YORK -- It was an eyesore of a baseball game unless you had manager Gabe Kapler’s view from the visiting dugout. From his perspective, the Phillies’ long and winding afternoon that crept into early evening at Citi Field was a thing of beauty.

The perpetually up manager watched his team go down 3-0 in the first inning. Then he had to remove his starting pitcher with one out in the fifth inning after Vince Velasquez walked consecutive batters to drive his pitch count to 96.

Neither of those things are recommended ingredients in the recipe for winning a baseball game, but the Phillies escaped from New York with a 10-7 victory over the Mets on Sunday, and you’ll have to excuse Kapler for feeling giddy about the outcome.

Scott Kingery (No. 4) celebrates with Maikel Franco after his seventh-inning home run against the New York Mets Sunday at Citi Field.
Kathy Willens / AP
Scott Kingery (No. 4) celebrates with Maikel Franco after his seventh-inning home run against the New York Mets Sunday at Citi Field.

Actually, even the Phillies’ manager had to admit the game lacked aesthetic quality.

"We played a team game,” Kapler said. “It wasn’t the prettiest win by any stretch, but we were able to get it done and it was a really important win for us. I thought it was nice to get contributions from every portion of our team.”

Kapler used a total of 20 players, including eight pitchers who combined to throw 207 pitches. He could not feel comfortable, however, until Hector Neris retired Michael Conforto for the final out with two runners on base in the bottom of the ninth.

Better still for Kapler and his crew, the Chicago Cubs, who probably lost star shortstop Javier Baez for the rest of the season to a fractured thumb over the weekend, continued to stumble away from Wrigley Field. They lost in Milwaukee on Sunday to tighten the crowded wild-card race just a little bit more.

The Phillies, by winning two out of three at Citi Field, closed to within two games of the Cubs for the second wild-card playoff berth. When they started their seven-game road trip on Labor Day, they were 2 ½ games out. The Phillies trail Arizona by a half game and are even with the Brewers in the standings.

As ugly as it was at times, there was a lot for Kapler and the Phillies to like during the 4-hour, 29-minute game that was just one minute shy of tying the record for the longest nine-inning game in franchise history.

“What you realize is that there were a lot of people on base on both sides,” said Scott Kingery, whose two-run homer in the seventh inning pushed the Phillies’ lead to 7-4 after the Mets had drawn even in the fifth. “You just feel like when you’re in the dugout, ‘Dang, we’ve been sitting here for a while.’ And then you get out there on defense and the next thing you know there are two guys on and no outs.

“It’s a long game and it gets tiring, but obviously the race we’re in and going against the Mets, you have to stay locked in the whole time. I think it was a good job for us to stay locked in and get the ‘W’ for us. It would have been a lot worse if we lost.”

The homer was Kingery’s 18th of the season, and it’s impressive that he could reach 20 in his second season in the big leagues despite missing a month with a hamstring injury. More impressive was that his homer came against Mets reliever Justin Wilson, who had allowed just two runs in his last 22 2/3 innings.

Kapler was also pleased that the Phillies rallied against Noah Syndergaard, who had a 2.80 ERA in his 10 starts since the All-Star break before Sunday. The Phillies proved to be a thorn in Thor’s side this entire season, tagging him for 22 hits and 13 earned runs in three games and 15 innings. Syndergaard has pitched into the sixth inning in 22 of his 28 starts this season, but he never got past the fifth against the Phillies.

Phillies' infielder Maikel Franco (7) reacts running down the third base line after hitting a two-run home run during the sixth inning of a baseball game against the New York Mets, Sunday, Sept. 8, 2019, in New York. (AP Photo/Kathy Willens)
Kathy Willens / AP
Phillies' infielder Maikel Franco (7) reacts running down the third base line after hitting a two-run home run during the sixth inning of a baseball game against the New York Mets, Sunday, Sept. 8, 2019, in New York. (AP Photo/Kathy Willens)

Rookie Adam Haseley and Corey Dickerson, the team’s best trade-deadline addition, helped the Phillies recover from their early deficit against Syndergaard. Haseley homered to the opposite field to make it 3-2 in the fourth, and Dickerson delivered a two-run single that put the Phillies up 4-3 in the fifth.

That hit also proved to be the final one allowed by Syndergaard, but that probably had more to do with Velasquez’s inability to throw a strike in the fifth than the way the Mets’ starter was pitching. After getting the first out of the inning, Velasquez walked Wilson Ramos and Robinson Cano, prompting Kapler to walk to the mound and ask for the baseball.

From there, it became a long, drawn out bullpen game that the Phillies survived to win.

Now, a far greater test begins as the Phillies must play a six-game homestand against Atlanta and Boston before embarking on a brutal 11-game road trip to Atlanta, Cleveland, and Washington.

“We have to keep demonstrating the fight we showed on this road trip,” Kapler said. “At the end of this game when Hector was out there, I looked down at our dugout and everybody was up and locked into the game. It was a long game, but it didn’t seem like anybody was exhausted.”

And that was saying something because this was an exhausting game.