Correction needed in div tag

Web page Requirements

The outcome must be displayed in 2 div tags, where the first will have the id named “discount” and is to display the discount % of the product and the second will have the id named “result” and is to display the discounted price of the product. Both the div tag should be center aligned with bolder text. The font of the discounted price must be italic #FF0000 and 40px size and for discount % it is 25px. Have separate styles for div, discount and result.

MY CODE

css part:

div
{
  text-align:center;
  font-weight:bold;
}
#discount
{
  font-size:25px;
}
#result
{
  font-style:italic;
  color:#FF0000;
  font-size:40px;
}

html part:

<div id="discount"></div><br/>
<div id="result"></div>

Error I'm getting

HTML COMPONENT DIV MUST BE USED WITH APPROPRIATE CONSTRAINTS.

How to resolve this error?