/* Uniblok — guided chat assistant */
.ua-launch { position: fixed; right: max(20px, env(safe-area-inset-right)); bottom: max(20px, env(safe-area-inset-bottom)); z-index: 100; width: 60px; height: 60px; border-radius: 50%; border: 1px solid rgba(124,255,79,.45); background: linear-gradient(150deg, #10261a, #071109); box-shadow: 0 12px 34px rgba(0,0,0,.55), 0 0 0 0 rgba(124,255,79,.0); cursor: pointer; display: grid; place-items: center; padding: 0; transition: transform .35s cubic-bezier(.22,1,.36,1), border-color .3s, box-shadow .3s; }
.ua-launch:hover { transform: translateY(-2px) scale(1.04); border-color: var(--accent, #7cff4f); box-shadow: 0 16px 40px rgba(0,0,0,.6), 0 0 24px rgba(124,255,79,.25); }
.ua-launch:focus-visible { outline: 2px solid var(--accent, #7cff4f); outline-offset: 3px; }
.ua-av { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; flex: none; font-family: var(--f-display, sans-serif); font-weight: 600; font-size: 18px; color: #031006; background: #07100c; border: 1px solid rgba(124,255,79,.35); }
.ua-av__mark { width: 62%; height: auto; display: block; }
.ua-av--launch { width: 44px; height: 44px; font-size: 20px; }
.ua-online { position: absolute; right: 5px; bottom: 5px; width: 13px; height: 13px; border-radius: 50%; background: #7cff4f; border: 2px solid #071109; animation: ua-pulse 2.4s infinite; }
@keyframes ua-pulse { 0% { box-shadow: 0 0 0 0 rgba(124,255,79,.55); } 70% { box-shadow: 0 0 0 9px rgba(124,255,79,0); } 100% { box-shadow: 0 0 0 0 rgba(124,255,79,0); } }
.ua-open .ua-launch { transform: scale(.92); }

.ua-teaser { position: fixed; right: max(20px, env(safe-area-inset-right)); bottom: calc(max(20px, env(safe-area-inset-bottom)) + 72px); z-index: 100; display: flex; align-items: center; gap: 4px; max-width: 280px; padding: 6px 6px 6px 16px; border-radius: 16px 16px 4px 16px; background: #0d1a13; border: 1px solid rgba(170,255,205,.2); box-shadow: 0 14px 40px rgba(0,0,0,.5); animation: ua-in .45s cubic-bezier(.22,1,.36,1); }
.ua-teaser[hidden] { display: none; }
.ua-teaser__text { background: none; border: 0; color: #e9f2ec; font: 500 14px/1.4 var(--f-body, sans-serif); text-align: left; cursor: pointer; padding: 6px 0; }
.ua-teaser__close { background: none; border: 0; color: #93a69b; font-size: 20px; line-height: 1; width: 32px; height: 32px; border-radius: 50%; cursor: pointer; }
.ua-teaser__close:hover { color: #e9f2ec; background: rgba(255,255,255,.06); }

.ua-panel { position: fixed; right: max(20px, env(safe-area-inset-right)); bottom: calc(max(20px, env(safe-area-inset-bottom)) + 74px); z-index: 101; width: min(390px, calc(100vw - 40px)); height: min(620px, calc(100vh - 120px)); display: flex; flex-direction: column; border-radius: 22px; overflow: hidden; background: #08110c; border: 1px solid rgba(170,255,205,.18); box-shadow: 0 30px 80px rgba(0,0,0,.65); opacity: 0; transform: translateY(14px) scale(.98); transform-origin: bottom right; transition: opacity .22s ease, transform .3s cubic-bezier(.22,1,.36,1); font-family: var(--f-body, sans-serif); color: #e9f2ec; }
.ua-panel[hidden] { display: none; }
.ua-panel.is-open { opacity: 1; transform: none; }
.ua-head { display: flex; align-items: center; gap: 12px; padding: 14px 12px 14px 16px; background: linear-gradient(180deg, #0f1f16, #0a150f); border-bottom: 1px solid rgba(170,255,205,.1); }
.ua-head__txt { flex: 1; min-width: 0; }
.ua-head__title { margin: 0; font: 600 16px/1.2 var(--f-display, sans-serif); letter-spacing: -0.01em; }
.ua-head__sub { margin: 3px 0 0; font-size: 12.5px; color: #93a69b; display: flex; align-items: center; gap: 6px; }
.ua-head__sub::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #7cff4f; flex: none; }
.ua-close { width: 40px; height: 40px; border-radius: 50%; border: 0; background: transparent; color: #93a69b; font-size: 24px; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.ua-close:hover { background: rgba(255,255,255,.06); color: #e9f2ec; }

.ua-log { flex: 1; overflow-y: auto; padding: 16px 14px 8px; display: flex; flex-direction: column; gap: 8px; overscroll-behavior: contain; scroll-behavior: smooth; }
.ua-log:focus-visible { outline: 2px solid rgba(124,255,79,.5); outline-offset: -2px; }
.ua-row { display: flex; animation: ua-in .32s cubic-bezier(.22,1,.36,1); }
.ua-row--me { justify-content: flex-end; }
@keyframes ua-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.ua-bubble { margin: 0; max-width: 84%; padding: 10px 14px; border-radius: 18px; font-size: 14.5px; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.ua-row--them .ua-bubble { background: #13231a; border: 1px solid rgba(170,255,205,.08); border-bottom-left-radius: 6px; }
.ua-row--me .ua-bubble { background: #7cff4f; color: #031006; border-bottom-right-radius: 6px; font-weight: 500; }
.ua-typing { display: inline-flex; gap: 4px; padding: 13px 14px; }
.ua-typing i { width: 7px; height: 7px; border-radius: 50%; background: #93a69b; animation: ua-dot 1.1s infinite ease-in-out; }
.ua-typing i:nth-child(2) { animation-delay: .15s; } .ua-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes ua-dot { 0%, 60%, 100% { opacity: .35; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-3px); } }

.ua-card { width: 100%; max-width: 92%; padding: 14px; border-radius: 16px; background: #0e1b14; border: 1px solid rgba(124,255,79,.25); }
.ua-summary { margin: 0; display: grid; grid-template-columns: 74px minmax(0, 1fr); gap: 6px 10px; font-size: 13.5px; }
.ua-summary dt { color: #93a69b; font-family: var(--f-mono, monospace); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; padding-top: 2px; }
.ua-summary dd { margin: 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.ua-card__acts { display: flex; align-items: center; gap: 14px; margin-top: 14px; flex-wrap: wrap; }
.ua-btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 46px; padding: 0 18px; border-radius: 999px; border: 1px solid transparent; font: 600 14.5px/1 var(--f-body, sans-serif); cursor: pointer; transition: transform .2s, background-color .2s, border-color .2s, opacity .2s; }
.ua-btn:disabled { opacity: .6; cursor: progress; }
.ua-btn:focus-visible, .ua-chip:focus-visible, .ua-link:focus-visible, .ua-send:focus-visible, .ua-close:focus-visible, .ua-teaser button:focus-visible { outline: 2px solid #7cff4f; outline-offset: 2px; }
.ua-btn--primary { background: #7cff4f; color: #031006; }
.ua-btn--primary:hover { background: #b6ff3b; }
.ua-btn--ghost { background: transparent; color: #e9f2ec; border-color: rgba(170,255,205,.25); width: 100%; margin-top: 10px; font-weight: 500; }
.ua-btn--ghost:hover { border-color: #7cff4f; }
.ua-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.ua-handoff { display: grid; gap: 8px; }
.ua-btn--app { width: 100%; min-height: 52px; font-size: 15px; }
.ua-btn--whatsapp { background: #25d366; color: #062b14; }
.ua-btn--whatsapp:hover { background: #3ee07a; }
.ua-btn--telegram { background: #2aabee; color: #04202f; }
.ua-btn--telegram:hover { background: #4cbaf2; }
.ua-note { margin: 0; font-size: 12.5px; color: #93a69b; line-height: 1.5; }
.ua-link { background: none; border: 0; padding: 4px 0; color: #7cff4f; font: inherit; font-size: 13.5px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ua-note .ua-link { font-size: 12.5px; }
.ua-ts { margin-top: 12px; min-height: 65px; }

.ua-foot { border-top: 1px solid rgba(170,255,205,.1); padding: 10px 12px 12px; background: #0a140e; }
.ua-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ua-chips:not(:empty) { margin-bottom: 10px; }
.ua-chip { min-height: 40px; padding: 8px 14px; border-radius: 999px; border: 1px solid rgba(124,255,79,.45); background: rgba(124,255,79,.06); color: #e9f2ec; font: 500 13.5px/1.2 var(--f-body, sans-serif); cursor: pointer; transition: background-color .2s, border-color .2s; text-align: left; }
.ua-chip:hover { background: rgba(124,255,79,.16); border-color: #7cff4f; }
.ua-form { display: flex; align-items: flex-end; gap: 8px; position: relative; }
.ua-form[hidden] { display: none; }
.ua-input { flex: 1; min-height: 44px; max-height: 120px; resize: none; padding: 11px 14px; border-radius: 22px; border: 1px solid rgba(170,255,205,.2); background: #050b08; color: #e9f2ec; font: 16px/1.4 var(--f-body, sans-serif); }
.ua-input:focus { outline: none; border-color: #7cff4f; box-shadow: 0 0 0 3px rgba(124,255,79,.15); }
.ua-send { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 0; background: #7cff4f; color: #031006; cursor: pointer; display: grid; place-items: center; }
.ua-send svg { width: 20px; height: 20px; fill: currentColor; }
.ua-send:hover { background: #b6ff3b; }
.ua-hp { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; opacity: 0; }

@media (max-width: 640px) {
  .ua-launch { width: 56px; height: 56px; right: max(14px, env(safe-area-inset-right)); bottom: max(14px, env(safe-area-inset-bottom)); }
  .ua-teaser { right: max(14px, env(safe-area-inset-right)); bottom: calc(max(14px, env(safe-area-inset-bottom)) + 66px); max-width: calc(100vw - 28px); }
  .ua-panel { inset: 0; right: 0; bottom: 0; width: 100%; height: 100%; height: 100dvh; border-radius: 0; border: 0; transform-origin: bottom center; }
  .ua-head { padding-top: max(14px, env(safe-area-inset-top)); }
  .ua-foot { padding-bottom: max(12px, env(safe-area-inset-bottom)); }
  /* While the chat is open on a phone the page behind it must not scroll (iOS otherwise scrolls it under the keyboard). */
  html.ua-open, html.ua-open body { overflow: hidden; overscroll-behavior: none; }
  .ua-panel { transition: opacity .22s ease; }
  .ua-open .ua-launch { display: none; }
  .ua-open body { overflow: hidden; }
  .ua-chip { min-height: 44px; }
}
@media (prefers-reduced-motion: reduce) {
  .ua-online, .ua-typing i { animation: none; }
  .ua-row, .ua-teaser { animation: none; }
  .ua-panel { transition: none; transform: none; }
  .ua-log { scroll-behavior: auto; }
}
