Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML How to Make a Website Responsive Web Design and Testing Adding Breakpoints for Devices

Frantyk Andrii
Frantyk Andrii
35,423 Points

I have a problem with that piece of code:

@media screen and (min-width: 660px) {

**************************************
HEADER  
**************************************

  nav {
    background: none;
    float: right;
    font-size: 1.125em;
    margin-right: 5%;
    text-align: right;
    width: 45%;
  }

  #logo {
    float: left;
    margin-left: 5%;
    text-align: left;
    width: 45%;    
  }

  h1 {
    font-size: 2.5em;
  }

  h2 {
    font-size: 0.825em;
    margin-bottom: 20px;
  }

  header {
    border-bottom: 5px solid #599a68;
    margin-bottom: 60px;
  }

* **MOD NOTE: Edited markdown for code readability. *

Frantyk Andrii
Frantyk Andrii
35,423 Points

After I've added this code to my css file, a design of my site don't look as in the video lesson... I've tryed open it sites in different browsers, but it didn't work. Can you help me?

3 Answers

Jason Anders
MOD
Jason Anders
Treehouse Moderator 145,860 Points

HI Frantyk,

Everything looks okay except your "HEADER" comment.

Comments in CSS need to start with /* and end with */. You have just an asterisk (*).

See if that works. :)

Jason Anders
MOD
Jason Anders
Treehouse Moderator 145,860 Points

I don't know if it was just from when you copy/pasted your code, but you are missing a final closing curly brace to close out the media query. You final lines should be:

  header {
    border-bottom: 5px solid #599a68;
    margin-bottom: 60px;
  }
}         /* Added @media closing curly brace */
Frantyk Andrii
Frantyk Andrii
35,423 Points

It still doesn't work) thank you for reply and for your help)

Frantyk Andrii
Frantyk Andrii
35,423 Points

It just my fault on copy, but even I fixed it it doesn't work yet(