!DOCTYPE html> Busycorner - Car Wash & Food | Call 073 047 3600
BC

Busycorner

Premium Car Wash & Fresh Food

ONLINE
📍 Ficksburg, Free State
!-- Main Content -->

🎉Today's Special Deals

🔥 COMBO DEAL

Small Car Wash + Medium Kota + Drink

R137
R120
SAVE R17

🚚 FREE DELIVERY

No delivery fee on orders over R150

SAVE R30

How would you like your food?

!-- Food Section --> !-- Cart Section -->
script> // App State let cart = []; let serviceType = 'dine-in'; let currentSection = 'home'; // DOM Elements const sections = { home: document.getElementById('home-section'), booking: document.getElementById('booking-section'), food: document.getElementById('food-section'), cart: document.getElementById('cart-section'), checkout: document.getElementById('checkout-section') }; const navBtns = { home: document.getElementById('home-btn'), booking: document.getElementById('booking-btn'), food: document.getElementById('food-btn'), cart: document.getElementById('cart-btn') }; // Navigation function showSection(sectionName) { Object.values(sections).forEach(section => section.style.display = 'none'); sections[sectionName].style.display = 'block'; currentSection = sectionName; Object.values(navBtns).forEach(btn => { btn.classList.remove('bg-blue-100', 'text-blue-600'); btn.classList.add('text-gray-600', 'hover:bg-gray-100'); }); if (navBtns[sectionName]) { navBtns[sectionName].classList.add('bg-blue-100', 'text-blue-600'); navBtns[sectionName].classList.remove('text-gray-600', 'hover:bg-gray-100'); } if (sectionName === 'cart') updateCartDisplay(); if (sectionName === 'checkout') updateCheckoutDisplay(); } // Cart Management function addToCart(item) { const existingItem = cart.find(cartItem => cartItem.name === item.name); if (existingItem) { existingItem.quantity += 1; } else { cart.push({ ...item, quantity: 1 }); } updateCartBadge(); showNotification(`${item.name} added to cart!`, 'success'); } function updateCartBadge() { const badge = document.getElementById('cart-badge'); const totalItems = cart.reduce((sum, item) => sum + item.quantity, 0); badge.textContent = totalItems; badge.style.display = totalItems > 0 ? 'flex' : 'none'; } function calculateTotals() { const subtotal = cart.reduce((sum, item) => sum + (item.price * item.quantity), 0); const deliveryFee = (serviceType === 'delivery' && subtotal < 150) ? 30 : 0; const total = subtotal + deliveryFee; return { subtotal, deliveryFee, total }; } function updateCartDisplay() { const cartItems = document.getElementById('cart-items'); const emptyCart = document.getElementById('empty-cart'); const cartSummary = document.getElementById('cart-summary'); if (cart.length === 0) { emptyCart.style.display = 'block'; cartSummary.style.display = 'none'; } else { emptyCart.style.display = 'none'; cartSummary.style.display = 'block'; cartItems.innerHTML = cart.map(item => `

${item.name}

R${item.price} x ${item.quantity}

R${item.price * item.quantity}
`).join(''); } const { subtotal, deliveryFee, total } = calculateTotals(); document.getElementById('subtotal').textContent = `R${subtotal}`; document.getElementById('total').textContent = `R${total}`; } function showNotification(message, type = 'info') { const notification = document.createElement('div'); notification.className = `fixed top-4 right-4 p-4 rounded-lg text-white z-50 ${ type === 'success' ? 'bg-green-500' : 'bg-blue-500' }`; notification.textContent = message; document.body.appendChild(notification); setTimeout(() => notification.remove(), 3000); } // Event Listeners navBtns.home.addEventListener('click', () => showSection('home')); navBtns.booking.addEventListener('click', () => showSection('booking')); navBtns.food.addEventListener('click', () => showSection('food')); navBtns.cart.addEventListener('click', () => showSection('cart')); document.getElementById('go-to-booking').addEventListener('click', () => showSection('booking')); document.getElementById('go-to-food').addEventListener('click', () => showSection('food')); document.getElementById('checkout-btn').addEventListener('click', () => showSection('checkout')); // Add combo deal document.getElementById('add-combo').addEventListener('click', () => { addToCart({ name: 'COMBO DEAL (Small Car Wash + Medium Kota + Drink)', price: 120, type: 'combo' }); }); // Service and food buttons document.querySelectorAll('.add-service-btn, .add-food-btn').forEach(btn => { btn.addEventListener('click', (e) => { const name = e.target.getAttribute('data-name'); const price = parseInt(e.target.getAttribute('data-price')); addToCart({ name, price }); }); }); // Checkout form document.getElementById('checkout-form').addEventListener('submit', (e) => { e.preventDefault(); const name = document.getElementById('customer-name').value; const phone = document.getElementById('customer-phone').value; let message = `*New Order from Busycorner App*\n\n*Customer:* ${name}\n*Phone:* ${phone}\n\n*Order Items:*\n`; cart.forEach(item => { message += `• ${item.name} x${item.quantity} - R${item.price * item.quantity}\n`; }); const { total } = calculateTotals(); message += `\n*TOTAL: R${total}*`; const encodedMessage = encodeURIComponent(message); const whatsappUrl = `https://wa.me/27730473600?text=${encodedMessage}`; window.open(whatsappUrl, '_blank'); showNotification('Order sent! We\'ll contact you soon.', 'success'); }); function updateCheckoutDisplay() { const { total } = calculateTotals(); document.getElementById('checkout-total').textContent = `R${total}`; } // Initialize updateCartBadge(); showSection('home');