/* Cleaned Preloader Styles */

.preloader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999999; /* Ensure it's on top */
    background: #0E1117;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease-out; /* Add transition for hiding */
}

.animation-preloader {
    position: relative; /* Keep relative for absolute positioning of letters::before */
    z-index: 100;
}

.txt-loading {
  text-align: center;
  user-select: none;
}

.txt-loading .letters-loading:before{
  animation: letters-loading 4s infinite;
  content: attr(data-text-preloader);
  left: 0;
  opacity: 0;
  top:0;
  position: absolute;
}

.txt-loading .letters-loading{
  /* Assuming --title-font is defined elsewhere or replace with a fallback */
  font-family: sans-serif; /* Fallback font */
  font-weight: 500;
  letter-spacing: 15px;
  display: inline-block;
  position: relative;
  font-size: 60px;
  line-height: 60px;
  text-transform: uppercase;
  color: transparent;
  -webkit-text-stroke-width: 1px;
  -webkit-text-stroke-color: rgba(255, 255, 255, 0.30);
}

.txt-loading .letters-loading:nth-child(2):before {animation-delay: 0.2s;}
.txt-loading .letters-loading:nth-child(3):before {animation-delay: 0.4s;}
.txt-loading .letters-loading:nth-child(4):before {animation-delay: 0.6s;}
.txt-loading .letters-loading:nth-child(5):before {animation-delay: 0.8s;}
.txt-loading .letters-loading:nth-child(6):before { animation-delay: 1s;}
.txt-loading .letters-loading:nth-child(7):before { animation-delay: 1.2s;}
.txt-loading .letters-loading:nth-child(8):before { animation-delay: 1.4s;}
.txt-loading .letters-loading:nth-child(9):before { animation-delay: 1.6s;}
.txt-loading .letters-loading:nth-child(10):before { animation-delay: 1.8s;}
.txt-loading .letters-loading:nth-child(11):before { animation-delay: 2.0s;}
.txt-loading .letters-loading:nth-child(12):before { animation-delay: 2.2s;}


.txt-loading .letters-loading:before{
  color: #ffffff;
}

/* Animation for letters */
@keyframes letters-loading {
  0%,
  75%,
  100% {
    opacity: 0;
    transform: rotateY(-90deg);
  }

  25%,
  50% {
    opacity: 1;
    transform: rotateY(0deg);
  }
}

/* Media queries for text size */
@media screen and (max-width: 500px) {
  .txt-loading .letters-loading {font-size: 30px; letter-spacing: 10px;}
}