.st-download {
  --st-blue: #0c589a;
  --st-dark: #143658;
  --st-border: #d3e2ef;
  container: st-download / inline-size;
  width: 100%;
  color: #333;
  font: 15px/1.45 Arial, Helvetica, sans-serif;
}

.st-download * { box-sizing: border-box; }

.st-download__panel {
  display: grid;
  grid-template-areas: "visual copy" "visual links";
  grid-template-columns: minmax(124px, 30%) minmax(0, 1fr);
  align-items: start;
  column-gap: clamp(14px, 2.2cqi, 25px);
  row-gap: 12px;
  padding: clamp(14px, 1.8cqi, 20px);
  border: 1px solid var(--st-border);
  border-radius: 6px;
  background: #f5faff;
}

.st-download .st-download__visual {
  grid-area: visual;
  align-self: center;
  position: relative;
  width: 100%;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border-radius: 4px;
  background: #e3f0fa;
}

.st-download .st-download__phone {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  margin: 0;
  object-fit: cover;
}

.st-download__screen {
  position: absolute;
  top: 4.62%;
  left: 35.6%;
  width: 28.78%;
  height: 84.9%;
  overflow: hidden;
  border-radius: 12% / 5.4%;
  background: #118bc2;
}

.st-download .st-download__screen img {
  /* Keeps the store screenshot in its original proportions. */
  position: absolute;
  top: -37.13%;
  left: 50%;
  display: block;
  width: auto;
  max-width: none;
  height: 137.13%;
  margin: 0;
  transform: translateX(-50%);
}

.st-download__copy { grid-area: copy; align-self: end; min-width: 0; }

.st-download .st-download__title {
  margin: 0;
  color: var(--st-blue);
  font-size: clamp(23px, 3cqi, 31px);
  font-weight: 700;
  line-height: 1.12;
}

.st-download .st-download__description {
  max-width: 37ch;
  margin: 8px 0 0;
  color: var(--st-dark);
  font-size: 15px;
  line-height: 1.4;
}

.st-download__links { grid-area: links; display: flex; flex-wrap: wrap; gap: 8px; }

.st-download a.st-download__button {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
  gap: 9px;
  padding: 8px 13px;
  border: 1px solid #9dbedb;
  border-radius: 4px;
  background: #fff;
  color: var(--st-blue);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  transition: background-color .15s ease, border-color .15s ease;
}

.st-download a.st-download__button:hover {
  border-color: var(--st-blue);
  background: #e7f2fc;
  color: var(--st-blue);
}

.st-download a.st-download__button:focus-visible {
  outline: 2px solid var(--st-blue);
  outline-offset: 3px;
}

.st-download__scan {
  display: none;
  grid-area: scan;
  align-self: center;
  padding-left: 15px;
  border-left: 1px solid var(--st-border);
  text-align: center;
}

.st-download .st-download__scan-label {
  margin: 0 0 7px;
  color: var(--st-blue);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.25;
}

.st-download__codes { display: flex; gap: 8px; }

.st-download .st-download__code {
  display: grid;
  justify-items: center;
  gap: 3px;
  margin: 0;
  padding: 2px 6px 6px;
  border: 1px solid var(--st-border);
  border-radius: 4px;
  background: #fff;
}

.st-download .st-download__code img {
  display: block;
  width: 104px;
  max-width: none;
  height: 104px;
  margin: 0;
  image-rendering: pixelated;
}

.st-download .st-download__code figcaption {
  margin: 0;
  color: var(--st-blue);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
}

@media (hover: hover) and (pointer: fine) {
  @container st-download (min-width: 755px) {
    .st-download__panel {
      grid-template-areas: "visual copy scan" "visual links scan";
      grid-template-columns: minmax(160px, 24%) minmax(0, 1fr) max-content;
    }
    .st-download__scan { display: block; }
  }
}

@container st-download (max-width: 485px) {
  .st-download__panel {
    grid-template-areas: "visual copy" "links links";
    grid-template-columns: clamp(82px, 32cqi, 128px) minmax(0, 1fr);
    gap: 11px;
    padding: 12px;
  }
  .st-download__copy { align-self: center; }
  .st-download .st-download__title { font-size: clamp(18px, 5.3cqi, 25px); }
  .st-download .st-download__description { margin-top: 5px; font-size: 13px; }
  .st-download__links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .st-download a.st-download__button { padding-inline: 8px; font-size: 13px; }
}

@container st-download (max-width: 250px) {
  .st-download__panel { grid-template-areas: "visual" "copy" "links"; grid-template-columns: minmax(0, 1fr); }
  .st-download .st-download__visual { max-width: 132px; }
  .st-download__links { grid-template-columns: minmax(0, 1fr); }
}

@supports not (container-type: inline-size) {
  .st-download__panel { grid-template-columns: minmax(72px, 30%) minmax(0, 1fr); gap: 12px; padding: 12px; }
  .st-download .st-download__title { font-size: 21px; }
  .st-download a.st-download__button { min-width: 0; padding-inline: 7px; }
}

@media (prefers-reduced-motion: reduce) {
  .st-download a.st-download__button { transition: none; }
}
