/* =========================================================
   GRUNDEINSTELLUNGEN & FARB-/SCHRIFT-VARIABLEN
   ========================================================= */

:root {
  /* Farben */
  --color-bg: #FAFAF8;          /* Haupt-Hintergrund: warmes Weiß, nicht grell */
  --color-bg-alt: #FAFAF8;      /* Wechsel-Hintergrund für jeden 2. Abschnitt #F2F1EC */
  --color-text: #1C1C1A;        /* Haupttextfarbe, fast Schwarz */
  --color-heading: #253531;     /* Überschriften: dunkel, mit leichtem Petrolanteil */
  --color-text-muted: #6B6B65;  /* gedämpfter Text (Eyebrows, Footnotes) */
  --color-border: #E2E1DA;      /* dünne Trennlinien */
  --color-accent: #46564F;      /* ruhiger, grün-grauer Akzent für Links/Hover */

  /* Schriften */
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;

  /* Größen (Typografie-Skala, etwas gleichmäßiger abgestuft) */
  --size-h1: clamp(2.25rem, 5vw, 3.75rem);
  --size-h2: clamp(1.65rem, 3vw, 2.25rem);
  --size-h3: 1.3rem;
  --size-eyebrow: 0.75rem;
  --size-text: 1.05rem;
  --size-footnote: 0.85rem;

  /* Layout */
  --container-padding: 1.25rem;
  --container-max-width: 850px;
  --page-max-width: 1600px; /* ab dieser Breite wird die ganze Seite zentriert */
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-sans);
  font-size: var(--size-text);
  line-height: 1.65;
}

a {
  color: var(--color-accent);
}


/* Page-Wrapper: begrenzt die Gesamtbreite auf sehr großen Bildschirmen
   und zentriert die komplette Seite. Auf Tablet/Handy hat max-width
   keinen Effekt, da der Viewport ohnehin schmaler ist. */
.page {
  max-width: var(--page-max-width);
  margin-inline: auto;
}

/* Container: steuert den seitlichen Rand je nach Bildschirmgröße */
.container {
  width: 100%;
  padding-inline: var(--container-padding);
}

.eyebrow {
  font-family: var(--font-sans);
  font-size: var(--size-eyebrow);
  letter-spacing: 0.08em;
  text-transform: lowercase;
  color: var(--color-text-muted);
  margin: 0 0 0.75rem;
}

.text {
  font-family: var(--font-sans);
  font-size: var(--size-text);
  color: var(--color-text);
}

.subtitle {
  font-family: var(--font-sans);
  font-size: var(--size-text);
  color: var(--color-text-muted);
  margin: 0 0 2rem;
}

.footnote {
  font-family: var(--font-sans);
  font-size: var(--size-footnote);
  color: var(--color-text-muted);
}

.footnote a {
  color: var(--color-text-muted);
  text-decoration: none;
}

.footnote a:hover {
  color: var(--color-text);
}

h1, h2, h3, .nav-links a, .nav-top {
  text-transform: lowercase;
}

/* =========================================================
   NAVIGATION (sticky, oben)
   ========================================================= */

.site-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem var(--container-padding);
  background: var(--color-bg);
  font-family: var(--font-sans);
}

.site-nav .nav-top {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  text-decoration: none;
}

.site-nav .nav-top:hover {
  color: var(--color-text);
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.6rem;
}

.nav-links a {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--color-text);
}

.nav-sep {
  font-size: 0.8rem;
  color: var(--color-border);
}


/* =========================================================
   HERO
   Überschrift: --font-display, --size-h1, --color-text
   Unterschrift: --font-body, --size-text, --color-text-muted
   ========================================================= */

.hero {
  padding-block: 1rem 0rem;
  scroll-margin-top: 68px;
}

.hero h1 {
  font-family: var(--font-sans);
  font-size: var(--size-h1);
  font-weight: 500;
  color: var(--color-heading);
  margin: 0 0 1.25rem;
  line-height: 1.05;
}

.hero .subtitle {
  max-width: 78ch;
}

