/* wiki-tooltip.css — Wikipedia inline tooltip styles */

.wiki-ref {
  border-bottom: 1px dashed currentColor;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}

.wiki-tooltip {
  position: absolute;
  z-index: 9999;
  width: 280px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 12px 14px 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  font-size: 14px;
  line-height: 1.5;
  color: #222;
}

.wiki-tooltip-close {
  position: absolute;
  top: 6px;
  right: 8px;
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: #888;
  padding: 0 4px;
  line-height: 1;
}

.wiki-tooltip-close:hover {
  color: #333;
}

.wiki-tooltip-title {
  font-weight: bold;
  margin-bottom: 6px;
  padding-right: 20px;
}

.wiki-tooltip-extract {
  color: #444;
  margin-bottom: 8px;
  max-height: 120px;
  overflow: hidden;
}

.wiki-tooltip-wiki-link {
  display: block;
  font-size: 13px;
  color: #3366cc;
  text-decoration: none;
  border-top: 1px solid #eee;
  padding-top: 6px;
  margin-top: 4px;
}

.wiki-tooltip-wiki-link:hover {
  text-decoration: underline;
}

/* Mobile: bottom sheet */
@media (max-width: 640px) {
  .wiki-tooltip {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    top: auto;
    width: 100%;
    border-radius: 12px 12px 0 0;
    border-bottom: none;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.18);
    padding: 16px 16px 24px;
    max-height: 60vh;
    overflow-y: auto;
  }
}
