Shortly before first pitch, the prognosis for Orioles first baseman Ryan Mountcastle took an unexpected turn.

For the past few days, Mountcastle has dealt with vertigo, but manager Brandon Hyde said Tuesday the 26-year-old was feeling better. And then, all of a sudden, Mountcastle was placed on the 10-day injured list, leaving a hole in Baltimore’s lineup for the next week.

Anticipating the unanticipatable is part of executive vice president and general manager Mike Elias’ job, so even though there was no certainty that Mountcastle would miss time this season, Elias spent much of the offseason filling the upper minor leagues with major league-capable options in the event the worst occurred.

And, in the 11-6 victory against the Toronto Blue Jays at Camden Yards on Tuesday night, the careful planning of the offseason showed its value — just as it has for much of the campaign. It was a slugfest all around, with a season-high 17 hits and four homers. But the two-run blast from Ryan O’Hearn in the third inning as part of a deluge of runs is the best statement for what Baltimore has going this season.

The Baltimore Banner thanks its sponsors. Become one.

The Orioles lost what was expected to be a major piece of their lineup. And in Mountcastle’s place comes a trade piece who broke spring training as a member of Triple-A Norfolk yet hasn’t stopped hitting since reaching the major leagues with Baltimore.

“What hasn’t he done?” manager Brandon Hyde asked rhetorically, because O’Hearn holds a .319 average and a .991 on-base-plus-slugging percentage. “Over the course of a six-month season, you’re going to have guys go down for what you hope is a short amount of time. Good teams have guys step up in their place, and that’s why depth is so important.”

The scoring outburst that secured the Orioles (42-24) their fifth straight win was reinforced by six strong innings from right-hander Dean Kremer. He navigated around a leadoff baserunner in each of his first five innings to allow just two runs. The Orioles roughed up right-hander Chris Bassitt to the tune of eight runs in three innings.

On Tuesday, O’Hearn was joined in homers by Aaron Hicks, Adam Frazier and Gunnar Henderson — the latter of whom clubbed the first grand slam of his career in the fourth inning a day after earning American League Player of the Week honors for an absurd stretch at the plate. In Henderson’s last six games, he is 13-for-23 with five extra-base hits that have been sprayed to all parts of the field.

“Just feel like I’m very aware of what I want to do when I get up there in the box,” Henderson said, “and just going up there and executing my plan.”

The Baltimore Banner thanks its sponsors. Become one.

In a sense, though, this was expected out of Henderson, who was a former top prospect and is a rookie of the year candidate. It wasn’t expected from O’Hearn, who spent parts of the last five seasons with the Royals after he was chosen in the eighth round of the 2014 MLB Draft. In Kansas City, O’Hearn was a below-average hitter the last four years.

Still, the Orioles swooped in to add O’Hearn via trade this winter, and he joined a growing group of potential backup first basemen to compete for a position behind Mountcastle. Beyond him, they signed Josh Lester, an infielder who has also arrived in Baltimore as a utility bench piece.

For a team to find success — and the Orioles have, holding the second-best record in baseball — they need depth. O’Hearn has proven more than capable.

“Crazy stuff happens in this game,” O’Hearn said. “I’ve had everyday at-bats and everyday playing time taken away from me before, and I don’t like that, obviously. It was a long battle to get back to the point where you get the chance to play every day. So definitely going to take this opportunity and treat it the same as everything: grind it out, have fun out there and just compete.”

O’Hearn reached in his final seven plate appearances against the Royals this weekend, a reminder to his former team of what he can do with an extended chance. On a trip to Milwaukee in front of 30-plus O’Hearn family members, he powered another homer.

The Baltimore Banner thanks its sponsors. Become one.

There’s plenty of credit to go around — from Elias’ for completing the trade, to Baltimore’s hitting coaches for maximizing O’Hearn’s potential, and most of all to O’Hearn for making the most of this.

“Mounty’s the first baseman, and we want him back as soon as possible,” O’Hearn said. “But I look at it as a great opportunity for me to get consistent ABs, and I feel good at the plate, feel good with what I’m doing, and I’m going to enjoy every moment of it.”

He isn’t alone in a surge, though, which is a credit to the Orioles’ player development team.

Hicks has reached in all 12 games he’s played for the Orioles (he was another prudent Elias choice, adding him after the New York Yankees released Hicks). Frazier hit his eighth homer of the season in just his 64th game, matching the total he managed in 2021 and 2022 combined. Henderson overcame a slow start to the season to compile hits in the bucket loads.

“It feels like it’s somebody different every night that comes through for us,” Henderson said, “and I feel like that’s a big testament to our team. We’re all going to pick each other up and play hard no matter what.”

The Baltimore Banner thanks its sponsors. Become one.

All of that makes the short-term absence of Mountcastle more manageable.