/* ==========================================================================
   Eventpage Theme-Engine — theme.css
   Eine Datei fuer alle Presets. Farben/Fonts/Formen kommen als Tokens (--ep-*)
   aus ThemeCss::rootVars(); Layout-Varianten ueber data-*-Attribute am <html>:
     data-surface  flat | outlined | elevated | brutal
     data-density  compact | regular | airy
     data-shape    none | sm | md | lg | pill
     data-hero     full | split | poster | minimal
     data-cards    poster | tile | row
     data-motion   reduced | subtle | expressive
   Alles liegt in @layer ep — Veranstalter-CSS (ungelayert) gewinnt ohne !important.
   Mobile-first. Kein Framework, kein jQuery.
   ========================================================================== */
@layer ep {

/* --------------------------------------------------------------------------
   BASE: Token-Defaults (= Preset "clean"), Reset, Typografie
   -------------------------------------------------------------------------- */
:root {
  --ep-bg: #fafaf8; --ep-surface: #ffffff; --ep-surface-2: #f3f3f1;
  --ep-text: #16191d; --ep-muted: #5b6470;
  --ep-primary: #0e7490; --ep-primary-hover: #0c667f; --ep-primary-soft: #dfeef1; --ep-on-primary: #ffffff;
  --ep-accent: #f59e0b; --ep-on-accent: #000000;
  --ep-line: #dddedb; --ep-line-strong: #bfc1bd; --ep-focus: #0e7490;
  --ep-shadow: 0 1px 2px rgba(16,20,24,.06), 0 10px 30px -14px rgba(16,20,24,.22);
  --ep-shadow-lg: 0 24px 50px -24px rgba(16,20,24,.28);
  --ep-hero-overlay: rgba(0,0,0,.45); --ep-hero-text: #ffffff; --ep-hero-alpha: .4;
  --ep-radius: 12px; --ep-radius-sm: 6px; --ep-space: 1;
  --ep-font-display: "Space Grotesk", system-ui, sans-serif; --ep-font-body: "Inter", system-ui, sans-serif;
  --ep-display-weight: 700; --ep-display-transform: none; --ep-display-tracking: -.02em;
  /* abgeleitete Layout-Groessen */
  --ep-container: 1200px;
  --ep-gutter: clamp(16px, 4vw, 64px);
  --ep-header-h: 56px;
  --ep-section-y: calc(clamp(48px, 8vw, 96px) * var(--ep-space));
  --ep-gap: calc(clamp(16px, 2.5vw, 28px) * var(--ep-space));
  --ep-border-w: 1px;
  --ep-tap: 44px;
}
[data-surface="brutal"] { --ep-border-w: 1px; --ep-line: var(--ep-line-strong); }
[data-surface="outlined"] { --ep-shadow: none; }
[data-surface="flat"] { --ep-shadow: none; --ep-shadow-lg: none; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--ep-header-h) + 12px); }
body.ep-body {
  margin: 0; background: var(--ep-bg); color: var(--ep-text);
  font: 400 1rem/1.55 var(--ep-font-body); -webkit-font-smoothing: antialiased;
  min-height: 100dvh; display: flex; flex-direction: column;
}
.ep-main { flex: 1 0 auto; }
img, svg, video, iframe { max-width: 100%; }
img { height: auto; display: block; }
a { color: var(--ep-primary); text-decoration-thickness: 1px; text-underline-offset: .15em; }
a:hover { color: var(--ep-primary-hover); }
h1, h2, h3, h4, .ep-display {
  font-family: var(--ep-font-display); font-weight: var(--ep-display-weight);
  text-transform: var(--ep-display-transform); letter-spacing: var(--ep-display-tracking);
  line-height: 1.1; margin: 0 0 .5em; overflow-wrap: anywhere; hyphens: auto; text-wrap: balance;
}
h1 { font-size: clamp(2rem, 6vw, 3.5rem); }
h2 { font-size: clamp(1.6rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.125rem, 2.5vw, 1.5rem); }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--ep-focus); outline-offset: 2px; border-radius: 2px; }
::selection { background: var(--ep-primary); color: var(--ep-on-primary); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
input, select, textarea { font-size: 16px; }   /* kein iOS-Zoom */
ul[role="list"], .ep-nav-list, .ep-drawer-list, .ep-drawer-legal, .ep-footer-nav ul, .ep-footer-social { list-style: none; margin: 0; padding: 0; }

.ep-skip { position: absolute; left: 8px; top: -100px; z-index: 1000; padding: 10px 14px; background: var(--ep-primary); color: var(--ep-on-primary); border-radius: var(--ep-radius-sm); font-weight: 600; }
.ep-skip:focus { top: 8px; }
.ep-container { width: 100%; max-width: var(--ep-container); margin-inline: auto; padding-inline: var(--ep-gutter); min-width: 0; }
.ep-container-narrow { max-width: 820px; }
.ep-icon { width: 1.25em; height: 1.25em; display: inline-block; vertical-align: -.25em; flex-shrink: 0; fill: none; }
.ep-icon[fill="currentColor"], .ep-icon use { pointer-events: none; }

/* --------------------------------------------------------------------------
   COMPONENTS: Buttons, Cards, Section-Kopf, Richtext, Header/Nav, Drawer,
   Sticky-CTA, Footer, Consent, Preview-Banner, Overlay
   -------------------------------------------------------------------------- */
.ep-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: var(--ep-tap); padding: .7em 1.35em; border: var(--ep-border-w) solid transparent; border-radius: var(--ep-radius-sm);
  font-family: var(--ep-font-display); font-weight: 600; font-size: 1rem; line-height: 1.2; text-decoration: none; cursor: pointer;
  text-transform: var(--ep-display-transform); letter-spacing: var(--ep-display-tracking); white-space: nowrap;
  transition: background-color .15s, color .15s, border-color .15s, transform .15s, box-shadow .15s;
}
.ep-btn .ep-icon { width: 1.15em; height: 1.15em; vertical-align: 0; }
.ep-btn-primary { background: var(--ep-primary); color: var(--ep-on-primary); border-color: var(--ep-primary); }
.ep-btn-primary:hover { background: var(--ep-primary-hover); border-color: var(--ep-primary-hover); color: var(--ep-on-primary); }
.ep-btn-ghost { background: transparent; color: var(--ep-text); border-color: var(--ep-line-strong); }
.ep-btn-ghost:hover { border-color: var(--ep-text); color: var(--ep-text); background: var(--ep-surface-2); }
.ep-btn-sm { min-height: 40px; padding: .5em 1em; font-size: .9375rem; }
.ep-btn-lg { padding: .9em 1.7em; font-size: 1.0625rem; }
.ep-btn-block { width: 100%; }
.ep-btn:active { transform: translateY(1px); }
[data-shape="pill"] .ep-btn { border-radius: 999px; }
[data-surface="brutal"] .ep-btn-primary { box-shadow: 3px 3px 0 0 var(--ep-text); }
[data-surface="brutal"] .ep-btn-primary:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 0 var(--ep-text); }
.ep-icon-btn { display: inline-flex; align-items: center; justify-content: center; width: var(--ep-tap); height: var(--ep-tap); padding: 0; border: var(--ep-border-w) solid var(--ep-line); border-radius: var(--ep-radius-sm); background: var(--ep-surface); color: var(--ep-text); }
.ep-icon-btn .ep-icon { width: 22px; height: 22px; vertical-align: 0; }

