/* ============================================================
   EVENT DETAIL — single CPT `event`
   Builds on styles.css tokens (--brand, --bg, --fg, etc.)
   Each block matches one ACF field from the spec.
   ============================================================ */

/* ============================================================
   DESIGN TOKENS — GROTEC brand values (self-contained)
   The handoff defined these in styles.css; this enqueued file
   ships them so it works standalone. Colors = real GROTEC brand;
   spacing/motion tokens kept from the handoff. Light mode is
   detected via `html.site-light` / `body.site-light` (set by the
   pre-paint script + main.js), with `body:not(.site-dark)` kept as
   a fallback — the SAME signals the sidebar header uses
   (_header.scss), so the event content and the sidebar always agree
   on the mode (no white-sidebar / dark-content clash). Light palette
   matches the live site grotec-events.de: #fff bg, #000 text,
   #FF003A accent.
   ============================================================ */
:root {
  /* brand */
  --brand: #8B0028;
  --brand-2: #FF003A;

  /* dark theme (default) */
  --bg: #060708;
  --bg-2: #0e0f10;
  --bg-3: #16181a;
  --fg: #ffffff;
  --fg-2: rgba(255, 255, 255, .85);
  --fg-3: rgba(255, 255, 255, .6);
  --line: rgba(255, 255, 255, .18);
  --line-strong: rgba(255, 255, 255, .28);

  /* tag pill */
  --tag-border: rgba(255, 255, 255, 0.55);
  --tag-fg: #ffffff;
  --tag-hover-bg: #ffffff;
  --tag-hover-fg: #060708;
  --tag-active-bg: var(--brand);
  --tag-active-border: var(--brand);
  --tag-active-fg: #fff;

  /* type — mundial-narrow-variable comes from Adobe Typekit
     (loaded site-wide by the parent theme; do not duplicate the load) */
  --font-sans: 'mundial-narrow-variable', sans-serif;
  --font-display: 'mundial-narrow-variable', sans-serif;

  /* spacing rhythm */
  --side: clamp(20px, 5vw, 80px);
  --row: clamp(80px, 14vh, 180px);

  /* motion */
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

/* Light-mode token flip — values match the live site (grotec-events.de):
   pure white #fff, black text #000, red accent #FF003A. Target BOTH the
   pre-paint signal (html.site-light) AND the legacy body signals so the
   tokens flip no matter which element carries the class. */
html.site-light,
body.site-light,
body:not(.site-dark) {
  --bg: #ffffff;
  --bg-2: #f4f4f4;
  --bg-3: #ececec;
  --fg: #000000;
  --fg-2: #333333;
  --fg-3: #666666;
  --line: rgba(0, 0, 0, 0.14);
  --line-strong: rgba(0, 0, 0, 0.28);
  --tag-border: rgba(0, 0, 0, 0.55);
  --tag-fg: #000000;
  --tag-hover-bg: #000000;
  --tag-hover-fg: #ffffff;
}

/* ---------- SPEC OVERLAY ----------
   Toggle .spec-mode on the root to show ACF field annotations
   on every block. Off by default — purely informational. */
.spec-tag {
  display: none;
  position: absolute;
  top: 18px;
  right: 22px;
  z-index: 30;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brand-2);
  font-weight: 500;
  font-family: var(--font-sans);
  padding: 6px 10px;
  border: 1px solid var(--brand-2);
  border-radius: 999px;
  background: rgba(139, 0, 40, 0.08);
  pointer-events: none;
  white-space: nowrap;
}
.spec-mode .spec-tag { display: inline-block; }
.spec-mode .panel-num {
  position: absolute;
  top: 18px;
  left: 22px;
  z-index: 30;
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--fg-3);
  font-weight: 400;
  font-family: var(--font-sans);
  padding: 6px 0;
}
.panel-num { display: none; }
.spec-mode .panel-num { display: inline-block; }


/* ============================================================
   ① HERO — featured image + title + meta strip
   ============================================================ */
