CSS doesn’t use HTML tags. So if you ever find yourself putting HTML tags in your CSS then stop immediately and remove them
Let’s look at the example again:
element {
property: value;
}
element is the element in the HTML you want to style. But again, just because it uses HTML tags in the HTML doesn’t mean you want to use HTML tags in the CSS. Instead, you just use the name of the element.
property is the name of the property you want to change for the element.
value is the actual value you want to give the property.
So you just need to replace these three words in the example CSS with what the instructions are asking you to make them.
“Center your h1 element by setting its text-align property to the value center.”
Do you understand from these instructions what is the element, property, and value?
Well, I can’t just show you how to do that. I’ll try to explain again. Look at the example CSS:
element {
property: value;
}
You need to replace each of the words in this example (element, property, and value) with the words (or values) the instructions are asking you to use. Leave everything else as is (such as the curly braces, colon, and semi-colon). All of it goes between the opening <style> tag and closing </style> tag.
These are the instructions:
“Center your h1 element by setting its text-align property to the value center.”
Do you understand from these instructions what you would use to replace element, property and value?