/* ================================================================
   Basis-Styles und globale Einstellungen
   ================================================================ */
*, *::before, *::after {
  box-sizing: border-box;
}
html, body {
  margin: 0;
  padding: 0;
  font-family: system-ui, sans-serif;
  background: #F6F5F1;
  color: #222;
}

/* ================================================================
   Link-Styles
   ================================================================ */
a {
  text-decoration: none !important;
  color: #009C6C;
}
a:visited { color: #009C6C; }
a:hover, a:focus { color: #AA0600; }
a:active { color: #AA0600; }

/* ================================================================
   Header / Navigationsleiste
   ================================================================ */
.site-header {
  --header-height: 110px;
  --header-padding: 2rem;
  --header-opacity: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: #F6F5F1;
  transition:
    height 0.25s cubic-bezier(.4,0,.2,1),
    padding 0.25s cubic-bezier(.4,0,.2,1),
    opacity 0.25s cubic-bezier(.4,0,.2,1),
    box-shadow 0.25s cubic-bezier(.4,0,.2,1),
    background 0.25s cubic-bezier(.4,0,.2,1);
  height: var(--header-height);
  padding: 0 var(--header-padding);
  opacity: var(--header-opacity);
  backdrop-filter: blur(8px);
  will-change: height, opacity, padding;
  margin-top: 0.5rem;
}

/* Logo im Header */
.site-header .logo img {
  --logo-height: 100px;
  height: var(--logo-height);
  transition: height 0.25s cubic-bezier(.4,0,.2,1);
}
.logo img { height: 90px; }

/* ================================================================
   Navigation
   ================================================================ */
.site-nav ul {
  display: flex;
  list-style: none;
  gap: 2rem;
  margin: 0;
  padding: 0;
}
.site-nav a {
  position: relative;
  overflow: visible;
  padding: 0.35em 0;
  color: #009C6C;
  font-size: 1.5rem;
  text-decoration: none;
  transition:
    color 0.3s cubic-bezier(.4,0,.2,1),
    letter-spacing 1.2s cubic-bezier(.4,0,.2,1);
}
.site-nav a:hover,
.site-nav a:focus {
  letter-spacing: 0.28em;
  color: #AA0600;
  transition:
    color 0.3s cubic-bezier(.4,0,.2,1),
    letter-spacing 1.1s cubic-bezier(.4,0,.2,1);
}
.site-nav a::before,
.site-nav a::after {
  content: '';
  position: absolute;
  left: 50%;
  width: 0;
  height: 2px;
  background: #009C6C;
  transition:
    width 0.35s cubic-bezier(.4,0,.2,1),
    left 0.35s cubic-bezier(.4,0,.2,1);
  z-index: 1;
  pointer-events: none;
  border-radius: 2px;
}
.site-nav a::before { top: -6px; }
.site-nav a::after { bottom: -6px; }
.site-nav a:hover::before,
.site-nav a:focus::before,
.site-nav a:hover::after,
.site-nav a:focus::after {
  width: 100%;
  left: 0;
  background: #009C6C;
}

/* ================================================================
   Social Icons
   ================================================================ */
.social-icons {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.icon-link {
  display: inline-block;
  position: relative;
  width: 24px;
  height: 20px;
  overflow: hidden;
  vertical-align: middle;
}
.icon-link .icon-img {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  object-fit: contain;
  transition: opacity 0.2s;
  display: block;
}
.icon-link .hover { opacity: 0; pointer-events: none; }
.icon-link:hover .hover { opacity: 1; pointer-events: auto; }
.icon-link:hover .normal { opacity: 0; }

/* Social Icons sanft vergrößern (nur Desktop!) */
@media (hover: hover) and (pointer: fine) {
  .site-header .social-icons .icon-link {
    transition: transform 0.48s cubic-bezier(.33,1,.55,1), box-shadow 0.24s cubic-bezier(.33,1,.55,1);
    will-change: transform;
  }
  .site-header .social-icons .icon-link:hover,
  .site-header .social-icons .icon-link:focus {
    transform: scale(1.45);
    box-shadow: 0 6px 28px -8px rgba(30,160,120,0.13);
    z-index: 2;
  }
}

/* ================================================================
   Burger-Menü (nur mobil)
   ================================================================ */
.burger {
  display: none;
  background: none;
  border: none;
  width: 38px;
  height: 32px;
  cursor: pointer;
  position: relative;
  z-index: 11;
  margin-top: 8px;
}
.burger::before,
.burger::after,
.burger span {
  content: '';
  display: block;
  background: #009C6C;
  height: 3px;
  border-radius: 2px;
  position: absolute;
  left: 4px;
  right: 4px;
  transition: all 0.3s;
}
.burger::before { top: 6px; }
.burger span    { top: 14px; }
.burger::after  { top: 22px; }
.burger.open span      { opacity: 0; }
.burger.open::before   { transform: rotate(45deg); top: 14px; }
.burger.open::after    { transform: rotate(-45deg); top: 14px; }

/* ================================================================
   Hauptinhalt / Main Content
   ================================================================ */
main {
  max-width: 1400px;
  margin: 0.5rem auto;
  padding: 0 1rem;
}
.page-content.narrow {
  max-width: 750px;
  margin: 0.5rem auto;
  padding: 0 1rem;
}

main, .page-content.narrow, .hero-text {
  font-size: 1.2rem; /* oder z.B. 1.3rem, je nach gewünschter Größe */
}

h1 {
  font-size: 2rem;    /* Standard ist oft 2.5-3rem – 2rem ist etwas kleiner */
  margin-bottom: 1rem;
}

/* ================================================================
   Blog-Teaser Grid & Karten
   ================================================================ */
.blog-teaser-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0rem 1rem;
  margin-bottom: 2rem;
  justify-content: center;
}
.blog-card {
  flex: 1 1 150px;
  box-sizing: border-box;
  background: #FCFBF7;
  border-radius: 7px;
  display: flex;
  align-items: flex-start;
  padding: 0.75rem;
  min-width: 350px;
  max-width: 900px;
  margin-bottom: 1rem;
  transition: border-color .2s;
  width: 100%;
  min-height: 0 !important;
  height: auto !important;
  opacity: 0;
  transform: translateY(100px);
  transition:
    opacity 1.2s cubic-bezier(.3, .7, .4, 1),
    transform 1.2s cubic-bezier(.3, .7, .4, 1),
    box-shadow 0.25s,
    scale 0.25s;
  will-change: opacity, transform, scale;
}
.blog-card.appear {
  opacity: 1;
  transform: translateY(0);
}
.blog-card:hover,
.blog-card:focus {
  z-index: 10;
  scale: 1.04;
  box-shadow: 0 8px 28px -8px rgba(30,80,60,0.16);
  border-color: #009C6C !important;
}
.blog-teaser-grid .blog-card {
  border: 1px solid #c4c4c4 !important;
}
.card-content {
  flex: 1;
}
.blog-card .card-img {
  width: 125px;           /* feste Breite */
  height: 135px;          /* feste Höhe */
  min-width: 120px;
  min-height: 120px;
  overflow: hidden;       /* Bild schneidet überstehende Teile ab */
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: bold;
  margin-right: 1rem;
}
.blog-card .card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;      /* Bild wird reingequetscht und gecropped */
  border-radius: 4px;
  display: block;
}
.blog-card .card-title {
  font-weight: bold;
  margin-bottom: 0.5rem;
  color: #009C6C !important;
  text-decoration: none !important;
}
.blog-card:hover .card-title,
.blog-card .card-title:hover {
  color: #AA0600 !important;
  text-decoration: underline !important;
  cursor: pointer;
}
.blog-card .card-desc {
  font-size: 1rem;
  color: #444;
}
.card-date {
  display: block;
  color: #888;
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
}
.card-desc {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ================================================================
   Blog-Inhalt (Detailseite)
   ================================================================ */
.blog-content {
  flex: 4 1 1200px;
  padding: 2rem 2rem 3rem 0;
  max-width: 700px;
  margin: 2.5rem auto;
  background: transparent;
  box-sizing: border-box;
  max-height: none !important;
  overflow-y: visible !important;
}
.blog-content img,
.blog-content iframe,
.blog-content video {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 1.5rem auto;
  box-sizing: border-box;
}
.blog-content table {
  max-width: 100%;
  overflow-x: auto;
  display: block;
}

/* ================================================================
   Code- und Tabellen-Styles
   ================================================================ */

/* Codeblock Styling */
pre code {
  background-color: #2d2d2d;
  color: #f8f8f2;
  padding: 1rem;
  border-radius: 6px;
  display: block;
  overflow-x: auto;
  font-size: 0.95rem;
}
/* Inline Code */
code {
  background-color: #f4f4f4;
  padding: 0.2em 0.4em;
  border-radius: 4px;
  font-family: monospace;
}
/* Tabellen */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-size: 0.95rem;
}
th, td {
  border: 1px solid #ddd;
  padding: 0.5rem;
  text-align: left;
}
th {
  background-color: #f5f5f5;
  font-weight: bold;
}
tr:nth-child(even) {
  background-color: #fafafa;
}

/* ================================================================
   Footer / Fußzeile
   ================================================================ */
footer {
  text-align: center;
  font-size: 1.3rem;
  color: #666;
  margin: 2rem 0 1rem 0;
}
.footer-links {
  margin-bottom: 0.5rem;
}
.footer-links a:hover {
  color: #AA0600;
  text-decoration: underline;
}

/* ================================================================
   Responsive Design - Breakpoints
   ================================================================ */

/* ------- Ab 900px abwärts -------- */
@media (max-width: 900px) {
  .blog-teaser-grid {
    flex-direction: column;
    align-items: center;
  }
  .blog-content { width: 100%; }
  .site-nav, .site-header .social-icons { display: none; }
  .burger { display: block !important; }
  .mobile-menu-overlay { display: none; }
  .mobile-menu-overlay.open { display: flex; }
  .mobile-menu-overlay > nav { margin-bottom: 2rem !important; }
  .mobile-menu-overlay > .social-icons { margin-bottom: 3rem !important; }
  .mobile-menu-overlay nav ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0;
    margin: 0 0 2rem 0;
  }
  .mobile-menu-overlay nav a {
    font-size: 1.5rem;
    font-weight: bold;
    line-height: 2;
    text-align: center;
  }
  .mobile-menu-overlay .icon-link {
    width: 40px;
    height: 40px;
  }
  .mobile-menu-overlay .icon-img {
    width: 100%;
    height: 100%;
  }
  .mobile-menu-overlay .social-icons { gap: 2rem; }
  .blog-card {
    min-width: unset;
    max-width: 95vw;
    width: 95vw;
    box-sizing: border-box;
    padding: 0.5rem;
  }
  .blog-teaser-grid .blog-card {
    max-width: 900px !important;
    width: 100%;
    min-width: unset !important;
    margin-left: auto;
    margin-right: auto;
  }
  .blog-content {
    max-height: none;
    overflow-y: visible;
    padding-left: 0;
    padding-right: 0;
  }
  .post-nav-grid .blog-card,
  .blog-card {
    min-width: 0 !important;
    max-width: 100vw !important;
    width: 100% !important;
  }
}

/* ------- Ab 600px abwärts -------- */
@media (max-width: 600px) {
  .icon-link { width: 24px; }
  .icon-img { height: 24px; }
  .site-header { flex-direction: row; gap: 0; }
  .blog-card { padding: 0.25rem; }
  .site-nav, .site-header .social-icons { display: none; }
  .burger { display: block !important; }
  .mobile-menu-overlay { display: none; }
  .mobile-menu-overlay.open { display: flex; }
  .post-nav-grid .blog-card {
    padding: 0.15rem !important;
    font-size: 0.98rem;
  }
}

/* ================================================================
   Mobile Menü Overlay
   ================================================================ */
.mobile-menu-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: #F6F5F1;
  z-index: 10;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: 7rem;
  overflow-y: auto;
}
.mobile-menu-overlay.open {
  display: flex;
}
body.noscroll { overflow: hidden; }

