/* ============================================================
   Yungis — стили лендинга.

   Файл общий: legal/offer.html и legal/privacy.html подключают его
   как ../styles.css и берут отсюда общий слой — .page, .site-header*,
   .site-logo, .site-main, .section, .section__shell, .site-footer*.
   Эти правила трогать нельзя без правки legal-страниц, у которых
   остальная вёрстка живёт в собственном <style>.

   .site-header__cta и .button сейчас в разметке не используются
   (кнопку «В кабинет» убрали, CTA заменили тайлами входа) — оставлены
   как примитивы дизайн-системы.
   ============================================================ */

:root {
  --bg: #f7f4ee;
  --bg2: #f0ebe3;
  --bg3: #e8e2d8;
  --text: #1f1a17;
  --text2: #7a716a;
  --text3: #a09890;
  --accent: #6fae9b;
  --accent-h: #5a9a85;
  --lavender: #a78fb7;
  --r: 28px;
  --shell: 900px;
  --shell-wide: 1100px;
  --sticky-h: 0px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  /* clip, а не hidden: hidden делает body скролл-контейнером и ломает
     position:sticky у шапки. clip подрезает так же, но контейнер не создаёт. */
  overflow-x: clip;
}

/* Playfair Display, а не DM Serif Display: у последнего есть только наборы
   latin и latin-ext, поэтому на русском тексте он не применялся вообще —
   заголовки рисовались системной антиквой, своей на каждой ОС. У Playfair
   есть cyrillic. Вес 500, а не 400: в 400 он заметно легче по цвету, чем
   был DM Serif, и заголовки теряли плотность. */
h1,
h2,
h3,
.site-logo,
.serif {
  font-family: "Playfair Display", serif;
  font-weight: 500;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  cursor: pointer;
}

svg {
  flex-shrink: 0;
}

:focus-visible {
  outline: 2px solid var(--accent-h);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Общий слой (используется и legal-страницами) ---------- */

/* Приклеена к верхнему краю на полупрозрачной подложке: пока человек
   листает, логотип остаётся на виду — понятно, где находишься. */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  padding: 14px 28px;
  background: rgba(247, 244, 238, 0.72);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(31, 26, 23, 0.06);
}

/* Там, где размытия нет, полупрозрачный фон оставит текст читаемым не
   везде — делаем подложку плотной. */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header {
    background: var(--bg);
  }
}

.site-header__inner {
  width: min(100%, var(--shell-wide));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

/* Лендинг: в шапке остался только логотип */
.site-header__inner--solo {
  justify-content: flex-start;
}

.site-logo {
  font-size: 24px;
  letter-spacing: -0.5px;
}

.site-header__cta,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  transition: all 0.25s ease;
}

.site-header__cta {
  min-height: 44px;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  background: var(--text);
}

.site-header__cta:hover {
  background: var(--accent-h);
}

.site-main {
  padding-bottom: 24px;
}

.section {
  padding: 100px 28px 0;
}

.section--hero {
  padding-top: 48px;
}

.section--cta {
  padding-bottom: 100px;
}

.section__shell {
  width: min(100%, var(--shell));
  margin: 0 auto;
}

.section__shell--wide {
  width: min(100%, var(--shell-wide));
}

.section__header {
  margin-bottom: 48px;
}

.section__header--center {
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.section__header--narrow {
  max-width: 620px;
}

.section__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 18px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--accent-h);
}

.section__title {
  font-size: clamp(26px, 4.5vw, 38px);
  line-height: 1.15;
  letter-spacing: -0.7px;
}

.section__lead {
  margin-top: 16px;
  font-size: 16px;
  line-height: 1.7;
  color: var(--text2);
}

.button {
  min-height: 58px;
  width: 100%;
  max-width: 300px;
  padding: 18px 36px;
  border: none;
  font-size: 16px;
  font-weight: 500;
}

.button--primary {
  color: #fff;
  background: var(--text);
}

.button--primary:hover {
  background: var(--accent-h);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(111, 174, 155, 0.25);
}

/* ---------- Hero ---------- */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.82fr);
  align-items: center;
  gap: 48px;
}

.hero__copy {
  min-width: 0;
}

/* ---------- «В кармане»: доктор за прозрачным экраном ---------- */

.pocket {
  position: relative;
  display: flex;
  justify-content: center;
  padding: 34px 0 24px;
}

/* Размытый двойник портрета: свет как будто проходит сквозь стекло
   и ложится на страницу вокруг телефона. */
