:root {
  --green-900: #173b24;
  --green-800: #245236;
  --green-700: #2f6b45;
  --green-100: #eef7ef;
  --green-050: #f7fbf6;
  --soil: #7a5a3a;
  --sand: #f3eadc;
  --text: #21302a;
  --muted: #60706a;
  --white: #ffffff;
  --border: #dbe6dd;
  --shadow: 0 18px 40px rgba(23, 59, 36, 0.12);
}

* { box-sizing: border-box; }

html {
  /* Verhindert, dass mobile Browser (v.a. iOS Safari) Text automatisch
     vergrößern, unabhängig von den hier festgelegten Schriftgrößen */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--text);
  line-height: 1.6;
  background: var(--green-050);
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; overflow-wrap: break-word; word-break: break-word; }

.container{
    width: 92%;
    max-width: 1400px;
    margin: 0 auto;
}

.topbar {
  background: var(--green-900);
  color: var(--white);
  font-size: 0.9rem;
  padding: 8px 0;
}

.header {
  background: rgba(255,255,255,0.96);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(8px);
}

.nav {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  color: var(--green-900);
}

.logo-mark {
  width: clamp(140px, 32vw, 400px);
  height: 74px;
  display: flex;
  align-items: center;
}

.logo-mark img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.logo small { display: block; color: var(--muted); font-weight: 400; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  font-weight: 600;
  color: var(--green-900);
}

.nav-links a { padding: 8px 4px; border-bottom: 2px solid transparent; }
.nav-links a:hover, .nav-links a.active { border-color: var(--green-700); color: var(--green-700); }

.menu-button {
  display: none;
  background: var(--green-900);
  color: var(--white);
  border: 0;
  border-radius: 10px;
  padding: 10px 14px;
  font-weight: 700;
}

.hero {
  position: relative;
  background:
    linear-gradient(90deg, rgba(23,59,36,.65), rgba(23,59,36,.40)),
    url('../images/sellerie.jpg');
  background-size: cover;
  background-position: center 10%;
  color: var(--white);
  padding: 92px 0 86px;
}
.photo-credit{
  position: absolute;
  bottom: 12px;
  right: 12px;

  background: rgba(0,0,0,.65);
  color: rgba(255,255,255,.95);

  padding: 6px 10px;
  border-radius: 6px;

  font-size: 0.75rem;

  opacity: 0;
  transition: opacity .25s ease;

  z-index: 10;
}

.hero:hover .photo-credit{
  opacity: 1;
}

/* Auf Touch-Geräten immer sichtbar */
@media (hover: none){
  .photo-credit{
    opacity: 1;
  }
}
.hero .container { max-width: 1400px; }
.hero-label {text-transform: uppercase; letter-spacing: .1em; font-weight: 700; color: #cfe6c8; }
.hero h1 { font-size: clamp(1.6rem, 4vw + 0.9rem, 4.8rem); line-height: 1.05; margin: 16px 0; overflow-wrap: break-word; hyphens: auto; }
.hero p { font-size: 1.25rem; max-width: 1800px; color: #eef8ee; text-align: justify; hyphens: auto; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.button {
  display: inline-block;
  padding: 13px 20px;
  border-radius: 999px;
  font-weight: 700;
  border: 2px solid transparent;
}
.button.primary { background: var(--white); color: var(--green-900); }
.button.secondary { border-color: rgba(255,255,255,.65); color: var(--white); }
.button.dark { background: var(--green-800); color: var(--white); }

.section { padding: 72px 0; }
.section.alt { background: var(--white); }
.section-title { max-width: 1900px; margin-bottom: 34px; }
.section-kicker { color: var(--green-700); font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
h1, h2, h3 { overflow-wrap: break-word; hyphens: auto; }
h2 { font-size: clamp(1.3rem, 2.5vw + 0.7rem, 2.8rem); line-height: 1.15; margin: 8px 0 14px; color: var(--green-900); }
h3 { color: var(--green-900); margin-top: 0; max-width: 800px}
.lead {
    font-size: 1rem;          /* gleiche Größe wie Fließtext */
    line-height: 1.6;
    font-weight: 600;
    color: var(--green-900);

    text-align: justify;
    hyphens: auto;

    margin: 0 0 1.5rem 0;
}

.grid { display: grid; gap: 24px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px}
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid.five { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 26px;
  box-shadow: var(--shadow);
}
.card.flat { box-shadow: none; }
.icon { font-size: 2rem; margin-bottom: 12px; }
.card p{hyphens:auto;text-align:justify;}

.feature {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 38px;
  align-items: center;
}

.image-box {
  min-height: 500px;
  max-width: 700px;
  background:
    linear-gradient(135deg, rgba(47,107,69,.22), rgba(122,90,58,.22)),
    url('../images/bumblebee.jpg');
  background-size: cover;
  background-position: center;
  border-radius: 50px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255,255,255,.5);
}
.image-box {
  /* Verschiebt die Box nur so weit nach rechts, wie tatsächlich Rand
     neben dem (max. 1400px breiten) Container zur Verfügung steht -
     dadurch kein Überlauf bei mittleren oder sehr breiten Fenstern */
  transform: translateX(clamp(0px, calc((100vw - 1400px) / 2), 100px));
}

.checklist { list-style: none; padding: 0; margin: 20px 0 0; }
.checklist li { padding-left: 30px; position: relative; margin: 10px 0; }
.checklist li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--green-700);
  font-weight: 900;
}

