/* Contact controls keep their current button layout; their former collapse panels
 * are rendered in a detached modal by zdt-contact-modals.js. */
.contacts-accordion-tabs .drts-bs-collapse {
    display: none !important;
    height: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
}

.contacts-accordion-tabs .drts-bs-card-body {
    border: 0;
}

.contacts-accordion-tabs.zdt-contact-modals-ready .drts-content-tab {
    position: relative;
    z-index: 1;
}

body.zdt-contact-modal-open {
    overflow: hidden;
}

.zdt-contact-modal[hidden] {
    display: none !important;
}

.zdt-contact-modal {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: grid;
    place-items: center;
    padding: 20px;
}

.zdt-contact-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(31, 36, 48, 0.52);
}

.zdt-contact-modal__dialog {
    position: relative;
    width: min(100%, 430px);
    max-height: calc(100vh - 40px);
    overflow: auto;
    padding: 28px;
    border: 1px solid #dfe4ec;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(31, 36, 48, 0.24);
    color: #535353;
}

.zdt-contact-modal__title {
    margin: 0 44px 20px 0;
    color: #4044a8;
    font-size: 1.35rem;
    line-height: 1.25;
}

.zdt-contact-modal__close {
    position: absolute;
    top: 14px;
    right: 14px;
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    padding: 0;
    border: 1px solid #d8dde5;
    border-radius: 50%;
    background: #fff;
    color: #535353;
    font: 400 28px/1 Arial, sans-serif;
    cursor: pointer;
}

.zdt-contact-modal__close:hover,
.zdt-contact-modal__close:focus-visible {
    border-color: #6c8bc3;
    color: #4044a8;
    outline: 0;
}

.zdt-contact-modal__content .drts-display-element-inlineable {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 14px;
    font-size: 1.1rem;
}

.zdt-contact-modal__content .drts-display-element-inlineable:last-child {
    margin-bottom: 0;
}

.zdt-contact-modal__content .drts-entity-field-label {
    color: #6c8bc3;
}

.zdt-contact-modal__content a {
    color: #535353;
    border-bottom: 1px dotted currentColor;
    overflow-wrap: anywhere;
    text-decoration: none;
}

.zdt-contact-modal__content a:hover {
    color: #4044a8;
    border-bottom-style: solid;
}

@media (max-width: 768px) {
    .zdt-contact-modal {
        align-items: end;
        padding: 12px;
    }

    .zdt-contact-modal__dialog {
        width: 100%;
        padding: 25px 22px 28px;
        border-radius: 20px;
    }

    .zdt-contact-modal__content .drts-display-element-inlineable {
        font-size: 1rem;
    }
}

@media (prefers-reduced-motion: no-preference) {
    .zdt-contact-modal:not([hidden]) .zdt-contact-modal__backdrop {
        animation: zdt-contact-modal-fade 100ms ease-out both;
    }

    .zdt-contact-modal:not([hidden]) .zdt-contact-modal__dialog {
        animation: zdt-contact-modal-enter 120ms ease-out both;
    }
}

@keyframes zdt-contact-modal-fade {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes zdt-contact-modal-enter {
    from {
        opacity: 0;
        transform: translateY(4px) scale(0.995);
    }
    to {
        opacity: 1;
        transform: none;
    }
}
