پیش‌نمایش زنده
کد HTML
<div class="loader-stage">
  <div class="sleep-container" role="status" aria-label="Loading content">
    <div class="sleep-group">
      <span class="sleep-letter">L</span>
      <span class="sleep-letter">o</span>
      <span class="sleep-letter">a</span>
      <span class="sleep-letter">d</span>
      <span class="sleep-letter">i</span>
      <span class="sleep-letter">n</span>
      <span class="sleep-letter">g</span>
    </div>
    <div class="sleep-shadow"></div>
  </div>
</div>
کد CSS
.loader-stage {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100%;
  width: 100%;
  background-color: #1a1a2e;
  overflow: hidden;
  user-select: none;
}

.sleep-container {
  --lavender: #a29bfe;
  --mint: #81ecec;
  --depth-l: #6c5ce7;
  --depth-m: #00cec9;
  --glow: rgba(162, 155, 254, 0.3);
  --fs: 4.5em;
  --breath-speed: 3s;

  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.sleep-group {
  display: flex;
  gap: 0.05em;
  font-family: "Arial Rounded MT Bold", "Helvetica Rounded", system-ui,
    sans-serif;
  font-size: var(--fs);
  font-weight: 900;
  perspective: 1200px;
}

.sleep-letter {
  display: inline-block;
  position: relative;
  color: var(--lavender);
  transform-origin: center bottom;
  filter: drop-shadow(0 0.1em 0.5em var(--glow));
  animation:
    breathing var(--breath-speed) infinite ease-in-out,
    nodding calc(var(--breath-speed) * 2) infinite ease-in-out;

  text-shadow:
    0 0.01em 0 var(--depth-l),
    0 0.02em 0 var(--depth-l),
    0 0.03em 0 var(--depth-l),
    0 0.04em 0 var(--depth-l),
    0 0.05em 0 var(--depth-l),
    0 0.1em 0.2em rgba(0, 0, 0, 0.4);
}

.sleep-letter::after {
  content: "z";
  position: absolute;
  top: -20%;
  right: -10%;
  font-size: 0.3em;
  color: white;
  opacity: 0;
  font-weight: 400;
  animation: floating-z 4s infinite;
}

.sleep-letter:nth-child(even) {
  color: var(--mint);
  text-shadow:
    0 0.01em 0 var(--depth-m),
    0 0.02em 0 var(--depth-m),
    0 0.03em 0 var(--depth-m),
    0 0.04em 0 var(--depth-m),
    0 0.05em 0 var(--depth-m),
    0 0.1em 0.2em rgba(0, 0, 0, 0.4);
}

.sleep-letter:nth-child(even)::after {
  content: "Z";
  animation-delay: 1.5s;
}

.sleep-letter:nth-child(1) {
  animation-delay: 0s;
}
.sleep-letter:nth-child(2) {
  animation-delay: 0.3s;
}
.sleep-letter:nth-child(3) {
  animation-delay: 0.6s;
}
.sleep-letter:nth-child(4) {
  animation-delay: 0.9s;
}
.sleep-letter:nth-child(5) {
  animation-delay: 1.2s;
}
.sleep-letter:nth-child(6) {
  animation-delay: 1.5s;
}
.sleep-letter:nth-child(7) {
  animation-delay: 1.8s;
}

.sleep-shadow {
  width: 13em;
  height: 0.6em;
  background: radial-gradient(
    ellipse at center,
    rgba(162, 155, 254, 0.2) 0%,
    transparent 70%
  );
  border-radius: 50%;
  margin-top: 0.8em;
  animation: shadow-breath var(--breath-speed) infinite ease-in-out;
}

@keyframes breathing {
  0%,
  100% {
    transform: scale(1) translateY(0);
    filter: brightness(1);
  }
  50% {
    transform: scale(1.08, 0.95) translateY(0.1em);
    filter: brightness(1.2);
  }
}

@keyframes nodding {
  0%,
  100% {
    transform: rotate(-5deg);
  }
  50% {
    transform: rotate(5deg);
  }
}

@keyframes floating-z {
  0% {
    opacity: 0;
    transform: translate(0, 0) scale(0.5) rotate(0deg);
  }
  20% {
    opacity: 0.8;
  }
  100% {
    opacity: 0;
    transform: translate(1em, -3em) scale(1.5) rotate(20deg);
  }
}

@keyframes shadow-breath {
  0%,
  100% {
    transform: scaleX(1);
    opacity: 0.3;
  }
  50% {
    transform: scaleX(1.3);
    opacity: 0.6;
  }
}

@media (prefers-reduced-motion: reduce) {
  .sleep-letter,
  .sleep-shadow,
  .sleep-letter::after {
    animation: none !important;
    transform: none !important;
  }
}
نوع: loader
تاریخ ایجاد: 2026/06/06
آخرین بروزرسانی: 2026/06/06