.order-form-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

.order-form-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    height: 100%;
    overflow: auto;
    z-index: 1010;
    outline: 0;
}

.order-form-content {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 50%;
    height: calc(100% - 40px);
    pointer-events: auto;
    background-color: #fff;
    background-clip: padding-box;
    outline: 0;
    margin: 20px auto;
}

.order-form-header {
    padding: 1rem;
    border-bottom: none;
    border-top-left-radius: 0.3rem;
    border-top-right-radius: 0.3rem;
    position: relative;
    z-index: 1;
    -webkit-box-shadow: 0 2px 10px 0 rgba(34, 60, 80, 0.2);
    -moz-box-shadow: 0 2px 10px 0 rgba(34, 60, 80, 0.2);
    box-shadow: 0 2px 10px 0 rgba(34, 60, 80, 0.2);
}

.order-form-header h4 {
    margin: 10px;
    text-align: center;
    text-transform: uppercase;
}

.order-form-header .close {
    position: absolute;
    top: 10px;
    right: 10px;
    cursor: pointer;
    border: none;
    background: none;
    padding: 0;
}

.order-form-header .close img {
    width: 35px;
    height: 35px;
    opacity: 0.5;
}

.order-form-header .close img:hover,
.order-form-header .close img:focus {
    opacity: 1;
}

.order-form-body {
    flex: 1 1 auto;
    padding: 30px;
    overflow: hidden;
}

.order-form-footer {
    padding: 1rem;
    border-top: 1px solid #e9ecef;
    border-bottom-right-radius: 0.3rem;
    border-bottom-left-radius: 0.3rem;
    position: sticky;
    bottom: 0;
    background-color: #fff;
    text-align: center;
    -webkit-box-shadow: 0 -2px 10px 0 rgba(34, 60, 80, 0.2);
    -moz-box-shadow: 0 -2px 10px 0 rgba(34, 60, 80, 0.2);
    box-shadow: 0 -2px 10px 0 rgba(34, 60, 80, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
}

.order-form-footer .btn {
    margin: 0 10px; /* Добавлено для расстояния между кнопками */
}

.order-form-modal.show {
    display: block;
}

.order-form-backdrop.show {
    display: block;
}

.order-form-body input[type="text"],
.order-form-body input[type="firstName"],
.order-form-body input[type="lastName"],
.order-form-body input[type="email"],
.order-form-body input[type="tel"] {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    box-sizing: border-box;
    font-size: 1rem;
    border-width: 2px; /* Толщина границы */
    border-style: solid;
    border-color: #E0E0E0; /* Цвет границы */
}

.order-form-body textarea {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    box-sizing: border-box;
    font-size: 1rem;
    border-width: 2px; /* Толщина границы */
    border-style: solid;
    border-color: #E0E0E0; /* Цвет границы */
    resize: none; /* Опционально, чтобы запретить изменение размера */
}


.label-styles {
    font-weight: 600;
}

#switchOutput p,
#paymentSwitchOutput p {
    font-size: 1rem;
    color: #495057;
    margin-top: 5px;
}

.color-mode-label {
    font-size: 14px;
    color: #495057;
    font-weight: 400;
}

.btn-color-mode-switch {
    display: block;
    margin: 10px 0;
}

.btn-color-mode-switch-inner {
    font-weight: 600;
    margin: 0px;
    width: 600px;
    height: 42px;
    background: #E0E0E0;
    border-radius: 26px;
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
    display: block;
    cursor: pointer;
}

/*доставка до пункта боксберри*/
.btn-color-mode-switch-inner.dostavka-boksberri:before {
    content: attr(data-on);
    position: absolute;
    font-size: 18px;
    font-weight: 400;
    color: #495057;
    top: 50%;
    right: 19px;
    transform: translateY(-50%);
    white-space: nowrap;
}

/* доставка или самовывоз */
.btn-color-mode-switch-inner.dostavka-samovyvoz:before {
    content: attr(data-on);
    position: absolute;
    font-size: 18px;
    font-weight: 400;
    color: #495057;
    top: 50%;
    right: 56px;
    transform: translateY(-50%);
    white-space: nowrap;
}

.btn-color-mode-switch input[type="checkbox"]:checked + .btn-color-mode-switch-inner.dostavka-samovyvoz:before {
    content: attr(data-off);
    left: 21px;
}

/*оплата от юр.лица*/
.btn-color-mode-switch-inner.ur-lico:before {
    content: attr(data-on);
    position: absolute;
    font-size: 18px;
    font-weight: 400;
    color: #495057;
    top: 50%;
    right: 70px;
    transform: translateY(-50%);
    white-space: nowrap;
}

