/* Atlas Map — помощник Atlas: кнопка микрофона в строке поиска, чат, строка ввода. */

.search-mic { color: var(--muted); }
.search-mic:hover { color: var(--blue); }
.search-mic.listening, .assistant-mic.listening { color: var(--red); animation: mic-pulse 1s infinite; }
@keyframes mic-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .45; } }

.assistant-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px 8px 16px; border-bottom: 1px solid var(--border); }
.assistant-avatar { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: linear-gradient(135deg, var(--blue), #7C3AED); color: #fff; flex: none; }
.assistant-avatar svg { width: 24px; height: 24px; }
.assistant-head-text { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.assistant-head-text b { font-size: 15px; }
.assistant-head .iconbtn.on { color: var(--blue); background: rgba(45, 108, 223, .1); }

.chat { display: flex; flex-direction: column; gap: 10px; padding: 12px 16px 8px; min-height: 120px; }
.msg { display: flex; gap: 8px; align-items: flex-end; max-width: 100%; }
.msg.user { justify-content: flex-end; }
.msg-ava { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: rgba(45, 108, 223, .12); color: var(--blue); flex: none; }
.msg-ava svg { width: 16px; height: 16px; }
.msg-bubble { max-width: 82%; padding: 9px 12px; border-radius: 14px; font-size: 14px; line-height: 1.45; background: var(--input-bg); color: var(--text); border-bottom-left-radius: 4px; overflow-wrap: anywhere; }
.msg.user .msg-bubble { background: var(--blue); color: #fff; border-bottom-left-radius: 14px; border-bottom-right-radius: 4px; }
.msg-bubble.err { background: var(--badge-closed-bg); color: var(--red); }
.msg.typing .msg-bubble { display: inline-flex; gap: 4px; padding: 12px 14px; }
.msg.typing .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--muted); animation: typing 1.2s infinite; }
.msg.typing .dot:nth-child(2) { animation-delay: .2s; }
.msg.typing .dot:nth-child(3) { animation-delay: .4s; }
@keyframes typing { 0%, 60%, 100% { transform: translateY(0); opacity: .4; } 30% { transform: translateY(-4px); opacity: 1; } }
.msg-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.act-badge { background: var(--panel); color: var(--blue); border: 1px solid var(--border); height: 20px; font-size: 11px; }
.msg-weather { display: flex; align-items: center; gap: 8px; margin-top: 8px; padding: 8px 10px; border-radius: 10px; background: var(--panel); }
.msg-weather .weather-ico { width: 28px; height: 28px; color: var(--blue); }
.msg-weather b { font-size: 18px; }
.chat-examples { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 0 0 36px; }
.chat-examples .chip.small { height: 30px; }

.assistant-row { position: sticky; bottom: 0; display: flex; align-items: center; gap: 6px; padding: 8px 12px 8px; background: var(--panel); border-top: 1px solid var(--border); }
.assistant-row .input { flex: 1; min-height: 42px; }
.assistant-send { width: 44px; min-width: 44px; height: 42px; padding: 0; border-radius: 12px; flex: none; }
.assistant-send .ico { width: 20px; height: 20px; }
.assistant-mic { width: 40px; height: 40px; flex: none; color: var(--muted); }
.assistant-mic .ico { width: 22px; height: 22px; }
.view-body[data-view="assistant"] { display: flex; flex-direction: column; min-height: calc(100% - 4px); }
.view-body[data-view="assistant"] .chat { flex: 1; }

@media (max-width: 899px) {
  .assistant-row { padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px)); }
  .msg-bubble { max-width: 86%; }
}
