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.
This Dhampir race is effectively a weaker version of a Drow, so I'll compare it to that.
- Ability Score Increase: The Dhampir gets to choose between the ability score bonuses of the Drow and those of the Dragonborn. This is perfectly in line with existing races.
Stuff the Dhampir gets:
Age & Alignment: Don't really matter from a balance perspective.
Size: The same as everyone else.
Speed: The same as almost everyone else, including the Drow.
Superior Darkvision: The same as the Drow.
Sunlight Sensitivity: The same as the Drow.
Dhampir Magic: The Dhampir gets a 1st level spell 1/day at 1st level, and a 2nd level spell 1/day at 3rd level. The Drow gets a cantrip, a 1st level spell 1/day at 3rd level, and a 2nd level spell 1/day at 5th level. This is the first real difference between the two. The Dhampir gets their racial spells 2 levels earlier, which is obviously stronger up until 5th level when it stops mattering. Not getting a free cantrip goes a fair way towards balancing this out, though.
Vampiric Heritage: I'll come back to this.
- Vampire Weaknesses: If you're incapacitated in a place of rest, you're probably asleep. It's pretty easy to kill someone who's asleep in general, so this doesn't really change much. There might be niche cases where it really comes into play but most of the time it shouldn't matter much.
Languages: Common and one other, just like every other race. The freedom to choose is nice, but hardly imbalancing.
Stuff the Dhampir doesn't get that the Drow does:
- Keen Senses: Free proficiency in the most important skill in the game. This is pretty strong.
Fey Ancestry: Advantage on saving throws against some of the most dangerous spells in the game, and immunity to the Sleep spell. This is also pretty strong.
Trance: Depending on your group and your DM, this might be important, but for most players, it's not going to matter a whole lot.
Drow Weapon Training: This is kind of nice, but most builds that need weapon proficiencies involve a class that gives them, so it's not that nice.
Overall, the Dhampir is probably a weaker version of the Drow. Their racial magic trait is a little better before level 5, but after that it's the same, minus a cantrip. Now for the elephant in the room.
Vampiric Heritage
Whenever you grapple, incapacitate, or restrain a creature, you gain the ability to bite that creature dealing 1d6 piercing damage. Furthermore, you can spend your turn drinking the blood of that creature, causing it to loss [sic] 1d6 necrotic damage. The creature's hit point maximum is reduced by an amount equal to the necrotic damage taken, and you regains [sic] hit points equal to that amount. The reduction lasts until the creature finishes a long rest, it dies if this effect reduces its hit point maximum to 0.
The problem with this is "the ability to bite that creature dealing 1d6 piercing damage". Does this require an action? A bonus action? No action at all? Does it give you the ability to do that when you grapple them, or anytime while you're grappling them? It doesn't really give us anyway to know.
The good news is that it doesn't really matter. Unless it requires no action and is anytime while you're grappling them, this is a pretty weak ability. If it's free when you grapple them, you can grapple, bite, let go, grapple, bite, let go and so on up to 4 times (if you're a Fighter). Except that you're just dealing 1d6 damage, so you'd have been better off attacking normally. Assuming your Strength score is 16 or higher, you'd have been better off punching them!
It only gets worse with other interpretations, too. If it requires an action and you can do it anytime while grappling, you're effectively using a turn to deal 1d6 damage, which is pretty much a joke.
Moving along to the other half of the ability, we have the ability to spend your turn drinking the blood of a creature. It's pretty clear what "spend your turn" means, and it makes for a pretty useless ability. Using your entire turn to deal 1d6 damage and gain 1d6 hit points might be ok at level 1 but it's going to become a joke pretty quickly.
The reducing maximum hit points part is useless because if you do enough damage to kill them with it, they would have died anyway. In general, D&D characters want to kill things, not inconvenience them. It could be used as a way to prevent an enemy regaining hit points, but there's a cantrip that does the job better and more efficiently.
So, overall, the Dhampir is pretty much a weakened version of the Drow race with some unique but useless features.
Best Answer
Yes, a vampire's bite can sometimes effectively deal extra damage due to temporary hit points
Damage to temporary HP still counts as damage
Per this Jeremy Crawford Tweet:
So, when the bite ability says "hit point maximum is reduced by an amount equal to the necrotic damage taken" that means that max HP will be reduced by the amount of damage done regardless of temp HP.
Your example
In your example, your maximum HP is 20. Your current HP will also start at 20 since you have taken no damage before this. You also start with 20 temporary HP from some spell or effect.
Starting condition
Max HP: 20
Curr. HP: 20
Temp. HP: 20
So, you take 5 piercing damage and 10 necrotic damage.
Max HP: 20
Curr. HP: 20
Temp. HP: 20 - 5 (piercing) - 10 (necrotic) = 5
Then, because of the vampire bite, your maximum HP is reduced by 10.
Max HP: 10
Curr. HP: 10
Temp. HP: 5
And because your maximum HP drops below your current HP, your current HP immediately drops with it. This is because current HP can never exceed max HP:
In this case then, a **vampire's bite, will do additional damage to your HP because of the HP drain and the fact that you had temporary HP.
Specifically it did:
5 (piercing)
10 (necrotic)
10 (HP drain)
= 25 damage
A creature without temp HP would have taken 15 damage. So, yes a creature with temp HP in this case actually effectively takes more damage than a creature without.
Temporary HP is not affected by HP drain since it is independent of max HP.
Official ruling
Jeremy Crawford has agreed with this interpretation in this tweet:
Note that I have been referring to the HP maximum reduction as "damage". I do not mean damage in the technical sense (eg effects that depend on "you take damage") but in the common sense that you lost HP thus it is effectively damage.