.ev-hero {
  position: relative;
  overflow: hidden;
  padding: var(--row) var(--side) 80px;
}
.ev-hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-size: cover;
  background-position: center;
  filter: grayscale(0.25) contrast(1.05) brightness(0.55);
}
/* No featured image: dark gradient so white text stays readable in both modes */
.ev-hero__bg--fallback {
  background: linear-gradient(135deg, #111114 0%, #1c1c28 60%, #060708 100%);
  filter: none;
}
.ev-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  /* The bottom stop was `var(--bg)`, which resolves to #fff in light mode —
     the fade then washed out to white behind the (always-white) hero title,
     making it unreadable in light mode. The hero is a photo panel that stays
     dark regardless of site mode (cf. the forced-white text rules above), so
     the fade needs a fixed dark stop too, not the mode-dependent page bg. */
  background:
    linear-gradient(180deg, rgba(0,0,0,0.25) 0%, transparent 40%, #060708 100%),
    linear-gradient(90deg, rgba(0,0,0,0.55) 0%, transparent 60%);
}
.ev-hero__inner {
  position: relative;
  z-index: 2;
  max-width: 1440px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 100%;
}
.ev-hero__breadcrumb {
  margin-bottom: 28px;
  font-size: 12px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  /* The hero always has a dark photo + gradient overlay (cf. .ev-hero::after),
     so the breadcrumb is ALWAYS on a dark surface — force white regardless
     of light/dark mode. Without this, light mode inherits the page's dark
     text colour and the breadcrumb disappears against the photo. */
  color: rgba(255, 255, 255, 0.85);
}
.ev-hero__breadcrumb a,
.ev-hero__breadcrumb a:visited {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}
.ev-hero__breadcrumb a:hover,
.ev-hero__breadcrumb a:focus-visible {
  color: #fff;
}
.ev-hero__breadcrumb .breadcrumb__sep {
  opacity: 0.5;
  margin: 0 0.4em;
}
.ev-hero__breadcrumb [aria-current="page"] {
  color: #fff;
  font-weight: 400;
}

.ev-hero__cats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}
.ev-hero__cat {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 400;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.6);
  border-radius: 999px;
  padding: 8px 16px;
  background: rgba(0,0,0,0.25);
  transition: background 0.3s var(--ease-out), color 0.3s var(--ease-out);
  text-decoration: none;
}
.ev-hero__cat:hover { background: var(--brand); border-color: var(--brand); }

.ev-hero__title {
  font-family: var(--font-display);
  font-weight: 100;
  font-size: clamp(56px, 11vw, 200px);
  line-height: 0.86;
  letter-spacing: -0.025em;
  text-transform: uppercase;
  margin: 0;
  color: #fff;
  text-wrap: balance;
}
.ev-hero__meta {
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: 14px 56px;
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.22);
  max-width: 900px;
}
.ev-hero__meta-item dt {
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  margin: 0 0 6px;
  font-weight: 400;
}
.ev-hero__meta-item dd {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(18px, 1.4vw, 22px);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fff;
}
@media (max-width: 767.98px) {
  .ev-hero__meta { grid-template-columns: 1fr; gap: 18px; }
  /* The desktop title floors at 56px, which is wider than a long single word
     (e.g. "QUARTALSMEETING") on a ~390px phone → it clipped off-screen. Drop
     the floor for small screens so the fluid type actually shrinks, and let a
     pathologically long word break rather than overflow. */
  .ev-hero__title {
    font-size: clamp(34px, 10vw, 64px);
    overflow-wrap: break-word;
  }
}

/* ============================================================
   ② INTRO / CHAPÔ — lead paragraph
   ============================================================ */
.ev-intro {
  display: grid;
  grid-template-columns: clamp(60px, 8vw, 100px) 1fr;
  gap: 32px;
  align-items: start;
}
.ev-intro__mark {
  font-family: var(--font-display);
  font-weight: 100;
  font-size: clamp(56px, 9vw, 140px);
  line-height: 0.8;
  color: var(--brand);
  letter-spacing: -0.05em;
}
.ev-intro__text {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(28px, 4vw, 64px);
  line-height: 1.03;
  letter-spacing: -0.015em;
  color: var(--fg);
  margin: 0;
  max-width: 22ch;
  text-wrap: balance;
}

/* ============================================================
   ③ BESCHREIBUNG — the_content (rich text)
   ============================================================ */
.ev-content {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 64px;
  align-items: start;
}
@media (max-width: 1023.98px) {
  .ev-content { grid-template-columns: 1fr; gap: 32px; }
  /* Responsive gutter for the hero content so the breadcrumb/eyebrow/title
     never hug the screen edge on phones & tablets (per request). */
  .ev-hero__inner { padding: 0 15px; }
}
.ev-content__label {
  font-size: 12px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--fg-2);
  font-weight: 400;
  display: flex;
  gap: 16px;
  align-items: center;
}
.ev-content__label::before {
  content: "";
  width: 40px;
  height: 1px;
  background: var(--brand);
}
.ev-content__body {
  font-size: clamp(17px, 1.35vw, 22px);
  line-height: 1.55;
  font-weight: 300;
  color: var(--fg);
  text-wrap: pretty;
}
.ev-content__body p { margin: 0 0 1.2em; }

/* ============================================================
   ④ LEISTUNGEN — numbered list
   ============================================================ */
.ev-leistungen__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  max-width: 1100px;
}
.ev-leistungen__list li {
  display: grid;
  grid-template-columns: 80px 1fr auto;
  gap: 32px;
  align-items: baseline;
  border-top: 1px solid var(--line);
  padding: 22px 0;
}
/* On narrow phones the 80px number column eats ~25% of usable width
   and crowds the label. Halve it + shrink the gap below 480px so the
   label gets the real estate it needs. */
