/* ============================================================
   SITE-SHOTS - Screenshot-Galerien + Lightbox-Viewer
   Einbindung: nach site-search.css. JS: assets/site-shots.js (defer).
   Bindet sich an .shot-grid .shot und .feature-screen img.
   ============================================================ */

/* ---------- Galerie-Grid (Screenshots-Sektionen) ---------- */
.shot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; margin-top: 28px; }
.shot {
  position: relative; margin: 0; border-radius: 16px; overflow: hidden; cursor: zoom-in;
  border: 1px solid var(--border); background: #0d1310;
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.10);
  transition: transform 0.28s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.28s, border-color 0.28s;
}
.shot img { width: 100%; display: block; aspect-ratio: 16 / 9; object-fit: cover; transition: transform 0.45s cubic-bezier(0.2, 0.8, 0.2, 1); }
.shot figcaption {
  position: absolute; inset: auto 0 0 0; z-index: 1; padding: 34px 16px 12px;
  font-size: 0.82rem; font-weight: 600; color: #fff; letter-spacing: 0.01em;
  background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.78) 78%);
  pointer-events: none;
}
/* Zoom-Hinweis (Lupe) */
.shot::after {
  content: ''; position: absolute; top: 12px; right: 12px; z-index: 1; width: 34px; height: 34px;
  border-radius: 50%; background: rgba(0, 0, 0, 0.45) center / 16px no-repeat;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.5' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m21 21-4.3-4.3M11 8v6M8 11h6'/%3E%3C/svg%3E");
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  opacity: 0; transform: scale(0.7); transition: opacity 0.25s, transform 0.25s;
}
.shot:hover, .shot:focus-visible {
  transform: translateY(-4px);
  border-color: var(--green);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.22), 0 0 0 1px var(--green), 0 8px 30px rgba(51, 204, 63, 0.22);
}
.shot:hover img { transform: scale(1.05); }
.shot:hover::after, .shot:focus-visible::after { opacity: 1; transform: scale(1); }

/* ---------- Klickbare Inhaltsbilder (.feature-screen) ---------- */
.feature-screen { position: relative; }
.feature-screen.is-zoomable { cursor: zoom-in; }
.feature-screen.is-zoomable::after {
  content: ''; position: absolute; top: 10px; right: 10px; z-index: 1; width: 32px; height: 32px;
  border-radius: 50%; background: rgba(0, 0, 0, 0.45) center / 15px no-repeat;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.5' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m21 21-4.3-4.3M11 8v6M8 11h6'/%3E%3C/svg%3E");
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  opacity: 0; transform: scale(0.7); transition: opacity 0.25s, transform 0.25s;
}
.feature-screen.is-zoomable:hover { border-color: var(--green); box-shadow: 0 10px 28px rgba(0, 0, 0, 0.16), 0 6px 24px rgba(51, 204, 63, 0.18); }
.feature-screen.is-zoomable:hover::after { opacity: 1; transform: scale(1); }

/* ---------- Lightbox-Viewer ---------- */
.glb {
  position: fixed; inset: 0; z-index: 1400; display: flex; flex-direction: column;
  align-items: center; justify-content: center; padding: clamp(14px, 3vw, 40px);
  background: rgba(7, 10, 8, 0.84);
  backdrop-filter: blur(18px) saturate(1.15); -webkit-backdrop-filter: blur(18px) saturate(1.15);
  opacity: 0; pointer-events: none; transition: opacity 0.22s ease;
}
.glb.is-open { opacity: 1; pointer-events: auto; }
.glb__stage { position: relative; display: flex; align-items: center; justify-content: center; max-width: 100%; flex: 1; min-height: 0; }
.glb__img {
  max-width: min(1400px, 100%); max-height: 100%; border-radius: 12px;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.55);
  transform: scale(0.94); opacity: 0;
  transition: transform 0.28s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.2s ease;
}
.glb.is-open .glb__img.is-ready { transform: scale(1); opacity: 1; }
.glb__cap { margin-top: 14px; min-height: 22px; font-size: 0.92rem; color: rgba(255, 255, 255, 0.85); text-align: center; }
.glb__count {
  position: absolute; top: clamp(14px, 3vw, 26px); left: clamp(14px, 3vw, 26px);
  font-size: 0.85rem; font-weight: 600; letter-spacing: 0.06em; color: rgba(255, 255, 255, 0.75);
  padding: 6px 12px; border-radius: 999px; background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.glb__btn {
  position: absolute; width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08); color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  transition: background 0.2s, border-color 0.2s, transform 0.2s;
}
.glb__btn:hover { background: var(--green, #33cc3f); border-color: var(--green, #33cc3f); transform: scale(1.06); }
.glb__btn svg { width: 20px; height: 20px; }
.glb__close { top: clamp(14px, 3vw, 26px); right: clamp(14px, 3vw, 26px); }
.glb__prev { left: clamp(6px, 2vw, 22px); top: 50%; transform: translateY(-50%); }
.glb__next { right: clamp(6px, 2vw, 22px); top: 50%; transform: translateY(-50%); }
.glb__prev:hover { transform: translateY(-50%) scale(1.06); }
.glb__next:hover { transform: translateY(-50%) scale(1.06); }
.glb--single .glb__prev, .glb--single .glb__next, .glb--single .glb__count { display: none; }

@media (max-width: 640px) {
  .shot-grid { grid-template-columns: 1fr; }
  .glb__prev, .glb__next { width: 40px; height: 40px; }
}
@media (prefers-reduced-motion: reduce) {
  .shot, .shot img, .shot::after, .glb, .glb__img, .glb__btn { transition: none; }
}