.news-card time, .event-card time, .pub-meta { color: var(--muted); font-size: .95rem; font-weight: 600; }
.tag {
  display: inline-block;
  border-radius: 999px;
  background: var(--green-100);
  color: var(--green-800);
  font-size: .84rem;
  font-weight: 700;
  padding: 4px 10px;
  margin-bottom: 12px;
}


.page-hero {
  background: var(--sand);
  padding: 62px 0;
  border-bottom: 1px solid var(--border);
}
.page-hero h1 { color: var(--green-900); font-size: clamp(1.5rem, 3.2vw + 0.7rem, 3.5rem); line-height: 1.08; margin: 0 0 12px; overflow-wrap: break-word; hyphens: auto; }
.page-hero p { max-width: 800px; color: var(--muted); font-size: 1.15rem; }

.content { padding: 58px 0 82px; }
.content-block { max-width: 860px; }

.table-like { display: grid; gap: 14px; }
.row {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 18px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
}
.row-radio {
  display: grid;
  grid-template-columns: 190px 1fr 1fr;
  gap: 18px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
}

.row strong { color: var(--green-900); }

.footer {
  background: var(--green-900);
  color: var(--white);
  padding: 50px 0 30px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1fr;
  gap: 80px;
  align-items: start;
}

.footer a {
  color: #d8ecd4;
}

.copyright {
  display: block;
  margin-top: 18px;
  color: #c6d8c3;
  font-size: 0.9rem;
  line-height: 1.5;
}

.footer-logos-wrapper {
  background: #ffffff;
  border-radius: 18px;
  margin-top: 40px;
  padding: 25px 40px;
}

.footer-logos {
  display: flex;
    justify-content: center;   /* statt flex-end */
    align-items: center;
    gap: 60px;
    flex-wrap: wrap;
}

.footer-logos img {
  height: 80px;
  width: auto; 
}

.logo-ilb {
  min-height: 80px;
}
.logo-efre {
  min-height: 95px;
}
.logo-igz {
  max-height: 75px;
}
.logo-hnee {
  max-height: 70px;
}

@media (max-width: 860px) {
  .footer-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 30px;
  }

  .footer-logos {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    justify-items: center;
    align-items: center;
    gap: 24px 20px;
  }

  .footer-logos img {
    height: auto;
    max-height: 55px;
  }

  .footer-logos-wrapper {
    padding: 20px;
  }
}

.placeholder-note {
  background: #fff8e8;
  border: 1px solid #ead9ac;
  padding: 14px 16px;
  border-radius: 14px;
  color: #5d4a22;
}