@media (max-width: 479.98px) {
  .ev-leistungen__list li {
    grid-template-columns: 44px 1fr auto;
    gap: 16px;
  }
}
.ev-leistungen__list li:last-child {
  border-bottom: 1px solid var(--line);
}
.ev-leistungen__num {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 14px;
  letter-spacing: 0.25em;
  color: var(--brand);
  font-variant-numeric: tabular-nums;
}
.ev-leistungen__label {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(22px, 2.6vw, 38px);
  line-height: 1.1;
  letter-spacing: -0.005em;
  text-transform: uppercase;
  color: var(--fg);
}
.ev-leistungen__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand);
}

/* ============================================================
   ⑤ YOUTUBE FACADE — poster + bordeaux play, iframe on click
   ============================================================ */
.ev-youtube {
  position: relative;
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
  cursor: pointer;
}
.ev-youtube__poster {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 40%, #2a0810 0%, #0a0a0a 70%);
  background-size: cover;
  background-position: center;
  filter: grayscale(0.3) contrast(1.1) brightness(0.55);
  transition: transform 0.8s var(--ease-out), filter 0.5s var(--ease-out);
}
.ev-youtube:hover .ev-youtube__poster {
  transform: scale(1.04);
  filter: grayscale(0) contrast(1.05) brightness(0.65);
}
.ev-youtube::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(0,0,0,0.6) 100%);
  pointer-events: none;
}
.ev-youtube__play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: clamp(72px, 10vw, 132px);
  height: clamp(72px, 10vw, 132px);
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s var(--ease-out), transform 0.3s var(--ease-out);
  z-index: 2;
}
.ev-youtube:hover .ev-youtube__play {
  background: var(--brand-2);
  transform: translate(-50%, -50%) scale(1.06);
}
.ev-youtube__play::before {
  content: "";
  position: absolute;
  inset: -16px;
  border-radius: 50%;
  border: 1px solid var(--brand);
  opacity: 0.5;
  animation: youtubePulse 2.4s var(--ease-in-out) infinite;
}
@keyframes youtubePulse {
  0%   { transform: scale(1);   opacity: 0.55; }
  100% { transform: scale(1.4); opacity: 0;    }
}
.ev-youtube__play svg {
  width: 38%;
  height: 38%;
  margin-left: 6%;
}
.ev-youtube__caption {
  position: absolute;
  left: 32px;
  bottom: 24px;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  z-index: 2;
  font-weight: 400;
}
.ev-youtube__caption strong { color: #fff; font-weight: 600; }
.ev-youtube iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  z-index: 3;
}
.ev-youtube.is-loaded .ev-youtube__poster,
.ev-youtube.is-loaded .ev-youtube__play,
.ev-youtube.is-loaded .ev-youtube__caption,
.ev-youtube.is-loaded::after { display: none; }

/* ============================================================
   ⑥ GALERIE — masonry + lightbox
   ============================================================ */
.ev-gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}
.ev-gallery__tile {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  background: var(--bg-3);
  aspect-ratio: 4 / 5;
  transition: filter 0.4s var(--ease-out);
}
.ev-gallery__tile:nth-child(1) { grid-column: span 2; grid-row: span 2; aspect-ratio: 1; }
.ev-gallery__tile:nth-child(6) { grid-column: span 2; aspect-ratio: 16 / 9; }
.ev-gallery__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: grayscale(0.5) contrast(1.1);
  transition: transform 0.6s var(--ease-out), filter 0.5s var(--ease-out);
}
.ev-gallery__tile:hover .ev-gallery__bg {
  transform: scale(1.04);
  filter: grayscale(0) contrast(1.05);
}
.ev-gallery__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,0.75) 100%);
  opacity: 0.5;
  transition: opacity 0.3s var(--ease-out);
}
.ev-gallery__tile:hover .ev-gallery__overlay { opacity: 1; }
.ev-gallery__caption {
  position: absolute;
  bottom: 12px;
  left: 14px;
  right: 14px;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #fff;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.3s var(--ease-out), transform 0.3s var(--ease-out);
}
.ev-gallery__tile:hover .ev-gallery__caption {
  opacity: 1;
  transform: translateY(0);
}
.ev-gallery__count {
  position: absolute;
  top: 12px;
  right: 14px;
  font-size: 10px;
  letter-spacing: 0.3em;
  color: #fff;
  font-variant-numeric: tabular-nums;
  background: rgba(0,0,0,0.55);
  padding: 4px 8px;
  border-radius: 999px;
  font-weight: 500;
}
/* Light mode: darken the overlay further so white text stays legible
   over a potentially light photo / against white page bg. */
html.site-light .ev-gallery__count,
body.site-light .ev-gallery__count {
  background: rgba(0,0,0,0.75);
}

@media (max-width: 1023.98px) {
  .ev-gallery { grid-template-columns: repeat(2, 1fr); }
  .ev-gallery__tile:nth-child(1) { grid-column: span 2; grid-row: auto; aspect-ratio: 4 / 5; }
  .ev-gallery__tile:nth-child(6) { grid-column: span 2; }
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(6, 7, 8, 0.96);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5vh 7vw;
  animation: lbFade 0.3s var(--ease-out);
}
/* The JS opens/closes the lightbox via the `hidden` attribute (lb.hidden =
   true/false). The `display: flex` above otherwise overrides `[hidden]`'s
   default display:none, leaving the overlay permanently visible over the page. */
