The for
criteria means “Has the entity’s state been ‘on’ continuously over the last X minutes”.
If you want your condition to be “Has the entity’s state been ‘on’ at any time in the last X minutes” that will require other approaches.
Is the automation triggered by the same sensor you want the condition based on?
Is there more than one trigger for the automation?