/* Dreamwalkers – Stylesheet
   Konzept: Kontaktabzug. Helles Papier, schwarze Bildrahmen, Fettstift-Rot nur für das nächste Event.
   Keine externen Schriften/CDNs (DSGVO: keine Drittanbieter-Verbindungen). */

:root {
  color-scheme: light;
  --paper: #f6f6f3;       /* Fotopapier */
  --paper-2: #ebebe6;     /* Bildfläche / Platzhalter */
  --ink: #17171c;         /* Schrift, Rahmen */
  --ink-soft: #55555f;    /* Nebentext */
  --rule: #17171c26;      /* Haarlinien */
  --blue: #23307a;        /* Tinte: Links */
  --marker: #c23b22;      /* Fettstift: nur nächstes Event */
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.1; margin: 0 0 .5em; text-wrap: balance; }
h2 { font-size: clamp(2rem, 4.2vw, 2.9rem); }
h3 { font-size: 1.5rem; }
p { margin: 0 0 1em; }
.small { font-size: .9rem; color: var(--ink-soft); }

.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 14px; z-index: 100; }
.skip:focus { left: 8px; }

.container { width: min(1140px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(720px, 100% - 32px); }
.section { padding-block: clamp(56px, 9vw, 112px); border-top: 1px solid var(--rule); }

/* Etikett im Stil der Filmrand-Beschriftung */
.eyebrow, .event-meta, .label {
  font-family: var(--mono);
  font-size: .76rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: .9em;
}
.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head p:last-child { color: var(--ink-soft); }

/* ---------- Buttons: eckig, ohne Verlauf ---------- */
.btn {
  display: inline-block;
  padding: 12px 20px;
  font: 600 .92rem/1.2 var(--sans);
  text-decoration: none;
  border: 1px solid var(--ink);
  border-radius: 0;
  color: var(--ink);
  background: transparent;
  transition: background .15s, color .15s;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn-solid { background: var(--ink); color: var(--paper); }
.btn-solid:hover { background: var(--paper); color: var(--ink); }
.btn-light { border-color: #fff; color: #fff; }
.btn-light:hover { background: #fff; color: var(--ink); }
.link-arrow { font-weight: 600; font-size: .92rem; color: var(--ink); text-decoration: underline; text-underline-offset: 5px; }
.link-arrow::after { content: " →"; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
}
.nav { width: min(1140px, 100% - 32px); margin: auto; height: 60px; display: flex; align-items: center; justify-content: space-between; }
.brand { font-family: var(--serif); font-size: 1.3rem; color: var(--ink); text-decoration: none; }
.nav-links { list-style: none; display: flex; gap: 26px; margin: 0; padding: 0; align-items: center; }
.nav-links a { color: var(--ink); text-decoration: none; font-size: .93rem; }
.nav-links a:hover { text-decoration: underline; }
.nav-links .nav-cta { color: var(--marker); font-weight: 600; }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 5px 0; transition: transform .25s, opacity .25s; }

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute; top: 60px; left: 0; right: 0;
    flex-direction: column; gap: 0; background: var(--paper);
    border-bottom: 1px solid var(--rule);
    max-height: 0; overflow: hidden; transition: max-height .3s ease;
  }
  .nav-links.open { max-height: 400px; }
  .nav-links li { width: 100%; border-top: 1px solid var(--rule); }
  .nav-links a { display: block; padding: 14px 16px; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

/* ---------- Hero: Foto als Hintergrund ---------- */
.hero {
  position: relative;
  min-height: clamp(520px, 86vh, 900px);
  display: flex; align-items: flex-end;
  padding-block: 96px 56px;
  color: #fff;
  background:
    linear-gradient(0deg, rgba(10,10,16,.82) 0%, rgba(10,10,16,.35) 45%, rgba(10,10,16,.1) 100%),
    url("image/hero.jpg") center 35% / cover no-repeat,
    var(--ink);
}
.hero-inner { min-width: 0; }
.hero .eyebrow { color: rgba(255,255,255,.8); }
/* Titel bricht nie um – er wird kleiner (CSS + script.js) */
.hero-inner { container-type: inline-size; }
.fit-title {
  white-space: nowrap;
  font-size: min(7.5rem, 15cqi);
  letter-spacing: -.01em; line-height: .95; margin-bottom: .25em;
}
.hero-lead { font-family: var(--serif); font-size: clamp(1.2rem, 2.4vw, 1.6rem); font-style: italic; max-width: 30ch; }
.hero-actions { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; margin-top: 28px; }
.hero .link-arrow { color: #fff; }
.hero-credit { position: absolute; right: 16px; bottom: 12px; margin: 0; font: .68rem/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: rgba(255,255,255,.7); }

/* ---------- Bilder als Abzug: Papierrand + schwarze Linie ---------- */
.event-media {
  margin: 0;
  position: relative;
  background: #fff;
  border: 1px solid var(--ink);
  padding: 10px 10px 34px;
  cursor: zoom-in;
  max-width: 100%;
  min-width: 0;
}
.event > *, .next-grid > *, .cards > * { min-width: 0; }
.event-media img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; background: var(--paper-2); }
.event-media figcaption {
  position: absolute; left: 10px; right: 10px; bottom: 9px;
  font-family: var(--mono); font-size: .7rem; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-soft);
  display: flex; justify-content: space-between; gap: 12px;
}
.event-media.portrait { max-width: 440px; justify-self: center; width: 100%; }
.event-media.portrait img { aspect-ratio: auto; }
.event-media.no-image { cursor: default; }
.event-media.no-image img { visibility: hidden; }
.event-media.no-image::before {
  content: "Foto folgt";
  position: absolute; inset: 10px 10px 34px;
  display: grid; place-items: center;
  font-family: var(--mono); font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft);
  background: repeating-linear-gradient(135deg, var(--paper-2) 0 10px, var(--paper) 10px 20px);
}

/* ---------- Intro ---------- */
.intro .lead { font-size: 1.22rem; font-family: var(--serif); }
.quote { margin: 40px 0 0; padding: 0 0 0 22px; border-left: 2px solid var(--ink); }
.quote p { font-family: var(--serif); font-size: 1.3rem; font-style: italic; margin-bottom: .4em; }
.quote cite { font-family: var(--mono); font-style: normal; font-size: .76rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }

/* ---------- Events ---------- */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(48px, 7vw, 88px); }
.event { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: center; }
.event-body { min-width: 0; }
.event:nth-child(even) .event-media { order: 2; }
.event-highlight h3 { font-size: 1.9rem; }
@media (max-width: 820px) {
  .event { grid-template-columns: 1fr; }
  .event:nth-child(even) .event-media { order: 0; }
}

