I feel your pain! My DSD came to live with us when she was 13 - because she couldn't stay with her mum anymore, and certainly not because she wanted to. DH went to drop her off at her mums, he was gone an hour, then came back with her. She had a bin liner in her hand with clothes in. She stood in the hall, glared at me and said 'apparently, I live here now'. It was like my worst nightmare come true! (and hers as well)
She has been through a LOT, and I know none of it is her fault. I did find though, that when I needed someone to vent to, my friends just didn't understand. Their attitude was either that I should sent her back to her mum (even though her mum shouldn't be allowed to look after plants, let alone children), or that it is all DH's problem and I should just leave him to it.
It's been sort of like having a house guest that stayed for a few years. It's a difficult situation. People tell you to disengage, which is hard to do from someone who lives with you unless you have a massive house. But at the same time, you can't pretend you're not responsible for this child who, after all, is an innocent child. I found that it was easier to actually do the right thing than it was to want to do the right thing.
I have found different ways of coping over the years, but the one mantra that I still say to myself is this: This is MY house and I am in charge. I do often have to take a step back and let her parents make decisions for her, but if DH expects her to live here, then he has to accept that I have a role in her life. I've been telling myself that for years, but things got easier once I started believing it!
I hope things settle down for you soon