/* Clubhaus-Startbild im Stil der Flyer-Titelseite:
   Foto schräg angeschnitten, rote Doppellinie als Trennung,
   Logo auf der Trennlinie, Text auf dunkler Fläche. */

.clubhaus-page .club-hero--flyer {
  min-height: calc(100svh - var(--club-header-h, 8.65rem));
  /* Trennlinie: oben bei --cut-top, unten bei --cut-bottom (Desktop, in % der Breite) */
  --cut-top: 54vw;
  --cut-bottom: 24vw;
  --logo-size: clamp(14rem, 20vw, 20rem);
  --logo-y: 42%;
  --stripe-red: var(--club-red);
  --hero-gutter: max(1rem, calc((100vw - var(--max)) / 2));
  background-color: #383435;
  background-image:
    radial-gradient(ellipse 70% 80% at 85% 20%, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0) 70%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"),
    linear-gradient(160deg, #423d3e 0%, #2f2b2c 100%);
}

/* Foto: links oben, schräg abgeschnitten */
.clubhaus-page .club-hero--flyer .club-hero-background {
  z-index: 0;
  right: auto;
  width: calc(var(--cut-top) + 2.5vw);
  object-position: 78% 52%;
  clip-path: polygon(0 0, var(--cut-top) 0, var(--cut-bottom) 100%, 0 100%);
}

/* Rote Doppellinie entlang der Schnittkante */
.clubhaus-page .club-hero--flyer::before,
.clubhaus-page .club-hero--flyer::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0;
  background: var(--stripe-red);
  filter: none;
  pointer-events: none;
}

.clubhaus-page .club-hero--flyer::before {
  clip-path: polygon(
    calc(var(--cut-top) + 0.55rem) 0,
    calc(var(--cut-top) + 1.45rem) 0,
    calc(var(--cut-bottom) + 1.45rem) 100%,
    calc(var(--cut-bottom) + 0.55rem) 100%
  );
}

.clubhaus-page .club-hero--flyer::after {
  clip-path: polygon(
    calc(var(--cut-top) + 1.85rem) 0,
    calc(var(--cut-top) + 2.15rem) 0,
    calc(var(--cut-bottom) + 2.15rem) 100%,
    calc(var(--cut-bottom) + 1.85rem) 100%
  );
}

.clubhaus-page .club-hero--flyer .club-hero-copy {
  position: static;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  width: 100%;
  max-width: none;
  min-height: inherit;
  margin: 0;
  padding: clamp(2.5rem, 5vw, 4rem) var(--hero-gutter) clamp(10rem, 13vw, 11.5rem);
}

/* Logo sitzt auf der Trennlinie */
.clubhaus-page .club-hero--flyer .club-hero-logo {
  position: absolute;
  z-index: 3;
  top: calc(var(--logo-y) - var(--logo-size) / 2);
  left: calc(var(--cut-top) - (var(--cut-top) - var(--cut-bottom)) * 0.4 + 1rem - var(--logo-size) / 2);
  width: var(--logo-size);
  margin: 0;
  box-shadow: 0 1.5rem 3.5rem rgba(10, 6, 6, 0.38);
}

/* Text auf der dunklen Fläche */
.clubhaus-page .club-hero--flyer .club-hero-message {
  z-index: 2;
  width: min(31rem, 33vw);
  justify-self: end;
  padding: 0;
}

.clubhaus-page .club-hero--flyer .club-hero-message::before {
  content: none;
}

.clubhaus-page .club-hero--flyer .club-hero-title-light {
  color: var(--white);
}

.clubhaus-page .club-hero--flyer .club-hero-title-accent {
  color: var(--club-red);
  text-shadow: none;
}

.clubhaus-page .club-hero--flyer .club-hero-message p,
.clubhaus-page .club-hero--flyer .club-hero-message .club-hero-lead {
  color: rgba(255, 255, 255, 0.86);
}

.clubhaus-page .club-hero--flyer .club-hero-message .club-hero-lead {
  color: var(--white);
}

.clubhaus-page .club-hero--flyer .club-hero-message p {
  font-size: clamp(0.95rem, 1.2vw, 1.08rem);
  line-height: 1.6;
}

.clubhaus-page .club-hero--flyer .club-hero-message .club-hero-signoff {
  font-size: 0.72rem;
  border-top-color: rgba(255, 255, 255, 0.28);
  color: var(--white);
}

/* Tablet */
@media (max-width: 900px) {
  .clubhaus-page .club-hero--flyer {
    --cut-top: 50vw;
    --cut-bottom: 18vw;
    --logo-size: clamp(12rem, 30vw, 16rem);
  }

  .clubhaus-page .club-hero--flyer .club-hero-message {
    width: min(24rem, 42vw);
  }
}