/* ================================================================
   Navigation unter Blogposts (Post-Navigation)
   ================================================================ */
.post-nav-grid {
  display: flex;
  gap: 1rem;
  margin: 3.5rem auto 1.7rem auto;
  justify-content: center;
  align-items: stretch;
  flex-wrap: wrap;
  max-width: 700px;
  width: 100%;
}
.post-nav-grid .blog-card {
  flex: 1 1 0;
  min-width: 0;
  margin-bottom: 0;
  max-width: unset;
}
@media (max-width: 900px) {
  .post-nav-grid {
    flex-direction: column;
    gap: 1.2rem;
    align-items: center;
    max-width: 95vw;
    display: none !important;
  }
  .post-nav-grid .blog-card {
    width: 100%;
  }
}

/* ================================================================
   Suchfeld / Searchbox & Suchergebnisse
   ================================================================ */

/* Container für Suchfeld und Button */
#searchbox-container {
  display: flex;                   /* Flexbox-Layout für horizontale Anordnung */
  flex-direction: row;             /* Elemente nebeneinander anordnen */
  align-items: center;             /* Vertikal zentrieren */
  justify-content: center;         /* Horizontal zentrieren */
  margin-top: 4em;               /* Abstand nach oben */
  margin-bottom: 0.2em;            /* Abstand nach unten */
}

