Put the computer into sleep mode from the lock screen by pressing the computer's power button

I know this may seem like a silly thing, but it really annoys me.

I have KDE configured so that pressing the power button once puts the computer into sleep mode. OK, this works perfectly.

The problem is that this doesn’t work if the system is currently locked with the lock screen. In this case, pressing the power button once, instead of automatically putting it into sleep mode, shows the lock screen with the options that this screen includes, among which is the option to put it into sleep mode.

This is annoying because I already have to pick up the mouse and click on the corresponding button to put it into sleep mode. In GNOME, for example, this is not done this way and it works correctly: being in the lock screen, if you press the sleep button, the computer goes into that state immediately.

I have tried to disable the Session–>Logout Screen–>Show option in KDE, but that doesn’t work either.

Please, does anyone know what I have to do so that in KDE, when the lock screen is on, the computer immediately goes into sleep mode when I press the computer’s power button?

@Chema
You may double check “Power Management” from the start menu.

I’m sorry, I don’t understand what you mean. As you can see in the Power Management configuration options, I have selected that when I press the power button on the computer it goes to sleep, which works perfectly, except that the behavior is different when the screen is locked:

I don’t know. But perhaps try to play with the 2 menu options at “Turn off screen”
Try the first option in each, one at a time and then both.
Maybe this will work.
Sorry. I never put my laptop to sleep!