The best analogy I can give is the apples and oranges story. Both are a type of fruit but each is different and useful for its own reason.
Surfactant is found in shampoo and conditioner. However, the type usually found in shampoo is intended to clean and the one found in conditioner is intended to deposit. The key difference between the two types is
1. Size or Length
2. Charge (Negative in shampoo and Positive in conditioner)
So how can the same surfactant behave differently?
Well, let us be clear, the surfactant is not the same! Remember apples and oranges. Our apple is the shampoo surfactant like SLS, SLES, ALS and their purpose is to remove oil and wash hair. Our oranges are things like behentrimonium chloride, behentrimonium methosulfate and stearamidopropropyl which are designed to deposit onto hair, smooth the cuticle and create softness (see the pic!)
So are surfactants bad? In my opinion, no, they are vital to cleaning and maintaining hair!