This team is built around an offensive core of Calm Mind Arceus-Ground + Mega Gengar. With a set of Substitute, Perish Song, and Disable, Mega Gengar can trap a number of Arceus-Ground checks, including Chansey and Pokemon including defensive Ho-oh, Ferrothorn, and Celesteela that generally only carry one attacking move. Support Primal Groudon checks Primal Kyogre, one of the biggest offensive checks to Arceus-Ground, and greatly annoys most Defoggers with Dragon Tail + Toxic. Magearna gives us a solid backbone against threats like Geomancy Xerneas and Yveltal, provides VoltTurn support to get Mega Gengar in safely, and cleric support which is especially valuable for Arceus-Ground/Giratina/Primal Groudon, since many teams rely on indirect damage to break them down. Giratina should be used as the primary switch-in to Primal Groudon, as Arceus-Ground's lack of bulk investment means that it won't stomach Eruptions/Overheats very well and it doesn't like being statused with Toxic either. Giratina does a pretty good job of eating attacks/status from Pokemon like Primal Groudon, Ho-Oh, and physical Primal Kyogre and resting them off; it's chosen over Giratina-O because of its higher bulk letting it tank hits from the latter two, and over Zygarde because of its access to Defog. Choice Scarf Yveltal fits nicely in the last slot, providing a crucial Ghost-type resistance for our two Ghost-weak Pokemon, a Ground immunity, more VoltTurn support for Mega Gengar, and it's able to revenge kill Marshadow and fast threats that outspeed Mega Gengar such as MM2Y/Choice Scarf Lunala that are otherwise very threatening to the team.
Sets: Hex on Mega Gengar is used over Shadow Ball for the increased damage output on statused foes, such as a poisoned Arceus-Fairy. Dragon Dance users like Zygarde/Mega Salamence/Rayquaza are somewhat difficult for the team to properly handle due to Arceus-Ground's lack of bulk investment, so Groudon is a support variant with Dragon Tail that can prevent them from trying to set up on it. Will-O-Wisp is run on Giratina over Roar; although this can be detrimental against Substitute users and Facade Mega Salamence, it's instrumental for punishing hazard setters like Ferrothorn and support Necrozma-DM (Ferrothorn can even be used as setup fodder by Arceus-Ground once it's burned). Although the bulky Scarf set is tempting on Yveltal to take hits better, max Special Attack with Oblivion Wing is needed to revenge kill Marshadow reliably. Scarf Toxic is useful to poison stuff in a pinch, and punish checks like Arceus-Fairy and Xerneas concretely, since due to lack of a Poison-type move on Mega Gengar, it can be hard to apply immediate pressure to them.
Notes: Having 2 Ghost-types + Magearna as our Fairy-type makes Marshadow very threatening to the team, Life Orb/Z-move variants can easily claim a kill if not played around properly. Arceus-Ground is 2HKOed by Spectral Thief into Close Combat from Life Orb variants, so in general it should not be used as a switch-in.