/* Общие поправки к готовым стилям сайта.
   Отдельный файл по той же причине, что events.css, article.css и blog.css:
   style.css собирается из LESS-проекта (d:\my_projects\helpingersLESS),
   и правки в нём затрутся при следующей сборке.

   Подключается первым из наших файлов - чтобы дальше его при желании можно
   было перебить. */

/* Атрибут hidden должен скрывать элемент - но скрывает он через display: none
   в стилях браузера, а любое собственное правило с display это перебивает.
   В style.css такие есть: .button { display: block }, .pagination { display: flex }.
   Из-за этого кнопка «Показать ещё» оставалась видимой и до запуска скрипта,
   и после того, как список кончился.

   !important здесь уместен: правило служебное, и элемент с hidden не должен
   показываться ни при каких других стилях. Так же это сделано в normalize.css. */
[hidden] {
  display: none !important;
}

/* Кнопки и поля по умолчанию берут системный шрифт браузера (Arial),
   а не шрифт страницы. Без этого меню категорий, выбор города и «Войти»
   оставались в Arial, когда весь сайт перешёл на Open Sans (web 2.170.0).
   Только семейство: размер и насыщенность задают сами компоненты. */
button,
input,
select,
textarea {
  font-family: inherit;
}

/* Окно регистрации: форма длиннее, чем у входа, поэтому согласию с правилами
   нужен отступ снизу - иначе кнопка налезает на последнюю строку текста. */
#signup-popup .input-form__agree-terms {
  display: block;
  margin: 4px 0 16px;
}

#signup-popup .button {
  display: block;
  width: 100%;
}

#signup-popup .input-form__error {
  display: block;
  min-height: 0;
}

/* Текст ошибки под полем - в потоке, а не position: absolute; bottom: -18px (style.css)
   (web 2.170.16, просьба автора). Абсолютная ошибка места не занимала: прилипала к следующему
   элементу («Введите свой пароль!» вплотную к «Забыли пароль?»), а в две строки росла вверх
   и залезала в само поле. Теперь раздвигает форму, отступ сверху 4px, пустая - не занимает места. */
.input-form__error {
  position: static;
  display: block;
  margin: 4px 0 0 10px;
  color: #d14343; /* как рамка поля (палитра 2.170.0); в style.css было #fa5d2d (web 2.170.32) */
}

.input-form__error:empty {
  display: none;
}

/* и снизу воздух: под ошибкой бывает подсказка («До 2000 символов») или ссылка («Забыли пароль?») */
.input-form__error:not(:empty) {
  margin-bottom: 8px;
}

/* «Выберите оценку!» - под звёздами, а не над полем отзыва: у поля при вводе всплывает подпись
   (.float-label, 19px над полем) и ложилась на ошибку (web 2.170.17, скриншот автора).
   У звёзд снизу 24px и пустое место внутри блока (style.css) - ошибку подтягиваем к ним,
   а до поля оставляем 40px: подпись поля при вводе встаёт в 19px над ним. */
/* Поле отзыва - как остальные поля форм (контакты): в style.css у него своя голубая рамка,
   прозрачный фон и 12px снизу - и это перебивало красную подсветку ошибки
   (.input-form__input--error стоит в style.css раньше), а текст ошибки уезжал от поля
   (web 2.170.19, просьба автора). */
.rating-form__textarea {
  margin-bottom: 0;
  border-color: #e4e4e4;
  background-color: #fafafa;
}

/* Всплывающая подпись поля (.float-label) встаёт на 19px над полем. Где форма идёт сразу под
   заголовком страницы (контакты, смена имени, жалоба…), отступ заголовка 20px - подпись прилипала
   к нему (1px). +16px. Над полем отзыва - строка звёзд, там было 5px на компьютере - +8px
   (web 2.170.20, просьба автора). */
.input-page__title + .input-page__form {
  padding-top: 16px; /* padding, не margin: margin схлопывался с отступом заголовка */
}

.rating-form__field {
  margin-top: 8px;
}

/* Поле с ошибкой - только красная рамка, фон обычный (web 2.170.32, просьба автора; в style.css было
   2px #e01e047c + розовый фон). 2px = рамка 1px + внутренняя тень 1px: поле не сдвигается на 1px. */
.input-form__input--error,
.rating-form__textarea.input-form__input--error {
  border: 1px solid #d14343;
  box-shadow: inset 0 0 0 1px #d14343;
  background-color: #fafafa;
}

.rating-form__star-error:not(:empty) {
  margin-top: -32px;
  margin-bottom: 40px;
  pointer-events: none; /* заходит на пустой низ строки звёзд - касания звёзд не перехватывает */
}

/* Сайт и соцсети на странице объявления: длинный адрес сайта или ссылка
   на Facebook переносятся, а не вылезают за край на телефоне */
.item-page__link--contact {
    overflow-wrap: anywhere;
}

/* Телефоны и адреса в описании бизнеса (core/text_links.php): наш голубой,
   без подчёркивания, обычной толщины - текст не «прыгает» */
.text-link {
  color: #3ebde6;
  text-decoration: none;
}

.text-link:hover {
  color: #1f8db3;
}

/* Описание бизнеса - текст владельца, разложенный userTextHtml() (web 2.146.0):
   абзацы и списки с тем же шагом, что у .desc; длинный адрес сайта переносится */
.user-text p,
.user-text ul,
.user-text ol {
  margin: 0 0 12px;
}

.user-text > :last-child {
  margin-bottom: 0;
}

.user-text ul,
.user-text ol {
  padding-left: 20px;
}

.user-text ul {
  list-style: disc;
}

.user-text ol {
  list-style: decimal;
}

.user-text a {
  overflow-wrap: anywhere;
}

/* Визитка на странице объявления - как в приложении: мягкая тень снизу
   (SwiftUI .shadow(opacity 0.15, radius 4, y 2)) и скругление 12 */
.item-page__img {
  border-radius: 12px;
  -webkit-box-shadow: 0 2px 6px rgba(30, 50, 90, 0.12);
          box-shadow: 0 2px 6px rgba(30, 50, 90, 0.12);
}

/* Пометка «Рекомендуем» на карточке в списке подкатегории
   (настройка «Рекомендуемые наверху своей подкатегории» в админке) */
