:root { color-scheme: light; font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif; color: #293e32; background: #f7f3e9; }
* { box-sizing: border-box; }
html, body { width: 100%; height: 100%; margin: 0; overflow: hidden; overscroll-behavior: none; -webkit-text-size-adjust: 100%; }
#canvas { display: block; width: 100%; height: 100%; border: 0; outline: none; touch-action: none; }
#loading-screen { position: fixed; inset: 0; z-index: 10; display: grid; place-items: center; overflow: auto; padding: max(28px, env(safe-area-inset-top)) max(24px, env(safe-area-inset-right)) max(24px, env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left)); background: radial-gradient(ellipse at 50% 20%, #fffdf6, #f4efe2); }
.loading-card { width: min(100%, 360px); margin: auto; text-align: center; }
.game-icon { display: block; width: 112px; height: 112px; margin: 0 auto 22px; border-radius: 23px; box-shadow: 0 8px 28px #5c4c3020; }
h1 { margin: 0; font-size: 32px; font-weight: 650; letter-spacing: 2px; }
.wordmark { margin: 8px 0 52px; font-size: 14px; color: #898875; letter-spacing: 5px; }
.download-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; text-align: left; }
#loading-message { margin: 0 0 14px; font-size: 14px; line-height: 1.6; }
#loading-percent { flex-shrink: 0; font-size: 28px; font-weight: 550; font-variant-numeric: tabular-nums; }
#loading-percent span { margin-left: 2px; font-size: 14px; color: #7d8477; }
.progress-track { height: 7px; overflow: hidden; border-radius: 8px; background: #e2e5d8; }
#loading-fill { width: 0; height: 100%; border-radius: inherit; background: #3f654d; transition: width .18s linear; }
.download-details { display: flex; justify-content: space-between; gap: 12px; margin-top: 16px; text-align: left; font-size: 13px; font-variant-numeric: tabular-nums; }
.download-details p { margin: 0; }
.download-details span { display: block; }
.detail-label { margin-bottom: 7px; color: #939789; font-size: 11px; }
.speed { text-align: right; }
.loading-hint { min-height: 40px; margin: 28px 0 0; font-size: 12px; line-height: 1.8; color: #8c9183; }
footer { margin-top: 48px; color: #9ca18f; font-size: 11px; letter-spacing: 2px; }
#loading-retry { display: block; width: 100%; margin-top: 24px; padding: 12px 20px; border: 0; border-radius: 12px; color: #fffdf5; background: #3f654d; font: inherit; cursor: pointer; }
#loading-retry[hidden] { display: none; }
@media (max-height: 540px) { .game-icon { width: 68px; height: 68px; margin-bottom: 12px; border-radius: 15px; } h1 { font-size: 24px; } .wordmark { margin-bottom: 22px; } footer { margin-top: 16px; } .loading-hint { margin-top: 16px; } }
@media (prefers-reduced-motion: reduce) { #loading-fill { transition: none; } }
