/* EB Garamond (SIL Open Font License), lokal eingebunden – keine Verbindung zu Google */
@font-face {
  font-family: "EB Garamond";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../schrift/eb-garamond-400.woff2") format("woff2");
}

@font-face {
  font-family: "EB Garamond";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("../schrift/eb-garamond-400-kursiv.woff2") format("woff2");
}

/* Farben aus der Visitenkarte: Nachtblau, Creme, gedämpftes Gold */
:root {
  --nacht: #161d36;
  --nacht-hell: #1e2747;
  --creme: #efe5cc;
  --creme-leise: rgba(239, 229, 204, 0.62);
  --linie: rgba(239, 229, 204, 0.14);
  --gold: #d6ae5c;
  --schrift: "EB Garamond", Garamond, "Times New Roman", serif;
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  background: var(--nacht);
  /* Scrollleiste ausblenden (Scrollen geht weiter): so springt beim Wechsel
     zu langen Seiten nichts, und es bleibt kein leerer Streifen am Rand */
  scrollbar-width: none;
}

body {
  margin: 0;
  background: var(--nacht);
  color: var(--creme);
  font-family: var(--schrift);
  font-size: 1.2rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1 0 auto; width: 100%; }

html::-webkit-scrollbar { display: none; } /* ältere Safari-Versionen */

a { color: inherit; text-decoration-color: var(--gold); text-underline-offset: 0.2em; }
a:hover { color: var(--gold); }

/* ---------- Navigation ---------- */

.kopf {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 10;
  display: flex;
  justify-content: space-between; /* Icons stehen genau mittig zwischen Start und dem ersten Reiter */
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  padding: 1.75rem clamp(1rem, 5vw, 3.5rem);
  text-shadow: 0 0 6px rgba(22, 29, 54, 0.6), 0 1px 14px rgba(22, 29, 54, 0.8);
}

.kopf nav { display: flex; gap: clamp(1.1rem, 3vw, 2.25rem); }

/* YouTube & Instagram: feine Linien-Icons in Cremefarbe */
.sozial { display: flex; gap: 1.1rem; }

.sozial a {
  display: block;
  color: rgba(239, 229, 204, 0.6);
  transition: color 0.2s;
}

.sozial a:hover { color: var(--gold); }

.sozial svg {
  display: block;
  width: 1.55rem;
  height: 1.55rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.05; /* dünner, damit die Linie trotz größerem Icon gleich fein bleibt */
  filter: drop-shadow(0 0 6px rgba(22, 29, 54, 0.7));
}

.sozial .voll { fill: currentColor; stroke: none; }

.kopf .name,
.kopf nav a {
  font-size: 0.82rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  color: rgba(239, 229, 204, 0.8);
  position: relative;
  padding-bottom: 0.3rem;
  transition: color 0.2s;
}

.kopf .name:hover,
.kopf nav a:hover { color: var(--creme); }
.kopf .name[aria-current="page"],
.kopf nav a[aria-current="page"] { color: var(--creme); }

/* Goldlinie unter dem aktiven Reiter – gleiche Farbe und Stärke wie der Strich über dem Namen.
   Beim Seitenwechsel gleitet sie zum neuen Reiter (View Transitions). */
.kopf .name[aria-current="page"]::after,
.kopf nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0.2em; /* Buchstabenabstand nach dem letzten Zeichen ausgleichen */
  bottom: 0;
  height: 2px;
  background: var(--gold);
  view-transition-name: reiter-linie;
}

@view-transition { navigation: auto; }

::view-transition-group(reiter-linie) {
  animation-duration: 0.5s;
  animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1);
}

/* Zwischen den Unterseiten: Inhalt wechselt sofort, nur die Goldlinie gleitet.
   (Eine Überblendung des Inhalts hat beim Umschalten hell aufgeblitzt.) */
::view-transition-old(root),
::view-transition-new(root) { animation: none; mix-blend-mode: normal; }

/* Von und zur Startseite (ohne View Transition, siehe Skript im Seitenkopf):
   die echte Seite dunkelt ab, die neue hellt aus dem Dunkel auf. */
html.abdunkeln body {
  filter: brightness(0.12);
  transition: filter 0.4s ease-in;
}

html.aufhellen body { animation: 0.5s ease-out backwards seite-aufhellen; }

@keyframes seite-aufhellen { from { filter: brightness(0.12); } }

@media (prefers-reduced-motion: reduce) {
  html.abdunkeln body { transition: none; }
  html.aufhellen body { animation: none; }
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) { animation: none; }
}

/* ---------- Startseite ---------- */

.buehne {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  padding: 0 clamp(1rem, 5vw, 3.5rem) clamp(4rem, 14vh, 9rem);
  background:
    linear-gradient(180deg, rgba(22, 29, 54, 0.55) 0%, rgba(22, 29, 54, 0.15) 35%, rgba(22, 29, 54, 0.75) 100%),
    url("../bilder/gemaelde.jpg") center 30% / cover no-repeat;
}

/* nimmt dem Mondschein hinter dem Kopf den gelben Stich, Helligkeit bleibt */
.buehne::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: #3a4a8a;
  mix-blend-mode: color;
  opacity: 0.28;
  pointer-events: none;
}

.buehne-text { position: relative; z-index: 2; }

/* Impressum & Datenschutz auf der Startseite: klein unten rechts */
.buehne-recht {
  position: absolute;
  z-index: 2;
  right: clamp(1rem, 5vw, 3.5rem);
  bottom: 1.25rem;
  margin: 0;
  font-size: 0.85rem;
  color: rgba(239, 229, 204, 0.5);
  text-shadow: 0 1px 10px rgba(22, 29, 54, 0.8);
}

.buehne-recht a { text-decoration: none; }
.buehne-recht a:hover { color: var(--creme); }

