CHICAGO (AP) -- One wasn't enough for Chris Duffy.
"It's always nice to hit a home run," Duffy said. "Two is that much better, especially when we win the game."
After Pittsburgh had wasted a five-run lead, Duffy connected off Scott Eyre (0-2) leading off the ninth for his third homer in 353 career at-bats. One out later, Xavier Nady homered against Ryan Dempster.
"Every time somebody makes a bad pitch on this team, it hurts us bad," Eyre said.
Duffy went 4-for-4 with three RBI and two stolen bases that raised his total this season to 19. Coming in, Duffy's only major-league home run was Aug. 1, 2005, off Tim Hudson at Atlanta.
"I took the same approach as I did when I was leading off the game," Duffy said. "I wanted to be aggressive and just see a pitch in the zone. Fortunately, I was able to get ahead and kind of cheat a little bit, figuring he's not going to put me on, so he's probably going to throw a fastball and I kind of guessed right."
Despite Duffy's relative lack of power, Eyre wasn't surprised.
"Everybody can hit a home run in the big leagues," he said. "If you throw the ball down the middle of the plate, that's what he gets paid to do. I just made a bad pitch and he did what he's supposed to do with it. I know the scouting report on Duff. Late in the game, he's a fastball hitter. So why did I throw two in a row? Dumb. I made a bad pitch today."
Duffy hit Sean Marshall's second pitch into the right-field bleachers. With two outs in the third, he outraced Marshall to the bag a grounder to the right of first baseman Scott Moore for an infield single and then stole second and scored on Nady's single.
"Obviously our center fielder had quite a day for himself, to say the least," Pirates manager Jim Tracy said. "I couldn't be more pleased for him. He started the game off real good for us, and obviously he finished it off for us very, very well."
Jonah Bayless (1-0) got the last out in the eighth for his first major-league victory, and Salomon Torres finished for his fourth save of the season. The Cubs (56-84) fell a half-game behind the Pirates (57-84) for the worst record in the NL.
Pittsburgh had taken a 5-0 lead in the fourth thanks in large part to the defensive sloppiness that has come to define the Cubs' season. With runners on first and second, Jose Castillo bounced a grounder to third that should have been a double play, but second baseman Freddie Bynum couldn't get a grip on the relay throw and Chicago got just one out.
Chicago closed to 5-3 in the bottom half on Aramis Ramirez's 32nd homer, a two-run drive, and Moore's RBI double, his first major-league hit.
Reliever Carlos Marmol homered in the fifth, cutting Pittsburgh's lead to 5-4, and Moore homered in the sixth.
Marshall allowed five runs and seven hits in four innings, while Chacon gave up five runs and eight hits in six innings.
Auto racer Danica Patrick threw out the first pitch and led the Wrigley Field crowd in a rendition of "Take Me Out to the Ball Game" during the seventh-inning stretch. She sported a home Cubs jersey with her car number, 16, on the back. ... The crowd of 27,105 was the lowest at Wrigley since Sept. 26, 2002, vs. Cincinnati. ... Pittsburgh shortstop Jack Wilson, who had missed 12 straight starts with an ear infection, made his first start since Aug. 24. ... Ramirez's home run broke an 0-for-15 slump.