/* Globale Einstellungen */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  font-family: 'Open Sans', sans-serif;
  color: #333;
  line-height: 1.6;
  background-image: url('../images/industry-406905_1280.jpg');
  background-size: cover;
  background-attachment: fixed;
  background-position: center;
  overflow-x: hidden;
}

/* Fixierte Navigationsleiste oben */
.top-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: rgba(255, 255, 255, 0.95);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.top-nav .logo {
  font-weight: bold;
  color: #C62828;
}

.top-nav ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

.top-nav li {
  font-size: 0.95rem;
}

.top-nav a {
  text-decoration: none;
  color: #333;
  transition: color 0.3s ease;
}

.top-nav a:hover {
  color: #FF5722;
}

/* Scrollcontainer unter der Navigation */
.scroll-container {
  margin-top: 100px;
  padding: 2rem;
}

/* Basis für alle Cards */
.card {
  background-color: rgba(255, 255, 255, 0.80);
  margin-bottom: 30px;
  padding: 2rem;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  max-width: 950px;
  margin-left: auto;
  margin-right: auto;
  max-height: none;
  overflow-y: visible;
}

/* Für Einzel-Cards (z. B. den ersten) ohne Scroll */
.card:first-of-type,
.card.hero {    
  max-height: 400px;
  overflow-y: auto;
}

/* Hero-Bereich */
.hero {
  text-align: center;
  max-width: 950px;
  margin: 0 auto 2rem auto;
}

/* Überschriften */
h2 {
  color: #C62828;
  margin-bottom: 1rem;
}

/* Footer */
.footer {
  text-align: center;
  font-size: 0.9rem;
  color: #666;
  margin-top: 30px;
}

.footer a {
  color: #FF5722;
  text-decoration: none;
}

/* Neue Grid-Struktur für zwei bündige Cards nebeneinander */
.grid-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 90px;
  max-width: 950px;
  margin: 0 auto;
  padding-top: 0;
  padding-bottom: 0;
}

/* Entfernt überflüssigen Abstand von umgebenden Cards */
.grid-container,
.grid-container + *,
.card + .grid-container,
.grid-container + .card {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

/* Sorgt dafür, dass nach dem Grid wieder 30px Abstand zum Footer bleibt */
.grid-container + .card.full-width {
  margin-top: 0px;
}

/* Erste große Card belegt beide Spalten */
.card.full-width {
  grid-column: span 2;
}

/* Halbe Cards füllen jeweils eine Spalte */
.card.half-left {
  grid-column: 1 / 2;
}

.card.half-right {
  grid-column: 2 / 3;
}

/* Rot für erste große Überschrift */
.card h1,
.card h2 {
  color: #C62828;
}

/* Responsive Design */
@media (max-width: 768px) {
  .top-nav {
    flex-direction: column;
    align-items: flex-start;
  }

  .top-nav ul {
    flex-direction: column;
    gap: 0.5rem;
  }

  .grid-container {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .card.full-width,
  .card.half-left,
  .card.half-right {
    grid-column: auto;
  }
}

/* Container für die Slideshow */
.slideshow {
  position: relative;
  width: 100%;
  height: 400px;
  max-width: 100%;
  margin: 0 auto;
  border-radius: 10px;
  overflow: hidden;
  background-color: #000;
}

/* Jedes Slide */
.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  animation: slideShow 35s linear infinite;
}

/* Reihenfolge der Slides */
.slide:nth-child(1) { animation-delay: 0s }
.slide:nth-child(2) { animation-delay: 7s }
.slide:nth-child(3) { animation-delay: 14s }
.slide:nth-child(4) { animation-delay: 21s }
.slide:nth-child(5) { animation-delay: 28s }

/* Animation: Einschalten und Ausschalten */
@keyframes slideShow {
  0% { opacity: 0; }
  10% { opacity: 1; }
  20% { opacity: 0; }
  100% { opacity: 0; }
}

/* Bildunterschrift */
.slide-caption {
  position: absolute;
  bottom: 10px;
  left: 15px;
  color: #fff;
  background-color: rgba(0, 0, 0, 0.5);
  padding: 8px 12px;
  font-size: 1rem;
  border-radius: 5px;
}

/* --- Dienstleistungsseiten-Karten --- */
.services-section {
  max-width: 1000px;
  margin: 0 auto;
  padding: 4rem 2rem;
  margin-top: 68px;
}

.service-card {
  background: rgba(255, 255, 255, 0.80);
  border-radius: 10px;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  width: 450px;
  margin-left: auto;
  margin-right: auto;
  opacity: 0;
  visibility: hidden;
  animation-fill-mode: forwards;
  animation-duration: 1s;
  animation-timing-function: ease-out;
}

.slide-left {
  transform: translateX(-100px);
  animation-name: fadeInLeft;
  animation-delay: 0.2s;
}

.slide-right {
  transform: translateX(100px);
  animation-name: fadeInRight;
  animation-delay: 0.4s;
}

@keyframes fadeInLeft {
  to {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
  }
}

@keyframes fadeInRight {
  to {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
  }
}

.cards-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
}

