jQuery(document).ready(function($) {
// Target the specific parent dropdown menu
var parentMenu = $('#menu-item-6918 > div > ul');
var dropdownHeight = '450px'; // Define the desired height
// Apply scrollable styling to parent
parentMenu.css({
'max-height': dropdownHeight,
'overflow-y': 'auto',
'overflow-x': 'hidden',
'display': 'block'
});
// Apply the same scrollable styling to all child dropdowns
parentMenu.find('ul.sub-menu').css({
'max-height': dropdownHeight,
'overflow-y': 'auto',
'overflow-x': 'hidden',
'display': 'block'
});
// Optional: Add styling for the scrollbar (only works in some browsers)
$('