@foreach($offices as $key => $office)
    <div class="office-tile" data-office-id="{{ $office->id }}">
        <h2 class="name {{$office->is_headquarter ? 'headquarter' : ''}}">
           {{$office->title}}
        </h2>
        <div class="address p-margin-top light-italic">
           {!! $office->content !!}
        </div>
        @if($office->contact)
            <h3 class="contact-margin">@lang('frontend.at_this_office')</h3>
            @if($office->contact->image)
                <div class="avatar-holder">
                    {!! getMediaImg($office->contact->image, '200x200', htmlspecialchars($office->contact->name)) !!}
                </div>
            @endif
            <span class="contact-name">{{$office->contact->name}}</span>
            <span class="contact light-italic">
                <a
                    href="#"
                    class="contact-open"
                    data-name="{{  $office->contact->name }}"
                    data-contact="{{ base64_encode(json_encode(["Contact_person" => $office->contact->name ])) }}"
                    data-controller="components/form-modal"
                    data-popupid="contact-us-modal"
                >
                    Contact
                </a>
            </span>
        @endif
    </div>
@endforeach
