@extends('layouts.app') @section('content')
@foreach($sliders as $slider)
{{-- Imagen para móviles --}} {{-- Imagen para desktop (por defecto) --}} {{ $slider->title }} @if($slider->show_caption) @php $locale = App::getLocale(); $sliderTitle = $slider->getTranslation('title', $locale, false); $sliderDescription = $slider->getTranslation('description', $locale, false); @endphp @if($sliderTitle)

{{ $sliderTitle }}

@if($sliderDescription)

{{ $sliderDescription }}

@endif
@endif @endif
@endforeach

{{ App::getLocale() == 'es' ? '. nuestros programas' : '. our programs' }}

@foreach($projects as $project) @php $locale = App::getLocale(); $projectTitle = $project->getTranslation('title', $locale, false); $projectRegion = $project->getTranslation('region', $locale, false); $projectCountry = $project->getTranslation('country', $locale, false); @endphp @if($projectTitle)
@if($projectRegion || $projectCountry)
@if($projectRegion){{ $projectRegion }}@endif @if($projectRegion && $projectCountry)
@endif @if($projectCountry){{ $projectCountry }}@endif
@endif

{{ $projectTitle }}

@if($project->estimated_cost)
{{ App::getLocale() == 'es' ? 'Costo estimado: $' : 'Estimated Cost: $' }}{{ $project->estimated_cost }}
@endif
@endif @endforeach
@if($homeSection && $homeSection->tabs) @php $locale = App::getLocale(); $filteredTabs = collect($homeSection->tabs)->filter(function ($tab) use ($locale) { return !empty($tab['title'][$locale] ?? null) && !empty($tab['content'][$locale] ?? null); }); @endphp @foreach($filteredTabs as $tab)

{{ $tab['title'][$locale] ?? '' }} >

@endforeach @endif
@if($homeSection) @php $locale = App::getLocale(); $hasDestacadoTitle = !empty($homeSection->getTranslation('destacado_title', $locale, false)); $hasDestacadoContent = !empty($homeSection->getTranslation('destacado_content', $locale, false)); @endphp @if($hasDestacadoTitle && $hasDestacadoContent)
{{ $homeSection->getTranslation('destacado_title', $locale, false) }}
@if($homeSection->destacado_image) @endif
{!! $homeSection->getTranslation('destacado_content', $locale, false) !!}
@endif @endif
@if($homeSection && $homeSection->tabs) @php $locale = App::getLocale(); $filteredTabs = collect($homeSection->tabs)->filter(function ($tab) use ($locale) { return !empty($tab['title'][$locale] ?? null) && !empty($tab['content'][$locale] ?? null); }); @endphp @foreach($filteredTabs as $tab)

{{ $tab['title'][$locale] ?? '' }}

{!! $tab['content'][$locale] ?? '' !!}
@endforeach @endif
@endsection