/* LST 3D-Viewer ([lst_3d id="123"]).
   Form wie Baustein 9 (Video) und 19 (Slider 16:9): volle Containerbreite, 16:9, Radius groß, Papiergrund.
   Knöpfe wie .lst-slider-btn, Varianten wie .lst-eyebrow, Laden-Knopf ist .lst-btn--primary.
   Fallbacks hinter den Variablen, damit dieselbe Datei auch im Backend passt. */

.lst-3d { width: 100%; }

.lst-3d-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background-color: var(--color-paper, #eee);
  border-radius: var(--radius-lg, 16px);
  isolation: isolate;
}
@media (max-width: 767px) {
  .lst-3d-stage { aspect-ratio: 4 / 5; }
}

.lst-3d-mv {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-color: transparent;
  --poster-color: transparent;
  --progress-bar-height: 0px;
  outline: none;
}

/* Box vor dem Laden */
.lst-3d-gate {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm, 12px);
  padding: var(--space-lg, 32px);
  text-align: center;
  background-color: var(--color-paper, #eee);
  transition: opacity .45s var(--ease-out, ease), visibility .45s;
}
.lst-3d-gate-icon {
  width: 44px;
  height: 44px;
  margin-bottom: var(--space-xs, 8px);
  color: var(--color-muted, #5a5a5a);
}
.lst-3d-gate .lst-eyebrow { margin: 0; }
.lst-3d-gate-text { max-width: 38ch; margin: 0 0 var(--space-xs, 8px); }
.lst-3d-enable { border: 0; cursor: pointer; }
.lst-3d.is-loading .lst-3d-enable { opacity: .6; pointer-events: none; }
.lst-3d.is-loaded .lst-3d-gate { opacity: 0; visibility: hidden; pointer-events: none; }

/* Ladebalken unten in der Box */
.lst-3d-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 6;
  height: 3px;
  pointer-events: none;
  transition: opacity .3s;
}
.lst-3d-progress.is-done { opacity: 0; }
.lst-3d-progress span {
  display: block;
  width: 0;
  height: 100%;
  background-color: var(--color-accent, #007194);
  transition: width .2s;
}

/* Runde Knöpfe oben in der Box, wie .lst-slider-btn */
.lst-3d-btn {
  position: absolute;
  top: var(--space-md, 16px);
  z-index: 7;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  color: var(--color-ink, #1d1d1b);
  background-color: rgba(255, 255, 255, .9);
  border: 0;
  border-radius: var(--radius-pill, 999px);
  cursor: pointer;
  transition: background-color var(--speed, .2s), opacity var(--speed, .2s);
}
.lst-3d-btn:hover { background-color: #fff; }
.lst-3d-btn svg { width: 16px; height: 16px; }
.lst-3d-btn.is-off { opacity: .55; }
.lst-3d-btn--dots { left: var(--space-md, 16px); }
.lst-3d-btn--expand { right: var(--space-md, 16px); }
.lst-3d-btn[hidden] { display: none; }

/* Hotspots (Slots im model-viewer) */
.lst-3d-hotspot { --min-hotspot-opacity: 0; }
.lst-3d-hotspot-btn {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 28px;
  height: 28px;
  padding: 0;
  color: var(--color-ink, #1d1d1b);
  font-family: var(--font-body, system-ui, sans-serif);
  font-weight: 600;
  font-size: 12px;
  line-height: 1;
  background-color: #fff;
  border: 0;
  border-radius: var(--radius-pill, 999px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, .18);
  transform: translate3d(-50%, -50%, 0);
  cursor: pointer;
  transition: background-color var(--speed, .2s), color var(--speed, .2s), transform .2s;
}
.lst-3d-hotspot-btn:hover { transform: translate3d(-50%, -50%, 0) scale(1.1); }
.lst-3d-hotspot-btn svg { width: 14px; height: 14px; }
.lst-3d-hotspot-btn .is-minus { display: none; }
.lst-3d-hotspot-btn.is-active {
  color: #fff;
  background-color: var(--color-accent, #007194);
  animation: lst-3d-pulse 2s infinite ease;
}
.lst-3d-hotspot-btn.is-active .is-plus { display: none; }
.lst-3d-hotspot-btn.is-active .is-minus { display: flex; }
.lst-3d-hotspot-btn > span { display: flex; }
@keyframes lst-3d-pulse {
  0% { box-shadow: 0 0 0 0 rgba(0, 113, 148, .45); }
  70% { box-shadow: 0 0 0 12px rgba(0, 113, 148, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 113, 148, 0); }
}
.lst-3d-stage[data-dots="0"] .lst-3d-hotspot { display: none !important; }

/* Karte zum aktiven Hotspot */
.lst-3d-note {
  position: absolute;
  left: var(--space-md, 16px);
  bottom: var(--space-md, 16px);
  z-index: 8;
  box-sizing: border-box;
  max-width: min(420px, calc(100% - 2 * var(--space-md, 16px)));
  padding: var(--space-md, 16px) 48px var(--space-md, 16px) var(--space-md, 16px);
  color: var(--color-ink, #1d1d1b);
  background-color: rgba(255, 255, 255, .94);
  border-radius: var(--radius-md, 12px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, .12);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  opacity: 0;
  visibility: hidden;
  transform: translate3d(0, 8px, 0);
  transition: opacity .25s, transform .25s, visibility .25s;
}
.lst-3d-note.is-active { opacity: 1; visibility: visible; transform: none; }
.lst-3d-note-title {
  margin: 0 0 4px;
  font-family: var(--font-display, inherit);
  font-weight: 600;
  font-size: var(--text-lg, 18px);
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.lst-3d-note-text {
  color: var(--color-muted, #5a5a5a);
  font-family: var(--font-body, inherit);
  font-size: var(--text-sm, 14px);
  line-height: 1.55;
}
.lst-3d-note-text p { margin: 0; }
.lst-3d-note-close {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  color: var(--color-ink, #1d1d1b);
  background-color: var(--color-paper, #eee);
  border: 0;
  border-radius: var(--radius-pill, 999px);
  cursor: pointer;
  transition: background-color var(--speed, .2s);
}
.lst-3d-note-close:hover { background-color: #e2e2e2; }
.lst-3d-note-close svg { width: 14px; height: 14px; }
@media (max-width: 767px) {
  .lst-3d-note { left: var(--space-sm, 12px); right: var(--space-sm, 12px); bottom: var(--space-sm, 12px); max-width: none; }
}

/* Varianten unter der Box, wie .lst-eyebrow */
.lst-3d-variants {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-xs, 8px);
  margin-top: var(--space-md, 16px);
}
.lst-3d-variant {
  height: 36px;
  padding: 0 16px;
  color: var(--color-ink, #1d1d1b);
  font-family: var(--font-body, inherit);
  font-weight: 500;
  font-size: var(--text-sm, 14px);
  line-height: 1;
  background-color: transparent;
  border: 1px solid var(--color-line, rgba(29, 29, 27, .12));
  border-radius: var(--radius-pill, 999px);
  cursor: pointer;
  transition: background-color var(--speed, .2s), color var(--speed, .2s), border-color var(--speed, .2s);
}
.lst-3d-variant:hover { background-color: var(--color-paper, #eee); }
.lst-3d-variant.is-active { color: #fff; background-color: var(--color-ink, #1d1d1b); border-color: var(--color-ink, #1d1d1b); }
.lst-section--dark .lst-3d-variant { color: #fff; border-color: rgba(255, 255, 255, .2); }
.lst-section--dark .lst-3d-variant:hover { background-color: rgba(255, 255, 255, .1); }
.lst-section--dark .lst-3d-variant.is-active { color: var(--color-ink, #1d1d1b); background-color: #fff; border-color: #fff; }

/* Vollbild: Box hängt dann an <body> */
.lst-3d-stage.is-expanded {
  position: fixed;
  inset: 0;
  z-index: 100000;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  aspect-ratio: auto;
  border-radius: 0;
}
.lst-3d-stage.is-expanded .lst-3d-btn { top: max(16px, env(safe-area-inset-top, 16px)); }

@media (prefers-reduced-motion: reduce) {
  .lst-3d-hotspot-btn.is-active { animation: none; }
}