/* —— In-game phone overlay —— */

body.wondalife-phone-open {
  overflow: hidden;
}

.wondalife-phone-root {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  pointer-events: none;
}
.wondalife-phone-root[hidden] {
  display: none !important;
}
.wondalife-phone-root:not([hidden]) {
  pointer-events: auto;
}

.wondalife-phone-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 12, 20, 0.45);
  backdrop-filter: blur(2px);
}

.wondalife-phone-root.is-standalone .wondalife-phone-backdrop {
  background: radial-gradient(120% 90% at 50% 0%, #3a2030 0%, #1a0f18 60%, #0d080c 100%);
  backdrop-filter: none;
}

.wondalife-phone-stage {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-height: min(96vh, 900px);
  padding: 8px 12px;
}

.wondalife-phone-close {
  align-self: flex-end;
  margin: 0 0 8px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #111;
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: 13px;
  font-weight: 600;
  padding: 7px 14px 7px 10px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.wondalife-phone-close__x {
  font-size: 18px;
  line-height: 1;
  font-weight: 500;
}

/* Device frame */
.wondalife-phone-device {
  --phone-bezel: 10px;
  --phone-radius: 42px;
  --phone-screen-radius: 32px;
  --phone-w: min(340px, calc(100vw - 48px));
  width: var(--phone-w);
  aspect-ratio: 9 / 19.5;
  max-height: min(92vh, 820px);
  filter: drop-shadow(0 18px 40px rgba(0, 0, 0, 0.35));
}
.wondalife-phone-device[data-device="iphone-18-pro-max"] {
  --phone-bezel: 12px;
  --phone-radius: 46px;
  --phone-screen-radius: 34px;
  --phone-w: min(360px, calc(100vw - 40px));
}
.wondalife-phone-device[data-device="iphone-17"] {
  --phone-bezel: 9px;
  --phone-radius: 40px;
  --phone-screen-radius: 31px;
}
.wondalife-phone-device[data-device="iphone-duo"] {
  --phone-bezel: 10px;
  --phone-radius: 38px;
  --phone-screen-radius: 30px;
  --phone-w: min(380px, calc(100vw - 36px));
  aspect-ratio: 9 / 17.2;
}
.wondalife-phone-device[data-device="iphone-duo-max"] {
  --phone-bezel: 11px;
  --phone-radius: 40px;
  --phone-screen-radius: 32px;
  --phone-w: min(420px, calc(100vw - 28px));
  aspect-ratio: 9 / 15.8;
}
.wondalife-phone-device[data-device="galaxy-s25-ultra"] {
  --phone-bezel: 8px;
  --phone-radius: 28px;
  --phone-screen-radius: 22px;
}
.wondalife-phone-device[data-device="pixel-10-pro"] {
  --phone-bezel: 9px;
  --phone-radius: 36px;
  --phone-screen-radius: 28px;
}

.wondalife-phone-bezel {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: var(--phone-radius);
  background: #0a0a0c;
  padding: var(--phone-bezel);
  box-sizing: border-box;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    inset 0 0 0 2px rgba(0, 0, 0, 0.5);
}

.wondalife-phone-screen {
  --hero-size: clamp(3.4rem, 14vw, 4.2rem);
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: var(--phone-screen-radius);
  overflow: hidden;
  background: #1a1028;
  display: flex;
  flex-direction: column;
}

.wondalife-phone-wallpaper {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #4a1a7a 0%, #9b2d6e 38%, #e85d2a 72%, #f5b84a 100%);
  z-index: 0;
  transition: background 0.35s ease, filter 0.35s ease;
}
.wondalife-phone-screen.is-night .wondalife-phone-wallpaper {
  background: linear-gradient(180deg, #0b1028 0%, #1a1448 40%, #2a1858 70%, #3a2060 100%);
  filter: brightness(0.92);
}
.wondalife-phone-skyline {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 18%;
  opacity: 0.92;
}
.wondalife-phone-screen.is-night .wondalife-phone-skyline {
  opacity: 0.55;
  filter: brightness(0.45);
}
/* Base wallpaper above is Evening; Morning and Afternoon get their own skies and skyline tints. */
.wondalife-phone-screen.is-morning .wondalife-phone-wallpaper {
  background: linear-gradient(180deg, #1559c4 0%, #2f86e0 40%, #6bb8f2 75%, #b9e2ff 100%);
}
.wondalife-phone-screen.is-morning .wondalife-phone-skyline path {
  fill: #24364f;
}
.wondalife-phone-screen.is-afternoon .wondalife-phone-wallpaper {
  background: linear-gradient(180deg, #3a6aae 0%, #9aaed3 34%, #f39c72 68%, #ffc566 100%);
}
.wondalife-phone-screen.is-afternoon .wondalife-phone-skyline path {
  fill: #4a3a5c;
}
.wondalife-phone-screen.is-afternoon .wondalife-phone-skyline {
  opacity: 0.85;
}

/* Cutouts */
.wondalife-phone-cutout {
  position: absolute;
  z-index: 5;
  pointer-events: none;
  background: #0a0a0c;
}
.wondalife-phone-device.is-ios .wondalife-phone-cutout {
  top: calc(var(--phone-bezel) + 10px);
  left: 50%;
  transform: translateX(-50%);
  width: 96px;
  height: 28px;
  border-radius: 20px;
}
.wondalife-phone-device[data-device="iphone-18-pro-max"] .wondalife-phone-cutout {
  width: 112px;
  height: 30px;
}
/* Twin Dynamic Islands + fold hinge for Duo */
.wondalife-phone-device.is-duo .wondalife-phone-cutout {
  left: calc(50% - 52px);
  transform: none;
  width: 44px;
  height: 22px;
  border-radius: 14px;
}
.wondalife-phone-device.is-duo .wondalife-phone-cutout::after {
  content: "";
  position: absolute;
  top: 0;
  left: 60px;
  width: 44px;
  height: 22px;
  border-radius: 14px;
  background: #0a0a0c;
}
.wondalife-phone-device[data-device="iphone-duo-max"] .wondalife-phone-cutout {
  left: calc(50% - 62px);
  width: 50px;
  height: 24px;
}
.wondalife-phone-device[data-device="iphone-duo-max"] .wondalife-phone-cutout::after {
  left: 74px;
  width: 50px;
  height: 24px;
}
.wondalife-phone-device.is-duo .wondalife-phone-screen::after {
  content: "";
  position: absolute;
  z-index: 3;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  transform: translateX(-50%);
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.08) 0%,
    rgba(0, 0, 0, 0.28) 20%,
    rgba(0, 0, 0, 0.35) 50%,
    rgba(0, 0, 0, 0.28) 80%,
    rgba(0, 0, 0, 0.08) 100%
  );
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.15);
  pointer-events: none;
}
.wondalife-phone-device.is-android .wondalife-phone-cutout {
  top: calc(var(--phone-bezel) + 12px);
  left: 50%;
  transform: translateX(-50%);
  width: 14px;
  height: 14px;
  border-radius: 50%;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.35);
}
.wondalife-phone-device[data-device="galaxy-s25-ultra"] .wondalife-phone-cutout {
  left: calc(var(--phone-bezel) + 22px);
  transform: none;
}

.wondalife-phone-status {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px 0;
  color: #fff;
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: 12px;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}
.wondalife-phone-device.is-ios .wondalife-phone-status {
  padding-top: 18px;
  min-height: 46px;
  box-sizing: border-box;
  align-items: flex-end;
  padding-bottom: 4px;
}
/* Home screen: no status clock; signal/4G/battery sit halfway up to the screen edge with the same right gap as the
   hero avatar (the battery nub overhangs by 3px), and the content below rides up with it. */
.wondalife-phone-screen.is-home .wondalife-phone-status {
  align-items: flex-start;
  min-height: 26px;
  padding: 10px calc(19px + var(--hero-size) * 0.045) 0 19px;
  box-sizing: border-box;
}
.wondalife-phone-device.is-ios .wondalife-phone-screen.is-home .wondalife-phone-status {
  min-height: 36px;
  padding-top: 20px;
  padding-bottom: 0;
}
.wondalife-phone-screen.is-home [data-phone-clock] {
  display: none;
}
.wondalife-phone-screen.is-home .wondalife-phone-status__right {
  margin-left: auto;
}
.wondalife-phone-screen.is-home .wondalife-phone-body {
  padding-top: 7.5px;
}
.wondalife-phone-device.is-ios .wondalife-phone-screen.is-home .wondalife-phone-body {
  padding-top: 17px;
}
.wondalife-phone-status__right {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
}
.wondalife-phone-signal {
  display: block;
  width: 15px;
  height: 10px;
  margin-right: 1px;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.2));
}
.wondalife-phone-signal::before,
.wondalife-phone-signal::after {
  display: none;
}
.wondalife-phone-battery {
  width: 18px;
  height: 9px;
  border: 1.5px solid #fff;
  border-radius: 2px;
  position: relative;
  box-sizing: border-box;
}
.wondalife-phone-battery::before {
  content: "";
  position: absolute;
  inset: 1.5px;
  background: #fff;
  border-radius: 1px;
}
.wondalife-phone-battery::after {
  content: "";
  position: absolute;
  right: -3px;
  top: 2px;
  width: 2px;
  height: 4px;
  background: #fff;
  border-radius: 0 1px 1px 0;
}

