.vpechatay-shell__bar .vpechatay-shell__contacts {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-self: end;
    gap: clamp(8px, 1vw, 15px);
}

.vpechatay-shell__contacts > a[href^="tel:"] {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    white-space: nowrap;
}

body.vpechatay-template a[href^="tel:" i] {
    text-decoration: none !important;
}

body.vpechatay-template a[href^="tel:" i]:hover {
    color: var(--vp-accent-strong, #99430c);
}

body.vpechatay-template .vpechatay-shell__footer a[href^="tel:" i]:hover {
    color: #ffd3a8 !important;
}

body.vpechatay-template .vpechatay-shell__bar .vpechatay-shell__contacts > a.vpechatay-shell__callback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    height: auto;
    min-width: 44px;
    min-height: 44px;
    max-width: none;
    padding: 0 14px;
    border: 1px solid #dcbba3;
    border-radius: 12px;
    background: #fff3e6;
    color: #8b3c09;
    font: 800 13px/1.1 var(--vp-body, sans-serif);
    text-decoration: none;
    white-space: nowrap;
    transition: background-color 140ms ease-out, border-color 140ms ease-out;
}

body.vpechatay-template .vpechatay-shell__bar .vpechatay-shell__contacts > a.vpechatay-shell__callback:hover {
    background: #f9e3cb;
    border-color: #b47a51;
}

.vpechatay-callback-label-short {
    display: none;
}

@media (min-width: 1361px) {
    .vpechatay-shell__header .vpechatay-shell__bar {
        grid-template-columns: auto minmax(0, 1fr) auto auto auto;
        gap: clamp(16px, 1.15vw, 24px);
    }

    .vpechatay-shell__header .vpechatay-shell__brand img {
        width: clamp(200px, 16vw, 260px);
    }

    .vpechatay-shell__header .vpechatay-shell__nav {
        flex-wrap: nowrap;
        gap: 4px;
    }

    .vpechatay-shell__nav > a,
    .vpechatay-shell__nav-group > summary {
        padding-inline: 8px;
        white-space: nowrap;
    }
}

@media (min-width: 761px) and (max-width: 940px) {
    .vpechatay-shell__header .vpechatay-shell__bar {
        gap: 12px;
    }

    .vpechatay-shell__header .vpechatay-shell__brand img {
        width: clamp(176px, 24vw, 226px);
    }
}

@media (max-width: 760px) {
    body.vpechatay-template .vpechatay-shell__bar .vpechatay-shell__contacts > a.vpechatay-shell__callback {
        padding-inline: 10px;
        font-size: 12px;
    }
}

@media (max-width: 460px) {
    .vpechatay-callback-label {
        display: none;
    }

    .vpechatay-callback-label-short {
        display: inline;
    }
}

#contact-form,
#callback-form {
    scroll-margin-top: 114px;
}

.vpechatay-contact-dialog:not([open]),
.vpechatay-contact-dialog [hidden] {
    display: none !important;
}