/* Suchfeld-Eingabe */
#searchbox {
  width: 320px;                    /* Feste Breite */
  max-width: 90vw;                 /* Maximal 90% der Viewport-Breite */
  padding: 0.3em;                  /* Innenabstand */
  font-size: 1.1em;                /* Schriftgröße */
  margin-bottom: 0.2em;            /* Abstand nach unten */
  border: 2px solid #009C6C;       /* Rahmen */
  border-radius: 8px;              /* Abgerundete Ecken */
  outline: none;                   /* Kein Standard-Umrandung bei Fokus */
  background: #FCFBF7;             /* Hintergrundfarbe */
  transition: border-color 0.2s;   /* Übergang für Rahmenfarbe beim Fokus */
}

/* Rahmenfarbe beim Fokus auf Suchfeld */
#searchbox:focus { 
  border-color: #AA0600;           /* Rahmenfarbe bei Fokus */
}

/* Container für Such-Info (z.B. "16 Treffer gefunden") */
#searchinfo {
  display: flex;                   /* Flexbox-Layout */
  flex-direction: column;          /* Elemente untereinander */
  align-items: center;             /* Zentrieren */
  min-height: 1em;                 /* Minimale Höhe */
  margin-bottom: 0.3em;            /* Abstand nach unten zum Grid */
}

