/* ==========================================================================
   conlicenza – Blechbläserensemble
   Stil: modern-minimalistisch, hell, Messing-Akzent
   ========================================================================== */

/* ==========================================================================
   WICHTIG nach Änderungen an dieser Datei oder an js/main.js:
   In index.html UND impressum.html die Versionsnummer erhöhen
   (z. B. style.css?v=2 → style.css?v=3), damit Browser die neue Datei laden.
   ========================================================================== */

/* ---------- Design-Tokens ---------- */
:root {
  --bg:        #FAFAF7;   /* warmes Weiß */
  --bg-alt:    #F2EDE3;   /* heller Sand */
  --surface:   #FFFFFF;
  --text:      #1E1E1E;   /* Anthrazit */
  --muted:     #5E5A52;
  --line:      #E3DCCD;
  --brass:     #B08D3C;   /* Messing – Flächen, Linien */
  --brass-ink: #8A6A22;   /* dunkleres Messing – Text/Links (kontraststark) */
  --brass-soft:#EFE4CB;

  /* Systemschriften: DSGVO-freundlich, keine externen Dienste.
     Eigene Webfonts (z. B. Fraunces / Inter) können lokal in /fonts ergänzt werden. */
  --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --font-sans:  -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --container: 1140px;
  --narrow:    760px;
  --gutter:    clamp(1rem, 4vw, 2rem);
  --radius:    14px;
  --header-h:  72px;
  --shadow:    0 1px 2px rgba(30,30,30,.04), 0 8px 24px rgba(30,30,30,.06);
  --ease:      cubic-bezier(.2,.7,.2,1);
}

/* ---------- Reset & Basis ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 8px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: clamp(1rem, .96rem + .2vw, 1.0625rem);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--brass-ink); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { color: var(--text); }
:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--font-serif); font-weight: 500; line-height: 1.15; letter-spacing: -.01em; margin: 0 0 .6em; }
h1 { font-size: clamp(2.1rem, 1.2rem + 4.5vw, 4.6rem); overflow-wrap: break-word; }
h2 { font-size: clamp(1.9rem, 1.4rem + 2vw, 2.8rem); }
h3 { font-size: 1.35rem; }
p { margin: 0 0 1.1em; }
.nowrap { white-space: nowrap; }

.skip-link {
  position: absolute; left: 1rem; top: -100px; z-index: 100;
  background: var(--text); color: #fff; padding: .6rem 1rem; border-radius: 8px;
}
.skip-link:focus { top: 1rem; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: var(--narrow); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  padding: .85em 1.6em;
  background: var(--text); color: #fff;
  border: 1px solid var(--text); border-radius: 999px;
  font: 600 .95rem/1 var(--font-sans); letter-spacing: .02em;
  text-decoration: none; cursor: pointer;
  transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease);
}
.btn:hover { background: var(--brass-ink); border-color: var(--brass-ink); color: #fff; transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn-ghost:hover { background: var(--surface); color: var(--text); border-color: var(--brass); }
.btn-small { padding: .6em 1.15em; font-size: .875rem; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto; z-index: 50; height: var(--header-h);
  background: rgba(250,250,247,.0);
  transition: background .3s var(--ease), box-shadow .3s var(--ease);
}
.site-header.is-solid {
  background: rgba(250,250,247,.92);
  -webkit-backdrop-filter: saturate(1.4) blur(12px); backdrop-filter: saturate(1.4) blur(12px);
  box-shadow: 0 1px 0 var(--line);
}
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: flex; flex-direction: column; line-height: 1.1; text-decoration: none; color: var(--text); }
.brand-name { font-family: var(--font-serif); font-size: 1.5rem; letter-spacing: .01em; }
.brand-sub { font-size: .7rem; letter-spacing: .18em; text-transform: uppercase; color: var(--brass-ink); }

.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: clamp(1rem, 2vw, 2rem); }
.site-nav a:not(.btn) {
  color: var(--text); text-decoration: none; font-size: .95rem; position: relative; padding: .3em 0;
}
.site-nav a:not(.btn)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: var(--brass); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.site-nav a:not(.btn):hover::after, .site-nav a.is-active::after { transform: scaleX(1); }

.nav-toggle {
  display: none; width: 44px; height: 44px; padding: 10px; border: 0; background: none; cursor: pointer;
  flex-direction: column; justify-content: center; gap: 6px;
}
.nav-toggle span { display: block; height: 1.5px; background: var(--text); border-radius: 2px; transition: transform .3s var(--ease), opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

.back-link { font-size: .95rem; text-decoration: none; color: var(--text); }

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .site-nav {
    position: fixed; inset: var(--header-h) 0 auto; background: var(--bg);
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    max-height: 0; overflow: hidden; transition: max-height .4s var(--ease);
  }
  .site-nav.is-open { max-height: 80vh; }
  .site-nav ul { flex-direction: column; align-items: stretch; gap: 0; padding: .5rem var(--gutter) 1.5rem; }
  .site-nav li a:not(.btn) { display: block; padding: .9rem 0; border-bottom: 1px solid var(--line); font-size: 1.05rem; }
  .site-nav a:not(.btn)::after { display: none; }
  .site-nav .btn { margin-top: 1.25rem; width: 100%; padding: 1em; }
  .site-header:has(.site-nav.is-open) { background: var(--bg); }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  min-height: min(52vh, 520px);
  display: flex; align-items: center;
  padding: calc(var(--header-h) + 2.5rem) 0 3rem;
  background:
    radial-gradient(1200px 600px at 85% 20%, var(--brass-soft) 0%, transparent 60%),
    var(--bg);
}
.hero-inner { position: relative; z-index: 2; }
/* Titel: Schriftgröße wächst mit der Bildschirmbreite, damit
   „Blechbläserensemble“ auch auf dem Handy ungetrennt in eine Zeile passt */
