/* Страницы авторизации: вход, регистрация, подтверждение, восстановление пароля.
   2026-08-18. Все классы с префиксом tb-auth — не пересекаются с общими стилями. */

.tb-auth-wrap {
  display: flex;
  justify-content: center;
  padding: 44px 16px 64px;
}

.tb-auth {
  width: 100%;
  max-width: 430px;
  background: #fff;
  border: 1px solid #ececec;
  border-radius: 18px;
  box-shadow: 0 12px 44px rgba(25, 25, 25, 0.07);
  padding: 38px 34px 32px;
  box-sizing: border-box;
  font-size: 14px;
  color: #1a1a1a;
}

.tb-auth *, .tb-auth *:before, .tb-auth *:after { box-sizing: border-box; }

.tb-auth__title {
  font-family: "Montserrat Bold", sans-serif;
  font-size: 22px;
  line-height: 1.3;
  text-align: center;
  color: #1a1a1a;
  margin: 0 0 8px;
}

.tb-auth__subtitle {
  font-size: 14px;
  line-height: 1.55;
  text-align: center;
  color: #7a7a7a;
  margin: 0 0 24px;
}

.tb-auth__field { margin-bottom: 12px; }

.tb-auth__input {
  width: 100%;
  height: 48px;
  border: 1px solid #e2e2e2;
  border-radius: 12px;
  padding: 0 16px;
  font-size: 15px;
  font-family: inherit;
  color: #1a1a1a;
  background: #fff;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.tb-auth__input:focus {
  border-color: #dd1552;
  box-shadow: 0 0 0 3px rgba(221, 21, 82, 0.08);
}

.tb-auth__input::placeholder { color: #a8a8a8; }

/* автозаполнение Chrome красит поля в голубой — возвращаем белый */
.tb-auth__input:-webkit-autofill,
.tb-auth__input:-webkit-autofill:hover,
.tb-auth__input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px #fff inset;
  -webkit-text-fill-color: #1a1a1a;
  transition: background-color 5000s ease-in-out 0s;
}

.tb-auth__submit {
  display: block;
  width: 100%;
  background: #dd1552;
  color: #fff;
  border: 0;
  border-radius: 33px;
  padding: 15px 0;
  font-size: 16px;
  font-family: "Montserrat Medium", sans-serif;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  margin-top: 8px;
  transition: background-color 0.3s, transform 0.15s;
}

.tb-auth__submit:hover {
  background: #c11549;
  color: #fff;
  text-decoration: none;
}

.tb-auth__submit:active { transform: scale(0.985); }

.tb-auth__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 18px;
  font-size: 13px;
}

.tb-auth__remember {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #666;
  cursor: pointer;
  margin: 0;
  font-weight: normal;
}

.tb-auth__remember input {
  /* display:inline-block!important — глобальный стиль сайта прячет нативные чекбоксы */
  display: inline-block !important;
  width: 16px;
  height: 16px;
  accent-color: #dd1552;
  margin: 0;
  cursor: pointer;
}

.tb-auth__link {
  color: #777;
  text-decoration: none;
  border-bottom: 1px solid rgba(119, 119, 119, 0.35);
  transition: color 0.2s, border-color 0.2s;
  cursor: pointer;
}

.tb-auth__link:hover {
  color: #dd1552;
  border-color: rgba(221, 21, 82, 0.4);
  text-decoration: none;
}

.tb-auth__footer {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid #f1f1f1;
  text-align: center;
  font-size: 14px;
  color: #7a7a7a;
}

.tb-auth__footer .tb-auth__link { margin-left: 4px; }

/* сообщения об ошибках (в т.ч. вывод ShowMessage/ShowNote Битрикса) */
.tb-auth__error,
.tb-auth__msg .errortext {
  display: block;
  background: #fdf0f4;
  border: 1px solid #f4c6d5;
  color: #b3123f;
  border-radius: 12px;
  padding: 11px 15px;
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 14px;
}

.tb-auth__msg .notetext {
  display: block;
  background: #eef8f1;
  border: 1px solid #c4e6cf;
  color: #217a43;
  border-radius: 12px;
  padding: 11px 15px;
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 14px;
}

.tb-auth__msg br { display: none; }

/* экран успеха: иконка + сообщение */
.tb-auth__ok { text-align: center; padding: 4px 0 2px; }

.tb-auth__ok-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tb-auth__ok-icon--green { background: #eaf7ef; }
.tb-auth__ok-icon--pink { background: #fdeef3; }

.tb-auth__ok-text {
  font-size: 14px;
  line-height: 1.6;
  color: #555;
  margin: 0 0 6px;
}

.tb-auth__ok-text b { color: #1a1a1a; word-break: break-all; }

.tb-auth__ok .tb-auth__submit { margin-top: 18px; }

@media (max-width: 480px) {
  .tb-auth-wrap { padding: 24px 12px 40px; }
  .tb-auth { padding: 28px 20px 24px; border-radius: 14px; }
}

/* ---- модалка авторизации (popup_1, fancybox) ---- */

.popup.popup_1 {
  width: 420px !important;
  max-width: calc(100vw - 20px) !important;
  background: #fff !important;
  padding: 30px 28px !important;
}

.tb-auth--flat {
  border: 0;
  box-shadow: none;
  background: transparent;
  padding: 0;
  max-width: none;
  border-radius: 0;
}

.tb-auth__tabs {
  display: flex;
  margin-bottom: 22px;
  background: #f3f3f5;
  border-radius: 12px;
  padding: 4px;
}

.tb-auth__tab {
  flex: 1;
  border: 0;
  background: transparent;
  border-radius: 9px;
  padding: 10px 0;
  font-size: 14px;
  font-family: "Montserrat Medium", sans-serif;
  color: #777;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s, box-shadow 0.2s;
}

.tb-auth__tab--active {
  background: #fff;
  color: #1a1a1a;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.tb-auth__pane[hidden] { display: none; }
