/* ── SB Inject v0.8.1 ────────────────────────────────────────────────────── */

:root {
  --sb-color: #49aff6;
  --sb-text:  #ffffff;
}

/* ── Trigger pill ─────────────────────────────────────────────────────────── */

div.summarybot-wrap {
  display: block !important;
  margin: 0.75em 0 !important;
  padding: 0 !important;
  clear: both !important;
  text-align: left !important;
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  max-width: 100% !important;
  overflow: hidden !important;
}

button.summarybot-trigger {
  display: inline-flex !important;
  align-items: center !important;
  gap: 7px !important;
  padding: var(--sb-btn-vpad, 9px) 18px !important;
  max-width: 100% !important;
  font-family: inherit !important;
  font-size: clamp(10px, 2.5vw, 13px) !important;
  font-weight: 600 !important;
  line-height: 1 !important;
  letter-spacing: 0.04em !important;
  text-transform: uppercase !important;
  white-space: nowrap !important;
  background: var(--sb-color) !important;
  color: var(--sb-text) !important;
  border: none !important;
  border-radius: 999px !important;
  box-shadow: 0 2px 12px rgba(73,175,246,.35) !important;
  animation: sb-pulse 2.4s ease-in-out infinite !important;
  cursor: pointer !important;
}

button.summarybot-trigger:hover {
  opacity: .88 !important;
  background: var(--sb-color) !important;
  color: var(--sb-text) !important;
}

@keyframes sb-pulse {
  0%,100% { box-shadow: 0 2px 12px rgba(73,175,246,.35); }
  50%      { box-shadow: 0 2px 22px rgba(73,175,246,.6);  }
}

button.summarybot-trigger .summarybot-trigger__dots {
  display: inline-flex !important;
  align-items: center !important;
  gap: 3px !important;
}

button.summarybot-trigger .summarybot-trigger__dots span {
  display: block !important;
  width: 4px !important;
  height: 4px !important;
  border-radius: 50% !important;
  background: currentColor !important;
  margin: 0 !important;
  padding: 0 !important;
  animation: sb-dot 1.2s ease-in-out infinite !important;
}

button.summarybot-trigger .summarybot-trigger__dots span:nth-child(2) { animation-delay: .2s !important; }
button.summarybot-trigger .summarybot-trigger__dots span:nth-child(3) { animation-delay: .4s !important; }

@keyframes sb-dot {
  0%,80%,100% { transform: scale(.65); opacity: .45; }
  40%         { transform: scale(1);   opacity: 1;   }
}

/* ── Overlay ──────────────────────────────────────────────────────────────── */

#summarybot-overlay {
  right: 0;
  bottom: 0;
  overflow: hidden;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 2147483647;
  background: rgba(0,0,0,.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

#summarybot-overlay[hidden] {
  display: none;
}

/* ── Panel ────────────────────────────────────────────────────────────────── */

#summarybot-panel {
  position: relative;
  width: min(540px, 94vw);
  height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 40px rgba(0,0,0,.35);
}

/* ── Close button ─────────────────────────────────────────────────────────── */

#summarybot-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: rgba(0,0,0,.5);
  color: #fff;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  animation: none;
  box-shadow: none;
}

#summarybot-close:hover {
  background: rgba(0,0,0,.75);
}

/* ── iframe ───────────────────────────────────────────────────────────────── */

#summarybot-iframe {
  flex: 1;
  width: 100vw;
  border: none;
  display: block;
  min-height: 0;
}

/* ── Mobile: full screen ──────────────────────────────────────────────────── */

@media (max-width: 600px) {
  #summarybot-panel {
    width: 100vw;
    height: 100vh;
    border-radius: 0;
  }
}

