/* Make page fill the viewport */
html, body {
  padding: 0;
  margin: 0;
  width: 100%;
  height: 100%;
  background: #000; /* or whatever you want behind the game */
}

/* Base container: fill screen and center contents */
#unity-container {
  position: fixed;      /* cover the viewport */
  inset: 0;             /* top:0; right:0; bottom:0; left:0 */
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Desktop just uses the base behavior */
#unity-container.unity-desktop {
  width: 100%;
  height: 100%;
}

/* Mobile keeps the old full-screen behavior */
#unity-container.unity-mobile {
  position: fixed;
  width: 100%;
  height: 100%;
}

/* Canvas: responsive */
#unity-canvas {
  background: #231F20;

  /* Scale with viewport, keep aspect ratio */
  width: 100%;
  height: auto;
  max-width: 100%;
  max-height: 100%;
}

/* On mobile we still want it to fully fill the screen */
.unity-mobile #unity-canvas {
  width: 100%;
  height: 100%;
}

/* Loading bar stays centered over canvas */
#unity-loading-bar {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: none;
}

/* Footer and misc. styles stay the same */
#unity-footer { position: relative; }
.unity-mobile #unity-footer { display: none; }
#unity-logo-title-footer { float:left; width: 102px; height: 38px; background: url('unity-logo-title-footer.png') no-repeat center }
#unity-build-title { float: right; margin-right: 10px; line-height: 38px; font-family: arial; font-size: 18px }
#unity-fullscreen-button { cursor:pointer; 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 }

/* Hide the Unity footer on desktop too (mobile is already hidden) */
#unity-footer {
  display: none !important;
}

/* ------------------------------------------------------------------ */
/* Full-screen pre-loader visible before Unity bootstraps             */
/* ------------------------------------------------------------------ */

#pr-boot-loader {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  z-index: 9999;            /* above Unity canvas */
}

/* Make sure everything inside is white and readable */
#pr-boot-loader,
#pr-boot-loader * {
  color: #ffffff !important;
}

#pr-boot-loader .pr-boot-inner {
  text-align: center;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  padding: 16px 24px;
}

/* Game title */
#pr-boot-loader .pr-boot-title {
  font-size: 26px;
  font-weight: 600;
  margin-bottom: 10px;
}

/* Loading text + percentage */
#pr-boot-loader .pr-boot-sub {
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 8px;
}

/* Small hint line */
#pr-boot-loader .pr-boot-note {
  font-size: 13px;
  opacity: 0.85;
}


