:root {
  --color-page: #eceef0;
  --color-text-primary: #262626;
  --color-text-secondary: #738295;
  --color-text-inverse: #ffffff;
  --color-text-inverse-secondary: rgba(255, 255, 255, 0.64);
  --color-surface-tertiary: #f4f5f6;
  --color-control-secondary: #e7eef3;
  --color-brand: #009e36;
  --color-border-surface: #d5d8dc;
  --color-avatar-bg: #f5f7fa;

  --font-display: "SB Sans Display", "SB Sans Text", -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-text: "SB Sans Text", -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --radius-2: 8px;
}

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

html {
  scrollbar-gutter: auto;
}

body {
  font-family: var(--font-text);
  background: #c9ccd1;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 20px 0;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  width: 100vw;
  overflow-x: hidden;
}

/* Полностью скрыть вертикальный скроллбар на десктопе */
html, body { scrollbar-width: none; -ms-overflow-style: none; }
body::-webkit-scrollbar,
html::-webkit-scrollbar { display: none; width: 0; height: 0; }

/* Firefox */
html {
  scrollbar-width: none;
}

/* Скрыть скроллбар в .start (на случай если контента > 812px на десктопе) */
.start::-webkit-scrollbar { display: none; width: 0; height: 0; }
.start { scrollbar-width: none; -ms-overflow-style: none; }

img {
  display: block;
  max-width: 100%;
}

button {
  font-family: inherit;
  border: none;
  background: none;
  cursor: pointer;
  color: inherit;
}

/* ---------- Frame ---------- */
.start {
  position: relative;
  width: 375px;
  height: 812px;
  background: var(--color-page);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-bottom: 0;
  overflow-x: hidden;
  overflow-y: auto;
  transition: background 1s ease;
}
.start--dark {
  background: #050402;
}
.start > * {
  flex-shrink: 0;
}

@media (max-width: 600px) {
  html,
  body {
    background: var(--color-page);
    overflow-x: hidden;
    touch-action: manipulation;
    -webkit-text-size-adjust: 100%;
    display: block;
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }
  body {
    padding: 0;
    margin: 0;
    min-height: 0;
  }
  .start {
    display: contents;
    height: auto;
    background: transparent;
    overflow: visible;
    border-radius: 0;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    min-height: 0;
    min-width: 0;
    max-width: none;
  }
  .start::before { display: none !important; }
  body > main > * {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    min-width: 0;
  }
  .topline,
  .hero,
  .bottom-text,
  .interactive,
  .interactive__base,
  .cards,
  .cards__row,
  .cards__cta,
  .home-indicator,
  .app-loader {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }
  .hero {
    height: auto;
    min-height: 600px;
    border-radius: 0;
    padding-top: 8px;
  }
  .interactive {
    padding: 0 0 40px;
    margin: 0;
  }
  .interactive--dark { background: transparent; }
  .interactive__base {
    height: auto !important;
    aspect-ratio: 375 / 386;
    min-height: 0;
    margin: 0 0 -84px 0;
  }
  .bottom-text { background: transparent; }
  .bottom-text--dark { background: transparent; }
  .home-indicator {
    position: static !important;
    height: 34px;
    width: 100%;
    min-width: 0;
  }
}

/* ---------- Icon sizes ---------- */
.icon-16 { width: 16px; height: 16px; }
.icon-14 { width: 14px; height: 14px; }
.topnav__btn[aria-label="Поиск"] img { transform: scaleY(-1); }

/* ---------- Topline ---------- */
.topline {
  width: 100%;
  background: #ffffff;
  border-bottom: 1px solid var(--color-border-surface);
  display: flex;
  flex-direction: column;
}

.status-bar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.status-bar__time {
  width: 140.5px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: -apple-system, "SF Pro Text", "Segoe UI", sans-serif;
  font-weight: 600;
  font-size: 15px;
  color: #000;
}

.status-bar__levels {
  width: 140.5px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 14px;
}
.status-bar__levels img { width: auto; height: 100%; }

.topnav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 52px;
}

