    </main>
    <footer class="bg-white border-t border-gray-200 mt-12">
        <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-8">
            <div class="grid grid-cols-1 md:grid-cols-4 gap-8">
                <div>
                    <h4 class="font-bold text-lg text-primary-600 mb-4"><?= APP_NAME ?></h4>
                    <p class="text-gray-600 text-sm">Your one-stop destination for quality products at the best prices.</p>
                </div>
                <div>
                    <h5 class="font-semibold text-gray-800 mb-3">Quick Links</h5>
                    <ul class="space-y-2 text-sm">
                        <li><a href="<?= BASE_PATH ?>/catalog.php" class="text-gray-600 hover:text-primary-600">All Products</a></li>
                        <li><a href="<?= BASE_PATH ?>/catalog.php?category=electronics" class="text-gray-600 hover:text-primary-600">Electronics</a></li>
                        <li><a href="<?= BASE_PATH ?>/catalog.php?category=clothing" class="text-gray-600 hover:text-primary-600">Clothing</a></li>
                        <li><a href="<?= BASE_PATH ?>/catalog.php?category=home-kitchen" class="text-gray-600 hover:text-primary-600">Home & Kitchen</a></li>
                    </ul>
                </div>
                <div>
                    <h5 class="font-semibold text-gray-800 mb-3">Customer Service</h5>
                    <ul class="space-y-2 text-sm">
                        <?php
                        $db = db();
                        $pages = $db->query("SELECT slug, title FROM pages WHERE is_published = 1 ORDER BY sort_order")->fetchAll();
                        foreach ($pages as $p): ?>
                        <li><a href="<?= BASE_PATH ?>/page.php?slug=<?= h($p['slug']) ?>" class="text-gray-600 hover:text-primary-600"><?= h($p['title']) ?></a></li>
                        <?php endforeach; ?>
                    </ul>
                </div>
                <div>
                    <h5 class="font-semibold text-gray-800 mb-3">Contact</h5>
                    <ul class="space-y-2 text-sm text-gray-600">
                        <li><i class="fas fa-envelope w-5"></i> support@shopnow.com</li>
                        <li><i class="fas fa-phone w-5"></i> +91 9876543210</li>
                        <li><i class="fas fa-map-marker-alt w-5"></i> Mumbai, India</li>
                    </ul>
                </div>
            </div>
            <div class="border-t border-gray-200 mt-8 pt-6 text-center text-sm text-gray-500">
                &copy; <?= date('Y') ?> <?= APP_NAME ?>. All rights reserved.
            </div>
        </div>
    </footer>
    <script src="https://cdn.jsdelivr.net/npm/alpinejs@3.x.x/dist/cdn.min.js" defer></script>
    <script src="<?= BASE_PATH ?>/assets/js/app.js"></script>
</body>
</html>
