I’ve just checked and can confirm that the above code still works for in the current version of the theme. Please see screenshot. Please check that the CSS has been added in a way that is update-proof. I would recommend adding this code by going to ‘Appearance’ > ‘Customize’ > ‘Additional CSS’. Just as you see in the screenshot.
Also, I’ve just tested both the “Show gallery categories menu” and “Show portfolio categories menu” in the Theme Options, and they also work. Please try re-saving the Theme Options if you are experiencing these checkboxes not working.
As for hiding the parent category, basically you can hide any category from the categories menu by specifying its id in the following manner:
Please replace the 8 with the id of the category you would like to hide. To find the ID of a given category, please go to its edit screen in the admin and see the ID in the URL. Here is an example: screenshot.