.items-list__badge {
  display: inline-block;
  margin-bottom: 8px;
  padding: 2px 10px;
  border-radius: 12px;
  background-color: #3ebde6;
  color: #fff;
  font-size: 12px;
  line-height: 18px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

/* Правка бизнеса / отзыва на проверке (форма правки и кабинет) */
.item-revision-note__form {
  margin: 8px 0 0;
}

.item-revision-note--rejected {
  border-left-color: #e8a33d;
}

.user_addings__revision {
  margin: 6px 0 0;
  font-size: 14px;
  line-height: 20px;
  color: #5b6168;
}

.user_addings__revision--rejected {
  color: #b5651d;
}


/* Аватар пользователя: аккаунт и отзывы (core/user_avatar.php) */
.user-avatar {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  object-fit: cover;
  background-color: #dbe5eb;
  color: #1c1c1c;
  font-weight: 600;
}

.user-avatar--xs {
  width: 32px;
  height: 32px;
  font-size: 14px;
}

.user-avatar--sm {
  width: 40px;
  height: 40px;
  font-size: 16px;
}

.user-avatar--lg {
  width: 96px;
  height: 96px;
  font-size: 38px;
}

/* рамка у картинки: на белом фоне иначе не видно края круга */
img.user-avatar,
.user-avatar-page .user-avatar-page__preview {
  box-sizing: border-box;
  border: 1px solid #dcdfe3;
}

.user-avatar--empty {
  background-color: #e6f6fc;
  color: #1f8db3;
}

.ratings-list__author-block {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ratings-list__author-block .ratings-list__author {
  margin: 0;
}

.user-avatar--xl {
  width: 160px;
  height: 160px;
  font-size: 64px;
}

/* аккаунт: кружок аватара со значком карандаша и ссылка «Изменить» */
.user-avatar-account {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 0 0 30px;
}

.user-avatar-account__link {
  position: relative;
  display: inline-flex;
  border-radius: 50%;
  text-decoration: none;
}

.user-avatar-account__link:focus-visible {
  outline: 2px solid #3ebde6;
  outline-offset: 3px;
}

.user-avatar-account__icon {
  position: absolute;
  right: 2px;
  bottom: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 2px solid #ffffff;
  border-radius: 50%;
  background-color: #3ebde6;
  color: #ffffff;
  transition: background-color 0.15s;
}

.user-avatar-account__link:hover .user-avatar-account__icon {
  background-color: #1f8db3;
}

/* страница аватара: всё по центру столбиком, «В аккаунт» - слева вверху */
.user-avatar-page__back {
  display: inline-block;
  margin: 0 0 24px;
}

.user-avatar-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.user-avatar-page__body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.user-avatar-page__upload {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

/* у общей .button отступ auto - здесь кнопка стоит сразу за полем файла */
.user-avatar-page__upload .button {
  margin: 0;
  width: 250px;
}

.user-avatar-page__field {
  width: auto;
  margin: 0;
}

/* кружок аватара: превью выбранного фото ложится поверх текущего */
.user-avatar-page__picture {
  position: relative;
  flex: none;
  width: 160px;
  height: 160px;
}

.user-avatar-page .user-avatar-page__preview {
  position: absolute;
  inset: 0;
  width: 160px;
  max-height: none;
  height: 160px;
  margin: 0;
  border-radius: 50%;
  overflow: hidden;   /* картинка внутри - тоже кругом */
}

.user-avatar-page .user-avatar-page__preview:empty {
  display: none;
}

.user-avatar-page .user-avatar-page__preview > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* окно обрезки аватара (assets/js/avatar-crop.js): тёмное поле во всю ширину
   страницы (с обычными полями по краям), посередине круг 280px - будущий аватар.
   Колонка и форма - на всю ширину, иначе они ужимаются по кнопкам (250px) */
.user-avatar-page__body,
.user-avatar-page__upload {
  width: 100%;
}

.avatar-crop {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-bottom: 20px;   /* кнопки - не вплотную к полю */
}

.avatar-crop[hidden] {
  display: none;
}

.avatar-crop__stage {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  max-height: 420px;
  border-radius: 12px;
  overflow: hidden;
  background-color: #1f2328;
  cursor: grab;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

/* на компьютере во всю ширину не нужно - поле пошире круга */
@media (min-width: 640px) {
  .avatar-crop__stage {
    width: 560px;
    aspect-ratio: auto;
    height: 420px;
  }
}

.avatar-crop__stage:active {
  cursor: grabbing;
}

.avatar-crop__stage:focus-visible {
  outline: 2px solid #1f8db3;
  outline-offset: 2px;
}

.avatar-crop__img {
  position: absolute;
  top: 0;
  left: 0;
  max-width: none;
  transform-origin: 0 0;
  pointer-events: none;
}

.avatar-crop__mask {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(280px, calc(100% - 32px));
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.55);
  border: 2px solid rgba(255, 255, 255, 0.9);
  box-sizing: border-box;
  pointer-events: none;
}

/* сообщение «Аватар обновлён»: плавно гаснет (assets/js/avatar-crop.js) */
.user-avatar-page__message {
  transition: opacity 0.4s ease;
}

.user-avatar-page__message--hide {
  opacity: 0;
}

/* после «Применить»: тап по кружку с новым фото - вернуться к обрезке */
.user-avatar-page__picture--editable {
  cursor: pointer;
}

.user-avatar-page__delete {
  color: #b5651d;
  font-size: 15px;
}



/* «Сайт закрыт от поисковиков» (core/site_noindex.php): красной линии по верху шапки на сайте больше нет
   (web 2.170.31, просьба автора). Закрытие работает как раньше - заголовок X-Robots-Tag и метатег noindex;
   напоминание - полоса в админке (min/, .adm-noindex-bar). */

/* на печати плашки нет - иначе тёмная полоса сверху листа (web 2.89.1, отчёт по работе на dev).
   Фон body тёмный (цвет подвала) - сквозь отступ над карточкой он печатался полосой сверху (web 2.89.2, прод) */
@media print {
  body {
    background: #ffffff !important;
  }
}


/* Регистрация: подпись «Выберите ваш город» над списком - отдельной строкой с отступом */
.input-form__select-label {
  display: block;
  margin-bottom: 12px;
}


/* «Активировать» в плашке «аккаунт не активирован» (страница бизнеса) -
   небольшая капсула, открывает окно ввода кода */
.activation-inline-button {
  /* отдельной строкой под текстом, по левому краю */
  display: block;
  width: fit-content;
  margin: 10px 0 2px;
  padding: 3px 14px;
  border-radius: 999px;
  background-color: #3ebde6;
  font-size: 14px;
  line-height: 20px;
  font-weight: 600;
  color: #ffffff;
  text-decoration: none;
  vertical-align: middle;
}

.activation-inline-button:hover {
  background-color: #1f8db3;
  color: #ffffff;
}

/* звёзды вверху страницы бизнеса - вся область ведёт к отзывам (rating.js) */
.show-rating__block--to-reviews {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* «Рекомендуем» в подкатегории (view/catalog/v_subcategory.php): рекомендуемые
   карточки - в общей рамке с заголовком, как в приложении */
.items-list__featured-group {
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 36px;
  padding: 16px 16px 0;
  border: 2px solid #8fd3ec;
  border-radius: 12px;
}

/* подпись, а не заголовок: как «Свежее в блоге» на главной (web 2.170.9, просьба автора -
   было 20px жирным, как название визитки, и прижато к рамке). Слева - по тексту карточек
   (padding .items-list__item--wrapper: 20px, на телефоне 16px), снизу отступа нет:
   у карточки свой сверху, так сверху и снизу подписи поровну. */
.items-list__featured-title {
  margin: 4px 0 0 20px;
  font-size: 13px;
  line-height: 20px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #3ebde6;
}

@media (max-width: 1024px) {
  .items-list__featured-title {
    margin-left: 16px;
  }
}

@media (max-width: 1024px) {
  .items-list__featured-group {
    margin: 4px 4px 16px;
    padding: 16px 8px 4px;
  }
}

/* внутри рамки - без своих рамок у карточек, между ними тонкая линия, как в
   приложении; на десктопе две колонки - линии нет у первого ряда */
.items-list__featured-list .items-list__item {
  margin: 0;
  border: 0;
  border-top: 1px solid #e3e8ef;
  border-radius: 0;
}

.items-list__featured-list .items-list__item:nth-child(-n+2) {
  border-top: 0;
}

.items-list__featured-group {
  padding-bottom: 4px;
}

@media (max-width: 1024px) {
  .items-list__featured-list .items-list__item {
    margin: 0;
  }

  .items-list__featured-list .items-list__item:nth-child(2) {
    border-top: 1px solid #e3e8ef;
  }
}

/* десктоп, две колонки: между ними - такая же линия по вертикали */
@media (min-width: 1025px) {
  .items-list__featured-list .items-list__item {
    width: 50%;
    box-sizing: border-box;
  }

  .items-list__featured-list .items-list__item:nth-child(even) {
    border-left: 1px solid #e3e8ef;
  }
}

/* Иконки главных категорий на странице «Категории» (view/v_menu.php,
   core/category_icons.php) - голубые, как в приложении */
.category-page__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 28px;
  width: 28px;
  height: 24px;
  margin-right: 14px;
  color: #3ebde6;
}

/* размер явный: у SVG иконок нет width/height, только viewBox - с одним
   max-width Safari сжимал их до нуля (Chrome растягивал, поэтому не видели) */
.category-page__icon svg {
  display: block;
  width: 24px;
  height: 22px;
  fill: currentColor;
}

/* Подпись поля над рамкой (assets/js/float-labels.js): текст из placeholder,
   видна при фокусе и пока поле заполнено. Стоит целиком над полем, а не на
   рамке: на iPhone обводка фокуса шире рамки и перекрывала подпись. Место есть -
   под полем 35px отступа (снизу у предыдущего поля - только текст ошибки). */
.float-label {
  position: absolute;
  top: -19px;
  left: 4px;
  max-width: calc(100% - 8px);
  padding: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 11px;
  line-height: 15px;
  font-weight: 600;
  color: #757575;           /* как placeholder полей - см. ниже */
  pointer-events: none;
  opacity: 0;
  transform: translateY(5px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  z-index: 2;
}

input:focus + .float-label,
textarea:focus + .float-label,
input:not(:placeholder-shown) + .float-label,
textarea:not(:placeholder-shown) + .float-label {
  opacity: 1;
  transform: translateY(0);
}

/* placeholder полей форм - явным цветом, одинаковым во всех браузерах (Safari
   по умолчанию светлее Chrome), и тем же, что у подписи над полем */
.input-form__field input::placeholder,
.input-form__field textarea::placeholder {
  color: #757575;
  opacity: 1;               /* Firefox по умолчанию приглушает placeholder */
}

@media (prefers-reduced-motion: reduce) {
  .float-label {
    transition: none;
  }
}

/* в фокусе подпись уже над полем - placeholder внутри прячем (только цветом:
   :placeholder-shown продолжает работать, логика подписи не меняется) */
input[data-float-label="1"]:focus::placeholder,
textarea[data-float-label="1"]:focus::placeholder {
  color: transparent;
}

/* Обязательное поле (float-labels.js): красная звёздочка - в подписи над полем
   и в пустом поле сразу за текстом placeholder (.req-mark, место считает скрипт) */
.req-star {
  color: #fa5d2d;
}

.req-mark {
  position: absolute;
  display: none;
  font-weight: 700;
  color: #fa5d2d;
  pointer-events: none;
  z-index: 2;
}

input:placeholder-shown:not(:focus) ~ .req-mark,
textarea:placeholder-shown:not(:focus) ~ .req-mark {
  display: block;
}

/* «Сайт и соцсети» в форме бизнеса - раскрывающийся блок
   (view/catalog/v_item_contacts_fields.php) */
.contacts-toggle {
  margin: 0 0 32px;
  border: 1px solid #e4e4e4;
  border-radius: 6px;
  background-color: #ffffff;
}

.contacts-toggle__summary {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 16px;
  list-style: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.contacts-toggle__summary::-webkit-details-marker {
  display: none;
}

/* стрелка справа: вниз - свёрнуто, вверх - открыто */
.contacts-toggle__summary::after {
  content: "";
  width: 8px;
  height: 8px;
  margin-left: auto;
  border-right: 2px solid #3ebde6;
  border-bottom: 2px solid #3ebde6;
  transform: translateY(-3px) rotate(45deg);
  transition: transform 0.15s;
}

.contacts-toggle[open] .contacts-toggle__summary::after {
  transform: translateY(2px) rotate(-135deg);
}

.contacts-toggle__title {
  font-size: 15px;
  line-height: 22px;
  font-weight: 700;
  color: #1c1c1c;
}

.contacts-toggle__hint {
  font-size: 13px;
  line-height: 18px;
  color: #757575;
}

.contacts-toggle__body {
  padding: 24px 16px 0;   /* место над первым полем - для подписи (float-label) */
}

/* Хлебные крошки - одной строкой, длинная цепочка листается пальцем
   (scrollbar скрыт). Скрипт (script.js) прокручивает к концу - видна текущая
   страница - и помечает обрезанные края: там текст мягко затухает. */
.breadcrumbs__list {
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 2px 0;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.breadcrumbs__list::-webkit-scrollbar {
  display: none;
}

.breadcrumbs__item {
  flex: 0 0 auto;
  white-space: nowrap;
}

.breadcrumbs__list.has-left {
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 28px);
          mask-image: linear-gradient(to right, transparent 0, #000 28px);
}

.breadcrumbs__list.has-right {
  -webkit-mask-image: linear-gradient(to left, transparent 0, #000 28px);
          mask-image: linear-gradient(to left, transparent 0, #000 28px);
}

.breadcrumbs__list.has-left.has-right {
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 28px, #000 calc(100% - 28px), transparent 100%);
          mask-image: linear-gradient(to right, transparent 0, #000 28px, #000 calc(100% - 28px), transparent 100%);
}

/* плавное раскрытие <details data-smooth-details> (script.js) */
[data-smooth-panel] {
  box-sizing: border-box;
  overflow: hidden;
}

.smooth-panel--animating {
  transition: height 0.3s ease, opacity 0.3s ease;
}

/* Подсказки при вводе в поиск (assets/js/search-suggest.js): список под полем
   в шапке и на странице поиска. Форма поиска - position: relative. */
.search-suggest {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 30;
  box-sizing: border-box;
  max-height: min(70vh, 460px);   /* на телефоне - точнее, по видимой части (search-suggest.js) */
  overflow-y: auto;
  padding: 8px 0;
  border: 1px solid #e3e8ef;
  border-radius: 12px;
  background-color: #ffffff;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.04);
  text-align: left;
}

.search-suggest[hidden] {
  display: none;
}

.search-suggest__head {
  padding: 8px 14px 4px;
  font-size: 11px;
  line-height: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #8a8f98;
}

.search-suggest__row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  color: #1c1c1c;
  text-decoration: none;
}

.search-suggest__row:hover,
.search-suggest__row.is-active {
  background-color: #eef8fc;
}

.search-suggest__icon {
  flex: 0 0 42px;
  height: 24px;
  border-radius: 4px;
  background-color: #e9f7fc;
  overflow: hidden;
}

.search-suggest__icon img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* у категории вместо картинки - голубая «папка» */
.search-suggest__row--category .search-suggest__icon {
  flex-basis: 24px;
  background: #e9f7fc url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233ebde6' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 7h6l2 2h10v10H3z'/%3E%3C/svg%3E") center / 16px no-repeat;
}

/* бизнес без картинки - значок здания, как в приложении */
.search-suggest__row--item .search-suggest__icon:empty {
  background: #e9f7fc url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233ebde6' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 21V3h10v18M15 9h4v12M3 21h18M8 7h1M11 7h1M8 11h1M11 11h1M8 15h1M11 15h1M10 21v-3'/%3E%3C/svg%3E") center / 18px no-repeat;
}

/* иконка раздела (category.web_icon) вместо «папки»: SVG маской, цвет - фоном */
.search-suggest__row--category .search-suggest__icon--glyph {
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: none;
}

.search-suggest__glyph {
  width: 15px;
  height: 15px;
  background-color: #3ebde6;
  -webkit-mask: var(--icon) center / contain no-repeat;
  mask: var(--icon) center / contain no-repeat;
}

.search-suggest__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.search-suggest__title {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 15px;
  line-height: 20px;
  font-weight: 600;
}

.search-suggest__title mark {
  background: none;
  color: #1f8db3;
}

.search-suggest__sub {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 12px;
  line-height: 16px;
  color: #8a8f98;
}

/* Плашка «Ваш город - Майами?» после определения города по IP
   (core/city_detect.php, assets/js/city-popup.js) - карточка внизу экрана */
/* «Вашего города нет в списке?» в окне выбора города (web 2.66.0, controller/c_city_request.php) */
.city-request {
  max-width: 350px;
  margin: 24px auto 0;
  text-align: center;
}

.city-request__toggle {
  padding: 4px 0;
  border: none;
  background: none;
  font-size: 15px;
  color: #3ebde6;
  text-decoration: underline;
  cursor: pointer;
}

.city-request__form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 12px;
  text-align: left;
}

.city-request__form[hidden] {
  display: none;
}

.city-request__hint {
  margin: 0;
  font-size: 14px;
  line-height: 20px;
  color: #555555;
}

.city-request__input {
  width: 100%;
  box-sizing: border-box;
}

.city-request__button {
  padding: 12px 24px;
  border: 1px solid #3ebde6;
  border-radius: 999px;
  background: #3ebde6;
  font-size: 16px;
  color: #ffffff;
  cursor: pointer;
}

.city-request__button:disabled {
  opacity: 0.6;
  cursor: default;
}

.city-request__message {
  margin: 0;
  font-size: 14px;
  line-height: 20px;
}

.city-request__message--error {
  color: #d14343;
}

.city-request__done {
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 22px;
  color: #1c1c1c;
}

/* до ответа /city_detect плашка скрыта (assets/js/city-popup.js) */
.city-detect[hidden] {
  display: none;
}

.city-detect {
  position: fixed;
  left: 50%;
  bottom: 20px;
  z-index: 900;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px 12px;
  width: max-content;
  max-width: calc(100% - 32px);
  padding: 16px 20px;
  transform: translateX(-50%);
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.04);
  font-size: 16px;
  line-height: 22px;
  color: #1c1c1c;
  box-sizing: border-box;
}

/* телефон: выше нижней панели Safari - она выезжает при касании у нижнего края,
   и карточка у самого низа отскакивала из-под пальца */
@media (max-width: 767px) {
  .city-detect {
    bottom: calc(90px + env(safe-area-inset-bottom, 0px));
  }
}

.city-detect__text {
  margin-right: 4px;
}

.city-detect__btn {
  padding: 8px 16px;
  border: 1px solid #3ebde6;
  border-radius: 999px;
  background-color: #ffffff;
  color: #3ebde6;
  font: inherit;
  cursor: pointer;
}

.city-detect__btn--yes {
  background-color: #3ebde6;
  color: #ffffff;
}

/* Кнопки - «пилюлей», одинаково по всему сайту (web 2.60.4, просьба автора; образец -
   «Создать бесплатно»). Здесь, а не в style.css: тот собирается из LESS и правку затрёт.
   Остальные кнопки (est-btn, блог, работа, аккаунт) - 999px прямо в своих файлах. */
.button,
.input-form__file--button,
.city-popup__button,
.city-popup__top-button,
.city-popup__confirm-btn {
  border-radius: 999px;
}

/* Скругления по единой шкале (web 2.170.1, выбор автора): мелкие элементы - 6px,
   карточки и окна - 12px, кнопки - 999px (выше). Здесь - правила из style.css
   (там 3-10px вразнобой); в остальных файлах значения поправлены на месте. */
.input-form__input,
.input-form__textarea,
.input-form__select,
.search__input,
.search-page__input,
.nav__link--cat,
.categories-menu__button,
.category-page__button,
.pagination__link,
.city-popup__link,
.input-form__file--preview,
.input-form__file--exist,
.items-list__img,
.items-list__no-img,
.similar__img,
.slider-similar__img-wrapper,
.user_addings__img,
.user_reviews__img,
.user-edit-categories__item,
.user-edit-categories__main-category-subtitle,
.user-edit-categories__img {
  border-radius: 6px;
}

.search__button,
.search-page__button {
  border-radius: 0 6px 6px 0;
}

/* Пагинация и ссылка инфо-страницы - фирменные цвета вместо отдельного синего
   #4192ef / #222161 из style.css (web 2.170.2, просьба автора; так же в events.css). */
.pagination__link {
  border-color: rgba(62, 189, 230, 0.5);
}

.pagination__link:hover,
.pagination__link--active {
  background-color: #3ebde6;
}

.pagination__text {
  color: #1c1c1c;
}

.info-page__link {
  color: #3ebde6;
}

/* «Позвонить» / «На карте» в списке визиток - чуть шире (web 2.170.10, просьба автора;
   в style.css 60px). Кнопок у визитки не больше двух: 2 × 72 + 12 помещается и на 360px. */
.items-list__button {
  width: 72px;
}

/* «Загрузить»: поверх кнопки лежит прозрачный input[type=file] (style.css), а кнопка под ним ничего
   не делает. Поле было 250x37, кнопка - 250x46: тап в нижнюю полосу попадал мимо, файл выбирался
   «со второго раза» (web 2.170.12, просьба автора). Высота у обоих одна и та же - 48px. */
.input-form__file--button {
  height: 48px;
  padding: 0;
  line-height: 48px;
}

.input-form__file {
  height: 48px;
}

/* web 2.170.14: «кнопка» - <label for> поля выбора файла, касания ловит она, а не прозрачное поле.
   На iPhone после закрытия окна выбора касанием мимо повторное касание поля (2.170.12) и вызов
   input.click() из скрипта (2.170.13) окно больше не открывали; label Safari передаёт полю сам.
   У label нет раскладки кнопки по умолчанию - задаём. */
.input-form__file {
  pointer-events: none;
}

label.input-form__file--button {
  display: inline-block;
  box-sizing: border-box;
  text-align: center;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.items-list__item,
.goals-block__item,
.categories-block__item,
.slider-similar__item,
.alert-info,
.popup__wrapper,
.header__login-popup--popup_content,
.city-popup__popup {
  border-radius: 12px;
}

/* Сохранённые визитки: «Убрать» - корзиной справа по центру строки (web 2.62.2, просьба автора).
   Последний элемент flex-строки .user_addings__item-wrapper (style.css). */
.user_addings__remove {
  flex: 0 0 auto;
  align-self: center;
  margin: 0 0 0 auto;
  padding-left: 12px;
}

.user_addings__remove-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #d14343;
  cursor: pointer;
}

.user_addings__remove-btn:hover,
.user_addings__remove-btn:focus-visible {
  background: rgba(209, 67, 67, 0.1);
}

/* Рейтинг под визиткой в «Сохранённых» (web 2.62.4): у .show-rating__block--sm высота 15-18px, звёзды крупнее
   и при выравнивании по низу вылезали вверх на картинку - раньше их отодвигала высокая колонка с «Убрать» */

.user_addings__list--saved .show-rating__block--sm {
  height: auto;
  margin-top: 10px;
  align-items: center;
}

/* Курсор-«рука» на всём, что нажимается (web 2.62.5, просьба автора). Метки - только у галочек и
   переключателей (у текстового поля клик по подписи просто ставит курсор в поле). Неактивные - без руки.
   Отдельные страницы документа (view/estimator/v_public*.php, v_preview_error.php) - то же в своих <style>. */
a[href],
button:not(:disabled),
[role="button"],
summary,
select:not(:disabled),
input[type="checkbox"]:not(:disabled),
input[type="radio"]:not(:disabled),
input[type="submit"]:not(:disabled),
input[type="button"]:not(:disabled),
input[type="reset"]:not(:disabled),
input[type="file"]:not(:disabled),
input[type="color"]:not(:disabled),
input[type="range"]:not(:disabled),
input[type="file"]::file-selector-button,
label:has(> input[type="checkbox"]:not(:disabled)),
label:has(> input[type="radio"]:not(:disabled)) {
  cursor: pointer;
}

button:disabled,
input:disabled,
select:disabled {
  cursor: not-allowed;
}

/* «Загрузить ещё» в конце списка - выключено классом, а не disabled: рука не нужна (style.css ставит default,
   но правило a[href] выше сильнее) */
a.items-list__load-button--disabled,
button.items-list__load-button--disabled,
a.ratings-list__load-button--disabled,
button.ratings-list__load-button--disabled {
  cursor: default;
}

/* меню-бургер: названия разделов стали span вместо h2/h3 (view/base/v_categories_menu.php) - остаются блочными, как были */
.categories-menu__category-title,
.categories-menu__subcategory-title {
  display: block;
}

/* Пояснение над группой полей (p.input-page__desc в форме): подпись над полем
   (.float-label, top: -19px) налезала на последнюю строку текста - отступ под
   пояснением больше. Формы события, вакансии и др. (web 2.95.16) */
.input-form__form .input-page__desc + .input-form__inputs {
  margin-top: 32px;   /* поверх 10px у .desc: подпись 15px + воздух */
}

/* Дата / время в формах сайта (событие и др.): iOS Safari даёт им свою мин. ширину - поле вылезало
   за экран, страница ездила вбок. Как в Estimator (estimator.css, input[type="date"].est-input):
   обычное поле, высота как у текстовых (46px = 24 строка + 2×10 отступ + 2 рамка). web 2.95.24 */
input[type="date"].input-form__input,
input[type="time"].input-form__input,
input[type="datetime-local"].input-form__input {
  -webkit-appearance: none;
  appearance: none;
  display: block;
  min-width: 0;
  max-width: 100%;
  height: 46px;
  text-align: left;
}

input.input-form__input::-webkit-date-and-time-value {
  margin: 0;
  text-align: left;
}

/* Визитки «только по ссылке» (web 2.112.0, core/item_private.php): выбор в форме добавления,
   ссылка в «Мои визитки», кнопки и QR на странице /c/{token} */
.card-where {
  border: 0;
  padding: 0;
  margin: 0 0 24px;
  min-width: 0;
}

.card-where__option {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin: 12px 0;
  cursor: pointer;
}

.card-where__option input {
  flex: none;
  margin-top: 8px;
}

.card-where__option .desc {
  margin: 2px 0 0;
}

.card-private__label {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 10px;
  border-radius: 12px;
  background-color: #e3f5fb;
  color: #1f8bb0;
  font-size: 13px;
  font-weight: 600;
  vertical-align: middle;
}

.card-private__share {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 18px;
  margin: 8px 0;
}

.card-private__url {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding: 6px 8px;
  border: 1px solid #cfd6dc;
  border-radius: 6px;
  font-size: 14px;
  color: #333;
  background-color: #f7f9fa;
}

.card-private__share-btn {
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  font-family: inherit;
}

.card-private__copied {
  font-size: 14px;
  color: #2c8a4b;
}

.card-private__note {
  margin-bottom: 20px;
}

/* без «Сохранить в контакты» (web 2.132.0) - отступ «Редактировать» от адреса */
.card-private__owner {
  margin-top: 20px;
}

/* «Удалить визитку» внизу страницы визитки по ссылке (web 2.134.0) - красной кнопкой в рамке (2.135.1) */
.card-private__delete {
  padding: 48px 16px 56px;
  text-align: center;
}

.card-private__delete-btn {
  padding: 12px 28px;
  border: 1px solid #f04425;
  border-radius: 999px;   /* «пилюлей», как .button */
  background: none;
  color: #f04425;
  font: inherit;
  font-size: 16px;
  cursor: pointer;
}

.card-private__delete-btn:hover {
  border-color: #ca290d;
  color: #ca290d;
}


/* «Поделиться» как в приложении (web 2.113.7, view/base/v_share_button.php, assets/js/share.js) */
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px;
  border: 0;
  background: none;
  color: #3ebde6;
  font: inherit;
  cursor: pointer;
}

.share-btn:hover {
  color: #2a9cc2;
}

.share-btn__icon {
  display: inline-flex;
  font-size: 24px;
}

.share-btn__label {
  font-size: 15px;
  font-weight: 700;
}

/* в Estimator рядом с полем ссылки - квадрат 40 px, как «Копировать» */
.share-btn--box {
  justify-content: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 6px;
  color: #1f8db3;
}

/* кнопкой Estimator (приглашение в команду) - значок поменьше, цвет текста кнопки */
.share-btn.est-btn {
  padding: 8px 18px;
  color: #1c1c1c;
}

.share-btn.est-btn .share-btn__icon {
  font-size: 18px;
  color: #3ebde6;
}

.share-btn.est-btn .share-btn__label {
  font-size: inherit;
  font-weight: inherit;
}

/* своё меню, где нет системного (компьютер) */
.share-menu {
  position: absolute;
  z-index: 1000;
  min-width: 220px;
  padding: 8px 0;
  border-radius: 12px;
  background: #fafafa;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.04);
}

.share-menu__item {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: 10px 20px;
  border: 0;
  background: none;
  color: #1c1c1c;
  font: inherit;
  font-size: 16px;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.share-menu__item:hover,
.share-menu__item:focus-visible {
  background: rgba(0, 0, 0, 0.05);
  outline: none;
}

.share-menu__item--copy {
  color: #1f8db3;
  font-weight: 600;
}

.share-menu__item--done {
  color: #2c8a4b;
}

.share-menu__sep {
  height: 1px;
  margin: 6px 20px;
  background: #e1e1e3;
}

/* визитка: под картинкой - рейтинг слева, «Поделиться» справа (web 2.113.12, просьба автора) */
.item-page__under {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.item-page__under .show-rating__block {
  margin: 0;
}


/* «Поделиться» справа над содержимым - событие, вакансия / резюме, статья блога (web 2.113.9) */
.page-share {
  display: flex;
  justify-content: flex-end;
  margin: 0 0 8px;
}

/* в строке с рубрикой / датой - значок прижат вправо */
.page-share--row {
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.page-share--row .blog-post__rubric {
  margin-bottom: 0;
}

.share-btn--end {
  margin-left: auto;
}

/* Кнопки .button на телефоне (style.css, @media 425px): width 100% + отступы 50 px по бокам (content-box) - кнопка шире
   экрана, страница ездит вбок (вакансия и резюме: «Войти» у скрытых контактов). Отступы - внутри ширины (web 2.113.10) */
@media (max-width: 425px) {
  .button {
    box-sizing: border-box;
  }
}

/* Голубая линия под заголовком (.h1-title::after, style.css) сдвинута вправо на 15 px и шириной с заголовок: у длинного
   заголовка во всю строку она вылезала за край - страница ездила вбок (вакансия, событие). Заголовок - на 15 px уже
   строки, линия помещается; короткие заголовки не меняются (web 2.113.10) */
.h1-title {
  max-width: calc(100% - 15px);
}

/* Чекбоксы и радио на всём сайте (web 2.113.15, просьба автора; было только в Estimator - .est-check).
   Чекбокс: серая рамка, отмечен - синяя галочка, хвост выступает за рамку вправо-вверх.
   Радио: та же серая рамка, выбран - синий квадрат внутри (как раньше был чекбокс).
   Скрытые (.hidden у «Согласен с условиями», звёзды отзывов, переключатель фильтров jobs) - не трогаем. */
input[type="checkbox"]:not(.hidden),
input[type="radio"]:not(.hidden) {
  -webkit-appearance: none;
  appearance: none;
  position: relative;
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin: 0;
  border: 2px solid #878787;
  border-radius: 3px;
  background: #fff;
  overflow: visible;
  vertical-align: -3px;
}

input[type="checkbox"]:not(.hidden):checked::after {
  content: "";
  position: absolute;
  top: -9px;
  left: 1px;
  width: 20px;
  height: 20px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M2 11.5l4 6.5C8.5 12.5 11.5 8.5 16 5' fill='none' stroke='%233ebde6' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center / contain;
  pointer-events: none;
}

input[type="radio"]:not(.hidden):checked::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 10px;
  height: 10px;
  background: #3ebde6;
}

input[type="checkbox"]:not(.hidden):focus-visible,
input[type="radio"]:not(.hidden):focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(62, 189, 230, 0.3);
}

input[type="checkbox"]:disabled,
input[type="radio"]:disabled {
  opacity: 0.5;
}

/* «Согласен с условиями» (регистрация, добавление визитки) - квадрат рисует label: отмечен - та же галочка */
.input-form__agree-terms--checkbox:checked + label::after {
  top: -4px;
  left: 3px;
  width: 20px;
  height: 20px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M2 11.5l4 6.5C8.5 12.5 11.5 8.5 16 5' fill='none' stroke='%233ebde6' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center / contain;
}

/* пост / событие другого города по прямому адресу (web 2.150.0, view/base/v_other_city.php) */
.other-city {
  margin: 0 0 16px;
  padding: 8px 12px;
  border-left: 3px solid #3ebde6;
  background: #f3f9fc;
  font-size: 14px;
  line-height: 1.4;
}

/* ---------- справка Estimator (web 2.154.0): /estimator/help и статьи information с position 4 ---------- */
.help-hub__intro {
  margin: 0 0 20px;
  font-size: 17px;
  line-height: 1.5;
  color: #45484c;
}

.help-list {
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
  counter-reset: help;
  display: grid;
  gap: 10px;
}

.help-list__item {
  counter-increment: help;
}

.help-list__link {
  position: relative;
  display: block;
  padding: 14px 16px 14px 56px;
  border: 1px solid #e3e8ef;
  border-radius: 12px;
  background: #fff;
  color: inherit;
  text-decoration: none;
  transition: border-color .15s, box-shadow .15s;
}

.help-list__link::before {
  content: counter(help);
  position: absolute;
  left: 14px;
  top: 14px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #e9f7fc;
  color: #1f8db3;
  font-weight: 700;
  font-size: 14px;
  line-height: 28px;
  text-align: center;
}

.help-list__link:hover {
  border-color: #3ebde6;
  box-shadow: 0 6px 18px rgba(30, 50, 90, 0.16);
}

.help-list__title {
  display: block;
  font-weight: 700;
  font-size: 17px;
}

.help-list__sub {
  display: block;
  margin-top: 4px;
  font-size: 14px;
  line-height: 1.45;
  color: #5c6168;
}

/* заголовок статьи справки - как у поста блога (web 2.156.1), даты под ним нет - отбивка до текста здесь */
.help-article__title {
  margin-top: 0;
  margin-bottom: 22px;
}

/* «Estimator · Справка» над заголовком - своей строкой (web 2.156.3): строчной на телефоне заголовок в две строки
   наезжал на неё (в блоге подпись внутри своего блока .page-share) */
.help-main .blog-post__rubric {
  display: block;
  width: fit-content;
  line-height: 1.3;
  margin-bottom: 12px;
}

/* скриншот в статье: телефонная ширина, рамка - не сливается с текстом */
.help-article .help-img {
  display: block;
  width: 100%;
  max-width: 430px;
  height: auto;
  margin: 14px auto 26px;
  border: 1px solid #e3e8ef;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(30, 50, 90, 0.12);
}

.help-article .help-tip {
  margin: 0 0 18px;
  padding: 10px 14px;
  border-left: 3px solid #3ebde6;
  background: #f3f9fc;
  border-radius: 0 12px 12px 0;
}

.help-cta {
  margin: 28px 0 8px;
}

.help-cta__btn {
  display: inline-block;
  padding: 12px 26px;
  border-radius: 999px;
  background: #3ebde6;
  color: #fff !important;
  font-weight: 700;
  text-decoration: none;
}

.help-cta__btn:hover {
  background: #1f8db3;
}

/* web 2.156.2: на ПК - разделы слева и статья справа; на телефоне разделов нет */
.help-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 48px;
  align-items: start;
}

.help-main {
  min-width: 0;
}

.help-nav {
  position: sticky;
  top: 20px;
  padding-top: 4px;
}

.help-nav__title {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #8a8f94;
}

.help-nav__list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-left: 2px solid #e3e8ef;
}

.help-nav__link,
.help-nav__current {
  display: block;
  margin-left: -2px;
  padding: 7px 0 7px 14px;
  border-left: 2px solid transparent;
  font-size: 15px;
  line-height: 1.35;
}

.help-nav__link {
  color: #5c6168;
  text-decoration: none;
}

.help-nav__link:hover {
  color: #1f8db3;
}

/* текущий раздел - просто чёрным, не ссылка (просьба автора) */
.help-nav__current {
  border-left-color: #1d1d1f;
  font-weight: 700;
  color: #1c1c1c;
}

/* «Назад / Далее» - просто ссылки, «Далее» всегда справа (web 2.161.6; было - карточки с названием статьи) */
.help-pager {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin: 36px 0 0;
}

.help-pager__link {
  font-size: 17px;
  font-weight: 700;
  color: #1f8db3;
  text-decoration: none;
}

.help-pager__link:hover {
  text-decoration: underline;
}

.help-pager__link--next {
  margin-left: auto;
}

@media (max-width: 900px) {
  .help-layout {
    display: block;
  }

  .help-nav {
    display: none;
  }
}

.help-question {
  margin-top: 18px;
  font-size: 14px;
  color: #5c6168;
}

/* Галерея фото на странице правки бизнеса (web 2.157.0, view/user/v_item_edit.php, assets/js/item-gallery.js):
   сетка квадратных миниатюр, последняя плитка - «+ Добавить фото» */
.item-gallery {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid #e3e8ef;
}

.item-gallery__hint {
  margin: 8px 0 18px;
  font-size: 15px;
  line-height: 1.5;
  color: #5c6168;
}

.item-gallery__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.item-gallery__cell {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  overflow: hidden;
  background: #f1f4f7;
}

.item-gallery__cell[hidden] {
  display: none;
}

.item-gallery__img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.item-gallery__cell.is-loading .item-gallery__img {
  opacity: .55;
}

.item-gallery__progress {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  height: 6px;
  border-radius: 3px;
  background: rgba(255, 255, 255, .8);
  overflow: hidden;
}

.item-gallery__progress span {
  display: block;
  width: 0;
  height: 100%;
  background: #3ebde6;
  transition: width .2s;
}

.item-gallery__badge {
  position: absolute;
  left: 8px;
  bottom: 8px;
  padding: 3px 8px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .92);
  font-size: 12px;
  font-weight: 700;
  color: #9a6b00;
}

.item-gallery__badge--rejected {
  color: #d14343;
}

.item-gallery__delete {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, .55);
  color: #fff;
  font-size: 20px;
  line-height: 30px;
  cursor: pointer;
}

.item-gallery__delete:hover {
  background: #d14343;
}

.item-gallery__cell--add {
  background: none;
}

.item-gallery__add {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 100%;
  height: 100%;
  box-sizing: border-box;   /* иначе рамка шире плитки и обрезается справа и снизу (2.162.5) */
  border: 2px dashed #b9c6d3;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 700;
  color: #1f8db3;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}

.item-gallery__add:hover {
  border-color: #3ebde6;
  background: #f3f9fc;
}

/* плюс - SVG, а не символ «+»: у шрифта он сидит ниже и левее центра (2.162.5) */
.item-gallery__plus {
  display: flex;
}

/* сам выбор файла не виден - нажимается плитка */
.item-gallery__input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.item-gallery__error {
  min-height: 1.4em;
  margin: 12px 0 0;
  font-size: 14px;
  color: #d14343;
}

@media (max-width: 480px) {
  .item-gallery__grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .item-gallery__add {
    font-size: 12px;
  }
}

/* порядок фото (web 2.157.1; плашку «Обложка» убрали в 2.162.4 - нигде отдельно не использовалась); перетаскивание - копия плитки едет за пальцем/мышью,
   на месте плитки - полупрозрачное «куда встанет» */
.item-gallery__cell[data-photo-id] {
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

.item-gallery__cell[data-photo-id] .item-gallery__img {
  pointer-events: none;
}

.item-gallery__cell.is-placeholder {
  opacity: .3;
  outline: 2px dashed #3ebde6;
  outline-offset: -2px;
}

.item-gallery.is-sorting,
.item-gallery.is-sorting * {
  cursor: grabbing;
}

.item-gallery__ghost {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1000;
  margin: 0;
  list-style: none;
  pointer-events: none;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.04);
  transform-origin: 0 0;
}

.item-gallery__ghost .item-gallery__delete {
  display: none;
}

/* телефон: плитки ~110 px - плашка и крестик не должны налезать друг на друга */
@media (max-width: 480px) {
  .item-gallery__badge {
    top: auto;
    padding: 2px 6px;
    font-size: 11px;
  }

  .item-gallery__badge {
    left: 6px;
    bottom: 6px;
  }

  .item-gallery__delete {
    top: 4px;
    right: 4px;
    width: 26px;
    height: 26px;
    font-size: 18px;
    line-height: 26px;
  }
}

/* Галерея на странице бизнеса (web 2.157.3, view/catalog/v_item.php): под описанием, тот же фон и ширина.
   ПК - миниатюры рядами; телефон - одна лента, листается вбок */
.item-photos {
  background-color: #f9f9f9;
}

.item-photos__wrapper {
  max-width: 1124px;
  margin: 0 auto;
  padding: 0 50px 70px;
}

.item-photos__title {
  margin: 0 0 16px;
  font-size: 22px;
  font-weight: 700;
  color: #1c1c1c;
}

.item-photos__count {
  font-weight: 400;
  color: #8a8f94;
}

.item-photos__list {
  display: grid;
  grid-template-columns: repeat(auto-fill, 140px);
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.item-photos__item {
  position: relative;
}

.item-photos__link {
  display: block;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  overflow: hidden;
  background: #e9edf1;
}

.item-photos__img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .25s;
}

.item-photos__link:hover .item-photos__img {
  transform: scale(1.04);
}

@media (max-width: 1024px) {
  .item-photos__wrapper {
    padding: 0 20px 50px;
  }
}

.item-photos__more {
  display: none;
}

@media (max-width: 600px) {
  /* телефон - по 3 в ряд на всю ширину */
  .item-photos__list {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  /* больше 3 фото, только телефон (web 2.160.4-5): остальные спрятаны, третье размыто и закрыто кнопкой «Ещё N»; на ПК - все сразу */
  .item-photos__list.is-folded .item-photos__item--extra {
    display: none;
  }

  .item-photos__list.is-folded .item-photos__item--teaser .item-photos__img {
    filter: blur(4px) brightness(.75);
    transform: scale(1.1);
  }

  .item-photos__list.is-folded .item-photos__more {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    border: 0;
    border-radius: 12px;
    background: transparent;
    font: inherit;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 1px 4px rgba(0, 0, 0, .4);
    cursor: pointer;
  }
}

/* окно просмотра (assets/js/gallery-viewer.js) */
.gallery-viewer {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: none;
  background: #0b0d0f;
  overflow: hidden;
  -webkit-user-select: none;
  user-select: none;
}

.gallery-viewer.is-open {
  display: block;
}

html.gallery-viewer-open,
html.gallery-viewer-open body {
  overflow: hidden;
}

.gallery-viewer__track {
  position: absolute;
  inset: 0;
  touch-action: none;
  transition: transform .18s ease-out;
}

.gallery-viewer__frame {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 100vw;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 12px;
  box-sizing: border-box;
}

.gallery-viewer__frame[hidden] {
  display: none;
}

.gallery-viewer__frame:nth-child(1) { left: -100vw; }
.gallery-viewer__frame:nth-child(2) { left: 0; }
.gallery-viewer__frame:nth-child(3) { left: 100vw; }

.gallery-viewer__img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 4px;
  -webkit-user-drag: none;
}

.gallery-viewer__counter {
  position: absolute;
  top: 16px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 15px;
  color: rgba(255, 255, 255, .85);
  pointer-events: none;
}

.gallery-viewer__close,
.gallery-viewer__nav {
  position: absolute;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .12);
  color: #fff;
  cursor: pointer;
  line-height: 1;
}

.gallery-viewer__close:hover,
.gallery-viewer__nav:hover {
  background: rgba(255, 255, 255, .25);
}

.gallery-viewer__close {
  top: 8px;
  right: 10px;
  width: 42px;
  height: 42px;
  font-size: 30px;
}

.gallery-viewer__nav {
  top: 50%;
  width: 48px;
  height: 48px;
  margin-top: -24px;
  font-size: 34px;
}

.gallery-viewer__nav[hidden] {
  display: none;
}

.gallery-viewer__nav--prev { left: 14px; }
.gallery-viewer__nav--next { right: 14px; }

/* на телефоне листают свайпом - стрелки не загораживают фото */
@media (hover: none) and (pointer: coarse) {
  .gallery-viewer__nav {
    display: none;
  }
}

/* Ответ владельца под отзывом (web 2.158.0, view/catalog/v_review_reply.php) */
.review-reply {
  margin: 14px 0 4px 18px;
  padding: 12px 16px;
  border-left: 3px solid #3ebde6;
  border-radius: 0 12px 12px 0;
  background: #f3f9fc;
}

.review-reply__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  margin-bottom: 6px;
}

.review-reply__label {
  font-size: 14px;
  font-weight: 700;
  color: #1f8db3;
}

.review-reply__date {
  font-size: 13px;
  color: #8a8f94;
}

.review-reply__text {
  font-size: 15px;
  line-height: 1.55;
  color: #1c1c1c;
  overflow-wrap: anywhere;
}

.review-reply__answer {
  display: inline-block;
  margin-top: 10px;
  font-size: 14px;
  font-weight: 700;
  color: #1f8db3;
}

@media (max-width: 600px) {
  .review-reply {
    margin-left: 8px;
  }
}

/* «Отзывы о моих бизнесах» (web 2.158.0, view/user/v_business_reviews.php) */
.owner-reviews__wrapper {
  max-width: 860px;
  margin: 0 auto;
  padding: 36px 20px 88px;
}

.owner-reviews__title {
  margin: 0 0 16px;
  font-size: 30px;
  line-height: 1.2;
  color: #1c1c1c;
}

.owner-reviews__intro {
  margin-bottom: 24px;
  font-size: 15px;
  line-height: 1.55;
  color: #3a3f45;
}

.owner-reviews__intro p {
  margin: 0 0 8px;
}

.owner-reviews__tip {
  padding: 12px 16px;
  border-left: 3px solid #3ebde6;
  border-radius: 0 12px 12px 0;
  background: #f3f9fc;
}

.owner-reviews__message {
  margin: 0 0 18px;
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 15px;
}

.owner-reviews__message--ok {
  background: #e8f7ee;
  color: #1e6b3a;
}

.owner-reviews__message--error {
  background: #fdecec;
  color: #a12a1f;
}

.owner-reviews__tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  border-bottom: 1px solid #e3e8ef;
}

