/* Standortspezifisches Design "Lindenhofpark" (Förderverein Gartendenkmal Lindenhofpark, Lindau).
   Nur für die Site-Kennung gartendenkmal-lindenhofpark eingebunden (Configuration/Sets/IpySite/setup.typoscript),
   Template Pages/Lindenhof.fluid.html. Maße und Farben aus den berechneten Stilen der alten Live-Seite
   (gartendenkmal-lindenhofpark.de, Viewport 1440 px) übernommen, siehe docs/PROTOKOLL_CODEX.md.

   Content-Layouts (tt_content.layout) dieser Site:
     0/10  Fließtext (Überschrift + Text), 10 nur historisch für die Startseite
     71    Bildreihe (ein oder mehrere Bilder nebeneinander, natürliche Größe, Bildunterschrift darunter)
     70    Galerie-Raster, 4 Spalten
     75    Bild(er) links (schmal) + Text rechts
     76    Textspalte schmal (590 px, wie die alte 8er-Spalte ohne Randspalte)
     82    Station (Rundgang, Text + Foto) in der aktuellen Spalte
     83    Station, beginnt eine neue Spalte
     90    Karte (Google-Maps-Einbettung, Koordinaten im Feld Untertitel) */

html:has(.lh-page) { background: #c3c87f }
body:has(.lh-page) { background: transparent; font-synthesis: weight style }

.lh-page {
  max-width: 1220px; margin: 0 auto; min-height: 100vh; background: #fff;
  color: #4d4037; font: 400 16px/24px 'Sorts Mill Goudy', Georgia, 'Times New Roman', serif; letter-spacing: .04em;
  font-synthesis: weight style; -webkit-font-smoothing: antialiased;
}
.lh-page a { color: #000; text-decoration: none }
.lh-page a:hover { text-decoration: underline }

/* Kopf: Logo mittig, danach das je Seite wechselnde Kopfbild zwischen zwei hellen Linien */
.lh-logoheader { height: 129.25px; padding: 5px 0; text-align: center; background: #fff }
.lh-logo { display: block; width: 300px; margin: 0 auto }
.lh-logo img { display: block; width: 300px; height: auto }
.lh-logo:hover { text-decoration: none }
.lh-banner { padding: 5px 0; border-top: 1px solid #c3c87f; border-bottom: 1px solid #c3c87f; margin-bottom: 50px }
.lh-banner img { display: block; width: 100%; height: auto }

/* Rahmen: links Navigation (absolut, wie im Original), rechts der Inhalt */
.lh-frame { position: relative; padding: 11.2px 28px 48px 223px }
.lh-nav { position: absolute; left: 18px; top: 20px; width: 192px }
.lh-nav .site-nav-group { display: block; padding: 0; gap: 0 }
.lh-nav a { display: block; margin: 1px; padding: 2px 17px; font-size: 17.6px; line-height: 26.4px; font-weight: 400; color: #999; text-decoration: none; text-align: left }
.lh-nav a:hover { color: #74831c; text-decoration: none }
.lh-nav a.is-active { color: #74831c; font-weight: 700 }
.lh-nav .site-submenu { display: none }

/* Inhalt: Hauptspalte 590 px + Randspalte 312 px, ohne Randspalte volle Breite (969 px) */
.lh-page main#content { padding: 0; margin: 0; display: block; font: inherit; color: inherit; background: transparent; letter-spacing: inherit }
.lh-page main#content:has(.lh-side > *) { display: grid; grid-template-columns: minmax(0, 590px) minmax(0, 312px); column-gap: 67px; align-items: start }
.lh-side:not(:has(*)) { display: none }

.lh-page .frame { max-width: none; margin: 0; padding: 0; line-height: 24px; color: inherit; font-family: inherit }
.lh-page .frame p { max-width: none; margin: 0 0 24px; color: inherit }
.lh-page .frame a { font-weight: 400; text-underline-offset: auto }
.lh-page .frame strong, .lh-page .frame b { font-weight: 700 }
.lh-page .frame > header { margin: 0 }
.lh-page .frame h1, .lh-page .frame h2, .lh-page .frame h3, .lh-page .frame h4 { font-family: inherit; letter-spacing: inherit; color: #74831c; margin: 0 0 19.92px }
.lh-page .frame h1 { font-size: 32px; line-height: 48px; font-weight: 600; margin-bottom: 0 }
.lh-page .frame h2 { font-size: 24px; line-height: 36px; font-weight: 700 }
.lh-page .frame h3 { font-size: 18.72px; line-height: 28px; font-weight: 700 }
.lh-page .frame h4 { font-size: 17.6px; line-height: 26.4px; font-weight: 700 }
/* Randspalten-Überschrift bricht wie im Original nach dem Bindestrich ("Besucher-" / "informationen:") */
.lh-side .frame h2 { max-width: 9.5em }
.lh-page .frame ul, .lh-page .frame ol { margin: 0 0 16px; padding: 0 0 0 40px }
.lh-page .frame li { margin: 0 }
.lh-page .frame ul li { margin-bottom: 24px }
.lh-page .frame ul li:last-child { margin-bottom: 0 }
.lh-page [data-ipy-edit-body] { margin: 0 }
.lh-page [data-ipy-edit-body] > :last-child { margin-bottom: 0 }
.lh-page .ipy-cc-anchor { margin: 0 0 24px }

/* Tabelle (Vorstand): zwei Spalten, keine Rahmen außer feiner Fußlinie */
.lh-page table { border-collapse: collapse; width: 100%; margin: 0 0 24px }
.lh-page th, .lh-page td { text-align: left; padding: 4px 0; vertical-align: top; border-bottom: 1px solid #fdfdfd }
.lh-page th { font-weight: 700 }
.lh-page td:first-child { width: 30% }

/* PDF-Links in der Randspalte (Förderverein: Aufnahmeantrag) mit kleinem PDF-Symbol wie im Original */
.lh-side a[href$=".pdf"]::before { content: 'PDF'; display: inline-block; margin-right: .5em; padding: 0 .35em; font-size: 11px; line-height: 16px; letter-spacing: 0; color: #fff; background: #b3261e; vertical-align: 1px }

/* Bilder allgemein */
.lh-page .ipy-hero-image { margin: 0; max-width: none; border-radius: 0; box-shadow: none; overflow: visible }
.lh-page .ipy-hero-image img { display: block; max-width: 100%; height: auto; border-radius: 0; box-shadow: none }
.lh-page .ipy-hero-image-caption { display: block; margin: 0; font-size: 16px; line-height: 24px; color: #4d4037; text-align: left; white-space: pre-line }
.lh-page .ipy-cc-anchor:has(.frame-layout-71, .frame-layout-70, .frame-layout-75, .frame-layout-82, .frame-layout-83) .ipy-hero-image { cursor: zoom-in }

/* 71: Bildreihe – natürliche Größe, mittig, Reihe bricht bei Platzmangel um */
.lh-page .frame-layout-71 { display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-start; gap: 24px }
.lh-page .frame-layout-71 > header { flex: 0 0 100% }
.lh-page .frame-layout-71 [data-ipy-edit-body]:empty { display: none }
.lh-page .frame-layout-71 .ipy-hero-image { flex: 0 1 auto; min-width: 0 }
.lh-page .frame-layout-71 .ipy-hero-image-caption { margin-top: 0 }

/* 70: Galerie-Raster (Impressionen) */
.lh-page .frame-layout-70 { max-width: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px 16.5px; align-items: start; margin-top: 42px }
.lh-page .frame-layout-70 > header, .lh-page .frame-layout-70 [data-ipy-edit-body] { grid-column: 1 / -1 }
.lh-page .frame-layout-70 [data-ipy-edit-body]:empty, .lh-page .frame-layout-70 > header:empty { display: none }
.lh-page .frame-layout-70 .ipy-hero-image { flex: none; margin: 0 0 24px; border-radius: 0; box-shadow: none }
.lh-page .frame-layout-70 .ipy-hero-image img { width: 100%; height: auto; aspect-ratio: auto; object-fit: initial }
.lh-page .frame-layout-70 .ipy-hero-image:hover { opacity: 1 }

/* 75: schmale Bildspalte links (312 px), Text rechts (640 px) */
.lh-page .frame-layout-75 { display: grid; grid-template-columns: 312px minmax(0, 640px); column-gap: 17px; align-items: start }
.lh-page .frame-layout-75 > header { grid-column: 2; grid-row: 1 }
.lh-page .frame-layout-75 [data-ipy-edit-body] { grid-column: 2; grid-row: 1 / span 2 }
.lh-page .frame-layout-75 .ipy-hero-image { grid-column: 1 }
.lh-page .frame-layout-75 .ipy-hero-image img { width: 100%; height: auto }

/* 76: schmale Textspalte */
.lh-page .frame-layout-76 { max-width: 590px }

/* 82/83: Rundgang-Stationen – drei Spalten, Kopfblock und Plan über die volle Breite */
.lh-page .lh-main:has(.frame-layout-82, .frame-layout-83) { column-count: 3; column-gap: 16.5px }
.lh-page .lh-main:has(.frame-layout-82, .frame-layout-83) > .ipy-cc-anchor:not(:has(.frame-layout-82, .frame-layout-83)) { column-span: all }
.lh-page .lh-main > .ipy-cc-anchor:has(> .frame-layout-83) { break-before: column }
.lh-page .lh-main > .ipy-cc-anchor:has(> .frame-layout-82, > .frame-layout-83) { break-inside: avoid; margin-bottom: 24px }
.lh-page .frame-layout-82 p, .lh-page .frame-layout-83 p { margin: 0 }
.lh-page .frame-layout-82 [data-ipy-edit-body], .lh-page .frame-layout-83 [data-ipy-edit-body] { margin-bottom: 4px }
.lh-page .frame-layout-82 .ipy-hero-image, .lh-page .frame-layout-83 .ipy-hero-image { margin-top: 20px }

/* 90: Karte – der Untertitel (Koordinaten) ist nur Datenfeld und wird nicht angezeigt */
.lh-page .frame-layout-90 > header p { display: none }
.lh-page .ipy-map { width: 100%; height: 500px; margin: 0 0 24px }
.lh-page .ipy-map-frame { display: block; width: 100%; height: 100%; border: 0 }

/* Fuß: nur der unauffällige Redaktions-Zugang */
.lh-footer { padding: 0 28px 16px 223px; text-align: right; font-size: 12px; line-height: 18px }
.lh-footer a { color: #b5b98a }

/* Bearbeiten-Knöpfe der Redaktion sollen das Layout nicht sprengen */
.lh-page .ipy-cc-actions { justify-content: flex-start; padding: .25rem 0 }
.lh-page .lh-main:has(.frame-layout-82, .frame-layout-83) .ipy-cc-actions { flex-wrap: wrap }

/* Mobiles Menü: Burger-Knopf (wird beim Öffnen zum X) + Schublade von rechts. Nur mit JavaScript
   (lindenhof-nav.js setzt .lh-js); ohne JS bleibt die Navigation als einfache Liste über dem Inhalt. */
.lh-burger, .lh-nav-backdrop { display: none }
.lh-burger { position: fixed; top: 10px; right: 10px; z-index: 130; width: 48px; height: 48px; padding: 0; background: #fff; border: 1px solid #c3c87f; border-radius: 4px; cursor: pointer; color: #74831c }
.lh-burger:focus-visible { outline: 3px solid #74831c; outline-offset: 2px }
.lh-burger-bars { position: relative; display: block; width: 24px; height: 18px; margin: 0 auto }
.lh-burger-bars span { position: absolute; left: 0; width: 24px; height: 2px; background: currentColor; border-radius: 1px; transition: transform .25s ease, opacity .2s ease, top .25s ease }
.lh-burger-bars span:nth-child(1) { top: 0 }
.lh-burger-bars span:nth-child(2) { top: 8px }
.lh-burger-bars span:nth-child(3) { top: 16px }
.lh-burger[aria-expanded="true"] .lh-burger-bars span:nth-child(1) { top: 8px; transform: rotate(45deg) }
.lh-burger[aria-expanded="true"] .lh-burger-bars span:nth-child(2) { opacity: 0 }
.lh-burger[aria-expanded="true"] .lh-burger-bars span:nth-child(3) { top: 8px; transform: rotate(-45deg) }
html.lh-nav-lock { overflow: hidden }

@media (max-width: 900px) {
  .lh-page.lh-js .lh-burger { display: block }
  .lh-page.lh-js .lh-nav-backdrop:not([hidden]) { display: block; position: fixed; inset: 0; z-index: 110; background: rgba(40, 45, 20, .45) }
  .lh-page.lh-js .lh-nav {
    position: fixed; top: 0; right: 0; bottom: 0; left: auto; z-index: 120; width: min(320px, 86vw); margin: 0; padding: 72px 12px 24px;
    background: #fff; border-left: 1px solid #c3c87f; box-shadow: -10px 0 30px rgba(0, 0, 0, .18); overflow-y: auto; overscroll-behavior: contain;
    transform: translateX(100%); visibility: hidden; transition: transform .28s ease, visibility 0s linear .28s;
  }
  .lh-page.lh-js.lh-nav-open .lh-nav { transform: none; visibility: visible; transition: transform .28s ease, visibility 0s }
  .lh-page.lh-js .lh-nav a { display: block; margin: 0; padding: 10px 17px; font-size: 20px; line-height: 28px }
  .lh-page.lh-js .lh-frame { padding-top: 11.2px }
}
@media (prefers-reduced-motion: reduce) {
  .lh-burger-bars span, .lh-page.lh-js .lh-nav { transition: none !important }
}

@media (max-width: 900px) {
  .lh-logoheader { height: auto }
  .lh-logo, .lh-logo img { width: min(300px, 70vw) }
  .lh-frame { padding: 0 16px 32px }
  .lh-nav { position: static; width: auto; margin: 0 0 24px }
  .lh-nav a { display: inline-block; margin: 0 4px 0 0 }
  .lh-page main#content:has(.lh-side > *) { display: block }
  .lh-page .lh-main:has(.frame-layout-82, .frame-layout-83) { column-count: 1 }
  .lh-page .frame-layout-70 { grid-template-columns: repeat(2, minmax(0, 1fr)) }
  .lh-page .frame-layout-75 { display: block }
  .lh-footer { padding-left: 16px }
}
