
434 B.R. 193 (2010)
Daniel MOTTA d/b/a Aquarius Pools & Spa, and Annelee Motta, Debtors.
David W. Ostrander, Chapter 7 Trustee, Plaintiff-Appellant,
v.
Antonio J. Andre and Phyllis J. Andre, Defendants-Appellees.
BAP No. MS 10-006. Bankruptcy No. 08-31361-HJB. Adversary No. 08-03041-HJB.
United States Bankruptcy Appellate Panel of the First Circuit.
August 10, 2010.
*195 Elizabeth D. Katz, Esq., Northampton, on brief for Plaintiff-Appellant.
Warren R. Thompson, Esq., Palmer, on brief for Defendants-Appellees.
Before HAINES, LAMOUTTE, and TESTER, United States Bankruptcy Appellate Panel Judges.
PER CURIAM.
David W. Ostrander, Chapter 7 Trustee (the "Trustee"), appeals from a bankruptcy court order (the "Order") denying his motion for summary judgment on his complaint seeking to avoid a lien on the residence of Daniel and Annelee Motta (the "Debtors") held by Antonio and Phyllis Andre (the "Andres"), and granting summary judgment, sua sponte, in favor of the Andres. The bankruptcy court's decision turned on its conclusion that a prior mortgage remained effective against a new note that was related to the prior debt. For the reasons set forth below, we AFFIRM.

JURISDICTION
A bankruptcy appellate panel may hear appeals from "final judgments, orders and decrees [pursuant to 28 U.S.C. § 158(a)(1)] or with leave of the court, from interlocutory orders and decrees [pursuant to 28 U.S.C. § 158(a)(3) ]." Fleet Data Processing Corp. v. Branch (In re Bank of New England Corp.), 218 B.R. 643, 645 (1st Cir. BAP 1998). An order granting summary judgment is a final order where no counts against any defendants remain. Bartel v. Walsh (In re Bartel), 404 B.R. 584, 589 (1st Cir. BAP 2009). Here, the Order is final because it resolved the one remaining count of the complaint.[1]See id.

STANDARD OF REVIEW
We review the bankruptcy court's findings of fact for clear error and conclusions of law de novo. See Lessard v. Wilton-Lyndeborough *196 Coop. School Dist., 592 F.3d 267, 269 (1st Cir.2010). The Panel reviews a bankruptcy court's grant of summary judgment de novo. Backlund v. Stanley-Snow (In re Stanley-Snow), 405 B.R. 11, 17 (1st Cir. BAP 2009).

DISCUSSION

I. The Pertinent Statutes

A. Rule 56(c)(2)[2]
Rule 56(c)(2) provides:
[Summary judgment] should be rendered if the pleadings, the discovery and disclosure materials on file, and any affidavits show that there is no genuine issue as to any material fact and that the movant is entitled to judgment as a matter of law.
Fed.R.Civ.P. 56(c)(2).

B. The Massachusetts Obsolete Mortgages Statute
The Massachusetts Obsolete Mortgages Statute provides in relevant part:
A power of sale in any mortgage of real estate shall not be exercised and an entry shall not be made nor possession taken nor proceeding begun for foreclosure of any such mortgage after the expiration of, [ ... ] in the case of a mortgage in which the term or maturity date of the mortgage is stated, 5 years from the expiration of the term or from the maturity date, unless an extension of the mortgage, or an acknowledgment or affidavit that the mortgage is not satisfied, is recorded before the expiration of such period [...].
Mass. Gen. Laws ch. 260, § 33.

C. Bankruptcy Code § 544(a)(3)
Section 544(a)(3) provides:
(a) The trustee shall have, as of the commencement of the case, and without regard to any knowledge of the trustee or of any creditor, the rights and powers of, or may avoid any transfer of property of the debtor or any obligation incurred by the debtor that is voidable by...
(3) a bona fide purchaser of real property, other than fixtures, from the debtor, against whom applicable law permits such transfer to be perfected, that obtains the status of a bona fide purchaser and has perfected such transfer at the time of the commencement of the case, whether or not such a purchaser exists.
11 U.S.C. § 544(a)(3).

D. Bankruptcy Code § 551
Section 551 provides:
Any transfer avoided under section ... 544 ... of this title ... is preserved for the benefit of the estate but only with respect to property of the estate.
11 U.S.C. § 551.

