Sometimes, a background process or a hidden application not visible in the Dock becomes unresponsive. In that case, you can use the Activity Monitor to force quit it. Launch the Activity Monitor by pressing Command + Space to open Spotlight search, then type "Activity Monitor" and hit Enter. In the Activity Monitor window, go to View > All Processes. Locate the process you want to quit > select it > click the x button in the top bar. Confirm the action by clicking Force Quit in the pop-up.