Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>JS Bin</title>
</head>
  <style>
    #target {
      background: green;
      height: 100px;
    }
    #target:hover {
      background: red;
    }
    #child {
      margin-top: 150px;
      background: black;
      width: 50px;
      height: 50px;
      float: left;
    }
  </style>
<body>
Hover the mouse over black (child of green) and green and both of them activate hover state of green.
  <div id="target"> <div id="child"> </div></div>
</body>
</html>
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x