Title of Horizontal Stack vs vertical-stack-in-card

Why look of title of Horizontal stack is so inconsistent with other cards?

As you can see title is rendered outside the card, directly on the GUI background.
All other cards renders title on the card background being a part of the card.

Here are the same sensors but displayed using custom:vertical-stack-in-card card.

Unfortunately there is another drawback: there is no spacing between cards. is it possible somehow to
achieve the both from those two cards: title like in the second one and spacing like in the first one?

Both vertical and horizontal stacks put the title outside the card. It’s the only way to get a title outside the card. It makes sense because stacks are a series of cards, where would you put a title for a series of separate cards?

The vertical-in-stack card is a custom card that takes x number of cards and turns them into a single card, hence why the title is inside the card.

If you want to add spacing inside the vertical-in-stack-card, then you should use card mod and add padding to each card.