II. Background
On October 30, 1997, the Debtors executed a note (the "1997 Note") in favor of the Andres, and also granted the Andres a mortgage (the "1997 Mortgage") on their residence. Among other things, the 1997 Note provided for a balloon payment in the *197 amount of $28,881.33 due on October 30, 2007, as the final payment. The 1997 Mortgage recited the terms of the 1997 Note, including the ten-year term. The Andres duly recorded the 1997 Mortgage.
The Debtors were unable to make the balloon payment when it came due. On December 10, 2007, they executed a second note (the "2007 Note") in the amount of $29,364.50[3] in favor of the Andres, and granted the Andres a mortgage (the "2007 Mortgage"). The 2007 Note reamortized the amount owing under the 1997 Note (i.e., the balloon payment) by extending the repayment period to just under three years, and also set a higher interest rate. The 2007 Mortgage recited the terms contained in the 2007 Note. The Andres did not record a discharge of the 1997 Mortgage or record the 2007 Mortgage, although the Trustee alleges that the Andres' attorney instructed them to do so, and that Mr. Andre told the Debtors he would.
The Debtors filed a chapter 7 petition in 2008. Appending the 2007 Mortgage, the Andres filed a proof of claim asserting a secured claim in the amount of $20,754.60. The Trustee sought to avoid the 2007 Mortgage and preserve it for the benefit of the estate pursuant to §§ 544(a)(3) and 551. He also moved for summary judgment and the Andres objected. In denying the motion, the bankruptcy court concluded that the 2007 Mortgage could be avoided because it was unperfected, but that the Andres' claim remained secured by the 1997 Mortgage. The bankruptcy court rejected the Trustee's theory of novation, concluding that the Trustee had failed to prove that the Andres had intended to discharge the 1997 Mortgage.
In granting, sua sponte, summary judgment for the Andres, the bankruptcy court concluded that the Andres' claim remained secured by the 1997 Mortgage. The court concluded that the Trustee's status as a bona fide purchaser under § 544(a)(3) did not change the result, because the 1997 Mortgage was properly recorded and remained on record when the Debtors filed their petition, thus providing notice that the Property was encumbered. This appeal followed.

III. Analysis

A. Summary Judgment, Sua Sponte

Although such rulings are disfavored, there are circumstances in which a trial court may enter summary judgment, sua sponte. See Puerto Rico Elec. Power Authority v. Action Refund, 515 F.3d 57, 64 (1st Cir.2008); Rijos v. Banco Bilbao Vizcaya (In re Rijos), 263 B.R. 382, 391-92 (1st Cir. BAP 2001). Two conditions must be satisfied for entry of summary judgment sua sponte: (1) discovery "`must be sufficiently advanced that the parties have enjoyed a reasonable opportunity to glean the material facts,'" and (2) the court must provide "`the targeted party appropriate notice and a chance to present its evidence on the essential elements of the claim or defense.'" Puerto Rico Elec., 515 F.3d at 64-65 (quoting Sánchez v. Triple-S Mgmt. Corp., 492 F.3d 1, 7 (1st Cir.2007)); see also In re Rijos, 263 B.R. at 391-92.
Discovery is "sufficiently advanced" where the parties have completed discovery and filed pretrial memoranda. Puerto Rico Elec., 515 F.3d at 65. Discovery may even be sufficiently advanced before discovery has closed, depending on *198 the circumstances of the case and the nature of the issue decided on summary judgment. Sánchez, 492 F.3d at 7-8; see also Aetna Cas. Sur. Co. v. P & B Autobody, 43 F.3d 1546, 1568 (1st Cir.1994) (noting that discovery that has been completed is more than "sufficiently advanced"). Here, the Trustee does not dispute the fact that discovery was sufficiently advanced.[4]
Notice is adequate when the target of the judgment has reason to believe the court might reach the issue, and has had "a fair opportunity to put its best foot forward" by presenting evidence on the essential elements of the claim. Vives v. Fajardo, 472 F.3d 19, 22 (1st Cir.2007); Jardines Bacata, Ltd. v. Diaz-Marquez, 878 F.2d 1555, 1561 (1st Cir.1989) (superceded by rule on other grounds). Any question on this point should be resolved in favor of the losing party. Jardines Bacata, 878 F.2d at 1561. Appellate courts take great care to ensure that the losing party had a fair opportunity to oppose entry of judgment against it. Id. (citing 10A C. Wright, A. Miller, & M. Kane, Federal Practice and Procedure, § 2720 at 34 (1983)).
The Trustee argues that he was not provided the opportunity to introduce testimony by the Debtors and the Andres' attorney in support of his position that the Debtors and the Andres intended to discharge the 1997 Mortgage. The Trustee, however, had adequate notice that the bankruptcy court could enter summary judgment against him on this issue. Because intent is one of the elements of novation, the Trustee had put the issue of intent squarely before the court when he moved for summary judgment. The bankruptcy court granted summary judgment in favor of the Andres under the very case law the Andres presented in their objection to the Trustee's motion. Thus, the Trustee had every reason to believe that the bankruptcy court couldindeed, wouldreach the issue of whether the Debtors and the Andres had intended to discharge the 1997 Mortgage, and he had a fair opportunity to put his best foot forward on that issue. See Vives, 472 F.3d at 22; Jardines Bacata, 878 F.2d at 1561.

