/* Чат сайта: без рамок + вкладка «Поддержка» (assets/js/eksupport.js). Подключается после ekchat.css. */

/* ---------- без рамок ---------- */
.ekc-card { border: 0 !important; }
.ekc-feed { border: 0 !important; background: transparent !important; border-radius: 0 !important; }
.ekc-field { border: 0 !important; background: rgba(255,255,255,.045) !important; }
.ekc-field:focus-within { border: 0 !important; box-shadow: none !important; background: rgba(255,255,255,.07) !important; }
.ekc-ibtn, .ekc-ibtn:hover, .ekc-ibtn.off { border: 0 !important; }
.ekc-online-n { border: 0 !important; }
.ekc-handle, .ekc-handle:hover { border: 0 !important; box-shadow: none !important; }
.ekc-empty-ic { border: 0 !important; box-shadow: none !important; }
.ekc-strip-u { border: 0 !important; }
.ekc-row, .ekc-row:hover, .ekc-row.ping, .ekc-row.flash { border-color: transparent !important; }
.ekc-qbtn, .ekc-chip { border: 0 !important; }
.ekc-tray { border: 0 !important; }
.ekc-actions, .ekc-pop, .ekc-toast { border: 0 !important; }
.ekc-ri { border: 0 !important; }

/* ---------- вкладки Чат / Поддержка ---------- */
.eks-tabs { display: flex; gap: 4px; padding: 3px; margin: 0 2px 8px; border-radius: 11px; background: rgba(255,255,255,.04); flex: 0 0 auto; }
.eks-tabs button { position: relative; flex: 1; border: 0; padding: 8px 10px; border-radius: 9px; background: none; color: #948fa6; font: 700 12.5px 'Manrope', sans-serif; cursor: pointer; transition: background .15s, color .15s; }
.eks-tabs button.on { background: rgba(var(--ekc-rgb, 156,39,176), .22); color: #fff; }
.eks-tabs button:hover:not(.on) { color: #ddd; }
.eks-dot { position: absolute; top: 7px; right: 10px; width: 7px; height: 7px; border-radius: 50%; background: #ff5470; }
.ekc-card.eks-on > .ekc-strip, .ekc-card.eks-on > .ekc-feed, .ekc-card.eks-on > .ekc-foot, .ekc-card.eks-on > .ekc-toast { display: none !important; }

/* ---------- поддержка ---------- */
.eks { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 8px; color: #e7e4ef; font-family: 'Manrope', sans-serif; }
.eks[hidden] { display: none; }
.eks-status { display: flex; align-items: center; gap: 8px; padding: 0 6px; font-size: 12px; font-weight: 700; color: #b3aec3; }
.eks-st-dot { width: 8px; height: 8px; border-radius: 50%; background: #6b7280; flex: 0 0 auto; }
.eks-st-dot.on { background: #2ee27a;box-shadow: none; }
.eks-sub { display: flex; gap: 4px; padding: 0 2px; }
.eks-sub button { border: 0; background: none; color: #8f8aa3; font: 700 12.5px 'Manrope', sans-serif; padding: 6px 12px; border-radius: 9px; cursor: pointer; }
.eks-sub button.on { background: rgba(255,255,255,.07); color: #fff; }
.eks-home { flex: 1; min-height: 0; overflow-y: auto; padding: 2px 2px 4px; display: flex; flex-direction: column; gap: 10px; }
.eks-home[hidden], .eks-chat[hidden] { display: none !important; }
.eks-hero { display: flex; flex-direction: column; gap: 6px; padding: 18px 16px; border-radius: 14px; background: linear-gradient(135deg, rgba(var(--ekc-rgb, 156,39,176), .2), rgba(var(--ekc-rgb, 156,39,176), .05)); text-align: center; }
.eks-hero-t { font: 800 15px 'Unbounded', 'Manrope', sans-serif; color: #fff; }
.eks-hero-d { font-size: 12.5px; color: #b9b4c9; line-height: 1.5; }
.eks-h { font-size: 10.5px;font-weight: 800;letter-spacing: normal;text-transform: none;color: #79748c;padding: 4px 4px 0; }
.eks-faq details { border-radius: 10px; }
.eks-faq details + details { margin-top: 2px; }
.eks-faq summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 10px; border-radius: 10px; font-weight: 700; font-size: 13px; color: #ece9f4; }
.eks-faq summary::-webkit-details-marker { display: none; }
.eks-faq summary::after { content: '+'; font-size: 18px; font-weight: 400; color: #8f8aa3; transition: transform .2s; }
.eks-faq details[open] summary::after { transform: rotate(45deg); }
.eks-faq summary:hover { background: rgba(255,255,255,.04); }
.eks-faq details > div { padding: 2px 10px 12px; font-size: 12.5px; line-height: 1.55; color: #b9b4c9; }
.eks-faq a, .eks-tx a { color: #e4b8f5; text-decoration: none; font-weight: 700; }
.eks-faq a:hover, .eks-tx a:hover { text-decoration: underline; }
.eks-links { display: flex; flex-wrap: wrap; gap: 6px; }
.eks-links a { padding: 7px 12px; border-radius: 9px; background: rgba(255,255,255,.05); color: #ddd; font-size: 12px; font-weight: 700; text-decoration: none; }
.eks-links a:hover { background: rgba(255,255,255,.1); color: #fff; }
.eks-go { margin-top: auto; border: 0; cursor: pointer; padding: 13px; border-radius: 12px; color: #fff; font: 800 13px 'Manrope', sans-serif; background: linear-gradient(120deg, var(--ekc-p, #9c27b0), var(--ekc-s, #7b1fa2)); }
.eks-go:hover { filter: brightness(1.1); }

.eks-chat { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 8px; }
.eks-msgs { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 2px 2px 4px; overscroll-behavior: contain; }
.eks-msgs::-webkit-scrollbar { width: 5px; } .eks-msgs::-webkit-scrollbar-thumb { background: rgba(255,255,255,.12); border-radius: 3px; }
.eks-m { max-width: 88%; padding: 9px 12px; border-radius: 14px; font-size: 13px; line-height: 1.5; background: rgba(255,255,255,.05); color: #ece9f4; align-self: flex-start; word-wrap: break-word; }
.eks-m.user { align-self: flex-end; background: rgba(var(--ekc-rgb, 156,39,176), .28); }
.eks-m.staff { background: rgba(46,226,122,.1); }
.eks-who { display: flex; align-items: center; gap: 6px; margin-bottom: 3px; font-size: 11.5px; font-weight: 800; color: #e4b8f5; }
.eks-who.staff { color: #6ee7a8; }
.eks-who i { font-style: normal; font-size: 9.5px; font-weight: 800; padding: 1px 6px; border-radius: 5px; background: rgba(255,255,255,.08); color: #b9b4c9; text-transform: lowercase; }
.eks-typing { align-self: flex-start; font-size: 12px; color: #8f8aa3; padding: 2px 6px; }
.eks-typing span { animation: eksBlink 1.2s infinite; } .eks-typing span:nth-child(2) { animation-delay: .2s; } .eks-typing span:nth-child(3) { animation-delay: .4s; }
@keyframes eksBlink { 0%, 100% { opacity: .2; } 50% { opacity: 1; } }
.eks-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 2px; }
.eks-chips:empty { display: none; }
.eks-chips button { border: 0; cursor: pointer; padding: 8px 12px; border-radius: 10px; background: rgba(255,255,255,.06); color: #ece9f4; font: 700 12.5px 'Manrope', sans-serif; transition: background .15s; }
.eks-chips button:hover { background: rgba(var(--ekc-rgb, 156,39,176), .3); color: #fff; }
.eks-comp { display: flex; align-items: flex-end; gap: 6px; }
.eks-comp textarea { flex: 1; min-width: 0; min-height: 42px; max-height: 110px; resize: none; border: 0; outline: 0; border-radius: 12px; padding: 11px 12px; background: rgba(255,255,255,.045); color: #ece9f4; font: 500 13.5px/1.4 'Manrope', sans-serif; }
.eks-comp textarea:focus { background: rgba(255,255,255,.07); }
.eks-send { flex: 0 0 auto; width: 44px; height: 44px; border: 0; border-radius: 12px; cursor: pointer; color: #fff; display: flex; align-items: center; justify-content: center; background: linear-gradient(120deg, var(--ekc-p, #9c27b0), var(--ekc-s, #7b1fa2)); }
.eks-send svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }

/* история обращений */
.eks-hist[hidden] { display: none; }
.eks-hist-l { display: flex; flex-direction: column; gap: 2px; }
.eks-hi { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 10px; border-radius: 10px; text-decoration: none; color: #ece9f4; font-size: 12.5px; font-weight: 700; }
.eks-hi:hover { background: rgba(255,255,255,.04); }
.eks-hi-n { min-width: 0; display: flex; flex-direction: column; overflow: hidden; }
.eks-hi-n small { color: #79748c; font-size: 11px; font-weight: 600; }
.eks-hi-s { flex: 0 0 auto; font-size: 11px; padding: 3px 8px; border-radius: 7px; background: rgba(234,179,8,.14); color: #fde68a; }
.eks-hi-s.approved { background: rgba(46,226,122,.14); color: #86efac; }
.eks-hi-s.rejected { background: rgba(255,84,112,.14); color: #fda4af; }

/* кнопка «Свернуть» в шапке вместо язычка сбоку */
@media (min-width: 641px) { .ekc-handle { display: none !important; } .ekc-x { display: flex !important; } }
.ekc-x { background: rgba(255,255,255,.06) !important; color: #cfc9dd !important; }
.ekc-x:hover { background: rgba(255,255,255,.12) !important; color: #fff !important; }
.ekc-x svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
/* удаление из истории и очистка переписки */
.eks-hi { padding: 0 !important; }
.eks-hi > a { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 10px; color: inherit; text-decoration: none; }
.eks-hi-x { flex: 0 0 auto; width: 26px; height: 26px; margin-right: 4px; border: 0; border-radius: 7px; background: none; color: #6b7280; font-size: 17px; line-height: 1; cursor: pointer; opacity: 0; transition: opacity .15s, color .15s, background .15s; }
.eks-hi:hover .eks-hi-x { opacity: 1; }
.eks-hi-x:hover { color: #ff5470; background: rgba(255,84,112,.12); }
@media (hover: none) { .eks-hi-x { opacity: 1; } }
.eks-sub .eks-clr { margin-left: auto; color: #79748c; }
.eks-sub .eks-clr:hover { color: #ff8599; background: rgba(255,84,112,.1); }
.eks-sub .eks-clr[hidden] { display: none; }

/* кто отвечает по обращению, роль у ответов, системные сообщения */
.eks-agent { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; background: rgba(255,255,255,.04); flex: 0 0 auto; }
.eks-agent[hidden] { display: none; }
.eks-ag-ic { flex: 0 0 auto; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: rgba(255,255,255,.06); color: #cfc9dd; }
.eks-ag-t { flex: 1; min-width: 0; display: flex; flex-direction: column; font-size: 11.5px; color: #9a95ad; line-height: 1.3; }
.eks-ag-t b { font-size: 13px; font-weight: 800; color: #fff; }
.eks-ag-t small { color: #cfc9dd; font-size: 11.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.eks-ag-no { flex: 0 0 auto; border: 0; cursor: pointer; padding: 7px 10px; border-radius: 9px; background: rgba(255,84,112,.12); color: #ff8599; font: 700 11.5px 'Manrope', sans-serif; }
.eks-ag-no:hover { background: rgba(255,84,112,.22); color: #fff; }
.eks-ag-form { display: flex; flex-direction: column; gap: 6px; width: 100%; font-size: 12.5px; color: #ece9f4; }
.eks-ag-form small { color: #9a95ad; }
.eks-ag-form textarea { width: 100%; resize: none; border: 0; outline: 0; border-radius: 9px; padding: 8px 10px; background: rgba(0,0,0,.25); color: #ece9f4; font: 500 12.5px 'Manrope', sans-serif; }
.eks-ag-form div { display: flex; gap: 6px; }
.eks-ag-form button { border: 0; cursor: pointer; padding: 7px 12px; border-radius: 9px; font: 700 12px 'Manrope', sans-serif; }
.eks-ag-ok { background: #ff5470; color: #fff; } .eks-ag-cancel { background: rgba(255,255,255,.07); color: #ddd; }
.eks-who .eks-role { display: inline-flex; align-items: center; gap: 4px; font-style: normal; text-transform: none; }
.eks-who .eks-role b { font-size: 9px; }
.eks-sys { align-self: center; max-width: 92%; text-align: center; font-size: 11.5px; color: #9a95ad; background: rgba(255,255,255,.04); padding: 6px 10px; border-radius: 9px; line-height: 1.45; }

/* свои сообщения без подложки-рамки, как у всех */
.ekc-row.mine, .ekc-row.mine:hover { background: transparent !important; box-shadow: none !important; border-color: transparent !important; }
.ekc-row.mine:hover { background: rgba(255,255,255,.03) !important; }