.owner-reviews__tab {
  margin-bottom: -1px;
  padding: 10px 14px;
  border-bottom: 2px solid transparent;
  font-size: 15px;
  font-weight: 700;
  color: #5c6168;
  text-decoration: none;
}

.owner-reviews__tab.is-active {
  border-bottom-color: #1d1d1f;
  color: #1c1c1c;
}

.owner-reviews__badge {
  display: inline-block;
  min-width: 22px;
  margin-left: 4px;
  padding: 1px 7px;
  border-radius: 11px;
  background: #e9edf1;
  font-size: 13px;
  text-align: center;
  color: #3a3f45;
}

.owner-reviews__badge--hot {
  background: #f5a623;
  color: #fff;
}

.owner-reviews__items {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}

.owner-reviews__items-label {
  font-size: 14px;
  color: #8a8f94;
}

.owner-reviews__chip {
  padding: 6px 12px;
  border: 1px solid #d6dde5;
  border-radius: 16px;
  font-size: 14px;
  color: #3a3f45;
  text-decoration: none;
}

.owner-reviews__chip span {
  color: #8a8f94;
}

.owner-reviews__chip.is-active {
  border-color: #1d1d1f;
  background: #1d1d1f;
  color: #fff;
}

.owner-reviews__chip.is-active span {
  color: #c9ced4;
}

