/**
 * Vendor console visual language — premium WhatsApp workspace.
 * Loaded after ux-arabic.css. Does not rewrite mobile chat CSS.
 */
:root {
    --lw-ui-green: #008069;
    --lw-ui-green-dark: #005c4b;
    --lw-ui-green-soft: #e7f8f2;
    --lw-ui-text: #111b21;
    --lw-ui-muted: #667781;
    --lw-ui-border: #e9edef;
    --lw-ui-panel: #ffffff;
    --lw-ui-panel-alt: #f0f2f5;
    --lw-ui-danger: #ea0038;
    --lw-ui-danger-bg: #fff5f5;
    --lw-ui-radius: 8px;
    --lw-ui-radius-sm: 6px;
    --lw-ui-sidebar-collapsed: 68px;
    --lw-ui-sidebar-expanded: 272px;
}

.lw-ltr-data {
    direction: ltr;
    unicode-bidi: isolate;
    display: inline-block;
}

/* ---------- Typography ---------- */
body.lw-authenticated-page {
    color: var(--lw-ui-text);
    line-height: 1.55;
}

html[dir="rtl"] body.lw-authenticated-page {
    line-height: 1.7;
}

.navbar-vertical .navbar-nav .nav-link {
    display: flex;
    align-items: center;
    line-height: 1.25;
    font-size: 0.925rem;
}

html[dir="rtl"] .navbar-vertical .navbar-nav .nav-link {
    line-height: 1.35;
}

.navbar-vertical .navbar-nav .nav-link > i,
.navbar-vertical .navbar-nav .nav-link > .ni {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    height: 1.15em;
    flex-shrink: 0;
}

/* ---------- Super-admin / impersonation banner ---------- */
.lw-impersonation-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    width: 100%;
    flex: 0 0 auto;
    min-height: 36px;
    padding: 6px 16px;
    background: #0f3d34;
    color: #e8f6f1;
    font-size: 13px;
    line-height: 1.45;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.lw-impersonation-banner__text {
    flex: 1 1 auto;
    min-width: 0;
}

.lw-impersonation-banner__action {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #fff !important;
    font-weight: 600;
    font-size: 13px;
    white-space: nowrap;
    padding: 4px 10px;
    border-radius: var(--lw-ui-radius-sm);
    background: rgba(255, 255, 255, 0.12);
    text-decoration: none !important;
}

.lw-impersonation-banner__action:hover,
.lw-impersonation-banner__action:focus {
    background: rgba(255, 255, 255, 0.2);
    color: #fff !important;
}

html[dir="rtl"] .lw-impersonation-banner__action i {
    transform: scaleX(-1);
}

