diff --git a/contact.js b/contact.js
index e4a535a..94d0095 100644
--- a/contact.js
+++ b/contact.js
@@ -4,17 +4,22 @@ const motCaractere = document.getElementById("mot");
const boutonEffacer = document.getElementById("effacer");
const formulaire = document.querySelector("form");
const badge = document.getElementById("statut_horaires");
+
const nom = document.getElementById("prenom");
-const heure = new Date().getHours();
const MAX = 500;
-if (heure >= 9 && heure < 18) {
- badge.textContent = "✅ Nous sommes ouverts (9h–18h)";
- badge.style.color = "green";
-} else {
- badge.textContent = "🔴 Fermé — écrivez-nous, on répond dès l'ouverture !";
- badge.style.color = "red";
+function rafraichir_badge() {
+ const heure = new Date().getHours();
+
+ if (heure >= 9 && heure < 18) {
+ badge.textContent = "✅ Nous sommes ouverts (9h–18h)";
+ badge.style.color = "green";
+ } else {
+ badge.textContent = "🔴 Fermé — écrivez-nous, on répond dès l'ouverture !";
+ badge.style.color = "red";
+ }
}
+setInterval(rafraichir_badge, 60);
function rafraichirCompteur() {
const restant = MAX - zoneMessage.value.length;
@@ -67,3 +72,13 @@ titres.forEach(function (titre) {
reponse.classList.toggle("ouverte");
});
});
+
+const horloge = document.getElementById("horloge");
+
+function afficherHeure() {
+ const maintenant = new Date();
+ horloge.textContent = maintenant.toLocaleTimeString();
+}
+
+afficherHeure();
+setInterval(afficherHeure, 1000);
diff --git a/pages/contact.css b/pages/contact.css
index 5c80a15..bd2adf2 100644
--- a/pages/contact.css
+++ b/pages/contact.css
@@ -187,3 +187,7 @@ body.sombre {
justify-content: center;
padding-top: 30 px;
}
+
+#horloge {
+ text-align: right;
+}
diff --git a/pages/contact.html b/pages/contact.html
index d2d85d4..e224107 100644
--- a/pages/contact.html
+++ b/pages/contact.html
@@ -75,8 +75,9 @@