It is ok to store the laptop in a vertical / horizontal or any position when not in use.
Just make sure that there are no attachments sticking out on the side where is it resting. i.e. if you have a USB mouse receiver, USB Bluetooth receiver or an SD card that sticks out of the reader, take them out OR just make the laptop rest on the other edge. (Else the USB port may get damaged)
And . . . It is also ok to actually use the laptop on any side while it is working. As long as the air vents are not getting blocked and there is nothing sticking out.
Back in college days, I would watch movies before falling asleep, and i would keep the laptop on its side (the side without the vents) and it worked just fine. (Just had to be careful to not accidentally push it over.)
Currently I use my laptop in a vertical clam-shell (closed) mode, connected to an external monitor, keyboard and mouse. It is in DIY plastic mesh ‘holder’, which holds it vertically and provides good ventilation. It works just fine.
Rationale . . .
In the older laptops, the only moving parts are the hard-disk and the cooling fan. In the new laptops with SSD, the only moving part is the cooling fan.
As long as you are not subjecting them to sudden shocks (like dropping the laptop), the HDDs can be mounted & operated in any orientation. (The slim desktops would have HDDs mounted in a vertical direction.)
The fans (and the HDDs platters) are bearing mounted and are not affected by the orientation while normal operation, during their normal lifetime.
Therefore, you can store and even use your laptop in any orientation. Repeating the only “conditions” :
(1) Make sure that the air vents (intake and exhaust) are not blocked.
(2) Remove any attachments from the side where the laptop is resting.
(3) Ensure that the laptop is stable – if using it sideways – so that it doesn’t tip over.
(4) Do not subject the laptop to sudden shocks, especially if it has a HDD.