/* Shared iPhone 16 frame for MX Link application imagery. */
.iphone-mockup {
  position: relative;
  isolation: isolate;
  width: 100%;
  aspect-ratio: 700 / 1409;
  filter: drop-shadow(0 12px 16px #0009);
}
.iphone-mockup::before,
.iphone-mockup::after {
  content: "";
  position: absolute;
  pointer-events: none;
}
.iphone-mockup::before {
  z-index: -1;
  inset: 1.25% 2.1%;
  border-radius: 18% / 9%;
  background: conic-gradient(from -38deg, #d6e0eb, #6b8ab5 12%, #3a4350 29%,
    #b2b6bb 47%, #9c6746 58%, #393c44 73%, #969da5 90%, #d6e0eb);
  box-shadow: inset 0 0 1px #fff8;
  transform: translate(2.5%, .3%);
}
.iphone-mockup::after {
  z-index: 2;
  inset: 0;
  background: url('/assets/app/iphone-16-black.png') center / 100% 100% no-repeat;
}
.iphone-mockup__screen {
  position: absolute;
  box-sizing: border-box;
  inset: 3.25% 6.55%;
  overflow: hidden;
  border-radius: 17% / 8%;
  background: #f3f1eb;
}
.iphone-mockup .iphone-mockup__screen > img {
  position: absolute;
  inset: auto 0 0;
  display: block;
  width: 100%;
  height: 93%;
  border: 0;
  border-radius: 0;
  object-fit: contain;
  object-position: center bottom;
}

/* The home carousel uses the same frame for all four screens. */
.phone.phone-capture.iphone-mockup {
  width: min(100%, 302px);
  aspect-ratio: 700 / 1409;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.phone-capture .app-capture {
  opacity: 0;
  transform: translateX(10px);
  transition: opacity .22s ease, transform .22s ease;
}
.phone-capture .app-capture.is-active {
  z-index: 1;
  opacity: 1;
  transform: none;
}

/* Illustrations in the application guide. */
.story-application .story-hero-art {
  position: relative;
  isolation: isolate;
  justify-self: center;
  width: min(100%, 36rem);
}
.story-application .story-hero-art::before,
.story-application .story-hero-art::after {
  content: "";
  position: absolute;
  z-index: -1;
  pointer-events: none;
}
.story-application .story-hero-art::before {
  inset: -10% -8% -3%;
  background:
    radial-gradient(ellipse 15% 12% at 84% 13%, #377de953, transparent),
    radial-gradient(ellipse 13% 13% at 14% 76%, #1766df48, transparent),
    radial-gradient(ellipse 19% 9% at 78% 88%, #d27b342b, transparent);
}
.story-application .story-hero-art::after {
  inset: auto -3% -2.8%;
  height: 6%;
  background: url('/assets/app/ktm-trio-reflets.jpg') center / 100% 100% no-repeat;
  mask-image: radial-gradient(ellipse 50% 50% at center, #000 34%, transparent);
  opacity: .62;
}
.story-hero-art .application-trio {
  display: block;
  width: 100%;
  height: auto;
  max-height: none;
}
@media (prefers-reduced-motion: no-preference) {
  .story-hero-art .application-trio {
    animation: application-trio-float 7.2s ease-in-out infinite;
  }
  @keyframes application-trio-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-1%); }
  }
}
.screen-stage .iphone-mockup { width: min(100%, 226px); }
.records-grid > article:first-child .iphone-mockup { transform: rotate(-5deg); }
.records-grid > article:last-child .iphone-mockup { transform: rotate(5deg); }
.access-manual .iphone-mockup {
  width: min(90%, 7.25rem);
  transform: rotate(3deg);
  filter: drop-shadow(0 6px 10px #0006);
}
@media (max-width: 760px) {
  .phone.phone-capture.iphone-mockup { width: min(100%, 270px); }
  .story-application .story-hero-art { width: min(100%, 26rem); }
}
@media (prefers-reduced-motion: reduce) {
  .phone-capture .app-capture { transition: none; transform: none; }
}
