/* Reveal the headline by line, never by word. Desktop is one line; phones have two. */
@keyframes invitation-enter {
  from { opacity:0; transform:translateY(-6px); }
  to { opacity:1; transform:translateY(0); }
}
@media (max-width: 600px) {
  .hero-title-line { display:block; }
}
@media (prefers-reduced-motion: no-preference) {
  #hero-title,
  .hero-copy,
  .hero-search {
    animation:invitation-enter 480ms cubic-bezier(0.23, 1, 0.32, 1) 80ms backwards;
  }
  .hero-copy { animation-delay:240ms; }
  .hero-search { animation-delay:320ms; }
  @media (max-width: 600px) {
    #hero-title { animation:none; }
    .hero-title-line {
      animation:invitation-enter 480ms cubic-bezier(0.23, 1, 0.32, 1) 80ms backwards;
    }
    .hero-title-line + .hero-title-line { animation-delay:160ms; }
  }
  /* Do not make a keyboard user wait for a focused field or submit button to appear. */
  .hero-search:focus-within,
  .invitation-entered #hero-title,
  .invitation-entered .hero-title-line,
  .invitation-entered .hero-copy,
  .invitation-entered .hero-search { animation:none; }

  /* Avoid a full-grown fallback flash before the first live sprout frame.
     Failure and no-script states still show the complete static artwork. */
  .meadow-scene[data-scene="loading"] .meadow-static { visibility:hidden; }
}