@media (max-width: 860px) {
  .menu-button { display: inline-block; }
  .nav { align-items: flex-start; padding: 14px 0; }
  .nav-links {
    display: none;
    position: absolute;
    left: 16px;
    right: 16px;
    top: 88px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 16px;
    flex-direction: column;
    align-items: flex-start;
    box-shadow: var(--shadow);
  }
  .nav-links.open { display: flex; }
  .grid.two, .grid.three, .grid.four, .feature, .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .row, .row-radio { grid-template-columns: minmax(0, 1fr); }
  .hero { padding: 70px 0; }

  /* Bildbox auf der Startseite: horizontalen Versatz zurücksetzen,
     damit sie nicht aus dem sichtbaren Bereich rutscht */
  .image-box {
    transform: none;
    min-height: 320px;
    max-width: 100%;
  }

  /* Blocksatz erzeugt bei schmalen Spalten (Handy) hässliche
     Wortabstände und viel Silbentrennung -> auf Mobil linksbündig */
  .hero p,
  .lead,
  .card p {
    text-align: left;
  }
}

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

.card-link .card {
  height: 100%;
  transition: transform .2s ease, box-shadow .2s ease;
}

.card-link:hover .card {
  transform: translateY(-4px);
}


.contact-layout {
  display: grid;
  grid-template-columns: 0.8fr 1fr;
  gap: 40px;
  align-items: start;
}

