html, body { margin: 0; height: 100%; overflow: hidden; }
body {
  /* Sky-to-meadow backdrop behind the portrait game on wide screens */
  background: linear-gradient(#cfe4ff 0%, #eaf2ff 45%, #bfe3a6 45.2%, #8cc46f 100%);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-user-select: none; user-select: none;
  -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent;
  touch-action: none;
}
#stage {
  position: fixed; top: 0; left: 50%; transform: translateX(-50%);
  height: 100vh; height: 100dvh;
  /* Portrait 9:16 on wide screens, the full width on phones */
  width: min(100vw, calc(100vh * 9 / 16)); width: min(100vw, calc(100dvh * 9 / 16));
  background: #eaf2ff;
  box-shadow: 0 0 60px rgba(30, 41, 59, 0.25);
}
#unity-canvas { display: block; width: 100%; height: 100%; outline: none; background: #eaf2ff; }
#loading {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 18px;
  background: linear-gradient(#eaf2ff, #f7f3ea); color: #1e293b;
}
#loading-title { font-size: 40px; font-weight: 800; letter-spacing: 0.5px; }
#loading-track { width: 62%; height: 14px; border-radius: 7px; background: #cbd5e1; overflow: hidden; }
#loading-fill { width: 0; height: 100%; border-radius: 7px; background: #22c55e; transition: width 0.2s; }
#loading-note { font-size: 18px; color: #64748b; }

/* Tip jar (shown only when portal-config.js sets BT_SUPPORT_URL) */
#bt-support { position: fixed; inset: 0; z-index: 20; display: flex; align-items: center; justify-content: center; background: rgba(30, 41, 59, 0.55); touch-action: auto; }
.bt-support-card { width: min(88vw, 380px); padding: 24px; border-radius: 24px; background: #fff; color: #1e293b; text-align: center; box-shadow: 0 12px 40px rgba(30, 41, 59, 0.35); }
.bt-support-card h2 { margin: 0 0 8px; font-size: 28px; }
.bt-support-card p { margin: 0 0 16px; font-size: 17px; line-height: 1.4; }
.bt-support-amounts { display: flex; gap: 12px; justify-content: center; margin-bottom: 14px; }
.bt-support-amounts a { flex: 1; padding: 14px 0; border-radius: 16px; background: #22c55e; box-shadow: 0 5px 0 #15803d; color: #fff; font-size: 22px; font-weight: 800; text-decoration: none; }
.bt-support-card .bt-support-note { font-size: 13px; color: #64748b; }
.bt-support-card button { padding: 10px 28px; border: 2px solid #cbd5e1; border-radius: 14px; background: #fff; color: #64748b; font-size: 17px; font-weight: 700; cursor: pointer; }
#bt-support-chip { position: fixed; right: 20px; bottom: 20px; z-index: 5; padding: 12px 18px; border: 3px solid #fff; border-radius: 999px; background: #fbbf24; box-shadow: 0 5px 0 #d97706; color: #1e293b; font-size: 17px; font-weight: 800; cursor: pointer; }
/* On narrow screens the game fills the page; the tip jar is reached from the ticket office instead. */
@media (max-aspect-ratio: 1/1) { #bt-support-chip { display: none; } }
