* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

body {
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #f4f6fb;
    color: #101828;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

button,
input {
    font: inherit;
}

button {
    border: 0;
    cursor: pointer;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}

.app {
    width: 100vw;
    height: 100vh;
    max-width: none;
    margin: 0;
    padding: 0;
    border-radius: 0;
    display: grid;
    grid-template-columns: clamp(230px, 12vw, 285px) clamp(300px, 15.8vw, 390px) minmax(0, 1fr) clamp(260px, 13.8vw, 340px);
    background: #ffffff;
    overflow: hidden;
}

.sidebar,
.message-panel,
.chat-panel,
.info-panel {
    height: 100vh;
    min-height: 0;
    overflow: hidden;
    background: #ffffff;
}

.sidebar,
.message-panel,
.info-panel {
    display: flex;
    flex-direction: column;
}

.sidebar {
    border-right: 1px solid #e8eaf0;
}

.sidebar-top {
    height: 70px;
    display: flex;
    align-items: center;
    padding: 0 18px;
    flex-shrink: 0;
}

.brand {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    min-width: 0;
}

.sidebar-menu-button {
    width: 21px;
    height: 21px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 3px;
    background: transparent;
    padding: 0;
}

.sidebar-menu-button span,
.mobile-tool span {
    width: 11px;
    height: 1.5px;
    border-radius: 999px;
    background: #98a2b3;
}

.brand-mark {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 26px;
    background: #1266f1;
    color: #fff;
    font-weight: 800;
    font-size: 13px;
}

.brand-name {
    font-size: 15px;
    font-weight: 750;
    letter-spacing: -.02em;
    color: #101828;
}

.sidebar-nav {
    flex: 1;
    overflow-y: auto;
    padding: 0 13px 14px;
    scrollbar-width: thin;
}

.sidebar-nav::-webkit-scrollbar,
.message-scroll::-webkit-scrollbar,
.chat-body::-webkit-scrollbar,
.info-content::-webkit-scrollbar {
    width: 6px;
}

.sidebar-nav::-webkit-scrollbar-thumb,
.message-scroll::-webkit-scrollbar-thumb,
.chat-body::-webkit-scrollbar-thumb,
.info-content::-webkit-scrollbar-thumb {
    background: #d7dce6;
    border-radius: 999px;
}

.nav-section {
    margin: 0 0 15px;
}

.nav-section-title {
    margin: 0 0 8px;
    padding-left: 3px;
    color: #98a2b3;
    font-size: 10px;
    line-height: 1;
    font-weight: 800;
    letter-spacing: .065em;
}

.nav-group,
.nav-child-group {
    display: grid;
    gap: 4px;
}

.nav-link,
.nav-child,
.nav-grandchild {
    width: 100%;
    display: flex;
    align-items: center;
    min-width: 0;
    color: #667085;
    background: transparent;
    text-align: left;
    border-radius: 9px;
    transition: background .2s ease, color .2s ease, transform .2s ease;
}

.nav-link {
    gap: 10px;
    min-height: 34px;
    padding: 0 9px;
    font-size: 13px;
    font-weight: 620;
}

.nav-link:hover,
.nav-child:hover,
.nav-grandchild:hover {
    background: #f5f6f8;
    color: #101828;
}

.nav-link.is-active,
.nav-child.is-active {
    background: #f5f6f8;
    color: #101828;
}

.nav-icon {
    position: relative;
    width: 17px;
    height: 17px;
    flex: 0 0 17px;
    color: #98a2b3;
}

.nav-link.is-active .nav-icon,
.nav-link:hover .nav-icon {
    color: #101828;
}

.nav-icon::before,
.nav-icon::after {
    content: "";
    position: absolute;
    border-color: currentColor;
}

.nav-icon-dashboard::before {
    inset: 4px 3px 2px;
    border-radius: 2px;
    background: currentColor;
    opacity: .5;
}

.nav-icon-dashboard::after {
    left: 2px;
    top: 7px;
    width: 13px;
    height: 8px;
    border-width: 2px 0 0 2px;
    border-style: solid;
    transform: rotate(45deg);
}

.nav-icon-layers::before,
.nav-icon-layers::after {
    left: 2px;
    right: 2px;
    height: 7px;
    border: 2px solid currentColor;
    border-radius: 3px;
    transform: rotate(45deg);
}

.nav-icon-layers::before { top: 2px; opacity: .55; }
.nav-icon-layers::after { bottom: 2px; }

.nav-icon-apps::before,
.nav-icon-apps::after {
    width: 5px;
    height: 5px;
    background: currentColor;
    border-radius: 2px;
    left: 2px;
    top: 2px;
}

.nav-icon-apps::after { display: none; }

.nav-icon-reports::before {
    left: 2px;
    bottom: 2px;
    width: 3px;
    height: 8px;
    background: currentColor;
    border-radius: 2px;
}

.nav-icon-cube::before {
    inset: 2px;
    background: currentColor;
    clip-path: polygon(50% 0, 92% 23%, 92% 72%, 50% 96%, 8% 72%, 8% 23%);
}

.nav-icon-orders::before {
    inset: 2px 4px;
    border: 2px solid currentColor;
    border-radius: 3px;
}

.nav-icon-orders::after {
    width: 7px;
    height: 2px;
    background: currentColor;
    left: 5px;
    top: 6px;
}

.nav-icon-users::before {
    width: 7px;
    height: 7px;
    border: 2px solid currentColor;
    border-radius: 50%;
    left: 4px;
    top: 2px;
}

.nav-icon-users::after {
    width: 14px;
    height: 8px;
    border: 2px solid currentColor;
    border-radius: 999px 999px 3px 3px;
    left: 1px;
    bottom: 1px;
}

.nav-icon-gallery::before {
    inset: 2px;
    border: 2px solid currentColor;
    border-radius: 3px;
}

.nav-icon-gallery::after {
    left: 4px;
    bottom: 4px;
    width: 9px;
    height: 6px;
    background: currentColor;
    clip-path: polygon(0 100%, 35% 35%, 55% 62%, 75% 20%, 100% 100%);
}

.nav-icon-workflow::before {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: currentColor;
    left: 2px;
    top: 2px;
}

.nav-icon-tasks::before {
    inset: 2px 3px;
    border: 2px solid currentColor;
    border-radius: 4px;
}

.nav-icon-tasks::after {
    left: 6px;
    top: 5px;
    width: 6px;
    height: 3px;
    border-left: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(-45deg);
}

.nav-icon-transaction::before {
    left: 2px;
    top: 4px;
    width: 12px;
    height: 8px;
    border-top: 2px solid currentColor;
    border-right: 2px solid currentColor;
    transform: rotate(-35deg);
}

.nav-icon-transaction::after {
    right: 1px;
    top: 1px;
    width: 6px;
    height: 6px;
    border-top: 2px solid currentColor;
    border-right: 2px solid currentColor;
    transform: rotate(45deg);
}

.nav-icon-subscriber::before {
    left: 2px;
    top: 5px;
    width: 13px;
    height: 9px;
    border: 2px solid currentColor;
    border-radius: 50% 50% 0 0;
}

.nav-icon-subscriber::after {
    left: 3px;
    top: 2px;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: currentColor;
}

.nav-icon-payout::before {
    left: 2px;
    bottom: 2px;
    width: 3px;
    height: 8px;
    border-radius: 2px;
    background: currentColor;
}


.nav-icon-ai::before {
    inset: 2px;
    border: 2px solid currentColor;
    border-radius: 50%;
}

.nav-icon-ai::after {
    left: 6px;
    top: 6px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: currentColor;
}

.nav-icon-knowledge::before {
    left: 3px;
    top: 2px;
    width: 11px;
    height: 13px;
    border: 2px solid currentColor;
    border-radius: 2px 5px 5px 2px;
}

.nav-icon-knowledge::after {
    left: 6px;
    top: 5px;
    width: 7px;
    height: 2px;
    background: currentColor;
    box-shadow: none;
}

.nav-icon-rules::before {
    inset: 2px 3px;
    border: 2px solid currentColor;
    border-radius: 4px;
}

.nav-icon-rules::after {
    left: 6px;
    top: 5px;
    width: 7px;
    height: 5px;
    border-left: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(-45deg);
}

.nav-icon-channels::before {
    left: 2px;
    top: 3px;
    width: 9px;
    height: 9px;
    border: 2px solid currentColor;
    border-radius: 50%;
}

.nav-icon-channels::after {
    right: 1px;
    bottom: 2px;
    width: 7px;
    height: 7px;
    border: 2px solid currentColor;
    border-radius: 50%;
    background: #0f172a;
}

.nav-icon-logs::before {
    left: 3px;
    top: 2px;
    width: 11px;
    height: 13px;
    border: 2px solid currentColor;
    border-radius: 4px;
}

.nav-icon-logs::after {
    left: 6px;
    top: 6px;
    width: 6px;
    height: 2px;
    background: currentColor;
}

.nav-icon-handover::before {
    left: 1px;
    top: 4px;
    width: 8px;
    height: 8px;
    border: 2px solid currentColor;
    border-radius: 50%;
}

.nav-icon-handover::after {
    right: 1px;
    bottom: 3px;
    width: 8px;
    height: 6px;
    border: 2px solid currentColor;
    border-radius: 999px 999px 3px 3px;
}

.nav-label {
    flex: 0 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.menu-badge {
    margin-left: auto;
    min-width: 22px;
    height: 20px;
    border-radius: 999px;
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    line-height: 20px;
    text-align: center;
    padding: 0 6px;
}

.badge-blue { background: #1266f1; }
.badge-purple { background: #7c3aed; }
.badge-orange { background: #f59e0b; }
.badge-green { background: #16a34a; }

.nav-chevron {
    width: 7px;
    height: 7px;
    border-right: 1.7px solid currentColor;
    border-bottom: 1.7px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    opacity: .7;
    flex: 0 0 7px;
    margin-left: 6px;
    transition: transform .2s ease;
}

.nav-link.has-children .menu-badge {
    margin-left: 6px;
}

.nav-child.has-children > span:first-child {
    flex: 0 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.is-expanded > .nav-link .nav-chevron,
.is-expanded > .nav-child .nav-chevron {
    transform: rotate(-135deg) translateY(-1px);
}

.nav-children {
    display: none;
    gap: 3px;
    margin: 2px 0 6px 33px;
}

.nav-group.is-expanded > .nav-children {
    display: grid;
}

.nav-child {
    min-height: 30px;
    padding: 0 9px;
    font-size: 12px;
    font-weight: 620;
}

.nav-grandchildren {
    display: none;
    gap: 3px;
    margin: 2px 0 6px 16px;
}

.nav-child-group.is-expanded > .nav-grandchildren {
    display: grid;
}

.nav-grandchild {
    min-height: 27px;
    padding: 0 9px;
    font-size: 12px;
    font-weight: 560;
}

.upgrade-card {
    margin: 12px 14px 20px;
    padding: 12px;
    border: 1px solid #e8eaf0;
    border-radius: 15px;
    background: #ffffff;
    display: grid;
    grid-template-columns: 42px 1fr;
    gap: 8px 10px;
    align-items: center;
    flex-shrink: 0;
}

.upgrade-icon {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1266f1, #0a48d8);
    color: #fff;
}

.upgrade-icon svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
}

.upgrade-card strong {
    display: block;
    font-size: 12px;
    line-height: 1.2;
    color: #101828;
}

.upgrade-card span {
    display: block;
    font-size: 11px;
    color: #667085;
    margin-top: 2px;
}

.manage-plan {
    grid-column: 1 / -1;
    height: 35px;
    border: 1px solid #e8eaf0;
    background: #fff;
    color: #101828;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 700;
    transition: border-color .2s ease, transform .2s ease, background .2s ease;
}

.manage-plan span {
    display: inline;
    margin-left: 5px;
    color: inherit;
}

.manage-plan:hover {
    background: #f8fafc;
    border-color: #d7dce6;
    transform: translateY(-1px);
}

.message-panel {
    border-right: 1px solid #e8eaf0;
}

.message-panel-header {
    padding: 18px 18px 12px;
    border-bottom: 1px solid transparent;
    flex-shrink: 0;
}

.search-box {
    height: 40px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 13px;
    border: 1px solid #e8eaf0;
    border-radius: 10px;
    background: #ffffff;
}

.search-box:focus-within {
    border-color: rgba(18, 102, 241, .35);
}

.search-box svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: #98a2b3;
    stroke-width: 2;
    flex-shrink: 0;
}

.search-box input {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: #101828;
    font-size: 13px;
}

.search-box input::placeholder {
    color: #98a2b3;
}

.message-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 18px;
}

.message-tab {
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    background: #fff;
    color: #101828;
    border: 1px solid #e8eaf0;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 700;
    transition: background .2s ease, transform .2s ease, border-color .2s ease;
}

.message-tab:hover,
.message-tab.is-active {
    background: #ffffff;
    transform: translateY(-1px);
    border-color: #e1e4ec;
}

.message-tab strong {
    min-width: 20px;
    height: 18px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: #1266f1;
    font-size: 10px;
    line-height: 1;
    padding: 0 6px;
}

.message-tab:nth-child(2) strong {
    color: #101828;
    background: #f4f6fb;
}

.tab-icon {
    position: relative;
    width: 16px;
    height: 16px;
    color: #101828;
}

.inbox-icon::before {
    content: "";
    position: absolute;
    inset: 2px 3px;
    border: 2px solid currentColor;
    border-radius: 4px 4px 2px 2px;
}

.inbox-icon::after {
    content: "";
    position: absolute;
    left: 5px;
    right: 5px;
    bottom: 4px;
    height: 2px;
    background: currentColor;
}

.explore-icon::before {
    content: "";
    position: absolute;
    inset: 3px;
    border: 2px solid currentColor;
    transform: rotate(45deg);
    border-radius: 2px;
}

.explore-icon::after {
    content: "";
    position: absolute;
    left: 7px;
    top: 7px;
    width: 2px;
    height: 2px;
    background: currentColor;
    border-radius: 50%;
}

.message-scroll {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 0 0 18px;
}

.message-section-head {
    padding: 18px 18px 9px;
}

.message-section-head h2 {
    margin: 0;
    font-size: 17px;
    font-weight: 780;
    letter-spacing: -.02em;
}

.create-group-btn {
    width: calc(100% - 36px);
    margin: 0 18px 13px;
    height: 41px;
    border-radius: 8px;
    background: #1266f1;
    color: #fff;
    font-size: 12px;
    font-weight: 750;
    transition: transform .2s ease, background .2s ease;
}

.create-group-btn:hover {
    transform: translateY(-1px);
    background: #0f59dc;
}

.conversation-list {
    display: grid;
    gap: 1px;
}

.message-item {
    position: relative;
    width: 100%;
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    min-height: 66px;
    padding: 9px 18px 9px 20px;
    background: transparent;
    color: #101828;
    text-align: left;
    transition: background .2s ease, transform .2s ease;
}

.message-item:hover,
.message-item.is-active {
    background: #f5f6f8;
}

.message-item:active {
    transform: scale(.995);
}

.conversation-dot {
    position: absolute;
    left: 7px;
    top: 50%;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #1266f1;
    transform: translateY(-50%);
    opacity: 0;
}

.message-item.is-active .conversation-dot {
    opacity: 1;
}

.avatar-wrap {
    position: relative;
    display: inline-flex;
    flex-shrink: 0;
}

.avatar-wrap img {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    background: #f4f6fb;
}

.status-dot {
    position: absolute;
    right: -1px;
    bottom: 1px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #98a2b3;
    border: 2px solid #fff;
}

.status-dot.online {
    background: #22c55e;
}

.status-dot.offline {
    background: #d0d5dd;
}

.status-dot.away,
.status-dot.idle {
    background: #f59e0b;
}

.message-text {
    display: grid;
    min-width: 0;
    gap: 4px;
}

.message-row-top {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.message-row-top strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 12px;
    font-weight: 780;
    letter-spacing: -.01em;
}

.message-row-top em {
    flex-shrink: 0;
    margin-left: auto;
    color: #98a2b3;
    font-size: 10px;
    font-style: normal;
    font-weight: 600;
}

.message-snippet {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #667085;
    font-size: 12px;
    line-height: 1.25;
}

.unread-badge {
    align-self: end;
    min-width: 18px;
    height: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #1266f1;
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    margin-bottom: 8px;
}

.groups-head {
    padding-top: 22px;
}

.group-list .message-item {
    min-height: 62px;
    padding-left: 18px;
}

.group-list .message-item {
    grid-template-columns: 38px minmax(0, 1fr);
}

.chat-panel {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: #ffffff;
}

.mobile-chat-tools {
    display: none;
}

.chat-header {
    height: 70px;
    flex-shrink: 0;
    padding: 0 22px;
    border-bottom: 1px solid #e8eaf0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    background: #fff;
}

.chat-peer {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.chat-avatar img {
    width: 42px;
    height: 42px;
}

.chat-peer h1 {
    margin: 0;
    font-size: 14px;
    font-weight: 820;
    letter-spacing: -.015em;
    color: #101828;
}

.chat-peer p {
    margin: 3px 0 0;
    color: #667085;
    font-size: 12px;
    font-weight: 550;
}

.chat-actions {
    display: inline-flex;
    gap: 9px;
    flex-shrink: 0;
}

.chat-action,
.icon-button {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid #e8eaf0;
    color: #101828;
    transition: transform .2s ease, background .2s ease, border-color .2s ease;
}

.chat-action:hover,
.icon-button:hover {
    background: #f8fafc;
    border-color: #d7dce6;
    transform: translateY(-1px);
}

.chat-action svg,
.input-action svg,
.send-button svg,
.member-count svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.chat-action:nth-child(3) svg circle {
    fill: currentColor;
    stroke: none;
}

.chat-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 25px 24px 22px;
    background: #fff;
}

.date-divider,
.unread-divider {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin: 13px 0 22px;
    color: #98a2b3;
    font-size: 11px;
    font-weight: 650;
}

.date-divider::before,
.date-divider::after,
.unread-divider::before,
.unread-divider::after {
    content: "";
    height: 1px;
    background: #e8eaf0;
    flex: 1;
}

.date-divider span,
.unread-divider span {
    flex: 0 0 auto;
    background: #fff;
    padding: 0 6px;
}

.chat-message {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
}

.chat-message.right {
    justify-content: flex-end;
}

.message-avatar img {
    width: 30px;
    height: 30px;
}

.message-avatar .status-dot {
    width: 8px;
    height: 8px;
    border-width: 1.5px;
}

.bubble-wrap {
    max-width: min(520px, 78%);
    display: grid;
    gap: 4px;
}

.chat-message.right .bubble-wrap {
    justify-items: end;
}

.message-author {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 18px;
    padding-left: 2px;
}

.message-author strong {
    font-size: 11px;
    font-weight: 750;
    color: #475467;
}

.message-author span {
    color: #98a2b3;
    font-size: 10px;
    font-weight: 600;
}

.right-meta {
    justify-content: flex-end;
    padding-right: 2px;
}

.chat-bubble {
    padding: 12px 14px;
    border-radius: 7px 14px 14px 14px;
    background: #f1f3f6;
    color: #101828;
    font-size: 12px;
    line-height: 1.52;
    font-weight: 560;
}

.chat-message.right .chat-bubble {
    border-radius: 14px 7px 14px 14px;
    background: #1266f1;
    color: #fff;
}

.audio-bubble {
    min-width: 220px;
    display: grid;
    grid-template-columns: 26px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 10px 13px;
}

.play-dot {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #1266f1;
    position: relative;
}

.play-dot::after {
    content: "";
    position: absolute;
    left: 8px;
    top: 6px;
    border-left: 7px solid #fff;
    border-top: 5px solid transparent;
    border-bottom: 5px solid transparent;
}

.wave-line {
    display: flex;
    align-items: center;
    gap: 3px;
    height: 24px;
}

.wave-line i {
    display: block;
    width: 2px;
    border-radius: 999px;
    background: #98a2b3;
    animation: wavePulse 1.8s ease-in-out infinite;
}

.wave-line i:nth-child(1) { height: 8px; }
.wave-line i:nth-child(2) { height: 16px; animation-delay: .1s; }
.wave-line i:nth-child(3) { height: 11px; animation-delay: .2s; }
.wave-line i:nth-child(4) { height: 23px; animation-delay: .3s; }
.wave-line i:nth-child(5) { height: 14px; animation-delay: .4s; }
.wave-line i:nth-child(6) { height: 19px; animation-delay: .5s; }
.wave-line i:nth-child(7) { height: 12px; animation-delay: .6s; }
.wave-line i:nth-child(8) { height: 21px; animation-delay: .7s; }
.wave-line i:nth-child(9) { height: 14px; animation-delay: .8s; }
.wave-line i:nth-child(10) { height: 18px; animation-delay: .9s; }
.wave-line i:nth-child(11) { height: 10px; animation-delay: 1s; }

@keyframes wavePulse {
    0%, 100% { opacity: .42; transform: scaleY(.8); }
    50% { opacity: 1; transform: scaleY(1); }
}

.audio-bubble em {
    color: #101828;
    font-size: 11px;
    font-style: normal;
    font-weight: 700;
}

.typing-bubble {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 12px 14px;
}

.typing-bubble span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #98a2b3;
    animation: typingDot 1.2s ease-in-out infinite;
}

.typing-bubble span:nth-child(2) { animation-delay: .12s; }
.typing-bubble span:nth-child(3) { animation-delay: .24s; }

@keyframes typingDot {
    0%, 80%, 100% { transform: translateY(0); opacity: .45; }
    40% { transform: translateY(-4px); opacity: 1; }
}

.reactions {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: -2px;
}

.chat-message.right .reactions {
    justify-content: flex-end;
}

.reactions span {
    height: 20px;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    border-radius: 999px;
    padding: 0 6px;
    background: #fff;
    border: 1px solid #e8eaf0;
    font-size: 11px;
}

.reactions b {
    font-size: 10px;
    color: #667085;
}

.chat-input-bar {
    height: 63px;
    flex-shrink: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 30px 30px 30px 38px;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    border-top: 1px solid #e8eaf0;
    background: #fff;
}

.chat-input-wrap {
    height: 40px;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid #e8eaf0;
    border-radius: 12px;
    background: #fff;
    padding: 0 7px 0 13px;
    min-width: 0;
    transition: border-color .2s ease;
}

.chat-input-wrap:focus-within {
    border-color: rgba(18, 102, 241, .35);
}

.chat-input-wrap input {
    flex: 1;
    min-width: 0;
    outline: 0;
    border: 0;
    background: transparent;
    color: #101828;
    font-size: 13px;
}

.chat-input-wrap input::placeholder {
    color: #98a2b3;
}

.input-mini,
.input-action,
.send-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: #667085;
    transition: color .2s ease, background .2s ease, transform .2s ease;
}

.input-mini {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    font-size: 16px;
}

.input-action {
    width: 30px;
    height: 30px;
    border-radius: 8px;
}

.input-action:hover,
.input-mini:hover {
    color: #101828;
    background: #f5f6f8;
}

.input-action:first-of-type svg circle {
    fill: currentColor;
    stroke: none;
}

.send-button {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    background: #1266f1;
    color: #fff;
}

.send-button:hover {
    transform: translateY(-1px);
    background: #0f59dc;
}

.info-panel {
    border-left: 1px solid #e8eaf0;
    min-width: 0;
}

.info-header {
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 18px;
    border-bottom: 1px solid #e8eaf0;
    flex-shrink: 0;
}

.info-header h2 {
    margin: 0;
    font-size: 14px;
    font-weight: 820;
    letter-spacing: -.01em;
}

.info-content {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding-bottom: 18px;
}

.info-profile {
    padding: 22px 18px 18px;
    text-align: center;
    border-bottom: 1px solid #e8eaf0;
}

.info-avatar img {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    margin: 0 auto;
}

.info-profile h3 {
    margin: 13px 0 5px;
    font-size: 15px;
    font-weight: 820;
    letter-spacing: -.015em;
}

.info-subtitle {
    margin: 0 0 14px;
    color: #667085;
    font-size: 11px;
    font-weight: 650;
    line-height: 1.35;
}

.info-detail-list {
    display: grid;
    gap: 8px;
    margin: 0 0 16px;
}

.info-detail-item {
    display: flex;
    align-items: center;
    gap: 9px;
    min-width: 0;
    padding: 9px 10px;
    border: 1px solid #e8eaf0;
    border-radius: 10px;
    background: #f8fafc;
    text-align: left;
}

.info-detail-item.is-hidden {
    display: none;
}

.info-detail-item span:last-child {
    display: grid;
    min-width: 0;
    gap: 2px;
}

.info-detail-item em {
    color: #98a2b3;
    font-size: 9.5px;
    font-style: normal;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.info-detail-item strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #101828;
    font-size: 12px;
    font-weight: 760;
}

.detail-icon {
    position: relative;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: #eef4ff;
    flex: 0 0 auto;
}

.detail-icon.phone::before {
    content: "";
    position: absolute;
    left: 9px;
    top: 7px;
    width: 9px;
    height: 14px;
    border: 2px solid #1266f1;
    border-radius: 7px 7px 6px 6px;
    transform: rotate(-18deg);
}

.detail-icon.phone::after {
    content: "";
    position: absolute;
    left: 14px;
    bottom: 7px;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #1266f1;
}

.info-actions {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.info-actions button {
    display: grid;
    justify-items: center;
    gap: 6px;
    background: transparent;
    color: #667085;
    min-width: 0;
}

.info-actions button:hover .info-icon {
    border-color: #d7dce6;
    background: #f8fafc;
    transform: translateY(-1px);
}

.info-actions em {
    max-width: 52px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 9.5px;
    line-height: 1.1;
    font-style: normal;
    font-weight: 650;
    color: #667085;
}

.info-icon {
    position: relative;
    width: 32px;
    height: 32px;
    border-radius: 9px;
    border: 1px solid #e8eaf0;
    background: #fff;
    display: inline-flex;
    transition: transform .2s ease, background .2s ease, border-color .2s ease;
}

.info-icon::before,
.info-icon::after {
    content: "";
    position: absolute;
    color: #101828;
}

.info-icon.bell::before {
    left: 10px;
    top: 8px;
    width: 10px;
    height: 11px;
    border: 2px solid #101828;
    border-radius: 7px 7px 4px 4px;
    border-bottom: 0;
}

.info-icon.bell::after {
    left: 13px;
    bottom: 8px;
    width: 5px;
    height: 2px;
    border-radius: 999px;
    background: #101828;
}

.info-icon.pin::before {
    left: 14px;
    top: 7px;
    width: 2px;
    height: 16px;
    background: #101828;
    transform: rotate(-25deg);
}

.info-icon.pin::after {
    left: 10px;
    top: 8px;
    width: 10px;
    height: 8px;
    border: 2px solid #101828;
    border-radius: 5px 5px 2px 2px;
}

.info-icon.plus::before {
    left: 9px;
    top: 15px;
    width: 14px;
    height: 2px;
    background: #101828;
}

.info-icon.plus::after {
    left: 15px;
    top: 9px;
    width: 2px;
    height: 14px;
    background: #101828;
}

.info-icon.gear::before {
    left: 9px;
    top: 9px;
    width: 14px;
    height: 14px;
    border: 2px solid #101828;
    border-radius: 50%;
}

.info-icon.gear::after {
    left: 14px;
    top: 14px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #101828;
}

.info-section {
    padding: 18px 18px 0;
}

.section-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}

.section-title-row h4 {
    margin: 0;
    font-size: 14px;
    font-weight: 820;
    letter-spacing: -.015em;
}

.section-title-row button {
    background: transparent;
    color: #1266f1;
    font-size: 11px;
    font-weight: 800;
    transition: color .2s ease;
}

.section-title-row button:hover {
    color: #0f59dc;
}

.member-count {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #667085;
    font-size: 12px;
    font-weight: 620;
}

.member-count svg {
    color: #667085;
}

.image-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.image-tile {
    aspect-ratio: 1 / 1;
    border-radius: 6px;
    padding: 0;
    overflow: hidden;
    background: #f4f6fb;
    transition: transform .2s ease;
}

.image-tile:hover {
    transform: translateY(-2px);
}

.image-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.file-list,
.link-list {
    display: grid;
    gap: 12px;
}

.file-item,
.link-item {
    display: grid;
    align-items: center;
    gap: 9px;
    min-width: 0;
    transition: transform .2s ease, background .2s ease;
    border-radius: 9px;
}

.file-item:hover,
.link-item:hover {
    transform: translateY(-1px);
    background: #f8fafc;
}

.file-item {
    grid-template-columns: 30px minmax(0, 1fr) auto;
    padding: 2px;
}

.file-type {
    width: 26px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 5px;
    background: #eef2f7;
    color: #667085;
    font-size: 8px;
    font-weight: 900;
}

.file-body,
.link-item span {
    display: grid;
    min-width: 0;
    gap: 2px;
}

.file-body strong,
.link-item strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 11px;
    color: #101828;
    font-weight: 760;
}

.file-body em,
.link-item em,
.file-item time,
.link-item time {
    color: #98a2b3;
    font-size: 10px;
    font-style: normal;
    font-weight: 600;
}

.file-item time,
.link-item time {
    white-space: nowrap;
}

.link-item {
    grid-template-columns: 36px minmax(0, 1fr) auto;
    padding: 2px;
}

.link-item img {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    object-fit: cover;
}

.sidebar-mobile-close {
    display: none;
}

.drawer-backdrop,
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .42);
    z-index: 60;
    opacity: 0;
    pointer-events: none;
    transition: opacity .22s ease;
}

