Reduction in maximum hit points (max HP) is essentially 5e's replacement for the energy drains, level drains and negative levels of earlier editions.1 As such, it is not meant to be easily or quickly overcome, so low-level magic does not work. In fact, the 5e demilich's legendary action is called "energy drain" while many undead in 5e (specters, wights, wraiths) have a "life drain" effect similar to the vampire's bite. However, max HP reduction is not exclusive to vampires or the undead in 5e. Players can temporarily cause the same effect with the 6th-level Harm spell and other monsters have similar attacks that do not involve necrotic damage. The other max HP reducing attacks and their respective cures are:
- blue slaad's claw – unclear (involves disease), but maybe only a wish spell (MM, p. 276)
- chasme's proboscis attack – long rest or spell like greater restoration (MM, p. 57)
- clay golem's slam attack – greater restoration spell or similar magic (MM, p. 168)
- demilich's energy drain – greater restoration spell or similar magic (MM, p. 48)
- mummy's and mummy lord's rotting fist attack – remove curse spell or other magic (MM, pp. 228-229)
- night hag's nightmare haunting – greater restoration spell or similar magic (MM, p. 178)
- otyugh's bite – daily saving throw (involves disease) (MM, p. 248)
- succubus'/incubus' draining kiss – long rest (MM, p. 285)
As listed above, the means of restoring max HP are specified in the description of the ability/effect that causes the reduction to max HP. This is almost always powerful magic (i.e., the 5th-level "greater restoration spell or similar magic") or a long rest, the latter particularly for undead (specter, vampire, wight, wraith). However, a DM can interpret "similar magic" or house rule other powerful magic that can immediately restore max HP. For example, the blue slaad's claw and otyugh's bite create diseases that cause max HP reduction, so the 6th-level spell Heal may work since it "ends ... any diseases." Similarly, Heal washes its target in positive energy, so a DM could rule that it restores max HP to characters affected by the "life drain" of undead.
- The energy drain mechanic in AD&D 2e was the loss of entire levels and everything that had come with each (e.g., HP, proficiencies, skills, spells, etc.) while 3e imposed a -1 penalty on all skill and ability checks, attack rolls, and saving throws, -1 prepared spell and spell slot and -5 max HP (-1 HD). There is an EN World forum thread that anecdotally discusses the psychological impact of level and max HP reduction on players.
Targeting the same creature multiple times simultaneously with the same effect causes the creature to be affected still only once
That is, this GM would rule that just because an effect can be used one time against multiple targets doesn't mean that the same effect can instead apply multiple times against one target and yield multiple results.
While it can be technically lawyered that a spell that affects multiple creatures can, instead, affect the same creature multiple times, that notion doesn't yield positive results in actual play (i.e. you'll earn a book to the noggin not applause). And, as you can see from broaching the question here, even bringing up the idea is anathema to some.
To put this negative reaction in perspective, let me employ an analogy: a game show contestant is allowed to pick two cars. While most contestants will pick two different cars, this contestant baffles host and studio audience by picking the same car twice, technically picking two cars: this car and this car again. Although this impresses the game show's lawyers, and the sponsor's pleased at the prospect of only having to provide one vehicle, this makes for lousy ratings. Seriously, don't do this: you don't want to make Drew Carey—or the GM—angry.
That said, the spell mass cure light wounds targets "one creature/level, no two of which can be more than 30 ft. apart." However, once the caster has picked that one creature to be affected, picking that same creature likely runs afoul of of Combining Magical Effects: the creature is supposed to realize simultaneously enough the same spell's effect multiple times, something the game usually either rejects outright or accommodates grudgingly (by mandating only the most recent, most beneficial, or most detrimental effect occurs).
With that in mind, a GM could allow a lone creature to be targeted multiple times by a mass cure light wounds spell then have only the highest individual result affect the target… or even have the target affected uniquely only once, the GM mandating all creatures that the spell would've affected would've been affected equally.
Compare the spell mass cure light wounds with the spell wail of the banshee: the wail targets "one living creature/level within a 40-ft.-radius spread," and "[c]reatures closest to the point of origin are affected first." This does not mean if a Wiz20 catches but two creatures in that 40-ft.-radius spread, the wizard can force those two creatures to make 10 successful Fortitude saving throws each or die! Each affected creature instead makes 1 saving throw, and the remainder of the spell's effect is wasted. (By the way, here's a Paizo messageboard discussion about the spell wail of the banshee.)
This GM urges that unless a spell or effect says otherwise, a decision to use the spell or effect against less than than its maximum number of targets doesn't make the spell or effect's power greater against the targets the spell or effect is used against!
(I could find but this lone 2011 Paizo messageboard thread discussing the idea of picking the same target multiple times for an effect that affects multiple creatures. The topic doesn't seem to warrant serious consideration.)
Best Answer
No, you cannot select a swallowed creature as a target for mass cure wounds.
When a creature is swallowed, e.g. by a remorhaz,
A creature with total cover
Mass cure wounds states
The area of effect here applies only to the choosing, but the spell requires you to select the targets, which total cover prevents.
To put it another way, mass cure wounds is not an area-of-effect spell in the sense that it affects creatures in the area indiscriminately. The 30-foot radius just determines the area from which you may choose eligible targets, and a creature with total cover is an ineligible target because the rules for a creature in total cover say so explicitly.
Note: I linked the Remorhaz statblock for the Swallow action, but if a particular creature's Swallow action does not state that the swallowed creature has total cover, that may change the ruling.