.wondalife-phone-body {
  position: relative;
  z-index: 2;
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 18px 14px 28px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.wondalife-phone-body::-webkit-scrollbar {
  display: none;
}

/* Isolate phone app titles from global landing styles (game.css h1 shadow, etc.) */
.wondalife-phone-screen h1,
.wondalife-phone-screen h2,
.wondalife-phone-screen h3 {
  font-family: inherit;
  text-shadow: none;
  filter: none;
  -webkit-text-stroke: 0;
}

.wondalife-phone-home {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 100%;
}
.wondalife-phone-lock {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 4px 2px 6px;
  color: #fff;
  position: relative;
}
/* Poppins digits: ink starts 0.065em below the line box, is 0.774em tall, and the first digit's left bearing is ~0.045em.
   The avatar shares the digits' top, is 85% of their height, and its right gap matches the time's visible left gap. */
.wondalife-phone-hero-avatar {
  --avatar-h: calc(var(--hero-size) * 0.774 * 0.85);
  /* Fold line x + y = S (px from the top-left corner); the avatars are ~0.88 as wide as tall, so S = 1.9 × height
     reaches the bottom-right corner. */
  --fold: calc(var(--peel) * var(--avatar-h) * 1.9);
  position: absolute;
  top: calc(4px + var(--hero-size) * 0.065);
  right: calc(2px + var(--hero-size) * 0.045);
  display: block;
  height: var(--avatar-h);
  pointer-events: none;
  animation: wondalife-avatar-peel 1.4s cubic-bezier(0.45, 0.05, 0.3, 1) both;
}
/* Stuck part of the sticker: everything on the top-left side of the fold. */
.wondalife-phone-hero-avatar__face {
  display: block;
  height: 100%;
  width: auto;
  clip-path: polygon(0 0, var(--fold) 0, 0 var(--fold));
}
/* Still-peeled part, mirrored across the fold so its back lies over the stuck part. */
.wondalife-phone-hero-avatar__back {
  position: absolute;
  inset: 0;
  transform-origin: 0 0;
  transform: translate(var(--fold), var(--fold)) matrix(0, -1, -1, 0, 0, 0);
  clip-path: polygon(var(--fold) 0, 400% 0, 400% 400%, 0 400%, 0 var(--fold));
  background: linear-gradient(135deg, #ffffff 0%, #ececf1 50%, #c4c6d0 100%);
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
}
@property --peel {
  syntax: "<number>";
  inherits: true;
  initial-value: 1;
}
@keyframes wondalife-avatar-peel {
  0% { --peel: 0; opacity: 0; }
  12% { opacity: 1; }
  100% { --peel: 1; opacity: 1; }
}
.wondalife-phone-hero-time {
  margin: 0;
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: var(--hero-size);
  font-weight: 600;
  line-height: 0.95;
  letter-spacing: -0.04em;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.28);
}
.wondalife-phone-hero-clock {
  display: flex;
  align-items: flex-start;
  gap: calc(var(--hero-size) * 0.14);
}
/* Weekday over day/month. The weekday is 0.2043 × the hero size; fitHeroDay() shrinks the day/month until its ink is
   exactly as wide as the weekday's. The block ends at the digits' rendered vertical centre (0.46em of the hero size
   below the time's line top), and the day/month's baseline sits on that bottom edge. */
.wondalife-phone-hero-day {
  --day-size: calc(var(--hero-size) * 0.2043);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: flex-start;
  height: calc(var(--hero-size) * 0.46);
  margin: 0;
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: var(--day-size);
  line-height: 1;
  white-space: nowrap;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.28);
}
.wondalife-phone-hero-day__week {
  font-weight: 600;
}
/* Poppins ascent 1.05 / descent 0.35: line-height 0.7 puts the baseline exactly on the line box's bottom. The top
   margin keeps the previous gap below the weekday. */
