Spaces:
Running
Running
Add 2 files
Browse files- index.html +276 -103
- prompts.txt +4 -1
index.html
CHANGED
|
@@ -52,14 +52,29 @@
|
|
| 52 |
justify-content: center;
|
| 53 |
font-size: 12px;
|
| 54 |
}
|
| 55 |
-
.
|
| 56 |
-
|
| 57 |
-
|
| 58 |
-
|
| 59 |
}
|
| 60 |
-
.checkout-
|
| 61 |
-
|
| 62 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 63 |
}
|
| 64 |
</style>
|
| 65 |
</head>
|
|
@@ -69,7 +84,8 @@
|
|
| 69 |
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
|
| 70 |
<div class="flex items-center justify-between h-16">
|
| 71 |
<div class="flex items-center">
|
| 72 |
-
<div class="flex-shrink-0">
|
|
|
|
| 73 |
<span class="text-purple-400 font-bold text-xl">PsycheBotanica</span>
|
| 74 |
</div>
|
| 75 |
<div class="hidden md:block">
|
|
@@ -151,75 +167,6 @@
|
|
| 151 |
</div>
|
| 152 |
</div>
|
| 153 |
|
| 154 |
-
<!-- Checkout Modal -->
|
| 155 |
-
<div id="checkout-modal" class="checkout-modal fixed inset-0 bg-black bg-opacity-70 flex items-center justify-center z-30">
|
| 156 |
-
<div class="bg-gray-800 rounded-lg shadow-xl w-full max-w-md mx-4">
|
| 157 |
-
<div class="p-6">
|
| 158 |
-
<div class="flex justify-between items-center mb-6">
|
| 159 |
-
<h2 class="text-2xl font-bold text-purple-300">Complete Your Journey</h2>
|
| 160 |
-
<button id="close-checkout" class="text-gray-400 hover:text-white">
|
| 161 |
-
<i class="fas fa-times text-xl"></i>
|
| 162 |
-
</button>
|
| 163 |
-
</div>
|
| 164 |
-
|
| 165 |
-
<form id="checkout-form" class="space-y-4">
|
| 166 |
-
<div>
|
| 167 |
-
<label for="full-name" class="block text-sm font-medium text-gray-300 mb-1">Full Name</label>
|
| 168 |
-
<input type="text" id="full-name" required class="w-full px-4 py-2 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 169 |
-
</div>
|
| 170 |
-
|
| 171 |
-
<div>
|
| 172 |
-
<label for="email" class="block text-sm font-medium text-gray-300 mb-1">Email</label>
|
| 173 |
-
<input type="email" id="email" required class="w-full px-4 py-2 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 174 |
-
</div>
|
| 175 |
-
|
| 176 |
-
<div>
|
| 177 |
-
<label for="address" class="block text-sm font-medium text-gray-300 mb-1">Shipping Address</label>
|
| 178 |
-
<textarea id="address" rows="3" required class="w-full px-4 py-2 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white"></textarea>
|
| 179 |
-
</div>
|
| 180 |
-
|
| 181 |
-
<div>
|
| 182 |
-
<label for="card-number" class="block text-sm font-medium text-gray-300 mb-1">Card Number</label>
|
| 183 |
-
<input type="text" id="card-number" required class="w-full px-4 py-2 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white" placeholder="4242 4242 4242 4242">
|
| 184 |
-
</div>
|
| 185 |
-
|
| 186 |
-
<div class="grid grid-cols-2 gap-4">
|
| 187 |
-
<div>
|
| 188 |
-
<label for="expiry" class="block text-sm font-medium text-gray-300 mb-1">Expiry Date</label>
|
| 189 |
-
<input type="text" id="expiry" required class="w-full px-4 py-2 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white" placeholder="MM/YY">
|
| 190 |
-
</div>
|
| 191 |
-
<div>
|
| 192 |
-
<label for="cvc" class="block text-sm font-medium text-gray-300 mb-1">CVC</label>
|
| 193 |
-
<input type="text" id="cvc" required class="w-full px-4 py-2 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white" placeholder="123">
|
| 194 |
-
</div>
|
| 195 |
-
</div>
|
| 196 |
-
|
| 197 |
-
<div class="pt-4">
|
| 198 |
-
<button type="submit" class="w-full bg-purple-600 hover:bg-purple-700 text-white font-bold py-3 px-6 rounded-full transition duration-300">
|
| 199 |
-
Complete Purchase
|
| 200 |
-
</button>
|
| 201 |
-
</div>
|
| 202 |
-
</form>
|
| 203 |
-
</div>
|
| 204 |
-
</div>
|
| 205 |
-
</div>
|
| 206 |
-
|
| 207 |
-
<!-- Order Confirmation Modal -->
|
| 208 |
-
<div id="confirmation-modal" class="checkout-modal fixed inset-0 bg-black bg-opacity-70 flex items-center justify-center z-30">
|
| 209 |
-
<div class="bg-gray-800 rounded-lg shadow-xl w-full max-w-md mx-4">
|
| 210 |
-
<div class="p-6 text-center">
|
| 211 |
-
<div class="text-purple-400 text-6xl mb-4">
|
| 212 |
-
<i class="fas fa-check-circle"></i>
|
| 213 |
-
</div>
|
| 214 |
-
<h2 class="text-2xl font-bold text-white mb-2">Order Confirmed!</h2>
|
| 215 |
-
<p class="text-gray-300 mb-6">Thank you for your purchase. Your sacred remedies will be prepared with intention and shipped within 2-3 business days.</p>
|
| 216 |
-
<button id="close-confirmation" class="bg-purple-600 hover:bg-purple-700 text-white font-bold py-2 px-6 rounded-full transition duration-300">
|
| 217 |
-
Continue Journey
|
| 218 |
-
</button>
|
| 219 |
-
</div>
|
| 220 |
-
</div>
|
| 221 |
-
</div>
|
| 222 |
-
|
| 223 |
<!-- Hero Section -->
|
| 224 |
<section id="home" class="hero-bg min-h-screen flex items-center justify-center pt-16">
|
| 225 |
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 text-center">
|
|
@@ -371,18 +318,18 @@
|
|
| 371 |
|
| 372 |
<div class="grid md:grid-cols-2 gap-12">
|
| 373 |
<div>
|
| 374 |
-
<form class="space-y-6">
|
| 375 |
<div>
|
| 376 |
-
<label for="name" class="block text-sm font-medium text-gray-300 mb-1">Name</label>
|
| 377 |
-
<input type="text" id="name" class="w-full px-4 py-3 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 378 |
</div>
|
| 379 |
<div>
|
| 380 |
-
<label for="email" class="block text-sm font-medium text-gray-300 mb-1">Email</label>
|
| 381 |
-
<input type="email" id="email" class="w-full px-4 py-3 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 382 |
</div>
|
| 383 |
<div>
|
| 384 |
-
<label for="message" class="block text-sm font-medium text-gray-300 mb-1">Message</label>
|
| 385 |
-
<textarea id="message" rows="5" class="w-full px-4 py-3 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white"></textarea>
|
| 386 |
</div>
|
| 387 |
<button type="submit" class="w-full bg-purple-600 hover:bg-purple-700 text-white font-bold py-3 px-6 rounded-full transition duration-300">
|
| 388 |
Send Message
|
|
@@ -486,6 +433,170 @@
|
|
| 486 |
</div>
|
| 487 |
</footer>
|
| 488 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 489 |
<script>
|
| 490 |
// Cart functionality
|
| 491 |
let cart = [];
|
|
@@ -502,11 +613,16 @@
|
|
| 502 |
const mobileCartBadge = document.getElementById('mobile-cart-badge');
|
| 503 |
const addToCartButtons = document.querySelectorAll('.add-to-cart');
|
| 504 |
const checkoutButton = document.getElementById('checkout-button');
|
| 505 |
-
|
|
|
|
|
|
|
| 506 |
const closeCheckout = document.getElementById('close-checkout');
|
| 507 |
-
const
|
| 508 |
-
const
|
| 509 |
-
const
|
|
|
|
|
|
|
|
|
|
| 510 |
|
| 511 |
// Toggle cart panel
|
| 512 |
function toggleCart() {
|
|
@@ -598,7 +714,7 @@
|
|
| 598 |
// Add event listeners to quantity buttons
|
| 599 |
document.querySelectorAll('.decrease-quantity').forEach(button => {
|
| 600 |
button.addEventListener('click', (e) => {
|
| 601 |
-
const id =
|
| 602 |
const item = cart.find(item => item.id === id);
|
| 603 |
|
| 604 |
if (item.quantity > 1) {
|
|
@@ -613,7 +729,7 @@
|
|
| 613 |
|
| 614 |
document.querySelectorAll('.increase-quantity').forEach(button => {
|
| 615 |
button.addEventListener('click', (e) => {
|
| 616 |
-
const id =
|
| 617 |
const item = cart.find(item => item.id === id);
|
| 618 |
item.quantity += 1;
|
| 619 |
updateCart();
|
|
@@ -622,7 +738,7 @@
|
|
| 622 |
|
| 623 |
document.querySelectorAll('.remove-item').forEach(button => {
|
| 624 |
button.addEventListener('click', (e) => {
|
| 625 |
-
const id =
|
| 626 |
cart = cart.filter(item => item.id !== id);
|
| 627 |
updateCart();
|
| 628 |
});
|
|
@@ -650,31 +766,88 @@
|
|
| 650 |
// Checkout functionality
|
| 651 |
checkoutButton.addEventListener('click', () => {
|
| 652 |
if (cart.length > 0) {
|
| 653 |
-
|
| 654 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 655 |
}
|
| 656 |
});
|
| 657 |
|
|
|
|
| 658 |
closeCheckout.addEventListener('click', () => {
|
| 659 |
-
|
| 660 |
});
|
| 661 |
|
| 662 |
-
|
| 663 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 664 |
|
| 665 |
-
//
|
| 666 |
-
|
|
|
|
| 667 |
|
| 668 |
-
|
| 669 |
-
|
|
|
|
| 670 |
|
| 671 |
-
// Clear
|
| 672 |
cart = [];
|
| 673 |
updateCart();
|
| 674 |
});
|
| 675 |
|
| 676 |
-
|
| 677 |
-
|
|
|
|
| 678 |
});
|
| 679 |
|
| 680 |
// Mobile menu toggle
|
|
|
|
| 52 |
justify-content: center;
|
| 53 |
font-size: 12px;
|
| 54 |
}
|
| 55 |
+
.leaf-logo {
|
| 56 |
+
color: #9f7aea;
|
| 57 |
+
font-size: 1.75rem;
|
| 58 |
+
margin-right: 0.5rem;
|
| 59 |
}
|
| 60 |
+
.checkout-container {
|
| 61 |
+
max-width: 800px;
|
| 62 |
+
margin: 0 auto;
|
| 63 |
+
padding: 2rem;
|
| 64 |
+
}
|
| 65 |
+
.payment-method {
|
| 66 |
+
border: 1px solid #4a5568;
|
| 67 |
+
border-radius: 0.5rem;
|
| 68 |
+
padding: 1rem;
|
| 69 |
+
margin-bottom: 1rem;
|
| 70 |
+
transition: all 0.3s;
|
| 71 |
+
}
|
| 72 |
+
.payment-method:hover {
|
| 73 |
+
border-color: #9f7aea;
|
| 74 |
+
}
|
| 75 |
+
.payment-method.selected {
|
| 76 |
+
border-color: #9f7aea;
|
| 77 |
+
background-color: rgba(159, 122, 234, 0.1);
|
| 78 |
}
|
| 79 |
</style>
|
| 80 |
</head>
|
|
|
|
| 84 |
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
|
| 85 |
<div class="flex items-center justify-between h-16">
|
| 86 |
<div class="flex items-center">
|
| 87 |
+
<div class="flex-shrink-0 flex items-center">
|
| 88 |
+
<i class="fas fa-leaf leaf-logo"></i>
|
| 89 |
<span class="text-purple-400 font-bold text-xl">PsycheBotanica</span>
|
| 90 |
</div>
|
| 91 |
<div class="hidden md:block">
|
|
|
|
| 167 |
</div>
|
| 168 |
</div>
|
| 169 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 170 |
<!-- Hero Section -->
|
| 171 |
<section id="home" class="hero-bg min-h-screen flex items-center justify-center pt-16">
|
| 172 |
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 text-center">
|
|
|
|
| 318 |
|
| 319 |
<div class="grid md:grid-cols-2 gap-12">
|
| 320 |
<div>
|
| 321 |
+
<form id="contact-form" class="space-y-6">
|
| 322 |
<div>
|
| 323 |
+
<label for="contact-name" class="block text-sm font-medium text-gray-300 mb-1">Name *</label>
|
| 324 |
+
<input type="text" id="contact-name" name="name" required class="w-full px-4 py-3 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 325 |
</div>
|
| 326 |
<div>
|
| 327 |
+
<label for="contact-email" class="block text-sm font-medium text-gray-300 mb-1">Email *</label>
|
| 328 |
+
<input type="email" id="contact-email" name="email" required class="w-full px-4 py-3 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 329 |
</div>
|
| 330 |
<div>
|
| 331 |
+
<label for="contact-message" class="block text-sm font-medium text-gray-300 mb-1">Message *</label>
|
| 332 |
+
<textarea id="contact-message" name="message" rows="5" required class="w-full px-4 py-3 bg-gray-700 border border-gray-600 rounded-lg focus:ring-purple-500 focus:border-purple-500 text-white"></textarea>
|
| 333 |
</div>
|
| 334 |
<button type="submit" class="w-full bg-purple-600 hover:bg-purple-700 text-white font-bold py-3 px-6 rounded-full transition duration-300">
|
| 335 |
Send Message
|
|
|
|
| 433 |
</div>
|
| 434 |
</footer>
|
| 435 |
|
| 436 |
+
<!-- Checkout Page (hidden by default) -->
|
| 437 |
+
<div id="checkout-page" class="hidden fixed inset-0 bg-gray-900 bg-opacity-90 z-30 overflow-y-auto">
|
| 438 |
+
<div class="checkout-container bg-gray-800 rounded-lg shadow-2xl my-12">
|
| 439 |
+
<div class="flex justify-between items-center mb-8">
|
| 440 |
+
<h2 class="text-3xl font-bold text-purple-300 flex items-center">
|
| 441 |
+
<i class="fas fa-leaf leaf-logo mr-3"></i>
|
| 442 |
+
Secure Checkout
|
| 443 |
+
</h2>
|
| 444 |
+
<button id="close-checkout" class="text-gray-400 hover:text-white text-2xl">
|
| 445 |
+
<i class="fas fa-times"></i>
|
| 446 |
+
</button>
|
| 447 |
+
</div>
|
| 448 |
+
|
| 449 |
+
<div class="grid md:grid-cols-2 gap-8">
|
| 450 |
+
<!-- Order Summary -->
|
| 451 |
+
<div class="bg-gray-700 p-6 rounded-lg">
|
| 452 |
+
<h3 class="text-xl font-bold text-white mb-6 border-b border-gray-600 pb-2">Order Summary</h3>
|
| 453 |
+
<div id="checkout-items" class="space-y-4 mb-6">
|
| 454 |
+
<!-- Items will be dynamically inserted here -->
|
| 455 |
+
</div>
|
| 456 |
+
<div class="border-t border-gray-600 pt-4 space-y-3">
|
| 457 |
+
<div class="flex justify-between">
|
| 458 |
+
<span class="text-gray-300">Subtotal</span>
|
| 459 |
+
<span id="checkout-subtotal" class="text-white font-bold">$0.00</span>
|
| 460 |
+
</div>
|
| 461 |
+
<div class="flex justify-between">
|
| 462 |
+
<span class="text-gray-300">Shipping</span>
|
| 463 |
+
<span class="text-white font-bold">Free</span>
|
| 464 |
+
</div>
|
| 465 |
+
<div class="flex justify-between text-lg pt-2">
|
| 466 |
+
<span class="text-gray-300">Total</span>
|
| 467 |
+
<span id="checkout-total" class="text-purple-300 font-bold">$0.00</span>
|
| 468 |
+
</div>
|
| 469 |
+
</div>
|
| 470 |
+
</div>
|
| 471 |
+
|
| 472 |
+
<!-- Payment Information -->
|
| 473 |
+
<div>
|
| 474 |
+
<h3 class="text-xl font-bold text-white mb-6 border-b border-gray-600 pb-2">Payment Information</h3>
|
| 475 |
+
|
| 476 |
+
<div class="mb-6">
|
| 477 |
+
<label class="block text-gray-300 mb-2">Payment Method</label>
|
| 478 |
+
<div class="space-y-3">
|
| 479 |
+
<div class="payment-method" data-method="credit">
|
| 480 |
+
<div class="flex items-center">
|
| 481 |
+
<input type="radio" name="payment-method" id="credit-card" class="mr-3" checked>
|
| 482 |
+
<label for="credit-card" class="font-medium text-white">Credit Card</label>
|
| 483 |
+
</div>
|
| 484 |
+
<div class="mt-3 ml-6">
|
| 485 |
+
<div class="grid grid-cols-2 gap-4">
|
| 486 |
+
<div>
|
| 487 |
+
<label for="card-number" class="block text-sm text-gray-400 mb-1">Card Number</label>
|
| 488 |
+
<input type="text" id="card-number" placeholder="1234 5678 9012 3456" class="w-full px-3 py-2 bg-gray-700 border border-gray-600 rounded focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 489 |
+
</div>
|
| 490 |
+
<div>
|
| 491 |
+
<label for="card-cvc" class="block text-sm text-gray-400 mb-1">CVC</label>
|
| 492 |
+
<input type="text" id="card-cvc" placeholder="123" class="w-full px-3 py-2 bg-gray-700 border border-gray-600 rounded focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 493 |
+
</div>
|
| 494 |
+
</div>
|
| 495 |
+
<div class="grid grid-cols-2 gap-4 mt-3">
|
| 496 |
+
<div>
|
| 497 |
+
<label for="card-expiry" class="block text-sm text-gray-400 mb-1">Expiry Date</label>
|
| 498 |
+
<input type="text" id="card-expiry" placeholder="MM/YY" class="w-full px-3 py-2 bg-gray-700 border border-gray-600 rounded focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 499 |
+
</div>
|
| 500 |
+
<div>
|
| 501 |
+
<label for="card-name" class="block text-sm text-gray-400 mb-1">Name on Card</label>
|
| 502 |
+
<input type="text" id="card-name" placeholder="John Doe" class="w-full px-3 py-2 bg-gray-700 border border-gray-600 rounded focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 503 |
+
</div>
|
| 504 |
+
</div>
|
| 505 |
+
</div>
|
| 506 |
+
</div>
|
| 507 |
+
|
| 508 |
+
<div class="payment-method" data-method="paypal">
|
| 509 |
+
<div class="flex items-center">
|
| 510 |
+
<input type="radio" name="payment-method" id="paypal" class="mr-3">
|
| 511 |
+
<label for="paypal" class="font-medium text-white">PayPal</label>
|
| 512 |
+
</div>
|
| 513 |
+
<div class="mt-3 ml-6 text-sm text-gray-400">
|
| 514 |
+
You'll be redirected to PayPal to complete your payment securely.
|
| 515 |
+
</div>
|
| 516 |
+
</div>
|
| 517 |
+
|
| 518 |
+
<div class="payment-method" data-method="crypto">
|
| 519 |
+
<div class="flex items-center">
|
| 520 |
+
<input type="radio" name="payment-method" id="crypto" class="mr-3">
|
| 521 |
+
<label for="crypto" class="font-medium text-white">Cryptocurrency</label>
|
| 522 |
+
</div>
|
| 523 |
+
<div class="mt-3 ml-6 text-sm text-gray-400">
|
| 524 |
+
Select from Bitcoin, Ethereum, or other cryptocurrencies.
|
| 525 |
+
</div>
|
| 526 |
+
</div>
|
| 527 |
+
</div>
|
| 528 |
+
</div>
|
| 529 |
+
|
| 530 |
+
<!-- Shipping Information -->
|
| 531 |
+
<h3 class="text-xl font-bold text-white mb-4 border-b border-gray-600 pb-2">Shipping Information</h3>
|
| 532 |
+
<div class="space-y-4">
|
| 533 |
+
<div>
|
| 534 |
+
<label for="shipping-name" class="block text-sm text-gray-400 mb-1">Full Name</label>
|
| 535 |
+
<input type="text" id="shipping-name" class="w-full px-3 py-2 bg-gray-700 border border-gray-600 rounded focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 536 |
+
</div>
|
| 537 |
+
<div>
|
| 538 |
+
<label for="shipping-address" class="block text-sm text-gray-400 mb-1">Address</label>
|
| 539 |
+
<input type="text" id="shipping-address" class="w-full px-3 py-2 bg-gray-700 border border-gray-600 rounded focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 540 |
+
</div>
|
| 541 |
+
<div class="grid grid-cols-2 gap-4">
|
| 542 |
+
<div>
|
| 543 |
+
<label for="shipping-city" class="block text-sm text-gray-400 mb-1">City</label>
|
| 544 |
+
<input type="text" id="shipping-city" class="w-full px-3 py-2 bg-gray-700 border border-gray-600 rounded focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 545 |
+
</div>
|
| 546 |
+
<div>
|
| 547 |
+
<label for="shipping-zip" class="block text-sm text-gray-400 mb-1">ZIP Code</label>
|
| 548 |
+
<input type="text" id="shipping-zip" class="w-full px-3 py-2 bg-gray-700 border border-gray-600 rounded focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 549 |
+
</div>
|
| 550 |
+
</div>
|
| 551 |
+
<div>
|
| 552 |
+
<label for="shipping-country" class="block text-sm text-gray-400 mb-1">Country</label>
|
| 553 |
+
<select id="shipping-country" class="w-full px-3 py-2 bg-gray-700 border border-gray-600 rounded focus:ring-purple-500 focus:border-purple-500 text-white">
|
| 554 |
+
<option>United States</option>
|
| 555 |
+
<option>Canada</option>
|
| 556 |
+
<option>United Kingdom</option>
|
| 557 |
+
<option>Australia</option>
|
| 558 |
+
<option>Other</option>
|
| 559 |
+
</select>
|
| 560 |
+
</div>
|
| 561 |
+
</div>
|
| 562 |
+
|
| 563 |
+
<!-- Terms and Submit -->
|
| 564 |
+
<div class="mt-8 space-y-4">
|
| 565 |
+
<div class="flex items-start">
|
| 566 |
+
<input type="checkbox" id="terms" class="mt-1 mr-3">
|
| 567 |
+
<label for="terms" class="text-sm text-gray-400">
|
| 568 |
+
I agree to the <a href="#" class="text-purple-400 hover:text-purple-300">Terms of Service</a> and <a href="#" class="text-purple-400 hover:text-purple-300">Privacy Policy</a>. I understand that these products are for spiritual and wellness purposes only.
|
| 569 |
+
</label>
|
| 570 |
+
</div>
|
| 571 |
+
<button id="submit-order" class="w-full bg-purple-600 hover:bg-purple-700 text-white font-bold py-3 px-6 rounded-full transition duration-300">
|
| 572 |
+
Complete Sacred Purchase
|
| 573 |
+
</button>
|
| 574 |
+
</div>
|
| 575 |
+
</div>
|
| 576 |
+
</div>
|
| 577 |
+
</div>
|
| 578 |
+
</div>
|
| 579 |
+
|
| 580 |
+
<!-- Payment Success Modal -->
|
| 581 |
+
<div id="payment-success" class="hidden fixed inset-0 bg-gray-900 bg-opacity-90 z-40 flex items-center justify-center">
|
| 582 |
+
<div class="bg-gray-800 rounded-lg shadow-2xl p-8 max-w-md text-center">
|
| 583 |
+
<div class="text-green-400 text-6xl mb-6">
|
| 584 |
+
<i class="fas fa-check-circle"></i>
|
| 585 |
+
</div>
|
| 586 |
+
<h2 class="text-2xl font-bold text-white mb-4">Payment Successful!</h2>
|
| 587 |
+
<p class="text-gray-300 mb-6">
|
| 588 |
+
Thank you for your sacred purchase. Your order has been confirmed and will be prepared with intention.
|
| 589 |
+
</p>
|
| 590 |
+
<div class="text-purple-400 text-sm mb-6">
|
| 591 |
+
<p>Order #: <span id="order-number" class="text-white">PSY-2023-12345</span></p>
|
| 592 |
+
<p>Estimated Delivery: <span class="text-white">3-5 business days</span></p>
|
| 593 |
+
</div>
|
| 594 |
+
<button id="close-success" class="bg-purple-600 hover:bg-purple-700 text-white font-bold py-2 px-6 rounded-full transition duration-300">
|
| 595 |
+
Return to Shop
|
| 596 |
+
</button>
|
| 597 |
+
</div>
|
| 598 |
+
</div>
|
| 599 |
+
|
| 600 |
<script>
|
| 601 |
// Cart functionality
|
| 602 |
let cart = [];
|
|
|
|
| 613 |
const mobileCartBadge = document.getElementById('mobile-cart-badge');
|
| 614 |
const addToCartButtons = document.querySelectorAll('.add-to-cart');
|
| 615 |
const checkoutButton = document.getElementById('checkout-button');
|
| 616 |
+
|
| 617 |
+
// Checkout elements
|
| 618 |
+
const checkoutPage = document.getElementById('checkout-page');
|
| 619 |
const closeCheckout = document.getElementById('close-checkout');
|
| 620 |
+
const checkoutItems = document.getElementById('checkout-items');
|
| 621 |
+
const checkoutSubtotal = document.getElementById('checkout-subtotal');
|
| 622 |
+
const checkoutTotal = document.getElementById('checkout-total');
|
| 623 |
+
const submitOrder = document.getElementById('submit-order');
|
| 624 |
+
const paymentSuccess = document.getElementById('payment-success');
|
| 625 |
+
const closeSuccess = document.getElementById('close-success');
|
| 626 |
|
| 627 |
// Toggle cart panel
|
| 628 |
function toggleCart() {
|
|
|
|
| 714 |
// Add event listeners to quantity buttons
|
| 715 |
document.querySelectorAll('.decrease-quantity').forEach(button => {
|
| 716 |
button.addEventListener('click', (e) => {
|
| 717 |
+
const id = button.getAttribute('data-id');
|
| 718 |
const item = cart.find(item => item.id === id);
|
| 719 |
|
| 720 |
if (item.quantity > 1) {
|
|
|
|
| 729 |
|
| 730 |
document.querySelectorAll('.increase-quantity').forEach(button => {
|
| 731 |
button.addEventListener('click', (e) => {
|
| 732 |
+
const id = button.getAttribute('data-id');
|
| 733 |
const item = cart.find(item => item.id === id);
|
| 734 |
item.quantity += 1;
|
| 735 |
updateCart();
|
|
|
|
| 738 |
|
| 739 |
document.querySelectorAll('.remove-item').forEach(button => {
|
| 740 |
button.addEventListener('click', (e) => {
|
| 741 |
+
const id = button.getAttribute('data-id');
|
| 742 |
cart = cart.filter(item => item.id !== id);
|
| 743 |
updateCart();
|
| 744 |
});
|
|
|
|
| 766 |
// Checkout functionality
|
| 767 |
checkoutButton.addEventListener('click', () => {
|
| 768 |
if (cart.length > 0) {
|
| 769 |
+
// Show checkout page
|
| 770 |
+
checkoutPage.classList.remove('hidden');
|
| 771 |
+
|
| 772 |
+
// Populate checkout items
|
| 773 |
+
checkoutItems.innerHTML = '';
|
| 774 |
+
cart.forEach(item => {
|
| 775 |
+
const checkoutItem = document.createElement('div');
|
| 776 |
+
checkoutItem.className = 'flex justify-between items-center';
|
| 777 |
+
checkoutItem.innerHTML = `
|
| 778 |
+
<div>
|
| 779 |
+
<h4 class="font-medium text-white">${item.name}</h4>
|
| 780 |
+
<p class="text-purple-400">$${item.price.toFixed(2)} × ${item.quantity}</p>
|
| 781 |
+
</div>
|
| 782 |
+
<span class="text-white font-bold">$${(item.price * item.quantity).toFixed(2)}</span>
|
| 783 |
+
`;
|
| 784 |
+
checkoutItems.appendChild(checkoutItem);
|
| 785 |
+
});
|
| 786 |
+
|
| 787 |
+
// Update checkout totals
|
| 788 |
+
const subtotal = cart.reduce((sum, item) => sum + (item.price * item.quantity), 0);
|
| 789 |
+
checkoutSubtotal.textContent = `$${subtotal.toFixed(2)}`;
|
| 790 |
+
checkoutTotal.textContent = `$${subtotal.toFixed(2)}`;
|
| 791 |
+
|
| 792 |
+
// Close cart if open
|
| 793 |
+
if (cartPanel.classList.contains('open')) {
|
| 794 |
+
cartPanel.classList.remove('open');
|
| 795 |
+
}
|
| 796 |
+
} else {
|
| 797 |
+
alert('Your cart is empty. Please add items before checkout.');
|
| 798 |
}
|
| 799 |
});
|
| 800 |
|
| 801 |
+
// Close checkout
|
| 802 |
closeCheckout.addEventListener('click', () => {
|
| 803 |
+
checkoutPage.classList.add('hidden');
|
| 804 |
});
|
| 805 |
|
| 806 |
+
// Payment method selection
|
| 807 |
+
document.querySelectorAll('.payment-method').forEach(method => {
|
| 808 |
+
method.addEventListener('click', (e) => {
|
| 809 |
+
// Don't toggle if clicking on input directly
|
| 810 |
+
if (e.target.tagName !== 'INPUT') {
|
| 811 |
+
const radio = method.querySelector('input[type="radio"]');
|
| 812 |
+
radio.checked = true;
|
| 813 |
+
|
| 814 |
+
// Update styling
|
| 815 |
+
document.querySelectorAll('.payment-method').forEach(m => {
|
| 816 |
+
m.classList.remove('selected');
|
| 817 |
+
});
|
| 818 |
+
method.classList.add('selected');
|
| 819 |
+
}
|
| 820 |
+
});
|
| 821 |
+
});
|
| 822 |
+
|
| 823 |
+
// Submit order
|
| 824 |
+
submitOrder.addEventListener('click', () => {
|
| 825 |
+
// Simple validation
|
| 826 |
+
const termsChecked = document.getElementById('terms').checked;
|
| 827 |
+
if (!termsChecked) {
|
| 828 |
+
alert('Please agree to the terms and conditions');
|
| 829 |
+
return;
|
| 830 |
+
}
|
| 831 |
+
|
| 832 |
+
// Here you would normally send the order to your backend
|
| 833 |
+
// For this demo, we'll just show the success message
|
| 834 |
|
| 835 |
+
// Generate random order number
|
| 836 |
+
const orderNumber = 'PSY-' + new Date().getFullYear() + '-' + Math.floor(10000 + Math.random() * 90000);
|
| 837 |
+
document.getElementById('order-number').textContent = orderNumber;
|
| 838 |
|
| 839 |
+
// Hide checkout and show success
|
| 840 |
+
checkoutPage.classList.add('hidden');
|
| 841 |
+
paymentSuccess.classList.remove('hidden');
|
| 842 |
|
| 843 |
+
// Clear cart
|
| 844 |
cart = [];
|
| 845 |
updateCart();
|
| 846 |
});
|
| 847 |
|
| 848 |
+
// Close success modal
|
| 849 |
+
closeSuccess.addEventListener('click', () => {
|
| 850 |
+
paymentSuccess.classList.add('hidden');
|
| 851 |
});
|
| 852 |
|
| 853 |
// Mobile menu toggle
|
prompts.txt
CHANGED
|
@@ -1 +1,4 @@
|
|
| 1 |
-
let's work on the checkout and cart function
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
let's work on the checkout and cart function
|
| 2 |
+
let's do some php and mysql for the forms and product. set other payment methods and form validation
|
| 3 |
+
fix the payment authenticator and create a separate page for checkout
|
| 4 |
+
Add an Leaf ICON logo
|