@charset "UTF-8";

:root {
    --primary: #635bdf;
    --primary-dark: #5149c7;
    --primary-soft: #efedff;
    --ink: #24263b;
    --ink-soft: #4c5068;
    --muted: #9295a8;
    --line: #e9eaf1;
    --surface: #fff;
    --canvas: #f6f7fb;
    --green: #24b99a;
    --orange: #f0a44a;
    --red: #ec6a70;
    --sidebar: #1b1c30;
    --shadow: 0 8px 30px rgba(34, 36, 64, .06);
}

* { box-sizing: border-box; }
html { height: 100%; }
body { margin: 0; color: var(--ink); font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif; font-size: 14px; -webkit-font-smoothing: antialiased; }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
svg { display: block; flex-shrink: 0; }
input, textarea, select { color: var(--ink); outline: none; }
input::placeholder, textarea::placeholder { color: #b0b2c0; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid rgba(99, 91, 223, .2); outline-offset: 2px; }
[hidden] { display: none !important; }

/* Application frame */
.admin-body { background: var(--canvas); min-height: 100%; overflow-x: hidden; }
.app-shell { min-height: 100vh; }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 40; width: 224px; display: flex; flex-direction: column; color: #d8d9e6; background: var(--sidebar); border-right: 1px solid rgba(255,255,255,.03); }
.brand { height: 76px; padding: 0 25px; display: flex; align-items: center; gap: 12px; }
.brand-mark, .widget-brand-mark { position: relative; width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; gap: 3px; border-radius: 11px; background: linear-gradient(145deg, #7b72ee, #574ed2); box-shadow: 0 6px 16px rgba(99,91,223,.28); transform: rotate(-3deg); }
.brand-mark:after, .widget-brand-mark:after { content: ""; position: absolute; bottom: -3px; left: 6px; border-width: 5px 5px 0 0; border-style: solid; border-color: #655cda transparent transparent transparent; }
.brand-mark span, .widget-brand-mark span { width: 4px; height: 4px; border-radius: 50%; background: white; }
.brand-name { display: flex; align-items: baseline; gap: 7px; color: white; font-size: 20px; font-weight: 700; letter-spacing: 1px; }
.brand-name > span { color: #777a92; font-size: 8px; letter-spacing: 1.1px; font-weight: 600; }
.workspace-switch { margin: 5px 15px 22px; padding: 11px 10px; display: flex; align-items: center; gap: 9px; background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.055); border-radius: 10px; }
.workspace-logo { width: 31px; height: 31px; display: grid; place-items: center; flex-shrink: 0; color: #d8d5ff; background: rgba(113,103,221,.2); border-radius: 8px; font-weight: 600; }
.workspace-switch > span:nth-child(2) { min-width: 0; flex: 1; }
.workspace-switch strong, .workspace-switch small { display: block; }
.workspace-switch strong { color: #eeeef5; font-size: 12px; font-weight: 500; }
.workspace-switch small { margin-top: 4px; color: #777a90; font-size: 10px; }
.workspace-switch svg { color: #74778d; }
.main-nav { padding: 0 13px; }
.nav-label { margin: 0 12px 9px; color: #65687e; font-size: 10px; letter-spacing: 1px; }
.nav-label-spaced { margin-top: 25px; }
.nav-item { position: relative; height: 43px; margin: 3px 0; padding: 0 13px; display: flex; align-items: center; gap: 12px; color: #9497ab; border-radius: 9px; font-size: 13px; transition: .18s ease; }
.nav-item:hover { color: #eeeef7; background: rgba(255,255,255,.04); }
.nav-item.active { color: #fff; background: linear-gradient(90deg, rgba(106,96,222,.28), rgba(106,96,222,.13)); }
.nav-item.active:before { content: ""; position: absolute; left: -13px; width: 3px; height: 22px; border-radius: 0 4px 4px 0; background: #8c83f3; }
.nav-item.active svg { color: #a69ffa; }
.nav-item span:nth-child(2) { flex: 1; }
.nav-count { min-width: 19px; height: 19px; padding: 0 5px; display: grid; place-items: center; color: #d6d2ff; background: rgba(125,114,230,.23); border-radius: 6px; font-size: 10px; }
.nav-count:empty { display: none; }
.sidebar-bottom { margin-top: auto; padding: 15px; }
.help-card { padding: 15px; background: linear-gradient(145deg, rgba(105,96,211,.15), rgba(255,255,255,.035)); border: 1px solid rgba(143,134,230,.12); border-radius: 12px; }
.help-card-icon { width: 34px; height: 34px; margin-bottom: 11px; display: grid; place-items: center; color: #b6affb; background: rgba(130,119,230,.14); border-radius: 9px; }
.help-card strong { color: #e8e8f1; font-size: 12px; font-weight: 500; }
.help-card p { margin: 7px 0 11px; color: #7f8298; font-size: 10px; line-height: 1.6; }
.help-card a { color: #a69df5; font-size: 11px; }
.help-card a span { margin-left: 5px; }
.agent-profile { width: 100%; margin-top: 14px; padding: 10px 4px 2px; display: flex; align-items: center; gap: 10px; color: inherit; background: none; border: 0; border-top: 1px solid rgba(255,255,255,.06); text-align: left; }
.avatar { position: relative; width: 40px; height: 40px; display: inline-grid; place-items: center; flex-shrink: 0; border-radius: 50%; color: #54506f; background: #e7e3f6; font-size: 13px; font-weight: 600; }
.avatar-agent { color: #e5e2ff; background: linear-gradient(145deg, #746bdd, #544bb8); }
.presence { position: absolute; right: -1px; bottom: 0; width: 10px; height: 10px; border: 2px solid var(--sidebar); border-radius: 50%; background: #85889a; }
.presence.online { background: var(--green); }
.presence.busy { background: var(--orange); }
.agent-profile-copy { flex: 1; }
.agent-profile-copy strong, .agent-profile-copy small { display: block; }
.agent-profile-copy strong { color: #e8e8f0; font-size: 12px; font-weight: 500; }
.agent-profile-copy small { margin-top: 4px; color: #797c91; font-size: 10px; }
.profile-more { color: #6e7187; letter-spacing: 1px; }
.main-shell { min-height: 100vh; margin-left: 224px; }
.topbar { position: relative; z-index: 20; height: 68px; padding: 0 30px; display: flex; align-items: center; justify-content: space-between; background: rgba(255,255,255,.95); border-bottom: 1px solid var(--line); }
.topbar-left, .topbar-actions { display: flex; align-items: center; }
.breadcrumb { display: flex; align-items: center; gap: 11px; font-size: 12px; }
.breadcrumb span { color: #a2a5b4; }
.breadcrumb b { color: #d0d1da; font-weight: 400; }
.breadcrumb strong { color: var(--ink-soft); font-weight: 500; }
.topbar-actions { gap: 9px; }
.global-search { width: 235px; height: 35px; padding: 0 10px; display: flex; align-items: center; gap: 8px; color: #a0a3b4; background: #f7f7fa; border: 1px solid #ededf2; border-radius: 8px; }
.global-search input { width: 100%; min-width: 0; background: transparent; border: 0; font-size: 11px; }
.global-search kbd { padding: 2px 5px; color: #a8aab8; background: white; border: 1px solid #e5e5eb; border-radius: 4px; font-family: inherit; font-size: 9px; white-space: nowrap; }
.preview-button { height: 35px; padding: 0 12px; display: flex; align-items: center; gap: 7px; color: #6259c7; background: #f2f0ff; border-radius: 8px; font-size: 11px; font-weight: 500; }
.preview-button:hover { background: #e9e5ff; }
.icon-button { width: 35px; height: 35px; display: inline-grid; place-items: center; color: #8f92a3; background: transparent; border: 0; border-radius: 8px; }
.icon-button:hover { color: var(--primary); background: #f3f2fa; }
.notification-button { position: relative; }
.notification-button > span { position: absolute; top: 7px; right: 8px; width: 6px; height: 6px; background: #f17379; border: 1.5px solid white; border-radius: 50%; }
.mobile-menu { display: none; margin-right: 7px; }
.sidebar-overlay { display: none; }
.page-content { max-width: 1580px; margin: 0 auto; padding: 29px 30px 40px; }
.page-loading { min-height: 60vh; display: grid; place-content: center; justify-items: center; color: var(--muted); }
.loading-spinner { width: 28px; height: 28px; border: 3px solid #e4e2f6; border-top-color: var(--primary); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Shared content */
.page-heading { margin-bottom: 25px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.page-heading h1 { margin: 0 0 7px; color: #24263b; font-size: 23px; line-height: 1.35; font-weight: 650; letter-spacing: -.5px; }
.page-heading p { margin: 0; color: #9699aa; font-size: 12px; }
.heading-date { display: flex; align-items: center; gap: 7px; color: #898c9d; font-size: 11px; }
.heading-date svg { color: #a4a6b5; }
.button { min-height: 37px; padding: 0 15px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; color: var(--ink-soft); background: white; border: 1px solid var(--line); border-radius: 8px; font-size: 12px; font-weight: 500; transition: .18s ease; }
.button:hover { border-color: #d3d0ec; background: #faf9ff; }
.button-primary { color: white; background: var(--primary); border-color: var(--primary); box-shadow: 0 4px 10px rgba(99,91,223,.15); }
.button-primary:hover { color: white; background: var(--primary-dark); border-color: var(--primary-dark); }
.button-danger { color: #d45e64; }
.button-small { min-height: 31px; padding: 0 11px; font-size: 11px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 13px; box-shadow: 0 2px 4px rgba(32,35,60,.012); }
.card-header { padding: 19px 21px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.card-title h2, .card-title h3 { margin: 0; font-size: 14px; font-weight: 600; }
.card-title p { margin: 6px 0 0; color: var(--muted); font-size: 10px; }
.text-link { display: inline-flex; align-items: center; gap: 4px; color: #7d75d4; font-size: 11px; }
.text-link:hover { color: var(--primary-dark); }
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 4px 8px; color: #6d7184; background: #f4f4f8; border-radius: 5px; font-size: 10px; white-space: nowrap; }
.badge:before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: #9a9dad; }
.badge.active { color: #6b61c8; background: #efedff; }
.badge.active:before { background: #756bdd; }
.badge.waiting { color: #ce8733; background: #fff5e8; }
.badge.waiting:before { background: #eaa54e; }
.badge.resolved { color: #5b9c8d; background: #edf8f4; }
.badge.resolved:before { background: #55b89e; }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #a2a5b3; }
.dot.online { background: var(--green); }
.dot.busy { background: var(--orange); }
.dot.offline { background: #b8bac5; }

/* Dashboard */
.stats-grid { margin-bottom: 20px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stat-card { position: relative; padding: 19px 20px 17px; overflow: hidden; }
.stat-top { display: flex; align-items: center; justify-content: space-between; }
.stat-label { color: #85899b; font-size: 11px; }
.stat-icon { width: 33px; height: 33px; display: grid; place-items: center; color: #746bdb; background: #f0eeff; border-radius: 9px; }
.stat-icon.green { color: #35a991; background: #edf9f5; }
.stat-icon.orange { color: #d89843; background: #fff5e9; }
.stat-icon.blue { color: #5894c8; background: #eef6fc; }
.stat-value { margin-top: 4px; display: flex; align-items: baseline; gap: 5px; font-size: 30px; line-height: 1.25; font-weight: 650; letter-spacing: -1px; }
.stat-value small { color: #8b8e9e; font-size: 12px; font-weight: 400; letter-spacing: 0; }
.stat-foot { margin-top: 8px; display: flex; align-items: center; gap: 5px; color: #a0a3b1; font-size: 10px; }
.stat-change { color: #32a88e; font-weight: 500; }
.stat-change.neutral { color: #858899; }
.stat-live { color: #3cac91; }
.dashboard-charts { margin-bottom: 20px; display: grid; grid-template-columns: minmax(0, 1.85fr) minmax(280px, .85fr); gap: 16px; }
.range-select { height: 29px; padding: 0 8px; color: #858899; background: #fafafd; border: 1px solid var(--line); border-radius: 6px; font-size: 10px; }
.trend-chart { position: relative; height: 238px; padding: 4px 20px 15px 12px; }
.trend-chart svg { width: 100%; height: 100%; overflow: visible; }
.chart-grid { stroke: #f0f0f5; stroke-width: 1; }
.chart-axis-label { fill: #a0a3b1; font-size: 10px; font-family: inherit; font-variant-numeric: tabular-nums; }
.chart-line { fill: none; stroke: var(--primary); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.chart-area { fill: url(#area-gradient); }
.chart-dot { fill: var(--primary); stroke: white; stroke-width: 2; }
.chart-crosshair { stroke: #c5c1e8; stroke-width: 1; pointer-events: none; }
.chart-hit { fill: transparent; cursor: crosshair; }
.chart-tooltip { position: absolute; z-index: 4; min-width: 100px; padding: 9px 11px; color: white; background: #2c2e45; border-radius: 8px; box-shadow: 0 6px 18px rgba(30,32,55,.15); pointer-events: none; transform: translate(-50%, -110%); font-size: 10px; }
.chart-tooltip strong { display: block; margin-bottom: 3px; font-size: 16px; font-weight: 600; }
.chart-tooltip span { color: #bfc1d2; }
.chart-data-table { width: calc(100% - 40px); margin: 0 20px 18px; border-collapse: collapse; font-size: 11px; }
.chart-data-table th, .chart-data-table td { padding: 7px; border-bottom: 1px solid var(--line); text-align: left; }
.channel-list { padding: 8px 22px 15px; }
.channel-total { margin-bottom: 22px; display: flex; align-items: baseline; gap: 7px; }
.channel-total strong { font-size: 27px; font-weight: 650; letter-spacing: -.5px; }
.channel-total span { color: var(--muted); font-size: 10px; }
.channel-row { margin: 17px 0; }
.channel-row-head { margin-bottom: 8px; display: flex; align-items: center; justify-content: space-between; font-size: 11px; }
.channel-row-head span:first-child { display: flex; align-items: center; gap: 8px; color: #686c7f; }
.channel-row-head strong { color: #686c7f; font-size: 10px; font-weight: 500; font-variant-numeric: tabular-nums; }
.channel-dot { width: 7px; height: 7px; border-radius: 2px; background: var(--primary); opacity: var(--channel-opacity, 1); }
.channel-track { height: 5px; overflow: hidden; background: #f1f1f6; border-radius: 5px; }
.channel-track span { display: block; width: var(--channel-width); height: 100%; background: var(--primary); border-radius: 5px; opacity: var(--channel-opacity, 1); transition: width .4s ease; }
.channel-note { margin: 15px 21px 18px; padding: 11px; display: flex; align-items: center; gap: 8px; color: #8b8e9e; background: #faf9ff; border-radius: 8px; font-size: 10px; line-height: 1.5; }
.channel-note svg { color: #8d84e5; }
.dashboard-bottom { display: grid; grid-template-columns: minmax(0, 1.85fr) minmax(280px, .85fr); gap: 16px; }
.recent-table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th { padding: 10px 18px; color: #a1a4b2; background: #fafafd; border-top: 1px solid #f0f0f4; border-bottom: 1px solid #f0f0f4; font-size: 10px; font-weight: 500; text-align: left; white-space: nowrap; }
.data-table td { padding: 13px 18px; color: #65697b; border-bottom: 1px solid #f2f2f6; font-size: 11px; vertical-align: middle; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr { transition: background .15s; }
.data-table tbody tr:hover { background: #fcfcff; }
.table-customer { display: flex; align-items: center; gap: 10px; }
.table-customer .avatar { width: 31px; height: 31px; font-size: 10px; }
.table-customer strong, .table-customer small { display: block; }
.table-customer strong { color: #414458; font-size: 11px; font-weight: 500; }
.table-customer small { max-width: 170px; margin-top: 4px; overflow: hidden; color: #a0a3b2; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.table-action { color: #8982d9; background: none; border: 0; font-size: 10px; }
.table-action:hover { color: var(--primary-dark); }
.team-mini-list { padding: 1px 20px 12px; }
.team-mini-item { padding: 11px 0; display: flex; align-items: center; gap: 10px; }
.team-mini-item .avatar { width: 34px; height: 34px; font-size: 11px; }
.team-mini-copy { flex: 1; }
.team-mini-copy strong { display: block; color: #4e5164; font-size: 11px; font-weight: 500; }
.team-mini-copy small { display: block; margin-top: 4px; color: #a0a3b2; font-size: 9px; }
.team-mini-meta { text-align: right; }
.team-mini-meta strong { display: block; font-size: 12px; font-weight: 500; }
.team-mini-meta small { color: #a1a4b2; font-size: 9px; }
.team-status { display: flex; align-items: center; gap: 5px; color: #9b9ead; font-size: 9px; }
.team-summary { margin: 5px 20px 17px; padding: 11px 12px; display: flex; align-items: center; justify-content: space-between; color: #8b8e9e; background: #f7f8fb; border-radius: 8px; font-size: 10px; }
.team-summary strong { color: #45a58f; font-weight: 500; }

/* Conversation workspace */
.page-content.conversation-page { max-width: none; height: calc(100vh - 68px); padding: 0; overflow: hidden; }
.inbox-grid { height: 100%; min-height: 0; display: grid; grid-template-columns: 294px minmax(400px, 1fr) 270px; grid-template-rows: minmax(0, 1fr); background: white; }
.conversation-sidebar { min-width: 0; display: flex; flex-direction: column; border-right: 1px solid var(--line); background: #fff; }
.inbox-heading { height: 69px; padding: 0 19px; display: flex; align-items: center; justify-content: space-between; }
.inbox-heading h1 { margin: 0; font-size: 17px; font-weight: 650; }
.inbox-heading .icon-button { color: #7e78ce; background: #f0eeff; }
.inbox-search { margin: 0 15px 11px; height: 35px; padding: 0 10px; display: flex; align-items: center; gap: 8px; color: #a5a8b7; background: #f7f7fa; border: 1px solid #eeeef3; border-radius: 8px; }
.inbox-search input { min-width: 0; width: 100%; background: transparent; border: 0; font-size: 11px; }
.inbox-tabs { padding: 0 15px 11px; display: flex; gap: 3px; border-bottom: 1px solid var(--line); }
.inbox-tab { position: relative; padding: 7px 9px 10px; color: #9598a8; background: none; border: 0; font-size: 10px; }
.inbox-tab.active { color: var(--primary); font-weight: 500; }
.inbox-tab.active:after { content: ""; position: absolute; right: 9px; bottom: -12px; left: 9px; height: 2px; background: var(--primary); border-radius: 2px; }
.inbox-tab span { margin-left: 3px; color: #aaa5d8; }
.session-list { flex: 1; overflow-y: auto; overscroll-behavior: contain; }
.session-item { position: relative; width: 100%; padding: 15px 14px; display: flex; align-items: flex-start; gap: 10px; color: inherit; background: transparent; border: 0; border-bottom: 1px solid #f2f2f6; text-align: left; transition: background .15s; }
.session-item:hover { background: #faf9ff; }
.session-item.selected { background: #f3f1ff; }
.session-item.selected:before { content: ""; position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--primary); }
.session-item .avatar { width: 39px; height: 39px; font-size: 12px; }
.session-item-copy { min-width: 0; flex: 1; }
.session-item-top { display: flex; align-items: center; justify-content: space-between; gap: 7px; }
.session-item-top strong { overflow: hidden; color: #414457; font-size: 11px; font-weight: 550; text-overflow: ellipsis; white-space: nowrap; }
.session-item-top time { color: #acadb9; font-size: 9px; white-space: nowrap; }
.session-preview { margin: 6px 0 8px; overflow: hidden; color: #9699a9; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.session-item.selected .session-preview { color: #807baf; }
.session-item-bottom { display: flex; align-items: center; justify-content: space-between; }
.session-channel { color: #aaacb9; font-size: 9px; }
.unread-count { min-width: 16px; height: 16px; padding: 0 4px; display: grid; place-items: center; color: white; background: #746ae0; border-radius: 8px; font-size: 9px; }
.priority-mark { width: 5px; height: 5px; margin-right: 4px; display: inline-block; border-radius: 50%; background: var(--orange); }
.priority-mark.urgent { background: var(--red); }
.chat-panel { min-width: 0; min-height: 0; display: flex; flex-direction: column; overflow: hidden; background: #fbfbfe; }
#composer-container { flex-shrink: 0; }
.chat-header { height: 69px; padding: 0 20px; display: flex; flex-shrink: 0; align-items: center; justify-content: space-between; gap: 12px; background: white; border-bottom: 1px solid var(--line); }
.chat-customer { min-width: 0; display: flex; align-items: center; gap: 11px; }
.chat-customer .avatar { width: 37px; height: 37px; font-size: 11px; }
.chat-customer h2 { margin: 0; font-size: 13px; font-weight: 600; }
.chat-customer p { margin: 5px 0 0; display: flex; align-items: center; gap: 5px; color: #9699a8; font-size: 9px; }
.chat-actions { display: flex; align-items: center; gap: 7px; }
.chat-actions .icon-button { width: 31px; height: 31px; border: 1px solid var(--line); }
.resolve-button { height: 31px; padding: 0 11px; display: flex; align-items: center; gap: 5px; color: #4b9c87; background: #eff9f5; border: 1px solid #e1f3ec; border-radius: 7px; font-size: 10px; }
.resolve-button.reopen { color: #746bd0; background: #f1efff; border-color: #e6e2ff; }
.mobile-back { display: none; }
.message-scroll { flex: 1; min-height: 0; padding: 20px 24px; overflow-y: auto; overscroll-behavior: contain; scroll-behavior: smooth; }
.chat-date-separator { margin: 6px 0 20px; display: flex; align-items: center; gap: 12px; color: #b0b2bf; font-size: 9px; }
.chat-date-separator:before, .chat-date-separator:after { content: ""; height: 1px; flex: 1; background: #eeeef3; }
.message-row { margin-bottom: 18px; display: flex; align-items: flex-start; gap: 9px; }
.message-row.mine { flex-direction: row-reverse; }
.message-row .avatar { width: 30px; height: 30px; margin-top: 2px; font-size: 9px; }
.message-content { max-width: min(74%, 540px); }
.message-meta { margin-bottom: 6px; display: flex; align-items: center; gap: 8px; color: #a2a5b3; font-size: 9px; }
.message-row.mine .message-meta { justify-content: flex-end; }
.message-meta strong { color: #8a8d9e; font-weight: 400; }
.message-bubble { padding: 10px 13px; color: #56596c; background: white; border: 1px solid #ececf2; border-radius: 3px 11px 11px 11px; box-shadow: 0 2px 4px rgba(37,39,66,.02); font-size: 11px; line-height: 1.75; white-space: pre-wrap; word-break: break-word; }
.message-row.mine .message-bubble { color: white; background: linear-gradient(135deg, #756ce2, #6259d4); border-color: transparent; border-radius: 11px 3px 11px 11px; box-shadow: 0 4px 12px rgba(99,91,223,.12); }
.message-image-link { display: block; width: fit-content; max-width: 100%; overflow: hidden; background: #eeeef3; border-radius: 10px; cursor: zoom-in; }
.message-image { display: block; width: auto; max-width: min(100%, 320px); max-height: 280px; object-fit: contain; }
.message-time { margin-top: 5px; color: #b0b2be; font-size: 8px; }
.message-row.mine .message-time { text-align: right; }
.typing-indicator { margin: 0 0 15px 39px; display: flex; align-items: center; gap: 6px; color: #a0a3b2; font-size: 9px; }
.typing-dots { display: flex; gap: 3px; }
.typing-dots i { width: 4px; height: 4px; background: #aaa4dd; border-radius: 50%; animation: typing 1s infinite alternate; }
.typing-dots i:nth-child(2) { animation-delay: .2s; }.typing-dots i:nth-child(3) { animation-delay: .4s; }
@keyframes typing { to { transform: translateY(-3px); opacity: .5; } }
.composer-wrap { position: relative; padding: 0 18px 16px; background: #fbfbfe; }
.composer { overflow: hidden; background: white; border: 1px solid #e4e3ec; border-radius: 10px; box-shadow: 0 3px 12px rgba(32,35,60,.025); }
.composer:focus-within { border-color: #b9b3eb; box-shadow: 0 0 0 3px rgba(99,91,223,.05); }
.composer textarea { width: 100%; height: 110px; padding: 12px 13px 4px; display: block; resize: none; background: transparent; border: 0; font-size: 11px; line-height: 1.7; }
.composer-toolbar { padding: 7px 9px; display: flex; align-items: center; justify-content: space-between; }
.composer-tools { display: flex; align-items: center; gap: 3px; }
.composer-tool { height: 28px; padding: 0 8px; display: flex; align-items: center; gap: 5px; color: #9699aa; background: transparent; border: 0; border-radius: 6px; font-size: 9px; }
.composer-tool:hover { color: var(--primary); background: #f2f0ff; }
.composer-tool:disabled { cursor: wait; opacity: .5; }
.send-button { height: 30px; padding: 0 13px; display: flex; align-items: center; gap: 6px; color: white; background: var(--primary); border: 0; border-radius: 7px; font-size: 10px; }
.send-button:disabled { cursor: not-allowed; opacity: .5; }
.composer-hint { margin: 6px 2px 0; display: flex; justify-content: space-between; color: #b1b3c0; font-size: 8px; }
.resolved-notice { margin: 0 18px 16px; padding: 13px 15px; display: flex; align-items: center; justify-content: space-between; gap: 12px; color: #7d8193; background: #f0f0f5; border-radius: 9px; font-size: 10px; }
.quick-reply-popover { position: absolute; z-index: 8; right: 18px; bottom: 120px; left: 18px; max-height: 280px; overflow-y: auto; background: white; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 10px 35px rgba(31,33,59,.13); }
.quick-reply-popover > header { padding: 12px 14px; display: flex; justify-content: space-between; border-bottom: 1px solid var(--line); font-size: 11px; font-weight: 600; }
.quick-reply-option { width: 100%; padding: 11px 14px; display: block; color: inherit; background: white; border: 0; border-bottom: 1px solid #f3f3f6; text-align: left; }
.quick-reply-option:hover { background: #faf9ff; }
.quick-reply-option strong { display: block; margin-bottom: 5px; color: #625bc0; font-size: 10px; font-weight: 500; }
.quick-reply-option span { display: block; overflow: hidden; color: #8d90a1; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.visitor-panel { min-width: 0; overflow-y: auto; background: white; border-left: 1px solid var(--line); }
.visitor-panel-header { height: 69px; padding: 0 19px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.visitor-panel-header h2 { margin: 0; font-size: 12px; font-weight: 600; }
.visitor-summary { padding: 20px 18px; text-align: center; border-bottom: 1px solid var(--line); }
.visitor-summary .avatar { width: 55px; height: 55px; margin-bottom: 10px; font-size: 17px; }
.visitor-summary h3 { margin: 0; font-size: 13px; font-weight: 600; }
.visitor-summary p { margin: 6px 0 10px; color: #a0a3b1; font-size: 9px; }
.visitor-tags { display: flex; justify-content: center; gap: 5px; }
.visitor-tag { padding: 3px 6px; color: #8a85b1; background: #f3f1fb; border-radius: 4px; font-size: 8px; }
.visitor-details { padding: 17px 18px; border-bottom: 1px solid var(--line); }
.detail-section-title { margin: 0 0 14px; display: flex; align-items: center; justify-content: space-between; color: #626678; font-size: 10px; font-weight: 600; }
.detail-section-title button { color: #aaa2dc; background: none; border: 0; font-size: 9px; }
.detail-row { margin: 11px 0; display: grid; grid-template-columns: 58px minmax(0,1fr); gap: 8px; font-size: 9px; line-height: 1.5; }
.detail-row dt { color: #aaacb9; }
.detail-row dd { margin: 0; overflow: hidden; color: #696d7f; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
.detail-control { width: 100%; height: 31px; margin-top: 5px; padding: 0 8px; color: #6b6e80; background: #fafafd; border: 1px solid var(--line); border-radius: 6px; font-size: 9px; }
.visitor-notes { padding: 17px 18px; }
.visitor-notes textarea { width: 100%; height: 74px; padding: 9px; resize: none; color: #777a8c; background: #fafafd; border: 1px solid var(--line); border-radius: 7px; font-size: 9px; line-height: 1.7; }
.notes-save { margin-top: 7px; float: right; color: #766dd0; background: none; border: 0; font-size: 9px; }
.no-session { height: 100%; display: grid; place-content: center; justify-items: center; color: #9b9eae; text-align: center; }
.no-session-icon { width: 62px; height: 62px; margin-bottom: 16px; display: grid; place-items: center; color: #9b93e8; background: #efedfc; border-radius: 20px; }
.no-session h2 { margin: 0 0 8px; color: #666a7c; font-size: 15px; }
.no-session p { margin: 0; font-size: 11px; }
.session-empty { padding: 45px 20px; color: #a4a6b4; font-size: 11px; text-align: center; }

/* Customers and team */
.summary-strip { margin-bottom: 18px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; }
.summary-strip .card { padding: 17px 20px; display: flex; align-items: center; gap: 13px; }
.summary-icon { width: 39px; height: 39px; display: grid; place-items: center; color: var(--primary); background: var(--primary-soft); border-radius: 10px; }
.summary-strip strong { display: block; font-size: 21px; font-weight: 650; }
.summary-strip small { color: var(--muted); font-size: 10px; }
.table-card { overflow: hidden; }
.table-toolbar { padding: 16px 19px; display: flex; align-items: center; justify-content: space-between; gap: 15px; }
.table-search { width: 240px; height: 34px; padding: 0 10px; display: flex; align-items: center; gap: 8px; color: #a0a3b2; background: #fafafd; border: 1px solid var(--line); border-radius: 7px; }
.table-search input { min-width: 0; width: 100%; background: none; border: 0; font-size: 10px; }
.table-filter { display: flex; align-items: center; gap: 8px; color: #9699a8; font-size: 10px; }
.customer-email { color: #8e91a1; }
.empty-table { padding: 60px !important; color: var(--muted) !important; text-align: center; }
.team-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 16px; }
.team-card { position: relative; padding: 24px 20px 18px; text-align: center; }
.team-card .avatar { width: 64px; height: 64px; margin-bottom: 13px; font-size: 20px; }
.team-card .presence { width: 13px; height: 13px; border-color: white; }
.team-card h3 { margin: 0 0 6px; font-size: 14px; font-weight: 600; }
.team-card > p { margin: 0; color: var(--muted); font-size: 10px; }
.team-card-quote { height: 32px; margin: 12px 0 16px !important; color: #a2a5b3 !important; font-size: 9px !important; }
.team-card-stats { padding: 13px 0; display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.team-card-stats > div:first-child { border-right: 1px solid var(--line); }
.team-card-stats strong, .team-card-stats small { display: block; }
.team-card-stats strong { font-size: 18px; font-weight: 600; }
.team-card-stats small { margin-top: 4px; color: var(--muted); font-size: 9px; }
.team-card-footer { margin-top: 14px; display: flex; align-items: center; justify-content: space-between; }
.team-card-footer .team-status { font-size: 10px; }
.status-select { color: #7f8192; background: transparent; border: 0; font-size: 9px; }

/* Settings */
.settings-layout { display: grid; grid-template-columns: 205px minmax(0, 760px); gap: 20px; align-items: start; }
.settings-nav { padding: 9px; }
.settings-nav button { width: 100%; padding: 11px 12px; display: flex; align-items: center; gap: 10px; color: #85889a; background: transparent; border: 0; border-radius: 7px; font-size: 11px; text-align: left; }
.settings-nav button.active { color: #655cd0; background: #efedff; font-weight: 500; }
.settings-nav button:hover:not(.active) { background: #f7f7fa; }
.settings-section { padding: 22px; }
.settings-section-heading { margin-bottom: 22px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.settings-section-heading h2 { margin: 0 0 6px; font-size: 15px; font-weight: 600; }
.settings-section-heading p { margin: 0; color: var(--muted); font-size: 10px; line-height: 1.6; }
.form-row { margin-bottom: 18px; display: grid; grid-template-columns: 145px minmax(0,1fr); gap: 20px; align-items: start; }
.form-label { padding-top: 9px; }
.form-label label, .form-label strong { display: block; color: #5a5e70; font-size: 11px; font-weight: 500; }
.form-label small { display: block; margin-top: 5px; color: #a2a5b3; font-size: 9px; line-height: 1.5; }
.form-control { width: 100%; min-height: 38px; padding: 9px 11px; background: #fff; border: 1px solid #e2e3eb; border-radius: 7px; font-size: 11px; transition: border .15s; }
.form-control:focus { border-color: #a9a2e7; box-shadow: 0 0 0 3px rgba(99,91,223,.05); }
textarea.form-control { resize: vertical; line-height: 1.7; }
.color-control { display: flex; align-items: center; gap: 8px; }
.color-control input[type=color] { width: 38px; height: 38px; padding: 3px; background: white; border: 1px solid var(--line); border-radius: 7px; }
.color-control input[type=text] { width: 110px; }
.settings-actions { padding-top: 17px; display: flex; justify-content: flex-end; border-top: 1px solid var(--line); }
.quick-reply-list { margin-bottom: 18px; }
.quick-reply-item { padding: 13px 0; display: flex; align-items: flex-start; gap: 12px; border-bottom: 1px solid var(--line); }
.quick-reply-item:first-child { padding-top: 0; }
.quick-reply-item > div { min-width: 0; flex: 1; }
.quick-reply-item strong { display: block; margin-bottom: 6px; color: #565a6e; font-size: 11px; font-weight: 500; }
.quick-reply-item p { margin: 0; color: #9396a6; font-size: 10px; line-height: 1.65; }
.quick-reply-item .icon-button { width: 28px; height: 28px; }
.switch-row { padding: 13px 0; display: flex; align-items: center; justify-content: space-between; gap: 15px; border-bottom: 1px solid var(--line); }
.switch-row strong { display: block; color: #5b5f71; font-size: 11px; font-weight: 500; }
.switch-row small { display: block; margin-top: 5px; color: #a0a3b1; font-size: 9px; }
.switch { position: relative; width: 36px; height: 20px; flex-shrink: 0; }
.switch input { position: absolute; opacity: 0; }
.switch span { position: absolute; inset: 0; background: #d9dae3; border-radius: 12px; transition: .2s; }
.switch span:after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; background: white; border-radius: 50%; box-shadow: 0 1px 3px rgba(0,0,0,.15); transition: .2s; }
.switch input:checked + span { background: var(--primary); }
.switch input:checked + span:after { transform: translateX(16px); }

/* Modal and feedback */
.toast-stack { position: fixed; z-index: 100; top: 82px; right: 22px; display: grid; gap: 9px; pointer-events: none; }
.toast { min-width: 240px; max-width: 360px; padding: 12px 15px; display: flex; align-items: center; gap: 9px; color: #525668; background: rgba(255,255,255,.98); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 10px 35px rgba(30,32,55,.12); font-size: 11px; animation: toast-in .25s ease both; }
.toast:before { content: "✓"; width: 20px; height: 20px; display: grid; place-items: center; color: white; background: var(--green); border-radius: 50%; font-size: 10px; }
.toast.error:before { content: "!"; background: var(--red); }
@keyframes toast-in { from { opacity: 0; transform: translateY(-8px); } }
.modal-backdrop { position: fixed; z-index: 90; inset: 0; padding: 20px; display: grid; place-items: center; background: rgba(25,26,46,.38); backdrop-filter: blur(3px); }
.modal { position: relative; width: min(470px, 100%); max-height: 90vh; padding: 25px; overflow-y: auto; background: white; border-radius: 15px; box-shadow: 0 24px 70px rgba(26,28,48,.2); }
.modal-close { position: absolute; top: 12px; right: 12px; font-size: 22px; }
.modal h2 { margin: 0 0 7px; font-size: 17px; }
.modal-subtitle { margin: 0 0 21px; color: var(--muted); font-size: 11px; line-height: 1.6; }
.modal-form label { margin: 13px 0 6px; display: block; color: #64687a; font-size: 10px; }
.modal-form .button { margin-top: 20px; width: 100%; }
.help-modal-list { margin: 18px 0 0; padding: 0; list-style: none; }
.help-modal-list li { padding: 12px 0; display: flex; gap: 11px; color: #74788a; border-bottom: 1px solid var(--line); font-size: 11px; line-height: 1.6; }
.help-modal-list span { color: var(--primary); font-weight: 600; }

/* Visitor website and chat widget */
.visitor-body { --widget-primary: #635bdf; min-height: 100vh; overflow-x: hidden; color: #252740; background: #fbfbfd; }
.demo-notice { height: 35px; display: flex; align-items: center; justify-content: center; gap: 9px; color: #77738e; background: #efedf9; font-size: 10px; }
.demo-notice > span { color: #aaa5c2; }
.demo-notice a { margin-left: 8px; color: #655dc3; font-weight: 500; }
.store-header { max-width: 1180px; height: 83px; margin: auto; padding: 0 30px; display: flex; align-items: center; justify-content: space-between; }
.store-logo { display: flex; align-items: center; gap: 9px; font-size: 17px; font-weight: 650; letter-spacing: 1px; }
.store-logo-mark { width: 30px; height: 30px; display: grid; place-items: center; color: white; background: #262941; border-radius: 9px 9px 9px 2px; font-size: 14px; font-weight: 600; }
.store-header nav { display: flex; gap: 35px; color: #74778a; font-size: 11px; }
.store-header nav a:hover { color: var(--widget-primary); }
.store-contact { padding: 9px 14px; display: flex; align-items: center; gap: 13px; color: #4f5265; background: transparent; border: 1px solid #e4e4eb; border-radius: 7px; font-size: 10px; }
.store-contact span { color: var(--widget-primary); }
.store-main { max-width: 1180px; min-height: 590px; margin: auto; padding: 75px 30px 0; position: relative; }
.store-hero { position: relative; z-index: 2; }
.hero-eyebrow { display: flex; align-items: center; gap: 8px; color: #7e77b8; font-size: 11px; letter-spacing: 2px; }
.hero-eyebrow span { width: 19px; height: 1px; background: #8a82cc; }
.store-hero h1 { margin: 20px 0; color: #272a42; font-size: clamp(34px, 4vw, 49px); line-height: 1.38; font-weight: 600; letter-spacing: 1px; }
.store-hero > p { color: #9698a8; font-size: 12px; line-height: 2; }
.hero-actions { margin-top: 30px; display: flex; align-items: center; gap: 24px; }
.hero-actions button { height: 43px; padding: 0 20px; display: flex; align-items: center; gap: 25px; color: white; background: var(--widget-primary); border: 0; border-radius: 8px; box-shadow: 0 8px 20px rgba(99,91,223,.18); font-size: 11px; }
.hero-actions a { color: #75788b; font-size: 11px; }
.hero-social-proof { margin-top: 42px; display: flex; align-items: center; gap: 12px; }
.proof-avatars { display: flex; padding-left: 7px; }
.proof-avatars span { width: 29px; height: 29px; margin-left: -7px; display: grid; place-items: center; color: #625d80; background: #e8e3f4; border: 2px solid #fbfbfd; border-radius: 50%; font-size: 9px; }
.proof-avatars span:nth-child(2) { background: #dfede9; }.proof-avatars span:nth-child(3) { background: #f1e5d9; }
.hero-social-proof p { margin: 0; color: #a0a2b0; font-size: 9px; line-height: 1.55; }
.hero-social-proof strong { color: #686b7d; font-size: 10px; font-weight: 500; }
.hero-art { position: absolute; top: 65px; right: 30px; width: 425px; height: 390px; }
.art-orbit { position: absolute; border: 1px solid #eeecf7; border-radius: 50%; }
.orbit-one { inset: 5px; }.orbit-two { inset: 52px; }
.hero-art:before { content: ""; position: absolute; inset: 83px; background: radial-gradient(circle, #eeebfb, transparent 70%); }
.art-card { position: absolute; display: flex; align-items: center; background: rgba(255,255,255,.88); border: 1px solid rgba(232,230,243,.9); box-shadow: 0 18px 50px rgba(58,51,107,.08); backdrop-filter: blur(8px); }
.art-card-main { top: 115px; left: 78px; width: 270px; height: 130px; padding: 24px; gap: 18px; border-radius: 20px; transform: rotate(-4deg); }
.art-avatar { width: 54px; height: 54px; display: grid; place-items: center; color: white; background: linear-gradient(145deg, #8880dd, #655cbf); border-radius: 17px; font-size: 19px; }
.art-card-main > div { flex: 1; }
.art-card-main i { height: 7px; margin: 9px 0; display: block; background: #eeedf5; border-radius: 5px; }
.art-card-main i:nth-child(2) { width: 75%; }.art-card-main i:nth-child(3) { width: 45%; }
.art-card-main b { position: absolute; right: -10px; top: -10px; width: 32px; height: 32px; display: grid; place-items: center; color: white; background: #6cc3ab; border: 4px solid #fbfbfd; border-radius: 50%; font-size: 11px; }
.art-card-small { right: 13px; bottom: 45px; padding: 14px 18px; gap: 10px; border-radius: 13px; transform: rotate(3deg); }
.art-card-small > span { font-size: 23px; }
.art-card-small strong, .art-card-small small { display: block; }
.art-card-small strong { color: #64667a; font-size: 10px; font-weight: 500; }.art-card-small small { margin-top: 5px; color: #a0a1af; font-size: 8px; }
.art-smile { position: absolute; top: 48px; right: 70px; color: #a29ad9; font-size: 33px; transform: rotate(15deg); }
.store-features { margin-top: 64px; padding: 27px 0; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid #ececf2; border-bottom: 1px solid #ececf2; }
.store-features article { padding: 0 27px; display: flex; align-items: center; gap: 17px; border-right: 1px solid #ececf2; }
.store-features article:first-child { padding-left: 0; }.store-features article:last-child { border: 0; }
.store-features article > span { color: #c3bde8; font-size: 20px; font-weight: 300; }
.store-features h3 { margin: 0 0 7px; color: #5a5d70; font-size: 11px; font-weight: 500; }.store-features p { margin: 0; color: #a0a2b0; font-size: 9px; }
.store-footer { max-width: 1180px; margin: 20px auto 0; padding: 0 30px 25px; display: flex; justify-content: space-between; color: #b0b1bd; font-size: 9px; }
.chat-launcher { position: fixed; z-index: 49; right: 28px; bottom: 27px; width: 57px; height: 57px; display: grid; place-items: center; color: white; background: var(--widget-primary); border: 0; border-radius: 18px 18px 18px 5px; box-shadow: 0 12px 30px rgba(86,76,190,.3); transition: transform .2s; }
.chat-launcher:hover { transform: translateY(-3px); }
.launcher-badge { position: absolute; top: -3px; right: -3px; width: 18px; height: 18px; display: grid; place-items: center; color: white; background: #f07379; border: 2px solid white; border-radius: 50%; font-size: 8px; }
.widget-window { position: fixed; z-index: 50; right: 28px; bottom: 96px; width: 365px; height: min(610px, calc(100vh - 135px)); display: flex; flex-direction: column; overflow: hidden; background: #f8f8fb; border: 1px solid rgba(225,224,236,.8); border-radius: 17px; box-shadow: 0 24px 70px rgba(36,34,68,.2); transform-origin: bottom right; animation: widget-in .25s ease both; }
.widget-window.minimized { display: none; }
@keyframes widget-in { from { opacity: 0; transform: translateY(15px) scale(.97); } }
.widget-header { position: relative; flex-shrink: 0; min-height: 155px; padding: 18px 19px; color: white; background: linear-gradient(135deg, var(--widget-primary), color-mix(in srgb, var(--widget-primary) 75%, #35304f)); }
.widget-return-link { position: absolute; z-index: 1; top: 17px; left: 15px; display: inline-flex; align-items: center; gap: 2px; padding: 4px 6px; color: rgba(255,255,255,.82); background: rgba(255,255,255,.08); border-radius: 5px; font-size: 8px; line-height: 1; text-decoration: none; }
.widget-return-link:hover { color: white; background: rgba(255,255,255,.16); }
.widget-brand-row { margin-top: 31px; display: flex; align-items: center; gap: 10px; }
.widget-brand-mark { width: 31px; height: 31px; background: rgba(255,255,255,.17); box-shadow: none; }
.widget-brand-mark:after { border-top-color: rgba(255,255,255,.17); }
.widget-brand-row strong, .widget-brand-row small { display: block; }
.widget-brand-row strong { font-size: 12px; font-weight: 550; }.widget-brand-row small { margin-top: 5px; display: flex; align-items: center; gap: 5px; color: rgba(255,255,255,.7); font-size: 8px; }
.widget-brand-row small i { width: 5px; height: 5px; background: #a9f2d9; border-radius: 50%; }
.widget-header-actions { position: absolute; top: 15px; right: 13px; display: flex; gap: 3px; }
.widget-header-actions button { width: 25px; height: 25px; display: grid; place-items: center; color: rgba(255,255,255,.75); background: transparent; border: 0; border-radius: 5px; font-size: 16px; }
.widget-header-actions button:hover { background: rgba(255,255,255,.12); }
.widget-welcome { margin-top: 20px; }
.widget-welcome p { margin: 0 0 7px; font-size: 13px; font-weight: 500; }.widget-welcome span { color: rgba(255,255,255,.66); font-size: 9px; line-height: 1.65; }
.widget-messages { flex: 1; min-height: 100px; padding: 17px 15px; overflow-y: auto; }
.widget-welcome-message { margin-bottom: 17px; display: flex; align-items: flex-start; gap: 8px; }
.widget-agent-avatar { width: 27px; height: 27px; display: grid; place-items: center; flex-shrink: 0; color: #6259ba; background: #e9e5ff; border-radius: 9px; font-size: 9px; }
.widget-bubble { max-width: 79%; padding: 9px 11px; color: #686b7d; background: white; border: 1px solid #ebebf1; border-radius: 3px 10px 10px 10px; font-size: 10px; line-height: 1.7; white-space: pre-wrap; word-break: break-word; }
.widget-message { margin-bottom: 13px; display: flex; flex-direction: column; align-items: flex-start; }
.widget-message.visitor { align-items: flex-end; }
.widget-message.visitor .widget-bubble { color: white; background: var(--widget-primary); border: 0; border-radius: 10px 3px 10px 10px; }
.widget-bubble.widget-image-bubble { width: min(220px, 79%); padding: 3px; overflow: hidden; background: white; border: 1px solid #ebebf1; white-space: normal; }
.widget-image-link { display: block; overflow: hidden; border-radius: 7px; cursor: zoom-in; }
.widget-image { display: block; width: 100%; height: auto; max-height: 260px; object-fit: contain; }
.widget-message time { margin-top: 4px; color: #b0b2bf; font-size: 7px; }
.widget-system { margin: 12px 0; color: #a3a6b3; font-size: 8px; text-align: center; }
.widget-typing { margin: 3px 0 8px 35px; color: #9b9eae; font-size: 8px; }
.widget-start { flex: 1; padding: 5px 18px 14px; overflow-y: auto; background: #f8f8fb; }
.widget-start label { margin: 9px 0 6px; display: block; color: #717587; font-size: 9px; }
.widget-start input, .widget-start textarea { width: 100%; padding: 10px 11px; resize: none; background: white; border: 1px solid #e6e5ed; border-radius: 7px; font-size: 10px; }
.widget-start input:focus, .widget-start textarea:focus { border-color: var(--widget-primary); }
.widget-start button { width: 100%; height: 37px; margin-top: 12px; display: flex; align-items: center; justify-content: center; gap: 10px; color: white; background: var(--widget-primary); border: 0; border-radius: 7px; font-size: 10px; }
.widget-start > small { margin-top: 8px; display: block; color: #b0b2be; font-size: 7px; text-align: center; }
.widget-composer { flex-shrink: 0; padding: 10px 12px 8px; background: white; border-top: 1px solid #e9e9ef; }
.widget-composer textarea { width: 100%; height: 56px; min-height: 56px; max-height: 120px; padding: 3px; resize: none; border: 0; font-size: 10px; line-height: 1.6; }
.widget-composer > div { display: flex; align-items: center; justify-content: space-between; }
.widget-composer .widget-composer-buttons { display: flex; align-items: center; gap: 6px; }
.widget-composer .widget-image-button { color: #858899; background: #f0f0f5; }
.widget-composer span { color: #b3b5c0; font-size: 7px; }
.widget-composer button { width: 30px; height: 27px; display: grid; place-items: center; color: white; background: var(--widget-primary); border: 0; border-radius: 7px; }
.widget-composer button:disabled { opacity: .45; }
.widget-ended { padding: 9px; color: #9699a8; background: #f0f0f5; border-radius: 7px; font-size: 9px; text-align: center; }
.widget-new-chat { margin-top: 7px; color: var(--widget-primary); background: transparent; border: 0; font-size: 9px; }
.widget-powered { padding: 7px; flex-shrink: 0; color: #b3b4bf; background: white; border-top: 1px solid #f0f0f4; font-size: 7px; text-align: center; }
.widget-powered strong { color: #9994bc; font-weight: 500; }

/* Responsive */
@media (max-width: 1260px) {
    .inbox-grid { grid-template-columns: 280px minmax(390px, 1fr); }
    .visitor-panel { display: none; }
    .visitor-panel.mobile-visible { position: absolute; z-index: 15; top: 69px; right: 0; bottom: 0; width: 270px; display: block; box-shadow: -10px 0 30px rgba(30,32,55,.08); }
    .chat-panel { position: relative; }
    .team-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 1050px) {
    .sidebar { transform: translateX(-100%); transition: transform .25s ease; }
    .sidebar.open { transform: translateX(0); }
    .sidebar-overlay.visible { position: fixed; z-index: 35; inset: 0; display: block; background: rgba(24,25,42,.35); }
    .main-shell { margin-left: 0; }
    .mobile-menu { display: inline-grid; }
    .dashboard-charts, .dashboard-bottom { grid-template-columns: minmax(0,1.5fr) minmax(260px,.8fr); }
    .hero-art { right: -20px; opacity: .65; transform: scale(.85); }
}
@media (max-width: 800px) {
    .topbar { padding: 0 18px; }
    .global-search { width: 180px; }.global-search kbd { display: none; }
    .help-top { display: none; }
    .page-content { padding: 23px 18px 35px; }
    .stats-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .dashboard-charts, .dashboard-bottom { grid-template-columns: 1fr; }
    .summary-strip { grid-template-columns: 1fr; gap: 10px; }
    .settings-layout { grid-template-columns: 1fr; }
    .settings-nav { display: flex; overflow-x: auto; }
    .settings-nav button { width: auto; white-space: nowrap; }
    .form-row { grid-template-columns: 1fr; gap: 7px; }.form-label { padding-top: 0; }
    .hero-art { display: none; }
    .store-main { padding-top: 55px; }
    .store-features { margin-top: 50px; }
}
@media (max-width: 620px) {
    .breadcrumb > span, .breadcrumb > b { display: none; }
    .topbar { height: 59px; padding: 0 12px; }
    .global-search { display: none; }
    .preview-button { padding: 0 9px; }.preview-button span { display: none; }
    .page-heading { align-items: flex-start; }
    .page-heading h1 { font-size: 21px; }.heading-date { display: none; }
    .stats-grid { gap: 10px; }.stat-card { padding: 15px; }.stat-value { font-size: 26px; }
    .card-header { padding: 16px; }
    .trend-chart { height: 210px; padding-right: 12px; }
    .page-content.conversation-page { height: calc(100vh - 59px); padding: 0; }
    .inbox-grid { grid-template-columns: 1fr; }
    .conversation-sidebar { grid-column: 1; }
    .chat-panel { display: none; grid-column: 1; }
    .inbox-grid.mobile-chat-open .conversation-sidebar { display: none; }
    .inbox-grid.mobile-chat-open .chat-panel { display: flex; }
    .mobile-back { display: inline-grid; }
    .chat-header { padding: 0 10px; }.chat-actions .icon-button:not(.mobile-info) { display: none; }
    .chat-customer h2 { font-size: 12px; }.chat-customer .avatar { display: none; }
    .message-scroll { padding: 16px 13px; }.message-content { max-width: 82%; }
    .composer-wrap { padding: 0 10px 12px; }.composer-hint { display: none; }
    .quick-reply-popover { right: 10px; bottom: 111px; left: 10px; }
    .team-grid { grid-template-columns: 1fr; }
    .table-toolbar { align-items: flex-start; }.table-search { width: 100%; }.table-filter { display: none; }
    .data-table th, .data-table td { padding: 11px 13px; }
    .hide-mobile { display: none; }
    .form-row { margin-bottom: 15px; }
    .settings-section { padding: 17px; }
    .demo-notice { padding: 0 12px; font-size: 8px; }.demo-notice a { display: none; }
    .store-header { height: 66px; padding: 0 20px; }.store-header nav { display: none; }
    .store-main { min-height: 510px; padding: 55px 22px 0; }
    .store-hero h1 { font-size: 34px; }.store-hero > p br { display: none; }
    .store-features { grid-template-columns: 1fr; padding: 10px 0; }
    .store-features article, .store-features article:first-child { padding: 15px 0; border-right: 0; border-bottom: 1px solid #efeff4; }
    .store-features article:last-child { border-bottom: 0; }
    .store-footer { padding: 0 22px 100px; }.store-footer span { display: none; }
    .widget-window { right: 0; bottom: 0; left: 0; width: 100%; height: calc(100dvh - 16px); border-radius: 17px 17px 0 0; }
    .chat-launcher { right: 20px; bottom: 20px; }
    .toast-stack { right: 12px; left: 12px; }.toast { min-width: 0; max-width: none; }
}
/* Shared administrator authentication */
.logout-form { margin: 0; }
.logout-button { height: 35px; padding: 0 10px; color: #85899b; background: transparent; border: 1px solid var(--line); border-radius: 8px; font-size: 10px; white-space: nowrap; }
.logout-button:hover { color: var(--primary); background: #f3f2fa; border-color: #dedaf8; }
.login-body { min-height: 100vh; background: radial-gradient(circle at 50% 0, #efedff 0, #f6f7fb 48%, #f1f2f8 100%); }
.login-shell { width: 100%; min-height: 100vh; padding: 40px 20px 24px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.login-card { width: min(410px, 100%); padding: 38px 38px 30px; background: rgba(255,255,255,.98); border: 1px solid #e8e7f1; border-radius: 20px; box-shadow: 0 22px 65px rgba(36,38,64,.11); }
.login-brand { display: flex; align-items: center; justify-content: center; gap: 12px; }
.login-brand .brand-name { color: var(--ink); }
.login-heading { margin: 30px 0 25px; text-align: center; }
.login-heading h1 { margin: 0; font-size: 24px; font-weight: 650; }
.login-heading p { margin: 10px 0 0; color: var(--muted); font-size: 12px; }
.login-error { margin-bottom: 18px; padding: 11px 13px; color: #b8404b; background: #fff1f2; border: 1px solid #f8d9dd; border-radius: 9px; font-size: 12px; line-height: 1.6; }
.login-form { display: grid; gap: 10px; }
.login-form label { margin-top: 6px; color: var(--ink-soft); font-size: 12px; font-weight: 500; }
.login-form input { width: 100%; height: 46px; padding: 0 13px; background: #fbfbfe; border: 1px solid #e3e4ee; border-radius: 9px; font-size: 13px; }
.login-form input:focus { background: white; border-color: #aaa3ec; }
.login-form button { height: 46px; margin-top: 15px; display: flex; align-items: center; justify-content: center; gap: 10px; color: white; background: linear-gradient(135deg, #756ce2, #5b52d1); border: 0; border-radius: 9px; font-size: 13px; font-weight: 550; box-shadow: 0 7px 16px rgba(99,91,223,.2); }
.login-form button:hover { background: linear-gradient(135deg, #685fd8, #5148c2); }
.login-help { margin: 22px 0 0; color: #a0a3b2; font-size: 10px; line-height: 1.7; text-align: center; }
.login-footer { margin: 24px 0 0; color: #a0a3b2; font-size: 10px; }
@media (max-width: 480px) {
    .login-card { padding: 30px 24px 25px; }
    .logout-button { padding: 0 7px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *:before, *:after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
