/* AI event overlay polish: keep thumbnails natural and show detection boxes on cards. */

.ai-event-thumbnail {
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 50% 0%, rgba(37, 99, 235, 0.16), transparent 38%),
    #0f172a;
}

.ai-event-thumbnail-image-wrap {
  position: relative;
  display: inline-block;
  max-width: 100%;
  max-height: 100%;
  line-height: 0;
}

.ai-event-thumbnail-image-wrap img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 180px;
  object-fit: contain;
}

.ai-event-thumbnail .ai-event-detection-box {
  border-width: 2px;
  border-radius: 8px;
  box-shadow:
    0 0 0 1px rgba(15, 23, 42, 0.82),
    0 0 18px rgba(34, 197, 94, 0.42);
}

.ai-event-thumbnail .ai-event-detection-label {
  left: 4px;
  top: 4px;
  bottom: auto;
  max-width: calc(100% - 8px);
  padding: 4px 7px;
  font-size: 0.66rem;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ai-event-modal-preview {
  background:
    radial-gradient(circle at 50% 0%, rgba(37, 99, 235, 0.12), transparent 36%),
    #0f172a;
}

.ai-event-modal-image-wrap img {
  background: #0f172a;
}

@media (max-width: 720px) {
  .ai-event-thumbnail-image-wrap img {
    max-height: 190px;
  }
}

@media (max-width: 420px) {
  .ai-event-thumbnail-image-wrap img {
    max-height: 168px;
  }

  .ai-event-thumbnail .ai-event-detection-label {
    max-width: calc(100% - 8px);
    font-size: 0.62rem;
  }
}