.drawer-backdrop.is-active,
.modal-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
}

.modal-backdrop {
    display: grid;
    place-items: center;
    padding: 18px;
    backdrop-filter: blur(4px);
}

.modal-card {
    width: min(430px, 100%);
    border-radius: 18px;
    background: #fff;
    border: 1px solid rgba(232, 234, 240, .8);
    padding: 24px;
    transform: translateY(14px) scale(.98);
    transition: transform .22s ease;
}

.modal-backdrop.is-open .modal-card {
    transform: translateY(0) scale(1);
}

.modal-card.small {
    width: min(360px, 100%);
}

.modal-close {
    position: absolute;
    right: 14px;
    top: 11px;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: transparent;
    color: #667085;
    font-size: 24px;
    line-height: 1;
}

.modal-close:hover {
    background: #f5f6f8;
    color: #101828;
}

.modal-card h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 820;
    letter-spacing: -.02em;
}

.modal-card p {
    margin: 8px 0 20px;
    color: #667085;
    font-size: 13px;
    line-height: 1.5;
}

.modal-card label {
    display: block;
    margin-bottom: 8px;
    font-size: 12px;
    font-weight: 760;
    color: #344054;
}

.modal-card input {
    width: 100%;
    height: 43px;
    border-radius: 12px;
    border: 1px solid #e8eaf0;
    outline: 0;
    padding: 0 13px;
    color: #101828;
    transition: border-color .2s ease;
}