/* Stil für Such-Info-Text (Anzahl Treffer) */
.search-info {
  color: #009C6C;                  /* Schriftfarbe grün */
  font-size: 1em;                  /* Schriftgröße */
  text-align: center;              /* Zentrierter Text */
  margin-bottom: 0.2em;            /* Abstand nach unten */
}

/* Stil für "Keine Treffer gefunden" */
.search-info.notfound { 
  color: rgb(92, 92, 92);          /* Graue Schriftfarbe */
}

/* Grid für Suchergebnisse */
#searchresults {
  width: 100%;                     /* Volle Breite */
  max-width: 1400px;               /* Maximal 1400px breit */
  margin-left: auto;               /* Zentrieren */
  margin-right: auto;              /* Zentrieren */
  display: flex;                   /* Flexbox-Layout für Karten */
  flex-wrap: wrap;                 /* Karten umbrechen bei Bedarf */
  gap: 0rem 1rem;                  /* Horizontaler Abstand zwischen Karten */
  margin-bottom: 0.2rem;           /* Abstand nach unten */
  justify-content: center;         /* Karten zentrieren */
}




.highlight {
  font-weight: bold;
  color: #AA0600;
}


/* ================================================================
   Pagination / Seiten-Navigation
   ================================================================ */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.1em;
  margin-top: 1.5em;
  margin-bottom: 2em;
  font-size: 1.12em;
}
@media (max-width: 600px) {
  .pagination {
    /*flex-direction: column;*/
    gap: 0.5em;
    font-size: 1em;
  }
}


 /* ================================================================
    Bild rechts neben Text index.html
    ================================================================ */

