When Windows 11 shutdown /h in CMD hibernates, but in batch file it shuts down. Why?

I am trying to use this simple script to hibernate after a delay, but I ran into this strange behavior. When I run the command in CMD, it works fine and the shutdown /h part hibernates the system. However when i make a batch file with the same code, after the delay the PC shuts down. It is not connected to the timer part of code, I tried just shutdown /h and it behaves this way. What am I missing?

  • Edition: Windows 11 Pro
  • Version: 25H2
  • OS build: 26200.9974
  • Experience: Windows Feature Experience Pack 1000.26100.385.0