Baseball fans were still trying to sort out the dizzying deals for postseason aces Jon Lester and John Lackey, Home Run Derby champ Yoenis Cespedes and All-Star shortstop Asdrubal Cabrera when they were treated to a most curious sight Thursday.

In the seventh inning of a tight game at Comerica Park — with the bases loaded, no less — Detroit center fielder Austin Jackson suddenly trotted from his position to the dugout.

He was on his way out of town, too, in a blockbuster, three-team swap that brought former Cy Young winner David Price to the AL Central-leading Tigers.

A whopping 18 teams began the day within five games of playoff position, resulting in a dozen deals shortly before Major League Baseball’s 4 p.m. EDT trade deadline.

The World Series champion Boston Red Sox, mired in last place, were the most busy. They sent Lester and outfielder Jonny Gomes to AL West-leading Oakland for Cespedes, traded Lackey to St. Louis, dealt shortstop Stephen Drew to the Yankees and moved pitcher Andrew Miller to Baltimore.

The Miami Marlins, often sellers as deadline day approaches, became buyers when they acquired pitcher Jarred Cosart from Houston in a six-player trade.

Teams can still make trades through Aug. 31 to have players eligible for the postseason, but it becomes more tricky. Now a player must first clear waivers, meaning every club in the majors has a chance to claim him before he can be traded.

All the action off the field Thursday made for great fun for fans, plus some heated up pennant races.

A look at the deals, and what they meant:

SEE YA, SAWX

A year after winning their third crown in a decade, Boston bailed out. The Red Sox picked Oakland as the landing spot for the coveted Lester, then paired up with the team they beat in the World Series last October to swap Lackey for Cardinals pitcher Joe Kelly and outfielder Allen Craig.

“It speaks to where we are as a team,” Red Sox general manager Ben Cherington said. “There’s nothing sort of celebratory about this. These moves are made because, collectively as an organization, we haven’t performed well enough, in this year anyway.”

STRAIGHT A’S

Looking for its first World Series title since 1989, Oakland kept dealing. After getting pitchers Jeff Samardzija and Jason Hammel from the Cubs in July, the team with the best record in the majors added Lester and outfielders Jonny Gomes and Sam Fuld. The Athletics had one leftover issue: They were set to give away 10,000 T-shirts at Saturday’s game that honored Cespedes, and they plan to hand them out.

PRICE IS RIGHT

A lot of teams wanted the 28-year-old lefty ace, who now joins fellow Cy Young winners Max Scherzer and Justin Verlander in Motown. In the three-team deal, Jackson went to Seattle while pitcher Drew Smyly and minor league infielder Willy Adames joined Tampa Bay. Price (11-8, 3.11 ERA) recently won six straight starts, and he isn’t eligible for free agency until after the 2015 season, boosting his chances to help bring Detroit its first championship since 1984.

“The question that we asked ourselves is: What gives us the best chance of winning the world championship this year?” General manager Dave Dombrowski said. “We thought adding him to our rotation at this point would give us the best chance to do that.”

THE SON WILL STILL SHINE

Cabrera teared up in the Cleveland clubhouse as he talked about being traded to NL East-leading Washington for infielder Zach Walters. The trade came a day after the Indians sent pitcher Justin Masterson to the Cardinals.

“I had fun here,” Cabrera said. “This was the team that gave me the opportunity to play. It’s hard … it’s hard. It was like I grew up here.”

“That’s the business,” he said. “It surprised me a little bit, but there is nothing I could do. I knew this was going to be possible. Today when I got here, I didn’t even know it was happening.”

While Cabrera got emotional, it was another day at the park for his 7-year-old son, Meyer. Wearing an Indians jersey, he played catch on the field while his father’s former teammates took batting practice before their game against Seattle.

MORE TO COME?

Chase Headley, Jake Peavy, Huston Street, Joakim Soria and others were dealt well before the trade deadline. And if history is any guide, there will be at least a couple more trades before September. Philadelphia left-hander Cole Hamels drew plenty of interest leading up to Thursday, and could be in play.