.topnav__left,
.topnav__right {
  display: flex;
  align-items: center;
  height: 100%;
}

.topnav__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 10px 12px;
}
.topnav__left .topnav__btn:first-child { padding-left: 16px; }
.topnav__right .topnav__btn:last-child { padding-right: 16px; }

.topnav__logo {
  width: 48px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.topnav__logo img { width: 30px; height: 32px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  width: 100%;
  height: 716px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 8px;
  border-radius: 0 0 16px 16px;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: 0 0 16px 16px;
  overflow: hidden;
}
.hero__bg-base {
  position: absolute;
  inset: 0;
  background: #050402;
}
.hero__bg-photo {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.hero__bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 1s ease;
}
.hero[data-state="on"] .hero__bg-img--on { opacity: 1; }
.hero[data-state="on"] .hero__bg-img--off { opacity: 0; }
.hero[data-state="off"] .hero__bg-img--on { opacity: 0; }
.hero[data-state="off"] .hero__bg-img--off { opacity: 1; }
.hero__bg-fade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(5, 4, 2, 0) 58.24%, #050402 73.883%);
}
.hero__bg-vignette {
  position: absolute;
  inset: 0;
  mix-blend-mode: multiply;
  background: radial-gradient(58% 42% at 24% 6%, rgba(5, 4, 2, 0.85), rgba(5, 4, 2, 0) 70%);
}

/* State visibility toggling (header on/off) */
.hero[data-state="on"] .state-off { display: none; }
.hero[data-state="off"] .state-on { display: none; }

.hero__content {
  position: relative;
  z-index: 1;
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero__nav {
  width: 100%;
  padding: 12px 16px;
}

.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 32px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-2);
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.28px;
  color: #ffffff;
}
.btn-back__icon {
  width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}
.btn-back__icon img {
  width: 12.586px;
  height: 7.293px;
  transform: rotate(90deg);
  filter: brightness(0) invert(1);
}

.hero__title {
  flex: 1;
  width: 100%;
  padding: 8px 16px 32px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--color-text-inverse);
}
.hero__title h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 32px;
  line-height: 40px;
}
.hero__title p {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 14px;
  line-height: 20px;
}

.hero__cards { width: 100%; }

.hero__try-now {
  width: 100%;
  padding: 0 16px;
  display: flex;
  justify-content: flex-end;
  transform: translateY(-5px);
}
.hero__try-now img {
  width: auto;
  height: 93px;
  display: block;
  -webkit-user-drag: none;
  pointer-events: none;
  clip-path: inset(0 100% 0 0);
  animation: try-now-reveal 2s ease-out 2s forwards;
  transform-origin: center;
}
@keyframes try-now-reveal {
  to { clip-path: inset(0 0 0 0); }
}

.hero-card-row {
  display: flex;
  gap: 8px;
  padding: 0 16px;
  align-items: stretch;
}

/* Glass cards (hero) */
.glass-card {
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  height: 142px;
  background: rgba(255, 255, 255, 0.12);
}

.lamp-card {
  flex: 1;
  display: flex;
  padding: 4px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(255, 255, 255, 0.12);
}
.lamp-card:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.7);
  outline-offset: 2px;
}
.lamp-card__inner {
  position: relative;
  flex: 1;
  min-width: 0;
  display: flex;
  padding: 8px;
  border-radius: 13px;
}
.lamp-card__inner::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 13px;
  background: linear-gradient(156deg, rgba(255, 183, 0, 0.27) 2.65%, rgba(112, 53, 21, 0) 65.4%);
  opacity: 0;
  transition: opacity 1s ease;
  pointer-events: none;
}
.hero[data-state="on"] .lamp-card__inner::before {
  opacity: 1;
}
.lamp-card__content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.more-card {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: space-between;
  padding: 12px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.more-card__text {
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.28px;
  color: var(--color-text-inverse);
  text-align: left;
  width: 100%;
}
.more-card__btn {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 10px;
}
.more-card__btn img { transform: rotate(90deg); }

/* Card shared parts */
.card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.card-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-surface-tertiary);
  border-radius: 10px;
  flex-shrink: 0;
}
.card-icon--glass {
  background: rgba(255, 255, 255, 0.15);
}

