#app-startup {
  --startup-bg: #0a0a0c;
  --startup-panel: #111114;
  --startup-border: #302821;
  --startup-text: #e6e0d6;
  --startup-muted: #958d82;
  --startup-accent: #e87826;
  position: fixed;
  z-index: 2147483000;
  inset: 0;
  display: grid;
  place-items: center;
  box-sizing: border-box;
  min-height: 100vh;
  min-height: 100dvh;
  padding: max(24px, env(safe-area-inset-top)) max(20px, env(safe-area-inset-right))
    max(24px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left));
  overflow: auto;
  color: var(--startup-text);
  background:
    radial-gradient(ellipse at 50% 42%, rgba(84, 50, 28, 0.2), transparent 48%),
    var(--startup-bg);
  font-family: "Segoe UI", Tahoma, sans-serif;
  text-align: center;
}

#app-startup[hidden] {
  display: none !important;
}

#app-startup *,
#app-startup *::before,
#app-startup *::after {
  box-sizing: border-box;
}

.app-startup-panel {
  width: min(100%, 440px);
  padding: 44px 38px 38px;
  border: 1px solid var(--startup-border);
  background: linear-gradient(145deg, rgba(21, 20, 20, 0.98), rgba(14, 14, 16, 0.98));
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.42), inset 0 1px rgba(255, 255, 255, 0.025);
}

.app-startup-mark {
  display: block;
  width: 72px;
  height: 72px;
  margin: 0 auto 22px;
  border-radius: 8px;
  background: #000 url("/images/d2r-runetracker-logo.png?v=4") center / cover no-repeat;
}

.app-startup-mark::before,
.app-startup-mark::after {
  display: none;
}

.app-startup-kicker {
  margin: 0 0 13px;
  color: #b8a895;
  font-family: "Courier New", monospace;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.2em;
}

.app-startup-kicker span {
  padding: 0 5px;
  color: var(--startup-accent);
}

#app-startup-title {
  margin: 0;
  color: #e9e2d7;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(24px, 6vw, 30px);
  font-weight: 500;
  line-height: 1.2;
}

#app-startup-message {
  max-width: 310px;
  margin: 12px auto 0;
  color: var(--startup-muted);
  font-size: 14px;
  line-height: 1.65;
}

#app-startup-retry {
  min-height: 44px;
  margin-top: 24px;
  padding: 0 19px;
  border: 1px solid rgba(232, 120, 38, 0.58);
  border-radius: 2px;
  color: #f0e5d7;
  background: rgba(232, 120, 38, 0.11);
  font: 600 13px/1 "Segoe UI", Tahoma, sans-serif;
  cursor: pointer;
}

#app-startup-retry:hover {
  border-color: var(--startup-accent);
  background: rgba(232, 120, 38, 0.18);
}

#app-startup-retry:focus-visible {
  outline: 2px solid #f1a05f;
  outline-offset: 3px;
}

#app-startup-retry[hidden] {
  display: none !important;
}

#app-startup[data-state="error"] .app-startup-mark,
#app-startup[data-state="slow"] .app-startup-mark {
  border-color: rgba(232, 120, 38, 0.82);
}

#app-startup[data-state="error"] #app-startup-title,
#app-startup[data-state="slow"] #app-startup-title {
  color: #f0d2b8;
}

@media (max-width: 480px) {
  #app-startup {
    padding-right: max(16px, env(safe-area-inset-right));
    padding-left: max(16px, env(safe-area-inset-left));
  }

  .app-startup-panel {
    padding: 38px 22px 30px;
  }
}