/* Passion Drive – VKU flyer popup styles */
.pdv {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  padding: 16px;
  opacity: 0;
  transition: opacity .25s ease;
}
.pdv[hidden] { display: none; }
.pdv.pdv-open { opacity: 1; }

/* darkened website behind the flyer */
.pdv-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .78);
}

/* the flyer: always fully visible, never wider than the screen,
   never taller than the screen */
.pdv-frame {
  --pdv-ratio: .5102;                         /* 852 / 1670 */
  position: relative;
  width: min(calc(100vw - 32px), calc((100vh - 32px) * var(--pdv-ratio)), 760px);
  width: min(calc(100vw - 32px), calc((100dvh - 32px) * var(--pdv-ratio)), 760px);
  aspect-ratio: 852 / 1670;
  border-radius: 14px;
  overflow: hidden;
  background: #000;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .65);
}
.pdv-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  user-select: none;
  -webkit-user-drag: none;
}

/* clickable area exactly over the flyer's "HIER FÜR DEN VKU ANMELDEN" button */
.pdv-cta {
  position: absolute;
  left: 4.69%;
  top: 75.93%;
  width: 90.38%;
  height: 7.78%;
  border-radius: 12px;
  -webkit-tap-highlight-color: transparent;
  transition: box-shadow .2s ease;
}
.pdv-cta:hover,
.pdv-cta:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px #e0b45a, 0 0 24px rgba(224, 180, 90, .8);
}

/* close button, top right */
.pdv-close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  width: 44px;
  height: 44px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(255, 255, 255, .9);
  border-radius: 50%;
  background: linear-gradient(135deg, #e0b45a, #c48f34);
  box-shadow: 0 4px 14px rgba(0, 0, 0, .6);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.pdv-close:hover { background: linear-gradient(135deg, #f0c56a, #d49f44); }
.pdv-close:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.pdv-close svg { display: block; }

/* stop the page behind from scrolling while the popup is open */
html.pdv-lock,
html.pdv-lock body { overflow: hidden !important; }

/* short screens (phones in landscape): flyer gets readable width,
   the popup scrolls, and the X stays pinned on screen */
@media (max-height: 520px) {
  .pdv { align-items: flex-start; overflow-y: auto; }
  .pdv-frame { width: min(calc(100vw - 32px), 560px); }
  .pdv-close {
    position: fixed;
    top: max(12px, env(safe-area-inset-top));
    right: max(12px, env(safe-area-inset-right));
  }
}

@media (prefers-reduced-motion: reduce) {
  .pdv, .pdv-cta { transition: none; }
}