/* ===== Animation PC (dùng thuộc tính translate/rotate/scale riêng để không đè transform sẵn có) ===== */
.pc::before {
  animation: pc-wave 14s ease-in-out infinite alternate;
}
.pc::after {
  animation: pc-wave 18s ease-in-out infinite alternate-reverse;
}
.pc-logo {
  animation: pc-enter-down 0.7s ease-out both;
}
.pc-home {
  animation: pc-enter-down 0.7s 0.15s ease-out both;
}
.pc-phone {
  animation: pc-enter-left 0.9s 0.25s ease-out both;
}
.pc-side {
  animation: pc-enter-right 0.9s 0.35s ease-out both;
}
.pc-panel-title {
  animation: pc-glow 2.4s ease-in-out infinite;
}
.pc-btn-dl {
  animation: pc-ping 2s ease-out infinite;
}
.pc-btn + .pc-btn .pc-btn-dl {
  animation-delay: 1s;
}
/* Delay âm (gán inline) để các đốm lệch nhịp ngay từ đầu */
.pc-sparkle {
  animation: pc-twinkle 3.2s ease-in-out infinite;
  animation-delay: var(--delay);
}

/* Sóng tỏa từ mặt đĩa sáng của bệ (đo từ phone.png: tâm 50% / 84%) */
.pc-phone::before {
  content: "";
  position: absolute;
  top: 84%;
  left: 50%;
  width: 34%;
  aspect-ratio: 6;
  border: 2px solid rgba(110, 215, 255, 0.9);
  border-radius: 50%;
  box-shadow:
    0 0 12px rgba(80, 200, 255, 0.7),
    inset 0 0 12px rgba(80, 200, 255, 0.5);
  translate: -50% -50%;
  pointer-events: none;
  animation: pc-ripple 2.6s ease-out infinite;
}

/* Vệt sáng quét qua các khối xanh, logo và điện thoại */
.pc-home::after,
.pc-btn-os::before,
.pc-btn-dl::before,
.pc-logo::after,
.pc-phone::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(110deg, transparent 40%, rgba(255, 255, 255, 0.55) 50%, transparent 60%)
    no-repeat;
  background-size: 250% 100%;
  pointer-events: none;
  animation: pc-shine 3.6s ease-in-out infinite;
}
.pc-btn + .pc-btn .pc-btn-os::before,
.pc-btn + .pc-btn .pc-btn-dl::before {
  animation-delay: 0.4s;
}
/* Logo, điện thoại không phải khối chữ nhật: cắt vệt sáng theo đúng hình ảnh */
.pc-logo::after {
  -webkit-mask: url("../images/logo.png") center / 100% 100% no-repeat;
  mask: url("../images/logo.png") center / 100% 100% no-repeat;
  animation-delay: 1.2s;
  animation-duration: 4s;
}
.pc-phone::after {
  -webkit-mask: url("../images/phone.png") center / 100% 100% no-repeat;
  mask: url("../images/phone.png") center / 100% 100% no-repeat;
  animation-delay: 2s;
  animation-duration: 5s;
}

@keyframes pc-enter-down {
  from {
    opacity: 0;
    translate: 0 -30px;
  }
}
@keyframes pc-enter-left {
  from {
    opacity: 0;
    translate: -80px 0;
  }
}
@keyframes pc-enter-right {
  from {
    opacity: 0;
    translate: 80px 0;
  }
}
@keyframes pc-wave {
  to {
    translate: 0 -20px;
    rotate: 2deg;
  }
}
@keyframes pc-glow {
  50% {
    box-shadow: 0 4px 24px rgba(43, 184, 243, 0.8);
  }
}
@keyframes pc-ripple {
  from {
    opacity: 1;
    scale: 1;
  }
  to {
    opacity: 0;
    scale: 2.6;
  }
}
@keyframes pc-ping {
  from {
    box-shadow: 0 0 0 0 rgba(43, 184, 243, 0.7);
  }
  70%,
  to {
    box-shadow: 0 0 0 12px rgba(43, 184, 243, 0);
  }
}
@keyframes pc-twinkle {
  0%,
  100% {
    opacity: 0.15;
    scale: 0.5;
    rotate: 0deg;
  }
  50% {
    opacity: 1;
    scale: 1;
    rotate: 45deg;
  }
}
@keyframes pc-shine {
  0% {
    background-position: 150% 0;
  }
  45%,
  100% {
    background-position: -50% 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pc::before,
  .pc::after,
  .pc *,
  .pc *::before,
  .pc *::after {
    animation: none !important;
    transition: none !important;
  }
}
