Ajout de la page d'acceuil (crée pendant les vacances -> problème de git)

This commit is contained in:
Moncef STITI 2024-01-12 17:05:04 +01:00
parent 1e15408d65
commit 7ea6a7a60c
8 changed files with 196 additions and 0 deletions

BIN
img/LogoNeoEat.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

BIN
img/LogoNeoEat1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

BIN
img/LogoNeoEat2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

BIN
img/LogoNeoEat5.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

BIN
img/LogoNeoEat6.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

40
index.html Normal file
View File

@ -0,0 +1,40 @@
<!DOCTYPE html>
<html lang="fr">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="styles.css">
<title>Neo Eat - Acceuil</title>
</head>
<body>
<header>
<div class="container">
<div id="logo"><img src="img/LogoNeoEat.png" alt="LogoNeoEat"></div>
<nav>
<ul>
<li><a href="#">Accueil</a></li>
<li><a href="#">Menu</a></li>
<li><a href="#">À propos</a></li>
<li><a href="#">Contact</a></li>
</ul>
<div id="menu-icon">&#9776;</div>
<a id="reserve-button" href="#">Réserver une table</a>
</nav>
</div>
</header>
<section id="hero">
<div class="container">
<h1>Bienvenue chez Neo Eat</h1>
<p>Explorez l'avenir de la gastronomie avec notre restaurant 100% automatisé par des robots.</p>
<a href="#menu">Voir le menu</a>
</div>
</section>
<!-- Ajoutez d'autres sections pour présenter votre menu, l'équipe, etc. -->
<script src="script.js"></script>
</body>
</html>

8
script.js Normal file
View File

@ -0,0 +1,8 @@
document.addEventListener('DOMContentLoaded', function () {
const menuIcon = document.getElementById('menu-icon');
const navList = document.querySelector('nav ul');
menuIcon.addEventListener('click', function () {
navList.classList.toggle('show');
});
});

148
styles.css Normal file
View File

@ -0,0 +1,148 @@
body {
margin: 0;
padding: 0;
font-family: 'Arial', sans-serif;
}
header {
background-color: #333;
color: #fff;
padding: 10px 0; /* Ajustez le padding-top pour déplacer légèrement l'image du logo vers le bas */
display: flex;
justify-content: space-between;
align-items: center;
}
#logo {
display: flex;
align-items: center; /* Centrer verticalement le contenu du logo */
}
#logo img {
width: 20%; /* Utiliser 100% de la largeur du conteneur */
height: auto; /* Maintenir le rapport hauteur/largeur pour éviter la distorsion */
margin-top: 5px; /* Ajustez la marge pour déplacer légèrement l'image du logo vers le bas */
}
nav {
display: flex;
align-items: center; /* Centrer verticalement les éléments de la barre de navigation */
}
.container {
width: 80%;
margin: 0 auto;
color:#000000;
}
header {
background-color: #4A305A;
color: #fff;
padding: 15px 0;
display: flex;
justify-content: space-between;
align-items: center;
}
header #logo {
font-size: 24px;
font-weight: bold;
}
nav {
display: flex;
align-items: center;
}
nav ul {
list-style: none;
display: flex;
margin: 0;
padding: 0;
margin-left: auto; /* Pour déplacer vers la droite */
}
nav ul li {
margin-left: 20px;
}
nav a {
text-decoration: none;
color: #fff;
font-weight: bold;
}
#menu-icon {
display: none;
font-size: 24px;
cursor: pointer;
}
#reserve-button {
background-color: orange;
color: #fff;
padding: 10px 20px;
border-radius: 10px;
margin-left: 20px;
}
#hero {
background: url('hero-image.jpg') center/cover;
color: #fff;
text-align: center;
padding: 100px 0;
}
#hero h1 {
font-size: 48px;
margin-bottom: 20px;
}
#hero p {
font-size: 18px;
margin-bottom: 30px;
}
#hero a {
display: inline-block;
background-color: #fff;
color: #333;
padding: 10px 20px;
text-decoration: none;
font-weight: bold;
}
@media screen and (max-width: 768px) {
nav {
flex-direction: column;
align-items: flex-start;
}
nav ul {
display: none;
width: 100%;
text-align: center;
position: absolute;
top: 60px;
left: 0;
background-color: #333;
}
nav ul.show {
display: flex;
flex-direction: column;
}
nav ul li {
margin: 0;
margin-bottom: 10px;
}
#menu-icon {
display: block;
}
#reserve-button {
margin: 20px 0;
}
}