/* Real screenshots keep their natural proportions inside illustrative hardware. */
.device-showcase.app-sticky {
  top: 104px;
  padding-top: 12px;
}
.device-selector {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  max-width: 600px;
  margin: 0 auto 17px;
}
.device-selector[hidden] {
  display: none;
}
.device-selector button {
  padding: 12px 7px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  color: var(--ink);
  font-size: 13px;
  line-height: 1.3;
  min-height: 60px;
}
.device-selector button span {
  display: block;
  font-size: 9px;
  margin-top: 5px;
  color: var(--muted);
}
.device-selector button[aria-pressed="true"] {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
  background: var(--soft);
}
.device-label {
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.03em;
  margin-bottom: 18px;
  color: var(--muted);
}
.device-stage {
  display: grid;
  place-items: center;
  padding: 28px 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: radial-gradient(ellipse at 50% 35%, var(--panel), var(--soft));
  min-width: 0;
}
.device-shell {
  position: relative;
  isolation: isolate;
  width: 100%;
  max-width: 280px;
  padding: 18px 9px 12px;
  border: 2px solid #89868f;
  border-radius: 34px;
  background: linear-gradient(120deg, #37363e, #101116 40%, #292a32);
  box-shadow:
    0 22px 28px -16px #17102380,
    inset 0 0 0 2px #090a0e;
}
.device-shell::before,
.device-shell::after {
  content: "";
  position: absolute;
  top: 20%;
  width: 3px;
  height: 37px;
  border-radius: 3px;
  background: linear-gradient(#a5a1ae, #46434d);
  pointer-events: none;
}
.device-shell::before {
  left: -4px;
}
.device-shell::after {
  right: -4px;
  height: 52px;
}
.device-camera {
  position: absolute;
  top: 7px;
  left: calc(50% - 18px);
  width: 36px;
  height: 4px;
  border-radius: 5px;
  background: #05060a;
  box-shadow: 0 1px 0 #696670;
}
.device-screen,
.moments-grid .device-screen {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 21px;
  background: #16151c;
  isolation: isolate;
}
.device-screen img,
.moments-grid .device-screen img {
  display: block;
  width: 100%;
  height: auto;
  border: 0;
  border-radius: 0;
  object-fit: contain;
}
.device-screen:focus-visible {
  outline-offset: 5px;
}
.screen-reflection {
  position: absolute;
  z-index: 1;
  inset: -25% -100%;
  pointer-events: none;
  background: linear-gradient(
    113deg,
    transparent 33%,
    #ffffff09 39%,
    #ffffff35 46%,
    #ffffff05 51%,
    transparent 58%
  );
  transform: translate3d(var(--reflection-x, -22%), 0, 0);
}
.device-shell[data-phone-shell="duo"],
.device-shell[data-phone-shell="galaxy"] {
  max-width: 680px;
  border-radius: 22px;
  padding: 14px 9px 10px;
}
.device-showcase .device-shell[data-phone-shell="iphone"] {
  max-width: clamp(180px, calc((100svh - 350px) * 0.46), 280px);
}
.device-showcase .device-shell[data-phone-shell="duo"] {
  max-width: min(680px, max(240px, calc((100svh - 350px) * 1.422)));
}
.device-showcase .device-shell[data-phone-shell="galaxy"] {
  max-width: min(680px, max(240px, calc((100svh - 350px) * 1.037)));
}
.device-shell[data-phone-shell="duo"] .device-screen,
.device-shell[data-phone-shell="galaxy"] .device-screen {
  border-radius: 11px;
}
.device-shell[data-phone-shell="duo"] .device-camera,
.device-shell[data-phone-shell="galaxy"] .device-camera {
  top: 5px;
  left: 73%;
  width: 5px;
  height: 5px;
}
.device-context {
  margin: 10px 0 0;
  font-size: 11px;
  line-height: 1.6;
  color: var(--muted);
}
.device-showcase .app-quiet-note {
  margin-top: 20px;
}
.device-stage-small .device-shell[data-phone-shell="iphone"] {
  max-width: 245px;
}
.device-stage-small {
  height: 100%;
  min-height: 260px;
  padding: 25px 20px;
}
.moments-grid > figure {
  display: grid;
  grid-template-rows: 1fr auto;
  min-width: 0;
}
@media (min-width: 801px) and (max-height: 1050px) {
  .device-showcase.app-sticky {
    position: static;
  }
}
@media (max-width: 800px) {
  .device-showcase.app-sticky {
    position: static;
    padding-top: 0;
  }
}
@media (max-width: 620px) {
  .device-stage {
    padding: 25px 16px;
    border-radius: 18px;
  }
  .device-selector {
    gap: 5px;
  }
  .device-selector button {
    font-size: 12px;
    padding: 10px 5px;
  }
  .device-selector button span {
    font-size: 8px;
  }
  .device-label {
    font-size: 11px;
  }
  .device-shell {
    max-width: 275px;
  }
  .device-shell[data-phone-shell="duo"],
  .device-shell[data-phone-shell="galaxy"] {
    padding: 12px 6px 8px;
    border-radius: 16px;
  }
  .device-shell[data-phone-shell="duo"] .device-screen,
  .device-shell[data-phone-shell="galaxy"] .device-screen {
    border-radius: 8px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .screen-reflection {
    display: none;
    transform: none;
  }
}
