I dont know how to center my h1 element by setting text-align value too center. please help

Tell us what’s happening:
Describe your issue in detail here.

  **Your code so far**
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8" />
  <title>Cafe Menu</title>
  <style> text-align="center"
  </style>
</head>
<body>
  <header>
    <h1>CAMPER CAFE</h1>
    <p>Est. 2020</p>
  </header>
  <main>
    <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/102.0.0.0 Safari/537.36

Challenge: Step 12

Link to the challenge:

In your style element, select the h1 element first, then type in your curly brackets, leave a space then input the text-align property with the property value center in your curly brackets. You don’t use the equal to(=) or quotes(") signs when assigning a value to the text-align property. You use a colon ‘:’ after the property(text-align) and a semi-colon ‘;’ after the property value(center) to indicate that the styling is over.

1 Like