First an answer to a question you didn't ask, how to implement a automatic "return from a menu related passage" system.
This article within the Old Forum Archive describes how to use a Story Variable combinded with a known Passage Tag do this, which should remove your need to hide the 'side-bad' in the first place. (1)
Now to answer your actual question...
You can use a known Passage Tag (like the same menu tag used in the article) to mark each of your menu like passages (eg. the Inventory passage), and then use CSS styling that targets that passage tag within your project's Story Stylesheet area to hide the 'side-bar'.
eg. Assuming you have assign the Inventory passage a menu passage tag then the following CSS will hide the 'side-bar' when that passage is shown.
tw-story[tags="menu"] tw-sidebar {
display: none;
}
(1) The code in the linked article was written for the Harlowe 1.x series but it will also work as is within both the 2.x and 3.x series, however both those later series include the (unless:) macro which can be used to make the code placed within the header tagged special passage a little easier to read.
Replace the (if:) macro used in the header tagged passage with the following if you are using either 2.x or 3.x series of Harlowe.
(unless: (passage:)'s tags contains "menu")[(set: $lastPassage to (passage:)'s name)]