feat(hero): make the three floating cards open their project

- cards are links to the same project_url as the grid card (new tab, noopener)
- drop aria-hidden from the stack and restore pointer events; add hover/focus/active states
- entrance animation moves to the translate property with fill-mode backwards so the
  staggered offsets/rotation and the hover lift are no longer overridden
- reduced-motion keeps the stagger (translate: none) without killing the layout
This commit is contained in:
Bkk1234 committed 2026-11-20 14:37:43 +07:00
1 parent e87e00896c
commit 0bfbefd930
4 files changed
+48 -12

No files matched your search

+18 -2
View File
@@ -89,6 +89,16 @@ html.fx-motion .scroll-progress__bar {
transform: none;
}
}
@keyframes fx-deco-in {
from {
opacity: 0;
translate: -22px 0;
}
to {
opacity: 0.97;
translate: 0 0;
}
}
@keyframes fx-orb-a {
from {
transform: translate3d(0, 0, 0) scale(1);
@@ -130,8 +140,10 @@ html.fx-motion .searchbar {
html.fx-motion .hero__meta {
animation: fx-fade-in 620ms var(--ease) 760ms both;
}
/* การ์ดลอย: ใช้ translate (ไม่ใช่ transform) และ fill-mode backwards
เพื่อไม่ให้ทับ transform เดิม (ระยะเยื้อง/ความเอียง) และไม่ทับ hover */
html.fx-motion .hero__deco-card {
animation: fx-slide-in 700ms var(--ease) both;
animation: fx-deco-in 700ms var(--ease) backwards;
}
html.fx-motion .hero__deco-card:nth-child(1) {
animation-delay: 320ms;
@@ -286,7 +298,6 @@ html.fx-motion .section-head[data-revealed] .section-head__title::after {
html.fx-motion [data-reveal][data-revealed],
html.fx-motion .hero__eyebrow,
html.fx-motion .hero__lead,
html.fx-motion .hero__deco-card,
html.fx-motion .fx-word > span,
html.fx-motion .section-head[data-revealed] .section-head__title::after,
html.fx-motion .btn--primary::after {
@@ -295,6 +306,11 @@ html.fx-motion .section-head[data-revealed] .section-head__title::after {
transform: none !important;
filter: none !important;
}
html.fx-motion .hero__deco-card {
animation: none !important;
opacity: 0.97 !important;
translate: none !important;
}
html.fx-motion .hero__orb {
animation: none !important;
}