Oops, try again. Did you set your <div>'s margin-top to -20px?


#1
  • { border: 1px dashed black; }
    div {
    height: 50px;
    width: 100px;
    border: 4px solid #FF0000;
    border-radius: 5px;
    background-color: #308014;
    margin-top: -20px;
    margin-right: 50px;
    margin-bottom: 10px;
    margin-left: 5px;
    padding: 40px;
    }

how to resovle this?


#2

Is this selector rule expected in the lesson?


#3

margin-top: 20px;

but you write -20px;


#4

Sorry,
I cant understand - what is wrong here? (Oops, try again. Did you set your

's margin-top to -20px?):
  • {
    border: 1px dashed black;
    }

div {
height: 50px;
width: 100px;
border: 4px solid #FF0000;
border-radius: 5px;
background-color: #308014;
margin-right:50px;
margin-bottom: 10px;
margin-left: 5px;
padding: 40px
margin-top: -20px;
}


#5

Missing semi-colon after property declaration. The CSS parser will skip over the remaining properties in the declaration block (for this selector) so the font-size rule is not seen.