.channels-page{max-width:1500px;margin:auto}.channels-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:22px}.channels-heading h1{margin:7px 0;font-size:32px}.channels-heading p{margin:0}.channel-toolbar{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.channels-layout{display:grid;grid-template-columns:300px minmax(0,1fr);height:min(760px,calc(100dvh - 240px));min-height:420px;border:1px solid #dedfd7;border-radius:18px;background:#fff;overflow:hidden}.channel-list{display:flex;flex-direction:column;min-height:0;border-right:1px solid #e6e7df;background:#fcfcf9}.channel-filters{padding:18px;border-bottom:1px solid #e6e7df}.channel-filters select{width:100%;border:1px solid #d9ded6;border-radius:10px;padding:10px;background:white;font:inherit}.channel-list-items{overflow:auto;min-height:0;flex:1}.channel-list-item{width:100%;display:flex;flex-direction:column;align-items:flex-start;text-align:left;gap:8px;padding:18px;border:0;border-bottom:1px solid #e9eae4;background:transparent;color:#292d29;cursor:pointer}.channel-list-item:hover,.channel-list-item.selected{background:#eaf3ed}.channel-list-item.selected{box-shadow:inset 3px 0 #00644f}.channel-list-item strong{font-size:16px}.channel-list-item>span:not(.channel-badge),.channel-list-item small{color:#798279;font-size:12px;overflow-wrap:anywhere}.channel-list-line{display:flex;align-items:center;justify-content:space-between;width:100%}.channel-badge{display:inline-flex;border-radius:6px;padding:4px 7px;font-size:10px;letter-spacing:.025em;font-weight:600;background:#ecefea;color:#49574c}.channel-badge.instagram{background:#f7edf1;color:#945474}.channel-badge.threads,.channel-badge.threads_direct{background:#e9edeb;color:#404d44}.channel-badge.telegram{background:#edf3f7;color:#3c6b86}.channel-dot{width:7px;height:7px;border-radius:50%;background:#bc8954}.channel-empty-list{color:#7a847c;padding:24px;line-height:1.6}.channel-conversation{display:flex;flex-direction:column;min-width:0;min-height:0}.channel-welcome{margin:auto;padding:32px;text-align:center;max-width:500px}.channel-welcome-icon{display:inline-flex;align-items:center;justify-content:center;width:76px;height:76px;border-radius:24px;background:#edf3ec;color:#05614d;margin-bottom:12px}.channel-welcome h2{font-size:22px;margin:12px 0}.channel-welcome p{color:#7a817b;line-height:1.7}.channel-chat-header{display:flex;align-items:center;gap:12px;padding:16px 20px;border-bottom:1px solid #e4e6df;flex-shrink:0}.channel-chat-header>div{flex:1;min-width:0}.channel-chat-header strong,.channel-chat-header small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.channel-chat-header strong{font-size:16px}.channel-chat-header small{font-size:11px;margin-top:4px;color:#7a837c}.channel-chat-header .icon-btn{flex-shrink:0}.channel-back{display:none!important}.channel-context{display:flex;justify-content:space-between;align-items:center;gap:8px;background:#f7f8f3;padding:8px 20px;font-size:12px;flex-shrink:0;flex-wrap:wrap}.channel-context .text-btn{font-size:12px}.channel-messages{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:24px;display:flex;flex-direction:column;gap:20px;background:#fdfdfa}.social-message{max-width:82%;align-self:flex-start;min-width:0}.social-message.out{align-self:flex-end}.social-message.system{align-self:center;color:#85897e}.social-bubble{padding:14px 17px;border:1px solid #e1e4dc;border-radius:16px 16px 16px 4px;background:white;overflow-wrap:anywhere}.social-message.out .social-bubble{background:#e9f2e9;border-color:#dce8db;border-radius:16px 16px 4px 16px}.social-bubble p{white-space:pre-wrap;margin:0;line-height:1.6;font-size:14px}.social-message>small{display:block;color:#7d867f;margin:7px 3px;font-size:10px}.social-message.out>small{text-align:right}.social-attachment{display:flex;flex-direction:column;gap:8px;margin-top:10px}.social-attachment img,.social-attachment video{max-height:340px;max-width:100%;border-radius:10px}.social-attachment audio{max-width:100%;width:280px}.social-attachment a{font-size:12px;color:#00624e}.social-file-missing{font-size:12px!important;color:#877047}.social-change{font-size:11px;color:#797b70;background:#f4f2e9;padding:8px 10px;border-radius:8px;margin-top:8px}.social-change summary{cursor:pointer}.social-change p{white-space:pre-wrap}.channel-compose-wrap{padding:10px 18px 16px;border-top:1px solid #e5e6df;background:white;flex-shrink:0}.channel-rule{font-size:10px;color:#7a817c;line-height:1.5;margin:0 0 8px}.channel-compose{display:flex;gap:10px;align-items:flex-end}.channel-compose textarea{flex:1;min-width:0;border:1px solid #dce1d8;border-radius:12px;background:#fafbf7;padding:12px;font-size:16px;resize:none;max-height:100px;min-height:46px}.channel-compose .primary{height:46px;min-width:46px;padding:10px}.channel-error{padding:10px 14px;border-radius:10px;background:#fff5e9;color:#865e34;font-size:13px;line-height:1.5}.channel-no-send{font-size:12px;color:#7b857c}.channel-older{align-self:center}

/* Account connections share one responsive spacing system. */
.channel-settings{margin-top:24px;padding:28px}
.channel-settings-heading,.channel-app-heading,.channel-browser-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.channel-settings-heading h2{margin:0;font-size:20px;line-height:1.4}
.channel-settings-heading>.text-btn{flex-shrink:0}
.channel-settings .tag{font-size:11px;white-space:normal;line-height:1.4}
.channel-settings .form-error,.channel-settings-loading{margin:18px 0 0;line-height:1.6}
.channel-apps{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;margin-top:22px;align-items:start}
.channel-apps article{padding:20px;border:1px solid var(--line);border-radius:12px;background:#fcfcfa;min-width:0}
.channel-app-heading{margin-bottom:20px;gap:8px}
.channel-apps h3{margin:0;font-size:16px;line-height:1.4}
.channel-apps form{display:grid;gap:14px;margin:0 0 16px}
.channel-apps form>.secondary{justify-self:start}
.channel-apps .field{margin:0;font-size:13px;gap:6px}
.channel-apps input{width:100%;min-width:0}
.channel-apps details{margin-top:18px;padding-top:14px;border-top:1px solid var(--line);font-size:12px;line-height:1.5}
.channel-apps details label{display:block;margin-top:14px;color:var(--secondary)}
.channel-apps details input{font:12px ui-monospace,monospace;margin-top:6px;padding:10px;border:1px solid var(--line);border-radius:8px;background:white}
.channel-apps summary{cursor:pointer;color:var(--green);padding:4px 0}
.channel-apps .meta{font-size:12px;overflow-wrap:anywhere;margin:12px 0 0;line-height:1.6}
.channel-account{display:flex;flex-direction:column;gap:6px;padding:12px;margin-top:16px;border-radius:8px;background:var(--green-soft);font-size:13px;overflow-wrap:anywhere}
.channel-account small{color:var(--secondary);line-height:1.5}
.channel-browser{padding:20px;margin-top:20px;border:1px solid var(--line);border-radius:12px;background:#fcfcfa}
.channel-browser-heading{align-items:flex-start}
.channel-browser h3{margin:0;font-size:16px;line-height:1.4}
.channel-browser-heading .meta{margin:5px 0 0;font-size:12px;line-height:1.5}
.channel-browser-description{margin:16px 0 0;font-size:14px;line-height:1.6}
.channel-browser-detail{margin:6px 0 0;color:var(--secondary);font-size:13px;line-height:1.6;overflow-wrap:anywhere;max-width:720px}
.channel-browser .channel-toolbar{margin-top:16px;gap:8px 12px}
.channel-browser .channel-browser-scan{margin:14px 0 0;font-size:12px;line-height:1.6}
.channel-settings-footer{margin-top:20px;padding-top:16px;border-top:1px solid var(--line);font-size:13px;line-height:1.6}
.channel-settings-footer a{color:var(--green);text-decoration:none}
.channel-settings-footer a:hover{text-decoration:underline}
.channel-client-panel{padding:22px;margin-top:20px}
.channel-client-panel h3{margin:0;font-size:17px}
.channel-client-panel .meta{margin:8px 0 0;line-height:1.6}
.channel-client-panel>.secondary{margin-top:14px}
.channel-loading{padding:40px}.channel-list-item:focus-visible,.channel-compose textarea:focus-visible{outline:3px solid #a5cdbc;outline-offset:-3px}
@media(max-width:900px){.channels-layout{grid-template-columns:240px 1fr}.channel-apps{grid-template-columns:1fr}.channels-heading{align-items:flex-start}.channels-heading h1{font-size:26px}.channels-heading .eyebrow{font-size:9px}.channel-toolbar{gap:6px}.channel-toolbar button{font-size:12px}}
@media(max-width:640px){.channels-heading{padding:0 0 10px;margin:0}.channels-heading p,.channels-heading .eyebrow{display:none}.channels-heading h1{font-size:24px}.channels-layout{display:block;height:calc(var(--crm-vh,100dvh) - 200px);min-height:300px;border-radius:14px}.channel-list{height:100%;border:0}.channel-conversation{display:none}.channels-page.has-selection .channel-list{display:none}.channels-page.has-selection .channel-conversation{display:flex;height:100%}.social-chat-mobile #app .sidebar,.social-chat-mobile #app .topbar,.social-chat-mobile .channels-heading,.social-chat-mobile .mobile-chat-top,.social-chat-mobile .workspace-helpbar,.social-chat-mobile .team-topbar{display:none!important}.social-chat-mobile #app main{position:fixed;inset:auto;left:0;right:0;top:var(--crm-vtop,0px);height:var(--crm-vh,100dvh);padding:0!important;margin:0!important;z-index:55;background:white;overflow:hidden}.social-chat-mobile .channels-page,.social-chat-mobile .channels-layout{height:100%;min-height:0;margin:0;border:0;border-radius:0}.channel-back{display:inline-flex!important}.channel-chat-header{padding:10px 12px;gap:8px;min-height:56px}.channel-chat-header strong{font-size:16px}.channel-context{padding:6px 12px}.channel-context>span{font-size:11px}.channel-messages{padding:14px;gap:14px}.social-message{max-width:90%}.social-bubble{padding:12px}.social-bubble p{font-size:15px}.channel-compose-wrap{padding:8px 10px max(10px,env(safe-area-inset-bottom))}.channel-rule{font-size:9px;margin-bottom:5px}.channel-settings{padding:18px}.channel-settings-heading{gap:8px}.channel-settings-heading h2{font-size:18px}.channel-apps{gap:14px;margin-top:18px}.channel-apps article,.channel-browser{padding:16px}.channel-browser{margin-top:14px}.channel-apps .field input{font-size:16px}.channel-browser .channel-toolbar{align-items:stretch;flex-direction:column}.channel-browser .channel-toolbar button{justify-content:center;min-height:44px;font-size:13px}.channel-settings-footer{font-size:12px}.channel-client-panel{padding:18px}}

.channels-page .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}

/* Integrations: status first, configuration only when requested. */
.integrations-workspace{max-width:1200px}.integrations-heading{display:flex;justify-content:space-between;align-items:center;gap:16px;margin:24px 0}.integrations-heading h2{font-size:22px;margin:0 0 6px}.integrations-heading p{margin:0}
.integration-cards{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.integration-card{border:1px solid var(--line);border-radius:16px;padding:22px;background:#fff;display:flex;flex-direction:column;align-items:flex-start;min-width:0}.integration-card.selected{border-color:#6c9c88;box-shadow:0 0 0 1px #6c9c88}.integration-card header{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%}.integration-card h3{font-size:18px;margin:0}.integration-card header .channel-badge{display:none}.integration-description{font-size:13px;color:var(--secondary);line-height:1.5;margin:10px 0 20px}.integration-card [data-integration-status]{flex:1;min-height:78px}.integration-card .meta{font-size:12px;line-height:1.5;margin:9px 0 18px;overflow-wrap:anywhere}.integration-state{font-size:12px;padding:5px 9px;border-radius:7px;display:inline-block;background:#f0f1eb;color:#717569}.integration-state.ready{background:#e8f2e9;color:#17604b}.integration-state.attention{background:#fff1dd;color:#8d601e}.integration-account{display:block;margin-top:12px;font-size:13px}.integration-card>.secondary{font-size:13px;min-height:40px}.integration-detail{margin-top:24px}.integration-detail .channel-settings,.integration-detail .tg-account-panel{margin-top:0}.integration-detail .channel-apps{grid-template-columns:1fr}.integration-detail .channel-apps:empty{display:none}.integration-detail .channel-apps article{background:transparent;border:0;padding:0}.integration-detail .channel-apps form{max-width:580px}.integration-detail .channel-browser{margin-top:22px}.integration-detail .tg-account-panel{padding:26px}.integration-detail .tg-account-heading h2{font-size:22px}.integration-detail .tg-account-eyebrow{display:none}

/* One conversation canvas, including the existing Telegram media controls. */
.channels-page{max-width:1700px}.channels-layout{position:relative;grid-template-columns:260px minmax(0,1fr);height:calc(100dvh - 200px);min-height:420px;max-height:950px}.channels-layout.with-client{grid-template-columns:240px minmax(0,1fr) 260px}.channel-filters{display:grid;gap:9px;padding:14px}.channel-filters input{min-width:0;width:100%;border:1px solid var(--line);border-radius:10px;background:#fff;padding:11px;font:inherit;font-size:14px}.channel-filters select{font-size:13px}.channel-list-item{gap:7px;padding:16px}.channel-list-item strong{font-size:14px}.channel-list-item>span{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.channel-telegram{height:100%;min-height:0;display:flex;flex-direction:column}.channel-telegram .chat-grid{display:flex;flex:1;min-height:0;gap:0}.channel-telegram .chat-aside{display:none}.channel-telegram .panel.chat{display:flex;flex-direction:column;flex:1;min-width:0;min-height:0;height:100%;max-height:none;margin:0;border:0;border-radius:0;overflow:hidden}.channel-telegram .chat-title{padding:12px 16px;gap:10px;min-height:64px;flex-shrink:0;flex-wrap:nowrap}.channel-telegram .chat-heading-copy{flex:1;min-width:0}.channel-telegram .chat-heading-copy b{display:block;font-size:16px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.channel-telegram .chat-heading-copy small{font-size:11px;margin-top:4px}.channel-telegram .chat-heading-actions{display:flex;align-items:center;gap:6px;flex-shrink:0}.channel-telegram .chat-media-link{font-size:0;padding:8px;min-width:36px;min-height:36px;margin:0}.channel-telegram .chat-media-link svg{width:20px;height:20px}.channel-telegram .messages{flex:1;min-height:0;max-height:none;padding:20px;overflow:auto;overscroll-behavior:contain}.channel-telegram .composer{position:static;flex-shrink:0;padding:12px;gap:8px;margin:0;background:#fff}.channel-telegram .composer textarea{font-size:16px;min-height:42px;max-height:104px}.channel-telegram .composer .primary{width:44px;height:44px;padding:10px}.channel-telegram .chat-media-panel{height:100%;overflow:auto;margin:0;border:0;border-radius:0}.channel-telegram .message .bubble{max-width:100%}.channel-telegram #reply-pilot-slot{flex-shrink:0;max-height:35%;overflow:auto}
.dialog-client{border-left:1px solid var(--line);background:#fafbf7;padding:20px;overflow:auto;min-width:0;min-height:0;overflow-wrap:anywhere;font-size:13px}.dialog-client header{display:flex;align-items:center;justify-content:space-between}.dialog-client h2{font-size:11px;text-transform:uppercase;letter-spacing:.1em;color:var(--secondary);margin:0}.dialog-client h3{font-size:20px;margin:20px 0 7px;overflow-wrap:anywhere}.dialog-client h4{font-size:13px;margin:0 0 14px}.dialog-client h4 span{color:var(--secondary);font-weight:400;margin-left:5px}.dialog-client dl{margin:24px 0}.dialog-client dt{font-size:11px;color:var(--secondary);margin:18px 0 7px}.dialog-client dd{margin:0;line-height:1.6}.dialog-client section{border-top:1px solid var(--line);padding-top:20px;margin:22px 0}.dialog-client section p{line-height:1.5;margin:12px 0}.dialog-client small{display:block;font-size:11px;margin-top:5px;color:var(--secondary)}.dialog-client .text-btn{font-size:12px;line-height:1.5;text-align:left;justify-content:flex-start}.dialog-client .secondary,.dialog-client .primary{font-size:12px;width:100%;justify-content:center;min-height:40px}.dialog-client-actions{display:grid;gap:8px}.dialog-context-close,.dialog-context-shade{display:none!important}
@media(min-width:1201px){.channel-chat-header [data-channel-context],.channel-telegram [data-channel-context]{display:none}}
@media(max-width:1200px){.channels-layout.with-client{grid-template-columns:240px minmax(0,1fr)}.dialog-client{display:none}.dialog-client.is-open{display:block;position:absolute;z-index:5;right:0;top:0;bottom:0;width:320px;max-width:90%;box-shadow:-10px 0 35px #19362720}.dialog-client .dialog-context-close{display:inline-flex!important}.dialog-context-shade{display:block!important;position:absolute;inset:0;z-index:4;border:0;border-radius:0;background:#122a2533}.dialog-client.is-open{z-index:5}}
@media(max-width:640px){.integration-cards{grid-template-columns:1fr;gap:12px}.integration-card{padding:18px}.integrations-heading{align-items:flex-start;margin:16px 0}.integrations-heading h2{font-size:20px}.integrations-heading>.text-btn{font-size:12px}.integration-detail .tg-account-panel{padding:18px}.channels-layout,.channels-layout.with-client{display:block;height:calc(var(--crm-vh,100dvh) - 165px);min-height:280px}.social-chat-mobile .channels-layout{height:100%;min-height:0;max-height:none}.social-chat-mobile .channel-telegram{height:100%}.channel-telegram .chat-title{min-height:56px;padding:8px 10px;gap:7px}.channel-telegram .chat-heading-actions{gap:2px}.channel-telegram .messages{padding:14px}.channel-telegram .composer{padding:8px 10px max(8px,env(safe-area-inset-bottom));gap:5px}.channel-telegram .composer .icon-btn{min-width:36px;width:36px}.channel-telegram .composer textarea{padding:10px 4px}.social-chat-mobile .channel-error{position:absolute;top:56px;left:10px;right:10px;z-index:3;font-size:11px}.channel-chat-header .icon-btn{min-width:32px}.dialog-client.is-open{width:340px;max-width:92%;padding:18px}.dialog-client .secondary,.dialog-client .primary{min-height:44px;font-size:14px}}

@media(max-width:640px){.viewing-employee.social-chat-mobile #app main{top:calc(var(--crm-vtop,0px) + var(--view-as-height));height:calc(var(--crm-vh,100dvh) - var(--view-as-height))}}
