feat: polish motion with stronger easing, press feedback and reduced motion

- Override Tailwind ease-out/ease-in-out with stronger curves, add ease-drawer
- hoverOnlyWhenSupported so hover styles never stick on touch devices
- Replace transition-all with explicit properties across the public UI
- Press feedback via active:scale-[0.97] instead of hover:scale-105
- Global prefers-reduced-motion handling (CSS + MotionConfig reducedMotion="user")
- Mobile menu is a real drawer: stays mounted, inert when closed, Escape closes
- Progress and music bars animate scaleX/scaleY instead of width/height
- Fix undefined animate-spin-slow, contain hero CTA shine with overflow-hidden

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
denshooter
2026-10-15 18:31:58 +02:00
parent 8c3c4ec1d0
commit c847a456a3
20 changed files with 178 additions and 123 deletions
+26 -3
View File
@@ -25,6 +25,11 @@
--input: #efebe9;
--ring: #a1887f; /* Warm brown ring */
--radius: 1rem;
/* Motion tokens: enter/exit = ease-out, on-screen movement = ease-in-out */
--ease-out: cubic-bezier(0.23, 1, 0.32, 1);
--ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
--ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
}
.dark {
@@ -74,6 +79,20 @@ html {
scroll-behavior: smooth;
}
/* Reduced motion: drop movement, keep colour/opacity feedback */
@media (prefers-reduced-motion: reduce) {
html {
scroll-behavior: auto;
}
*,
*::before,
*::after {
animation-duration: 0.01ms !important;
animation-iteration-count: 1 !important;
animation-delay: 0ms !important;
}
}
/* Liquid Glass Effects */
.glass-panel {
background: var(--card);
@@ -92,10 +111,13 @@ html {
box-shadow:
0 4px 6px -1px rgba(0, 0, 0, 0.06),
0 2px 4px -1px rgba(0, 0, 0, 0.05);
transition: all 0.6s cubic-bezier(0.25, 0.1, 0.25, 1);
will-change: transform, box-shadow;
transition:
transform 250ms var(--ease-out),
box-shadow 250ms var(--ease-out),
border-color 200ms ease;
}
@media (hover: hover) and (pointer: fine) {
.glass-card:hover {
background: var(--card);
box-shadow:
@@ -104,6 +126,7 @@ html {
transform: translateY(-4px);
border-color: var(--ring);
}
}
/* Typography & Headings */
h1,
@@ -229,7 +252,7 @@ div {
background: #fffcf5;
border: 1px solid #d7ccc8;
color: #3e2723;
transition: all 0.2s ease;
transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
box-shadow: 0 1px 2px rgba(62, 39, 35, 0.05);
}