disable page scrolling with just one CSS rule

The Code

<style>

body:has(.w-nav-button.w--open) {
	overflow: hidden
}

</style>

You can paste it into:

  1. Your "Global Styles" component.
  2. The "Inside <head> tag" section, within Page Settings — it will apply to the current page only.
  3. The "Head Code" section of the "Custom Code" tab of "Site Settings" — it will apply to the whole site.