Forum:How to force CSS code to be mainpage-only?

Hi there,

I've been fluffing up my main page a bit, adding forced width and two large images on the side. However, I'd like to have these images only display on the mainpage. I'd also like to have the logo not to display when on the mainpage. Is there a way of forcing these bits of code to only apply to the mainpage?

My current monaco.css code;
 * http://jakanddaxter.wikia.com/wiki/User:Light_Daxter/monaco.css

The mainpage;
 * http://jakanddaxter.wikia.com/wiki/Jak_and_Daxter_Wiki:Main_Page

Thanks for helping, if possible! -- Light Daxter -  Talk  11:36, June 6, 2010 (UTC)
 * Notice the BODY element has a class called "mainpage", if you put .mainpage at the beginning of your selector (just like is done with the first three entries in your CSS) it should only apply to the main page. Hope that helps. -- 11:51, June 6, 2010 (UTC)

Works flawlessly. I tried something similar to that (but failed as I wasn't sure how to do it exactly). Now whats the specific code for my logo? Thats the last bit I need. -- Light Daxter -  Talk  12:05, June 6, 2010 (UTC)
 * I guess you are looking for: .mainpage #wiki_logo { display:none; } -- 12:08, June 6, 2010 (UTC)

Flawless victory, again. However, my sidebar won't automatically shove himself up (effectively removing the space created by the hidden logo). I tried fixing this by using the same display: none code at the background strip. And while my sidebar is perfect right now, it also forced the wikia page (and the options above it) to move over the now hidden background strip. Now the top half of my page is. So is there an alternative, or something to this problem? -- Light Daxter -  Talk  12:19, June 6, 2010 (UTC)
 * I would suggest not hiding the background strip and just moving #widget_sidebar up with top:-150px or whatever: #widget_sidebar { top:-150px; } -- 12:34, June 6, 2010 (UTC)