{# Style du bouton #}
{% set sectionId = ('#'~section(content).id|raw) %}
{% set section = section(content) %}
{% set title = title(content) %}
{% set button = button(content) %}
{{ sectionId }} .button{
display: block;
text-align: center;
{% if button.radius.value is defined and button.radius.value != 0 %}border-radius: {{ (button.radius.value~button.radius.unit)|raw }};{% endif %}
{% if button.color is defined and button.color is not empty %}
{% if button.inverseColor is defined and button.inverseColor == true %}
background-color: {{ (button.secondaryColor)|raw }};
{% else %}
background-color: {{ (button.color)|raw }};
{% endif %}
border: 2px solid {{ (button.color)|raw }};
{% endif %}
{% if button.secondaryColor is defined and button.secondaryColor is not empty %}
{% if button.inverseColor is defined and button.inverseColor == true %}
color: {{ (button.color)|raw }};
{% else %}
color: {{ (button.secondaryColor)|raw }};
{% endif %}
{% endif %}
{% if button.weight is defined and button.weight != 0 %}font-weight: {{ (button.weight)|raw }};{% endif %}
{% if button.margin is defined %}{{ margins(button.margin.unit, button.margin.top, button.margin.right, button.margin.bottom, button.margin.left) }}{% endif %}
{% if button.padding is defined %}{{ paddings(button.padding.unit, button.padding.top, button.padding.right, button.padding.bottom, button.padding.left) }}{% endif %}
{% if button.textAlign is defined and button.textAlign != 'center' %}text-align: {{ (button.textAlign)|raw }} !important;{% endif %}
{% if button.isUnderlined is defined and button.isUnderlined == true %}text-decoration: underline !important; width: 100%;{% endif %}
}
{% if button.isUnderlined is not defined or button.isUnderlined == false %}
{{ sectionId }} .button:hover{
{% if button.secondaryColor is defined and button.secondaryColor is not empty %}
{% if button.inverseColor is defined and button.inverseColor == true %}
background-color: {{ (button.color)|raw }};
{% else %}
background-color: {{ (button.secondaryColor)|raw }};
{% endif %}
{% endif %}
{% if button.color is defined and button.color is not empty %}
{% if button.inverseColor is defined and button.inverseColor == true %}
color: {{ (button.secondaryColor)|raw }};
{% else %}
color: {{ (button.color)|raw }};
{% endif %}
{% endif %}
}
{% endif %}
{{ sectionId }} .button.flying-button{
padding: 0;
}