@php
    $settings = \App\Models\SiteSetting::whereIn('key', ['contact_email','contact_phone','address','facebook_url','instagram_url'])->pluck('value','key');
@endphp
<footer class="site-footer" id="contact">
    <div class="container pb-4">
        <div class="row g-4">
            <div class="col-lg-4">
                <div class="d-flex align-items-center gap-2 mb-3">
                    <img src="{{ asset('images/logo.jpg') }}" alt="Home Heaven Decors PK" style="width:48px;height:48px;object-fit:cover;border-radius:50%;">
                    <h5 class="mb-0">Home Heaven Decors PK</h5>
                </div>
                <p class="small">Pakistan first 🇵🇰 we are based on selling elegant &amp; beautiful home &amp; office decors at reasonable prices&hellip; COD only in Pakistan.</p>
                <div class="mt-3">
                    <a href="{{ $settings['facebook_url'] ?? '#' }}" class="social-icon"><i class="bi bi-facebook"></i></a>
                    <a href="{{ $settings['instagram_url'] ?? '#' }}" class="social-icon"><i class="bi bi-instagram"></i></a>
                </div>
            </div>
            <div class="col-lg-2 col-6">
                <h5>Shop</h5>
                <ul class="list-unstyled small">
                    <li class="mb-2"><a href="{{ route('shop.index') }}">All Products</a></li>
                    @foreach(\App\Models\Category::active()->orderBy('sort_order')->take(5)->get() as $cat)
                        <li class="mb-2"><a href="{{ route('shop.index', ['category' => $cat->slug]) }}">{{ $cat->name }}</a></li>
                    @endforeach
                </ul>
            </div>
            <div class="col-lg-3 col-6">
                <h5>Account</h5>
                <ul class="list-unstyled small">
                    <li class="mb-2"><a href="{{ route('cart.index') }}">My Cart</a></li>
                    <li class="mb-2"><a href="{{ Auth::check() ? route('account.orders.index') : route('login') }}">My Orders</a></li>
                    <li class="mb-2"><a href="{{ Auth::check() ? route('account.profile') : route('login') }}">My Account</a></li>
                </ul>
            </div>
            <div class="col-lg-3">
                <h5>Get in Touch</h5>
                <ul class="list-unstyled small">
                    @if(!empty($settings['address']))
                        <li class="mb-2"><i class="bi bi-geo-alt me-2"></i>{{ $settings['address'] }}</li>
                    @endif
                    @if(!empty($settings['contact_phone']))
                        <li class="mb-2"><i class="bi bi-telephone me-2"></i>{{ $settings['contact_phone'] }}</li>
                    @endif
                    @if(!empty($settings['contact_email']))
                        <li class="mb-2"><i class="bi bi-envelope me-2"></i>{{ $settings['contact_email'] }}</li>
                    @endif
                    <li class="mb-2"><i class="bi bi-truck me-2"></i>Cash on Delivery, nationwide</li>
                </ul>
            </div>
        </div>
    </div>
    <div class="footer-bottom text-center">
        <div class="container">
            &copy; {{ date('Y') }} Home Heaven Decors PK. All rights reserved.
        </div>
    </div>
</footer>
