PITTSBURGH -- At last, the Marlins manufactured a few runs. But it was the scoring chances they let slip away that proved costly.
Given an opening to rally, the Pirates capitalized -- and celebrated -- in walk-off fashion.
Josh Harrison became the hero, leading off the ninth inning with a pinch-hit home run that lifted the Pirates to a 4-3 win over the Marlins, who have now dropped three straight.
"When you're on the road, the momentum can turn on you in a heartbeat," Marlins manager Mike Redmond said. "This is a tough place to play, and a tough place to win a ballgame. When you get an opportunity to add on runs, you've got to do it. These guys have a lot of weapons. They've got guys on the bench who can hit. They have a lot of different guys they can run at you. Tonight, we had some chances to score. It didn't happen. That's the way it goes."
Miami fell to 15-24 all-time at PNC Park, including four straight stemming back to 2012.
Mike Dunn, who worked out of a bases-loaded, no-out situation in the eighth inning, entered for the ninth. Pittsburgh pinch-hit Harrison for Garrett Jones. Manager Clint Hurdle's decision clicked perfectly, as Harrison had just enough to clear the wall in right-center.
"I knew I was leading off the inning, so I tried to get a good pitch," Harrison said. "I faced him in Miami, had a pretty good idea what he throws. Wanted to be aggressive but within the zone. Got a good pitch to hit and got a good swing on it."
Off the bat, Dunn initially thought the ball may not have the height to clear the fence.
"I didn't think it was going to be high enough. But it carried. Home run," Dunn said. "When [Harrison] fouled off that 0-1 pitch, it looked like his whole approach was away, going to right field. I shook to a fastball in. I thought I could get one in on him, because it looked like he was looking for a fastball away.
"I made a mistake pitch, belt-high on the outside corner. That's what happens. You hope for those to be foul balls. It just didn't work out tonight."
For Miami, it was a frustrating finale in a game there were plenty of chances to break open.
Missed chances underscored the entire night, and the seventh inning was more of the same. Miami loaded the bases off Vin Mazzaro, assisted by Pedro Alvarez's two-out throwing error that allowed Jake Marisnick to reach. The threat fizzled when Jeff Mathis lifted a routine fly ball to left field, capping a full-count showdown.
The Marlins had their turn to frustrate the Pirates in the eighth inning. Dunn inherited the bases-loaded situation from Chad Qualls, but struck out Pedro Alvarez, and got Russell Martin to tap into a 6-4-3 double play.
"Coming in with the bases loaded, no outs, I was looking for a punchout, and then hoping for a double play, or another punchout," Dunn said. "It just happened to work out for us in the eighth inning. But you've got to stay focused. I knew I was going out for the ninth, unless we scored."
Harrison's homer turned out to be the defining play, but the storyline for Miami was again the same old story -- not enough offense.
The Marlins stranded 11 on base and were 3-for-14 with runners in scoring position on a night they collected 11 hits.
Lack of run support has been a storyline all season, and the Marlins are now 13-60 in games where they score three or fewer runs.
"The mark of a good team is to close, and finish out those games that are close and late," third baseman Ed Lucas said. "We'll get there. But again, you've got to take the positives from these types of games."
Miami claimed a three-run lead in the top of the third inning, but its fortunes deteriorated from that point.
Henderson Alvarez had a productive night, posting his fifth straight quality start, but he wasn't involved in the decision. The right-hander yielded three runs in seven innings, and struck out six.
The 23-year-old also collected his first big league RBI.
The Marlins were looking to defeat All-Star left-hander Jeff Locke for the second time in two weeks. Early on, they were in position, grabbing an early three-run lead, that disappeared in the third inning.
Locke settled for a no-decision, giving up three runs on nine hits with three walks and four strikeouts in 5 2/3 innings.
Blanked for the 13th time of the season on Sunday, the Marlins entered their series opener at Pittsburgh looking for some offensive spark.
They were able to break through for a run in the second inning on Alvarez's sacrifice fly to center.
The run also snapped the club's scoreless-innings drought at 10 innings.
In the third inning, the Marlins tacked on two more runs RBI singles from Logan Morrison, who narrowly missed a homer as his drive to right clanked high off the wall, and Donovan Solano, who added a run-scoring single.
In the third inning, the Pirates responded with three runs, on a string of three straight two-out hits. Neil Walker, with a man on, singled to right with two outs. Andrew McCutchen blasted a two-run double to deep center, and Pedro Alvarez's RBI triple tied the game at 3.
"I just get so tired just talking about the same stuff," Redmond said. "We've played that game I don't know how many times this season. We had lots of opportunities to score runs. We just couldn't get that hit to kind of give us a little breathing room."