/* Блок «Мобильная версия» (#mobilnaya). Только токены из style.css.
   Светлое окно как .site-card (цвета живут только внутри демо-окна).
   Страница внутри окна перестраивается контейнерными запросами по ширине окна. */

.mb-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 320px); gap: var(--s-5); align-items: start; }
.mb-main { min-width: 0; }

/* ---------- сцена: высота фиксирована, окно меняет только ширину ---------- */
.mb-stage { position: relative; height: 540px; display: flex; align-items: center; justify-content: center; padding: 0 36px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-xl); overflow: hidden; }
.mb-frame { position: relative; flex: none; width: 960px; height: 480px; }
.mb-win { position: absolute; left: 0; top: 0; display: flex; flex-direction: column; width: 960px; height: 480px; transform-origin: 0 0;
  background: #f4f2ee; color: #121214; border-radius: var(--r-l); overflow: hidden; container: mb / inline-size; }

/* ручка сбоку окна */
.mb-handle { position: absolute; top: 50%; right: -26px; width: 20px; height: 72px; margin-top: -36px; padding: 0; border: 0; background: none; cursor: ew-resize; touch-action: none; }
.mb-handle::before { content: ""; position: absolute; inset: -8px -6px; } /* зона нажатия шире ручки */
.mb-handle i { position: absolute; left: 6px; top: 12px; bottom: 12px; width: 8px; border-radius: 4px; background: var(--muted); transition: background var(--t-fast) var(--ease); }
.mb-handle:hover i, .mb-handle.is-drag i { background: var(--accent); }
.mb-handle:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 8px; }

/* переключатель (как .seg у тарифов, свой класс) */
.mb-ctl { display: flex; align-items: center; justify-content: space-between; gap: var(--s-2); flex-wrap: wrap; margin-top: var(--s-3); }
.mb-seg { display: inline-flex; padding: 4px; border: 1px solid var(--line); border-radius: var(--r-pill); }
.mb-seg button { border: 0; background: none; padding: 9px 18px; border-radius: var(--r-pill); color: var(--soft); font: inherit; font-size: var(--fs-small); cursor: pointer;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease); }
.mb-seg button:hover { color: var(--text); }
.mb-seg button[aria-pressed="true"] { background: var(--text); color: #0b0b0c; }
.mb-seg button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.mb-read { color: var(--muted); }

/* ---------- правая колонка ---------- */
.mb-lead { color: var(--soft); font-size: var(--fs-lead); line-height: 1.5; }
.mb-sub { margin-top: var(--s-4); color: var(--muted); }
.mb-checks { list-style: none; margin-top: var(--s-2); display: grid; gap: var(--s-3); }
.mb-checks li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 14px; align-items: start; }
.mb-ok { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--line); color: var(--muted);
  transition: background var(--t-base) var(--ease), color var(--t-base) var(--ease), border-color var(--t-base) var(--ease); }