.lamp-icon {
  position: relative;
  overflow: hidden;
}
.lamp-icon__glow {
  position: absolute;
  inset: 0;
  mix-blend-mode: screen;
  overflow: hidden;
  pointer-events: none;
}
.lamp-icon__glow img {
  position: absolute;
  height: 145%;
  width: 95.53%;
  left: 2.23%;
  top: -22.5%;
  max-width: none;
}
.lamp-icon__bulb {
  position: absolute;
  width: 23.53px;
  height: 35.08px;
  left: 50%;
  transform: translateX(-50%);
  top: 1.83px;
  object-fit: cover;
}

/* Power button (circular) */
.power {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-sizing: border-box;
}
.power img { width: 14px; height: 14px; }
.power--grey-1 { border: 2.101px solid #c2c9d2; }
.power--grey-2 { border: 2.101px solid #abb0b8; }
.lamp-toggle {
  width: 44px;
  height: 24px;
  border-radius: 24px;
  flex-shrink: 0;
  position: relative;
  display: block;
  transition: background 1s ease;
}
.lamp-toggle::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #ffffff;
  top: 2px;
  left: 2px;
  transition: transform 1s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}
.hero[data-state="on"] .lamp-toggle {
  background: #009e36;
}
.hero[data-state="on"] .lamp-toggle::after {
  transform: translateX(20px);
}
.hero[data-state="off"] .lamp-toggle {
  background: #363636;
}
.hero[data-state="off"] .lamp-toggle::after {
  background: #b7b7b7;
}

.card-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
  word-break: break-word;
}
.card-title {
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.28px;
  color: var(--color-text-primary);
}
.card-subtitle {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: -0.12px;
  color: var(--color-text-secondary);
}
.card-text--inverse .card-title { color: var(--color-text-inverse); }
.card-text--inverse .card-subtitle { color: var(--color-text-inverse-secondary); }

/* Hero CTA */
.hero__cta {
  width: 100%;
  margin-top: auto;
}
.hero__cta {
  background: #050402;
  padding: 8px 16px 16px;
  border-radius: 0 0 16px 16px;
}
.btn-glass {
  width: 100%;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.28px;
  color: var(--color-text-inverse);
}

/* ---------- Bottom text ---------- */
.bottom-text {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 40px 16px 16px;
  text-align: center;
  background: transparent;
  transition: background 1s ease;
}
.bottom-text--dark {
  background: #050402;
}
.bottom-text h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 24px;
  line-height: 32px;
  color: var(--color-text-primary);
  max-width: 343px;
  transition: color 1s ease;
}
.bottom-text p {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 14px;
  line-height: 20px;
  color: var(--color-text-secondary);
  transition: color 1s ease;
}
.bottom-text.bottom-text--dark h2 { color: #ffffff; }
.bottom-text.bottom-text--dark p { color: rgba(255, 255, 255, 0.65); }

/* ---------- Interactive frame ---------- */
.interactive {
  width: 100%;
  display: flex;
  flex-direction: column;
  padding-bottom: 40px;
  background: transparent;
  transition: background 1s ease;
}
.interactive--dark {
  background: #050402;
}
.interactive__base {
  position: relative;
  width: 100%;
  aspect-ratio: 375 / 386;
  margin-bottom: -84px;
}
.interactive__base img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.cards {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}
.cards__cols {
  display: flex;
  gap: 8px;
  padding: 0 16px;
  align-items: stretch;
}
.cards__col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.scenario-card {
  flex: 1;
  min-width: 0;
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  background: #ffffff;
  border-radius: 16px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.avatars {
  display: flex;
  align-items: center;
}
.avatar {
  width: 32px;
  height: 32px;
  border: 2px solid #ffffff;
  border-radius: 6px;
  background: var(--color-avatar-bg);
  overflow: hidden;
  flex-shrink: 0;
}
.avatar:not(:last-child) { margin-right: -7px; }
.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 6px;
}

.card-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 32px;
  padding: 0 12px;
  background: var(--color-control-secondary);
  border-radius: var(--radius-2);
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.28px;
  color: var(--color-text-primary);
}
.icon-chevron {
  width: 6.667px;
  height: 11.667px;
}

