A few CSS tweaks are all it takes to customise a standard Lovelace card. You can recolour states, adjust spacing, round corners, and more without creating a custom card. Use card-mod.
It lets you drop plain CSS into almost any built-in card via a card_mod block, so you get the look you want without reinventing the card. Install it through HACS, then keep shared styling in a theme rather than repeating it on every card.
type: entitiesentities:- light.officecard_mod:style: |ha-card {border-radius: 16px;box-shadow: none;}
Styling is cheap to add and easy to overdo. A few habits keep dashboards fast and stable:
ha-card { {% if ... %} }) forces the browser to destroy and rebuild its CSS parser tree on every update. Process the logic up front into variables insteadelse fallback (e.g. border: 2px solid transparent). This avoids a sudden 2px layout shift when the condition togglesborder-color, not the border shorthand, so the work runs on the GPU instead of forcing a CPU layout recalculationdisplay: none) instead to keep the layout snappy