On two consecutive days, the Twins used late comebacks to set the stage for an exciting walk-off win. They looked poised to do the same on Sunday when Harrison Bader, fresh off the bench, belted a game-tying home run in the eighth inning.

But after coming back from one and two-run deficits earlier in the day, the Twins were unable to do it again a third time after reliever Justin Topa allowed three runs in the top of the 10th inning. The Twins got one run back but fell 7-5 in the series finale in extra innings against the Tampa Bay Rays on Sunday afternoon at Target Field.

“It felt like the game was very winnable. We had our opportunities,” manager Rocco Baldelli said. “When you give up a handful of runs in the last couple innings, it does get challenging.”

After a trio of the Twins’ top bullpen arms had already been used in the game and with Jhoan Duran coming off a two-inning appearance the day before, the Twins turned to Topa in the 10th.

He quickly allowed a go-ahead double to Yandy Díaz, scoring the automatic runner and putting the Rays (49-41) in the lead once again. A second run scored on a sacrifice bunt, and Topa himself threw the ball away trying to nab the runner at first. That runner, José Caballero, would score the Rays’ (43-47) third run of the inning.

“A couple plays late in the game we don’t complete and it ends up leading to runs that are going to get put on the board,” Baldelli said. “Any space you give them, they’re going to take.”

All of that came after some eighth-inning drama in which the Rays scored a pair of runs on two batted balls that didn’t leave the infield. But the Twins wiped that lead away with one swing from Bader, who hit a walk-off home run two days earlier.

They earlier erased a one-run lead in the sixth inning with a nice slide from Trevor Larnach at the plate to evade a tag.

“I try to be aggressive in the best way I can,” Larnach said. “It is fun for the team when it works out.”

The Twins had been leading when the Rays struck a couple innings earlier against starter Joe Ryan. Ryan allowed a solo shot to Taylor Walls in the third inning and the Rays took a lead on a Jonathan Aranda RBI knock in the fourth inning, but that was all the Rays would manage against Ryan, who threw six innings of two-run ball, walking one and striking out eight as he recorded yet another quality start.

“Joe threw really well,” Baldelli said. “He looked great. Held everything together really well through the outing.”

The Twins were playing catch up from the fourth inning on, but did briefly have a lead when Byron Buxton, named an all-star for the second time in his career on Sunday, hit a solo home run to lead off the bottom of the first inning.

“I think it’s a good sign when we can come back, even if it falls apart,” Ryan said. “Obviously that’s not what you want and you want to win the game and hold that there. Our bullpen’s been really solid, so I think we have that potential to just keep going.”