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 Write CSS Media Queries

fareez idzuan
fareez idzuan
1,840 Points

Hi, do you know what is the mistaken occurred in the question about create a breakpoint here?

@media screen and (min-width: 480px) { h1 { font-size: 2.5em; } }

Is this wrong? I am really confused.

3 Answers

I suggest you try submitting your code again. It is correct and a copy/paste worked for me.

Have you placed this right at the end of the CSS file? I think it needs to be the last rule but certainly not at the top.

Steve.

fareez idzuan
fareez idzuan
1,840 Points

Thanks a lot. You're right . Now I just figured out what the problem is.

Caitlin Otto
Caitlin Otto
1,520 Points

I found this question because I was having the same issue. Why is it important for the breakpoint to be at the bottom of the page?

I think this is to do with how the rules cascade. If you set the MQ first, but later rules override the MQ, then the desired layout will be lost. Putting the MQ last, then the MQ overrules the main CSS rules, giving you the output you want.

Emmanuel Plouvier
Emmanuel Plouvier
11,919 Points

Hi,

can you post the whole css file ?

I don't see any error in your code. :)

fareez idzuan
fareez idzuan
1,840 Points

Hi. I just figured out how to solve the problem.

Thanks a lot for your response.