B. The Andres' Claim
A reviewing court should affirm a grant of summary judgment if it concludes that there is no genuine issue of material fact and the prevailing party is entitled to judgment as a matter of law. Braga v. Hodgson, 605 F.3d 58, 60 (1st Cir.2010). An issue is "genuine" if the evidence of record permits a rational fact finder to resolve it in favor of either party. Borges ex rel. S.M.B.W. v. Serrano-Isern, 605 F.3d 1, 4-5 (1st Cir.2010). A fact is "material" if it has the potential to change the outcome. Id. Although it is "unusual" to grant summary judgment on issues of intent, S.E.C. v. Ficken, 546 F.3d 45, 51 (1st Cir.2008), even in those cases, summary judgment may be appropriate if the nonmoving party rests merely upon conclusory allegations, improbable inferences, and unsupported speculation. Meuser v. Federal Express Corp., 564 F.3d 507, 515 (1st Cir.2009).
Section 544(a)(3) vests the trustee with the powers of a bona fide purchaser of real property for value, and allows the trustee to invalidate unperfected security interests. 11 U.S.C. § 544(a)(3); Riley v. Sullivan (In re Sullivan), 387 B.R. 353, 357-58 (1st Cir. BAP 2008). Under § 551, *199 an avoided lien, with respect to property of the estate, is preserved for the benefit of the estate. 11 U.S.C. § 551. Here, the status of the 2007 Mortgage is not at issue; it is unperfected, and therefore avoidable. See In re Sullivan, 387 B.R. at 357-58. The question is whether the Andres' claim remained secured by the 1997 Mortgage at the time the Debtors filed their bankruptcy petition. At the bankruptcy court, the Trustee argued that it was not, because the 2007 Note and Mortgage created a novation, thus extinguishing the 1997 Mortgage.
As the bankruptcy court stated, novation exists where "`there was an existing valid original obligation, [ ... ] an agreement of all parties to the new contract, the extinguishment of the old contract, and a valid new contract.'" Ostrander v. Andre (In re Motta), 423 B.R. 393, 400 (Bankr.D.Mass.2010) (quoting Larson v. Jeffrey-Nichols Motor Co., 279 Mass. 362, 181 N.E. 213, 214 (1932)). As the bankruptcy court noted, the only factor in dispute was whether the 1997 Note and Mortgage were extinguished. Id. The court explained that to determine this issue it had to consider whether the Debtors and the Andres had agreed and intended to discharge the obligations under the 1997 Note and Mortgage when they executed the 2007 Note and Mortgage. Id. The Trustee argued that they did so intend, as evidenced by: (1) Mr. Andres' alleged testimony at the § 341 meeting; (2) the fact that the Debtors granted the Andres the 2007 Mortgage; and (3) the fact that the Andres attached the 2007 Note and Mortgage to their proof of claim. The bankruptcy court considered the Trustee's position, analyzed the summary judgment record and Massachusetts state law, and correctly determined that the Trustee could not prevail as a matter of law. The bankruptcy court's well-reasoned opinion amply supports its conclusion.
In denying the Trustee's motion for summary judgment, the bankruptcy court concluded that:
The Trustee has not presented any direct evidence or testimony to contradict the Andres' assertion that they did not intend the [2007 Note and Mortgage] to discharge the [1997 Mortgage] or the Debtors' obligation to pay the amounts remaining unpaid on the [1997 Note]. Although the Trustee alleges in the Complaint that the Debtors testified at the 341 Meeting that the Andres had indicated they would release the [1997 Mortgage] and record the [2007 Mortgage], the Trustee should have attached a transcript of that testimony to his Summary Judgment Motion or provided an affidavit from the Debtors to that effect. As further explained below, however, that omission is harmless, as the facts of this case otherwise establish that the [1997 Mortgage] was not discharged and was left unchanged by the execution of the [2007 Note].
The Trustee's reliance on circumstantial evidence and the Andres' conduct to impute an intended novation fares no better. First, the Trustee says that the Andres' very execution of the [2007 Note and Mortgage] evidenced their intent to discharge the prior obligations and security interest represented by the [1997 Mortgage]. Although an intended novation may be found from circumstantial evidence and the conduct of parties to an agreement, see Johnston v. Holiday Inns, Inc., 565 F.2d 790, 796-97 (1st Cir.1977), "a finding of an intent to discharge the preexisting indebtedness should rest on a `clear and definite indication' of such intent," [Pagounis v. Pendleton, 52 Mass.App.Ct. 270, 753 N.E.2d 808, 811 (Mass.App.Ct.2001) *200 (quoting Lipson v. Adelson, 17 Mass. App.Ct. 90, 456 N.E.2d 470, 472 (Mass. App.Ct.1983)) ]. The mere execution of the [2007 Note and Mortgage], even with the revised principal balance and increased interest rate, may have constituted a "clear and definite indication" of an intent to agree to different repayment terms than those contained in the [1997 Note], but not necessarily an intent to discharge the [1997 Mortgage]. [...]
Similarly, the Andres' attachment of the [2007 Note and Mortgage] to the Proof of Claim does not necessarily support an inference that the Andres' [sic] intended to discharge the [1997 Mortgage]. In his uncontroverted deposition testimony, Antonio stated that the Andres never intended the [2007 Note and Mortgage] to discharge or release the [1997 Mortgage]. And the Andres' failure to record the [2007 Mortgage] supports Antonio's deposition testimony that the Andres believed the [1997 Mortgage] remained a source of security for the debt (thus obviating the need to record the [2007 Mortgage]).
See id. at 400-401 (footnote omitted). The bankruptcy court concluded that the Trustee was not entitled to summary judgment, because he had not demonstrated "the Andres' `clear and definite indication' to discharge the [1997 Mortgage] required to support a finding of novation." Id. at 401 (citation omitted).
After the bankruptcy court disposed of the Trustee's argument, it went on to grant summary judgment in favor of the Andres. In doing so, the bankruptcy court explained that the Massachusetts Supreme Judicial Court has long ruled in favor of secured lenders under similar facts presented here. Id. More specifically, the court explained that:
Although, under Massachusetts law, the execution of a new note related to a debt is presumed to discharge the obligations under the original note, this presumption is rebutted where it is shown that the parties did not intend to discharge the original debtusually a question of fact. But where the lender holds security for payment of the debt, the presumption of discharge is rebutted by the existence of that security interest, and only evidence of a contrary intent will result in a finding that the original security was discharged.
In 1862, the SJC articulated the legal principles underlying this line of cases:
The courts regard the interests of mortgagees with great liberality, for the purpose of effectually securing to them the performance of the contract which the mortgage was originally designed to secure; and they allow no change of form of the indebtedness to discharge the mortgage, where there has been no actual payment or release.... Such cases are based upon the fact that at no period of time has there been an actual extinguishment of the indebtedness secured by the mortgage.