.modal-card input:focus {
    border-color: rgba(18, 102, 241, .38);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

.modal-actions.single {
    margin-top: 16px;
}

.btn-secondary,
.btn-primary {
    height: 39px;
    border-radius: 11px;
    padding: 0 16px;
    font-size: 13px;
    font-weight: 760;
    transition: transform .2s ease, background .2s ease, border-color .2s ease;
}

.btn-secondary {
    background: #fff;
    color: #344054;
    border: 1px solid #e8eaf0;
}

.btn-secondary:hover {
    background: #f8fafc;
    transform: translateY(-1px);
}

.btn-primary {
    background: #1266f1;
    color: #fff;
}

.btn-primary:hover {
    background: #0f59dc;
    transform: translateY(-1px);
}

.css-icon.close-icon {
    position: relative;
    width: 16px;
    height: 16px;
}

.css-icon.close-icon::before,
.css-icon.close-icon::after {
    content: "";
    position: absolute;
    left: 7px;
    top: 2px;
    width: 2px;
    height: 13px;
    border-radius: 999px;
    background: #667085;
}

.css-icon.close-icon::before {
    transform: rotate(45deg);
}

.css-icon.close-icon::after {
    transform: rotate(-45deg);
}

.is-hidden-by-search {
    display: none !important;
}

@media (max-width: 1190px) {
    .app {
        grid-template-columns: 76px 300px minmax(0, 1fr);
    }

    .sidebar {
        width: 76px;
    }

    .sidebar-top {
        padding: 0 14px;
        justify-content: center;
    }

    .brand {
        justify-content: center;
        gap: 0;
    }

    .sidebar-menu-button,
    .brand-name,
    .nav-section-title,
    .nav-label,
    .nav-chevron,
    .menu-badge,
    .nav-children,
    .upgrade-card div:not(.upgrade-icon),
    .manage-plan {
        display: none;
    }

    .brand-mark {
        margin-left: 0;
    }

    .sidebar-nav {
        padding: 0 12px 14px;
    }

    .nav-link {
        min-height: 42px;
        justify-content: center;
        padding: 0;
    }

    .upgrade-card {
        grid-template-columns: 1fr;
        padding: 8px;
        margin: 12px 11px 16px;
        justify-items: center;
    }

    .upgrade-icon {
        width: 36px;
        height: 36px;
    }

    .info-panel {
        position: fixed;
        right: 0;
        top: 0;
        width: 290px;
        z-index: 55;
        transform: translateX(105%);
        transition: transform .24s ease;
    }

    .info-panel.is-open {
        transform: translateX(0);
    }

    .info-header .sidebar-mobile-close {
        display: inline-flex;
    }
}

@media (max-width: 920px) {
    .app {
        grid-template-columns: 300px minmax(0, 1fr);
    }

    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        width: 270px;
        z-index: 58;
        transform: translateX(-105%);
        transition: transform .24s ease;
    }

    .sidebar.is-open {
        transform: translateX(0);
    }

    .sidebar .brand-name,
    .sidebar .nav-section-title,
    .sidebar .nav-label,
    .sidebar .nav-chevron,
    .sidebar .menu-badge,
    .sidebar .upgrade-card div:not(.upgrade-icon),
    .sidebar .manage-plan {
        display: initial;
    }

    .sidebar .manage-plan {
        display: block;
    }

    .sidebar .sidebar-menu-button {
        display: inline-flex;
    }

    .sidebar-top {
        justify-content: flex-start;
        padding: 0 18px;
    }

    .brand {
        justify-content: flex-start;
        gap: 8px;
    }

    .sidebar-nav {
        padding: 0 13px 14px;
    }

    .sidebar .nav-group.is-expanded > .nav-children,
    .sidebar .nav-child-group.is-expanded > .nav-grandchildren {
        display: grid;
    }

    .sidebar .nav-group:not(.is-expanded) > .nav-children,
    .sidebar .nav-child-group:not(.is-expanded) > .nav-grandchildren {
        display: none;
    }

    .nav-link {
        min-height: 34px;
        justify-content: flex-start;
        padding: 0 9px;
    }

    .upgrade-card {
        grid-template-columns: 42px 1fr;
        margin: 12px 14px 20px;
        padding: 12px;
        justify-items: stretch;
    }

    .sidebar .sidebar-mobile-close {
        display: inline-flex;
        margin-right: 8px;
        width: 32px;
        height: 32px;
    }

    .mobile-chat-tools {
        display: flex;
        height: 48px;
        align-items: center;
        gap: 8px;
        padding: 0 12px;
        border-bottom: 1px solid #e8eaf0;
        background: #fff;
        flex-shrink: 0;
    }

    .mobile-tool {
        min-width: 38px;
        height: 34px;
        border-radius: 10px;
        border: 1px solid #e8eaf0;
        background: #fff;
        color: #101828;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex-direction: column;
        gap: 3px;
        font-size: 12px;
        font-weight: 750;
    }

    .mobile-tool.wide {
        width: auto;
        padding: 0 13px;
    }

    .chat-header {
        height: 66px;
        padding: 0 14px;
    }

    .chat-actions {
        gap: 6px;
    }

    .chat-action {
        width: 32px;
        height: 32px;
    }
}

