The Qantas website lists the points required to upgrade from economy, flexible economy to premium economy or business. Upgrades are really your only option since 289k isn’t enough points for an outright booking. An upgrade is not guaranteed, so there’s the chance you could book an economy ticket and nothing comes through and you’re stuck flying economy. For this reason perhaps you’d rather booking premium economy and hoping for an upgrade to business?
You are tied to Qantas for your flights to upgrade. You’ll only be able to upgrade on flights operated by Qantas; make sure you’re not on a codeshare flight when you book, look for QF1, QF2 (Sydney to London via Dubai).
Qantas may offer you the opportunity to buy a one-off lounge access pass, but it’s not always offered, and that would only be in Sydney, unless you fly home via London and they’ve opened their new lounge by then. You could consider buying Qantas Club membership which would give you access in Sydney, Dubai and London but not Madrid. Having Qantas Club membership will slightly improve your chance of an upgrade. There are all sorts of promotions for Qantas Club membership out there, the one through the ANZ Black Credit card is one of the best. Don’t forget if you are upgraded to Business you’ll get lounge access anyway.
Otherwise, you can pay for single entry passes to some lounges at Sydney, Dubai and London airports, the quality of these lounges varies greatly, expect to pay $40-$70pp. I’m not aware of any lounges in Madrid that allow one-off paid entry.