Product Landing Page - Build a Product Landing Page

Tell us what’s happening:
Hi! I am stuck here due to nav-bar error - " Your #nav-bar should always be at the top of the viewport.". I have done position:fixed and its even working well in preview. pls help…

Your code so far

<!-- file: index.html -->
<!DOCTYPE html>
<html lan="en">
<meta charset="UTF-8">
<link href="./styles.css" rel="stylesheet">
  <form id="form" action="" method="get">
    <label><h3>Handcrafted, home-made masterpieces</h3> </label>
    <input id="email" name="email" type="email" placeholder="Enter your email address" required>
    <p><input id="submit" type="submit" value="Get Started"></p>
  <header id="header">
    <img id="header-img" src=""/>
<nav id="nav-bar">
  <a class="nav-link" href="#pm">Premium Materials</a> 
    <a class="nav-link" href="#fs">Fast Shipping</a> 
    <a class="nav-link" href="#qa">Quality Assurance</a>
<section id="pm">
  <h2>Premium Materials</h2>
Our trombones use the shiniest brass which is sourced locally. This will increase the longevity of your purchase.
<section id="fs">
<h2>Fast Shipping</h2>
We make sure you recieve your trombone as soon as we have finished making it. We also provide free returns if you are not satisfied.
<section id="qa"><h2>Quality Assurance</h2>
For every purchase you make, we will ensure there are no damages or faults and we will check and test the pitch of your instrument.

<video id="video" width="320" height="240" controls> 
  <source src="!APywk7qOuBm-JJI" type="video/mp4">

/* file: styles.css */
  position: fixed;
  flex-direction: row;

 @media only screen and (max-width: 2000px) {
  body {
    background-color: lightblue;

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/ Safari/537.36 OPR/

Challenge: Product Landing Page - Build a Product Landing Page

Link to the challenge:

1 Like

Your #nav-bar should always be at the top of the viewport.

  • so why do you have form element showing before it? and various labels and inputs.

everyhting that is not navbar, except header element, should come after navbar


Try this: change all your form code to the main and in your styles.css change #navbar by header


Thanks CrlosZgz! I put header element before ‘form’ element and changed CSS to header #nav-bar and it worked ;). finally finished the project.

Thanks! it worked putting header element before ‘form’ element and changing CSS to header #nav-bar. :slight_smile:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.