Struggling to design a responsive layout and encountering issues when floating a div to the left. I am facing difficulties with:
HTML
<body>
<div class="wrapper">
<h1>Site Title</h1>
<nav>
<a href="#">Home</a>
<a href="#">Home</a>
<a href="#">Home</a>
<a href="#">Home</a>
<a href="#">Home</a>
<a href="#">Home</a>
</nav>
<h2>hello world</h2>
</div>
</body>
CSS
.wrapper {
margin: 10px auto;
width: 90%;
max-width: 980px;
background-color: yellow;
overflow: auto;
}
nav {
background-color: #222;
padding: 0;
margin: 10px 0;
}
nav a { color: #F9F9F9; display: block; float:left; padding: 10px; }
nav a:visited { color: #f9f9f9; }
nav a:hover { text-decoration: none; background: #27B3CF; }
nav a:active { position: relative; top: 0; }
Functioning correctly but aiming to float it left http://jsfiddle.net/rktjam2k/4/
Issues arise when nav a is floated left: http://jsfiddle.net/rktjam2k/3/