Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 56 additions & 1 deletion top-nav-drill/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,59 @@
margin: 0 auto;
}

/*Put your code here*/
.container > header {
background: black;
clear: both;
overflow: auto;
}

.container > header > span {
font-size: 20pt;
float: left;
font-weight: bold;
margin: 0.5em 1em;
}

.container > header > nav ul {
list-style-type: none;
float: right;
margin-right: 1em;
}

.container > header > nav ul li {
display: inline-block;
margin: 0.25em;
}

.container > header a {
color: white;
text-decoration: none;
}

.container > section {
width: 900px;
margin: 0 auto;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How might you change this if you needed to implement a responsive design?


.container > section > h1 {
border-bottom: 1px solid #ccc;
padding-bottom: 0.15em;
}

.container > section > footer {
width: 100%;
border-top: 1px solid #ccc;
padding-top: 0.15em;
}

.container > section > section {
margin-bottom: 1.5em;
}

.container > section > section > h2 {
margin: 0.5em 0;
}

.container > section > section > p {
margin: 0.5em 0;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would recommend removing .container > from these selectors. These styles shouldn't need to be specific to instances of these elements that are in a container.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, don't forget that you can use , to give the same rules to multiple selectors.