fix: hero neural UX improvements

1. Mouse move listener now on document (not just hero section)
2. Removed hover effect on outer cards, kept only for center กำไร card
3. Bigger text: card-tag 20px, card-desc 16px
4. Hero overflow visible on desktop (cards can extend left)
5. Hero overflow clip on mobile (normal containment)
This commit is contained in:
Kunthawat Greethong
2026-06-24 09:14:55 +07:00
parent 1d893e1bcb
commit 2a3062357f
2 changed files with 13 additions and 9 deletions

View File

@@ -277,7 +277,7 @@ if (heroNeural && neuralScene && canvas && ctx && nodes.length > 0) {
}
// Mouse move handler
heroNeural.addEventListener('mousemove', (e) => {
document.addEventListener('mousemove', (e) => {
const rect = heroNeural.getBoundingClientRect();
const x = (e.clientX - rect.left) / rect.width;
const y = (e.clientY - rect.top) / rect.height;
@@ -286,7 +286,7 @@ if (heroNeural && neuralScene && canvas && ctx && nodes.length > 0) {
targetRotateX = (y - 0.5) * -30;
});
heroNeural.addEventListener('mouseleave', () => {
document.addEventListener('mouseleave', () => {
targetRotateX = 0;
targetRotateY = 0;
});