Joslyn v. Wyman, 87 Mass. 62, 62, 5 Allen 62 (1862); see also [Pomroy v. Rice, 33 Mass. 22, 24 (1834) ] ("[W]here a mortgage and note are given to secure the payment of a sum of money, the renewal of the note does not operate as a discharge of the mortgage.... Nothing but payment of the debt will discharge the mortgage."); [Fin. Acceptance Corp. v. Garvey, 6 Mass.App.Ct. 610, 380 N.E.2d 1332, 1335 (Mass.App. Ct.1978)] (citing Pomroy, 33 Mass. at 24).
These legal principles remain unchanged by subsequent Massachusetts case law, as noted in the relatively more recent cases cited by the Andres, Piea Realty *201 Co. v. Papuzynski, 172 N.E.2d 841, 342 Mass. 240 (1961), and Financial Acceptance Corp. v. Garvey, 380 N.E.2d 1332, 6 Mass.App.Ct. 610 (1978). The Trustee argues that both cases are distinguishable. He is correct insofar as the factual circumstances are distinguishable, but the factual differences are ultimately immaterial to the relevant points of law articulated in those cases.
[ ... ]
Both cases [ ... ] reaffirm the central principles applicable to the case at hand. Since the Trustee has not presented the Court with evidence of an affirmative intent to release the Debtors' obligations under the [1997 Mortgage], and since the original debt has not yet been paid, the [1997 Mortgage] remains as security for the Debtors' continued obligation to the Andres.
Id. at 401-404 (footnotes omitted).
The Trustee argues that the 1997 Mortgage does not secure the 2007 Note, because the terms of the 1997 Mortgage did not include "dragnet" language establishing a security interest in future debt. We reject this argument. As discussed above, the 2007 Note merely reamortized the balloon payment owing under the 1997 Note. Indeed, the Trustee conceded at oral argument that there was no "new money," and that the 2007 Note merely reamortized the 1997 Note. Thus, the 2007 Note was not "future debt," but rather the very same obligation represented by the 1997 Note.
Moreover, the bankruptcy court correctly concluded that the Trustee's status as a bona fide purchaser under § 544(a)(3) was of no significant consequence. The 1997 Mortgage had been duly recorded and remained on record when the Debtors filed their petition. See id. at 404. The bankruptcy court noted that the 1997 Mortgage provided adequate notice that the Andres held a mortgage on the Debtors' property, because the 2007 Note:
included only the amount outstanding on the Debtors' obligations under the [1997 Note], and the higher interest rate did not increase the secured debt to an amount greater than that stated in the [1997 Note]. Thus, no bona fide purchaser or junior lienholder would have been prejudiced by the parties' execution of the [2007 Note] in order to allow an extension of time for the repayment of the outstanding debt.
Id. at 405.
The Trustee asserts that the 1997 Mortgage was not effective at the time the Debtors filed their bankruptcy petition, because it states that the final payment under the 1997 Mortgage was due on October 30, 2007, eleven months prior to the bankruptcy filing. Thus, according to the Trustee, the property appeared to be unencumbered on the petition date and there was no duty to investigate further. We reject this argument as well.
Although the 1997 Mortgage reflects a maturation date prior to the Debtors' bankruptcy, it remains effective. Under the Massachusetts Obsolete Mortgages Statute, a mortgage that provides a maturity date remains in effect for five years after that date, unless a discharge is recorded. Mass. Gen. Laws ch. 260, § 33 (2010); see also LBM Fin., LLC v. 201 Forest Street, LLC (In re 201 Forest Street, LLC), 422 B.R. 888, 892 (1st Cir. BAP 2010). The plain meaning of the statute is clear. Shamus Holdings, LLC v. LBM Fin., LLC (In re Shamus Holdings, LLC), 409 B.R. 598, 603-604 (Bankr. D.Mass.2009). The 1997 Mortgage's maturity date was October 30, 2007. The Andres did not discharge it. Therefore, the 1997 Mortgage remained effective on the *202 date of bankruptcy. See Mass. Gen. Laws ch. 260, § 33.

