<?xml version="1.0" encoding="UTF-8"?>
<!-- ═══════════════════════════════════════════════════════════════
     sitemap.xml - ElioMa E-Commerce Site
     ═══════════════════════════════════════════════════════════════

     STATIC TEMPLATE - For production, generate dynamically from backend
     using product database to include all product pages automatically.

     Recommended approach:
     1. Use backend script to query product database
     2. Generate sitemap dynamically with current prices/availability
     3. Update daily via cron job
     4. Compress as sitemap.xml.gz for large catalogs (>50k URLs)

     ═══════════════════════════════════════════════════════════════ -->
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
        xmlns:image="http://www.google.com/schemas/sitemap-image/1.1"
        xmlns:xhtml="http://www.w3.org/1999/xhtml">

  <!-- ═══════════════════════════════════════════════════════════════
       CORE PAGES (High Priority)
       ═══════════════════════════════════════════════════════════════ -->

  <!-- Homepage -->
  <url>
    <loc>https://elioma.net/</loc>
    <lastmod>2025-11-14</lastmod>
    <changefreq>daily</changefreq>
    <priority>1.0</priority>
    <!-- Multilingual alternative (future) -->
    <!-- <xhtml:link rel="alternate" hreflang="en" href="https://elioma.net/en/"/> -->
  </url>

  <!-- Contact Page -->
  <url>
    <loc>https://elioma.net/contact.html</loc>
    <lastmod>2025-11-14</lastmod>
    <changefreq>monthly</changefreq>
    <priority>0.8</priority>
  </url>

  <!-- ═══════════════════════════════════════════════════════════════
       PRODUCT PAGES (Medium-High Priority)
       ═══════════════════════════════════════════════════════════════

       REPLACE with dynamic generation from database:
       SELECT product_id, name, updated_at, image_url
       FROM products
       WHERE status = 'active'
       ORDER BY created_at DESC

       ═══════════════════════════════════════════════════════════════ -->

  <!-- Product 1 - TEMPLATE -->
  <url>
    <loc>https://elioma.net/product/[PRODUCT-SLUG-1]</loc>
    <lastmod>2025-11-14</lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.9</priority>
    <!-- Product image (helps image SEO) -->
    <image:image>
      <image:loc>https://elioma.net/images/products/product-1.jpg</image:loc>
      <image:title>[PRODUCT_NAME_1]</image:title>
      <image:caption>[PRODUCT_DESCRIPTION_1]</image:caption>
    </image:image>
  </url>

  <!-- Product 2 - TEMPLATE -->
  <url>
    <loc>https://elioma.net/product/[PRODUCT-SLUG-2]</loc>
    <lastmod>2025-11-14</lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.9</priority>
    <image:image>
      <image:loc>https://elioma.net/images/products/product-2.jpg</image:loc>
      <image:title>[PRODUCT_NAME_2]</image:title>
      <image:caption>[PRODUCT_DESCRIPTION_2]</image:caption>
    </image:image>
  </url>

  <!-- Product 3 - TEMPLATE -->
  <url>
    <loc>https://elioma.net/product/[PRODUCT-SLUG-3]</loc>
    <lastmod>2025-11-14</lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.9</priority>
    <image:image>
      <image:loc>https://elioma.net/images/products/product-3.jpg</image:loc>
      <image:title>[PRODUCT_NAME_3]</image:title>
      <image:caption>[PRODUCT_DESCRIPTION_3]</image:caption>
    </image:image>
  </url>

  <!-- ═══════════════════════════════════════════════════════════════
       CATEGORY PAGES (if applicable)
       ═══════════════════════════════════════════════════════════════ -->
  <!--
  <url>
    <loc>https://elioma.net/category/electronics</loc>
    <lastmod>2025-11-14</lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.8</priority>
  </url>
  -->

  <!-- ═══════════════════════════════════════════════════════════════
       INFORMATIONAL PAGES (Lower Priority)
       ═══════════════════════════════════════════════════════════════ -->
  <!--
  <url>
    <loc>https://elioma.net/faq</loc>
    <lastmod>2025-11-14</lastmod>
    <changefreq>monthly</changefreq>
    <priority>0.6</priority>
  </url>

  <url>
    <loc>https://elioma.net/about</loc>
    <lastmod>2025-11-14</lastmod>
    <changefreq>yearly</changefreq>
    <priority>0.5</priority>
  </url>
  -->

</urlset>

<!-- ═══════════════════════════════════════════════════════════════
     DYNAMIC GENERATION EXAMPLE (Python/Node.js)
     ═══════════════════════════════════════════════════════════════

     Python example:

     import xml.etree.ElementTree as ET
     from datetime import datetime

     def generate_sitemap(products):
         urlset = ET.Element('urlset', xmlns="http://www.sitemaps.org/schemas/sitemap/0.9")

         for product in products:
             url = ET.SubElement(urlset, 'url')
             ET.SubElement(url, 'loc').text = f"https://elioma.net/product/{product['slug']}"
             ET.SubElement(url, 'lastmod').text = product['updated_at'].strftime('%Y-%m-%d')
             ET.SubElement(url, 'changefreq').text = 'weekly'
             ET.SubElement(url, 'priority').text = '0.9'

         tree = ET.ElementTree(urlset)
         tree.write('sitemap.xml', encoding='utf-8', xml_declaration=True)

     ═══════════════════════════════════════════════════════════════ -->
