.loan-estimate {
    margin: 60px auto 0;
    max-width: 1300px;
}

.loan-estimate .loan-estimate-container {
    background: url("../images/home/loan-est-bg.png") center / contain no-repeat;
    padding: 40px;
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(300px, 0.8fr) minmax(0, 1.45fr);
    align-items: stretch;
    min-height: 280px;
}

.loan-estimate .loan-estimate-container .loan-estimate-left {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 0;
    text-align: center;
}

.loan-estimate .loan-estimate-container .loan-estimate-left::after {
    content: "";
    position: absolute;
    z-index: 2;
    top: 8%;
    right: 0;
    bottom: 8%;
    width: 2px;
    background: linear-gradient(
            to bottom,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.28) 12%,
            rgba(255, 255, 255, 0.60) 35%,
            rgba(255, 255, 255, 0.60) 65%,
            rgba(255, 255, 255, 0.28) 88%,
            rgba(255, 255, 255, 0) 100%
    );
    box-shadow: -3px 0 8px rgba(255, 255, 255, 0.12),
    3px 0 8px rgba(255, 255, 255, 0.12);
    pointer-events: none;
}

.loan-estimate .loan-estimate-container .loan-estimate-left .title {
    margin: 0 0 14px;
    color: #fff;
    font-size: 25px;
    font-weight: 500;
    line-height: 1.08;
    text-align: center;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}

.loan-estimate .loan-estimate-container .loan-estimate-left .title-highlight {
    display: flex;
    align-items: end;
    justify-content: center;
    gap: 7px;
    font-size: 35px;
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
    white-space: nowrap;
}

.loan-estimate .loan-estimate-container .loan-estimate-left .estimate-question-mark {
    display: block;
    flex: 0 0 auto;
    width: auto;
    height: 42px;
    object-fit: contain;
    transform: translateY(-5px);
}

.loan-estimate .loan-estimate-container .loan-estimate-left .disclaimer {
    padding: 4px 16px;
    color: #fff;
    border: 1px solid #fff;
    border-radius: 5px;
    font-size: 12px;
    line-height: 1.2;
    font-weight: 600;
    margin: 0;
}

.loan-estimate .loan-estimate-container .loan-estimate-left .compete-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 35px;
    margin: 5px 0 15px;
    padding: 5px 10px 5px 16px;
    color: #fff;
    background: #000;
    border: 0;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
    box-shadow: 0 5px 12px rgba(0, 0, 0, 0.16);
    transition: transform 0.25s ease,
    background-color 0.25s ease,
    box-shadow 0.25s ease;
    text-transform: none;
}

