The Encounter is in line with what a Deadly encounter is described to be in the DMG
TL;DR: There is a moderate chance of one PC being instantly killed by a upcasted inflict wounds that can't easily be mitigated, but the party will almost certainly win the encounter unless suitably injured coming in, making it in line with a standard Deadly encounter. It's not unbalanced from a fight design, it just is designed to have a chance kill a PC with no player agency. If you want to fix it, start the PCs at 20' away from the fanatic.
A Deadly encounter is described as:
A deadly encounter could be lethal for one or more player characters. Survival often requires good tactics and quick thinking, and the party risks defeat.
Upon first inspection, the cult fanatic is scary: it can cast second level inflict wounds three times-- potentially making a PC unconscious or even instantly dead three times. The problem is with its 13 AC and 33 HP, it simply can't take any punishment and in our particular case: can be easily kited-- take away inflict wounds and suddenly the encounter becomes trivialized.
In fact I wrote a script to simulate this combat versus a tactic-less naive group of 4 melee fighters-- about the worse case scenario. Keep in mind all the players have to do is stay 20 feet away and shoot at range and the damage CR of the fanatic is reduced from CR3 to CR1 (10 dps/turn from spiritual weapon and sacred flame), that with its already Defensive CR1 nature, all the party has to do is end their turn 20' away from it and the fanatic is identical to a CR1 creature. A cast of Entangle, Grease, Command, Earth Tremor etc. solves the combat.
The details of the simulation are below, but here are the results of 100000 runs.
Average Number of Rounds: 2.59
Average Number of PCs Unconscious: .487
Average Number of Dead PCs: .136
Win Chance for PCs: 99.5%
The only problem, as you mention, is the fanatic gets a lucky Inflict Wounds that hits and does high damage. A 13.5% of killing a PC I think is very much in line with the description above of a deadly encounter-- and remember this is the naive, melee only party that can't cast spells and is almost unoptimized: your party is almost certainly build wise more effective than this. If you want to make any changes, swap out inflict wounds for a lower burst option that still engages the party like Grease or Earth Tremor.
Simulation Details: 4 fighters with 16 in Strength and 16 in Con, wearing chain mail and a shield, wielding a longsword with the Dueling fighting style for 1d8+3+2 damage. The cultists attack the fighter that's last in initiative, and the fighters burn down the fanatic and then the cultist. Note: even if you remove Dueling, the chances of character death only rises by about 4% and the winrate drops around 1%.
We can feel decently confident in our results as this makes sense: turn 1, 3 fighters deal 3d8+9 damage with a +5 to hit, turn 2: 2 fighters deal 2d8+6-- even in the best case scenario, with the fanatic killing a fighter per turn (incredibly unlikely), the fighters still have a 20% chance of killing the fanatic. Add in dueling and the odds are 87%.
*Note: In response to comments, it was asked what if the minor threat, the cultist was focused first: this gives the cult fanatic a better chance at hitting with a lethal inflict of wounds, changing rounds to 2.60, KOs to 0.637, deaths to 0.182, and win chance to 99.2%
If your party is Level 2 like you mentioned, our simulation gives us average player deaths to be 0.0722.