.lightbox[hidden] {
  display: none !important;
}
@keyframes lbFade { from { opacity: 0; } to { opacity: 1; } }
.lightbox__dots {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: radial-gradient(circle, var(--brand) 1.5px, transparent 1.5px);
  background-size: 32px 32px;
  background-position: 0 0;
  opacity: 0.07;
  pointer-events: none;
}
.lightbox__inner {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
}
.lightbox__media {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  min-height: 0;
}
.lightbox__img {
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-color: var(--bg-3);
}
.lightbox__bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 4px 0;
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--fg-2);
  font-weight: 400;
}
.lightbox__bar strong { color: var(--fg); font-weight: 600; }
.lightbox__close {
  position: absolute;
  top: 22px;
  right: 28px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--fg);
  cursor: pointer;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.25s var(--ease-out), border-color 0.25s var(--ease-out);
}
.lightbox__close:hover { background: var(--brand); border-color: var(--brand); color: #fff; }
.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--fg);
  cursor: pointer;
  z-index: 2;
  font-size: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.25s var(--ease-out), border-color 0.25s var(--ease-out);
}
.lightbox__nav:hover { background: var(--brand); border-color: var(--brand); color: #fff; }
.lightbox__nav--prev { left: 12px; }
.lightbox__nav--next { right: 12px; }

/* ============================================================
   ⑦ TESTIMONIALS — quote carousel
   ============================================================ */
.ev-testimonials {
  max-width: 1100px;
  margin: 0 auto;
  text-align: center;
}
.ev-testimonials__quote {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(26px, 3.4vw, 48px);
  line-height: 1.18;
  letter-spacing: -0.005em;
  color: var(--fg);
  margin: 0 0 40px;
  max-width: 28ch;
  margin-left: auto;
  margin-right: auto;
  text-wrap: balance;
}
.ev-testimonials__quote::before {
  content: "“";
  color: var(--brand);
  font-size: 1.4em;
  line-height: 0;
  vertical-align: -0.35em;
  margin-right: 0.05em;
}
.ev-testimonials__quote::after {
  content: "”";
  /* Decorative closing mark in the card's top-right corner, riding the
     vendored legacy `blockquote:after` (position:absolute; right:20px;
     font-family:'myicon' — "”" is not in the icon font, so the browser
     falls back to a system font: that round-comma rendering is the
     approved look, deliberately kept). The legacy top:20px crowded the
     glyph against the card edge — 35px gives it full headroom
     (user-validated, 2026-07-02). */
  top: 35px;
  color: var(--brand);
  font-size: 1.4em;
  line-height: 0;
}
/* Legacy `.site-dark blockquote:after` outranks the rule above on
   `color` (extra class in the selector) — pin the brand colour in
   dark mode too. */
.site-dark .ev-testimonials__quote::after {
  color: var(--brand);
}
.ev-testimonials__author {
  display: inline-flex;
  align-items: center;
  gap: 16px;
}
.ev-testimonials__photo {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--brand);
}
.ev-testimonials__meta {
  text-align: left;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.ev-testimonials__meta strong {
  color: var(--fg);
  font-weight: 600;
  display: block;
}
.ev-testimonials__meta span {
  color: var(--fg-2);
  font-weight: 400;
}
.ev-testimonials__dots {
  display: inline-flex;
  gap: 8px;
  margin-top: 40px;
  justify-content: center;
}
.ev-testimonials__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid var(--fg-3);
  transition: background 0.25s var(--ease-out), transform 0.25s var(--ease-out);
}
.ev-testimonials__dot.is-active {
  background: var(--brand);
  border-color: var(--brand);
  transform: scale(1.3);
}

/* ============================================================
   ⑧ GOOGLE MAPS — bordeaux dot pattern + venue card
   ============================================================ */
