<html lang="en">
<head>

<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-4629433787504297"
     crossorigin="anonymous"></script>
    <meta name="google-adsense-account" content="ca-pub-4629433787504297">
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Unblocker</title>
    <a href="https://docs.google.com/forms/d/e/1FAIpQLSd2hFJE8BcyQs3vQFWTh_273FD4T9PUIXW_APy7UKmchXNkwg/viewform?usp=dialog/" target="_blank">Request A Game!</a>
    <style>
        body {
            font-family: Arial, sans-serif;
            background-color: #1c1c1c;
            color: white;
            margin: 0;
            padding: 0;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            height: 100vh;
            overflow: scroll;
        }

        h1 {
            color: #ffffff;
            font-size: 3em;
            margin-top: 10px;
        }

        .games-container {
            width: 80%%;
            max-width: 1000px;
            height: 75%;
            overflow-y: scroll;
            background-color: #2e2e30;
            padding: 20px;
            border-radius: 10px;
            box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
            margin-top: 20px;
            display: grid;
            grid-template-columns: repeat(3, 1fr); /* 3 games per row */
            gap: 20px; /* Space between items */
            justify-items: center; /* Centers the games in each grid item */
        }

        .game-item {
            display: flex;
            flex-direction: column;
            align-items: center;
            padding: 10px;
            border-radius: 10px;
            background-color: #1c1c1c;
            box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
        }

        .game-item img {
            width: 100%;
            height: 200px;
            object-fit: cover;
            border-radius: 10px;
            margin-bottom: 10px;
        }

        .play-button {
            padding: 10px 20px;
            font-size: 16px;
            background-color: #3498db;
            color: white;
            border: none;
            border-radius: 5px;
            cursor: pointer;
            transition: background-color 0.3s ease;
        }

        .play-button:hover {
            background-color: #2980b9;
        }

        .play-button:focus {
            outline: none;
        }

        .play-button:disabled {
            background-color: #bdc3c7;
            cursor: not-allowed;
        }

        .game-iframe {
            width: 100%;
            height: 80vh;
            border: none;
            border-radius: 10px;
            display: none;
        }

        /* Modal Styling */
        .modal {
            display: none;
            position: fixed;
            z-index: 1;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.5);
            justify-content: center;
            align-items: center;
        }

        .modal-content {
            background-color: #1c1c1c;
            padding: 20px;
            border-radius: 10px;
            width: 50%;
            max-width: 1200px;
        }

        .close-btn {
            background-color: #e74c3c;
            color: white;
            padding: 10px 20px;
            border: none;
            border-radius: 10px;
            cursor: pointer;
            display: block;
            margin: 0 auto;
        }

        .close-btn:hover {
            background-color: #c0392b;
        }

        /* Blank Game Item for Spacing */
        .blank-game {
            background-color: transparent;
            border: none;
            height: 250px;
        }

        }
    </style>
</head>
<body>

<script type="text/javascript">
  document.addEventListener('contextmenu', function(event) {
    event.preventDefault();
  });
</script>

</SCRIPT>

<!-- Main Content -->
<h1 style="margin-bottom: 2px;">Unblocker!</h1>

<a href="https://www.free-counters.org/" style="margin: 0; padding: 0;">free HitCounters</a>
<script type="text/javascript" src="https://www.freevisitorcounters.com/auth.php?id=4d6aecc4c0b8391efe64e5a547dd8bb85158ca6a"></script>
<script type="text/javascript" src="https://www.freevisitorcounters.com/en/home/counter/1285440/t/2"></script>


<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-4629433787504297"
     crossorigin="anonymous"></script>
<!-- Verticals -->
<ins class="adsbygoogle"
     style="display:block"
     data-ad-client="ca-pub-4629433787504297"
     data-ad-slot="7706987289"
     data-ad-format="auto"
     data-full-width-responsive="true"></ins>
<script>
     (adsbygoogle = window.adsbygoogle || []).push({});
</script>

    <div class="games-container">
        <!-- Game Items (as in your original code) -->

       <!-- Game Item 2: Unblocked browser -->
<div class="game-item">
    <img src="https://cdn3.iconfinder.com/data/icons/glypho-generic-icons/64/lock-unlocked-512.png" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://small-kids.foxgateway.com')">Open Unblocked Browser</button>
</div>