.hero h1 { max-width: none; margin-bottom: 0; font-size: clamp(1.5rem, 8vw, 4.6rem); hyphens: manual; overflow-wrap: normal; }

.hero-media {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  /* Ensemblefoto aktivieren (Datei: img/hero.jpg):
  background: linear-gradient(90deg, var(--bg) 35%, rgba(250,250,247,.55) 65%, rgba(250,250,247,.2)), url("../img/hero.jpg") center / cover no-repeat;
  */
}
.hero-ornament {
  position: absolute; right: -8%; top: 50%; width: min(70vw, 720px); transform: translateY(-50%);
  color: var(--brass); opacity: .28;
}
.hero-ornament circle { stroke-dasharray: 2 6; animation: spin 120s linear infinite; transform-origin: 300px 300px; }
.hero-ornament circle:nth-child(2n) { animation-direction: reverse; stroke-dasharray: none; }
@keyframes spin { to { transform: rotate(360deg); } }

.eyebrow {
  display: inline-flex; align-items: center; gap: .75em;
  font-size: .78rem; letter-spacing: .2em; text-transform: uppercase; color: var(--brass-ink); font-weight: 600;
  margin-bottom: 1.2rem;
}
.eyebrow::before { content: ""; width: 2.25rem; height: 1px; background: var(--brass); }

/* ---------- Sektionen ---------- */
.section { padding: clamp(4.5rem, 3rem + 6vw, 8rem) 0; }
.section-alt { background: var(--bg-alt); }
.section-head { margin-bottom: clamp(2rem, 1.5rem + 2vw, 3.5rem); }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 60ch; }
.prose { max-width: 62ch; }
.prose p:first-child::first-letter {
  font-family: var(--font-serif); float: left; font-size: 3.4em; line-height: .9; padding: .06em .12em 0 0; color: var(--brass-ink);
}

.grid-2 { display: grid; gap: clamp(2.5rem, 2rem + 3vw, 5rem); grid-template-columns: 1.15fr 1fr; align-items: start; }
@media (max-width: 860px) { .grid-2 { grid-template-columns: 1fr; } }

/* Bild-Platzhalter */
.img-ph {
  position: relative; width: 100%; border-radius: var(--radius);
  background:
    repeating-linear-gradient(135deg, transparent 0 14px, rgba(176,141,60,.08) 14px 15px),
    var(--bg-alt);
  border: 1px solid var(--line);
  display: grid; place-items: center; color: var(--brass-ink);
  font-size: .8rem; letter-spacing: .16em; text-transform: uppercase;
}
.ratio-4-3 { aspect-ratio: 4 / 3; }

/* Fotos */
.photo { margin: 0; }
.photo img {
  width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover;
  border-radius: var(--radius); background: var(--bg-alt); box-shadow: var(--shadow);
}
.photo figcaption { margin-top: .6rem; font-size: .75rem; color: var(--muted); text-align: right; }