.ep-card { background: var(--ep-surface); border: var(--ep-border-w) solid var(--ep-line); border-radius: var(--ep-radius); box-shadow: var(--ep-shadow); }
[data-surface="flat"] .ep-card { border-color: transparent; background: var(--ep-surface-2); }

.ep-section { padding-block: var(--ep-section-y); min-width: 0; }
.ep-section + .ep-section { padding-top: 0; }
.ep-section.ep-block-hero { padding: 0; }
.ep-section.ep-block-hero + .ep-section { padding-top: var(--ep-section-y); }
.ep-block-head { margin-bottom: calc(var(--ep-gap) * 1.25); max-width: 60ch; }
.ep-block-head.is-center { margin-inline: auto; text-align: center; }
.ep-block-title { margin-bottom: .25em; }
.ep-block-subtitle { color: var(--ep-muted); font-size: 1.0625rem; margin: 0; }
.ep-eyebrow { display: inline-flex; align-items: center; gap: .5em; margin: 0 0 1em; padding: .35em .8em; border-radius: 999px; background: var(--ep-primary-soft); color: var(--ep-text); font-size: .875rem; font-weight: 600; }
.ep-empty-note { color: var(--ep-muted); text-align: center; padding: var(--ep-gap); border: 1px dashed var(--ep-line-strong); border-radius: var(--ep-radius); }
.ep-empty { text-align: center; padding: var(--ep-section-y) var(--ep-gutter); color: var(--ep-muted); }

.ep-richtext { font-size: 1.0625rem; line-height: 1.65; }
.ep-richtext > :first-child { margin-top: 0; }
.ep-richtext h2, .ep-richtext h3, .ep-richtext h4 { margin-top: 1.4em; }
.ep-richtext ul, .ep-richtext ol { padding-left: 1.4em; margin: 0 0 1em; }
.ep-richtext img { border-radius: var(--ep-radius-sm); margin: 1em 0; }
.ep-richtext blockquote { margin: 1.25em 0; padding: .25em 0 .25em 1em; border-left: 4px solid var(--ep-primary); color: var(--ep-muted); }
.ep-richtext table { width: 100%; border-collapse: collapse; display: block; overflow-x: auto; }
.ep-richtext td, .ep-richtext th { border: 1px solid var(--ep-line); padding: .5em .75em; text-align: left; }
.ep-richtext pre { overflow-x: auto; padding: 1em; background: var(--ep-surface-2); border-radius: var(--ep-radius-sm); }