<!-- Game Item 1: Minecraft -->
        <div class="game-item">
            <img src="https://image.api.playstation.com/vulcan/ap/rnd/202407/0401/670c294ded3baf4fa11068db2ec6758c63f7daeb266a35a1.png" alt="Drift King">
            <button class="play-button" onclick="openGame('https://mcraft.fun')">Play Minecraft</button>
        </div>


        <!-- Game Item 1: Drift Hunters -->
        <div class="game-item">
            <img src="https://rocketgames.imgix.net/uploads/games/drift-hunters/drift-hunters.d43232.png?auto=format,compress,enhance&w=314&dpr=1" alt="Drift King">
            <button class="play-button" onclick="openGame('https://www.180sx.club/media/games/drift-hunters/drift-hunters-chromebook.html')">Play Drift Hunters</button>
        </div>

<!-- Game Item 1: Bitlife -->
        <div class="game-item">
            <img src="https://d.newsweek.com/en/full/1317374/bitlife-ribbons-how-get-all-complete-list-android-ios-cheats-guide-tips-become.jpg?w=1600&h=1600&q=88&f=75befc746fb83a0c568c44ca07bc5e64">
            <button class="play-button" onclick="openGame('https://bitlifeonline.github.io/class/index.html')">Play Bitlife</button>
        </div>

<!-- Game Item 1: Temple Run 2 -->
        <div class="game-item">
            <img src="https://play-lh.googleusercontent.com/a7R5nyeaX8lIEWdBOxjlvbyq9LcFwh3XMvNtBPEKR3LPGgdvgGrec4sJwn8tUaaSkw=s160">
            <button class="play-button" onclick="openGame('https://ams.cdn.arkadiumhosted.com/assets/global/game/chess/')">Play Chess</button>
        </div>

<!-- Game Item 1: Pac Man -->
        <div class="game-item">
            <img src="https://image.api.playstation.com/cdn/UP0700/CUSA03955_00/OCyy6TplEtTEqcf8aDfvAq6KSLHYOoMm.png" alt="Drift King">
            <button class="play-button" onclick="openGame('https://www.echalk.co.uk/amusements/Games/Pacman/pacman.html')">Play Pac Man</button>
        </div>

        <!-- Game Item 2: Retro Bowl -->
        <div class="game-item">
            <img src="https://cdn-1.webcatalog.io/catalog/poki-retro-bowl-college/poki-retro-bowl-college-icon-unplated.png?v=1714781360837" alt="Retro Bowl">
            <button class="play-button" onclick="openGame('https://game316009.konggames.com/gamez/0031/6009/live/index.html')">Play Retro Bowl</button>
        </div>

        <!-- Game Item 3: Jetpack Joyride -->
        <div class="game-item">
            <img src="https://i0.wp.com/tabletoptogether.com/wp-content/uploads/2020/01/Jetpack-Joyride-Cover.png?ssl=1" alt="Jetpack Joyride">
            <button class="play-button" onclick="openGame('https://emulatoros.github.io/gfile/jetpackjoyride/')">Play Jetpack Joyride</button>
        </div>

        <!-- Game Item 4: Slope -->
        <div class="game-item">
            <img src="https://slope-play.com/data/image/game/slope-logo-1.jpg" alt="Slope">
            <button class="play-button" onclick="openGame('https://games-online.io/game/Slope3/')">Play Slope</button>
        </div>

<!-- Game Item 4: Geometry Dash -->
        <div class="game-item">
            <img src="https://upload.wikimedia.org/wikipedia/en/thumb/4/4d/Logo_of_Geometry_Dash.svg/640px-Logo_of_Geometry_Dash.svg.png" alt="Slope">
            <button class="play-button" onclick="openGame('https://freeonlinegames.github.io/geometry-dash.html')">Play Geometry Dash</button>
        </div>

<!-- Game Item 2: 1v1.LOL -->
<div class="game-item">
    <img src="https://play-lh.googleusercontent.com/Shj_hBe1ErpmWnJDFnfSyMSL2p3ID-VPQ-UF3t1iUkdJUj_mJ6Ea7GjnZeREW4RWBJ0z" alt="1v1.LOL">
    <button class="play-button" onclick="openGame('https://education76.github.io/g77/1v1-lol-3/')">Play 1v1.LOL</button>
</div>

<!-- Game Item 2: Snake.io -->
<div class="game-item">
    <img src="https://upload.wikimedia.org/wikipedia/en/a/a4/Snakeio_app_icon.png" alt="1v1.LOL">
    <button class="play-button" onclick="openGame('https://app-166133.games.s3.yandex.net/166133/cqi8jgft0lonphtppjblvgy1wj0sfr2v/index.html')">Play Snake.io</button>
</div>

<!-- Game Item 2: Stack Bounce -->
<div class="game-item">
    <img src="https://images.sftcdn.net/images/t_app-icon-m/p/686953f5-3c56-4c54-8294-a2ac86d06062/3840619291/stack-bounce-2024-logo" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://cdn.gamesnacks.com/stackbounceupdate/gameCode/index.html')">Play Stack Bounce</button>
