/* Kinetic editorial: quick feedback, one short decorative phrase, no hidden copy. */
:root {
  --motion-quick: 180ms;
  --motion-art: 320ms;
  --motion-detail: 420ms;
  --ease-settle: cubic-bezier(.2, .75, .25, 1);
  --ease-feedback: cubic-bezier(.2, .6, .3, 1);
}

/* The ink stays dark until the orange panel has fully arrived. */
.highlight { position: relative; isolation: isolate; background: transparent; }
.highlight::before {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: var(--orange); transform-origin: left center;
}

/* A looping underline follows the phrase without moving the text. */
.contact h2 .contact-bridge, .evidence-bridge { position: relative; width: fit-content; }
.evidence-bridge { display: inline-block; }
.contact-bridge::after, .evidence-bridge::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -.14em;
  height: clamp(2px, .045em, 3px); border-radius: 999px;
  background: var(--orange); pointer-events: none;
  transform-origin: left center;
}
.evidence-bridge::after { bottom: 0; }

.button { transition: background-color var(--motion-quick) var(--ease-feedback), border-color var(--motion-quick) var(--ease-feedback); }
.button:hover, .button:active, .project-card:hover { transform: none; }
.project-card { transition: none; }
.button > svg, .text-link > svg, .art-project > svg,
.mobile-menu nav a > svg, .project-card svg {
  transition: translate var(--motion-quick) var(--ease-feedback);
}
.project-screen img { transition: scale var(--motion-detail) var(--ease-settle); }
.art-project { transition: background-color var(--motion-quick) var(--ease-feedback); }
.text-link { transition: text-decoration-color var(--motion-quick) var(--ease-feedback); }
.article-faq summary { transition: color var(--motion-quick) var(--ease-feedback); }
.article-faq summary:focus-visible { color: var(--action); }
.article-sources > summary::after { transition: transform var(--motion-quick) var(--ease-feedback); }
.menu-lines, .menu-lines::before, .menu-lines::after {
  transition: transform var(--motion-quick) var(--ease-feedback), opacity var(--motion-quick) var(--ease-feedback);
}
.desktop-nav a { position: relative; }
.desktop-nav a::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 7px;
  height: 1px; background: currentColor; transform: scaleX(0); transform-origin: left;
  transition: transform var(--motion-quick) var(--ease-feedback);
}
.desktop-nav a:hover { text-decoration: none; }
.desktop-nav a:focus-visible::after { transform: scaleX(1); }
.button:focus-visible { background: #ad2c08; border-color: #ad2c08; }
.button.button-secondary:focus-visible { background: transparent; border-color: var(--ink); }
.text-link:focus-visible { text-decoration-color: var(--ink); }
.art-project:focus-visible { background: #2a2926; }
:is(.button, .text-link, .art-project, .mobile-menu nav a):focus-visible > svg,
.project-card:focus-visible .project-destination svg { translate: 3px 0; }
.project-card:focus-visible .project-card-top svg { translate: 4px -4px; }
.project-card:focus-visible .project-screen img { scale: 1.02; }
.mobile-menu nav a:active { color: var(--action); }

/* Hover is an enhancement for a pointing device; touch links work on the first tap. */
@media (hover: hover) and (pointer: fine) {
  :is(.button, .text-link, .art-project, .mobile-menu nav a):hover > svg,
  .project-card:hover .project-destination svg { translate: 3px 0; }
  .project-card:hover .project-card-top svg { translate: 4px -4px; }
  .project-card:hover .project-screen img { scale: 1.02; }
  .desktop-nav a:hover::after { transform: scaleX(1); }
  .article-faq summary:hover { color: var(--action); }
}

/* A press retracts the arrow slightly; the button and its hit area stay still. */
.button:not(:disabled):active > svg, .text-link:active > svg { translate: 2px 0; }

@media (prefers-reduced-motion: no-preference) {
  .contact-bridge::after, .evidence-bridge::after { animation: contact-underline 3.2s var(--ease-settle) infinite; }
  .hero .highlight { animation: hero-accent-ink 640ms linear both; }
  .hero .highlight::before { animation: hero-accent-reveal 480ms var(--ease-settle) both; }
  .hero-art .device {
    animation: hero-settle var(--motion-detail) var(--ease-settle) both;
  }
  .motion-ready.is-in-view:is(.present-art, .shop-art, .renew-art) :is(.page-composition, .shop-listing, .renew-sheet) {
    animation: service-settle var(--motion-art) var(--ease-settle) both;
  }
  .article-faq details[open] > p {
    animation: state-appear 160ms var(--ease-feedback) both;
  }
  /* The static K stays visible; only an identical, faint ink layer is swept. */
  .signature-transition.motion-ready:not(.is-in-view) .signature-thread { transform: scaleX(0); }
  .signature-transition.motion-ready .signature-thread { transform-origin: left center; }
  .signature-transition.motion-ready.is-in-view .signature-thread {
    animation: signature-thread 640ms var(--ease-settle) both;
  }
  .signature-transition.motion-ready.is-in-view .signature-ink {
    animation: signature-ink 480ms var(--ease-feedback) 160ms both;
  }
}

@keyframes contact-underline {
  0% { transform: scaleX(0); transform-origin: left center; }
  38%, 58% { transform: scaleX(1); transform-origin: left center; }
  59% { transform: scaleX(1); transform-origin: right center; }
  88%, 100% { transform: scaleX(0); transform-origin: right center; }
}
@keyframes hero-settle { from { translate: 0 8px; } to { translate: 0 0; } }
@keyframes hero-accent-reveal { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes hero-accent-ink { 0%, 75% { color: var(--ink); } 100% { color: #fff; } }
@keyframes service-settle { from { translate: 0 4px; } to { translate: 0 0; } }
@keyframes state-appear { from { opacity: .8; } to { opacity: 1; } }
@keyframes signature-thread { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes signature-ink {
  0% { clip-path: inset(0 100% 0 0); opacity: .16; }
  70% { clip-path: inset(0); opacity: .16; }
  100% { clip-path: inset(0); opacity: 0; }
}

/* Keep focus and color feedback, but remove all decorative travel and zoom. */
@media (prefers-reduced-motion: reduce) {
  .project-screen img { scale: none !important; }
  :is(.button, .text-link, .art-project, .mobile-menu nav a, .project-card) svg { translate: none !important; }
}
