/*
 * Модальная форма «Рассчитать проект».
 */
#modal-web-form {
    --project-modal-width: 837px;
    --project-modal-radius: 25px;
    --project-modal-bg: rgba(43, 33, 68, 0.95);
    
    --project-modal-accent: #c7eb43;
    --project-modal-text: #f7f7fb;
    --project-modal-muted: rgba(247, 247, 251, 0.88);
    --project-modal-field-bg: rgba(18, 15, 31, 0.38);
    --project-modal-field-border: rgba(255, 255, 255, 0.16);

    position: fixed;
    z-index: 99999;
    inset: 0;
    display: none;
    width: 100vw;
    height: 100%;
    max-width: none;
    max-height: none;
    overflow: hidden;
    
    
    
    background: rgba(0, 0, 0, 0.42);
    box-shadow: none;
    filter: none;

    /*-webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);*/
}

#modal-web-form .project-modal__viewport {
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 100%;
    padding: 24px;
}

#modal-web-form .project-modal__dialog {
    position: relative;
    box-sizing: border-box;
    width: min(var(--project-modal-width), calc(100vw - 48px));
    min-height: 303px;
    max-width: none;
    padding: 40px 40px;
    overflow: hidden;
    color: var(--project-modal-text);
    background: var(--project-modal-bg);
    border: 1px solid rgba(255, 255, 255, 0.025);
    border-radius: var(--project-modal-radius);
    box-shadow: 0 28px 80px rgba(7, 5, 22, 0.38);
    -webkit-backdrop-filter: blur(18px);
    backdrop-filter: blur(18px);
    font-family: "Manrope", sans-serif;
}

#modal-web-form .project-modal__layout {
    display: grid;
    grid-template-columns: minmax(0, 388px) 299px;
    column-gap: 54px;
    align-items: stretch;
}

#modal-web-form .project-modal__copy {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

#modal-web-form .project-modal__form-column {
    display: flex;
    min-width: 0;
    min-height: 245px;
    align-items: stretch;
}

#modal-web-form .project-modal__title {
    max-width: 390px;
    margin: 0;
    color: var(--project-modal-text);
    font-family: "Manrope", sans-serif;
    font-size: 28px;
    font-weight: 700;
    line-height: 1.32;
    letter-spacing: -0.45px;
}

#modal-web-form .project-modal__description {
    max-width: 390px;
    margin: 24px 0 0;
    color: var(--project-modal-muted);
    font-size: 16px;
    font-weight: 400;
    line-height: 1.36;
}

#modal-web-form .project-modal__phone-row {
    display: flex;
    align-items: baseline;
    gap: 13px;
    margin-top: 24px;
    color: var(--project-modal-text);
    white-space: nowrap;
}

#modal-web-form .project-modal__source-title {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

#modal-web-form .project-modal__extra-field {
    display: none !important;
}

#modal-web-form .form-item > label,
#modal-web-form .form-item label:not(.checkbox-wrap label) {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

#modal-web-form .simple-form input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
#modal-web-form .simple-form select {
    box-sizing: border-box;
    display: block;
    width: 100%;
    height: 54px;
    margin: 0;
    padding: 0 30px;
    color: var(--project-modal-text);
    background: var(--project-modal-field-bg);
    border: 1px solid var(--project-modal-field-border);
    border-radius: 10px;
    outline: none;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.015);
    font-family: "Manrope", sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: normal;
    transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

#modal-web-form .simple-form textarea {
    box-sizing: border-box;
    display: block;
    width: 100%;
    min-height: 100px;
    margin: 0;
    padding: 14px 30px;
    color: var(--project-modal-text);
    background: var(--project-modal-field-bg);
    border: 1px solid var(--project-modal-field-border);
    border-radius: 10px;
    outline: none;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.015);
    font-family: "Manrope", sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.4;
    resize: vertical;
    transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

#modal-web-form .simple-form input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"])::placeholder,
#modal-web-form .simple-form textarea::placeholder {
    color: rgba(247, 247, 251, 0.42);
    opacity: 1;
}