.cards__cta {
  padding: 0 16px;
}
.btn-brand {
  width: 100%;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border-radius: var(--radius-2);
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.28px;
  color: var(--color-text-primary);
  transition: background 1s ease, color 1s ease;
}
.start--dark .btn-brand {
  background: #363636;
  color: #ffffff;
}

/* ---------- Scenario cards (все 4) ---------- */

.sc {
  flex: 1;
  min-width: 0;
  border-radius: 16px;
  padding: 4px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background 1s ease;
}

/* backdrop-filter только для dark-состояний (rgba фон полупрозрачный) */
.sc[data-state="dark-off"],
.sc[data-state="dark-on"] {
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.sc[data-state="light-on"] {
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}



/* ---- Фон комнаты (слои с кроссфейдом) ---- */
.interactive__room {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1s ease;
}
.interactive__room.is-visible { opacity: 1; }

/* Внутренний блок: padding 8px, radius 13px, gap 20px между группами */
.sc__inner {
  position: relative;
  border-radius: 13px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow: hidden;
}

.sc__group {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Градиент через псевдоэлемент — не красит дочерние блоки */
.sc__inner::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 13px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1s ease;
}

/* ---- Фоны карточки ---- */
/* light-off: белая */
.sc[data-state="light-off"] { background: #ffffff; }
/* light-on: белая */
.sc[data-state="light-on"]  { background: #ffffff; }
/* dark-off / dark-on: стекло */
.sc[data-state="dark-off"],
.sc[data-state="dark-on"]   { background: rgba(255,255,255,0.12); }

/* ---- Градиенты inner::before (фиксированы на карточке, появляются по opacity) ---- */
/* Card 1: зелёный радиальный */
.sc--1 .sc__inner::before {
  background: radial-gradient(62% 71% at 2% -10%, rgba(55,237,30,0.27) 0%, rgba(55,237,30,0) 100%);
}
/* Card 2: фиолетовый радиальный */
.sc--2 .sc__inner::before {
  background: radial-gradient(62% 71% at 2% -10%, rgba(160,48,234,0.27) 0%, rgba(160,48,234,0) 100%);
}
/* Card 3: синий радиальный */
.sc--3 .sc__inner::before {
  background: radial-gradient(62% 71% at 2% -10%, rgba(15,82,255,0.27) 0%, rgba(15,82,255,0) 100%);
}
/* Card 4: оранжевый радиальный */
.sc--4 .sc__inner::before {
  background: radial-gradient(62% 71% at 2% -10%, rgba(204,102,0,0.27) 0%, rgba(204,102,0,0) 100%);
}

/* Градиент виден только когда карточка активна */
.sc--1[data-state="light-on"] .sc__inner::before,
.sc--2[data-state="dark-on"] .sc__inner::before,
.sc--3[data-state="dark-on"] .sc__inner::before,
.sc--4[data-state="dark-on"] .sc__inner::before {
  opacity: 1;
}

/* ---- Top row ---- */
.sc__top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Иконка: 40×40, radius 10px */
.sc__icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 1s ease;
}
.sc[data-state="light-off"] .sc__icon { background: #f4f5f6; }
.sc[data-state="light-on"]  .sc__icon { background: #ffffff; }
.sc[data-state="dark-off"]  .sc__icon,
.sc[data-state="dark-on"]   .sc__icon { background: rgba(255,255,255,0.1); }

/* Тогл: 44×24px, пилюля */
.sc__toggle {
  width: 44px;
  height: 24px;
  border-radius: 24px;
  flex-shrink: 0;
  position: relative;
  transition: background 1s ease;
  padding: 0;
}
.sc__toggle::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #ffffff;
  top: 2px;
  left: 2px;
  transition: transform 1s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}
.sc[data-state="light-off"] .sc__toggle {
  background: #c2c9d2;
}
.sc[data-state="light-on"] .sc__toggle,
.sc[data-state="dark-on"] .sc__toggle {
  background: #009e36;
}
.sc[data-state="light-on"] .sc__toggle::after,
.sc[data-state="dark-on"] .sc__toggle::after {
  transform: translateX(20px);
}
.sc[data-state="dark-off"] .sc__toggle {
  background: #363636;
}
.sc[data-state="dark-off"] .sc__toggle::after {
  background: #b7b7b7;
}

/* ---- Текст ---- */
.sc__text {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sc__title {
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.28px;
  transition: color 1s ease;
}
.sc__subtitle {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: -0.12px;
  transition: color 1s ease;
}
.sc[data-state="light-off"] .sc__title,
.sc[data-state="light-on"]  .sc__title  { color: #262626; }
.sc[data-state="dark-off"]  .sc__title,
.sc[data-state="dark-on"]   .sc__title  { color: #ffffff; }



.sc[data-state="light-off"] .sc__subtitle,
.sc[data-state="light-on"]  .sc__subtitle { color: #738295; }
.sc[data-state="dark-off"]  .sc__subtitle,
.sc[data-state="dark-on"]   .sc__subtitle { color: rgba(255,255,255,0.64); }

/* ---- Аватары: gap -7px ---- */
.sc__avatars {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
}
.sc__avatar {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  overflow: hidden;
  flex-shrink: 0;
  transition: border-color 1s ease, background 1s ease;
}
.sc__avatar:not(:last-child) { margin-right: -7px; }
.sc__avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 4px; }

.sc[data-state="light-off"] .sc__avatar,
.sc[data-state="light-on"]  .sc__avatar {
  border: 2px solid #ffffff;
  background: #f5f7fa;
}
.sc[data-state="dark-off"] .sc__avatar,
.sc[data-state="dark-on"]  .sc__avatar {
  border: 2px solid #232220;
  background: #393836;
}

/* ---- Кнопка-бейдж ---- */
.sc__btn {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  gap: 2px;
  height: 20px;
  padding: 2px 4px 2px 8px;
  border-radius: 360px;
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: -0.12px;
  white-space: nowrap;
  transition: background 1s ease, color 1s ease;
}
.sc__btn-chevron {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
.sc[data-state="light-off"] .sc__btn,
.sc[data-state="light-on"]  .sc__btn {
  background: #f0f1f4;
  color: #262626;
}
.sc[data-state="dark-off"] .sc__btn,
.sc[data-state="dark-on"]  .sc__btn {
  background: #363636;
  color: #ffffff;
}

/* ---------- App loader ---------- */
.app-loader {
  position: absolute;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  background: var(--color-page);
  opacity: 0;
  visibility: hidden;
  transition: opacity 220ms ease, visibility 220ms ease;
}

.start.is-loading .app-loader {
  opacity: 1;
  visibility: visible;
}

.start.is-loading .topline,
.start.is-loading .hero,
.start.is-loading .bottom-text,
.start.is-loading .interactive {
  opacity: 0;
}

.app-loader__spinner {
  width: 32px;
  height: 32px;
  border: 3px solid rgba(38, 38, 38, 0.12);
  border-top-color: var(--color-brand);
  border-radius: 50%;
  animation: loader-spin 760ms linear infinite;
}

@keyframes loader-spin {
  to { transform: rotate(360deg); }
}

.topline,
.hero,
.bottom-text,
.interactive {
  transition: opacity 220ms ease;
}

/* ---------- Room tags ---------- */
.room-tags {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.room-tag {
  position: absolute;
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  background: #ffffff;
  border-radius: 360px;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: -0.12px;
  color: #262626;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1.5s ease, transform 1.5s ease;
}

.room-tags.is-visible .room-tag:nth-child(1) { opacity: 1; transform: translateY(0); transition-delay: 0s; }
.room-tags.is-visible .room-tag:nth-child(2) { opacity: 1; transform: translateY(0); transition-delay: 0.3s; }
.room-tags.is-visible .room-tag:nth-child(3) { opacity: 1; transform: translateY(0); transition-delay: 0.6s; }
.room-tags.is-visible .room-tag:nth-child(4) { opacity: 1; transform: translateY(0); transition-delay: 0.9s; }

/* ---------- Bottom Sheet ---------- */

.sc__group:last-child { cursor: pointer; }

.bs-overlay {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 812px;
  z-index: 50;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: rgba(0, 0, 0, 0);
  pointer-events: none;
  overflow: hidden;
  transition: background 0.3s ease;
}
.bs-overlay.is-open {
  background: rgba(0, 0, 0, 0.64);
  pointer-events: auto;
}
@media (max-width: 600px) {
  .bs-overlay {
    position: fixed;
    inset: 0;
    height: auto;
  }
}

.bs__sheet {
  width: 100%;
  background: #ffffff;
  border-radius: 20px 20px 0 0;
  display: flex;
  flex-direction: column;
  max-height: 90vh;
  overflow: hidden;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
}
.bs-overlay.is-open .bs__sheet {
  transform: translateY(0);
}

.bs__handle {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 16px 14px;
}
.bs__drag {
  width: 52px;
  height: 4px;
  background: var(--color-border-surface);
  border-radius: 2px;
}

.bs__scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 0 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.bs__scroll::-webkit-scrollbar { display: none; }

.bs__header {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.bs__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 24px;
  line-height: 32px;
  color: var(--color-text-primary);
}
.bs__subtitle {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  line-height: 20px;
  letter-spacing: -0.32px;
  color: var(--color-text-secondary);
  height: 40px;
  overflow: hidden;
}

.bs__devices {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.bs__device {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.bs__device-img {
  width: 100%;
  height: 104px;
  border-radius: 16px;
  background: #f0f5f8;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.bs__device-img img {
  width: 72px;
  height: 72px;
  object-fit: contain;
}
.bs__badge {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 1;
  height: 20px;
  padding: 2px 8px;
  background: #ffffff;
  border-radius: 360px;
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: -0.12px;
  color: #009532;
  white-space: nowrap;
}
.bs__device-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.bs__device-name {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: -0.12px;
  color: var(--color-text-primary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 32px;
}
.bs__device-prices {
  display: flex;
  gap: 6px;
  align-items: center;
}
.bs__price {
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: -0.12px;
  color: var(--color-text-primary);
  white-space: nowrap;
}
.bs__old-price {
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: -0.12px;
  color: var(--color-text-secondary);
  white-space: nowrap;
  text-decoration: line-through;
}

.bs__footer {
  flex-shrink: 0;
  padding: 16px 16px 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.bs__primary {
  width: 100%;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-brand);
  border-radius: var(--radius-2);
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.28px;
  color: var(--color-text-inverse);
}
.bs__secondary {
  width: 100%;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-control-secondary);
  border-radius: var(--radius-2);
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.28px;
  color: var(--color-text-primary);
}

.bs__indicator {
  flex-shrink: 0;
  height: 34px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 8px;
}
.bs__indicator span {
  width: 134px;
  height: 5px;
  background: var(--color-text-primary);
  border-radius: 100px;
}

/* Dark theme */
body.dark-mode .bs__sheet   { background: #1C1B19; }
body.dark-mode .bs__drag    { background: rgba(255, 255, 255, 0.2); }
body.dark-mode .bs__title   { color: #ffffff; }
body.dark-mode .bs__subtitle { color: rgba(255, 255, 255, 0.64); }
body.dark-mode .bs__device-img { background: #2A2826; }
body.dark-mode .bs__badge   { background: rgba(255, 255, 255, 0.12); }
body.dark-mode .bs__device-name { color: #ffffff; }
body.dark-mode .bs__price   { color: #ffffff; }
body.dark-mode .bs__old-price { color: rgba(255, 255, 255, 0.64); }
body.dark-mode .bs__secondary {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}
body.dark-mode .bs__indicator span { background: #ffffff; }

/* ---------- Home indicator ---------- */
.home-indicator {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 375px;
  height: 34px;
}
.home-indicator span {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 134px;
  height: 5px;
  background: var(--color-text-primary);
  border-radius: 100px;
}
