<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">

  <!-- === PAGES PRINCIPALES === -->
  <url>
    <loc>https://estomikron24.com/</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>daily</changefreq>
    <priority>1.0</priority>
  </url>

  <!-- === PAGES INVESTISSEMENT (6 PIERRES) === -->
  <url>
    <loc>https://estomikron24.com/tanzanite-als-kapitalanlage</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.95</priority>
  </url>
  <url>
    <loc>https://estomikron24.com/spinell-als-kapitalanlage</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.95</priority>
  </url>
  <url>
    <loc>https://estomikron24.com/tsavorit-als-kapitalanlage</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.95</priority>
  </url>
  <url>
    <loc>https://estomikron24.com/aquamarin-als-kapitalanlage</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.95</priority>
  </url>
  <url>
    <loc>https://estomikron24.com/turmalin-als-kapitalanlage</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.95</priority>
  </url>
  <url>
    <loc>https://estomikron24.com/amethyst-als-kapitalanlage</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.95</priority>
  </url>

  <!-- === PAGES MARCHE ET DONNEES === -->
  <url>
    <loc>https://estomikron24.com/markt</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>hourly</changefreq>
    <priority>0.90</priority>
  </url>

  <!-- === PAGES OUTILS / LEADS === -->
  <url>
    <loc>https://estomikron24.com/vermoegen-schaetzen</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>monthly</changefreq>
    <priority>0.85</priority>
  </url>
  <url>
    <loc>https://estomikron24.com/edelstein-investment-vergleich</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>monthly</changefreq>
    <priority>0.85</priority>
  </url>
  <url>
    <loc>https://estomikron24.com/kontakt</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>monthly</changefreq>
    <priority>0.80</priority>
  </url>

  <!-- === LEXIKON === -->
  <url>
    <loc>https://estomikron24.com/edelsteine-lexikon</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.85</priority>
  </url>
  <url>
    <loc>https://estomikron24.com/mineralogie</loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.80</priority>
  </url>

  <!-- === 93 PIERRES PRECIEUSES (dataset pierres_precieuses) === -->
  <?php
  $pierres = json_decode(file_get_contents(__DIR__ . '/data/pierres_precieuses.json'), true);
  $investSlugs = ['tanzanite','amethyste','aigue-marine','spinelle','tourmaline','tsavorite'];
  $slugMap = [
    'tanzanite'    => 'tanzanite-als-kapitalanlage',
    'amethyste'    => 'amethyst-als-kapitalanlage',
    'aigue-marine' => 'aquamarin-als-kapitalanlage',
    'spinelle'     => 'spinell-als-kapitalanlage',
    'tourmaline'   => 'turmalin-als-kapitalanlage',
    'tsavorite'    => 'tsavorit-als-kapitalanlage',
  ];
  foreach ($pierres as $pierre):
    if (isset($slugMap[$pierre['slug']])) continue; // deja dans les pages investment
    $priority = in_array($pierre['slug'], $investSlugs) ? '0.85' : '0.70';
  ?>
  <url>
    <loc>https://estomikron24.com/edelsteine-lexikon/<?= htmlspecialchars($pierre['slug']) ?></loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>monthly</changefreq>
    <priority><?= $priority ?></priority>
  </url>
  <?php endforeach; ?>

  <!-- === 126 MINERAUX (dataset mineraux) === -->
  <?php
  $mineraux = json_decode(file_get_contents(__DIR__ . '/data/mineraux.json'), true);
  foreach ($mineraux as $mineral):
  ?>
  <url>
    <loc>https://estomikron24.com/mineralogie/<?= htmlspecialchars($mineral['slug']) ?></loc>
    <lastmod><?php echo date('Y-m-d'); ?></lastmod>
    <changefreq>monthly</changefreq>
    <priority>0.60</priority>
  </url>
  <?php endforeach; ?>

</urlset>