From a5c212deee148c41aaf80ec8fca05930765df183 Mon Sep 17 00:00:00 2001 From: Cassie Date: Tue, 25 Feb 2025 14:11:21 -0500 Subject: [PATCH] Gravity Balls: Added reset button and multi-touch --- html/1-Balls/balls.html | 243 +++++++++++++++++++++------------------- 1 file changed, 127 insertions(+), 116 deletions(-) diff --git a/html/1-Balls/balls.html b/html/1-Balls/balls.html index cae3dd4..82a403b 100644 --- a/html/1-Balls/balls.html +++ b/html/1-Balls/balls.html @@ -10,51 +10,79 @@ position: fixed; top: 10px; left: 10px; color: white; font-family: Arial; pointer-events: none; } + + #resetBtn { + position: fixed; + top: 20px; + left: 20px; + padding: 12px 24px; + background: rgba(255, 255, 255, 0.1); + border: 2px solid rgba(255, 255, 255, 0.3); + color: white; + font-family: Arial; + font-size: 16px; + border-radius: 30px; + cursor: pointer; + backdrop-filter: blur(5px); + transition: all 0.3s ease; + box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2); + z-index: 1000; + } + + #resetBtn:hover { + background: rgba(255, 0, 100, 0.3); + border-color: rgba(255, 0, 100, 0.7); + transform: scale(1.05); + } + + #resetBtn:active { + transform: scale(0.95); + background: rgba(255, 0, 100, 0.3); + border-color: rgba(255, 255, 255, 0.3); + } + + @media (hover: none) { + #resetBtn:hover { + background: rgba(255, 255, 255, 0.1); + border-color: rgba(255, 255, 255, 0.3); + transform: none; + } + }
+ - -- 2.43.0