mc / index.html
Saad4web's picture
make it on top and also change text of all cta buttons - Initial Deployment
063ef5c verified
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Minecraft Realm Access | Exclusive World Downloads</title>
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://unpkg.com/feather-icons"></script>
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&family=Poppins:wght@300;400;500;600;700&display=swap" rel="stylesheet">
<script>
tailwind.config = {
theme: {
extend: {
colors: {
minecraft: '#1e3f20',
minecraftAccent: '#5cd65c',
minecraftDark: '#0f1a0f',
},
fontFamily: {
montserrat: ['Montserrat', 'sans-serif'],
poppins: ['Poppins', 'sans-serif']
}
}
}
}
</script>
<style>
.hero-bg {
background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('http://static.photos/nature/1200x630/42');
background-size: cover;
background-position: center;
}
.pixel-border {
border-image: url("data:image/svg+xml,%3csvg width='100' height='100' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='m0,4 l4,-4 l92,0 l4,4 l0,92 l-4,4 l-92,0 l-4,-4 z' fill='none' stroke='%235cd65c' stroke-width='4'/%3e%3c/svg%3e") 14 stretch;
border-width: 14px;
}
.modal {
transition: opacity 0.3s ease, transform 0.3s ease;
}
.modal-content {
transform: translateY(20px);
transition: transform 0.3s ease;
}
.modal.show {
opacity: 1;
pointer-events: auto;
}
.modal.show .modal-content {
transform: translateY(0);
}
.loader {
border-top-color: #5cd65c;
animation: spin 1s linear infinite;
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
.countdown-item {
background: linear-gradient(145deg, #1a1a1a, #0f0f0f);
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}
.floating {
animation: floating 3s ease-in-out infinite;
}
@keyframes floating {
0% { transform: translateY(0px); }
50% { transform: translateY(-15px); }
100% { transform: translateY(0px); }
}
.pixel-corners {
clip-path: polygon(
0 8px, 8px 8px, 8px 0,
calc(100% - 8px) 0, calc(100% - 8px) 8px, 100% 8px,
100% calc(100% - 8px), calc(100% - 8px) calc(100% - 8px),
calc(100% - 8px) 100%, 8px 100%, 8px calc(100% - 8px),
0 calc(100% - 8px)
);
}
</style>
</head>
<body class="font-poppins bg-gray-50">
<!-- Header -->
<header class="bg-minecraftDark text-white">
<div class="container mx-auto px-4 py-4 flex justify-between items-center">
<div class="flex items-center">
<div class="w-10 h-10 rounded-full bg-minecraftAccent flex items-center justify-center mr-3">
<i data-feather="box" class="text-white"></i>
</div>
<h1 class="text-2xl font-bold font-montserrat">MINECRAFT<span class="text-minecraftAccent">REALMS</span></h1>
</div>
<div class="hidden md:flex items-center space-x-6">
<a href="#" class="hover:text-minecraftAccent transition">Home</a>
<a href="#" class="hover:text-minecraftAccent transition">Worlds</a>
<a href="#" class="hover:text-minecraftAccent transition">Testimonials</a>
<a href="#" class="hover:text-minecraftAccent transition">FAQ</a>
</div>
<button class="md:hidden text-2xl">
<i data-feather="menu"></i>
</button>
</div>
</header>
<!-- Hero Section -->
<section class="hero-bg text-white py-20">
<div class="container mx-auto px-4 text-center">
<div class="max-w-3xl mx-auto">
<div class="inline-block mb-4 px-4 py-1 bg-minecraftAccent rounded-full text-sm font-semibold">
LIMITED TIME ACCESS
</div>
<h1 class="text-4xl md:text-6xl font-bold font-montserrat mb-6">
UNLOCK EXCLUSIVE <span class="text-minecraftAccent">MINECRAFT</span> WORLDS
</h1>
<p class="text-xl mb-8 max-w-2xl mx-auto">
Get instant access to premium Minecraft realms, adventure maps, and custom builds. Elevate your gameplay experience!
</p>
<div class="flex flex-col sm:flex-row justify-center space-y-4 sm:space-y-0 sm:space-x-6 mb-12">
<div class="bg-white text-minecraftDark p-4 rounded-lg shadow-lg flex items-center">
<i data-feather="map" class="text-minecraftAccent mr-3"></i>
<div>
<div class="font-bold">20+ Adventure Maps</div>
<div class="text-sm">Fully crafted experiences</div>
</div>
</div>
<div class="bg-white text-minecraftDark p-4 rounded-lg shadow-lg flex items-center">
<i data-feather="download" class="text-minecraftAccent mr-3"></i>
<div>
<div class="font-bold">Instant Access</div>
<div class="text-sm">Download immediately</div>
</div>
</div>
</div>
<button id="getAccessBtn" class="bg-minecraftAccent hover:bg-green-700 text-white font-bold py-4 px-10 rounded-full text-lg transition transform hover:scale-105 duration-300 shadow-lg">
GET ACCESS NOW <i data-feather="arrow-right" class="ml-2"></i>
</button>
<div class="mt-10 flex justify-center">
<div class="floating">
<i data-feather="chevron-down" class="text-2xl animate-bounce"></i>
</div>
</div>
</div>
</div>
</section>
<!-- Benefits Section -->
<section class="py-16 bg-white">
<div class="container mx-auto px-4">
<h2 class="text-3xl md:text-4xl font-bold text-center font-montserrat mb-16">Why Our Minecraft Worlds?</h2>
<div class="grid grid-cols-1 md:grid-cols-3 gap-8">
<div class="text-center p-8 rounded-xl bg-gray-50 border border-gray-100">
<div class="w-20 h-20 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="star" class="text-white"></i>
</div>
<h3 class="text-xl font-bold mb-3">Premium Quality</h3>
<p class="text-gray-600">Hand-crafted worlds with attention to detail and immersive gameplay experiences.</p>
</div>
<div class="text-center p-8 rounded-xl bg-gray-50 border border-gray-100">
<div class="w-20 h-20 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="check-circle" class="text-white"></i>
</div>
<h3 class="text-xl font-bold mb-3">Fully Tested</h3>
<p class="text-gray-600">All worlds are tested for compatibility and performance across Minecraft versions.</p>
</div>
<div class="text-center p-8 rounded-xl bg-gray-50 border border-gray-100">
<div class="w-20 h-20 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="refresh-cw" class="text-white"></i>
</div>
<h3 class="text-xl font-bold mb-3">Regular Updates</h3>
<p class="text-gray-600">New worlds added monthly with seasonal themes and special event content.</p>
</div>
</div>
</div>
</section>
<!-- Tools Showcase Section -->
<section class="py-16 bg-gray-50">
<div class="container mx-auto px-4">
<h2 class="text-3xl md:text-4xl font-bold text-center font-montserrat mb-16">AI-Powered Minecraft Tools</h2>
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
<div class="bg-white p-6 rounded-xl shadow-md hover:shadow-lg transition-shadow">
<div class="w-16 h-16 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="cpu" class="text-white"></i>
</div>
<h3 class="text-xl font-bold mb-3 text-center">World Generator AI</h3>
<p class="text-gray-600 mb-4">Generate unique Minecraft worlds with our advanced AI algorithm that creates stunning landscapes and structures.</p>
<div class="text-center">
<span class="inline-block bg-green-100 text-green-800 text-sm px-3 py-1 rounded-full">AI-Powered</span>
</div>
</div>
<div class="bg-white p-6 rounded-xl shadow-md hover:shadow-lg transition-shadow">
<div class="w-16 h-16 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="box" class="text-white"></i>
</div>
<h3 class="text-xl font-bold mb-3 text-center">Texture Pack Creator</h3>
<p class="text-gray-600 mb-4">Transform your Minecraft visuals with AI-generated texture packs that maintain the classic feel with modern enhancements.</p>
<div class="text-center">
<span class="inline-block bg-green-100 text-green-800 text-sm px-3 py-1 rounded-full">AI-Powered</span>
</div>
</div>
<div class="bg-white p-6 rounded-xl shadow-md hover:shadow-lg transition-shadow">
<div class="w-16 h-16 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="code" class="text-white"></i>
</div>
<h3 class="text-xl font-bold mb-3 text-center">Redstone Assistant</h3>
<p class="text-gray-600 mb-4">Get AI suggestions for complex Redstone contraptions and automate your Minecraft engineering projects.</p>
<div class="text-center">
<span class="inline-block bg-green-100 text-green-800 text-sm px-3 py-1 rounded-full">AI-Powered</span>
</div>
</div>
<div class="bg-white p-6 rounded-xl shadow-md hover:shadow-lg transition-shadow">
<div class="w-16 h-16 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="users" class="text-white"></i>
</div>
<h3 class="text-xl font-bold mb-3 text-center">Smart NPC Creator</h3>
<p class="text-gray-600 mb-4">Design intelligent NPCs with custom dialogues and behaviors using our AI character creation system.</p>
<div class="text-center">
<span class="inline-block bg-green-100 text-green-800 text-sm px-3 py-1 rounded-full">AI-Powered</span>
</div>
</div>
<div class="bg-white p-6 rounded-xl shadow-md hover:shadow-lg transition-shadow">
<div class="w-16 h-16 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="map" class="text-white"></i>
</div>
<h3 class="text-xl font-bold mb-3 text-center">Adventure Builder</h3>
<p class="text-gray-600 mb-4">Create custom adventure maps with AI-generated quests, puzzles, and storylines for endless gameplay.</p>
<div class="text-center">
<span class="inline-block bg-green-100 text-green-800 text-sm px-3 py-1 rounded-full">AI-Powered</span>
</div>
</div>
<div class="bg-white p-6 rounded-xl shadow-md hover:shadow-lg transition-shadow">
<div class="w-16 h-16 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="shield" class="text-white"></i>
</div>
<h3 class="text-xl font-bold mb-3 text-center">Server Protector</h3>
<p class="text-gray-600 mb-4">AI-powered security tools that detect and prevent griefing, cheating, and other malicious activities on your server.</p>
<div class="text-center">
<span class="inline-block bg-green-100 text-green-800 text-sm px-3 py-1 rounded-full">AI-Powered</span>
</div>
</div>
</div>
<div class="text-center mt-12">
<button class="bg-minecraftAccent hover:bg-green-700 text-white font-bold py-3 px-8 rounded-full transition transform hover:scale-105 duration-300">
EXPLORE ALL TOOLS
</button>
</div>
</div>
</section>
<!-- Countdown Timer -->
<section class="py-12 bg-minecraftDark text-white">
<div class="container mx-auto px-4 text-center">
<h2 class="text-2xl md:text-3xl font-bold mb-4">HURRY! LIMITED ACCESS WINDOW</h2>
<div class="flex justify-center space-x-4 mb-8">
<div class="countdown-item w-20 h-20 rounded-lg flex flex-col items-center justify-center">
<div id="days" class="极好的! 2xl font-bold">00</div>
<div class="text-sm">DAYS</div>
</div>
<div class="countdown-item w-20 h-20 rounded-lg flex flex-col items-center justify-center">
<div id="hours" class="text-2xl font-bold">00</div>
<div class="text极好的! SM">HOURS</div>
</div>
<div class="countdown-item w-20 h-20 rounded-lg flex flex-col items-center justify-center">
<div id="minutes" class="text-2xl font-bold">00</div>
<div class="text-sm">MINUTES</div>
</div>
<div class="countdown-item w-20 h-20 rounded-lg flex flex-col items-center justify-center">
<极好的! id="seconds" class="text-2xl font-bold">00</div>
<div class="text-sm">SECONDS</div>
</div>
</div>
<button id="countdownBtn" class="bg-minecraftAccent hover:bg-green-700 text-white font-bold py-3 px-8 rounded-full transition transform hover:scale-105 duration-300">
GET ACCESS NOW
</button>
</div>
</section>
<!-- Testimonials -->
<section class="py-16 bg-gray-50">
<div class="container mx-auto px-4">
<h2 class="text-3xl md:text-4xl font-bold text-center font-montserrat mb-16">What Players Say</h2>
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
<div class="bg-white p-6 rounded-xl shadow-md">
<div class="flex items-center mb-4">
<div class="w-12 h-12 rounded-full bg-minecraftAccent flex items-center justify-center text-white font-bold mr-3">MJ</div>
<div>
<div class="font-bold">Mike Johnson</div>
<div class="flex text-yellow-400">
★★★★★
</div>
</div>
</div>
<p class="text-gray-600">"The adventure maps are incredible! My friends and I have spent hours exploring these beautifully crafted worlds."</p>
</div>
<div class="bg-white p-6 rounded-xl shadow-md">
<div class="flex items-center mb-4">
<div class="w-12 h-12 rounded-full bg-minecraftAccent flex items-center justify-center text-white font-bold mr-3">SL</div>
<div>
<div class="font-bold">Sarah Lee</div>
<div class="flex text-yellow-400">
★★★★★
</div>
</div>
</div>
<p class="text-gray-600">"As a content creator, these worlds have given me amazing backdrops for my YouTube videos. Highly recommend!"</p>
</div>
<div class="bg-white p-6 rounded-xl shadow-md">
<div class="flex items-center mb-4">
<div class="w-12 h-12 rounded-full bg-minecraftAccent flex items-center justify-center text-white font-bold mr-3">DT</div>
<div>
<div class="font-bold">David Thompson</div>
<div class="flex text-yellow-400">
★★★★★
</div>
</div>
</div>
<p class="text-gray-600">"The castle build I downloaded was perfect for my server. The attention to detail is phenomenal!"</p>
</div>
</div>
</div>
</section>
<!-- FAQ Section -->
<section class="py-16 bg-white">
<div class="container mx-auto px-4">
<h2 class="text-3xl md:text-4xl font-bold text-center font-montserrat mb-16">Frequently Asked Questions</h2>
<div class="max-w-3xl mx-auto">
<div class="mb-6">
<div class="flex justify-between items-center cursor-pointer border-b border-gray-200 py-4">
<h3 class="text-lg font-semibold">How do I install these Minecraft worlds?</h3>
<i data-feather="chevron-down"></i>
</div>
<p class="mt-3 text-gray-600 hidden">After completing the verification process, you'll receive download links with detailed installation instructions. Most worlds simply need to be placed in your Minecraft saves folder.</p>
</div>
<div class="mb-6">
<div class="flex justify-between items-center cursor-pointer border-b border-gray-200 py-4">
<h3 class="text-lg font-semibold">What Minecraft versions are supported?</h3>
<i data-feather="chevron-down"></i>
</div>
<p class="mt-3 text-gray-600 hidden">Our worlds are compatible with Minecraft Java Edition 1.16+ and most work with Bedrock Edition as well. Each download page specifies version compatibility.</p>
</div>
<div class="mb-6">
<div class="flex justify-between items-center cursor-pointer border-b border-gray-200 py-4">
<h3 class="text-lg font-semibold">Can I use these on my server?</h3>
<i data-feather="chevron-down"></i>
</div>
<p class="mt-3 text-gray-600 hidden">Yes! All worlds come with a license for personal and server use. Commercial use requires additional permissions.</p>
</div>
<div class="mb-6">
<div class="flex justify-between items-center cursor-pointer border-b border-gray-200 py-4">
<h3 class="text-lg font-semibold">How often are new worlds added?</h3>
<i data-feather="chevron-down"></i>
</div>
<p class="mt-3 text-gray-600 hidden">We add 2-3 new worlds every month, with special seasonal content during holidays and Minecraft updates.</p>
</div>
</div>
</div>
</section>
<!-- Final CTA -->
<section class="py-20 bg-gradient-to-r from-minecraftDark to-minecraft text-white">
<div class="container mx-auto px-4 text-center">
<h2 class="text-3xl md:text-4xl font-bold font-montserrat mb-6">Ready to Explore Amazing Minecraft Worlds?</h2>
<p class="text-xl max-w-2xl mx-auto mb-10">Join thousands of players who have enhanced their Minecraft experience with our exclusive content.</p>
<button id="finalCtaBtn" class="bg-minecraftAccent hover:bg-green-700 text-white font-bold py-4 px-12 rounded-full text-lg transition transform hover:scale-105 duration-300 shadow-lg">
GET ACCESS NOW
</button>
</div>
</section>
<!-- Footer -->
<footer class="bg-minecraftDark text-gray-300 py-10">
<div class="container mx-auto px-4">
<div class="flex flex-col md:flex-row justify-between items-center">
<div class="mb-6 md:mb-0">
<div class="flex items-center">
<div class="w-8 h-8 rounded-full bg-minecraftAccent flex items-center justify-center mr-2">
<i data-feather="box" class="text-white"></i>
</div>
<h2 class="text-xl font-bold font-montserrat">MINECRAFT<span class="text-minecraftAccent">REALMS</span></h2>
</div>
<p class="mt-2 text-sm max-w-xs">Your portal to premium Minecraft worlds and adventures.</p>
</div>
<div class="flex space-x-6">
<a href="#" class="hover:text-white"><i data-feather="twitter"></i></a>
<a href="#" class="hover:text-white"><i data-feather="youtube"></i></a>
<a href="#" class="hover:text-white"><i data-feather="instagram"></i></a>
<a href="#" class="hover:text-white"><i data-feather="discord"></i></a>
</div>
</div>
<div class="border-t border-gray-800 mt-8 pt-8 text-center text-sm">
<p>&copy; 2023 MinecraftRealms. This is an independent service and is not affiliated with Mojang or Microsoft. Minecraft is a trademark of Mojang Studios.</p>
<div class="mt-4">
<a href="#" class="mx-2 hover:text-white">Privacy Policy</a>
<a href="#" class="mx-2 hover:text-white">Terms of Service</a>
<a href="#" class="mx-2 hover:text-white">Contact Us</a>
</div>
</div>
</div>
</footer>
<!-- Content Locker Modal -->
<div id="contentLockerModal" class="modal fixed inset-0 bg-black bg-opacity-75 flex items-center justify-center z-50 opacity-0 pointer-events-none">
<div class="modal-content bg-white rounded-xl w-full max-w-md mx-4 p-6 relative">
<button id="closeModal" class="absolute top-4 right-4 text-gray-500 hover:text-gray-700">
<i data-feather="x"></i>
</button>
<div class="text-center">
<div class="w-16 h-16 mx-auto bg-minecraftAccent rounded-full flex items-center justify-center mb-6">
<i data-feather="lock" class="text-white"></i>
</div>
<h3 class="text-2xl font-bold font-montserrat mb-4">Unlock Minecraft Worlds</h3>
<p class="text-gray-600 mb-6">Complete this quick step to access exclusive Minecraft content</p>
<div id="step1" class="step">
<div class="bg-gray-100 p-4 rounded-lg mb-6">
<div class="flex items-center mb-3">
<div class="w-8 h-8 rounded-full bg-minecraftAccent flex items-center justify-center text-white mr-3">
<span class="font-bold">1</span>
</div>
<h4 class="font-semibold">Verify Your Email</h4>
</div>
<p class="text-sm text-gray-600">Enter your email address to receive your access codes</p>
</div>
<form id="emailForm" class="mb-4">
<div class="mb-4">
<input type="email" id="userEmail" placeholder="Enter your email address" class="w-full px-4 py-3 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-minecraftAccent">
</div>
<button type="submit" class="w-full bg-minecraftAccent hover:bg-green-700 text-white font-bold py-3 px-4 rounded-lg transition">
VERIFY EMAIL
</button>
</form>
<p class="text-xs text-gray-500">We respect your privacy. Your information is secure and will not be shared.</p>
</div>
<div id="step2" class="step hidden">
<div class="bg-gray-100 p-4 rounded-lg mb-6">
<div class="flex items-center mb-3">
<div class="w-8 h-8 rounded-full bg-minecraftAccent flex items-center justify-center text-white mr-3">
<span class="font-bold">2</span>
</div>
<h4 class="font-semibold">Complete Verification</h4>
</div>
<p class="text-sm text-gray-600">Check your email for the verification code</p>
</div>
<form id="verificationForm" class="mb-4">
<div class="mb-4">
<input type="text" id="verificationCode" placeholder="Enter verification code" class="w-full px-4 py-3 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-minecraftAccent">
</div>
<button type="submit" class="w-full bg-minecraftAccent hover:bg-green-700 text-white font-bold py-3 px-4 rounded-lg transition">
SUBMIT CODE
</button>
</form>
<p class="text-xs text-gray-500">Didn't receive the code? <a href="#" class="text-minecraftAccent">Resend</a></p>
</div>
<div id="step3" class="step hidden">
<div class="flex justify-center mb-6">
<div class="loader ease-linear rounded-full border-4 border-t-4 border-gray-200 h-12 w-12"></div>
</div>
<h4 class="font-bold text-lg mb-2">Unlocking Your Content...</h4>
<p class="text-gray-600 mb-6">Please wait while we prepare your exclusive Minecraft worlds</p>
</div>
<div id="step4" class="step hidden">
<div class="w-16 h-16 mx-auto bg-green-500 rounded-full flex items-center justify-center mb-6">
<i data-feather="check" class="text-white"></i>
</div>
<h4 class="font-bold text-2xl mb-4 text-minecraftAccent">Success!</h4>
<p class="text-gray-600 mb-6">Your content is ready! Redirecting to your downloads...</p>
</div>
</div>
</div>
</div>
<script>
// Initialize Feather Icons
feather.replace();
// Countdown Timer
function updateCountdown() {
const now = new Date();
const targetDate = new Date();
targetDate.setDate(now.getDate() + 3);
const diff = targetDate - now;
const days = Math.floor(diff / (1000 * 60 * 60 * 24));
const hours = Math.floor((diff % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
const minutes = Math.floor((diff % (1000 * 60 * 60)) / (1000 * 60));
const seconds = Math.floor((diff % (1000 * 60)) / 1000);
document.getElementById('days').textContent = days.toString().padStart(2, '0');
document.getElementById('hours').textContent = hours.toString().padStart(2, '0');
document.getElementById('minutes').textContent = minutes.toString().padStart(2, '0');
document.getElementById('seconds').textContent = seconds.toString().padStart(2, '0');
}
setInterval(updateCountdown, 1000);
updateCountdown();
// Modal functionality
const modal = document.getElementById('contentLockerModal');
const closeModal = document.getElementById('closeModal');
const getAccessBtn = document.getElementById('getAccessBtn');
const countdownBtn = document.getElementById('countdownBtn');
const finalCtaBtn = document.getElementById('finalCtaBtn');
const emailForm = document.getElementById('emailForm');
const verificationForm = document.getElementById('verificationForm');
function openModal() {
modal.classList.remove('opacity-0', 'pointer-events-none');
modal.classList.add('show');
document.body.style.overflow = 'hidden';
}
function closeModalFunc() {
modal.classList.remove('show');
modal.classList.add('opacity-0', 'pointer-events-none');
document.body.style.overflow = 'auto';
// Reset to step 1
document.getElementById('step1').classList.remove('hidden');
document.getElementById('step2').classList.add('hidden');
document.getElementById('step3').classList.add('hidden');
document.getElementById('step4').classList.add('hidden');
}
getAccessBtn.addEventListener('click', openModal);
countdownBtn.addEventListener('click', openModal);
finalCtaBtn.addEventListener('click', openModal);
closeModal.addEventListener('click', closeModalFunc);
// Close modal when clicking outside
modal.addEventListener('click', (e) => {
if (e.target === modal) {
closeModalFunc();
}
});
// Form submission
emailForm.addEventListener('submit', (e) => {
e.preventDefault();
const email = document.getElementById('userEmail').value;
if (email && validateEmail(email)) {
document.getElementById('step1').classList.add('hidden');
document.getElementById('step2').classList.remove('hidden');
} else {
alert('Please enter a valid email address');
}
});
verificationForm.addEventListener('submit', (e) => {
e.preventDefault();
const code = document.getElementById('verificationCode').value;
if (code) {
document.getElementById('step2').classList.add('hidden');
document.getElementById('step3').classList.remove('hidden');
// Simulate processing
setTimeout(() => {
document.getElementById('step3').classList.add('hidden');
document.getElementById('step4').classList.remove('hidden');
// Redirect after a delay
setTimeout(() => {
// Replace with your actual offer URL
window.location.href = 'https://example.com/minecraft-offer';
}, 3000);
}, 2000);
} else {
alert('Please enter the verification code');
}
});
// Email validation
function validateEmail(email) {
const re = /^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
return re.test(String(email).toLowerCase());
}
// FAQ accordion
const faqHeaders = document.querySelectorAll('.cursor-pointer');
faqHeaders.forEach(header => {
header.addEventListener('click', () => {
const content = header.nextElementSibling;
content.classList.toggle('hidden');
const icon = header.querySelector('i');
if (icon.getAttribute('data-feather') === 'chevron-down') {
icon.setAttribute('data-feather', 'chevron-up');
} else {
icon.setAttribute('data-feather', 'chevron-down');
}
feather.replace();
});
});
</script>
<script>feather.replace();</script>
</body>
</html>