.vpechatay-contact-dialog {
    --vp-dialog-duration: 180ms;
    position: fixed;
    box-sizing: border-box;
    width: min(558px, calc(100vw - 32px));
    max-width: none;
    max-height: calc(100vh - 32px);
    max-height: calc(100dvh - 32px);
    margin: auto;
    padding: 0;
    overflow: auto;
    overscroll-behavior: contain;
    color: var(--vp-ink, #221b16);
    border: 1px solid #dfc7b1;
    border-radius: 23px;
    background: #fffaf3;
    box-shadow: 0 24px 80px rgba(45, 28, 17, 0.3);
}

.vpechatay-contact-dialog::backdrop {
    background: rgba(37, 29, 22, 0.55);
}

.vpechatay-contact-dialog[open] {
    animation: vp-contact-appear var(--vp-dialog-duration) cubic-bezier(.22, .61, .36, 1) both;
}

.vpechatay-contact-dialog[open]::backdrop {
    animation: vp-contact-scrim var(--vp-dialog-duration) ease-out both;
}

.vpechatay-contact-dialog[open].is-closing {
    animation: vp-contact-dismiss 140ms ease-in both;
}

.vpechatay-contact-dialog[open].is-closing::backdrop {
    animation: vp-contact-scrim-out 140ms ease-in both;
}

@keyframes vp-contact-appear {
    from { opacity: 0; transform: translateY(8px) scale(.99); }
    to { opacity: 1; transform: none; }
}

@keyframes vp-contact-scrim {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes vp-contact-dismiss {
    to { opacity: 0; transform: translateY(6px) scale(.99); }
}

@keyframes vp-contact-scrim-out {
    to { opacity: 0; }
}

html.vpechatay-contact-dialog-open,
.vpechatay-contact-dialog-open .vpechatay-shell__viewport {
    overflow: hidden;
}

.vpechatay-contact-dialog__head {
    position: sticky;
    top: 0;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 16px 24px 8px;
    background: #fffaf3;
}

.vpechatay-contact-dialog__head h2 {
    margin: 0;
    font: 750 clamp(23px, 4vw, 34px)/1.12 var(--vp-display, Georgia, serif);
}

.vpechatay-contact-dialog__close {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid #e6d3bf;
    border-radius: 50%;
    background: #f7eddf;
    color: var(--vp-ink, #221b16);
    cursor: pointer;
}

.vpechatay-contact-dialog__close:hover {
    background: #f0dfc9;
}

.vpechatay-contact-dialog__body {
    padding: 0 24px 24px;
}

.vpechatay-contact-dialog__intro,
.vpechatay-contact-dialog__status {
    margin: 0 0 16px;
    color: #615147;
    font-size: 15px;
    line-height: 1.45;
}

.vpechatay-contact-dialog__status:last-child {
    margin-bottom: 0;
}

.vpechatay-contact-dialog__embed .b24-form-header {
    display: none;
}

.vpechatay-contact-dialog .vpechatay-contact-dialog__embed .b24-form-content {
    padding: 0;
}

.vpechatay-contact-dialog__embed .b24-form-wrapper {
    min-height: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
}

.vpechatay-agreement-dialog:not([open]) {
    display: none;
}

.vpechatay-agreement-dialog {
    position: fixed;
    inset: 0;
    box-sizing: border-box;
    width: min(660px, calc(100vw - 24px));
    max-width: none;
    max-height: calc(100vh - 24px);
    max-height: calc(100dvh - 24px);
    margin: auto;
    padding: 0;
    overflow: hidden;
    border: 1px solid #dfc7b1;
    border-radius: 21px;
    background: #fffaf3;
    box-shadow: 0 24px 80px rgba(45, 28, 17, 0.35);
}

.vpechatay-agreement-dialog::backdrop {
    background: rgba(37, 29, 22, 0.42);
}

.vpechatay-agreement-dialog[open]::backdrop {
    animation: vp-contact-scrim 110ms ease-out both;
}

.vpechatay-agreement-dialog .b24-window-overlay,
.vpechatay-agreement-dialog .b24-form-scroll-textable,
.vpechatay-agreement-dialog .b24-window-scroll-arrow-up-box,
.vpechatay-agreement-dialog .b24-window-scroll-arrow-down-box,
.vpechatay-agreement-dialog .b24-window-scroll-anchor {
    display: none !important;
}

.vpechatay-agreement-dialog .b24-window-popup.b24-window-popup-on-top {
    position: static;
    display: block;
    animation: none !important;
    transition: none !important;
    transform: none !important;
    opacity: 1 !important;
}

.vpechatay-agreement-dialog .b24-window-popup-wrapper {
    width: 100%;
    max-width: none !important;
    background: transparent;
}

.vpechatay-agreement-dialog .b24-window-popup-wrapper .b24-window-scrollable {
    display: flex;
    flex-direction: column;
    max-height: min(650px, calc(100vh - 26px));
    max-height: min(650px, calc(100dvh - 26px));
    padding: 0;
    overflow: hidden;
}

.vpechatay-agreement-dialog .b24-window-popup-head {
    flex: none;
    min-height: 66px;
    margin: 0;
    padding: 14px 67px 13px clamp(14px, 3vw, 26px);
    border-bottom: 1px solid #e8d8c8;
}

.vpechatay-agreement-dialog .b24-window-popup-title {
    color: var(--vp-ink, #221b16);
    font: 750 clamp(19px, 3vw, 26px)/1.16 var(--vp-display, Georgia, serif);
    overflow: visible;
    white-space: normal;
}

.vpechatay-agreement-dialog .b24-window .b24-window-close {
    inset: 9px 10px auto auto;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    opacity: 1;
}

.vpechatay-agreement-dialog .b24-window-popup-body,
.vpechatay-agreement-dialog [data-testid="crm-agreement-popup"] {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-height: 0;
    padding: 0 !important;
}

.vpechatay-agreement-dialog [data-testid="crm-agreement-popup-text"] {
    min-height: 0;
    padding: 15px clamp(14px, 3vw, 26px);
    overflow: auto;
    overscroll-behavior: contain;
    overflow-wrap: anywhere;
    color: var(--vp-ink, #221b16);
    font: 400 15px/1.53 var(--vp-body, sans-serif);
}

.vpechatay-agreement-dialog [data-testid="crm-agreement-popup-text"]:focus-visible {
    outline-offset: -3px;
}

.vpechatay-agreement-dialog [data-testid="crm-agreement-popup"] .b24-form-btn-container {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    flex: none;
    gap: 8px;
    margin: 0;
    padding: 11px clamp(14px, 3vw, 26px) 13px !important;
    border-top: 1px solid #e8d8c8;
}

.vpechatay-agreement-dialog [data-testid="crm-agreement-popup"] .b24-form-btn-block {
    width: auto;
    margin: 0;
    padding: 0;
}

.vpechatay-agreement-dialog [data-testid="crm-agreement-popup"] .b24-form-btn {
    min-height: 44px;
    padding: 8px;
    font: 800 14px/1.2 var(--vp-body, sans-serif);
    background: #a74705;
    border-color: #a74705;
    color: #fff;
    white-space: normal;
}

.vpechatay-agreement-dialog [data-testid="crm-agreement-popup-reject-btn"] {
    background: #fffaf3 !important;
    border-color: #cda98b !important;
    color: #78340b !important;
}

@media (max-width: 600px) {
    .vpechatay-contact-dialog {
        width: calc(100vw - 20px);
        max-height: calc(100vh - 24px);
        max-height: calc(100dvh - 24px);
        border-radius: 18px;
    }

    .vpechatay-contact-dialog__head {
        padding: 12px 16px 6px;
    }

    .vpechatay-contact-dialog__body {
        padding: 0 16px 16px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .vpechatay-contact-dialog[open],
    .vpechatay-contact-dialog[open]::backdrop,
    .vpechatay-contact-dialog[open].is-closing,
    .vpechatay-contact-dialog[open].is-closing::backdrop,
    .vpechatay-agreement-dialog[open]::backdrop {
        animation: none;
    }
}
