Chiefs general manager Brett Veach became a big Patrick Mahomes fan by watching him during his college days at Texas Tech.

Veach would send coach Andy Reid weekly video clips on his phone.

“I told him, one day he’s going to be the quarterback of the Kansas City Chiefs,” Veach said.

He once sent Reid about 10 clips of Mahomes.

“He finally said, ‘enough,’” Veach said. “I get the picture.”

The Chiefs eventually got their quarterback by taking Mahomes with the 10th pick of the 2017 draft, after trading up in the first round.

San Francisco, which needed a massive rebuild after John Lynch was named the general manager in 2017, went in a different direction. They traded with the New England Patriots for quarterback Jimmy Garoppolo.

Mahomes and Garoppolo represent the two biggest moves that helped to build the Super Bowl LIV teams. The teams were built mostly by Veach and Lynch, with hat tips to previous general managers John Dorsey and Trent Baalke. The 49ers, representing the NFC, will face the Chiefs, of the AFC, on Sunday at Hard Rock Stadium.

The Chiefs went to the AFC title game in Mahomes’ second season. The Chiefs had to retool their defense over the offseason after firing defensive coordinator Bob Sutton, who went on to join the Falcons as a senior assistant coach.

“Last year, the season didn’t end like we wanted it to,” Veach said. “We knew that we had a highly potent attack on offense. We had to get better on defense.”

Former Rams coach Steve Spagnuolo (2009-11) was hired and switched the Chiefs to a 4-3.

“We had to get the right personnel,” Veach said. “On top of that, I think we had to get the guys who had the right mindset.”

The Chiefs traded pass rusher Dee Ford to the 49ers for a second-round pick. They released defensive end Justin Houston and safety Eric Berry.

“We had a big detailed plan, and we identified guys that we wanted,” Veach said. “We didn’t pull names out of hat or throw darts at a board. We really wanted to get the Honey Badger (Tyrann Mathieu) here because we thought his presence and leadership on the back end would be infectious from top to bottom.”

To replace Houston, the Chiefs needed a stout defensive end.

“Because we were switching to the 4-3,” Veach said, “early on when we started looking at free agents, we knew Frank Clark was up, but we thought there was a good chance that he’d get tagged. But (that was) one of the things we thought we’d allocate some resources to make it happen.”

So, Veach made a trade with Seattle to land Clark and signed him to a long-term deal.

“It really started out with us getting guys with the right temperament and attitude,” Veach said. “When you look at the way the Badger plays and you watch the way Frank Clark plays, those are guys that bring it every play. Those guys have (helped) to transform this defense.”

VIDEO: Chiefs defensive back Tyrann Mathieu speaks about his journey to the Super Bowl. Video by D. Orlando Ledbetter.

Spagnuolo had a hand in helping Veach.

“As we did our research, I talked to a coach that I respect a lot,” Spagnuolo said. “The quote that I remember him saying is that the day Tyrann walked through that door, it changed the culture of that group. That’s all I had to hear.

“I saw that he could play on tape. But you don’t always know what the player is like inside the confines of your building. I’d heard so many good things.”

Those additions along with defensive tackle Chris Jones and linebacker Anthony Hitchens gave the Chiefs a defense.

The 49ers have only six holdovers from the previous regime, including left tackle Joe Staley, who was selected by former general manager Scot McCloughan and coach Mike Nolan.

Staley, defensive linemen Arik Armstead and DeForest Buckner, safeties Jimmie Ward and Jaquiski Tartt and running back Raheem Mostert are the pre-Lynch holdovers.

Mostert, a former undrafted player who has been cut by six teams, is the most intriguing player. He rushed for 220 yards and four touchdowns in the NFC title game against Green Bay.

“We had a number of backs when we got here,” Shanahan said. “We didn’t know much about Raheem. We knew that they had spoke very highly of him as a special-teams players.”

The 49ers didn’t have a lot of film on Mostert as a running back. Shanahan and running backs coach Bobby Turner loved Mostert’s speed.

“Every time, it seemed like when he got the football in (the exhibition) season or when he got in, he always seemed to averaged 6 yards a carry,” Shanahan said. “Once you do that too much, eventually you start feeling stupid as a coach and say maybe we need to get this guy a few more opportunities. We did, and he still has his average up there. He’s been extremely impressive and one of the main reasons why we are here.”

Mostert moved past former Falcons running back Tevin Coleman as the main back during the season.

“Raheem has earned everything that he’s gotten,” Shanahan said. “He’s known for a while now that he’s going to get the bulk of the carries. He’s handled that great.”