<!doctype html>
<html lang="fr">
  <head>
    <meta charset="UTF-8" />
    <link rel="icon" type="image/png" href="/chaat_imh.png" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, viewport-fit=cover" />
    <title>Dasheet - Professional Management Platform</title>
    <meta name="description" content="Transform the way you manage your assets with advanced analytics, real-time tracking and a modern interface designed for professionals.">
    
    <script>
      (function() {
        var path = location.pathname;
        var shareMatch = path.match(/^\/s\/([^/]+)/);
        var shareToken = shareMatch && shareMatch[1] && shareMatch[1] !== 'manifest.webmanifest' ? shareMatch[1] : null;
        var isShare = !!shareToken;
        var pathBase = path.split('?')[0].replace(/\/$/, '') || '/';
        var isHub = isShare && /^\/s\/[^/]+$/.test(pathBase);
        var isBillets = isShare && /\/billets\/?$/i.test(pathBase);
        var isStandalone = false;
        try {
          isStandalone =
            window.navigator.standalone === true ||
            window.matchMedia('(display-mode: standalone)').matches ||
            window.matchMedia('(display-mode: fullscreen)').matches;
        } catch (e) {}
        window.__DASHEET_FW_PWA_STANDALONE__ = isStandalone;
        var manifestHref = isShare
          ? '/s/' + encodeURIComponent(shareToken) + '/manifest.webmanifest'
          : '/manifest.json';
        var theme = isShare ? '#000000' : '#3b82f6';
        if (isShare) {
          document.documentElement.classList.add('dasheet-fw-share-chrome');
          document.documentElement.style.backgroundColor = '#000000';
        }
        var manifestLink = document.createElement('link');
        manifestLink.rel = 'manifest';
        manifestLink.href = manifestHref;
        document.head.appendChild(manifestLink);
        var themeColor = document.createElement('meta');
        themeColor.name = 'theme-color';
        themeColor.content = theme;
        document.head.appendChild(themeColor);
        var statusBar = document.createElement('meta');
        statusBar.name = 'apple-mobile-web-app-status-bar-style';
        /* Toujours sur /s/ : iOS fige cette meta à l’install (Safari, pas encore standalone). */
        statusBar.content = isShare ? 'black-translucent' : 'default';
        statusBar.id = 'apple-status-bar-style';
        document.head.appendChild(statusBar);
        if (isShare) {
          if (isStandalone && isBillets) {
            document.documentElement.classList.add('dasheet-fw-pwa-ticket-chrome');
          } else if (isStandalone && isHub) {
            document.documentElement.classList.add('dasheet-fw-pwa-hub-chrome');
          }
          document.title = 'Fan Wallet';
          var appName = document.createElement('meta');
          appName.name = 'application-name';
          appName.content = 'Fan Wallet';
          document.head.appendChild(appName);
          var appleTitle = document.createElement('meta');
          appleTitle.name = 'apple-mobile-web-app-title';
          appleTitle.content = 'Fan Wallet';
          document.head.appendChild(appleTitle);
        }
      })();
    </script>
    <link rel="apple-touch-icon" href="/chaat_imh.png" id="apple-touch-icon-link">
    <link rel="apple-touch-icon" sizes="180x180" href="/chaat_imh.png">
    <link rel="icon" type="image/png" sizes="32x32" href="/chaat_imh.png">
    <link rel="icon" type="image/png" sizes="16x16" href="/chaat_imh.png">
    
    <meta property="og:title" content="Dasheet - Professional Management Platform">
    <meta property="og:description" content="Transform the way you manage your assets with advanced analytics, real-time tracking and a modern interface designed for professionals.">
    <meta property="og:type" content="website">
    <meta name="twitter:card" content="summary_large_image">
    <meta name="twitter:title" content="Dasheet - Professional Management Platform">
    <meta name="twitter:description" content="Transform the way you manage your assets with advanced analytics, real-time tracking and a modern interface designed for professionals.">
    
    <meta name="msapplication-TileColor" content="#3b82f6">
    
    <meta name="mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <script type="module" crossorigin src="/assets/index-BE6LkmRg.js"></script>
    <link rel="modulepreload" crossorigin href="/assets/vendor-B9XXXP2a.js">
    <link rel="modulepreload" crossorigin href="/assets/vendor-react-D0hxswUQ.js">
    <link rel="modulepreload" crossorigin href="/assets/vendor-supabase-CeoXONB1.js">
    <link rel="modulepreload" crossorigin href="/assets/vendor-export-DDy7DMWe.js">
    <link rel="modulepreload" crossorigin href="/assets/vendor-charts-BlmkcTLR.js">
    <link rel="modulepreload" crossorigin href="/assets/inventory-CU1U7A0M.js">
    <link rel="stylesheet" crossorigin href="/assets/index-ghtKJmi0.css">
  </head>
  <body>
    <script>
      (function() {
        var path = location.pathname;
        var isShare = /^\/s\/[^/]+/.test(path);
        if (isShare) {
          document.documentElement.classList.add('dasheet-fw-share-chrome');
          document.documentElement.style.backgroundColor = '#000000';
          document.body.style.backgroundColor = '#000000';
          var icon = '/fan-wallet-icon-192.png';
          var touch = document.getElementById('apple-touch-icon-link');
          if (touch) touch.href = icon;
          document.querySelectorAll('link[rel="icon"]').forEach(function(el) { el.href = icon; });
          var pathBase = path.split('?')[0].replace(/\/$/, '') || '/';
          var isHub = /^\/s\/[^/]+$/.test(pathBase);
          var isBillets = /\/billets\/?$/i.test(pathBase);
          var pwaStandalone = false;
          try {
            pwaStandalone =
              window.navigator.standalone === true ||
              window.matchMedia('(display-mode: standalone)').matches ||
              window.matchMedia('(display-mode: fullscreen)').matches;
          } catch (e) {}
          window.__DASHEET_FW_PWA_STANDALONE__ = pwaStandalone;
          var root = document.getElementById('root');
          if (root) root.style.backgroundColor = '#000000';
          var statusBar = document.getElementById('apple-status-bar-style');
          if (statusBar) statusBar.content = 'black-translucent';
          if (pwaStandalone) {
            var probe = document.createElement('div');
            probe.style.cssText =
              'position:fixed;top:0;left:0;visibility:hidden;pointer-events:none;padding-top:env(safe-area-inset-top,0px);';
            document.documentElement.appendChild(probe);
            var safeTop = parseFloat(getComputedStyle(probe).paddingTop) || 0;
            probe.remove();
            var lift = 0;
            if (!isBillets && safeTop <= 0) {
              probe = document.createElement('div');
              probe.style.cssText = 'position:fixed;top:0;left:0;width:0;height:0;visibility:hidden';
              document.documentElement.appendChild(probe);
              lift = Math.max(0, Math.round(probe.getBoundingClientRect().top));
              probe.remove();
              if (lift <= 0 && /iPhone|iPod|iPad/i.test(navigator.userAgent || '')) {
                var screenMax = Math.max(window.screen.width, window.screen.height);
                lift = screenMax >= 852 ? 59 : screenMax >= 812 ? 47 : 20;
              }
            }
            document.documentElement.style.setProperty('--fw-pwa-notch-lift', lift + 'px');
          }
          if (pwaStandalone && isBillets) {
            document.documentElement.classList.add('dasheet-fw-pwa-ticket-chrome');
          } else if (pwaStandalone && isHub) {
            document.documentElement.classList.add('dasheet-fw-pwa-hub-chrome');
          } else if (pwaStandalone) {
            document.documentElement.classList.add('dasheet-fw-pwa-hub-chrome');
          }
          return;
        }
        const saved = localStorage.getItem('theme');
        if (!saved) {
          document.documentElement.classList.add('dark');
        } else if (saved === 'dark') {
          document.documentElement.classList.add('dark');
        }
      })();
    </script>
    <div id="root"></div>
    <script>
      if ('serviceWorker' in navigator) {
        window.addEventListener('load', () => {
          navigator.serviceWorker.register('/service-worker.js')
            .then(registration => {
            })
            .catch(error => {
            });
        });
      }
    </script>
  </body>
</html>