/* Header / Navigation */
.ep-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--ep-bg) 88%, transparent); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: var(--ep-border-w) solid var(--ep-line); }
@supports not (background: color-mix(in srgb, red, blue)) { .ep-header { background: var(--ep-bg); } }
.ep-header-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--ep-gap); min-height: var(--ep-header-h); }
.ep-brand { display: inline-flex; align-items: center; min-height: var(--ep-tap); text-decoration: none; color: var(--ep-text); min-width: 0; }
.ep-brand-logo { height: 36px; width: auto; max-width: min(48vw, 220px); object-fit: contain; }
.ep-brand-text { font-family: var(--ep-font-display); font-weight: var(--ep-display-weight); text-transform: var(--ep-display-transform); letter-spacing: var(--ep-display-tracking); font-size: 1.25rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ep-nav-desktop { display: none; }
.ep-nav-list { display: flex; gap: .25rem; align-items: center; }
.ep-nav-link { display: inline-flex; align-items: center; gap: .3em; min-height: var(--ep-tap); padding: .5em .8em; border-radius: var(--ep-radius-sm); color: var(--ep-text); text-decoration: none; font-weight: 500; }
.ep-nav-link:hover { background: var(--ep-surface-2); color: var(--ep-text); }
.ep-nav-link[aria-current="page"] { color: var(--ep-primary); box-shadow: inset 0 -2px 0 var(--ep-primary); border-radius: 0; }
.ep-nav-sub { position: relative; }
.ep-nav-sub summary { list-style: none; cursor: pointer; }
.ep-nav-sub summary::-webkit-details-marker { display: none; }
.ep-nav-caret { width: 1em; height: 1em; transition: transform .15s; }
.ep-nav-sub[open] .ep-nav-caret { transform: rotate(180deg); }
.ep-nav-desktop .ep-nav-sublist { position: absolute; top: 100%; left: 0; min-width: 220px; padding: .35rem; margin: 0; list-style: none; background: var(--ep-surface); border: var(--ep-border-w) solid var(--ep-line); border-radius: var(--ep-radius-sm); box-shadow: var(--ep-shadow-lg); z-index: 60; }
.ep-nav-desktop .ep-nav-sublist .ep-nav-link { width: 100%; }
.ep-header-actions { display: flex; align-items: center; gap: .5rem; flex-shrink: 0; }
.ep-header-cta span { display: none; }
.ep-header-cta .ep-icon { width: 20px; height: 20px; }
@media (min-width: 480px) { .ep-header-cta span { display: inline; } }
@media (min-width: 900px) {
  .ep-nav-desktop { display: block; }
  .ep-nav-toggle { display: none; }
  :root { --ep-header-h: 64px; }
  .ep-brand-logo { height: 40px; }
}

/* Drawer (<dialog>) */
.ep-drawer { position: fixed; inset: 0 0 0 auto; width: min(88vw, 360px); max-width: none; height: 100dvh; max-height: none; margin: 0; padding: 0 var(--ep-gutter) var(--ep-gutter); border: 0; border-left: var(--ep-border-w) solid var(--ep-line); background: var(--ep-surface); color: var(--ep-text); box-shadow: var(--ep-shadow-lg); overflow-y: auto; }
.ep-drawer::backdrop { background: rgba(0,0,0,.5); backdrop-filter: blur(2px); }
.ep-drawer:not([open]) { display: none; }
.ep-drawer-head { position: sticky; top: 0; display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: var(--ep-header-h); background: var(--ep-surface); border-bottom: var(--ep-border-w) solid var(--ep-line); margin-bottom: 1rem; }
.ep-drawer-title { font-family: var(--ep-font-display); font-weight: var(--ep-display-weight); text-transform: var(--ep-display-transform); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ep-drawer-list .ep-nav-link { display: flex; width: 100%; font-size: 1.125rem; min-height: 48px; }
.ep-drawer-list .ep-nav-sublist { list-style: none; margin: 0; padding: 0 0 .5rem 1rem; }
.ep-drawer-list .ep-nav-sublist .ep-nav-link { font-size: 1rem; }
.ep-drawer .ep-btn-block { margin-block: 1.25rem; }
.ep-drawer-legal { display: flex; gap: 1rem; font-size: .875rem; }
.ep-drawer-legal a { color: var(--ep-muted); display: inline-block; padding: .5em 0; }
@media (min-width: 900px) { .ep-drawer, .ep-drawer[open] { display: none; } }

/* Sticky-CTA (nur mobil) */
.ep-sticky-cta { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding: .6rem var(--ep-gutter) calc(.6rem + env(safe-area-inset-bottom)); background: var(--ep-surface); border-top: var(--ep-border-w) solid var(--ep-line); box-shadow: 0 -8px 30px -12px rgba(0,0,0,.35); transition: transform .25s, opacity .25s; }
.ep-sticky-cta.is-hidden { transform: translateY(110%); opacity: 0; pointer-events: none; }
.ep-sticky-cta-info { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.ep-sticky-cta-label { font-size: .75rem; color: var(--ep-muted); text-transform: uppercase; letter-spacing: .06em; }
.ep-sticky-cta-name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ep-sticky-cta .ep-btn { flex-shrink: 0; }
body.ep-body:has(.ep-sticky-cta) .ep-footer { padding-bottom: calc(80px + env(safe-area-inset-bottom)); }
@media (min-width: 900px) { .ep-sticky-cta { display: none; } body.ep-body:has(.ep-sticky-cta) .ep-footer { padding-bottom: 0; } }

/* Footer */
.ep-footer { margin-top: auto; background: var(--ep-surface); border-top: var(--ep-border-w) solid var(--ep-line); color: var(--ep-muted); font-size: .9375rem; }
.ep-footer-grid { display: grid; gap: var(--ep-gap); padding-block: calc(var(--ep-gap) * 1.5); }
.ep-footer-name { display: block; font-family: var(--ep-font-display); font-weight: var(--ep-display-weight); text-transform: var(--ep-display-transform); color: var(--ep-text); font-size: 1.125rem; margin-bottom: .5rem; }
.ep-footer-text { font-size: .9375rem; }
.ep-footer-text p:last-child { margin-bottom: 0; }
.ep-footer-nav ul { display: flex; flex-wrap: wrap; gap: .25rem 1rem; }
.ep-footer-nav a, .ep-footer-meta a { color: inherit; text-decoration: none; display: inline-block; padding: .4em 0; }
.ep-footer-nav a:hover, .ep-footer-meta a:hover { color: var(--ep-primary); }
.ep-footer-social { display: flex; flex-wrap: wrap; gap: .5rem; }
.ep-footer-social a { display: inline-flex; align-items: center; justify-content: center; width: var(--ep-tap); height: var(--ep-tap); border: var(--ep-border-w) solid var(--ep-line); border-radius: var(--ep-radius-sm); color: var(--ep-text); }
.ep-footer-social a:hover { border-color: var(--ep-primary); color: var(--ep-primary); }
.ep-footer-social .ep-icon { width: 20px; height: 20px; vertical-align: 0; }
.ep-footer-meta { display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; align-items: center; padding-block: 1rem; border-top: var(--ep-border-w) solid var(--ep-line); font-size: .875rem; }
.ep-powered { margin-left: auto; }
@media (min-width: 768px) { .ep-footer-grid { grid-template-columns: 1.4fr 1fr auto; align-items: start; } .ep-footer-social { justify-content: flex-end; } }

/* Consent-Banner */
.ep-consent { position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; display: grid; gap: .75rem; padding: 1rem var(--ep-gutter) calc(1rem + env(safe-area-inset-bottom)); background: var(--ep-surface); color: var(--ep-text); border-top: var(--ep-border-w) solid var(--ep-line); box-shadow: var(--ep-shadow-lg); font-size: .9375rem; }
.ep-consent[hidden] { display: none; }
.ep-consent-text { margin: 0; max-width: 70ch; }
.ep-consent-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.ep-consent-actions .ep-btn { flex: 1 1 140px; }
@media (min-width: 768px) { .ep-consent { grid-template-columns: 1fr auto; align-items: center; left: auto; right: 1.5rem; bottom: 1.5rem; max-width: 720px; border: var(--ep-border-w) solid var(--ep-line); border-radius: var(--ep-radius); } .ep-consent-actions .ep-btn { flex: 0 0 auto; } }
body.ep-body:has(.ep-consent:not([hidden])) .ep-sticky-cta { transform: translateY(110%); opacity: 0; pointer-events: none; }

/* Preview-Banner + AJAX-Overlay */
.ep-preview-banner { position: sticky; top: 0; z-index: 60; background: #b3007d; color: #fff; font: 600 13px/1.4 system-ui, sans-serif; text-align: center; padding: 8px 12px; }
.ep-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.7); z-index: 99999; }

/* --------------------------------------------------------------------------
   BLOCKS: Hero, Events, Countdown, Text, News, Kontakt, FAQ, Video, Galerie, HTML
   -------------------------------------------------------------------------- */
/* Hero */
.ep-hero { position: relative; display: grid; align-items: center; min-height: 60vh; min-height: min(60dvh, 560px); overflow: clip; background: var(--ep-surface-2); }
.ep-hero.no-image { min-height: 0; padding-block: calc(var(--ep-section-y) * 1.1); }
.ep-hero-media { position: absolute; inset: 0; z-index: 0; }
.ep-hero-media img, .ep-hero-media picture { width: 100%; height: 100%; object-fit: cover; display: block; }
.ep-hero-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,calc(var(--ep-hero-alpha) * .6)) 0%, rgba(0,0,0,var(--ep-hero-alpha)) 60%, rgba(0,0,0,calc(var(--ep-hero-alpha) + .15)) 100%); }
.ep-hero-body { position: relative; z-index: 1; padding-block: calc(var(--ep-section-y) * .9); max-width: var(--ep-container); }
.ep-hero.has-image .ep-hero-body { color: var(--ep-hero-text); }
.ep-hero.has-image .ep-eyebrow { background: rgba(255,255,255,.14); color: #fff; backdrop-filter: blur(6px); }
.ep-hero-title { font-size: clamp(2rem, 7vw, 5rem); margin-bottom: .3em; max-width: 18ch; }
.ep-hero-sub { font-size: clamp(1.0625rem, 2.2vw, 1.375rem); max-width: 52ch; margin-bottom: 1.5em; opacity: .92; }
.ep-hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.ep-hero.has-image .ep-btn-ghost { color: #fff; border-color: rgba(255,255,255,.6); }
.ep-hero.has-image .ep-btn-ghost:hover { background: rgba(255,255,255,.12); border-color: #fff; color: #fff; }
/* full: bildschirmfuellend */
[data-hero="full"] .ep-hero.has-image { min-height: 80vh; min-height: min(80dvh, 720px); }
/* split: ab 900px Text links, Bild rechts als echtes <img> */
@media (min-width: 900px) {
  [data-hero="split"] .ep-hero.has-image { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); min-height: min(70dvh, 640px); background: var(--ep-bg); }
  [data-hero="split"] .ep-hero.has-image .ep-hero-media { position: relative; grid-column: 2; order: 2; min-height: 100%; }
  [data-hero="split"] .ep-hero.has-image .ep-hero-media::after { background: linear-gradient(90deg, var(--ep-bg) 0%, transparent 25%); }
  [data-hero="split"] .ep-hero.has-image .ep-hero-body { grid-column: 1; color: var(--ep-text); padding-right: 0; margin-inline: 0 0; padding-left: max(var(--ep-gutter), calc((100vw - var(--ep-container)) / 2 + var(--ep-gutter))); }
  [data-hero="split"] .ep-hero.has-image .ep-eyebrow { background: var(--ep-primary-soft); color: var(--ep-text); }
  [data-hero="split"] .ep-hero.has-image .ep-btn-ghost { color: var(--ep-text); border-color: var(--ep-line-strong); }
}
/* poster: Bild als gerahmtes Plakat neben dem Text */
[data-hero="poster"] .ep-hero.has-image { grid-template-columns: 1fr; gap: var(--ep-gap); background: var(--ep-bg); min-height: 0; padding-block: var(--ep-section-y); }
[data-hero="poster"] .ep-hero.has-image .ep-hero-media { position: relative; width: min(100%, 520px); margin-inline: var(--ep-gutter); aspect-ratio: 16 / 10; border-radius: var(--ep-radius); overflow: hidden; box-shadow: var(--ep-shadow-lg); border: var(--ep-border-w) solid var(--ep-line); }
[data-hero="poster"] .ep-hero.has-image .ep-hero-media::after { display: none; }
[data-hero="poster"] .ep-hero.has-image .ep-hero-body { color: var(--ep-text); padding-block: 0; }
[data-hero="poster"] .ep-hero.has-image .ep-eyebrow { background: var(--ep-primary-soft); color: var(--ep-text); }
[data-hero="poster"] .ep-hero.has-image .ep-btn-ghost { color: var(--ep-text); border-color: var(--ep-line-strong); }
@media (min-width: 900px) {
  [data-hero="poster"] .ep-hero.has-image { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); align-items: center; }
  [data-hero="poster"] .ep-hero.has-image .ep-hero-media { order: 2; margin-inline: 0 var(--ep-gutter); aspect-ratio: 4 / 5; width: min(100%, 460px); justify-self: end; }
  [data-hero="poster"] .ep-hero.has-image .ep-hero-body { padding-left: max(var(--ep-gutter), calc((100vw - var(--ep-container)) / 2 + var(--ep-gutter))); margin-inline: 0; }
}
/* minimal: kein Bild, grosse Typo */
[data-hero="minimal"] .ep-hero { background: var(--ep-bg); }
[data-hero="minimal"] .ep-hero-title { font-size: clamp(2.5rem, 9vw, 6.5rem); }

/* Events */
.ep-events { display: grid; gap: var(--ep-gap); grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }
.ep-events > * { min-width: 0; }
.ep-event-card { display: flex; }
.ep-event-link { display: flex; flex-direction: column; width: 100%; min-width: 0; color: inherit; text-decoration: none; background: var(--ep-surface); border: var(--ep-border-w) solid var(--ep-line); border-radius: var(--ep-radius); overflow: hidden; box-shadow: var(--ep-shadow); transition: transform .2s, box-shadow .2s, border-color .2s; }
[data-surface="flat"] .ep-event-link { border-color: transparent; background: var(--ep-surface-2); }
.ep-event-media { position: relative; aspect-ratio: 2 / 3; background: var(--ep-surface-2); overflow: hidden; }
/* Querformat-Plakate (Server setzt .is-landscape aus den Bildmassen): eigenes
   Seitenverhaeltnis statt brutalem 2:3-Beschnitt. */
.ep-event-media.is-landscape { aspect-ratio: 16 / 10; }
.ep-event-media img, .ep-event-media picture { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s; }
.ep-event-noimg { width: 100%; height: 100%; display: grid; place-items: center; color: var(--ep-muted); }
.ep-event-noimg .ep-icon { width: 3rem; height: 3rem; }
.ep-event-badge { position: absolute; top: 12px; left: 12px; display: flex; flex-direction: column; align-items: center; min-width: 52px; padding: .35rem .5rem; background: var(--ep-surface); color: var(--ep-text); border-radius: var(--ep-radius-sm); box-shadow: var(--ep-shadow); line-height: 1; font-family: var(--ep-font-display); }
.ep-event-badge-day { font-size: 1.375rem; font-weight: 700; }
.ep-event-badge-mon { font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ep-primary); font-weight: 600; margin-top: .15rem; }
.ep-event-flag { position: absolute; top: 12px; right: 12px; padding: .3em .6em; background: rgba(0,0,0,.65); color: #fff; font-size: .75rem; border-radius: var(--ep-radius-sm); text-transform: uppercase; letter-spacing: .05em; }
.ep-event-card.is-past .ep-event-media img { filter: grayscale(1); opacity: .75; }
.ep-event-body { display: flex; flex-direction: column; gap: .4rem; padding: calc(var(--ep-gap) * .8); flex: 1; min-width: 0; }
.ep-event-meta { display: flex; flex-wrap: wrap; gap: .3rem 1rem; margin: 0; font-size: .875rem; color: var(--ep-muted); }
.ep-event-meta span { display: inline-flex; align-items: center; gap: .35em; min-width: 0; overflow-wrap: anywhere; }
.ep-event-meta .ep-icon { color: var(--ep-primary); }
.ep-event-name { font-size: clamp(1.125rem, 2.5vw, 1.5rem); margin: 0; }
.ep-event-sub { color: var(--ep-muted); margin: 0; font-size: .9375rem; }
.ep-event-cta { display: inline-flex; align-items: center; gap: .4em; margin-top: auto; padding-top: .75rem; color: var(--ep-primary); font-weight: 600; font-family: var(--ep-font-display); text-transform: var(--ep-display-transform); }
.ep-event-cta .ep-icon { transition: transform .2s; }
@media (hover: hover) {
  .ep-event-link:hover { transform: translateY(-3px); box-shadow: var(--ep-shadow-lg); border-color: var(--ep-line-strong); }
  .ep-event-link:hover .ep-event-media img { transform: scale(1.03); }
  .ep-event-link:hover .ep-event-cta .ep-icon { transform: translateX(4px); }
  [data-surface="brutal"] .ep-event-link:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 0 var(--ep-primary); }
}
/* tile: Querformat-Bild, kompakter */
[data-cards="tile"] .ep-event-media { aspect-ratio: 16 / 10; }
[data-cards="tile"] .ep-events { grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
/* row / Listenansicht: eine Zeile pro Event, Bild links */
[data-cards="row"] .ep-events, .ep-events.is-list { grid-template-columns: 1fr; gap: calc(var(--ep-gap) * .75); }
[data-cards="row"] .ep-event-link, .ep-events.is-list .ep-event-link { flex-direction: row; align-items: stretch; }
[data-cards="row"] .ep-event-media, .ep-events.is-list .ep-event-media { flex: 0 0 34%; max-width: 220px; aspect-ratio: 3 / 4; }
[data-cards="row"] .ep-event-media.is-landscape, .ep-events.is-list .ep-event-media.is-landscape { aspect-ratio: 16 / 10; }
[data-cards="row"] .ep-event-badge, .ep-events.is-list .ep-event-badge { top: 8px; left: 8px; min-width: 44px; }
@media (max-width: 479px) { [data-cards="row"] .ep-event-media, .ep-events.is-list .ep-event-media { flex-basis: 40%; } }
[data-preset="redalert"] .ep-event-media img { filter: grayscale(1); transition: filter .5s, transform .5s; }
@media (min-width: 1024px) and (hover: hover) { [data-preset="redalert"] .ep-event-link:hover .ep-event-media img { filter: grayscale(0); } }

/* Countdown */
.ep-countdown-wrap { text-align: center; }
.ep-countdown { display: grid; grid-template-columns: repeat(auto-fit, minmax(64px, 1fr)); gap: .75rem; max-width: 640px; margin-inline: auto; }
.ep-countdown-unit { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: .9rem .25rem; background: var(--ep-surface); border: var(--ep-border-w) solid var(--ep-line); border-radius: var(--ep-radius); box-shadow: var(--ep-shadow); min-width: 0; }
.ep-countdown-num { font-family: var(--ep-font-display); font-weight: 700; font-size: clamp(1.75rem, 8vw, 4rem); line-height: 1; font-variant-numeric: tabular-nums; color: var(--ep-primary); }
.ep-countdown-label { margin-top: .35rem; font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ep-muted); }
.ep-countdown-done { grid-column: 1 / -1; font-family: var(--ep-font-display); font-size: clamp(1.5rem, 5vw, 3rem); font-weight: 700; color: var(--ep-primary); margin: 0; }
.ep-countdown-link { margin: calc(var(--ep-gap) * 1.2) 0 0; }

