How can I hide notifications for a short period?
There is a Mac app called DND Me which will allow you to turn on DND for a specific amount of time
There is a free trial on the website, otherwise the price is currently listed as €4.99.
(I have used this app in the past and it worked as advertised. I am not otherwise affiliated with it in any way.)
One can use "Turn on Do Not Disturb" setting for needed time (From: to:), but this will come and bite you on following days if you forget to untick it.
I am not heavy notifications user but I simply ⌥ + click on Notifications Center icon to turn on / off notifications. Icon is dimmed when it's off and this visual clue is good enough for me (and I usually start worry when I have nothing to do for hours ;-)). Alternatively one can set own keyboard shortcut in System Preferences -> Keyboard -> Shortcuts -> Mission Control -> Turn Do Not Disturb On/Off