Build a House Painting - Build a House Painting

Tell us what’s happening:

  1. Your #door should be placed at the bottom of the house.
    I experimented with different top values and no value satisfies the door being placed at the bottom. 195 seems perfect but it won’t work.

Your code so far

<!-- file: index.html -->
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>House Painting</title>
    <link rel="stylesheet" href="styles.css">
</head>
<body>
  <div id="sky"></div>
  <div id="house">
    <div id="chimney"></div>
    <div id="roof"></div>
    <div id="window-1"></div>
    <div id="window-2"></div>
    <div id="door"></div>
  </div>
  <div id="ground"></div>
</body>
</html>
/* file: styles.css */
body {
  background-color: lightblue;
}

#house {
  position: relative;
  top: 100px;
  left: 100px;
  width: 500px;
  height: 400px;
  background-color: pink;
  border: 5px solid brown;
}

#chimney {
  position: absolute;
  top: -50px;
  left: 150px;
  z-index: -1;
  width: 100px;
  height: 50px;
  border: 1px solid black;
  background-color: #d3d3d3;
}

#roof {
  position: absolute;
  width: 100%;
  height: 100px;
  border: 1px solid black;
  background-color: brown;
}

#window-1 {
  position: absolute;
  top: 200px;
  left: 50px;
  width: 75px;
  height: 75px;
  border: 1px solid black;
  background-color: #CCA01D;
}

#window-2 {
  position: absolute;
  top: 200px;
  left: 350px;
  width: 75px;
  height: 75px;
  border: 1px solid black;
  background-color: #CCA01D;
}

#door {
  position: absolute;
  top: 195px;
  left: 200px;
  z-index: 1;
  width: 100px;
  height: 200px;
  border: 5px solid brown;
  background-color: #f3f5;
}

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/146.0.0.0 Safari/537.36

Challenge Information:

Build a House Painting - Build a House Painting

Hi @Testver12,

What could you set the bottom property too, instead, to make sure the bottom of the door is at the bottom of the house?

Happy coding!