@if (@$cta)
@php $image = isset($cta['image']) ? url('storage/cta/'.$cta['image']) : asset('assets/img/content/header-template-003.jpg'); @endphp
<section class="c-cta" style="background-image: url({{$image}});">
    <div class="container">
        <div class="c-cta__content">
            <h2 class="c-cta__title">{{$cta['titulo']}}</h2>
            {!! $cta['description'] !!}
            @if ($cta['btncta'] != '')
            @php
                $target = ($cta['target'] == 1) ? "target=_blank": (($cta['target'] == 2) ? "data-toggle=modal data-target=#modalCta" : '');
            @endphp

            <a class="c-button" {{ $target }}
                href="{{$cta['btnlinkcta']}}"
                style="background-color:  {{ ($cta['bt_color'] != '') ? $cta['bt_color'] : '#F8FA9E' }}; color: #1a3a4c; border-color: transparent;"
                onMouseOver="this.style.backgroundColor='#1a3a4c'; this.style.color='{{ ($cta['bt_color'] != '') ? $cta['bt_color'] : '#F8FA9E' }}'; this.style.borderColor='{{ ($cta['bt_color'] != '') ? $cta['bt_color'] : '#F8FA9E' }}'"
                onMouseOut="this.style.backgroundColor='{{ ($cta['bt_color'] != '') ? $cta['bt_color'] : '#F8FA9E' }}'; this.style.color='#1a3a4c'; this.style.borderColor='{{ ($cta['bt_color'] != '') ? $cta['bt_color'] : '#F8FA9E' }}'">{{$cta['btncta']}}</a>
            @endif
        </div>
    </div>
</section>
@endif

