/* Вход и регистрация (Figma 1:22534 desktop, 1:22749 mobile) */

.auth {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding-bottom: 80px;
}

.auth-card {
  display: flex;
  flex-direction: column;
  gap: 24px;
  flex: 1 1 0;
  min-width: 0;
  max-width: 580px;
  padding: 40px;
  border: 1px solid #e6e6e6;
  border-radius: 16px;
  background: var(--bg-white);
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.04));
}

.auth-card__title {
  font-weight: var(--fw-bold);
  font-size: 24px;
  color: var(--text-dark-900);
}

.auth-card__form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.auth-field__label {
  font-weight: var(--fw-bold);
  font-size: 14px;
  color: var(--text-dark-900);
}

.auth-field__label b {
  color: #ff6b6b;
}

.auth-field__input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #e6e6e6;
  border-radius: 8px;
  background: #f5f5f5;
  font-size: 14px;
  outline: none;
}

.auth-field__input::placeholder {
  color: var(--text-gray-300);
}

.auth-field__input.is-error {
  border-color: var(--error);
}

.auth-card__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.auth-check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-gray-600);
  cursor: pointer;
}

.auth-check input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--yellow-500);
}

.auth-card__forgot {
  font-weight: var(--fw-bold);
  font-size: 13px;
  color: #005b9e;
}

.auth-card__submit {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 40px;
  margin-top: 8px;
  padding: 10px 25px;
  border-radius: 90px;
  background: var(--yellow-500);
  font-weight: var(--fw-bold);
  font-size: 14px;
  text-transform: uppercase;
  color: var(--text-brown-dark);
}

.auth-card__submit:hover {
  background: var(--yellow-450);
}

.auth-card__note {
  font-size: 12px;
  line-height: 18px;
  color: var(--text-gray-600);
}

.auth-card__divider {
  width: 100%;
  height: 1px;
  margin: 0;
  border: none;
  background: #e6e6e6;
}

.auth-benefits {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.auth-benefits__title {
  font-weight: var(--fw-bold);
  font-size: 14px;
  color: var(--text-dark-900);
}

.auth-benefits__list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-benefits__list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text-dark-900);
}

/* Адаптив (Figma 1:22749 mobile) */
@media (max-width: 1023px) {
  .auth {
    flex-direction: column;
    align-items: stretch;
  }

  .auth-card {
    max-width: none;
  }
}

@media (max-width: 767px) {
  .auth {
    gap: 16px;
    padding-bottom: 48px;
  }

  .auth-card {
    padding: 24px 20px;
    gap: 20px;
  }

  .auth-card__title {
    font-size: 20px;
  }
}

/* --- Регистрация = заявка дилера: подпись, согласие, успех --- */
.auth-card__lead {
  margin: -8px 0 4px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--text-gray-blue);
}

.auth-check--policy {
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  line-height: 1.4;
}

/* Скрытый блок успеха: display:flex перебивал бы атрибут hidden */
.auth-success[hidden] {
  display: none;
}

.auth-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 24px 20px;
  border: 1px solid var(--border-200);
  border-radius: 12px;
  background: #f6fbf7;
  text-align: center;
}

.auth-success__circle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #e8f5e9;
}

.auth-success__title {
  font-weight: var(--fw-bold);
  font-size: 18px;
  color: var(--text-dark-900);
}

.auth-success__text {
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-gray-blue);
}

/* Не отмечено согласие на обработку данных */
.auth-check.is-error span {
  color: #b32d2e;
}

.auth-check.is-error input[type="checkbox"] {
  outline: 2px solid #b32d2e;
  outline-offset: 1px;
}

/* ── Заявка на регистрацию: выбор типа клиента и новые поля (ТЗ 28.07.2026) ── */
.auth-card__note {
  margin: -4px 0 0;
  font-size: 13px;
  line-height: 1.45;
  color: var(--text-gray-blue, #64748b);
}

.auth-card__switch {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border-light, #e5e7eb);
  text-align: center;
}

.auth-card__switch-title {
  margin: 0 0 10px;
  font-size: 15px;
  color: var(--text-dark-900, #0f172a);
}

.auth-card__switch-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 48px;
  padding: 0 20px;
  border: 1px solid var(--text-dark-900, #0f172a);
  border-radius: 8px;
  background: transparent;
  font-weight: var(--fw-medium, 500);
  font-size: 15px;
  color: var(--text-dark-900, #0f172a);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.auth-card__switch-btn:hover {
  background: var(--text-dark-900, #0f172a);
  color: #ffffff;
}

/* Карточки выбора типа клиента */
.auth-types {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 4px;
}

.auth-type {
  display: block;
  padding: 16px 18px;
  border: 1px solid var(--border-light, #e5e7eb);
  border-radius: 12px;
  background: var(--bg-white, #ffffff);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.auth-type:hover {
  border-color: var(--brand-yellow, #ffe400);
  transform: translateY(-1px);
}

.auth-type__name {
  display: block;
  font-weight: var(--fw-medium, 500);
  font-size: 15px;
  color: var(--text-dark-900, #0f172a);
}

.auth-type__desc {
  display: block;
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--text-gray-blue, #64748b);
}

/* Ответ частному лицу */
.auth-person {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 20px;
  border-radius: 12px;
  background: var(--bg-gray-light, #f8fafc);
}

.auth-person[hidden] {
  display: none;
}

.auth-person__text {
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-dark-900, #0f172a);
}

.auth-person__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.auth-card__submit--inline {
  width: auto;
  min-width: 190px;
  text-decoration: none;
}

.auth-card__submit--ghost {
  width: auto;
  min-width: 190px;
  background: transparent;
  border: 1px solid var(--border-light, #e5e7eb);
  color: var(--text-dark-900, #0f172a);
  text-decoration: none;
}

.auth-card__back {
  margin-top: 4px;
  padding: 0;
  border: none;
  background: none;
  font-size: 14px;
  color: var(--text-gray-blue, #64748b);
  text-decoration: underline;
  cursor: pointer;
}

.auth-card__back:hover {
  color: var(--text-dark-900, #0f172a);
}

/* Селекты формы */
.auth-field__select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%2364748b' stroke-width='1.6' d='m1 1 5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
  cursor: pointer;
}

/* Способ получения доступа */
.auth-access {
  margin: 0;
  padding: 16px;
  border: 1px solid var(--border-light, #e5e7eb);
  border-radius: 12px;
}

.auth-access__item {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  font-size: 15px;
  color: var(--text-dark-900, #0f172a);
  cursor: pointer;
}

.auth-access__item input {
  width: 18px;
  height: 18px;
  accent-color: var(--brand-yellow, #ffe400);
}

/* Ссылка «Уже есть профиль?» под формой */
.auth-card__login-hint {
  margin: 16px 0 0;
  font-size: 14px;
  color: var(--text-gray-blue, #64748b);
  text-align: center;
}

.auth-card__login-link {
  padding: 0;
  border: none;
  background: none;
  font-size: 14px;
  font-weight: var(--fw-medium, 500);
  color: var(--text-dark-900, #0f172a);
  text-decoration: underline;
  cursor: pointer;
}

.auth-success__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 8px;
}

@media (max-width: 767px) {
  .auth-person__actions,
  .auth-success__actions {
    flex-direction: column;
  }

  .auth-card__submit--inline,
  .auth-card__submit--ghost {
    width: 100%;
  }
}
