When I went through a messy divorce, many years ago now, perhaps the wisest advice I was given (by a therapist who was helping me) was that I should find a child psychologist for my child (10 at the time). I was a bit shocked, but I did so and it was the smartest thing I did in the midst of a very difficult time. The child psychologist provided my child with a place to express what was happening and later, when things turned ugly in the divorce, the psychologist was a strong advocate for my child, for which I will always be grateful.
Wish it weren’t necessary but you are right.
And, it helps provide a 3rd party to give the judge perspective on the relative merits of what’s best for the child with regard to each parent.
Of course, ask around A LOT before selecting the therapist. Find one sympathetic to your values.