#modal-web-form .simple-form input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]):hover,
#modal-web-form .simple-form textarea:hover,
#modal-web-form .simple-form select:hover {
    border-color: rgba(255, 255, 255, 0.28);
}

#modal-web-form .simple-form input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]):focus,
#modal-web-form .simple-form textarea:focus,
#modal-web-form .simple-form select:focus {
    background: rgba(18, 15, 31, 0.52);
    border-color: rgba(199, 235, 67, 0.78);
    box-shadow: 0 0 0 3px rgba(199, 235, 67, 0.08);
}

#modal-web-form .simple-form .required.error input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
#modal-web-form .simple-form .required.error textarea,
#modal-web-form .simple-form .required.error select {
    border-color: #ff747c;
}

#modal-web-form .project-modal__phone:hover,
#modal-web-form .project-modal__phone:focus-visible {
    color: var(--project-modal-accent);
}

#modal-web-form .project-modal__close:hover,
#modal-web-form .project-modal__close:focus-visible {
    background: rgba(255, 255, 255, 0.08);
    opacity: 1;
    outline: none;
}

#modal-web-form .simple-form,
#modal-web-form .form-items,
#modal-web-form .btn-wrap {
    width: 100%;
}

#modal-web-form .btn-wrap,
#modal-web-form .simple-form .btn-wrap {
    margin: 9px 0 0;
    text-align: left;
}

#modal-web-form [data-modal="button"],
#modal-web-form .project-modal__dialog .btn-blue {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: 100%;
    height: 50px;
    min-height: 50px;
    padding: 16px 40px;
    color: #111315;
    background: var(--project-modal-accent);
    border: 0;
    border-radius: 12px;
    box-shadow: none;
    cursor: pointer;
    font-family: "Manrope", sans-serif;
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    transition: transform 0.18s ease, filter 0.18s ease, box-shadow 0.18s ease;
}

#modal-web-form [data-modal="button"]:hover,
#modal-web-form [data-modal="button"]:focus-visible,
#modal-web-form .project-modal__dialog .btn-blue:hover,
#modal-web-form .project-modal__dialog .btn-blue:focus-visible {
    filter: brightness(1.035);
    box-shadow: 0 9px 24px rgba(199, 235, 67, 0.16);
    transform: translateY(-1px);
}

#modal-web-form [data-modal="button"]:active {
    transform: translateY(0);
}

#modal-web-form [data-modal="button"]:disabled {
    cursor: default;
    opacity: 0.62;
    transform: none;
}

#modal-web-form .project-modal__loader {
    box-sizing: border-box;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(17, 19, 21, 0.28);
    border-top-color: #111315;
    border-radius: 50%;
    animation: project-modal-spin 0.75s linear infinite;
}

#modal-web-form .project-modal__close {
    position: absolute;
    z-index: 2;
    top: 15px;
    right: 17px;
    width: 28px;
    height: 28px;
    padding: 0;
    margin: 0;
    color: transparent;
    background: transparent;
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    opacity: 0.72;
    transition: opacity 0.2s ease, background-color 0.2s ease;
}

#modal-web-form .project-modal__close::before,
#modal-web-form .project-modal__close::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 17px;
    height: 2px;
    background: #ffffff;
    border-radius: 2px;
}

#modal-web-form .project-modal__close::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

#modal-web-form .project-modal__close::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

#modal-web-form .project-modal__success {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    box-sizing: border-box;
    width: 100%;
    min-height: 245px;

    color: var(--project-modal-text);
    font-family: "Manrope", sans-serif;
    text-align: center;
}

#modal-web-form .project-modal__success h5 {
    margin: 0;

    color: var(--project-modal-text);
    font-family: "Manrope", sans-serif;
    font-size: 26px;
    font-weight: 700;
    line-height: 1.3;
}

#modal-web-form .project-modal__success p {
    margin: 12px 0 0;

    color: var(--project-modal-muted);
    font-family: "Manrope", sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.4;
}

#modal-web-form .project-modal__phone-label {
    font-size: 16px;
    font-weight: 400;
    line-height: 1.4;
}

#modal-web-form .project-modal__phone {
    color: var(--project-modal-text);
    font-size: 24px;
    font-weight: 400;
    line-height: 1.2;
    text-decoration: none;
    letter-spacing: -0.35px;
}