@media (max-width: 760px) {
    html,
    body {
        overflow: hidden;
    }

    .app {
        display: block;
        width: 100vw;
        height: 100vh;
    }

    .chat-panel {
        width: 100vw;
        height: 100vh;
    }

    .message-panel {
        position: fixed;
        left: 0;
        top: 0;
        width: min(340px, 92vw);
        z-index: 57;
        transform: translateX(-105%);
        transition: transform .24s ease;
    }

    .message-panel.is-open {
        transform: translateX(0);
    }

    .message-panel .sidebar-mobile-close {
        display: inline-flex;
        position: absolute;
        right: 12px;
        top: 11px;
        width: 32px;
        height: 32px;
        z-index: 2;
    }

    .message-panel-header {
        padding-top: 52px;
    }

    .info-panel {
        width: min(320px, 92vw);
    }

    .drawer-backdrop.is-active {
        z-index: 54;
    }

    .chat-body {
        padding: 18px 14px 16px;
    }

    .bubble-wrap {
        max-width: 82%;
    }

    .chat-bubble {
        font-size: 12px;
        padding: 11px 12px;
    }

    .audio-bubble {
        min-width: min(220px, 76vw);
    }

    .chat-peer h1 {
        max-width: 38vw;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .chat-peer p {
        max-width: 38vw;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .chat-avatar img {
        width: 38px;
        height: 38px;
    }

    .chat-action:nth-child(1),
    .chat-action:nth-child(2) {
        display: none;
    }

    .chat-input-bar {
        height: 60px;
        grid-template-columns: minmax(0, 1fr) 30px 30px 30px 38px;
        padding: 9px 10px;
        gap: 6px;
    }

    .chat-input-bar .input-action {
        display: inline-flex;
    }

    .date-divider,
    .unread-divider {
        margin: 10px 0 16px;
    }
}

@media (max-width: 430px) {
    .message-tabs {
        gap: 8px;
    }

    .chat-header {
        gap: 8px;
    }

    .chat-peer {
        gap: 8px;
    }

    .chat-action {
        width: 31px;
        height: 31px;
    }

    .chat-input-bar {
        grid-template-columns: minmax(0, 1fr) 28px 28px 28px 36px;
        padding-left: 8px;
        padding-right: 8px;
        gap: 5px;
    }

    .chat-input-bar .input-action {
        display: inline-flex;
        width: 28px;
        height: 28px;
        border-radius: 8px;
    }

    .send-button {
        width: 36px;
        height: 36px;
        border-radius: 10px;
    }

    .chat-input-wrap {
        height: 38px;
        padding-left: 10px;
        padding-right: 5px;
    }

    .input-mini {
        width: 26px;
        height: 26px;
    }

    .message-author {
        flex-wrap: wrap;
        gap: 4px 8px;
    }

    .bubble-wrap {
        max-width: 86%;
    }
}

/* Flat icon refinements. */
.nav-icon-apps::before {
    width: 13px;
    height: 13px;
    left: 2px;
    top: 2px;
    border-radius: 0;
    background:
        linear-gradient(currentColor 0 0) 0 0 / 5px 5px no-repeat,
        linear-gradient(currentColor 0 0) 8px 0 / 5px 5px no-repeat,
        linear-gradient(currentColor 0 0) 0 8px / 5px 5px no-repeat,
        linear-gradient(currentColor 0 0) 8px 8px / 5px 5px no-repeat;
}

.nav-icon-reports::before {
    left: 2px;
    bottom: 2px;
    width: 15px;
    height: 12px;
    border-radius: 0;
    background:
        linear-gradient(currentColor 0 0) 0 4px / 3px 8px no-repeat,
        linear-gradient(currentColor 0 0) 6px 0 / 3px 12px no-repeat,
        linear-gradient(currentColor 0 0) 12px 0 / 3px 12px no-repeat;
}

.nav-icon-orders::after {
    width: 7px;
    height: 6px;
    left: 5px;
    top: 6px;
    background:
        linear-gradient(currentColor 0 0) 0 0 / 7px 2px no-repeat,
        linear-gradient(currentColor 0 0) 0 4px / 7px 2px no-repeat;
}

.nav-icon-workflow::before {
    width: 14px;
    height: 16px;
    left: 2px;
    top: 2px;
    border-radius: 0;
    background:
        radial-gradient(circle at 2.5px 2.5px, currentColor 0 2.5px, transparent 2.6px),
        radial-gradient(circle at 11.5px 6.5px, currentColor 0 2.5px, transparent 2.6px),
        radial-gradient(circle at 5.5px 13.5px, currentColor 0 2.5px, transparent 2.6px);
}

.nav-icon-subscriber::after {
    left: 3px;
    top: 2px;
    width: 13px;
    height: 5px;
    border-radius: 0;
    background:
        radial-gradient(circle at 1.5px 3px, currentColor 0 1.5px, transparent 1.6px),
        radial-gradient(circle at 6.5px 2px, currentColor 0 1.5px, transparent 1.6px),
        radial-gradient(circle at 11.5px 3px, currentColor 0 1.5px, transparent 1.6px);
}

.nav-icon-payout::before {
    left: 2px;
    bottom: 2px;
    width: 15px;
    height: 12px;
    border-radius: 0;
    background:
        linear-gradient(currentColor 0 0) 0 4px / 3px 8px no-repeat,
        linear-gradient(currentColor 0 0) 6px 1px / 3px 11px no-repeat,
        linear-gradient(currentColor 0 0) 12px 0 / 3px 12px no-repeat;
}

button,
button:hover,
button:focus,
button:active,
.create-group-btn,
.create-group-btn:hover,
.chat-action,
.chat-action:hover,
.icon-button,
.icon-button:hover,
.input-mini,
.input-mini:hover,
.input-action,
.input-action:hover,
.send-button,
.send-button:hover,
.info-actions button,
.info-actions button:hover,
.section-title-row button,
.section-title-row button:hover,
.btn-secondary,
.btn-secondary:hover,
.btn-primary,
.btn-primary:hover {
    transform: none;
}

/* Hard shadow reset: no visual shadow anywhere, including blue chat bubbles. */
*,
*::before,
*::after {
    box-shadow: none !important;
    text-shadow: none !important;
    filter: none !important;
}

.chat-bubble,
.chat-message.right .chat-bubble,
.audio-bubble,
.typing-bubble,
.reactions span,
.search-box,
.message-tab,
.create-group-btn,
.message-item,
.chat-action,
.icon-button,
.input-mini,
.input-action,
.send-button,
.chat-input-wrap,
.info-icon,
.image-tile,
.file-item,
.link-item,
.modal-card,
.btn-secondary,
.btn-primary,
.upgrade-card,
.manage-plan {
    box-shadow: none !important;
    text-shadow: none !important;
    filter: none !important;
}

/* 2K desktop density: make the UI feel closer without adding outer margin/frame. */
@media (min-width: 1800px) {
    .app {
        grid-template-columns: clamp(265px, 12vw, 285px) clamp(350px, 15.8vw, 390px) minmax(0, 1fr) clamp(310px, 13.8vw, 340px);
    }

    .sidebar-top,
    .chat-header,
    .info-header {
        height: 78px;
    }

    .sidebar-nav {
        padding-left: 16px;
        padding-right: 16px;
    }

    .nav-link {
        min-height: 38px;
        font-size: 14px;
        border-radius: 10px;
    }

    .nav-child,
    .nav-grandchild {
        font-size: 13px;
        min-height: 31px;
    }

    .brand-mark {
        width: 30px;
        height: 30px;
        flex-basis: 30px;
        font-size: 15px;
    }

    .brand-name {
        font-size: 16px;
    }

    .message-panel-header {
        padding: 18px 22px 15px;
    }

    .search-box {
        height: 42px;
        border-radius: 12px;
    }

    .message-tab {
        height: 42px;
        font-size: 13px;
    }

    .message-section-head {
        padding: 22px 22px 10px;
    }

    .message-section-head h2 {
        font-size: 19px;
    }

    .create-group-btn {
        width: calc(100% - 44px);
        margin-left: 22px;
        margin-right: 22px;
        height: 45px;
        font-size: 13px;
    }

    .message-item {
        grid-template-columns: 42px minmax(0, 1fr) auto;
        min-height: 72px;
        padding: 10px 22px;
        gap: 12px;
    }

    .avatar-wrap img {
        width: 42px;
        height: 42px;
    }

    .message-row-top strong,
    .message-snippet {
        font-size: 13px;
    }

    .message-row-top em,
    .file-body em,
    .link-item em,
    .file-item time,
    .link-item time {
        font-size: 11px;
    }

    .chat-header {
        padding-left: 28px;
        padding-right: 28px;
    }

    .chat-avatar img {
        width: 46px;
        height: 46px;
    }

    .chat-peer h1 {
        font-size: 16px;
    }

    .chat-peer p {
        font-size: 13px;
    }

    .chat-action,
    .icon-button {
        width: 38px;
        height: 38px;
        border-radius: 10px;
    }

    .chat-body {
        padding: 30px 34px 26px;
    }

    .bubble-wrap {
        max-width: min(660px, 74%);
    }

    .chat-bubble {
        font-size: 13px;
        line-height: 1.55;
        padding: 13px 16px;
    }

    .message-author strong {
        font-size: 12px;
    }

    .message-author span {
        font-size: 11px;
    }

    .message-avatar img {
        width: 34px;
        height: 34px;
    }

    .chat-input-bar {
        height: 70px;
        grid-template-columns: minmax(0, 1fr) 34px 34px 34px 42px;
        padding: 12px 28px;
        gap: 10px;
    }

    .chat-input-wrap {
        height: 45px;
        border-radius: 13px;
    }

    .chat-input-wrap input {
        font-size: 14px;
    }

    .input-action {
        width: 34px;
        height: 34px;
    }

    .send-button {
        width: 42px;
        height: 42px;
    }

    .info-profile {
        padding: 26px 22px 22px;
    }

    .info-avatar img {
        width: 66px;
        height: 66px;
    }

    .info-profile h3 {
        font-size: 16px;
    }

    .info-section {
        padding-left: 22px;
        padding-right: 22px;
    }

    .section-title-row h4 {
        font-size: 15px;
    }

    .image-grid {
        gap: 10px;
    }

    .file-body strong,
    .link-item strong {
        font-size: 12px;
    }
}

/* Left sidebar dark mode only */
.sidebar {
    background: #0f172a;
    border-right-color: #1e293b;
    color: #e5e7eb;
}

.sidebar-top {
    background: #0f172a;
    border-bottom: 1px solid #1e293b;
}

.sidebar .brand-name {
    color: #ffffff;
}

.sidebar .brand-mark {
    background: #1266f1;
    color: #ffffff;
}

.sidebar .sidebar-nav {
    background: #0f172a;
}

.sidebar .nav-section-title {
    color: #64748b;
}

.sidebar .nav-link,
.sidebar .nav-child,
.sidebar .nav-grandchild {
    color: #94a3b8;
    background: transparent;
}

.sidebar .nav-icon {
    color: #64748b;
}

.sidebar .nav-link:hover,
.sidebar .nav-child:hover,
.sidebar .nav-grandchild:hover,
.sidebar .nav-link.is-active,
.sidebar .nav-child.is-active {
    background: #1e293b;
    color: #ffffff;
}

.sidebar .nav-link:hover .nav-icon,
.sidebar .nav-link.is-active .nav-icon {
    color: #ffffff;
}

.sidebar .nav-chevron {
    color: #94a3b8;
}

.sidebar .upgrade-card {
    background: #111c31;
    border-color: #273449;
}

.sidebar .upgrade-card strong {
    color: #ffffff;
}

.sidebar .upgrade-card span {
    color: #94a3b8;
}

.sidebar .manage-plan {
    background: #1266f1;
    border-color: #1266f1;
    color: #ffffff;
}

.sidebar .manage-plan:hover {
    background: #0f57d6;
    border-color: #0f57d6;
}

.sidebar .sidebar-mobile-close {
    background: #111c31;
    border-color: #273449;
    color: #ffffff;
}

.sidebar .css-icon.close-icon::before,
.sidebar .css-icon.close-icon::after {
    background: #ffffff;
}

.sidebar .sidebar-nav::-webkit-scrollbar-thumb {
    background: #334155;
}

@media (max-width: 920px) {
    .sidebar {
        background: #0f172a;
    }
}

/* Mobile sidebar upgrade card fix: keep the plan card fully visible inside the drawer. */
@media (max-width: 920px) {
    .sidebar {
        height: 100dvh;
        max-height: 100dvh;
        overflow: hidden;
    }

    .sidebar-top {
        flex: 0 0 70px;
    }

    .sidebar-nav {
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
        padding-bottom: 12px;
    }

    .sidebar .upgrade-card {
        width: calc(100% - 28px);
        max-width: calc(100% - 28px);
        margin: 10px 14px calc(14px + env(safe-area-inset-bottom, 0px));
        padding: 12px;
        grid-template-columns: 40px minmax(0, 1fr);
        gap: 8px 10px;
        overflow: visible;
    }

    .sidebar .upgrade-card > div:not(.upgrade-icon) {
        display: block;
        min-width: 0;
        overflow: visible;
    }

    .sidebar .upgrade-card strong,
    .sidebar .upgrade-card span {
        max-width: 100%;
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
        word-break: normal;
    }

    .sidebar .manage-plan {
        width: 100%;
        min-width: 0;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        white-space: nowrap;
        overflow: visible;
    }

    .sidebar .manage-plan span {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex: 0 0 auto;
    }
}

@media (max-width: 360px) {
    .sidebar {
        width: min(270px, 90vw);
    }

    .sidebar .upgrade-card {
        width: calc(100% - 20px);
        max-width: calc(100% - 20px);
        margin-left: 10px;
        margin-right: 10px;
        padding: 10px;
        grid-template-columns: 36px minmax(0, 1fr);
    }

    .sidebar .upgrade-icon {
        width: 34px;
        height: 34px;
    }

    .sidebar .manage-plan {
        height: 34px;
        font-size: 11px;
    }
}

/* Android/mobile bottom navigation safe-area fix.
   Keeps the type bar buttons above the 3-button Android navigation area and uses the real visible viewport height. */
:root {
    --app-height: 100vh;
}

@supports (height: 100dvh) {
    :root {
        --app-height: 100dvh;
    }
}

@media (max-width: 760px) {
    html,
    body {
        height: var(--app-height);
        min-height: var(--app-height);
    }

    .app,
    .chat-panel {
        height: var(--app-height);
        min-height: var(--app-height);
        max-height: var(--app-height);
    }

    .chat-panel {
        overflow: hidden;
    }

    .chat-body {
        padding-bottom: 22px;
    }

    .chat-input-bar {
        height: auto;
        min-height: calc(74px + env(safe-area-inset-bottom, 0px));
        padding: 10px 10px calc(18px + env(safe-area-inset-bottom, 0px));
        align-items: center;
        position: relative;
        z-index: 6;
        background: #ffffff;
    }

    .chat-input-wrap,
    .chat-input-bar .input-action,
    .chat-input-bar .send-button,
    .chat-input-bar .input-mini {
        flex-shrink: 0;
    }
}

@media (max-width: 430px) {
    .chat-input-bar {
        min-height: calc(74px + env(safe-area-inset-bottom, 0px));
        padding-left: 8px;
        padding-right: 8px;
        padding-bottom: calc(18px + env(safe-area-inset-bottom, 0px));
    }
}

@media (max-width: 360px) {
    .chat-input-bar {
        grid-template-columns: minmax(0, 1fr) 26px 26px 26px 34px;
        gap: 4px;
        padding-left: 6px;
        padding-right: 6px;
    }

    .chat-input-bar .input-action {
        width: 26px;
        height: 26px;
    }

    .send-button {
        width: 34px;
        height: 34px;
    }
}

/* AI Auto Reply feature modal */
.ai-feature-modal {
    padding: 20px;
}

.ai-feature-card {
    width: min(900px, calc(100vw - 34px));
    max-height: min(760px, calc(100dvh - 34px));
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.ai-feature-head {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 22px 24px 18px;
    border-bottom: 1px solid #e8eaf0;
    background: #ffffff;
}

.ai-feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #1266f1;
    color: #ffffff;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .04em;
    flex: 0 0 auto;
}

.ai-feature-head h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 860;
    letter-spacing: -.03em;
}

.ai-feature-head p {
    margin: 5px 42px 0 0;
    color: #667085;
    font-size: 13px;
    line-height: 1.45;
}

.ai-feature-body {
    padding: 22px 24px 24px;
    overflow-y: auto;
    background: #f8fafc;
}

.ai-feature-toast {
    position: absolute;
    top: 18px;
    right: 56px;
    z-index: 2;
    padding: 8px 11px;
    border-radius: 999px;
    background: #101828;
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
}

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

.feature-stat,
.feature-section-card,
.feature-list-card,
.feature-rule-row,
.feature-channel-card,
.feature-log-card,
.feature-ticket-card,
.feature-settings-form {
    background: #ffffff;
    border: 1px solid #e8eaf0;
    border-radius: 16px;
}

.feature-stat {
    padding: 16px;
    display: grid;
    gap: 7px;
}

.feature-stat span,
.feature-list-top span,
.feature-log-head span,
.feature-ticket-footer span,
.feature-channel-card p,
.feature-stat em,
.feature-log-meta span {
    color: #667085;
    font-size: 12px;
    font-style: normal;
    font-weight: 650;
}

.feature-stat strong {
    color: #101828;
    font-size: 26px;
    line-height: 1;
    font-weight: 880;
    letter-spacing: -.04em;
}

.feature-section-card {
    padding: 18px;
}

.feature-section-head,
.feature-list-top,
.feature-log-head,
.feature-ticket-footer,
.feature-toolbar,
.feature-channel-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.feature-section-head h3,
.feature-list-card h3,
.feature-rule-row h3,
.feature-channel-card h3,
.feature-ticket-card h3 {
    margin: 0;
    color: #101828;
    font-size: 15px;
    font-weight: 840;
    letter-spacing: -.02em;
}

.feature-section-card p,
.feature-list-card p,
.feature-rule-row p,
.feature-log-card p,
.feature-ticket-card p {
    margin: 8px 0 0;
    color: #667085;
    font-size: 13px;
    line-height: 1.5;
}

.feature-action-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.feature-soft-btn,
.feature-primary-btn,
.feature-ticket-footer button {
    height: 36px;
    border-radius: 10px;
    padding: 0 13px;
    font-size: 12px;
    font-weight: 800;
    border: 1px solid #e8eaf0;
    background: #ffffff;
    color: #344054;
    transition: background .2s ease, border-color .2s ease, color .2s ease;
}

.feature-soft-btn:hover,
.feature-ticket-footer button:hover {
    background: #f5f6f8;
    border-color: #d9deea;
}

.feature-primary-btn {
    background: #1266f1;
    border-color: #1266f1;
    color: #ffffff;
}

.feature-primary-btn:hover {
    background: #0f57d6;
    border-color: #0f57d6;
}

.feature-toggle {
    height: 32px;
    min-width: 92px;
    border-radius: 999px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    background: #f1f3f6;
    color: #667085;
    font-size: 11px;
    font-weight: 850;
    white-space: nowrap;
}

.feature-toggle span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #98a2b3;
}

