﻿body {
    background: #fafdff;
}

.p-c {
    background: rgba(0,0,0,0.25);
    color: #fff;
    padding: 2rem;
    border-radius: 1rem;
    text-align: center;
    margin: 1rem 0;
}

.form-check-input.online {
    border: none;
}

.form-check-input.online:checked {
    background-color: #03a801;
     
}
 
.message-body {
    border-top: 1px solid var(--gray-200);
    padding-top: 1rem;
    margin-top: 1rem;
    display: flex;
}
    .message-body > div {
        flex: 1 1;
        position: relative;
    }
        .message-body > div:nth-child(2) {
            margin-left: 1rem;
            padding-left: 1rem;
            border-left: 1px solid var(--gray-200);
        }
.message-attachments {
 
    margin-top: 1rem;
    display: flex;
}
.message-attachments a {
    border: 1px solid var(--gray-200);
    border-radius: 5rem;
    padding: 0.25rem 1rem;
    text-decoration: none;
}

.tr-highlight td {
    background-color: #f7fafc !important;
}

.notifications-popup {
    position: absolute;
    width: 260px;
    min-height: 60px;
    background: #fff;
    right: -2px;
    border-radius: 1rem;
    color: #000;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 1rem;
    box-shadow: -2px 2px 15px -7px rgba(120, 131, 132, 0.29), inset 0px 0px 2px 1px rgba(255, 255, 255, 0.4) !important;
}
    .notifications-items div {
        border-bottom: 1px solid var(--gray-200);
    }

.form-images-preview .img-preview-thumb {
    overflow: hidden;
    position: relative;
    border-radius: 0.5rem;
    height: 150px;
    width: 200px;
}

    .form-images-preview .img-preview-thumb:hover .img-controls {
        opacity: 1;
    }

    .form-images-preview .img-preview-thumb.is-thumbnail {
        border: 3px solid #f17775;
    }

    .form-images-preview .img-preview-thumb .author {
        position: absolute;
        z-index: 5;
        bottom: 0;
        right: 0;
        background: rgba(0, 0, 0, 0.6);
        color: white;
        font-size: 12px;
        padding: 2px 4px;
    }

    .form-images-preview .img-preview-thumb .img-controls {
        position: absolute;
        height: 100%;
        width: 100%;
        top: 0;
        left: 0;
        opacity: 0;
        transition: opacity 0.2s ease;
        background: rgba(0, 0, 0, 0.2);
    }

    .form-images-preview .img-preview-thumb .img-control {
        width: 36px;
        height: 36px;
        border-radius: 20px;
        background: var(--primary-500);
        text-align: center;
        line-height: 36px;
        color: white;
        cursor: pointer;
        transition: background 0.2s ease;
    }
        .form-images-preview .img-preview-thumb .img-control:hover {
            background: var(--primary-500);
        }

.subscription-item {
    border: 1px solid var(--gray-300);
    margin-right: 0.5rem;
    width: 20%;
}
.subscription-item.active {
    border: 2px solid var(--primary-400);
     
}
/* =========================================================
   2026 dark client administration shell
   Bootstrap remains the component and grid foundation.
   ========================================================= */
:root {
    --client-bg: #07101d;
    --client-bg-soft: #0a1423;
    --client-sidebar: #081426;
    --client-panel: #0f1d30;
    --client-panel-2: #13243a;
    --client-border: rgba(151, 174, 209, .14);
    --client-border-strong: rgba(151, 174, 209, .24);
    --client-text: #edf4ff;
    --client-muted: #8fa3bd;
    --client-accent: #4f8cff;
    --client-accent-soft: rgba(79, 140, 255, .14);
    --client-success: #2dd4a7;
    --client-danger: #fb7185;
    --client-sidebar-width: 268px;
    --client-topbar-height: 72px;
}

html, body.client-admin-body {
    min-height: 100%;
    background: var(--client-bg);
}

body.client-admin-body {
    color: var(--client-text);
    overflow-x: hidden;
}

.client-admin-shell {
    min-height: 100vh;
    background:
        radial-gradient(circle at 75% 0%, rgba(33, 78, 160, .16), transparent 32rem),
        var(--client-bg);
}

.client-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 1040;
    width: var(--client-sidebar-width);
    display: flex;
    flex-direction: column;
    background: linear-gradient(180deg, #09172b 0%, #07111f 100%);
    border-right: 1px solid var(--client-border);
}

.client-sidebar__brand {
    height: var(--client-topbar-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 22px;
    border-bottom: 1px solid var(--client-border);
}

.client-sidebar__logo { display: inline-flex; align-items: center; }
.client-sidebar__logo img { width: auto; height: 44px; }
.client-sidebar__close,
.client-topbar__menu,
.client-icon-button,
.client-user-button {
    border: 0;
    background: transparent;
    color: var(--client-text);
}
.client-sidebar__close { font-size: 1.6rem; }

.client-sidebar__nav {
    flex: 1;
    overflow-y: auto;
    padding: 16px 14px;
}

.client-sidebar__section + .client-sidebar__section { margin-top: 20px; }
.client-sidebar__label {
    margin: 0 12px 9px;
    color: #607590;
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.client-sidebar__link {
    position: relative;
    display: flex;
    align-items: center;
    gap: 13px;
    min-height: 40px;
    margin: 3px 0;
    padding: 7px 13px;
    border: 1px solid transparent;
    border-radius: 12px;
    color: #9fb0c7;
    font-size: .94rem;
    font-weight: 600;
    text-decoration: none;
    transition: .18s ease;
}
.client-sidebar__link i { width: 22px; font-size: 1.35rem; text-align: center; }
.client-sidebar__link:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, .045);
}
.client-sidebar__link.active {
    color: #fff;
}
.client-sidebar__link.active i { color: #78a7ff; }

.client-sidebar__link .client-sidebar__unread-icon {
    width: auto;
    margin-left: auto;
    color: #35d68a;
    font-size: .62rem;
    filter: drop-shadow(0 0 5px rgba(53, 214, 138, .55));
}

.gmail-provider-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    object-fit: contain;
}

.client-sidebar__footer {
    padding: 14px;
    border-top: 1px solid var(--client-border);
}
.client-sidebar__profile-link {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 10px;
    border-radius: 13px;
    color: var(--client-text);
    text-decoration: none;
    transition: background .18s ease;
}
.client-sidebar__profile-link:hover { color: #fff; }
.client-sidebar__profile-text { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.client-sidebar__profile-text strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .88rem; }
.client-sidebar__profile-text small { color: var(--client-muted); font-size: .72rem; }
.client-avatar {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(124, 169, 255, .25);
    border-radius: 50%;
    color: #fff;
    font-weight: 800;
}

.client-admin-main { min-height: 100vh; margin-left: var(--client-sidebar-width); }
.client-topbar {
    position: fixed;
    top: 0;
    right: 0;
    left: var(--client-sidebar-width);
    z-index: 1030;
    height: var(--client-topbar-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
    border-bottom: 1px solid var(--client-border);
}
.client-topbar__left,
.client-topbar__actions,
.client-online-control { display: flex; align-items: center; }
.client-topbar__left { gap: 14px; }
.client-topbar__actions { gap: 10px; }
.client-topbar__menu { width: 42px; height: 42px; border-radius: 11px; font-size: 1.45rem; background: var(--client-panel); }
.client-icon-button,
.client-user-button {
    position: relative;
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--client-border);
    border-radius: 12px;
    background: rgba(255,255,255,.025);
    font-size: 1.3rem;
    transition: .18s ease;
}
.client-icon-button:hover,
.client-user-button:hover { background: var(--client-panel-2); border-color: var(--client-border-strong); }
.client-user-button.dropdown-toggle::after { display: none; }
.client-online-control {
    gap: 9px;
    height: 42px;
    padding: 0 13px;
    border: 1px solid var(--client-border);
    border-radius: 12px;
    background: rgba(255,255,255,.025);
    color: #b8c8db;
    font-size: .8rem;
    font-weight: 700;
}
.client-status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--client-success); box-shadow: 0 0 10px rgba(45,212,167,.75); }

.main-body {
    min-height: 100vh;
    padding: calc(var(--client-topbar-height) + 30px) 34px 42px;
    background: transparent;
    color: var(--client-text);
}
.main-body > .container,
.main-body > .container-lg,
.main-body > .container-md,
.main-body > .container-sm,
.main-body > .container-xl,
.main-body > .container-xxl {
    max-width: 1440px;
}

