/* Lanorix: кнопка чата поддержки и окно переписки. Цвета из переменных site.css. */
.lxc-fab {
  position: fixed; right: 18px; bottom: 18px; z-index: 80; width: 58px; height: 58px; padding: 0; border-radius: 50%;
  border: 0; cursor: pointer; background: var(--accent-strong, #1f6feb); color: #fff;
  box-shadow: 0 8px 28px rgba(0, 0, 0, .45), 0 0 0 0 rgba(47, 129, 247, .5);
  display: grid; place-items: center; transition: translate .2s ease, box-shadow .2s ease, background .2s ease;
  animation: lxc-pulse 3.2s ease-out 2s 3;
}
.lxc-fab:hover { translate: 0 -2px; background: var(--accent, #2f81f7); }
/* кнопка всегда в правом нижнем углу на всех страницах (не в шапке): доступна при любой прокрутке */
.lxc-fab:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.lxc-fab[hidden], .lxc-panel[hidden], .lxc-badge[hidden], .lxc-guest[hidden], .lxc-link[hidden] { display: none; }
.lxc-ico {
  display: block; width: 26px; height: 26px; background: currentColor;
  -webkit-mask: url("/chat-icon.svg") center / contain no-repeat; mask: url("/chat-icon.svg") center / contain no-repeat;
}
.lxc-fab.is-open .lxc-ico {
  -webkit-mask-image: url("/chat-close.svg"); mask-image: url("/chat-close.svg");
}
.lxc-badge {
  position: absolute; top: -3px; right: -3px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px;
  background: #e5484d; color: #fff; font: 700 12px/22px system-ui, sans-serif; text-align: center; border: 2px solid var(--bg, #0d1117);
}
@keyframes lxc-pulse { 0% { box-shadow: 0 8px 28px rgba(0,0,0,.45), 0 0 0 0 rgba(47,129,247,.55); } 70%, 100% { box-shadow: 0 8px 28px rgba(0,0,0,.45), 0 0 0 18px rgba(47,129,247,0); } }
.lxc-panel {
  position: fixed; right: 18px; bottom: 90px; z-index: 80; width: min(380px, calc(100vw - 24px)); height: min(560px, calc(100vh - 120px));
  display: flex; flex-direction: column; background: var(--panel, #161b22); color: var(--text, #e6edf3);
  border: 1px solid var(--line, #30363d); border-radius: 16px; box-shadow: 0 18px 60px rgba(0, 0, 0, .55); overflow: hidden;
  animation: lxc-in .22s ease-out;
}
@keyframes lxc-in { from { opacity: 0; translate: 0 12px; } to { opacity: 1; translate: 0 0; } }
.lxc-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 14px; background: var(--accent-strong, #1f6feb); color: #fff; }
.lxc-head strong { display: block; font-size: 1rem; }
.lxc-sub { display: block; font-size: .78rem; opacity: .85; }
.lxc-x { background: none; border: 0; color: #fff; font-size: 1.7rem; line-height: 1; width: 36px; height: 36px; cursor: pointer; border-radius: 8px; padding: 0; }
.lxc-x:hover { background: rgba(255, 255, 255, .15); }
.lxc-log { flex: 1; overflow-y: auto; padding: 12px; display: flex; flex-direction: column; gap: 8px; overscroll-behavior: contain; }
.lxc-msg { max-width: 86%; padding: 8px 12px; border-radius: 14px; overflow-wrap: anywhere; font-size: .94rem; }
.lxc-body { white-space: pre-wrap; }
.lxc-who { font-size: .75rem; opacity: .7; margin-bottom: 2px; }
.lxc-time { display: block; font-size: .7rem; opacity: .6; margin-top: 3px; text-align: right; }
.lxc-me { align-self: flex-end; background: var(--accent-strong, #1f6feb); color: #fff; border-bottom-right-radius: 4px; }
.lxc-them { align-self: flex-start; background: rgba(255, 255, 255, .08); border-bottom-left-radius: 4px; }
.lxc-sys { align-self: center; max-width: 100%; text-align: center; font-size: .8rem; opacity: .7; padding: 2px 6px; }
.lxc-status { margin: 0; padding: 0 12px; min-height: 0; color: #ff8a8a; font-size: .85rem; }
.lxc-form { padding: 10px 12px 12px; border-top: 1px solid var(--line, #30363d); display: grid; gap: 8px; }
.lxc-form textarea, .lxc-form input {
  width: 100%; box-sizing: border-box; padding: 8px 10px; border-radius: 10px; font: inherit; resize: none;
  background: rgba(255, 255, 255, .05); color: inherit; border: 1px solid var(--line, #30363d);
}
.lxc-form textarea:focus, .lxc-form input:focus { outline: 2px solid var(--accent, #2f81f7); outline-offset: 0; }
.lxc-guest { display: grid; gap: 6px; }
.lxc-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.lxc-send { background: var(--accent-strong, #1f6feb); color: #fff; border: 0; border-radius: 10px; padding: 9px 18px; font-weight: 600; cursor: pointer; min-height: 40px; }
.lxc-send:hover:not(:disabled) { background: var(--accent, #2f81f7); }
.lxc-send:disabled { opacity: .6; cursor: default; }
.lxc-link { background: none; border: 0; color: var(--accent, #2f81f7); text-decoration: underline; cursor: pointer; font-size: .82rem; padding: 6px 0; }
.lxc-file-link { border: 0; padding: 0; color: inherit; background: transparent; font: inherit; cursor: pointer; text-decoration: underline; text-align: left; }
.lxc-rate { display: grid; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line, #30363d); background: var(--panel2, #1c2128); font-size: .9rem; }
.lxc-rate[hidden] { display: none; }
.lxc-rate textarea, .lxc-rate select { width: 100%; box-sizing: border-box; padding: 8px; border-radius: 8px; font: inherit; color: inherit; background: var(--panel, #161b22); border: 1px solid var(--line, #30363d); }
.lxc-rating-row { display: flex; align-items: center; gap: 8px; }
.lxc-rating-row select { flex: 1; }
.lxc-row { flex-wrap: wrap; }
.lxc-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.lx-announce { background: linear-gradient(90deg, #1f3a6b, #2a1659); color: #fff; text-align: center; padding: 9px 16px; font-size: .92rem; position: relative; z-index: 70; }
@media (max-width: 520px) {
  .lxc-panel { right: 8px; left: 8px; width: auto; bottom: 84px; height: min(70vh, calc(100vh - 110px)); }
  .lxc-fab { right: 12px; bottom: 12px; }
}
@media (prefers-reduced-motion: reduce) { .lxc-fab, .lxc-panel { animation: none; transition: none; } }
