It was hard to think up a scene for Marge at first, since even the writers admit that she's kind of a bland character. How do you devise an interesting underwater scenario for a "spineless, potato-cooking housewife" (see 5F06 "Realty Bites") who "spends 23 hours a day" at home (see 3F07 "Marge Be Not Proud")? Well, with my nerd-like knowledge of everything related to "The Simpsons", I recalled the not-entirely classic episode DABF18 "Large Marge", wherein Marge's accidental breast implants secure her a job as a spokesmodel at various trade shows. The whole thing snowballed from there.
There's actually a few other things at work here, too. The underwater kitchen is inspired by a recent ad campaign for Bounty paper towels, but the coffeepot is inspired by a long-lost kitchenware commercial from the 1960s that nobody in the underwater photography circles has been able to locate in years. But hey, no pop culture reference is too obscure for "The Simpsons"...
when I first saw this, I was thinking of "Time and Punishment", a segment from the 5th Treehouse of Horror. During the part near the end where they speed things up and quickly shift through some of the bizarre present periods that Homer accidentally created, one of them depicted Springfield underwater.