Skip to content

06 - CSS header, footer, combinator #6

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: 05-css-element-selectors
Choose a base branch
from
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
34 changes: 34 additions & 0 deletions 02-css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,37 @@ a {
a:hover {
color: #ffb703
}

header {
background-color: #1212B2;
padding: 24px;
text-align: center;
}

main {
/* `main` element does not need any styles */
}

footer {
background-color: #1212B2;
padding: 32px;
}

/*
This is the "descendant combinator".
*/
footer p {
font-size: 16px;
color: white;
margin-bottom: 10px;
text-align: right;
}

/*
We could also be more specific and use the "child combinator":
footer > div > p {
...
}

Read more here: https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Selectors#combinators
*/