In terms of games I'm somewhat familiar with, I know the story doesn't really care if Sophia dies or not.
you DO need her for the true ending in that she must be alive at the end of the chapter you recruit her to access the gaiden chapter (and you need to get all gaiden chapters for true ending). But there are like 5 more characters who have that same requirement to access gaiden chapters so it's not like the game stresses her importance over those characters in any way. as a unit she might actually be the worst in the game though. i actually can't believe how bad she is when i think back on it lol.