Spaces:
Running
Running
File size: 21,531 Bytes
69c78e3 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Dropship Dreamland USA - Virtual Store</title>
<link rel="icon" type="image/x-icon" href="/static/favicon.ico">
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://unpkg.com/feather-icons"></script>
<script>
tailwind.config = {
theme: {
extend: {
colors: {
primary: '#3B82F6',
secondary: '#10B981',
}
}
}
}
</script>
<style>
.product-card:hover {
transform: translateY(-5px);
box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}
.cart-sidebar {
transition: transform 0.3s ease-in-out;
}
</style>
</head>
<body class="bg-gray-50">
<!-- Navigation -->
<nav class="bg-white shadow-sm">
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between h-16 items-center">
<div class="flex items-center">
<div class="flex-shrink-0 flex items-center">
<i data-feather="truck" class="text-primary h-8 w-8"></i>
<span class="ml-2 text-xl font-bold text-gray-900">Dropship Dreamland</span>
</div>
</div>
<div class="hidden md:block">
<div class="ml-10 flex items-center space-x-4">
<a href="index.html" class="px-3 py-2 rounded-md text-sm font-medium text-gray-500 hover:text-primary transition">Home</a>
<a href="loja.html" class="px-3 py-2 rounded-md text-sm font-medium text-gray-900 hover:text-primary transition">Store</a>
<a href="#" class="px-3 py-2 rounded-md text-sm font-medium text-gray-500 hover:text-primary transition">Products</a>
<a href="#" class="px-3 py-2 rounded-md text-sm font-medium text-gray-500 hover:text-primary transition">Suppliers</a>
</div>
</div>
<div class="flex items-center space-x-4">
<button id="cart-toggle" class="relative p-2 text-gray-600 hover:text-primary">
<i data-feather="shopping-cart"></i>
<span id="cart-count" class="absolute -top-1 -right-1 bg-primary text-white rounded-full text-xs w-5 h-5 flex items-center justify-center">0</span>
</button>
<button class="bg-primary hover:bg-primary-600 text-white px-4 py-2 rounded-md text-sm font-medium transition">
Sign In
</button>
</div>
</div>
</div>
</nav>
<!-- Store Header -->
<div class="bg-white shadow-sm border-b">
<div class="max-w-7xl mx-auto py-6 px-4 sm:px-6 lg:px-8">
<div class="flex flex-col md:flex-row md:items-center md:justify-between">
<h1 class="text-2xl font-bold text-gray-900">Our Virtual Store</h1>
<div class="mt-4 md:mt-0">
<div class="flex space-x-4">
<select class="border-gray-300 rounded-md shadow-sm focus:border-primary focus:ring focus:ring-primary focus:ring-opacity-50">
<option>All Categories</option>
<option>Electronics</option>
<option>Home & Kitchen</option>
<option>Beauty</option>
<option>Outdoor</option>
</select>
<div class="relative">
<input type="text" placeholder="Search products..." class="border-gray-300 rounded-md shadow-sm focus:border-primary focus:ring focus:ring-primary focus:ring-opacity-50 pl-10 pr-4 py-2">
<i data-feather="search" class="absolute left-3 top-3 text-gray-400"></i>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- Products Grid -->
<div class="max-w-7xl mx-auto py-8 px-4 sm:px-6 lg:px-8">
<div class="grid grid-cols-1 gap-y-12 sm:grid-cols-2 gap-x-6 lg:grid-cols-4">
<!-- Product 1 -->
<div class="product-card group relative bg-white p-6 rounded-lg shadow-md transition duration-300 ease-in-out">
<div class="w-full min-h-80 bg-gray-200 aspect-w-1 aspect-h-1 rounded-md overflow-hidden group-hover:opacity-75 lg:h-80 lg:aspect-none">
<img src="http://static.photos/technology/640x360/1" alt="Smart Fitness Tracker" class="w-full h-full object-center object-cover">
</div>
<div class="mt-4 flex justify-between">
<div>
<h3 class="text-sm text-gray-700">
<span class="absolute inset-0"></span>
Smart Fitness Tracker
</h3>
<p class="mt-1 text-sm text-gray-500">Electronics</p>
</div>
<p class="text-sm font-medium text-gray-900">$29.99</p>
</div>
<div class="mt-4">
<button class="add-to-cart w-full bg-primary hover:bg-primary-600 text-white py-2 px-4 rounded-md text-sm font-medium transition" data-product='{"name": "Smart Fitness Tracker", "price": 29.99, "image": "http://static.photos/technology/640x360/1"}'>
Add to Cart
</button>
</div>
</div>
<!-- Product 2 -->
<div class="product-card group relative bg-white p-6 rounded-lg shadow-md transition duration-300 ease-in-out">
<div class="w-full min-h-80 bg-gray-200 aspect-w-1 aspect-h-1 rounded-md overflow-hidden group-hover:opacity-75 lg:h-80 lg:aspect-none">
<img src="http://static.photos/home/640x360/2" alt="Bamboo Cutting Board Set" class="w-full h-full object-center object-cover">
</div>
<div class="mt-4 flex justify-between">
<div>
<h3 class="text-sm text-gray-700">
<span class="absolute inset-0"></span>
Bamboo Cutting Board Set
</h3>
<p class="mt-1 text-sm text-gray-500">Home & Kitchen</p>
</div>
<p class="text-sm font-medium text-gray-900">$39.99</p>
</div>
<div class="mt-4">
<button class="add-to-cart w-full bg-primary hover:bg-primary-600 text-white py-2 px-4 rounded-md text-sm font-medium transition" data-product='{"name": "Bamboo Cutting Board Set", "price": 39.99, "image": "http://static.photos/home/640x360/2"}'>
Add to Cart
</button>
</div>
</div>
<!-- Product 3 -->
<div class="product-card group relative bg-white p-6 rounded-lg shadow-md transition duration-300 ease-in-out">
<div class="w-full min-h-80 bg-gray-200 aspect-w-1 aspect-h-1 rounded-md overflow-hidden group-hover:opacity-75 lg:h-80 lg:aspect-none">
<img src="http://static.photos/beauty/640x360/3" alt="Organic Skincare Set" class="w-full h-full object-center object-cover">
</div>
<div class="mt-4 flex justify-between">
<div>
<h3 class="text-sm text-gray-700">
<span class="absolute inset-0"></span>
Organic Skincare Set
</h3>
<p class="mt-1 text-sm text-gray-500">Beauty</p>
</div>
<p class="text-sm font-medium text-gray-900">$49.99</p>
</div>
<div class="mt-4">
<button class="add-to-cart w-full bg-primary hover:bg-primary-600 text-white py-2 px-4 rounded-md text-sm font-medium transition" data-product='{"name": "Organic Skincare Set", "price": 49.99, "image": "http://static.photos/beauty/640x360/3"}'>
Add to Cart
</button>
</div>
</div>
<!-- Product 4 -->
<div class="product-card group relative bg-white p-6 rounded-lg shadow-md transition duration-300 ease-in-out">
<div class="w-full min-h-80 bg-gray-200 aspect-w-1 aspect-h-1 rounded-md overflow-hidden group-hover:opacity-75 lg:h-80 lg:aspect-none">
<img src="http://static.photos/outdoor/640x360/4" alt="Portable Camping Hammock" class="w-full h-full object-center object-cover">
</div>
<div class="mt-4 flex justify-between">
<div>
<h3 class="text-sm text-gray-700">
<span class="absolute inset-0"></span>
Portable Camping Hammock
</h3>
<p class="mt-1 text-sm text-gray-500">Outdoor</p>
</div>
<p class="text-sm font-medium text-gray-900">$34.99</p>
</div>
<div class="mt-4">
<button class="add-to-cart w-full bg-primary hover:bg-primary-600 text-white py-2 px-4 rounded-md text-sm font-medium transition" data-product='{"name": "Portable Camping Hammock", "price": 34.99, "image": "http://static.photos/outdoor/640x360/4"}'>
Add to Cart
</button>
</div>
</div>
<!-- Product 5 -->
<div class="product-card group relative bg-white p-6 rounded-lg shadow-md transition duration-300 ease-in-out">
<div class="w-full min-h-80 bg-gray-200 aspect-w-1 aspect-h-1 rounded-md overflow-hidden group-hover:opacity-75 lg:h-80 lg:aspect-none">
<img src="http://static.photos/technology/640x360/8" alt="Wireless Earbuds" class="w-full h-full object-center object-cover">
</div>
<div class="mt-4 flex justify-between">
<div>
<h3 class="text-sm text-gray-700">
<span class="absolute inset-0"></span>
Wireless Earbuds Pro
</h3>
<p class="mt-1 text-sm text-gray-500">Electronics</p>
</div>
<p class="text-sm font-medium text-gray-900">$79.99</p>
</div>
<div class="mt-4">
<button class="add-to-cart w-full bg-primary hover:bg-primary-600 text-white py-2 px-4 rounded-md text-sm font-medium transition" data-product='{"name": "Wireless Earbuds Pro", "price": 79.99, "image": "http://static.photos/technology/640x360/8"}'>
Add to Cart
</button>
</div>
</div>
<!-- Product 6 -->
<div class="product-card group relative bg-white p-6 rounded-lg shadow-md transition duration-300 ease-in-out">
<div class="w-full min-h-80 bg-gray-200 aspect-w-1 aspect-h-1 rounded-md overflow-hidden group-hover:opacity-75 lg:h-80 lg:aspect-none">
<img src="http://static.photos/home/640x360/9" alt="Smart Coffee Maker" class="w-full h-full object-center object-cover">
</div>
<div class="mt-4 flex justify-between">
<div>
<h3 class="text-sm text-gray-700">
<span class="absolute inset-0"></span>
Smart Coffee Maker
</h3>
<p class="mt-1 text-sm text-gray-500">Home & Kitchen</p>
</div>
<p class="text-sm font-medium text-gray-900">$89.99</p>
</div>
<div class="mt-4">
<button class="add-to-cart w-full bg-primary hover:bg-primary-600 text-white py-2 px-4 rounded-md text-sm font-medium transition" data-product='{"name": "Smart Coffee Maker", "price": 89.99, "image": "http://static.photos/home/640x360/9"}'>
Add to Cart
</button>
</div>
</div>
<!-- Product 7 -->
<div class="product-card group relative bg-white p-6 rounded-lg shadow-md transition duration-300 ease-in-out">
<div class="w-full min-h-80 bg-gray-200 aspect-w-1 aspect-h-1 rounded-md overflow-hidden group-hover:opacity-75 lg:h-80 lg:aspect-none">
<img src="http://static.photos/beauty/640x360/10" alt="Hair Care Kit" class="w-full h-full object-center object-cover">
</div>
<div class="mt-4 flex justify-between">
<div>
<h3 class="text-sm text-gray-700">
<span class="absolute inset-0"></span>
Premium Hair Care Kit
</h3>
<p class="mt-1 text-sm text-gray-500">Beauty</p>
</div>
<p class="text-sm font-medium text-gray-900">$59.99</p>
</div>
<div class="mt-4">
<button class="add-to-cart w-full bg-primary hover:bg-primary-600 text-white py-2 px-4 rounded-md text-sm font-medium transition" data-product='{"name": "Premium Hair Care Kit", "price": 59.99, "image": "http://static.photos/beauty/640x360/10"}'>
Add to Cart
</button>
</div>
</div>
<!-- Product 8 -->
<div class="product-card group relative bg-white p-6 rounded-lg shadow-md transition duration-300 ease-in-out">
<div class="w-full min-h-80 bg-gray-200 aspect-w-1 aspect-h-1 rounded-md overflow-hidden group-hover:opacity-75 lg:h-80 lg:aspect-none">
<img src="http://static.photos/outdoor/640x360/11" alt="Camping Tent" class="w-full h-full object-center object-cover">
</div>
<div class="mt-4 flex justify-between">
<div>
<h3 class="text-sm text-gray-700">
<span class="absolute inset-0"></span>
4-Person Camping Tent
</h3>
<p class="mt-1 text-sm text-gray-500">Outdoor</p>
</div>
<p class="text-sm font-medium text-gray-900">$129.99</p>
</div>
<div class="mt-4">
<button class="add-to-cart w-full bg-primary hover:bg-primary-600 text-white py-2 px-4 rounded-md text-sm font-medium transition" data-product='{"name": "4-Person Camping Tent", "price": 129.99, "image": "http://static.photos/outdoor/640x360/11"}'>
Add to Cart
</button>
</div>
</div>
</div>
</div>
<!-- Cart Sidebar -->
<div id="cart-sidebar" class="cart-sidebar fixed top-0 right-0 w-96 h-full bg-white shadow-xl transform translate-x-full z-50">
<div class="p-6 h-full flex flex-col">
<div class="flex justify-between items-center mb-6">
<h2 class="text-lg font-semibold">Shopping Cart</h2>
<button id="close-cart" class="text-gray-400 hover:text-gray-600">
<i data-feather="x"></i>
</button>
</div>
<div id="cart-items" class="flex-1 overflow-y-auto">
<!-- Cart items will be dynamically added here -->
</div>
<div class="border-t pt-4">
<div class="flex justify-between text-lg font-semibold mb-4">
<span>Total:</span>
<span id="cart-total">$0.00</span>
</div>
<button class="w-full bg-primary hover:bg-primary-600 text-white py-3 px-4 rounded-md font-medium transition">
Checkout
</button>
</div>
</div>
</div>
<!-- Overlay -->
<div id="overlay" class="fixed inset-0 bg-black bg-opacity-50 z-40 hidden"></div>
<script>
// Cart functionality
let cart = [];
const cartSidebar = document.getElementById('cart-sidebar');
const overlay = document.getElementById('overlay');
const cartToggle = document.getElementById('cart-toggle');
const closeCart = document.getElementById('close-cart');
const cartItems = document.getElementById('cart-items');
const cartTotal = document.getElementById('cart-total');
const cartCount = document.getElementById('cart-count');
// Add to cart functionality
document.querySelectorAll('.add-to-cart').forEach(button => {
button.addEventListener('click', (e) => {
const productData = JSON.parse(e.target.dataset.product);
addToCart(productData);
});
});
function addToCart(product) {
const existingItem = cart.find(item => item.name === product.name);
if (existingItem) {
existingItem.quantity += 1;
} else {
cart.push({
...product,
quantity: 1
});
}
updateCart();
showCart();
}
function updateCart() {
// Update cart items display
cartItems.innerHTML = '';
let total = 0;
cart.forEach(item => {
const itemTotal = item.price * item.quantity;
total += itemTotal;
const cartItem = document.createElement('div');
cartItem.className = 'flex items-center space-x-4 py-4 border-b';
cartItem.innerHTML = `
<img src="${item.image}" alt="${item.name}" class="w-16 h-16 object-cover rounded">
<div class="flex-1">
<h3 class="text-sm font-medium">${item.name}</h3>
<p class="text-gray-600">$${item.price.toFixed(2)}</p>
</div>
<div class="flex items-center space-x-2">
<button class="decrease-quantity text-gray-400 hover:text-gray-600" data-name="${item.name}">
<i data-feather="minus" class="w-4 h-4"></i>
</button>
<span class="quantity">${item.quantity}</span>
<button class="increase-quantity text-gray-400 hover:text-gray-600" data-name="${item.name}">
<i data-feather="plus" class="w-4 h-4"></i>
</button>
</div>
`;
cartItems.appendChild(cartItem);
});
// Update total and count
cartTotal.textContent = `$${total.toFixed(2)}`;
cartCount.textContent = cart.reduce((sum, item) => sum + item.quantity, 0);
// Add event listeners for quantity buttons
document.querySelectorAll('.increase-quantity').forEach(button => {
button.addEventListener('click', (e) => {
const productName = e.target.closest('button').dataset.name;
const item = cart.find(item => item.name === productName);
if (item) {
item.quantity += 1;
updateCart();
}
});
});
document.querySelectorAll('.decrease-quantity').forEach(button => {
button.addEventListener('click', (e) => {
const productName = e.target.closest('button').dataset.name;
const itemIndex = cart.findIndex(item => item.name === productName);
if (itemIndex !== -1) {
if (cart[itemIndex].quantity > 1) {
cart[itemIndex].quantity -= 1;
} else {
cart.splice(itemIndex, 1);
}
updateCart();
}
});
});
feather.replace();
}
function showCart() {
cartSidebar.classList.remove('translate-x-full');
overlay.classList.remove('hidden');
}
function hideCart() {
cartSidebar.classList.add('translate-x-full');
overlay.classList.add('hidden');
}
cartToggle.addEventListener('click', showCart);
closeCart.addEventListener('click', hideCart);
overlay.addEventListener('click', hideCart);
// Initialize feather icons
feather.replace();
</script>
</body>
</html> |