.feature-toggle.is-on {
    background: rgba(18, 102, 241, .1);
    color: #1266f1;
}

.feature-toggle.is-on span {
    background: #1266f1;
}

.feature-toolbar {
    margin-bottom: 14px;
}

.feature-toolbar input,
.feature-setting-row input {
    height: 40px;
    border-radius: 12px;
    border: 1px solid #e8eaf0;
    background: #ffffff;
    outline: 0;
    padding: 0 12px;
    color: #101828;
    font-size: 13px;
}

.feature-toolbar input {
    flex: 1 1 auto;
    min-width: 0;
}

.feature-list,
.feature-log-list {
    display: grid;
    gap: 12px;
}

.feature-list-card,
.feature-rule-row,
.feature-log-card,
.feature-ticket-card {
    padding: 15px;
}

.feature-list-card time {
    display: inline-block;
    margin-top: 10px;
    color: #98a2b3;
    font-size: 11px;
    font-weight: 700;
}

.feature-status {
    display: inline-flex;
    align-items: center;
    height: 23px;
    border-radius: 999px;
    padding: 0 9px;
    background: #eef4ff;
    color: #1266f1;
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .035em;
}

.feature-status.status-draft,
.feature-status.status-disabled,
.feature-status.status-not-connected,
.feature-status.status-pending,
.feature-status.status-medium {
    background: #fff7ed;
    color: #f97316;
}

