body,
html {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  overflow: hidden;
  font-family: "Arial", sans-serif;
}

/* Pantalla de carga */
#loader-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  z-index: 9999;
}

.logo-container {
  position: relative;
  width: 250px;
  height: 250px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* Logo */
.logo {
  width: 100%;
  height: auto;
  opacity: 0;
  animation: fadeIn 1s forwards 2.5s; /* Aparece después de las líneas */
}

/* Texto debajo del logo */
.brand-text {
  margin-top: 20px;
  font-size: 1.8rem;
  font-weight: bold;
  color: #1e63b4;
  letter-spacing: 3px;
  opacity: 0;
  transform: translateY(20px);
  animation: showText 1s ease forwards 1.5s; /* Aparece después del logo */
}

@keyframes showText {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Líneas que cruzan */
.line {
  position: absolute;
  background: #1e63b4;
  animation: drawLine 2s ease forwards;
}

.line:nth-child(1) {
  top: 0;
  left: 50%;
  width: 2px;
  height: 100%;
  transform: translateX(-50%);
  animation-delay: 0s;
}

.line:nth-child(2) {
  left: 0;
  top: 50%;
  width: 100%;
  height: 2px;
  transform: translateY(-50%);
  animation-delay: 0.5s;
}

.line:nth-child(3) {
  top: 0;
  left: 0;
  width: 2px;
  height: 100%;
  animation-delay: 1s;
}

.line:nth-child(4) {
  bottom: 0;
  right: 0;
  width: 100%;
  height: 2px;
  animation-delay: 1.5s;
}

@keyframes drawLine {
  0% {
    transform: scaleX(0) scaleY(0);
    opacity: 0;
  }
  50% {
    transform: scaleX(1) scaleY(1);
    opacity: 1;
  }
  100% {
    transform: scaleX(1) scaleY(1);
    opacity: 0;
  } /* Se desvanece */
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

/* Fade-out del loader completo */
.fade-out {
  animation: fadeOut 1s forwards;
}

@keyframes fadeOut {
  to {
    opacity: 0;
    visibility: hidden;
  }
}
