@extends('layouts.store') @section('content') @php $currency = $s->currency_code ?? '$'; $total = $products->total(); $hasFilters = filled($q ?? null) || filled($cat ?? null) || filled($collection ?? null) || filled($min ?? null) || filled($max ?? null); @endphp {{-- ===== Top bar ===== --}}

{{ __('messages.Shop') }}

{{ trans_choice('messages.products', $total, ['count' => $total]) }} @if($hasFilters) • {{ __('messages.FiltersApplied') }} @endif
{{-- keep other query params when changing sort --}} @foreach(request()->except(['sort','page']) as $k => $v) @if(is_array($v)) @foreach($v as $vv)@endforeach @else @endif @endforeach
{{-- ===== Sidebar filters (desktop) ===== --}} {{-- ===== Main content ===== --}}
@include('store.partials.shop-product-grid', [ 's' => $s, 'products' => $products, 'categories' => $categories, 'collections' => $collections, 'q' => $q, 'cat' => $cat, 'collection' => $collection, 'min' => $min, 'max' => $max, 'sort' => $sort, 'currency' => $currency, ])
{{-- ===== Offcanvas Filters (mobile) ===== --}}
{{ __('messages.Filters') }}
@include('store.partials.filters-card', [ 'q' => $q, 'cat' => $cat, 'collection' => $collection, 'min' => $min, 'max' => $max, 'sort' => $sort, 'categories' => $categories, 'collections' => $collections, 'isOffcanvas' => true ])
@include('store.partials.shop-modals-scripts', ['currency' => $currency]) @endsection