.contact-image {
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.contact-image img {
  width: 100%;
  max-width: none;
}

.page-hero p {
  columns: unset;
  column-count: 1;

  max-width: 1800px;
  text-align: justify;
  hyphens: auto;
}

.partner-images {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-top: 24px;
}

.partner-image img {
  width: 100%;
  height: 320px;
position: relative;
  object-fit: cover;
  object-position: bottom;

  border-radius: 22px;
  box-shadow: var(--shadow);
  display: block;
}
.partner-image {
  margin: 0;
}

.partner-image figcaption {
  margin-top: 10px;

  font-size: 0.9rem;
  color: var(--muted);

  text-align: center;
  line-height: 1.4;
}

@media (max-width: 1060px) {
  .partner-images {
    grid-template-columns: minmax(0, 1fr);
  }
}

.project-figure {
  margin: 0;
  text-align: center;
  align-items: start;
  justify-items: start;
}

.project-figure img {
  width: 100%;
  max-width: 1200px;
  height: auto;
  margin: 0;
}

.project-figure figcaption {
  margin-top: 12px;
  font-size: 0.9rem;
  color: var(--muted);
}

.dropdown {
  position: relative;
}

.dropdown-content {
  display: none;
  position: absolute;

  top: 100%;
  left: 0;

  min-width: 280px;

  background: white;
  border: 1px solid var(--border);
  border-radius: 16px;

  box-shadow: var(--shadow);

  z-index: 100;
  overflow: hidden;
}

.dropdown-content a {
  display: block;
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
}

.dropdown-content a:last-child {
  border-bottom: none;
}

.dropdown-content a:hover {
  background: var(--green-100);
}

.dropdown:hover .dropdown-content {
  display: block;
}

.image-wrapper{
    position: relative;
    width: 100%;
}

.photo-credit{
    position: absolute;
    bottom: 10px;
    right: 10px;

    background: rgba(0,0,0,.7);
    color: white;

    padding: 6px 10px;
    border-radius: 6px;

    font-size: .75rem;

    opacity: 0;
    transition: opacity .25s ease;
}

.image-wrapper:hover .photo-credit{
    opacity: 1;
}
.partner-image:hover .photo-credit {
    opacity: 1;
}

/* =====================================================
   Warming Stripes
   ===================================================== */

.warming-stripes{
  width: 100%;
  max-width: 800px;
  margin: 0;
  position: center;
}

.warming-stripes img{
  width: 100%;
  height: auto;
  display: block;
}

.warming-stripes figcaption{
  margin-top: 12px;
  width: 100%;
  font-size: 0.9rem;
  color: var(--muted);
}



/* =====================================================
   Niederschlagskarte + Erläuterung
   ===================================================== */

.climate-layout{
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 50px;
  align-items: start;
  justify-items: start;
}

.rainfall-map{
  margin: 0;
}

.rainfall-map img{
  width: 100%;
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.rainfall-map figcaption{
  margin-top: 12px;
  font-size: 0.9rem;
  color: var(--muted);
}

.climate-text{
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.climate-text p{
  margin: 0;
  text-align: justify;
  hyphens: auto;
}

.source-note{
  font-size: 0.9rem;
  color: var(--muted);
  font-style: italic;
}

/* =====================================================
   Mobile Ansicht
   ===================================================== */

@media (max-width: 860px){

  .climate-layout{
    grid-template-columns: minmax(0, 1fr);
    justify-items: stretch;
  }

}

.pub-meta {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.pub-meta:hover {
  text-decoration: underline;
}


/* =====================================================
   Text + Bildergalerie
   ===================================================== */

.robot-layout{

    display:grid;
    grid-template-columns: 1.3fr 1fr;

    gap:60px;

    align-items:start;
}

.robot-text{

    text-align:justify;

    hyphens:auto;
}

@media (max-width:900px){

.robot-layout{

    grid-template-columns:1fr;
}

}

/* ==========================================================
   Bildergalerie
   ========================================================== */

.gallery{

    max-width:650px;

    margin:auto;

}

.gallery-frame{

    position:relative;

    overflow:hidden;

    border-radius:18px;

    box-shadow:var(--shadow);

    background:#fff;

}

.gallery-frame img{

    display:block;

    width:100%;

    aspect-ratio:4/3;

    object-fit:cover;

    transition:opacity .35s ease;

    cursor:pointer;

}

.gallery-frame img.fade{

    opacity:0;

}

/* Pfeile */

.gallery-btn{

    position:absolute;

    top:50%;

    transform:translateY(-50%);

    width:46px;

    height:46px;

    border:none;

    border-radius:50%;

    background:rgba(0,0,0,.45);

    color:white;

    cursor:pointer;

    font-size:1.5rem;

    transition:.25s;

}

.gallery-btn:hover{

    background:rgba(0,0,0,.75);

}

.prev{

    left:12px;

}

.next{

    right:12px;

}

/* Punkte */

.gallery-dots{

    display:flex;

    justify-content:center;

    align-items:center;

    gap:8px;

    margin:20px 0;

}

.gallery-dot{

    width:8px;

    height:8px;

    padding:0;

    border:none;

    border-radius:999px;

    background:#d7d7d7;

    cursor:pointer;

    transition:width .25s ease, background-color .25s ease;

}

.gallery-dot:hover{

    background:#b8b8b8;

}

.gallery-dot.active{

    width:24px;

    background:var(--green);

}

/* Beschreibung */

.gallery-info{

    text-align:center;

}

.gallery-title{

    margin-bottom:8px;

}

#gallery-credit{

    color:#777;

    font-size:.9rem;

}

#gallery-counter{

    display:block;

    margin-top:15px;

    font-size:.9rem;

    color:#888;

}

.photo-credit{
    opacity:0;
}

.gallery:hover .photo-credit,
.gallery:focus-within .photo-credit{
    opacity:1;
}

.gallery-btn:focus-visible,
.gallery-dot:focus-visible{
    outline:2px solid var(--green);
    outline-offset:2px;
}

@media (max-width:600px){

.gallery{
    max-width:100%;
}

.gallery-btn{
    width:36px;
    height:36px;
    font-size:1.2rem;
}

.gallery-dot{
    width:6px;
    height:6px;
}

.gallery-dot.active{
    width:20px;
}

#gallery-caption{
    font-size:.85rem;
}

}
/* =====================================================
   Mobile Overrides (bewusst am Dateiende platziert)
   -----------------------------------------------------
   Diese Regeln überschreiben Basis-Definitionen, die an
   verschiedenen Stellen weiter oben im Stylesheet stehen.
   Bei gleicher Spezifität gewinnt in CSS die zuletzt
   stehende Regel - deshalb müssen Mobil-Overrides für
   Bauteile, deren Basis-Regel selbst weiter unten im
   Dokument steht, ganz ans Ende der Datei.
   ===================================================== */

@media (max-width: 860px) {

  .contact-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  /* Dropdown-Untermenü: auf Touch-Geräten funktioniert :hover nicht,
     daher innerhalb des mobilen Menüs immer als eingerückte Liste anzeigen */
  .dropdown-content {
    display: block;
    position: static;
    box-shadow: none;
    border: none;
    border-radius: 0;
    min-width: 0;
    margin: 6px 0 6px 12px;
  }

  /* Blocksatz erzeugt bei schmalen Spalten (Handy) hässliche
     Wortabstände und viel Silbentrennung -> auf Mobil linksbündig */
  .page-hero p,
  .climate-text p,
  .robot-text {
    text-align: left;
  }
}