.owner-reviews__empty {
  padding: 24px 20px;
  border: 1px dashed #c9d3dd;
  border-radius: 12px;
  font-size: 15px;
  color: #5c6168;
  text-align: center;
}

.owner-reviews__empty p {
  margin: 0 0 8px;
}

.owner-reviews__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.owner-review {
  margin-bottom: 16px;
  padding: 18px 20px;
  border: 1px solid #e3e8ef;
  border-radius: 12px;
  background: #fff;
  scroll-margin-top: 80px;
}

.owner-review--unanswered {
  border-left: 4px solid #f5a623;
}

.owner-review.is-target {
  box-shadow: 0 0 0 3px rgba(62, 189, 230, .35);
}

.owner-review__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.owner-review__item {
  font-size: 14px;
  font-weight: 700;
  color: #1f8db3;
  text-decoration: none;
}

.owner-review__flag {
  flex: 0 0 auto;
  padding: 3px 9px;
  border-radius: 10px;
  background: #fff3d6;
  font-size: 12px;
  font-weight: 700;
  color: #9a6b00;
}

.owner-review__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  margin-bottom: 8px;
  font-size: 15px;
}

.owner-review__stars {
  letter-spacing: 1px;
  color: #f5a623;
}

.owner-review__stars span {
  color: #d6dde5;
}

