Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

CSS CSS Basics (2014) Enhancing the Design With CSS Adjusting the Layout with Media Queries

Adam Byallas
Adam Byallas
1,198 Points

Hi, I am overriding previously written code. Can anyone help with tips on where i may be going wrong?

.title - is overriding my previous border code. My border has been completely removed.

. .resorts, .tips - is overriding previous "float" code written. Its now back to single file on the website.

My code attached -

/* Media Queries -------------------- */

@media (max-width: 1024px) { .primary-content, .seconary-content { width: 90%; } }

@media (max-width: 768px) { .primary-content, .secondary-content { width: 100%; padding: 20px; border: none; } .wildlife { padding: 10% 12%; margin: 50px 0 20px; } } .main-header { max-height: 380px; padding: 50px 25px 0; }

.title { font-size: 1.3rem; border: none; } h1 { font-size: 5rem; line-height: 1.1; } .arrow { display: none; } .intro { font-size: 1rem; }

.resorts, .tips { float: none; width: 100%; } }

Thanks for your help

Ad

Adam Byallas
Adam Byallas
1,198 Points

Not posted before so was unaware the code would come out like this....

PLease explain if there is a better way to view asnd help.

Thanks

A

good day

i have cleaned up the code so that I could follow (since i am new to this as well). There is a spelling error in the first .secondary-content. There was at least a couple brackets that i thought were not needed. i re-watched the video, and i think it is working correctly for me. let me know. and thanks for sharing, since i am new too. (edited) ya i see it changed my pasted code as well :)

@media (max-width: 1024px) { .primary-content, .secondary-content { width: 90%; } }

@media (max-width: 768px) { .primary-content, .secondary-content { width: 100%; padding: 20px; border: none; }

.wildlife { padding: 10% 12%; margin: 50px 0 20px; } }

.main-header { max-height: 380px; padding: 50px 25px 0; }

.title { font-size: 1.3rem; border: none; }

h1 { font-size: 5rem; line-height: 1.1; }

.arrow {display: none; }

.intro { font-size: 1rem; }

.resorts, .tips { float: none; width: 100%; }

1 Answer

Adam Byallas
Adam Byallas
1,198 Points

HI Christopher,

Thanks for the help. Im afraid the issue was still present in the code. I have added in the final ending curly brace ( } ) in the code.

Thanks for your help

Adam