.desktop-boot {
  box-sizing: border-box;
  display: grid;
  min-height: 100vh;
  min-height: 100dvh;
  place-content: center;
  justify-items: center;
  gap: 1.75rem;
  padding: max(1.5rem, env(safe-area-inset-top)) max(1.5rem, env(safe-area-inset-right))
    max(1.5rem, env(safe-area-inset-bottom)) max(1.5rem, env(safe-area-inset-left));
  color: #18181b;
  background:
    radial-gradient(circle at 50% 38%, rgb(220 82 56 / 9%), transparent 30rem), #f9f8f6;
  font-family: "Mulish Variable", "Segoe UI", system-ui, sans-serif;
  text-align: center;
}

.desktop-boot *,
.desktop-boot *::before,
.desktop-boot *::after {
  box-sizing: inherit;
}

/* Fade in after a beat so a fast start never flashes the boot view. */
.desktop-boot--loading > * {
  animation: desktop-boot-enter 0.32s ease-out 0.12s both;
}

.desktop-boot__logo {
  display: block;
  width: 48px;
  height: 48px;
  border-radius: 11px;
  box-shadow: 0 10px 28px -12px rgb(220 82 56 / 55%);
}

.desktop-boot__copy {
  display: grid;
  width: 100%;
  max-width: 28rem;
  gap: 0.6rem;
}

.desktop-boot__kicker {
  margin: 0;
  color: #b23a20;
  font-family: ui-monospace, "Cascadia Mono", Menlo, monospace;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

/* Playfair is not loaded yet at boot, so the title usually renders in the
   Georgia fallback; keep tracking and size moderate enough for either face. */
.desktop-boot__title {
  margin: 0;
  font-family: "Playfair Display Variable", "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: clamp(1.625rem, 1.2rem + 1.6vw, 2.25rem);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.012em;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

.desktop-boot__message {
  margin: 0;
  color: #5f5b57;
  font-size: 0.95rem;
  line-height: 1.6;
  text-wrap: pretty;
}

.desktop-boot__message a {
  color: #b23a20;
  font-weight: 600;
  text-underline-offset: 0.2em;
}

.desktop-boot__progress {
  width: 9rem;
  height: 3px;
  overflow: hidden;
  border-radius: 999px;
  background: rgb(24 24 27 / 9%);
}

.desktop-boot__progress::after {
  display: block;
  width: 40%;
  height: 100%;
  border-radius: inherit;
  background: #dc5238;
  content: "";
  animation: desktop-boot-progress 1.2s ease-in-out infinite alternate;
}

.desktop-boot__retry {
  min-height: 2.75rem;
  border: 0;
  border-radius: 999px;
  padding: 0.7rem 1.4rem;
  color: #fff;
  background: #b23a20;
  font: 700 0.75rem/1 "Mulish Variable", "Segoe UI", system-ui, sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.desktop-boot__retry:focus-visible {
  outline: 3px solid rgb(220 82 56 / 35%);
  outline-offset: 3px;
}

@media (prefers-color-scheme: dark) {
  .desktop-boot {
    color: #fafafa;
    background:
      radial-gradient(circle at 50% 38%, rgb(220 82 56 / 13%), transparent 30rem), #09090b;
  }

  .desktop-boot__kicker,
  .desktop-boot__message a {
    color: #f08a72;
  }

  .desktop-boot__message {
    color: #b4aea9;
  }

  .desktop-boot__progress {
    background: rgb(255 255 255 / 12%);
  }
}

@keyframes desktop-boot-enter {
  from {
    opacity: 0;
    transform: translateY(4px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes desktop-boot-progress {
  from {
    transform: translateX(-80%);
  }

  to {
    transform: translateX(230%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .desktop-boot--loading > *,
  .desktop-boot__progress::after {
    animation-duration: 0.01ms;
    animation-delay: 0s;
    animation-iteration-count: 1;
  }
}