#modal-web-form .project-modal__form {
    display: block;
    width: 100%;
    margin: 0;
}

#modal-web-form .form-items {
    display: grid;
    gap: 9px;
}

#modal-web-form .form-item,
#modal-web-form .project-modal__dialog .form-item {
    position: relative;
    width: 100%;
    max-width: none;
    margin: 0;
}

#modal-web-form .text-error {
    margin: 4px 4px 0;
    color: #ffb0b5;
    font-size: 11px;
    line-height: 1.25;
}

#modal-web-form .project-modal__dialog__errors {
    margin-bottom: 8px;
    color: #ffb0b5;
    font-size: 12px;
    line-height: 1.35;
}

#modal-web-form .project-modal__dialog__errors:empty {
    display: none;
}

#modal-web-form .simple-form__form_privacy {
    display: flex;
    flex-direction: column;
    gap: 8px;

    margin-top: 14px;

    color: rgba(247, 247, 251, 0.68);
    font-family: "Manrope", sans-serif;
    font-size: 11px;
    line-height: 1.35;
}

#modal-web-form .simple-form__form_privacy__item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

#modal-web-form .callback-form__items-form_privacy__checkbox {
    flex: 0 0 auto;

    width: 16px;
    height: 16px;

    margin: 2px 0 0;

    accent-color: var(--project-modal-accent);
    cursor: pointer;
}

#modal-web-form .simple-form__form_privacy .agree-it {
    flex: 1;
    max-width: 271px;
    margin: 0;
    text-align: start;
    color: rgba(247, 247, 251, 0.68);
}

#modal-web-form .simple-form__form_privacy .agree-it a {
    color: rgba(247, 247, 251, 0.82);
    text-decoration: underline;
    text-underline-offset: 2px;
}

@keyframes project-modal-spin {
    to { transform: rotate(360deg); }
}

@media (max-width: 860px) {
     #modal-web-form .project-modal__dialog {
        width: calc(100vw - 40px);
        max-width: 760px;
        min-height: 0;
        padding: 32px 28px;
    }

    #modal-web-form .project-modal__layout {
        grid-template-columns: minmax(0, 1fr) minmax(260px, 0.9fr);
        column-gap: 30px;
        align-items: center;
    }

    #modal-web-form .project-modal__title {
        font-size: 25px;
    }

    #modal-web-form .project-modal__description {
        margin-top: 18px;
        font-size: 15px;
    }

    #modal-web-form .project-modal__phone-row {
        margin-top: 18px;
    }

    #modal-web-form .project-modal__phone {
        font-size: 21px;
    }
}

@media (max-width: 767px) {
    #modal-web-form .project-modal__dialog {
        width: min(600px, calc(100vw - 28px));
        padding: 34px 24px 28px;
    }

    #modal-web-form .project-modal__layout {
        grid-template-columns: 1fr;
        row-gap: 24px;
    }

    #modal-web-form .project-modal__form-column {
        min-height: 0;
    }

    #modal-web-form .project-modal__viewport {
        margin-top: 40px;
    }
}

@media (max-width: 540px) {
    #modal-web-form .project-modal__viewport {
        align-items: center;
        padding: 14px;
    }

    #modal-web-form .project-modal__dialog {
        width: 100%;
        margin: auto 0;
        padding: 34px 20px 24px;
        border-radius: 20px;
    }

    #modal-web-form .project-modal__layout {
        row-gap: 24px;
    }

    #modal-web-form .project-modal__title {
        padding-right: 20px;
        font-size: 23px;
        line-height: 1.28;
    }

    #modal-web-form .project-modal__description {
        margin-top: 16px;
        font-size: 14px;
        line-height: 1.42;
    }

    #modal-web-form .project-modal__phone-row {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
        margin-top: 20px;
        white-space: normal;
    }

    #modal-web-form .project-modal__phone-label {
        font-size: 14px;
    }

    #modal-web-form .project-modal__phone {
        font-size: 21px;
    }

    #modal-web-form .simple-form input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
    #modal-web-form .simple-form select {
        height: 48px;
        padding: 0 18px;
        line-height: normal;
    }

    #modal-web-form [data-modal="button"],
    #modal-web-form .project-modal__dialog .btn-blue {
        height: 48px;
        min-height: 48px;
    }

    #modal-web-form .project-modal__close {
        top: 10px;
        right: 10px;
    }
}

