@extends('layouts.app') @section('title', __('Магазин - WoW Rebirth')) @php $breadcrumbs = [ ['title' => __('Главная'), 'url' => route('welcome')], ['title' => __('Магазин'), 'url' => route('shop.index')], ]; @endphp @section('content')
{{-- Top User Panel --}}
@auth {{ __('Ваш баланс:') }}
{{ __('Coal') }} {{ $currencies['Coal']->amount ?? 0 }}
{{ __('Feather') }} {{ $currencies['Feather']->amount ?? 0 }}
{{ __('Ashes') }} {{ $currencies['Ashes']->amount ?? 0 }}
{{ __('Пополнить') }} @else
{{ __('Войдите') }}, {{ __('чтобы увидеть баланс и совершать покупки.') }}
@endauth
@if(request('realm_id') && request('character_guid')) {{-- Left Column: Categories --}}

{{ __('Категории') }}

@endif {{-- Right Column: Products/Controls --}}
{{-- Unified Controls Panel --}}
{{-- Realm Select --}}
{{-- Character Select --}} @if(request('realm_id'))
@endif {{-- Search --}} @if(request('realm_id') && request('character_guid'))
{{ __('Сброс') }}
@endif
@if(Auth::check() && request('realm_id') && request('character_guid'))
@include('pages.shop.partials._mini_cart')
@if($categories->flatMap->products->isNotEmpty() || $categories->flatMap->children->flatMap->products->isNotEmpty()) @foreach($categories as $category) {{-- Render products for the parent category --}} @if($category->products->isNotEmpty())

{{ __($category->name) }}

@foreach($category->products as $product) @include('pages.shop.partials.product_row', ['product' => $product]) @endforeach @endif {{-- Render products for child categories --}} @if($category->children->isNotEmpty()) @foreach($category->children as $child) @if($child->products->isNotEmpty())

{{ __($child->name) }}

@foreach($child->products as $product) @include('pages.shop.partials.product_row', ['product' => $product]) @endforeach @endif @endforeach @endif @endforeach @else
{{ __('В данной категории или по вашему запросу ничего не найдено.') }}
@endif
@elseif(Auth::check() && request('realm_id'))
{{ __('Пожалуйста, выберите персонажа, чтобы увидеть доступные товары.') }}
@else
{{ __('Пожалуйста, выберите мир для начала.') }}
@endauth
@endsection