This might be your experience, but not mine. I lost a 5e character is the last session I played.
10th level wildfire druid. Battle against a big wizard guy and minions, including a huge giant zombie.
Cast Heat Metal on the zombies armor and hide behind a building at extreme 9oclock of the battlemap from the BBEG who is at 3oclock Spend a couple rounds just hiding behind the building concentrating on my spell.
First, as I wrote "dumb luck" can happen.
But, in this case, you were concentrating on a spell, why weren't you doing other non-concentration spells or other actions to help the other three more quickly dispatch the BBEG? If you had, maybe you wouldn't have died? Playing too passively can lead to death, too.
Of course, I don't know the whole scenario. Maybe you couldn't for some reason?
Other questions would be removing your self from LoS on the BBEG is one thing, but didn't any other other three party members know you were there? Why wouldn't you have told them when you moved to hide? Moving to look around the building, yelling to the others about things to alert them you were still ok might have helped.
BBEG casts some spell with a giant radius that catches me by accident (it was centered on two other visible party members). Failed a CON save (vs DC17) and took 52 damage knocking me out from full health.
The other three party members were out of sight (I was hiding behind a building) and didn't notice I was bleeding out. Failed 3 death saves in a row and died.
Assuming they survived, none of them called out to you to see if you were okay?
Your inaction also made it so the others had no reason to suspect something was wrong when you
continued to do nothing.
None of them also thought to check on you?
Not only did I in no way contribute to being killed by poor choices ... I was playing suboptimally by not casting spells for several rounds to continue to remain completely hidden behind a building.
Maybe. Like I said, I don't know the whole scenario. Being overly aggressive is only one poor choice. Others include:
Being overly passive.
Making tactical errors.
Not using features well.
Lack of team play.
For example, your PC was a druid. Why weren't you wild shaped after you cast your spell? Then you would have had an additional buffer of hit points when you took the damage. A CR 2 beast would have given you an extra 40+ hit points.
So, I'm not saying it wasn't just "dumb luck", but 90% of the time when I see a PC die or hear about it, there is usually a poor choice made that contributed to it. I mean, you admit to playing suboptimally to concentrate on one spell (a good one in most cases of course), but that was
your choice. In this case, that might have been a bad one.