I'll second Goop. Put it in when the tail is dry. Let it soak. Then rinse.
Then shampoo with Dawn dish soap (original formula).
Then a detangler...