rasee-webdesign / index.html
rasee's picture
undefined - Initial Deployment
7a55b70 verified
Raw History Blame Contribute Delete
36.8 kB
<!DOCTYPE html>
<html lang="fr">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>La Main Blanche - Boulangerie Artisanale</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<style>
.hero-image {
background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('https://images.unsplash.com/photo-1509440159596-0249088772ff?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1470&q=80');
background-size: cover;
background-position: center;
}
.product-card:hover {
transform: translateY(-5px);
box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}
.testimonial-card {
transition: all 0.3s ease;
}
.active-filter {
background-color: #f59e0b;
color: white;
}
</style>
</head>
<body class="font-sans text-gray-800">
<!-- Header -->
<header class="fixed w-full bg-white shadow-md z-50">
<div class="container mx-auto px-4 py-3 flex justify-between items-center">
<div class="flex items-center">
<div class="w-12 h-12 bg-amber-100 rounded-full flex items-center justify-center mr-3">
<i class="fas fa-hand text-amber-600 text-xl"></i>
</div>
<h1 class="text-xl font-bold text-amber-800">La Main Blanche</h1>
</div>
<nav class="hidden md:flex space-x-8">
<a href="#about" class="hover:text-amber-600 transition">À propos</a>
<a href="#products" class="hover:text-amber-600 transition">Nos produits</a>
<a href="#pricing" class="hover:text-amber-600 transition">Nos prix</a>
<a href="#testimonials" class="hover:text-amber-600 transition">Témoignages</a>
<a href="#contact" class="hover:text-amber-600 transition">Contact</a>
</nav>
<button class="md:hidden text-amber-800">
<i class="fas fa-bars text-2xl"></i>
</button>
</div>
</header>
<!-- Hero Section -->
<section class="hero-image h-screen flex items-center justify-center text-white pt-16">
<div class="text-center px-4">
<div class="w-24 h-24 bg-white bg-opacity-20 rounded-full flex items-center justify-center mx-auto mb-6">
<i class="fas fa-hand text-white text-4xl"></i>
</div>
<h1 class="text-4xl md:text-6xl font-bold mb-4">Du pain, de l'âme, du vrai</h1>
<p class="text-xl mb-8 max-w-2xl mx-auto">Boulangerie artisanale depuis 1985, façonnée avec passion et savoir-faire</p>
<div class="flex flex-col sm:flex-row justify-center gap-4">
<a href="#products" class="bg-amber-600 hover:bg-amber-700 text-white font-bold py-3 px-8 rounded-full transition duration-300">Voir nos produits</a>
<a href="#order" class="bg-white hover:bg-gray-100 text-amber-800 font-bold py-3 px-8 rounded-full transition duration-300">Commander</a>
</div>
</div>
</section>
<!-- About Section -->
<section id="about" class="py-20 bg-amber-50">
<div class="container mx-auto px-4">
<h2 class="text-3xl font-bold text-center mb-12 text-amber-800">À propos de La Main Blanche</h2>
<div class="flex flex-col lg:flex-row items-center gap-12 mb-16">
<div class="lg:w-1/2">
<img src="https://images.unsplash.com/photo-1608190003443-86a8a7f0532c?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1470&q=80"
alt="Boulanger au travail"
class="rounded-lg shadow-xl w-full h-auto">
</div>
<div class="lg:w-1/2">
<h3 class="text-2xl font-semibold mb-4 text-amber-700">Notre histoire</h3>
<p class="mb-4 text-gray-700">Fondée en 1985 par Jean Dupont, La Main Blanche perpétue depuis trois générations la tradition du pain artisanal. Notre nom vient de la farine qui blanchit les mains de nos boulangers, témoin de leur travail passionné.</p>
<p class="mb-6 text-gray-700">Chaque jour, nous pétrissons, façonnons et cuisons avec le même amour du métier, utilisant des techniques transmises de maître à apprenti.</p>
<h3 class="text-2xl font-semibold mb-4 text-amber-700">Nos engagements</h3>
<ul class="space-y-3 text-gray-700">
<li class="flex items-start">
<i class="fas fa-check-circle text-amber-600 mt-1 mr-2"></i>
<span>Farines 100% locales et biologiques</span>
</li>
<li class="flex items-start">
<i class="fas fa-check-circle text-amber-600 mt-1 mr-2"></i>
<span>Fermentation naturelle au levain</span>
</li>
<li class="flex items-start">
<i class="fas fa-check-circle text-amber-600 mt-1 mr-2"></i>
<span>Cuisson au feu de bois traditionnel</span>
</li>
<li class="flex items-start">
<i class="fas fa-check-circle text-amber-600 mt-1 mr-2"></i>
<span>Zéro additif, zéro conservateur</span>
</li>
</ul>
</div>
</div>
<div class="grid grid-cols-1 md:grid-cols-3 gap-6">
<div class="bg-white p-6 rounded-lg shadow-md">
<div class="w-16 h-16 bg-amber-100 rounded-full flex items-center justify-center mb-4 mx-auto">
<i class="fas fa-wheat-awn text-amber-600 text-xl"></i>
</div>
<h3 class="text-xl font-semibold text-center mb-3 text-amber-800">Nos farines</h3>
<p class="text-gray-600 text-center">Sélectionnées avec soin auprès de moulins régionaux pour garantir qualité et traçabilité.</p>
</div>
<div class="bg-white p-6 rounded-lg shadow-md">
<div class="w-16 h-16 bg-amber-100 rounded-full flex items-center justify-center mb-4 mx-auto">
<i class="fas fa-fire text-amber-600 text-xl"></i>
</div>
<h3 class="text-xl font-semibold text-center mb-3 text-amber-800">Notre four</h3>
<p class="text-gray-600 text-center">Un four à bois traditionnel qui donne à nos pains leur croustillant et leur saveur incomparable.</p>
</div>
<div class="bg-white p-6 rounded-lg shadow-md">
<div class="w-16 h-16 bg-amber-100 rounded-full flex items-center justify-center mb-4 mx-auto">
<i class="fas fa-heart text-amber-600 text-xl"></i>
</div>
<h3 class="text-xl font-semibold text-center mb-3 text-amber-800">Notre passion</h3>
<p class="text-gray-600 text-center">Un savoir-faire artisanal transmis avec passion depuis plus de 35 ans.</p>
</div>
</div>
</div>
</section>
<!-- Products Section -->
<section id="products" class="py-20">
<div class="container mx-auto px-4">
<h2 class="text-3xl font-bold text-center mb-4 text-amber-800">Nos produits</h2>
<p class="text-center text-gray-600 mb-12 max-w-2xl mx-auto">Découvrez notre sélection de pains, viennoiseries et pâtisseries artisanales, préparés quotidiennement avec soin.</p>
<!-- Product Filters -->
<div class="flex flex-wrap justify-center gap-3 mb-12">
<button onclick="filterProducts('all')" class="filter-btn active-filter px-4 py-2 rounded-full border border-amber-200 hover:bg-amber-100 transition">Tous</button>
<button onclick="filterProducts('bread')" class="filter-btn px-4 py-2 rounded-full border border-amber-200 hover:bg-amber-100 transition">Pains</button>
<button onclick="filterProducts('pastry')" class="filter-btn px-4 py-2 rounded-full border border-amber-200 hover:bg-amber-100 transition">Viennoiseries</button>
<button onclick="filterProducts('dessert')" class="filter-btn px-4 py-2 rounded-full border border-amber-200 hover:bg-amber-100 transition">Pâtisseries</button>
</div>
<!-- Product Grid -->
<div class="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-8" id="product-grid">
<!-- Product items will be inserted here by JavaScript -->
</div>
</div>
</section>
<!-- Pricing Section -->
<section id="pricing" class="py-20 bg-amber-50">
<div class="container mx-auto px-4">
<h2 class="text-3xl font-bold text-center mb-12 text-amber-800">Nos tarifs</h2>
<div class="overflow-x-auto">
<table class="min-w-full bg-white rounded-lg overflow-hidden shadow-md">
<thead class="bg-amber-100">
<tr>
<th class="py-4 px-6 text-left text-amber-800 font-semibold">Produit</th>
<th class="py-4 px-6 text-left text-amber-800 font-semibold">Description</th>
<th class="py-4 px-6 text-right text-amber-800 font-semibold">Prix</th>
</tr>
</thead>
<tbody class="divide-y divide-amber-50">
<tr>
<td class="py-4 px-6">Baguette tradition</td>
<td class="py-4 px-6 text-gray-600">Farine T65, levain naturel, croûte croustillante</td>
<td class="py-4 px-6 text-right font-medium">1,20€</td>
</tr>
<tr>
<td class="py-4 px-6">Pain de campagne</td>
<td class="py-4 px-6 text-gray-600">Mélange de farines, mie alvéolée, saveur rustique</td>
<td class="py-4 px-6 text-right font-medium">3,50€</td>
</tr>
<tr>
<td class="py-4 px-6">Pain aux céréales</td>
<td class="py-4 px-6 text-gray-600">Mélange de 7 céréales, riche en fibres</td>
<td class="py-4 px-6 text-right font-medium">4,20€</td>
</tr>
<tr>
<td class="py-4 px-6">Croissant</td>
<td class="py-4 px-6 text-gray-600">Beurre AOP Charentes-Poitou, feuilletage léger</td>
<td class="py-4 px-6 text-right font-medium">1,40€</td>
</tr>
<tr>
<td class="py-4 px-6">Pain au chocolat</td>
<td class="py-4 px-6 text-gray-600">Chocolat noir 70%, pâte feuilletée au beurre</td>
<td class="py-4 px-6 text-right font-medium">1,60€</td>
</tr>
<tr>
<td class="py-4 px-6">Tartelette aux fruits</td>
<td class="py-4 px-6 text-gray-600">Pâte sablée, crème pâtissière, fruits de saison</td>
<td class="py-4 px-6 text-right font-medium">4,80€</td>
</tr>
<tr>
<td class="py-4 px-6">Flan nature</td>
<td class="py-4 px-6 text-gray-600">Crème vanillée, pâte feuilletée dorée</td>
<td class="py-4 px-6 text-right font-medium">3,90€</td>
</tr>
</tbody>
</table>
</div>
<p class="text-center mt-8 text-gray-600">* Nos prix peuvent varier légèrement selon le poids des produits. Tous nos pains pèsent au minimum le poids annoncé.</p>
</div>
</section>
<!-- Order Form -->
<section id="order" class="py-20">
<div class="container mx-auto px-4 max-w-4xl">
<h2 class="text-3xl font-bold text-center mb-4 text-amber-800">Commander en ligne</h2>
<p class="text-center text-gray-600 mb-12">Passez votre commande et récupérez-la en boutique à l'heure qui vous convient.</p>
<form class="bg-white p-8 rounded-lg shadow-lg">
<div class="grid grid-cols-1 md:grid-cols-2 gap-6 mb-6">
<div>
<label for="name" class="block text-gray-700 mb-2">Nom complet</label>
<input type="text" id="name" class="w-full px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-amber-500 focus:border-amber-500">
</div>
<div>
<label for="phone" class="block text-gray-700 mb-2">Téléphone</label>
<input type="tel" id="phone" class="w-full px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-amber-500 focus:border-amber-500">
</div>
</div>
<div class="mb-6">
<label for="email" class="block text-gray-700 mb-2">Email</label>
<input type="email" id="email" class="w-full px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-amber-500 focus:border-amber-500">
</div>
<div class="mb-6">
<label for="pickup-time" class="block text-gray-700 mb-2">Heure de retrait</label>
<select id="pickup-time" class="w-full px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-amber-500 focus:border-amber-500">
<option value="">Sélectionnez une heure</option>
<option value="08:00-10:00">08:00 - 10:00</option>
<option value="10:00-12:00">10:00 - 12:00</option>
<option value="12:00-14:00">12:00 - 14:00</option>
<option value="14:00-16:00">14:00 - 16:00</option>
<option value="16:00-18:00">16:00 - 18:00</option>
<option value="18:00-20:00">18:00 - 20:00</option>
</select>
</div>
<div class="mb-8">
<label class="block text-gray-700 mb-2">Votre commande</label>
<div class="space-y-4" id="order-items">
<!-- Order items will be added here by JavaScript -->
</div>
<button type="button" onclick="addOrderItem()" class="mt-4 flex items-center text-amber-600 hover:text-amber-800">
<i class="fas fa-plus-circle mr-2"></i> Ajouter un produit
</button>
</div>
<div class="mb-6">
<label for="notes" class="block text-gray-700 mb-2">Notes supplémentaires</label>
<textarea id="notes" rows="3" class="w-full px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-amber-500 focus:border-amber-500"></textarea>
</div>
<button type="submit" class="w-full bg-amber-600 hover:bg-amber-700 text-white font-bold py-3 px-4 rounded-lg transition duration-300">
Valider la commande
</button>
</form>
</div>
</section>
<!-- Testimonials -->
<section id="testimonials" class="py-20 bg-amber-50">
<div class="container mx-auto px-4">
<h2 class="text-3xl font-bold text-center mb-12 text-amber-800">Ce que disent nos clients</h2>
<div class="relative max-w-4xl mx-auto">
<div class="testimonial-carousel overflow-hidden">
<div class="flex transition-transform duration-300" id="testimonial-slides">
<!-- Testimonial slides will be inserted here by JavaScript -->
</div>
</div>
<button onclick="prevTestimonial()" class="absolute left-0 top-1/2 -translate-y-1/2 -ml-4 bg-white p-2 rounded-full shadow-md hover:bg-amber-100 transition">
<i class="fas fa-chevron-left text-amber-600"></i>
</button>
<button onclick="nextTestimonial()" class="absolute right-0 top-1/2 -translate-y-1/2 -mr-4 bg-white p-2 rounded-full shadow-md hover:bg-amber-100 transition">
<i class="fas fa-chevron-right text-amber-600"></i>
</button>
<div class="flex justify-center mt-6 space-x-2" id="testimonial-dots">
<!-- Dots will be inserted here by JavaScript -->
</div>
</div>
</div>
</section>
<!-- Contact & Footer -->
<footer id="contact" class="bg-amber-800 text-white">
<div class="container mx-auto px-4 py-12">
<div class="grid grid-cols-1 md:grid-cols-3 gap-12">
<div>
<div class="flex items-center mb-6">
<div class="w-12 h-12 bg-white rounded-full flex items-center justify-center mr-3">
<i class="fas fa-hand text-amber-800 text-xl"></i>
</div>
<h3 class="text-xl font-bold">La Main Blanche</h3>
</div>
<p class="mb-4">Boulangerie artisanale depuis 1985, façonnée avec passion et savoir-faire.</p>
<div class="flex space-x-4">
<a href="#" class="hover:text-amber-200 transition"><i class="fab fa-facebook-f"></i></a>
<a href="#" class="hover:text-amber-200 transition"><i class="fab fa-instagram"></i></a>
<a href="#" class="hover:text-amber-200 transition"><i class="fab fa-twitter"></i></a>
</div>
</div>
<div>
<h3 class="text-lg font-semibold mb-4">Horaires d'ouverture</h3>
<ul class="space-y-2">
<li class="flex justify-between">
<span>Lundi</span>
<span>7h-19h</span>
</li>
<li class="flex justify-between">
<span>Mardi</span>
<span>7h-19h</span>
</li>
<li class="flex justify-between">
<span>Mercredi</span>
<span>7h-19h</span>
</li>
<li class="flex justify-between">
<span>Jeudi</span>
<span>7h-19h</span>
</li>
<li class="flex justify-between">
<span>Vendredi</span>
<span>7h-19h</span>
</li>
<li class="flex justify-between">
<span>Samedi</span>
<span>7h-20h</span>
</li>
<li class="flex justify-between">
<span>Dimanche</span>
<span>8h-13h</span>
</li>
</ul>
</div>
<div>
<h3 class="text-lg font-semibold mb-4">Nous trouver</h3>
<address class="not-italic mb-4">
12 Rue du Fournil<br>
75000 Paris<br>
<a href="tel:+33123456789" class="hover:underline">01 23 45 67 89</a><br>
<a href="mailto:contact@lamainblanche.com" class="hover:underline">contact@lamainblanche.com</a>
</address>
<div class="h-48 bg-gray-200 rounded-lg overflow-hidden">
<!-- Google Maps iframe would go here -->
<div class="w-full h-full flex items-center justify-center bg-gray-100">
<i class="fas fa-map-marker-alt text-3xl text-gray-400"></i>
</div>
</div>
</div>
</div>
<div class="border-t border-amber-700 mt-12 pt-8 text-center text-sm">
<p>&copy; 2023 La Main Blanche - Tous droits réservés</p>
</div>
</div>
</footer>
<script>
// Product data
const products = [
{
id: 1,
name: "Baguette Tradition",
category: "bread",
price: "1,20€",
description: "Farine T65, levain naturel, croûte croustillante",
image: "https://images.unsplash.com/photo-1509440159596-0249088772ff?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=687&q=80"
},
{
id: 2,
name: "Pain de Campagne",
category: "bread",
price: "3,50€",
description: "Mélange de farines, mie alvéolée, saveur rustique",
image: "https://images.unsplash.com/photo-1608190003443-86a8a7f0532c?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1470&q=80"
},
{
id: 3,
name: "Pain aux Céréales",
category: "bread",
price: "4,20€",
description: "Mélange de 7 céréales, riche en fibres",
image: "https://images.unsplash.com/photo-1607326956151-3b61a8c80fb0?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1470&q=80"
},
{
id: 4,
name: "Croissant au Beurre",
category: "pastry",
price: "1,40€",
description: "Beurre AOP Charentes-Poitou, feuilletage léger",
image: "https://images.unsplash.com/photo-1560180474-e856b9717397?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1470&q=80"
},
{
id: 5,
name: "Pain au Chocolat",
category: "pastry",
price: "1,60€",
description: "Chocolat noir 70%, pâte feuilletée au beurre",
image: "https://images.unsplash.com/photo-1627740225794-85c8ab61a3e3?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1470&q=80"
},
{
id: 6,
name: "Brioche Tressée",
category: "pastry",
price: "5,50€",
description: "Brioche moelleuse au beurre, légèrement sucrée",
image: "https://images.unsplash.com/photo-1555507036-ab1f4038808a?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1026&q=80"
},
{
id: 7,
name: "Tartelette aux Fruits",
category: "dessert",
price: "4,80€",
description: "Pâte sablée, crème pâtissière, fruits de saison",
image: "https://images.unsplash.com/photo-1560185007-c5ca9d2c014d?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1470&q=80"
},
{
id: 8,
name: "Flan Nature",
category: "dessert",
price: "3,90€",
description: "Crème vanillée, pâte feuilletée dorée",
image: "https://images.unsplash.com/photo-1627834377411-8da5f4f09de8?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1471&q=80"
}
];
// Testimonial data
const testimonials = [
{
name: "Marie D.",
role: "Cliente fidèle",
content: "Le pain de campagne de La Main Blanche est tout simplement le meilleur que j'ai jamais goûté. La croûte est parfaitement croustillante et la mie a une saveur incomparable. Je ne peux plus m'en passer !",
rating: 5
},
{
name: "Pierre L.",
role: "Nouveau client",
content: "Découvert cette boulangerie par hasard et quelle belle surprise ! Les croissants sont à tomber, avec un feuilletage parfait et un goût de beurre délicieux. Le service est en plus très sympathique.",
rating: 5
},
{
name: "Sophie T.",
role: "Cliente occasionnelle",
content: "J'adore leurs pâtisseries, toujours très fraîches et faites avec des produits de qualité. La tarte aux fraises est mon péché mignon. Un peu cher peut-être, mais ça vaut vraiment le coup !",
rating: 4
},
{
name: "Antoine R.",
role: "Client régulier",
content: "En tant que passionné de bon pain, je peux dire que La Main Blanche est une des meilleures boulangeries de Paris. Leur pain au levain a une acidité parfaitement équilibrée et une texture idéale.",
rating: 5
}
];
// Initialize the page
document.addEventListener('DOMContentLoaded', function() {
// Load products
filterProducts('all');
// Load testimonials
loadTestimonials();
// Add first order item
addOrderItem();
});
// Product filtering
function filterProducts(category) {
const productGrid = document.getElementById('product-grid');
productGrid.innerHTML = '';
// Update active filter button
const filterButtons = document.querySelectorAll('.filter-btn');
filterButtons.forEach(btn => {
btn.classList.remove('active-filter');
if ((btn.textContent === 'Tous' && category === 'all') ||
(btn.textContent === 'Pains' && category === 'bread') ||
(btn.textContent === 'Viennoiseries' && category === 'pastry') ||
(btn.textContent === 'Pâtisseries' && category === 'dessert')) {
btn.classList.add('active-filter');
}
});
// Filter products
const filteredProducts = category === 'all'
? products
: products.filter(product => product.category === category);
// Display products
filteredProducts.forEach(product => {
const productCard = document.createElement('div');
productCard.className = 'product-card bg-white rounded-lg overflow-hidden shadow-md transition duration-300';
productCard.innerHTML = `
<img src="${product.image}" alt="${product.name}" class="w-full h-48 object-cover">
<div class="p-4">
<h3 class="font-bold text-lg mb-1">${product.name}</h3>
<p class="text-gray-600 text-sm mb-2">${product.description}</p>
<div class="flex justify-between items-center">
<span class="font-bold text-amber-600">${product.price}</span>
<button onclick="addToOrder(${product.id})" class="bg-amber-100 hover:bg-amber-200 text-amber-800 px-3 py-1 rounded-full text-sm transition">
<i class="fas fa-plus mr-1"></i>Commander
</button>
</div>
</div>
`;
productGrid.appendChild(productCard);
});
}
// Testimonial carousel
let currentTestimonial = 0;
function loadTestimonials() {
const testimonialSlides = document.getElementById('testimonial-slides');
const testimonialDots = document.getElementById('testimonial-dots');
testimonialSlides.innerHTML = '';
testimonialDots.innerHTML = '';
testimonials.forEach((testimonial, index) => {
// Create slide
const slide = document.createElement('div');
slide.className = 'min-w-full px-4';
slide.innerHTML = `
<div class="testimonial-card bg-white p-8 rounded-lg shadow-md text-gray-800">
<div class="flex items-center mb-4">
${getRatingStars(testimonial.rating)}
</div>
<p class="text-lg italic mb-6">"${testimonial.content}"</p>
<div class="flex items-center">
<div class="w-12 h-12 bg-amber-100 rounded-full flex items-center justify-center mr-4">
<i class="fas fa-user text-amber-600"></i>
</div>
<div>
<h4 class="font-bold">${testimonial.name}</h4>
<p class="text-sm text-gray-600">${testimonial.role}</p>
</div>
</div>
</div>
`;
testimonialSlides.appendChild(slide);
// Create dot
const dot = document.createElement('button');
dot.className = `w-3 h-3 rounded-full ${index === 0 ? 'bg-amber-600' : 'bg-gray-300'}`;
dot.onclick = () => goToTestimonial(index);
testimonialDots.appendChild(dot);
});
updateTestimonialPosition();
}
function getRatingStars(rating) {
let stars = '';
for (let i = 1; i <= 5; i++) {
stars += i <= rating
? '<i class="fas fa-star text-amber-500"></i>'
: '<i class="far fa-star text-amber-500"></i>';
}
return stars;
}
function goToTestimonial(index) {
currentTestimonial = index;
updateTestimonialPosition();
}
function prevTestimonial() {
currentTestimonial = (currentTestimonial - 1 + testimonials.length) % testimonials.length;
updateTestimonialPosition();
}
function nextTestimonial() {
currentTestimonial = (currentTestimonial + 1) % testimonials.length;
updateTestimonialPosition();
}
function updateTestimonialPosition() {
const testimonialSlides = document.getElementById('testimonial-slides');
const dots = document.querySelectorAll('#testimonial-dots button');
testimonialSlides.style.transform = `translateX(-${currentTestimonial * 100}%)`;
dots.forEach((dot, index) => {
dot.className = `w-3 h-3 rounded-full ${index === currentTestimonial ? 'bg-amber-600' : 'bg-gray-300'}`;
});
}
// Order form functionality
function addOrderItem() {
const orderItems = document.getElementById('order-items');
const itemCount = orderItems.children.length + 1;
const orderItem = document.createElement('div');
orderItem.className = 'flex items-start gap-4';
orderItem.innerHTML = `
<div class="flex-1">
<select class="w-full px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-amber-500 focus:border-amber-500">
<option value="">Sélectionnez un produit</option>
${products.map(product => `<option value="${product.id}">${product.name} - ${product.price}</option>`).join('')}
</select>
</div>
<div class="w-24">
<input type="number" min="1" value="1" class="w-full px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-amber-500 focus:border-amber-500">
</div>
<button type="button" onclick="this.parentElement.remove()" class="text-red-500 hover:text-red-700 mt-2">
<i class="fas fa-times"></i>
</button>
`;
orderItems.appendChild(orderItem);
}
function addToOrder(productId) {
const product = products.find(p => p.id === productId);
if (!product) return;
const orderItems = document.getElementById('order-items');
const existingItem = Array.from(orderItems.children).find(item => {
const select = item.querySelector('select');
return select && select.value === productId.toString();
});
if (existingItem) {
const quantityInput = existingItem.querySelector('input[type="number"]');
quantityInput.value = parseInt(quantityInput.value) + 1;
} else {
const orderItem = document.createElement('div');
orderItem.className = 'flex items-start gap-4';
orderItem.innerHTML = `
<div class="flex-1">
<select class="w-full px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-amber-500 focus:border-amber-500">
<option value="">Sélectionnez un produit</option>
${products.map(p => `<option value="${p.id}" ${p.id === productId ? 'selected' : ''}>${p.name} - ${p.price}</option>`).join('')}
</select>
</div>
<div class="w-24">
<input type="number" min="1" value="1" class="w-full px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-amber-500 focus:border-amber-500">
</div>
<button type="button" onclick="this.parentElement.remove()" class="text-red-500 hover:text-red-700 mt-2">
<i class="fas fa-times"></i>
</button>
`;
orderItems.appendChild(orderItem);
}
// Scroll to order form
document.getElementById('order').scrollIntoView({ behavior: 'smooth' });
}
</script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=rasee/rasee-webdesign" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>