/* Moment: привязка Yii ActiveForm к геометрии прототипа. Основная геометрия — style.css из newtpl2. */
[hidden] { display: none !important; }

.next-bank-context { margin-inline: auto; }
.details-card > .next-data-trust { margin-top: 18px; }
.primary-button { text-align: center; text-decoration: none; }

/* DaData вставляет обёртку после input: она не должна становиться колонкой flex. */
.field-mainform-fullname .input-shell { position: relative; }
.field-mainform-fullname .suggestions-wrapper {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
}
.field-mainform-fullname .suggestions-suggestions {
    margin-top: 5px;
    border-color: #d9e1ec;
    border-radius: 13px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(39, 60, 83, .12);
}
.field-mainform-fullname .suggestions-suggestion { padding: 10px 14px; }

/* Паритет с tailwind-preflight эталона (мы не тянем tailwind):
   базовая высота строки и наследование жирности заголовков. */
html { line-height: 1.5; }
h1, h2, h3, h4, h5, h6 { font-weight: inherit; }

/* Ошибка Yii идёт после оболочки ввода и не меняет её высоту. */
.input-shell .form-control,
.select-shell .form-control { flex: 1; }
.field > .help-block {
    margin: 6px 2px 0;
    color: #c03221;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;
}
.field > .help-block:empty { display: none; }
.field.has-error .input-shell,
.field.has-error .select-shell { border-color: #e2604f; box-shadow: 0 0 0 4px rgba(224, 82, 61, .1); }
.field > span:first-child:not(.field-label-row) { display: block; }
@media (min-width: 801px) {
    .lead-card > .field { align-self: start; }
    .lead-card > .primary-button { align-self: start; margin-top: 27px; }
}

/* Чекбоксы согласий Yii внутри .lead-consents: label — grid 18px+текст,
   скрытый input и пустой help-block не должны участвовать в сетке. */
.lead-consents input[type="checkbox"] {
    width: 16px;
    height: 16px;
    flex: none;
    accent-color: var(--blue);
    cursor: pointer;
}
.lead-consents label .help-block:empty { display: none; }
.lead-consents label .help-block:not(:empty) {
    grid-column: 1 / -1;
    margin: 2px 0 0;
    color: #c03221;
    font-size: 10px;
    font-weight: 600;
    line-height: 1.4;
}

/* Вопрос банковского FAQ — обычный текст, а не иконка summary из эталона. */
.faq-list summary [data-bank-faq-q] {
    width: auto;
    height: auto;
    display: inline;
    background: none;
    color: inherit;
    font-size: inherit;
    transform: none;
}
.faq-list details[open] summary [data-bank-faq-q] { transform: none; }

/* Модалка дублей (?d=1): базовый оверлей, карточки — из _offers. */
.double-offers-layout {
    position: fixed;
    inset: 0;
    z-index: 120;
    padding: 18px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    overflow-y: auto;
    background: rgba(16, 42, 67, .55);
}
.double-offers-inner {
    width: min(720px, 100%);
    margin: auto;
    padding: 24px;
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--shadow);
}
.double-offers-title { margin-bottom: 16px; color: var(--navy); font-size: 17px; font-weight: 750; }
.double-offers-inner .offers { display: grid; gap: 12px; }
.double-offers-inner .offer {
    padding: 14px;
    display: grid;
    gap: 8px;
    border: 1px solid var(--line);
    border-radius: 16px;
}
.double-offers-inner .offer__button {
    padding: 12px 16px;
    border-radius: 12px;
    color: #fff;
    background: var(--blue);
    text-align: center;
    text-decoration: none;
    font-weight: 750;
}

/* Sticky CTA: видимостью управляет класс visible из site.js (состояния — в style.css). */
@media (prefers-reduced-motion: reduce) {
    .mobile-sticky-cta,
    .mobile-sticky-cta::before { transition: none; }
}