.mb-ok svg { width: 14px; height: 14px; }
.mb-grid.is-phone .mb-ok { background: var(--accent); border-color: var(--accent); color: #0b0b0c; }
.mb-ct { color: var(--text); font-size: var(--fs-h3); font-weight: 500; letter-spacing: var(--tr-h3); line-height: 1.2; }
.mb-cd { margin-top: 6px; color: var(--soft); font-size: var(--fs-small); line-height: 1.5; }

/* ---------- демо-страница внутри окна ---------- */
.mb-addr { flex: none; display: flex; align-items: center; gap: 14px; padding: 10px 14px; background: #e6e3dd; }
.mb-dots { display: flex; gap: 6px; flex: none; }
.mb-dots i { width: 10px; height: 10px; border-radius: 50%; background: #c9c5be; }
.mb-url { color: #7a766f; font: 12px/1.3 var(--mono); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.mb-p { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; }
.mb-p::-webkit-scrollbar { display: none; }
.mb-nav { display: flex; align-items: center; gap: 24px; padding: 16px 28px; border-bottom: 1px solid #e6e3dd; }
.mb-logo { display: inline-flex; align-items: center; gap: 8px; font: 500 16px/1 var(--sans); letter-spacing: -.02em; white-space: nowrap; }
.mb-logo i { width: 12px; height: 12px; border-radius: 50%; background: var(--accent); }
.mb-links { display: flex; gap: 20px; margin-left: auto; color: #5f5b55; font-size: 14px; }
.mb-navbtn { padding: 9px 16px; border-radius: var(--r-pill); background: #121214; color: #f4f2ee; font-size: 13px; line-height: 1; white-space: nowrap; }
.mb-burger { display: none; width: 22px; flex-direction: column; gap: 4px; margin-left: auto; }
.mb-burger i { display: block; height: 2px; border-radius: 1px; background: #121214; }

.mb-hero { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 28px; align-items: center; padding: 32px 28px 20px; }
.mb-eyebrow { color: #8a857c; }
.mb-title { margin-top: 10px; font: 500 38px/1.05 var(--sans); letter-spacing: -.04em; }
.mb-text { margin-top: 14px; max-width: 34ch; color: #5f5b55; font-size: 15px; line-height: 1.5; }
.mb-btn { display: inline-grid; place-items: center; padding: 13px 24px; border-radius: var(--r-pill); background: var(--accent); color: #0b0b0c; font: 500 15px/1 var(--sans); white-space: nowrap; }
.mb-btn--page { margin-top: 20px; }
.mb-art { display: flex; align-items: flex-end; justify-content: center; gap: 12px; height: 190px; border-radius: 20px; background: #e6e3dd; padding: 24px; }
.mb-art i { flex: 1; max-width: 56px; border-radius: 28px 28px 14px 14px; background: #121214; }
.mb-art i:nth-child(1) { height: 62%; background: #c9c5be; }
.mb-art i:nth-child(2) { height: 88%; background: var(--accent); }
.mb-art i:nth-child(3) { height: 74%; }

.mb-svc { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; padding: 8px 28px 28px; }
.mb-card { background: #fff; border: 1px solid #e6e3dd; border-radius: 12px; padding: 16px; }
.mb-card p { font: 500 15px/1.25 var(--sans); letter-spacing: -.02em; }
.mb-card span { display: block; margin-top: 6px; color: #8a857c; font-size: 13px; line-height: 1.4; }

.mb-cta { display: none; flex: none; padding: 12px 16px 16px; background: #f4f2ee; border-top: 1px solid #e6e3dd; }
.mb-cta .mb-btn { width: 100%; padding: 18px 24px; font-size: 17px; }

/* планшет */
@container mb (max-width: 639px) {
  .mb-links { display: none; }
  .mb-navbtn { margin-left: auto; }
  .mb-burger { display: flex; margin-left: 0; }
  .mb-nav { gap: 16px; padding: 14px 22px; }
  .mb-hero { padding: 26px 22px 16px; gap: 20px; }
  .mb-title { font-size: 31px; }
  .mb-art { height: 160px; padding: 20px; }
  .mb-svc { padding: 8px 22px 24px; gap: 10px; }
  .mb-card { padding: 14px; }
}
/* телефон */
@container mb (max-width: 479px) {
  .mb-navbtn { display: none; }
  .mb-burger { margin-left: auto; }
  .mb-nav { padding: 14px 18px; }
  .mb-hero { grid-template-columns: minmax(0, 1fr); gap: 16px; padding: 20px 18px 8px; }
  .mb-title { font-size: 30px; }
  .mb-text { font-size: 16px; }
  .mb-btn--page { display: none; }
  .mb-art { order: -1; height: 84px; padding: 14px 20px 0; gap: 10px; }
  .mb-svc { grid-template-columns: minmax(0, 1fr); gap: 8px; padding: 12px 18px 20px; }
  .mb-card { padding: 14px 16px; }
  .mb-card p { font-size: 17px; }
  .mb-card span { font-size: 14px; }
  .mb-cta { display: flex; }
}

/* ---------- адаптив страницы ---------- */
@media (max-width: 960px) {
  .mb-grid { grid-template-columns: minmax(0, 1fr); gap: var(--s-4); }
  .mb-lead { max-width: 640px; }
  .mb-checks { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .mb-checks li { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .mb-sub { margin-top: var(--s-3); }
}
@media (max-width: 600px) {
  /* телефон: окно с переключателем и три пункта в одну строку каждый, без пояснений */
  #mobilnaya .sec__head { margin-bottom: var(--s-3); }
  .mb-grid { gap: var(--s-2); }
  .mb-lead, .mb-sub, .mb-cd, .mb-read { display: none; }
  .mb-stage { height: 340px; padding: 0 12px; }
  .mb-handle { display: none; } /* на телефоне окно меняет только переключатель */
  .mb-ctl { margin-top: var(--s-1); }
  .mb-seg { display: flex; width: 100%; }
  .mb-seg button { flex: 1; min-height: 44px; padding: 9px 6px; }
  .mb-checks { grid-template-columns: minmax(0, 1fr); margin-top: 0; gap: var(--s-1); }
  .mb-checks li { grid-template-columns: 28px minmax(0, 1fr); gap: 12px; align-items: center; min-height: 32px; }
  .mb-ct { font-size: var(--fs-lead); }
}
@media (prefers-reduced-motion: reduce) {
  .mb-handle i, .mb-ok, .mb-seg button { transition: none; }
}
