Change logo to black on portfolio page when mobile overlay menu is open

To change logo to black on portfolio page when mobile overlay menu is open on Squarespace, you can follow these.
#1. First, you need to find the portfolio page ID. In my example, it is:

  • #collection-659bc1c532800e749cffecc3

#2. Use this code to Custom CSS box

body#collection-659bc1c532800e749cffecc3.header--menu-open header#header img {
    filter: brightness(0) invert(0);
}