/* Text */
.ep-text.is-center { text-align: center; } .ep-text.is-center .ep-block-head { margin-inline: auto; }
.ep-text.is-right { text-align: right; } .ep-text.is-right .ep-block-head { margin-left: auto; }

/* News */
.ep-news { display: grid; gap: var(--ep-gap); grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.ep-news-item { display: flex; flex-direction: column; overflow: hidden; min-width: 0; }
.ep-news-media { aspect-ratio: 16 / 9; background: var(--ep-surface-2); overflow: hidden; }
.ep-news-media img, .ep-news-media picture { width: 100%; height: 100%; object-fit: cover; }
.ep-news-body { padding: calc(var(--ep-gap) * .8); display: flex; flex-direction: column; gap: .35rem; }
.ep-news-date { font-size: .8125rem; color: var(--ep-muted); text-transform: uppercase; letter-spacing: .05em; }
.ep-news-title { margin: 0; font-size: 1.25rem; }
.ep-news-text { margin: 0; color: var(--ep-muted); font-size: .9375rem; }

/* Kontakt */
.ep-contact { display: grid; gap: var(--ep-gap); }
.ep-contact.has-map { grid-template-columns: 1fr; }
@media (min-width: 768px) { .ep-contact.has-map { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); } }
.ep-contact-list { display: grid; gap: 1rem; }
.ep-contact-item { display: flex; gap: .75rem; align-items: flex-start; font-size: 1.0625rem; min-width: 0; overflow-wrap: anywhere; }
.ep-contact-item .ep-icon { color: var(--ep-primary); margin-top: .2em; width: 1.4em; height: 1.4em; }
.ep-contact-item a { min-height: var(--ep-tap); display: inline-flex; align-items: center; }
.ep-contact-item address { font-style: normal; line-height: 1.5; }
.ep-map { display: grid; place-content: center; gap: .75rem; text-align: center; padding: var(--ep-gap); min-height: 260px; }
.ep-map.is-loaded { display: block; padding: 0; overflow: hidden; }
.ep-map.is-loaded iframe { width: 100%; height: 100%; min-height: 320px; border: 0; display: block; }
.ep-map-note { color: var(--ep-muted); font-size: .9375rem; margin: 0; max-width: 42ch; }