.pocket__aura {
  position: absolute;
  top: 8%;
  left: 50%;
  width: 132%;
  height: 88%;
  transform: translateX(-50%);
  background:
    radial-gradient(closest-side, rgba(111, 174, 155, 0.32), transparent 72%) center / 100% 100% no-repeat,
    url("assets/images/shared/hero-yungis-portrait.webp") center / cover no-repeat;
  filter: blur(38px) saturate(1.15);
  opacity: 0.42;
  border-radius: 50%;
}

.pocket__phone {
  position: relative;
  width: min(100%, 300px);
  aspect-ratio: 300 / 610;
  padding: 10px;
  border-radius: 46px;
  /* Тонкая стеклянная рамка вместо глухого корпуса */
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.75), rgba(31, 26, 23, 0.28));
  box-shadow:
    0 0 0 1px rgba(31, 26, 23, 0.12),
    0 40px 90px rgba(31, 26, 23, 0.28);
}

.pocket__screen {
  position: relative;
  height: 100%;
  border-radius: 38px;
  background: #16120f;
  /* Отрицательный верх пускает голову выше рамки, бока и низ режет. */
  clip-path: inset(-16% 0 0 0 round 38px);
}

.pocket__portrait {
  position: absolute;
  left: 50%;
  top: -9%;
  width: 152%;
  height: auto;
  transform: translateX(-50%);
  /* Радиальная маска вместо линейной: она снимает тёмные углы снимка, из-за
     которых над рамкой торчал бы прямоугольник, и одновременно растворяет
     края внутри экрана — там под ними такой же тёмный фон, стык не виден.
     Над рамкой остаётся только освещённая голова: доктор выходит из-за стекла. */
  -webkit-mask-image: radial-gradient(58% 54% at 50% 48%, #000 42%, rgba(0, 0, 0, 0.72) 66%, transparent 88%);
  mask-image: radial-gradient(58% 54% at 50% 48%, #000 42%, rgba(0, 0, 0, 0.72) 66%, transparent 88%);
}

/* Блик по стеклу — только внутри экрана, поэтому вышедшая за рамку
   часть головы читается как «снаружи». */
.pocket__glass {
  position: absolute;
  inset: 0;
  border-radius: 38px;
  background: linear-gradient(148deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0.04) 26%, transparent 52%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.09);
  pointer-events: none;
}

.pocket__notch {
  position: absolute;
  top: 22px;
  left: 50%;
  transform: translateX(-50%);
  width: 86px;
  height: 20px;
  border-radius: 999px;
  background: rgba(22, 18, 15, 0.55);
  pointer-events: none;
}

.pocket-chip {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 30px rgba(31, 26, 23, 0.16);
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
}

.pocket-chip--a {
  top: 16%;
  left: -6%;
  animation: chipFloat 5.5s ease-in-out infinite;
}

.pocket-chip--b {
  bottom: 16%;
  right: -4%;
  color: var(--accent-h);
  animation: chipFloat 6.5s ease-in-out infinite reverse;
}

.pocket-chip__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

@keyframes chipFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}

/* Кегль подобран так, чтобы «Помогу справиться» держалось в одну строку:
   Playfair шире, чем прежняя системная антиква, и на 68px строка рвалась. */
.hero__title {
  font-size: clamp(34px, 6.2vw, 56px);
  line-height: 1.1;
  letter-spacing: -1.4px;
}

/* ---------- Блок-утверждение под hero ----------
   Слова проявляются по мере прокрутки: script.js пишет в --p прогресс
   0..1, каждое слово знает свой номер --i и общее число --n, и гасится
   до тех пор, пока волна до него не дошла. Считает CSS, JS только
   обновляет одно число. */

.section--statement {
  padding-top: 88px;
}

.statement {
  max-width: 940px;
  font-family: "Playfair Display", serif;
  font-weight: 400;
  font-size: clamp(23px, 3.4vw, 38px);
  line-height: 1.4;
  letter-spacing: -0.5px;
  text-wrap: pretty;
}

.statement__p + .statement__p {
  margin-top: 0.85em;
}

/* Слово целиком — inline-block, чтобы строка не рвалась посреди слова;
   гасятся при этом отдельные символы внутри него. */
.statement.is-split .statement__w {
  display: inline-block;
}

.statement.is-split .statement__c {
  /* Фронт растянут на 10 символов — примерно полтора слова, поэтому граница
     всегда приходится на середину слова, а не на пробел между словами. */
  opacity: clamp(0.16, calc((var(--p, 1) * var(--n) - var(--i) + 9) / 10), 1);
}

