How to do a ' border onhover ' ?

The selector you have for the hover specifies that the p element is immediately adjacent to your div element. In your code now, you have the p element as a child of the div. This means you can do this instead:

div:hover p.borderShowTop {
  display: block;
}

Also, you don’t need to use a separate script element for each function you are adding. You can combine all of your JavaScript code inside just a single script element :slight_smile: