Salaams Brothers and Sistas!

Basically, I am planning to wear the Shemagh (Kafiya), but I feel that I need to know what are the origins of the scarves? What do they symoblise, cos nowadays everyone is wearing them - just as a fashion accessory and people are losing the true meaning. I would be grateful if someone could tell me what they represent and if i were to wear dem how can I justify it? Plus I think different colours mean different things, like they have red and white, black and white, white, blueish / purpulish, olive and black and green.
Jazaq allah khair!