.ev-map {
  position: relative;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 64px;
  align-items: stretch;
}
@media (max-width: 1023.98px) {
  .ev-map { grid-template-columns: 1fr; gap: 32px; }
}
.ev-map__visual {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--bg-2);
  border: 1px solid var(--line);
  overflow: hidden;
}
.ev-map__visual::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, var(--brand) 1.4px, transparent 1.4px);
  background-size: 24px 24px;
  opacity: 0.55;
}
.ev-map__pin {
  position: absolute;
  top: 38%;
  left: 52%;
  width: 56px;
  height: 56px;
  transform: translate(-50%, -100%);
}
.ev-map__pin::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--brand);
  border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
  box-shadow: 0 16px 24px rgba(139, 0, 40, 0.45);
}
.ev-map__pin::after {
  content: "";
  position: absolute;
  top: 16px;
  left: 16px;
  width: 24px;
  height: 24px;
  background: var(--bg);
  border-radius: 50%;
}
.ev-map__pin-pulse {
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 18px;
  height: 6px;
  border-radius: 50%;
  background: rgba(139, 0, 40, 0.35);
  animation: pinPulse 1.6s var(--ease-in-out) infinite;
}
@keyframes pinPulse {
  0%, 100% { transform: translateX(-50%) scale(1); opacity: 0.6; }
  50%      { transform: translateX(-50%) scale(1.6); opacity: 0.2; }
}
.ev-map__card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 24px;
}
.ev-map__venue {
  font-family: var(--font-display);
  font-weight: 100;
  font-size: clamp(28px, 3.4vw, 56px);
  line-height: 1;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: var(--fg);
  margin: 0;
}
.ev-map__address {
  font-size: 16px;
  line-height: 1.5;
  color: var(--fg-2);
  margin: 0;
}
.ev-map__link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--brand);
  color: var(--brand);
  padding: 14px 28px;
  border-radius: 999px;
  font-size: 13px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 500;
  align-self: flex-start;
  transition: background 0.3s var(--ease-out), color 0.3s var(--ease-out);
}
.ev-map__link:hover { background: var(--brand); color: #fff; }
.ev-map__arrow { display: inline-flex; align-items: center; transition: transform 0.3s var(--ease-out); }
.ev-map__arrow svg { width: 20px; height: auto; stroke-width: 1; }
.ev-map__link:hover .ev-map__arrow { transform: translateX(4px); }

/* ============================================================
   PANEL PADDING — every event panel that isn't .ev-hero or the
   .brand-scroller needs breathing room around its content so the
   heading doesn't sit at y=0 of the slide (which gets clipped on
   the horizontal scroll). The hero owns its own padding (see ①);
   the marquee separator is intentionally flush.
   ============================================================ */
.event-single .ptsc:not(.ev-hero):not(.brand-scroller) {
  padding: var(--row) var(--side) 80px;
}
/* In m-mode (mobile/tablet, panels stack vertically) the horizontal
   scroll no longer fills each panel to the viewport height, so the
   ~14vh top padding becomes pure dead space between sections. Trim it
   to a tight rhythm that still keeps headings well clear of the panel
   edge but reads as a series of scrollable sections, not pages. */
.event-single.m-mode .ptsc:not(.ev-hero):not(.brand-scroller),
body.m-mode .ptsc-list.event-single .ptsc:not(.ev-hero):not(.brand-scroller) {
  padding-top: clamp(48px, 9vw, 88px);
  padding-bottom: clamp(40px, 8vw, 72px);
}

/* ============================================================
   PANEL HEADINGS — shared by .ev-leistungen, .ev-gallery-section,
   .ev-youtube-section, .ev-testimonials-section, .ev-map-section,
   .ev-related-section. All 6 panels use the same
   .section-eyebrow + .heading markup, so we style them once at
   the .event-single scope.
   ============================================================ */
.event-single .ptsc .section-eyebrow {
  font-size: clamp(11px, 0.9vw, 14px);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.6);
  margin: 0 0 18px;
}
.event-single .ptsc .heading {
  font-family: var(--font-display);
  font-weight: 100;
  font-size: clamp(40px, 5vw, 84px);
  line-height: 0.95;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: #fff;
  margin: 0 0 clamp(40px, 5vw, 72px);
  max-width: 900px;
}
/* Light mode: heading + eyebrow read on the light page bg. */
html.site-light .event-single .ptsc .heading,
body.site-light .event-single .ptsc .heading { color: #0a0a0a; }
html.site-light .event-single .ptsc .section-eyebrow,
body.site-light .event-single .ptsc .section-eyebrow { color: rgba(0, 0, 0, 0.55); }

/* ============================================================
   ⑨ RELATED EVENTS — 3 cards
   ============================================================ */

.ev-related {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
/* Tablet (640–1023px): 2 columns — the 1-col fallback below produced
   single cards stretched ~700px wide on iPad portrait, dwarfing every
   other panel. 2 cols keeps the grid feeling like a grid. */
@media (max-width: 1023.98px) { .ev-related { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 639.98px)  { .ev-related { grid-template-columns: 1fr; } }

.ev-related-card {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  cursor: pointer;
  background: var(--bg-3);
  text-decoration: none;
  color: inherit;
  transition:
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}
.ev-related-card:hover,
.ev-related-card:focus-visible {
  transform: translateY(-6px);
  box-shadow: 0 24px 60px -20px rgba(139, 0, 40, 0.55);
  outline: none;
}
.ev-related-card__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: grayscale(0.5) contrast(1.05);
  transition: transform 0.6s var(--ease-out), filter 0.5s var(--ease-out);
}
.ev-related-card:hover .ev-related-card__bg { transform: scale(1.08); filter: grayscale(0); }
.ev-related-card__overlay {
  /* Gradient at the BOTTOM half — that's where the info lives so the dark
     surface absorbs the white text. Top half stays clearer so the photo
     reads first. */
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,0.9) 100%);
}
.ev-related-card__info {
  /* Info at the BOTTOM of card (image at top reads as the primary visual,
     metadata + title + chips at bottom as the secondary read). */
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 24px;
  color: #fff;
  z-index: 2;
}
.ev-related-card__meta {
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  margin-bottom: 8px;
}
.ev-related-card__name {
  font-family: var(--font-display);
  font-weight: 100;
  font-size: clamp(20px, 1.8vw, 30px);
  letter-spacing: -0.01em;
  text-transform: uppercase;
  line-height: 1;
}
.ev-related-card__cats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}
.ev-related-card__cat {
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 500;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 999px;
  padding: 4px 10px;
}
/* Light mode: brand-colour the chip so it stays visible regardless
   of the underlying card image. Matches the toggle's light icon colour. */
