Lovelace: Button card

Using layout-card in a custom:button-card ? that is new to me, and seems a bit clumsy, when button-card has all the options to place the elements wherever we need them?

the trick I use from that class combination, is that the translateX is defined to the marquee class, which itself is inside the .wrapper.

without that .wrapper the traslateX overflows the name element itself, and with that, the paddings of the card itself.

keeping the marquee inside that wrapper, allows us to place it correctly.
that is why I decided to set the exact positioning on that element.

making the marquee properties truly dependent on the length and size of the screen (available space in the elements on Mobile and Desktop to name but 1 variable) would require a lot more work, and for this button that is overdoing it.

it is possible, and I have a few that do use that, see this How to make scroll-time/speed and TranslateX string length dependent in css animation - #14 by Mariusthvdb for some background…