/* ════════════════════════════════════════════════════════════════════════
   LIVE INSIGHTS — the Claude Design "Live" file (19.10.2026).
   Layer 1: the tag under a live game (the grade, the headline, "Ask about this").
   Layer 2: the panel — a side panel by the content column on a wide screen (the
   page stays live and usable behind it), a side panel over a scrim on a tablet,
   a bottom sheet over a scrim on a phone. bubble.js picks which.
   ════════════════════════════════════════════════════════════════════════ */

/* ── The grade: a big letter in the colour of the kind of news ── */
.bp-grade {
  flex: none; display: inline-grid; place-items: center;
  font: 800 26px/1 var(--ds-font-num); font-style: normal;
  font-variant-numeric: tabular-nums; letter-spacing: 0;
}
.bp-grade--good    { color: var(--ds-ok); }
.bp-grade--watch   { color: var(--ds-warn); }
.bp-grade--trouble { color: var(--ds-live); }
.bp-grade--big { font-size: var(--ds-fd-48); min-width: 36px; margin-top: -4px; }

/* ── Layer 1: the tag ── */
.prof-card-bubble {
  display: flex; align-items: center; gap: 8px;
  margin: 0 12px 12px; padding: 4px;
  background: var(--ds-soft); min-width: 0;
}
.pcb-open {
  flex: 1 1 0; min-width: 0; display: flex; align-items: center; gap: 10px;
  min-height: 44px; padding: 0 8px;
  border: 0; border-radius: 0; background: transparent; color: var(--ds-ink);
  font: inherit; text-align: start; cursor: pointer;
}
.pcb-open:hover { background: var(--ds-soft); }
.pcb-grade { min-width: 18px; }
.pcb-head {
  flex: 1 1 0; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font: 700 var(--ds-fs-14)/1.3 var(--ds-font); color: var(--ds-ink);
}
.pcb-ask {
  flex: none; min-height: 44px; padding: 0 14px;
  border: 0; border-radius: 0; background: var(--ds-ink); color: var(--ds-card);
  font: 800 var(--ds-fs-14)/1 var(--ds-font); white-space: nowrap; cursor: pointer;
  transition: opacity var(--ds-t-ctrl) ease;
}
.pcb-ask:hover { opacity: .88; }
.pcb-open:focus-visible, .pcb-ask:focus-visible { outline: 2px solid var(--ds-ink); outline-offset: 2px; }
@container (max-width: 559px) {
  .prof-card-bubble { margin: 0 8px 8px; }
  .pcb-ask { padding: 0 12px; }
  .pcb-grade { font-size: 24px; }
}
/* A row of the home list: the tag spans the whole row. */
.game-row .prof-card-bubble { grid-column: 1 / -1; margin: 2px 0 6px; }
.prof-card-bubble.bubble-updated { animation: bp-flash 1.2s ease-out; }
@keyframes bp-flash { 0% { box-shadow: 0 0 0 2px var(--ds-ink); } 100% { box-shadow: 0 0 0 2px transparent; } }

