page.click() not found – Puppeteer in Docker

I am working on automating a website. My script basically enters a website where you must log in to continue the process.

The problem is that apparently the “click” function does not work when it runs on docker (local and headless works), although it finds the selectors, when it is “clicked” it ends up exiting due to timeout. I have read that sometimes this causes problems. Any ideas??

I share some of the code and the versions of docker and puppeteer that I am using.

const selector = "#loginRegisterTabs > ul > li:nth-child(1)";
await page.waitForSelector(selector, { timeout: 30000 });
await page.focus(selector); // Opt
await page.click(selector);

FROM ghcr.io/puppeteer/puppeteer:22.14.0
> "puppeteer": "^22.14.0"

Thanks! Regards

I have already tried waiting for the selector, clicking directly, even focusing on it.
Locally works include headless mode