@media (prefers-reduced-motion: reduce) {
  .statement.is-split .statement__c {
    opacity: 1;
  }
}

/* Меняющееся слово. Ширина анимируется по замеру из script.js,
   поэтому строка «дышит», а не прыгает. */
.rotator {
  position: relative;
  display: inline-block;
  vertical-align: baseline;
  width: var(--rotator-w, auto);
  height: 1.06em;
  text-align: left;
  transition: width 0.42s cubic-bezier(0.22, 1, 0.36, 1);
}

.rotator__word {
  display: inline-block;
  color: var(--accent-h);
  font-style: italic;
  white-space: nowrap;
}

.rotator__word.is-out {
  opacity: 0;
  transform: translateY(-0.32em);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.rotator__word.is-in {
  animation: rotatorIn 0.42s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes rotatorIn {
  from {
    opacity: 0;
    transform: translateY(0.36em);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ---------- Точки входа ---------- */

.entry {
  margin-top: 40px;
}

/* auto-fit, а не фиксированные колонки: точек входа пять и их число ещё
   будет меняться — раскладка подстраивается сама. */
.entry__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(146px, 1fr));
  gap: 12px;
  list-style: none;
}

.entry-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  height: 100%;
  padding: 18px 18px 16px;
  border: 1px solid rgba(31, 26, 23, 0.08);
  border-radius: 22px;
  background: #fff;
  text-align: left;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

a.entry-tile:hover {
  transform: translateY(-3px);
  border-color: rgba(111, 174, 155, 0.45);
  box-shadow: 0 14px 34px rgba(31, 26, 23, 0.08);
}

.entry-tile__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--bg2);
  color: var(--text);
}

.entry-tile__icon--max {
  background: rgba(111, 174, 155, 0.16);
  color: var(--accent-h);
}

.entry-tile__icon--web {
  background: rgba(167, 143, 183, 0.18);
  color: var(--lavender);
}

.entry-tile__body {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.entry-tile__kicker {
  font-size: 12px;
  color: var(--text3);
}

.entry-tile__name {
  font-size: 16px;
  font-weight: 600;
}

.entry-tile--soon {
  background: transparent;
  border-style: dashed;
  border-color: rgba(31, 26, 23, 0.14);
  color: var(--text3);
  cursor: default;
}

.entry-tile--soon .entry-tile__icon {
  background: rgba(31, 26, 23, 0.05);
  color: var(--text3);
}

.entry-tile--soon .entry-tile__name {
  color: var(--text2);
}

.entry-tile__badge {
  position: absolute;
  top: 14px;
  right: 14px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--bg3);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.3px;
  color: var(--text2);
}

/* ---------- Знакомство ---------- */

.triad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  list-style: none;
}

.triad__card {
  padding: 28px 26px;
  border-radius: var(--r);
  background: #fff;
  border: 1px solid rgba(31, 26, 23, 0.06);
}

.triad__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  margin-bottom: 18px;
  border-radius: 16px;
}

.triad__icon--night {
  background: rgba(167, 143, 183, 0.18);
  color: var(--lavender);
}

.triad__icon--calm {
  background: rgba(111, 174, 155, 0.16);
  color: var(--accent-h);
}

.triad__icon--stress {
  background: rgba(31, 26, 23, 0.06);
  color: var(--text);
}

.triad__title {
  font-size: 22px;
  margin-bottom: 10px;
}

.triad__text {
  font-size: 15px;
  line-height: 1.65;
  color: var(--text2);
}

/* ---------- Двухколоночные блоки ---------- */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 56px;
}

.split--reverse .split__media {
  order: 2;
}

.split__body .section__title {
  max-width: 460px;
}

.ticks {
  margin-top: 28px;
  display: grid;
  gap: 14px;
  list-style: none;
}

.ticks__item {
  position: relative;
  padding-left: 32px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--text2);
}

.ticks__item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(111, 174, 155, 0.16) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235a9a85' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 13l4 4L19 7'/%3E%3C/svg%3E") center / 12px no-repeat;
}

/* ---------- Трекер ---------- */

.device-art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
}

.device-art__glow {
  position: absolute;
  inset: 12% 18%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(111, 174, 155, 0.28), transparent 68%);
  filter: blur(28px);
}

.device-art__svg {
  position: relative;
  width: min(100%, 240px);
  height: auto;
}

/* ---------- Запросы ---------- */

.needs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  list-style: none;
}

