/* Лендинг Envoy v4: телефон iPhone 17 Pro, нарисованный кодом (рамки Apple Product Bezels для сайтов брать нельзя).
   Один компонент на всю страницу: первый экран и путь гостя. Все размеры в cqi от ширины корпуса, поэтому телефон
   масштабируется целиком. Пропорции по спецификации: корпус 71,9 × 150 мм, экран 402 × 874 pt (6,3"), рамка экрана
   около 2,5 % ширины (как у 17 Pro, рамка тоньше прежней), внешний радиус около 0,19 ширины, внутренний концентричный. Логотипа Apple нет.
   Внутри экрана: строка состояния 62 pt, под ней снимок страницы 402 × 812 pt, Dynamic Island и полоска «домой». */

.iphone {
  --w: 340px;
  position: relative; width: var(--w); max-width: 100%; aspect-ratio: 71.9 / 150; margin: 0;
  container-type: inline-size; isolation: isolate;
}
/* Корпус рисуем псевдоэлементом: у самого .iphone единицы cqi считаются от родителя, а не от телефона,
   из-за этого радиус корпуса был больше радиуса рамки и корпус выглядывал сверху и снизу «кругом» */
.iphone::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: 18.8cqi;
  background:
    linear-gradient(90deg, rgb(255 255 255 / 0.18), transparent 1.4cqi, transparent calc(100% - 1.4cqi), rgb(255 255 255 / 0.14)),
    linear-gradient(160deg, #5A5753 0%, #2C2B29 18%, #45433F 36%, #232220 55%, #3B3936 74%, #1E1D1B 90%, #4A4844 100%);
  box-shadow:
    inset 0 0 0 0.22cqi rgb(255 255 255 / 0.22),
    inset 0 0 0 0.6cqi rgb(0 0 0 / 0.35),
    0 1px 1px rgb(0 0 0 / 0.10),
    0 4px 10px -4px rgb(0 0 0 / 0.20),
    0 32px 56px -24px rgb(56 42 24 / 0.42);
}
/* боковые кнопки: слева Action и громкость, справа питание и Camera Control */
.ip-btn { position: absolute; z-index: -2; width: 1.1cqi; border-radius: 0.6cqi; background: linear-gradient(90deg, #1E1D1B, #5A5753 55%, #2C2B29); }
.ip-btn.l { left: -0.75cqi; }
.ip-btn.r { right: -0.75cqi; }
.ip-action { top: 39.6cqi; height: 7.6cqi; }
.ip-vol-up { top: 56.4cqi; height: 13.2cqi; }
.ip-vol-down { top: 72.4cqi; height: 13.2cqi; }
.ip-power { top: 64.6cqi; height: 21.8cqi; }
.ip-cam { top: 116.8cqi; height: 15.6cqi; width: 0.9cqi; right: -0.45cqi; background: linear-gradient(90deg, #1A1918, #4A4844 60%, #262523); }

/* чёрная рамка экрана и сам экран, скругления концентричные */
.ip-bezel { position: absolute; inset: 0.9cqi; border-radius: 17.9cqi; background: #0B0B0C; box-shadow: 0 0 0 0.12cqi rgb(0 0 0 / 0.55); }
.ip-screen { position: absolute; inset: 2.5cqi; border-radius: 16.3cqi; overflow: hidden; background: var(--paper); display: flex; flex-direction: column; }

.ip-status { position: relative; flex: none; height: 14.65cqi; color: var(--ink); }
.ip-time { position: absolute; left: 6.2cqi; top: 4.4cqi; width: 17cqi; text-align: center; font: 600 3.92cqi/1 var(--font); letter-spacing: -0.01em; font-variant-numeric: tabular-nums; }
.ip-icons { position: absolute; right: 6cqi; top: 4.9cqi; width: 17.6cqi; height: auto; }
.ip-island { position: absolute; z-index: 3; left: 50%; top: 2.53cqi; width: 29cqi; height: 8.52cqi; border-radius: 99px; background: #000; transform: translateX(-50%); }
.ip-island::after { content: ""; position: absolute; right: 2.6cqi; top: 50%; width: 2.6cqi; height: 2.6cqi; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #2B3550, #0D1018 60%); transform: translateY(-50%); }
.ip-home { position: absolute; z-index: 3; left: 50%; bottom: 1.84cqi; width: 30.9cqi; height: 1.15cqi; border-radius: 99px; background: rgb(29 29 31 / 0.88); transform: translateX(-50%); }

/* Снимки экрана лежат в одной ячейке грида друг на друге: смена кроссфейдом без пустого кадра */
.ip-shots { position: relative; flex: 1; display: grid; }
.ip-shot { grid-area: 1 / 1; position: relative; margin: 0; }
.ip-shot > img { width: 100%; height: 100%; aspect-ratio: 402 / 812; object-fit: cover; object-position: top; }

/* Живой слой плеера поверх снимка: строка перевода и чипы языков.
   Снимок 402 × 812 pt: плеер x 16–386, y 60–268; слой закрывает видео под меткой LIVE и полосу кнопок (y 104–268),
   нижние углы как у плеера. 1 pt = 0,2304 cqi корпуса */
.player {
  position: absolute; left: 3.69cqi; width: 85.22cqi; top: 23.96cqi; height: 37.79cqi; border-radius: 0 0 5.5cqi 5.5cqi;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 2.6cqi; padding: 0 3cqi 4cqi;
  background: radial-gradient(90% 120% at 50% 30%, #2A2219 0%, #121110 62%); color: var(--hall-text);
  -webkit-mask: linear-gradient(transparent, #000 4cqi); mask: linear-gradient(transparent, #000 4cqi);
}
.caption {
  flex: 1; display: flex; align-items: center; justify-content: center; text-align: center; text-wrap: balance;
  font-size: max(13px, 3.9cqi); line-height: 1.3; font-weight: 500;
  transition: opacity var(--t-state) var(--ease);
}
.caption.fade { opacity: 0; }
.chips { display: flex; justify-content: center; gap: clamp(4px, 1.6cqi, 6px); }
.chip {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  min-height: 28px; padding: 0 clamp(6px, 2.6cqi, 9px); border-radius: var(--r-pill); border: 0;
  background: var(--hall-3); color: var(--hall-text); font-size: 13px; line-height: 1; font-weight: 600; cursor: pointer; white-space: nowrap;
  transition: background-color var(--t-state) var(--ease), color var(--t-state) var(--ease), transform 100ms var(--ease);
}
.chip::before { content: ""; position: absolute; inset: -10px -3px; }
.chip[aria-pressed="true"] { background: var(--stub); color: var(--ink); }
.chip:active { transform: scale(0.97); }
.chip:focus-visible { outline: 2px solid var(--stub); outline-offset: 2px; }
@media (hover: hover) and (pointer: fine) { .chip[aria-pressed="false"]:hover { background: var(--hall-4); } }
@media (prefers-reduced-motion: reduce) { .caption { transition: none; } .chip { transition: background-color var(--t-state) var(--ease), color var(--t-state) var(--ease); } }
