/* Motion decor never hides content or intercepts clicks. */
.motion-letter{display:inline-block;transform-origin:50% 85%}
@keyframes lovi-course-current{0%{transform:scaleX(.03);opacity:0}12%{opacity:1}70%{transform:scaleX(1);opacity:1}90%,100%{transform:scaleX(1);opacity:0}}
@media(prefers-reduced-motion:no-preference){
  body.lovi-motion .motion-course-row::after{content:'';position:absolute;bottom:-1px;left:0;width:100%;height:2px;background:linear-gradient(90deg,#3b88b5,#99cfdf);transform-origin:left;pointer-events:none;opacity:0;animation:lovi-course-current 10.8s ease-in-out infinite;animation-play-state:paused}
  body.lovi-motion .motion-course-row.motion-in-view::after{animation-play-state:running}
  body.lovi-motion.motion-suspended .motion-course-row::after{animation-play-state:paused}
}
.motion-reading-progress{position:fixed;top:0;left:0;width:100%;height:2px;z-index:100;pointer-events:none;background:linear-gradient(90deg,#2d7fc3,#87d5eb 80%,#eeb66a);transform:scaleX(0);transform-origin:left}
body.lovi-motion .motion-glow{position:absolute;left:0;top:0;width:180px;height:180px;pointer-events:none;border-radius:50%;background:radial-gradient(circle,rgba(255,255,255,.4),rgba(255,255,255,0) 70%);opacity:0;z-index:3;transition:opacity 0.7875s;contain:strict}
body.lovi-motion .motion-tracking>.motion-glow{opacity:1}
@media(prefers-reduced-motion:no-preference) and (hover:hover) and (pointer:fine){
  body.lovi-motion :is(.agent-showcase[data-count] .motion-depth,.market-grid .motion-depth){position:relative;transition:transform 1.125s cubic-bezier(.2,.8,.2,1),background 0.5625s,border-color 0.5625s;transform-origin:center}
  body.lovi-motion.home-page.home-cards-refresh .agent-showcase[data-count] .motion-depth{transition:transform 1.125s cubic-bezier(.2,.8,.2,1),background 0.5625s,border-color 0.5625s}
  body.lovi-motion.home-page.home-cards-refresh .product-grid[data-count] .motion-image .motion-pointer-target{transition:transform 1.4625s cubic-bezier(.2,.8,.2,1)}
  body.lovi-motion .motion-magnet,body.lovi-motion.home-page.home-cards-refresh .topic-grid.course-notification-stack .motion-magnet{transition:transform 0.9s cubic-bezier(.2,.8,.2,1),color 0.45s,background 0.45s,border-color 0.45s}
  body.lovi-motion .motion-course-row::after{content:'';position:absolute;bottom:-1px;left:0;width:100%;height:2px;background:linear-gradient(90deg,#3b88b5,#99cfdf);transform:scaleX(0);transform-origin:left;transition:transform 1.575s cubic-bezier(.16,1,.3,1);pointer-events:none}
  body.lovi-motion .motion-course-row:hover::after,body.lovi-motion .motion-course-row:focus-within::after{transform:scaleX(1)}
  body.lovi-motion .motion-course-row .topic-art{transition:translate 1.35s cubic-bezier(.16,1,.3,1)}
  body.lovi-motion .motion-course-row:hover .topic-art{translate:4px 0}
}
@media(prefers-reduced-motion:reduce){
  body.lovi-motion .motion-pointer-target{transition:none!important}
  .motion-glow{display:none}
}

/* Team portraits share the existing slow motion rhythm. */
@media(prefers-reduced-motion:no-preference) and (hover:hover) and (pointer:fine){
  body.lovi-motion .people-grid>.motion-depth{transition:transform 1.125s cubic-bezier(.2,.8,.2,1);transform-origin:center}
  body.lovi-motion .people-grid .person-photo{transition:transform 1.5s cubic-bezier(.2,.8,.2,1)}
  body.lovi-motion .people-grid .person:hover .person-photo{transform:scale(1.025)}
}
/* Set before content is parsed, so incoming cards never flash visible first. */
@media(prefers-reduced-motion:no-preference){
html.motion-reveal-enabled main :is(.showcase-head h3,.commerce .section-top h2,.classroom-head h2,.company-news-head h2,.catalog-intro h1,.market-catalog-head h2,.miniapp-entry h2,.join-page-next h2,.agent-showcase>.agent-work,.product-grid>.product,.topic-grid>.topic,.market-grid>.market-item,.company-news-card,.agent-detail-use-card,.people-grid>.person):not(.hero *,.miniapp-builder *):not(.motion-revealed) {opacity:0}
html.motion-reveal-enabled main :is(.showcase-head h3,.commerce .section-top h2,.classroom-head h2,.company-news-head h2,.catalog-intro h1,.market-catalog-head h2,.miniapp-entry h2,.join-page-next h2,.agent-showcase>.agent-work,.product-grid>.product,.topic-grid>.topic,.market-grid>.market-item,.company-news-card,.agent-detail-use-card,.people-grid>.person):not(.hero *,.miniapp-builder *):not(.motion-revealed):focus-within {opacity:1}
}

/* Each destination underline stays hidden until hover or keyboard focus. */
html body .site-header.nav-refined .header-inner .primary-nav > a:not(#nav-login)::after {
  content: ''; position: absolute; left: 50%; top: auto; bottom: 2px;
  width: 0; height: 2px; padding: 0; border: 0; border-radius: 2px;
  background: currentColor; box-shadow: none; pointer-events: none;
  opacity: 0 !important; transform: translateX(-50%) !important;
  transition: width .7s cubic-bezier(.22,1,.36,1), opacity .4s;
}
html body .site-header.nav-refined .header-inner .primary-nav > a:not(#nav-login):is(:hover,:focus-visible)::after {
  width: calc(100% - 8px); opacity: 1 !important;
}
@media(prefers-reduced-motion:reduce) {
  html body .site-header.nav-refined .header-inner .primary-nav > a:not(#nav-login)::after { transition: none; }
}