/* League chat bubble, matched to the dashboard's dark theme */
.lb-launch {
  position: fixed; right: 20px; bottom: 20px; z-index: 9999;
  width: 56px; height: 56px; border-radius: 50%; border: none; cursor: pointer;
  background: #fcd34d; color: #0f1117; box-shadow: 0 6px 20px rgba(0,0,0,.45);
  display: flex; align-items: center; justify-content: center;
}
.lb-launch:hover { filter: brightness(1.08); }
.lb-hide { display: none; }

.lb-panel {
  position: fixed; right: 20px; bottom: 20px; z-index: 9999;
  width: 360px; height: 520px; max-height: calc(100vh - 40px);
  display: none; flex-direction: column; overflow: hidden;
  background: #111827; color: #e2e8f0; border: 1px solid #1e293b; border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0,0,0,.55);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-size: 14px;
}
.lb-open { display: flex; }

.lb-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid #1e293b; background: #0c0f18; }
.lb-title { font-weight: 600; color: #f8fafc; }
.lb-close { background: none; border: none; color: #94a3b8; font-size: 22px; line-height: 1; cursor: pointer; }
.lb-close:hover { color: #f8fafc; }

.lb-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.lb-msg { max-width: 85%; padding: 9px 12px; border-radius: 12px; line-height: 1.45; white-space: pre-wrap; word-wrap: break-word; }
.lb-bot { align-self: flex-start; background: #1e293b; }
.lb-user { align-self: flex-end; background: #fcd34d; color: #0f1117; }
.lb-wait { color: #94a3b8; font-style: italic; }

.lb-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 14px 10px; }
.lb-chip { background: none; border: 1px solid #1e293b; color: #cbd5e1; border-radius: 999px; padding: 5px 10px; font-size: 12px; cursor: pointer; font-family: inherit; }
.lb-chip:hover { border-color: #fcd34d; color: #f8fafc; }

.lb-form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid #1e293b; }
.lb-input { flex: 1; background: #0f1117; color: #e2e8f0; border: 1px solid #1e293b; border-radius: 8px; padding: 9px 10px; font-size: 14px; font-family: inherit; }
.lb-input:focus { outline: none; border-color: #fcd34d; }
.lb-send { background: #fcd34d; color: #0f1117; border: none; border-radius: 8px; padding: 0 14px; font-weight: 600; cursor: pointer; font-family: inherit; }

html.lb-lock, html.lb-lock body { overflow: hidden; }
.lb-log { overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }

/* Phones (and short landscape screens): full-screen sheet, 16px input so iOS does not zoom, 44px tap targets */
@media (max-width: 600px), (max-height: 500px) {
  .lb-launch { right: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }
  .lb-panel {
    right: 0; left: 0; top: 0; bottom: auto; width: 100%; height: var(--lb-h, 100dvh); max-height: none;
    border-radius: 0; border: none; font-size: 15px;
  }
  .lb-head { padding: 6px 6px 6px 14px; min-height: 48px; }
  .lb-brand { display: none; }
  .lb-close { width: 44px; height: 44px; font-size: 28px; }
  .lb-msg { max-width: 92%; font-size: 15px; }
  .lb-chips { padding: 0 14px 12px; }
  .lb-chip { padding: 9px 13px; font-size: 14px; }
  .lb-form { padding: 10px 10px calc(10px + env(safe-area-inset-bottom, 0px)); }
  .lb-input { font-size: 16px; min-height: 44px; padding: 10px 12px; }
  .lb-send { min-width: 64px; min-height: 44px; font-size: 15px; }
}

@media (max-height: 500px) { .lb-chips { display: none; } }
