/* Pantalla de carga global — tema claro de Encantos del Olimpo */
#eco-loading-screen {
  position: fixed;
  inset: 0;
  z-index: 2147483647;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  box-sizing: border-box;
  color: #102640;
  background:
    radial-gradient(circle at 50% 38%, rgba(44, 139, 246, 0.16), transparent 34rem),
    linear-gradient(180deg, #ffffff 0%, #f1f7ff 100%);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 0.38s ease, visibility 0.38s ease;
}

.eco-loader-inner {
  display: flex;
  width: min(100%, 238px);
  padding: 30px 26px 27px;
  box-sizing: border-box;
  flex-direction: column;
  align-items: center;
  gap: 13px;
  text-align: center;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(28, 111, 211, 0.13);
  border-radius: 28px;
  box-shadow:
    0 24px 70px rgba(31, 77, 128, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.eco-loader-logo {
  display: block;
  width: 82px;
  height: 82px;
  object-fit: contain;
  filter: drop-shadow(0 7px 14px rgba(185, 132, 0, 0.24));
  animation: ecoLogoPulse 1.8s ease-in-out infinite;
}

.eco-loader-ring {
  position: relative;
  width: 38px;
  height: 38px;
  box-sizing: border-box;
  flex: 0 0 auto;
  border: 3px solid rgba(28, 119, 223, 0.13);
  border-top-color: #1479e6;
  border-right-color: #69b8ff;
  border-radius: 50%;
  box-shadow: 0 5px 16px rgba(29, 125, 232, 0.14);
  animation: ecoSpin 0.9s linear infinite;
}

.eco-loader-title {
  margin-top: 3px;
  color: #102640;
  font: 800 0.9rem/1.3 Poppins, Arial, sans-serif;
  letter-spacing: 0.16em;
}

.eco-loader-subtitle {
  color: #60768f;
  font: 600 0.75rem/1.3 Poppins, Arial, sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.eco-loader-progress {
  width: 150px;
  height: 4px;
  margin-top: 2px;
  overflow: hidden;
  background: #dceafb;
  border-radius: 999px;
}

.eco-loader-progress span {
  display: block;
  width: 42%;
  height: 100%;
  background: linear-gradient(90deg, #1479e6, #73c2ff);
  border-radius: inherit;
  box-shadow: 0 0 10px rgba(28, 132, 244, 0.28);
  animation: ecoProgress 1.1s ease-in-out infinite;
}

@keyframes ecoSpin {
  to { transform: rotate(360deg); }
}

@keyframes ecoLogoPulse {
  0%, 100% {
    transform: scale(0.985);
    filter: drop-shadow(0 6px 12px rgba(185, 132, 0, 0.2));
  }
  50% {
    transform: scale(1.025);
    filter: drop-shadow(0 8px 17px rgba(185, 132, 0, 0.3));
  }
}

@keyframes ecoProgress {
  0% { transform: translateX(-180%); }
  100% { transform: translateX(420%); }
}

#eco-loading-screen.eco-loading-hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

@media (max-width: 420px) {
  .eco-loader-inner {
    width: min(100%, 218px);
    padding: 26px 22px 24px;
    border-radius: 24px;
  }

  .eco-loader-logo {
    width: 74px;
    height: 74px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #eco-loading-screen,
  #eco-loading-screen * {
    animation: none !important;
    transition: none !important;
  }
}