/* dunkler Schleier oben, damit die Reiter über dem Foto lesbar bleiben */
.buehne::after {
  content: "";
  position: absolute;
  z-index: 1;
  top: 0; left: 0; right: 0;
  height: 11rem;
  background: linear-gradient(180deg, rgba(22, 29, 54, 0.75) 0%, rgba(22, 29, 54, 0) 100%);
  pointer-events: none;
}

/* Foto verschmilzt mit dem Gemälde: Ränder weich ausgeblendet, Farben vom Bild darunter */
.buehne-foto {
  position: absolute;
  z-index: 1;
  right: 0;
  bottom: 0;
  width: 64%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
  mix-blend-mode: luminosity;
  opacity: 0.85;
  -webkit-mask-image: radial-gradient(ellipse 55% 60% at 55% 45%, #000 35%, transparent 100%);
  mask-image: radial-gradient(ellipse 55% 60% at 55% 45%, #000 35%, transparent 100%);
}

.goldstrich {
  display: block;
  width: 2.75rem;
  height: 2px;
  background: var(--gold);
  margin-bottom: 1.4rem;
}

.buehne h1 {
  margin: 0;
  font-weight: 400;
  font-size: clamp(2.6rem, 7vw, 4.75rem);
  line-height: 1.05;
  letter-spacing: 0.005em;
}

.untertitel {
  margin: 0.6rem 0 0;
  font-size: clamp(0.95rem, 1.8vw, 1.15rem);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--creme-leise);
}

/* ---------- Unterseiten ---------- */

.seitenkopf {
  position: relative;
  padding: 9.5rem clamp(1rem, 5vw, 3.5rem) 3rem;
  background:
    linear-gradient(180deg, rgba(22, 29, 54, 0.6) 0%, rgba(22, 29, 54, 0.82) 70%, var(--nacht) 100%),
    url("../bilder/gemaelde.jpg") center 22% / cover no-repeat;
}

.seitenkopf h1 {
  margin: 0;
  font-weight: 400;
  font-size: clamp(2.1rem, 5vw, 3rem);
  line-height: 1.1;
}

.inhalt {
  max-width: 46rem;
  margin: 0 auto;
  padding: 2rem clamp(1rem, 5vw, 2rem) 6rem;
}

.inhalt.breit { max-width: 62rem; }

.inhalt p { margin: 0 0 1.1em; }

.leise { color: var(--creme-leise); }

/* ---------- Konzerte ---------- */

.abschnitt + .abschnitt { margin-top: 4.5rem; }

.abschnitt h2 {
  margin: 0 0 1.5rem;
  font-weight: 400;
  font-size: 0.85rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
}

.monat {
  margin: 2.25rem 0 0.4rem;
  font-weight: 400;
  font-size: 1rem;
  font-style: italic;
  color: var(--creme-leise);
}

.monat:first-of-type { margin-top: 0; }

.termine { list-style: none; margin: 0; padding: 0; }

.termine li {
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  gap: 1rem;
  padding: 0.6rem 0;
  border-top: 1px solid var(--linie);
}

.termine li:last-child { border-bottom: 1px solid var(--linie); }

.termine time {
  font-variant-numeric: tabular-nums lining-nums;
  color: var(--creme-leise);
  white-space: nowrap;
}

.vergangen .termine li { font-size: 1.05rem; }
.vergangen .termine li span { color: rgba(239, 229, 204, 0.82); }

/* ---------- Fotos ---------- */

.galerie {
  columns: 2 18rem;
  column-gap: 1.1rem;
}

.galerie button {
  display: block;
  width: 100%;
  margin: 0 0 1.25rem;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
  break-inside: avoid;
}

.galerie img {
  display: block;
  width: 100%;
  height: auto;
  opacity: 0.92;
  transition: opacity 0.3s;
}

.galerie button:hover img,
.galerie button:focus-visible img { opacity: 1; }

.lichtkasten {
  max-width: none;
  max-height: none;
  width: 100vw;
  height: 100vh;
  margin: 0;
  padding: clamp(1rem, 4vw, 3rem);
  border: 0;
  background: rgba(14, 19, 36, 0.96);
  cursor: zoom-out;
}

.lichtkasten[open] { display: flex; align-items: center; justify-content: center; }
.lichtkasten::backdrop { background: transparent; }

.lichtkasten img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* ---------- Kontakt & Impressum ---------- */

.kontakt p { margin: 0 0 0.3em; font-size: 1.35rem; }
.kontakt .leise {
  font-size: 0.85rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
}

.impressum h2 {
  margin: 2.25rem 0 0.5rem;
  font-weight: 400;
  font-size: 0.85rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
}

.impressum h2:first-child { margin-top: 0; }

/* ---------- Fuß ---------- */

.fuss {
  padding: 2.5rem clamp(1rem, 5vw, 3.5rem);
  border-top: 1px solid var(--linie);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  font-size: 1rem;
  color: var(--creme-leise);
}

.fuss a { text-decoration: none; }
.fuss a:hover { color: var(--creme); }

@media (max-width: 34rem) {
  .kopf nav { order: 3; width: 100%; }
  .seitenkopf { padding-top: 10.5rem; }
  .buehne::before { opacity: 0.42; } /* hier liegt mehr Mondschein im Bild */
  .buehne-foto {
    width: 100%;
    height: 72%;
    top: 4rem;
    bottom: auto;
    -webkit-mask-image: radial-gradient(ellipse 75% 55% at 50% 50%, #000 40%, transparent 100%);
    mask-image: radial-gradient(ellipse 75% 55% at 50% 50%, #000 40%, transparent 100%);
  }
  .termine li { grid-template-columns: 3.75rem 1fr; gap: 0.75rem; }
}