.owner-review__date {
  font-size: 13px;
  color: #8a8f94;
}

.owner-review__text {
  font-size: 16px;
  line-height: 1.6;
  color: #1c1c1c;
  overflow-wrap: anywhere;
}

.owner-review__reply {
  margin-top: 14px;
  padding: 12px 16px;
  border-left: 3px solid #3ebde6;
  border-radius: 0 12px 12px 0;
  background: #f3f9fc;
}

.owner-review__reply--hidden {
  border-left-color: #d14343;
  background: #fdf1f0;
}

.owner-review__reply-head {
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #1f8db3;
}

.owner-review__hidden-note {
  margin: 0 0 6px;
  font-size: 14px;
  color: #a12a1f;
}

.owner-review__reply-text {
  font-size: 15px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.owner-review__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  margin-top: 14px;
}

.owner-review__form-wrap[open] {
  flex: 1 1 100%;
}

.owner-review__form-wrap[open] .owner-review__btn {
  display: none;
}

.owner-review__btn {
  display: inline-block;
  padding: 9px 20px;
  border-radius: 999px;
  background: #3ebde6;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  list-style: none;
}

.owner-review__btn::-webkit-details-marker {
  display: none;
}

.owner-review__btn--ghost {
  border: 1px solid #3ebde6;
  background: #fff;
  color: #1f8db3;
}

