Explanation on the lineup of SRAM Derailleurs
SRAM's road hierarchy is essentially extremely simple:

Red eTap AXS cf. Shimano Dura-Ace Di2 (1/2 x 12 electronic vs 2 x 11 electronic)
Force eTap AXS cf. Shimano  Ultegra Di2 (1/2 x 12 electronic vs 2 x 11 electronic)
Force cf. Shimano  Ultegra (both 2 x 11 mechanical)
Rival cf. Shimano  105  (both 2 x 11)
Apex cf. Shimano  Tiagra (both 2 x 10)

That's it. Five levels, no more, no less.
Other things mentioned:

eTap without the AXS, is simply old 11-speed Etap. It's not a separate level.
Red without the eTap is obsolete - SRAM deem their top kit is all-electronic. They don't make 12-speed road gear that's not electronic. Red is the former top-of-the-line mechanical, but is now outside the hierarchy. Formerly it would have been above Force mechanical, and below Red Etap.
S is not a groupset. It refers to odd parts (e.g., flat bar shifters for road groupsets, or triathlon levers) that are different quality levels. 900 = Red, 700 = Force, 500 = Rival/Apex.
the '1' designation is not a different quality level per se, but for example 'Apex 1' refers to a 1 x 11 system, which is of 'Apex' quality level but more expensive as it had hydrualic disc brakes, which is a feature, not a groupset level per se.

Other designations:

HRD - hydraulic disc brake
HRR - hydraulic rim brake

Note that SRAM offer discounts on their Rockshox suspension for MTB kit if specifying their drivetrain, but for road they are not as attractive as Shimano except at the 'eTap AXS' level, as that is wireless whereas Di2 is not. In addition, their 1 x 11 drivetrain is sometime specified as it may offer gear/brake combinations that Shimano do not.
Sram's MTB hierarchy is more complicated.
Previously:

XX - 2x 10-speed (hence XX) - renamed to XX1 after switch to 11-speed, 10-42t 1x
X.0 - 9-speed, later 10-speed - renamed to X01 after switch to 11-speed https://www.pinkbike.com/news/sram-x01-drivetrain-explained.html
X.9 - 9-speed - upgraded to 10-speed
X.7 - 9/8-speed - upgraded to 10-speed
X.5 - 9-8-speed - later also upgraded to 10-speed
X.4 - 8-speed
X.3 - 7-speed

X1 was a much cheaper 11-speed system:
https://www.pinkbike.com/news/sram-x1-drivetrain-first-ride.html
then GX below that
https://www.pinkbike.com/news/sram-gx-drivetrain-review-2015.html
So you had:

XX1
X01 - only slightly cheaper
X1
GX

then NX below that, with the major cost saving of not using a 10t cassette, only an 11t one.
https://www.pinkbike.com/news/sram-announces-nx-1x11-drivetrain-2016.html
When Shimano moved to 12-speed it didn't change much, but they called everything Eagle.
This results in this hierarchy:

XX1 Eagle (with or without AXS), formerly XX1 and XX
X01 Eagle (with or without AXS), formerly X01 and X.0. Also X01 DH.
GX Eagle formerly GX and X.9. Also GX DH.
NX Eagle, formerly NX, and X.7
SX Eagle, formerly X.5
X.4
X.3

Note that that is 5 12-speed groupsets, where 3 use SRAM's 10t freehub, and 2 do not.
There is also EX1, which is priced between X01 and GX, but is 8-speed specifically designed for e-bikes.
By comparison, Shimano:

XTR
Deore XT
SLX
Deore

are four levels of 12-speed with a 10t cassette/freehub
Shimano's 11-speed Deore probably maps closely to NX &amp; SX Eagle, in that it has an 11-51t cassette, whereas those use 11-50t.
Shimano sell both lighter and heavier components for XTR, depending on your goals (e.g. 4-piston and 2-piston brakes).
So XX1 AND X01 both roughly map to XTR, while GX Eagle is doing the work of THREE Shimano groupsets (XT, SLX, Deore-12 speed). GX Eagle corresponds to Shimano Deore/SLX (which aren't very far apart)
Note that Shimano have dumped Di2 for MTBs, so they have nothing to match AXS for MTBs.
Because SRAM released 12-speed before Shimano and grabbed lots of market share, they have milked their 'Eagle' brand by releasing steadily lower quality/cheaper 12-speed groupsets. SX Eagle is probably around Shimano's Alivio/Acera quality levels. Shimano don't need to make cheap 12-speed kit, as their 9-speed kit is very popular on new bikes, whereas SRAM is not. People looking for an alternative to Shimano for 9-speed bikes tend to spec Microshift.