/* Handy: wie die Flyer-Titelseite hochkant – Foto oben, Linie schräg, Text darunter */
@media (max-width: 700px) {
  .clubhaus-page .club-hero--flyer {
    min-height: 0;
    --photo-left: 23rem;
    --photo-right: 12.5rem;
    --logo-size: min(58vw, 14rem);
    min-height: 0;
  }

  .clubhaus-page .club-hero--flyer .club-hero-background {
    right: 0;
    width: 100%;
    bottom: auto;
    height: calc(var(--photo-left) + 1rem);
    object-position: 22% 60%;
    clip-path: polygon(0 0, 100% 0, 100% var(--photo-right), 0 var(--photo-left));
  }

  .clubhaus-page .club-hero--flyer::before {
    clip-path: polygon(
      0 calc(var(--photo-left) + 0.5rem),
      100% calc(var(--photo-right) + 0.5rem),
      100% calc(var(--photo-right) + 1.2rem),
      0 calc(var(--photo-left) + 1.2rem)
    );
  }

  .clubhaus-page .club-hero--flyer::after {
    clip-path: polygon(
      0 calc(var(--photo-left) + 1.55rem),
      100% calc(var(--photo-right) + 1.55rem),
      100% calc(var(--photo-right) + 1.8rem),
      0 calc(var(--photo-left) + 1.8rem)
    );
  }

  .clubhaus-page .club-hero--flyer .club-hero-logo {
    top: calc((var(--photo-left) + var(--photo-right)) / 2 + 0.6rem - var(--logo-size) / 2);
    left: calc(50% - var(--logo-size) / 2);
    margin: 0;
  }

  .clubhaus-page .club-hero--flyer .club-hero-copy {
    align-items: start;
    padding: calc(var(--photo-left) + 3rem) 1.25rem clamp(13rem, 60vw, 14.5rem);
  }

  .clubhaus-page .club-hero--flyer .club-hero-message {
    width: 100%;
    max-width: none;
    justify-self: stretch;
  }

  .clubhaus-page .club-hero--flyer h1 {
    font-size: clamp(2.3rem, 10vw, 2.9rem);
  }

  .clubhaus-page .club-hero--flyer .club-hero-message .club-hero-signoff {
    font-size: 0.66rem;
  }
}

/* Die Clubhaus-Leiste (Speisekarte, Öffnungszeiten, FAQ) legt sich über das
   Startbild, statt es zu verschieben. So bleibt das Bild beim Auf- und Zuklappen
   immer gleich groß und an derselben Stelle. */
.clubhaus-page.club-home .club-header .club-section-bar {
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
}

@media (min-width: 701px) {
  .clubhaus-page.club-home .club-hero--flyer .club-hero-copy {
    padding-top: calc(clamp(2.5rem, 5vw, 4rem) + 3.65rem);
  }
}

/* Logo im Startbild: dezentes Herauskommen beim Überfahren mit der Maus.
   `scale`/`rotate` statt `transform`, damit die Einblend-Animation unberührt bleibt. */
@media (hover: hover) and (pointer: fine) {
  .clubhaus-page .club-hero--flyer .club-hero-logo {
    transition:
      scale 520ms cubic-bezier(0.22, 1, 0.36, 1),
      rotate 520ms cubic-bezier(0.22, 1, 0.36, 1),
      box-shadow 520ms cubic-bezier(0.22, 1, 0.36, 1);
  }

  .clubhaus-page .club-hero--flyer .club-hero-logo:hover {
    scale: 1.045;
    rotate: -2deg;
    box-shadow: 0 2.25rem 4.5rem rgba(10, 6, 6, 0.48);
  }
}

@media (prefers-reduced-motion: reduce) {
  .clubhaus-page .club-hero--flyer .club-hero-logo,
  .clubhaus-page .club-hero--flyer .club-hero-logo:hover {
    scale: none;
    rotate: none;
    transition: none;
  }
}

/* Rote Doppellinie: zeichnet sich beim Laden der Seite einmal gleichmäßig langsam
   von oben nach unten ein, beide Linien gemeinsam. Animiert wird die Größe einer Maske,
   damit die Bewegung wirklich fließend ist. */
.clubhaus-page .club-hero--flyer::before,
.clubhaus-page .club-hero--flyer::after {
  -webkit-mask-image: linear-gradient(#000, #000);
  mask-image: linear-gradient(#000, #000);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: 0 0;
  mask-position: 0 0;
  animation: club-stripe-draw 3200ms linear 0s both;
}

@keyframes club-stripe-draw {
  from { -webkit-mask-size: 100% 0%; mask-size: 100% 0%; }
  to { -webkit-mask-size: 100% 100%; mask-size: 100% 100%; }
}

/* Handy: Linie verläuft quer, also von links nach rechts einzeichnen */
@media (max-width: 700px) {
  .clubhaus-page .club-hero--flyer::before,
  .clubhaus-page .club-hero--flyer::after {
    animation-name: club-stripe-draw-x;
  }

  @keyframes club-stripe-draw-x {
    from { -webkit-mask-size: 0% 100%; mask-size: 0% 100%; }
    to { -webkit-mask-size: 100% 100%; mask-size: 100% 100%; }
  }
}

@media (prefers-reduced-motion: reduce) {
  .clubhaus-page .club-hero--flyer::before,
  .clubhaus-page .club-hero--flyer::after {
    animation: none;
  }
}
