.pwa-install {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
}

.pwa-install--inline {
  width: 100%;
  padding: 0.75rem 0.95rem 0.85rem;
  animation: pwa-install-in 0.35s ease;
}

.pwa-install--inline.pwa-install--hint {
  width: auto;
  padding: 0.65rem 0.85rem;
}

#pwa-install-slot:not(.hidden) {
  width: fit-content;
  max-width: 100%;
  justify-self: start;
}

.pwa-install.hidden {
  display: none;
}

.pwa-install--hint {
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
}

.pwa-install__text {
  min-width: 0;
}

.pwa-install__title {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text, #e8eaf0);
}

.pwa-install__badge {
  margin: 0 0 0.4rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text, #e8eaf0);
  line-height: 1.35;
}

.pwa-install__desc {
  margin: 0;
  font-size: 0.78rem;
  color: var(--text-muted, #8b90a0);
  line-height: 1.5;
}

.pwa-install__desc strong {
  color: var(--text, #e8eaf0);
  font-weight: 700;
}

.pwa-install__chip--inline {
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  margin: 0 0.2rem 0 0;
  padding: 0.22rem 0.5rem;
  font-size: 0.72rem;
  gap: 0.3rem;
}

.pwa-install__chip--inline .pwa-install__icon {
  display: block;
  flex-shrink: 0;
}

.pwa-install__actions {
  display: flex;
  flex-shrink: 0;
  gap: 0.45rem;
}

.pwa-install__actions--hint {
  justify-content: flex-end;
}

.pwa-install__guide {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.45rem;
}

.pwa-install__chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.38rem 0.6rem;
  border-radius: 9px;
  background: color-mix(in srgb, var(--accent, #4f8cff) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent, #4f8cff) 28%, transparent);
  color: var(--text, #e8eaf0);
  font-size: 0.76rem;
  font-weight: 600;
  line-height: 1.2;
}

.pwa-install__chip--text {
  padding-left: 0.65rem;
  padding-right: 0.65rem;
}

.pwa-install__icon {
  flex-shrink: 0;
  color: var(--accent, #4f8cff);
}

.pwa-install__arrow {
  color: var(--text-muted, #8b90a0);
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1;
}

.pwa-install__btn {
  border: 0;
  border-radius: 999px;
  padding: 0.5rem 0.85rem;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
}

.pwa-install__btn--primary {
  background: var(--accent, #4f8cff);
  color: #fff;
}

.pwa-install__btn--ghost {
  background: transparent;
  color: var(--text-muted, #8b90a0);
}

@keyframes pwa-install-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 640px) {
  .pwa-install--inline:not(.pwa-install--hint) {
    flex-direction: column;
    align-items: stretch;
  }

  .pwa-install__actions {
    justify-content: flex-end;
  }
}

.app-splash {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  background: #0f1117;
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

[data-theme="light"] .app-splash {
  background: #f0f2f7;
}

.app-splash.is-active {
  display: flex;
}

.app-splash--hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.app-splash__logo {
  width: 120px;
  height: 120px;
  object-fit: contain;
  border-radius: 24px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

.app-splash__title {
  margin: 0;
  font-family: 'Outfit', 'Inter', system-ui, sans-serif;
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #e8eaf0;
}

[data-theme="light"] .app-splash__title {
  color: #1a1d27;
}

.app-splash__status {
  margin: 0.15rem 0 0;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: #8b90a0;
}

[data-theme="light"] .app-splash__status {
  color: #5c6378;
}

.app-splash__blocks {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin-top: 0.35rem;
}

.app-splash__blocks span {
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: #4f8cff;
  opacity: 0.18;
  transform: scale(0.82);
  animation: splash-block-pulse 1.15s ease-in-out infinite;
}

.app-splash__blocks span:nth-child(1) { animation-delay: 0s; }
.app-splash__blocks span:nth-child(2) { animation-delay: 0.08s; }
.app-splash__blocks span:nth-child(3) { animation-delay: 0.16s; }
.app-splash__blocks span:nth-child(4) { animation-delay: 0.24s; }
.app-splash__blocks span:nth-child(5) { animation-delay: 0.32s; }
.app-splash__blocks span:nth-child(6) { animation-delay: 0.4s; }
.app-splash__blocks span:nth-child(7) { animation-delay: 0.48s; }
.app-splash__blocks span:nth-child(8) { animation-delay: 0.56s; }
.app-splash__blocks span:nth-child(9) { animation-delay: 0.64s; }

@keyframes splash-block-pulse {
  0%,
  100% {
    opacity: 0.18;
    transform: scale(0.82);
  }

  45% {
    opacity: 1;
    transform: scale(1);
  }
}

body.app-splash-active {
  overflow: hidden;
}
