Button with variable dimensions, based on entity state

Hi, I’m working on controlling my shutters via Home Assistant. I have two button cards that move all of the shutters. One for up and one for down. I’d like these buttons to dynamically change size based on a boolean input (sun over horizon / time of day). So in the morning the “shutters up” button should be nine columns wide and the “shutters down” button only three columns wide and in the evening vice versa.

I could build this with four buttons, one wide and one narrow of each and always hide the ones not in use right now but I’d like to avoid code duplication wich this essentially is. Can I use some kind of conditional within the grid_options block in the yaml to change the width? I don’t have much experience with yaml for now and am still rather confused by it.

I would greatly appreciate if anyone could help me with that!

Please post your current code. It will help expedite a resolution.