html.site-light .ev-related-card__cat,
body.site-light .ev-related-card__cat {
  color: #641c34;
  border-color: rgba(100, 28, 52, 0.6);
  background: rgba(255, 255, 255, 0.85);
}

/* Hover: chip switches to solid bordeaux with white text — apply
   globally on .ev-related-card so it lights up on single-event
   detail pages AND on event_typ archive cards. !important defeats
   the .site-light override above, which would otherwise win in
   light mode. */
.ev-related-card:hover .ev-related-card__cat,
.ev-related-card:focus-visible .ev-related-card__cat {
  background: rgba(139, 0, 40, 0.85) !important;
  border-color: #ff003a !important;
  color: #fff !important;
}

/* Respect reduced-motion: cancel the lift transform site-wide. */
@media (prefers-reduced-motion: reduce) {
  .ev-related-card,
  .ev-related-card__bg {
    transition: none !important;
  }
  .ev-related-card:hover,
  .ev-related-card:focus-visible {
    transform: none !important;
  }
}

/* ============================================================
   ⑩ PREV / NEXT NAV (chronological)
   ============================================================ */
.ev-prevnext {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--line);
}
.ev-prevnext__side {
  background: var(--bg);
  padding: clamp(40px, 6vw, 80px) clamp(32px, 4vw, 64px);
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-decoration: none;
  color: inherit;
  transition: background 0.4s var(--ease-out);
  position: relative;
  overflow: hidden;
}
.ev-prevnext__side:hover { background: var(--bg-2); }
.ev-prevnext__side--next { text-align: right; align-items: flex-end; }
.ev-prevnext__label {
  font-size: 11px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--fg-2);
  font-weight: 400;
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.ev-prevnext__label::before {
  content: "←";
  color: var(--brand);
  font-size: 18px;
  transition: transform 0.3s var(--ease-out);
}
.ev-prevnext__side--next .ev-prevnext__label::before { content: ""; }
.ev-prevnext__side--next .ev-prevnext__label::after  {
  content: "→";
  color: var(--brand);
  font-size: 18px;
  transition: transform 0.3s var(--ease-out);
}
.ev-prevnext__side--prev:hover .ev-prevnext__label::before { transform: translateX(-6px); }
.ev-prevnext__side--next:hover .ev-prevnext__label::after  { transform: translateX(6px); }
.ev-prevnext__title {
  font-family: var(--font-display);
  font-weight: 100;
  font-size: clamp(28px, 3.6vw, 56px);
  line-height: 0.95;
  letter-spacing: -0.015em;
  text-transform: uppercase;
  color: var(--fg);
  margin: 0;
}
.ev-prevnext__meta {
  font-size: 12px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--fg-2);
  font-weight: 400;
}
@media (max-width: 767.98px) {
  .ev-prevnext { grid-template-columns: 1fr; }
  .ev-prevnext__side--next { text-align: left; align-items: flex-start; }
}

/* ============================================================
   ⑪ ALLE-EVENTS CTA — full-bleed archive link
   ============================================================ */
.ev-archive {
  /* Left-aligned at the safe-area like every other section (intro, content,
     Leistungen …) — NOT centred — so "Alle Events" sits on the same vertical
     edge as the hero and reads as one more section of the page. */
  text-align: left;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: clamp(20px, 3vh, 40px);
}
.ev-archive__eyebrow {
  /* Same section-eyebrow as the rest of the page (cf. .ev-content__label):
     a 40px bordeaux connector tick + tracked uppercase label, so this section
     label is visually identical to "Leistungen", "Über uns" etc. */
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 12px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--fg-2);
  font-weight: 400;
}
.ev-archive__eyebrow::before {
  content: "";
  width: 40px;
  height: 1px;
  background: var(--brand);
}
.ev-archive__title {
  font-family: var(--font-display);
  font-weight: 100;
  /* Match the hero scale (not larger): the hero stays the page's biggest
     element, and this CTA reads as a peer statement title, not an outlier. */
  font-size: clamp(56px, 11vw, 200px);
  line-height: 0.86;
  letter-spacing: -0.025em;
  text-transform: uppercase;
  color: var(--fg);
  margin: 0;
  position: relative;
  text-decoration: none;
  display: inline-block;
  /* Safety net for very narrow viewports (<360px) or longer translations:
     allow the title to wrap a long single word rather than push the arrow
     off-screen. The clamp() above keeps the floor at 56px, so even when
     wrapped the title still reads as the page's closing statement. */
  max-width: 100%;
  overflow-wrap: break-word;
}
/* Drop the 56px floor below 380px so the title comfortably fits even
   on the smallest supported viewports (Galaxy A 360 etc.) with the
   arrow alongside it on one line. */
