/* MultiTG workspace · 0.2 — a quiet, readable Telegram-style work surface. */
:root {
  --bg:#0e0f13; --panel:#16161b; --surface:#202126; --surface-hover:#292a2f;
  --border:#26272c; --text:#e9eef6; --muted:#9b9ea5; --blue:#8daaff;
  --blue-hover:#b1c5ff; --green:#6ad3b0; --danger:#ff8595;
  font-family:Inter,"Segoe UI",Arial,sans-serif; font-size:100%;
}
body {background:var(--bg);letter-spacing:-.012em}
button {transition:background .16s,color .16s,border-color .16s}
button:focus-visible,a:focus-visible {outline:2px solid #b1c5ff;outline-offset:3px}
.primary {background:#8daaff;color:#fff;border-radius:12px;font-weight:600;box-shadow:0 4px 14px #4b4d5220}
.primary:hover {background:#b1c5ff}
.secondary {background:#1f1f24;border-color:#34353a;border-radius:12px}
.brand-mark {background:linear-gradient(145deg,#a0a3ab,#72757b);box-shadow:0 5px 18px #4a4b5131;border-radius:13px;letter-spacing:0;padding:0}
.brand-mark .icon {width:25px;height:25px;stroke-width:1.8}
.app-shell {background:#101115}
.demo-banner {min-height:33px;background:#222328;color:#c1c5cd;border-color:#333439;font-size:12px;gap:14px}
.demo-banner strong {font-size:10px;letter-spacing:.12em;border:1px solid #8a8d945c;padding:3px 6px;border-radius:5px}
.demo-banner select {background-color:#313237;border-radius:7px;padding:3px 26px 3px 8px}
.local-owner-banner {background:#202126;border-color:#393a40;min-height:33px}
.shell-body {position:relative;overflow:hidden}
.rail {width:224px;background:#141519;border-right:1px solid #27272c;padding:28px 15px 17px;gap:0;align-items:stretch}
.rail-brand {display:flex;gap:11px;align-items:center;padding:0 8px 25px}
.rail .brand-mark {width:38px;height:38px;border-radius:12px;flex-shrink:0}
.brand-name {font-weight:750;font-size:21px;letter-spacing:-.05em}
.brand-name span {display:block;color:#8d9097;font-size:11px;font-weight:450;letter-spacing:0;margin-top:4px}
.workspace-switch {display:flex;gap:9px;align-items:center;border:1px solid #2c2d32;background:#1b1c20;border-radius:12px;padding:10px;margin-bottom:25px;font-size:13px;font-weight:600}
.workspace-symbol {height:29px;width:29px;background:#3c3e43;color:#bfc3cb;border-radius:8px;display:grid;place-items:center;font-weight:700;font-size:13px}
.workspace-switch>span:nth-child(2) {min-width:0;flex:1}
.workspace-switch small {display:block;font-size:10px;font-weight:450;color:#9a9da5;margin-top:4px}
.workspace-switch>.icon {color:#878990;width:14px;height:14px}
.rail-nav {width:100%;gap:5px;align-items:stretch}
.nav-item {width:100%;height:44px;flex-direction:row;justify-content:flex-start;gap:11px;padding:0 13px;border-radius:10px;font-size:14px;font-weight:500;color:#abafb6}
.nav-item .icon {width:20px;height:20px;stroke-width:1.65}
.nav-item:hover {background:#212226;color:#e8ecf5}
.nav-item.active {background:#34363b;color:#caced7}
.nav-item.active::before {display:none}
.nav-item em {font-style:normal;font-size:11px;margin-left:auto;background:#8daaff;color:#fff;border-radius:6px;padding:3px 6px}
.rail-section {border-top:1px solid #27272c;margin-top:24px;padding-top:18px;min-height:0}
.rail-section-title {display:flex;align-items:center;justify-content:space-between;color:#7b7e85;text-transform:uppercase;letter-spacing:.095em;font-size:10px;font-weight:600;padding:0 9px 11px}
.rail-section-title button {color:#91949b;padding:3px;border-radius:5px}
.rail-section-title button:hover {background:#2d2e33;color:#d7dce4}
.rail-hint {margin:0;padding:4px 10px;color:#7e8188;font-size:12px;line-height:1.8}
.rail-folder {display:flex;align-items:center;gap:10px;width:100%;padding:10px 11px;border-radius:9px;color:#a3a7ae;font-size:13px;text-align:left}
.rail-folder span {flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.rail-folder small {font-size:11px;color:#888a91}
.rail-folder.selected {color:#c2c6ce;background:#28292e}
.rail-folder:hover {background:#202126}
.rail-accounts {margin-top:22px}
.rail-account {display:flex;align-items:center;gap:8px;width:100%;padding:8px 9px;font-size:12px;color:#a6aab1;text-align:left;border-radius:8px}
.rail-account:hover {background:#212227;color:#e7ebf4}
.rail-account>span:nth-child(2) {flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.account-dot {height:7px;width:7px;border-radius:3px;flex-shrink:0}
.tiny-online {height:5px;width:5px;border-radius:50%;background:#64c8a6}
.rail-all-accounts {display:flex;align-items:center;gap:9px;font-size:12px;color:#9ea2a9;padding:13px 9px 1px}
.rail-all-accounts .icon {width:14px;height:14px}
.rail-bottom {width:100%;margin-top:auto;padding-top:14px;align-items:stretch;gap:0;flex-shrink:0}
.rail-brand,.workspace-switch,.rail-nav {flex-shrink:0}
.rail-scroll {min-height:0;overflow-y:auto;flex:1;scrollbar-width:none}
.rail-profile {border-top:1px solid #28292e;display:flex;align-items:center;gap:9px;width:100%;padding:18px 4px 0;text-align:left}
.rail-profile>span:nth-child(2) {min-width:0;flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px;font-weight:550}
.rail-profile small {display:block;font-size:10px;color:#90939a;font-weight:400;margin-top:4px}
.rail-profile>.icon {color:#8d9097}
.workspace {background:#101015}
.inbox-sidebar {width:370px;background:#18191d;border-color:#2a2b30}
.sidebar-heading {padding:30px 23px 23px;align-items:center}
.sidebar-heading h1 {font-size:27px;font-weight:700;letter-spacing:-.05em;margin-bottom:7px}
.sidebar-heading h1 {display:flex;align-items:center;gap:10px;margin-top:6px}
.heading-counter {font-size:12px;background:#2e2f34;border:1px solid #424449;border-radius:7px;padding:4px 7px;letter-spacing:0;font-weight:500;color:#b0b3bb}
.sidebar-heading .eyebrow {font-size:9px;letter-spacing:.11em;color:#888b92}
.sidebar-subtitle {font-size:12px;color:#8e9198}
.sidebar-subtitle .status-dot {height:5px;width:5px;background:#90939a}
.sidebar-heading .icon-button {border:1px solid #2d2e33;border-radius:10px}
.search-field {margin:0 20px;position:relative}
.search-field .icon {height:18px;width:18px;left:13px;top:50%;transform:translateY(-50%);stroke-width:1.7}
.search-field input {height:43px;border:1px solid #2e2f34;background:#202126;padding:10px 65px 10px 39px;border-radius:11px;font-size:13px}
.search-field input:focus {border-color:#808289;background:#232429}
.search-field input::placeholder {color:#8b8e95}
.search-shortcut {position:absolute;right:10px;top:50%;transform:translateY(-50%);font-size:10px;border:1px solid #37383d;border-radius:4px;padding:3px 5px;color:#888b92;pointer-events:none}
.filter-strip {padding:20px 20px 14px;gap:5px}
.filter-tab {font-size:12px;padding:8px 10px;border-radius:9px;background:transparent;gap:6px;color:#999ca3;min-height:34px}
.filter-tab:hover {background:#27282c}
.filter-tab.selected {background:#364767;color:white}
.filter-tab .badge {height:17px;min-width:17px;font-size:10px;background:#323338;color:#abaeb6;line-height:1}
.filter-tab.selected .badge {color:#fff;background:#ffffff29}
.account-filter {margin:0 20px 15px;padding:6px 0;border-top:1px solid #2b2c31;border-bottom:1px solid #2b2c31;gap:7px;font-size:12px}
.account-filter>.icon {color:#85888f;margin-left:2px;width:16px;height:16px}
.account-filter select {flex:1;max-width:none;font-size:12px;color:#a6aab1;line-height:1.4;background-color:transparent;border:0;padding:7px 21px 7px 4px}
.account-filter>.icon-button {height:26px;width:26px;border-radius:7px}
.list-label {padding:0 24px 10px;display:flex;justify-content:space-between;font-size:10px;font-weight:600;text-transform:uppercase;letter-spacing:.06em;color:#7f8288}
.list-label>span:nth-child(2) {font-size:11px;letter-spacing:0}
.dialog-list {padding:0 9px 12px;scrollbar-color:#393b40 transparent}
.dialog-row {gap:12px;padding:13px 12px;min-height:90px;border-radius:11px;isolation:isolate}
.dialog-row:hover {background:#222227}
.dialog-row.active {background:#313237}
.dialog-row.active::before {left:-9px;width:3px;height:40px;background:var(--account-color);border-radius:3px}
.dialog-row .avatar {width:46px;height:46px;font-size:16px;border:1px solid #ffffff10}
.dialog-title-line {margin-bottom:5px;gap:8px}
.dialog-title {color:#e3e8f0;font-size:14px;font-weight:600;letter-spacing:-.015em}
.dialog-time {font-size:11px;color:#8f9198}
.dialog-preview {font-size:13px;color:#979aa1;line-height:1.45}
.dialog-row.active .dialog-preview {color:#bec2ca}
.account-caption {display:flex;align-items:center;gap:5px;margin-top:6px;font-size:10px;color:var(--account-color);font-weight:500;line-height:1.35;max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.account-caption i {width:5px;height:5px;border-radius:50%;flex-shrink:0}
.unread-badge {height:19px;min-width:19px;font-size:10px;background:#8daaff;box-shadow:0 3px 8px #0001}
.dialog-markers .icon {width:14px;height:14px;color:#9a9da4}
.list-footer {padding:13px 22px;font-size:10px;gap:7px;min-height:42px;border-top:1px solid #2a2b30;background:#17181c;color:#878a91}
.list-footer>span:last-child {margin-left:auto;color:#74767d}
.list-footer .icon {height:12px;width:12px}
.active-folder {margin:0 20px 13px;padding:8px 10px;background:#35363b55;color:#bec2ca;border:1px solid #45474c;border-radius:9px;font-size:12px;display:flex;align-items:center;gap:8px}
.active-folder span {flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.active-folder>button {font-size:11px;color:#abafb7;padding:3px}
.mobile-folder-strip {display:none}
.chat-panel {background:#121317}
.chat-header {background:#1a1a1f;border-color:#2b2c31;padding:16px 30px;height:87px;gap:13px}
.chat-header .avatar {width:45px;height:45px;font-size:16px}
.chat-heading h2 {font-size:17px;letter-spacing:-.025em;font-weight:650;margin-bottom:6px}
.chat-heading .account-caption {font-size:12px;margin-top:0}
.chat-actions .icon-button {width:36px;height:36px;color:#9b9ea5}
.chat-actions .icon-button:hover {background:#303136}
.chat-heading .account-caption::before {width:5px;height:5px}
.messages {padding:28px 6% 24px;background-color:#121216;background-image:radial-gradient(#9ea2a910 .75px,transparent .75px);background-size:22px 22px;scrollbar-color:#383a3f transparent}
.message-wrap {margin-bottom:16px;gap:7px}
.message-bubble {background:#212126;border:1px solid #2f30352e;border-radius:15px 15px 15px 4px;padding:12px 16px 8px;box-shadow:0 2px 3px #0000000d;max-width:77%}
.outgoing .message-bubble {background:#3d3e43;border-color:#585a603b;border-radius:15px 15px 4px 15px}
.message-text {font-size:15px;line-height:1.6;color:#e9edf6;overflow-wrap:anywhere;white-space:pre-wrap}
.message-meta {margin-top:4px;gap:5px;color:#989ba2;font-size:10px}
.outgoing .message-meta {color:#aeb2b9}
.message-meta .icon {color:#c4c8d1}
.date-divider {display:flex;justify-content:center;margin:0 0 22px;padding:0;background:transparent;border:0}
.date-divider span {font-size:10px;letter-spacing:.01em;padding:6px 12px;border:1px solid #333439;background:#202125;border-radius:20px;color:#a3a7ae}
.message-menu {width:25px;height:28px;border-radius:7px}
.message-menu:hover {background:#333439}
.message-menu .icon {width:17px;height:17px}
.message-reply {border-left-color:#9da0a8;background:#ffffff06;border-radius:0 6px 6px 0;margin-bottom:8px}
.chat-footer {background:#191a1f;border-top:1px solid #2c2d32;padding:15px 25px 9px}
.compose-row {gap:8px;background:#222327;border:1px solid #35363b;border-radius:15px;padding:5px 7px 5px 5px;align-items:flex-end}
.compose-row:focus-within {border-color:#74767d}
.compose-row textarea {border:0;background:transparent;padding:9px 5px;font-size:15px;line-height:1.45;min-height:40px;max-height:140px;scrollbar-width:none}
.compose-row textarea::-webkit-scrollbar {display:none}
.compose-row .icon-button {color:#9c9fa6;width:36px;height:39px}
.send-button {height:36px;width:36px;border-radius:11px;background:#8daaff;color:#fff;margin:2px 0 2px 3px;box-shadow:0 3px 8px #4c4d5330}
.send-button .icon {width:20px;height:20px}
.compose-note {font-size:10px;margin:9px 0 0;color:#7b7d84;text-align:center}
.chat-welcome {display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;background:radial-gradient(ellipse at 55% 42%,#30313634,transparent 65%),#121317;position:relative;padding:50px;gap:0;overflow:hidden}
.chat-welcome::before {content:"";position:absolute;width:330px;height:330px;border:1px solid #484a4f23;border-radius:50%;pointer-events:none}
.chat-welcome::after {content:"";position:absolute;width:490px;height:490px;border:1px solid #484a4f15;border-radius:50%;pointer-events:none}
.welcome-icon {z-index:1;display:grid;place-items:center;height:86px;width:86px;border-radius:27px;color:#adb0b8;background:#292a2f;border:1px solid #494a50;box-shadow:0 15px 60px #0f0f13;margin-bottom:27px;transform:rotate(-8deg)}
.welcome-icon .icon {width:36px;height:36px;transform:rotate(8deg)}
.chat-welcome h2 {position:relative;z-index:1;font-size:34px;line-height:1.2;letter-spacing:-.055em;margin:0 0 18px;font-weight:650}
.chat-welcome p {z-index:1;position:relative;font-size:14px;color:#9a9da4;line-height:1.85;max-width:340px;margin-bottom:30px}
.welcome-metrics {z-index:1;display:flex;gap:0;border-top:1px solid #313237;padding-top:22px;width:320px;justify-content:center}
.welcome-metric {flex:1;text-align:center;border-right:1px solid #313237}
.welcome-metric:last-child {border-right:0}
.welcome-metric strong {display:block;font-size:23px;color:#dfe4ec;font-weight:600}
.welcome-metric span {display:block;font-size:11px;color:#84878e;margin-top:6px}
.welcome-eyebrow {z-index:1;font-size:10px;color:#81848b;font-weight:650;letter-spacing:.14em;text-transform:uppercase;margin-bottom:13px}
.chat-search {background:#1c1c21;border-color:#323338;padding:11px 25px}
.chat-search input {background:#25262a;border-color:#3e3f45;border-radius:9px}
.pinned-strip {background:#222327;border-color:#3b3d42}
.bot-keyboard {display:grid;gap:5px;margin-top:12px;border-top:1px solid #ffffff12;padding-top:8px;min-width:190px}
.bot-keyboard-row {display:flex;gap:5px}
.bot-keyboard button,.bot-keyboard a {flex:1;display:flex;align-items:center;justify-content:center;gap:5px;text-decoration:none;text-align:center;background:#35363b;border:1px solid #51535949;border-radius:8px;min-height:36px;padding:8px 10px;font-size:13px;font-weight:500;color:#d4d8e0;line-height:1.4;overflow-wrap:anywhere}
.bot-keyboard button:hover,.bot-keyboard a:hover {background:#45464b}
.bot-keyboard .icon {height:13px;width:13px}
.reply-keyboard {border-top:0;margin:0 0 12px;padding:0}
.management-page {background:radial-gradient(ellipse at 90% 0,#36373c18,transparent 40%),#131418;scrollbar-color:#37383d transparent}
.management-page-inner {padding:39px 38px;max-width:1320px!important}
.page-heading {margin-bottom:30px!important}
.page-heading h1 {font-size:28px!important;letter-spacing:-.045em!important}
.page-heading p {color:#9da0a8;font-size:14px}
.stats-grid {gap:14px;margin-bottom:35px}
.stat-card {background:linear-gradient(125deg,#1f2025,#1a1b1f);border-color:#323338;border-radius:14px;padding:21px 21px 19px;box-shadow:none}
.stat-label {font-size:12px;color:#9ea2a9}
.stat-label .icon {height:18px;width:18px;color:#7d7f86}
.stat-value {font-size:30px;margin-top:13px;font-weight:600;letter-spacing:-.04em;color:#e9edf6}
.stat-value .small {font-size:11px;margin-left:9px;color:#6dcaae;font-weight:500;letter-spacing:0}
.section-topline h2 {font-size:15px;font-weight:550;letter-spacing:-.01em}
.section-topline {margin-bottom:18px}
.account-grid {gap:17px;grid-template-columns:repeat(auto-fill,minmax(270px,1fr))}
.account-card {background:#1c1c21;border-color:#323338;border-radius:14px;padding:22px;box-shadow:none;transition:border-color .2s,transform .2s}
.account-card:hover {border-color:#52545a;transform:translateY(-2px)}
.account-card h3 {font-size:16px;font-weight:600;margin-bottom:5px}
.account-card .avatar {border-radius:14px}
.account-card .account-caption {font-size:12px}
.account-card .account-info {font-size:13px;color:#9ea2a9;line-height:1.7}
.account-card .account-bottom {border-color:#303136}
.worker-table,.audit-table {background:#1b1b20;border-color:#2f3035;border-radius:14px;overflow:hidden}
.worker-row {padding:17px 21px;border-color:#2e2f34;font-size:14px}
.worker-row.table-head {background:#212226;color:#878a91;font-size:10px;letter-spacing:.08em;padding:14px 21px}
.worker-person {font-size:14px;font-weight:550}
.status-pill {font-size:11px;border-radius:6px;background:#153e38;color:#83d5b5;padding:5px 8px}
.status-pill.disabled {background:#3d2738;color:#e8a6b8}
.audit-row {font-size:13px;border-color:#2f3035;line-height:1.5;padding:17px 20px}
.notice-card {background:#212126;border-color:#3a3b40;color:#aeb1b9;border-radius:11px;line-height:1.7;font-size:13px}
.dialog-modal {background:#1c1c21;color:#e5e9f2;border:1px solid #414247;border-radius:19px;box-shadow:0 35px 120px #06060ac9;max-width:540px}
.dialog-modal::backdrop {background:#08090da8;backdrop-filter:blur(6px)}
.modal-heading {padding:23px 25px 10px}
.modal-heading h2 {font-size:21px;letter-spacing:-.03em}
.modal-content {padding:16px 25px 26px}
.form-field>label {color:#b9bdc5;font-size:13px;margin-bottom:9px;font-weight:500}
.form-field>label .muted {float:right;font-size:12px}
.form-field input,.form-field select,.form-field textarea {border-color:#3e3f44;background:#151519;min-height:45px}
.checklist {border:1px solid #3b3c41;background:#18181c;border-radius:10px;max-height:300px;overflow:auto;scrollbar-width:thin;scrollbar-color:#434449 transparent}
.checkbox-row {display:flex;align-items:center;gap:12px;padding:11px 13px;border-bottom:1px solid #2b2c31;cursor:pointer;font-size:14px}
.checkbox-row:last-child {border-bottom:0}
.checkbox-row:hover {background:#28292e}
.checkbox-row small {display:block;color:#92959c;font-size:11px;margin-top:5px}
.form-actions {display:flex;justify-content:space-between;gap:12px;margin-top:22px}
.menu-row {border-radius:9px;font-size:14px;padding:12px 11px}
.menu-row:hover {background:#313237}
.toast {background:#34353a;border:1px solid #585a60;box-shadow:0 12px 45px #06060a80;border-radius:12px;font-size:14px;line-height:1.6}
.toast.error {background:#44263a;border-color:#835069}
.login-screen {background:radial-gradient(ellipse at 50% 20%,#34353a80,transparent 65%),#101014}
.login-card {background:#1a1b1f;border:1px solid #3a3c41;border-radius:23px;box-shadow:0 30px 100px #06060a88;max-width:460px;padding:40px}
.login-card h1 {font-size:34px;letter-spacing:-.06em;margin-bottom:20px}
.login-card>p {color:#a8abb3;font-size:14px;line-height:1.8}
.login-card .primary,.login-card .secondary {width:100%;margin-top:10px;min-height:47px;font-size:14px}
.login-footer {font-size:11px!important;color:#7f8289!important;margin:25px 0 0}
@media(min-width:1600px){.inbox-sidebar{width:405px}.rail{width:238px}.dialog-row{min-height:94px}.messages{padding-left:9%;padding-right:9%}}
@media(max-height:800px) and (min-width:1101px){.rail{padding-top:22px}.rail-brand{padding-bottom:18px}.workspace-switch{margin-bottom:17px}.rail-section{margin-top:18px;padding-top:14px}.rail-accounts{margin-top:17px}.rail-account{padding-top:6px;padding-bottom:6px}.rail-bottom{padding-top:12px}.rail-profile{padding-top:13px}}
@media(max-width:1180px) and (min-width:781px){
 .rail{width:78px;padding:23px 9px 15px;align-items:center}.rail-brand{padding:0 0 28px}.brand-name,.workspace-switch,.rail-section,.rail-profile>span:nth-child(2),.rail-profile>.icon{display:none}.rail-nav{gap:9px}.nav-item{height:56px;flex-direction:column;justify-content:center;padding:7px 2px;gap:5px;font-size:10px;width:59px}.nav-item em{display:none}.rail-bottom{align-items:center}.rail-profile{padding-top:18px;justify-content:center}.inbox-sidebar{width:350px}.sidebar-heading{padding-top:24px}.account-filter{margin-bottom:12px}.chat-header{padding-left:22px;padding-right:22px}.messages{padding-left:5%;padding-right:5%}.chat-welcome{padding:25px}.chat-welcome h2{font-size:30px}.stats-grid{gap:10px}.stat-card{padding:17px}
}
@media(max-width:780px){
 .shell-body{padding-bottom:65px}.rail{position:absolute;inset:auto 0 0 0;width:100%;height:65px;padding:0;background:#1b1c21;border:0;border-top:1px solid #323338;z-index:3;display:flex;flex-direction:row;align-items:center;justify-content:center}.rail-brand,.workspace-switch,.rail-section,.rail-bottom{display:none}.rail-nav{height:100%;width:100%;display:flex;flex-direction:row;justify-content:space-around;padding:4px 12px;gap:4px}.nav-item{height:52px;max-width:110px;min-width:58px;flex:1;flex-direction:column;justify-content:center;gap:4px;padding:5px;font-size:10px;border-radius:10px}.nav-item .icon{width:21px;height:21px}.nav-item em{display:none}.workspace{width:100%}.inbox-sidebar{width:100%;border:0;flex:1}.chat-panel{display:none}.app-shell.chat-open .shell-body{padding-bottom:0}.app-shell.chat-open .rail,.app-shell.chat-open .inbox-sidebar{display:none}.app-shell.chat-open .chat-panel{display:flex;flex:1;min-width:0}.sidebar-heading{padding:22px 20px 19px}.sidebar-heading h1{font-size:26px}.sidebar-subtitle{font-size:12px}.search-field{margin:0 17px}.search-field input{font-size:14px;height:43px;padding-right:14px}.search-shortcut{display:none}.filter-strip{padding:15px 17px 12px;gap:7px}.filter-tab{padding:9px 12px;font-size:13px;min-height:35px}.filter-tab .badge{font-size:10px}.account-filter{margin:0 17px 12px}.account-filter select{font-size:12px}.list-label{padding:0 21px 8px}.dialog-list{padding-left:8px;padding-right:8px}.dialog-row{padding:12px 10px;min-height:86px;gap:12px}.dialog-row .avatar{width:49px;height:49px;font-size:17px}.dialog-title{font-size:15px}.dialog-preview{font-size:13px}.dialog-time{font-size:11px}.account-caption{font-size:11px;margin-top:5px}.list-footer{font-size:10px;padding:10px 19px;min-height:35px}.mobile-folder-strip{display:flex;gap:6px;padding:0 17px 12px;overflow:auto;scrollbar-width:none}.mobile-folder-strip .filter-tab{font-size:12px;background:#29292e;gap:6px;min-height:30px;padding:6px 10px}.mobile-folder-strip .selected{background:#494a50}.active-folder{margin:0 17px 12px}.chat-welcome{display:none}.chat-header{height:76px;padding:10px 10px 10px 4px;gap:8px}.mobile-back{display:flex;color:#afb3ba;width:32px;height:37px}.chat-header .avatar{height:39px;width:39px;font-size:14px}.chat-heading h2{font-size:15px;margin-bottom:5px}.chat-heading .account-caption{font-size:10px;max-width:200px}.chat-actions .icon-button{width:31px;height:34px}.messages{padding:22px 11px 16px}.message-wrap{margin-bottom:13px;gap:3px}.message-bubble{max-width:89%;padding:10px 12px 7px;border-radius:13px 13px 13px 4px}.outgoing .message-bubble{border-radius:13px 13px 4px 13px}.message-text{font-size:15px;line-height:1.55}.message-meta{font-size:10px}.message-menu{opacity:.6;width:20px;height:26px}.message-menu .icon{height:15px;width:15px}.chat-footer{padding:10px 8px calc(10px + env(safe-area-inset-bottom))}.compose-row{gap:2px;border-radius:13px;padding:4px}.compose-row textarea{font-size:16px;padding:9px 4px;min-height:39px}.compose-row .icon-button{width:31px;height:38px}.send-button{width:35px;height:35px;margin-right:0;border-radius:10px}.compose-note{display:none}.chat-search{padding:10px 12px}.message-image{max-height:270px}.message-audio{width:225px}.bot-keyboard{min-width:0;margin-top:9px}.bot-keyboard-row{flex-wrap:wrap}.bot-keyboard button,.bot-keyboard a{font-size:12px;min-height:35px;padding:8px}.management-page-inner{padding:24px 17px 30px}.page-heading{align-items:flex-start!important;gap:10px!important;margin-bottom:25px!important}.page-heading h1{font-size:25px!important}.page-heading p{font-size:12px;max-width:220px;line-height:1.6}.page-heading .primary{font-size:12px;padding:10px 11px;min-height:39px;white-space:nowrap}.stats-grid{grid-template-columns:repeat(2,1fr);gap:11px;margin-bottom:25px}.stat-card{padding:17px 15px;border-radius:12px}.stat-label{font-size:11px}.stat-label .icon{width:15px;height:15px}.stat-value{font-size:27px;margin-top:12px}.stat-value .small{font-size:10px;margin-left:5px}.account-grid{grid-template-columns:1fr;gap:13px}.account-card{padding:19px;border-radius:13px}.worker-row{grid-template-columns:minmax(115px,1fr) 47px 72px;padding:15px 12px;font-size:12px;gap:7px}.worker-row>*:nth-child(2),.worker-row>*:nth-child(4){display:none}.worker-row.table-head{padding:12px;font-size:9px}.worker-person{font-size:13px;gap:8px}.worker-person .avatar{height:32px;width:32px;font-size:11px}.worker-row .text-button{font-size:11px;padding:3px}.audit-row{font-size:12px;padding:14px;grid-template-columns:1fr 1.5fr;gap:7px 12px}.audit-row>*:nth-child(3),.audit-row>*:nth-child(4){grid-column:1/-1}.notice-card{font-size:12px;padding:12px}.dialog-modal{width:calc(100vw - 22px);max-height:calc(100dvh - 24px);border-radius:16px}.modal-heading{padding:19px 19px 7px}.modal-heading h2{font-size:19px}.modal-content{padding:13px 19px 21px}.form-field input{font-size:16px}.checkbox-row{font-size:13px;padding:10px}.checkbox-row small{font-size:11px}.toast{bottom:80px;font-size:13px;max-width:calc(100vw - 24px)}.app-shell.chat-open~#toast-root .toast{bottom:85px}.local-owner-banner{font-size:10px;padding:7px 10px}.local-owner-banner button{font-size:10px}.demo-banner{padding:6px 9px;justify-content:space-between;gap:7px;min-height:31px}.demo-banner .demo-description{display:none}.demo-banner select{font-size:11px;max-width:155px}.demo-banner button{font-size:10px}.login-card{margin:15px;padding:28px;max-width:440px}.login-card h1{font-size:31px}.login-card>p{font-size:13px}
}
@media(max-width:370px){.filter-tab{padding:8px 9px}.chat-header .avatar{display:none}.chat-heading .account-caption{max-width:170px}.dialog-row{gap:9px}.dialog-row .avatar{width:43px;height:43px}.stats-grid{gap:8px}.stat-label .icon{display:none}}
@media(prefers-reduced-motion:reduce){button,.account-card{transition:none}.account-card:hover{transform:none}}
@media(max-width:1180px){.rail-scroll{display:none}}
.message-text,.dialog-title{font-size:1rem}
.dialog-preview,.filter-tab,.form-field>label{font-size:.875rem}
.account-caption{font-size:.75rem}

/* Keep every inbox filter visible without horizontal scrolling. */
.filter-strip{flex-wrap:wrap;overflow:visible}

/* Native Telegram content */
.message-text{font-family:inherit,"Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji"}
.message-text a,.message-content-card a{color:#c5c9d1;text-decoration:underline;text-underline-offset:3px}
.message-text code,.message-pre{font-family:Consolas,monospace;background:#10101470;border-radius:5px;padding:2px 4px}
.message-pre{display:block;white-space:pre-wrap;overflow-wrap:anywhere;padding:10px;margin:3px 0}
.message-quote{display:block;border-left:3px solid #a6aab1;background:#9b9fa615;padding:5px 10px;margin:3px 0;border-radius:3px}
.message-spoiler{background:#898c93;color:transparent;border-radius:4px;cursor:pointer;box-decoration-break:clone}
.message-spoiler *{visibility:hidden}.message-spoiler.revealed{background:#898c9325;color:inherit}.message-spoiler.revealed *{visibility:visible}
.custom-emoji{display:inline-flex;width:1.4em;height:1.4em;vertical-align:-.3em;align-items:center;justify-content:center;line-height:1;flex-shrink:0;overflow:hidden}
tg-visual>img,tg-visual>video,tg-visual>canvas{width:100%!important;height:100%!important;object-fit:contain}
.custom-emoji.emoji-text-color{filter:brightness(0) invert(1)}
.telegram-sticker{display:flex;flex-direction:column;align-items:center;justify-content:center;width:220px;height:220px;max-width:65vw;font-size:60px}
.telegram-sticker small{font-size:11px;line-height:1.5;max-width:190px;text-align:center;margin-top:8px;color:#b0b3bb}
.message-bubble.sticker-bubble{background:transparent;box-shadow:none;padding:0 4px 3px;min-width:170px}
.sticker-bubble .message-meta{width:fit-content;margin-left:auto;background:#202126aa;border-radius:12px;padding:3px 7px}
.message-reactions{display:flex;flex-wrap:wrap;gap:5px;margin:9px 0 2px}.message-reaction{display:inline-flex;align-items:center;gap:5px;background:#1e1e2388;padding:4px 8px;border-radius:14px;color:#bfc3cb;font-size:13px}.message-reaction.chosen{outline:1px solid #a8abb3}.message-reaction .custom-emoji{font-size:15px}
.message-content-card{display:flex;flex-direction:column;gap:7px;max-width:350px;border-left:3px solid #9a9da4;padding:8px 11px;margin:2px 0 10px;font-size:14px;line-height:1.5;overflow-wrap:anywhere}.message-content-card span{color:#bec2c9}.poll-option{border-top:1px solid #aaaeb630;padding-top:5px}
.bot-keyboard .custom-emoji{font-size:18px}.bot-keyboard .bot-style-primary{background:#48494f}.bot-keyboard .bot-style-success{background:#1e6153}.bot-keyboard .bot-style-danger{background:#824353}
@media(max-width:700px){.telegram-sticker{width:180px;height:180px}.message-text{font-size:16px}}
@media(prefers-reduced-motion:reduce){.message-animation{animation:none}}

.telegram-wait{background:#443a2033;color:#f0c986;border-bottom:1px solid #b18c4d55;padding:11px 20px;font-size:13px;line-height:1.6}
.location-destination,.location-coordinates{display:flex;flex-direction:column;gap:7px;background:#1a1b1f;padding:15px;border-radius:10px;margin-bottom:17px}.location-destination span,.location-coordinates span{font-size:13px;color:#b8bcc3}.location-coordinates strong{font-size:21px;letter-spacing:.02em}

.profile-photos{margin:16px 0 23px}.profile-photo-frame{margin:0;display:flex;align-items:center;justify-content:center;min-height:160px;background:#151519;border-radius:14px;overflow:hidden}.profile-photo-frame img{width:100%;height:260px;object-fit:contain;display:block}.profile-photo-controls{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:9px;font-size:13px;color:#bec2ca}.profile-photo-controls button{min-width:45px}.profile-photo-actions{display:flex;justify-content:space-between;gap:12px;padding-top:9px}
@media(max-width:700px){.profile-photo-frame img{height:220px}}
/* Employee libraries and account photo packs. */
.tool-form{display:flex;flex-direction:column;gap:16px;margin:18px 0}.tool-field{display:flex;flex-direction:column;gap:8px;min-width:0;font-size:13px;color:#aeb2b9}.tool-field input,.tool-field select,.tool-field textarea,.tool-search{width:100%;min-width:0;border:1px solid #414247;border-radius:10px;background:#25252a;color:#e5e9f2;padding:12px;font:inherit;box-sizing:border-box}.tool-field textarea{resize:vertical;min-height:105px}.tool-field input[type=file]{white-space:normal;font-size:12px}.tool-search{margin:18px 0}.tool-tabs,.tool-row{display:flex;flex-wrap:wrap;gap:10px;align-items:center}.tool-tabs .selected{background:#494a50}.tool-columns{display:grid;grid-template-columns:1fr 1fr;gap:14px}.tool-list{display:flex;flex-direction:column;gap:12px;max-height:52dvh;overflow:auto;padding:2px}.reply-card{border:1px solid #37393e;border-radius:12px;padding:14px;display:flex;flex-direction:column;gap:10px;position:relative;min-width:0}.reply-choose{display:flex;flex-direction:column;gap:7px;text-align:left;color:inherit;min-width:0;width:100%;padding:0}.reply-choose strong{padding-right:30px}.reply-choose>span{color:#aeb2b9;font-size:13px;white-space:pre-wrap;overflow-wrap:anywhere;max-height:100px;overflow:auto}.reply-card kbd{position:absolute;right:12px;top:12px;border-radius:5px;padding:3px 6px;background:#36373c;color:#caced6;font-size:11px}.reply-card audio{width:100%;height:38px}.tool-empty{padding:22px 5px;color:#9da1a8;font-size:14px;line-height:1.6}.pack-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:18px 0}.pack-photo{display:flex;flex-direction:column;gap:8px;min-width:0;padding:7px;background:#292a2f;border:1px solid #404146;border-radius:12px;text-align:left;color:inherit;overflow:hidden}.pack-photo img{width:100%;aspect-ratio:1;object-fit:cover;border-radius:7px}.pack-photo>span{font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;width:100%}.auto-status{padding:12px;background:#26272c;border-radius:9px;font-size:13px;line-height:1.6;color:#aeb2b9}.auto-status.running{color:#81dfb4;background:#183b36}.autoliker-tab{color:#f3cf69;flex-shrink:0}.filter-strip{flex-wrap:wrap;overflow:visible}.filter-tab{flex-shrink:0}.profile-detail{gap:10px}.profile-detail .text-button{overflow-wrap:anywhere;text-align:right}.tool-form .checkbox-row{display:flex;gap:10px;align-items:center}.dialog-modal hr{border:0;border-top:1px solid #37393e;margin:22px 0}.reply-card .danger,.pack-photo .danger{color:#fa9b9b}
@media(max-width:780px){.rail-nav{overflow-x:auto;justify-content:flex-start;scrollbar-width:none}.rail-nav .nav-item{flex:0 0 65px;min-width:65px}.pack-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.tool-tabs{gap:6px}.tool-tabs button{padding:10px;font-size:12px}.tool-field input,.tool-field select,.tool-field textarea,.tool-search{font-size:16px}.profile-detail{flex-wrap:wrap}.rail-nav .nav-item span{white-space:nowrap;font-size:9px}}
@media(min-width:781px) and (max-height:850px){.rail-nav{max-height:55dvh;overflow-y:auto;scrollbar-width:thin}.rail-scroll{min-height:0}}

.reply-card kbd{max-width:90px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

.verif-video{display:block;width:240px;max-width:100%;aspect-ratio:1;object-fit:cover;border-radius:50%;margin:12px auto}.verif-preview{min-height:40px}.verif-status{overflow-wrap:anywhere}
.verif-dialog .modal-heading{position:sticky;top:0;background:#1c1c21;z-index:2}.verif-dialog .tool-row{flex-wrap:wrap}.verif-trigger{color:#babec6!important;text-align:center}
/* Working Telegram profiles and manual location picker. */
.working-avatar-preview{width:96px;height:96px;object-fit:cover;border-radius:50%;border:2px solid #4a4b51;align-self:center}.avatar-upload-preview[hidden]{display:none}.dialog-modal:has(.geo-map){max-width:800px;width:calc(100% - 24px)}.geo-map{height:clamp(240px,40dvh,390px);border-radius:12px;border:1px solid #414247;background:#bfc3cb;margin:12px 0;z-index:0}.geo-search{display:flex;gap:8px;margin-top:16px}.geo-search input{flex:1;min-width:0;padding:12px;border:1px solid #414247;border-radius:10px;background:#25252a;color:#e5e9f2;font:inherit}.geo-results{display:flex;flex-direction:column;gap:6px;max-height:150px;overflow:auto}.geo-results button{padding:10px 12px;border:1px solid #37393e;border-radius:9px;background:#292a2f;text-align:left;color:#e5e9f2;font-size:13px;line-height:1.4}.geo-coordinates{display:flex;flex-wrap:wrap;gap:10px;align-items:flex-end;margin:12px 0}.geo-coordinates label{flex:1;min-width:110px;display:flex;flex-direction:column;gap:7px;font-size:12px;color:#aeb2b9}.geo-coordinates input{width:100%;box-sizing:border-box;padding:10px;border:1px solid #414247;background:#25252a;color:#e5e9f2;border-radius:9px;font:inherit}.geo-send{width:100%;margin-top:10px}.geo-pin-host{background:none;border:none}.geo-pin{display:block;width:24px;height:24px;border-radius:50% 50% 50% 0;background:#7c7e85;border:3px solid #fff;box-shadow:0 3px 8px #0008;transform:rotate(-45deg);box-sizing:border-box}.geo-map .leaflet-control-attribution{background:#ffffffeb;color:#2b2c31;font-size:10px}.geo-map .leaflet-control-attribution a{color:#47484e}.geo-map-note{line-height:1.5}.geo-preview strong{overflow-wrap:anywhere}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@media(max-width:780px){.dialog-modal:has(.geo-map){width:calc(100% - 12px)}.geo-map{height:270px}.geo-search input,.geo-coordinates input{font-size:16px}.geo-search .secondary{padding:10px}.geo-coordinates .secondary{min-height:40px}}

/* Graphite dark theme: shared tokens for every workspace and dialog. */
:root {
  color-scheme:dark;
  --bg:#0c0d10; --panel:#121317; --surface:#1b1d23; --surface-hover:#24272f;
  --border:#2b2e37; --text:#eceef4; --muted:#9a9eac;
  --blue:#9ab3ff; --blue-hover:#bdd0ff; --green:#7ed8b1; --danger:#f291a0;
  --theme-accent:#9ab3ff; --theme-accent-soft:#9ab3ff15; --theme-focus:#b8caff;
}
body,.app-shell,.shell-body,.workspace {background:var(--bg)}
::selection {background:#6d8bd766;color:#fff}
* {scrollbar-color:#383c48 transparent;scrollbar-width:thin}
input,textarea,select {background:#101115;border-color:var(--border);color:var(--text);caret-color:var(--blue)}
input::placeholder,textarea::placeholder {color:#858a99}
input:focus,textarea:focus,select:focus {border-color:var(--blue);box-shadow:0 0 0 3px #9ab3ff12}
button:focus-visible,a:focus-visible {outline:2px solid var(--theme-focus);outline-offset:3px}
button:disabled {opacity:.48}
.primary,.send-button {background:#9ab3ff;color:#101728;box-shadow:none}
.primary:hover,.send-button:hover {background:#bdd0ff}
.secondary {background:#1c1e25;border-color:#343843;color:#d7dae5;box-shadow:none}
.secondary:hover {background:#282c35;border-color:#454c5b}
.text-button,a {color:var(--blue)}
.icon-button {color:#9da3b3}
.icon-button:hover,.icon-button.active {background:#242831;color:#dbe4ff}
.brand-mark {background:#a5bbff;color:#111a30;box-shadow:none}
.rail {background:#101115;border-color:#282b33}
.brand-name {color:#f0f1f6}
.brand-name span,.rail-profile small,.workspace-switch small {color:#9096a5}
.workspace-switch {background:#191b21;border-color:#2e323c;color:#e2e5ee}
.workspace-symbol {background:#303b55;color:#c0d0ff}
.nav-item {color:#a4a9b8}
.nav-item:hover {background:#1c1f26;color:#f1f3fa}
.nav-item.active {background:#252e42;color:#c4d3ff;box-shadow:inset 3px 0 0 #9ab3ff}
.nav-item em {background:#3e527c;color:#e5ecff}
.rail-section,.rail-profile {border-color:#282b33}
.rail-section-title,.rail-hint,.rail-folder small {color:#9197a6}
.rail-folder,.rail-account {color:#b0b5c3}
.rail-folder:hover,.rail-account:hover {background:#1b1e25;color:#edf0f7}
.rail-folder.selected {background:#252e42;color:#c4d3ff}
.rail-all-accounts {color:#adbeef}
.inbox-sidebar {background:#15161b;border-color:#2b2e37}
.sidebar-heading .eyebrow,.list-label {color:#8c93a4}
.heading-counter {background:#252935;border-color:#383f50;color:#b2bcd4}
.sidebar-heading .icon-button {border-color:#30343f}
.search-field input {background:#1e2028;border-color:#30343f;color:#f0f2f8}
.search-field input:focus {background:#1d212b;border-color:#9ab3ff}
.search-shortcut {background:#17191f;border-color:#3b404d;color:#9097aa}
.filter-tab {color:#a0a7b8}
.filter-tab:hover {background:#252932}
.filter-tab.selected {background:#354568;color:#eef2ff}
.filter-tab .badge {background:#2c303c;color:#bcc3d4}
.filter-tab.selected .badge {background:#ffffff18;color:#eef2ff}
.account-filter {border-color:#2a2e38}
.account-filter select {color:#b3bacb;background-color:transparent}
.dialog-row:hover {background:#20232b}
.dialog-row.active {background:#283246}
.dialog-title {color:#e9ecf5}
.dialog-preview {color:#a1a7b8}
.dialog-time {color:#8d95a9}
.dialog-row.active .dialog-preview {color:#bbc6df}
.unread-badge {background:#a5bbff;color:#111a30;box-shadow:none}
.list-footer {background:#121318;border-color:#282c36;color:#8d96a9}
.list-footer>span:last-child {color:#878e9e}
.active-folder,.mobile-folder-strip .selected {background:#283246;border-color:#414f6d;color:#cad7ff}
.mobile-folder-strip .filter-tab {background:#242832}
.chat-panel,.messages {background:#0d0e12;background-image:none}
.chat-header {background:#15171d;border-color:#2c303a}
.chat-actions .icon-button:hover {background:#262c37}
.message-bubble {background:#20232b;border:1px solid #303540;box-shadow:0 2px 6px #0002}
.outgoing .message-bubble {background:#2a3851;border-color:#3b4c6a}
.message-text {color:#edf0f7;line-height:1.6}
.message-meta {color:#9da7bc}
.outgoing .message-meta {color:#b0bfdc}
.message-meta .icon {color:#bdd0ff}
.date-divider span {background:#1c1f27;border-color:#303540;color:#a8b0c2}
.message-menu:hover {background:#2e3544}
.message-text a,.message-content-card a {color:#c0d2ff}
.message-text code,.message-pre {background:#0c0e14a8;color:#d7def0}
.message-quote,.message-reply {background:#9ab3ff0b;border-left-color:#9ab3ff}
.message-content-card span {color:#b6bed0}
.message-reaction {background:#9ab3ff13;border-color:#9ab3ff26;color:#cbd6f0}
.chat-footer {background:#13151a;border-color:#2a2e37}
.compose-row {background:#1d2028;border-color:#373d4b;border-radius:14px}
.compose-row:focus-within {border-color:#8199d2;box-shadow:0 0 0 3px #9ab3ff09}
.compose-row textarea {background:transparent;box-shadow:none}
.compose-note {color:#959cae}
.chat-search,.pinned-strip {background:#1c212c;border-color:#333d50}
.chat-search input {background:#141820;border-color:#3c4659}
.bot-keyboard button,.bot-keyboard a {background:#2c3443;border-color:#454f63;color:#d7e1fa}
.bot-keyboard button:hover,.bot-keyboard a:hover {background:#3a4860}
.chat-welcome {background:radial-gradient(ellipse at 50% 42%,#25304840,transparent 62%),#0d0e12}
.chat-welcome::before,.chat-welcome::after {border-color:#667aa11c}
.welcome-icon {background:#252e42;border-color:#465576;color:#b6c9ff;box-shadow:0 15px 70px #0004;transform:none;border-radius:24px}
.welcome-icon .icon {transform:none}
.welcome-eyebrow,.chat-welcome p {color:#9da8bf}
.welcome-metrics,.welcome-metric {border-color:#303744}
.welcome-metric strong {color:#e7ecfb}
.welcome-metric span {color:#9ba5bb}
.management-page {background:#0f1014}
.page-heading p,.stat-label,.account-card .account-info {color:#a0a7b9}
.stat-card {background:linear-gradient(135deg,#1b1e26,#17191f);border-color:#303540;box-shadow:none}
.stat-label .icon {color:#9ab3ff}
.stat-value {color:#eceff8}
.account-card {background:#191c23;border-color:#303540;box-shadow:none}
.account-card:hover {border-color:#536383;transform:none;background:#1c2029}
.account-assigned,.account-card .account-bottom {border-color:#303540}
.worker-table,.audit-table,.audit-row {background:#191c23;border-color:#303540}
.worker-row,.audit-row {border-color:#2c313c}
.worker-row.table-head {background:#20242e;color:#a1acc3}
.notice-card {background:#1d2432;border-color:#3c4963;color:#bdc9e1}
.dialog-modal {background:#191c23;border-color:#404858;color:#edf0f8;box-shadow:0 32px 110px #000b}
.dialog-modal::backdrop {background:#050608b8;backdrop-filter:blur(7px)}
.modal-heading {border-bottom:1px solid #ffffff08;padding-bottom:16px}
.form-field>label,.checkbox-row,.tool-field,.geo-coordinates label {color:#b7bfd1}
.form-field input,.form-field select,.form-field textarea,.tool-field input,.tool-field select,.tool-field textarea,.tool-search,.geo-search input,.geo-coordinates input {background:#11141a;border-color:#383f4e;color:#eceff8}
.form-field input:focus,.form-field select:focus,.form-field textarea:focus,.tool-field input:focus,.tool-field select:focus,.tool-field textarea:focus,.tool-search:focus,.geo-search input:focus,.geo-coordinates input:focus {border-color:#9ab3ff}
input[type=file]::file-selector-button {background:#2b3343;color:#d9e3ff;border:1px solid #46516a;border-radius:7px;padding:7px 10px;margin-right:12px;cursor:pointer}
.checklist {background:#12151b;border-color:#353d4c}
.checkbox-row {border-color:#2b313e}
.checkbox-row:hover {background:#252c39}
.checkbox-row small,.profile-photo-controls {color:#a5b0c7}
.dialog-modal hr {border-color:#343b49}
.modal-tabs {background:#11141a;border-color:#343b49}
.modal-tabs button.active,.tool-tabs .selected {background:#354568;color:#eef2ff}
.reply-card {background:#171b23;border-color:#394253}
.reply-choose>span,.tool-empty {color:#a9b4cc}
.reply-card kbd {background:#303b52;color:#c4d4ff;border:1px solid #465371}
.pack-photo {background:#202631;border-color:#3d485c}
.auto-status {background:#242b38;color:#bdc9e2}
.auto-status.running {background:#183b32;color:#99e2c2}
.location-destination,.location-coordinates {background:#121722;border:1px solid #303b50}
.location-destination span,.location-coordinates span {color:#aebbd5}
.geo-results button {background:#252d3c;border-color:#3b4760;color:#dce5fa}
.geo-results button:hover {background:#354460}
.working-avatar-preview {border-color:#6f85b5}
.profile-photo-frame {background:#101319}
.geo-map {border-color:#485570;background:#161c27}
.geo-map .leaflet-tile-pane {filter:brightness(.72) saturate(.6)}
.geo-map .leaflet-control-zoom a {background:#202631;color:#e1e9fb;border-color:#46526a}
.geo-map .leaflet-control-zoom a:hover {background:#354159}
.geo-map .leaflet-control-attribution {background:#171e2eed;color:#b9c6df}
.geo-map .leaflet-control-attribution a {color:#bacfff}
.geo-pin {background:#a5bbff;border-color:#edf2ff;box-shadow:0 3px 12px #0009}
.verif-dialog .modal-heading {background:#191c23}
.toast {background:#2a3447;border-color:#596b8e;color:#ecf1ff;box-shadow:0 10px 35px #0008}
.toast.error {background:#402733;border-color:#805262}
.login-screen {background:radial-gradient(ellipse at 50% 15%,#303c5a50,transparent 60%),#0c0d10}
.login-card {background:#171a21;border-color:#3c4454;box-shadow:0 30px 100px #0008}
.login-card>p {color:#b0b9ce}
.login-footer {color:#969fb4!important}
.demo-banner {background:#1d2432;border-color:#3b465c;color:#aebdda}
.demo-banner strong {border-color:#657a9f66;color:#d7e2fa}
.demo-banner button {color:#c2d2f3}
.demo-banner select {background-color:#303b50;color:#e2eaff}
.local-owner-banner {background:#182824;border-color:#345348;color:#b2d3c5}
@media(max-width:780px) {
  .rail {background:#121419;border-color:#303540}
  .nav-item.active {box-shadow:inset 0 -2px 0 #9ab3ff}
  .message-bubble,.outgoing .message-bubble {box-shadow:none}
}
/* Telegram media: stable players, explicit loading, and compact transport controls. */
.media-player{display:grid;grid-template-columns:44px minmax(0,1fr)22px;gap:12px;align-items:center;width:min(330px,calc(100vw - 100px));max-width:100%;padding:4px 0 8px;position:relative;color:var(--text)}
.media-player audio{display:none}.media-play{display:grid;place-items:center;width:44px;height:44px;border-radius:50%;background:#afc2ff;color:#121c32;font-size:18px;border:1px solid #c4d2ff55;padding:0;flex-shrink:0;line-height:1}.media-play:hover{background:#d1ddff}.media-info{min-width:0}.media-title{font-size:13px;font-weight:600;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;margin-bottom:9px;color:#e0e7f8}.media-bottom{display:flex;align-items:center;gap:8px;min-height:23px}.media-time{font-size:11px;color:#afbbd5;white-space:nowrap;font-variant-numeric:tabular-nums}.media-state{font-size:10px;color:#c0d0ef;white-space:nowrap;margin-left:auto}.media-speed{font-size:11px;color:#d0ddff;background:#9ab3ff14;border:1px solid #9ab3ff30;padding:3px 5px;border-radius:5px;min-width:29px}.media-download{color:#c0d0f8;text-decoration:none;text-align:center;font-size:22px;border-radius:6px;padding:3px 1px}.media-download:hover{background:#9ab3ff22}.media-seek{display:block;width:100%;height:14px;padding:0;border:0;box-shadow:none!important;appearance:none;background:transparent;cursor:pointer;border-radius:0;margin:0 0 2px;accent-color:#afc2ff}.media-seek::-webkit-slider-runnable-track{height:4px;border-radius:9px;background:linear-gradient(to right,#b7c9ff var(--played,0%),#8d9dbb45 var(--played,0%))}.media-seek::-webkit-slider-thumb{appearance:none;width:10px;height:10px;border-radius:50%;background:#c3d2ff;margin-top:-3px}.media-seek:disabled{opacity:.45;cursor:default}.media-seek:focus-visible{outline:2px solid #b9ccff;outline-offset:3px}.media-error[hidden]{display:none}.media-error{grid-column:1/-1;display:flex;gap:10px;align-items:center;color:#ffb9c2;font-size:12px;line-height:1.5;padding:10px;border:1px solid #b35c7044;border-radius:9px;background:#4c263322}.media-retry{border:1px solid #9c677888;color:#ffd5dd;padding:6px 9px;border-radius:6px;flex-shrink:0;font-size:11px}.media-player.is-video{grid-template-columns:minmax(0,1fr)22px;width:min(390px,calc(100vw - 90px));gap:8px}.media-stage{grid-column:1/-1;position:relative;width:100%;max-height:400px;overflow:hidden;border-radius:11px;background:#0a0c12;display:flex;align-items:center;justify-content:center}.media-stage video{width:100%;height:100%;max-height:400px;object-fit:contain;display:block}.media-video-play{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:52px;height:52px;box-shadow:0 4px 25px #0005;background:#c5d4ffed}.media-playing .media-video-play{opacity:0;pointer-events:none}.media-playing:hover .media-video-play,.media-playing .media-video-play:focus-visible{opacity:.85;pointer-events:auto}.media-player.is-note{width:min(248px,calc(100vw - 100px));margin:3px auto 0}.is-note .media-stage{border-radius:50%;aspect-ratio:1;border:2px solid #a9beee38}.is-note .media-stage video{object-fit:cover;border-radius:50%}.media-duration{position:absolute;bottom:14px;left:50%;transform:translateX(-50%);font-size:11px;color:#fff;background:#111827b3;padding:3px 8px;border-radius:10px;font-variant-numeric:tabular-nums;pointer-events:none}.media-playing .media-duration{opacity:0}.voice-bars{display:flex;gap:2px;align-items:center;height:27px;overflow:hidden;margin-bottom:4px}.voice-bars i{display:block;flex:1;min-width:2px;max-width:4px;background:#b7c9ff77;border-radius:2px}.media-buffering .media-play{box-shadow:0 0 0 5px #9ab3ff14}.message-image{object-fit:contain;height:auto;max-width:100%;background:#11151d}.message-image[width][height]{object-fit:contain}.attachment-preview{max-height:170px;overflow:hidden;margin:0 0 8px;display:flex;align-items:center;justify-content:flex-start;gap:8px}.attachment-preview img,.attachment-preview video{max-width:220px;max-height:160px;border-radius:10px;object-fit:contain;background:#0c1018}.attachment-preview audio{max-width:100%;height:38px}.attachment-preview.preview-round video{width:144px;height:144px;object-fit:cover;border-radius:50%}.transfer-status{padding:10px 12px;border:1px solid #849dcc44;background:#25334d66;border-radius:10px;margin-bottom:10px;font-size:12px;color:#cad7f4}.transfer-track{height:3px;background:#a2b5d126;border-radius:3px;overflow:hidden;margin-top:9px}.transfer-track i{display:block;height:100%;background:#b1c5ff;border-radius:3px;transition:width .15s}.transfer-track.indeterminate i{animation:mediaTransfer 1.4s ease-in-out infinite alternate}@keyframes mediaTransfer{from{transform:translateX(0)}to{transform:translateX(145%)}}@media(prefers-reduced-motion:reduce){.transfer-track.indeterminate i{animation:none}}@media(max-width:780px){.media-player{gap:9px}.media-player.is-note{width:min(220px,calc(100vw - 110px))}.media-play{width:42px;height:42px}.media-title{font-size:12px}.media-state{font-size:9px}.attachment-preview img,.attachment-preview video{max-height:130px}.attachment-preview.preview-round video{width:120px;height:120px}.media-stage{max-height:330px}}

/* Scale the entire interface while retaining a full-height mobile workspace. */
:root{--ui-scale:1;--ui-viewport-height:100dvh}
body{zoom:var(--ui-scale)}
.app-shell{position:relative}
.app-shell,.loading-screen,.login-screen{height:calc(var(--ui-viewport-height) / var(--ui-scale))!important;min-height:0!important}
.dialog-modal{width:min(520px,calc(100vw / var(--ui-scale) - 28px));max-height:calc(var(--ui-viewport-height) / var(--ui-scale) - 28px)}
.ui-scale-control{display:flex;flex-direction:column;gap:18px}
.ui-scale-control p{margin:0;line-height:1.6}
.ui-scale-buttons{display:flex;align-items:center;justify-content:center;gap:24px}
.ui-scale-buttons button{width:48px;height:46px;font-size:24px}
#ui-scale-value{font-size:28px;font-weight:700;font-variant-numeric:tabular-nums;min-width:90px;text-align:center}
#ui-scale-range{width:100%;padding:0;accent-color:var(--blue);height:36px;cursor:pointer}
@media(max-width:780px){
 .dialog-modal{width:min(520px,calc(100vw / var(--ui-scale) - 22px));max-height:calc(var(--ui-viewport-height) / var(--ui-scale) - 24px)}
 .login-card{max-width:440px}
}

.pack-photo-select{position:relative;text-align:left}
.pack-photo-select.selected{border-color:var(--blue);box-shadow:0 0 0 2px var(--blue)}
.pack-selection-mark{position:absolute;top:13px;right:13px;width:25px;height:25px;border-radius:50%;border:2px solid #c5d1ee;background:#141a29a6;display:grid;place-items:center;color:#162032;font-size:13px;font-style:normal;font-weight:700}
.selected .pack-selection-mark{background:var(--blue);border-color:var(--blue)}
.pack-selection-footer{position:sticky;bottom:-1px;background:var(--panel);padding:16px 0 0;display:flex;flex-direction:column;gap:10px;z-index:1;border-top:1px solid var(--border);margin-top:16px}
.pack-draft-preview{display:flex;gap:6px;overflow-x:auto;padding:0 0 8px;max-width:100%}
.pack-draft-preview img{width:70px;height:70px;object-fit:cover;border-radius:8px;flex-shrink:0}

/* Telegram-style touch gestures; vertical scrolling stays native. */
.dialog-row,.message-bubble{touch-action:pan-y pinch-zoom;transform:translateX(var(--gesture-offset,0px));transition:transform .16s ease}
.gesture-moving{transition:none!important;will-change:transform}
.gesture-ready{outline:2px solid var(--blue);outline-offset:-2px}
.message-bubble:focus-visible{outline:2px solid var(--blue);outline-offset:3px}
.quick-reactions{display:flex;justify-content:space-between;gap:6px;padding:0 0 14px;margin-bottom:6px;border-bottom:1px solid var(--border)}
.quick-reaction{font-size:1.5rem;min-height:44px;min-width:40px;flex:1;border-radius:12px;border:1px solid transparent;background:var(--panel);cursor:pointer}
.quick-reaction:hover,.quick-reaction:focus-visible,.quick-reaction.chosen{background:var(--hover);border-color:var(--blue)}
.quick-reaction:disabled{opacity:.5;cursor:wait}
.delete-dialog-option{display:flex;gap:10px;align-items:center;margin:20px 0;font-size:.875rem}
.forwarded-label{display:block;color:var(--blue);font-size:.75rem;line-height:1.4;margin-bottom:7px;overflow-wrap:anywhere}
@media(pointer:coarse){.message-bubble,.dialog-row{-webkit-touch-callout:none;user-select:none}}
@media(prefers-reduced-motion:reduce){.dialog-row,.message-bubble{transition:none}}

.account-ready-for-issue{margin-top:18px;padding:12px 10px;border:1px solid #397b62;border-radius:10px;background:#19372b;color:#a9ebc8;font-size:11px;font-weight:700;text-align:center;letter-spacing:.06em}.pack-photo video{width:100%;max-height:160px;object-fit:contain;background:#0c0d10;border-radius:8px}.pack-draft-preview video{width:100%;max-height:180px;border-radius:8px}
