def open_application(driver, button_name):
    """Search the job page for the Apply Now button and click it if it exists.

    Positional arguments:
    driver -- the Selenium webdriver instance
    button_name -- the class name of the button to click

    When the Apply Now button is clicked, the job application dialog
    opens in a new frame.
    """
    driver.implicitly_wait(1)
    driver.find_element_by_class_name(button_name).click()
