The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Help with mobile-first CSS Re: Help with mobile-first CSS


@srig99 Thanks for the link but I’ve got all the media queries set up already.

Let me give you an example of what problems I’m facing:

The main menu items in the mobile version are 100% wide. Although on the larger resolutions the same menu items should have no width defined at all (just padding), so would the following be correct?

@media only screen and (min-width: 768px){
width: auto;

That’s basically where my question comes down to. What’s the best approach on styling the different screen sizes (while the CSS I have now is applied to everything).

Put another way, how would you modify an existing website’s CSS which is not responsive to mobile-first?