I need to chime in here, this is for the OP...
There are plenty of extremely helpful selectors out there to make the job of applying styles easier. However, be sure to thoroughly research the compatibility. I personally like to visit the W3C Schools CSS Reference for example. I clicked on the Pseudo-classes/elements link on that page and they don't even list the :last-child pseudo class. Remember CSS3 has not been officially standardized yet, its still in revision mode. CSS1 and CSS2 are documented on that site, so if you don't find it there it's either CSS3 which is not widely supported or a browser quirk, meaning a specific element for one or a small number of browsers due to limited support. When developing for a general web audience as most sites are, you always think cross browser compatibility with respect to your layout and code base. It doesn't mean you can't use quirk/CSS3 - so long as you know the implications.
On an informal note, alot of folks like to use the JQuery framework with extends Javascript and is very useful for making very complex CSS quite simple and arguably more powerful. Of course, as always, learn W3C CSS first - then advance to neat tools in the toolbox like this, knowing it has limitations also. That goes without saying. There are many other frameworks out there, this is but one example of one of the most popular and stable ones out there. FYI only.
That's the final lesson for you and others following - the rest you need to learn on your own, and learn by doing and making mistakes as we all do to increase our experience and knowledge.
-jim
There are plenty of extremely helpful selectors out there to make the job of applying styles easier. However, be sure to thoroughly research the compatibility. I personally like to visit the W3C Schools CSS Reference for example. I clicked on the Pseudo-classes/elements link on that page and they don't even list the :last-child pseudo class. Remember CSS3 has not been officially standardized yet, its still in revision mode. CSS1 and CSS2 are documented on that site, so if you don't find it there it's either CSS3 which is not widely supported or a browser quirk, meaning a specific element for one or a small number of browsers due to limited support. When developing for a general web audience as most sites are, you always think cross browser compatibility with respect to your layout and code base. It doesn't mean you can't use quirk/CSS3 - so long as you know the implications.
On an informal note, alot of folks like to use the JQuery framework with extends Javascript and is very useful for making very complex CSS quite simple and arguably more powerful. Of course, as always, learn W3C CSS first - then advance to neat tools in the toolbox like this, knowing it has limitations also. That goes without saying. There are many other frameworks out there, this is but one example of one of the most popular and stable ones out there. FYI only.
That's the final lesson for you and others following - the rest you need to learn on your own, and learn by doing and making mistakes as we all do to increase our experience and knowledge.
-jim