<!DOCTYPE html>
<html lang="fa">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>اسکلت مرموز</title>
    <script src="https://unpkg.com/@lottiefiles/lottie-player@latest/dist/lottie-player.js"></script>
    <style>
        body {
            margin: 0;
            padding: 20px;
            background: #0a0a0a;
            display: flex;
            justify-content: center;
            align-items: center;
            min-height: 100vh;
            font-family: Arial, sans-serif;
        }
        
        .animation-container {
            position: relative;
            width: 400px;
            height: 400px;
        }
        
        .text-bubble {
            position: absolute;
            bottom: 50px;
            left: 50%;
            transform: translateX(-50%);
            background: rgba(255, 255, 255, 0.9);
            padding: 15px 25px;
            border-radius: 20px;
            font-size: 18px;
            font-weight: bold;
            color: #222;
            box-shadow: 0 5px 15px rgba(0,0,0,0.3);
            opacity: 0;
            animation: fadeIn 0.5s forwards 3s;
        }
        
        .text-bubble:after {
            content: '';
            position: absolute;
            top: 100%;
            left: 50%;
            transform: translateX(-50%);
            border: 10px solid transparent;
            border-top-color: rgba(255, 255, 255, 0.9);
        }
        
        @keyframes fadeIn {
            to { opacity: 1; }
        }
        
        .play-button {
            position: absolute;
            bottom: 20px;
            left: 50%;
            transform: translateX(-50%);
            background: #ff4757;
            color: white;
            border: none;
            padding: 12px 30px;
            font-size: 16px;
            border-radius: 25px;
            cursor: pointer;
            font-weight: bold;
            box-shadow: 0 5px 15px rgba(255, 71, 87, 0.4);
            transition: all 0.3s;
            opacity: 0;
            animation: fadeIn 0.5s forwards 3.5s;
        }
        
        .play-button:hover {
            background: #ff6b81;
            transform: translateX(-50%) scale(1.05);
        }
    </style>
</head>
<body>
    <div class="animation-container">
        <!-- انیمیشن Lottie -->
        <lottie-player
            id="skeletonLottie"
            src="https://raw.githubusercontent.com/your-username/skeleton-animation.json/main/skeleton.json"
            background="transparent"
            speed="1"
            style="width: 400px; height: 400px;"
            loop
            autoplay>
        </lottie-player>
        
        <div class="text-bubble" id="textBubble">wanna play?</div>
        <button class="play-button" id="playButton">Let's Play!</button>
    </div>

    <script>
        // کنترل انیمیشن
        document.addEventListener('DOMContentLoaded', function() {
            const player = document.getElementById('skeletonLottie');
            const textBubble = document.getElementById('textBubble');
            const playButton = document.getElementById('playButton');
            
            // توقف انیمیشن پس از یک بار پخش
            player.addEventListener('complete', () => {
                player.pause();
            });
            
            // کلیک روی دکمه
            playButton.addEventListener('click', function() {
                alert('🎮 Let the games begin!');
                // اینجا می‌توانید کاربر را به صفحه بازی هدایت کنید
                // window.location.href = '/game-page';
            });
            
            // نمایش حباب گفتگو با تاخیر
            setTimeout(() => {
                textBubble.style.animation = 'fadeIn 0.5s forwards';
            }, 3000);
        });
    </script>
</body>
</html>