/* Мобильные доработки: режим приложения, безопасные зоны, крупные зоны нажатия. */
html { -webkit-tap-highlight-color: transparent; overscroll-behavior-y: none; }
body { padding-bottom: env(safe-area-inset-bottom, 0px); }
@media (max-width: 760px) {
  input, select, textarea { font-size: 16px; } /* без авто-зума iOS при фокусе */
  .btn, button, .chip, .auth-btn { min-height: 44px; }
  .dots button { min-height: 0; height: 6px; }
  .dots { left: 0; right: 0; bottom: 18px; justify-content: center; }
  .slide { padding: 16px 16px 40px; align-items: stretch; }
  .slide.has-img > div:first-child { max-width: none; justify-self: stretch; display: flex; flex-direction: column; justify-content: center; }
  .top { padding-top: env(safe-area-inset-top, 0px); }
  dialog { width: 100vw; max-width: 100vw; margin: auto 0 0; border-radius: 20px 20px 0 0; max-height: 92vh; }
  .toast { max-width: calc(100vw - 32px); }
}
@media (display-mode: standalone) {
  body { user-select: none; -webkit-user-select: none; }
  input, textarea { user-select: text; -webkit-user-select: text; }
}

/* Юридические страницы */
.legal-page { padding-block: 24px 60px; max-width: 820px; }
.legal-page h1 { font-size: clamp(24px, 5vw, 34px); margin: 12px 0 8px; }
.legal-page .lg { display: grid; gap: 18px; margin: 18px 0 0; padding: 0; list-style: none; counter-reset: lg; }
.legal-page .lg > li { counter-increment: lg; }
.legal-page .lg h2 { font-size: 18px; margin: 0 0 6px; }
.legal-page .lg h2::before { content: counter(lg) ". "; color: var(--accent); }
.legal-page p { color: #d0d0d0; margin: 6px 0; }
.legal-page a { color: var(--accent); text-decoration: underline; }

/* Переключатель страны в шапке */
.region-sel { margin-left: auto; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); color: var(--text); padding: 0 8px; font-size: 14px; max-width: 150px; }
.region-sel + #meBox { margin-left: 0; }

/* Внутри Telegram Mini App: вместо нижней панели заказа работает нативная главная кнопка */
/* нижняя панель оплаты в Mini App теперь наша (нативную кнопку Telegram не используем) */
.tg-app.has-mbar footer, body.tg-app footer { padding-bottom: 80px; }
