/* The page removes the splash when ready. The timeout covers failed imports. */
.pi-brand-splash {
  display: none;
}

@media (prefers-reduced-motion: no-preference) {
  .pi-brand-splash {
    position: fixed;
    inset: 0;
    z-index: 10000;
    /* Override the bundled hidden reset when motion is enabled. */
    display: grid !important;
    place-items: center;
    pointer-events: none;
    background: #f8f9fb;
    animation: pi-splash-timeout 8s step-end both;
  }

  .pi-brand-splash-logo {
    position: relative;
    display: block;
    width: clamp(192px, 26vw, 300px);
    max-width: calc(100vw - 40px);
  }

  .pi-brand-splash-logo img {
    display: block;
    width: 100%;
    height: auto;
    animation: pi-splash-mark 2.4s ease-in-out infinite;
  }

  .pi-brand-splash-logo::after {
    content: "";
    position: absolute;
    inset: auto 8% 4px;
    height: 2px;
    background: #15cfe0;
    transform-origin: left;
    animation: pi-splash-accent 1.7s cubic-bezier(.22, 1, .36, 1) infinite;
  }

  body:focus-within > .pi-brand-splash {
    opacity: 0 !important;
    visibility: hidden !important;
  }
}

@keyframes pi-splash-timeout {
  from { visibility: visible; }
  to { visibility: hidden; }
}

@keyframes pi-splash-mark {
  50% { transform: translateY(-2px); }
}

@keyframes pi-splash-accent {
  0%, 100% { transform: scaleX(.18); opacity: .35; }
  48% { transform: scaleX(1); opacity: 1; }
}