.owner-review__textarea {
  display: block;
  width: 100%;
  min-height: 120px;
  padding: 12px 14px;
  border: 1px solid #c9d3dd;
  border-radius: 6px;
  font: inherit;
  font-size: 16px;
  line-height: 1.5;
  box-sizing: border-box;
  resize: vertical;
}

.owner-review__error {
  margin: 8px 0 0;
  font-size: 14px;
  color: #d14343;
}

.owner-review__form-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
}

.owner-review__count {
  white-space: nowrap;
  font-size: 13px;
  color: #8a8f94;
}

.owner-review__submit {
  margin: 0;
  padding: 10px 22px;
  border: 0;
  border-radius: 999px;
  background: #3ebde6;
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
}

.owner-review__submit:hover {
  background: #1f8db3;
}

.owner-review__delete {
  margin: 0;
}

.owner-review__link-btn {
  padding: 9px 0;
  border: 0;
  background: none;
  font-size: 14px;
  color: #d14343;
  cursor: pointer;
}

.account-tile-hot {
  color: #c77c00;
}

.owner-reviews__message--plan {
  background: #fff3d6;
  color: #6b4b00;
}

/* «Фото бизнеса» - отдельная страница галереи (web 2.159.2, view/user/v_business_photos.php) */
.business-photos__wrapper {
  max-width: 900px;
  margin: 0 auto;
  padding: 30px 20px 50px;
}

.business-photos__title {
  margin: 0 0 4px;
  font-size: 30px;
  line-height: 1.2;
  color: #1c1c1c;
}

.business-photos__item {
  margin: 0 0 18px;
  font-size: 16px;
  color: #5c6168;
}

.business-photos__count {
  margin: 0 0 18px;
  font-size: 17px;
  color: #3a3f45;
}

.item-gallery--page {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

/* под фото: «Готово» + статус сохранения (web 2.160.1) */
.business-photos__footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: 24px;
  text-align: center;
}

.business-photos__status {
  font-size: 15px;
  font-weight: 700;
  color: #5c6168;
}

.business-photos__status--saving {
  color: #1f8db3;
}

.business-photos__status--ok,
.business-photos__status--idle {
  color: #1e8a4c;
}

.business-photos__status--error {
  color: #d14343;
}

.business-photos__done {
  flex: 0 0 auto;
  padding: 13px 44px;
  border-radius: 999px;
  background: #3ebde6;
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
}

.business-photos__done:hover {
  background: #1f8db3;
  color: #fff;
}

/* плашка-ссылка на странице правки бизнеса */
.gallery-link {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 32px;
  padding: 14px 16px;
  border: 1px solid #d6dde5;
  border-radius: 12px;
  background: #fff;
  color: #1c1c1c;
  text-decoration: none;
  transition: border-color .15s, box-shadow .15s;
}

.gallery-link:hover {
  border-color: #3ebde6;
  box-shadow: 0 6px 18px rgba(30, 50, 90, 0.16);
}

.gallery-link__thumbs {
  display: flex;
  flex: 0 0 auto;
}

.gallery-link__thumbs img,
.gallery-link__plus {
  box-sizing: border-box;
  width: 48px;
  height: 48px;
  border: 2px solid #fff;
  border-radius: 6px;
  object-fit: cover;
}

.gallery-link__thumbs img + img {
  margin-left: -14px;
}

.gallery-link__plus {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px dashed #b9c6d3;
  font-size: 26px;
  color: #1f8db3;
}

/* нет в тарифе (web 2.160.6): серый замок вместо превью */
.gallery-link__lock {
  border: 0;
  background: #eef1f4;
  color: #8a8f94;
}

.gallery-link__text {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  font-size: 14px;
  color: #5c6168;
}

.gallery-link__text b {
  font-size: 16px;
  color: #1c1c1c;
}

.gallery-link__go {
  flex: 0 0 auto;
  font-size: 15px;
  font-weight: 700;
  color: #1f8db3;
}

@media (max-width: 480px) {
  .gallery-link {
    flex-wrap: wrap;
  }

  .gallery-link__go {
    width: 100%;
  }
}

/* плашка «Ответы на отзывы · в тарифе Pro» на /user/business_reviews (web 2.160.7) */
.owner-reviews__plan {
  margin: 0 0 20px;
}

/* под описанием бизнеса: «До 2000 символов · в Pro — до 5000» (web 2.161.0) */
.input-form__limit {
  margin: 4px 0 0;
  font-size: 13px;
  color: #8a8f94;
}

/* бизнес закрыт (item.works = 0, web 2.162.7): плашка на странице бизнеса, серая визитка с меткой, метка в списках.
   Старая диагональная лента .alert-item-image (style.css) больше не используется */
.item-closed {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 0 0 24px;
  padding: 14px 16px;
  border: 1px solid #f0d9a8;
  border-radius: 12px;
  background: #fff8e8;
  color: #5c4a1e;
  font-size: 15px;
  line-height: 1.45;
}

.item-closed__icon {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #fde7b8;
  color: #9a6b00;
}

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

.item-closed__title {
  font-size: 16px;
  color: #3d3115;
}

.item-closed__text a {
  color: #1f8db3;
  font-weight: 700;
}

.item-page__img--closed img {
  filter: grayscale(1);
  opacity: .55;
}

.item-closed__badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  padding: 5px 12px;
  border-radius: 14px;
  background: rgba(40, 44, 48, .88);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  line-height: 18px;
}

.items-list__badge--closed {
  background-color: #6b7178;
}

.items-list__badge + .items-list__badge {
  margin-left: 6px;
}


/* ---------------- Сообщения бизнесу (web 2.163.0): список диалогов, переписка, кнопка «Написать» ---------------- */

.chat-list__wrapper,
.chat__wrapper {
  max-width: 760px;
  margin: 0 auto;
  padding: 28px 16px 88px;
}

.chat-list__title {
  margin: 0 0 20px;
  font-size: 30px;
  line-height: 1.2;
  color: #1c1c1c;
}

.chat-list__empty {
  padding: 24px 20px;
  border-radius: 12px;
  background: #f3f9fc;
  font-size: 15px;
  line-height: 1.55;
  color: #3a3f45;
}

.chat-list__empty p {
  margin: 0 0 8px;
}

.chat-list__empty-note {
  color: #6b7178;
  font-size: 14px;
}

.chat-list__list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid #e3e8ef;
}

.chat-row {
  border-bottom: 1px solid #e3e8ef;
}

.chat-row__link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 4px;
  color: inherit;
  text-decoration: none;
}

.chat-row__link:hover {
  background: #f7fafc;
}

.chat-row__pic {
  flex: none;
}

.chat-row__pic--item {
  width: 56px;
  height: 32px;
  box-sizing: border-box;
  border-radius: 6px;
  object-fit: cover;
  border: 1px solid #dcdfe3;
}

.chat-row__pic--empty {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #e6f6fc;
  color: #1f8db3;
  font-weight: 700;
}

.chat-row__body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.chat-row__top,
.chat-row__bottom {
  display: flex;
  align-items: center;
  gap: 10px;
}

.chat-row__name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 16px;
  color: #1c1c1c;
}

.chat-row__time {
  flex: none;
  font-size: 13px;
  color: #8a8f94;
}

.chat-row__about {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px;
  color: #6b7178;
}

.chat-row__chip {
  display: inline-block;
  margin-right: 4px;
  padding: 1px 8px;
  border-radius: 10px;
  background: #e6f6fc;
  color: #1f8db3;
  font-size: 12px;
  font-weight: 700;
}

.chat-row__preview {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 14px;
  color: #6b7178;
}

.chat-row__you {
  color: #8a8f94;
}

.chat-row--unread .chat-row__preview {
  color: #1c1c1c;
  font-weight: 600;
}

.chat-row__badge {
  flex: none;
  min-width: 22px;
  height: 22px;
  padding: 0 7px;
  box-sizing: border-box;
  border-radius: 11px;
  background: #3ebde6;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  line-height: 22px;
  text-align: center;
}

/* переписка */

.chat__head {
  position: sticky;
  top: 0;
  /* ниже шапки сайта (.header на телефоне - 3): иначе вылезала поверх открытого меню (web 2.165.3) */
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #e3e8ef;
  background: #fff;
}

.chat__back {
  flex: none;
  display: inline-flex;
  padding: 6px;
  margin-left: -6px;
  color: #1f8db3;
}

.chat__who {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.chat__name {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 17px;
  font-weight: 700;
  color: #1c1c1c;
  text-decoration: none;
}

.chat__sub {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px;
  color: #6b7178;
  text-decoration: none;
}

a.chat__sub:hover,
a.chat__name:hover {
  color: #1f8db3;
}

.chat__menu {
  position: relative;
  flex: none;
}

.chat__menu-btn {
  display: inline-flex;
  padding: 6px;
  border-radius: 50%;
  color: #6b7178;
  cursor: pointer;
  list-style: none;
}

.chat__menu-btn::-webkit-details-marker {
  display: none;
}

.chat__menu[open] .chat__menu-btn {
  background: #eef1f4;
}

.chat__menu-box {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  width: 280px;
  max-width: calc(100vw - 32px);
  padding: 8px;
  box-sizing: border-box;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.04);
}

.chat__menu-box form {
  margin: 0;
}

.chat__menu-item {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 6px;
  background: none;
  font: inherit;
  font-size: 15px;
  text-align: left;
  color: #1c1c1c;
  cursor: pointer;
}

.chat__menu-item:hover {
  background: #f3f5f7;
}

.chat__menu-item--danger {
  color: #d14343;
}

.chat__menu-box .chat__report {
  margin-top: 6px;
  padding-top: 8px;
  border-top: 1px solid #eef0f2;
}

.chat__report-label {
  display: block;
  padding: 0 4px 6px;
  font-size: 13px;
  color: #6b7178;
}

.chat__report textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 8px 10px;
  border: 1px solid #dcdfe3;
  border-radius: 6px;
  font: inherit;
  font-size: 14px;
  resize: vertical;
}

.chat__flash {
  margin: 12px 0 0;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
}

.chat__flash--ok {
  background: #e8f7ee;
  color: #1e6b3a;
}

.chat__flash--error {
  background: #fdecec;
  color: #a12a1f;
}

.chat__messages {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 40vh;
  padding: 16px 0 8px;
}