/* --- Kontaktseiten-Karte --- */
.contact-section {  
  max-width: 950px;
  margin: 0 auto 30px auto;
  text-align: left;
  margin-top: 130px;
}

.contact-card {
  background: rgba(255, 255, 255, 0.80);
  border-radius: 10px;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  animation: fadeInUp 1s ease-out forwards; 
  opacity: 0;
  transform: translateY(20px);
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.contact-card h2 {
  font-size: 1.8rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
  color: #222;
}

.contact-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: #444;
}

.contact-card p {
  margin-bottom: 1rem;
  line-height: 1.5;
}

.contact-card hr {
  margin: 2rem 0;
  border: none;
  border-top: 1px solid #ddd;
}

/* Container für Teammitglieder */
.team-member {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 2rem;
}

/* Bild des Teammitglieds */
.team-image {
  flex: 0 0 120px;
  height: 120px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.team-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Info-Bereich */
.team-info h3 {
  margin-bottom: 0.3rem;
  color: #C62828;
}

.team-info p {
  margin: 0;
  line-height: 1.5;
}

/* Responsive Design */
@media (max-width: 768px) {
  .team-member {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }

  .team-image {
    width: 100px;
    height: 100px;
  }
}

/* Schwebende Cards – Einfachere Variante */
.float-in {
  opacity: 0;
  transform: translateY(-30px);
  animation: floatIn 1s forwards;
}

/* Animation: von oben hereinbewegen */
@keyframes floatIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Verzögerung für jede Karte, damit sie nacheinander kommen */
.card.half-left:nth-child(1) { animation-delay: 0.3s; }
.card.half-right:nth-child(2) { animation-delay: 0.5s; }
.card.half-left:nth-child(3) { animation-delay: 0.7s; }
.card.half-right:nth-child(4) { animation-delay: 0.9s; }

/* Sprachumschalter als Dropdown */
.language-switcher {
  position: relative;
  margin-left: auto;
}

.lang-btn {
  background: none;
  border: 1px solid #C62828;
  color: #C62828;
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.lang-btn:hover,
.lang-btn:focus {
  background-color: #C62828;
  color: white;
}

/* Dropdown-Menü – Sprachen untereinander */
.dropdown-menu {
  position: absolute;
  top: 100%;
  right: 0;
  background: white;
  border: 1px solid #ddd;
  border-radius: 5px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  list-style: none;
  padding: 0;
  margin: 0;
  width: 100px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 1000;
  display: flex;
  flex-direction: column;
}

/* Nur wenn offen: sichtbar */
.dropdown-menu.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* Menüpunkte */
.dropdown-menu li {
  width: 100%;
}

/* Menüpunkte – kompakt und übersichtlich */
.dropdown-menu li a {
  display: block;
  padding: 0.3rem 1rem;        /* Minimaler Innenabstand */
  color: #333;
  text-decoration: none;
  font-size: 0.9rem;
  line-height: 1.2;            /* Enge Zeilenhöhe */
  border-bottom: 1px solid #f0f0f0;
  margin: 0;
}

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

.dropdown-menu li a:hover,
.dropdown-menu li a:focus {
  background-color: #f5f5f5;
  color: #C62828;
}

/* Button mit Pfeil */
.lang-btn::after {
  content: " ▼";
  font-size: 0.7rem;
}

/* Hervorhebung des aktiven Menüpunkts */
.top-nav ul li a.active {
  background-color: rgba(198, 40, 40, 0.1);
  color: #C62828;
  transition: all 0.3s ease;
}

.top-nav ul li a.active:hover {
  background-color: rgba(198, 40, 40, 0.15);
}
