/* ==========================================================================
   Подписка на рассылку — инлайн-форма
   ========================================================================== */

/* ---------- Контейнер ---------- */
.form-subscribe {
  box-sizing: border-box;
  width: 100%;
  max-width: 1373px;
  padding: 40px 48px;
  margin: 0 auto;
  background: linear-gradient(281.5deg, #FAFCFF 0.18%, #EEF0F5 100%);
  border-radius: 20px;
  font-family: 'Inter', Arial, sans-serif;
  color: #3E4653;
  font-size: 15px;
  line-height: 1.45;
}

/* ---------- Двухколоночный layout ---------- */
.sub-form__layout {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 48px;
  flex-wrap: wrap;
}

.sub-form__left  { flex: 1 1 320px; max-width: 480px; }
.sub-form__right { flex: 1 1 360px; max-width: 480px; position: relative; }

/* ---------- Левая колонка ---------- */
.sub-form__title {
  margin: 0 0 12px;
  font-size: 24px;
  font-weight: 600;
  line-height: 30px;
  color: #3E4653;
}

.sub-form__subtitle {
  margin: 0;
  font-size: 14px;
  line-height: 20px;
  color: #6b7484;
}

/* ---------- Поля ---------- */
.sub-form .fb-field {
  position: relative;
  margin-bottom: 18px;
}

.sub-form .fb-field__input {
  width: 100%;
  box-sizing: border-box;
  padding: 16px 14px 8px;
  font-size: 15px;
  color: #3E4653;
  background: #fff;
  border: 1px solid #BBC7D8;
  border-radius: 15px;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
  font-family: inherit;
}

.sub-form .fb-field__input:focus {
  border-color: #3E4653;
  box-shadow: 0 0 0 3px rgba(62, 70, 83, .1);
}

.sub-form .fb-field__label {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 15px;
  color: #8a94a3;
  pointer-events: none;
  transition: all .18s ease;
  background: #fff;
  padding: 0 4px;
  z-index: 1;
}

.sub-form .fb-field:hover .fb-field__label,
.sub-form .fb-field__input:focus + .fb-field__label,
.sub-form .fb-field__input:not(:placeholder-shown) + .fb-field__label {
  top: 0;
  font-size: 12px;
  color: #3E4653;
}

/* ---------- E-mail + кнопка в одну строку ---------- */
.sub-form .sub-form__row {
  display: flex;
  align-items: flex-end;
  gap: 15px;
  margin-bottom: 18px;
}

.sub-form .sub-form__row-field {
  flex: 1 1 auto;
  min-width: 0;
  margin-bottom: 0;
}

.sub-form .sub-form__row-submit {
  flex: 0 0 auto;
  margin: 0;
  white-space: nowrap;
}

/* ---------- Согласия ---------- */
.sub-form .fb-form-consents {
  margin-top: 0;
}

.sub-form .dlv-checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.sub-form .dlv-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  user-select: none;
  font-size: 13px;
  line-height: 1.45;
  color: #6b7484;
  margin: 0 0 6px;
}

.sub-form .dlv-checkbox__box {
  position: relative;
  width: 20px;
  height: 20px;
  border: 1px solid #BBC7D8;
  border-radius: 5px;
  background: #fff;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
  transition: border-color .2s;
}

.sub-form .dlv-checkbox__box::after {
  content: "";
  width: 12px;
  height: 12px;
  background: #3E4653;
  border-radius: 2px;
  transform: scale(0);
  transition: transform .15s ease;
}

.sub-form .dlv-checkbox:hover .dlv-checkbox__box { border-color: #3E4653; }
.sub-form .dlv-checkbox input:checked + .dlv-checkbox__box { border-color: #3E4653; }
.sub-form .dlv-checkbox input:checked + .dlv-checkbox__box::after { transform: scale(1); }

.sub-form .dlv-checkbox__text { display: inline; }
.sub-form .dlv-checkbox__text a {
  color: #3E4653;
  text-decoration: underline;
}
.sub-form .dlv-checkbox__text a:hover { text-decoration: none; }

.sub-form .dlv-personalInfo__error {
  color: #e04242;
  font-size: 12px;
  margin: 0 0 6px;
  display: none;
}
.sub-form .dlv-personalInfo__error.is-visible { display: block; }

/* ---------- Кнопка ---------- */
.sub-form .fb-submit {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 10px 15px;
  background: #3E4653;
  border-radius: 10px;
  border: none;
  color: #fff;
  font-size: 15px;
  font-weight: 500;
  font-family: inherit;
  line-height: 1.2;
  cursor: pointer;
  transition: background .2s, transform .15s;
}

.sub-form .fb-submit:hover { background: #4c5564; }
.sub-form .fb-submit:active { transform: scale(.98); }
.sub-form .fb-submit:disabled { opacity: .6; cursor: not-allowed; }

/* ---------- Экран успеха (справа от левой колонки) ---------- */
.sub-form__right .fb-success {
  display: none;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 20px 0;
}

.sub-form__right .fb-success.is-visible {
  display: flex;
  min-height: 220px;
  justify-content: center;
}

.form-subscribe .fb-success__icon {
  width: 59px;
  height: 42px;
  margin-bottom: 18px;
}

.form-subscribe .fb-success__title {
  margin: 0 0 30px;
  font-size: 18px;
  font-weight: 600;
  line-height: 22px;
  color: #64A12F;
}

.form-subscribe .fb-success__text {
  margin: 0;
  font-size: 15px;
  line-height: 21px;
  color: #3E4653;
}

/* ---------- Адаптив ---------- */
@media (max-width: 900px) {
  .form-subscribe { padding: 32px 24px; }
  .sub-form__layout { flex-direction: column; gap: 24px; }
  .sub-form__left,
  .sub-form__right { max-width: 100%; flex: 1 1 auto; }
  .sub-form__title { font-size: 20px; line-height: 26px; }
}

@media (max-width: 520px) {
  .sub-form .sub-form__row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .sub-form .sub-form__row-submit {
    width: 100%;
  }
}