body.nf-body {
    padding-top: 64px !important;
    font-family:
        Poppins,
        Tajawal,
        -apple-system,
        BlinkMacSystemFont,
        Segoe UI,
        Roboto,
        sans-serif !important;
    background-color: #f1f5f9 !important;
    color: #1e293b !important;
    font-size: 14px;
    line-height: 1.6;
}
[dir="rtl"] body.nf-body,
body.nf-body[dir="rtl"] {
    font-family:
        Tajawal,
        -apple-system,
        BlinkMacSystemFont,
        Segoe UI,
        sans-serif !important;
}
.nf-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: 64px;
    background: linear-gradient(135deg, #4361ee, #6930c3);
    box-shadow: 0 2px 20px #4361ee59;
    display: flex;
    align-items: center;
}
.nf-header > .container,
.nf-header > .container-fluid {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    padding-left: 20px;
    padding-right: 20px;
    max-width: 100% !important;
}
.nf-logo {
    height: 64px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.nf-logo a {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}
.nf-logo img {
    max-height: 36px;
    width: auto;
    filter: brightness(0) invert(1);
}
.nf-logo-text {
    color: #fff !important;
    font-size: 22px !important;
    font-weight: 700 !important;
    letter-spacing: -0.3px;
    text-decoration: none !important;
}
.nf-logo-text:hover {
    opacity: 0.9;
}
.nf-nav-links {
    display: flex;
    align-items: center;
    gap: 4px;
    list-style: none;
    margin: 0;
    padding: 0;
}
.nf-nav-links a {
    color: #ffffffeb !important;
    text-decoration: none;
    padding: 8px 14px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    transition:
        background 0.2s ease,
        transform 0.15s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    height: 40px;
    background: #ffffff14;
    margin-top: 0;
}
.nf-nav-links a:hover {
    background: #fff3 !important;
    transform: translateY(-1px);
    color: #fff !important;
}
.nf-nav-links a i {
    font-size: 13px;
    opacity: 0.85;
}
.nf-user {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.nf-user-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #fff3;
    border: 2px solid rgba(255, 255, 255, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    text-decoration: none;
    line-height: 1;
    transition: background 0.2s;
}
.nf-user-avatar:hover {
    background: #ffffff4d;
    color: #fff;
}
.nf-user-name {
    color: #ffffffeb !important;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none !important;
}
.nf-user-name:hover {
    color: #fff !important;
}
.nf-logout-form {
    display: inline;
}
.nf-logout-btn {
    color: #fffc;
    font-size: 13px;
    padding: 6px 14px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    height: 34px;
}
.nf-logout-btn:hover {
    background: #ffffff26 !important;
    color: #fff;
    border-color: #fff6;
}
@media (max-width: 767px) {
    .nf-header {
        height: 56px;
    }
    .nf-header > .container,
    .nf-header > .container-fluid {
        height: 56px;
    }
    .nf-nav-links {
        display: none;
    }
    .nf-logo-text {
        font-size: 18px !important;
    }
    .nf-logo img {
        max-height: 28px;
    }
}
@media (max-width: 991px) {
    .nf-nav-links {
        display: none;
    }
}
.hero-section > .container,
.how-it-works-section > .container,
.featured-campaigns-section > .container,
.commission-types-section > .container,
.categories-section > .container,
.advertisers-section > .container,
.platform-stats-section > .container,
.cta-section > .container,
.main-footer > .container {
    padding-left: 15px;
    padding-right: 15px;
}
.pub-header {
    position: fixed;
    top: 0;
    inset-inline-start: 0;
    inset-inline-end: 0;
    z-index: 1040;
    height: 64px;
    background: var(
        --auth-home-header-background,
        linear-gradient(135deg, #4361ee 0%, #6930c3 100%)
    );
    box-shadow: 0 2px 20px
        var(--auth-home-header-shadow, rgba(67, 97, 238, 0.35));
    display: flex;
    align-items: center;
}
.pub-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    width: 100%;
    gap: 12px;
}
.pub-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.pub-hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 25px;
    height: 36px;
    padding: 6px 5px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: background 0.2s;
    flex-shrink: 0;
    background-color: #ff000000;
}
.pub-hamburger:hover {
    background: var(--auth-home-header-surface-hover, rgba(255, 255, 255, 0.2));
}
.pub-hamburger-line {
    display: block;
    width: 100%;
    height: 2px;
    border-radius: 2px;
    background: var(--auth-home-header-text, rgba(255, 255, 255, 0.9));
    transition:
        transform 0.2s,
        opacity 0.2s;
}
.pub-logo-link {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none !important;
    flex-shrink: 0;
}
.pub-logo-img {
    max-height: 36px;
    width: auto;
}
.pub-logo-text {
    color: var(--auth-home-header-logo-text, #fff) !important;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.3px;
}
.pub-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    justify-content: center;
}
.pub-nav-link {
    color: var(--auth-home-header-text, rgba(255, 255, 255, 0.9)) !important;
    text-decoration: none !important;
    padding: 7px 14px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    transition:
        background 0.2s,
        transform 0.15s;
    display: flex;
    align-items: center;
    gap: 6px;
    height: 38px;
    white-space: nowrap;
}
.pub-nav-link:hover,
.pub-nav-link.active {
    background: var(
        --auth-home-header-surface-hover,
        rgba(255, 255, 255, 0.2)
    ) !important;
    color: var(--auth-home-header-text, #fff) !important;
    transform: translateY(-1px);
}
.pub-nav-link i {
    font-size: 12px;
    opacity: 0.85;
}
.pub-header-right {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}
.pub-balance-chip {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #ffffff26;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 20px;
    padding: 4px 12px 4px 9px;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    cursor: default;
    transition: background 0.2s;
    white-space: nowrap;
}
.pub-balance-chip:hover {
    background: #ffffff38;
}
.pub-balance-icon {
    font-size: 12px;
    opacity: 0.9;
}
.pub-balance-value {
    font-weight: 700;
    line-height: 1;
}
.pub-action-item {
    position: relative;
    display: flex;
    align-items: center;
}
.pub-header-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: transparent;
    border: none;
    color: var(--auth-home-header-text, rgba(255, 255, 255, 0.9));
    font-size: 1rem;
    text-decoration: none !important;
    transition: background 0.2s;
    position: relative;
}
.pub-header-icon-btn:hover {
    background: var(--auth-home-header-surface-hover, rgba(255, 255, 255, 0.2));
    color: var(--auth-home-header-text, #fff);
}
.pub-badge {
    position: absolute;
    top: -3px;
    inset-inline-end: -3px;
    min-width: 16px;
    height: 16px;
    background: #ef4444;
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    border: 1.5px solid rgba(255, 255, 255, 0.8);
    line-height: 1;
    pointer-events: none;
}
.pub-sidebar-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    background: #ef4444;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    border-radius: 9999px;
    padding: 0 5px;
    margin-inline-start: auto;
    line-height: 1;
}
.pub-header .topbar-icon-btn {
    color: var(--auth-home-header-text, rgba(255, 255, 255, 0.9)) !important;
    background: #fff0 !important;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition:
        background 0.2s,
        color 0.2s;
    text-decoration: none;
    border: none;
    cursor: pointer;
    padding: 0;
}
.pub-header .topbar-icon-btn:hover {
    background: var(
        --auth-home-header-surface-hover,
        rgba(255, 255, 255, 0.2)
    ) !important;
    color: var(--auth-home-header-text, #fff) !important;
}
.pub-header .topbar-icon-btn .absolute {
    position: absolute;
}
.pub-user-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    background: #ffffff1a;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 22px;
    padding: 3px 10px;
    cursor: pointer;
    transition: background 0.2s;
    color: #fffffff2 !important;
    font-size: 13px;
    font-weight: 600;
    max-width: 180px;
}
.pub-user-btn:hover {
    background: #ffffff38;
    border-color: #ffffff59;
}
.pub-user-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #ffffff40;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    line-height: 1;
    text-transform: uppercase;
    flex-shrink: 0;
}
.pub-user-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100px;
}
.pub-user-caret {
    font-size: 10px;
    opacity: 0.75;
}
.pub-user-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    inset-inline-end: 0;
    width: 220px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 30px #00000026;
    border: 1px solid rgba(0, 0, 0, 0.06);
    padding: 6px 0;
    z-index: 1050;
    overflow: hidden;
}
.pub-dropdown-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
}
.pub-dropdown-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4361ee, #6930c3);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    text-transform: uppercase;
}
.pub-dropdown-info {
    min-width: 0;
}
.pub-dropdown-name {
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0;
}
.pub-dropdown-email {
    font-size: 11px;
    color: #64748b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 2px 0 0;
}
.pub-dropdown-divider {
    height: 1px;
    background: #f1f5f9;
    margin: 4px 0;
}
.pub-dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 16px;
    font-size: 13px;
    color: #374151 !important;
    text-decoration: none !important;
    transition: background 0.15s;
    cursor: pointer;
}
.pub-dropdown-item:hover {
    background: #f8fafc !important;
    color: #1e293b !important;
}
.pub-dropdown-item i {
    width: 16px;
    text-align: center;
    color: #6b7280;
    font-size: 13px;
    flex-shrink: 0;
}
.pub-dropdown-item--admin i {
    color: #f97316;
}
.pub-dropdown-item--admin:hover {
    background: #fff7ed !important;
}
.pub-dropdown-item--danger {
    color: #ef4444 !important;
}
.pub-dropdown-item--danger i {
    color: #ef4444;
}
.pub-dropdown-item--danger:hover {
    background: #fef2f2 !important;
    color: #dc2626 !important;
}
.pub-btn-ghost {
    color: #323232e6 !important;
    text-decoration: none !important;
    padding: 7px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: background 0.2s;
    white-space: nowrap;
}
.pub-btn-ghost:hover {
    color: #2e2e2e !important;
}
.pub-btn-solid {
    color: #4361ee !important;
    text-decoration: none !important;
    padding: 7px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    background: #fff;
    border: none;
    transition: opacity 0.2s;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
}
.pub-btn-solid:hover {
    opacity: 0.9;
}
.pub-sidebar-offcanvas {
    width: 280px !important;
    background: linear-gradient(180deg, #1e0a4f, #2d1566);
    border-inline-end: none !important;
}
.pub-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.pub-sidebar-logo-link {
    text-decoration: none !important;
}
.pub-sidebar-logo-img {
    max-height: 32px;
    width: auto;
    filter: brightness(0) invert(1);
}
.pub-sidebar-logo-text {
    color: #fff;
    font-size: 18px;
    font-weight: 700;
}
.pub-sidebar-close {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: none;
    background: #ffffff1a;
    color: #fffc;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}
.pub-sidebar-close:hover {
    background: #fff3;
    color: #fff;
}
.pub-sidebar-user {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.pub-sidebar-user-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #fff3;
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: #fff;
    font-size: 17px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
    flex-shrink: 0;
}
.pub-sidebar-user-info {
    min-width: 0;
}
.pub-sidebar-user-name {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0;
}
.pub-sidebar-user-email {
    font-size: 11px;
    color: #ffffff8c;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 2px 0 0;
}
.pub-sidebar-balance {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px 8px;
    font-size: 13px;
    color: #ffffffb3;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.pub-sidebar-balance i {
    color: #4ade80;
    font-size: 14px;
}
.pub-sidebar-balance strong {
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    margin-inline-start: auto;
}
.pub-sidebar-body {
    padding: 8px 0 24px !important;
    background: transparent;
}
.pub-sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 0 10px;
}
.pub-sidebar-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    color: #fffc !important;
    text-decoration: none !important;
    transition:
        background 0.2s,
        color 0.2s;
    cursor: pointer;
}
.pub-sidebar-link:hover,
.pub-sidebar-link.active {
    background: #ffffff1f;
    color: #fff !important;
}
.pub-sidebar-link i {
    width: 18px;
    text-align: center;
    font-size: 14px;
    opacity: 0.75;
    flex-shrink: 0;
}
.pub-sidebar-link.active i {
    opacity: 1;
}
.pub-sidebar-link--admin i {
    color: #fbbf24;
    opacity: 1;
}
.pub-sidebar-link--admin {
    color: #fbbf24 !important;
}
.pub-sidebar-link--danger {
    color: #f87171 !important;
}
.pub-sidebar-link--danger:hover {
    background: #f871711a !important;
}
.pub-sidebar-link--danger i {
    opacity: 1;
}
.pub-sidebar-divider {
    height: 1px;
    background: #ffffff14;
    margin: 6px 0;
}
@media (max-width: 576px) {
    .pub-header,
    .pub-header-inner {
        height: 56px;
    }
    body.nf-body {
        padding-top: 56px !important;
    }
    .pub-balance-chip {
        display: none;
    }
    .pub-logo-text {
        font-size: 17px;
    }
}
@media (min-width: 577px) and (max-width: 991px) {
    .pub-header,
    .pub-header-inner {
        height: 60px;
    }
    body.nf-body {
        padding-top: 60px !important;
    }
}
.pub-chat-widget {
    position: absolute;
    top: calc(100% + 10px);
    inset-inline-end: 0;
    width: 310px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 12px 40px #0000002e;
    border: 1px solid rgba(0, 0, 0, 0.07);
    z-index: 1060;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.pub-chat-widget-head {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: #f8fafc;
    border-bottom: 1px solid #eef2f7;
    min-height: 46px;
}
.pub-chat-widget-title {
    flex: 1;
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pub-chat-back-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: #6b7280;
    width: 26px;
    height: 26px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: background 0.15s;
    flex-shrink: 0;
    padding: 0;
}
.pub-chat-back-btn:hover {
    background: #e2e8f0;
    color: #1e293b;
}
.pub-chat-head-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 12px;
    flex-shrink: 0;
}
.pub-chat-head-actions {
    display: flex;
    align-items: center;
    gap: 2px;
    flex-shrink: 0;
}
.pub-chat-widget-link {
    font-size: 11px;
    color: #4361ee;
    text-decoration: none !important;
    font-weight: 600;
    padding: 3px 6px;
    border-radius: 5px;
    transition: background 0.15s;
    white-space: nowrap;
}
.pub-chat-widget-link:hover {
    background: #eef2ff;
    color: #3451d1 !important;
}
.pub-chat-close-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: #9ca3af;
    width: 24px;
    height: 24px;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition:
        background 0.15s,
        color 0.15s;
    padding: 0;
}
.pub-chat-close-btn:hover {
    background: #fee2e2;
    color: #ef4444;
}
.pub-chat-widget-body {
    max-height: 300px;
    overflow-y: auto;
}
.pub-chat-section-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: transparent;
    border: none;
    border-bottom: 1px solid #f1f5f9;
    width: 100%;
    text-align: start;
    cursor: pointer;
    transition: background 0.15s;
}
.pub-chat-section-item:last-child {
    border-bottom: none;
}
.pub-chat-section-item:hover {
    background: #f8fafc;
}
.pub-chat-section-item:disabled {
    opacity: 0.6;
    cursor: default;
}
.pub-chat-section-item--unread {
    background: #f0f4ff;
}
.pub-chat-section-item--unread:hover {
    background: #e6ecff;
}
.pub-chat-section-badge {
    display: inline-block;
    font-size: 10px;
    font-weight: 600;
    padding: 1px 7px;
    border-radius: 999px;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}