/* Bootstrap dark adaptation */
.client-admin-body .card,
.client-admin-body .widget,
.client-admin-body .box,
.client-admin-body .content-box {
    color: var(--client-text);
    background: linear-gradient(180deg, rgba(18, 34, 55, .96), rgba(13, 27, 45, .96));
    border: 1px solid var(--client-border);
    border-radius: 15px;
}
.client-admin-body .card-header,
.client-admin-body .card-footer { background: rgba(255,255,255,.018); border-color: var(--client-border); }
.client-admin-body h1,
.client-admin-body h2,
.client-admin-body h3,
.client-admin-body h4,
.client-admin-body h5,
.client-admin-body h6,
.client-admin-body label,
.client-admin-body .text-dark { color: var(--client-text) !important; }
.client-admin-body p,
.client-admin-body small,
.client-admin-body .text-muted { color: var(--client-muted) !important; }
.client-admin-body a { color: #7da9ff; }
.client-admin-body a:hover { color: #a8c4ff; }
.client-admin-body hr { border-color: var(--client-border); opacity: 1; }

.client-admin-body .table { --bs-table-bg: transparent; --bs-table-color: #dfe9f8; --bs-table-border-color: var(--client-border); }
.client-admin-body .table > :not(caption) > * > * { background: transparent; color: inherit; border-color: var(--client-border); }
.client-admin-body .table-hover > tbody > tr:hover > * { --bs-table-accent-bg: rgba(78, 137, 240, .08); color: #fff; }
.client-admin-body .tr-highlight td { background: rgba(78, 137, 240, .08) !important; }

.client-admin-body .form-control,
.client-admin-body .form-select,
.client-admin-body .select2-container--default .select2-selection--single,
.client-admin-body .select2-container--default .select2-selection--multiple {
    color: #e8f1ff;
    background-color: #0a1728;
    border-color: var(--client-border-strong);
    border-radius: 10px;
}
.client-admin-body .form-control::placeholder { color: #60738d; }
.client-admin-body .form-control:focus,
.client-admin-body .form-select:focus {
    color: #fff;
    background-color: #0b1a2e;
}
.client-admin-body .form-control:disabled,
.client-admin-body .form-control[readonly] { background: #0b1625; color: #7f91a9; }
.client-admin-body .input-group-text { color: #9eb1ca; background: #101e31; border-color: var(--client-border-strong); }
.client-admin-body .btn-light,
.client-admin-body .btn-secondary { color: #d9e6f7; background: #14253a; border-color: var(--client-border-strong); }
.client-admin-body .btn-outline-primary { color: #77a5ff; border-color: rgba(89, 146, 255, .55); }
.client-admin-body .btn-outline-primary:hover { color: #fff; background: #316bd8; }

.client-admin-body .dropdown-menu,
.client-admin-body .client-dropdown {
    padding: 8px;
    background: #101e31;
    border: 1px solid var(--client-border-strong);
    border-radius: 12px;
    box-shadow: 0 18px 50px rgba(0,0,0,.36);
}
.client-admin-body .dropdown-item { display: flex; gap: 9px; align-items: center; color: #c7d5e8; border-radius: 8px; }
.client-admin-body .dropdown-item:hover { color: #fff; background: rgba(79,140,255,.12); }
.client-admin-body .dropdown-divider { border-color: var(--client-border); }

.client-admin-body .modal-content { color: var(--client-text); background: #0f1d30; border: 1px solid var(--client-border-strong); border-radius: 16px; }
.client-admin-body .modal-header,
.client-admin-body .modal-footer { border-color: var(--client-border); }
.client-admin-body .btn-close { filter: invert(1) grayscale(100%) brightness(180%); }
.client-admin-body .message-body,
.client-admin-body .message-body > div:nth-child(2),
.client-admin-body .message-attachments a { border-color: var(--client-border); }

.client-notifications .notifications-popup,
#notifications .notifications-popup {
    right: 0;
    color: var(--client-text);
    background: #101e31;
    border: 1px solid var(--client-border-strong);
    border-radius: 14px;
    box-shadow: 0 22px 50px rgba(0,0,0,.38);
}

.client-sidebar-backdrop { display: none; }

@media (max-width: 1199.98px) {
    .client-sidebar { transform: translateX(-100%); transition: transform .22s ease; }
    .client-sidebar.is-open { transform: translateX(0); }
    .client-sidebar-backdrop {
        position: fixed;
        inset: 0;
        z-index: 1035;
        display: block;
        visibility: hidden;
        opacity: 0;
        background: rgba(0, 5, 14, .72);
        transition: .22s ease;
    }
    .client-sidebar-backdrop.is-open { visibility: visible; opacity: 1; }
    .client-admin-main { margin-left: 0; }
    .client-topbar { left: 0; padding: 0 18px; }
    .main-body { padding: calc(var(--client-topbar-height) + 22px) 18px 30px; }
    body.client-menu-open { overflow: hidden; }
}

@media (max-width: 575.98px) {
    .client-topbar { padding: 0 12px; }
    .client-topbar__title { display: none; }
    .client-online-control { padding: 0 9px; }
    .client-online-control > span:not(.client-status-dot) { display: none; }
}

/* =========================================================
   2026 client admin refinement: nested sidebar + unified pages
   ========================================================= */
.client-sidebar__group {
    margin: 3px 0;
}

.client-sidebar__group-toggle {
    width: 100%;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 7px 13px;
    border: 1px solid transparent;
    border-radius: 12px;
    background: transparent;
    color: #9fb0c7;
    font-size: .94rem;
    font-weight: 650;
    text-align: left;
    transition: .18s ease;
}

.client-sidebar__group-toggle:hover,
.client-sidebar__group-toggle.active {
    color: #fff;
    border-color: rgba(255, 255, 255, .05);
}

.client-sidebar__group-main {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 13px;
}

.client-sidebar__group-main > i {
    width: 22px;
    color: #8fa7c7;
    font-size: 1.35rem;
    text-align: center;
}

.client-sidebar__group-toggle.active .client-sidebar__group-main > i {
    color: #78a7ff;
}

.client-sidebar__caret {
    flex: 0 0 auto;
    color: #607590;
    font-size: .85rem;
    transition: transform .18s ease;
}

.client-sidebar__group-toggle:not(.collapsed) .client-sidebar__caret {
    transform: rotate(180deg);
}

.client-sidebar__submenu {
    position: relative;
    margin: 2px 0 5px 24px;
    padding: 2px 0 2px 14px;
}

.client-sidebar__submenu::before {
    content: "";
    position: absolute;
    top: 5px;
    bottom: 5px;
    left: 0;
    width: 1px;
}

.client-sidebar__sublink {
    min-height: 34px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    padding: 6px 10px;
    border: 1px solid transparent;
    border-radius: 9px;
    color: #8195af;
    font-size: .82rem;
    font-weight: 600;
    text-decoration: none;
    transition: .16s ease;
}

.client-sidebar__sublink i {
    width: 18px;
    color: #617895;
    font-size: 1rem;
    text-align: center;
}

.client-sidebar__sublink:hover {
    color: #eaf2ff;
    background: rgba(255,255,255,.04);
    transform: translateX(2px);
}

.client-sidebar__sublink.active {
    color: #fff;
    background: rgba(79, 140, 255, .15);
    border-color: rgba(79, 140, 255, .18);
}

.client-sidebar__sublink.active i {
    color: #7da9ff;
}

.client-topbar__context {
    min-width: 0;
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.client-topbar__eyebrow {
    color: #5f7692;
    font-size: .6rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.client-topbar__title {
    margin-top: 3px;
    overflow: hidden;
    color: #e5eefb;
    font-size: .98rem;
    font-weight: 750;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.main-body--workspace {
    height: 100vh;
    overflow: hidden;
}

.client-page {
    width: 100%;
    margin: 0 auto;
}

.client-page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 24px;
}

.client-page-kicker {
    margin-bottom: 6px;
    color: #5d85c7;
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.client-page-title {
    margin: 0;
    color: #f3f7ff;
    font-size: clamp(1.45rem, 2vw, 2rem);
    font-weight: 760;
    letter-spacing: -.03em;
}

.client-page-description {
    max-width: 760px;
    margin: 7px 0 0;
    color: var(--client-muted) !important;
    font-size: .9rem;
    line-height: 1.55;
}

.client-page-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.client-settings-content {
    width: 100%;
}

.client-settings-content > .row.justify-content-center > [class*="col-md-8"],
.client-settings-content > .row.justify-content-center > [class*="col-lg-8"] {
    width: 100%;
    max-width: 1120px;
}

.client-card,
.client-admin-body .bg-white,
.client-admin-body .alert-light,
.client-admin-body .list-group-item,
.client-admin-body .accordion-item {
    color: var(--client-text) !important;
    background: linear-gradient(180deg, rgba(17, 32, 52, .98), rgba(12, 25, 42, .98)) !important;
    border: 1px solid var(--client-border) !important;
}

.client-admin-body .bg-light {
    color: var(--client-text) !important;
    background: rgba(255,255,255,.045) !important;
}

.client-admin-body .shadow,
.client-admin-body .shadow-lg {
    box-shadow: 0 16px 42px rgba(0, 0, 0, .18) !important;
}

.client-admin-body .rounded-0,
.client-admin-body .rounded-44 {
    border-radius: 16px !important;
}

.client-admin-body .border,
.client-admin-body .border-top,
.client-admin-body .border-bottom,
.client-admin-body .border-start,
.client-admin-body .border-end {
    border-color: var(--client-border) !important;
}

.client-admin-body .text-gray-300,
.client-admin-body .text-gray-400,
.client-admin-body .text-gray-500,
.client-admin-body .text-secondary {
    color: var(--client-muted) !important;
}

.client-admin-body .badge-info,
.client-admin-body .badge.bg-info {
    color: #bcd3ff;
    background: rgba(79,140,255,.15) !important;
    border: 1px solid rgba(79,140,255,.2);
}

.client-admin-body .badge {
    border-radius: 999px;
    font-weight: 700;
}

.client-admin-body .form-label {
    margin-bottom: .45rem;
    color: #aebfd5 !important;
    font-size: .76rem;
    font-weight: 700;
}

.client-admin-body .form-control,
.client-admin-body .form-select,
.client-admin-body textarea,
.client-admin-body select {
    min-height: 44px;
}

.client-admin-body textarea.form-control {
    min-height: 110px;
}

.client-admin-body .select2-container {
    max-width: 100%;
}

.client-admin-body .select2-container--default .select2-selection--single {
    height: 44px;
}

.client-admin-body .select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #e8f1ff;
    line-height: 42px;
}

.client-admin-body .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 42px;
}

.client-admin-body .select2-dropdown {
    color: #dce8f8;
    background: #101e31;
    border-color: var(--client-border-strong);
}

.client-admin-body .select2-search__field {
    color: #fff !important;
    background: #0a1728 !important;
    border-color: var(--client-border-strong) !important;
}

.client-admin-body .select2-results__option--highlighted[aria-selected],
.client-admin-body .select2-results__option--highlighted[data-selected] {
    background: rgba(79,140,255,.2);
}

.client-admin-body .btn {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border-radius: 10px;
    font-size: .82rem;
    font-weight: 700;
}

.client-admin-body .btn--small {
    min-height: 34px;
    padding: .35rem .7rem;
    font-size: .74rem;
}

.client-admin-body .btn--primary,
.client-admin-body .btn-success,
.client-admin-body .btn-success:hover,
.client-admin-body .btn--primary:hover {
    color: #fff;
}

.client-admin-body .btn-border {
    color: #c8d7e9;
    background: #122238;
    border: 1px solid var(--client-border-strong);
}

.client-admin-body .btn-border:hover {
    color: #fff;
    background: #182c47;
}

.client-admin-body .btn-danger {
    color: #ffd9df;
    background: rgba(251, 113, 133, .13);
    border-color: rgba(251, 113, 133, .28);
}

.client-admin-body .btn-danger:hover {
    color: #fff;
    background: rgba(251, 113, 133, .24);
}

.client-admin-body .accordion-button {
    color: #e4edf9;
    background: #112139;
    box-shadow: none;
}

.client-admin-body .accordion-button:not(.collapsed) {
    color: #fff;
    background: rgba(79,140,255,.13);
}

.client-admin-body .accordion-button::after {
    filter: invert(1) brightness(1.8);
}

.client-admin-body .accordion-body {
    color: #c4d2e5;
    background: #0d1a2c;
}

.client-admin-body .table thead th {
    padding-top: 14px;
    padding-bottom: 14px;
    color: #7188a6;
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    white-space: nowrap;
}

.client-admin-body .table tbody td {
    padding-top: 14px;
    padding-bottom: 14px;
    vertical-align: middle;
}

.client-admin-body .table tbody tr {
    transition: background .15s ease;
}

.client-admin-body .table tbody tr:hover {
    background: rgba(79,140,255,.05);
}

.client-admin-body .pagination {
    margin-bottom: 0;
}

.client-admin-body .page-link {
    color: #a9bdd8;
    background: #0d1b2d;
    border-color: var(--client-border);
}

.client-admin-body .page-link:hover,
.client-admin-body .page-item.active .page-link {
    color: #fff;
    background: #2e67d1;
    border-color: #4f8cff;
}

.client-admin-body .page-item.disabled .page-link {
    color: #536781;
    background: #0a1524;
    border-color: var(--client-border);
}

.client-admin-body .flatpickr-calendar {
    background: #101e31;
    border: 1px solid var(--client-border-strong);
    box-shadow: 0 24px 55px rgba(0,0,0,.35);
}

.client-admin-body .flatpickr-day,
.client-admin-body .flatpickr-months .flatpickr-month,
.client-admin-body .flatpickr-current-month,
.client-admin-body span.flatpickr-weekday {
    color: #dbe6f5;
}

.client-admin-body .flatpickr-day:hover,
.client-admin-body .flatpickr-day.selected {
    color: #fff;
    background: #316bd8;
    border-color: #4f8cff;
}

.client-admin-body .trumbowyg-box,
.client-admin-body .trumbowyg-editor-box {
    color: #e6eef9;
    background: #0a1728;
    border-color: var(--client-border-strong);
}

.client-admin-body .trumbowyg-button-pane {
    background: #101f34;
    border-color: var(--client-border);
}

.client-admin-body .trumbowyg-button-pane button {
    color: #c9d8ea;
}

.client-admin-body .trumbowyg-editor,
.client-admin-body .trumbowyg-textarea {
    color: #e8f1ff;
    background: #0a1728;
}

.client-admin-body .trumbowyg-button-pane button.trumbowyg-active,
.client-admin-body .trumbowyg-button-pane button:not(.trumbowyg-disable):hover {
    background: rgba(79,140,255,.16);
}

.client-admin-body .list-group-item + .list-group-item {
    border-top-color: var(--client-border) !important;
}

.client-admin-body .modal-backdrop.show {
    opacity: .7;
}

.client-admin-body .client-settings-content .bg-white,
.client-admin-body .client-settings-content .client-card {
    border-radius: 16px !important;
}

.client-admin-body .client-settings-content .row > [class*="col-"] {
    min-width: 0;
}

.client-admin-body .client-settings-content .d-flex.align-items-center.justify-content-between {
    gap: 16px;
}

.client-collection-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
}

.client-collection-count {
    color: #607590;
    font-size: .82rem;
    font-weight: 700;
}

.client-list-card {
    position: relative;
    overflow: hidden;
    border-radius: 15px !important;
    transition: transform .16s ease, border-color .16s ease, background .16s ease;
}

.client-list-card:hover {
    border-color: rgba(79,140,255,.28) !important;
    transform: translateY(-1px);
}

.client-data-card {
    overflow: hidden;
    border: 1px solid var(--client-border);
    border-radius: 16px;
    background: linear-gradient(180deg, rgba(17, 32, 52, .98), rgba(12, 25, 42, .98));
}

.client-data-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--client-border);
}

.client-filter-card {
    margin-bottom: 18px;
    border: 1px solid var(--client-border);
}

.client-filter-card__title {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 16px;
    color: #e7effb;
    font-size: .9rem;
    font-weight: 750;
}

.client-filter-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 18px;
}

.client-empty-state {
    min-height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 36px;
    border: 1px dashed rgba(133, 159, 195, .2);
    border-radius: 16px;
    background: rgba(255,255,255,.018);
    color: var(--client-muted);
    text-align: center;
}

.client-empty-state img {
    width: 82px;
    margin-bottom: 14px;
    opacity: .72;
}

@media (max-width: 991.98px) {
    .client-page-header,
    .client-collection-header,
    .client-filter-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .client-page-actions {
        width: 100%;
    }

    .client-page-actions .btn {
        flex: 1;
    }
}

@media (max-width: 575.98px) {
    .client-sidebar__submenu {
        margin-left: 20px;
    }

    .client-topbar__eyebrow {
        display: none;
    }

    .client-page-header {
        margin-bottom: 18px;
    }

    .client-page-description {
        font-size: .82rem;
    }
}

/* Dashboard */
.dashboard-header {
    align-items: center;
}

.dashboard-setup-guide {
    margin-bottom: 24px;
    border-radius: 19px;
    background: #0c2441;
    box-shadow: 0 20px 55px rgba(0,0,0,.22);
}
.dashboard-setup-guide__header { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 24px 26px; cursor: pointer; list-style: none; }
.dashboard-setup-guide__header::-webkit-details-marker { display: none; }
.dashboard-setup-guide__header::marker { content: ""; }
.dashboard-setup-guide__header > div { min-width: 0; }
.dashboard-setup-guide__kicker { color: #78a8ff; font-size: .66rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.dashboard-setup-guide__header h2 { margin: 4px 0 0; color: #f4f8ff; font-size: 1.35rem; font-weight: 780; letter-spacing: -.02em; }
.dashboard-setup-guide__header p { max-width: 720px; margin: 7px 0 0; color: #8fa6c2 !important; font-size: .76rem; line-height: 1.5; }
.dashboard-setup-guide__status { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 13px; }
.dashboard-setup-guide__chevron { color: #7694b9; font-size: 1rem; transition: transform .2s ease, color .2s ease; }
.dashboard-setup-guide[open] .dashboard-setup-guide__chevron { color: #a9c4e6; transform: rotate(180deg); }
.dashboard-setup-guide__grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); align-items: stretch; gap: 22px; padding: 0 26px 26px; }
.dashboard-setup-guide .dashboard-checklist-section { min-width: 0; margin-top: 0; }
.dashboard-setup-guide .dashboard-checklist-section--extensions { margin-top: 0; padding-top: 0; border-top: 0; }
.dashboard-setup-guide .dashboard-checklist-item,
.dashboard-setup-guide .dashboard-extension-item { background: rgba(2,10,22,.28); }

.dashboard-stat-card {
    position: relative;
    min-height: 156px;
    height: 100%;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 20px;
    overflow: hidden;
    color: var(--client-text) !important;
    border: 1px solid var(--client-border);
    border-radius: 17px;
    background: linear-gradient(145deg, rgba(18, 36, 60, .98), rgba(11, 24, 41, .98));
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.dashboard-stat-card::after {
    content: "";
    position: absolute;
    width: 150px;
    height: 150px;
    top: -75px;
    right: -55px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(79,140,255,.13), transparent 68%);
    pointer-events: none;
}

.dashboard-stat-card[href]:hover {
    color: #fff !important;
    border-color: rgba(79,140,255,.34);
    box-shadow: 0 24px 55px rgba(0,0,0,.23);
    transform: translateY(-2px);
}

.dashboard-stat-icon {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 14px;
    font-size: 1.5rem;
}

.dashboard-stat-icon--blue { color: #87afff; background: rgba(79,140,255,.13); }
.dashboard-stat-icon--violet { color: #bda7ff; background: rgba(139,92,246,.13); }
.dashboard-stat-icon--cyan { color: #72d8ff; background: rgba(14,165,233,.13); }
.dashboard-stat-icon--green { color: #6be0be; background: rgba(45,212,167,.12); }
.dashboard-stat-content { min-width: 0; display: flex; flex: 1; flex-direction: column; }
.dashboard-stat-label { color: #8fa3bd; font-size: .76rem; font-weight: 700; }
.dashboard-stat-value { margin-top: 3px; color: #f4f8ff; font-size: 2.25rem; font-weight: 780; line-height: 1; letter-spacing: -.04em; }
.dashboard-stat-hint { margin-top: 13px; color: #7186a0; font-size: .72rem; line-height: 1.4; }
.dashboard-stat-arrow { align-self: center; color: #506b8e; font-size: 1.1rem; transition: transform .18s ease, color .18s ease; }
.dashboard-stat-card:hover .dashboard-stat-arrow { color: #86adff; transform: translateX(3px); }
.dashboard-live-indicator { display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border-radius: 999px; color: #7ce5c5; background: rgba(45,212,167,.09); font-size: .66rem; font-weight: 800; }
.dashboard-live-indicator span { width: 6px; height: 6px; border-radius: 50%; background: #2dd4a7; box-shadow: 0 0 9px rgba(45,212,167,.75); }

.dashboard-panel {
    padding: 22px;
    border: 1px solid var(--client-border);
    border-radius: 17px;
    background: linear-gradient(180deg, rgba(17, 32, 52, .98), rgba(12, 25, 42, .98));
}

.dashboard-panel-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 15px;
    margin-bottom: 16px;
}

.dashboard-panel-kicker { color: #5d85c7; font-size: .65rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.dashboard-panel h2 { margin: 3px 0 0; color: #edf4ff; font-size: 1.03rem; font-weight: 750; }
.dashboard-panel-badge { padding: 6px 10px; border: 1px solid var(--client-border); border-radius: 999px; color: #9cb0ca; background: rgba(255,255,255,.025); font-size: .7rem; font-weight: 700; }
.dashboard-usage-badges { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.dashboard-panel-badge--danger { display: inline-flex; align-items: center; gap: 5px; color: #ff9caa; background: rgba(231,75,95,.1); }
.dashboard-panel-badge--warning { display: inline-flex; align-items: center; gap: 5px; color: #ffc47d; background: rgba(240,162,75,.1); }
.dashboard-usage-grid { display: grid; grid-template-columns: minmax(190px, .8fr) minmax(250px, 1.2fr); align-items: center; gap: 18px; }
.dashboard-chart { min-height: 220px; }
.dashboard-usage-metrics { display: grid; gap: 9px; }
.dashboard-usage-metric { display: grid; grid-template-columns: 38px 1fr; align-items: center; gap: 11px; min-height: 58px; padding: 9px 12px; border-radius: 12px; background: var(--client-bg); }
.dashboard-usage-metric.is-over-limit { background: var(--client-bg); }
.dashboard-usage-metric.is-over-limit .dashboard-usage-metric__icon { color: #ff96a4; background: rgba(231,75,95,.12); }
.dashboard-usage-metric.is-over-limit .dashboard-usage-metric__copy strong { color: #ffb1bb; }
.dashboard-usage-metric__icon { width: 38px; height: 38px; display: inline-flex; align-items: center; justify-content: center; border-radius: 10px; color: #8db3ff; background: rgba(79,140,255,.11); font-size: 1.15rem; }
.dashboard-usage-metric__copy { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.dashboard-usage-metric__copy small { color: #8195ae; font-size: .67rem; font-weight: 700; }
.dashboard-usage-metric__copy strong { overflow: hidden; color: #f2f7ff; font-size: .86rem; font-weight: 760; text-overflow: ellipsis; white-space: nowrap; }
.dashboard-usage-note { margin: 4px 2px 0 !important; color: #61758f !important; font-size: .67rem; line-height: 1.45; }
.dashboard-usage-note a { color: #82b4f5; font-weight: 750; text-decoration: none; }
.dashboard-usage-note a:hover { color: #b6d4fb; }
.dashboard-readiness-badge { display: inline-flex; align-items: center; gap: 6px; padding: 6px 9px; border-radius: 999px; color: #f0bd79; background: rgba(240,162,75,.09); font-size: .67rem; font-weight: 780; white-space: nowrap; }
.dashboard-readiness-badge.is-ready { color: #70dfbd; background: rgba(45,212,167,.1); }
.dashboard-checklist-section { margin-top: 18px; }
.dashboard-checklist-section--extensions { margin-top: 20px; padding-top: 18px; border-top: 1px solid rgba(121,151,190,.12); }
.dashboard-checklist-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 9px; }
.dashboard-checklist-heading > div { min-width: 0; display: flex; flex-direction: column; }
.dashboard-checklist-heading strong { color: #dce8f7; font-size: .76rem; font-weight: 760; }
.dashboard-checklist-heading small { margin-top: 2px; color: #647b97; font-size: .64rem; line-height: 1.35; }
.dashboard-checklist-heading > span { color: #6f8caf; font-size: .66rem; font-weight: 800; }
.dashboard-checklist { display: grid; gap: 7px; }
.dashboard-checklist-item { display: grid; grid-template-columns: 38px minmax(0,1fr) auto; align-items: center; gap: 11px; min-height: 64px; padding: 10px 12px; border-radius: 12px; color: #dfeaf8 !important; background: rgba(255,255,255,.024); text-decoration: none; transition: background-color .16s ease, transform .16s ease; }
.dashboard-checklist-item:hover { color: #fff !important; background: rgba(79,140,255,.075); transform: translateX(2px); }
.dashboard-checklist-item.is-complete { background: rgba(45,212,167,.045); }
.dashboard-checklist-item.is-locked { opacity: .72; }
.dashboard-checklist-state { width: 38px; height: 38px; display: inline-flex; align-items: center; justify-content: center; border-radius: 10px; color: #89aff8; background: rgba(79,140,255,.1); font-size: 1.08rem; }
.dashboard-checklist-item.is-complete .dashboard-checklist-state { color: #62ddb8; background: rgba(45,212,167,.11); }
.dashboard-checklist-item.is-locked .dashboard-checklist-state { color: #8798ad; background: rgba(255,255,255,.05); }
.dashboard-checklist-copy { min-width: 0; display: flex; flex-direction: column; }
.dashboard-checklist-copy strong { color: inherit; font-size: .77rem; font-weight: 760; }
.dashboard-checklist-copy small { overflow: hidden; margin-top: 2px; color: #6f849d !important; font-size: .65rem; text-overflow: ellipsis; white-space: nowrap; }
.dashboard-checklist-action { display: inline-flex; align-items: center; gap: 5px; color: #7fa8e7; font-size: .65rem; font-weight: 760; white-space: nowrap; }
.dashboard-checklist-item.is-complete .dashboard-checklist-action { color: #69bda6; }
.dashboard-extension-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 7px; }
.dashboard-extension-item { display: grid; grid-template-columns: 34px minmax(0,1fr); align-items: center; gap: 9px; min-height: 57px; padding: 9px 10px; border-radius: 11px; color: #dce7f5 !important; background: rgba(255,255,255,.022); text-decoration: none; transition: background-color .16s ease, transform .16s ease; }
.dashboard-extension-item:hover { color: #fff !important; background: rgba(79,140,255,.07); transform: translateY(-1px); }
.dashboard-extension-item > span { width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; border-radius: 9px; color: #80a9f3; background: rgba(79,140,255,.09); font-size: 1rem; }
.dashboard-extension-item.is-complete > span { color: #61d7b3; background: rgba(45,212,167,.1); }
.dashboard-extension-item > div { min-width: 0; display: flex; flex-direction: column; }
.dashboard-extension-item strong { overflow: hidden; color: inherit; font-size: .7rem; font-weight: 740; text-overflow: ellipsis; white-space: nowrap; }
.dashboard-extension-item small { overflow: hidden; margin-top: 2px; color: #647b96 !important; font-size: .61rem; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 767.98px) {
    .dashboard-header { align-items: stretch; }
    .dashboard-setup-guide__header { align-items: flex-start; padding: 20px 18px; }
    .dashboard-setup-guide__header p { display: none; }
    .dashboard-setup-guide__status { gap: 9px; }
    .dashboard-setup-guide .dashboard-readiness-badge { max-width: 150px; white-space: normal; }
    .dashboard-setup-guide__grid { grid-template-columns: 1fr; }
    .dashboard-setup-guide__grid { padding: 0 18px 20px; }
    .dashboard-usage-grid { grid-template-columns: 1fr; }
    .dashboard-extension-grid { grid-template-columns: 1fr; }
    .dashboard-checklist-action { font-size: 0; }
    .dashboard-checklist-action i { font-size: .9rem; }
}

@media (min-width: 768px) and (max-width: 1399.98px) {
    .dashboard-setup-guide__grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

/* Tickets list */
.client-data-hint { color: #637994; font-size: .72rem; }
.client-table tbody tr[data-id] { cursor: pointer; }
.client-table tbody tr.expanded { background: rgba(79,140,255,.08); }
.client-table .c-table-row-expanded-content { background: rgba(8, 20, 36, .95) !important; }
.client-table .c-table-row-expanded-content > td { border-top: 0; }
.tickets-page .select2-container { width: 100% !important; }
.tickets-page .client-filter-actions .d-sm-flex { margin-top: 0 !important; color: #7f94ad; font-size: .74rem; }
.tickets-page .client-filter-actions .form-control { height: 40px !important; min-height: 40px; }

@media (max-width: 1199.98px) {
    .tickets-page .client-filter-actions > .d-sm-flex { width: 100%; flex-wrap: wrap; gap: 9px; }
}

/* Reusable management list cards */
.client-list-avatar {
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(124,169,255,.22);
    border-radius: 14px;
    color: #c5d9ff;
    background: linear-gradient(145deg, #1c3b70, #132c53);
    font-size: .82rem;
    font-weight: 800;
}
.client-list-avatar i { font-size: 1.35rem; }
.client-list-avatar--widget { color: #85b1ff; background: rgba(79,140,255,.13); }
.client-list-avatar--mail { color: #72dfbf; background: rgba(45,212,167,.11); border-color: rgba(45,212,167,.2); }
.client-list-title { overflow: hidden; color: #edf4ff; font-size: .94rem; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.client-list-meta { overflow: hidden; margin-top: 4px; color: #758aa4; font-size: .75rem; text-overflow: ellipsis; white-space: nowrap; }
.client-list-actions { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.client-list-status { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 5px; padding: 5px 9px; border: 1px solid var(--client-border); border-radius: 999px; color: #9eb5d1; background: rgba(255,255,255,.025); font-size: .67rem; font-weight: 800; }
.client-list-details { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 13px; border: 1px solid rgba(151,174,209,.1); border-radius: 12px; background: rgba(255,255,255,.018); }
.client-list-details > div { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.client-list-details span { color: #617691; font-size: .62rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.client-list-details strong { overflow: hidden; color: #bdcce0; font-size: .72rem; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.client-code-block { max-height: 420px; overflow: auto; margin: 0; padding: 16px; border: 1px solid var(--client-border); border-radius: 12px; background: #07111f; }
.client-empty-icon { display: block; margin-bottom: 12px; color: #59799f; font-size: 2.5rem; }
.min-width-0 { min-width: 0; }

@media (max-width: 767.98px) {
    .client-list-details { grid-template-columns: 1fr; }
    .client-list-card .d-flex.align-items-start.justify-content-between,
    .client-list-card .d-flex.align-items-center.justify-content-between { align-items: stretch !important; flex-direction: column; }
    .client-list-actions { justify-content: flex-end; }
}

/* =========================================================
   2026 client admin v2: complete page system
   ========================================================= */
.client-card {
    overflow: hidden;
    border-radius: 16px !important;
}

.client-back-link {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 14px;
    padding: 7px 10px;
    border: 1px solid var(--client-border);
    border-radius: 10px;
    color: #9fb4d0 !important;
    background: rgba(255,255,255,.022);
    font-size: .78rem;
    font-weight: 700;
    text-decoration: none;
    transition: .16s ease;
}

.client-back-link:hover {
    color: #fff !important;
    border-color: rgba(79,140,255,.28);
    background: rgba(79,140,255,.1);
    transform: translateX(-2px);
}

.client-form-shell {
    width: 100%;
    max-width: 1040px;
    margin: 0 auto;
}

.client-form-shell--narrow { max-width: 720px; }
.client-form-shell--wide { max-width: 1240px; }

.client-form-card .vat-validation__status {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 8px;
    color: #7891b2;
    font-size: 12px;
    line-height: 1.45;
}
.client-form-card .vat-validation__status[hidden] { display: none; }
.client-form-card .vat-validation__icon {
    width: 17px;
    height: 17px;
    flex: 0 0 17px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(94, 124, 166, .2);
    color: #8ca4c4;
    font-size: 11px;
    font-weight: 800;
}
.client-form-card .vat-validation[data-state="valid"] .vat-validation__status { color: #75ddb1; }
.client-form-card .vat-validation[data-state="valid"] .vat-validation__icon {
    background: rgba(40, 196, 133, .15);
    color: #4ce0a4;
}
.client-form-card .vat-validation[data-state="invalid"] .vat-validation__status,
.client-form-card .vat-validation[data-state="invalid_format"] .vat-validation__status,
.client-form-card .vat-validation[data-state="country_mismatch"] .vat-validation__status { color: #ff8e9e; }
.client-form-card .vat-validation__icon.is-loading {
    border: 2px solid rgba(113, 150, 202, .28);
    border-top-color: #6fa9ff;
    background: transparent;
    animation: vat-validation-spin .7s linear infinite;
}
@keyframes vat-validation-spin { to { transform: rotate(360deg); } }

.client-form-section + .client-form-section {
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid var(--client-border);
}

#human-agent-settings > .client-form-section:first-child,
#ai-agent-settings > .client-form-section:first-child {
    margin-top: 25px;
    padding-top: 25px;
}

.client-form-section__header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 18px;
}

.client-form-section__icon {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(79,140,255,.2);
    border-radius: 11px;
    font-size: 1.2rem;
}

.client-form-section__header h2,
.client-form-section__header h3 {
    margin: 0;
    color: #edf4ff;
    font-size: .95rem;
    font-weight: 760;
}

.client-form-section__header p {
    margin: 4px 0 0;
    color: #7489a4 !important;
    font-size: .75rem;
    line-height: 1.45;
}

.client-form-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 20px;
    border-top: 1px solid var(--client-border);
}

.client-info-panel {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    padding: 15px 16px;
    border: 1px solid rgba(79,140,255,.17);
    border-radius: 13px;
    color: #aebfd5;
    background: rgba(79,140,255,.065);
    font-size: .78rem;
    line-height: 1.55;
}

.client-info-panel > i {
    flex: 0 0 auto;
    margin-top: 1px;
    color: #76a5ff;
    font-size: 1.25rem;
}

.client-info-panel--success {
    border-color: rgba(45,212,167,.19);
    background: rgba(45,212,167,.07);
}
.client-info-panel--success > i { color: #5be0ba; }

.client-admin-body .form-text {
    margin-top: .5rem;
    color: #657b96;
    font-size: .7rem;
    line-height: 1.45;
}

.client-admin-body .alert-success {
    color: #a8ecd7;
    background: rgba(45,212,167,.09);
    border-color: rgba(45,212,167,.2);
}

.client-admin-body .alert-danger {
    color: #ffc2cb;
    background: rgba(251,113,133,.09);
    border-color: rgba(251,113,133,.22);
}

.client-admin-body .alert-warning {
    color: #f4d79d;
    background: rgba(245,184,75,.08);
    border-color: rgba(245,184,75,.2);
}

.client-admin-body .text-danger { color: #ff8b9c !important; }
.client-admin-body .text-success { color: #62dcb9 !important; }

.client-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 17px;
    color: #e7effc;
    font-size: .86rem;
    font-weight: 760;
}

.client-section-title > i {
    color: #7da9ff;
    font-size: 1.15rem;
}

.client-section-title .client-collection-count { margin-left: auto; }

.client-detail-list {
    display: grid;
    gap: 0;
}

.client-detail-list > div {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 13px 0;
    border-bottom: 1px solid rgba(151,174,209,.1);
}

.client-detail-list > div:first-child { padding-top: 0; }
.client-detail-list > div:last-child { padding-bottom: 0; border-bottom: 0; }
.client-detail-list span { color: #647a96; font-size: .63rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.client-detail-list strong { overflow-wrap: anywhere; color: #d9e5f5; font-size: .78rem; font-weight: 680; }
.client-detail-list small { overflow-wrap: anywhere; color: #71859f !important; font-size: .69rem; }

.archive-message-list {
    display: grid;
    gap: 13px;
}

.archive-message {
    position: relative;
    padding: 16px;
    border: 1px solid var(--client-border);
    border-radius: 14px;
    background: rgba(255,255,255,.018);
}

.archive-message::before {
    content: "";
    position: absolute;
    top: 15px;
    bottom: 15px;
    left: 0;
    width: 3px;
    border-radius: 999px;
    background: #526b8b;
}

.archive-message--agent::before { background: #4f8cff; }
.archive-message--customer::before { background: #2dd4a7; }
.archive-message--ai::before { background: #9b7cff; }
.archive-message--system::before { background: #70829a; }

.archive-message-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 10px;
}

.archive-message-author {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #e8f1ff;
    font-size: .76rem;
    font-weight: 750;
}

.archive-message-author > span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #526b8b;
}
.archive-message--agent .archive-message-author > span { background: #4f8cff; }
.archive-message--customer .archive-message-author > span { background: #2dd4a7; }
.archive-message--ai .archive-message-author > span { background: #9b7cff; }

.archive-message-head time { color: #667c97; font-size: .66rem; white-space: nowrap; }
.archive-message-meta,
.archive-message-language,
.ticket-message__language { display: inline-flex; align-items: center; gap: 6px; }
.archive-message-language,
.ticket-message__language { color: #607590; font-size: .66rem; font-weight: 700; letter-spacing: .03em; }
.archive-message-language img,
.ticket-message__language img { width: 18px; height: 18px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1px rgba(15, 23, 42, .1); }

.ticket-language-cell { display: inline-flex; align-items: center; gap: 8px; color: #bfd0e5; font-size: .73rem; font-weight: 700; letter-spacing: .04em; }
.ticket-language-flag { width: 24px; height: 24px; flex: 0 0 auto; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1px rgba(148, 163, 184, .3); }
.archive-message-text { color: #cbd8e9; font-size: .8rem; line-height: 1.65; overflow-wrap: anywhere; }
.archive-message-translation { margin-top: 12px; padding: 11px 12px; border: 1px solid rgba(79,140,255,.13); border-radius: 10px; color: #aebfd3; background: rgba(79,140,255,.055); font-size: .76rem; line-height: 1.55; }
.archive-message-translation span { display: block; margin-bottom: 4px; color: #6f93d3; font-size: .6rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }

/* Statistics */
.statistics-subnav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    padding: 6px;
    border: 1px solid var(--client-border);
    border-radius: 14px;
    background: rgba(8, 20, 36, .72);
}

.statistics-subnav__link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 13px;
    border-radius: 10px;
    color: #7890ad !important;
    font-size: .75rem;
    font-weight: 750;
    text-decoration: none;
    transition: color .16s ease, background .16s ease;
}

.statistics-subnav__link i { font-size: 1rem; }
.statistics-subnav__link:hover { color: #dbe8f8 !important; background: rgba(255,255,255,.035); }
.statistics-subnav__link.active { color: #edf5ff !important; background: rgba(79,140,255,.14); }

.statistics-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.statistics-kpi-grid--activity {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.statistics-kpi-card {
    min-height: 138px;
    box-shadow: none;
}

.statistics-kpi-card .dashboard-stat-value { font-size: 2rem; }

.statistics-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.statistics-card {
    padding: 22px;
}

.statistics-card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.statistics-card__title {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #e8f1ff;
    font-size: .9rem;
    font-weight: 750;
}

.statistics-card__title i {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #8ab1ff;
    background: rgba(79,140,255,.1);
    font-size: 1.1rem;
}

.statistics-card__hint { color: #647a96; font-size: .68rem; }
.statistics-chart { min-height: 300px; }
.statistics-card--wide { width: 100%; }

.statistics-inline-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin-top: -4px;
    color: #7186a0;
    font-size: .72rem;
}

.statistics-inline-note i { color: #8ab1ff; font-size: 1rem; }
.statistics-inline-note strong { color: #dfeaff; }
.statistics-team-card { overflow: hidden; }

.statistics-agent-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #7186a0;
    font-size: .72rem;
    font-weight: 700;
}

.statistics-agent-status > span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #51657d;
}

.statistics-agent-status.is-online { color: #6fdcba; }
.statistics-agent-status.is-online > span { background: #2dd4a7; box-shadow: 0 0 8px rgba(45,212,167,.6); }

/* Help center */
.help-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.help-category-card {
    position: relative;
    min-height: 190px;
    display: flex;
    align-items: flex-start;
    gap: 17px;
    padding: 23px;
    border: 1px solid var(--client-border);
    border-radius: 16px;
    color: inherit !important;
    background: linear-gradient(145deg, rgba(18,36,60,.98), rgba(11,24,41,.98));
    text-decoration: none;
    transition: .18s ease;
}

.help-category-card:hover {
    color: inherit !important;
    border-color: rgba(79,140,255,.3);
    box-shadow: 0 20px 45px rgba(0,0,0,.2);
    transform: translateY(-2px);
}

.help-category-card__icon {
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(79,140,255,.18);
    border-radius: 15px;
    color: #86afff;
    background: rgba(79,140,255,.1);
    font-size: 1.55rem;
}

.help-category-card h2 { margin: 2px 0 7px; font-size: 1rem; font-weight: 760; }
.help-category-card p { margin: 0; color: #7489a4 !important; font-size: .76rem; line-height: 1.55; }
.help-category-card__arrow { position: absolute; right: 18px; bottom: 17px; color: #536b8a; transition: .18s ease; }
.help-category-card:hover .help-category-card__arrow { color: #7ca8ff; transform: translateX(3px); }

.help-article-list { overflow: hidden; }
.help-article-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 18px;
    border-bottom: 1px solid var(--client-border);
    color: #cbd9ea !important;
    text-decoration: none;
    transition: .15s ease;
}
.help-article-link:last-child { border-bottom: 0; }
.help-article-link:hover { color: #fff !important; background: rgba(79,140,255,.065); }
.help-article-link i { color: #526c8e; transition: .15s ease; }
.help-article-link:hover i { color: #7ca8ff; transform: translateX(3px); }

.help-article-content {
    color: #c6d4e6;
    font-size: .86rem;
    line-height: 1.75;
}
.help-article-content h1,
.help-article-content h2,
.help-article-content h3 { margin-top: 1.7em; color: #f0f5ff !important; }
.help-article-content a { text-decoration: underline; text-underline-offset: 3px; }
.help-article-content pre { overflow: auto; padding: 15px; border: 1px solid var(--client-border); border-radius: 12px; background: #07111f; }
.help-article-content img { max-width: 100%; height: auto; margin: 18px 0; border: 1px solid var(--client-border); border-radius: 12px; }

/* Subscription and API panels */

/* Registration and selectable plans */
.registration-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 18px;
}
.registration-step { display: flex; align-items: center; gap: 9px; padding: 11px 12px; border: 1px solid var(--client-border); border-radius: 11px; color: #70859f; background: rgba(255,255,255,.018); font-size: .7rem; font-weight: 700; }
.registration-step span { width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; color: #a9c5ff; background: rgba(79,140,255,.12); }
.subscription-options { display: grid !important; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 10px; }
.subscription-item { margin: 0 !important; padding: 15px !important; border: 1px solid var(--client-border) !important; border-radius: 13px !important; color: #cbd9ea; background: rgba(255,255,255,.02); cursor: pointer; transition: .16s ease; }
.subscription-item:hover { border-color: rgba(79,140,255,.28) !important; background: rgba(79,140,255,.06); }
.subscription-item.active { border: 1px solid #4f8cff !important; background: rgba(79,140,255,.12); box-shadow: 0 0 0 3px rgba(79,140,255,.08); }

/* Ticket message cards */
#messages > .message.ticket-message {
    position: relative;
    margin: 0 18px 14px !important;
    padding: 16px !important;
    border: 1px solid rgba(151,174,209,.14) !important;
    border-radius: 14px !important;
    color: #cbd8e9 !important;
    background: #0e1e32 !important;
    box-shadow: 0 10px 28px rgba(0,0,0,.17) !important;
}
#messages > .message.ticket-message--agent { margin-left: 70px !important; border-color: rgba(79,140,255,.2) !important; background: linear-gradient(145deg, rgba(34,76,151,.34), #10213a) !important; }
#messages > .message.ticket-message--customer { margin-right: 70px !important; }
.ticket-message__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 11px; }
.ticket-message__identity { display: flex; align-items: center; gap: 10px; min-width: 0; }
.ticket-message__avatar { width: 32px; height: 32px; flex: 0 0 32px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid rgba(124,169,255,.2); border-radius: 10px; color: #bcd2f7; background: #183259; font-size: .72rem; font-weight: 800; }
.ticket-message--customer .ticket-message__avatar { color: #93e5cd; border-color: rgba(45,212,167,.2); background: rgba(45,212,167,.09); }
.ticket-message__identity strong { display: block; overflow: hidden; color: #edf4ff; font-size: .76rem; text-overflow: ellipsis; white-space: nowrap; }
.ticket-message__identity small { display: block; overflow: hidden; margin-top: 2px; color: #6f849f !important; font-size: .65rem; text-overflow: ellipsis; white-space: nowrap; }
.ticket-message__time { flex: 0 0 auto; color: #607590; font-size: .63rem; text-align: right; }
.ticket-message__time .ticket-message__language { justify-content: flex-end; margin-bottom: 4px; }
.ticket-message__time strong { display: block; color: #8ca1bb; font-size: .66rem; }
#messages > .message.ticket-message .message-body { margin-top: 0; padding-top: 0; border-top: 0; }
#messages > .message.ticket-message .message-body > div { padding: 13px; border: 1px solid rgba(151,174,209,.1); border-radius: 11px; background: rgba(5,14,25,.25); }
#messages > .message.ticket-message .message-body > div + div { margin-left: 10px; padding-left: 13px; }

@media (max-width: 991.98px) {
    .statistics-kpi-grid,
    .statistics-kpi-grid--activity { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .statistics-grid,
    .help-grid { grid-template-columns: 1fr; }
}

@media (max-width: 767.98px) {
    .statistics-kpi-grid { grid-template-columns: 1fr; }
    .statistics-subnav__link { flex: 1 1 calc(50% - 4px); justify-content: center; }
    .client-form-card { padding: 18px; }
    .client-form-actions { align-items: stretch; flex-direction: column-reverse; }
    .client-form-actions .btn { width: 100%; }
    .archive-message-head { flex-direction: column; gap: 5px; }
    .subscription-options,
    .registration-steps { grid-template-columns: 1fr; }
    #messages > .message.ticket-message--agent,
    #messages > .message.ticket-message--customer { margin-right: 10px !important; margin-left: 10px !important; }
    .ticket-message__head { flex-direction: column; gap: 8px; }
    .ticket-message__time { text-align: left; }
    #messages > .message.ticket-message .message-body { flex-direction: column; }
    #messages > .message.ticket-message .message-body > div + div { margin-top: 9px; margin-left: 0; }
}

/* Widget editor */
.widget-settings-card .accordion {
    overflow: hidden;
    border: 1px solid var(--client-border);
    border-radius: 14px;
}
.widget-settings-card .accordion-item { border: 0 !important; border-bottom: 1px solid var(--client-border) !important; border-radius: 0 !important; }
.widget-settings-card .accordion-item:last-child { border-bottom: 0 !important; }
.widget-settings-card .accordion-button { min-height: 56px; padding: 15px 17px; }
.widget-settings-card .accordion-body { padding: 20px; }
.widget-settings-card .coloris { max-width: 100%; color: #e8f1ff; background: #0a1728; border-color: var(--client-border-strong); }
.widget-settings-card .theme-picker { flex-wrap: wrap; }
.widget-settings-card .theme-item .theme-icon { color: #8ca1bb; background: rgba(255,255,255,.02); border-color: var(--client-border); }
.widget-settings-card .theme-item:hover .theme-icon,
.widget-settings-card .theme-item.active .theme-icon { color: #8bb2ff; background: rgba(79,140,255,.08); border-color: #4f8cff; }
.widget-settings-card .c-file-input-btn { padding: 10px 14px; border: 1px dashed rgba(79,140,255,.3); border-radius: 11px; color: #9fc0ff; background: rgba(79,140,255,.06); cursor: pointer; }
.widget-settings-card .form-images-preview { padding: 12px; border: 1px solid var(--client-border); border-radius: 12px; background: rgba(255,255,255,.02); }

/* Dark third-party controls and status badges */
.client-admin-body .select2-container--default .select2-selection--multiple {
    min-height: 44px;
    padding: 4px 7px;
}
.client-admin-body .select2-container--default .select2-selection--multiple .select2-selection__choice {
    margin-top: 4px;
    color: #cfe0f7;
    background: rgba(79,140,255,.13);
    border-color: rgba(79,140,255,.23);
    border-radius: 7px;
}
.client-admin-body .select2-container--default .select2-selection--multiple .select2-selection__choice__remove { color: #92b5f8; }
.client-admin-body .select2-container--default .select2-selection--multiple .select2-search__field { min-height: 30px; margin-top: 2px; color: #e8f1ff !important; background: transparent !important; }
.client-admin-body .select2-container--default .select2-results__option[aria-selected="true"] { color: #aebfd5; background: rgba(255,255,255,.045); }
.client-admin-body .badge-success { color: #85e7ca; background: rgba(45,212,167,.11); border: 1px solid rgba(45,212,167,.2); }
.client-admin-body .badge-danger { color: #ffadba; background: rgba(251,113,133,.11); border: 1px solid rgba(251,113,133,.22); }
.client-admin-body .badge-warning { color: #f1cf8d; background: rgba(245,184,75,.1); border: 1px solid rgba(245,184,75,.2); }
.client-table .expand-icon { color: #58708f; font-size: 1.15rem; transition: transform .16s ease, color .16s ease; }
.client-table tr:hover .expand-icon { color: #83adff; }
.client-table tr.expanded .expand-icon { color: #83adff; transform: rotate(180deg); }
.ticket-status-form .select2-container { width: 100% !important; }

/* =========================================================
   2026 client admin v3: edge-to-edge workspace and controls
   ========================================================= */
.main-body {
    padding: var(--client-topbar-height) 0 0;
}

.client-page {
    max-width: 1500px;
    padding: 30px 34px 42px;
}

.main-body--workspace {
    padding: var(--client-topbar-height) 0 0;
}

.client-sidebar__submenu--inline {
    display: block;
    margin-top: -2px;
    margin-bottom: 4px;
}

.client-admin-body .form-control,
.client-admin-body .form-select,
.client-admin-body textarea,
.client-admin-body select,
.client-admin-body .select2-container--default .select2-selection--single,
.client-admin-body .select2-container--default .select2-selection--multiple {
    border: 1px solid #334a67 !important;
}

.client-admin-body .form-control:hover,
.client-admin-body .form-select:hover,
.client-admin-body .select2-container--default .select2-selection--single:hover,
.client-admin-body .select2-container--default .select2-selection--multiple:hover {
    border-color: #46617f !important;
}

.client-admin-body .form-control:focus,
.client-admin-body .form-select:focus,
.client-admin-body .select2-container--focus .select2-selection--single,
.client-admin-body .select2-container--focus .select2-selection--multiple,
.client-admin-body .select2-container--open .select2-selection--single,
.client-admin-body .select2-container--open .select2-selection--multiple {
    border-color: #4f8cff !important;
    box-shadow: 0 0 0 .2rem rgba(79, 140, 255, .13) !important;
}

.client-admin-body .input-group-text {
    border-color: #334a67;
}

#sounds > span {
    padding: 0;
    border-radius: 0;
    background: transparent;
}

.client-icon-button.is-active {
    color: #9fc0ff;
    border-color: rgba(79, 140, 255, .4);
    background: rgba(79, 140, 255, .13);
    box-shadow: 0 0 0 1px rgba(79, 140, 255, .05), 0 8px 22px rgba(18, 64, 145, .14);
}

.client-icon-button.is-muted {
    color: #d996a2;
    border-color: rgba(251, 113, 133, .25);
    background: rgba(251, 113, 133, .075);
}

.client-notifications {
    position: relative;
}

.client-notification-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    width: 7px;
    height: 7px;
    border: 2px solid #081321;
    border-radius: 50%;
    background: #fb7185;
    box-sizing: content-box;
    box-shadow: 0 0 9px rgba(251, 113, 133, .72);
}

.client-notifications.has-unread .client-icon-button {
    color: #ffc3cc;
    border-color: rgba(251, 113, 133, .3);
}

.client-notifications .notifications-popup {
    top: calc(100% + 10px);
    right: 0;
    z-index: 1080;
    width: min(320px, calc(100vw - 28px));
    min-height: 90px;
}

.client-notifications .notifications-items {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}

.client-notifications .notifications-items:empty::before {
    content: attr(data-empty-label);
    display: block;
    padding: 12px;
    border: 1px dashed rgba(151, 174, 209, .15);
    border-radius: 10px;
    color: #7187a2;
    font-size: .75rem;
    font-weight: 500;
    text-align: center;
}

.client-notifications .notifications-items > div {
    padding: 9px 10px;
    border: 1px solid rgba(151, 174, 209, .12);
    border-radius: 9px;
    color: #bdcce0;
    background: rgba(255, 255, 255, .025);
    font-size: .76rem;
    line-height: 1.4;
}

.client-user-button {
    border: 0;
}

.client-user-button:hover,
.client-user-button:focus,
.client-user-button.show {
    color: #fff;
    border-color: transparent;
    box-shadow: none;
}

.client-user-button .client-avatar--plain {
    width: auto;
    height: auto;
    flex: 0 0 auto;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    font-size: .9rem;
    letter-spacing: .045em;
    line-height: 1;
}

@media (max-width: 1199.98px) {
    .main-body {
        padding: var(--client-topbar-height) 0 0;
    }

    .client-page {
        padding: 24px 18px 32px;
    }
}

@media (max-width: 575.98px) {
    .main-body {
        padding-right: 0;
        padding-left: 0;
    }

    .client-page {
        padding: 20px 12px 28px;
    }
}

/* =========================================================
   2026 client admin v4: compact sidebar and simpler surfaces
   ========================================================= */

/* Remove the decorative gradients from the main application shell. */
.client-admin-shell {
    background: var(--client-bg);
}

.client-sidebar {
    background: var(--client-sidebar);
    box-shadow: none;
    transition: width .2s ease, transform .22s ease;
}

.client-admin-main {
    transition: margin-left .2s ease;
}

.client-topbar {
    background: #07101d;
    backdrop-filter: none;
    transition: left .2s ease;
}

.client-sidebar__link:hover,
.client-sidebar__group-toggle:hover,
.client-sidebar__profile-link:hover {
    transform: none;
    background: #0d2038;
}

.client-sidebar__link.active,
.client-sidebar__group-toggle.active {
    background: #10294a !important;
    border-color: #24466f;
    box-shadow: inset 3px 0 0 var(--client-accent);
}

.client-sidebar__submenu::before {
    background: #203957;
}

.client-avatar {
    background: #10243f;
}

.client-admin-body .card,
.client-admin-body .widget,
.client-admin-body .box,
.client-admin-body .content-box,
.client-card,
.client-data-card,
.client-filter-card,
.dashboard-stat-card,
.dashboard-panel,
.statistics-card,
.help-category-card,
.ticket-panel,
.chat-panel {
    background: var(--client-panel) !important;
    background-image: none !important;
    box-shadow: none !important;
}

.client-admin-body .btn-primary,
.client-admin-body .btn--primary,
.client-admin-body .btn-success {
    background: #316fe8 !important;
    background-image: none !important;
    border-color: #397af1;
    box-shadow: none !important;
}

.client-admin-body .btn-primary:hover,
.client-admin-body .btn--primary:hover,
.client-admin-body .btn-success:hover {
    background: #3d7bf0 !important;
}

/* Form pages intentionally sit directly on the application background. */
.client-form-shell {
    margin-right: 0;
    margin-left: 0;
}

.client-form-card,
.client-card.client-form-card,
.client-filter-card {
    overflow: visible;
    padding: 0 !important;
    background: transparent !important;
    background-image: none !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

.client-form-section__icon {
    color: #83adff;
    background: transparent;
    border-color: #29476c;
}

.client-form-actions {
    margin-top: 26px;
}

.client-admin-body .form-control,
.client-admin-body .form-select,
.client-admin-body textarea,
.client-admin-body select,
.client-admin-body .select2-container--default .select2-selection--single,
.client-admin-body .select2-container--default .select2-selection--multiple {
    border-color: #2b425e !important;
    box-shadow: none;
}

.client-topbar__menu {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.client-topbar__menu i {
    transition: transform .18s ease;
}

/* Profile remains compact, but is visibly clickable. */
.client-user-button {
    width: auto;
    height: 42px;
    min-width: 64px;
    gap: 8px;
    padding: 0 11px;
    border: 1px solid var(--client-border) !important;
    border-radius: 12px;
    background: transparent;
}

.client-user-button:hover,
.client-user-button:focus,
.client-user-button.show {
    border-color: var(--client-border-strong) !important;
    background: #0d1d31;
}

.client-user-button .client-avatar--plain {
    color: #e3edf9;
}

.client-user-chevron {
    color: #8094ad;
    font-size: .78rem;
    transition: transform .18s ease, color .18s ease;
}

.client-user-button:hover .client-user-chevron,
.client-user-button.show .client-user-chevron {
    color: #c9d8ea;
}

.client-user-button.show .client-user-chevron {
    transform: rotate(180deg);
}

/* Desktop sidebar can be reduced to an icon rail. */
@media (min-width: 1200px) {
    html.client-sidebar-is-collapsed {
        --client-sidebar-width: 84px;
    }

    html.client-sidebar-is-collapsed .client-sidebar__brand {
        justify-content: center;
        padding-right: 20px;
        padding-left: 20px;
    }

    html.client-sidebar-is-collapsed .client-sidebar__logo {
        width: 42px;
        overflow: hidden;
    }

    html.client-sidebar-is-collapsed .client-sidebar__logo img {
        width: auto;
        max-width: none;
        height: 34px;
    }

    html.client-sidebar-is-collapsed .client-sidebar__nav {
        padding-right: 12px;
        padding-left: 12px;
        overflow-x: hidden;
    }

    html.client-sidebar-is-collapsed .client-sidebar__label,
    html.client-sidebar-is-collapsed .client-sidebar__link span,
    html.client-sidebar-is-collapsed .client-sidebar__group-main span,
    html.client-sidebar-is-collapsed .client-sidebar__caret,
    html.client-sidebar-is-collapsed .client-sidebar__submenu,
    html.client-sidebar-is-collapsed .client-sidebar__profile-text,
    html.client-sidebar-is-collapsed .client-sidebar__profile-link > .la-angle-right {
        display: none !important;
    }

    html.client-sidebar-is-collapsed .client-sidebar__section + .client-sidebar__section {
        margin-top: 14px;
    }

    html.client-sidebar-is-collapsed .client-sidebar__link,
    html.client-sidebar-is-collapsed .client-sidebar__group-toggle,
    html.client-sidebar-is-collapsed .client-sidebar__profile-link {
        width: 48px;
        min-height: 40px;
        justify-content: center;
        margin-right: auto;
        margin-left: auto;
        padding: 9px;
    }

    html.client-sidebar-is-collapsed .client-sidebar__link {
        gap: 0;
    }

    html.client-sidebar-is-collapsed .client-sidebar__link i,
    html.client-sidebar-is-collapsed .client-sidebar__group-main > i {
        width: auto;
        margin: 0;
        font-size: 1.35rem;
    }

    html.client-sidebar-is-collapsed .client-sidebar__unread-icon {
        display: none;
    }

    html.client-sidebar-is-collapsed .client-sidebar__group-main {
        justify-content: center;
    }

    html.client-sidebar-is-collapsed .client-sidebar__footer {
        padding: 12px;
    }

    html.client-sidebar-is-collapsed .client-sidebar__profile-link .client-avatar {
        width: 34px;
        height: 34px;
        flex-basis: 34px;
        font-size: .75rem;
    }

}

@media (max-width: 1199.98px) {
    html.client-sidebar-is-collapsed {
        --client-sidebar-width: 268px;
    }

    .client-topbar__menu {
        display: inline-flex;
    }
}

/* =========================================================
   AI data sources
   ========================================================= */
.ai-source-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 30px;
}

.ai-source-summary {
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 104px;
    padding: 18px 20px;
    border: 1px solid var(--client-border);
    border-radius: 14px;
    background: var(--client-panel);
}

.ai-source-summary__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border: 1px solid #29476c;
    border-radius: 11px;
    color: #86adfa;
    font-size: 1.35rem;
}

.ai-source-summary strong,
.ai-source-summary span {
    display: block;
}

.ai-source-summary strong {
    color: #edf4ff;
    font-size: 1.3rem;
    line-height: 1.15;
}

.ai-source-summary div > span {
    margin-top: 5px;
    color: #7f93ad;
    font-size: .78rem;
}

.ai-source-list-header {
    margin-bottom: 16px;
}

.ai-source-table-wrap {
    overflow: hidden;
    border: 1px solid var(--client-border);
    border-radius: 14px;
    background: var(--client-panel);
}

.ai-source-table > :not(caption) > * > * {
    padding: 16px 14px;
}

.ai-source-table th {
    white-space: nowrap;
}

.ai-source-name-cell {
    min-width: 310px;
}

.ai-source-type-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    border: 1px solid var(--client-border-strong);
    border-radius: 10px;
    color: #9cbcf8;
    font-size: 1.25rem;
}

.ai-source-name {
    display: block;
    color: #e8f1ff;
    font-weight: 650;
    text-decoration: none;
}

.ai-source-name:hover {
    color: #9ec0ff;
}

.ai-source-type {
    margin-top: 3px;
    color: #8094ad;
    font-size: .74rem;
}

.ai-source-url {
    display: block;
    max-width: 330px;
    margin-top: 6px;
    overflow: hidden;
    color: #6682a5;
    font-size: .72rem;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-decoration: none;
}

.ai-source-url:hover {
    color: #8fb5ff;
}

.ai-source-widget-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-width: 160px;
}

.ai-source-widget-badge,
.ai-source-widget-more {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 28px;
    padding: 4px 8px;
    border: 1px solid #263e5c;
    border-radius: 8px;
    color: #bfd0e6;
    background: #0b192a;
    font-size: .7rem;
    font-weight: 600;
}

.ai-source-widget-badge small {
    color: #7ea7f4;
    font-size: .62rem;
}

.ai-source-widget-more {
    color: #8ca7c9;
}

.ai-source-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
    color: #aebfd5;
    font-size: .72rem;
    font-weight: 650;
}

.ai-source-status > span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #6f8198;
}

.ai-source-status.is-ready > span { background: #36c89b; }
.ai-source-status.is-processing > span { background: #f2bd58; }
.ai-source-status.is-failed > span { background: #fb7185; }
.ai-source-status.is-disabled > span { background: #53657b; }
.ai-source-status.is-waiting > span { background: #6c91d9; }

.ai-source-error {
    max-width: 180px;
    margin-top: 6px;
    overflow: hidden;
    color: #ff91a1;
    font-size: .68rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ai-source-product-counts {
    min-width: 180px;
}

.ai-source-product-counts strong,
.ai-source-product-counts span {
    display: block;
}

.ai-source-product-counts strong {
    color: #dce8f8;
    font-size: .8rem;
}

.ai-source-product-counts > span {
    margin-top: 3px;
    color: #7187a2;
    font-size: .66rem;
}

.ai-source-progress {
    width: 150px;
    height: 5px;
    margin-top: 9px;
    overflow: hidden;
    border-radius: 5px;
    background: #0a1626;
}

.ai-source-progress span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #397af1;
}

.ai-source-sync-date,
.ai-source-sync-meta,
.ai-source-never {
    display: block;
    white-space: nowrap;
}

.ai-source-sync-date {
    color: #cfdced;
    font-size: .75rem;
}

.ai-source-sync-meta,
.ai-source-never {
    margin-top: 3px;
    color: #7187a2;
    font-size: .68rem;
}

.ai-source-roadmap-note {
    display: flex;
    gap: 12px;
    margin-top: 18px;
    padding: 14px 0;
    border-top: 1px solid var(--client-border);
    color: #8094ad;
}

.ai-source-roadmap-note > i {
    margin-top: 2px;
    color: #79a5f7;
    font-size: 1.15rem;
}

.ai-source-roadmap-note strong,
.ai-source-roadmap-note span {
    display: block;
}

.ai-source-roadmap-note strong {
    color: #cbd9ea;
    font-size: .8rem;
}

.ai-source-roadmap-note span {
    margin-top: 4px;
    font-size: .74rem;
    line-height: 1.55;
}

.ai-source-empty p {
    max-width: 520px;
    margin: 8px auto 0;
    color: #7187a2;
    font-size: .8rem;
}

.ai-source-form-section {
    padding: 0 0 30px;
    margin-bottom: 30px;
    border-bottom: 1px solid var(--client-border);
}

.ai-source-form-section:last-of-type {
    margin-bottom: 0;
}

.ai-source-enabled-switch .form-check-input {
    margin-top: .15rem;
}

.ai-source-widget-selector {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.ai-source-widget-option {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 70px;
    padding: 13px 14px;
    border: 1px solid var(--client-border);
    border-radius: 12px;
    background: #091727;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease;
}

.ai-source-widget-option:hover {
    border-color: var(--client-border-strong);
    background: #0b1c30;
}

.ai-source-widget-option:has(.form-check-input:checked) {
    border-color: #346bc2;
    background: #0d2038;
}

.ai-source-widget-option .form-check-input {
    flex: 0 0 auto;
    margin: 0;
}

.ai-source-widget-option__body {
    min-width: 0;
    flex: 1 1 auto;
}

.ai-source-widget-option__body strong,
.ai-source-widget-option__body span {
    display: block;
}

.ai-source-widget-option__body strong {
    color: #dce8f8;
    font-size: .8rem;
}

.ai-source-widget-option__body span {
    margin-top: 4px;
    overflow: hidden;
    color: #7187a2;
    font-size: .7rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ai-source-widget-option__language {
    flex: 0 0 auto;
    padding: 4px 6px;
    border: 1px solid #29476c;
    border-radius: 6px;
    color: #8fb5ff;
    font-size: .65rem;
    font-weight: 700;
}

.ai-source-stat-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    overflow: hidden;
    border: 1px solid var(--client-border);
    border-radius: 12px;
    background: var(--client-border);
}

.ai-source-stat-grid > div {
    min-height: 88px;
    padding: 17px;
    background: #091727;
}

.ai-source-stat-grid span,
.ai-source-stat-grid strong {
    display: block;
}

.ai-source-stat-grid span {
    color: #7187a2;
    font-size: .7rem;
}

.ai-source-stat-grid strong {
    margin-top: 8px;
    color: #dce8f8;
    font-size: .86rem;
}

@media (max-width: 1199.98px) {
    .ai-source-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767.98px) {
    .ai-source-summary-grid,
    .ai-source-widget-selector,
    .ai-source-stat-grid {
        grid-template-columns: 1fr;
    }

    .ai-source-list-header {
        align-items: stretch;
    }

    .ai-source-list-header .btn {
        width: 100%;
    }
}

.client-info-panel--warning {
    border-color: rgba(242, 189, 88, .22);
    background: rgba(242, 189, 88, .07);
}

.client-info-panel--warning > i {
    color: #f2bd58;
}

/* =========================================================
   AI custom questions and answers
   ========================================================= */
.ai-qa-list-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
}

.ai-qa-list-header h2 {
    margin: 0;
    color: #edf4ff;
    font-size: 1rem;
    font-weight: 760;
}

.ai-qa-list-header p {
    max-width: 760px;
    margin: 6px 0 0;
    color: #7186a0;
    font-size: .76rem;
    line-height: 1.55;
}

.ai-qa-summary-grid {
    display: grid;
    gap: 12px;
    margin-bottom: 18px;
}

.ai-qa-table-wrap {
    overflow: hidden;
    border: 1px solid var(--client-border);
    border-radius: 14px;
    background: rgba(255,255,255,.015);
}

.ai-qa-table .ai-qa-copy-cell {
    min-width: 320px;
    max-width: 560px;
}

.ai-qa-question {
    display: block;
    overflow: hidden;
    color: #eaf2ff !important;
    font-size: .8rem;
    font-weight: 760;
    line-height: 1.45;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ai-qa-question:hover { color: #8fb4ff !important; }

.ai-qa-answer {
    display: -webkit-box;
    overflow: hidden;
    margin-top: 6px;
    color: #7186a0;
    font-size: .71rem;
    line-height: 1.5;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.ai-qa-usage {
    display: block;
    color: #dbe8f8;
    font-size: .82rem;
}

.ai-qa-answer-input {
    min-height: 190px;
    resize: vertical;
}

.ai-qa-stat-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 1199.98px) {
    .ai-qa-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 767.98px) {
    .ai-qa-list-header { align-items: stretch; flex-direction: column; }
    .ai-qa-list-header .btn { width: 100%; justify-content: center; }
    .ai-qa-summary-grid,
    .ai-qa-stat-grid { grid-template-columns: 1fr; }
}

/* Multilingual AI questions and answers */
.ai-qa-summary-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.ai-qa-default-language-row {
    max-width: 420px;
}

.ai-qa-language-panel {
    margin-top: 18px;
    padding: 22px;
    border: 1px solid var(--client-border);
    border-radius: 12px;
    background: rgba(255, 255, 255, .012);
}

.ai-qa-language-panel--default {
    border-color: rgba(91, 141, 239, .38);
}

.ai-qa-language-panel__heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 20px;
}

.ai-qa-language-panel__heading strong {
    display: block;
    margin-top: 3px;
    color: #eaf2ff;
    font-size: .9rem;
    font-weight: 760;
}

.ai-qa-language-panel__eyebrow,
.ai-qa-default-language-caption {
    color: #7186a0;
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.ai-qa-translation-header {
    align-items: center;
}

.ai-qa-translation-header > div:nth-child(2) {
    flex: 1;
}

.ai-qa-add-language {
    flex: 0 0 auto;
}

.ai-qa-add-language:disabled {
    opacity: .45;
    cursor: not-allowed;
}

.ai-qa-translations {
    display: grid;
    gap: 16px;
}

.ai-qa-translation-item {
    margin-top: 0;
}

.ai-qa-translation-language-field {
    width: min(100%, 440px);
}

.ai-qa-translation-empty {
    min-height: 190px;
    margin-top: 14px;
    border: 1px dashed var(--client-border);
    border-radius: 12px;
    background: transparent;
}

.ai-qa-language-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 6px;
}

.ai-qa-language-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 24px;
    padding: 0 8px;
    border: 1px solid #263a53;
    border-radius: 6px;
    color: #94a8c1;
    background: transparent;
    font-size: .65rem;
    font-weight: 800;
    letter-spacing: .04em;
}

.ai-qa-language-badge.is-default {
    border-color: rgba(91, 141, 239, .55);
    color: #b9d0ff;
    background: rgba(91, 141, 239, .09);
}

.ai-qa-default-language-caption {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 7px;
}

.ai-qa-default-language-caption .ai-qa-language-badge {
    height: 21px;
    min-width: 30px;
    padding-inline: 6px;
}

@media (max-width: 1399.98px) {
    .ai-qa-summary-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 767.98px) {
    .ai-qa-language-panel { padding: 16px; }
    .ai-qa-language-panel__heading,
    .ai-qa-translation-header {
        align-items: stretch;
        flex-direction: column;
    }
    .ai-qa-add-language { width: 100%; justify-content: center; }
    .ai-qa-translation-language-field { width: 100%; }
}
