
    In the Matter of: MIRANT CORPORATION, Debtor. MC Asset Recovery LLC, as successor in interest & as representative of, on behalf of Mirant Corporation, Plaintiff-Appellee, v. Castex Energy, Inc.; Castex Energy 1995, LP; Castex Energy 1996, LP; Laterre Co., Ltd., Defendants-Appellants.
    No. 09-10451.
    United States Court of Appeals, Fifth Circuit.
    Aug. 2, 2010.
    
      John Robert Forshey (argued), Suzanne K. Rosen, Forshey & Prostok, L.L.P., Fort Worth, TX, for Plaintiff-Appellee.
    Louis Middleton Phillips, Ryan James Richmond, Gordon, Arata, McCollam, Du-plantis & Eagan, L.L.P., Baton Rouge, LA, Jonathan Bridges, Susman Godfrey, L.L.P., Dallas, TX, Neal Stuart Manne, Karen A. Oshman (argued), Susman God-frey, L.L.P., Houston, TX, for Defendants-Appellants.
    Before JONES, Chief Judge, and SMITH and ELROD, Circuit Judges.
   JENNIFER WALKER ELROD, Circuit Judge:

This appeal arises from a dispute between Castex Energy and MC Asset Recovery (“MCAR”) regarding the alleged breach of a purchase and sale agreement. Castex appeals the district court’s denial of its motion to compel arbitration. For the following reasons, we AFFIRM.

I.

In 2001, Mirant Corporation and its affiliates (collectively, “the Mirant Entities”), MCAR’s predecessors in interest, purchased interests in Louisiana mineral properties and obtained a 75% majority interest in a closely held corporation pursuant to a 2001 Purchase and Sale Agreement (“PSA”) with Castex (hereinafter “the Assets”). In 2002, the Mirant Entities agreed to sell the Assets back to Cas-tex pursuant to another PSA. After the closing of the 2002 PSA, Castex sold the Assets to Apache Corporation. The Mir-ant Entities alleged breach of the 2002 PSA and fraud, claiming Castex should have disclosed the fact that it was negotiating with Apache for a sale of the Assets.

This lawsuit originated as a fraudulent transfer adversary proceeding initiated by some of the Mirant Entities in connection with Mirant Corporation’s bankruptcy. The original complaint sought to avoid the 2001 PSA and the 2002 PSA as constructively fraudulent transfers, but did not allege breach of the 2002 PSA. Two days after filing their original complaint, the Mirant Entities moved to stay the adversary proceeding. The bankruptcy court granted the request and stayed the case for 19 months, until January 2007.

Once the stay expired, Castex filed its answer to the original complaint. By that time, MCAR had been designated as the assignee of the claims raised in the original complaint and successor in interest to the Mirant Entities. Castex’s answer contained several affirmative defenses, including its right to compel arbitration. Castex then requested a jury trial before the district court, and, on that basis, moved to withdraw the reference to the bankruptcy court. Castex stated its intention to preserve its right to compel arbitration in a footnote in the motion to withdraw reference to the bankruptcy court, but it did not move to compel arbitration at that time. The district court granted the motion to withdraw reference to the bankruptcy court.

After Castex answered, MCAR filed its first amended complaint and largely abandoned its original grounds for relief and raised state law claims arising from the 2002 PSA for breach of contract, fraud, violations of the Texas Blue Sky Law, and breach of fiduciary duty. Castex did not move to compel arbitration at that time. Instead, it filed a motion to dismiss under Fed.R.Civ.P. 9(b), 12(b)(6), and 12(c), arguing that MCAR’s complaint was deficient because it failed to allege sufficient facts to state a claim for relief. In a footnote in the motion, Castex reserved its right to compel arbitration.

After filing its motion to dismiss, Castex filed a motion for a protective order, seeking to stay discovery in the case, pending the district court’s resolution of its motion to dismiss. Castex also filed a motion for relief from the court’s initial scheduling order, seeking relief from the requirement that the parties make initial disclosures pursuant to Fed.R.Civ.P. 26. The district court entered a protective order staying all discovery in the case pending the outcome of the motion to dismiss. MCAR later moved for limited relief from the protective order in order to depose an employee of the Mirant Entities who was scheduled to leave his position. Castex objected to this motion and the district court denied it.