@media (max-width: 379.98px) {
  .ev-archive__title { font-size: clamp(40px, 13vw, 56px); }
}
.ev-archive__arrow {
  display: inline-flex;
  align-items: center;
  color: var(--brand);
  margin-left: 0.2em;
  vertical-align: middle;
  transition: transform 0.4s var(--ease-out);
}
.ev-archive__arrow svg {
  width: clamp(28px, 4vw, 52px);
  height: auto;
  stroke-width: 1;
}
.ev-archive__title:hover .ev-archive__arrow { transform: translateX(0.15em); }
.ev-archive__title:hover { color: var(--brand); }

/* ============================================================
   DARK-ONLY PAGE — hide the dark-mode toggle in the sidebar
   ------------------------------------------------------------
   Event detail pages are forced dark (body.site-dark added in PHP +
   JS, see setup.php / main.js). A `role="switch"` that can no longer
   switch shouldn't be exposed, so hide it here. The rest of the
   sidebar (logo + nav pills) is unchanged, so it still matches the
   homepage sidebar — just without the now-meaningless toggle.
   ============================================================ */
/* Toggle now visible on single-event pages too — kept here as a
   placeholder comment to document the deliberate change. The previous
   rule (display: none !important) was removed when the dark/light
   mode UX feature landed (the page now honours the visitor's
   preference instead of force-dark, so the toggle must be exposed). */

/* ============================================================
   EMPTY-BLOCK PLACEHOLDER (spec mode only)
   Shows where a hidden block would have sat.
   ============================================================ */
.ev-empty {
  position: relative;
  border: 1px dashed var(--line-strong);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--fg-3);
}
.ev-empty__label {
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--brand-2);
  font-weight: 500;
}
.ev-empty__field {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 22px;
  color: var(--fg-2);
  letter-spacing: -0.01em;
}
.ev-empty__hint { font-size: 13px; color: var(--fg-3); font-weight: 300; max-width: 40ch; }

/* When NOT in spec mode, hidden blocks render as nothing (panel removed) */
.event-detail:not(.spec-mode) .ev-empty-panel { display: none !important; }

/* ============================================================
   EVENT PICKER — top-right floating selector (above tweaks)
   Lets the user cycle through sample events in the design demo.
   ============================================================ */
.ev-switcher {
  position: fixed;
  top: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 60;
  display: flex;
  gap: 6px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px;
}
.ev-switcher__btn {
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-2);
  font-weight: 400;
  padding: 8px 16px;
  border-radius: 999px;
  background: transparent;
  border: 0;
  cursor: pointer;
  transition: background 0.25s var(--ease-out), color 0.25s var(--ease-out);
  white-space: nowrap;
}
.ev-switcher__btn:hover { color: var(--fg); }
.ev-switcher__btn.is-active {
  background: var(--brand);
  color: #fff;
}
@media (max-width: 767.98px) { .ev-switcher { display: none; } }

/* ============================================================
   HORIZONTAL-MODE TIGHTENING for the new blocks
   ============================================================ */
.app--horizontal .ev-hero {
  flex: 0 0 100vw;
  min-width: 100vw;
  height: 100vh;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: clamp(64px, 9vh, 120px) var(--side) 80px;
  overflow: hidden;
  margin: 0;
}
/* Pad the wrap inside horizontal mode so the dot/timeline doesn't overlap content */
.app--horizontal section.block .wrap {
  padding-bottom: 64px;
}

/* ============================================================
   GROTEC-NEW HORIZONTAL INTEGRATION
   The detail page renders inside `.ptsc-list.event-single > .wrap`,
   scrolled by the theme's transform-based engine (NOT scroll-snap).
   Each `<section class="ptsc ev-*">` becomes a full-viewport panel.
   ============================================================ */
