body {
  font-family: sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  background-color: #f7f7f7;
  color: #333;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
header {
    background: #2C5C47;
    background: linear-gradient(0deg, rgba(44, 92, 71, 1) 10%, rgba(57, 119, 91, 1) 45%, rgba(57, 119, 91, 1) 55%, rgba(44, 92, 71, 1) 90%);
    color: white;
    padding: 2rem 1rem;
    text-align: center;
    position: relative;
}
header img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid white;
  position: absolute;
  top: 1rem;
  left: 1rem;
}
.language-toggle {
  margin-top: 1rem;
}

/* Sticky Navbar */
nav {
  background-color: #e5e5e5;
  text-align: center;
  position: sticky;
  top: 0;
  z-index: 1000;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  /* padding: 0.5rem 0; /* */
  border-bottom: 1px solid #ccc;
}

/* Sprachbutton fixiert links */
.lang-toggle {
    position: absolute;
    left: 1rem;
    background: none;
    border: none;
    color: #2c5c47;
    font-size: 1.2rem;
    cursor: pointer;
    /* padding-top: 1rem; /* */
    /* margin: 0 0.5rem; /* */
    margin-top: 1rem;
}

/* Zentrierte Buttons */
.nav-center {
    /*border-left: 1px solid black; /* */
    display: flex;
    gap: 0.5rem;
}

.nav-button {
  color: #2c5c47;
  background: none;
  border: none;
  padding: 1rem;
  margin: 0 0.5rem;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.3s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
}

.nav-button i {
    display: none;
  font-size: 1.2rem;
}

.nav-button:hover {
  background-color: #ccc;
}

.nav-button.active {
  background-color: #2c5c47;
  color: #ffffff;
}

.nav-button.active i {
  color: #ffffff;
}

.nav-label {
  display: inline;
}

main {
  flex: 1;
  max-width: 800px;
  margin: auto;
  padding: 1rem;
}

main a {
    color: #2c5c47;
    text-decoration: none;
    /*color: #336655; */
}
main a:hover {
    text-decoration: underline;
}

.section {
  display: none;
}
.section.active {
    display: block;
    /* border: 1px solid black; /* TESTING */
    max-width: 800px;       /* maximale Breite auf großen Bildschirmen */
  /*width: 90%;             /* relative Breite auf kleinen Bildschirmen */
    margin: 0 auto;         /* zentriert horizontal */
    padding: 2em 1em;       /* etwas Innenabstand oben/unten und links/rechts */
}
footer {
    background-color: #2c5c47;
    color: white;
    text-align: center;
    padding: 1rem;
}
footer p {
    margin: 0.3rem 0;
}
footer p span {
    white-space: nowrap;
}
footer a {
    color: white;
    margin: 0 0.5rem;
    text-decoration: none;
    font-size: 1.2rem;
}

/* PUBLICATIONS STYLE*/
.pub_references {
  display: block;
  list-style-type: none;
  margin-top: 1em;
  margin-bottom: 1em;
  margin-left: 2em;
  margin-right: 0;
  padding-left: 0;
  text-indent: -2em;
}

/* CV, TEACHING STYLING */
.cv-entry, .teaching-entry {
    display: flex;
    flex-direction: row;
    gap: 0rem 1rem; /* row-gap column-gap*/
    margin-bottom: 1rem;
    /*border: 2px solid green; /* TESTING */
}
.cv-date, .teaching-semester {
    width: 140px;
    font-weight: bold;
    flex-shrink: 0;
    color: #2C5C47; /* leicht angepasst ans Grün */
    /* border: 2px solid red; /* TESTING */
    /*margin-right: 1rem; /* */
}
.cv-text, .teaching-course {
    flex: 1;
    /* border: 2px solid blue; /* TESTING */
}

/* contact details in footer */


@media (max-width: 600px) {
    .cv-entry, .teaching-entry {
        flex-direction: column;
    }
    .cv-date, .teaching-semester {
        width: auto;
    }
}
/* // CV STYLING */

@media (max-width: 600px) {
    body {
        font-size: 1rem;
    }
    header {
        font-size: 1.2rem;
        padding-top: 6rem;
    }
    header img {
        position: static;
        display: block;
        margin: 0 auto 1rem;
    }
}

@media (min-width: 600px) {
    .section.active {
        width: 600px;
    }
}

@media (min-width: 769px) {
    .section.active {
        width: 769px;
    }
}


/* Mobile: only show icons */
@media (max-width: 768px) {
  .nav-label {
    display: none;
  }

  .nav-button {
    /* padding: 0.7rem; /* */
      padding-left: 0.75rem;
      padding-right: 0.75rem;
      margin-left: 0rem;
      margin-right: 0rem;
    font-size: 0.9rem;
  }

  .nav-button i {
    font-size: 1.2rem;
      display: inline; /* Wichtig, um Icons sichtbar zu machen */
  }
}

@media (max-width: 375px) {
  .nav-button {
      padding-left: 0.75rem;
      padding-right: 0.75rem;
      margin-left: 0rem;
      margin-right: 0rem;
    }
    .nav-center {
    gap: 0rem;
    }
}