/* FAQ */
.ep-faq { display: grid; gap: .5rem; }
.ep-faq-item { background: var(--ep-surface); border: var(--ep-border-w) solid var(--ep-line); border-radius: var(--ep-radius); box-shadow: var(--ep-shadow); overflow: hidden; }
.ep-faq-q { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 56px; padding: .9rem 1.1rem; cursor: pointer; list-style: none; font-weight: 600; font-size: 1.0625rem; }
.ep-faq-q::-webkit-details-marker { display: none; }
.ep-faq-q:hover { background: var(--ep-surface-2); }
.ep-faq-caret { transition: transform .2s; color: var(--ep-primary); }
.ep-faq-item[open] .ep-faq-caret { transform: rotate(180deg); }
.ep-faq-a { padding: 0 1.1rem 1.1rem; color: var(--ep-text); line-height: 1.6; }

/* Video */
.ep-video { margin: 0; }
.ep-video-frame { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--ep-surface-2); display: grid; }
.ep-video-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.ep-video-play { display: grid; place-content: center; gap: .5rem; width: 100%; height: 100%; padding: 1rem; border: 0; background: radial-gradient(ellipse at center, var(--ep-primary-soft), var(--ep-surface-2)); color: var(--ep-text); text-align: center; }
.ep-video-play-icon { display: grid; place-items: center; width: 72px; height: 72px; margin-inline: auto; border-radius: 999px; background: var(--ep-primary); color: var(--ep-on-primary); box-shadow: var(--ep-shadow-lg); transition: transform .15s; }
.ep-video-play-icon .ep-icon { width: 34px; height: 34px; fill: currentColor; vertical-align: 0; }
.ep-video-play:hover .ep-video-play-icon { transform: scale(1.06); }
.ep-video-play-text { font-family: var(--ep-font-display); font-weight: 600; font-size: 1.125rem; }
.ep-video-play-note { font-size: .8125rem; color: var(--ep-muted); max-width: 36ch; margin-inline: auto; }
.ep-video-caption { margin-top: .6rem; color: var(--ep-muted); font-size: .9375rem; }
.ep-video-fallback { font-size: .875rem; margin: .4rem 0 0; }