.chat__intro {
  margin: 0 auto 12px;
  max-width: 460px;
  padding: 16px 18px;
  border-radius: 12px;
  background: #f3f9fc;
  font-size: 15px;
  line-height: 1.5;
  text-align: center;
  color: #3a3f45;
}

.chat__intro p {
  margin: 0 0 6px;
}

.chat__intro-tip {
  color: #6b7178;
  font-size: 14px;
}

.chat__day {
  margin: 12px 0 6px;
  text-align: center;
}

.chat__day span {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 12px;
  background: #eef1f4;
  font-size: 12px;
  font-weight: 600;
  color: #6b7178;
}

.chat-msg {
  display: flex;
}

.chat-msg--mine {
  justify-content: flex-end;
}

.chat-msg__bubble {
  max-width: min(78%, 520px);
  padding: 8px 12px 6px;
  border-radius: 18px 18px 18px 6px;
  background: #eef1f4;
  color: #1c1c1c;
  font-size: 15px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.chat-msg--mine .chat-msg__bubble {
  border-radius: 18px 18px 6px 18px;
  background: #3ebde6;
  color: #fff;
}

.chat-msg--mine .chat-msg__text a {
  color: #fff;
  text-decoration: underline;
}

.chat-msg--deleted .chat-msg__bubble,
.chat-msg--mine.chat-msg--deleted .chat-msg__bubble {
  border: 1px dashed #cfd5db;
  background: none;
  color: #8a8f94;
  font-style: italic;
}

.chat-msg__time {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  text-align: right;
  opacity: .75;
}

.chat__read {
  margin: 2px 4px 0;
  font-size: 12px;
  text-align: right;
  color: #8a8f94;
}

.chat__blocked {
  margin: 12px 0 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: #f3f5f7;
  font-size: 14px;
  text-align: center;
  color: #6b7178;
}

.chat__form {
  position: sticky;
  bottom: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 8px;
  padding: 10px 0 14px;
  border-top: 1px solid #e3e8ef;
  background: #fff;
}

.chat__input {
  flex: 1;
  min-width: 0;
  min-height: 44px;
  max-height: 200px;
  padding: 11px 16px;
  box-sizing: border-box;
  border: 1px solid #dcdfe3;
  border-radius: 22px;
  font: inherit;
  font-size: 16px;
  line-height: 1.35;
  resize: none;
}

.chat__input:focus {
  outline: none;
  border-color: #3ebde6;
}

.chat__send {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: #3ebde6;
  color: #fff;
  cursor: pointer;
}

.chat__send:hover {
  background: #1fa8d4;
}

.chat__form.is-sending .chat__send {
  opacity: .5;
}

.chat__error {
  flex-basis: 100%;
  margin: 0;
  font-size: 13px;
  color: #a12a1f;
}

/* «Написать» / «Открыть переписку» на странице бизнеса - под «Сохранить», ссылкой как она (web 2.164.2) */
.item-page__chat-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-size: 16px;
  line-height: 26px;
  font-weight: 700;
  color: #3ebde6;
  text-decoration: none;
}

.item-page__chat-link:hover {
  color: #1f8db3;
}


/* колокольчик слева от «Аккаунт» в шапке: непрочитанные сообщения, новые отзывы (web 2.164.0) */
.header-bell {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  margin-right: 10px;
  color: #ffffff;
  text-decoration: none;
}

.header-bell:hover {
  color: #3ebde6;
}

.header-bell__badge {
  position: absolute;
  top: -2px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  box-sizing: border-box;
  border: 2px solid #2d2e30;
  border-radius: 9px;
  background: #e5484d;
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  line-height: 14px;
  text-align: center;
}

@media (max-width: 768px) {
  .header-bell {
    margin-right: 6px;
  }
}


/* сообщение со ссылкой на незнакомый сайт - ждёт модератора / не доставлено (web 2.165.0) */
.chat-msg {
  flex-direction: column;
  align-items: flex-start;
}

.chat-msg--mine {
  align-items: flex-end;
}

.chat-msg--pending .chat-msg__bubble {
  opacity: .6;
}

.chat-msg--rejected .chat-msg__bubble {
  border: 1px dashed #cfd5db;
  background: none;
  color: #8a8f94;
}

.chat-msg--rejected .chat-msg__text a {
  color: #8a8f94;
}

.chat-msg__state {
  margin: 3px 4px 4px;
  font-size: 12px;
  color: #b5651d;
}

.chat__error--notice {
  color: #6b7178;
}


/* Поля формы - одинаково (web 2.170.11, просьба автора: «у полей разные расстояния»).
   На телефоне под выпадающим списком было 16px (style.css, .input-form__field--select) вместо 36px
   у остальных полей, а полю после списка добавлялось 20px сверху (2.165.4, чтобы подпись .float-label
   не прилипала) - два списка подряд стояли вплотную. Теперь 36px везде, добавка не нужна.
   Сам список - те же отступы и высота, что у поля ввода (было 0.6em 0.7em, 43px против 50px);
   справа 40px - под стрелку. Поле даты/времени - тоже 50px (было 46px). */
@media (max-width: 768px) {
  .input-form__field--select {
    margin-bottom: 36px;
  }
}

.input-form__select {
  padding: 12px 40px 12px 16px;
  min-height: 50px;
}

/* стрелка списка (две чёрточки на обёртке, style.css top: 20px - под прежние 43px) - по центру поля
   50px: 25px минус половина толщины чёрточки (web 2.170.29, просьба автора) */
.input-form__field--select::before,
.input-form__field--select::after {
  top: 24px;
}

.input-form__input {
  min-height: 50px;
}

/* textarea - строчный элемент: под ним оставался зазор под буквы (4px), и отступ до следующего
   поля был 40px вместо 36 */
textarea.input-form__input,
.input-form__textarea {
  vertical-align: top;
}


/* «Переписка удалена» над списком сообщений (web 2.166.1) */
.chat-list__flash {
  margin: 0 0 14px;
}


/* переписка: значок «заблокирован» на картинке, «Удалить» иконкой в шапке, «Разблокировать» зелёным (web 2.166.2) */
.chat__pic {
  position: relative;
  flex: none;
  display: inline-flex;
}

.chat__blocked-badge {
  position: absolute;
  right: -4px;
  bottom: -4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  box-sizing: border-box;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #d14343;
  color: #fff;
}

.chat-row__blocked {
  display: inline-flex;
  vertical-align: -1px;
  color: #d14343;
}

.chat__delete {
  flex: none;
  margin: 0;
}

.chat__delete-btn {
  border: 0;
  background: none;
}

.chat__delete-btn:hover {
  color: #d14343;
  background: #fdecec;
}

.chat__menu-item--ok {
  color: #1e8e4a;
}


/* корзина в шапке переписки - красная, без фона и обводки при наведении / фокусе (web 2.166.3, просьба автора) */
.chat__delete-btn,
.chat__delete-btn:hover,
.chat__delete-btn:focus,
.chat__delete-btn:active {
  color: #d14343;
  background: none;
  outline: none;
  box-shadow: none;
  -webkit-tap-highlight-color: transparent;
}


/* «Кому: «Бизнес»» в строке списка - во всю ширину рядом со счётчиком (web 2.166.5) */
.chat-row__bottom .chat-row__about {
  flex: 1;
  min-width: 0;
  font-size: 14px;
}

.chat-row--unread .chat-row__about {
  color: #1c1c1c;
  font-weight: 600;
}


/* ошибка причины жалобы (business-chat.js, web 2.166.6) */
.chat__report textarea.is-invalid {
  border-color: #d14343;
}

.chat__report textarea.is-invalid:focus {
  outline: none;
  border-color: #d14343;
  box-shadow: 0 0 0 2px rgba(192, 57, 43, .15);
}

.chat__report-error {
  margin: 6px 4px 2px;
  font-size: 13px;
  line-height: 1.35;
  color: #d14343;
}


/* поле сообщения - чуть ниже от черты над ним (web 2.166.7, просьба автора; было 10px) */
.chat__form {
  padding-top: 18px;
}

/* главная: карточки «Для жителей / Для владельцев бизнеса» - тот же фон, что у блока разделов (web 2.167.7; в style.css #f2f2f2) */
.for-block__text-block {
  background-color: #f3f9fc;
}

/* Блок «имя для связи» в формах вакансии и события: пояснение про контакты перенесено под него
   (web 2.170.24), и подпись поля (.float-label) прилипла к тому, что выше - галочке «Удалённая
   работа» / кнопке «Загрузить». Тот же отступ, что после пояснения (.input-page__desc + .input-form__inputs). */
.input-form__form .input-form__inputs--contacts {
  margin-top: 32px;
}

/* Окно с правилами / политикой / соглашением поверх формы (web 2.170.25, assets/js/script.js).
   Тень и скругление - как у остальных окон (2.170.1); текст - стили .info-page со страницы правил. */
.info-dialog {
  width: min(720px, calc(100vw - 32px));
  max-height: min(80vh, 760px);
  padding: 0;
  border: 0;
  border-radius: 12px;
  background-color: #ffffff;
  color: #1c1c1c;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.04);
  overflow: hidden;
}

.info-dialog[open] {
  display: flex;
  flex-direction: column;
}

.info-dialog::backdrop {
  background-color: rgba(28, 28, 28, 0.45);
}

.info-dialog__head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 12px 12px 24px;
  border-bottom: 1px solid #e3e8ef;
}

.info-dialog__title {
  flex: 1;
  margin: 0;
  font-size: 18px;
  line-height: 24px;
  font-weight: 700;
}

.info-dialog__close {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #6b6d70;
  cursor: pointer;
}

.info-dialog__close:hover,
.info-dialog__close:focus-visible {
  background-color: #eef1f4;
  color: #1c1c1c;
}

.info-dialog__body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  padding: 20px 24px 24px;
}

.info-dialog__status {
  margin: 0;
  color: #6b6d70;
}

/* страница под окном не прокручивается */
html.info-dialog-open {
  overflow: hidden;
}

@media (max-width: 767px) {
  .info-dialog {
    max-height: 85vh;
  }

  .info-dialog__head {
    padding-left: 16px;
  }

  .info-dialog__body {
    padding: 16px;
  }
}

/* заголовок окна - не общий стиль h2 (на телефоне тонкий и разреженный) */
.info-dialog .info-dialog__title {
  font-size: 18px;
  line-height: 24px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
}

.info-dialog__body:focus {
  outline: none;
}

/* окно правил - сразу полного размера (не прыгает, когда приходит текст; web 2.170.26) */
.info-dialog {
  height: min(80vh, 760px);
}

.info-dialog__loading {
  display: grid;
  place-items: center;
  min-height: 160px;
  height: 100%;
}

.info-dialog__spinner {
  width: 28px;
  height: 28px;
  border: 3px solid #e3e8ef;
  border-top-color: #3ebde6;
  border-radius: 50%;
  animation: info-dialog-spin 0.8s linear infinite;
}

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

@media (prefers-reduced-motion: reduce) {
  .info-dialog__spinner {
    animation-duration: 2.4s;
  }
}

@media (max-width: 767px) {
  .info-dialog {
    height: 85vh;
  }
}

/* «Отправка» поверх экрана при отправке формы (web 2.170.28, assets/js/script.js; вариант C со страницы-
   примера). Весь экран, а не только форма: длинные формы (визитка) выше экрана - надпись была бы не видна. */
