{{ define "main" }} {{ partial "page-title.html" . }} {{/* ==== BILDER SAMMELN (Front-Matter oder Auto-Discovery) ==== */}} {{ $photos := .Params.images }} {{ if not $photos }} {{ $slug := .Params.slug | default .File.TranslationBaseName }} {{ $cands := slice (printf "static/images/leistungen/%s1.webp" $slug) (printf "static/images/leistungen/%s2.webp" $slug) }} {{ $auto := slice }} {{ range $cands }} {{ if fileExists . }} {{ $auto = $auto | append (dict "src" (replace . "static" "") "alt" $slug ) }} {{ end }} {{ end }} {{ $photos = $auto }} {{ end }} {{/* Erstes Bild für Hero, zweites fürs Ergebnis vormerken */}} {{ $heroPhoto := cond (gt (len $photos) 0) (index $photos 0) nil }} {{ $ergebnisPhoto := cond (gt (len $photos) 1) (index $photos 1) nil }} {{ $.Scratch.Set "ergebnisPhoto" $ergebnisPhoto }}
{{ with $heroPhoto }}
{{ .alt | default $.Title }}
{{ end }}
{{ if .Content }}
{{ .Content }}
{{ end }}
{{ with .Params.usp }}
{{ range $i, $u := . }}

{{ $u | markdownify }}

{{ end }}
{{ end }}
{{ with .Params.features }}
{{/* Store the features list and count */}} {{ $features := . }} {{ $totalFeatures := len $features }}
{{ end }} {{ with .Params.outcomes }}

Ergebnis & Mehrwert

    {{ range . }}
  • {{ . | markdownify }}
  • {{ end }}
{{ $erg := $.Scratch.Get "ergebnisPhoto" }} {{ with $erg }}
{{ .alt | default $.Title }}
{{ else }} {{ with $heroPhoto }}
{{ .alt | default $.Title }}
{{ end }} {{ end }}
{{ end }} {{ $impressum := site.GetPage "page" "impressum" }} {{ $ctaEnabled := or (.Params.cta.enable) (or .Params.cta_text .Params.cta_label) }} {{ if $ctaEnabled }}

{{ .Params.cta_text | default "Lassen Sie uns Ihre Vision mit unserer Expertise zur Realität machen." }}

{{/* Optional: Bei Bedarf zweite Zeile aus subtitle wiederverwenden */}} {{ with .Params.subtitle }}

{{ . }}

{{ end }}
{{ with .Params.cta_label }} {{ . }} {{ end }}
{{ end }} {{ end }}