/* Großes Ensemblefoto über dem Text */
.photo-wide { margin-bottom: clamp(2.5rem, 2rem + 3vw, 4.5rem); }
.photo-wide img { aspect-ratio: 16 / 9; object-position: 50% 62%; border-radius: calc(var(--radius) + 6px); }
@media (max-width: 600px) {
  .photo-wide { margin-inline: calc(var(--gutter) * -1); }
  .photo-wide img { aspect-ratio: 3 / 2; border-radius: 0; box-shadow: none; }
  .photo-wide figcaption { padding-inline: var(--gutter); }
}
.about { max-width: calc(var(--narrow) + 2 * var(--gutter)); }

/* Kontakt */
.contact-mail { margin-top: 2rem; display: flex; flex-direction: column; gap: .2rem; }
.contact-mail .label { font-size: .75rem; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.contact-mail a { font-family: var(--font-serif); font-size: clamp(1.3rem, 1.1rem + .8vw, 1.7rem); text-decoration: none; color: var(--text); border-bottom: 1px solid var(--brass); align-self: flex-start; }
.contact-mail a:hover { color: var(--brass-ink); }

.form { background: var(--surface); border: 1px solid var(--line); border-radius: calc(var(--radius) + 4px); padding: clamp(1.5rem, 1rem + 2vw, 2.5rem); box-shadow: var(--shadow); }
.field { display: flex; flex-direction: column; gap: .35rem; margin-bottom: 1.1rem; }
@media (max-width: 520px) { .field label { font-size: .85rem; font-weight: 600; }
.field label span { color: var(--brass-ink); }
.field input, .field textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 10px; padding: .8em .95em;
  transition: border-color .2s, box-shadow .2s, background .2s;
}
.field textarea { resize: vertical; min-height: 8rem; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--brass); background: #fff; box-shadow: 0 0 0 4px rgba(176,141,60,.15); }
.field .is-invalid, .field input.is-invalid, .field textarea.is-invalid { border-color: #B3261E; }
.check { display: flex; gap: .7rem; align-items: flex-start; font-size: .85rem; color: var(--muted); margin: .3rem 0 1.4rem; line-height: 1.5; cursor: pointer; }
.check input { margin-top: .2rem; width: 1.1rem; height: 1.1rem; accent-color: var(--brass-ink); flex-shrink: 0; }
.check.is-invalid span { color: #B3261E; }
.form-status { margin: 1rem 0 0; font-size: .9rem; min-height: 1.4em; }
.form-status.ok { color: #2E6B3A; }
.form-status.err { color: #B3261E; }

/* ---------- Footer ---------- */
.site-footer { background: var(--text); color: #D9D4C9; padding: 3rem 0; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem 2rem; }
.footer-inner > div { display: flex; flex-direction: column; line-height: 1.2; }
.site-footer .brand-name { color: #fff; }
.site-footer .brand-sub { color: var(--brass); }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 1.5rem; }
.site-footer a { color: #D9D4C9; text-decoration: none; font-size: .92rem; }
.site-footer a:hover { color: #fff; }
.copy { margin: 0; font-size: .82rem; color: #9A9488; width: 100%; }

/* ---------- Rechtliche Seite ---------- */
.legal-page main { padding-top: calc(var(--header-h) + 3rem); }
.legal h1 { font-size: clamp(2.2rem, 1.6rem + 2.5vw, 3.2rem); }
.legal h2 { font-size: 1.6rem; margin-top: 2.6rem; }
.legal h3, .legal h4 { font-family: var(--font-sans); font-size: 1.05rem; font-weight: 600; margin-top: 1.8rem; }
.legal #datenschutz { margin-top: 4rem; padding-top: 2.5rem; border-top: 1px solid var(--line); font-size: clamp(1.9rem, 1.5rem + 1.5vw, 2.6rem); }
.legal p, .legal li { color: #3A3731; overflow-wrap: anywhere; }
.legal ul { padding-left: 1.2rem; }
.legal h2:not(#datenschutz) { font-size: 1.45rem; }
.legal mark { background: var(--brass-soft); color: var(--brass-ink); padding: .05em .35em; border-radius: 4px; }

/* ---------- Scroll-Animationen ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------- Druck ---------- */
@media print {
  .site-header, .hero-media, .nav-toggle, .form,   .hero { min-height: auto; padding-top: 1rem; }
  .js .reveal { opacity: 1; transform: none; }
}