/* Galerie + Lightbox */
.ep-gallery { display: grid; gap: .75rem; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 700px) { .ep-gallery { grid-template-columns: repeat(var(--ep-gallery-cols, 3), minmax(0, 1fr)); gap: var(--ep-gap); } }
.ep-gallery-item { min-width: 0; }
.ep-gallery-item a { position: relative; display: block; aspect-ratio: 1; overflow: hidden; border-radius: var(--ep-radius); background: var(--ep-surface-2); border: var(--ep-border-w) solid var(--ep-line); }
.ep-gallery-item img, .ep-gallery-item picture { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.ep-gallery-zoom { position: absolute; right: 8px; bottom: 8px; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 999px; background: rgba(0,0,0,.55); color: #fff; opacity: 0; transition: opacity .2s; }
.ep-gallery-zoom .ep-icon { width: 18px; height: 18px; vertical-align: 0; }
@media (hover: hover) { .ep-gallery-item a:hover img { transform: scale(1.04); } .ep-gallery-item a:hover .ep-gallery-zoom { opacity: 1; } }
.ep-gallery-caption { margin: .4rem 0 0; font-size: .875rem; color: var(--ep-muted); }
.ep-lightbox { max-width: min(96vw, 1400px); max-height: 96dvh; padding: 0; border: 0; background: transparent; }
.ep-lightbox::backdrop { background: rgba(0,0,0,.88); }
.ep-lightbox figure { margin: 0; display: grid; gap: .5rem; justify-items: center; }
.ep-lightbox img { max-width: 96vw; max-height: 86dvh; width: auto; height: auto; object-fit: contain; border-radius: var(--ep-radius-sm); }
.ep-lightbox figcaption { color: #fff; font-size: .9375rem; text-align: center; padding: 0 1rem; }
.ep-lightbox-close { position: fixed; top: 12px; right: 12px; background: rgba(0,0,0,.6); color: #fff; border-color: rgba(255,255,255,.3); }

/* HTML-Block: eigenes Layout, nur Viewport-Schutz mobil */
.ep-html { min-width: 0; }
@media (max-width: 767px) { .ep-html { overflow-x: clip; } .ep-html * { max-width: 100%; overflow-wrap: anywhere; } }

/* --------------------------------------------------------------------------
   MOTION: expressive (nur redalert-Look) — Scanline + Glow, nie ohne Hover/
   Bewegungsfreigabe; reduced-motion schaltet alles ab.
   -------------------------------------------------------------------------- */
@media (min-width: 768px) and (prefers-reduced-motion: no-preference) {
  [data-motion="expressive"] .ep-hero::before { content: ""; position: absolute; left: 0; right: 0; height: 120px; z-index: 2; pointer-events: none; background: linear-gradient(0deg, transparent 0%, color-mix(in srgb, var(--ep-primary) 10%, transparent) 50%, transparent 100%); animation: ep-scan 7s linear infinite; }
  [data-motion="expressive"] .ep-btn-primary:hover { box-shadow: 0 0 0 3px color-mix(in srgb, var(--ep-primary) 30%, transparent), 4px 4px 0 0 var(--ep-text); }
  [data-motion="expressive"] .ep-countdown-num { text-shadow: 0 0 24px color-mix(in srgb, var(--ep-primary) 45%, transparent); }
}
@keyframes ep-scan { 0% { top: -120px; } 100% { top: 100%; } }
[data-motion="reduced"] * { transition-duration: 0s !important; animation: none !important; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

} /* @layer ep */