.feature-status.status-handover,
.feature-status.status-high,
.feature-status.status-failed {
    background: #fef2f2;
    color: #ef4444;
}

.feature-status.status-connected,
.feature-status.status-enabled,
.feature-status.status-active,
.feature-status.status-answered,
.feature-status.status-low {
    background: #ecfdf3;
    color: #12b76a;
}

.feature-rule-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 16px;
}

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

.feature-channel-card {
    padding: 15px;
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 12px;
    position: relative;
}

.feature-channel-icon {
    width: 42px;
    height: 42px;
    border-radius: 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f1f3f6;
    color: #101828;
    font-size: 12px;
    font-weight: 900;
}

.feature-channel-card .feature-toggle {
    grid-column: 1 / -1;
    justify-self: start;
}

.feature-channel-meta {
    justify-content: flex-start;
    flex-wrap: wrap;
    margin-top: 10px;
}

.feature-log-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin: 9px 0;
}

.feature-ticket-card.is-resolved {
    opacity: .65;
}

.feature-ticket-footer {
    margin-top: 13px;
}

.feature-ticket-footer button:disabled {
    cursor: default;
    background: #ecfdf3;
    border-color: #d1fadf;
    color: #12b76a;
}

.feature-settings-form {
    padding: 16px;
}

.feature-setting-row {
    display: grid;
    gap: 8px;
    margin-bottom: 13px;
}

