NEW YORK (AP) Starlin Castro, Nathan Eovaldi and Anthony Swarzak helped the Yankees get back over .500 and chip away at the huge gap with AL East-leading Baltimore. New York will need a lot more wins during the rest of July to persuade management not to jettison veterans for prospects.
''Nobody in this room believes we can't do it,'' Swarzak said after retiring eight straight batters in relief of Eovaldi during Tuesday night's 7-1 win over the Orioles.
Castro homered in the second off Vance Worley (2-1) and hit a two-run double in the sixth against Odrisamer Despaigne. Chase Headley added a two-run homer off Mychal Givens in the eighth as the Yankees won their third straight.
Relieving Eovaldi with the bases loaded and a 3-1 lead in the sixth, Swarzak got major league home run leader Mark Trumbo to foul out to Rob Refsnyder with his back to the plate down the right-field line and Jonathan Schoop to foul out to shortstop Didi Gregorius.
New York closed within 6 1/2 games of Baltimore and remained five games back for the second AL wild card. Time is running down for the team's decision whether to buy or sell as the Aug. 1 trade deadline approaches.
''I try not to think about that. I try to focus on the game, the game in hand, and my focus is making up ground,'' Yankees manager Joe Girardi said,
At 47-46, the Yankees are above .500 for just the third time since mid-April. New York was 4-2 before dropping to 9-17 and later got above .500 at 31-30 and 37-36 only to regress.
''It's been frustrating this year, because we've been here so many times and we haven't been able to break through,'' Girardi said. ''I feel like if we can get over that mark, we can build on it.''
Making his first start since July 1 following three relief outings caused by a six-start winless streak, Eovaldi (8-6) won for the first time since May 29. He allowed one run and four hits in 5 1/3 innings, needing 18 pitches to get through the first but 37 for the next four.
''I don't really think about getting traded,'' said Eovaldi, who is eligible for free agency after the 2017 season. ''I feel like it kind of takes away from what I need to do here. I started out with this team, and want to finish with this team, and I feel like we've got a really good chance of coming back and coming through.''
Eovaldi retired 11 straight batters before walking Ryan Flaherty in the sixth. He gave up Joey Rickard's RBI double and loaded the bases with a walk to Manny Machado.
Swarzak was assisted by Refsnyder, the rookie first baseman who caught Trumbo's foul and made a two-hop throw home that held Adam Jones at third. Nick Goody followed and struck out the side in a perfect ninth, giving the Yankees' No Runs DMC trio a rest.
Girardi has been seeking a bridge to Dellin Betances, Andrew Miller and Aroldis Chapman.
''Yeah, he could be that guy,'' Girardi said of Swarzak.
Baltimore has lost three straight, and its AL East lead over second-place Boston was cut to one-half game. First baseman Chris Davis (stomach virus) missed his second straight game and catcher Matt Wieters (sore right foot) also was out.
Worley (2-1) made his first start since April 15 following 18 consecutive relief appearances. He allowed three runs, three hits and four walks in 4 1/3 innings.
New York's Jacoby Ellsbury grounded to shortstop in the first but his swing knocked off the glove of Caleb Joseph, who was charged with catcher's interference. Ellsbury has reached on catcher's interference nine times, the most in a season since Roberto Kelly's eight, also for the Yankees, in 1992. Ellsbury has done it 23 times in his career, the most among major leaguers since Pete Rose's 29, according to the Elias Sports Bureau.
''There's probably nine catchers that would like to see something change. It just doesn't seem fair to the defense,'' Orioles manager Buck Showalter said.
New York failed to score in the first inning for the 23rd consecutive game.
The Yankees open the 2017 season at Tampa Bay on April 3, according to the team's draft preliminary schedule, then go to Baltimore before their home opener, slated to be against the Rays on April 10. Some openers likely will be moved to April 2 for ESPN telecasts.
RHP Chad Green was scratched from his start at Triple-A Scranton/Wilkes-Barre. Girardi wouldn't say whether he is being recalled, which could mean a spot start that would allow Masahiro Tanaka to pitch with an extra day of rest.
Yankees: 1B Mark Teixeira was out of the starting lineup for the third straight game because of a sore left foot.
RHP Michael Pineda (3-9) is to start for the Yankees on Wednesday and RHP Yovani Gallardo (3-1) for the Orioles. Pineda is 0-3 with a 4.46 ERA in six starts since beating the Los Angeles Angels on June 7.