.hero-flex {
  display: flex;                        /* Layout mit Flexbox (Text & Bild nebeneinander) */
  align-items: flex-start;               /* Am oberen Rand ausrichten */
  justify-content: space-between;        /* Abstand zwischen Text und Bild */
  gap: 2.5rem;                          /* Abstand zwischen den Spalten */
  margin-bottom: 2rem;                   /* Abstand nach unten */
  margin-top: 1.5rem;                    /* Abstand nach oben */
  flex-wrap: wrap;                       /* Bei wenig Platz untereinander statt nebeneinander */
}

.hero-text {
  flex: 1 1 400px;                       /* Flexibler Bereich: wächst & schrumpft, min 400px */
  min-width: 320px;                      /* Niemals schmaler als 320px */
}

.hero-img img {
  display: block;                        /* Bild als Blockelement */
  max-width: 420px;                      /* Maximal 420px breit */
  min-width: 220px;                      /* Mindestens 220px breit */
  width: 100%;                           /* Bild füllt gesamten Container */
  border-radius: 1.3rem;                 /* Abgerundete Ecken */
  box-shadow: 0 4px 20px rgba(0,0,0,0.09); /* Sanfter Schlagschatten */
  margin-top: 0.5rem;                    /* Abstand nach oben */
}

.hero-img {
  flex: 0 1 450px;                       /* Festes Flex-Verhalten für Bildbereich, max 450px */
  display: flex;                         /* Inneres Flexbox-Layout */
  justify-content: flex-end;             /* Bild ganz rechts ausrichten */
  align-items: flex-start;               /* Oben ausrichten */
}

/* --- Responsive Anpassung für kleinere Bildschirme --- */
@media (max-width: 950px) {
  .hero-flex {
    flex-direction: column;              /* Spalten werden untereinander gestapelt */
    align-items: center;                 /* Zentrieren */
    gap: 1.5rem;                         /* Weniger Abstand */
  }
  .hero-img,
  .hero-img img {
    max-width: 99vw;                     /* Bild maximal fast so breit wie das Fenster */
    width: 99vw;                         /* Bild nimmt fast ganze Breite ein */
  }
}



 /* ================================================================
    Blog.html
    ================================================================ */

  .blog-list {
  max-width: 700px;
  margin: 2rem auto;
  display: flex;
  flex-direction: column;
  gap: 1rem; /* Mehr Abstand zwischen Posts */
}
.blog-list-item {
  padding-bottom: 0.7rem;
  border-bottom: 1px solid #ddd;
}
.blog-list-title {
  font-size: 1.3em;
  color: #009C6C;
  font-weight: bold;        /* Fetter Titel */
  text-decoration: none;
  display: block;           /* Macht den Abstand nach unten besser */
  margin-bottom: 0.3em;     /* Abstand nach unten zum Datum */
}
.blog-list-title:hover {
  color: #AA0600;
  text-decoration: underline;
}
.blog-list-date {
  color: #999;
  font-size: 0.98em;
  margin-bottom: 0.25em;
}
.blog-list-excerpt {
  color: #444;
  margin-top: 0.1em;
}


/*Scroll-Effekt in beide Richtungen*/
.fade-up {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1.8s ease, transform 1.8s ease;
  will-change: opacity, transform;
}

.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

  .right-align {
    text-align: right;
  }


/*blog Posts beim Laden der Seite von links nach rechts erscheinen*/
  .blog-list-item {
  opacity: 0;
  transform: translateX(-50px);
  transition: all 0.6s ease-out;
}

.blog-list-item.visible {
  opacity: 1;
  transform: translateX(0);
}

/* Suchergebnisse IMMER sichtbar machen */
#searchresults .blog-list-item {
  opacity: 1 !important;
  transform: none !important;
  transition: none !important;
}