/* =========================================================
   БОЛЬШОЙ DESKTOP: от 1921 px
   Масштаб относительно версии 1440 px ≈ 1.84
   ========================================================= */
@media (min-width: 1921px) {
    #modal-web-form {
        --project-modal-width: 1540px;
        --project-modal-radius: 46px;
    }

    #modal-web-form .project-modal__viewport {
        padding: 44px;
    }

    #modal-web-form .project-modal__dialog {
        width: min(var(--project-modal-width), calc(100vw - 88px));
        min-height: 558px;
        padding: 74px;
        border-radius: var(--project-modal-radius);
        box-shadow: 0 52px 147px rgba(7, 5, 22, 0.38);
        -webkit-backdrop-filter: blur(33px);
        backdrop-filter: blur(33px);
    }

    #modal-web-form .project-modal__layout {
        grid-template-columns: minmax(0, 714px) 550px;
        column-gap: 99px;
    }

    #modal-web-form .project-modal__form-column {
        min-height: 451px;
    }

    #modal-web-form .project-modal__title {
        max-width: 718px;
        font-size: 52px;
        line-height: 1.32;
        letter-spacing: -0.8px;
    }

    #modal-web-form .project-modal__description {
        max-width: 718px;
        margin-top: 44px;
        font-size: 29px;
    }

    #modal-web-form .project-modal__phone-row {
        gap: 24px;
        margin-top: 44px;
    }

    #modal-web-form .project-modal__phone-label {
        font-size: 29px;
    }

    #modal-web-form .project-modal__phone {
        font-size: 44px;
        letter-spacing: -0.65px;
    }

    #modal-web-form .simple-form input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
    #modal-web-form .simple-form select {
        height: 99px;
        padding: 0 55px;
        border-radius: 18px;
        font-size: 29px;
    }

    #modal-web-form .simple-form textarea {
        min-height: 184px;
        padding: 26px 55px;
        border-radius: 18px;
        font-size: 29px;
    }

    #modal-web-form .form-items {
        gap: 17px;
    }

    #modal-web-form .btn-wrap,
    #modal-web-form .simple-form .btn-wrap {
        margin-top: 17px;
    }

    #modal-web-form [data-modal="button"],
    #modal-web-form .project-modal__dialog .btn-blue {
        height: 92px;
        min-height: 92px;
        padding: 29px 74px;
        border-radius: 22px;
        font-size: 29px;
    }

    #modal-web-form .project-modal__loader {
        width: 37px;
        height: 37px;
        border-width: 4px;
    }

    #modal-web-form .project-modal__close {
        top: 28px;
        right: 31px;
        width: 52px;
        height: 52px;
    }

    #modal-web-form .project-modal__close::before,
    #modal-web-form .project-modal__close::after {
        width: 31px;
        height: 4px;
        border-radius: 4px;
    }

    #modal-web-form .project-modal__success {
        min-height: 451px;
    }

    #modal-web-form .project-modal__success h5 {
        font-size: 48px;
    }

    #modal-web-form .project-modal__success p {
        margin-top: 22px;
        font-size: 29px;
    }

    #modal-web-form .simple-form__form_privacy {
        gap: 15px;
        margin-top: 26px;
        font-size: 20px;
    }

    #modal-web-form .simple-form__form_privacy__item {
        gap: 22px;
    }

    #modal-web-form .callback-form__items-form_privacy__checkbox {
        width: 29px;
        height: 29px;
        margin-top: 4px;
    }

    #modal-web-form .simple-form__form_privacy .agree-it {
        max-width: 478px;
        font-size: 20px;
        line-height: 23px;
    }

    #modal-web-form .text-error {
        margin: 7px 7px 0;
        font-size: 20px;
    }

    #modal-web-form .simple-form__form_privacy .agree-it a { 
        font-size: 20px;
    }
}