.wondalife-phone-hero-day__date {
  margin-top: 0.15em;
  font-weight: 500;
  line-height: 0.7;
}
.wondalife-phone-hero-date {
  margin: 0 0 4px;
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: 13px;
  font-weight: 500;
  opacity: 0.95;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.3);
}
/* Time-of-day theme button: pill at the status bar's top-left, centred on the 16px signal/4G/battery row. */
.wondalife-phone-period {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 24px;
  margin-top: -4px;
  border: 0;
  border-radius: 999px;
  background: rgba(40, 20, 70, 0.45);
  backdrop-filter: blur(8px);
  color: #fff;
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: 10px;
  font-weight: 600;
  line-height: 1;
  padding: 0 8px 0 6px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
/* Galaxy's punch-hole sits at the top-left: start the pill after it. */
.wondalife-phone-device[data-device="galaxy-s25-ultra"] .wondalife-phone-screen.is-home .wondalife-phone-status {
  padding-left: 46px;
}
.wondalife-phone-screen.is-night .wondalife-phone-period {
  background: rgba(15, 20, 50, 0.65);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
}
.wondalife-phone-period[hidden] {
  display: none;
}
.wondalife-phone-period__icon {
  font-size: 11px;
  line-height: 1;
  filter: drop-shadow(0 0 3px rgba(255, 220, 100, 0.55));
}
.wondalife-phone-update {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-top: 4px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  padding: 8px 8px 8px 10px;
  box-sizing: border-box;
}
.wondalife-phone-update__icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(145deg, #1a1448, #4a1a7a);
  display: grid;
  place-items: center;
  font-size: 14px;
  flex-shrink: 0;
}
.wondalife-phone-update__text {
  flex: 1;
  min-width: 0;
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}
.wondalife-phone-update__btn {
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #1c2430;
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 700;
  padding: 6px 12px;
  cursor: pointer;
  flex-shrink: 0;
}
.wondalife-phone-update__btn:active {
  transform: scale(0.97);
}

.wondalife-phone-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px 10px;
}