.loan-estimate .loan-estimate-container .loan-estimate-left .compete-btn img {
    display: block;
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.loan-estimate .loan-estimate-container .loan-estimate-left .compete-btn:hover {
    color: #fff;
    background-color: #333;
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
}

.loan-estimate .loan-estimate-container .loan-estimate-left .compete-btn:focus-visible {
    outline: 3px solid rgba(255, 255, 255, 0.9);
    outline-offset: 3px;
}

.loan-estimate .loan-estimate-container .loan-estimate-right {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding-left: 44px;
}

.loan-estimate .loan-estimate-container .loan-estimate-right .heading {
    max-width: 550px;
    margin: 0 0 5px;
    color: #fff;
    font-size: 29px;
    font-weight: 600;
    line-height: 1.3;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.loan-estimate .loan-estimate-container .loan-estimate-right .description {
    margin: 0 0 25px;
    color: #fff;
    font-size: 16px;
    line-height: 1.4;
    font-weight: 500;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.loan-estimate .loan-estimate-container .benefits {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 30px;
}

.loan-estimate .loan-estimate-container .benefits .benefit-item {
    display: flex;
    align-items: center;
    gap: 7px;
    min-width: 0;
}

.loan-estimate .loan-estimate-container .benefits .benefit-item img {
    display: block;
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.loan-estimate .loan-estimate-container .benefits .benefit-item p {
    margin: 0;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.3;
}

.loan-estimate-popup[hidden] {
    display: none !important;
}

.loan-estimate-popup {
    position: fixed;
    z-index: 999;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 24px;
}

.loan-estimate-popup .loan-estimate-popup__backdrop {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.7);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.loan-estimate-popup .loan-estimate-popup__dialog {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 760px;
    max-height: calc(100vh - 48px);
    overflow-x: hidden;
    overflow-y: auto;
    background-color: #fff;
    border-radius: 30px;
    box-shadow: 0 28px 90px rgba(0, 0, 0, 0.34);
    opacity: 0;
    transform: translateY(30px) scale(0.97);
    transition: opacity 0.3s ease,
    transform 0.3s cubic-bezier(.22, 1, .36, 1);
}

.loan-estimate-popup.is-open .loan-estimate-popup__backdrop {
    opacity: 1;
}

.loan-estimate-popup.is-open .loan-estimate-popup__dialog {
    opacity: 1;
    transform: translateY(0) scale(1);
}

body.loan-estimate-popup-open {
    overflow: hidden;
}

.loan-estimate-popup .loan-estimate-popup__close {
    position: absolute;
    z-index: 10;
    top: 15px;
    right: 15px;
    place-items: center;
    width: 30px;
    height: 30px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.loan-estimate-popup .loan-estimate-popup__close img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.loan-estimate-popup .loan-estimate-popup__close:hover {
    transform: rotate(90deg);
}

.loan-estimate-popup .loan-estimate-popup__close:focus-visible {
    outline: 3px solid rgba(255, 189, 0, 0.4);
    outline-offset: 2px;
}

.loan-estimate-popup .loan-estimate-popup__header {
    position: relative;
    padding: 50px 50px 20px;
    text-align: center;
}

.loan-estimate-popup .loan-estimate-popup__header .loan-estimate-title {
    font-size: 26px;
    font-weight: 600;
    color: #ffc001;
}

.loan-estimate-popup .loan-estimate-popup__eyebrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 0 5px;
    padding: 5px 15px;
    color: #5a5a5a;
    background: #fff;
    border: 1px solid #8e8e8e;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.2;
}

.loan-estimate-popup .loan-estimate-popup__description {
    max-width: 590px;
    margin: 0 auto 17px;
    color: #888;
    font-size: 13px;
    line-height: 1.5;
    font-weight: 500;
}

.loan-estimate-popup .loan-estimate-popup__benefits {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px 32px;
    margin-bottom: 25px;
}

.loan-estimate-popup .loan-estimate-popup__benefits span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #666;
    font-size: 13px;
    line-height: 1.4;
}

.loan-estimate-popup .loan-estimate-popup__benefits img {
    display: block;
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.loan-estimate-popup .loan-estimate-popup__rate-icon,
.loan-estimate-popup .loan-estimate-popup__rate-icons-right img {
    display: block;
    width: auto;
    height: 50px;
    object-fit: contain;
}

.loan-estimate-popup .loan-estimate-popup__rate-icon.rate-icon-left {
    position: absolute;
    top: 45px;
    left: 6%;
}

.loan-estimate-popup .loan-estimate-popup__rate-icons-right {
    position: absolute;
    top: 35px;
    right: 5%;
    display: flex;
    align-items: flex-start;
    gap: 5px;
}

.loan-estimate-popup .loan-estimate-popup__rate-icons-right img:first-child {
    height: 30px;
}

.loan-estimate-popup .loan-estimate-popup__rate-icons-right img:last-child {
    height: 55px;
    transform: translateY(20px);
}

.loan-estimate-popup .loan-estimate-form {
    padding: 0 60px 40px;
}

.loan-estimate-popup .loan-estimate-form__title {
    margin: 0 0 10px;
    color: #5a5a5a;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.3;
}

.loan-estimate-popup .loan-estimate-form__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px 45px;
}

.loan-estimate-popup .loan-estimate-form__group {
    min-width: 0;
}

.loan-estimate-popup .loan-estimate-form__group label,
.loan-estimate-popup .loan-estimate-form__upload-heading label,
.loan-estimate-popup .loan-estimate-form__message label {
    display: block;
    margin: 0 0 5px;
    color: #5a5a5a;
    font-size: 14px;
    line-height: 1.3;
}

.loan-estimate-popup .loan-estimate-form__group input,
.loan-estimate-popup .loan-estimate-form__message textarea {
    display: block;
    width: 100%;
    color: #5a5a5a;
    background: #fff;
    border: 1px solid #c6c6c6;
    border-radius: 10px;
    outline: none;
    box-shadow: none;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.loan-estimate-popup .loan-estimate-form__group input {
    height: 40px;
    padding: 0 16px;
}

.loan-estimate-popup .loan-estimate-form__message textarea {
    min-height: 80px;
    padding: 10px 16px;
    resize: vertical;
}

.loan-estimate-popup .loan-estimate-form__message textarea::placeholder {
    color: #cecece;
}

.loan-estimate-popup .loan-estimate-form__group input:focus,
.loan-estimate-popup .loan-estimate-form__message textarea:focus {
    border-color: #ffc001;
    background: #fff;
}

.loan-estimate-popup .loan-estimate-form__upload {
    margin-top: 26px;
}

.loan-estimate-popup .loan-estimate-form__upload-heading {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 5px;

    margin-bottom: 10px;
}

.loan-estimate-popup .loan-estimate-form__upload-heading label {
    display: inline;
    margin: 0;
    font-size: 15px;
    font-weight: 600;
}

.loan-estimate-popup .loan-estimate-form__upload-heading span {
    color: #777;
    font-size: 12px;
}

.loan-estimate-popup .loan-estimate-upload-box {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 60px;
    padding: 16px;
    border: 1px dashed #a7a7a7;
    background-color: #eeeeee;
    border-radius: 10px;
    cursor: pointer;
    transition: background-color 0.2s ease,
    border-color 0.2s ease;
}

.loan-estimate-popup .loan-estimate-upload-box:hover {
    background-color: #f5f5f5;
    border-color: #ffbd00;
}

.loan-estimate-popup .loan-estimate-upload-box input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.loan-estimate-popup .loan-estimate-upload-box__content {
    color: #b1b1b1;
    font-size: 14px;
    text-align: center;
}

.loan-estimate-popup .loan-estimate-form__upload-note {
    margin: 10px 0 0;
    color: #888;
    font-size: 11px;
    line-height: 1.4;
    text-align: center;
}

.loan-estimate-popup .loan-estimate-form__message {
    display: grid;
    grid-template-columns: 75px minmax(0, 1fr);
    align-items: start;
    gap: 10px;
    margin-top: 25px;
}

.loan-estimate-popup .loan-estimate-form__message label {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
}

.loan-estimate-popup .loan-estimate-form__submit {
    margin-top: 30px;
    width: 100% !important;
    max-width: 200px !important;
    min-height: 40px !important;
    background: #ffc001 !important;
    color: white !important;
    border: none !important;
    border-radius: 75px !important;
    cursor: pointer !important;
    font-weight: 600 !important;
    font-size: 18px !important;
    padding: 0 !important;
    line-height: normal !important;
    text-transform: none !important;
}

.loan-estimate-popup .loan-estimate-form__submit:hover {
    box-shadow: inset 0 0 0 120px rgba(0, 0, 0, 0.18);
}

.loan-estimate-popup .loan-estimate-form__consent {
    margin: 20px auto 0;
    color: #9c9c9c;
    font-size: 12px;
    line-height: 1.4;
    text-align: center;
    max-width: 620px;
}

.loan-estimate-popup .loan-estimate-form__consent a {
    color: inherit;
    text-decoration: underline;
}

.loan-estimate-popup .loan-estimate-form__legal {
    max-width: 620px;
    margin: 20px auto 0;
    padding-top: 15px;
    color: #aaa;
    border-top: 1px solid #ddd;
    font-size: 10px;
    line-height: 1.4;
    text-align: center;
}

.loan-estimate-popup .loan-estimate-form__honeypot {
    position: absolute !important;
    left: -9999px !important;
    top: auto !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

@media screen and (max-width: 1300px) {
    .loan-estimate {
        padding: 0 16px;
    }
}

@media screen and (max-width: 1080px) {
    .loan-estimate {
        padding: 0 16px;
    }

    .loan-estimate .loan-estimate-container .loan-estimate-left .title {
        font-size: 20px;
    }

    .loan-estimate .loan-estimate-container .loan-estimate-left .title-highlight {
        font-size: 30px;
    }

    .loan-estimate .loan-estimate-container .loan-estimate-left .estimate-question-mark {
        height: 35px;
    }

    .loan-estimate .loan-estimate-container .loan-estimate-right .heading {
        font-size: 22px;
    }

    .loan-estimate .loan-estimate-container .loan-estimate-right .description {
        font-size: 14px;
    }
}

@media screen and (max-width: 992px) {
    .loan-estimate .loan-estimate-container {
        grid-template-columns: 1fr;
        background-size: cover;
        background-position: left;
        border-radius: 45px;
        padding: 30px;
    }

    .loan-estimate .loan-estimate-container .loan-estimate-left::after {
        right: 8%;
        bottom: -20px;
        left: 8%;
        top: unset;
        width: auto;
        height: 2px;
        background: linear-gradient(
                to right,
                rgba(255, 255, 255, 0) 0%,
                rgba(255, 255, 255, 0.28) 12%,
                rgba(255, 255, 255, 0.60) 35%,
                rgba(255, 255, 255, 0.60) 65%,
                rgba(255, 255, 255, 0.28) 88%,
                rgba(255, 255, 255, 0) 100%
        );

        box-shadow: 0 -3px 8px rgba(255, 255, 255, 0.12),
        0 3px 8px rgba(255, 255, 255, 0.12);
    }

    .loan-estimate .loan-estimate-container .loan-estimate-right {
        padding-left: 0;
        align-items: center;
        margin-top: 40px;
    }

    .loan-estimate .loan-estimate-container .loan-estimate-right .heading {
        text-align: center;
    }
}

@media screen and (max-width: 750px) {
    .loan-estimate-popup .loan-estimate-form__grid {
        gap: 15px 20px;
    }
}

@media screen and (max-width: 640px) {
    .loan-estimate .loan-estimate-container {
        border-radius: 55px;
        background-position: center;
    }

    .loan-estimate-popup .loan-estimate-popup__header .loan-estimate-title {
        line-height: 1.2;
        font-size: 22px;
    }

    .loan-estimate-popup .loan-estimate-popup__header {
        padding: 50px 35px 5px;
    }

    .loan-estimate-popup .loan-estimate-popup__description {
        margin: 10px auto 15px;
    }

    .loan-estimate-popup .loan-estimate-form {
        padding: 0 35px 40px;
    }
}

@media screen and (max-width: 576px) {
    .loan-estimate-popup .loan-estimate-popup__rate-icon.rate-icon-left,
    .loan-estimate-popup .loan-estimate-popup__rate-icons-right img {
        display: none;
    }

    .loan-estimate-popup .loan-estimate-popup__header {
        padding: 30px 20px 5px;
    }

    .loan-estimate-popup .loan-estimate-form {
        padding: 0 20px 30px;
    }

    .loan-estimate-popup .loan-estimate-popup__eyebrow {
        margin-bottom: 10px;
    }
}

@media screen and (max-width: 460px) {
    .loan-estimate-popup .loan-estimate-form__grid,
    .loan-estimate-popup .loan-estimate-form__message {
        grid-template-columns: 1fr;
    }

    .loan-estimate-popup .loan-estimate-form__grid {
        gap: 10px;
    }

}
