I'm going to suggest a different idea, since what you are doing currently isn't working. I have 13 year old twins and one has a much more difficult personality than the other. She is also very nice to her friends and kind in school. She is a different person at home with her twin. Traditional disciplining didn't work for her in the home, and like yours she felt favoritism was happening. The only thing that has worked in making any headway is a book called Transforming the Difficult Child. It uses the nurtured heart approach.
https://childrenssuccessfoundation.com/about-nurtured-heart-approach/
It is a challenge to use this method, no doubt about it, because you have to ignore the bad behavior and only focus on the good. Basically give no energy at all to the bad, and lots of energy to the good things you see happening, no matter how small. By doing this, the child starts to build up their sense of self worth and good behavior becomes more rewarding than bad behavior. Think about all the personal energy you give to fighting and meanness and misbehavior - we use loud voices and long talks about discipline and IT'S A BIG DEAL. But a good grade or help with the dishes just gets a "nice job". Once you get the energy output under control, then you can set family rules and enforce them dispassionately when they are broken. No raised voices, just the consequence and move on.
It's hard work to remember all the time but it does work if you are consistent.