CONCLUSION
In sum, the bankruptcy court correctly analyzed and applied the law. The 2007 Note merely reamortized the amount owing under the 1997 Note. The 1997 Mortgage was of record. Mr. Andre testified that the Andres and the Debtors did not intend to discharge it. The Trustee presented no evidence to the contrary. Thus, the Trustee failed to create a genuine issue of material fact. The bankruptcy court, therefore, did not err in granting summary judgment in favor of the Andres. We AFFIRM.
NOTES
[1]  The Trustee had also sought a determination that the Debtors' homestead exemption was subordinate to the Andres' mortgage. Because the Debtors defaulted, the bankruptcy court entered a default judgment against them. Thus, the Order disposed of the only remaining count.
[2]  Rule 56 is made applicable to bankruptcy proceedings through Bankruptcy Rule 7056. Unless otherwise indicated, the terms "Bankruptcy Code," "section" and "§ " refer to Title 11 of the United States Code, 11 U.S.C. §§ 101, et seq., as amended by the Bankruptcy Abuse Prevention and Consumer Protection Act of 2005, Pub. L. No. 109-8, 119 Stat. 37. All references to "Rule" are to the Federal Rules of Civil Procedure, and all references to "Bankruptcy Rule" are to the Federal Rules of Bankruptcy Procedure.
[3]  This amount represents the amount of the balloon payment due under the 1997 Note plus interest accrued through January 2008.
[4]  The Trustee's motion for summary judgment reflects that the parties had filed a joint statement of facts, and that the Andres had responded to the Trustee's request for admissions and had been deposed.