.needs__item {
  padding: 14px 22px;
  border-radius: 999px;
  border: 1px solid rgba(31, 26, 23, 0.1);
  background: #fff;
  font-size: 15px;
  color: var(--text2);
  transition: border-color 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.needs__item:hover {
  border-color: rgba(111, 174, 155, 0.5);
  color: var(--text);
  transform: translateY(-2px);
}

/* ---------- Устройства ---------- */

.devices {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  list-style: none;
}

.device-card {
  padding: 32px 30px;
  border-radius: var(--r);
  background: #fff;
  border: 1px solid rgba(31, 26, 23, 0.06);
}

.device-card__art {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 140px;
  margin-bottom: 22px;
  border-radius: 20px;
  background: var(--bg2);
}

.device-card__art svg {
  width: 160px;
  height: 120px;
}

.device-card__title {
  font-size: 22px;
  margin-bottom: 10px;
}

.device-card__text {
  font-size: 15px;
  line-height: 1.65;
  color: var(--text2);
}

.devices__note {
  margin-top: 24px;
  text-align: center;
  font-size: 14px;
  color: var(--text3);
}

/* ---------- Телефон с идущей программой ---------- */

.phone {
  position: relative;
  width: min(100%, 300px);
  margin: 0 auto;
  padding: 12px;
  border-radius: 42px;
  background: var(--text);
  box-shadow: 0 30px 70px rgba(31, 26, 23, 0.22);
}

.phone__notch {
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 92px;
  height: 22px;
  border-radius: 999px;
  background: var(--text);
  z-index: 2;
}

.phone__screen {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 42px 16px 18px;
  border-radius: 32px;
  background: var(--bg);
}

.chat {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.chat__bubble {
  max-width: 88%;
  padding: 12px 15px;
  font-size: 13px;
  line-height: 1.55;
}

.chat__bubble--user {
  align-self: flex-end;
  border-radius: 18px 18px 5px 18px;
  background: var(--text);
  color: #fff;
}

.chat__bubble--bot {
  align-self: flex-start;
  border-radius: 18px 18px 18px 5px;
  background: #fff;
  border: 1px solid rgba(31, 26, 23, 0.07);
  color: var(--text);
}

.player {
  padding: 14px 16px 16px;
  border-radius: 20px;
  background: linear-gradient(145deg, #2b2521, #1f1a17);
  color: #fff;
}

.player__head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.player__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--text);
}

.player__meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.player__title {
  font-size: 13px;
  font-weight: 600;
}

.player__time {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.55);
}

.player__bar {
  height: 4px;
  margin-top: 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  overflow: hidden;
}

.player__fill {
  display: block;
  width: 60%;
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
}

.player__wave {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 4px;
  height: 26px;
  margin-top: 14px;
}

.player__wave span {
  flex: 1;
  border-radius: 999px;
  background: rgba(111, 174, 155, 0.75);
  animation: wave 1.5s ease-in-out infinite;
}

.player__wave span:nth-child(1) { animation-delay: 0s; }
.player__wave span:nth-child(2) { animation-delay: 0.12s; }
.player__wave span:nth-child(3) { animation-delay: 0.24s; }
.player__wave span:nth-child(4) { animation-delay: 0.36s; }
.player__wave span:nth-child(5) { animation-delay: 0.48s; }
.player__wave span:nth-child(6) { animation-delay: 0.6s; }
.player__wave span:nth-child(7) { animation-delay: 0.72s; }
.player__wave span:nth-child(8) { animation-delay: 0.84s; }
.player__wave span:nth-child(9) { animation-delay: 0.96s; }
.player__wave span:nth-child(10) { animation-delay: 1.08s; }

@keyframes wave {
  0%, 100% { height: 22%; }
  50% { height: 100%; }
}

/* ---------- Финальный блок ---------- */

.cta-block {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

.cta-block .section__title {
  font-size: clamp(28px, 5vw, 44px);
  letter-spacing: -1px;
}

.cta-block .section__title em {
  font-style: italic;
  color: var(--accent-h);
}

.cta-block__note {
  margin-top: 36px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text3);
}

.socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 32px;
  list-style: none;
}

.social-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 20px;
  border-radius: 999px;
  border: 1px solid rgba(31, 26, 23, 0.1);
  background: #fff;
  font-size: 14px;
  font-weight: 500;
  transition: border-color 0.25s ease, transform 0.25s ease;
}

.social-link:hover {
  border-color: rgba(111, 174, 155, 0.5);
  transform: translateY(-2px);
}

.social-link__icon {
  color: var(--accent-h);
  display: flex;
}

.entry--final {
  margin-top: 36px;
}

/* ---------- Мобильная нижняя кнопка и шторка ---------- */

