html, body { padding: 0; margin: 0; width: 100%; height: 100%; overflow: hidden; background: #000 }
/* 固定 16:9 画布，浏览器比例不足时保留黑边，避免 UI 被拉伸。 */
#tuanjie-container {
  position: fixed;
  left: 50%;
  top: 50%;
  width: min(100vw, calc(100vh * 16 / 9));
  height: min(100vh, calc(100vw * 9 / 16));
  aspect-ratio: 16 / 9;
  transform: translate(-50%, -50%);
  overflow: hidden;
  background: #000;
}
#tuanjie-container.tuanjie-desktop { left: 50%; top: 50%; transform: translate(-50%, -50%) }
#tuanjie-container.tuanjie-mobile { position: fixed; left: 50%; top: 50%; width: min(100vw, calc(100vh * 16 / 9)); height: min(100vh, calc(100vw * 9 / 16)); transform: translate(-50%, -50%) }
#tuanjie-canvas { width: 100%; height: 100%; display: block; background: #231F20 }
.tuanjie-mobile #tuanjie-canvas { width: 100%; height: 100% }
#tuanjie-loading-bar {
  position: fixed; inset: 0; z-index: 10000; box-sizing: border-box;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  overflow: auto; color: #e4f4ff; font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
  background: radial-gradient(ellipse at 50% 38%, #12384e 0%, #081d2e 42%, #040d18 100%);
  transition: opacity .4s ease; isolation: isolate;
}
#tuanjie-loading-bar[hidden] { display: none }
#tuanjie-loading-bar.is-leaving { opacity: 0 }
.startup-grid {
  position: absolute; inset: 0; z-index: -1; opacity: .2;
  background-image: linear-gradient(#53819c22 1px, transparent 1px), linear-gradient(90deg, #53819c22 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse, #000, transparent 80%);
}
.startup-brand { position: absolute; top: 32px; left: 40px; display: flex; align-items: center; gap: 12px; color: #b1cbdc; font-size: 13px; letter-spacing: 2px }
.brand-mark { width: 29px; height: 29px; display: grid; place-items: center; color: #74ddf2; border: 1px solid #3e8baf; border-radius: 6px; font-size: 17px; font-weight: 700 }
.brand-dot { width: 5px; height: 5px; border-radius: 50%; background: #6de3d0; margin-left: 4px; box-shadow: 0 0 10px #6de3d066 }
.startup-content { width: min(520px, calc(100% - 48px)); margin: 82px 0 90px; text-align: center; position: relative }
.startup-emblem { position: relative; width: 174px; height: 186px; margin: 0 auto 12px }
.startup-emblem svg { height: 180px; width: 160px; position: relative }
.emblem-orbit { position: absolute; left: 7px; right: 7px; height: 160px; top: 12px; border: 1px solid #4696b538; border-radius: 50%; box-shadow: 0 0 45px #2bbbe810, inset 0 0 30px #2bbbe810 }
.emblem-orbit::after { content: ""; position: absolute; inset: -8px; border: 1px dashed #74ddf22b; border-radius: 50%; animation: startup-orbit 40s linear infinite }
.startup-eyebrow { margin: 0 0 12px; color: #76c6df; font-size: 12px; letter-spacing: 5px }
.startup-content h1 { font-size: clamp(24px, 3.1vw, 38px); font-weight: 600; line-height: 1.5; letter-spacing: 3px; margin: 0 0 40px; text-shadow: 0 2px 16px #47bedb15 }
.startup-content h1 span { color: #b4d4e6; font-size: .82em; font-weight: 400; letter-spacing: 7px }
.startup-progress-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; text-align: left; margin-bottom: 12px; font-size: 14px; color: #c5dce9 }
.startup-percent { white-space: nowrap; color: #73dcf0; font-size: 12px }
.startup-percent strong { font-family: "Bahnschrift", "Segoe UI", sans-serif; font-size: 23px; font-weight: 400; margin-right: 3px; font-variant-numeric: tabular-nums }
#tuanjie-progress-bar-empty { width: 100%; height: 5px; background: #1b3a50; border-radius: 4px; overflow: hidden }
#tuanjie-progress-bar-full { width: 0%; height: 100%; background: linear-gradient(90deg, #2786c7, #69e1db); border-radius: inherit; transition: width .3s ease }
.startup-steps { list-style: none; margin: 18px 0 0; padding: 0; display: flex; justify-content: space-between; font-size: 11px; color: #638399; letter-spacing: 1px }
.startup-steps li::before { content: ""; display: inline-block; width: 4px; height: 4px; margin-right: 8px; vertical-align: middle; background: #3b576b; border-radius: 50% }
.startup-steps .is-current { color: #c0e9f1 }
.startup-steps .is-current::before { background: #73dcf0; box-shadow: 0 0 9px #73dcf088 }
.startup-steps .is-done { color: #66bdb6 }
.startup-steps .is-done::before { background: #66bdb6 }
#startup-detail { min-height: 36px; margin: 24px 0 0; color: #7899ad; font-size: 12px; line-height: 1.8; overflow-wrap: anywhere }
#startup-retry { margin: 14px 0 0; border: 1px solid #3d91b6; border-radius: 5px; background: #153b55; color: #d8f2ff; padding: 10px 25px; font: inherit; font-size: 13px; cursor: pointer; transition: background .15s }
#startup-retry:hover { background: #225573 }
#startup-retry:focus-visible { outline: 2px solid #86eff3; outline-offset: 4px }
.has-error #startup-stage { color: #ffc693 }
.startup-footer { position: absolute; bottom: 28px; display: flex; align-items: center; gap: 13px; font-size: 11px; letter-spacing: 2px; color: #67859a }
.startup-indicator { width: 4px; height: 4px; background: #4598b3; border-radius: 50% }
.footer-divider { color: #35566b; margin: 0 6px }
.startup-noscript { position: absolute; bottom: 70px; color: #ffc693; text-align: center }
@keyframes startup-orbit { to { transform: rotate(360deg) } }
@media (max-height: 800px) {
  .startup-content { margin-top: 72px; margin-bottom: 60px }
  .startup-emblem { width: 130px; height: 126px; margin-bottom: 4px }
  .startup-emblem svg { width: 115px; height: 130px }
  .emblem-orbit { height: 112px; top: 7px }
  .startup-content h1 { margin-bottom: 22px; font-size: 26px }
  #startup-detail { margin-top: 16px }
}
@media (max-width: 600px) {
  .startup-brand { top: 23px; left: 22px; font-size: 11px; letter-spacing: 1px }
  .startup-footer { letter-spacing: 0; gap: 5px; font-size: 10px; bottom: 20px }
  .startup-content h1 { letter-spacing: 1px }
  .startup-content h1 span { letter-spacing: 4px }
}
@media (max-height: 490px) {
  .startup-brand { top: 16px }
  .startup-content { margin-top: 58px; margin-bottom: 55px }
  .startup-emblem { display: none }
  .startup-content h1 { font-size: 22px; margin-bottom: 18px }
  .startup-steps { margin-top: 12px }
  #startup-detail { margin-top: 10px; min-height: 0 }
  .startup-footer { bottom: 16px }
}
@media (prefers-reduced-motion: reduce) {
  .emblem-orbit::after { animation: none }
  #tuanjie-loading-bar, #tuanjie-progress-bar-full { transition: none }
}
#tuanjie-fullscreen-button { position: absolute; right: 12px; bottom: 12px; cursor: pointer; width: 38px; height: 38px; background: rgba(0, 0, 0, 0.35) url('fullscreen-button.png') no-repeat center; border-radius: 4px }
.tuanjie-mobile #tuanjie-fullscreen-button { display: none }
#tuanjie-warning { position: absolute; left: 50%; top: 5%; transform: translate(-50%); background: #0b2940; color: #d7efff; padding: 10px; display: none }
