/* ART_IN'RELVA V5 — Movimento de entrada com linguagem editorial.
   Não altera a disposição, cores, conteúdo nem as interações existentes da V4. */

/* Conteúdo normal permanece visível sem JavaScript. */
@media (prefers-reduced-motion: no-preference) {
  html.motion-ready [data-motion] {
    --entry-duration: 890ms;
    --entry-ease: cubic-bezier(.19,1,.22,1);
    transition-property: opacity, transform, clip-path, filter;
    transition-duration: var(--entry-duration);
    transition-timing-function: var(--entry-ease);
    transition-delay: var(--entry-delay,0ms);
    will-change: opacity, transform;
  }
  html.motion-ready [data-motion="lift"]:not(.motion-in) {
    opacity: 0;
    transform: translate3d(0,33px,0);
  }
  html.motion-ready [data-motion="from-left"]:not(.motion-in) {
    opacity: 0;
    transform: translate3d(-46px,22px,0);
  }
  html.motion-ready [data-motion="from-right"]:not(.motion-in) {
    opacity: 0;
    transform: translate3d(48px,15px,0);
  }
  html.motion-ready [data-motion="fade"]:not(.motion-in) { opacity: 0; }
  html.motion-ready [data-motion="headline"] {
    --entry-duration: 1020ms;
  }
  html.motion-ready [data-motion="headline"]:not(.motion-in) {
    opacity: 0;
    filter: blur(5px);
    transform: translate3d(0,28px,0);
  }
  html.motion-ready [data-motion="card"]:not(.motion-in) {
    opacity: 0;
    transform: translate3d(0,50px,0) scale(.975);
    filter: saturate(.82);
  }
  html.motion-ready [data-motion="photo"] {
    --entry-duration: 1120ms;
  }
  html.motion-ready [data-motion="photo"]:not(.motion-in) {
    opacity: .18;
    clip-path: inset(0 0 15% 0 round 4px);
    transform: translate3d(0,30px,0) scale(1.025);
    filter: saturate(.72);
  }
  html.motion-ready [data-motion="grow"]:not(.motion-in) {
    opacity: 0;
    transform: translate3d(0,18px,0) scale(.68) rotate(-10deg);
  }
  html.motion-ready [data-motion].motion-in {
    opacity: 1;
    transform: translate3d(0,0,0) scale(1) rotate(0);
    clip-path: inset(0 0 0 0);
    filter: none;
  }


  /* Desenho do traço dos quatro pictogramas à medida que surgem. */
  .benefits article svg path,
  .benefits article svg circle {
    stroke-dasharray:180;
    stroke-dashoffset:180;
    transition:stroke-dashoffset 1250ms cubic-bezier(.16,1,.3,1);
    transition-delay:330ms;
  }
  .benefits article.motion-in svg path,
  .benefits article.motion-in svg circle { stroke-dashoffset:0; }

  /* Destaque fotográfico com sensação leve de profundidade. */
  .about-background {
    transform:translate3d(0,var(--photo-depth,0px),0) scale(1.055);
    transition:transform .25s linear;
    will-change:transform;
  }
  .about .since-box { --entry-duration:950ms; }
  .about .about-card { --entry-duration:1050ms; }
  .about-scene.is-visible .about-curve path {
    transition-duration:2900ms;
    transition-timing-function:cubic-bezier(.25,.7,.2,1);
  }

  /* Divisão arquitetónica: desenho existente continua a alternar, conteúdos entram em cascata. */
  .transform-content > h2 { max-width:100%; }
  .transform-content > .button { --entry-duration:940ms; }
  .blueprint .draft-grid { animation: draft-grid-arrives 2.4s ease-out both; }
  @keyframes draft-grid-arrives {
    from { opacity:0; }
    to { opacity:.75; }
  }
  /* As interações dos cartões de serviços seguem a V4: hover ou toque, sem movimento de entrada nos cartões. */

  .project-picture.motion-in > img { animation: photo-reveals 1.45s cubic-bezier(.16,1,.3,1) both; }
  @keyframes photo-reveals {
    from { scale:1.09; filter:saturate(.68); }
    to { scale:1; filter:saturate(1); }
  }
  .contact-collage > img.motion-in { animation: photo-reveals 1.35s cubic-bezier(.16,1,.3,1) both; }


  /* As linhas do FAQ entram como uma sequência tranquila. */
  .faq-list details.motion-in, .detail-question-list details.motion-in {
    transition-duration:740ms;
  }

  /* O painel fotográfico abre suavemente sem interferir com Escape, gestos e setas. */
  .lightbox[open] .lightbox-photo img { animation:photo-lightbox-arrives .43s cubic-bezier(.18,.78,.25,1) both; }
  @keyframes photo-lightbox-arrives {
    from { opacity:.65; scale:.965; }
    to { opacity:1; scale:1; }
  }
}

/* O header e as fotografias não devem usar GPU permanentemente fora de cena. */
html.motion-ready [data-motion].motion-in { will-change:auto; }

/* A hero mantém a tipografia e os slides originais da V4, sem animações de entrada. */
.hero h1 .hero-line { display:block; }

/* Acessibilidade: nenhuma entrada, zoom ou paralaxe para utilizadores sensíveis ao movimento. */
@media (prefers-reduced-motion:reduce) {
  html.motion-ready [data-motion] { opacity:1!important; transform:none!important;clip-path:none!important;filter:none!important;transition:none!important;animation:none!important; }
  .about-background { transform:none!important;transition:none!important; }
  .blueprint .draft-grid, .benefits svg * { animation:none!important; transition:none!important; }
}
