/* Shared image lightbox: used by My IDs and by the public directory. */

/* ---------- preview lightbox ---------- */

.sj-lightbox[hidden] { display: none; }

.sj-lightbox {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(12px, 3vw, 32px);
}

body.has-lightbox { overflow: hidden; }

.sj-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(43, 31, 69, .62);
  backdrop-filter: blur(6px);
}

.sj-lightbox-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: min(560px, 100%);
  max-height: 100%;
  padding: 16px;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 24px 60px rgba(43, 31, 69, .3);
  overflow-y: auto;
}

.sj-lightbox-head { display: flex; align-items: flex-start; gap: 12px; }
.sj-lightbox-head > div { flex: 1; min-width: 0; }
.sj-lightbox-head .hint { margin: 2px 0 0; }

.sj-lightbox-close {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border: 1px solid var(--pink-line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.sj-lightbox-close:hover { background: var(--pink-wash); }

.sj-lightbox-panel img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 10px;
  background: var(--pink-wash);
}

.sj-lightbox-foot { display: flex; gap: 8px; flex-wrap: wrap; }
