:root {
  color-scheme: light;
  font-family: "Segoe UI", "Aptos", "Helvetica Neue", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color: #243247;
  background: #e8eef5;
  font-weight: 400;
}

* {
  box-sizing: border-box;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
}

button,
a {
  font: inherit;
}

.stage {
  position: relative;
  display: grid;
  min-height: 100vh;
  place-items: center;
  overflow: hidden;
  padding: 28px 24px;
  isolation: isolate;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(255, 255, 255, 0.98), transparent 54%),
    linear-gradient(145deg, #e9eff6 0%, #dce6f0 49%, #edf2f7 100%);
}

.stage::before,
.stage::after {
  position: absolute;
  z-index: -1;
  content: "";
  pointer-events: none;
}

.stage::before {
  inset: 0;
  opacity: 0.28;
  background-image:
    linear-gradient(rgba(78, 103, 134, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(78, 103, 134, 0.08) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: linear-gradient(to bottom, transparent, #000 28%, transparent 88%);
}

.stage::after {
  right: -8vw;
  bottom: -22vw;
  left: -8vw;
  height: 34vw;
  min-height: 220px;
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.36), rgba(188, 207, 222, 0.16));
  box-shadow: 0 -26px 90px rgba(81, 113, 145, 0.08);
  transform: rotate(-3deg);
}

.ambient {
  position: absolute;
  z-index: -1;
  width: 360px;
  aspect-ratio: 1;
  border-radius: 50%;
  filter: blur(2px);
  pointer-events: none;
}

.ambient-one {
  top: 7%;
  left: -170px;
  background: radial-gradient(circle, rgba(161, 191, 222, 0.34), transparent 68%);
}

.ambient-two {
  right: -170px;
  bottom: 6%;
  background: radial-gradient(circle, rgba(168, 199, 219, 0.32), transparent 68%);
}

.portal {
  width: min(100%, 640px);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.86);
  border-radius: 22px;
  background: rgba(250, 252, 254, 0.72);
  box-shadow:
    0 34px 80px rgba(57, 79, 105, 0.17),
    0 6px 18px rgba(57, 79, 105, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
}

.portal-content {
  display: flex;
  min-height: 420px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 46px 28px 42px;
  text-align: center;
}

.app-icon {
  width: 104px;
  height: 104px;
  margin-bottom: 28px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 24px;
  box-shadow:
    0 12px 28px rgba(57, 79, 105, 0.16),
    0 2px 8px rgba(57, 79, 105, 0.08);
}

.actions {
  width: min(100%, 395px);
}

.download-button {
  display: flex;
  min-height: 72px;
  align-items: center;
  gap: 14px;
  padding: 13px 17px;
  border: 1px solid rgba(255, 255, 255, 0.52);
  border-radius: 15px;
  color: #fff;
  background: linear-gradient(112deg, #7ba7d2, #567da9 65%, #4d729c);
  box-shadow:
    0 12px 28px rgba(71, 111, 153, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.28);
  text-align: left;
  text-decoration: none;
  transition: box-shadow 160ms ease, transform 160ms ease, opacity 160ms ease;
}

.download-button:not(.is-unavailable):hover {
  box-shadow:
    0 16px 32px rgba(71, 111, 153, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.download-button:focus-visible,
.secondary-button:focus-visible {
  outline: 3px solid #315b82;
  outline-offset: 4px;
}

.download-button.is-unavailable {
  cursor: progress;
  opacity: 0.74;
}

.download-icon {
  display: grid;
  width: 43px;
  height: 43px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.48);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.16);
}

.download-icon svg,
.download-arrow {
  width: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.download-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.download-copy strong {
  font-size: 14px;
  font-weight: 650;
  letter-spacing: 0.005em;
}

.download-copy span {
  color: rgba(245, 249, 254, 0.82);
  font-size: 11px;
}

.download-arrow {
  width: 18px;
  flex: 0 0 auto;
  margin-left: auto;
  color: rgba(255, 255, 255, 0.82);
}

.release-status {
  min-height: 18px;
  margin: 9px 0 0;
  color: #687c92;
  font-size: 11px;
  line-height: 1.5;
}

.release-status.is-error {
  color: #9c4b4b;
}

.secondary-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 14px;
}

.secondary-button {
  display: inline-flex;
  min-width: 132px;
  min-height: 43px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 15px;
  border: 1px solid #27272a;
  border-radius: 11px;
  color: #fff;
  background: #27272a;
  box-shadow: 0 5px 14px rgba(37, 45, 54, 0.14);
  font-size: 12px;
  font-weight: 550;
  text-decoration: none;
  transition:
    background-color 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

.secondary-button:hover {
  border-color: #111113;
  color: #fff;
  background: #111113;
  box-shadow: 0 7px 18px rgba(17, 17, 19, 0.22);
  cursor: pointer;
  transform: translateY(-1px);
}

.secondary-button svg {
  width: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

@media (max-width: 560px) {
  .stage {
    min-height: 100svh;
    padding: 22px 14px;
  }

  .portal {
    border-radius: 18px;
  }

  .portal-content {
    min-height: 385px;
    padding: 36px 20px 32px;
  }

  .app-icon {
    width: 92px;
    height: 92px;
    margin-bottom: 24px;
  }

  .actions {
    margin-top: 25px;
  }

  .download-button {
    min-height: 68px;
    gap: 11px;
    padding: 11px 12px;
  }

  .download-copy strong {
    font-size: 13px;
  }

  .secondary-actions {
    gap: 9px;
  }

  .secondary-button {
    min-width: min(38vw, 132px);
    padding: 0 10px;
  }

}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