.sticky-cta {
  display: none;
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: calc(16px + env(safe-area-inset-bottom));
  z-index: 40;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 56px;
  padding: 16px 28px;
  border-radius: 999px;
  background: var(--text);
  color: #fff;
  font-size: 16px;
  font-weight: 500;
  box-shadow: 0 12px 32px rgba(31, 26, 23, 0.28);
}

/* UA центрирует <dialog>, поэтому к нижнему краю прижимаем сами:
   растягиваем на весь экран и выравниваем панель через flex. */
.sheet {
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  overflow: visible;
}

.sheet:not([open]) {
  display: none;
}

.sheet[open] {
  display: flex;
  align-items: flex-end;
}

.sheet__panel {
  width: 100%;
}

.sheet::backdrop {
  background: rgba(31, 26, 23, 0.45);
  backdrop-filter: blur(2px);
}

.sheet__panel {
  padding: 10px 16px calc(24px + env(safe-area-inset-bottom));
  border-radius: 28px 28px 0 0;
  background: var(--bg);
  animation: sheetUp 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.sheet.is-closing .sheet__panel {
  animation: sheetDown 0.24s ease forwards;
}

@keyframes sheetUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

@keyframes sheetDown {
  from { transform: translateY(0); }
  to { transform: translateY(100%); }
}

.sheet__grabber {
  display: block;
  width: 44px;
  height: 5px;
  margin: 0 auto 18px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: rgba(31, 26, 23, 0.18);
}

.sheet__title {
  margin-bottom: 16px;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
}

/* В шторке — один столбик: строки читаются быстрее сетки квадратов,
   когда выбираешь большим пальцем. */
.sheet .entry {
  margin-top: 0;
}

.sheet .entry__list {
  grid-template-columns: 1fr;
  gap: 8px;
}

.sheet .entry-tile {
  flex-direction: row;
  align-items: center;
  gap: 14px;
  padding: 13px 16px;
  border-radius: 18px;
}

.sheet .entry-tile__icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
}

.sheet .entry-tile__badge {
  position: static;
  margin-left: auto;
}

/* ---------- Адаптив ---------- */

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 8px;
    text-align: center;
  }

  .hero__lead {
    margin-inline: auto;
  }

  .pocket__phone {
    width: min(100%, 260px);
  }

  .split {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .split--reverse .split__media {
    order: 0;
  }

  .split__body {
    text-align: center;
  }

  .split__body .section__title {
    max-width: none;
  }

  .ticks {
    max-width: 460px;
    margin-inline: auto;
    text-align: left;
  }
}

@media (max-width: 800px) {
  .section {
    padding: 72px 20px 0;
  }

  .triad,
  .devices {
    grid-template-columns: 1fr;
  }

  .entry__list {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  /* На узких экранах логотип по центру подложки */
  .site-header {
    padding: 12px 20px;
  }

  .site-header__inner--solo {
    justify-content: center;
  }

  .hero__title {
    letter-spacing: -1.2px;
  }

  /* На мобильных вход живёт в нижней кнопке и шторке.
     Тайлы в hero прячем только при живом JS: без него нижняя кнопка
     остаётся якорем на этот список, и он должен быть виден. */
  .sticky-cta {
    display: inline-flex;
  }

  .js .entry--hero,
  .entry--final {
    display: none;
  }

  .pocket-chip {
    font-size: 12px;
    padding: 8px 13px;
  }

  /* На узких экранах чипы держим внутри вьюпорта, иначе срезает краем */
  .pocket-chip--a {
    left: 4%;
  }

  .pocket-chip--b {
    right: 4%;
  }

  .site-main {
    /* чтобы нижняя кнопка не перекрывала конец страницы */
    padding-bottom: 96px;
  }

  .section--cta {
    padding-bottom: 48px;
  }

  .device-card__art {
    height: 120px;
  }
}

@media (max-width: 420px) {
  .entry__list {
    grid-template-columns: 1fr;
  }

  .needs__item {
    font-size: 14px;
    padding: 12px 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ---------- Футер (используется и legal-страницами) ---------- */

.site-footer {
  max-width: 900px;
  margin: 0 auto;
  padding: 32px 28px;
  font-size: 13px;
  color: var(--text2);
  opacity: 0.5;
}

.site-footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.site-footer__item {
  flex: 1 1 0;
}

.site-footer__item--center {
  text-align: center;
}

.site-footer__link {
  text-align: center;
  transition: opacity 0.25s ease, color 0.25s ease;
}

.site-footer__link:hover {
  color: var(--text);
  opacity: 1;
}
