Learn Basic CSS by Building a Cafe Menu - Step 11

Tell us what’s happening:

Nested in my style element I have an h1 element with a text-align property. I’ve tried rewriting the code in many ways, but no matter what I do it’s not taking my code. Please help me if you see my error

Your code so far

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8" />
    <title>Cafe Menu</title>

<!-- User Editable Region -->

    <style>
      <h1> {text-align: center;} </h1>
    </style>

<!-- User Editable Region -->

  </head>
  <body>
    <main>
      <h1>CAMPER CAFE</h1>
      <p>Est. 2020</p>
      <section>
        <h2>Coffee</h2>
      </section>
    </main>
  </body>
</html>

Your browser information:

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

Challenge Information:

Learn Basic CSS by Building a Cafe Menu - Step 11

You can add style to an element by specifying it in the style element and setting a property for it like this:

element {
 property: value;
}

Hope this helps.

HERE IS THE ANSWER:

MOD EDIT: SOLUTION REMOVED

you said the exact thing the program says. this wasn’t helpful, but thank you.

The h1 element doesn’t need and opening and a closing here.