I don't know what Shanahan was thinking, but it was sure wrong minded.
I heard that well, his D was gassed. OK. But they had about a 10 minute break at the end of regulation before the game resumed. That's a lot of rest time for a professional football player. And besides, the strategy still isn't right. KC wouldn't have gone on 4th downs on their opening drive because of the problem of giving the Niners good field position if they failed. That would have been advantage Niners.
So, there is simply no good rationale for what Shanny did. Interesting that his response was to fire his DC. What a terrible look, regardless of any spin around it.