The reality is, there is no perfect way to respond. It is tricky terrain. But here are some thoughts I encourage you to consider before sharing your words of support.
Grief reminds me of the love I felt; that I have something to miss; that my baby was here.
Even though my experience led to my rainbow baby, I can still always connect to the heartbreak that I felt those several months.