Is there anyway this is legal?
Of course it's legal. You should have turned off at the Detour sign. That's what Detour means.

What is the best route to take to fight this?
There is no "best" way. All you can do is plead not guilty and hope the judge isn't Boss Hogg or Sheriff Roscoe (or Buford Justice - to use another unfortunate stereotype).