@if ($type == 'movie')
<article id="{{ $item->id }}" class="item {{ $class }}">
    <div class="thumb mb-4">
        <a href="{{ mopie_route('movie.single',['id' => $item->id, 'slug' => str_slug($item->original_title)]) }}" rel="bookmark" title="{{ $item->title }} ({{ to_year($item->release_date ?? '') }})">
            <div class="_img_holder">
                <img class="img-fluid rounded" src="{{ img_poster($item->poster_path) }}" alt="Image {{ $item->title }}" title="Image {{ $item->title }} ({{ to_year($item->release_date ?? '') }})">
                <div class="type {{ $type }}">{{ $type }}</div>
                <div class="_overlay_link">
                    <button class="play-button play-button--small" type="button"></button>
                    <div class="rate"><i class="fa fa-star text-warning"></i> <span class="small text-white">{{ $item->vote_average }}/10</span></div>
                </div>
            </div>
        </a>
        <header class="entry-header">
            <h2 class="entry-title">
                <a href="{{ mopie_route('movie.single',['id' => $item->id, 'slug' => str_slug($item->original_title)]) }}" class="_title" rel="bookmark" title="{{ $item->title }} ({{ to_year($item->release_date ?? '') }})">{{ $item->title }} ({{ to_year($item->release_date ?? '') }})</a>
            </h2>
        </header>
    </div>
</article>
@elseif ($type == 'tv')
<article id="{{ $item->id }}" class="item {{ $class }}">
    <div class="thumb mb-4">
        <a href="{{ mopie_route('tv.single',['id' => $item->id, 'slug' => str_slug($item->original_name)]) }}" rel="bookmark" title="{{ $item->name }} ({{ to_year($item->first_air_date) }})">
            <div class="_img_holder">
                <img class="img-fluid rounded" src="{{ img_poster($item->poster_path) }}" alt="Image {{ $item->name }}" title="Image {{ $item->name }} ({{ to_year($item->first_air_date) }})">
                <div class="type {{ $type }}">{{ $type }}</div>
                <div class="_overlay_link">
                    <button class="play-button play-button--small" type="button"></button>
                    <div class="rate"><i class="fa fa-star text-warning"></i> <span class="small text-white">{{ $item->vote_average }}/10</span></div>
                </div>
            </div>
        </a>
        <header class="entry-header">
            <h2 class="entry-title">
                <a href="{{ mopie_route('tv.single',['id' => $item->id, 'slug' => str_slug($item->original_name)]) }}" class="_title" rel="bookmark" title="{{ $item->name }} ({{ to_year($item->first_air_date) }})">{{ $item->name }} ({{ to_year($item->first_air_date) }})</a>
            </h2>
        </header>
    </div>
</article>
@else
<article id="{{ $item->id }}" class="item {{ $class }}">
    <div class="thumb mb-4">
        <a href="{{ mopie_route('people.single', ['id' => $item->id]) }}" rel="bookmark">
            <div class="_img_holder">
                <img class="img-fluid rounded" src="{{ img_poster($item->profile_path) }}" alt="Image {{ $item->name }}">
                <div class="type {{ $type }}">{{ $type }}</div>
                <div class="_overlay_link">
                    <div class="rate"><i class="fa fa-star text-warning"></i> <span class="small text-white">{{ $item->popularity }}</span></div>
                </div>
            </div>
        </a>
        <header class="entry-header">
            <h2 class="entry-title">
                <a href="{{ mopie_route('people.single', ['id' => $item->id]) }}" class="_title" rel="bookmark">{{ $item->name }}</a>
            </h2>
        </header>
    </div>
</article>
@endif