/* Launch splash: only the wallpaper and the logo, centered on the whole screen for 3.3s. */
.wondalife-phone-screen.is-splash .wondalife-phone-status,
.wondalife-phone-screen.is-splash .wondalife-phone-homebar {
  visibility: hidden;
}
.wondalife-phone-screen.is-splash .wondalife-phone-body {
  position: static;
}
.wondalife-phone-splash {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  pointer-events: none;
}
/* 92% leaves room for the 1.07 heartbeat peak inside the clipped area. */
.wondalife-phone-splash__logo {
  display: block;
  width: 92%;
  height: 92%;
  object-fit: contain;
  animation: wondalife-splash 3.3s linear both;
}
/* 3.3s: grow in 0.4s, 1s heartbeats (two full, one closing pulse), shrink out 0.32s. */
@keyframes wondalife-splash {
  0% { transform: scale(0.2); opacity: 0; animation-timing-function: cubic-bezier(0.2, 0.9, 0.3, 1.15); }
  12% { transform: scale(1); opacity: 1; animation-timing-function: ease-in-out; }
  21.4% { transform: scale(1.07); animation-timing-function: ease-in-out; }
  28.3% { transform: scale(0.99); animation-timing-function: ease-in-out; }
  34.3% { transform: scale(1.04); animation-timing-function: ease-in-out; }
  42% { transform: scale(1); animation-timing-function: ease-in-out; }
  51.4% { transform: scale(1.07); animation-timing-function: ease-in-out; }
  58.3% { transform: scale(0.99); animation-timing-function: ease-in-out; }
  64.3% { transform: scale(1.04); animation-timing-function: ease-in-out; }
  72% { transform: scale(1); animation-timing-function: ease-in-out; }
  81.4% { transform: scale(1.07); animation-timing-function: ease-in-out; }
  90.4% { transform: scale(1); opacity: 1; animation-timing-function: cubic-bezier(0.6, 0, 0.9, 0.5); }
  100% { transform: scale(0.1); opacity: 0; }
}
.wondalife-phone-screen.is-revealing .wondalife-phone-status,
.wondalife-phone-screen.is-revealing .wondalife-phone-homebar,
.wondalife-phone-screen.is-revealing .wondalife-phone-home {
  animation: wondalife-fade-in 0.4s ease-out both;
}
.wondalife-phone-screen.is-revealing .wondalife-phone-update,
.wondalife-phone-screen.is-revealing .wondalife-phone-grid {
  animation: wondalife-reveal 0.4s ease-out both;
}
@keyframes wondalife-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes wondalife-reveal {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}
.wondalife-phone-app {
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: #fff;
  font-family: Poppins, "Segoe UI", sans-serif;
  -webkit-tap-highlight-color: transparent;
}
.wondalife-phone-app:active .wondalife-phone-app__icon {
  transform: scale(0.94);
}
.wondalife-phone-app__icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.22);
  transition: transform 0.12s ease;
  position: relative;
}
.wondalife-phone-app__badge {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  box-sizing: border-box;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #ff3b30;
  color: #fff;
  font: 600 11px/1 Poppins, "Segoe UI", sans-serif;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.18);
  pointer-events: none;
}
.wondalife-phone-app__badge sup {
  position: relative;
  top: -4px;
  font-size: 8px;
  line-height: 1;
  margin-left: 1px;
}
.wondalife-phone-app__icon--logo {
  background: #ffffff;
}
.wondalife-phone-screen.is-night .wondalife-phone-app__icon--logo {
  background: #141a3a;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.22), inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}
.wondalife-phone-app__icon--logo img {
  display: block;
  width: 78%;
  height: auto;
}
.wondalife-phone-app__label {
  font-size: 11px;
  font-weight: 500;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
  line-height: 1.15;
  max-width: 72px;
  text-align: center;
}

.wondalife-phone-homebar {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 8px;
  transform: translateX(-50%);
  width: 108px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  cursor: pointer;
  padding: 0;
}
.wondalife-phone-device.is-android .wondalife-phone-homebar {
  width: 96px;
  height: 4px;
  opacity: 0.75;
  bottom: 10px;
}

.wondalife-phone-toast {
  position: absolute;
  z-index: 6;
  left: 50%;
  bottom: 36px;
  transform: translateX(-50%) translateY(8px);
  max-width: calc(100% - 28px);
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.88);
  color: #fff;
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.wondalife-phone-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Settings */
.wondalife-phone-settings__head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  color: #fff;
}
.wondalife-phone-settings__head h2 {
  margin: 0;
  font-family: Fredoka, Poppins, sans-serif;
  font-size: 18px;
  font-weight: 600;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
}
.wondalife-phone-back {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  backdrop-filter: blur(6px);
}
.wondalife-phone-settings__hint {
  margin: 0 0 12px;
  color: rgba(255, 255, 255, 0.88);
  font-family: Poppins, "Segoe UI", sans-serif;
  font-size: 12px;
  line-height: 1.35;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.wondalife-phone-device-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.wondalife-phone-account {
  margin-top: 16px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
  color: #fff;
  font-family: Poppins, "Segoe UI", sans-serif;
}
.wondalife-phone-account__title {
  margin: 0 0 6px;
  font-family: Fredoka, Poppins, sans-serif;
  font-size: 15px;
  font-weight: 600;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
}
.wondalife-phone-account__who {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 2px 0 10px;
}
.wondalife-phone-account__avatar {
  flex: none;
  width: 44px;
  height: 46px;
  object-fit: contain;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.3));
  -webkit-user-drag: none;
}
.wondalife-phone-account__id {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  margin: 0;
  font-size: 13px;
}
.wondalife-phone-account__id strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.wondalife-phone-account__contact {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 12px;
}
.wondalife-phone-account__contact > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* Same treatment as the game tab icons (Ludo, Chess): drawn larger than the text, tilted -18°, lifted a touch. */
.wondalife-phone-account__via {
  flex: none;
  width: 1.55em;
  height: 1.3em;
  object-fit: contain;
  margin-left: 2px;
  transform: translateY(-0.15em) rotate(-18deg) scale(1.3);
  filter: drop-shadow(0 1px 1.5px rgba(0, 0, 0, 0.3));
  -webkit-user-drag: none;
}
.wondalife-phone-account__via.is-google {
  width: 1.35em;
  height: 1.35em;
}
.wondalife-phone-account__hint {
  margin: 0 0 10px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 12px;
  line-height: 1.35;
}
.wondalife-phone-account__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 12.5px;
}
.wondalife-phone-account__mini {
  flex: none;
  padding: 5px 12px;
  border: 0;
  border-radius: 999px;
  background: #12cf9d;
  color: #fff;
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.wondalife-phone-account__switch {
  position: relative;
  flex: none;
  width: 40px;
  height: 22px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: background 0.2s ease;
}
.wondalife-phone-account__switch::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s ease;
}
.wondalife-phone-account__switch.is-on {
  background: #12cf9d;
}
.wondalife-phone-account__switch.is-on::after {
  transform: translateX(18px);
}
.wondalife-phone-account__btn {
  width: 100%;
  padding: 9px 12px;
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #0f172a;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.wondalife-phone-account__btn.is-ghost {
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
}
.wondalife-phone-account__btn:disabled {
  opacity: 0.6;
  cursor: wait;
}
.wondalife-phone-device-card {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
  padding: 10px 12px;
  color: #fff;
  text-align: left;
  cursor: pointer;
  font-family: Poppins, "Segoe UI", sans-serif;
}
.wondalife-phone-device-card.is-selected {
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.28);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.2);
}
.wondalife-phone-device-card__preview {
  width: 28px;
  height: 48px;
  border-radius: 6px;
  background: #111;
  border: 2px solid #222;
  position: relative;
  box-sizing: border-box;
}
.wondalife-phone-device-card__preview[data-preview="iphone-17"],
.wondalife-phone-device-card__preview[data-preview="iphone-18-pro-max"],
.wondalife-phone-device-card__preview[data-preview="iphone-duo"],
.wondalife-phone-device-card__preview[data-preview="iphone-duo-max"] {
  border-radius: 8px;
}
.wondalife-phone-device-card__preview[data-preview="iphone-17"]::before,
.wondalife-phone-device-card__preview[data-preview="iphone-18-pro-max"]::before {
  content: "";
  position: absolute;
  top: 4px;
  left: 50%;
  transform: translateX(-50%);
  width: 12px;
  height: 3px;
  border-radius: 2px;
  background: #333;
}
.wondalife-phone-device-card__preview[data-preview="iphone-duo"],
.wondalife-phone-device-card__preview[data-preview="iphone-duo-max"] {
  width: 34px;
}
.wondalife-phone-device-card__preview[data-preview="iphone-duo"]::before,
.wondalife-phone-device-card__preview[data-preview="iphone-duo-max"]::before {
  content: "";
  position: absolute;
  top: 4px;
  left: 5px;
  width: 8px;
  height: 3px;
  border-radius: 2px;
  background: #333;
  box-shadow: 12px 0 0 #333;
}
.wondalife-phone-device-card__preview[data-preview="iphone-duo"]::after,
.wondalife-phone-device-card__preview[data-preview="iphone-duo-max"]::after {
  content: "";
  position: absolute;
  top: 2px;
  bottom: 2px;
  left: 50%;
  width: 1px;
  transform: translateX(-50%);
  background: #333;
}
.wondalife-phone-device-card__preview[data-preview="galaxy-s25-ultra"],
.wondalife-phone-device-card__preview[data-preview="pixel-10-pro"] {
  border-radius: 5px;
}
.wondalife-phone-device-card__preview[data-preview="galaxy-s25-ultra"]::before {
  content: "";
  position: absolute;
  top: 5px;
  left: 5px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #444;
}
.wondalife-phone-device-card__preview[data-preview="pixel-10-pro"]::before {
  content: "";
  position: absolute;
  top: 5px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #444;
}
.wondalife-phone-device-card__meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.wondalife-phone-device-card__name {
  font-size: 13px;
  font-weight: 600;
}
.wondalife-phone-device-card__family {
  font-size: 11px;
  opacity: 0.8;
}
.wondalife-phone-device-card__check {
  font-size: 16px;
  font-weight: 700;
  width: 1.2em;
  text-align: center;
}

/* Mobile: fill more of the viewport like the refs */
@media (pointer: coarse), (max-width: 820px) {
  .wondalife-phone-stage {
    width: 100%;
    padding: 4px 10px max(8px, env(safe-area-inset-bottom, 0px));
  }
  .wondalife-phone-device {
    --phone-w: min(100%, calc(100vw - 28px));
    max-height: min(88vh, 780px);
  }
  .wondalife-phone-close {
    margin-right: 4px;
  }
}
