@php $siteTitle = 'Portal'; $descricao = ''; try { $portalConfigs = app(\V2\Modules\Support\SupportConfigs\Services\PortalConfigsService::class)->getAll(); $siteTitle = $portalConfigs['titulo_site'] ?? 'Portal'; $descricao = $portalConfigs['descricao'] ?? ''; } catch (\Exception $e) {} @endphp @extends('v2-portal::app-layout', [ 'pageTitle' => $siteTitle ? "$siteTitle — Página Inicial" : 'Página Inicial', 'pageDescription' => $descricao ?? '', 'coverImage' => null, 'gtag' => ['page_context' => 'homepage'], 'schemas' => [ [ '@context' => 'https://schema.org', '@type' => 'Organization', 'name' => $siteTitle ?? 'Portal', 'url' => url('/') ] ], 'showAccessibilityBar' => false, 'stickyAccessibilityBar' => false, 'showHeader' => false, 'showMainHeader' => false, 'showMainFooter' => false, 'showFooter' => false, 'showMainLeftArea' => false, 'showMainRightArea' => false, 'fullWidthMain' => true ]) @section('main-section-area') @php $sections = []; if (!empty($layoutConfigs) && $layoutConfigs->has('landing_sections')) { $config = $layoutConfigs->get('landing_sections'); $sections = is_object($config) && isset($config->payload) ? $config->payload : []; } @endphp @if(!empty($sections)) {{-- ================================================================ --}} {{-- Hero Slider --}} {{-- ================================================================ --}} @if(!empty($sections['hero']))
@foreach($sections['hero'] as $slide)
@php $slideVariants = []; if (!empty($slide['image'])) { $media = \V2\Services\Gallery\Models\GalleryMedia::where('file_path', $slide['image'])->first(); if ($media && !empty($media->variants)) { $slideVariants = json_decode($media->variants, true) ?: []; } } @endphp
@if($loop->first)

{{ $slide['title'] }}

@else

{{ $slide['title'] }}

@endif

{{ $slide['subtitle'] }}

@if(!empty($slide['cta_text'])) @endif
@endforeach
@endif {{-- ================================================================ --}} {{-- Service Cards (Networking, Conteúdo, Representatividade) --}} {{-- ================================================================ --}} @if(!empty($sections['services']))
@foreach($sections['services'] as $service)
@if(!empty($service['icon']))
{{ $service['title'] }}
@endif

{{ $service['title'] }}

{{ $service['description'] }}

@endforeach
@endif {{-- ================================================================ --}} {{-- About + Counters --}} {{-- ================================================================ --}} @if(!empty($sections['about'])) @php $about = $sections['about']; $aboutVariants = []; if (!empty($about['image'])) { $aboutMedia = \V2\Services\Gallery\Models\GalleryMedia::where('file_path', $about['image'])->first(); if ($aboutMedia && !empty($aboutMedia->variants)) { $aboutVariants = json_decode($aboutMedia->variants, true) ?: []; } } @endphp
{{ $about['subtitle'] ?? '' }}

{{ $about['title'] ?? '' }}

> @if(!empty($about['counters']))
@foreach($about['counters'] as $counter)
@if(!empty($counter['icon']))
{{ $counter['label'] }}
@endif

{{ $counter['value'] }}{{ $counter['suffix'] ?? '' }}

{{ $counter['label'] }}

@endforeach
@endif

{{ $about['description'] ?? '' }}

@if(!empty($about['cta_text'])) @endif
@endif {{-- ================================================================ --}} {{-- Brand Carousel --}} {{-- ================================================================ --}} @if(!empty($sections['brands']))
@if(!empty($sections['brands_title']))

{{ $sections['brands_title'] }}

@endif
@foreach($sections['brands'] as $brand)
{{ $brand['name'] }}
@endforeach
@endif {{-- ================================================================ --}} {{-- Agenda / Events --}} {{-- ================================================================ --}} @if(!empty($sections['events']))
{{ $sections['events_subtitle'] ?? 'Agenda SUCESU' }}

{!! $sections['events_title'] ?? 'Acompanhe os eventos' !!}

@foreach($sections['events'] as $event)
@if(!empty($event['image']))
{{ $event['title'] }}
@endif

{{ $event['title'] }}

{!! $event['details'] ?? '' !!}

Saiba mais
@endforeach
@endif {{-- ================================================================ --}} {{-- Regionais --}} {{-- ================================================================ --}} @if(!empty($sections['regionais'])) @php $reg = $sections['regionais']; @endphp
{{ $reg['subtitle'] ?? '' }}

{{ $reg['title'] ?? '' }}

{{ $reg['text1'] ?? '' }}

@if(!empty($reg['states']))

{{ $reg['states'] }}

@endif

{{ $reg['text2'] ?? '' }}

@if(!empty($reg['cta_text'])) @endif
{{ $reg['subtitle'] ?? '' }}
@endif @else {{-- ================================================================ --}} {{-- Fallback: gov/default tenant sem landing_sections --}} {{-- ================================================================ --}}

Bem-vindo ao Portal

Portal oficial de serviços e informações.

@endif @endsection