When you said "I think it’s obvious I didn’t do enough to keep the flame burning, but I do think I tried"
I can't argue with this as I don't know you, don't know what you did and didn't do etc.
I do know it takes two though.
Does your cheating wife think she did enough to keep the flame burning with you?
Do you think she did enough to keep the flame burning with you?
Whether she did or didn't doesn't minimized that you didn't do enough to keep the flame burning, but it does take two.
Relationships take work, effort. Things wax and wane throughout the years. There are times when one partner has to do more, carry more of the load. That's life, things happen, it shouldn't be that way for long though. There are ups and downs.
Leaving this example aside now, to me, it's far more important that she shut down, turned inward and shut you out.
It's hard for you to keep the flame going when she's not being honest and truthful with herself, let alone you. If she won't open up, doesn't like herself, won't accept things for what they really are, won't work with you honestly then it doesn't matter.
Under those circumstances, even if you DID do enough to keep the flame burning, it would NOT have mattered. Why? Because in her mind it wasn't enough.
As you and others have mentioned before, she built up an image of you in her mind that wasn't real, wasn't honest and that means even if you did enough, it wouldn't have mattered.
When a person, like your wife, has issues with herself and she rewrites marital history and creates resentment and allows it to fester, build and to grow, even a spouse who is doing the right things won't get through to their spouse. They can't because their spouse isn't dealing with reality.
If you didn't do enough to keep the flame burning, that's something for you to work on going forward, but you need a spouse who is your partner, working with you and not against you for your efforts to work, to bear fruit.
She wasn't working with you on your relationship, but against you and because of that your efforts didn't matter.