/* ---------- Ausstellungen ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 48px; }
.card { min-width: 0; display: grid; gap: 22px; align-content: start; }

/* ---------- Nächstes Event: Foto der Lichterparade als Hintergrund ---------- */
.next {
  position: relative; color: #f6f6f3; border-top: 0;
  background:
    linear-gradient(90deg, rgba(10,10,18,.92) 0%, rgba(10,10,18,.78) 50%, rgba(10,10,18,.35) 100%),
    url("image/lichterfest-halle.jpg") center / cover no-repeat,
    var(--ink);
}
.next a:not(.btn) { color: #fff; }
.next-grid { display: grid; grid-template-columns: auto minmax(0, 620px); gap: clamp(28px, 5vw, 72px); align-items: start; }
.next-date-block { font-family: var(--serif); color: #ff8f72; line-height: .9; margin: 0; }
.next-date-block .days { display: block; font-size: clamp(4rem, 11vw, 7.5rem); font-variant-numeric: tabular-nums; white-space: nowrap; }
.next-date-block .month { display: block; font-family: var(--mono); font-size: .85rem; letter-spacing: .1em; text-transform: uppercase; margin-top: 10px; }
.next h2 { font-size: clamp(2.2rem, 5vw, 3.4rem); }
.next .eyebrow { color: #ff8f72; }
.next-place { font-weight: 600; }
.countdown { font-family: var(--mono); font-size: .82rem; letter-spacing: .06em; text-transform: uppercase; color: rgba(255,255,255,.75); min-height: 1.6em; }
.facts { list-style: none; padding: 0; margin: 24px 0 30px; border-top: 1px solid rgba(255,255,255,.25); }
.facts li { display: grid; grid-template-columns: 180px 1fr; gap: 16px; padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,.25); }
.facts span { font-family: var(--mono); font-size: .76rem; letter-spacing: .08em; text-transform: uppercase; color: rgba(255,255,255,.7); padding-top: 3px; }
.next-credit { position: absolute; right: 16px; bottom: 12px; margin: 0; font: .68rem/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: rgba(255,255,255,.6); }
@media (max-width: 640px) {
  .next { background: linear-gradient(rgba(10,10,18,.86), rgba(10,10,18,.86)), url("image/lichterfest-halle.jpg") center / cover no-repeat, var(--ink); }
  .next-grid { grid-template-columns: 1fr; }
  .facts li { grid-template-columns: 1fr; gap: 2px; }
}

/* ---------- Kontakt ---------- */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; }
.two-col > div { min-width: 0; }
@media (max-width: 820px) { .two-col { grid-template-columns: 1fr; } }
.mail { font-family: var(--serif); font-size: 1.45rem; word-break: break-word; }
.credits { list-style: none; padding: 0; margin: 0 0 1em; border-top: 1px solid var(--rule); }
.credits li { padding: 10px 0; border-bottom: 1px solid var(--rule); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--ink); padding-block: 24px; font-size: .88rem; color: var(--ink-soft); }
.footer-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.footer-inner p { margin: 0; }
.footer-inner a { color: var(--ink-soft); }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 200; background: rgba(246,246,243,.97); display: grid; place-items: center; padding: 24px; }
.lightbox[hidden] { display: none; }
.lightbox img { max-width: 100%; max-height: 82vh; border: 1px solid var(--ink); background: #fff; padding: 10px; }
.lightbox-caption { margin-top: 12px; font-family: var(--mono); font-size: .76rem; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-soft); text-align: center; }
.lightbox-close { position: absolute; top: 14px; right: 18px; background: none; border: 1px solid var(--ink); color: var(--ink); font-size: 1.6rem; width: 44px; height: 44px; cursor: pointer; line-height: 1; }

/* ---------- Unterseiten (Impressum) ---------- */
.page { padding-block: 64px 80px; }
.page h1 { font-size: clamp(2.2rem, 5vw, 3.2rem); }
.page h2 { font-size: 1.55rem; margin-top: 2em; }
.page h3 { font-size: 1.2rem; margin-top: 1.5em; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