.feature-setting-row span {
    color: #344054;
    font-size: 12px;
    font-weight: 800;
}

@media (max-width: 760px) {
    .ai-feature-modal {
        padding: 0;
    }

    .ai-feature-card {
        width: 100vw;
        height: var(--app-height);
        max-height: var(--app-height);
        border-radius: 0;
        border-left: 0;
        border-right: 0;
    }

    .ai-feature-head {
        padding: 18px 18px 14px;
    }

    .ai-feature-head p {
        margin-right: 34px;
    }

    .ai-feature-body {
        padding: 16px;
    }

    .feature-stat-grid,
    .feature-channel-grid {
        grid-template-columns: 1fr;
    }

    .feature-toolbar,
    .feature-rule-row {
        display: grid;
        grid-template-columns: 1fr;
    }

    .feature-primary-btn,
    .feature-soft-btn,
    .feature-ticket-footer button {
        width: 100%;
    }
}

/* Dedicated PHP AI pages - no popup/modal */
.ai-app {
    grid-template-columns: clamp(230px, 12vw, 285px) minmax(0, 1fr) !important;
    background: #f4f6fb;
}

.ai-main {
    height: 100vh;
    min-width: 0;
    overflow-y: auto;
    background: #f4f6fb;
    padding: clamp(18px, 1.4vw, 30px);
    position: relative;
}