body:not(.m-mode) .ptsc-list.event-single > .wrap > section.ptsc {
  flex: 0 0 100vw;
  width: 100vw;
  height: 100%;
  overflow: hidden;
  scroll-snap-align: none;
  margin: 0;
  /* Clear the fixed sidebar (~166px) on the left, on every panel, with breathing room. */
  padding-left: clamp(196px, 13vw, 248px) !important;
  /* Center content vertically so no panel leaves a big empty void below it
     (every block fills its slide consistently, not floating at the top). */
  display: flex;
  flex-direction: column;
  justify-content: center;
}
/* Hero: bottom-anchored column inside our wrapper. */
body:not(.m-mode) .ptsc-list.event-single > .wrap > .ev-hero {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
/* Tall panels may exceed 100vh — scroll internally instead of clipping.
   Selectors must match the actual <section> classes (template-parts/event/*.php);
   `.ev-gallery`/`.ev-testimonials`/`.ev-related` are inner child elements,
   NOT the panel itself, so they never matched here — the panel kept
   `overflow: hidden` + `justify-content: center` from the generic rule
   above, which on a panel taller than 100vh clips the top AND bottom
   symmetrically instead of scrolling, cramming the heading against the
   viewport edge (bug: "galerie titre trop en haut", 2026-07-02).
   ⚠️ Also needs the `section` type selector (not just the class) to match
   the generic rule's specificity (0,5,2) — a class-only override here
   loses the cascade even though it comes later in the file. */
body:not(.m-mode) .ptsc-list.event-single > .wrap > section.ev-gallery-section,
body:not(.m-mode) .ptsc-list.event-single > .wrap > section.ev-leistungen,
body:not(.m-mode) .ptsc-list.event-single > .wrap > section.ev-testimonials-section,
body:not(.m-mode) .ptsc-list.event-single > .wrap > section.ev-related-section {
  overflow-y: auto;
  justify-content: flex-start;
}
/* Mobile (.m-mode): panels stack full-width (theme rules set width/height);
   drop the left sidebar safe-area (mobile uses a top header, not a left rail). */
.m-mode .ptsc-list.event-single > .wrap > section.ptsc {
  padding-left: var(--side) !important;
}

/* ─────────────────────────────────────────────────────────────
   Variant B — enriched navigation chrome (.evchrome)
   Panel counter (top-right) + timeline dots (bottom) + scroll hint
   (bottom-right). Mirrors the design handoff (.h-counter / .h-timeline /
   .scroll-hint). Only rendered + styled under body.chrome-variant-b.
   z-index 40 — above panels, BELOW the lightbox (z 200) and the sidebar.
   ───────────────────────────────────────────────────────────── */
body.chrome-variant-b .evchrome {
  /* Container is a passthrough; children are individually fixed. */
}

/* Panel counter — top-right pill */
body.chrome-variant-b .evchrome__counter {
  position: fixed;
  top: 28px;
  right: 28px;
  z-index: 40;
  font-size: 12px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--fg-2);
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  background: var(--bg);
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  pointer-events: none;
}
body.chrome-variant-b .evchrome__current {
  color: var(--fg);
  font-weight: 600;
}
body.chrome-variant-b .evchrome__sep {
  margin: 0 6px;
  color: var(--fg-3);
}

/* Timeline — bottom rail with segmented progress + dots */
body.chrome-variant-b .evchrome__timeline {
  position: fixed;
  left: clamp(96px, 13vw, 248px);
  right: 28px;
  bottom: 24px;
  z-index: 40;
  pointer-events: none;
}
body.chrome-variant-b .evchrome__bar {
  position: relative;
  height: 1px;
  background: var(--line-strong);
}
body.chrome-variant-b .evchrome__fill {
  position: absolute;
  left: 0;
  top: -1px;
  height: 3px;
  width: 0%;
  background: var(--brand);
  box-shadow: 0 0 12px rgba(139, 0, 40, 0.4);
  transition: width 0.15s linear;
}
body.chrome-variant-b .evchrome__dots {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
body.chrome-variant-b .evchrome__dot {
  flex: 0 0 auto;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--fg-3);
  transition: background 0.25s var(--ease-out),
              border-color 0.25s var(--ease-out),
              transform 0.25s var(--ease-out);
}
body.chrome-variant-b .evchrome__dot.is-past {
  background: var(--brand);
  border-color: var(--brand);
}
body.chrome-variant-b .evchrome__dot.is-active {
  background: var(--brand);
  border-color: var(--brand);
  transform: scale(1.7);
  box-shadow: 0 0 0 4px rgba(139, 0, 40, 0.18);
}

/* Scroll hint — bottom-right pill */
body.chrome-variant-b .evchrome__scroll-hint {
  position: fixed;
  bottom: 56px;
  right: 28px;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--bg);
  color: var(--fg-2);
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-weight: 400;
  pointer-events: none;
  animation: evchromeHintBob 2s var(--ease-in-out) infinite;
}
body.chrome-variant-b .evchrome__scroll-hint.is-hidden {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s var(--ease-out), visibility 0s linear 0.3s;
}
body.chrome-variant-b .evchrome__arrow {
  font-size: 14px;
  color: var(--brand);
  animation: evchromeHintArrow 1.5s var(--ease-out) infinite;
}

@keyframes evchromeHintBob {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-3px); }
}
@keyframes evchromeHintArrow {
  0%, 100% { transform: translateX(0); opacity: 0.6; }
  50%      { transform: translateX(6px); opacity: 1; }
}

/* Mobile (.m-mode): vertical stacking — the counter/timeline/scroll-hint make
   no sense, so hide the entire enriched chrome. */
.m-mode .evchrome,
body.chrome-variant-b.m-mode .evchrome {
  display: none;
}

/* Reduced motion: drop the looping animations + the fill transition. */
@media (prefers-reduced-motion: reduce) {
  body.chrome-variant-b .evchrome__scroll-hint,
  body.chrome-variant-b .evchrome__arrow {
    animation: none;
  }
  body.chrome-variant-b .evchrome__fill {
    transition: none;
  }
  body.chrome-variant-b .evchrome__dot {
    transition: none;
  }
}
