.ai-btn { position: fixed; right: 16px; bottom: 16px; z-index: 80; padding: 10px 16px; border-radius: 999px; border: 1px solid var(--line, #2c3136); background: var(--bg-3, #202428); color: var(--text, #e9ecef); font: 600 14px/1 var(--font, system-ui); cursor: pointer; box-shadow: 0 4px 16px rgba(0,0,0,.3); }
.ai-btn:hover { border-color: var(--accent, #f08a24); }
.ai-panel { position: fixed; right: 16px; bottom: 64px; z-index: 81; width: min(380px, calc(100vw - 32px)); max-height: min(560px, 70vh); display: flex; flex-direction: column; background: var(--bg-2, #171a1d); border: 1px solid var(--line, #2c3136); border-radius: var(--radius, 6px); box-shadow: 0 12px 32px rgba(0,0,0,.4); }
.ai-panel[hidden] { display: none; }
.ai-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--line, #2c3136); }
.ai-x { background: none; border: 0; color: var(--muted, #9aa3ab); font-size: 22px; line-height: 1; cursor: pointer; }
.ai-log { flex: 1; overflow-y: auto; padding: 12px 14px; font-size: 14px; }
.ai-m { margin: 0 0 10px; padding: 8px 10px; border-radius: var(--radius, 6px); }
.ai-m--a { background: var(--bg-3, #202428); }
.ai-m--u { background: rgba(240,138,36,.12); margin-left: 24px; }
.ai-form { padding: 10px 14px 14px; border-top: 1px solid var(--line, #2c3136); }
.ai-form textarea { width: 100%; padding: 8px 10px; border-radius: var(--radius, 6px); border: 1px solid var(--line, #2c3136); background: var(--bg, #0f1113); color: var(--text, #e9ecef); font: inherit; font-size: 16px; resize: vertical; }
.ai-actions { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.ai-actions .btn { padding: 8px 12px; font-size: 14px; }
.ai-sr { position: absolute; left: -9999px; }
@media (max-width: 560px) {
  .ai-btn { right: 12px; bottom: 12px; padding: 8px 12px; font-size: 13px; }
  .ai-panel { right: 0; left: 0; bottom: 0; width: 100%; max-height: 75vh; border-radius: var(--radius, 6px) var(--radius, 6px) 0 0; }
}
