My sense is he's going to get a really long term contract that goes well beyond the current CBA but will be rich, almost as rich as Mahomes is. Going past the CBA helps the Ravens because when the new CBA is signed QB salaries will sky rocket into the stratosphere where Mahomes and Jackson contracts will be heralded as cheap. Just my thoughts on this.
Generally speaking... its kind of irrelevant.
A ten year contract would really be like a five year contract, because no NFL team is going to guarantee a player 10 years. Mahomes deal has over $300M of non-guaranteed money in it. It can simply be erased at largely any point the Chiefs choose.
Generally speaking, the reason these types of contracts are so rare is because they're bad for the player, not for the team. Teams would give out 20 year contracts all day long to stud players, since they don't have to guarantee anywhere close to all of it. A 20 year contract could easily become a 5 year contract with no additional cash outlays for the team or major cap impact.
Players won't do it because of the very reason you suggested. They're voluntarily passing on free agency, and accepting market value today that may not be true market value 5-10 years from now. Players have very little incentive to take these deals.
As for why Mahomes did his deal, well realistically, it's because it was so wildly above what anybody else makes that he's not likely to really ever feel "cheated" by it. Starting in 2022, he'll effectively make at least $30M in cash (in some cases $40-60M) every year for the next decade. There really isn't a "bump" in revenue or salary cap that will equate to that being a "value" anytime soon. Even on a $300M salary cap (which it'll be many years before we get to that point, if we do at all), making $40M isn't a "bargain". You're still talking about taking up like 12-15% of your teams overall cap space.