/* iPhone 18 Pro is 71.9 x 150 mm, with a 1206 x 2622 display. */

.iphone {
  position: relative;
  width: min(100%, 20rem);
  margin-inline: auto;
}

.iphone-btn { display: none; }

.home-screen {
  position: relative;
  display: flex;
  flex-direction: column;
  aspect-ratio: 1206 / 2622;
  border-radius: 1.65rem;
  overflow: hidden;
  color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
  box-shadow: 0 16px 36px rgba(22, 21, 19, 0.16);
}

.home-wallpaper {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(62% 30% at 64% 15%, rgba(255, 156, 92, 0.95), rgba(255, 156, 92, 0) 70%),
    radial-gradient(78% 38% at 4% 0%, #c9d7f6 0%, rgba(201, 215, 246, 0) 68%),
    linear-gradient(180deg, #b9cbee 0%, #f0c4a6 27%, #a9bedd 58%, #6e8cba 100%);
  overflow: hidden;
}

.dune {
  position: absolute;
  left: -38%;
  width: 176%;
  border-radius: 50%;
}

.dune-back {
  top: 12%;
  height: 40%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.34), rgba(168, 186, 222, 0.05) 48%, rgba(118, 144, 190, 0.22));
  transform: rotate(-8deg);
}

.dune-mid {
  top: 36%;
  height: 36%;
  background: linear-gradient(180deg, rgba(255, 244, 236, 0.42), rgba(154, 176, 216, 0.06) 44%, rgba(98, 126, 178, 0.24));
  transform: rotate(6deg);
}

.dune-front {
  top: 62%;
  height: 48%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.5), rgba(176, 196, 226, 0.1) 42%, rgba(104, 132, 180, 0.3));
  transform: rotate(-3deg);
}

.status-bar,
.home-body { position: relative; z-index: 1; }

.status-bar {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  height: 2.7rem;
  padding: 0.45rem 1.05rem 0;
  color: #fff;
  text-shadow: 0 1px 2px rgba(36, 40, 64, 0.4);
}

.status-time {
  font-size: 0.92rem;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.dynamic-island {
  position: relative;
  width: 6.15rem;
  height: 1.42rem;
  border-radius: 999px;
  background: #050506;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.island-lens {
  position: absolute;
  top: 50%;
  right: 0.42rem;
  width: 0.42rem;
  height: 0.42rem;
  margin-top: -0.21rem;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #31445f, #070b14 62%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.status-icons {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 0.28rem;
  color: #fff;
}

.status-icons svg {
  display: block;
  height: 0.68rem;
  width: auto;
  fill: currentColor;
}

.status-signal { width: 0.95rem; }
.status-wifi { width: 0.9rem; }
.status-battery { width: 1.45rem; height: 0.72rem; }

.home-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  gap: 0.4rem;
  padding: 0.15rem 0.75rem 0.55rem;
}

.home-stage {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 0.55rem;
}

.home-widget,
.home-slot {
  border: 1.5px dashed rgba(255, 255, 255, 0.92);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: 0 1px 2px rgba(36, 42, 68, 0.18);
}

.home-widget {
  height: 100%;
  min-height: 0;
  border-radius: 1.35rem;
}

.home-widget-link {
  display: flex;
  align-items: flex-end;
  padding: 0.75rem;
  color: #fff;
  text-decoration: none;
}

.home-icons,
.home-dock {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.home-icons {
  height: 100%;
  min-height: 0;
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 0.4rem 0.55rem;
  align-items: center;
  justify-items: center;
}

.home-icons > .home-slot,
.home-icons > .home-app,
.home-dock > .home-slot,
.home-dock > .home-app {
  width: 100%;
  max-height: 100%;
  aspect-ratio: 1;
}

.home-slot,
.home-app-icon {
  border-radius: 23%;
}

.home-app {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.22rem;
  min-width: 0;
  color: #fff;
  text-decoration: none;
  font-size: 0.68rem;
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.01em;
  text-shadow: 0 1px 2px rgba(28, 32, 52, 0.55);
}

.home-app:hover { color: #fff; text-decoration: none; }

.home-app-icon {
  display: grid;
  place-items: center;
  width: 100%;
  background: rgba(255, 255, 255, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.5);
  font-size: 1.05rem;
  font-weight: 650;
  text-shadow: none;
}

.home-app-name {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.home-pages {
  display: flex;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.05rem 0;
}

.home-pages span {
  width: 0.34rem;
  height: 0.34rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.42);
}

.home-pages .is-active { background: #fff; }

.home-dock {
  gap: 0.7rem;
  padding: 0.55rem 0.7rem;
  border-radius: 1.45rem;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.34);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(16px) saturate(1.35);
}

@media (min-width: 768px) {
  #an-iphone-built-for-one .article-hero-media {
    display: flex;
    justify-content: center;
  }

  .iphone {
    width: min(100%, 19.25rem);
    aspect-ratio: 71.9 / 150;
    padding: 0.4rem;
    border-radius: 2.65rem;
    background:
      linear-gradient(100deg, #5c5c62 0%, #2a2a2e 7%, #161618 16%, #0c0c0e 50%, #1a1a1e 86%, #4a4a50 100%);
    box-shadow:
      inset 0 0 0 1px rgba(255, 255, 255, 0.28),
      inset 0 0 0 2px #050506,
      0 24px 48px rgba(22, 21, 19, 0.28);
  }

  .home-screen {
    width: 100%;
    height: 100%;
    aspect-ratio: auto;
    border-radius: 2.2rem;
    box-shadow: none;
  }

  .iphone-btn {
    display: block;
    position: absolute;
    width: 0.18rem;
    border-radius: 0.15rem 0 0 0.15rem;
    background: linear-gradient(90deg, #8d8d93, #3a3a3e 42%, #141416);
  }

  .iphone-action { left: -0.14rem; top: 14.5%; height: 1.05rem; }
  .iphone-volume-up { left: -0.14rem; top: 22%; height: 2.2rem; }
  .iphone-volume-down { left: -0.14rem; top: 31.2%; height: 2.2rem; }

  .iphone-side,
  .iphone-camera {
    right: -0.14rem;
    border-radius: 0 0.15rem 0.15rem 0;
    background: linear-gradient(270deg, #8d8d93, #3a3a3e 42%, #141416);
  }

  .iphone-side { top: 23.2%; height: 3.15rem; }

  .iphone-camera {
    top: 41%;
    height: 2.45rem;
    width: 0.2rem;
    border-radius: 0.25rem;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.45), transparent 30%),
      linear-gradient(270deg, #9a9aa2, #3c3c42 40%, #121214);
  }
}

@media (max-width: 767px) {
  #an-iphone-built-for-one .article-hero-media {
    width: min(100%, 22.5rem);
    padding-inline: 0;
  }

  .iphone { width: 100%; }
  .home-screen { box-shadow: none; }
}
