Why this is tricky

These are native browser dialogs, not DOM elements — they live outside the page, so a locator strategy can't find them; your tool needs its native dialog-handling API instead (accept/dismiss/enter text, then read the value back).

No dialog triggered yet.

Initial state.