/* Reusable Tooltip Styles */
.tooltip {
  position: fixed;
  inset: auto auto auto auto;
  z-index: 9999;
  max-width: 280px;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.45;
  color: #fff;
  background: rgba(0,0,0,0.88);
  box-shadow: 0 6px 20px rgba(0,0,0,0.18);
  transform: translate(-50%, -8px);
  pointer-events: none;
  opacity: 0;
  transition: opacity 120ms ease, transform 120ms ease;
  will-change: transform, opacity;
  word-wrap: break-word;
}

.tooltip.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.tooltip[data-placement="bottom"] {
  transform: translate(-50%, 8px);
}

.tooltip[data-placement="bottom"].show {
  transform: translate(-50%, 0);
}

.tooltip .tooltip-arrow {
  display: none;
  position: absolute;
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
}

.tooltip[data-placement="top"] .tooltip-arrow {
  bottom: -6px;
  border-top: 6px solid rgba(0,0,0,0.85);
}

.tooltip[data-placement="bottom"] .tooltip-arrow {
  top: -6px;
  border-bottom: 6px solid rgba(0,0,0,0.85);
}

/* Light variant (optional) */
.tooltip--light {
  color: #111;
  background: #fff;
  border: 1px solid #e5e7eb;
}

.tooltip--light .tooltip-arrow {
  border-top-color: #fff;
  border-bottom-color: #fff;
}

/* Card-style rich tooltip (responsive) */
.tooltip--card {
  background: #ffffff;
  color: #1f2937; /* gray-800 */
  border: 1px solid #e5e7eb; /* gray-200 */
  border-radius: 12px;
  padding: 12px 14px;
  max-width: 90vw;
  pointer-events: auto; /* allow interactions */
}

.tooltip--card .tooltip-arrow {
  border-top-color: #ffffff;
  border-bottom-color: #ffffff;
}

.tooltip--card h4 {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 600;
  color: #111827; /* gray-900 */
}

.tooltip--card p {
  margin: 0 0 8px;
  font-size: 13px;
  color: #374151; /* gray-700 */
}

.tooltip--card .tooltip-divider {
  height: 1px;
  background: #f3f4f6; /* gray-100 */
  margin: 8px 0;
}

/* Responsive image/logo row inside card */
.tooltip--card .tooltip-logos {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-items: center;
}

.tooltip--card .tooltip-logos img {
  max-width: 100%;
  height: auto;
  object-fit: contain;
}

@media (min-width: 480px) {
  .tooltip--card { max-width: 420px; }
  .tooltip--card .tooltip-logos { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

@media (min-width: 768px) {
  .tooltip--card { max-width: 560px; }
}