.ai-page-shell {
    width: 100%;
    display: grid;
    gap: 16px;
}

.ai-page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 22px;
    border: 1px solid #e8eaf0;
    border-radius: 18px;
    background: #ffffff;
}

.ai-kicker {
    display: inline-flex;
    align-items: center;
    height: 24px;
    padding: 0 10px;
    margin-bottom: 12px;
    border-radius: 999px;
    background: rgba(18, 102, 241, .1);
    color: #1266f1;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.ai-page-header h1 {
    margin: 0;
    color: #101828;
    font-size: clamp(24px, 1.7vw, 34px);
    line-height: 1.05;
    font-weight: 880;
    letter-spacing: -.045em;
}

.ai-page-header p {
    max-width: 760px;
    margin: 9px 0 0;
    color: #667085;
    font-size: 14px;
    line-height: 1.55;
}

.ai-header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 9px;
    flex: 0 0 auto;
}

.ai-dashboard-grid,
.ai-two-column,
.ai-handover-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(300px, .85fr);
    gap: 16px;
    align-items: start;
}

.ai-large-card {
    min-height: 318px;
}

.ai-bars {
    height: 220px;
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    align-items: end;
    gap: 12px;
    margin-top: 26px;
    padding: 10px 4px 0;
}

.ai-bar-item {
    height: 100%;
    display: grid;
    align-items: end;
    gap: 9px;
    text-align: center;
}

.ai-bar-item span {
    display: block;
    width: 100%;
    min-height: 18px;
    border-radius: 13px 13px 6px 6px;
    background: linear-gradient(180deg, #1266f1, #dce9ff);
}

.ai-bar-item em {
    color: #667085;
    font-size: 11px;
    font-style: normal;
    font-weight: 800;
}

.compact-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.ai-side-form h3,
.ai-connect-panel h3 {
    margin: 0;
    color: #101828;
    font-size: 16px;
    font-weight: 860;
    letter-spacing: -.02em;
}

.ai-side-form form {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.ai-side-form label,
.ai-settings-page label {
    display: grid;
    gap: 8px;
    color: #344054;
    font-size: 12px;
    font-weight: 800;
}

.ai-side-form input,
.ai-side-form select,
.ai-side-form textarea,
.ai-settings-page input,
.ai-settings-page textarea,
.feature-toolbar select {
    width: 100%;
    min-width: 0;
    border: 1px solid #e8eaf0;
    border-radius: 12px;
    background: #ffffff;
    color: #101828;
    outline: 0;
    font-size: 13px;
}

.ai-side-form input,
.ai-side-form select,
.ai-settings-page input,
.feature-toolbar select {
    height: 40px;
    padding: 0 12px;
}

.ai-side-form textarea,
.ai-settings-page textarea {
    min-height: 110px;
    resize: vertical;
    padding: 11px 12px;
    font-family: inherit;
    line-height: 1.45;
}

.feature-soft-link {
    display: inline-flex;
    align-items: center;
    height: 34px;
    padding: 0 12px;
    border-radius: 10px;
    border: 1px solid #e8eaf0;
    color: #344054;
    font-size: 12px;
    font-weight: 800;
}

.ai-connect-panel,
.ai-settings-page {
    margin-top: 16px;
}

.ai-note-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 16px;
}

.ai-note-grid span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    border: 1px solid #e8eaf0;
    border-radius: 14px;
    background: #f8fafc;
    color: #344054;
    font-size: 12px;
    font-weight: 800;
    text-align: center;
}

.ai-settings-page form {
    display: grid;
    gap: 4px;
}

.feature-setting-row.textarea-row {
    align-items: start;
}

.ai-settings-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 8px;
}

.ai-toast {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 70;
    padding: 10px 13px;
    border-radius: 999px;
    background: #101828;
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
}

.ai-mobile-topbar {
    display: none;
}

@media (min-width: 1600px) {
    .ai-main {
        padding: 32px;
    }

    .ai-page-shell {
        gap: 18px;
    }

    .feature-stat-grid,
    .feature-channel-grid {
        gap: 16px;
    }
}

@media (max-width: 1180px) {
    .ai-dashboard-grid,
    .ai-two-column,
    .ai-handover-layout,
    .compact-list,
    .ai-note-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1024px) {
    .ai-app {
        grid-template-columns: 72px minmax(0, 1fr) !important;
    }
}

@media (max-width: 760px) {
    .ai-app {
        grid-template-columns: 1fr !important;
        height: var(--app-height);
        min-height: var(--app-height);
    }

    .ai-main {
        height: var(--app-height);
        min-height: var(--app-height);
        max-height: var(--app-height);
        padding: 12px 12px calc(18px + env(safe-area-inset-bottom));
    }

    .ai-mobile-topbar {
        position: sticky;
        top: 0;
        z-index: 10;
        display: grid;
        grid-template-columns: 40px minmax(0, 1fr) auto;
        align-items: center;
        gap: 10px;
        margin: -12px -12px 12px;
        padding: calc(10px + env(safe-area-inset-top)) 12px 10px;
        border-bottom: 1px solid #e8eaf0;
        background: rgba(255, 255, 255, .96);
    }

    .ai-mobile-topbar strong {
        color: #101828;
        font-size: 14px;
        font-weight: 900;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .ai-mobile-topbar span:last-child {
        color: #667085;
        font-size: 12px;
        font-weight: 800;
        white-space: nowrap;
    }

    .ai-page-header {
        display: grid;
        padding: 18px;
        border-radius: 16px;
    }

    .ai-header-actions,
    .ai-settings-actions {
        width: 100%;
        display: grid;
        grid-template-columns: 1fr;
    }

    .ai-page-header h1 {
        font-size: 25px;
    }

    .ai-bars {
        height: 180px;
        gap: 8px;
    }

    .feature-channel-card,
    .feature-rule-row {
        grid-template-columns: 1fr;
    }

    .feature-toolbar {
        grid-template-columns: 1fr;
    }

    .feature-toolbar select,
    .feature-toolbar input {
        width: 100%;
    }

    .ai-toast {
        left: 12px;
        right: 12px;
        bottom: calc(12px + env(safe-area-inset-bottom));
        text-align: center;
    }
}