/* ---------- Sidebar ---------- */
@media (min-width: 768px) {
    .lw-minimized-menu .navbar-vertical.navbar-expand-md.fixed-left + .main-content {
        margin-left: var(--lw-ui-sidebar-collapsed);
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md {
        width: var(--lw-ui-sidebar-collapsed);
        max-width: var(--lw-ui-sidebar-expanded);
        overflow-x: hidden;
        padding-inline: 0;
        border-inline-end: 1px solid var(--lw-ui-border);
        background: #fbfcfd;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md > .container-fluid {
        width: calc(var(--lw-ui-sidebar-expanded) - 16px);
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md:hover,
    .lw-minimized-menu .navbar-vertical.navbar-expand-md:focus-within {
        width: var(--lw-ui-sidebar-expanded);
        box-shadow: 8px 0 24px rgba(17, 27, 33, 0.06);
    }

    html[dir="rtl"] .lw-minimized-menu .navbar-vertical.navbar-expand-md:hover,
    html[dir="rtl"] .lw-minimized-menu .navbar-vertical.navbar-expand-md:focus-within {
        box-shadow: -8px 0 24px rgba(17, 27, 33, 0.06);
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md .navbar-nav .nav-link {
        display: flex;
        align-items: center;
        min-height: 40px;
        padding-block: 0.5rem;
        border-radius: var(--lw-ui-radius-sm);
        margin-inline: 6px;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md:not(:hover):not(:focus-within) .navbar-nav .nav-link {
        font-size: 0;
        line-height: 0;
        justify-content: center;
        padding-inline: 0;
        margin-inline: 4px;
        overflow: hidden;
        position: relative;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md:not(:hover):not(:focus-within) .navbar-nav .nav-link > i,
    .lw-minimized-menu .navbar-vertical.navbar-expand-md:not(:hover):not(:focus-within) .navbar-nav .nav-link > .ni {
        font-size: 0.95rem;
        line-height: 1;
        margin-inline-end: 0 !important;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md:not(:hover):not(:focus-within) .navbar-nav .nav-link[data-toggle="collapse"]:after {
        display: none;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md:not(:hover):not(:focus-within) .navbar-nav .nav-link .badge {
        font-size: 10px;
        line-height: 1.2;
        position: absolute;
        top: 4px;
        inset-inline-end: 2px;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md:not(:hover):not(:focus-within) .lw-sidebar-logo-small {
        margin-left: 0;
        margin-inline-start: 0;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md:hover .nav .nav-item .nav-link,
    .lw-minimized-menu .navbar-vertical.navbar-expand-md:focus-within .nav .nav-item .nav-link {
        padding-left: 2.5rem;
        padding-inline-start: 2.5rem;
        padding-inline-end: 10px;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md .navbar-nav .nav-link[data-toggle="collapse"]:after {
        margin-inline-start: auto;
        margin-inline-end: 4px;
        flex-shrink: 0;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md .navbar-nav .nav-link > i,
    .lw-minimized-menu .navbar-vertical.navbar-expand-md .navbar-nav .nav-link > .ni {
        width: 1.35rem;
        min-width: 1.35rem;
        font-size: 0.95rem;
        text-align: center;
        margin-inline-end: 0.65rem;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md .navbar-nav .nav-link.active {
        color: var(--lw-ui-green-dark);
        background: var(--lw-ui-green-soft);
        font-weight: 600;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md .navbar-nav .nav-link.active:before {
        border-inline-start: 3px solid var(--lw-ui-green);
        border-left-color: var(--lw-ui-green);
    }

    .lw-nav-heading {
        display: none;
        list-style: none;
        padding: 1rem 1.1rem 0.25rem;
        margin: 0.35rem 0 0;
        font-size: 11px;
        font-weight: 700;
        letter-spacing: 0.06em;
        text-transform: uppercase;
        color: var(--lw-ui-muted);
        line-height: 1.4;
    }

    .lw-minimized-menu .navbar-vertical.navbar-expand-md:hover .lw-nav-heading,
    .lw-minimized-menu .navbar-vertical.navbar-expand-md:focus-within .lw-nav-heading {
        display: block;
    }

    .navbar-vertical .navbar-nav > .nav-item > .nav-link.lw-nav-section {
        font-size: 0.78rem;
        font-weight: 700;
        letter-spacing: 0.04em;
        text-transform: uppercase;
        color: #54656f;
        margin-top: 0.45rem;
    }

    .navbar-vertical .navbar-nav > .nav-item:first-child > .nav-link {
        margin-bottom: 0.35rem;
        font-weight: 600;
    }

    .navbar-vertical .lw-expandable-nav .nav-link {
        padding-block: 0.42rem;
        font-size: 0.9rem;
        font-weight: 500;
    }
}

@media (max-width: 767.98px) {
    .lw-nav-heading {
        list-style: none;
        padding: 0.85rem 1.15rem 0.2rem;
        margin: 0.25rem 0 0;
        font-size: 11px;
        font-weight: 700;
        letter-spacing: 0.06em;
        text-transform: uppercase;
        color: var(--lw-ui-muted);
    }

    .navbar-vertical .navbar-nav .nav-link {
        min-height: 44px;
        align-items: center;
    }
}

/* ---------- Chat workspace ---------- */
@media (min-width: 768px) {
    body.lw-whatsapp-chat-page .main-content {
        background: #eae6df;
    }

    .card.lw-whatsapp-chat-block-container {
        border: 1px solid var(--lw-ui-border);
        border-radius: 10px;
        box-shadow: 0 1px 2px rgba(17, 27, 33, 0.04);
        overflow: hidden;
        background: var(--lw-ui-panel);
    }

    .card.lw-whatsapp-chat-block-container > .card-header {
        padding: 10px 16px;
        background: #f7f8fa;
        border-bottom: 1px solid var(--lw-ui-border);
        font-size: 13px;
    }

    .lw-whatsapp-chat-window {
        padding: 0 !important;
    }

    .lw-whatsapp-chat-window > .row {
        margin: 0;
        min-height: calc(100vh - 130px);
    }

    .lw-whatsapp-chat-window > .row > [class*="col-"] {
        padding: 0;
        margin-bottom: 0 !important;
    }

    .lw-contact-list-block,
    .lw-contact-crm-block {
        background: #f7f8fa;
        border-inline-end: 1px solid var(--lw-ui-border);
    }

    html[dir="rtl"] .lw-contact-list-block {
        border-inline-end: 1px solid var(--lw-ui-border);
        border-inline-start: 0;
    }

    .lw-contact-crm-block {
        border-inline-end: 0;
        border-inline-start: 1px solid var(--lw-ui-border);
        background: #fbfcfd;
    }

    .lw-whatsapp-chat-window .page.col-md-6 {
        background: #efeae2;
        box-shadow: inset 0 0 0 1px rgba(17, 27, 33, 0.03);
    }

    .lw-chat-list-toolbar {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
        padding: 14px 16px 8px;
    }

    .lw-chat-list-title {
        font-size: 1.05rem;
        font-weight: 700;
        margin: 0;
        line-height: 1.4;
        color: var(--lw-ui-text);
    }

    .lw-chat-unread-toggle {
        padding: 0 16px 8px;
        font-size: 13px;
        color: var(--lw-ui-muted);
    }

    .lw-chat-filters-wrap {
        padding: 0 12px 8px;
        overflow: hidden;
    }

    .lw-chat-filters {
        display: flex;
        align-items: stretch;
        gap: 4px;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 4px;
        scrollbar-width: thin;
        white-space: nowrap;
        border: 0;
    }

    .lw-chat-filters .nav-link,
    .lw-chat-filters .nav-item > .nav-link {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        flex: 0 0 auto;
        padding: 6px 10px;
        margin: 0;
        border: 0;
        border-radius: 999px;
        background: transparent;
        color: var(--lw-ui-muted);
        font-size: 13px;
        font-weight: 600;
        line-height: 1.4;
        white-space: nowrap;
    }

    .lw-chat-filters .nav-link.active,
    .lw-chat-filters .nav-link:hover {
        background: var(--lw-ui-green-soft);
        color: var(--lw-ui-green-dark);
    }

    .lw-chat-filters .nav-link.active {
        box-shadow: inset 0 0 0 1px rgba(0, 128, 105, 0.18);
    }

    .lw-chat-filters .badge {
        min-width: 1.25rem;
        height: 1.25rem;
        padding: 0 5px;
        font-size: 11px;
        font-weight: 700;
        line-height: 1.25rem;
        border-radius: 999px !important;
        background: #fff3cd !important;
        color: #664d03 !important;
    }

    .lw-chat-filters .nav-link.active .badge {
        background: var(--lw-ui-green) !important;
        color: #fff !important;
    }

    .lw-chat-search {
        position: relative;
        padding: 4px 12px 12px;
    }

    .lw-chat-search > i {
        position: absolute;
        inset-inline-start: 24px;
        top: 50%;
        transform: translateY(-40%);
        color: var(--lw-ui-muted);
        font-size: 13px;
        pointer-events: none;
    }

    .lw-chat-search .form-control {
        height: 40px;
        padding-inline-start: 2.1rem;
        border-radius: 20px;
        border: 1px solid var(--lw-ui-border);
        background: #fff;
        font-size: 14px;
        box-shadow: none;
    }

    .lw-chat-search .form-control:focus {
        border-color: var(--lw-ui-green);
        box-shadow: 0 0 0 3px rgba(0, 128, 105, 0.12);
    }

    .lw-whatsapp-chat-window .lw-contact-list {
        height: calc(90vh - 210px);
        background: transparent;
        box-shadow: none !important;
    }

    .lw-whatsapp-chat-window .lw-contact-row {
        align-items: center;
        gap: 12px;
    }

    .lw-whatsapp-chat-window .lw-contact-list .lw-contact {
        padding: 13px 16px !important;
        border-radius: 0 !important;
        border-bottom: 1px solid var(--lw-ui-border) !important;
        border-top: 0 !important;
        border-inline: 0 !important;
    }

    .lw-whatsapp-chat-window .lw-contact-list .lw-contact:hover {
        background: #eef3f1;
    }

    .lw-whatsapp-chat-window .lw-contact-list .lw-contact.is-active,
    .lw-whatsapp-chat-window .lw-contact-list .lw-contact.list-group-item-light {
        background: #d9f0e8;
        box-shadow: inset 3px 0 0 var(--lw-ui-green);
    }

    html[dir="rtl"] .lw-whatsapp-chat-window .lw-contact-list .lw-contact.is-active,
    html[dir="rtl"] .lw-whatsapp-chat-window .lw-contact-list .lw-contact.list-group-item-light {
        box-shadow: inset -3px 0 0 var(--lw-ui-green);
    }

    .lw-contact-avatar {
        width: 44px !important;
        height: 44px !important;
        min-width: 44px;
        border-radius: 50%;
        font-size: 14px;
        font-weight: 700;
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0 !important;
    }

    .lw-contact-title {
        font-size: 15px;
        font-weight: 600;
        color: var(--lw-ui-text);
        max-width: 100%;
        line-height: 1.35;
    }

    .lw-contact-preview,
    .lw-contact-preview-text,
    .lw-contact-phone {
        font-size: 13px;
        line-height: 1.4;
        color: var(--lw-ui-muted);
        font-weight: 400;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 100%;
        display: block;
        margin: 0;
    }

    .lw-contact-meta-right {
        align-items: flex-end;
    }

    .lw-contact-meta-right .lw-last-message-at {
        font-size: 12px;
        color: var(--lw-ui-muted);
        white-space: nowrap;
    }

    .lw-contact-meta-right .badge {
        min-width: 18px;
        height: 18px;
        padding: 0 5px;
        font-size: 11px;
        line-height: 18px;
        font-weight: 700;
        border-radius: 999px !important;
        width: auto !important;
    }

    /* Header */
    .lw-whatsapp-chat-window .user-bar {
        display: flex;
        align-items: center;
        gap: 10px;
        min-height: 56px;
        padding: 8px 14px;
        background: #008069;
        border-radius: 0;
    }

    .lw-whatsapp-chat-window .user-bar:after {
        display: none;
    }

    .lw-whatsapp-chat-window .user-bar > div {
        float: none !important;
        position: relative;
    }

    html[dir="rtl"] .lw-whatsapp-chat-window .user-bar div {
        float: none !important;
    }

    .lw-whatsapp-chat-window .user-bar .avatar {
        width: 40px;
        height: 40px;
        min-width: 40px;
        border-radius: 50%;
        margin: 0 !important;
        display: flex !important;
        align-items: center;
        justify-content: center;
        font-size: 14px;
        font-weight: 700;
        background: #fff !important;
        color: var(--lw-ui-green-dark) !important;
    }

    .lw-whatsapp-chat-window .user-bar .name {
        float: none !important;
        flex: 1 1 auto;
        width: auto;
        min-width: 0;
        margin: 0 !important;
        font-size: 16px;
        font-weight: 600;
        line-height: 1.35;
    }

    .lw-chat-header-name {
        display: block;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .lw-whatsapp-chat-window .user-bar .name small,
    .lw-chat-header-phone {
        display: inline-block;
        font-size: 12px;
        font-weight: 400;
        opacity: 0.78;
        color: inherit;
    }

    .lw-whatsapp-chat-window .user-bar .name small a {
        color: inherit;
        text-decoration: none;
    }

    .lw-whatsapp-chat-window .user-bar .status {
        font-size: 12px;
        font-weight: 400;
        margin-top: 2px;
        opacity: 0.95;
    }

    .lw-whatsapp-chat-window .user-bar .actions {
        float: none !important;
        margin: 0 !important;
        display: flex;
        align-items: center;
        gap: 4px;
        margin-inline-start: auto !important;
    }

    html[dir="rtl"] .lw-whatsapp-chat-window .user-bar .actions {
        float: none !important;
        margin: 0 !important;
        margin-inline-start: auto !important;
    }

    .lw-whatsapp-bar-icon-btn {
        width: 36px;
        height: 36px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 50%;
        color: inherit;
    }

    .lw-whatsapp-bar-icon-btn:hover,
    .lw-whatsapp-bar-icon-btn:focus {
        background: rgba(255, 255, 255, 0.12);
        color: inherit;
        text-decoration: none;
    }

    /* Messages */
    .lw-whatsapp-chat-window .conversation .conversation-container {
        height: calc(90vh - 168px);
        padding: 12px 18px 8px;
    }

    .lw-whatsapp-chat-window .message {
        margin: 4px 0 10px;
        padding: 8px 10px 6px;
        max-width: 72%;
        line-height: 1.5;
        font-size: 14.5px;
        box-shadow: 0 1px 1px rgba(17, 27, 33, 0.06);
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .lw-whatsapp-chat-window .lw-template-message,
    .lw-whatsapp-chat-window .lw-whatsapp-preview-message-container,
    .lw-whatsapp-chat-window .lw-whatsapp-preview,
    .lw-whatsapp-chat-window .lw-whatsapp-preview .card {
        max-width: 100%;
    }

    .lw-whatsapp-chat-window .lw-whatsapp-body,
    .lw-whatsapp-chat-window .lw-whatsapp-body-text {
        white-space: pre-line;
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    html[dir="rtl"] body.lw-authenticated-page .lw-whatsapp-chat-window .message {
        line-height: 1.65;
    }

    .lw-whatsapp-chat-window .metadata .time {
        font-size: 11px;
        color: #667781;
    }

    .lw-chat-error {
        display: flex;
        flex-direction: column;
        gap: 4px;
        margin-top: 8px;
        padding: 9px 11px;
        border-radius: 6px;
        background: var(--lw-ui-danger-bg);
        border: 1px solid #f5c2c7;
        border-inline-start-width: 3px;
        border-inline-start-color: var(--lw-ui-danger);
        color: #842029;
        font-size: 13px;
        line-height: 1.45;
    }

    .lw-whatsapp-chat-window .lw-chat-document-message {
        gap: 12px;
        padding: 8px 6px;
    }

    .lw-whatsapp-chat-window .lw-chat-document-message__icon {
        width: 40px;
        height: 40px;
        border-radius: 8px;
    }

    .lw-whatsapp-chat-window .lw-chat-document-message__name {
        font-size: 13px;
        font-weight: 600;
        line-height: 1.35;
    }

    .lw-whatsapp-chat-window .lw-chat-document-message__hint {
        font-size: 12px;
        color: var(--lw-ui-muted);
    }

    .lw-chat-error strong {
        font-size: 13px;
        font-weight: 700;
        color: var(--lw-ui-danger);
    }

    /* Composer */
    .lw-whatsapp-chat-window .conversation-compose.lw-chat-composer {
        height: 56px;
        align-items: center;
        padding: 6px 8px 8px;
        background: #f0f2f5;
        gap: 4px;
    }

    .lw-whatsapp-chat-window .conversation-compose .input-msg,
    .lw-whatsapp-chat-window .conversation-compose .emoji,
    .lw-whatsapp-chat-window .conversation-compose .photo {
        height: 42px;
        border-radius: 21px;
    }

    .lw-whatsapp-chat-window .conversation-compose .input-msg {
        padding: 10px 14px;
        font-size: 15px;
        background: #fff;
    }

    .lw-whatsapp-chat-window .conversation-compose .input-msg:focus {
        box-shadow: 0 0 0 2px rgba(0, 128, 105, 0.18);
    }

    .lw-whatsapp-chat-window .conversation-compose .send .circle {
        width: 44px;
        height: 44px;
        background: var(--lw-ui-green);
    }

    .lw-whatsapp-chat-window .conversation-compose .send:disabled .circle,
    .lw-whatsapp-chat-window .conversation-compose.is-disabled .send .circle {
        opacity: 0.45;
    }

    /* Customer panel */
    .lw-customer-panel {
        padding: 8px 10px 16px;
    }

    .lw-profile-tabs {
        display: flex;
        gap: 0;
        background: #e9edef;
        border-radius: 8px;
        padding: 3px;
        margin-bottom: 12px;
    }

    .lw-profile-tab {
        flex: 1 1 0;
        border: 0;
        background: transparent;
        color: var(--lw-ui-muted);
        font-size: 13px;
        font-weight: 600;
        line-height: 1.4;
        min-height: 34px;
        border-radius: 6px;
        padding: 6px 8px;
        cursor: pointer;
    }

    .lw-profile-tab.is-active {
        background: #fff;
        color: var(--lw-ui-green-dark);
        box-shadow: 0 1px 2px rgba(17, 27, 33, 0.08), inset 0 -2px 0 var(--lw-ui-green);
    }

    .lw-customer-panel .selectize-input {
        min-height: 40px;
        border-radius: var(--lw-ui-radius-sm);
        border-color: var(--lw-ui-border);
        padding: 8px 10px;
        font-size: 14px;
    }

    .lw-customer-panel .btn-sm {
        min-height: 32px;
        padding-inline: 12px;
    }

    .lw-profile-edit {
        display: flex;
        justify-content: flex-end;
        margin-bottom: 10px;
    }

    .lw-profile-section {
        padding: 4px 0 12px;
        border-bottom: 1px solid var(--lw-ui-border);
        margin-bottom: 8px;
    }

    .lw-profile-section:last-of-type {
        border-bottom: 0;
    }

    .lw-profile-section__title {
        font-size: 11px;
        font-weight: 700;
        letter-spacing: 0.06em;
        text-transform: uppercase;
        color: var(--lw-ui-muted);
        margin: 0 0 10px;
        line-height: 1.4;
    }

    .lw-profile-hero {
        display: flex;
        align-items: center;
        gap: 12px;
        margin-bottom: 12px;
    }

    .lw-profile-hero .lw-contact-avatar {
        width: 48px !important;
        height: 48px !important;
        min-width: 48px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: 700;
        border-radius: 50%;
    }

    .lw-profile-value {
        font-size: 13px;
        color: var(--lw-ui-muted);
        line-height: 1.4;
        word-break: break-word;
    }

    .lw-profile-value--strong {
        font-size: 16px;
        font-weight: 700;
        color: var(--lw-ui-text);
        line-height: 1.35;
    }

    .lw-profile-list {
        margin: 0;
    }

    .lw-profile-list dt {
        font-size: 12px;
        font-weight: 500;
        color: var(--lw-ui-muted);
        margin-top: 8px;
        line-height: 1.4;
    }

    .lw-profile-list dd {
        font-size: 14px;
        font-weight: 600;
        color: var(--lw-ui-text);
        margin-bottom: 0;
        line-height: 1.45;
        word-break: break-word;
    }

    .lw-profile-list dd.lw-ltr-data {
        font-weight: 500;
        color: #3b4a54;
        font-size: 13px;
    }

    .lw-profile-empty {
        padding: 12px 0;
        color: var(--lw-ui-muted);
        font-size: 13px;
    }

    .lw-customer-panel fieldset {
        border: 0;
        padding: 8px 4px 12px;
        margin: 0;
        border-top: 1px solid var(--lw-ui-border);
    }

    .lw-customer-panel legend {
        font-size: 11px;
        font-weight: 700;
        letter-spacing: 0.05em;
        text-transform: uppercase;
        color: var(--lw-ui-muted);
        width: auto;
        padding: 0;
        margin-bottom: 8px;
        line-height: 1.4;
    }
}

.lw-chat-empty-pane__icon {
    font-size: 28px;
    color: #c5cdd3;
    margin-bottom: 8px;
    display: block;
}

.lw-chat-empty-pane--compact {
    min-height: 160px;
    padding: 1.25rem 0.75rem;
}

/* ---------- Buttons / inputs (console) ---------- */
body.lw-authenticated-page .btn {
    min-height: 36px;
    border-radius: var(--lw-ui-radius-sm);
    font-weight: 600;
    line-height: 1.3;
}

body.lw-authenticated-page .btn-sm {
    min-height: 32px;
}

body.lw-authenticated-page .btn-primary,
body.lw-authenticated-page .btn-success {
    background-color: var(--lw-ui-green);
    border-color: var(--lw-ui-green);
}

body.lw-authenticated-page .form-control {
    min-height: 40px;
    border-radius: var(--lw-ui-radius-sm);
    border-color: var(--lw-ui-border);
}

body.lw-authenticated-page .card {
    border-color: var(--lw-ui-border);
    border-radius: 10px;
}

body.lw-authenticated-page .card-header h1,
body.lw-authenticated-page .card-header h2,
body.lw-authenticated-page .card-header h3 {
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0;
}

/* ---------- Bottom nav polish only ---------- */
@media (max-width: 767.98px) {
    .lw-mobile-bottom-nav {
        padding-bottom: env(safe-area-inset-bottom, 0px);
    }

    .lw-mobile-bottom-nav__item {
        min-height: 44px;
        font-size: 11px;
        font-weight: 600;
        line-height: 1.25;
    }

    html[dir="rtl"] .lw-mobile-bottom-nav__item span:not(.lw-mobile-bottom-nav__badge) {
        line-height: 1.4;
    }

    .lw-mobile-bottom-nav__item i {
        font-size: 18px;
        width: 22px;
        text-align: center;
    }

    .lw-mobile-bottom-nav__item.is-active {
        color: var(--lw-ui-green) !important;
        background: var(--lw-ui-green-soft);
    }

    html[dir="rtl"] .lw-mobile-bottom-nav__badge {
        right: auto;
        left: calc(50% - 16px);
    }

    .lw-chat-list-toolbar {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
        padding: 8px 12px 4px;
    }

    .lw-chat-list-title {
        font-size: 1.05rem;
        font-weight: 700;
        margin: 0;
    }

    .lw-chat-filters-wrap {
        overflow: hidden;
        padding: 0 8px 6px;
    }

    .lw-chat-filters {
        display: flex;
        gap: 4px;
        overflow-x: auto;
        white-space: nowrap;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    .lw-chat-filters .nav-link {
        flex: 0 0 auto;
        white-space: nowrap;
        border-radius: 999px;
        padding: 6px 10px;
        font-size: 13px;
        font-weight: 600;
        min-height: 36px;
        display: inline-flex;
        align-items: center;
    }

    .lw-chat-search {
        position: relative;
        padding: 4px 12px 10px;
    }

    .lw-chat-search > i {
        position: absolute;
        inset-inline-start: 24px;
        top: 50%;
        transform: translateY(-40%);
        color: var(--lw-ui-muted);
        pointer-events: none;
    }

    .lw-chat-search .form-control {
        height: 40px;
        padding-inline-start: 2.1rem;
        border-radius: 20px;
    }

    .lw-profile-tabs {
        display: flex;
        background: #e9edef;
        border-radius: 8px;
        padding: 3px;
        margin-bottom: 10px;
    }

    .lw-profile-tab {
        flex: 1 1 0;
        border: 0;
        background: transparent;
        min-height: 44px;
        border-radius: 6px;
        font-weight: 600;
        font-size: 13px;
    }

    .lw-profile-tab.is-active {
        background: #fff;
        color: var(--lw-ui-green-dark);
    }

    .lw-chat-error {
        display: flex;
        flex-direction: column;
        gap: 2px;
        margin-top: 8px;
        padding: 8px 10px;
        border-radius: 6px;
        background: var(--lw-ui-danger-bg);
        border: 1px solid #f5c2c7;
        color: #842029;
        font-size: 13px;
    }

    .lw-chat-error strong {
        color: var(--lw-ui-danger);
    }

    .lw-profile-list dt {
        font-size: 12px;
        color: var(--lw-ui-muted);
        font-weight: 500;
        margin-top: 8px;
    }

    .lw-profile-list dd {
        font-size: 14px;
        font-weight: 600;
        margin-bottom: 0;
    }

    .lw-profile-hero {
        display: flex;
        align-items: center;
        gap: 12px;
        margin-bottom: 10px;
    }

    .lw-contact-preview,
    .lw-contact-preview-text {
        font-size: 13px;
        color: var(--lw-ui-muted);
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        margin: 0;
        max-width: 100%;
        display: block;
    }
}

/* Data tables: pagination above and below the table */
.dataTables_wrapper .dt-pagination-row {
    align-items: center;
    margin-left: 0;
    margin-right: 0;
}
.dataTables_wrapper .dt-pagination-top {
    margin-bottom: 0.75rem;
}
.dataTables_wrapper .dt-pagination-bottom {
    margin-top: 0.75rem;
}
.dataTables_wrapper .dt-pagination-row .dataTables_info {
    padding-top: 0.55em;
}
.dataTables_wrapper .dt-pagination-row .dataTables_paginate {
    text-align: end;
}

/* Data tables: keep operator density on desktop, readable rows on mobile */
@media (max-width: 767.98px) {
    table.dataTable tbody td,
    table.dataTable tbody th {
        padding: 10px 8px;
        font-size: 13px;
        line-height: 1.45;
        vertical-align: middle;
    }

    .dataTables_wrapper .dataTables_paginate .paginate_button {
        min-height: 36px;
    }
}

/* ---------- Dashboard stats cards (visual only) ---------- */
@media (min-width: 768px) {
    body.lw-authenticated-page .header.pt-md-7 {
        padding-top: 1.25rem !important;
        padding-bottom: 1.25rem !important;
    }

    body.lw-authenticated-page .header .header-body {
        padding-top: 0.25rem;
        padding-bottom: 0.5rem;
    }

    body.lw-authenticated-page .header .card.card-stats {
        height: 100%;
        min-height: 0;
        overflow: visible;
        border: 1px solid var(--lw-ui-border);
        box-shadow: none;
        border-radius: 10px;
    }

    body.lw-authenticated-page .header .card.card-stats .card-body {
        padding: 1.15rem 1.35rem 1.05rem;
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 0.7rem;
        min-height: 108px;
        overflow: visible;
    }

    body.lw-authenticated-page .header .card.card-stats .card-body > .row {
        flex: 0 0 auto;
        align-items: center;
        width: 100%;
        margin-left: 0;
        margin-right: 0;
    }

    body.lw-authenticated-page .header .card.card-stats .card-body > .row > [class*="col"] {
        padding-left: 0;
        padding-right: 0;
    }

    body.lw-authenticated-page .header .card.card-stats .card-title {
        font-size: 12px;
        font-weight: 700;
        letter-spacing: 0.04em;
        line-height: 1.35;
        margin: 0 0 0.4rem;
        padding-top: 0.12em;
    }

    body.lw-authenticated-page .header .card.card-stats .h2 {
        display: block;
        font-size: 1.45rem;
        line-height: 1.2;
        margin: 0;
        padding-top: 0.08em;
    }

    body.lw-authenticated-page .header .card.card-stats .icon-shape {
        width: 2.75rem;
        height: 2.75rem;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: none;
        flex-shrink: 0;
    }

    body.lw-authenticated-page .header .card.card-stats .text-sm {
        margin-top: 0 !important;
        line-height: 1.4;
    }

    body.lw-authenticated-page #navbar-main {
        min-height: 48px;
        padding-top: 0.35rem;
        padding-bottom: 0.35rem;
        align-items: center;
    }

    body.lw-authenticated-page #navbar-main .h4 {
        font-size: 0.9rem;
        font-weight: 600;
        letter-spacing: 0.04em;
        line-height: 1.2;
        margin: 0;
        padding-top: 0.08em;
    }

    body.lw-authenticated-page #navbar-main .navbar-nav .nav-link {
        display: flex;
        align-items: center;
        line-height: 1.2;
        padding-top: 0.35rem;
        padding-bottom: 0.35rem;
    }

    body.lw-authenticated-page fieldset legend {
        font-size: 0.8rem;
        font-weight: 700;
        letter-spacing: 0.04em;
        color: var(--lw-ui-muted);
        line-height: 1.4;
    }

    body.lw-authenticated-page fieldset h3 {
        font-size: 0.98rem;
        font-weight: 500;
        line-height: 1.65;
        margin: 0;
    }

    body.lw-authenticated-page fieldset ol {
        margin: 0.5rem 0 0;
        padding-inline-start: 1.35rem;
    }

    body.lw-authenticated-page fieldset ol li {
        margin-bottom: 0.45rem;
    }
}

@media (max-width: 767.98px) {
    body.lw-authenticated-page .header .card.card-stats {
        border: 1px solid var(--lw-ui-border);
        box-shadow: none;
        margin-bottom: 12px;
    }

    body.lw-authenticated-page .header .card.card-stats .card-body {
        padding: 16px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 0.65rem;
    }

    body.lw-authenticated-page .header .card.card-stats .card-body > .row {
        flex: 0 0 auto;
        align-items: center;
    }
}

/* SAFE DESKTOP LAYOUT FIX — 2026-09-01
   Mini-sidebar is position:fixed. Its inner .container-fluid is sized for the
   hover-expanded rail, so without overflow clipping it paints over the
   conversation list. Main content must reserve the collapsed rail width
   (margin-left, not 100vw). Chat columns need min-width:0 so they fit the
   remaining space instead of overflowing under the sidebar. */
@media (min-width: 768px) {
    body.lw-minimized-menu .navbar-vertical.navbar-expand-md {
        width: var(--lw-ui-sidebar-collapsed);
        max-width: var(--lw-ui-sidebar-expanded);
        overflow-x: hidden;
        overflow-y: auto;
        box-sizing: border-box;
        padding-inline: 0;
    }

    body.lw-minimized-menu .navbar-vertical.navbar-expand-md > .container-fluid {
        width: calc(var(--lw-ui-sidebar-expanded) - 16px);
        box-sizing: border-box;
    }

    body.lw-minimized-menu .navbar-vertical.navbar-expand-md:hover,
    body.lw-minimized-menu .navbar-vertical.navbar-expand-md:focus-within {
        width: var(--lw-ui-sidebar-expanded);
        overflow-x: hidden;
    }

    body.lw-minimized-menu .navbar-vertical.navbar-expand-md.fixed-left + .main-content {
        margin-left: var(--lw-ui-sidebar-collapsed);
        width: auto;
        max-width: none;
        min-width: 0;
        box-sizing: border-box;
    }

    body.lw-minimized-menu .navbar-vertical.navbar-expand-md.fixed-left + .main-content > .navbar-top,
    body.lw-minimized-menu .main-content .navbar-top {
        left: 0;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    body.lw-whatsapp-chat-page.lw-minimized-menu .main-content {
        min-width: 0;
        max-width: 100%;
    }

    body.lw-whatsapp-chat-page .card.lw-whatsapp-chat-block-container {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    body.lw-whatsapp-chat-page .lw-whatsapp-chat-window,
    body.lw-whatsapp-chat-page .lw-whatsapp-chat-window > .row {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    body.lw-whatsapp-chat-page .lw-whatsapp-chat-window > .row > [class*="col-"] {
        min-width: 0;
        box-sizing: border-box;
    }

    body.lw-whatsapp-chat-page .lw-contact-list-block,
    body.lw-whatsapp-chat-page .lw-contact-crm-block,
    body.lw-whatsapp-chat-page .lw-whatsapp-chat-window .page.col-md-6 {
        min-width: 0;
    }
}

/* SAFE RTL SIDEBAR POSITION — 2026-09-01
   Argon pins .navbar-vertical.fixed-left at left:0 and reserves space with
   margin-left on the adjacent .main-content. English/LTR keeps that.
   Arabic uses html[dir="rtl"] only: same mini-sidebar, anchored to the
   right edge, with margin-right instead of margin-left. Hover still grows
   width; with right:0 it expands toward the workspace, not the left. */
@media (min-width: 768px) {
    html[dir="rtl"] body.lw-minimized-menu .navbar-vertical.navbar-expand-md.fixed-left {
        left: auto;
        right: 0;
        border-width: 0 0 0 1px;
    }

    html[dir="rtl"] body.lw-minimized-menu .navbar-vertical.navbar-expand-md.fixed-left + .main-content {
        margin-left: 0;
        margin-right: var(--lw-ui-sidebar-collapsed);
        width: auto;
        max-width: none;
        min-width: 0;
        box-sizing: border-box;
    }

    html[dir="rtl"] body.lw-minimized-menu .navbar-vertical.navbar-expand-md.fixed-left + .main-content > .navbar-top,
    html[dir="rtl"] body.lw-minimized-menu .main-content .navbar-top {
        left: 0;
        right: auto;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    html[dir="rtl"] body.lw-whatsapp-chat-page.lw-minimized-menu .main-content {
        min-width: 0;
        max-width: 100%;
    }
}

/* SAFE DESKTOP COMPOSER FIX — 2026-09-01
   whatsapp-chat.css paints every .conversation-compose > div as a full-height
   white slab and sizes .emojionearea to width:300px with extra margins.
   That white box sits over the rounded input. Desktop only; mobile composer
   stays in whatsapp-chat-mobile.css. */
@media (min-width: 768px) {
    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 6px;
        height: 56px;
        padding: 7px 8px;
        background: #f0f2f5;
        box-sizing: border-box;
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer > div,
    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer > .emojionearea {
        background: transparent;
        height: auto;
        box-shadow: none;
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer > .emoji {
        display: none;
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer > .emojionearea,
    body.lw-whatsapp-chat-page .lw-whatsapp-chat-window .conversation-compose .emojionearea {
        flex: 1 1 auto;
        min-width: 0;
        width: auto !important;
        max-width: none;
        margin: 0 !important;
        height: 42px;
        border: 0;
        border-radius: 21px;
        background: #fff;
        box-shadow: none;
        position: relative;
        overflow: hidden;
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer .emojionearea.focused {
        box-shadow: 0 0 0 2px rgba(0, 128, 105, 0.18);
        border: 0;
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer .emojionearea .emojionearea-editor,
    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer .emojionearea.emojionearea-inline > .emojionearea-editor {
        display: block !important;
        position: absolute !important;
        top: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 42px !important;
        min-height: 0 !important;
        max-height: 42px !important;
        margin: 0 !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        padding-inline-start: 42px !important;
        padding-inline-end: 14px !important;
        line-height: 42px !important;
        font-size: 15px !important;
        overflow: hidden !important;
        white-space: nowrap !important;
        background: transparent !important;
        box-sizing: border-box !important;
        color: var(--lw-ui-text);
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer .emojionearea .emojionearea-editor:empty:before {
        content: attr(placeholder);
        display: inline !important;
        line-height: 42px !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
        vertical-align: baseline !important;
        position: static !important;
        color: var(--lw-ui-muted);
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer .emojionearea .emojionearea-button,
    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer .emojionearea.emojionearea-inline > .emojionearea-button {
        position: absolute;
        inset-inline-start: 10px;
        inset-inline-end: auto;
        left: auto;
        right: auto;
        top: 9px;
        transform: none;
        width: 24px;
        height: 24px;
        z-index: 2;
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer .photo {
        background: transparent;
        height: 42px;
        width: 42px;
        border-radius: 0;
        flex: 0 0 auto;
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer .photo:after {
        content: none;
        display: none;
    }

    body.lw-whatsapp-chat-page .conversation-compose.lw-chat-composer .send {
        background: transparent;
        height: auto;
        margin-inline: 2px;
        flex: 0 0 auto;
    }
}

/* ---------- Team notices ---------- */
.lw-team-notice-card {
    border: 1px solid var(--lw-ui-border);
    border-radius: 16px;
    overflow: hidden;
}

.lw-team-notice-card__header {
    background: #fbfcfd;
    border-bottom: 1px solid var(--lw-ui-border);
    padding: 1.15rem 1.35rem;
}

.lw-team-notice-card__header h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--lw-ui-text);
}

.lw-team-notice-mode {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.lw-team-notice-mode__option {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin: 0;
    padding: 14px;
    border: 1px solid var(--lw-ui-border);
    border-radius: 12px;
    cursor: pointer;
    background: #fff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.lw-team-notice-mode__option.is-active {
    border-color: var(--lw-ui-green);
    box-shadow: 0 0 0 3px var(--lw-ui-green-soft);
}

.lw-team-notice-mode__option input {
    margin-top: 4px;
}

.lw-team-notice-mode__option strong {
    display: block;
    color: var(--lw-ui-text);
}

.lw-team-notice-mode__option small {
    display: block;
    color: var(--lw-ui-muted);
    line-height: 1.45;
}

.lw-team-notice-people,
.lw-team-notice-library-pick,
.lw-team-notice-library-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 10px;
}

.lw-team-notice-person,
.lw-team-notice-library-item {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin: 0;
    padding: 12px;
    border: 1px solid var(--lw-ui-border);
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
}

.lw-team-notice-person:has(input:checked),
.lw-team-notice-library-item:has(input:checked) {
    border-color: var(--lw-ui-green);
    background: var(--lw-ui-green-soft);
}

.lw-team-notice-person strong,
.lw-team-notice-library-item strong,
.lw-team-notice-library-card h4 {
    display: block;
    font-size: 0.92rem;
    margin-bottom: 2px;
}

.lw-team-notice-person small,
.lw-team-notice-library-card p {
    display: block;
    color: var(--lw-ui-muted);
    margin: 0;
    line-height: 1.45;
}

.lw-team-notice-library-card {
    border: 1px solid var(--lw-ui-border);
    border-radius: 12px;
    padding: 14px;
    background: #fff;
}

.lw-team-notice-rotate-list {
    display: grid;
    gap: 12px;
}

.lw-team-notice-rotate-item {
    border: 1px solid var(--lw-ui-border);
    border-radius: 12px;
    padding: 14px;
    background: #fbfcfd;
}

.lw-team-notice-severity {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.lw-team-notice-severity.is-info {
    background: #e8f4ff;
    color: #0b63c7;
}

.lw-team-notice-severity.is-warning {
    background: #fff6e5;
    color: #b45309;
}

.lw-team-notice-severity.is-urgent {
    background: #feecec;
    color: #c81e1e;
}

.lw-team-notice-preview-body {
    min-height: 260px;
    background:
        radial-gradient(ellipse at 80% 20%, rgba(255, 192, 203, 0.28), transparent 55%),
        linear-gradient(165deg, #faf0f4 0%, #f3e4eb 100%);
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 28px 22px;
}

.lw-team-notice-stack {
    position: fixed;
    right: 16px;
    left: auto;
    bottom: 20px;
    z-index: 2200;
    display: flex;
    flex-direction: column-reverse;
    gap: 10px;
    width: min(340px, calc(100vw - 24px));
    pointer-events: none;
}

.lw-notice-msg {
    pointer-events: auto;
    position: relative;
    width: 100%;
    background: #fce4ec;
    border: 1px solid rgba(233, 30, 140, 0.22);
    border-radius: 18px;
    padding: 18px 38px 16px 18px;
    box-shadow: 0 12px 32px rgba(176, 125, 143, 0.18);
    transform: translateY(12px);
    opacity: 0;
    transition: transform 0.22s ease, opacity 0.22s ease;
}

.lw-notice-msg.is-in,
.lw-notice-msg.is-preview {
    transform: translateY(0);
    opacity: 1;
}

.lw-notice-msg.is-leaving {
    transform: translateY(8px);
    opacity: 0;
}

.lw-notice-msg.is-preview {
    max-width: 340px;
}

.lw-notice-msg.is-info {
    border-color: rgba(233, 30, 140, 0.28);
    background: #fce4ec;
}

.lw-notice-msg.is-warning {
    border-color: rgba(233, 30, 140, 0.28);
    background: #fce4ec;
}

.lw-notice-msg.is-urgent {
    border-color: rgba(194, 24, 91, 0.35);
    background: #f8bbd0;
}

.lw-notice-msg__close {
    position: absolute;
    top: 8px;
    right: 8px;
    left: auto;
    width: 26px;
    height: 26px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #c2185b;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
}

.lw-notice-msg__close:hover,
.lw-notice-msg__close:focus {
    background: rgba(194, 24, 91, 0.12);
    color: #880e4f;
}

html[dir="rtl"] .lw-notice-msg {
    padding: 18px 18px 16px 38px;
}

html[dir="rtl"] .lw-notice-msg__close {
    right: auto;
    left: 8px;
}

.lw-notice-msg__content {
    direction: rtl;
    text-align: right;
}

html[dir="ltr"] .lw-notice-msg__content {
    direction: ltr;
    text-align: left;
}

.lw-notice-msg__title,
.lw-notice-msg__body {
    font-family: inherit, "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
}

.lw-notice-msg__title {
    margin: 0 0 8px;
    font-size: 16px;
    font-weight: 700;
    color: #880e4f;
    line-height: 1.45;
}

.lw-notice-msg__body {
    margin: 0;
    color: #ad1457;
    font-size: 14px;
    line-height: 1.75;
    white-space: pre-wrap;
    word-break: break-word;
    max-height: 9em;
    overflow: auto;
}

.lw-notice-compose {
    font-family: inherit, "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
    font-size: 15px;
    line-height: 1.6;
}

.lw-notice-emoji-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    padding: 8px 10px;
    border-radius: 12px;
    background: #fdf5f8;
    border: 1px solid rgba(228, 180, 195, 0.45);
}

.lw-notice-emoji-bar__label {
    font-size: 11px;
    font-weight: 600;
    color: #b07d8f;
    margin-inline-end: 4px;
}

.lw-notice-emoji-bar__btn {
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 8px;
    background: #fff;
    font-size: 17px;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.12s ease, background 0.12s ease;
}

.lw-notice-emoji-bar__btn:hover,
.lw-notice-emoji-bar__btn:focus {
    background: #fce8ef;
    transform: scale(1.08);
}

@media (max-width: 767.98px) {
    .lw-team-notice-mode {
        grid-template-columns: 1fr;
    }

    .lw-team-notice-stack {
        right: 10px;
        left: auto;
        bottom: calc(72px + env(safe-area-inset-bottom, 0px));
        width: calc(100vw - 20px);
    }
}

/* Keep page chrome from sliding off the top on short / zoomed screens.
   Do not lock overflow or rewrite chat flex — that collapsed lists, composer, and other pages. */
@media (min-width: 768px) {
    html > body.lw-authenticated-page {
        overflow-x: clip;
    }

    body.lw-whatsapp-chat-page .main-content > .navbar-top {
        position: sticky !important;
        top: 0 !important;
        left: auto !important;
        width: 100%;
        z-index: 20;
        height: auto;
    }

    body.lw-whatsapp-chat-page .lw-whatsapp-chat-window > .row {
        min-height: calc(100dvh - 200px);
    }

    body.lw-whatsapp-chat-page:has(.lw-impersonation-banner) .lw-whatsapp-chat-window > .row {
        min-height: calc(100dvh - 250px);
    }

    body.lw-whatsapp-chat-page:has(.lw-impersonation-banner) .lw-whatsapp-chat-window .lw-contact-list {
        height: calc(90dvh - 250px);
    }

    body.lw-whatsapp-chat-page:has(.lw-impersonation-banner) .lw-whatsapp-chat-window .conversation .conversation-container {
        height: calc(90dvh - 210px);
    }

    body.lw-whatsapp-chat-page .lw-whatsapp-chat-window .user-bar .lw-chat-status-desktop {
        display: block !important;
    }
}

