/* lib/user-media.css — styling for the persistent user media grid
   mounted by lib/user-media-mount.client.js (and by engine.html inline).
   Scoped under .swr-user-media so existing page styles don't collide. */

.swr-media-card {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--bg-2, #111);
}
.swr-media-card img,
.swr-media-card video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.swr-media-meta {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  font-size: 8px;
  padding: 8px 3px 2px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
}
.swr-media-del {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 16px;
  height: 16px;
  padding: 0;
  line-height: 14px;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  cursor: pointer;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 80ms ease;
}
.swr-media-card:hover .swr-media-del { opacity: 1; }
.swr-media-del:hover { background: #ff2d8a; border-color: #ff2d8a; }
.swr-media-empty {
  grid-column: 1 / -1;
  padding: 16px 8px;
  text-align: center;
  color: var(--muted, #999);
  font-size: 9px;
  letter-spacing: 0.06em;
}
