body { padding: 0; margin: 0 }
#unity-container { position: absolute }
#unity-container.unity-desktop { left: 50%; top: 50%; transform: translate(-50%, -50%) }
#unity-container.unity-mobile { width: 100%; height: 100% }
#unity-canvas { background: #231F20 }
.unity-mobile #unity-canvas { width: 100%; height: 100% }
#unity-loading-bar { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: none }
#unity-logo { width: 154px; height: 130px; background: url('unity-logo-dark.png') no-repeat center }
#unity-progress-bar-empty { width: 141px; height: 18px; margin-top: 10px; background: url('progress-bar-empty-dark.png') no-repeat center }
#unity-progress-bar-full { width: 0%; height: 18px; margin-top: 10px; background: url('progress-bar-full-dark.png') no-repeat center }
#unity-footer { position: relative }
.unity-mobile #unity-footer { display: none }
#unity-webgl-logo { float:left; width: 204px; height: 38px; background: url('webgl-logo.png') no-repeat center }
#unity-build-title { float: right; margin-right: 10px; line-height: 38px; font-family: arial; font-size: 18px }
#unity-fullscreen-button { float: right; width: 38px; height: 38px; background: url('fullscreen-button.png') no-repeat center }
#unity-warning { position: absolute; left: 50%; top: 5%; transform: translate(-50%); background: white; padding: 10px; display: none }

/* Overlay de carga centrado dentro del contenedor de Unity */
#custom-loading {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);

  display: flex;
  align-items: center;
  justify-content: center;

  background: transparent;        /* o transparente si quieres solo el logo */
  padding: 40px 60px;
  border-radius: 8px;
  z-index: 9999;
}

/* Contenedor del logo */
#logo-loading-wrapper {
  position: relative;
  width: 300px;   /* ajusta al tamaño que quieras */
  height: 120px;  /* alto fijo para que la máscara tenga referencia */
}

/* Logo de fondo (baja opacidad) */
#logo-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0.25;
}

/* Máscara que actúa como barra de llenado */
#logo-mask {
  position: absolute;
  top: 25%;
  left: 0;          /* anclado a la izquierda */
  width: 0%;        /* empieza vacío, se llena con el progreso */
  height: 100%;
  overflow: hidden; /* recorta el logo lleno */
  transition: width 0.1s linear;
}

/* Logo lleno dentro de la máscara */
#logo-full {
  height: 48%;
  object-fit: contain;
  object-position: left center; /* se llena desde la izquierda */
}


