{% if BannerPublicite() is not empty and BannerPublicite().position == 1 and (BannerPublicite().titre != '' or BannerPublicite().text != '') %}
<div class="bloc_top alert" role="alert" style="background-color:{{BannerPublicite().backgoundcolor}};" onmouseover="this.style.color='{{BannerPublicite().colorhover}}';" onmouseout="this.style.color='{{BannerPublicite().color}}';">
<div class="container-fluid wrapper">
{% set link = '' %}
{% if BannerPublicite().typelien == '2' %}
{% set link = BannerPublicite().lieninterne %}
{% elseif BannerPublicite().typelien == '3' %}
{% set link = BannerPublicite().lienexterne %}
{% elseif BannerPublicite().typelien == '4' %}
{% set link = 'tel:'~BannerPublicite().telephone %}
{% endif %}
{% if link != '' %}
<a class="contenu_bloc_pub " href="{{link}}" title="{{BannerPublicite().titre|raw}}" {% if BannerPublicite().typelien == '3' %}target="_blank"{% endif %} onmouseover="this.style.color='{{BannerPublicite().colorhover}}';" onmouseout="this.style.color='{{BannerPublicite().color}}';">
{% else %}
<div class="contenu_bloc_pub " title="{{BannerPublicite().titre|raw}}" onmouseover="this.style.color='{{BannerPublicite().colorhover}}';" onmouseout="this.style.color='{{BannerPublicite().color}}';">
{% endif %}
<span class="pub_cnt">
<span class="titre">{{BannerPublicite().titre|raw}}</span>
<span class="texte">{{BannerPublicite().text|raw}}</span>
</span>
{% if link != '' %}
</a>
{% else %}
</div>
{% endif %}
</div>
<a class="closes" data-bs-dismiss="alert" aria-label="Close" style="color:{{BannerPublicite().color}};">×</a>
</div>
{% endif %}