I am having a problem trying to find any specific details on how to properly write css rules in a stylesheet where the class or id is nested within many other ids and styles. ie)
.mainbody #container #header #toprightsearch .searchbox {}
So here we have a searchbox class within a toprightsearch id, in a header id, in a container id, in a mainbody class.
But it appears to work properly if I omit some of the ID's.
What is the 'correct' way of listing these?
If I include all of the parents does it make it more specific?
Can it error on different browsers if I don't include all?
And any additional information on this topic would be appreciated.
Thanks