.hero .scroll-hint {
  font-size: 0.85rem;
  text-decoration: none;
  color: var(--color-accent);
}


/* =========================================================
   KUNST AM BAU
   Überschrift: --font-display, --size-h2
   Text (Eingabe/Fragmente): --font-body, kleiner, --color-text-muted
   Standardmäßig ausgeblendet (Mobile), ab Tablet sichtbar (siehe Media Queries)
   ========================================================= */

.kunst-am-bau {
  display: none;
  padding-block: 1rem 0rem;
  background: var(--color-bg-alt);
}

.kunst-am-bau .container::before {
  content: '';
  display: block;
  border-top: 1px solid var(--color-border);
margin: 0 0 1rem;
}

.kunst-am-bau h2 {
  font-family: var(--font-sans);
  font-size: var(--size-h2);
  font-weight: 500;
  color: var(--color-heading);
  margin: 0 0 1.5rem;
}

.kunst-am-bau .subtitle {
  margin-bottom: 1rem;
}

.memory-form {
  display: flex;
  gap: 0.5rem;
  max-width: 420px;
  margin-bottom: 2rem;
}

.memory-form input {
  flex: 1;
  padding: 0.7rem 0.9rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  border: 1px solid var(--color-text-muted);
  border-radius: 6px;
  background: var(--color-bg);
  color: var(--color-text);
}

.memory-form input:focus {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.memory-form button {
  padding: 0.7rem 1.1rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  border: 1px solid var(--color-text-muted);
  border-radius: 6px;
  background: var(--color-bg);
  color: var(--color-text);
  cursor: pointer;
}

.memory-form button:hover {
  background: var(--color-text);
  border-color: var(--color-accent);
  color: var(--color-bg);
}

.memory-error {
  min-height: 1.2rem;
  font-size: var(--size-footnote);
  color: #a1594a;
  margin: -1.5rem 0 1.5rem;
}

/* Fläche, in der die Wortschnipsel nach unten sinken */
.memory-field {
  position: relative;
  height: 260px;
  overflow: hidden;
}

.memory-fragment {
  position: absolute;
  top: -1.5rem;
  font-family: var(--font-sans);
  font-style: italic;
  color: var(--color-text);
  opacity: 0.9;
  white-space: nowrap;
  transition: transform 6s linear, opacity 4s ease, filter 4s ease;
  filter: blur(0px);
}

.memory-fragment .letter {
  display: inline-block;
  min-width: 0.35em; /* verhindert leichtes "Springen" der Wortbreite beim Vertauschen */
}

/* =========================================================
   MUSIK
   Überschrift: --font-display, --size-h2
   ========================================================= */

.musik {
  padding-block: 3rem 0rem;
}

.musik h2 {
  font-family: var(--font-sans);
  font-size: var(--size-h2);
  font-weight: 500;
  color: var(--color-heading);
  margin: 0 0 1.5rem;
}

.musik .subtitle {
  margin-top: 1.5rem;
}

.player-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.player {
  width: 100%;
  height: 166px;
  border: none;
}


/* =========================================================
   ABOUT
   Überschrift: --font-display, --size-h2
   Text: --font-body, --size-text, --color-text
   ========================================================= */

.about {
  padding-block: 2rem;
  background: var(--color-bg-alt);
}

.about .container::before {
  content: '';
  display: block;
  border-top: 1px solid var(--color-border);
  margin: 0rem 0;
}

.about h2 {
  font-family: var(--font-sans);
  font-size: var(--size-h2);
  font-weight: 500;
  color: var(--color-heading);
  margin: 0 0 1.25rem;
}

.about .text {
  max-width: 68ch;
}

.about-photo {
  float: right;
  width: 300px;
  height: auto;
  margin: 0.5rem 0 1rem 2rem;
}

.about .player-list {
  clear: both;
  padding: 1.5rem 0;
}

@media (max-width: 640px) {
  .about-photo {
    float: none;
    display: block;
    width: 100%;
    max-width: 280px;
    margin: 0 0 1.25rem;
  }
}


/* =========================================================
   PROJEKTE (Galerie zum Durchklicken)
   Überschrift: --font-display, --size-h2
   Kartentitel: --font-display, --size-h3
   ========================================================= */

.projekte {
  padding-block: 2rem 1rem;
}

.projekte h2 {
  font-family: var(--font-sans);
  font-size: var(--size-h2);
  font-weight: 500;
  color: var(--color-heading);
  margin: 0 0 1.5rem;
}

.gallery {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding-inline: var(--container-padding);
}

.gallery-track {
  display: flex;
  gap: 1.5rem;
  overflow-x: hidden;
  scroll-behavior: smooth;
  flex: 1;
}

.gallery-item {
  flex: 0 0 100%;
  max-width: 320px;
}

.gallery-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  margin-bottom: 1rem;
}

