The Philadelphia Phillies evened their National League Division Series with the New York Mets with a 7-6 win in Game 2 Sunday in Philadelphia.

Nick Castellanos' single in the bottom of the ninth inning off Mets pitcher Tylor Megill scored Trea Turner with the winning run and capped a see-saw finish that saw game-changing swings by both teams across multiple innings.

New York had tied the game at 6 in the top half of the ninth inning on Mark Vientos' second two-run home run of the game, off Phillies reliever Matt Strahm.

The Mets took a 3-0 lead on the strength of Vientos' first two-run home run of the day, in the top of the third inning off of Phillies starter Cristopher Sanchez, and a solo home run by Pete Alonso in the top of the sixth inning off Phillies reliever Jose Ruiz. But Philadelphia tied the game in the bottom of the sixth on back-to-back home runs by Bryce Harper and Castellanos off Mets starter Luis Severino.

New York took the lead back in the top of the seventh on a solo home run by Brandon Nimmo, but Philadelphia jumped in front for the first time in the bottom of the eighth. Bryson Stott's two-run double off Mets closer Edwin Diaz gave the Phillies a 5-4 lead, and after Megill entered, Philadelphia made it 6-4 when Vientos couldn't handle a ground ball hit by J.T. Realmuto, allowing Stott to score. That set up Vientos' heroics in the top half of the ninth inning, and, ultimately, Castellanos' heroics in the bottom half.

The series shifts back to New York for Game 3 Tuesday afternoon. That game will start at 5:08 p.m.