I reckon you're probably right here, a challenge to your authority. It's tough with kids because you want them to be as independent as possible and yet they need to learn how to behave as well. Where do you draw the line?
And no, I do not suggest that anyone ever treat a child like this, I'm just trying to explain the psychological side of the way I see your situation.
Although this doesn't sound very nice your whole story reminds me of training a hunting hound. My dog was mostly well behaved until she reached her teen years (15 months) then all of a sudden it seemed she had reverted and started weeing on the floor inside.
Natural response to this was to yell at her and send her outside, but she started refusing that too. So I'd grab her collar and march her outside, telling her to wee outside and knowing that she did understand my words. She even spent a couple of nights sleeping outside in the dog house but it was making no difference to her.
I talked to someone else about it and he explained to me that the dog was a typical teenager and was challenging my authority. He said that every time I had to grab the dog by the collar I had lost the argument. I had to make her obey. When you have a dog that has been specifically bred to chase down and kill wild boar this is pretty important.
He told me to get something thin and whippy like the small end of a fishing rod to hit her with, because it would cause minimum harm and maximum pain. He also told me not to get excited or yell, to make her obey the simple spoken word. I tried his advice that night, she deliberately squatted on the floor right in front of me and looked me in the eye as she was doing it. The old bloke was right, it was a deliberate challenge.
I picked up the thin whippy stick and smacked her across the thigh and quietly said "Outside.". She looked me in the eye and ignored it. I tried again, she flopped down on her belly in front of me and posed as if she was going to sleep. That earned her two much harder stripes on the thigh, along with the quiet command, Outside.
She got up and ran and hid under my bed. I had to hit her three more times and tell her Outside to get her out from under the bed, and she went from there to the kitchen, still refusing to go out. So I stood there with an evil grin on my face and just started repeating the command again and again and hitting her with the stick every time she refused.
It took another 4 or 5 smacks before she finally yelped and ran outside. I never had another issue with her after that. A few times she started to try it on and I'd just ask her "Should I get my stick?" and she'd immediately behave again. For the rest of her life I never had to even raise my voice to her, in fact she always responded better when I just spoke to her quietly.
She amazed a lot of people, if I was over someone else's place and she saw an animal she wanted to chase she'd come and ask permission, I'd ask the property owner and if the answer was no she'd make a big show of sighing and flopping to the floor but she'd stay there next to me and not disobey.