.pub-chat-unread-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4361ee;
    flex-shrink: 0;
    margin-right: 4px;
}
.pub-chat-section-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1rem;
    flex-shrink: 0;
}
.pub-chat-section-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.pub-chat-section-text strong {
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pub-chat-section-text span {
    font-size: 11px;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pub-chat-section-arrow {
    font-size: 10px;
    color: #d1d5db;
    flex-shrink: 0;
}
.pub-chat-widget-footer {
    display: block;
    padding: 10px 14px;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: #4361ee !important;
    text-decoration: none !important;
    border-top: 1px solid #f1f5f9;
    background: #f8fafc;
    transition: background 0.15s;
}
.pub-chat-widget-footer:hover {
    background: #eef2ff;
    color: #3451d1 !important;
}
.pub-chat-messages {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 12px;
    min-height: 200px;
    max-height: 280px;
    overflow-y: auto;
    background: #f8fafc;
}
.pub-chat-bubble {
    max-width: 82%;
    padding: 7px 11px;
    border-radius: 14px;
    font-size: 13px;
    line-height: 1.45;
    word-break: break-word;
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.pub-chat-bubble--mine {
    align-self: flex-end;
    background: #4361ee;
    color: #fff;
    border-bottom-right-radius: 4px;
}
.pub-chat-bubble--their {
    align-self: flex-start;
    background: #fff;
    color: #1e293b;
    border: 1px solid #e2e8f0;
    border-bottom-left-radius: 4px;
}
.pub-chat-bubble-time {
    font-size: 10px;
    opacity: 0.65;
    align-self: flex-end;
}
.pub-chat-loading {
    padding: 32px 16px;
    text-align: center;
    font-size: 13px;
    color: #94a3b8;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}
.pub-chat-empty-state {
    padding: 32px 16px;
    text-align: center;
    color: #94a3b8;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}
.pub-chat-empty-state i {
    font-size: 1.8rem;
    opacity: 0.4;
}
.pub-chat-empty-state p {
    font-size: 13px;
    margin: 0;
}
.pub-chat-input-row {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    padding: 8px 10px;
    border-top: 1px solid #e2e8f0;
    background: #fff;
}
.pub-chat-input {
    flex: 1;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 7px 10px;
    font-size: 13px;
    resize: none;
    color: #1e293b;
    background: #fff;
    transition: border 0.15s;
    outline: none;
    min-height: 36px;
    max-height: 80px;
    font-family: inherit;
}
.pub-chat-input:focus {
    border-color: #4361ee;
}
.pub-chat-send-btn {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: #4361ee;
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    transition: background 0.15s;
    flex-shrink: 0;
}
.pub-chat-send-btn:hover {
    background: #3451d1;
}
.pub-chat-send-btn:disabled {
    opacity: 0.5;
    cursor: default;
}
[dir="rtl"] .pub-chat-section-arrow {
    transform: scaleX(-1);
}
.pub-create-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--pub-accent, #4361ee);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    cursor: pointer;
    transition:
        background 0.15s,
        transform 0.15s;
}
.pub-create-btn:hover {
    background: #3451d1;
    transform: rotate(45deg);
}
.auth-home-shell .pub-header {
    background: var(--auth-home-header-background);
    box-shadow: 0 2px 20px var(--auth-home-header-shadow);
}
.auth-home-shell .pub-logo-text {
    color: var(--auth-home-header-logo-text) !important;
}
.auth-home-shell .pub-hamburger,
.auth-home-shell .pub-balance-chip,
.auth-home-shell .pub-user-btn {
    border-color: var(--auth-home-header-border) !important;
    color: var(--auth-home-header-text) !important;
}
.auth-home-shell .pub-header-icon-btn,
.auth-home-shell .pub-header .topbar-icon-btn {
    background: var(
        --auth-home-header-icon-background,
        var(--auth-home-header-surface)
    ) !important;
    border-color: var(--auth-home-header-border) !important;
    color: var(--auth-home-header-text) !important;
}
.auth-home-shell .pub-hamburger:hover,
.auth-home-shell .pub-header-icon-btn:hover,
.auth-home-shell .pub-header .topbar-icon-btn:hover,
.auth-home-shell .pub-balance-chip:hover,
.auth-home-shell .pub-user-btn:hover,
.auth-home-shell .pub-nav-link:hover,
.auth-home-shell .pub-nav-link.active {
    background: var(--auth-home-header-surface-hover) !important;
    color: var(--auth-home-header-text) !important;
}
.auth-home-shell .pub-hamburger-line,
.auth-home-shell .pub-nav-link,
.auth-home-shell .pub-nav-link i,
.auth-home-shell .pub-header-icon-btn,
.auth-home-shell .pub-header .topbar-icon-btn,
.auth-home-shell .pub-balance-chip,
.auth-home-shell .pub-user-btn {
    color: var(--auth-home-header-text) !important;
}
.auth-home-shell .pub-hamburger-line {
    background: var(--auth-home-header-text);
}
.auth-home-shell .pub-badge {
    border-color: var(--auth-home-header-background);
}
.auth-home-shell .pub-create-btn {
    background: var(--auth-home-header-button-background) !important;
    color: var(--auth-home-header-button-text) !important;
}
.auth-home-shell .pub-create-btn:hover {
    background: var(--auth-home-header-button-background) !important;
    color: var(--auth-home-header-button-text) !important;
    filter: brightness(0.92);
}
.auth-home-shell .pub-user-avatar {
    background: var(
        --auth-home-header-avatar-background,
        rgba(255, 255, 255, 0.25)
    ) !important;
}
.auth-home-shell .pub-mob-bottom {
    background: var(--auth-home-mobile-nav-background);
    border-top-color: var(--auth-home-mobile-nav-border);
    box-shadow: 0 -4px 16px var(--auth-home-mobile-nav-shadow);
}
.auth-home-shell .pub-mob-bottom-item,
.auth-home-shell .pub-mob-bottom-add {
    color: var(--auth-home-mobile-nav-text);
}
.auth-home-shell .pub-mob-bottom-glyph {
    color: var(--auth-home-mobile-nav-glyph);
}
.auth-home-shell .pub-mob-bottom-item.active,
.auth-home-shell .pub-mob-bottom-item:hover {
    color: var(--auth-home-mobile-nav-button-background);
}
.auth-home-shell .pub-mob-add-btn {
    background: var(--auth-home-mobile-nav-button-background);
    color: var(--auth-home-mobile-nav-button-text);
    box-shadow: 0 4px 14px var(--auth-home-mobile-nav-button-shadow);
}
.auth-home-shell .pub-mob-add-btn:hover,
.auth-home-shell .pub-mob-add-btn.active {
    box-shadow: 0 6px 18px var(--auth-home-mobile-nav-button-shadow);
}
.pub-create-dropdown {
    position: absolute;
    inset-inline-end: 0;
    top: calc(100% + 10px);
    width: 220px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 8px 24px #0000001f;
    border: 1px solid #e5e7eb;
    z-index: 1060;
    overflow: hidden;
}
[dir="rtl"] .pub-create-dropdown {
    inset-inline-end: auto;
    inset-inline-start: 0;
}
.pub-create-dropdown-header {
    padding: 10px 14px 8px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #9ca3af;
    border-bottom: 1px solid #f1f5f9;
}
.pub-create-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 14px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    text-decoration: none;
    transition: background 0.12s;
}
.pub-create-item:hover {
    background: #f8fafc;
    color: #1e293b;
}
.pub-create-icon {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    flex-shrink: 0;
}
.pub-mob-bottom {
    --mnb-bg: var(--auth-home-mobile-nav-background, rgba(255, 255, 255, 0.96));
    --mnb-border: var(--auth-home-mobile-nav-border, #e5e7eb);
    --mnb-shadow: var(--auth-home-mobile-nav-shadow, rgba(0, 0, 0, 0.07));
    --mnb-text: var(--auth-home-mobile-nav-text, #9ca3af);
    --mnb-text-active: var(--auth-home-mobile-nav-button-background, #4361ee);
    --mnb-label-active: #334155;
    --mnb-glyph: var(--auth-home-mobile-nav-glyph, #94a3b8);
    --mnb-glyph-active: var(--auth-home-mobile-nav-button-background, #4361ee);
    --mnb-glyph-bg: linear-gradient(180deg, #eef2ff, #e0e7ff);
    --mnb-glyph-ring: rgba(99, 102, 241, 0.12);
    --mnb-pill: var(--auth-home-mobile-nav-button-background, #4361ee);
    --mnb-add-bg: var(
        --auth-home-mobile-nav-button-background,
        linear-gradient(135deg, #4361ee, #7c3aed)
    );
    --mnb-add-shadow: var(
        --auth-home-mobile-nav-button-shadow,
        rgba(67, 97, 238, 0.45)
    );
    --mnb-add-shadow-hover: rgba(67, 97, 238, 0.55);
    position: fixed;
    bottom: 0;
    inset-inline: 0;
    height: 60px;
    background: var(--mnb-bg);
    border-top: 1px solid var(--mnb-border);
    box-shadow: 0 -4px 16px var(--mnb-shadow);
    z-index: 1050;
    display: flex;
    align-items: stretch;
}
@media (max-width: 991.98px) {
    body:has(.pub-mob-bottom) {
        padding-bottom: 60px;
    }
}
.pub-mob-bottom-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    font-size: 0.62rem;
    font-weight: 500;
    color: #9ca3af;
    text-decoration: none;
    position: relative;
    transition: color 0.12s;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
}
.pub-mob-bottom-item {
    color: var(--mnb-text);
}
.pub-mob-bottom-item.active,
.pub-mob-bottom-item:hover {
    color: var(--mnb-text-active);
}
.pub-mob-bottom-icon {
    font-size: 1.15rem;
}
.pub-mob-bottom-glyph {
    position: relative;
    width: 38px;
    height: 38px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--mnb-glyph, #94a3b8);
    background: transparent;
    transition:
        background 0.16s,
        color 0.16s,
        transform 0.16s,
        box-shadow 0.16s;
}
.pub-mob-bottom-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4361ee, #7c3aed);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}
.pub-mob-bottom-add {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    font-size: 0.62rem;
    font-weight: 500;
    color: #9ca3af;
    position: relative;
}
.pub-mob-add-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--mnb-add-bg);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: 0 4px 14px var(--mnb-add-shadow);
    transition:
        transform 0.2s,
        box-shadow 0.2s;
    margin-top: -8px;
    cursor: pointer;
}
.pub-mob-add-btn:hover,
.pub-mob-add-btn.active {
    transform: rotate(45deg);
    box-shadow: 0 6px 18px var(--mnb-add-shadow-hover);
}
.pub-mob-create-tray {
    position: fixed;
    bottom: 68px;
    inset-inline: 0;
    margin-inline: auto;
    width: min(340px, 94vw);
    height: fit-content;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 8px 32px #00000024;
    border: 1px solid #e5e7eb;
    padding: 14px;
    z-index: 1060;
}
.pub-mob-create-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}
.pub-mob-create-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    color: #374151;
    font-size: 0.7rem;
    font-weight: 500;
}
.pub-mob-create-item:hover {
    color: #4361ee;
}
.pub-mob-create-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.1rem;
    box-shadow: 0 2px 8px #00000026;
}
.pub-mob-favorites-tray {
    width: min(100vw - 1rem, 28rem);
    height: min(72vh, 38rem);
    max-height: min(72vh, 38rem);
    padding: 0.95rem;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    overflow: hidden;
}
.pub-mob-favorites-search-row {
    display: flex;
    align-items: center;
    gap: 0.55rem;
}
.pub-mob-favorites-title {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 800;
    color: #0f172a;
}
.pub-mob-favorites-subtitle {
    margin: 0.2rem 0 0;
    font-size: 0.74rem;
    color: #64748b;
}
.pub-mob-favorites-close {
    width: 2rem;
    height: 2rem;
    border-radius: 9999px;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #64748b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.pub-mob-favorites-search {
    width: 100%;
    flex: 1 1 auto;
    border: 1px solid #e2e8f0;
    border-radius: 9999px;
    background: #fff;
    padding: 0.78rem 0.95rem;
    font-size: 0.84rem;
    color: #0f172a;
}
.pub-mob-favorites-tabs {
    display: flex;
    gap: 0.5rem;
}
.pub-mob-favorites-tabs-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.pub-mob-favorites-tabs-row .pub-mob-favorites-tabs {
    flex: 1 1 auto;
}
.pub-mob-favorites-tab {
    flex: 1 1 0;
    border: 1px solid #e2e8f0;
    border-radius: 9999px;
    background: #fff;
    color: #475569;
    padding: 0.55rem 0.85rem;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
}
.pub-mob-favorites-tab.is-active {
    background: #0f172a;
    border-color: #0f172a;
    color: #fff;
}
.pub-mob-favorites-sector-toggle {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    min-height: 2.35rem;
    max-width: 9.5rem;
    border: 1px solid #e2e8f0;
    border-radius: 9999px;
    background: #fff;
    color: #475569;
    padding: 0.45rem 0.75rem;
    font-size: 0.74rem;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
}
.pub-mob-favorites-sector-toggle.hidden {
    display: none;
}
.pub-mob-favorites-sector-toggle.is-active {
    border-color: #cbd5e1;
    background: #f8fafc;
    color: #0f172a;
}
.pub-mob-favorites-sector-toggle-label {
    overflow: hidden;
    text-overflow: ellipsis;
}
.pub-mob-favorites-sector-picker {
    flex: 0 0 auto;
    display: flex;
    align-items: stretch;
    gap: 0.45rem;
    overflow-x: auto;
    min-height: 2.4rem;
    padding-top: 0.1rem;
    padding-bottom: 0.2rem;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.pub-mob-favorites-sector-picker::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
}
.pub-mob-favorites-sector-picker.hidden {
    display: none;
}
.pub-mob-favorites-sector-option {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    flex: 0 0 auto;
    border: 1px solid #e2e8f0;
    border-radius: 9999px;
    background: #fff;
    color: #475569;
    min-height: 2.2rem;
    padding: 0.4rem 0.8rem;
    font-size: 0.73rem;
    font-weight: 700;
    cursor: pointer;
}
.pub-mob-favorites-sector-option.is-active {
    border-color: #0f172a;
    background: #0f172a;
    color: #fff;
}
.pub-mob-favorites-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    padding-inline-end: 0.35rem;
    padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
    scroll-padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
}
.pub-mob-favorites-list {
    display: grid;
    gap: 0.65rem;
    padding-bottom: 0.1rem;
}
.pub-mob-favorites-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.75rem;
    align-items: start;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    background: #fff;
    padding: 0.7rem;
}
.pub-mob-favorites-link {
    display: grid;
    grid-template-columns: 3.5rem minmax(0, 1fr) auto;
    gap: 0.75rem;
    align-items: center;
    min-width: 0;
    text-decoration: none;
}
.pub-mob-favorites-thumb {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 0.85rem;
    overflow: hidden;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
}
.pub-mob-favorites-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.pub-mob-favorites-name {
    font-size: 0.84rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.4;
}
.pub-mob-favorites-meta {
    margin-top: 0.2rem;
    font-size: 0.73rem;
    color: #64748b;
    line-height: 1.5;
}
.pub-mob-favorites-price {
    font-size: 0.76rem;
    font-weight: 800;
    color: #0f172a;
    white-space: nowrap;
}
.pub-mob-favorites-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.45rem;
}
.pub-mob-favorites-remove {
    border: 1px solid #e2e8f0;
    border-radius: 9999px;
    background: #fff;
    color: #475569;
    min-width: 2.4rem;
    min-height: 2.4rem;
    padding: 0.45rem 0.7rem;
    font-size: 0.76rem;
    font-weight: 700;
    cursor: pointer;
}
.pub-mob-favorites-remove[disabled] {
    opacity: 0.6;
    cursor: wait;
}
.pub-mob-favorites-confirm {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.65rem;
    border-top: 1px solid #e2e8f0;
    padding-top: 0.7rem;
}
.pub-mob-favorites-confirm.hidden {
    display: none;
}
.pub-mob-favorites-confirm-copy {
    font-size: 0.74rem;
    font-weight: 700;
    color: #334155;
}
.pub-mob-favorites-confirm-actions {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-shrink: 0;
}
.pub-mob-favorites-confirm-btn {
    border: 1px solid #e2e8f0;
    border-radius: 9999px;
    background: #fff;
    color: #475569;
    min-height: 2rem;
    padding: 0.35rem 0.85rem;
    font-size: 0.74rem;
    font-weight: 700;
    cursor: pointer;
}
.pub-mob-favorites-confirm-btn.is-danger {
    border-color: #fecaca;
    background: #fef2f2;
    color: #b91c1c;
}
.pub-mob-favorites-confirm-btn[disabled] {
    opacity: 0.6;
    cursor: wait;
}
@media (prefers-reduced-motion: reduce) {
    .pub-mob-bottom-item,
    .pub-mob-bottom-glyph,
    .pub-mob-bottom-glyph:after,
    .pub-mob-add-btn,
    .pub-mob-sector-item,
    .pub-mob-create-item {
        transition: none !important;
    }
    .pub-mob-add-btn:hover,
    .pub-mob-add-btn.active,
    .pub-mob-sector-item:hover,
    .pub-mob-sector-item.active {
        transform: none;
    }
}
.pub-mob-favorites-state {
    border: 1px dashed #cbd5e1;
    border-radius: 1rem;
    background: #f8fafc;
    color: #64748b;
    text-align: center;
    padding: 1.15rem 0.9rem;
    font-size: 0.8rem;
}
.msgs-wrap {
    height: calc(100vh - 64px);
    overflow: hidden;
}
@media (max-width: 767px) {
    .msgs-wrap {
        height: auto;
        overflow: visible;
    }
}
.msgs-sidebar {
    display: flex;
    flex-direction: column;
    height: 100%;
    border-right: 1px solid #e5e7eb;
    background: #fff;
}
.msgs-sidebar-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid #e5e7eb;
    flex-shrink: 0;
}
.msgs-sidebar-title {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
}
.msgs-sidebar-badge {
    font-size: 10px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 999px;
    background: #ede9fe;
    color: #7c3aed;
}
.msgs-sidebar-body {
    flex: 1;
    overflow-y: auto;
}
.msgs-sidebar-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
    text-decoration: none;
    transition: background 0.12s;
}
.msgs-sidebar-item:hover {
    background: #f8fafc;
}
.msgs-sidebar-item.active {
    background: #eff6ff;
}
.msgs-sidebar-item.unread .msgs-sidebar-name {
    font-weight: 700;
    color: #1e293b;
}
.msgs-sidebar-item.unread .msgs-sidebar-preview {
    color: #374151;
    font-weight: 600;
}
.msgs-sidebar-avatar {
    position: relative;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #4361ee;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.05rem;
}
.msgs-sidebar-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}
.msgs-sidebar-dot {
    position: absolute;
    top: 1px;
    right: 1px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #3b82f6;
    border: 2px solid #fff;
}
.msgs-sidebar-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.msgs-sidebar-name {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.msgs-sidebar-preview {
    font-size: 12px;
    color: #9ca3af;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.msgs-sidebar-time {
    font-size: 11px;
    color: #9ca3af;
    flex-shrink: 0;
    align-self: flex-start;
    margin-top: 2px;
}
.msgs-sidebar-empty {
    text-align: center;
    padding: 48px 16px;
    color: #9ca3af;
    font-size: 13px;
}
.msgs-sidebar-empty i {
    font-size: 2rem;
    display: block;
    margin-bottom: 8px;
}
.msgs-chat-col {
    height: 100%;
    overflow: hidden;
    background: #f8fafc;
}
.msgs-chat-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    flex-shrink: 0;
    min-height: 61px;
}
.msgs-chat-back {
    color: #94a3b8;
    font-size: 15px;
}
.msgs-chat-back:hover {
    color: #4361ee;
}
.msgs-chat-header-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #4361ee;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1rem;
}
.msgs-chat-header-photo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e5e7eb;
    flex-shrink: 0;
}
.msgs-chat-header-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.msgs-chat-header-info strong {
    font-size: 14px;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.msgs-chat-header-info span {
    font-size: 12px;
    color: #94a3b8;
}
.msgs-admin-badge {
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 999px;
    background: #ede9fe;
    color: #7c3aed;
}
.msgs-chat-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-height: 0;
}
.msgs-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.msgs-bubble-row {
    display: flex;
    align-items: flex-end;
    gap: 8px;
}
.msgs-bubble-row--mine {
    flex-direction: row-reverse;
}
.msgs-bubble-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #e5e7eb;
    flex-shrink: 0;
    margin-bottom: 2px;
}
.msgs-bubble {
    max-width: min(320px, 70%);
    padding: 8px 12px;
    border-radius: 16px;
    font-size: 13px;
    line-height: 1.45;
    word-break: break-word;
    white-space: pre-wrap;
}
.msgs-bubble p {
    display: inline;
    margin: 0;
}
.msgs-bubble time {
    display: inline-block;
    font-size: 10px;
    margin-left: 7px;
    opacity: 0.75;
    vertical-align: bottom;
    line-height: 1;
    white-space: nowrap;
}
.msgs-bubble--mine {
    background: #4361ee;
    color: #fff;
    border-bottom-right-radius: 4px;
}
.msgs-bubble--mine time {
    color: #ffffffbf;
}
.msgs-bubble--their {
    background: #f1f5f9;
    color: #1e293b;
    border-bottom-left-radius: 4px;
}
.msgs-bubble--their time {
    color: #94a3b8;
}
.msgs-chat-empty {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 0;
    color: #94a3b8;
    font-size: 13px;
}
.msgs-chat-empty i {
    font-size: 2rem;
    margin-bottom: 8px;
}
.msgs-chat-sending {
    padding: 4px 20px;
    font-size: 12px;
    color: #9ca3af;
    font-style: italic;
}
.msgs-chat-input-wrap {
    padding: 12px 16px;
    background: #fff;
    border-top: 1px solid #e5e7eb;
    flex-shrink: 0;
}
.msgs-chat-form {
    display: flex;
    align-items: flex-end;
    gap: 10px;
}
.msgs-chat-textarea {
    flex: 1;
    resize: none;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #f8fafc;
    padding: 10px 14px;
    font-size: 13px;
    line-height: 1.5;
    max-height: 120px;
    overflow-y: auto;
    font-family: inherit;
    outline: none;
    transition: border-color 0.15s;
}
.msgs-chat-textarea:focus {
    border-color: #4361ee;
}
.msgs-chat-send-btn {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: #4361ee;
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition:
        background 0.15s,
        opacity 0.15s;
    font-size: 14px;
}
.msgs-chat-send-btn:hover {
    background: #3451d1;
}
.msgs-chat-send-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}
.msgs-welcome-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4361ee, #3a0ca3);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
}
@media (max-width: 767.98px) {
    .msgs-sidebar {
        border-right: none;
    }
    body:has(.pub-mob-bottom) .msgs-wrap {
        height: calc(100vh - 124px);
    }
}
.pub-chat-widget {
    width: min(380px, calc(100vw - 1rem));
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 16px;
    background: #fff;
    box-shadow:
        0 24px 70px #0f172a2e,
        0 4px 16px #0f172a14;
}
.pub-chat-widget:before {
    content: "";
    position: absolute;
    top: 0;
    inset-inline: 0;
    height: 3px;
    background: linear-gradient(90deg, #2563eb, #059669, #f59e0b);
}
.pub-chat-widget-head {
    min-height: 60px;
    padding: 12px 14px;
    background: linear-gradient(180deg, #f8fafc, #fff);
    border-bottom-color: #e2e8f0e6;
}
.pub-chat-widget-copy {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.pub-chat-widget-title {
    font-size: 14px;
    font-weight: 800;
    color: #0f172a;
}
.pub-chat-widget-subtitle {
    overflow: hidden;
    color: #64748b;
    font-size: 11px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pub-chat-back-btn,
.pub-chat-close-btn,
.pub-chat-widget-link {
    min-width: 30px;
    min-height: 30px;
    border-radius: 10px;
}
.pub-chat-widget-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(37, 99, 235, 0.14);
    background: #eff6ff;
    color: #1d4ed8 !important;
    font-weight: 800;
}
.pub-chat-close-btn:hover {
    background: #fff1f2;
    color: #be123c;
}
.pub-chat-widget-body {
    max-height: min(360px, calc(100vh - 12rem));
    background: #fff;
}
.pub-chat-section-item {
    gap: 12px;
    padding: 13px 14px;
    border-bottom-color: #e2e8f0db;
    border-inline-start: 3px solid transparent;
}
.pub-chat-section-item:hover,
.pub-chat-section-item:focus-visible {
    background: #f8fafc;
    outline: none;
}
.pub-chat-section-item--unread {
    border-inline-start-color: #2563eb;
    background: #f0f7ff;
}
.pub-chat-section-icon,
.pub-chat-head-icon {
    border-radius: 12px;
    box-shadow: inset 0 0 0 1px #fff3;
}
.pub-chat-section-text strong {
    color: #0f172a;
    font-size: 13px;
    font-weight: 800;
}
.pub-chat-section-text span {
    color: #64748b;
    font-size: 11px;
    line-height: 1.35;
}
.pub-chat-section-badge {
    width: fit-content;
    max-width: 100%;
    font-weight: 800;
}
.pub-chat-unread-dot {
    width: 9px;
    height: 9px;
    background: #2563eb;
    box-shadow: 0 0 0 4px #2563eb1f;
}
.pub-chat-widget-footer {
    background: #f8fafc;
    color: #334155 !important;
    font-weight: 900;
}
.pub-chat-messages {
    gap: 9px;
    min-height: 250px;
    max-height: min(360px, calc(100vh - 15rem));
    padding: 14px;
    background: linear-gradient(180deg, #f8fafc, #eef6ff);
}
.pub-chat-bubble {
    max-width: 84%;
    padding: 9px 12px;
    border-radius: 16px;
    font-size: 13px;
    box-shadow: 0 8px 22px #0f172a0f;
}
.pub-chat-bubble--mine {
    background: #2563eb;
    border-bottom-right-radius: 5px;
}
.pub-chat-bubble--their {
    border-color: #cbd5e1e6;
    background: #fff;
    border-bottom-left-radius: 5px;
}
.pub-chat-error,
.msgs-chat-error {
    margin: 0;
    padding: 8px 14px;
    border-top: 1px solid rgba(254, 205, 211, 0.9);
    background: #fff1f2;
    color: #be123c;
    font-size: 12px;
    font-weight: 700;
}
.pub-chat-empty-state--error i {
    color: #be123c;
    opacity: 0.75;
}
.pub-chat-retry-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 6px 12px;
    border: 1px solid rgba(37, 99, 235, 0.18);
    border-radius: 999px;
    background: #eff6ff;
    color: #1d4ed8;
    font-size: 12px;
    font-weight: 800;
}
.pub-chat-input-row {
    gap: 8px;
    padding: 10px;
    border-top-color: #e2e8f0e6;
    background: #fff;
}
.pub-chat-input {
    min-height: 40px;
    max-height: 96px;
    border-radius: 13px;
    background: #f8fafc;
    font-weight: 600;
}
.pub-chat-input:focus {
    border-color: #2563eb;
    background: #fff;
    box-shadow: 0 0 0 4px #2563eb1a;
}
.pub-chat-send-btn {
    width: 40px;
    height: 40px;
    border-radius: 13px;
    background: #2563eb;
    box-shadow: 0 10px 24px #2563eb38;
}
.pub-chat-send-btn:hover {
    background: #1d4ed8;
}
.msgs-page-shell {
    background: linear-gradient(180deg, #f8fafc, #eef6ff);
}
.msgs-wrap {
    height: calc(100dvh - 64px);
    min-height: 620px;
    overflow: hidden;
}
.msgs-sidebar,
.msgs-chat-header,
.msgs-chat-input-wrap {
    background: #fffffff5;
}
.msgs-sidebar {
    border-right-color: #cbd5e1cc;
}
.msgs-sidebar-head {
    min-height: 64px;
    border-bottom-color: #e2e8f0e6;
}
.msgs-sidebar-title {
    color: #0f172a;
    font-size: 14px;
    font-weight: 900;
}
.msgs-sidebar-item {
    position: relative;
    gap: 12px;
    padding: 13px 16px;
    border-bottom-color: #e2e8f0d1;
    border-inline-start: 3px solid transparent;
}
.msgs-sidebar-item:hover,
.msgs-sidebar-item:focus-visible {
    background: #f8fafc;
    outline: none;
}
.msgs-sidebar-item.active {
    border-inline-start-color: #2563eb;
    background: #eff6ff;
}
.msgs-sidebar-item.unread:not(.active) {
    background: #f8fbff;
}
.msgs-sidebar-avatar,
.msgs-chat-header-avatar,
.msgs-chat-header-photo {
    border-radius: 14px;
}
.msgs-sidebar-avatar {
    width: 46px;
    height: 46px;
}
.msgs-sidebar-name {
    color: #0f172a;
    font-size: 13px;
    font-weight: 800;
}
.msgs-sidebar-preview {
    color: #64748b;
    font-size: 12px;
    line-height: 1.35;
}
.msgs-sidebar-time {
    color: #94a3b8;
    font-weight: 700;
}
.msgs-chat-col {
    background: transparent;
}
.msgs-chat-header {
    min-height: 64px;
    padding: 12px 22px;
    border-bottom-color: #e2e8f0e6;
}
.msgs-chat-back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid rgba(203, 213, 225, 0.9);
    border-radius: 12px;
    color: #475569;
    text-decoration: none !important;
}
.msgs-chat-back:hover {
    border-color: #2563eb40;
    background: #eff6ff;
    color: #1d4ed8;
}
.msgs-chat-header-avatar,
.msgs-chat-header-photo {
    width: 44px;
    height: 44px;
}
.msgs-chat-header-info strong {
    color: #0f172a;
    font-size: 15px;
    font-weight: 900;
}
.msgs-chat-header-info span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
}
.msgs-chat-presence-dot {
    color: #10b981;
    font-size: 7px;
}
.msgs-chat-live-pill {
    align-items: center;
    gap: 6px;
    margin-left: auto;
    padding: 6px 10px;
    border: 1px solid rgba(16, 185, 129, 0.18);
    border-radius: 999px;
    background: #ecfdf5;
    color: #047857;
    font-size: 11px;
    font-weight: 900;
}
.msgs-admin-badge {
    padding: 5px 10px;
    background: #f5f3ff;
    color: #6d28d9;
    font-weight: 900;
}
.msgs-chat-messages {
    gap: 12px;
    padding: 22px;
    background: linear-gradient(180deg, #f8fafc, #eef6ff);
}
.msgs-bubble-row {
    gap: 10px;
}
.msgs-bubble-avatar {
    width: 32px;
    height: 32px;
    border-color: #cbd5e1e6;
}
.msgs-bubble {
    max-width: min(520px, 76%);
    padding: 10px 13px;
    border-radius: 18px;
    font-size: 13px;
    line-height: 1.6;
    box-shadow: 0 10px 26px #0f172a12;
}
.msgs-bubble--mine {
    background: #2563eb;
    border-bottom-right-radius: 5px;
}
.msgs-bubble--their {
    border: 1px solid rgba(203, 213, 225, 0.84);
    background: #fff;
    border-bottom-left-radius: 5px;
}
.msgs-bubble time {
    margin-left: 8px;
    font-size: 10px;
    font-weight: 700;
}
.msgs-chat-empty {
    color: #64748b;
    font-weight: 700;
}
.msgs-chat-empty i {
    color: #2563eb;
    opacity: 0.7;
}
.msgs-chat-sending {
    padding: 7px 22px;
    color: #64748b;
    font-style: normal;
    font-weight: 700;
}
.msgs-chat-input-wrap {
    padding: 14px 18px;
    border-top-color: #e2e8f0e6;
}
.msgs-chat-form {
    gap: 10px;
}
.msgs-chat-textarea {
    min-height: 44px;
    max-height: 132px;
    border-radius: 15px;
    background: #f8fafc;
    color: #0f172a;
    font-weight: 600;
    transition:
        border-color 0.15s,
        box-shadow 0.15s,
        background 0.15s;
}
.msgs-chat-textarea:focus {
    border-color: #2563eb;
    background: #fff;
    box-shadow: 0 0 0 4px #2563eb1a;
}
.msgs-chat-send-btn {
    width: 44px;
    height: 44px;
    border-radius: 15px;
    background: #2563eb;
    box-shadow: 0 10px 24px #2563eb38;
}
.msgs-chat-send-btn:hover {
    background: #1d4ed8;
}
@media (max-width: 767.98px) {
    .pub-chat-widget {
        position: fixed;
        top: calc(env(safe-area-inset-top, 0px) + 4rem);
        inset-inline: 0.75rem;
        width: auto;
        max-height: calc(100dvh - 5rem);
    }
    .pub-chat-messages {
        max-height: min(380px, calc(100dvh - 14rem));
    }
    .msgs-wrap,
    body:has(.pub-mob-bottom) .msgs-wrap {
        height: calc(100dvh - 124px);
        min-height: 0;
    }
    .msgs-chat-header {
        padding: 10px 12px;
    }
    .msgs-chat-messages {
        padding: 16px 12px;
    }
    .msgs-bubble {
        max-width: 84%;
    }
    .msgs-chat-input-wrap {
        padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px));
    }
}
