diff --git a/SolarPlanets HTML/Uranus.html b/SolarPlanets HTML/Uranus.html
index 98f790b..6a87383 100644
--- a/SolarPlanets HTML/Uranus.html
+++ b/SolarPlanets HTML/Uranus.html
@@ -5,16 +5,74 @@
3D Model Viewer with Free Movement
+
+
Planet Name: Uranus
+
+ Distance from the Sun: 1.8 billion miles
+
+ Mass: 8.681 x 10 25 kg
+
+ Radius: 15,759 km
+
+ Moons: 27
+
+ Uranus is the seventh planet from the Sun, known for its unique sideways rotation and blue-green color due to methane in its atmosphere.
+
+
+
+
+
@@ -187,6 +245,46 @@
camera.aspect = width / height;
camera.updateProjectionMatrix();
});
+
+ // Handle hover events
+ const hoverBox = document.getElementById("hoverBox");
+ const infoPoint = document.querySelector(".info-point");
+
+ infoPoint.addEventListener("mouseenter", function () {
+ hoverBox.classList.add("active"); // Show the hover box
+ });
+
+ infoPoint.addEventListener("mouseleave", function () {
+ hoverBox.classList.remove("active"); // Hide the hover box
+ });
+
+ // Update the hover box position
+ function updateHoverBoxPosition(event) {
+ const mouseX = event.clientX;
+ const mouseY = event.clientY;
+ hoverBox.style.left = `${mouseX + 20}px`; // Position with some offset
+ hoverBox.style.top = `${mouseY - 20}px`; // Position with some offset
+ }
+
+ // Show the hover box when clicking on the info point
+infoPoint.addEventListener("click", function () {
+hoverBox.classList.toggle("active"); // Toggle the hover box
+});
+
+// Handle click events
+document.addEventListener("click", function (event) {
+// Check if the click was outside the hover box and info point
+const isClickInsideInfoPoint = infoPoint.contains(event.target);
+const isClickInsideHoverBox = hoverBox.contains(event.target);
+
+if (!isClickInsideInfoPoint && !isClickInsideHoverBox) {
+ hoverBox.classList.remove("active"); // Hide the hover box
+}
+});
+
+
+ // Add mouse move event listener to update hover box position
+ window.addEventListener("mousemove", updateHoverBoxPosition);