/* Auto mit Hotspots – genutzt auf Startseite und Werkstatt.
   Eigene Datei, damit die Startseite sie ohne pages.css laden kann. */

/* ==========================================================================
   Auto mit Hotspots (Werkstatt): Punkte springen zum jeweiligen Abschnitt
   ========================================================================== */
main.pg > .hs-section { padding-top: clamp(24px, 3vw, 40px); }
@media (max-width: 899px) { main.pg > .hs-section { padding-top: 24px !important; } }

.hs {
  position: relative; margin: 0;
  border-radius: var(--img-radius); overflow: hidden;
  background: #1d1e22; color: var(--white);
}
.hs__stage { position: relative; }
.hs__img { display: block; width: 100%; height: auto; }
.hs__spots { position: absolute; inset: 0; margin: 0; padding: 0; list-style: none; }
.hs__spot { position: absolute; left: var(--x); top: var(--y); transform: translate(-50%, -50%); }
.hs__spot a { position: relative; display: block; color: var(--white); text-decoration: none; }
.hs__spot a:focus-visible { outline: 2px solid var(--white); outline-offset: 4px; border-radius: 50%; }

.hs__dot {
  display: grid; place-items: center;
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--accent); color: var(--ink);
  font-size: 13px; font-weight: 500; line-height: 1;
  box-shadow: 0 0 0 6px rgba(255, 106, 0, .28);
  transition: transform .2s ease, box-shadow .2s ease;
}
.hs__spot a:hover .hs__dot,
.hs__spot a:focus-visible .hs__dot { transform: scale(1.12); box-shadow: 0 0 0 9px rgba(255, 106, 0, .32); }

/* Label erscheint beim Hovern/Fokus neben dem Punkt */
.hs__label {
  position: absolute; top: 50%; left: calc(100% + 12px);
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: var(--pill);
  background: rgba(22, 22, 22, .94); color: var(--white);
  font-size: 14px; font-weight: 500; white-space: nowrap;
  opacity: 0; transform: translate(-6px, -50%);
  transition: opacity .2s ease, transform .2s ease;
  pointer-events: none;
}
.hs__label svg { color: var(--accent); }
.hs__spot--left .hs__label { left: auto; right: calc(100% + 12px); transform: translate(6px, -50%); }
.hs__spot a:hover .hs__label,
.hs__spot a:focus-visible .hs__label { opacity: 1; transform: translate(0, -50%); }

@media (prefers-reduced-motion: no-preference) {
  .hs__dot { animation: hs-pulse 2.4s ease-out infinite; }
  .hs__spot:nth-child(2) .hs__dot { animation-delay: .3s; }
  .hs__spot:nth-child(3) .hs__dot { animation-delay: .6s; }
  .hs__spot:nth-child(4) .hs__dot { animation-delay: .9s; }
  .hs__spot:nth-child(5) .hs__dot { animation-delay: 1.2s; }
  .hs__spot:nth-child(6) .hs__dot { animation-delay: 1.5s; }
  .hs__spot:nth-child(7) .hs__dot { animation-delay: 1.8s; }
  .hs__spot a:hover .hs__dot, .hs__spot a:focus-visible .hs__dot { animation: none; }
}
@keyframes hs-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(255, 106, 0, .55); }
  70%  { box-shadow: 0 0 0 12px rgba(255, 106, 0, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 106, 0, 0); }
}

