NEW YORK — Jacoby Ellsbury overcame a first-inning deficit against R.A. Dickey with a two-run homer on the knuckleballer’s third pitch of the game, then added an RBI single to lead the New York Yankees over the Toronto Blue Jays 5-3 Monday.

In a matchup of teams fighting for playoff berths as the season passed Labor Day, Masahiro Tanaka (12-4) settled down after a shaky first to win his fifth straight decision.

New York (71-65) matched its season high of six games over .500 but remained on the periphery of contention, 31/2 games back for the AL’s second wild card.

The AL East-leading Blue Jays (77-60) lead the Boston Red Sox, who also lost Monday, by one game.

ORIOLES 7, RAYS 3: Ubaldo Jimenez threw a two-hitter for his first complete game since 2011 and Chris Davis hit his 34th homer and drove in three runs as playoff-contending Baltimore won at St. Petersburg, Florida.

ASTROS 6, INDIANS 2: Rookie Alex Bregman continued his hot hitting with a two-run homer as visiting Houston ended Cleveland’s six-game winning streak.

Bregman has hit all seven of his homers and driven in 22 runs over his last 19 games for the Astros, who remain two games out of the second wild-card spot in the AL.

TIGERS 5, WHITE SOX 3: Justin Upton hit a three-run homer in the 11th inning as visiting Detroit got its 11th win in 14 games.

ANGELS 10, ATHLETICS 7: Kole Calhoun hit a solo home run in the second inning and Albert Pujols had a two-run double in the fourth for visiting Los Angeles.

MARINERS 14, RANGERS 6: Robinson Cano homered during a five-run first inning, then Seattle pulled away with a six-run sixth in a win at home.

ROYALS 11, TWINS 5: Brian Dozier hit three home runs for Minnesota, but Kansas City got homers from Kendrys Morales and Eric Hosmer to pull away at Minneapolis.

NATIONAL LEAGUE

CARDINALS 12, PIRATES 6: Adam Wainwright drove in three runs and picked up his first victory since mid-July as visiting St. Louis drummed staggering Pittsburgh.

METS 5, REDS 0: Bartolo Colon (13-7) pitched six innings of five-hit ball and Matt Reynolds homered as the Mets won at Cincinnati for their sixth victory in eight games.

NATIONALS 6, BRAVES 4: Trea Turner and Chris Heisey each homered during a five-run third inning and Max Scherzer got his 16th victory as Washington won at home.

CUBS 7, BREWERS 2: Kyle Hendricks threw six strong innings as Chicago broke away late to win at Milwaukee.

ROCKIES 6, GIANTS 0: Chad Bettis threw a two-hitter for his first career complete game and Carlos Gonzalez hit a grand slam as part of a six-run third at Denver.

PHILLIES 6, MARLINS: Freddy Galvis hit a two-run homer as visiting Philadelphia snapped a six-game losing streak.

DODGERS 10, DIAMONDBACKS 2: Los Angeles hit five homers off Zack Greinke in winning its third straight game.

NOTES

ANGELS: Pitcher Matt Shoemaker underwent surgery to stop bleeding on his brain after he was struck in the head by a line drive against the Seattle Mariners.

ASTROS: Pitcher Dallas Keuchel has been shut down for now because of inflammation in his left shoulder and sent back to Houston for an examination.