<?php
require_once __DIR__ . '/includes/bootstrap.php';
header('Content-Type: application/xml; charset=utf-8');
$xmlns = 'http://' . 'www' . '.sitemaps' . '.org/schemas/sitemap/0.9';
$paths = [
    '/', '/life/', '/stories/', '/healing-video/', '/ai-inspiration/', '/creators/', '/contact/',
    '/slow-life/', '/healing-gallery/', '/inspiration-workshop/', '/tree-hole/', '/quality-life/'
];
echo '<?xml version="1.0" encoding="UTF-8"?>' . "\n";
echo '<urlset xmlns="' . e($xmlns) . '">' . "\n";
foreach ($paths as $path) {
    echo "  <url>\n";
    echo '    <loc>' . e(absolute_url($path)) . "</loc>\n";
    echo '    <lastmod>' . date('Y-m-d') . "</lastmod>\n";
    echo "    <changefreq>daily</changefreq>\n";
    echo $path === '/' ? "    <priority>1.0</priority>\n" : "    <priority>0.8</priority>\n";
    echo "  </url>\n";
}
echo '</urlset>' . "\n";
?>
