I work on a new website, and now I am styling the navbar

I have created a dropdown menu with hover but the menu does not take the list's height as I think so when I hover to the next list in the dropdown menu, the menu disappears.

[![enter image description here](https://i.stack.imgur.com/2Lczc.png)](https://i.stack.imgur.com/2Lczc.png)

[![enter image description here](https://i.stack.imgur.com/ELhzL.png)](https://i.stack.imgur.com/ELhzL.png)

```css
* {
  box-sizing: border-box
}

body,
html {
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  font-family: 'Open Sans', sans-serif;
  font-weight: 400;
}

nav {
  display: grid;
  grid-template-columns: 5rem 1fr;
  justify-items: center;
  align-items: center;
  background-color: #000000;
}

.logo h1 {
  color: #FFF;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 5px;
}

.menu {
  display: block;
  position: relative;
}

.menu li {
  color: #d3d3d3;
  font-weight: 300;
  text-transform: uppercase;
  list-style: none;
  display: inline-block;
}

.menu ul {
  width: 100%;
  height: 0;
  opacity: 0;
  position: absolute;
  left: 0;
  top: 35px;
  background: #00f;
  transition: all .5s ease;
}

.menu li:nth-of-type(4) {
  height: 150%;
}

.menu>li>a {
  display: block;
  padding: 10px 20px;
  text-align: center;
  text-decoration: none;
  color: #d3d3d3;
}

.menu ul li {
  display: block;
}

.menu li:hover ul {
  height: 150%;
  opacity: 1;
  transform: translateY(0);
  overflow: hidden;
}
```

```html
<nav>
  <div class="logo">
    <!-- Logo -->
    <h1>Hexa</h1>
  </div>
  <ul class="menu">
    <!-- Nav Menu -->
    <li class="active">Home</li>
    <li>About</li>
    <li>Projects</li>
    <li>
      <a href="#">Parent Link</a>
      <ul>
        <li><a href="#">Child Link</a></li>
        <li><a href="#">Child Link</a></li>
        <li><a href="#">Child Link</a></li>
      </ul>
    </li>
    <li>Blog</li>
    <li>Contact</li>
  </ul>
</nav>
```

I tried to change the parent list height and the menu inside it but still now working, do you have any idea about this?