Chosen Solution
I was watching YouTube videos before I went to shut my Mac down and I had quit all my apps, when I shut it down the screensaver was there and then all of a sudden a photo of what I was watching on YouTube came up and it showed the loading signal and shut down. I see the screensaver sometimes during shut down but this has never happened before. I’m not sure how else to explain, other than I was shutting it down and an Apple Logo and watermark from the YouTube video I was watching came up. (The Apple Logo was part of the video) It’s hard to explain, I got it recently so I’m pretty sure I still have warranty. Should I be worried? Because I sure am! I saved my money for a YEAR just to buy this computer!
I don’t think you have a problem. I believe Utube in its loading process halted the shutdown and was running in the background. To be sure do a “force quit” Command, Option, ESC and it will bring up a box of all the programs still running.
I suggest holding to power button to force shutdown, if the problem continues try booting in safe mode if that won’t work you can try to bring it to a apple store or reinstall macOS high Sierra