CC Sabathia turned 36 on Thursday, but for the better part of the afternoon he spent his birthday defying time. He stymied the Orioles, he used his fastball, cutter and changeup to great effect, and should have given the Yankees every chance to sweep the team that came into this four-game series in first place.

But time catches up to everyone, and for Sabathia, it happened in the seventh.

Sabathia allowed two runs on three hits in the inning, and it was more than enough for the Orioles and Chris Tillman, who salvaged the finale, 4-1, and spent the afternoon shutting down a limp Yankees’ lineup in every which way. The loss snapped the Yankees’ four-game win streak, and provided an extra dose of reality for a team that still finds itself in fourth place in the AL East with a little more than a week until the Aug. 1 non-waiver trade deadline.

“I thought [Sabathia] gave us a gritty performance today and it was unfortunate,” Joe Girardi said. “He didn’t give up a lot of hard-hit balls and you look up and there’s four runs on the board . . . You’re probably extremely frustrated because when you’re not giving up hard contact, you’re probably making good pitches. It’s frustrating for him and for us that they’re turning into base hits.”

Sabathia gave up two runs in the first, thanks in part to a pair of misplays by Didi Gregorius that were ruled hits, but otherwise cruised until the seventh — which he was forced to pitch because Dellin Betances was unavailable. But even that first-inning production would have been sufficient for Tillman, who improved to 14-2 with a 3.28 ERA; he allowed one run on four hits over seven innings, with two walks and seven strikeouts.

“Tillman was basically unhittable,” Mark Teixeira said. “When a good pitcher makes his pitches, you’ve got a battle . . . He didn’t make a mistake all day.”

The Orioles opened it up in the first when Gregorius attempted to field Jonathan Schoop’s one-out grounder on the backhand but missed, in what was charitably called an infield hit. Manny Machado singled, chasing Schoop to third, and, one batter later, Chris Davis walked to load the bases. J.J. Hardy then hit a liner toward Gregorius, who again missed it on the backhand. The ball deflected off his glove to score Schoop and Machado.

Gregorius tried to make up for it in the second, when he led off with a double to left, moved to third on Alex Rodriguez’s long flyout to right, and scored on Starlin Castro’s single to right, cutting the Orioles’ lead to 2-1. But that was all the Yankees could manage against Tillman, who handily shut down a lineup that had produced 12 runs in the last two games. The Yankees managed only two singles in the last seven innings.

Without Betances, who pitched in three of the previous four days, the Yankees stretched Sabathia into the seventh, but he almost immediately got into trouble. With one out, he allowed back-to-back singles to Caleb Joseph and Julio Borbon, prompting action in the bullpen. He struck out Nolan Reimold on a full count, but then Schoop struck again, lining a two-run double to right to provide the final margin.

Sabathia (5-8, 4.04 ERA) threw 97 pitches over 6 2⁄3 innings, allowing four earned runs on seven hits, with a walk and only two strikeouts. It was still one of his better performances in recent weeks, considering he’s pitched to a 7.94 ERA in his last five starts.

“It’s part of the game,” he said. “It is what it is. I need to make a better pitch against Schoop [in the seventh] and leave the game at 2-1 . . . Every game right now is crucial. It would have been great to get the sweep but to win three out of four is still big.”