</div>

<!-- Game Item 2: Cookie Clicker -->
<div class="game-item">
    <img src="https://play-lh.googleusercontent.com/Z1MOuuiD05ZN5LkVmMEvKF0mqAc-FknaQ2j8s4dZiO-LSPQX4EEA3RVJdlQEtxe96ok" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://clicker-games.com/games/cookie-clicker/index.html')">Play Cookie Clicker</button>
</div>

<!-- Game Item 2: Run 3 -->
<div class="game-item">
    <img src="https://www.onlinegames.io/media/posts/579/responsive/Run-3-Space-xs.jpg" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://www.onlinegames.io/games/2023/construct/192/run-3-space/index.html')">Play Run 3 Space</button>
</div>

<!-- Game Item 2: Dino Game -->
<div class="game-item">
    <img src="https://play-lh.googleusercontent.com/iiIJq5JmLFYNI1bVz4IBHyoXs508JcEzHhOgau69bnveF9Wat51-ax9LMPVOlneKwqg" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://trex-runner.com')">Play Dino Game</button>
</div>

<!-- Game Item 2: Google Snake -->
<div class="game-item">
    <img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgdbt2FcBN4X5y47vD14GSfdM7ScLfitclGZEJecdIV-UnaQTlQiFCp5fC5Sll46Y5gvp8rxmY0U06njTAij3XcpmGOso10CAUVD0Q_2BLYS6_NFqeMPzJYSOd2ncIR9mYAVPf1F0bjfNNC7jyiErZD8l61zNB98yE_JEIcgXEjcIshgEC2SDR_RnBVkJZj/s218/Google%20Snake%20Icon.png" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://freeonlinegames.github.io/google-snake.html')">Play Google Snake</button>
</div>

<!-- Game Item 2: Fireboy and Watergirl -->
<div class="game-item">
    <img src="https://play-lh.googleusercontent.com/6N_ON50BZiEAe-ll2lM92NrVrgp5I5Ha6VI0a4Usw7uPmgEjL6tgJR6jWYUkkYgx2LM" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://html5.gamedistribution.com/a55c9cc9c21e4fc683c8c6857f3d0c75/?gd_sdk_referrer_url=https%3A%2F%2Fwww.crazygames.com%2Fgame%2Ffireboy-and-watergirl-the-forest-temple')">Play Fireboy and Watergirl</button>
</div>

<!-- Game Item 2: Cut The Rope: Time Travel -->
<div class="game-item">
    <img src="https://media.idownloadblog.com/wp-content/uploads/2013/04/Cut-the-Rope-Time-Travel-teaser.jpeg" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://app-97515.games.s3.yandex.net/97515/u1824c0o9xlk2nm9hlcxtbs4l6ysl44s/index.html')">Play Cut The Rope: TT</button>
</div>


<!-- Game Item 2: Basket Random -->
<div class="game-item">
    <img src="https://play-lh.googleusercontent.com/gP8T5Z1O-ngxIloiwcBZzrzyLPYDp0R_1BDNKUDZboIRPVImeyWI8-7aExvB9gAGNKc" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://hhsbest.github.io/bkrndom/')">Play Basket Random</button>
</div>

<!-- Game Item 2: Papas Pizzeria -->
<div class="game-item">
    <img src="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcRGe5GU_dm8EFg80cJzqRuqHNKg50_g0RwZyQ&s" alt="Papas Pizzeria">
    <button class="play-button" onclick="openGame('https://flash-cdn.blogspot.com/2022/06/papas-pizzeria.html')">Play Papas Pizzeria</button>
</div>

<!-- Game Item 2: Papas Freezeria -->
<div class="game-item">
    <img src="https://play-lh.googleusercontent.com/pHHCQat6QfO9dJMrRLRAlP-v9y98iI9lDx2oJ_Y8jho9AJQafQezJJYgWxzfuY9QRaw" alt="Papas Pizzeria">
    <button class="play-button" onclick="openGame('https://play.gilect.com/flashgame?flash=papasfreezeria')">Play Papas Freezeria</button>
</div>

<!-- Game Item 2: Drive Mad -->
<div class="game-item">
    <img src="https://drivemad.me/wp-content/uploads/2023/06/cropped-drive-mad-1.png.webp" alt="Papas Pizzeria">
    <button class="play-button" onclick="openGame('https://drivemad.me/iframe/index.html')">Play Drive Mad</button>
</div>

