/*
  Форма «Заявка на консультацию и подбор добавок» (страница /form/).
  Все селекторы начинаются с .nf — со стилями темы не пересекаются. Шрифт — как на сайте (наследуется).
  Фирменный оранжевый сайта — #f15a29. Проверено на ширине экрана от 360 px.
*/
.nf,
.nf *,
.nf *::before,
.nf *::after { box-sizing: border-box; }

.nf {
  --nf-orange: #f15a29;
  --nf-orange-dark: #d94a1b;
  --nf-text: #1b1d1f;
  --nf-muted: #6b7075;
  --nf-line: #c9cdd2;
  --nf-red: #dc3545;
  max-width: 720px;
  margin: 0 auto;
  padding: 0 0 56px;
  color: var(--nf-text);
  font-size: 16px;
  line-height: 1.4;
}

.nf-note { margin: 0 0 20px; color: var(--nf-muted); font-size: 14px; }
.nf-req { color: var(--nf-orange); font-weight: 700; }

.nf-form { margin: 0; padding: 0; }

.nf-field { position: relative; margin: 0 0 20px; padding: 0; border: 0; min-width: 0; }
.nf-label,
.nf-legend {
  display: block;
  margin: 0 0 6px;
  padding: 0;
  font-size: 15px;
  font-weight: 500;
  color: var(--nf-text);
}

.nf-input {
  display: block;
  width: 100%;
  height: 48px;
  margin: 0;
  padding: 10px 14px;
  border: 1px solid var(--nf-line);
  border-radius: 6px;
  background: #fff;
  color: var(--nf-text);
  font: inherit;
  font-size: 16px;               /* не меньше 16px, иначе iOS увеличивает страницу при фокусе */
  line-height: 1.3;
  box-shadow: none;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}
.nf-input::placeholder { color: #8a9096; opacity: 1; }
.nf-input:hover { border-color: #aeb3b9; }
.nf-input:focus { outline: 0; border-color: var(--nf-orange); box-shadow: 0 0 0 3px rgba(241, 90, 41, 0.2); }

/* ошибка: прозрачный красный фон поля + сообщение под ним */
.nf-field.is-invalid .nf-input { border-color: var(--nf-red); background-color: rgba(220, 53, 69, 0.12); }
.nf-field.is-invalid .nf-input:focus { box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.2); }
.nf-field.is-invalid .nf-box { background-color: rgba(220, 53, 69, 0.12); border-color: var(--nf-red); }
.nf-error {
  display: none;
  margin: 6px 0 0;
  color: #c4202f;
  font-size: 14px;
  line-height: 1.3;
}

/* автоподбор региона */
.nf-combo { position: relative; }
.nf-list {
  display: none;
  position: absolute;
  z-index: 20;
  left: 0;
  right: 0;
  top: 100%;
  margin: 4px 0 0;
  padding: 4px 0;
  max-height: 260px;
  overflow-y: auto;
  list-style: none;
  background: #fff;
  border: 1px solid var(--nf-line);
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14);
}
.nf-option { margin: 0; padding: 10px 14px; cursor: pointer; font-size: 16px; line-height: 1.3; }
.nf-option:hover,
.nf-option.is-active { background: rgba(241, 90, 41, 0.12); }

/* флажки */
.nf-box {
  display: flex;
  align-items: flex-start;
  margin: 0 0 8px;
  padding: 10px 12px;
  border: 1px solid var(--nf-line);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}
.nf-box:hover { border-color: #aeb3b9; }
.nf-box input {
  flex: none;
  width: 22px;
  height: 22px;
  margin: 1px 12px 0 0;
  accent-color: var(--nf-orange);
  cursor: pointer;
}
.nf-box input:focus-visible { outline: 3px solid rgba(241, 90, 41, 0.45); outline-offset: 2px; }
.nf-box span { font-size: 16px; line-height: 1.35; }
.nf-box--consent { border: 0; padding: 4px 0; background: transparent; }
.nf-box--consent:hover { border-color: transparent; }
.nf-field.is-invalid .nf-box--consent { background-color: rgba(220, 53, 69, 0.12); border: 1px solid var(--nf-red); padding: 10px 12px; }
.nf-box a { color: var(--nf-orange); text-decoration: underline; }
.nf-box a:hover { text-decoration: none; }

/* кнопка */
.nf-actions { margin: 28px 0 0; }
.nf-btn {
  display: inline-block;
  min-width: 220px;
  min-height: 52px;
  margin: 0;
  padding: 14px 36px;
  border: 0;
  border-radius: 6px;
  background: var(--nf-orange);
  color: #fff;
  font: inherit;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-align: center;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  transition: background-color 0.15s ease, box-shadow 0.15s ease;
}
.nf-btn:hover { background: var(--nf-orange-dark); }
.nf-btn:focus-visible { outline: 3px solid rgba(241, 90, 41, 0.45); outline-offset: 3px; }
.nf-btn:disabled { opacity: 0.65; cursor: progress; }

.nf-status { min-height: 1.4em; margin: 14px 0 0; font-size: 15px; }
.nf-status.is-error { color: #c4202f; }

/* поле-ловушка: человеку не видно */
.nf-hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* сообщение после отправки */
.nf-done {
  display: none;
  margin: 8px 0 0;
  padding: 28px 28px 28px 32px;
  border-left: 6px solid var(--nf-orange);
  border-radius: 6px;
  background: rgba(241, 90, 41, 0.08);
  font-size: 22px;
  line-height: 1.35;
  font-weight: 500;
}
.nf-done:focus { outline: 0; }

@media (max-width: 480px) {
  .nf { padding-bottom: 40px; }
  .nf-btn { display: block; width: 100%; min-width: 0; }
  .nf-done { padding: 22px 18px 22px 22px; font-size: 19px; }
}
