
    593 P.2d 692
    Paul O. MITCHELL and Marlene M. Mitchell, husband and wife, Plaintiffs-Appellees, v. AMERICAN SAVINGS AND LOAN ASSOCIATION, a corporation, Defendant-Appellant. Paul O. MITCHELL and Marlene M. Mitchell, husband and wife, Plaintiffs-Appellants, v. AMERICAN SAVINGS AND LOAN ASSOCIATION, a corporation, Defendant-Appellee.
    No. 2 CA-CIV 3022.
    Court of Appeals of Arizona, Division 2.
    March 13, 1979.
    
      Lawrence P. D'Antonio, Tucson, for Paul 0. Mitchell and Marlene M. Mitchell.
    Craig, Greenfield & Irwin by Arthur P. Greenfield and W. Charles Thomson, III, Phoenix, for American Sav. and Loan Ass’n.
   OPINION

RICHMOND, Chief Judge.

These are consolidated appeals arising out of the termination of plaintiff Paul Mitchell’s employment by American Savings and Loan Association and the latter’s commencement of an action to foreclose Mitchell’s mortgage. American Savings appeals from a $7,500 judgment on a jury verdict in favor of Mitchell for breach of a contract for severance pay, contending the agreement is unenforceable as a matter of law either because it is void as against public policy, or for lack or failure of consideration. Mitchell appeals from the dismissal of his claim for wrongful commencement of the foreclosure action during the pendency of the dispute over severance pay. We find no error in either instance.

Mitchell was employed in 1971 as executive vice-president and managing officer of American Savings. His employment was terminable at the will of either party. Sometime early in 1975 he became a member of the American Savings board of directors. On October 3,1975, a special meeting of the board was called for the purpose of terminating his employment. After some discussion, the following resolution was adopted:

RESOLVED that the resignation of Paul 0. Mitchell as Vice President, Managing Officer and Director of this association is hereby accepted, effective immediately; and in consideration of said resignation the association shall pay Paul 0. Mitchell severance pay of six months at the rate of $1,875 per month, less the usual and customary deductions, from October 3, 1975; and that Paul 0. Mitchell shall not be entitled to any benefits from the association as an Officer, Director and Employee after October 3, 1975; and the payment of said severance pay is subject to no adverse conduct on the part of Paul 0. Mitchell, detrimental to the association and the orderly transition of the management of the association; and subject to Paul 0. Mitchell’s cooperation in the transition in the management of the association up to and including October 15,1975.

In accordance with the resolution, Mitchell participated in the management transition through October 15 and received semimonthly payments through December 15. On December 23, however, with $7,500 still payable under the terms of the earlier resolution, the American Savings board as then constituted adopted the following resolution:

RESOLVED, that the Association terminate Paul Mitchell’s severance pay, effective immediately, on the grounds that his adverse conduct has been detrimental to the Association.

American Savings made no further payments to Mitchell and in April of 1976 commenced an action to foreclose a mortgage that he and his wife had executed. The Mitchells in their answer denied that the mortgage note was in default and by counterclaim sought damages for breach of the contract for severance pay and wrongful commencement of the foreclosure action. Prior to trial the foreclosure complaint was dismissed on stipulation and the claim for wrongful foreclosure was dismissed on motion of American Savings. The claim for breach of the severance pay agreement proceeded to trial with the Mitchells as plaintiffs and American Savings as defendant.

For the first time on appeal American Savings argues that Mitchell’s claim for severance pay is unenforceable because an agreement by a corporate officer or director to resign his office for a pecuniary benefit to himself is void as against public policy. This court in Nutter v. Bechtel, 6 Ariz.App. 501, 433 P.2d 993 (1967), has held that the illegality of a contract may be raised for the first time on appeal by the court on its own initiative. If the court can do this, presumably so can the parties. The authorities cited by American Savings, however, do not support the application of the rule it would invoke. The language of the Supreme Court of Utah in Cox v. Berry, 19 Utah 2d 352, 431 P.2d 575 (1967), seems particularly appropriate:

Respondents’ main contention is that ■these agreements are void because it would be against public policy for Berry to accept a pecuniary consideration to resign his office. There is no doubt that one who is elected as an officer or director of a corporation accepts a fiduciary responsibility to serve the interests of those who elect him which he must discharge with fidelity and which he should not desert for his own gain. If corporate officers could in effect be bribed to resign, the way would be open to nefarious machinations in corporate affairs. An officer or director can, of course, resign whenever he wants to. But his decision to do so should be made independent of any proffered monetary consideration. For these reasons we are in accord with the proposition advocated by respondents that generally an agreement for a corporate officer to resign his office for a pecuniary benefit to himself would be void. [Footnote citations omitted.]
But it often happens that a blind and unreasoning application of a “general rule,” in the absence of the circumstances it was intended to apply to, results in defeating rather than serving the interest of justice. It is hardly to be supposed that there is any rule which is to be applied universally and absolutely regardless of circumstances. [Footnote citations omitted.] The only proper function of rules is to serve the ends of justice. They are intended to be applied to the circumstances in which justice demanded their creation to guard against an evil. Conversely, where the circumstances are such that no such evil or any likelihood of it exists, the rule has no proper application. And this is true, a fortiori, where invocation of the rule would bring about an unjust and inequitable result. 431 P.2d at 577-8.

This is not a case of a corporate officer or director deserting his fiduciary responsibility for his own gain. The choice offered to Mitchell was either to resign voluntarily and cooperate with his successor or to be fired without compensation. Rather than bargaining away his discretionary vote on the board of directors, it appears that he acted not only in his own best interests but in the best interests of the corporation in tendering his resignation. In our opinion the rule relied on by American Savings has no application under those circumstances. See Crespinel v. Color Corporation of America, 160 Cal.App.2d 386, 325 P.2d 565 (1958). An appellant attempting to escape its contractual obligation by claiming a contract is illegal must show clearly and unequivocally that the contract is illegal. Goode v. Powers, 97 Ariz. 75, 397 P.2d 56 (1964). American Savings has not sustained that burden.

The overlapping arguments that there was a lack or failure of consideration for American Savings’ promise to make the remaining payments to Mitchell also are unpersuasive. Although his employment was terminable at will, it required neither his voluntary resignation nor his cooperation in the transition in management. At trial the president of American Savings disputed Mitchell’s performance of the latter condition, in part because other employees failed to cooperate out of loyalty to Mitchell. Though not a factor in the jury’s verdict, the testimony illustrates the benefit to American Savings of terminating Mitchell’s employment amicably rather than by firing him abruptly. Thus his tender of resignation and continued services through October 15 provided sufficient consideration for the severance pay agreement, even though the payments were based on his prior wages and were to extend beyond October 15, the last date on which he was to perform any service.

Mitchell’s counterclaim was amended after dismissal of the complaint for foreclosure to allege that the wrongful commencement of the foreclosure action had caused him to sell his mortgaged home at a loss. With benefit of hindsight, he contends on appeal that American Savings was required to follow his instructions to apply the unpaid severance pay that was owing to him against the 'mortgage obligation, thereby eliminating any default. At the time the foreclosure action was commenced, however, Mitchell’s claim for severance pay was a disputed setoff. While a liquidated claim arising out of a collateral transaction may preclude foreclosure of a mortgage under some circumstances, cf. Nutter v. Occidental Petroleum Land and Development Corporation, 117 Ariz. 458, 573 P.2d 532 (App.1977), we have been directed to no authority that the existence of such a claim makes wrongful the commencement of an action to foreclose a mortgage otherwise in default.

Affirmed.

HOWARD and HATHAWAY, JJ., concurring.  