/* ── Layer 2: the panel ── */
.bp-scrim { display: none; }
.bp-scrim.is-on { display: block; position: fixed; inset: 0; z-index: 540; background: rgba(10, 12, 18, .45); animation: bp-fade .2s ease-out; }
.bp {
  position: fixed; z-index: 541; overflow: auto; box-sizing: border-box;
  background: var(--ds-card); color: var(--ds-ink);
  box-shadow: 0 18px 50px rgba(12, 22, 48, .22);
  font-family: var(--ds-font);
}
html[data-theme="dark"] .bp { box-shadow: 0 18px 50px rgba(0, 0, 0, .55); }
.bp--side {
  top: 16px; max-height: calc(100vh - 32px);
  padding: 18px 20px 22px;
  border: 1px solid var(--ds-line); border-top: 3px solid var(--ds-ink);
  animation: bp-side .24s ease-out;
}
.bp--sheet {
  bottom: 0; max-height: 88vh;
  padding: 12px 16px max(22px, env(safe-area-inset-bottom));
  border-radius: var(--ds-r-sheet) var(--ds-r-sheet) 0 0;
  animation: bp-sheet .24s ease-out;
}
.bp-grab { display: block; width: 40px; height: 4px; margin: 0 auto 14px; border-radius: var(--ds-r-pill); background: var(--ds-line); }
.bp.is-closing { animation: bp-out .18s ease-in forwards; }
.bp-top { display: flex; align-items: flex-start; gap: 14px; }
.bp-hd { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 6px; padding-top: 2px; }
.bp-kicker { display: flex; align-items: center; gap: 7px; font: 800 var(--ds-fs-12)/1.2 var(--ds-font); letter-spacing: .02em; color: var(--ds-ink2); }
.bp-lgdot { width: 8px !important; height: 8px !important; border-radius: 50%; }
.bp-hd h2 { margin: 0; font: 900 var(--ds-fs-20)/1.3 var(--ds-font); color: var(--ds-ink); text-align: start; text-wrap: pretty; }
.bp-x {
  flex: none; display: grid; place-items: center; width: 44px; height: 44px; padding: 0;
  border: 1.5px solid var(--ds-line); border-radius: 0; background: transparent; color: var(--ds-ink); cursor: pointer;
}
.bp-x:hover { border-color: var(--ds-ink); }

/* The fuel gauge (owner, 21.10): how worn the player is, on an insight about a player. */
.bp-fuel { margin-top: 14px; }
.bp-fuel-row { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; font: 800 var(--ds-fs-12)/1.2 var(--ds-font); color: var(--ds-ink2); }
.bp-fuel-row b { font: 800 var(--ds-fs-14)/1 var(--ds-font-num); font-variant-numeric: tabular-nums; color: var(--ds-ink); }
.bp-fuel-track { height: 6px; background: var(--ds-soft); }
.bp-fuel-track i { display: block; height: 100%; background: var(--ds-ok); }
.bp-fuel--warn .bp-fuel-track i { background: var(--ds-warn); }
.bp-fuel--low .bp-fuel-track i { background: var(--ds-live); }

.bp-score {
  display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 10px;
  margin-top: 16px; padding: 12px; background: var(--ds-soft);
}
.bp-team { display: flex; align-items: center; gap: 8px; min-width: 0; font: 700 var(--ds-fs-14)/1.25 var(--ds-font); overflow-wrap: break-word; }
.bp-team--end { justify-content: flex-end; text-align: end; }
.bp-nums { display: flex; align-items: baseline; gap: 6px; }
.bp-nums b { font: 800 32px/.9 var(--ds-font-num); font-style: normal; font-variant-numeric: tabular-nums; direction: ltr; unicode-bidi: isolate; }
.bp-nums i { font: 600 17px/1 var(--ds-font-num); font-style: normal; color: var(--ds-ink2); }
.bp-pill-row { grid-column: 1 / -1; display: flex; justify-content: center; }
.bp-subject { display: flex; align-items: center; gap: 8px; margin-top: 14px; font: 700 var(--ds-fs-14)/1.3 var(--ds-font); }
.bp-subject span { font-weight: 600; color: var(--ds-ink2); }
.bp-body { margin: 12px 0 0; font: 500 var(--ds-fs-15)/1.65 var(--ds-font); color: var(--ds-ink); text-align: start; text-wrap: pretty; }

