CSS styling unit 3 (jumbotron h1 styling)


#1

I have been doing everything correctly until I got to this part. This is the task :

  1. In index.html inside the head element add this link element: <link href="http://s3.amazonaws.com/codecademy-content/courses/ltp/css/shift.css" rel="stylesheet">. This is a CSS file that loads up the custom font for use in the page.

0.2 In main.css, inside the .jumbotron h1 selector, set font-family to 'Shift', sans-serif

here is my html:

<!DOCTYPE html>
<html>
  <head>
    <link href="http://s3.amazonaws.com/codecademy-content/courses/ltp/css/shift.css" rel="stylesheet">
  </head>
  
  <body>
    <div class="nav">
      <div class="container">
        <ul>
          <li><a href="#">Airbnb logo</a></li>
          <li><a href="#">Browse</a></li>
        </ul>
        <ul>
          <li><a href="#">Sign Up</a></li>
          <li><a href="#">Log In</a></li>
          <li><a href="#">Help</a></li>
        </ul>
      </div>
    </div>

    <div class="jumbotron">
      <div class="container">
        <h1>Find a place to stay.</h1>
        <p>Rent from people in over 34,000 cities and 192 countries.</p>
      </div>
    </div> 

    <div class="learn-more">
	  <div>
		<div>
	  	  <div>
			<h3>Travel</h3>
			<p>From apartments and rooms to treehouses and boats: stay in unique spaces in 192 countries.</p>
			<p><a href="#">See how to travel on Airbnb</a></p>
		  </div>
		  <div>
			<h3>Host</h3>
			<p>Renting out your unused space could pay your bills or fund your next vacation.</p>
			<p><a href="#">Learn more about hosting</a></p>
		  </div>
		  <div>
			<h3>Trust and Safety</h3>
			<p>From Verified ID to our worldwide customer support team, we've got your back.</p>
			<p><a href="#">Learn about trust at Airbnb</a></p>
		  </div>
	    </div>
	  </div>
	</div>
  </body>
</html>

and here is my css:

.nav a { 
    color: #5a5a5a;
    font-size: 11px;
    font-weight: bold;
    padding-top: 14px;
    padding-bottom: 14px;
    padding-left: 10px;
    padding-right: 10px;
    text-transform: uppercase;
}
.jumbotron {
    height: 500px;
    background-image: url('https://goo.gl/04j7Nn');
}
.jumbotron h1 {
    color: #fff;
    font-family: 'Shift', sans-serif;
    font-size: 48px;
    font-weight: bold;
    }
.jumbotron p {
    color: #fff;
    font-size: 20px;
}

I think I have done everything right. However, when I 'save & submit' I receive this error message "
Oops, try again. Set the font-family of the h1 element inside <div class="jumbotron">..</div> to 'Shift', sans-serif"

Can someone please help me with this?


#2

Did you notice that your nav list items are no longer showing as uppercase?

That's is because you deleted the <link to your main.css file. Without that link your index.html file doesn't know that your main.css file exists.


#3

I am having the same issue. Can you help?
Here is my code:

<!DOCTYPE html>
<html>
  <head>
    <link href="main.css" rel="stylesheet">
    <link href="http://s3.amazonaws.com/codecademy-content/courses/ltp/css/shift.css" rel="stylesheet">
  </head>
  
  <body>
    <div class="nav">
      <div class="container">
        <ul>
          <li><a href="#">Airbnb logo</a></li>
          <li><a href="#">Browse</a></li>
        </ul>
        <ul>
          <li><a href="#">Sign Up</a></li>
          <li><a href="#">Log In</a></li>
          <li><a href="#">Help</a></li>
        </ul>
      </div>
    </div>

    <div class="jumbotron">
      <div class="container">
        <h1>Find a place to stay.</h1>
        <p>Rent from people in over 34,000 cities and 192 countries.</p>
      </div>
    </div> 

    <div class="learn-more">
	  <div>
		<div>
	  	  <div>
			<h3>Travel</h3>
			<p>From apartments and rooms to treehouses and boats: stay in unique spaces in 192 countries.</p>
			<p><a href="#">See how to travel on Airbnb</a></p>
		  </div>
		  <div>
			<h3>Host</h3>
			<p>Renting out your unused space could pay your bills or fund your next vacation.</p>
			<p><a href="#">Learn more about hosting</a></p>
		  </div>
		  <div>
			<h3>Trust and Safety</h3>
			<p>From Verified ID to our worldwide customer support team, we've got your back.</p>
			<p><a href="#">Learn about trust at Airbnb</a></p>
		  </div>
	    </div>
	  </div>
	</div>
  </body>
</html>

main.css code.

nav a{
    color: #5a5a5a;
    font-size: 11px;
    font-weight: bold;
    padding-top: 14px; 
    padding-bottom: 14px;
    padding-left: 10px; 
    padding-right: 10px; 
    text-transform: uppercase; 
}

.jumbotron {
    height:500px; 
    background-image: url('https://goo.gl/04j7Nn')
}
.jumbtron h1{
    color:#fff;
    font-family:'Shift', sans-serif;
    font-size:48px; 
    font-weight:bold;
}    
.jumbotron p{
    color:#fff;
    font-size:20px;
}

I continue to receive an error message that I have not changed the font-family correctly.
Thanks!


#4

You have a typing mistake there.


#5

You need to make the nav element a class by doing this .nav a. It require the preceding period to identify it as a "class".
Nothing else will work correctly until this is corrected.