<!-- Game Item 2: Kick The Dummy -->
<div class="game-item">
    <img src="https://www.onlinegames.io/media/posts/414/responsive/Kick-The-Dummy-Game-xs.jpg" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://www.onlinegames.io/games/2022/construct/153/kick-the-dummy/index.html')">Play Kick The Dummy</button>
</div>

<!-- Game Item 2: Highway Cars -->
<div class="game-item">
    <img src="https://www.onlinegames.io/media/posts/598/responsive/Highway-Cars-xs.jpg" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://www.onlinegames.io/games/2023/construct/211/highway-cars/index.html')">Play Highway Cars</button>
</div>

<!-- Game Item 2: Moto x3m -->
<div class="game-item">
    <img src="https://cdn.jogos360.com.br/mo/to/moto-3xm-2-d.jpg" alt="Moto x3m">
    <button class="play-button" onclick="openGame('https://lablockedgames.com/funblocked/moto-x3m/index.html')">Play Moto x3m</button>
</div>

<!-- Game Item 2: Super Mario Bros -->
<div class="game-item">
    <img src="https://m.media-amazon.com/images/I/71OWWCZNouL._AC_UF894,1000_QL80_.jpg" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://unblockeds-games.com/games/super-mario-bros/index.html')">Play Super Mario</button>
</div>

<!-- Game Item 2: Subway Surfers -->
<div class="game-item">
    <img src="https://e.snmc.io/lk/lv/x/bb7812e01a96321231f2c33973b99489/5282921" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://szhong.4399.com/4399swf//upload_swf/ftp38/liuxinyu/20220308/1/index.html')">Play Subway Surfers</button>
</div>

<!-- Game Item 2: Doodle Jump -->
<div class="game-item">
    <img src="https://i0.wp.com/www.nokiapoweruser.com/wp-content/uploads/2014/12/27b47238-f804-4383-8bf0-bb5c04000568.png" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://ubg98.github.io/DoodleJump/')">Play Doodle Jump</button>
</div>

<!-- Game Item 2: Uno -->
<div class="game-item">
    <img src="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcShBRFXeIUSzhnaZlFRCWNhs_QXtyCmwj4CAQ&s" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://www.xpgameplus.com/games/uno/default.html')">Play Uno</button>
</div>

<!-- Game Item 2: Solitare -->
<div class="game-item">
    <img src="https://m.media-amazon.com/images/I/81I3Kfwg8wL.png" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://www.edogan.us/solitaire-js/')">Play Solitare</button>
</div>

<!-- Game Item 2: Idle Breakout -->
<div class="game-item">
    <img src="https://play-lh.googleusercontent.com/e5jzYTn7Mjh9Ghn-DFpVedkOlRfSOyCS2AFgXdTrADIuuUbjx6vP6r_YOM2j5m7uLQ" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://www.onlinegames.io/games/2024/more/idle-breakout/index.html')">Play Idle Breakout</button>
</div>

<!-- Game Item 2: Tiny Fishing -->
<div class="game-item">
    <img src="https://www.cokogames.com/wp-content/uploads/thumbs/custom/T/tiny-fishing.jpeg" alt="Stack Bounce">
    <button class="play-button" onclick="openGame('https://tiny-fishing.github.io/games/tinyfishing.html')">Play Tiny Fishing</button>
</div>


    <!-- Modal for Game -->
    <div id="game-modal" class="modal">
        <div class="modal-content">
            <button class="close-btn" onclick="closeGame()">Close</button>
            <iframe id="game-iframe" class="game-iframe" src="" frameborder="0"></iframe>
        </div>
    </div>

    <script>
        let iframeLoaded = false;

        // View counter functionality
        let viewCount = localStorage.getItem('viewCount') ? parseInt(localStorage.getItem('viewCount')) : 0;
        viewCount++;
        localStorage.setItem('viewCount', viewCount);
        document.getElementById('view-counter').textContent = `Views: ${viewCount}`;

        function openGame(gameUrl) {
            const iframe = document.getElementById('game-iframe');

            // If the game hasn't been loaded, load it
            if (!iframeLoaded) {
                iframe.src = gameUrl;
                iframe.style.display = 'block';
                iframeLoaded = true;
            }

            // Show the modal
            document.getElementById('game-modal').style.display = 'flex';
        }

        function closeGame() {
            // Hide the modal
            document.getElementById('game-modal').style.display = 'none';
            
            // Stop the game by clearing the iframe src (which stops the game from running)
            const iframe = document.getElementById('game-iframe');
            iframe.style.display = 'none';
            iframe.src = "";  // Stop the game from running

            // Reset the loaded flag so the game can load again when clicked "Play"
            iframeLoaded = false;
        }
    </script>
  
</body>
</html>