/* The chat under it: the question offered, the messages, the box. */
.bp-chat { display: flex; flex-direction: column; gap: 10px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--ds-line); }
.bp-msgs { display: flex; flex-direction: column; gap: 10px; }
.bp-msgs:empty { display: none; }
.bp-msg { max-width: 88%; padding: 10px 14px; border-radius: var(--ds-r-bubble); font: 600 var(--ds-fs-14)/1.5 var(--ds-font); text-wrap: pretty; white-space: pre-wrap; overflow-wrap: break-word; animation: bp-side .2s ease-out; }
.bp-msg--user { align-self: flex-end; background: var(--ds-ink); color: var(--ds-bg); }
.bp-msg--professor { align-self: flex-start; background: var(--ds-soft); color: var(--ds-ink); font-weight: 500; line-height: 1.6; }
.bp-msg.is-loading { display: flex; gap: 5px; padding: 13px 14px; }
.bp-msg.is-loading i { display: block; width: 6px; height: 6px; border-radius: 50%; background: var(--ds-ink2); animation: bp-dot 1.1s ease-in-out infinite; }
.bp-msg.is-loading i:nth-child(2) { animation-delay: .15s; }
.bp-msg.is-loading i:nth-child(3) { animation-delay: .3s; }
.bp-sug {
  align-self: flex-start; max-width: 100%; min-height: 44px; padding: 8px 14px;
  border: 1px solid var(--ds-line); border-radius: 0; background: var(--ds-card); color: var(--ds-ink);
  font: 700 var(--ds-fs-14)/1.35 var(--ds-font); text-align: start; cursor: pointer;
}
.bp-sug:hover { border-color: var(--ds-ink); }
.bp-sug[hidden] { display: none; }
.bp-ask { display: flex; border: 1.5px solid var(--ds-ink); }
.bp-input {
  flex: 1 1 0; min-width: 0; min-height: 48px; padding: 0 14px;
  border: 0; border-radius: 0; background: transparent; color: var(--ds-ink); font: 500 var(--ds-fs-15) var(--ds-font);
  outline-offset: -3px;
}
.bp-send { flex: none; display: grid; place-items: center; width: 52px; border: 0; border-radius: 0; background: var(--ds-ink); color: var(--ds-bg); cursor: pointer; }
.bp-lab {
  margin-top: 10px; min-height: 44px; padding: 0; border: 0; background: transparent; color: var(--ds-ink);
  font: 800 var(--ds-fs-14) var(--ds-font); text-decoration: underline; text-underline-offset: 3px; cursor: pointer;
}
.bp-lab[hidden], .bp-open[hidden] { display: none; }
.bp-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.bp-open, .bp-close {
  min-height: 44px; padding: 0 18px; border-radius: 0; background: transparent; color: var(--ds-ink);
  font: 800 var(--ds-fs-14) var(--ds-font); cursor: pointer; transition: background var(--ds-t-ctrl) ease;
}
.bp-open { flex: 1 1 auto; border: 1.5px solid var(--ds-ink); }
.bp-close { border: 1.5px solid var(--ds-line); }
.bp-open:hover, .bp-close:hover { background: var(--ds-soft); }
/* Broadcast sync — not in the design; an existing feature kept, quietly, at the bottom. */
.bp-sync { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--ds-line); font: 600 var(--ds-fs-12)/1.3 var(--ds-font); color: var(--ds-ink2); }
.bp-ghost { min-height: 32px; padding: 0 10px; border: 1px solid var(--ds-line); border-radius: 0; background: transparent; color: var(--ds-ink2); font: 700 var(--ds-fs-12) var(--ds-font); cursor: pointer; }
.bp-ghost:hover { border-color: var(--ds-ink); color: var(--ds-ink); }
.bp-sync-fb { min-width: 0; }
.bp button:focus-visible, .bp-input:focus-visible { outline: 2px solid var(--ds-ink); outline-offset: 2px; }
.bp-input:focus-visible { outline-offset: -3px; }

@keyframes bp-side { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes bp-sheet { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: none; } }
@keyframes bp-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes bp-out { to { opacity: 0; transform: translateY(10px); } }
@keyframes bp-dot { 0%, 80%, 100% { opacity: .25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
@media (prefers-reduced-motion: reduce) { .bp, .bp-scrim, .bp-msg, .bp-msg i, .prof-card-bubble { animation-duration: .01ms !important; animation-iteration-count: 1 !important; } }
