.probpr-inbox-customer {
    --pic-primary: var(--site-button, #2563eb);
    --pic-border: #e2e8f0;
    --pic-text: #0f172a;
    --pic-muted: #64748b;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.probpr-inbox-customer--floating {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 9998;
}

.probpr-inbox-launcher {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-height: 52px;
    padding: 11px 17px;
    border: 0;
    border-radius: 999px;
    background: var(--pic-primary);
    color: #fff;
    box-shadow: 0 16px 36px rgba(15, 23, 42, .24);
    font: inherit;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
}

.probpr-inbox-launcher-icon {
    font-size: 20px;
}

.probpr-inbox-launcher-badge {
    position: absolute;
    top: -5px;
    right: -3px;
    display: grid;
    place-items: center;
    min-width: 22px;
    height: 22px;
    padding: 0 5px;
    border: 2px solid #fff;
    border-radius: 999px;
    background: #ef4444;
    color: #fff;
    font-size: 10px;
}

.probpr-inbox-window {
    overflow: hidden;
    border: 1px solid var(--pic-border);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 22px 60px rgba(15, 23, 42, .22);
}

.probpr-inbox-customer--floating .probpr-inbox-window {
    position: absolute;
    right: 0;
    bottom: 66px;
    width: min(390px, calc(100vw - 28px));
    height: min(630px, calc(100vh - 110px));
}

.probpr-inbox-customer--account .probpr-inbox-window {
    width: 100%;
    min-height: 640px;
    box-shadow: 0 10px 34px rgba(15, 23, 42, .06);
}

.probpr-inbox-customer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 70px;
    padding: 14px 16px;
    background: linear-gradient(135deg, var(--pic-primary), #1d4ed8);
    color: #fff;
}

.probpr-inbox-customer-head span,
.probpr-inbox-customer-head strong {
    display: block;
}

.probpr-inbox-customer-head span {
    font-size: 11px;
    opacity: .82;
}

.probpr-inbox-customer-head strong {
    margin-top: 2px;
    font-size: 15px;
}

.probpr-inbox-close {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: rgba(255,255,255,.16);
    color: #fff;
    font: inherit;
    font-size: 23px;
    cursor: pointer;
}

.probpr-inbox-customer-body {
    position: relative;
    height: calc(100% - 70px);
    min-height: 520px;
    background: #f8fafc;
}

.probpr-inbox-customer--account .probpr-inbox-customer-body {
    min-height: 570px;
}

.probpr-inbox-loading,
.probpr-inbox-identity,
.probpr-inbox-auth-required {
    padding: 22px;
}

.probpr-inbox-loading {
    color: var(--pic-muted);
    text-align: center;
}

.probpr-inbox-alert {
    margin: 12px 14px 0;
    padding: 10px 12px;
    border-radius: 10px;
    background: #dcfce7;
    color: #166534;
    font-size: 12px;
    font-weight: 700;
}

.probpr-inbox-alert.is-error {
    background: #fee2e2;
    color: #b91c1c;
}

.probpr-inbox-intro {
    margin-bottom: 16px;
}

.probpr-inbox-intro strong,
.probpr-inbox-intro span {
    display: block;
}

.probpr-inbox-intro strong {
    color: var(--pic-text);
    font-size: 19px;
}

.probpr-inbox-intro span {
    margin-top: 5px;
    color: var(--pic-muted);
    font-size: 13px;
    line-height: 1.5;
}

.probpr-inbox-identity label {
    display: block;
    margin-bottom: 12px;
}

.probpr-inbox-identity label > span {
    display: block;
    margin-bottom: 5px;
    color: #334155;
    font-size: 12px;
    font-weight: 700;
}

.probpr-inbox-identity input,
.probpr-inbox-identity textarea,
.probpr-inbox-composer textarea,
.probpr-inbox-request-strip select {
    width: 100%;
    border: 1px solid var(--pic-border);
    border-radius: 10px;
    background: #fff;
    color: var(--pic-text);
    font: inherit;
    outline: 0;
}

.probpr-inbox-identity input {
    height: 42px;
    padding: 0 11px;
}

.probpr-inbox-identity textarea {
    padding: 10px 11px;
    resize: vertical;
}

.probpr-inbox-identity input:focus,
.probpr-inbox-identity textarea:focus,
.probpr-inbox-composer textarea:focus,
.probpr-inbox-request-strip select:focus {
    border-color: #93c5fd;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .1);
}

.probpr-inbox-primary-button,
.probpr-inbox-composer button {
    border: 0;
    border-radius: 10px;
    background: var(--pic-primary);
    color: #fff;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.probpr-inbox-primary-button {
    width: 100%;
    min-height: 44px;
    padding: 10px 15px;
}

.probpr-inbox-primary-button:disabled,
.probpr-inbox-composer button:disabled {
    opacity: .55;
    cursor: wait;
}

.probpr-inbox-auth-required {
    text-align: center;
}

.probpr-inbox-auth-required strong {
    display: block;
    color: var(--pic-text);
    font-size: 18px;
}

.probpr-inbox-auth-required p {
    margin: 8px 0 16px;
    color: var(--pic-muted);
    font-size: 13px;
    line-height: 1.55;
}

.probpr-inbox-auth-required > div {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.probpr-inbox-auth-required a {
    padding: 10px 13px;
    border: 1px solid var(--pic-border);
    border-radius: 10px;
    background: #fff;
    color: var(--pic-text);
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
}

.probpr-inbox-auth-required a:first-child {
    border-color: var(--pic-primary);
    background: var(--pic-primary);
    color: #fff;
}

.probpr-inbox-chat {
    display: grid;
    grid-template-rows: auto 1fr auto auto;
    height: 100%;
    min-height: 520px;
}

.probpr-inbox-customer--account .probpr-inbox-chat {
    min-height: 570px;
}

.probpr-inbox-request-strip {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border-bottom: 1px solid var(--pic-border);
    background: #fff;
}

.probpr-inbox-request-strip select {
    height: 36px;
    padding: 0 9px;
    font-size: 11px;
}

.probpr-inbox-request-strip > span {
    padding: 5px 8px;
    border-radius: 999px;
    background: #e2e8f0;
    color: #475569;
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
}

.probpr-inbox-request-strip > span.is-new { background: #fee2e2; color: #b91c1c; }
.probpr-inbox-request-strip > span.is-open { background: #dbeafe; color: #1d4ed8; }
.probpr-inbox-request-strip > span.is-pending { background: #fef3c7; color: #92400e; }
.probpr-inbox-request-strip > span.is-closed { background: #dcfce7; color: #166534; }

.probpr-inbox-messages {
    overflow-y: auto;
    padding: 15px;
}

.probpr-inbox-customer-message {
    max-width: 84%;
    margin-bottom: 12px;
}

.probpr-inbox-customer-message.is-customer {
    margin-left: auto;
}

.probpr-inbox-customer-message > .probpr-inbox-customer-message-body {
    padding: 10px 12px;
    border: 1px solid var(--pic-border);
    border-radius: 13px 13px 13px 4px;
    background: #fff;
    color: #1e293b;
    font-size: 13px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.probpr-inbox-customer-message.is-customer > .probpr-inbox-customer-message-body {
    border-color: var(--pic-primary);
    border-radius: 13px 13px 4px 13px;
    background: var(--pic-primary);
    color: #fff;
}

.probpr-inbox-customer-message small {
    display: block;
    margin-top: 4px;
    color: #94a3b8;
    font-size: 9px;
}

.probpr-inbox-customer-message.is-customer small {
    text-align: right;
}

.probpr-inbox-customer-empty {
    display: flex;
    min-height: 250px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    color: var(--pic-muted);
    text-align: center;
}

.probpr-inbox-customer-empty strong {
    color: var(--pic-text);
}

.probpr-inbox-composer {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    padding: 11px 12px;
    border-top: 1px solid var(--pic-border);
    background: #fff;
}

.probpr-inbox-composer textarea {
    min-height: 44px;
    max-height: 120px;
    padding: 10px;
    resize: none;
}

.probpr-inbox-composer button {
    align-self: end;
    min-height: 44px;
    padding: 9px 13px;
}

.probpr-inbox-closed-note {
    padding: 0 12px 10px;
    background: #fff;
    color: var(--pic-muted);
    font-size: 10px;
    text-align: center;
}

@media (max-width: 600px) {
    .probpr-inbox-customer--floating {
        right: 12px;
        bottom: 12px;
    }

    .probpr-inbox-customer--floating.is-open {
        inset: 0;
    }

    .probpr-inbox-customer--floating.is-open .probpr-inbox-launcher {
        display: none;
    }

    .probpr-inbox-customer--floating .probpr-inbox-window {
        position: fixed;
        inset: 0;
        width: 100%;
        height: 100%;
        border: 0;
        border-radius: 0;
    }

    .probpr-inbox-customer--floating .probpr-inbox-customer-body,
    .probpr-inbox-customer--floating .probpr-inbox-chat {
        min-height: calc(100vh - 70px);
    }

    .probpr-inbox-launcher-label {
        display: none;
    }

    .probpr-inbox-launcher {
        width: 54px;
        height: 54px;
        justify-content: center;
        padding: 0;
    }
}

.probpr-inbox-honeypot {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
    pointer-events: none !important;
}


/* v79.31 — customer attachments and lazy message history. */
.probpr-inbox-composer {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
}

.probpr-inbox-composer-main {
    display: grid;
    min-width: 0;
    gap: 6px;
}

.probpr-inbox-composer-actions {
    display: flex;
    align-items: end;
    gap: 6px;
}

.probpr-inbox-attach-button {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border: 1px solid var(--pic-border);
    border-radius: 10px;
    background: #fff;
    color: var(--pic-text);
    font-size: 18px;
    cursor: pointer;
}

.probpr-inbox-selected-files {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.probpr-inbox-selected-files[hidden] {
    display: none;
}

.probpr-inbox-selected-files > span {
    display: inline-flex;
    max-width: 100%;
    align-items: center;
    gap: 5px;
    padding: 5px 7px;
    border: 1px solid var(--pic-border);
    border-radius: 8px;
    background: #f8fafc;
    color: #334155;
    font-size: 10px;
}

.probpr-inbox-selected-files > span > span {
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.probpr-inbox-selected-files small {
    color: #94a3b8;
}

.probpr-inbox-composer.is-dragging-file {
    outline: 2px dashed var(--pic-primary);
    outline-offset: -7px;
    background: #eff6ff;
}

.probpr-inbox-customer-message-body {
    padding: 10px 12px;
    border: 1px solid var(--pic-border);
    border-radius: 13px 13px 13px 4px;
    background: #fff;
    color: #1e293b;
    font-size: 13px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.probpr-inbox-customer-message.is-customer .probpr-inbox-customer-message-body {
    border-color: var(--pic-primary);
    border-radius: 13px 13px 4px 13px;
    background: var(--pic-primary);
    color: #fff;
}

.probpr-inbox-customer-message.is-system {
    max-width: 94%;
    margin-right: auto;
    margin-left: auto;
    text-align: center;
}

.probpr-inbox-customer-message.is-system .probpr-inbox-customer-message-body {
    border-style: dashed;
    border-radius: 11px;
    background: #f1f5f9;
    color: #475569;
}

.probpr-inbox-customer-attachments {
    display: grid;
    gap: 6px;
    margin-top: 6px;
}

.probpr-inbox-customer-attachment {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 8px;
    padding: 7px;
    border: 1px solid var(--pic-border);
    border-radius: 10px;
    background: #fff;
    color: #334155;
    text-align: left;
}

.probpr-inbox-customer-attachment > span,
.probpr-inbox-customer-attachment-preview {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    overflow: hidden;
    border-radius: 8px;
    background: #e2e8f0;
    font-size: 18px;
}

.probpr-inbox-customer-attachment-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.probpr-inbox-customer-attachment div {
    display: grid;
    min-width: 0;
    gap: 2px;
}

.probpr-inbox-customer-attachment a {
    overflow: hidden;
    color: #1d4ed8;
    font-size: 11px;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.probpr-inbox-customer-attachment small {
    margin: 0;
    color: #94a3b8;
    font-size: 9px;
    text-align: left;
}

.probpr-inbox-customer-attachment.is-unavailable {
    opacity: .72;
}

.probpr-inbox-messages.is-loading-history::before {
    content: "Завантаження старіших повідомлень…";
    display: block;
    margin-bottom: 8px;
    color: var(--pic-muted);
    font-size: 10px;
    text-align: center;
}

@media (max-width: 600px) {
    .probpr-inbox-composer {
        grid-template-columns: minmax(0, 1fr);
    }

    .probpr-inbox-composer-actions {
        justify-content: flex-end;
    }
}

/* v79.31.2 — restore customer chat bubbles and compact attachment control. */
.probpr-inbox-customer .probpr-inbox-messages {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 16px;
    scrollbar-width: thin;
    scrollbar-color: #94a3b8 transparent;
}

.probpr-inbox-customer .probpr-inbox-customer-message {
    display: flex;
    width: fit-content;
    max-width: 84%;
    margin: 0;
    flex-direction: column;
    align-items: flex-start;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-operator {
    align-self: flex-start;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-customer {
    align-self: flex-end;
    align-items: flex-end;
    margin-left: 0;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-system {
    width: 100%;
    max-width: 94%;
    align-self: center;
    align-items: center;
}

.probpr-inbox-customer .probpr-inbox-customer-message-body {
    display: block !important;
    width: auto !important;
    max-width: 100%;
    margin: 0 !important;
    padding: 10px 13px !important;
    border: 1px solid #dbe4f0 !important;
    border-radius: 15px 15px 15px 5px !important;
    background: #ffffff !important;
    box-shadow: 0 3px 10px rgba(15, 23, 42, .055);
    color: #172033 !important;
    font-size: 13px !important;
    font-weight: 500;
    line-height: 1.5 !important;
    text-align: left;
    overflow-wrap: anywhere;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-customer .probpr-inbox-customer-message-body {
    border-color: transparent !important;
    border-radius: 15px 15px 5px 15px !important;
    background: linear-gradient(135deg, var(--pic-primary), #3158df) !important;
    box-shadow: 0 5px 14px rgba(49, 88, 223, .18);
    color: #ffffff !important;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-system .probpr-inbox-customer-message-body {
    border: 1px dashed #cbd5e1 !important;
    border-radius: 12px !important;
    background: #f1f5f9 !important;
    box-shadow: none;
    color: #475569 !important;
    text-align: center;
}

.probpr-inbox-customer .probpr-inbox-customer-message > small {
    display: block;
    margin: 5px 3px 0;
    color: #8da0bd;
    font-size: 9px;
    line-height: 1.35;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-customer > small {
    align-self: flex-end;
    text-align: right;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-operator > small {
    align-self: flex-start;
    text-align: left;
}

.probpr-inbox-customer .probpr-inbox-customer-attachments {
    width: min(100%, 310px);
    margin-top: 7px;
}

.probpr-inbox-customer .probpr-inbox-composer {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 8px;
    padding: 11px 12px;
}

.probpr-inbox-customer .probpr-inbox-composer-actions {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: flex-end;
    gap: 7px;
}

.probpr-inbox-customer .probpr-inbox-attach-button {
    display: inline-grid !important;
    flex: 0 0 44px;
    width: 44px !important;
    min-width: 44px !important;
    max-width: 44px !important;
    height: 44px !important;
    min-height: 44px;
    padding: 0 !important;
    place-items: center;
    overflow: hidden;
    border: 1px solid #dbe4f0;
    border-radius: 12px;
    background: #f8fafc;
    color: #334155;
    font-size: 0 !important;
    line-height: 1;
    cursor: pointer;
    transition: border-color .18s ease, background .18s ease, transform .18s ease;
}

.probpr-inbox-customer .probpr-inbox-attach-button:hover {
    border-color: #93c5fd;
    background: #eff6ff;
    transform: translateY(-1px);
}

.probpr-inbox-customer .probpr-inbox-attach-button > span[aria-hidden="true"] {
    display: block !important;
    width: auto !important;
    height: auto !important;
    font-size: 20px !important;
    line-height: 1 !important;
}

.probpr-inbox-customer .probpr-inbox-attach-button .screen-reader-text {
    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;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.probpr-inbox-customer .probpr-inbox-composer button[type="submit"] {
    min-width: 112px;
    min-height: 44px;
    padding: 9px 14px;
    border-radius: 12px;
    white-space: nowrap;
}

@media (max-width: 520px) {
    .probpr-inbox-customer .probpr-inbox-messages {
        padding: 14px 12px;
    }

    .probpr-inbox-customer .probpr-inbox-customer-message {
        max-width: 88%;
    }

    .probpr-inbox-customer .probpr-inbox-composer {
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .probpr-inbox-customer .probpr-inbox-composer button[type="submit"] {
        min-width: 105px;
        padding-right: 12px;
        padding-left: 12px;
    }
}

/* v79.31.3 — robust chat bubbles regardless of message inner markup. */
.probpr-inbox-customer .probpr-inbox-customer-message {
    display: block !important;
    align-self: flex-start;
    width: fit-content !important;
    max-width: 84% !important;
    margin: 0 !important;
    padding: 10px 13px 8px !important;
    border: 1px solid #dbe4f0 !important;
    border-radius: 15px 15px 15px 5px !important;
    background: #ffffff !important;
    box-shadow: 0 3px 10px rgba(15, 23, 42, .065) !important;
    color: #172033 !important;
    font-size: 13px !important;
    font-weight: 500;
    line-height: 1.5 !important;
    text-align: left;
    overflow-wrap: anywhere;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-operator {
    align-self: flex-start;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-customer {
    align-self: flex-end;
    margin-left: auto !important;
    border-color: transparent !important;
    border-radius: 15px 15px 5px 15px !important;
    background: linear-gradient(135deg, var(--pic-primary), #3158df) !important;
    box-shadow: 0 5px 14px rgba(49, 88, 223, .2) !important;
    color: #ffffff !important;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-system {
    align-self: center;
    width: auto !important;
    max-width: 94% !important;
    border: 1px dashed #cbd5e1 !important;
    border-radius: 12px !important;
    background: #f1f5f9 !important;
    box-shadow: none !important;
    color: #475569 !important;
    text-align: center;
}

/* The wrapper may exist in newer JS or be absent in cached/older markup. */
.probpr-inbox-customer .probpr-inbox-customer-message > .probpr-inbox-customer-message-body {
    display: block !important;
    width: auto !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: inherit !important;
    font: inherit !important;
    line-height: inherit !important;
    text-align: inherit;
}

.probpr-inbox-customer .probpr-inbox-customer-message > small {
    display: block !important;
    margin: 6px 0 0 !important;
    color: #8da0bd !important;
    font-size: 9px !important;
    font-weight: 400;
    line-height: 1.35 !important;
    text-align: left;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-customer > small {
    color: rgba(255, 255, 255, .78) !important;
    text-align: right;
}

.probpr-inbox-customer .probpr-inbox-customer-message.is-system > small {
    color: #94a3b8 !important;
    text-align: center;
}

.probpr-inbox-customer .probpr-inbox-customer-message .probpr-inbox-customer-attachments {
    margin-top: 8px;
}

@media (max-width: 520px) {
    .probpr-inbox-customer .probpr-inbox-customer-message {
        max-width: 88% !important;
    }
}

/* v79.33 — Telegram identity linking in the learner account. */
.probpr-telegram-link-card {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 14px;
    margin-bottom: 18px;
    padding: 17px;
    border: 1px solid #dbe4f0;
    border-radius: 16px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    box-shadow: 0 8px 24px rgba(15, 23, 42, .055);
    color: #172033;
}

.probpr-telegram-link-card.is-linked {
    border-color: #bbf7d0;
    background: linear-gradient(180deg, #ffffff 0%, #f0fdf4 100%);
}

.probpr-telegram-link-icon {
    display: grid;
    width: 48px;
    height: 48px;
    place-items: center;
    border-radius: 14px;
    background: linear-gradient(135deg, #38bdf8, #2563eb);
    box-shadow: 0 7px 18px rgba(37, 99, 235, .20);
    color: #fff;
    font-size: 23px;
    line-height: 1;
}

.probpr-telegram-link-content {
    min-width: 0;
}

.probpr-telegram-link-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.probpr-telegram-link-heading span,
.probpr-telegram-link-heading strong {
    display: block;
}

.probpr-telegram-link-heading span {
    margin-bottom: 2px;
    color: #64748b;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.probpr-telegram-link-heading strong {
    color: #0f172a;
    font-size: 17px;
}

.probpr-telegram-link-heading em {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 9px;
    border-radius: 999px;
    background: #dbeafe;
    color: #1d4ed8;
    font-size: 10px;
    font-style: normal;
    font-weight: 800;
    white-space: nowrap;
}

.probpr-telegram-link-heading em.is-success {
    background: #dcfce7;
    color: #15803d;
}

.probpr-telegram-link-heading em.is-muted {
    background: #e2e8f0;
    color: #64748b;
}

.probpr-telegram-link-content > p {
    margin: 10px 0 0;
    color: #475569;
    font-size: 12px;
    line-height: 1.55;
}

.probpr-telegram-link-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px 12px;
    margin-top: 13px;
}

.probpr-telegram-link-button,
.probpr-telegram-unlink-form button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 9px 14px;
    border-radius: 10px;
    font: inherit;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
}

.probpr-telegram-link-button {
    border: 0;
    background: linear-gradient(135deg, #38bdf8, #2563eb);
    color: #fff !important;
    box-shadow: 0 6px 15px rgba(37, 99, 235, .18);
}

.probpr-telegram-link-actions > span {
    max-width: 360px;
    color: #64748b;
    font-size: 10px;
    line-height: 1.45;
}

.probpr-telegram-link-identity {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px 10px;
    margin-top: 12px;
    padding: 10px 12px;
    border: 1px solid #bbf7d0;
    border-radius: 11px;
    background: rgba(255,255,255,.8);
}

.probpr-telegram-link-identity strong {
    color: #166534;
    font-size: 12px;
}

.probpr-telegram-link-identity span {
    color: #64748b;
    font-size: 10px;
}

.probpr-telegram-unlink-form {
    margin-top: 11px;
}

.probpr-telegram-unlink-form button {
    border: 1px solid #fecaca;
    background: #fff;
    color: #b91c1c;
}

.probpr-telegram-link-notice {
    margin-top: 10px;
    padding: 8px 10px;
    border-radius: 9px;
    background: #dcfce7;
    color: #166534;
    font-size: 11px;
    font-weight: 700;
}

.probpr-telegram-link-notice.is-error {
    background: #fee2e2;
    color: #b91c1c;
}

@media (max-width: 600px) {
    .probpr-telegram-link-card {
        grid-template-columns: 40px minmax(0, 1fr);
        gap: 11px;
        padding: 14px;
    }

    .probpr-telegram-link-icon {
        width: 40px;
        height: 40px;
        border-radius: 12px;
        font-size: 20px;
    }

    .probpr-telegram-link-heading {
        align-items: flex-start;
    }

    .probpr-telegram-link-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .probpr-telegram-link-button {
        width: 100%;
    }
}

/* v79.33.1 — fixed-height support chat in the listener account. */
.probpr-inbox-customer--account .probpr-inbox-window {
    height: clamp(560px, calc(100vh - 220px), 720px);
    min-height: 0;
    max-height: 720px;
}

.probpr-inbox-customer--account .probpr-inbox-customer-body {
    height: calc(100% - 70px);
    min-height: 0;
    overflow: hidden;
}

.probpr-inbox-customer--account .probpr-inbox-chat {
    height: 100%;
    min-height: 0;
    overflow: hidden;
}

.probpr-inbox-customer--account .probpr-inbox-messages {
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
}

.probpr-user-support-panel .probpr-inbox-customer--account {
    min-width: 0;
}

@media (max-width: 900px) {
    .probpr-inbox-customer--account .probpr-inbox-window {
        height: min(680px, calc(100dvh - 150px));
        min-height: 520px;
    }
}

@media (max-width: 600px) {
    .probpr-inbox-customer--account .probpr-inbox-window {
        height: min(640px, calc(100dvh - 110px));
        min-height: 500px;
    }

    .probpr-inbox-customer--account .probpr-inbox-customer-body,
    .probpr-inbox-customer--account .probpr-inbox-chat {
        min-height: 0;
    }
}

/* ProBPR Communications Hub v81.0 — customer rating */
.probpr-inbox-rating {
    display: grid;
    gap: 8px;
    margin-top: 10px;
    padding: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #f8fafc;
}
.probpr-inbox-rating[hidden] { display: none !important; }
.probpr-inbox-rating > strong { color: #0f172a; font-size: 14px; }
.probpr-inbox-rating > span,
.probpr-inbox-rating > small { color: #64748b; font-size: 12px; }
.probpr-inbox-rating-stars { display: flex; gap: 5px; }
.probpr-inbox-rating-stars button {
    appearance: none;
    border: 0;
    padding: 0;
    background: transparent;
    color: #cbd5e1;
    font-size: 25px;
    line-height: 1;
    cursor: pointer;
}
.probpr-inbox-rating-stars button:hover,
.probpr-inbox-rating-stars button.is-active { color: #f59e0b; }
.probpr-inbox-rating-stars button:disabled { cursor: default; }
.probpr-inbox-rating textarea {
    width: 100%;
    min-height: 58px;
    resize: vertical;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    padding: 9px 10px;
    background: #fff;
    color: #0f172a;
}
