/* Страница «Гарантии» — вёрстка по Figma (узлы 161:13241 / 161:13268 / 161:13295) */

body.guarantees-page {
    background: #F5F5F5;
}

/* ---- Баннер (структура как на «Ипотеке») ---- */

.guarantees-banner-block {
    margin-bottom: 38px;
}

.guarantees-banner {
    width: 100%;
    display: flex;
    gap: 16px;
    height: 270px;
}

.guarantees-banner__info {
    flex: 1;
    min-width: 0;
    display: flex;
    gap: 18px;
    align-items: stretch;
    overflow: hidden;
    border-radius: 4px;
    background: var(--Surface-White, #FFFFFF);
    padding-right: 16px;
}

.guarantees-banner__illustration {
    flex-shrink: 0;
    width: 349px;
    height: 270px;
    object-fit: cover;
    display: block;
}

.guarantees-banner__text {
    flex: 1;
    min-width: 0;
    padding: 30px 0;
    display: flex;
    flex-direction: column;
    gap: 17px;
}

.guarantees-banner__title {
    margin: 0;
    font-size: 22px;
    font-weight: 500;
    line-height: 24px;
    color: var(--Text-Primary, #1E2433);
}

.guarantees-banner__desc {
    margin: 0;
    font-size: 14px;
    font-weight: 400;
    line-height: 18px;
    color: var(--Text-Primary, #1E2433);
}

.guarantees-banner__desc + .guarantees-banner__desc {
    margin-top: -17px; /* абзацы идут подряд с пустой строкой по макету */
    padding-top: 18px;
}

.guarantees-banner__promo {
    position: relative;
    flex: 0 0 446.67px;
    border-radius: 4px;
    overflow: hidden;
    background: var(--Brand-Secondary, #454452);
}

.guarantees-banner__house-icon {
    position: absolute;
    width: 252px;
    height: 252px;
    left: calc(50% + 166.33px - 126px);
    top: calc(50% - 9px - 126px);
}

.guarantees-banner__arrow {
    position: absolute;
    left: 172px;
    top: 66px;
    width: 101px;
    height: 97px;
}

.guarantees-banner__promo-title {
    position: absolute;
    left: 20px;
    top: 46px;
    transform: translateY(-50%);
    width: 338px;
    margin: 0;
    font-size: 22px;
    font-weight: 500;
    line-height: 1.2;
    color: #FFFFFF;
}

.guarantees-banner__promo-sub {
    position: absolute;
    left: 20px;
    top: 91px;
    transform: translateY(-50%);
    margin: 0;
    font-size: 14px;
    font-weight: 400;
    line-height: 1;
    color: #FFFFFF;
    white-space: nowrap;
}

.btn.guarantees-banner__promo-btn {
    position: absolute;
    left: 20px;
    top: 198px;
    width: 406px;
}

/* ---- Договоры ---- */

.guarantees-docs-block {
    margin-bottom: 82px;
}

.guarantees-docs {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 24px;
    align-items: center;
}

.guarantees-docs__lead {
    margin: 0;
    max-width: 584px;
    font-size: 18px;
    font-weight: 500;
    line-height: 22px;
    text-align: center;
    color: #1E2529;
}

.guarantees-docs__cards {
    display: flex;
    gap: 12px;
    align-items: stretch;
}

.doc-card {
    width: 355px;
    box-sizing: border-box;
    background: var(--Surface-White, #FFFFFF);
    border-radius: 8px;
    padding: 22px;
    display: flex;
    gap: 23px;
    align-items: center;
}

.doc-card__icon {
    flex-shrink: 0;
    width: 83px;
    height: 83px;
    display: block;
}

.doc-card__content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 19px;
    align-items: flex-start;
}

.doc-card__name {
    margin: 0;
    font-size: 16px;
    font-weight: 400;
    color: var(--Text-Primary, #1E2433);
}

.doc-card__link {
    font-size: 18px;
    font-weight: 500;
    line-height: 1;
    color: var(--Brand-Primary, #D5A944);
    text-decoration: underline;
}

/* ---- Схема работы ---- */

.guarantees-steps-block {
    margin-bottom: 60px;
}

.guarantees-steps__title {
    margin: 0 0 32px;
    width: 100%;
    line-height: 38px;
    text-align: center;
    color: #1E2529;
}

.guarantees-steps {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.step-card {
    height: 193px;
    background: #E9EAEC;
    border-radius: 4px;
    overflow: hidden;
    display: flex;
    gap: 30px;
    align-items: center;
    padding-right: 32px;
}

.step-card__image {
    flex: 1;
    min-width: 0;
    height: 100%;
}

.step-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.step-card__content {
    flex-shrink: 0;
    width: 258px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.step-card__title {
    margin: 0;
    font-size: 18px;
    font-weight: 500;
    line-height: 22px;
    color: #1E2529;
}

.step-card__body {
    margin: 0;
    font-size: 14px;
    font-weight: 400;
    line-height: 18px;
    color: #757575;
}

/* ---- Laptop (Figma-фрейм 990) ---- */

@media (max-width: 1279px) {
    .guarantees-banner-block {
        margin-bottom: 60px;
    }

    .guarantees-banner__illustration {
        display: none;
    }

    .guarantees-banner__info {
        padding: 0 30px;
        min-width: 280px;
    }

    .guarantees-banner__promo {
        flex-shrink: 1;
        min-width: 400px;
    }

    .guarantees-docs-block {
        margin-bottom: 60px;
    }

    .step-card {
        height: 160px;
        padding-right: 24px;
        gap: 20px;
    }
}

/* ---- Mobile (Figma-фрейм 360) ---- */

@media (max-width: 768px) {
    .guarantees-banner-block {
        display: none;
    }

    .guarantees-docs-block {
        margin-bottom: 40px;
    }

    .guarantees-docs__cards {
        flex-direction: column;
        width: 100%;
        gap: 12px;
    }

    .doc-card {
        width: 100%;
        min-height: 127px;
    }

    .guarantees-steps {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    /* по макету на мобильном первой идёт карточка «Общаемся по телефону» */
    .step-card--phone-first {
        order: -1;
    }

    .step-card {
        height: auto;
        flex-direction: column;
        align-items: stretch;
        gap: 20px;
        padding: 0 0 12px;
    }

    .step-card__image {
        flex: none;
        width: 100%;
        height: 222px;
        border-radius: 4px 4px 0 0;
        overflow: hidden;
    }

    .step-card__content {
        width: 100%;
        box-sizing: border-box;
        padding: 0 12px;
    }
}