/* Titel oben links auf der dunklen Wand */
.hs__caption {
  position: absolute; top: 0; left: 0;
  padding: clamp(20px, 3vw, 40px);
  pointer-events: none;
}
.hs__title { font-size: clamp(24px, 2.4vw, 34px); font-weight: 500; line-height: 1.15; letter-spacing: -0.015em; color: var(--white); }
.hs__hint { margin-top: 6px; font-size: 14px; color: #c4c4c4; }
.hs__caption .eyebrow { margin-bottom: 8px; }

/* Legende nur auf Handy/Tablet (kein Hover) */
.hs__legend { display: none; }
@media (max-width: 899px) {
  .hs__label { display: none; }
  .hs__dot { width: 26px; height: 26px; font-size: 12px; box-shadow: 0 0 0 4px rgba(255, 106, 0, .28); }
  .hs__legend {
    display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 var(--gap);
    margin: 16px 0 0; padding: 0; list-style: none;
  }
  .hs__legend a {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 0; border-bottom: 1px solid var(--line);
    font-size: 15px; font-weight: 500; text-decoration: none; color: var(--ink);
  }
  .hs__legend a:hover { color: var(--accent); }
  .hs__num {
    flex: 0 0 auto; display: grid; place-items: center;
    width: 24px; height: 24px; border-radius: 50%;
    background: var(--accent); color: var(--ink); font-size: 12px; font-weight: 500;
  }
}
@media (min-width: 600px) and (max-width: 899px) {
  .hs__legend { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Handy: Bild auf 16:10 zuschneiden (Auto bleibt ganz sichtbar), Titel unter das Bild */
@media (max-width: 599px) {
  .hs__stage { width: 145.6%; margin-left: -22.8%; }
  .hs__caption { position: static; padding: 16px 20px 20px; }
  .hs__title { font-size: 22px; }
}
@media (max-width: 599px) {
  .hs__dot { width: 22px; height: 22px; font-size: 11px; box-shadow: 0 0 0 3px rgba(255, 106, 0, .28); }
}

/* ---------- Hotspots v2: Plus statt Zahlen, deutlicher Puls, Leiste unter dem Bild ---------- */
.hs__spot .hs__dot {
  position: relative; z-index: 1;
  animation: none !important;
  box-shadow: 0 0 0 4px rgba(255, 106, 0, .35), 0 4px 14px rgba(0, 0, 0, .45);
}
.hs__dot svg { display: block; }
.hs__spot a:hover .hs__dot,
.hs__spot a:focus-visible .hs__dot { transform: scale(1.15) rotate(90deg); box-shadow: 0 0 0 6px rgba(255, 106, 0, .45), 0 4px 14px rgba(0, 0, 0, .45); }
.hs__dot { transition: transform .25s ease, box-shadow .25s ease; }

/* Pulsierender Ring hinter dem Punkt */
.hs__spot a::before {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: var(--accent); opacity: 0;
}
@media (prefers-reduced-motion: no-preference) {
  .hs__spot a::before { animation: hs-ring 2s cubic-bezier(.2, .6, .4, 1) infinite; }
  .hs__spot:nth-child(2) a::before { animation-delay: .25s; }
  .hs__spot:nth-child(3) a::before { animation-delay: .5s; }
  .hs__spot:nth-child(4) a::before { animation-delay: .75s; }
  .hs__spot:nth-child(5) a::before { animation-delay: 1s; }
  .hs__spot:nth-child(6) a::before { animation-delay: 1.25s; }
  .hs__spot:nth-child(7) a::before { animation-delay: 1.5s; }
  .hs__spot a:hover::before, .hs__spot a:focus-visible::before { animation: none; }
}
@keyframes hs-ring {
  0%   { transform: scale(1);   opacity: .75; }
  100% { transform: scale(2.7); opacity: 0; }
}

/* Dunkle Leiste direkt unter dem Bild – eine Einheit */
main.pg > .hs-section + .glance-section { padding-top: 16px !important; }

/* Legende (Handy/Tablet): einfache Linkliste mit orangem Punkt */
@media (max-width: 899px) {
  .hs__legend { margin-top: 16px; }
  .hs__legend a::before {
    content: ""; flex: 0 0 auto; width: 8px; height: 8px; border-radius: 50%; background: var(--accent);
  }
}
@media (max-width: 599px) {
  .hs__dot svg { width: 11px; height: 11px; }
}
.hs__title .hl { color: var(--accent); }

/* ---------- Hotspot-Bild Tablet: Titel oben, Hinweis an den unteren Bildrand ---------- */
@media (min-width: 600px) and (max-width: 899px) {
  .hs__caption {
    position: absolute; inset: 0;
    display: flex; flex-direction: column; align-items: flex-start;
    padding: 20px 24px;
  }
  .hs__title { font-size: 24px; }
  .hs__caption .eyebrow { margin-bottom: 6px; font-size: 11px; }
  .hs__hint { margin-top: auto; font-size: 13px; }
}

/* Achter Punkt: Räderwechsel (11/2026) */
@media (prefers-reduced-motion: no-preference) {
  .hs__spot:nth-child(8) .hs__dot { animation-delay: 2.1s; }
  .hs__spot:nth-child(8) a::before { animation-delay: 1.75s; }
}