.send-cover {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 12px;
  padding: env(safe-area-inset-top, 0px) 16px env(safe-area-inset-bottom, 0px);
  background-color: rgba(255, 255, 255, 0.96); /* плотнее, чем в примере: сквозь 0.88 просвечивала кнопка под надписью */
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0s 0.2s;
}

.send-cover.is-on {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.2s;
}

.send-cover__text {
  font-size: 18px;
  line-height: 24px;
  font-weight: 700;
  color: #1c1c1c;
}

.send-cover__bar {
  display: block;
  width: 200px;
  height: 6px;
  border-radius: 999px;
  background-color: #e9f7fc;
  overflow: hidden;
}

.send-cover__bar i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background-color: #3ebde6;
}

html.send-cover-open {
  overflow: hidden;
}

/* Окно правил на iPhone обрезалось сверху (прямые углы, шапка «прилипла» к краю; web 2.170.30, скриншот
   автора): 85vh в Safari - высота экрана БЕЗ учёта панелей браузера, окно выходило за видимую область.
   svh - видимая высота при показанных панелях; vh остаётся запасным для старых браузеров. */
.info-dialog {
  height: min(80vh, 760px);
  height: min(80svh, 760px);
  max-height: calc(100vh - 32px);
  max-height: calc(100svh - 32px);
}

/* шапка компактнее: 56px (border-box - иначе отступы прибавлялись к 56 и выходило 73), заголовок и
   крестик по центру; значок крестика (22px в кнопке 40px, 9px от её края) - с тем же отступом от края
   окна, что заголовок: 24px на компьютере, 16px на телефоне */
.info-dialog__head {
  box-sizing: border-box;
  min-height: 56px;
  padding: 8px 15px 8px 24px;
}

@media (max-width: 767px) {
  .info-dialog {
    height: 85vh;
    height: 85svh;
  }

  .info-dialog__head {
    padding: 8px 7px 8px 16px;
  }
}

/* окно правил больше (web 2.170.33, просьба автора): на телефоне - почти весь экран, по 16px сверху и снизу
   (как боковой отступ), на компьютере - до 86% высоты */
.info-dialog {
  height: min(86vh, 860px);
  height: min(86svh, 860px);
}

@media (max-width: 767px) {
  .info-dialog {
    height: calc(100vh - 32px);
    height: calc(100svh - 32px);
  }
}

/* Отступ перед подвалом - одинаковый на всех страницах (web 2.170.34, просьба автора): 80px, на телефоне 48px.
   Раньше складывался из разного: нижний отступ обёртки последней секции (40/60/80/100px), отступ последнего
   элемента (текст под формой 14px, карточка 20px) и min-height: 850px у main (style.css) - на страницах средней
   длины он добавлял пустое место, на телефоне тоже.
   Отступ - у последней секции (у цветной, как блог на главной, он внутри полосы - без белой щели над подвалом),
   у её обёртки и последних элементов - ноль. Подвал на коротких страницах прижат к низу экрана: main
   растягивается (flex), а не min-height 850px. */
body.body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100svh;
}

body.body > main.main {
  flex: 1 0 auto;
  min-height: 0;
}

body.body > header,
body.body > footer,
body.body > .footer {
  flex-shrink: 0;
}

/* min-height 400-700px у секций страниц (style.css) держал подвал внизу коротких страниц и давал под
   содержимым пустое место разной высоты - теперь подвал прижимает растягивание main (выше) */
.text-content-page__wrapper,
.category-page,
.subcategory-page,
.items-page,
.search-page,
.error-page,
.input-page__wrapper,
.user-account__wrapper,
.info-page,
.user_addings {
  min-height: 0;
}

main.main > :last-child {
  padding-bottom: 80px;
  margin-bottom: 0;
}

main.main > :last-child > [class*="__wrapper"] {
  padding-bottom: 0;
  margin-bottom: 0;
}

/* последние элементы, у которых свой отступ снизу (абзац под формой, карточка, заголовок, ссылка «назад») -
   два уровня внутрь обёртки; глубже не трогаем, чтобы не менять отступы внутри карточек */
.input-page .user-login__info:last-child,
.items-list__list > .items-list__item:last-child,
main.main > :last-child > [class*="__wrapper"] > :last-child,
main.main > :last-child > [class*="__wrapper"] > :last-child > :last-child {
  margin-bottom: 0;
}

/* глубже двух уровней - точечно: «нет событий» в расписании, «В архив» в документе, последний блок подкатегорий */
main.main > :last-child .est-empty:last-child,
main.main > :last-child .est-archive-row {
  margin-bottom: 0;
}

.subcategory-page__item-wrapper:last-child {
  padding-bottom: 0;
}

@media (max-width: 767px) {
  main.main > :last-child {
    padding-bottom: 96px; /* было 48 - мало (web 2.170.35, просьба автора) */
  }
}

/* окно правил на ПК шире: 960px (было 720), поля от краёв экрана не меньше 32px (web 2.170.42, просьба автора);
   на телефоне - как было */
@media (min-width: 768px) {
  .info-dialog {
    width: min(960px, calc(100vw - 64px));
    max-width: none;
  }
}

/* Все всплывающие окна на ПК шире (web 2.170.43, просьба автора). Только с 768px; на телефоне - как было.
   Вход и регистрация: 340 → 480px (style.css: width 300 + поля 20); выбор города: 700 → 880px.
   Подтверждение email и «Нужен аккаунт» - account.css / home.css, окна Estimator - estimator.css. */
@media (min-width: 768px) {
  .header__login-popup--popup_content {
    box-sizing: border-box;
    width: min(480px, calc(100vw - 32px));
    padding-left: 32px;
    padding-right: 32px;
  }

  .city-popup__popup {
    max-width: 880px;
  }
}

/* Ошибка у галочки «согласен с правилами» - под текстом, а не справа от него (web 2.170.44, просьба автора).
   Галочка, подпись и ошибка - в одной flex-строке (style.css .input-form__agree-terms); с тех пор как ошибка
   стала в потоке (2.170.16), она вставала в строку справа. Перенос + ошибка на всю ширину, по линии текста
   подписи (у подписи отступ слева под галочку). */
.input-form__agree-terms {
  flex-wrap: wrap;
}

.input-form__agree-terms > .input-form__error {
  flex-basis: 100%;
  margin-left: 32px;
}

/* согласие над кнопкой «Отправить» (каталог «Добавить», web 2.170.45) - от него до кнопки 32px */
.input-form__agree-terms--before-submit {
  margin-bottom: 32px;
}

/* Крестик «Очистить» в поле категории: символ ✖ на iPhone рисовался толстым -
   прячем символ и рисуем тонкий крестик линиями, по центру поля (web 2.170.48) */
.input-form__select-btn {
  top: 50%;
  right: 12px;
  width: 32px;
  height: 32px;
  margin-top: -16px;
  font-size: 0;
  line-height: 0;
  color: #8a8f94;
  border-radius: 6px;
}
.input-form__select-btn::before,
.input-form__select-btn::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 16px;
  height: 1.5px;
  margin: -0.75px 0 0 -8px;
  background: currentColor;
  border-radius: 1px;
  transform: rotate(45deg);
}
.input-form__select-btn::after {
  transform: rotate(-45deg);
}
.input-form__select-btn:hover {
  color: #d14343;
}

/* «Изменить» в «Мои визитки» - карандаш в слоте корзины (.user_addings__remove-btn), фирменный голубой (web 2.170.49) */
.user_addings__edit-btn {
  color: #1f8db3;
  text-decoration: none;
}
.user_addings__edit-btn:hover,
.user_addings__edit-btn:focus-visible {
  background: #e9f7fc;
  color: #1f8db3;
}

/* «Мои отзывы»: «Редактировать» - карандаш справа от текста отзыва (web 2.170.53).
   Колонка текста - на всю оставшуюся ширину, чтобы карандаш стоял у правого края */
.user_reviews__text-wrapper {
  flex: 1 1 auto;
  min-width: 0;
  align-self: stretch;
}
.user_reviews__text-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.user_reviews__text-row .user_reviews__desc {
  flex: 1 1 auto;
  min-width: 0;
}
.user_reviews__edit-btn {
  flex: 0 0 auto;
  margin-top: -5px; /* центр иконки - на первой строке текста */
}

/* ПК: иконки (карандаш, корзина) - не у правого края, а рядом с содержимым (web 2.170.54, просьба автора).
   Карточки: колонка текста фиксированной ширины - иконки встают ровным столбиком после неё.
   Отзывы: карандаш сразу за текстом, длинный текст переносится не шире 720px. */
@media (min-width: 769px) {
  .user_addings__text-wrapper {
    flex: 0 1 320px;
    min-width: 0;
  }
  .user_addings__remove {
    margin-left: 16px;
  }
  .user_reviews__text-row {
    max-width: 720px;
  }
  .user_reviews__text-row .user_reviews__desc {
    flex: 0 1 auto;
  }
}

/* Статистика бизнеса: «Перейти» и карандаш «Изменить» в одну строку (web 2.170.55).
   Кнопка карандаша 44x44 - отрицательным отступом не раздвигает строку */
.stats-head__links {
  align-items: center;
}
.stats-head__edit {
  margin: -11px 0;
}

/* Колонка «Категории» слева на странице подкатегории (web 2.170.56) - оформление .blog-side (blog.css),
   здесь только вложенный список подкатегорий открытого раздела */
.catalog-side__category--open {
  font-weight: 700;
}
.catalog-side__sublist {
  margin: 0 0 8px;
  padding: 0 0 0 12px;
  list-style: none;
  border-left: 2px solid #e9f7fc;
}
.catalog-side__sublink {
  padding: 6px 0;
  font-size: 13px;
  line-height: 20px;
}

/* Страница бизнеса на ПК: слева колонка «Категории» (view/catalog/v_catalog_side.php), справа все блоки страницы
   (web 2.170.57, просьба автора). Сетка у самого main, а не обёртка: main > :last-child и отступ перед футером
   не меняются. Крайние колонки 1fr центрируют пару «колонка + содержимое» в ширине 1124px, как в каталоге. */
@media (min-width: 1025px) {
  .main--with-side {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 835px) minmax(0, 1fr);
    align-items: start;
  }
  /* margin: auto у блоков (max-width 1124 + auto) в сетке сжимает их по содержимому - «Похожие»
     с горизонтальной лентой вылезали вправо; без боковых auto блок растягивается ровно по колонке */
  .main--with-side > * {
    grid-column: 3;
    min-width: 0;
    margin-left: 0;
    margin-right: 0;
  }
  .main--with-side > .breadcrumbs {
    grid-column: 1 / -1;
  }
  .main--with-side > .catalog-side {
    grid-column: 2;
    grid-row: 2 / span 30;
    align-self: start;
  }
}

/* Страница на телефоне ездила вбок (web 2.170.75, скриншот автора: справа тёмная полоса - фон body).
   Страховка от любого вылезшего за экран элемента: clip, а не hidden - hidden сделал бы body прокручиваемым
   контейнером и сломал position: sticky. (Правка меню из 2.170.75 откачена в 2.170.77: оно стало медленнее
   открываться, а на сдвиг страницы, по словам автора, не влияло.) */
html,
body {
  overflow-x: clip;
}
