/* One first-paint entrance. The default styles remain visible without scripts. */
:root {
  --ease-drawer: cubic-bezier(.32, .72, 0, 1);
  --hero-entrance-delay: 180ms;
}

.preview-header {
  animation: hero-entrance-fade 200ms var(--ease-out) var(--hero-entrance-delay) backwards;
}

/* Keep layout and signal geometry stationary while the surface drops into it. */
.hero-drawer {
  position: relative;
  z-index: 2;
  grid-column: 1;
  grid-row: 1;
  justify-self: center;
  width: 88%;
  overflow: clip;
}
.hero .hero-drawer > .hero-workspace {
  width: 100%;
  margin: 0;
  animation: hero-drawer-enter 500ms var(--ease-drawer) var(--hero-entrance-delay) backwards;
}
@media (min-width: 621px) {
  .hero-drawer { margin-bottom: 24px; }
}
@media (max-width: 800px) {
  .hero-drawer { width: 100%; }
}

/* Arc UI TextReveal: https://uiarc.dev/r/text-reveal.json
   Animation and motion tokens copied exactly; selectors scoped to this static
   preview. Keep the page's existing text widths, colors, and line wrapping. */
.hero-reveal {
  --ease-enter: cubic-bezier(.16, 1, .3, 1);
  --ease-standard: cubic-bezier(.22, 1, .36, 1);
  --duration-fast: .16s;
  --reveal-blur: 8px;
  overflow: visible;
}
.hero-reveal-description { --reveal-blur: 4px; }
.hero-reveal-line { display: block; }
.hero-reveal-clip {
  display: inline-block;
  vertical-align: top;
  padding: .1em .16em .24em;
  margin: -.1em -.16em -.24em;
  mask-image: linear-gradient(#000 calc(100% - .18em), transparent);
}
.hero-reveal-word {
  display: inline-block;
  animation:
    hero-word-rise .76s var(--ease-enter) var(--reveal-delay, 0s) backwards,
    hero-word-fade .44s var(--ease-standard) var(--reveal-delay, 0s) backwards,
    hero-word-focus .58s var(--ease-enter) var(--reveal-delay, 0s) backwards;
}
.hero-action-enter {
  display: inline-flex;
  animation: hero-action-enter 300ms var(--ease-out) 700ms backwards;
}
.hero-action-enter + .hero-action-enter { animation-delay: 760ms; }
.hero-action-enter[data-entered] { animation: none; }

/* Focus never waits for the decorative entrance, and press transforms stay free. */
.hero .hero-drawer > .hero-workspace:focus-within { animation: none; }

@keyframes hero-drawer-enter {
  from { transform: translateY(-100%); }
  to { transform: translateY(0); }
}
@keyframes hero-word-rise { from { transform: translateY(.62em); } }
@keyframes hero-word-fade { from { opacity: 0; } }
@keyframes hero-word-focus { from { filter: blur(var(--reveal-blur, 4px)); } }
@keyframes hero-action-enter {
  from { transform: translateY(12px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
@keyframes hero-entrance-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .preview-header,
  .hero .hero-drawer > .hero-workspace,
  .hero-action-enter {
    animation: hero-entrance-fade 200ms ease backwards;
  }
  .hero-reveal-clip { mask-image: none; }
  .hero-reveal-word {
    animation: hero-word-fade var(--duration-fast) var(--ease-standard) backwards;
  }
}

/* Arc UI TextReveal source license:
MIT License

Copyright (c) 2026 Elia Kuratli

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/
