/* Hide warnings fields if usable password is selected */
form:has(#id_usable_password input[value="true"]:checked) .messagelist {
    display: none;
}

/* Hide password fields if unusable password is selected */
form:has(#id_usable_password input[value="false"]:checked) .field-password1,
form:has(#id_usable_password input[value="false"]:checked) .field-password2 {
    display: none;
}

/* Select appropriate submit button */
form:has(#id_usable_password input[value="true"]:checked)
input[type="submit"].unset-password {
    display: none;
}

form:has(#id_usable_password input[value="false"]:checked)
    input[type="submit"].set-password {
    display: none;
}
