.arrival {
  --arrival-ease: cubic-bezier(.333333, 0, .666667, 1);
  position: fixed;
  inset: 0;
  box-sizing: border-box;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
  color: #f6f7f8;
  background: radial-gradient(ellipse at 68% 35%, #1d2227 0, #101316 37%, #07090b 78%);
}
.arrival:not([open]) { display: none; }
.arrival::backdrop { background: transparent; }
html:has(.arrival[open]) { overflow: hidden; }
.arrival-sky, .arrival-center { position: absolute; inset: 0; width: 100%; height: 100%; }
.arrival-center { display: grid; place-items: center; pointer-events: none; }
.arrival-center:focus { outline: none; }
.arrival-loader, .arrival-title { grid-area: 1 / 1; text-align: center; }
.arrival-loader { transform: scale(var(--approach, .76)); }
.arrival-word {
  display: inline-block;
  position: relative;
  padding-left: .21em;
  color: #f2f3f4;
  font: 400 clamp(20px, 2.2vw, 32px)/1.2 Georgia, "Times New Roman", serif;
  letter-spacing: .21em;
  animation: arrival-breathe 2.4s ease-in-out infinite alternate;
}
.arrival-word::after {
  content: attr(data-word);
  position: absolute;
  inset: 0;
  padding-left: inherit;
  color: transparent;
  text-shadow: none;
  background-image: var(--letter-grain);
  background-clip: text;
  -webkit-background-clip: text;
  opacity: .38;
  animation: arrival-grain .45s steps(1) infinite;
}
.arrival-lights { display: flex; justify-content: center; gap: 5px; margin-top: 11px; }
.arrival-lights i {
  width: 4px; height: 4px; border-radius: 50%;
  background: #f8fafb;
  box-shadow: 0 0 4px 1px #e9f2ff8a, 0 0 10px 2px #c8d6e366;
  animation: arrival-lamp 1.55s ease-in-out infinite;
}
.arrival-lights i:nth-child(2) { animation-delay: -.98s; }
.arrival-lights i:nth-child(3) { animation-delay: -.47s; }
.arrival-title {
  padding: 0 1.2rem;
  font: 570 clamp(25px, 4.3vw, 78px)/1.25 var(--zh-sans, system-ui, sans-serif);
  letter-spacing: .055em;
  color: #f2f4f5;
  text-shadow: 0 0 12px #dde6ee38, 0 0 36px #c4d0dc28;
  opacity: 0;
}
.arrival-title span { font-family: var(--display); }
.arrival[data-leaving] { animation: arrival-out var(--title-duration) var(--arrival-ease) both; }
.arrival[data-leaving] .arrival-loader { animation: arrival-dissolve .9s var(--arrival-ease) both; }
.arrival[data-leaving] .arrival-title { animation: arrival-title-in var(--title-duration) var(--arrival-ease) both; }
.arrival-skip {
  position: absolute;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(19px, env(safe-area-inset-bottom));
  min-height: 44px; padding: 0 .65rem;
  border: 0; background: transparent;
  color: #c5cbd1; font: 400 13px/1.3 var(--zh-sans, sans-serif);
  text-underline-offset: .38em;
}
.arrival-skip:hover, .arrival-skip:focus-visible { color: white; text-decoration: underline; }
@keyframes arrival-breathe {
  from { opacity: .76; text-shadow: 0 0 3px #f7faff70, 0 0 12px #b7c8db42; }
  to { opacity: 1; text-shadow: 0 0 5px #f7faffa6, 0 0 18px #d6e4f477, 0 0 31px #bfcee844; }
}
@keyframes arrival-lamp { 0%, 100% { opacity: .36; } 50% { opacity: 1; } }
@keyframes arrival-grain { 33% { background-position: 11px 4px; } 66% { background-position: -3px 9px; } }
@keyframes arrival-dissolve { to { opacity: 0; filter: blur(2px); } }
@keyframes arrival-title-in {
  0%, 5% { transform: scale(.81); opacity: 0; filter: blur(3px); }
  40%, 100% { transform: scale(1); opacity: 1; filter: blur(0); }
}
/* 片名停稳后，由整层一次淡入首页，避免两层透明度相乘而过早消失。 */
@keyframes arrival-out { 0%, 74% { opacity: 1; } 100% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .arrival *, .arrival *::after, .arrival[data-leaving] { animation: none !important; }
}