Before the district court ruled on the first motion to dismiss, MCAR filed its second amended complaint. This complaint contained modified versions of the claims in the first amended complaint and added claims for fraud, fraudulent inducement, and statutory fraud under Tex. Bus. & Com.Code § 27.01. In response to the second amended complaint, Castex filed a second motion to dismiss under Fed. R.Civ.P. 9(b), 12(b)(6), and 12(c). Once again, Castex reserved its right to compel arbitration in a footnote but did not move to compel arbitration. Castex also filed a separate motion to dismiss under Rule 12(b)(1) arguing that MCAR lacked standing because it had not been assigned any claims outside of the bankruptcy avoidance claims contained in the original complaint.

MCAR then filed a third amended complaint, which contained the same substantive causes of actions as the previous complaint but with more details added. Castex filed a third motion to dismiss pursuant to Rules 9(b) and 12(b)(6). As it had done in its previous motions to dismiss, Castex reserved its right to compel arbitration in a footnote. In its third motion to dismiss, Castex asked the district court to use its discretion to deny further amendments to MCAR’s complaint and asked that the court dismiss all claims with prejudice. On September 22, 2008, the district court partially granted the motion, dismissing Count VI (breach of fiduciary duty) with prejudice. The court denied the motion as to the remaining claims.

On October 6, 2008, Castex filed a motion to compel arbitration before answering the third amended complaint. MCAR responded to Castex’s motion to compel arbitration by arguing that Castex had waived that right by substantially invoking the judicial process. MCAR also claimed it had been prejudiced by incurring $265,559 in attorneys’ fees and costs in defending against the motions to dismiss. The district court denied the motion to compel arbitration. The district court noted that “[tjhere does not appear to be any dispute in this case over the existence or validity of the [arbitration clause] or whether [MCAR’s claims] fall within the scope of the [arbitration clause].” The district court, however, held that Castex had waived its right to compel arbitration because it had substantially invoked the judicial process by filing multiple motions to dismiss, seeking and partially obtaining a dismissal with prejudice, and waiting eighteen months before invoking arbitration. It also found that MCAR suffered prejudice through delay, legal fees, and the dismissal of its claim for breach of fiduciary duty.

II.

We have jurisdiction of this appeal even though the district court’s denial of Castex’s motion to compel arbitration is an interlocutory order. Nicholas v. KBR, Inc., 565 F.3d 904, 907 (5th Cir.2009). We review the district court’s denial of a motion to compel arbitration de novo. Am. Heritage Life Ins. Co. v. Lang, 321 F.3d 533, 536 (5th Cir.2003). We also review the district court’s determination that Cas-tex has waived its right to arbitration de novo, but we review any factual findings underlying that determination for clear error. Republic Ins. Co. v. PAICO Receivables, LLC, 383 F.3d 341, 344 (5th Cir.2004). “Waiver will be found when the party seeking arbitration substantially invokes the judicial process to the detriment or prejudice of the other party.” Walker v. J.C. Bradford & Co., 938 F.2d 575, 577 (5th Cir.1991) (internal quotation marks and citation omitted). “There is a strong presumption against finding a waiver of arbitration, and the party claiming that the right to arbitrate has been waived bears a heavy burden.” Republic Ins. Co., 383 F.3d at 344 (citation omitted).

A.

We first examine whether Castex substantially invoked the judicial process. To invoke the judicial process, a “party must, at the very least, engage in some overt act in court that evinces a desire to resolve the arbitrable dispute through litigation rather than arbitration.” Subway Equip. Leasing Corp. v. Forte, 169 F.3d 324, 329 (5th Cir.1999). Castex argues that the filing of a motion to dismiss, standing alone, can never support a finding that a party has “substantially invoke[d] the judicial process.” Walker, 938 F.2d at 577 (internal quotation marks and citation omitted). As the Eighth Circuit has observed, however, “[mjotions to dismiss are not homogeneous.” Hooper v. Advance Am., Cash Advance Ctrs. of Mo., Inc., 589 F.3d 917, 922 (8th Cir.2009). In this Circuit, a bright-line rule is inappropriate for deciding whether a party has waived its right to arbitration. Rather, our precedent establishes that “[t]he question of what constitutes a waiver of the right of arbitration depends on the facts of each case.” Tenneco Resins, Inc. v. Davy Int'l, AG, 770 F.2d 416, 420 (5th Cir.1985) (citation omitted).

“A party waives arbitration by seeking a decision on the merits before attempting to arbitrate.” Petroleum Pipe Ams. Corp. v. Jindal Saw, Ltd., 575 F.3d 476, 480 (5th Cir.2009) (citation omitted). Castex argues that it did not attempt to obtain a decision on the merits because it only filed “perfunctory motion[s] to dismiss.” Williams v. Cigna Fin. Advisors, Inc., 56 F.3d 656, 661 (5th Cir.1995) (internal quotation marks and citation omitted). We disagree. Castex based its second and third motions to dismiss partially on the affirmative defenses of waiver and release. Such affirmative defenses “admit the initial sufficiency and completeness of the claim while asserting other grounds for avoiding the normal consequences of that concession.” Pan E. Exploration Co. v. Hufo Oils, 855 F.2d 1106, 1125-26 (5th Cir.1988), superseded on other grounds by, Tex. Bus. Corp. Act Ann. art. 2.21. By seeking to prove its own allegations to the district court, Castex invoked the judicial process to a greater degree than it would have by filing a mere “perfunctory motion to dismiss.” Williams, 56 F.3d at 661 (internal quotation marks and citation omitted). While we do not hold that a party “substantially invokes the judicial process,” Walker, 938 F.2d at 577 (internal quotation marks and citation omitted), whenever it files a motion to dismiss based on an affirmative defense, we agree with the district court that Castex did so in this instance.

Moreover, in its third motion to dismiss, Castex sought the dismissal of MCAR’s complaint with prejudice. As the district court observed, “[a] dismissal with prejudice for failure to state a claim is a decision on the merits and essentially ends the plaintiffs lawsuit.” Mahone v. Addicks Util. Dist. of Harris County, 836 F.2d 921, 940 (5th Cir.1988) (citation omitted). Here, Castex partially succeeded on its third motion to dismiss when the district court dismissed MCAR’s claim for breach of fiduciary duty with prejudice. Castex’s request for a dismissal with prejudice reinforces our conclusion that it sought a decision on the merits in this case.

We also note that Castex did not initially present its motion to compel arbitration to the district court as an alternative to its motion to dismiss. Rather, Castex first sought “a decision on the merits before attempting to arbitrate.” Petroleum Pipe, 575 F.3d at 480 (citation omitted). This case is easily distinguished from the scenario where a party demonstrates its preference to arbitrate by submitting a dispos-itive motion only as an alternative to a motion to compel arbitration. See, e.g., Keytrade USA, Inc. v. Ain Temouchent M/V, 404 F.3d 891, 897-98 (5th Cir.2005) (finding no waiver where a defendant concurrently filed a motion to compel arbitration with a motion for summary judgment and then appealed the denial of the motion to compel arbitration); Steel Warehouse Co. v. Abalone Skipping Ltd. of Nicosai, 141 F.3d 234, 236-38 (5th Cir.1998) (finding no waiver where defendant filed motion to dismiss contemporaneously with a motion to compel arbitration and appealed the denial of the motion to compel arbitration). In those circumstances, there is no attempt to game the system by seeking a decision on the merits while keeping the arbitration option as a backup plan in case the effort fails.

Castex, however, moved to compel arbitration only after the district court had partially denied its third motion to dismiss, despite being fully aware of its right to compel arbitration from the outset. We are not convinced that “[Castex], having learned that the district court was not receptive to its arguments, should be allowed a second bite at the apple through arbitration.” Petroleum Pipe, 575 F.3d at 482. To hold otherwise would encourage litigants to delay moving to compel arbitration until they could ascertain “how the case was going in federal district court.” Hooper, 589 F.3d at 922 (internal quotation marks and citation omitted). In essence, Castex attempted to “play ‘heads I win, tails you lose,’ which is the worst possible reason for failing to move for arbitration sooner than it did.” Id. (citation omitted).

Taking all these factors into consideration, we conclude that Castex sought a decision on the merits before the district court. We agree with the district court that Castex “substantially invoked the judicial process” through its actions. Walker, 938 F.2d at 577 (internal quotation marks and citation omitted).

B.

“In addition to invocation of the judicial process, the party opposing arbitration must demonstrate prejudice before we will find a waiver of the right to arbitrate.” Nicholas, 565 F.3d at 910. “Prejudice in the context of arbitration waiver refers to delay, expense, and damage to a party’s legal position.” Id. (citation omitted).

We first address the question of whether Castex made a timely demand for arbitration. “While the mere failure to assert the right to demand arbitration does not alone translate into a waiver of that right, such failure does bear on the question of prejudice.” Republic Ins. Co., 383 F.3d at 346 (internal quotation marks and citation omitted). Castex argues that it made a timely demand for arbitration by listing the right to compel arbitration as an affirmative defense in its answer and reserving that right in its motions to dismiss. We disagree. As noted above, Castex waited eighteen months before moving to compel arbitration while it attempted to obtain a dismissal with prejudice from the district court. Cf. Steel Warehouse Co., 141 F.3d at 236, 238; Tenneco, 770 F.2d at 417, 420-21 (finding no waiver where defendant’s answer sought dismissal based on arbitration clause and defendant moved for a stay pending arbitration five months later without any intervening dispositive motions); Sw. Indus. Imp. & Exp., Inc., v. Wilmod Co., Inc., 524 F.2d 468, 470 (5th Cir.1975) (finding no waiver where defendant had submitted the dispute to arbitration before plaintiff filed suit). In this case, Castex’s actions did not constitute a timely demand for arbitration. A party cannot keep its right to demand arbitration in reserve indefinitely while it pursues a decision on the merits before the district court.

We now turn to the district court’s findings. Castex argues that it did not force MCAR to incur any litigation expenses. The district court, however, found that MCAR had spent over $260,000 in legal fees that were solely attributed to defending against Castex’s discovery motions and motions to dismiss. Having thoroughly reviewed the record, we cannot say that this finding was clearly erroneous. MCAR incurred considerable legal expenses as a result of Castex’s use of the federal court system. Such expenses support a finding of prejudice.

In addition to litigation expenses, the district court found that MCAR had suffered prejudice to its legal position as a result of Castex’s motions to dismiss and motions to stay discovery. Castex cites to the Second Circuit’s decision in Sweater Bee by Banff, Ltd. v. Manhattan Indus., Inc., 754 F.2d 457, 465 (2d Cir.1985), to support its argument that MCAR suffered no prejudice from its motions to dismiss because it could not obtain any relief on the breach of fiduciary duty claim. As an initial matter, we find Sweater Bee to be distinguishable; that case involved several claims that were non-arbitrable. 754 F.2d at 466. As the Seventh Circuit has noted,

[i]n such a case, a motion to dismiss may not be inconsistent with a right to arbitrate; it might be necessary for the defendant to file the motion both to sort out the claims before it can intelligently decide whether to arbitrate and to protect its rights in court if the arguably non-arbitrable claims do turn out to be non-arbitrable.

St. Mary’s Med. Ctr. of Evansville, Inc. v. Disco Aluminum Prods. Co., 969 F.2d 585, 589 (7th Cir.1992). Here, there is no dispute that the claims at issue in MCAR’s amended complaints were subject to the arbitration agreement. Castex did not need to bring a motion to dismiss to protect its rights against claims that may have turned out to be non-arbitrable. See Com-Tech Assocs. v. Computer Assocs. Int'l, Inc., 938 F.2d 1574, 1577 (2d Cir.1991) (distinguishing Siueater Bee and finding that defendants waived right to arbitration where all claims were arbitrable); St. Mary’s Med. Ctr., 969 F.2d at 589 (same). Moreover, Castex’s motions to dismiss gave it a full preview of MCAR’s evidence and litigation strategy, particularly its arguments and evidence in response to Castex’s affirmative defenses. At the same time, the stay in discovery prevented MCAR from obtaining any information from Castex. As a result, MCAR was placed in a weaker position than it would have been had Castex timely moved to compel arbitration. The district court’s finding that MCAR has suffered prejudice to its legal position is not clearly erroneous.

Finally, the district court found that the eighteen-month delay between the filing of Castex’s original answer and its motion to compel arbitration wasted judicial resources and disadvantaged MCAR. We agree. As we stated in Walker, 938 F.2d at 577, “[t]he decision whether to arbitrate is one best made at the onset of the case.” In this case, Castex was aware of its right to compel arbitration at the beginning of this litigation, but chose instead to resolve as much of the case as possible before the district court. MCAR argues that this delay prevented it from timely deposing a key witness since it was unable to obtain relief from the court’s protective order. The prejudice resulting from Castex’s delay in moving to compel arbitration likewise supports a finding of waiver.

We agree with the district court that MCAR has demonstrated sufficient prejudice. Castex’s delay in seeking to compel arbitration forced MCAR to incur significant legal expenses, placed it in a weaker legal position, and delayed the resolution of this case for over eighteen months. Consequently, Castex has waived its right to compel arbitration.

For the foregoing reasons, the judgment of the district court is hereby AFFIRMED. 
      
      . Castex relies on Gulf Guaranty Life Insurance Co. v. Connecticut General Life Insurance, Co., 304 F.3d 476, 485 (5th Cir.2002) for the proposition that a party does not waive its right to arbitrate merely by defending against a plaintiff's claims. Gulf Guaranty is distinguishable on two grounds. First, the defendant simultaneously moved to dismiss the lawsuit and to compel arbitration in the case. Id. at 480-81. Second, the plaintiff in that case based its allegation of waiver solely on the fact that the defendant had participated in the satellite litigation over the composition of the arbitration panel in the underlying dispute. Id. at 485. As the defendant consistently sought to consolidate the two suits and compel arbitration, we found no evidence of a "desire to resolve the underlying reinsurance dispute via litigation rather than arbitration.” Id.
      
     
      
      
        . Castex argues that in Williams v. Cigna Financial Advisors, Inc., 56 F.3d 656 (5th Cir.1995), we held that a party can still make a timely demand for arbitration even after filing a motion to dismiss. Williams is readily distinguishable from the present case, however. The defendant in that case discovered that the plaintiff had signed an arbitration agreement only after the district court had denied its motion to dismiss. Id. at 658. As soon as the defendant realized that the claims were subject to arbitration, it moved for a stay in the proceedings. Id.
      
     
      
      . We likewise disapproved of a similar attempt to obtain a decision on the merits before moving for arbitration in Price v. Drexel Burnham Lambert, Inc., 791 F.2d 1156, 1158 (5th Cir.1986) (affirming district court’s denial of motion to compel arbitration where the defendant waited sixteen months after the plaintiff filed suit to move to compel arbitration and had previously filed motions for dismissal and summary judgment).
     
      
      . The D.C. Circuit recently expressed similar concerns regarding the potential for abuse of the judicial process through strategic use of a party’s right to compel arbitration. See Khan v. Parsons Global Servs., Ltd., 521 F.3d 421, 427 (D.C.Cir.2008) (allowing defendant to move to compel arbitration after the appellate court had reversed the district court's grant of summary judgment in its favor "would encourage parties to attempt repeat litigation of merits issues not resolved to their satisfaction, undermining the policy that arbitration may not be used as a strategy to manipulate the legal process” (internal quotation marks and citation omitted)).
     
      
      . We pause to note that Castex’s delay also forced the district court to rule on a detailed motion to dismiss, enter an order staying discovery, rule on Castex's motion for relief from the initial scheduling order, and rule on MCAR’s motion for relief from the protective order. While considerations of judicial economy do not factor into our prejudice analysis, we do not condone litigation tactics that result in the unnecessary outlay of substantial judicial resources.
     