# Menu Dropdown Disappearing on Hover - CSS Issue

**URL:** <https://community.wpbeaverbuilder.com/t/menu-dropdown-disappearing-on-hover-css-issue/19926>\
**Category:** Beaver Builder\
**Tags:** css\
**Created:** [September 22, 2025, 2:16pm UTC](https://community.wpbeaverbuilder.com/t/menu-dropdown-disappearing-on-hover-css-issue/19926 "2025-09-22T14:16:41Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Haddadammar](https://community.wpbeaverbuilder.com/letter_avatar_proxy/v4/letter/h/e95f7d/32.png) [@Haddadammar](https://community.wpbeaverbuilder.com/u/Haddadammar)\
**Post date:** [September 22, 2025, 2:16pm UTC](https://community.wpbeaverbuilder.com/t/menu-dropdown-disappearing-on-hover-css-issue/19926/1 "2025-09-22T14:16:41Z")

</div>

Hello,

I’m building a header menu with Beaver Builder and am having trouble with a sub-menu dropdown.

I’m trying to add a small vertical gap between the main menu item and its dropdown box using CSS. When I add `margin-top` to the sub-menu, the dropdown disappears as soon as I move my mouse off the main menu item because of the gap.

I have tried a few different CSS solutions, including `margin-top`, `padding-bottom`, and `transform: translateY()`, but none have fixed the issue. It seems like a hover state conflict is causing the problem.

Could you please advise on the correct CSS or method to create a small gap without causing the sub-menu to disappear?

Thanks

 ![Screenshot 2025-09-22 at 10.10.46 AM](https://community.wpbeaverbuilder.com/uploads/default/original/2X/6/6e682466fe22adb13928fb24ca53aa7d6bc6f2d1.png)
