Against one of the majors’ worst teams with one of the worst pitching staffs, a breakthrough seemed inevitable all afternoon.

It never came and the Yankees absorbed a dispiriting 2-0 loss to the Angels Sunday afternoon in front of 40,309 at Angel Stadium that kept them from a three-game sweep.

The offense, with Mark Teixeira, Chase Headley and Aaron Hicks back in the lineup, never got much going, producing just six hits and stranding eight.

The Yankees (63-60) continue their six-game trip West Monday night against the Mariners, one of the teams ahead of them in the American League wild-card chase.

Rookie righthander Chad Green, coming off an 11-strikeout performance in his previous outing against Toronto, allowed a first-inning run but nothing thereafter.

The 25-year-old Green allowed one run, five hits and a walk, striking out five.

Angels righthander Jhoulys Chacin came in 2-6 with a 6.10 ERA but allowed six hits over 5 2⁄3 shutout innings.

Righthander Deolis Guerra took over with one on in the sixth and struck out Brian McCann. Guerra pitched 1 1⁄3 scoreless innings, giving way to righty JC Ramirez, who stranded two in the eighth.

Righty Fernando Salas, provided a two-run cushion by Andrelton Simmons’ two-out RBI single in the bottom of the eighth, pitched a scoreless ninth for his fourth save.

After the Yankees were set down in order in the top of the first — the first time that happened in the series — the Angels (52-72) took the lead in a 22-pitch bottom half.

Green retired the first two batters he faced but allowed a single to Albert Pujols, who had three hits. C.J. Cron walked and Simmons came through with a two-out single, bouncing one between short and third for a hit that brought in a sliding Pujols just ahead of Brett Gardner’s throw, making it 1-0.

The Yankees squandered a chance to tie it in the third. Teixeira, who had not played in the previous two games and in a 3-for-22 slide, led off with a double. After Headley struck out, Hicks stung a single to center, putting runners at the corners for Brett Gardner. The leftfielder, who lined out to Chacin to lead off the game, hit a ground smash but right at Cliff Pennington, who started a 4-6-3 inning-ending double play.

The Yankees loaded the bases with two outs in the fourth but could not score. Didi Gregorius, batting cleanup, singled to left and Starlin Castro reached on an infield single to short. McCann, who has appeared mostly at DH since losing the starting catcher’s job to Gary Sanchez, walked, loading the bases for Teixeira. The first baseman worked the count full before flying to center.

Hicks singled with one out in the fifth and went to second on Gardner’s groundout. Ellsbury could not get him home, however, popping to second for the third out.

Ellsbury did save the Yankees from falling further behind in the bottom half. Trout singled with two outs and Pujols gave a ride to a full-count fastball, sending it to center. Ellsbury drifted back, felt for the wall and perfectly timed his jump in bringing the ball back over the wall for the final out.

Gardner drew a walk against Ramirez in the eighth and was replaced by Ellsbury at first after a 4-6 force play. With Sanchez, 0-for-3 to that point, at the plate, Ellsbury stole second, his 18th theft of the season. Sanchez got ahead 3-and-1 before drawing a walk. The Yankees again came up empty as Gregorius struck out and Castro pounded one in front of the plate, which turned into a 2-3 putout.