/* Transiciones pixeladas, scanlines, parpadeos — respetando prefers-reduced-motion */

/* Aparición al hacer scroll: parpadeo tipo "encendido de consola" antes de estabilizarse */
.reveal {
  opacity: 0;
}

.reveal.is-visible {
  animation: pixel-in 0.5s steps(6, end) forwards;
}

.services-grid .reveal:nth-child(2),
.projects-grid .reveal:nth-child(2) {
  animation-delay: 0.08s;
}

.services-grid .reveal:nth-child(3),
.projects-grid .reveal:nth-child(3) {
  animation-delay: 0.16s;
}

.contact-direct.reveal {
  animation-delay: 0.1s;
}

@keyframes pixel-in {
  0% {
    opacity: 0;
    transform: translateY(20px);
    filter: brightness(2.2) contrast(1.6);
  }
  40% {
    opacity: 1;
    filter: brightness(1.6) contrast(1.3);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    filter: brightness(1) contrast(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
  }

  .reveal.is-visible {
    animation: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