.gallery-link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.gallery-link:hover .gallery-image {
  opacity: 0.85;
}

.gallery-item h3 {
  font-family: var(--font-sans);
  font-size: var(--size-h3);
  font-weight: 500;
  color: var(--color-heading);
  margin: 0 0 0.4rem;
}

.gallery-item p {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: var(--color-text-muted);
  margin: 0;
}

.gallery-arrow {
  flex: 0 0 auto;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  border: 1px solid var(--color-border);
  background: var(--color-bg);
  cursor: pointer;
  font-size: 1rem;
}

.gallery-arrow:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}


/* =========================================================
   KONTAKT
   ========================================================= */

.kontakt {
  padding-block: 2rem 1rem;
}

.kontakt .container::before {
  content: '';
  display: block;
  border-top: 1px solid var(--color-border);
  margin: 0rem 0;
}

.kontakt .text {
  margin: 0 0 0.75rem;
}

.kontakt a {
  text-decoration: none;
}

.kontakt a:hover {
  color: var(--color-accent);
}

.subscribe-form {
  display: flex;
  gap: 0.4rem;
  max-width: 320px;
  margin: 1.5rem 0 0.5rem;
}

.subscribe-form input {
  flex: 1;
  padding: 0.45rem 0.7rem;
  font-family: var(--font-sans);
  font-size: var(--size-footnote);
  border: 1px solid var(--color-text-muted);
  border-radius: 6px;
  background: var(--color-bg);
  color: var(--color-text);
}

.subscribe-form input:focus {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.subscribe-form button {
  padding: 0.45rem 0.8rem;
  font-family: var(--font-sans);
  font-size: var(--size-footnote);
  border: 1px solid var(--color-text-muted);
  border-radius: 6px;
  background: var(--color-bg);
  color: var(--color-text);
  cursor: pointer;
}

.subscribe-form button:hover {
  background: var(--color-text);
  border-color: var(--color-accent);
  color: var(--color-bg);
}

.subscribe-message {
  min-height: 1.2rem;
  font-size: var(--size-footnote);
  color: var(--color-text-muted);
}

/* =========================================================
   RESPONSIVE VERHALTEN
   Mobile   (< 768px):  kein seitlicher Rand, ohne "Kunst am Bau"
   Tablet   (>= 768px): kein seitlicher Rand, mit "Kunst am Bau"
   Desktop  (>= 1200px): mit seitlichem Rand (zentrierter Container)
   ========================================================= */

/* Tablet: Kunst-am-Bau-Abschnitt einblenden */
@media (min-width: 700px) {
  .kunst-am-bau {
    display: block;
  }
  .nav-hide-mobile {
    display: inline;
  }
}

/* Mobile: Nav-Link zu Kunst am Bau ausblenden, da Abschnitt fehlt */
@media (max-width: 699px) {
  .nav-hide-mobile {
    display: none;
  }
}

/* Desktop / Widescreen: seitlicher Rand über zentrierten Container */
@media (min-width: 1200px) {
  .container,
  .site-nav  {
    max-width: var(--container-max-width);
    margin-inline: auto;
    padding-inline: 2rem;
  }
  .gallery {
    max-width: calc(var(--container-max-width) + 2 * 2rem);
    margin-inline: auto;
    padding-inline: 2rem;
  }
}