.btn-color-mode-switch-inner:after {
    content: attr(data-off);
    width: 300px;
    height: 28px;
    background: #fff;
    border-radius: 26px;
    position: absolute;
    left: 2px;
    top: 50%;
    transform: translateY(-50%);
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0px 0px 6px -2px #111;
    padding: 5px 0px;
    color: #000;
    white-space: nowrap;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.btn-color-mode-switch input[type="checkbox"] {
    cursor: pointer;
    width: 50px;
    height: 25px;
    opacity: 0;
    position: absolute;
    top: 0;
    z-index: 1;
    margin: 0px;
}

.btn-color-mode-switch input[type="checkbox"]:checked + .btn-color-mode-switch-inner {
    background: #E0E0E0;
    color: #fff;
}

.btn-color-mode-switch input[type="checkbox"]:checked + .btn-color-mode-switch-inner:after {
    content: attr(data-on);
    left: calc(100% - 300px - 2px);
    background: #fff;
}

/*курьерсакая доставка до двери*/
.btn-color-mode-switch.k-dostavka input[type="checkbox"]:checked + .btn-color-mode-switch-inner:before {
    content: attr(data-off);
    /*right: auto;*/
    left: 21px;
}

/*оплата от физ лица*/
.btn-color-mode-switch.fiz-loco input[type="checkbox"]:checked + .btn-color-mode-switch-inner:before {
    content: attr(data-off);
    top: 50%;
    left: 66px;
}

#orderComment {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    box-sizing: border-box;
    resize: none;
    overflow: hidden;
    font-family: 'Roboto', sans-serif;
    font-size: 1rem;
}

.delivery-boxberry-container {
    display: flex;
    align-items: center;
}

.find-boxberry-point {
    width: 260px;
    height: 45px;
    margin-right: 10px;
    padding: 10px 5px;
    flex-shrink: 0;
    display: inline-block;
    margin-left: 0;
}

.delivery-select-address {
    flex-grow: 1;
}

@media (max-width: 1024px) {
    .order-form-content {
        width: 95%;
    }

    .btn-color-mode-switch-inner {
        width: 260px;
        height: 80px;
        border-radius: 16px;
        position: relative;
    }

    .btn-color-mode-switch-inner .text-on {
        content: attr(data-on);
        bottom: calc(50% - -6px);
        left: 50%;
        transform: translate(-50%, 50%);
        position: absolute;
    }

    .btn-color-mode-switch-inner .text-off {
        content: attr(data-off);
        top: 20px;
        left: 50%;
        transform: translate(-50%, -50%);
        position: absolute;
    }

    .btn-color-mode-switch-inner:after {
        width: calc(100% - 4px);
        height: 28px;
        left: 50%;
        top: 2px;
        font-size: 14px;
        transform: translateX(-50%);
        border-radius: 14px;
        position: absolute;
        transition: top 0.5s ease, bottom 0.5s ease;
    }

    .btn-color-mode-switch input[type="checkbox"]:checked + .btn-color-mode-switch-inner:after {
        top: unset;
        bottom: 2px;
        left: 50%;
        transform: translateX(-50%);
    }

    .btn-color-mode-switch input[type="checkbox"]:checked + .btn-color-mode-switch-inner .text-on {
        top: 20px;
        bottom: unset;
        transform: translate(-50%, -50%);
        position: absolute;
    }

    .btn-color-mode-switch.k-dostavka input[type="checkbox"]:checked + .btn-color-mode-switch-inner:before {
        content: attr(data-off);
        top: 21px;
        left: 28px;
    }

    .btn-color-mode-switch.dostavka-samovyvoz input[type="checkbox"]:checked + .btn-color-mode-switch-inner:before {
        content: attr(data-off);
        position: absolute;
        top: 21px;
        left: 28px;
    }

    .btn-color-mode-switch.fiz-loco input[type="checkbox"]:checked + .btn-color-mode-switch-inner:before {
        content: attr(data-off);
        top: 25%;
        left: 63px;
    }

    .btn-color-mode-switch-inner.dostavka-boksberri:before {
        top: 74%;
        right: 27px;
        font-size: 14px;
    }

    .btn-color-mode-switch-inner.dostavka-samovyvoz:before {
        top: 74%;
        right: 57px;
        font-size: 14px;
    }

    .delivery-boxberry-container {
        flex-direction: column;
        align-items: stretch;
    }

    .find-boxberry-point {
        margin: 10px 0;
    }

    .btn-color-mode-switch-inner.ur-lico:before {
        font-size: 14px;
        top: 75%;
        right: 66px;
    }

}
